glebtv-ckeditor 4.7.3 → 4.14.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/Gemfile +13 -12
- data/README.md +358 -2
- data/Rakefile +17 -17
- data/app/assets/javascripts/ckeditor/config.js.erb +3 -3
- data/app/controllers/ckeditor/application_controller.rb +3 -0
- data/app/controllers/ckeditor/attachment_files_controller.rb +2 -0
- data/app/controllers/ckeditor/pictures_controller.rb +2 -0
- data/app/helpers/ckeditor/application_helper.rb +2 -0
- data/config/locales/bg.ckeditor.yml +9 -0
- data/config/locales/cs.ckeditor.yml +9 -0
- data/config/locales/da.ckeditor.yml +9 -0
- data/config/locales/de.ckeditor.yml +9 -0
- data/config/locales/el-GR.cdkeditor.yml +9 -0
- data/config/locales/es.ckeditor.yml +9 -0
- data/config/locales/fr.ckeditor.yml +9 -0
- data/config/locales/hu.ckeditor.yml +9 -0
- data/config/locales/it.ckeditor.yml +9 -0
- data/config/locales/ja.ckeditor.yml +9 -0
- data/config/locales/nb.ckeditor.yml +9 -0
- data/config/locales/nl.ckeditor.yml +9 -0
- data/config/locales/pl.ckeditor.yml +9 -0
- data/config/locales/pt-BR.ckeditor.yml +9 -0
- data/config/locales/pt-PT.ckeditor.yml +9 -0
- data/config/locales/pt.ckeditor.yml +9 -0
- data/config/locales/sq.ckeditor.yml +9 -0
- data/config/locales/sv-SE.ckeditor.yml +9 -0
- data/config/locales/tr.ckeditor.yml +9 -0
- data/config/locales/uk.ckeditor.yml +9 -0
- data/config/locales/zh-CN.ckeditor.yml +9 -0
- data/config/locales/zh-TW.ckeditor.yml +9 -0
- data/config/routes.rb +2 -0
- data/lib/ckeditor.rb +13 -16
- data/lib/ckeditor/asset_response.rb +15 -4
- data/lib/ckeditor/backend/active_storage.rb +68 -0
- data/lib/ckeditor/backend/carrierwave.rb +2 -12
- data/lib/ckeditor/backend/dragonfly.rb +2 -0
- data/lib/ckeditor/backend/paperclip.rb +2 -15
- data/lib/ckeditor/backend/shrine.rb +29 -0
- data/lib/ckeditor/helpers/controllers.rb +2 -0
- data/lib/ckeditor/helpers/form_builder.rb +2 -0
- data/lib/ckeditor/helpers/form_helper.rb +2 -0
- data/lib/ckeditor/helpers/view_helper.rb +2 -0
- data/lib/ckeditor/hooks/cancan.rb +4 -1
- data/lib/ckeditor/hooks/formtastic.rb +2 -0
- data/lib/ckeditor/hooks/pundit.rb +2 -0
- data/lib/ckeditor/hooks/simple_form.rb +2 -0
- data/lib/ckeditor/http.rb +8 -5
- data/lib/ckeditor/orm/active_record.rb +2 -0
- data/lib/ckeditor/orm/base.rb +11 -2
- data/lib/ckeditor/orm/mongoid.rb +2 -0
- data/lib/ckeditor/paginatable.rb +2 -0
- data/lib/ckeditor/rails.rb +2 -0
- data/lib/ckeditor/rails_admin/field.rb +16 -3
- data/lib/ckeditor/text_area.rb +2 -0
- data/lib/ckeditor/utils.rb +3 -16
- data/lib/ckeditor/utils/javascript_code.rb +1 -1
- data/lib/ckeditor/version.rb +4 -2
- data/lib/generators/ckeditor/install_generator.rb +16 -19
- data/lib/generators/ckeditor/pundit_policy_generator.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/active_storage/ckeditor/asset.rb +10 -0
- data/lib/generators/ckeditor/templates/active_record/{refile → active_storage}/ckeditor/attachment_file.rb +3 -1
- data/lib/generators/ckeditor/templates/active_record/active_storage/ckeditor/picture.rb +13 -0
- data/lib/generators/ckeditor/templates/active_record/{carrierwave/migration_versioned.rb → active_storage/migration.rb} +8 -5
- data/lib/generators/ckeditor/templates/active_record/carrierwave/ckeditor/asset.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/carrierwave/ckeditor/attachment_file.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/carrierwave/ckeditor/picture.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/carrierwave/migration.rb +7 -5
- data/lib/generators/ckeditor/templates/active_record/dragonfly/ckeditor/asset.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/dragonfly/ckeditor/attachment_file.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/dragonfly/ckeditor/picture.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/dragonfly/migration.rb +7 -5
- data/lib/generators/ckeditor/templates/active_record/paperclip/ckeditor/asset.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/paperclip/ckeditor/attachment_file.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/paperclip/ckeditor/picture.rb +2 -0
- data/lib/generators/ckeditor/templates/active_record/paperclip/migration.rb +8 -6
- data/lib/generators/ckeditor/templates/active_record/{refile → shrine}/ckeditor/asset.rb +3 -1
- data/lib/generators/ckeditor/templates/active_record/shrine/ckeditor/attachment_file.rb +21 -0
- data/lib/generators/ckeditor/templates/active_record/shrine/ckeditor/picture.rb +49 -0
- data/lib/generators/ckeditor/templates/active_record/shrine/migration.rb +22 -0
- data/lib/generators/ckeditor/templates/base/carrierwave/uploaders/ckeditor_attachment_file_uploader.rb +2 -1
- data/lib/generators/ckeditor/templates/base/carrierwave/uploaders/ckeditor_picture_uploader.rb +2 -3
- data/lib/generators/ckeditor/templates/base/dragonfly/initializer.rb +2 -0
- data/lib/generators/ckeditor/templates/base/shrine/initializer.rb +25 -0
- data/lib/generators/ckeditor/templates/ckeditor.rb +3 -6
- data/lib/generators/ckeditor/templates/mongoid/carrierwave/ckeditor/asset.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/carrierwave/ckeditor/attachment_file.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/carrierwave/ckeditor/picture.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/paperclip/ckeditor/asset.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/paperclip/ckeditor/attachment_file.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/paperclip/ckeditor/picture.rb +2 -0
- data/lib/generators/ckeditor/templates/mongoid/shrine/ckeditor/asset.rb +8 -0
- data/lib/generators/ckeditor/templates/mongoid/shrine/ckeditor/attachment_file.rb +21 -0
- data/lib/generators/ckeditor/templates/mongoid/shrine/ckeditor/picture.rb +47 -0
- data/lib/generators/ckeditor/templates/pundit_policy/attachment_file_policy.rb +2 -0
- data/lib/generators/ckeditor/templates/pundit_policy/picture_policy.rb +2 -0
- data/lib/tasks/ckeditor.rake +2 -0
- data/test/controllers/attachment_files_controller_test.rb +17 -15
- data/test/controllers/pictures_controller_test.rb +17 -15
- data/test/dummy/Rakefile +2 -0
- data/test/dummy/app/assets/javascripts/application.js +0 -2
- data/test/dummy/app/controllers/application_controller.rb +2 -0
- data/test/dummy/app/controllers/posts_controller.rb +2 -0
- data/test/dummy/app/helpers/application_helper.rb +2 -0
- data/test/dummy/app/helpers/posts_helper.rb +2 -0
- data/test/dummy/app/models/post.rb +2 -0
- data/test/dummy/app/views/posts/index.html.erb +0 -3
- data/test/dummy/app/views/posts/show.html.erb +3 -0
- data/test/dummy/config.ru +2 -0
- data/test/dummy/config/application.rb +5 -1
- data/test/dummy/config/boot.rb +2 -0
- data/test/dummy/config/environment.rb +2 -0
- data/test/dummy/config/environments/development.rb +2 -0
- data/test/dummy/config/environments/production.rb +2 -0
- data/test/dummy/config/environments/test.rb +5 -3
- data/test/dummy/config/initializers/assets.rb +2 -0
- data/test/dummy/config/initializers/backtrace_silencers.rb +2 -0
- data/test/dummy/config/initializers/ckeditor.rb +2 -0
- data/test/dummy/config/initializers/cookies_serializer.rb +2 -0
- data/test/dummy/config/initializers/inflections.rb +2 -0
- data/test/dummy/config/initializers/mime_types.rb +2 -0
- data/test/dummy/config/initializers/paperclip.rb +2 -0
- data/test/dummy/config/initializers/session_store.rb +2 -0
- data/test/dummy/config/initializers/wrap_parameters.rb +2 -0
- data/test/dummy/config/routes.rb +2 -0
- data/test/dummy/config/storage.yml +3 -0
- data/test/dummy/db/migrate/20110623120047_create_posts.rb +5 -3
- data/test/dummy/db/migrate/20170806125915_create_active_storage_tables.rb +26 -0
- data/test/dummy/script/rails +2 -0
- data/test/functional/posts_controller_test.rb +18 -16
- data/test/generators/install_generator_test.rb +58 -56
- data/test/integration/navigation_test.rb +2 -0
- data/test/models/attachment_file_test.rb +4 -4
- data/test/models/ckeditor_test.rb +3 -21
- data/test/models/picture_test.rb +12 -10
- data/test/models/utils_test.rb +2 -0
- data/test/orm/active_record.rb +11 -1
- data/test/orm/mongoid.rb +2 -0
- data/test/support/helpers.rb +2 -0
- data/test/support/integration_case.rb +2 -0
- data/test/test_helper.rb +15 -9
- data/vendor/assets/javascripts/ckeditor/CHANGES.md +1404 -859
- data/vendor/assets/javascripts/ckeditor/LICENSE.md +8 -7
- data/vendor/assets/javascripts/ckeditor/README.md +5 -5
- data/vendor/assets/javascripts/ckeditor/adapters/jquery.js +7 -7
- data/vendor/assets/javascripts/ckeditor/build-config.js +12 -6
- data/vendor/assets/javascripts/ckeditor/ckeditor.js +1090 -907
- data/vendor/assets/javascripts/ckeditor/config.js +2 -2
- data/vendor/assets/javascripts/ckeditor/contents.css +7 -7
- data/vendor/assets/javascripts/ckeditor/lang/en.js +3 -3
- data/vendor/assets/javascripts/ckeditor/lang/ru.js +3 -3
- data/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/a11yhelp.js +7 -7
- data/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/en.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/a11yhelp/dialogs/lang/ru.js +3 -3
- data/vendor/assets/javascripts/ckeditor/plugins/about/dialogs/about.js +5 -5
- data/vendor/assets/javascripts/ckeditor/plugins/about/dialogs/hidpi/logo_ckeditor.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/about/dialogs/logo_ckeditor.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/clipboard/dialogs/paste.js +11 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/css/codemirror.min.css +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/icons/autoformat.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/icons/searchcode.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/icons/uncommentselectedrange.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/images/autocomplete.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/images/autoformat.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/images/commentselectedrange.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/images/searchcode.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/images/uncommentselectedrange.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/beautify.min.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.addons.min.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.addons.search.min.js +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.min.js +1 -6
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.bbcodemixed.min.js +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.handlebars.min.js +1 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.htmlmixed.min.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.javascript.min.js +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.php.min.js +3 -3
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.twig.min.js +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/plugin.js +236 -218
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/base16-light.css +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/darcula.css +51 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/gruvbox-dark.css +37 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/idea.css +42 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/lesser-dark.css +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/lucario.css +37 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/monokai.css +5 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/nord.css +42 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/oceanic-next.css +44 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/panda-syntax.css +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/shadowfox.css +52 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/solarized.css +0 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/ssms.css +16 -0
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/vibrant-ink.css +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/codemirror/theme/yonce.css +59 -0
- data/vendor/assets/javascripts/ckeditor/plugins/colordialog/dialogs/colordialog.css +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/colordialog/dialogs/colordialog.js +12 -12
- data/vendor/assets/javascripts/ckeditor/plugins/dialog/dialogDefinition.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/dialog/styles/dialog.css +18 -0
- data/vendor/assets/javascripts/ckeditor/plugins/div/dialogs/div.js +9 -8
- data/vendor/assets/javascripts/ckeditor/plugins/find/dialogs/find.js +23 -23
- data/vendor/assets/javascripts/ckeditor/plugins/flash/dialogs/flash.js +17 -17
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/button.js +6 -6
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/checkbox.js +5 -5
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/form.js +3 -3
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/hiddenfield.js +5 -5
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/radio.js +7 -7
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/select.js +17 -16
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/textarea.js +7 -6
- data/vendor/assets/javascripts/ckeditor/plugins/forms/dialogs/textfield.js +9 -9
- data/vendor/assets/javascripts/ckeditor/plugins/icons.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/icons_hidpi.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/iframe/dialogs/iframe.js +9 -8
- data/vendor/assets/javascripts/ckeditor/plugins/image/dialogs/image.js +1271 -44
- data/vendor/assets/javascripts/ckeditor/plugins/image/icons/hidpi/image.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image/icons/image.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image/lang/en.js +25 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image/lang/ru.js +25 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image/plugin.js +184 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/dev/assets/image1.jpg +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/dev/assets/image2.jpg +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/dev/contents.css +35 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/dev/image2.html +339 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/dialogs/image2.js +553 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/icons/hidpi/image.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/icons/image.png +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/lang/en.js +21 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/lang/ru.js +21 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/plugin.js +1783 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/samples/assets/image1.jpg +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/samples/assets/image2.jpg +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/image2/samples/image2.html +69 -0
- data/vendor/assets/javascripts/ckeditor/plugins/lineheight/plugin.js +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/link/dialogs/anchor.js +5 -5
- data/vendor/assets/javascripts/ckeditor/plugins/link/dialogs/link.js +27 -25
- data/vendor/assets/javascripts/ckeditor/plugins/liststyle/dialogs/liststyle.js +8 -8
- data/vendor/assets/javascripts/ckeditor/plugins/loremipsum/lang/fr.js +8 -0
- data/vendor/assets/javascripts/ckeditor/plugins/loremipsum/plugin.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/pastefromword/filter/default.js +41 -51
- data/vendor/assets/javascripts/ckeditor/plugins/pastetools/filter/common.js +22 -0
- data/vendor/assets/javascripts/ckeditor/plugins/pastetools/filter/image.js +6 -0
- data/vendor/assets/javascripts/ckeditor/plugins/preview/images/pagebreak.gif +0 -0
- data/vendor/assets/javascripts/ckeditor/plugins/preview/styles/screen.css +10 -0
- data/vendor/assets/javascripts/ckeditor/plugins/scayt/CHANGELOG.md +1 -17
- data/vendor/assets/javascripts/ckeditor/plugins/scayt/README.md +63 -7
- data/vendor/assets/javascripts/ckeditor/plugins/scayt/dialogs/options.js +32 -33
- data/vendor/assets/javascripts/ckeditor/plugins/smiley/dialogs/smiley.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/en.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/lang/ru.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/specialchar/dialogs/specialchar.js +12 -12
- data/vendor/assets/javascripts/ckeditor/plugins/stylesheetparser/plugin.js +10 -10
- data/vendor/assets/javascripts/ckeditor/plugins/stylesheetparser/samples/stylesheetparser.html +8 -7
- data/vendor/assets/javascripts/ckeditor/plugins/table/dialogs/table.js +20 -19
- data/vendor/assets/javascripts/ckeditor/plugins/tabletools/dialogs/tableCell.js +16 -15
- data/vendor/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.css +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/templates/dialogs/templates.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/templates/templates/default.js +2 -2
- data/vendor/assets/javascripts/ckeditor/plugins/widget/images/handle.png +0 -0
- data/vendor/assets/javascripts/ckeditor/{samples/toolbarconfigurator/lib/codemirror/LICENSE → plugins/wordcount/LICENSE.md} +21 -19
- data/vendor/assets/javascripts/ckeditor/plugins/wordcount/README.md +106 -0
- data/vendor/assets/javascripts/ckeditor/plugins/wordcount/lang/en.js +1 -0
- data/vendor/assets/javascripts/ckeditor/plugins/wordcount/lang/ru.js +2 -1
- data/vendor/assets/javascripts/ckeditor/plugins/wordcount/plugin.js +475 -378
- data/vendor/assets/javascripts/ckeditor/plugins/wordcount/samples/maxParagraphs.html +26 -0
- data/vendor/assets/javascripts/ckeditor/plugins/wsc/README.md +62 -7
- data/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/tmpFrameset.html +1 -1
- data/vendor/assets/javascripts/ckeditor/plugins/wsc/dialogs/wsc.js +82 -82
- data/vendor/assets/javascripts/ckeditor/plugins/youtube/LICENSE.md +15 -0
- data/vendor/assets/javascripts/ckeditor/plugins/youtube/README.md +156 -0
- data/vendor/assets/javascripts/ckeditor/plugins/youtube/plugin.js +8 -7
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor_gecko.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor_ie.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor_ie7.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor_ie8.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/editor_iequirks.css +1 -1
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/icons.png +0 -0
- data/vendor/assets/javascripts/ckeditor/skins/minimalist/icons_hidpi.png +0 -0
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/dialog.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/dialog_ie.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/dialog_ie8.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/dialog_iequirks.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/editor.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/editor_gecko.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/editor_ie.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/editor_ie8.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/editor_iequirks.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/readme.md +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono-lisa/skin.js +2 -2
- data/vendor/assets/javascripts/ckeditor/skins/moono/dialog.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/dialog_ie.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/dialog_ie7.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/dialog_ie8.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/dialog_iequirks.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor_gecko.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor_ie.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor_ie7.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor_ie8.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/editor_iequirks.css +3 -3
- data/vendor/assets/javascripts/ckeditor/skins/moono/readme.md +5 -5
- data/vendor/assets/javascripts/ckeditor/skins/moono/skin.js +2 -2
- data/vendor/assets/javascripts/ckeditor/styles.js +4 -4
- data/vendor/assets/javascripts/ckeditor/vendor/promise.js +13 -0
- metadata +143 -138
- data/lib/ckeditor/backend/refile.rb +0 -39
- data/lib/ckeditor/utils/content_type_detector.rb +0 -38
- data/lib/generators/ckeditor/templates/active_record/dragonfly/migration_versioned.rb +0 -23
- data/lib/generators/ckeditor/templates/active_record/paperclip/migration_versioned.rb +0 -23
- data/lib/generators/ckeditor/templates/active_record/refile/ckeditor/picture.rb +0 -11
- data/lib/generators/ckeditor/templates/active_record/refile/migration.rb +0 -23
- data/lib/generators/ckeditor/templates/active_record/refile/migration_versioned.rb +0 -23
- data/test/support/raw_post.rb +0 -9
- data/vendor/assets/javascripts/ckeditor/plugins/iframedialog/plugin.js +0 -169
- data/vendor/assets/javascripts/ckeditor/plugins/lineheight/lang/ru.js +0 -3
- data/vendor/assets/javascripts/ckeditor/plugins/loremipsum/lang/ru.js +0 -8
- data/vendor/assets/javascripts/ckeditor/plugins/notification/lang/en.js +0 -7
- data/vendor/assets/javascripts/ckeditor/plugins/notification/lang/ru.js +0 -7
- data/vendor/assets/javascripts/ckeditor/plugins/notification/plugin.js +0 -929
- data/vendor/assets/javascripts/ckeditor/samples/css/samples.css +0 -1632
- data/vendor/assets/javascripts/ckeditor/samples/img/github-top.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/img/header-bg.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/img/header-separator.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/img/logo.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/img/navigation-tip.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/index.html +0 -128
- data/vendor/assets/javascripts/ckeditor/samples/js/sample.js +0 -53
- data/vendor/assets/javascripts/ckeditor/samples/js/sf.js +0 -17
- data/vendor/assets/javascripts/ckeditor/samples/old/ajax.html +0 -85
- data/vendor/assets/javascripts/ckeditor/samples/old/api.html +0 -210
- data/vendor/assets/javascripts/ckeditor/samples/old/appendto.html +0 -59
- data/vendor/assets/javascripts/ckeditor/samples/old/assets/inlineall/logo.png +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/old/assets/outputxhtml/outputxhtml.css +0 -204
- data/vendor/assets/javascripts/ckeditor/samples/old/assets/posteddata.php +0 -59
- data/vendor/assets/javascripts/ckeditor/samples/old/assets/sample.jpg +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/old/assets/uilanguages/languages.js +0 -7
- data/vendor/assets/javascripts/ckeditor/samples/old/datafiltering.html +0 -508
- data/vendor/assets/javascripts/ckeditor/samples/old/dialog/assets/my_dialog.js +0 -48
- data/vendor/assets/javascripts/ckeditor/samples/old/dialog/dialog.html +0 -190
- data/vendor/assets/javascripts/ckeditor/samples/old/divreplace.html +0 -144
- data/vendor/assets/javascripts/ckeditor/samples/old/enterkey/enterkey.html +0 -106
- data/vendor/assets/javascripts/ckeditor/samples/old/htmlwriter/assets/outputforflash/outputforflash.fla +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/old/htmlwriter/assets/outputforflash/outputforflash.swf +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/old/htmlwriter/assets/outputforflash/swfobject.js +0 -19
- data/vendor/assets/javascripts/ckeditor/samples/old/htmlwriter/outputforflash.html +0 -283
- data/vendor/assets/javascripts/ckeditor/samples/old/htmlwriter/outputhtml.html +0 -224
- data/vendor/assets/javascripts/ckeditor/samples/old/index.html +0 -131
- data/vendor/assets/javascripts/ckeditor/samples/old/inlineall.html +0 -314
- data/vendor/assets/javascripts/ckeditor/samples/old/inlinebycode.html +0 -124
- data/vendor/assets/javascripts/ckeditor/samples/old/inlinetextarea.html +0 -113
- data/vendor/assets/javascripts/ckeditor/samples/old/jquery.html +0 -103
- data/vendor/assets/javascripts/ckeditor/samples/old/magicline/magicline.html +0 -209
- data/vendor/assets/javascripts/ckeditor/samples/old/readonly.html +0 -76
- data/vendor/assets/javascripts/ckeditor/samples/old/replacebyclass.html +0 -60
- data/vendor/assets/javascripts/ckeditor/samples/old/replacebycode.html +0 -59
- data/vendor/assets/javascripts/ckeditor/samples/old/sample.css +0 -357
- data/vendor/assets/javascripts/ckeditor/samples/old/sample.js +0 -50
- data/vendor/assets/javascripts/ckeditor/samples/old/sample_posteddata.php +0 -16
- data/vendor/assets/javascripts/ckeditor/samples/old/tabindex.html +0 -78
- data/vendor/assets/javascripts/ckeditor/samples/old/toolbar/toolbar.html +0 -235
- data/vendor/assets/javascripts/ckeditor/samples/old/uicolor.html +0 -72
- data/vendor/assets/javascripts/ckeditor/samples/old/uilanguages.html +0 -122
- data/vendor/assets/javascripts/ckeditor/samples/old/wysiwygarea/fullpage.html +0 -80
- data/vendor/assets/javascripts/ckeditor/samples/old/xhtmlstyle.html +0 -234
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/css/fontello.css +0 -55
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/LICENSE.txt +0 -10
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/config.json +0 -28
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.eot +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.svg +0 -14
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.ttf +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/font/fontello.woff +0 -0
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/index.html +0 -446
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/abstracttoolbarmodifier.js +0 -13
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/fulltoolbareditor.js +0 -9
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/toolbarmodifier.js +0 -33
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/js/toolbartextmodifier.js +0 -14
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/codemirror.css +0 -325
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/codemirror.js +0 -288
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/javascript.js +0 -25
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/neo.css +0 -36
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/show-hint.css +0 -38
- data/vendor/assets/javascripts/ckeditor/samples/toolbarconfigurator/lib/codemirror/show-hint.js +0 -16
@@ -1,6 +1,6 @@
|
|
1
1
|
/**
|
2
|
-
* @license Copyright (c) 2003-
|
3
|
-
* For licensing, see
|
2
|
+
* @license Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
* For licensing, see https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
5
|
|
6
6
|
CKEDITOR.editorConfig = function( config ) {
|
@@ -1,18 +1,19 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
5
|
|
6
6
|
body
|
7
7
|
{
|
8
8
|
/* Font */
|
9
|
-
|
9
|
+
/* Emoji fonts are added to visualise them nicely in Internet Explorer. */
|
10
|
+
font-family: sans-serif, Arial, Verdana, "Trebuchet MS", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";
|
10
11
|
font-size: 12px;
|
11
12
|
|
12
13
|
/* Text color */
|
13
14
|
color: #333;
|
14
15
|
|
15
|
-
/* Remove the background color to make it transparent */
|
16
|
+
/* Remove the background color to make it transparent. */
|
16
17
|
background-color: #fff;
|
17
18
|
|
18
19
|
margin: 20px;
|
@@ -60,7 +61,7 @@ ol,ul,dl
|
|
60
61
|
{
|
61
62
|
/* IE7: reset rtl list margin. (#7334) */
|
62
63
|
*margin-right: 0px;
|
63
|
-
/*
|
64
|
+
/* Preserved spaces for list items with text direction different than the list. (#6249,#8049)*/
|
64
65
|
padding: 0 40px;
|
65
66
|
}
|
66
67
|
|
@@ -113,8 +114,7 @@ span[lang]
|
|
113
114
|
figure
|
114
115
|
{
|
115
116
|
text-align: center;
|
116
|
-
|
117
|
-
border-radius: 2px;
|
117
|
+
outline: solid 1px #ccc;
|
118
118
|
background: rgba(0,0,0,0.05);
|
119
119
|
padding: 10px;
|
120
120
|
margin: 10px 20px;
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/license
|
4
4
|
*/
|
5
|
-
CKEDITOR.lang['en']={"editor":"Rich Text Editor","editorPanel":"Rich Text Editor panel","common":{"editorHelp":"Press ALT 0 for help","browseServer":"Browse Server","url":"URL","protocol":"Protocol","upload":"Upload","uploadSubmit":"Send it to the Server","image":"Image","flash":"Flash","form":"Form","checkbox":"Checkbox","radio":"Radio Button","textField":"Text Field","textarea":"Textarea","hiddenField":"Hidden Field","button":"Button","select":"Selection Field","imageButton":"Image Button","notSet":"
|
5
|
+
CKEDITOR.lang['en']={"editor":"Rich Text Editor","editorPanel":"Rich Text Editor panel","common":{"editorHelp":"Press ALT 0 for help","browseServer":"Browse Server","url":"URL","protocol":"Protocol","upload":"Upload","uploadSubmit":"Send it to the Server","image":"Image","flash":"Flash","form":"Form","checkbox":"Checkbox","radio":"Radio Button","textField":"Text Field","textarea":"Textarea","hiddenField":"Hidden Field","button":"Button","select":"Selection Field","imageButton":"Image Button","notSet":"
|
@@ -1,5 +1,5 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/license
|
4
4
|
*/
|
5
|
-
CKEDITOR.lang['ru']={"editor":"Визуальный текстовый редактор","editorPanel":"Визуальный редактор текста","common":{"editorHelp":"Нажмите ALT-0 для открытия справки","browseServer":"Выбор на сервере","url":"Ссылка","protocol":"Протокол","upload":"Загрузка файла","uploadSubmit":"Загрузить на сервер","image":"Изображение","flash":"Flash","form":"Форма","checkbox":"Чекбокс","radio":"Радиокнопка","textField":"Текстовое поле","textarea":"Многострочное текстовое поле","hiddenField":"Скрытое поле","button":"Кнопка","select":"Выпадающий список","imageButton":"Кнопка-изображение","notSet":"<не указано>","id":"Идентификатор","name":"Имя","langDir":"Направление текста","langDirLtr":"Слева направо (LTR)","langDirRtl":"Справа налево (RTL)","langCode":"Код языка","longDescr":"Длинное описание ссылки","cssClass":"Класс CSS","advisoryTitle":"Заголовок","cssStyle":"Стиль","ok":"ОК","cancel":"Отмена","close":"Закрыть","preview":"Предпросмотр","resize":"Перетащите для изменения размера","generalTab":"Основное","advancedTab":"Дополнительно","validateNumberFailed":"Это значение не является числом.","confirmNewPage":"Несохранённые изменения будут потеряны! Вы действительно желаете перейти на другую страницу?","confirmCancel":"Некоторые параметры были изменены. Вы уверены, что желаете закрыть без сохранения?","options":"Параметры","target":"Цель","targetNew":"Новое окно (_blank)","targetTop":"Главное окно (_top)","targetSelf":"Текущее окно (_self)","targetParent":"Родительское окно (_parent)","langDirLTR":"Слева направо (LTR)","langDirRTL":"Справа налево (RTL)","styles":"Стиль","cssClasses":"CSS классы","width":"Ширина","height":"Высота","align":"Выравнивание","alignLeft":"По левому краю","alignRight":"По правому краю","alignCenter":"По центру","alignJustify":"По ширине","alignTop":"Поверху","alignMiddle":"Посередине","alignBottom":"Понизу","alignNone":"Нет","invalidValue":"Недопустимое значение.","invalidHeight":"Высота задается числом.","invalidWidth":"Ширина задается числом.","invalidCssLength":"Значение, указанное в поле \"%1\", должно быть положительным целым числом. Допускается указание единиц меры CSS (px, %, in, cm, mm, em, ex, pt или pc).","invalidHtmlLength":"Значение, указанное в поле \"%1\", должно быть положительным целым числом. Допускается указание единиц меры HTML (px или %).","invalidInlineStyle":"Значение, указанное для стиля элемента, должно состоять из одной или нескольких пар данных в формате \"параметр : значение\", разделённых точкой с запятой.","cssLengthTooltip":"Введите значение в пикселях, либо число с корректной единицей меры CSS (px, %, in, cm, mm, em, ex, pt или pc).","unavailable":"%1, недоступно","keyboard":{"8":"Backspace","13":"Enter","16":"Shift","17":"Ctrl","18":"Alt","32":"Пробел","35":"End","36":"Home","46":"Delete","224":"Command"},"keyboardShortcut":"Комбинация клавиш"},"about":{"copy":"Copyright © $1. Все права защищены.","dlgTitle":"О CKEditor","help":"$1 содержит подробную справку по использованию.","moreInfo":"Для получения информации о лицензии, пожалуйста, перейдите на наш сайт:","title":"О CKEditor","userGuide":"Руководство пользователя CKEditor"},"basicstyles":{"bold":"Полужирный","italic":"Курсив","strike":"Зачеркнутый","subscript":"Подстрочный индекс","superscript":"Надстрочный индекс","underline":"Подчеркнутый"},"bidi":{"ltr":"Направление текста слева направо","rtl":"Направление текста справа налево"},"blockquote":{"toolbar":"Цитата"},"notification":{"closed":"Уведомление закрыто"},"button":{"selectedLabel":"%1 (Выбрано)"},"toolbar":{"toolbarCollapse":"Свернуть панель инструментов","toolbarExpand":"Развернуть панель инструментов","toolbarGroups":{"document":"Документ","clipboard":"Буфер обмена / Отмена действий","editing":"Корректировка","forms":"Формы","basicstyles":"Простые стили","paragraph":"Абзац","links":"Ссылки","insert":"Вставка","styles":"Стили","colors":"Цвета","tools":"Инструменты"},"toolbars":"Панели инструментов редактора"},"clipboard":{"copy":"Копировать","copyError":"Настройки безопасности вашего браузера не разрешают редактору выполнять операции по копированию текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+C).","cut":"Вырезать","cutError":"Настройки безопасности вашего браузера не разрешают редактору выполнять операции по вырезке текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+X).","paste":"Вставить","pasteNotification":"Ваш браузер не поддерживает данный метод вставки. Для вставки нажмите %1"},"colorbutton":{"auto":"Автоматически","bgColorTitle":"Цвет фона","colors":{"000":"Чёрный","800000":"Бордовый","8B4513":"Кожано-коричневый","2F4F4F":"Темный синевато-серый","008080":"Сине-зелёный","000080":"Тёмно-синий","4B0082":"Индиго","696969":"Тёмно-серый","B22222":"Кирпичный","A52A2A":"Коричневый","DAA520":"Золотисто-берёзовый","006400":"Темно-зелёный","40E0D0":"Бирюзовый","0000CD":"Умеренно синий","800080":"Пурпурный","808080":"Серый","F00":"Красный","FF8C00":"Темно-оранжевый","FFD700":"Золотистый","008000":"Зелёный","0FF":"Васильковый","00F":"Синий","EE82EE":"Фиолетовый","A9A9A9":"Тускло-серый","FFA07A":"Светло-лососевый","FFA500":"Оранжевый","FFFF00":"Жёлтый","00FF00":"Лайма","AFEEEE":"Бледно-синий","ADD8E6":"Свелто-голубой","DDA0DD":"Сливовый","D3D3D3":"Светло-серый","FFF0F5":"Розово-лавандовый","FAEBD7":"Античный белый","FFFFE0":"Светло-жёлтый","F0FFF0":"Медвяной росы","F0FFFF":"Лазурный","F0F8FF":"Бледно-голубой","E6E6FA":"Лавандовый","FFF":"Белый","1ABC9C":"Strong Cyan","2ECC71":"Изумрудный","3498DB":"Bright Blue","9B59B6":"Amethyst","4E5F70":"Grayish Blue","F1C40F":"Ярко-желтый","16A085":"Dark Cyan","27AE60":"Тёмно-изумрудный","2980B9":"Strong Blue","8E44AD":"Тёмно-фиолетовый","2C3E50":"Desaturated Blue","F39C12":"Оранжевый","E67E22":"Морковный","E74C3C":"Pale Red","ECF0F1":"Bright Silver","95A5A6":"Light Grayish Cyan","DDD":"Светло-серый","D35400":"Pumpkin","C0392B":"Strong Red","BDC3C7":"Silver","7F8C8D":"Grayish Cyan","999":"Тёмно-серый"},"more":"Ещё цвета...","panelTitle":"Цвета","textColorTitle":"Цвет текста"},"colordialog":{"clear":"Очистить","highlight":"Под курсором","options":"Настройки цвета","selected":"Выбранный цвет","title":"Выберите цвет"},"templates":{"button":"Шаблоны","emptyListMsg":"(не определено ни одного шаблона)","insertOption":"Заменить текущее содержимое","options":"Параметры шаблона","selectPromptMsg":"Пожалуйста, выберите, какой шаблон следует открыть в редакторе","title":"Шаблоны содержимого"},"contextmenu":{"options":"Параметры контекстного меню"},"div":{"IdInputLabel":"Идентификатор","advisoryTitleInputLabel":"Заголовок","cssClassInputLabel":"Классы CSS","edit":"Редактировать контейнер","inlineStyleInputLabel":"Стиль элемента","langDirLTRLabel":"Слева направо (LTR)","langDirLabel":"Направление текста","langDirRTLLabel":"Справа налево (RTL)","languageCodeInputLabel":"Код языка","remove":"Удалить контейнер","styleSelectLabel":"Стиль","title":"Создать Div-контейнер","toolbar":"Создать Div-контейнер"},"elementspath":{"eleLabel":"Путь элементов","eleTitle":"Элемент %1"},"find":{"find":"Найти","findOptions":"Опции поиска","findWhat":"Найти:","matchCase":"Учитывать регистр","matchCyclic":"По всему тексту","matchWord":"Только слово целиком","notFoundMsg":"Искомый текст не найден.","replace":"Заменить","replaceAll":"Заменить всё","replaceSuccessMsg":"Успешно заменено %1 раз(а).","replaceWith":"Заменить на:","title":"Поиск и замена"},"fakeobjects":{"anchor":"Якорь","flash":"Flash анимация","hiddenfield":"Скрытое поле","iframe":"iFrame","unknown":"Неизвестный объект"},"flash":{"access":"Доступ к скриптам","accessAlways":"Всегда","accessNever":"Никогда","accessSameDomain":"В том же домене","alignAbsBottom":"По низу текста","alignAbsMiddle":"По середине текста","alignBaseline":"По базовой линии","alignTextTop":"По верху текста","bgcolor":"Цвет фона","chkFull":"Разрешить полноэкранный режим","chkLoop":"Повторять","chkMenu":"Включить меню Flash","chkPlay":"Автоматическое воспроизведение","flashvars":"Переменные для Flash","hSpace":"Гориз. отступ","properties":"Свойства Flash","propertiesTab":"Свойства","quality":"Качество","qualityAutoHigh":"Запуск на высоком","qualityAutoLow":"Запуск на низком","qualityBest":"Лучшее","qualityHigh":"Высокое","qualityLow":"Низкое","qualityMedium":"Среднее","scale":"Масштабировать","scaleAll":"Пропорционально","scaleFit":"Заполнять","scaleNoBorder":"Заходить за границы","title":"Свойства Flash","vSpace":"Вертик. отступ","validateHSpace":"Горизонтальный отступ задается числом.","validateSrc":"Вы должны ввести ссылку","validateVSpace":"Вертикальный отступ задается числом.","windowMode":"Взаимодействие с окном","windowModeOpaque":"Непрозрачный","windowModeTransparent":"Прозрачный","windowModeWindow":"Обычный"},"font":{"fontSize":{"label":"Размер","voiceLabel":"Размер шрифта","panelTitle":"Размер шрифта"},"label":"Шрифт","panelTitle":"Шрифт","voiceLabel":"Шрифт"},"forms":{"button":{"title":"Свойства кнопки","text":"Текст (Значение)","type":"Тип","typeBtn":"Кнопка","typeSbm":"Отправка","typeRst":"Сброс"},"checkboxAndRadio":{"checkboxTitle":"Свойства флаговой кнопки","radioTitle":"Свойства кнопки выбора","value":"Значение","selected":"Выбрано","required":"Обязательное поле"},"form":{"title":"Свойства формы","menu":"Свойства формы","action":"Действие","method":"Метод","encoding":"Кодировка"},"hidden":{"title":"Свойства скрытого поля","name":"Имя","value":"Значение"},"select":{"title":"Свойства списка выбора","selectInfo":"Информация о списке выбора","opAvail":"Доступные варианты","value":"Значение","size":"Размер","lines":"строк(и)","chkMulti":"Разрешить выбор нескольких вариантов","required":"Обязательное поле","opText":"Текст","opValue":"Значение","btnAdd":"Добавить","btnModify":"Изменить","btnUp":"Поднять","btnDown":"Опустить","btnSetValue":"Пометить как выбранное","btnDelete":"Удалить"},"textarea":{"title":"Свойства многострочного текстового поля","cols":"Колонок","rows":"Строк"},"textfield":{"title":"Свойства текстового поля","name":"Имя","value":"Значение","charWidth":"Ширина поля (в символах)","maxChars":"Макс. количество символов","required":"Обязательное поле","type":"Тип содержимого","typeText":"Текст","typePass":"Пароль","typeEmail":"Email","typeSearch":"Поиск","typeTel":"Номер телефона","typeUrl":"Ссылка"}},"format":{"label":"Форматирование","panelTitle":"Форматирование","tag_address":"Адрес","tag_div":"Обычное (div)","tag_h1":"Заголовок 1","tag_h2":"Заголовок 2","tag_h3":"Заголовок 3","tag_h4":"Заголовок 4","tag_h5":"Заголовок 5","tag_h6":"Заголовок 6","tag_p":"Обычное","tag_pre":"Моноширинное"},"horizontalrule":{"toolbar":"Вставить горизонтальную линию"},"iframe":{"border":"Показать границы фрейма","noUrl":"Пожалуйста, введите ссылку фрейма","scrolling":"Отображать полосы прокрутки","title":"Свойства iFrame","toolbar":"iFrame"},"image":{"alt":"Альтернативный текст","border":"Граница","btnUpload":"Загрузить на сервер","button2Img":"Вы желаете преобразовать это изображение-кнопку в обычное изображение?","hSpace":"Гориз. отступ","img2Button":"Вы желаете преобразовать это обычное изображение в изображение-кнопку?","infoTab":"Данные об изображении","linkTab":"Ссылка","lockRatio":"Сохранять пропорции","menu":"Свойства изображения","resetSize":"Вернуть обычные размеры","title":"Свойства изображения","titleButton":"Свойства изображения-кнопки","upload":"Загрузить","urlMissing":"Не указана ссылка на изображение.","vSpace":"Вертик. отступ","validateBorder":"Размер границ должен быть задан числом.","validateHSpace":"Горизонтальный отступ должен быть задан числом.","validateVSpace":"Вертикальный отступ должен быть задан числом."},"indent":{"indent":"Увеличить отступ","outdent":"Уменьшить отступ"},"smiley":{"options":"Выбор смайла","title":"Вставить смайл","toolbar":"Смайлы"},"justify":{"block":"По ширине","center":"По центру","left":"По левому краю","right":"По правому краю"},"language":{"button":"Установка языка","remove":"Удалить язык"},"link":{"acccessKey":"Клавиша доступа","advanced":"Дополнительно","advisoryContentType":"Тип содержимого","advisoryTitle":"Заголовок","anchor":{"toolbar":"Вставить / редактировать якорь","menu":"Изменить якорь","title":"Свойства якоря","name":"Имя якоря","errorName":"Пожалуйста, введите имя якоря","remove":"Удалить якорь"},"anchorId":"По идентификатору","anchorName":"По имени","charset":"Кодировка ресурса","cssClasses":"Классы CSS","download":"Скачать как файл","displayText":"Отображаемый текст","emailAddress":"Email адрес","emailBody":"Текст сообщения","emailSubject":"Тема сообщения","id":"Идентификатор","info":"Информация о ссылке","langCode":"Код языка","langDir":"Направление текста","langDirLTR":"Слева направо (LTR)","langDirRTL":"Справа налево (RTL)","menu":"Редактировать ссылку","name":"Имя","noAnchors":"(В документе нет ни одного якоря)","noEmail":"Пожалуйста, введите email адрес","noUrl":"Пожалуйста, введите ссылку","other":"<другой>","popupDependent":"Зависимое (Netscape)","popupFeatures":"Параметры всплывающего окна","popupFullScreen":"Полноэкранное (IE)","popupLeft":"Отступ слева","popupLocationBar":"Панель адреса","popupMenuBar":"Панель меню","popupResizable":"Изменяемый размер","popupScrollBars":"Полосы прокрутки","popupStatusBar":"Строка состояния","popupToolbar":"Панель инструментов","popupTop":"Отступ сверху","rel":"Отношение","selectAnchor":"Выберите якорь","styles":"Стиль","tabIndex":"Последовательность перехода","target":"Цель","targetFrame":"<фрейм>","targetFrameName":"Имя целевого фрейма","targetPopup":"<всплывающее окно>","targetPopupName":"Имя всплывающего окна","title":"Ссылка","toAnchor":"Ссылка на якорь в тексте","toEmail":"Email","toUrl":"Ссылка","toolbar":"Вставить/Редактировать ссылку","type":"Тип ссылки","unlink":"Убрать ссылку","upload":"Загрузка"},"list":{"bulletedlist":"Вставить / удалить маркированный список","numberedlist":"Вставить / удалить нумерованный список"},"liststyle":{"armenian":"Армянская нумерация","bulletedTitle":"Свойства маркированного списка","circle":"Круг","decimal":"Десятичные (1, 2, 3, и т.д.)","decimalLeadingZero":"Десятичные с ведущим нулём (01, 02, 03, и т.д.)","disc":"Окружность","georgian":"Грузинская нумерация (ани, бани, гани, и т.д.)","lowerAlpha":"Строчные латинские (a, b, c, d, e, и т.д.)","lowerGreek":"Строчные греческие (альфа, бета, гамма, и т.д.)","lowerRoman":"Строчные римские (i, ii, iii, iv, v, и т.д.)","none":"Нет","notset":"<не указано>","numberedTitle":"Свойства нумерованного списка","square":"Квадрат","start":"Начиная с","type":"Тип","upperAlpha":"Заглавные латинские (A, B, C, D, E, и т.д.)","upperRoman":"Заглавные римские (I, II, III, IV, V, и т.д.)","validateStartNumber":"Первый номер списка должен быть задан обычным целым числом."},"magicline":{"title":"Вставить здесь параграф"},"maximize":{"maximize":"Развернуть","minimize":"Свернуть"},"newpage":{"toolbar":"Новая страница"},"pagebreak":{"alt":"Разрыв страницы","toolbar":"Вставить разрыв страницы для печати"},"pastetext":{"button":"Вставить только текст","pasteNotification":"Ваш браузер не поддерживает данный метод вставки. Для вставки нажмите %1"},"pastefromword":{"confirmCleanup":"Текст, который вы желаете вставить, по всей видимости, был скопирован из Word. Следует ли очистить его перед вставкой?","error":"Невозможно очистить вставленные данные из-за внутренней ошибки","title":"Вставить из Word","toolbar":"Вставить из Word"},"preview":{"preview":"Предварительный просмотр"},"print":{"toolbar":"Печать"},"removeformat":{"toolbar":"Убрать форматирование"},"save":{"toolbar":"Сохранить"},"selectall":{"toolbar":"Выделить все"},"showblocks":{"toolbar":"Отображать блоки"},"sourcearea":{"toolbar":"Источник"},"specialchar":{"options":"Выбор специального символа","title":"Выберите специальный символ","toolbar":"Вставить специальный символ"},"scayt":{"btn_about":"О SCAYT","btn_dictionaries":"Словари","btn_disable":"Отключить SCAYT","btn_enable":"Включить SCAYT","btn_langs":"Языки","btn_options":"Настройки","text_title":"Проверка орфографии по мере ввода (SCAYT)"},"stylescombo":{"label":"Стили","panelTitle":"Стили форматирования","panelTitle1":"Стили блока","panelTitle2":"Стили элемента","panelTitle3":"Стили объекта"},"table":{"border":"Размер границ","caption":"Заголовок","cell":{"menu":"Ячейка","insertBefore":"Вставить ячейку слева","insertAfter":"Вставить ячейку справа","deleteCell":"Удалить ячейки","merge":"Объединить ячейки","mergeRight":"Объединить с правой","mergeDown":"Объединить с нижней","splitHorizontal":"Разделить ячейку по вертикали","splitVertical":"Разделить ячейку по горизонтали","title":"Свойства ячейки","cellType":"Тип ячейки","rowSpan":"Объединяет строк","colSpan":"Объединяет колонок","wordWrap":"Перенос по словам","hAlign":"Горизонтальное выравнивание","vAlign":"Вертикальное выравнивание","alignBaseline":"По базовой линии","bgColor":"Цвет фона","borderColor":"Цвет границ","data":"Данные","header":"Заголовок","yes":"Да","no":"Нет","invalidWidth":"Ширина ячейки должна быть числом.","invalidHeight":"Высота ячейки должна быть числом.","invalidRowSpan":"Количество объединяемых строк должно быть задано числом.","invalidColSpan":"Количество объединяемых колонок должно быть задано числом.","chooseColor":"Выберите"},"cellPad":"Внутренний отступ ячеек","cellSpace":"Внешний отступ ячеек","column":{"menu":"Колонка","insertBefore":"Вставить колонку слева","insertAfter":"Вставить колонку справа","deleteColumn":"Удалить колонки"},"columns":"Колонки","deleteTable":"Удалить таблицу","headers":"Заголовки","headersBoth":"Сверху и слева","headersColumn":"Левая колонка","headersNone":"Без заголовков","headersRow":"Верхняя строка","invalidBorder":"Размер границ должен быть числом.","invalidCellPadding":"Внутренний отступ ячеек (cellpadding) должен быть числом.","invalidCellSpacing":"Внешний отступ ячеек (cellspacing) должен быть числом.","invalidCols":"Количество столбцов должно быть больше 0.","invalidHeight":"Высота таблицы должна быть числом.","invalidRows":"Количество строк должно быть больше 0.","invalidWidth":"Ширина таблицы должна быть числом.","menu":"Свойства таблицы","row":{"menu":"Строка","insertBefore":"Вставить строку сверху","insertAfter":"Вставить строку снизу","deleteRow":"Удалить строки"},"rows":"Строки","summary":"Итоги","title":"Свойства таблицы","toolbar":"Таблица","widthPc":"процентов","widthPx":"пикселей","widthUnit":"единица измерения"},"undo":{"redo":"Повторить","undo":"Отменить"},"wsc":{"btnIgnore":"Пропустить","btnIgnoreAll":"Пропустить всё","btnReplace":"Заменить","btnReplaceAll":"Заменить всё","btnUndo":"Отменить","changeTo":"Изменить на","errorLoading":"Произошла ошибка при подключении к серверу проверки орфографии: %s.","ieSpellDownload":"Модуль проверки орфографии не установлен. Хотите скачать его?","manyChanges":"Проверка орфографии завершена. Изменено слов: %1","noChanges":"Проверка орфографии завершена. Не изменено ни одного слова","noMispell":"Проверка орфографии завершена. Ошибок не найдено","noSuggestions":"- Варианты отсутствуют -","notAvailable":"Извините, но в данный момент сервис недоступен.","notInDic":"Отсутствует в словаре","oneChange":"Проверка орфографии завершена. Изменено одно слово","progress":"Орфография проверяется...","title":"Проверка орфографии","toolbar":"Проверить орфографию"}};
|
5
|
+
CKEDITOR.lang['ru']={"editor":"Визуальный текстовый редактор","editorPanel":"Визуальный редактор текста","common":{"editorHelp":"Нажмите ALT-0 для открытия справки","browseServer":"Выбор на сервере","url":"Ссылка","protocol":"Протокол","upload":"Загрузка файла","uploadSubmit":"Загрузить на сервер","image":"Изображение","flash":"Flash","form":"Форма","checkbox":"Чекбокс","radio":"Радиокнопка","textField":"Текстовое поле","textarea":"Многострочное текстовое поле","hiddenField":"Скрытое поле","button":"Кнопка","select":"Выпадающий список","imageButton":"Кнопка-изображение","notSet":"<не указано>","id":"Идентификатор","name":"Имя","langDir":"Направление текста","langDirLtr":"Слева направо (LTR)","langDirRtl":"Справа налево (RTL)","langCode":"Код языка","longDescr":"Длинное описание ссылки","cssClass":"Класс CSS","advisoryTitle":"Заголовок","cssStyle":"Стиль","ok":"ОК","cancel":"Отмена","close":"Закрыть","preview":"Предпросмотр","resize":"Перетащите для изменения размера","generalTab":"Основное","advancedTab":"Дополнительно","validateNumberFailed":"Это значение не является числом.","confirmNewPage":"Несохранённые изменения будут потеряны! Вы действительно желаете перейти на другую страницу?","confirmCancel":"Некоторые параметры были изменены. Вы уверены, что желаете закрыть без сохранения?","options":"Параметры","target":"Цель","targetNew":"Новое окно (_blank)","targetTop":"Главное окно (_top)","targetSelf":"Текущее окно (_self)","targetParent":"Родительское окно (_parent)","langDirLTR":"Слева направо (LTR)","langDirRTL":"Справа налево (RTL)","styles":"Стиль","cssClasses":"CSS классы","width":"Ширина","height":"Высота","align":"Выравнивание","left":"По левому краю","right":"По правому краю","center":"По центру","justify":"По ширине","alignLeft":"По левому краю","alignRight":"По правому краю","alignCenter":"По центру","alignTop":"Поверху","alignMiddle":"Посередине","alignBottom":"Понизу","alignNone":"Нет","invalidValue":"Недопустимое значение.","invalidHeight":"Высота задается числом.","invalidWidth":"Ширина задается числом.","invalidLength":"Указанное значение для поля \"%1\" должно быть положительным числом без или с корректным символом единицы измерения (%2)","invalidCssLength":"Значение, указанное в поле \"%1\", должно быть положительным целым числом. Допускается указание единиц меры CSS (px, %, in, cm, mm, em, ex, pt или pc).","invalidHtmlLength":"Значение, указанное в поле \"%1\", должно быть положительным целым числом. Допускается указание единиц меры HTML (px или %).","invalidInlineStyle":"Значение, указанное для стиля элемента, должно состоять из одной или нескольких пар данных в формате \"параметр : значение\", разделённых точкой с запятой.","cssLengthTooltip":"Введите значение в пикселях, либо число с корректной единицей меры CSS (px, %, in, cm, mm, em, ex, pt или pc).","unavailable":"%1, недоступно","keyboard":{"8":"Backspace","13":"Ввод","16":"Shift","17":"Ctrl","18":"Alt","32":"Пробел","35":"End","36":"Home","46":"Delete","112":"F1","113":"F2","114":"F3","115":"F4","116":"F5","117":"F6","118":"F7","119":"F8","120":"F9","121":"F10","122":"F11","123":"F12","124":"F13","125":"F14","126":"F15","127":"F16","128":"F17","129":"F18","130":"F19","131":"F20","132":"F21","133":"F22","134":"F23","135":"F24","224":"Command"},"keyboardShortcut":"Комбинация клавиш","optionDefault":"По умолчанию"},"about":{"copy":"Copyright © $1. Все права защищены.","dlgTitle":"О CKEditor 4","moreInfo":"Для получения информации о лицензии, пожалуйста, перейдите на наш сайт:"},"basicstyles":{"bold":"Полужирный","italic":"Курсив","strike":"Зачеркнутый","subscript":"Подстрочный индекс","superscript":"Надстрочный индекс","underline":"Подчеркнутый"},"bidi":{"ltr":"Направление текста слева направо","rtl":"Направление текста справа налево"},"blockquote":{"toolbar":"Цитата"},"notification":{"closed":"Уведомление закрыто"},"toolbar":{"toolbarCollapse":"Свернуть панель инструментов","toolbarExpand":"Развернуть панель инструментов","toolbarGroups":{"document":"Документ","clipboard":"Буфер обмена / Отмена действий","editing":"Корректировка","forms":"Формы","basicstyles":"Простые стили","paragraph":"Абзац","links":"Ссылки","insert":"Вставка","styles":"Стили","colors":"Цвета","tools":"Инструменты"},"toolbars":"Панели инструментов редактора"},"clipboard":{"copy":"Копировать","copyError":"Настройки безопасности вашего браузера не разрешают редактору выполнять операции по копированию текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+C).","cut":"Вырезать","cutError":"Настройки безопасности вашего браузера не разрешают редактору выполнять операции по вырезке текста. Пожалуйста, используйте для этого клавиатуру (Ctrl/Cmd+X).","paste":"Вставить","pasteNotification":"Для вставки нажмите %1. Ваш браузер не поддерживает возможность вставки через панель инструментов или контекстное меню","pasteArea":"Область вставки","pasteMsg":"Вставьте контент в эту область и нажмите OK"},"colorbutton":{"auto":"Автоматически","bgColorTitle":"Цвет фона","colors":{"000":"Чёрный","800000":"Бордовый","8B4513":"Кожано-коричневый","2F4F4F":"Темный синевато-серый","008080":"Сине-зелёный","000080":"Тёмно-синий","4B0082":"Индиго","696969":"Тёмно-серый","B22222":"Кирпичный","A52A2A":"Коричневый","DAA520":"Золотисто-берёзовый","006400":"Темно-зелёный","40E0D0":"Бирюзовый","0000CD":"Умеренно синий","800080":"Пурпурный","808080":"Серый","F00":"Красный","FF8C00":"Темно-оранжевый","FFD700":"Золотистый","008000":"Зелёный","0FF":"Васильковый","00F":"Синий","EE82EE":"Фиолетовый","A9A9A9":"Тускло-серый","FFA07A":"Светло-лососевый","FFA500":"Оранжевый","FFFF00":"Жёлтый","00FF00":"Лайма","AFEEEE":"Бледно-синий","ADD8E6":"Свелто-голубой","DDA0DD":"Сливовый","D3D3D3":"Светло-серый","FFF0F5":"Розово-лавандовый","FAEBD7":"Античный белый","FFFFE0":"Светло-жёлтый","F0FFF0":"Медвяной росы","F0FFFF":"Лазурный","F0F8FF":"Бледно-голубой","E6E6FA":"Лавандовый","FFF":"Белый","1ABC9C":"Насыщенный голубой","2ECC71":"Изумрудный","3498DB":"Светло-синий","9B59B6":"Аметист","4E5F70":"Сине-серый","F1C40F":"Ярко-желтый","16A085":"Тёмно-голубой","27AE60":"Тёмно-изумрудный","2980B9":"Насыщенный синий","8E44AD":"Тёмно-фиолетовый","2C3E50":"Ненасыщенный синий","F39C12":"Оранжевый","E67E22":"Морковный","E74C3C":"Бледно-красный","ECF0F1":"Яркий серебристый","95A5A6":"Светлый серо-голубой","DDD":"Светло-серый","D35400":"Цвет тыквы","C0392B":"Насыщенный красный","BDC3C7":"Серебристый","7F8C8D":"Серо-голубой","999":"Тёмно-серый"},"more":"Ещё цвета...","panelTitle":"Цвета","textColorTitle":"Цвет текста"},"colordialog":{"clear":"Очистить","highlight":"Под курсором","options":"Настройки цвета","selected":"Выбранный цвет","title":"Выберите цвет"},"contextmenu":{"options":"Параметры контекстного меню"},"div":{"IdInputLabel":"Идентификатор","advisoryTitleInputLabel":"Заголовок","cssClassInputLabel":"Классы CSS","edit":"Редактировать контейнер","inlineStyleInputLabel":"Стиль элемента","langDirLTRLabel":"Слева направо (LTR)","langDirLabel":"Направление текста","langDirRTLLabel":"Справа налево (RTL)","languageCodeInputLabel":"Код языка","remove":"Удалить контейнер","styleSelectLabel":"Стиль","title":"Создать Div-контейнер","toolbar":"Создать Div-контейнер"},"elementspath":{"eleLabel":"Путь элементов","eleTitle":"Элемент %1"},"filetools":{"loadError":"Ошибка при чтении файла","networkError":"Сетевая ошибка при загрузке файла","httpError404":"HTTP ошибка при загрузке файла (404: Файл не найден)","httpError403":"HTTP ошибка при загрузке файла (403: Запрещено)","httpError":"HTTP ошибка при загрузке файла (%1)","noUrlError":"Не определен URL для загрузки файлов","responseError":"Некорректный ответ сервера"},"find":{"find":"Найти","findOptions":"Опции поиска","findWhat":"Найти:","matchCase":"Учитывать регистр","matchCyclic":"По всему тексту","matchWord":"Только слово целиком","notFoundMsg":"Искомый текст не найден.","replace":"Заменить","replaceAll":"Заменить всё","replaceSuccessMsg":"Успешно заменено %1 раз(а).","replaceWith":"Заменить на:","title":"Поиск и замена"},"fakeobjects":{"anchor":"Якорь","flash":"Flash анимация","hiddenfield":"Скрытое поле","iframe":"iFrame","unknown":"Неизвестный объект"},"flash":{"access":"Доступ к скриптам","accessAlways":"Всегда","accessNever":"Никогда","accessSameDomain":"В том же домене","alignAbsBottom":"По низу текста","alignAbsMiddle":"По середине текста","alignBaseline":"По базовой линии","alignTextTop":"По верху текста","bgcolor":"Цвет фона","chkFull":"Разрешить полноэкранный режим","chkLoop":"Повторять","chkMenu":"Включить меню Flash","chkPlay":"Автоматическое воспроизведение","flashvars":"Переменные для Flash","hSpace":"Гориз. отступ","properties":"Свойства Flash","propertiesTab":"Свойства","quality":"Качество","qualityAutoHigh":"Запуск на высоком","qualityAutoLow":"Запуск на низком","qualityBest":"Лучшее","qualityHigh":"Высокое","qualityLow":"Низкое","qualityMedium":"Среднее","scale":"Масштабировать","scaleAll":"Пропорционально","scaleFit":"Заполнять","scaleNoBorder":"Заходить за границы","title":"Свойства Flash","vSpace":"Вертик. отступ","validateHSpace":"Горизонтальный отступ задается числом.","validateSrc":"Вы должны ввести ссылку","validateVSpace":"Вертикальный отступ задается числом.","windowMode":"Взаимодействие с окном","windowModeOpaque":"Непрозрачный","windowModeTransparent":"Прозрачный","windowModeWindow":"Обычный"},"font":{"fontSize":{"label":"Размер","voiceLabel":"Размер шрифта","panelTitle":"Размер шрифта"},"label":"Шрифт","panelTitle":"Шрифт","voiceLabel":"Шрифт"},"format":{"label":"Форматирование","panelTitle":"Форматирование","tag_address":"Адрес","tag_div":"Обычное (div)","tag_h1":"Заголовок 1","tag_h2":"Заголовок 2","tag_h3":"Заголовок 3","tag_h4":"Заголовок 4","tag_h5":"Заголовок 5","tag_h6":"Заголовок 6","tag_p":"Обычное","tag_pre":"Моноширинное"},"forms":{"button":{"title":"Свойства кнопки","text":"Текст (Значение)","type":"Тип","typeBtn":"Кнопка","typeSbm":"Отправка","typeRst":"Сброс"},"checkboxAndRadio":{"checkboxTitle":"Свойства флаговой кнопки","radioTitle":"Свойства кнопки выбора","value":"Значение","selected":"Выбрано","required":"Обязательное поле"},"form":{"title":"Свойства формы","menu":"Свойства формы","action":"Действие","method":"Метод","encoding":"Кодировка"},"hidden":{"title":"Свойства скрытого поля","name":"Имя","value":"Значение"},"select":{"title":"Свойства списка выбора","selectInfo":"Информация о списке выбора","opAvail":"Доступные варианты","value":"Значение","size":"Размер","lines":"строк(и)","chkMulti":"Разрешить выбор нескольких вариантов","required":"Обязательное поле","opText":"Текст","opValue":"Значение","btnAdd":"Добавить","btnModify":"Изменить","btnUp":"Поднять","btnDown":"Опустить","btnSetValue":"Пометить как выбранное","btnDelete":"Удалить"},"textarea":{"title":"Свойства многострочного текстового поля","cols":"Колонок","rows":"Строк"},"textfield":{"title":"Свойства текстового поля","name":"Имя","value":"Значение","charWidth":"Ширина поля (в символах)","maxChars":"Макс. количество символов","required":"Обязательное поле","type":"Тип содержимого","typeText":"Текст","typePass":"Пароль","typeEmail":"Email","typeSearch":"Поиск","typeTel":"Номер телефона","typeUrl":"Ссылка"}},"horizontalrule":{"toolbar":"Вставить горизонтальную линию"},"iframe":{"border":"Показать границы фрейма","noUrl":"Пожалуйста, введите ссылку фрейма","scrolling":"Отображать полосы прокрутки","title":"Свойства iFrame","toolbar":"iFrame"},"indent":{"indent":"Увеличить отступ","outdent":"Уменьшить отступ"},"language":{"button":"Установка языка","remove":"Удалить язык"},"link":{"acccessKey":"Клавиша доступа","advanced":"Дополнительно","advisoryContentType":"Тип содержимого","advisoryTitle":"Заголовок","anchor":{"toolbar":"Вставить / редактировать якорь","menu":"Изменить якорь","title":"Свойства якоря","name":"Имя якоря","errorName":"Пожалуйста, введите имя якоря","remove":"Удалить якорь"},"anchorId":"По идентификатору","anchorName":"По имени","charset":"Кодировка ресурса","cssClasses":"Классы CSS","download":"Скачать как файл","displayText":"Отображаемый текст","emailAddress":"Email адрес","emailBody":"Текст сообщения","emailSubject":"Тема сообщения","id":"Идентификатор","info":"Информация о ссылке","langCode":"Код языка","langDir":"Направление текста","langDirLTR":"Слева направо (LTR)","langDirRTL":"Справа налево (RTL)","menu":"Редактировать ссылку","name":"Имя","noAnchors":"(В документе нет ни одного якоря)","noEmail":"Пожалуйста, введите email адрес","noUrl":"Пожалуйста, введите ссылку","noTel":"Please type the phone number","other":"<другой>","phoneNumber":"Phone number","popupDependent":"Зависимое (Netscape)","popupFeatures":"Параметры всплывающего окна","popupFullScreen":"Полноэкранное (IE)","popupLeft":"Отступ слева","popupLocationBar":"Панель адреса","popupMenuBar":"Панель меню","popupResizable":"Изменяемый размер","popupScrollBars":"Полосы прокрутки","popupStatusBar":"Строка состояния","popupToolbar":"Панель инструментов","popupTop":"Отступ сверху","rel":"Отношение","selectAnchor":"Выберите якорь","styles":"Стиль","tabIndex":"Последовательность перехода","target":"Цель","targetFrame":"<фрейм>","targetFrameName":"Имя целевого фрейма","targetPopup":"<всплывающее окно>","targetPopupName":"Имя всплывающего окна","title":"Ссылка","toAnchor":"Ссылка на якорь в тексте","toEmail":"Email","toUrl":"Ссылка","toPhone":"Phone","toolbar":"Вставить/Редактировать ссылку","type":"Тип ссылки","unlink":"Убрать ссылку","upload":"Загрузка"},"list":{"bulletedlist":"Вставить / удалить маркированный список","numberedlist":"Вставить / удалить нумерованный список"},"liststyle":{"bulletedTitle":"Свойства маркированного списка","circle":"Окружность","decimal":"Десятичные (1, 2, 3, и т.д.)","disc":"Круг","lowerAlpha":"Строчные латинские (a, b, c, d, e, и т.д.)","lowerRoman":"Строчные римские (i, ii, iii, iv, v, и т.д.)","none":"Нет","notset":"<не указано>","numberedTitle":"Свойства нумерованного списка","square":"Квадрат","start":"Начиная с","type":"Тип","upperAlpha":"Заглавные латинские (A, B, C, D, E, и т.д.)","upperRoman":"Заглавные римские (I, II, III, IV, V, и т.д.)","validateStartNumber":"Первый номер списка должен быть задан обычным целым числом."},"magicline":{"title":"Вставить здесь параграф"},"maximize":{"maximize":"Развернуть","minimize":"Свернуть"},"newpage":{"toolbar":"Новая страница"},"pagebreak":{"alt":"Разрыв страницы","toolbar":"Вставить разрыв страницы для печати"},"pastefromword":{"confirmCleanup":"Текст, который вы желаете вставить, по всей видимости, был скопирован из Word. Следует ли очистить его перед вставкой?","error":"Невозможно очистить вставленные данные из-за внутренней ошибки","title":"Вставить из Word","toolbar":"Вставить из Word"},"pastetext":{"button":"Вставить только текст","pasteNotification":"Press %1 to paste. Your browser doesn‘t support pasting with the toolbar button or context menu option.","title":"Вставить только текст"},"preview":{"preview":"Предварительный просмотр"},"print":{"toolbar":"Печать"},"removeformat":{"toolbar":"Убрать форматирование"},"save":{"toolbar":"Сохранить"},"scayt":{"btn_about":"О SCAYT","btn_dictionaries":"Словари","btn_disable":"Отключить SCAYT","btn_enable":"Включить SCAYT","btn_langs":"Языки","btn_options":"Настройки","text_title":"Проверка орфографии по мере ввода (SCAYT)"},"selectall":{"toolbar":"Выделить все"},"showblocks":{"toolbar":"Отображать блоки"},"smiley":{"options":"Выбор смайла","title":"Вставить смайл","toolbar":"Смайлы"},"sourcearea":{"toolbar":"Источник"},"specialchar":{"options":"Выбор специального символа","title":"Выберите специальный символ","toolbar":"Вставить специальный символ"},"stylescombo":{"label":"Стили","panelTitle":"Стили форматирования","panelTitle1":"Стили блока","panelTitle2":"Стили элемента","panelTitle3":"Стили объекта"},"table":{"border":"Размер границ","caption":"Заголовок","cell":{"menu":"Ячейка","insertBefore":"Вставить ячейку слева","insertAfter":"Вставить ячейку справа","deleteCell":"Удалить ячейки","merge":"Объединить ячейки","mergeRight":"Объединить с правой","mergeDown":"Объединить с нижней","splitHorizontal":"Разделить ячейку по вертикали","splitVertical":"Разделить ячейку по горизонтали","title":"Свойства ячейки","cellType":"Тип ячейки","rowSpan":"Объединяет строк","colSpan":"Объединяет колонок","wordWrap":"Перенос по словам","hAlign":"Горизонтальное выравнивание","vAlign":"Вертикальное выравнивание","alignBaseline":"По базовой линии","bgColor":"Цвет фона","borderColor":"Цвет границ","data":"Данные","header":"Заголовок","yes":"Да","no":"Нет","invalidWidth":"Ширина ячейки должна быть числом.","invalidHeight":"Высота ячейки должна быть числом.","invalidRowSpan":"Количество объединяемых строк должно быть задано числом.","invalidColSpan":"Количество объединяемых колонок должно быть задано числом.","chooseColor":"Выберите"},"cellPad":"Внутренний отступ ячеек","cellSpace":"Внешний отступ ячеек","column":{"menu":"Колонка","insertBefore":"Вставить колонку слева","insertAfter":"Вставить колонку справа","deleteColumn":"Удалить колонки"},"columns":"Колонки","deleteTable":"Удалить таблицу","headers":"Заголовки","headersBoth":"Сверху и слева","headersColumn":"Левая колонка","headersNone":"Без заголовков","headersRow":"Верхняя строка","heightUnit":"height unit","invalidBorder":"Размер границ должен быть числом.","invalidCellPadding":"Внутренний отступ ячеек (cellpadding) должен быть числом.","invalidCellSpacing":"Внешний отступ ячеек (cellspacing) должен быть числом.","invalidCols":"Количество столбцов должно быть больше 0.","invalidHeight":"Высота таблицы должна быть числом.","invalidRows":"Количество строк должно быть больше 0.","invalidWidth":"Ширина таблицы должна быть числом.","menu":"Свойства таблицы","row":{"menu":"Строка","insertBefore":"Вставить строку сверху","insertAfter":"Вставить строку снизу","deleteRow":"Удалить строки"},"rows":"Строки","summary":"Итоги","title":"Свойства таблицы","toolbar":"Таблица","widthPc":"процентов","widthPx":"пикселей","widthUnit":"единица измерения"},"templates":{"button":"Шаблоны","emptyListMsg":"(не определено ни одного шаблона)","insertOption":"Заменить текущее содержимое","options":"Параметры шаблона","selectPromptMsg":"Пожалуйста, выберите, какой шаблон следует открыть в редакторе","title":"Шаблоны содержимого"},"undo":{"redo":"Повторить","undo":"Отменить"},"widget":{"move":"Нажмите и перетащите, чтобы переместить","label":"%1 виджет"},"uploadwidget":{"abort":"Загрузка отменена пользователем","doneOne":"Файл успешно загружен","doneMany":"Успешно загружено файлов: %1","uploadOne":"Загрузка файла ({percentage}%)","uploadMany":"Загрузка файлов, {current} из {max} загружено ({percentage}%)..."},"wsc":{"btnIgnore":"Пропустить","btnIgnoreAll":"Пропустить всё","btnReplace":"Заменить","btnReplaceAll":"Заменить всё","btnUndo":"Отменить","changeTo":"Изменить на","errorLoading":"Произошла ошибка при подключении к серверу проверки орфографии: %s.","ieSpellDownload":"Модуль проверки орфографии не установлен. Хотите скачать его?","manyChanges":"Проверка орфографии завершена. Изменено слов: %1","noChanges":"Проверка орфографии завершена. Не изменено ни одного слова","noMispell":"Проверка орфографии завершена. Ошибок не найдено","noSuggestions":"- Варианты отсутствуют -","notAvailable":"Извините, но в данный момент сервис недоступен.","notInDic":"Отсутствует в словаре","oneChange":"Проверка орфографии завершена. Изменено одно слово","progress":"Орфография проверяется...","title":"Проверка орфографии","toolbar":"Проверить орфографию"}};
|
@@ -1,10 +1,10 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
|
-
CKEDITOR.dialog.add("a11yHelp",function(e){var a=
|
6
|
-
|
7
|
-
|
8
|
-
'\x3cdiv class\x3d"cke_accessibility_legend" role\x3d"document" aria-labelledby\x3d"'+
|
9
|
-
|
5
|
+
CKEDITOR.dialog.add("a11yHelp",function(f){function m(a){for(var b,c,h=[],d=0;d<g.length;d++)c=g[d],b=a/g[d],1<b&&2>=b&&(a-=c,h.push(e[c]));h.push(e[a]||String.fromCharCode(a));return h.join("+")}function t(a,b){var c=f.getCommandKeystroke(b,!0);return c.length?CKEDITOR.tools.array.map(c,m).join(" / "):a}var a=f.lang.a11yhelp,b=f.lang.common.keyboard,p=CKEDITOR.tools.getNextId(),q=/\$\{(.*?)\}/g,g=[CKEDITOR.ALT,CKEDITOR.SHIFT,CKEDITOR.CTRL],e={8:b[8],9:a.tab,13:b[13],16:b[16],17:b[17],18:b[18],19:a.pause,
|
6
|
+
20:a.capslock,27:a.escape,33:a.pageUp,34:a.pageDown,35:b[35],36:b[36],37:a.leftArrow,38:a.upArrow,39:a.rightArrow,40:a.downArrow,45:a.insert,46:b[46],91:a.leftWindowKey,92:a.rightWindowKey,93:a.selectKey,96:a.numpad0,97:a.numpad1,98:a.numpad2,99:a.numpad3,100:a.numpad4,101:a.numpad5,102:a.numpad6,103:a.numpad7,104:a.numpad8,105:a.numpad9,106:a.multiply,107:a.add,109:a.subtract,110:a.decimalPoint,111:a.divide,112:a.f1,113:a.f2,114:a.f3,115:a.f4,116:a.f5,117:a.f6,118:a.f7,119:a.f8,120:a.f9,121:a.f10,
|
7
|
+
122:a.f11,123:a.f12,144:a.numLock,145:a.scrollLock,186:a.semiColon,187:a.equalSign,188:a.comma,189:a.dash,190:a.period,191:a.forwardSlash,192:a.graveAccent,219:a.openBracket,220:a.backSlash,221:a.closeBracket,222:a.singleQuote};e[CKEDITOR.ALT]=b[18];e[CKEDITOR.SHIFT]=b[16];e[CKEDITOR.CTRL]=CKEDITOR.env.mac?b[224]:b[17];return{title:a.title,minWidth:600,minHeight:400,contents:[{id:"info",label:f.lang.common.generalTab,expand:!0,elements:[{type:"html",id:"legends",style:"white-space:normal;",focus:function(){this.getElement().focus()},
|
8
|
+
html:function(){for(var b='\x3cdiv class\x3d"cke_accessibility_legend" role\x3d"document" aria-labelledby\x3d"'+p+'_arialbl" tabIndex\x3d"-1"\x3e%1\x3c/div\x3e\x3cspan id\x3d"'+p+'_arialbl" class\x3d"cke_voice_label"\x3e'+a.contents+" \x3c/span\x3e",e=[],c=a.legend,h=c.length,d=0;d<h;d++){for(var f=c[d],g=[],r=f.items,m=r.length,n=0;n<m;n++){var k=r[n],l=CKEDITOR.env.edge&&k.legendEdge?k.legendEdge:k.legend,l=l.replace(q,t);l.match(q)||g.push("\x3cdt\x3e%1\x3c/dt\x3e\x3cdd\x3e%2\x3c/dd\x3e".replace("%1",
|
9
|
+
k.name).replace("%2",l))}e.push("\x3ch1\x3e%1\x3c/h1\x3e\x3cdl\x3e%2\x3c/dl\x3e".replace("%1",f.name).replace("%2",g.join("")))}return b.replace("%1",e.join(""))}()+'\x3cstyle type\x3d"text/css"\x3e.cke_accessibility_legend{width:600px;height:400px;padding-right:5px;overflow-y:auto;overflow-x:hidden;}.cke_browser_quirks .cke_accessibility_legend,{height:390px}.cke_accessibility_legend *{white-space:normal;}.cke_accessibility_legend h1{font-size: 20px;border-bottom: 1px solid #AAA;margin: 5px 0px 15px;}.cke_accessibility_legend dl{margin-left: 5px;}.cke_accessibility_legend dt{font-size: 13px;font-weight: bold;}.cke_accessibility_legend dd{margin:10px}\x3c/style\x3e'}]}],
|
10
10
|
buttons:[CKEDITOR.dialog.cancelButton]}});
|
@@ -1,6 +1,6 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
5
|
CKEDITOR.plugins.setLang("a11yhelp","en",{title:"Accessibility Instructions",contents:"Help Contents. To close this dialog press ESC.",legend:[{name:"General",items:[{name:"Editor Toolbar",legend:"Press ${toolbarFocus} to navigate to the toolbar. Move to the next and previous toolbar group with TAB and SHIFT+TAB. Move to the next and previous toolbar button with RIGHT ARROW or LEFT ARROW. Press SPACE or ENTER to activate the toolbar button."},{name:"Editor Dialog",legend:"Inside a dialog, press TAB to navigate to the next dialog element, press SHIFT+TAB to move to the previous dialog element, press ENTER to submit the dialog, press ESC to cancel the dialog. When a dialog has multiple tabs, the tab list can be reached either with ALT+F10 or with TAB as part of the dialog tabbing order. With tab list focused, move to the next and previous tab with RIGHT and LEFT ARROW, respectively."},
|
6
6
|
{name:"Editor Context Menu",legend:"Press ${contextMenu} or APPLICATION KEY to open context-menu. Then move to next menu option with TAB or DOWN ARROW. Move to previous option with SHIFT+TAB or UP ARROW. Press SPACE or ENTER to select the menu option. Open sub-menu of current option with SPACE or ENTER or RIGHT ARROW. Go back to parent menu item with ESC or LEFT ARROW. Close context menu with ESC."},{name:"Editor List Box",legend:"Inside a list-box, move to next list item with TAB OR DOWN ARROW. Move to previous list item with SHIFT+TAB or UP ARROW. Press SPACE or ENTER to select the list option. Press ESC to close the list-box."},
|
@@ -1,11 +1,11 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
5
|
CKEDITOR.plugins.setLang("a11yhelp","ru",{title:"Горячие клавиши",contents:"Помощь. Для закрытия этого окна нажмите ESC.",legend:[{name:"Основное",items:[{name:"Панель инструментов",legend:"Нажмите ${toolbarFocus} для перехода к панели инструментов. Для перемещения между группами панели инструментов используйте TAB и SHIFT+TAB. Для перемещения между кнопками панели иструментов используйте кнопки ВПРАВО или ВЛЕВО. Нажмите ПРОБЕЛ или ENTER для запуска кнопки панели инструментов."},{name:"Диалоги",legend:'Внутри диалога, нажмите TAB чтобы перейти к следующему элементу диалога, нажмите SHIFT+TAB чтобы перейти к предыдущему элементу диалога, нажмите ENTER чтобы отправить диалог, нажмите ESC чтобы отменить диалог. Когда диалоговое окно имеет несколько вкладок, получить доступ к панели вкладок как части диалога можно нажатием или сочетания ALT+F10 или TAB, при этом активные элементы диалога будут перебираться с учетом порядка табуляции. При активной панели вкладок, переход к следующей или предыдущей вкладке осуществляется нажатием стрелки "ВПРАВО" или стрелки "ВЛЕВО" соответственно.'},
|
6
6
|
{name:"Контекстное меню",legend:'Нажмите ${contextMenu} или клавишу APPLICATION, чтобы открыть контекстное меню. Затем перейдите к следующему пункту меню с помощью TAB или стрелкой "ВНИЗ". Переход к предыдущей опции - SHIFT+TAB или стрелкой "ВВЕРХ". Нажмите SPACE, или ENTER, чтобы задействовать опцию меню. Открыть подменю текущей опции - SPACE или ENTER или стрелкой "ВПРАВО". Возврат к родительскому пункту меню - ESC или стрелкой "ВЛЕВО". Закрытие контекстного меню - ESC.'},{name:"Редактор списка",
|
7
7
|
legend:'Внутри окна списка, переход к следующему пункту списка - TAB или стрелкой "ВНИЗ". Переход к предыдущему пункту списка - SHIFT+TAB или стрелкой "ВВЕРХ". Нажмите SPACE, или ENTER, чтобы задействовать опцию списка. Нажмите ESC, чтобы закрыть окно списка.'},{name:"Путь к элементу",legend:'Нажмите ${elementsPathFocus}, чтобы перейти к панели пути элементов. Переход к следующей кнопке элемента - TAB или стрелкой "ВПРАВО". Переход к предыдущей кнопку - SHIFT+TAB или стрелкой "ВЛЕВО". Нажмите SPACE, или ENTER, чтобы выбрать элемент в редакторе.'}]},
|
8
8
|
{name:"Команды",items:[{name:"Отменить",legend:"Нажмите ${undo}"},{name:"Повторить",legend:"Нажмите ${redo}"},{name:"Полужирный",legend:"Нажмите ${bold}"},{name:"Курсив",legend:"Нажмите ${italic}"},{name:"Подчеркнутый",legend:"Нажмите ${underline}"},{name:"Гиперссылка",legend:"Нажмите ${link}"},{name:"Свернуть панель инструментов",legend:"Нажмите ${toolbarCollapse}"},{name:"Команды доступа к предыдущему фокусному пространству",legend:'Нажмите ${accessPreviousSpace}, чтобы обратиться к ближайшему недостижимому фокусному пространству перед символом "^", например: два смежных HR элемента. Повторите комбинацию клавиш, чтобы достичь отдаленных фокусных пространств.'},
|
9
|
-
{name:"Команды доступа к следующему фокусному пространству",legend:"Press ${accessNextSpace} to access the closest unreachable focus space after the caret, for example: two adjacent HR elements. Repeat the key combination to reach distant focus spaces."},{name:"Справка по горячим клавишам",legend:"Нажмите ${a11yHelp}"},{name:"Вставить только текст",legend:"Нажмите ${pastetext}",legendEdge:"
|
9
|
+
{name:"Команды доступа к следующему фокусному пространству",legend:"Press ${accessNextSpace} to access the closest unreachable focus space after the caret, for example: two adjacent HR elements. Repeat the key combination to reach distant focus spaces."},{name:"Справка по горячим клавишам",legend:"Нажмите ${a11yHelp}"},{name:"Вставить только текст",legend:"Нажмите ${pastetext}",legendEdge:"Нажмите ${pastetext} и затем ${paste}"}]}],tab:"Tab",pause:"Pause",capslock:"Caps Lock",escape:"Esc",pageUp:"Page Up",
|
10
10
|
pageDown:"Page Down",leftArrow:"Стрелка влево",upArrow:"Стрелка вверх",rightArrow:"Стрелка вправо",downArrow:"Стрелка вниз",insert:"Insert",leftWindowKey:"Левая клавиша Windows",rightWindowKey:"Правая клавиша Windows",selectKey:"Выбрать",numpad0:"Цифра 0",numpad1:"Цифра 1",numpad2:"Цифра 2",numpad3:"Цифра 3",numpad4:"Цифра 4",numpad5:"Цифра 5",numpad6:"Цифра 6",numpad7:"Цифра 7",numpad8:"Цифра 8",numpad9:"Цифра 9",multiply:"Умножить",add:"Плюс",subtract:"Вычесть",decimalPoint:"Десятичная точка",divide:"Делить",
|
11
11
|
f1:"F1",f2:"F2",f3:"F3",f4:"F4",f5:"F5",f6:"F6",f7:"F7",f8:"F8",f9:"F9",f10:"F10",f11:"F11",f12:"F12",numLock:"Num Lock",scrollLock:"Scroll Lock",semiColon:"Точка с запятой",equalSign:"Равно",comma:"Запятая",dash:"Тире",period:"Точка",forwardSlash:"Наклонная черта",graveAccent:"Апостроф",openBracket:"Открыть скобку",backSlash:"Обратная наклонная черта",closeBracket:"Закрыть скобку",singleQuote:"Одинарная кавычка"});
|
@@ -1,8 +1,8 @@
|
|
1
1
|
/*
|
2
|
-
Copyright (c) 2003-
|
3
|
-
For licensing, see LICENSE.md or
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
4
|
*/
|
5
|
-
CKEDITOR.dialog.add("about",function(a){a=a.lang.about;var b=CKEDITOR.getUrl(CKEDITOR.plugins.get("about").path+"dialogs/"+(CKEDITOR.env.hidpi?"hidpi/":"")+"logo_ckeditor.png");return{title:
|
6
|
-
b+");"+(CKEDITOR.env.hidpi?"background-size:
|
7
|
-
|
5
|
+
CKEDITOR.dialog.add("about",function(a){a=a.lang.about;var b=CKEDITOR.getUrl(CKEDITOR.plugins.get("about").path+"dialogs/"+(CKEDITOR.env.hidpi?"hidpi/":"")+"logo_ckeditor.png");return{title:a.dlgTitle,minWidth:390,minHeight:210,contents:[{id:"tab1",label:"",title:"",expand:!0,padding:0,elements:[{type:"html",html:'\x3cstyle type\x3d"text/css"\x3e.cke_about_container{color:#000 !important;padding:10px 10px 0;margin-top:5px}.cke_about_container p{margin: 0 0 10px;}.cke_about_container .cke_about_logo{height:81px;background-color:#fff;background-image:url('+
|
6
|
+
b+");"+(CKEDITOR.env.hidpi?"background-size:194px 58px;":"")+'background-position:center; background-repeat:no-repeat;margin-bottom:10px;}.cke_about_container a{cursor:pointer !important;color:#00B2CE !important;text-decoration:underline !important;}.cke_about_container \x3e p,.cke_rtl .cke_about_container \x3e p{text-align:center;}\x3c/style\x3e\x3cdiv class\x3d"cke_about_container"\x3e\x3cdiv class\x3d"cke_about_logo"\x3e\x3c/div\x3e\x3cp\x3eCKEditor '+CKEDITOR.version+" (revision "+CKEDITOR.revision+
|
7
|
+
')\x3cbr\x3e\x3ca target\x3d"_blank" rel\x3d"noopener noreferrer" href\x3d"https://ckeditor.com/"\x3ehttps://ckeditor.com\x3c/a\x3e\x3c/p\x3e\x3cp\x3e'+a.moreInfo+'\x3cbr\x3e\x3ca target\x3d"_blank" rel\x3d"noopener noreferrer" href\x3d"https://ckeditor.com/legal/ckeditor-oss-license/"\x3ehttps://ckeditor.com/legal/ckeditor-oss-license/\x3c/a\x3e\x3c/p\x3e\x3cp\x3e'+a.copy.replace("$1",'\x3ca target\x3d"_blank" rel\x3d"noopener noreferrer" href\x3d"https://cksource.com/"\x3eCKSource\x3c/a\x3e - Frederico Knabben')+
|
8
8
|
"\x3c/p\x3e\x3c/div\x3e"}]}],buttons:[CKEDITOR.dialog.cancelButton]}});
|
Binary file
|
Binary file
|
@@ -0,0 +1,11 @@
|
|
1
|
+
/*
|
2
|
+
Copyright (c) 2003-2020, CKSource - Frederico Knabben. All rights reserved.
|
3
|
+
For licensing, see LICENSE.md or https://ckeditor.com/legal/ckeditor-oss-license
|
4
|
+
*/
|
5
|
+
CKEDITOR.dialog.add("paste",function(c){function k(a){var b=new CKEDITOR.dom.document(a.document),g=b.getBody(),d=b.getById("cke_actscrpt");d&&d.remove();g.setAttribute("contenteditable",!0);g.on(e.mainPasteEvent,function(a){a=e.initPasteDataTransfer(a);f?a!=f&&(f=e.initPasteDataTransfer()):f=a});if(CKEDITOR.env.ie&&8>CKEDITOR.env.version)b.getWindow().on("blur",function(){b.$.selection.empty()});b.on("keydown",function(a){a=a.data;var b;switch(a.getKeystroke()){case 27:this.hide();b=1;break;case 9:case CKEDITOR.SHIFT+
|
6
|
+
9:this.changeFocus(1),b=1}b&&a.preventDefault()},this);c.fire("ariaWidget",new CKEDITOR.dom.element(a.frameElement));b.getWindow().getFrame().removeCustomData("pendingFocus")&&g.focus()}var h=c.lang.clipboard,e=CKEDITOR.plugins.clipboard,f;c.on("pasteDialogCommit",function(a){a.data&&c.fire("paste",{type:"auto",dataValue:a.data.dataValue,method:"paste",dataTransfer:a.data.dataTransfer||e.initPasteDataTransfer()})},null,null,1E3);return{title:h.paste,minWidth:CKEDITOR.env.ie&&CKEDITOR.env.quirks?370:
|
7
|
+
350,minHeight:CKEDITOR.env.quirks?250:245,onShow:function(){this.parts.dialog.$.offsetHeight;this.setupContent();this._.committed=!1},onLoad:function(){(CKEDITOR.env.ie7Compat||CKEDITOR.env.ie6Compat)&&"rtl"==c.lang.dir&&this.parts.contents.setStyle("overflow","hidden")},onOk:function(){this.commitContent()},contents:[{id:"general",label:c.lang.common.generalTab,elements:[{type:"html",id:"pasteMsg",html:'\x3cdiv style\x3d"white-space:normal;width:340px"\x3e'+h.pasteMsg+"\x3c/div\x3e"},{type:"html",
|
8
|
+
id:"editing_area",style:"width:100%;height:100%",html:"",focus:function(){var a=this.getInputElement(),b=a.getFrameDocument().getBody();!b||b.isReadOnly()?a.setCustomData("pendingFocus",1):b.focus()},setup:function(){var a=this.getDialog(),b='\x3chtml dir\x3d"'+c.config.contentsLangDirection+'" lang\x3d"'+(c.config.contentsLanguage||c.langCode)+'"\x3e\x3chead\x3e\x3cstyle\x3ebody{margin:3px;height:95%;word-break:break-all;}\x3c/style\x3e\x3c/head\x3e\x3cbody\x3e\x3cscript id\x3d"cke_actscrpt" type\x3d"text/javascript"\x3ewindow.parent.CKEDITOR.tools.callFunction('+
|
9
|
+
CKEDITOR.tools.addFunction(k,a)+",this);\x3c/script\x3e\x3c/body\x3e\x3c/html\x3e",g=CKEDITOR.env.air?"javascript:void(0)":CKEDITOR.env.ie&&!CKEDITOR.env.edge?"javascript:void((function(){"+encodeURIComponent("document.open();("+CKEDITOR.tools.fixDomain+")();document.close();")+'})())"':"",d=CKEDITOR.dom.element.createFromHtml('\x3ciframe class\x3d"cke_pasteframe" frameborder\x3d"0" allowTransparency\x3d"true" src\x3d"'+g+'" aria-label\x3d"'+h.pasteArea+'" aria-describedby\x3d"'+a.getContentElement("general",
|
10
|
+
"pasteMsg").domId+'"\x3e\x3c/iframe\x3e');f=null;d.on("load",function(a){a.removeListener();a=d.getFrameDocument();a.write(b);c.focusManager.add(a.getBody());CKEDITOR.env.air&&k.call(this,a.getWindow().$)},a);d.setCustomData("dialog",a);a=this.getElement();a.setHtml("");a.append(d);if(CKEDITOR.env.ie&&!CKEDITOR.env.edge){var e=CKEDITOR.dom.element.createFromHtml('\x3cspan tabindex\x3d"-1" style\x3d"position:absolute" role\x3d"presentation"\x3e\x3c/span\x3e');e.on("focus",function(){setTimeout(function(){d.$.contentWindow.focus()})});
|
11
|
+
a.append(e);this.focus=function(){e.focus();this.fire("focus")}}this.getInputElement=function(){return d};CKEDITOR.env.ie&&(a.setStyle("display","block"),a.setStyle("height",d.$.offsetHeight+2+"px"))},commit:function(){var a=this.getDialog().getParentEditor(),b=this.getInputElement().getFrameDocument().getBody(),c=b.getBogus();c&&c.remove();b=b.getHtml();this.getDialog()._.committed=!0;a.fire("pasteDialogCommit",{dataValue:b,dataTransfer:f||e.initPasteDataTransfer()})}}]}]}});
|
@@ -1 +1 @@
|
|
1
|
-
.CodeMirror{font-family:monospace;height:300px;color:black;direction:ltr}.CodeMirror-lines{padding:4px 0}.CodeMirror pre{padding:0 4px}.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{background-color:white}.CodeMirror-gutters{border-right:1px solid #ddd;background-color:#f7f7f7;white-space:nowrap}.CodeMirror-linenumber{padding:0 3px 0 5px;min-width:20px;text-align:right;color:#999;white-space:nowrap}.CodeMirror-guttermarker{color:black}.CodeMirror-guttermarker-subtle{color:#999}.CodeMirror-cursor{border-left:1px solid black;border-right:0;width:0}.CodeMirror div.CodeMirror-secondarycursor{border-left:1px solid silver}.cm-fat-cursor .CodeMirror-cursor{width:auto;border:0!important;background:#7e7}.cm-fat-cursor div.CodeMirror-cursors{z-index:1}.cm-fat-cursor-mark{background-color:rgba(20,255,20,0.5);-webkit-animation:blink 1.06s steps(1) infinite;-moz-animation:blink 1.06s steps(1) infinite;animation:blink 1.06s steps(1) infinite}.cm-animate-fat-cursor{width:auto;border:0;-webkit-animation:blink 1.06s steps(1) infinite;-moz-animation:blink 1.06s steps(1) infinite;animation:blink 1.06s steps(1) infinite;background-color:#7e7}@-moz-keyframes blink{50%{background-color:transparent}}@-webkit-keyframes blink{50%{background-color:transparent}}@keyframes blink{50%{background-color:transparent}}.cm-tab{display:inline-block;text-decoration:inherit}.CodeMirror-rulers{position:absolute;left:0;right:0;top:-50px;bottom:-20px;overflow:hidden}.CodeMirror-ruler{border-left:1px solid #ccc;top:0;bottom:0;position:absolute}.cm-s-default .cm-header{color:blue}.cm-s-default .cm-quote{color:#090}.cm-negative{color:#d44}.cm-positive{color:#292}.cm-header,.cm-strong{font-weight:bold}.cm-em{font-style:italic}.cm-link{text-decoration:underline}.cm-strikethrough{text-decoration:line-through}.cm-s-default .cm-keyword{color:#708}.cm-s-default .cm-atom{color:#219}.cm-s-default .cm-number{color:#164}.cm-s-default .cm-def{color:#00f}.cm-s-default .cm-variable-2{color:#05a}.cm-s-default .cm-variable-3,.cm-s-default .cm-type{color:#085}.cm-s-default .cm-comment{color:#a50}.cm-s-default .cm-string{color:#a11}.cm-s-default .cm-string-2{color:#f50}.cm-s-default .cm-meta{color:#555}.cm-s-default .cm-qualifier{color:#555}.cm-s-default .cm-builtin{color:#30a}.cm-s-default .cm-bracket{color:#997}.cm-s-default .cm-tag{color:#170}.cm-s-default .cm-attribute{color:#00c}.cm-s-default .cm-hr{color:#999}.cm-s-default .cm-link{color:#00c}.cm-s-default .cm-error{color:#f00}.cm-invalidchar{color:#f00}.CodeMirror-composing{border-bottom:2px solid}div.CodeMirror span.CodeMirror-matchingbracket{color:#0f0}div.CodeMirror span.CodeMirror-nonmatchingbracket{color:#f22}.CodeMirror-matchingtag{background:rgba(255,150,0,.3)}.CodeMirror-activeline-background{background:#e8f2ff}.CodeMirror{position:relative;overflow:hidden;background:white}.CodeMirror-scroll{overflow:scroll!important;margin-bottom:-30px;margin-right:-30px;padding-bottom:30px;height:100%;outline:0;position:relative}.CodeMirror-sizer{position:relative;border-right:30px solid transparent}.CodeMirror-vscrollbar,.CodeMirror-hscrollbar,.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{position:absolute;z-index:6;display:none}.CodeMirror-vscrollbar{right:0;top:0;overflow-x:hidden;overflow-y:scroll}.CodeMirror-hscrollbar{bottom:0;left:0;overflow-y:hidden;overflow-x:scroll}.CodeMirror-scrollbar-filler{right:0;bottom:0}.CodeMirror-gutter-filler{left:0;bottom:0}.CodeMirror-gutters{position:absolute;left:0;top:0;min-height:100%;z-index:3}.CodeMirror-gutter{white-space:normal;height:100%;display:inline-block;vertical-align:top;margin-bottom:-30px}.CodeMirror-gutter-wrapper{position:absolute;z-index:4;background:none!important;border:none!important}.CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}.CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}.CodeMirror-gutter-wrapper ::selection{background-color:transparent}.CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}.CodeMirror-lines{cursor:text;min-height:1px}.CodeMirror pre{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;border-width:0;background:transparent;font-family:inherit;font-size:inherit;margin:0;white-space:pre;word-wrap:normal;line-height:inherit;color:inherit;z-index:2;position:relative;overflow:visible;-webkit-tap-highlight-color:transparent;-webkit-font-variant-ligatures:contextual;font-variant-ligatures:contextual}.CodeMirror-wrap pre{word-wrap:break-word;white-space:pre-wrap;word-break:normal}.CodeMirror-linebackground{position:absolute;left:0;right:0;top:0;bottom:0;z-index:0}.CodeMirror-linewidget{position:relative;z-index:2;overflow:auto}.CodeMirror-rtl pre{direction:rtl}.CodeMirror-code{outline:0}.CodeMirror-scroll,.CodeMirror-sizer,.CodeMirror-gutter,.CodeMirror-gutters,.CodeMirror-linenumber{-moz-box-sizing:content-box;box-sizing:content-box}.CodeMirror-measure{position:absolute;width:100%;height:0;overflow:hidden;visibility:hidden}.CodeMirror-cursor{position:absolute;pointer-events:none}.CodeMirror-measure pre{position:static}div.CodeMirror-cursors{visibility:hidden;position:relative;z-index:3}div.CodeMirror-dragcursors{visibility:visible}.CodeMirror-focused div.CodeMirror-cursors{visibility:visible}.CodeMirror-selected{background:#d9d9d9}.CodeMirror-focused .CodeMirror-selected{background:#d7d4f0}.CodeMirror-crosshair{cursor:crosshair}.CodeMirror-line::selection,.CodeMirror-line>span::selection,.CodeMirror-line>span>span::selection{background:#d7d4f0}.CodeMirror-line::-moz-selection,.CodeMirror-line>span::-moz-selection,.CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}.cm-searching{background-color:#ffa;background-color:rgba(255,255,0,.4)}.cm-force-border{padding-right:.1px}@media print{.CodeMirror div.CodeMirror-cursors{visibility:hidden}}.cm-tab-wrap-hack:after{content:''}span.CodeMirror-selectedtext{background:0}.CodeMirror{font:13px/1.4em monospace;text-align:left}.CodeMirror .activeline{background:#e8f2ff}.CodeMirror .CodeMirror-foldmarker{color:blue;-ms-text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;-webkit-text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;font-family:arial;line-height:.3;cursor:pointer}.CodeMirror-matchingtag{background:#ff9600;background:rgba(255,150,0,0.3)}.searchCodeButton span,.autoFormat span,.CommentSelectedRange span,.UncommentSelectedRange span{width:16px;height:16px;margin-left:6px}.searchCodeButton span{background:url("../icons/searchcode.png") no-repeat}.autoFormat span{background:url("../icons/autoformat.png") no-repeat}.CommentSelectedRange span{background:url("../icons/commentselectedrange.png") no-repeat}.UncommentSelectedRange span{background:url("../icons/uncommentselectedrange.png") no-repeat}.cke_reset_all .CodeMirror-scroll *{word-wrap:break-word;white-space:pre-wrap;word-break:normal}.cke_reset_all .cm-s-cobalt *,.cke_reset_all .cm-s-erlang-dark *,.cke_reset_all .cm-s-lesser-dark *,.cke_reset_all .cm-s-monokai *,.cke_reset_all .cm-s-night *,.cke_reset_all .cm-s-rubyblue *,.cke_reset_all .cm-s-twilight *,.cke_reset_all .cm-s-xq-dark *,.cke_reset_all .cm-s-base16-dark *,.cke_reset_all .cm-s-3024-night *,.cke_reset_all .cm-s-the-matrix *,.cke_reset_all .cm-s-paraiso-dark *,.cke_reset_all .cm-s-paraiso-light *{color:inherit;font:inherit}.cm-s-cobalt .CodeMirror-selected{background:#b36539!important}.cm-s-erlang-dark .CodeMirror-selected{background:#b36539!important}.cm-s-lesser-dark .CodeMirror-selected{background:#45443b!important}.cm-s-monokai .CodeMirror-selected{background:#49483e!important}.cm-s-night .CodeMirror-selected{background:#447!important}.cm-s-rubyblue .CodeMirror-selected{background:#38566f!important}.cm-s-twilight .CodeMirror-selected{background:#323232!important}.cm-s-xq-dark .CodeMirror-selected{background:#a8f!important}.cm-s-the-matrix .CodeMirror-selected{background:#494949!important}.cm-s-mbo .CodeMirror-selected{background:#716c62!important}.cm-s-blackboard .activeline,.cm-s-cobalt .activeline,.cm-s-erlang-dark .activeline,.cm-s-lesser-dark .activeline,.cm-s-monokai .activeline,.cm-s-night .activeline,.cm-s-rubyblue .activeline,.cm-s-vibrant-ink .activeline,.cm-s-xq-dark .activeline,.cm-s-base16-dark .activeline,.cm-s-3024-night .activeline,.cm-s-paraiso-light .activeline,.cm-s-paraiso-dark .activeline,.cm-s-pastel-on-dark .activeline{background:#757575}.cm-s-pastel-on-dark .activeline{background:#404040}.cm-s-mbo .activeline{background:#716c62}.cm-s-twilight .activeline{background:#494949}.cm-s-the-matrix .activeline{background:#060}.CodeMirror-focused .cm-matchhighlight{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFklEQVQI12NgYGBgkKzc8x9CMDAwAAAmhwSbidEoSQAAAABJRU5ErkJggg==);background-position:bottom;background-repeat:repeat-x}.CodeMirror-hints{position:absolute;z-index:10;overflow:hidden;list-style:none;margin:0;padding:2px;-webkit-box-shadow:2px 3px 5px #000;-ms-box-shadow:2px 3px 5px #000;box-shadow:2px 3px 5px #000;border-radius:3px;border:1px solid silver;background:white;font-size:90%;font-family:monospace;max-height:20em;overflow-y:auto}.CodeMirror-hint{margin:0;padding:0 4px;border-radius:2px;max-width:19em;overflow:hidden;white-space:pre;color:black;cursor:pointer}.CodeMirror-hint-active{background:#08f;color:white}.cm-trailingspace{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAACCAYAAAB/qH1jAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3QUXCToH00Y1UgAAACFJREFUCNdjPMDBUc/AwNDAAAFMTAwMDA0OP34wQgX/AQBYgwYEx4f9lQAAAABJRU5ErkJggg==);background-position:bottom left;background-repeat:repeat-x}.CodeMirror-dialog{position:absolute;left:0;right:0;background:inherit;z-index:15;padding:.1em .8em;overflow:hidden;color:inherit}.CodeMirror-dialog-top{border-bottom:1px solid #eee;top:0}.CodeMirror-dialog-bottom{border-top:1px solid #eee;bottom:0}.CodeMirror-dialog input{border:0;outline:0;background:transparent;width:20em;color:inherit;font-family:monospace}.CodeMirror-dialog button{font-size:70%}.CodeMirror-foldmarker{color:blue;text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;font-family:arial;line-height:.3;cursor:pointer}.CodeMirror-foldgutter{width:.7em}.CodeMirror-foldgutter-open,.CodeMirror-foldgutter-folded{cursor:pointer}.CodeMirror-foldgutter-open:after{content:"\25BE"}.CodeMirror-foldgutter-folded:after{content:"\25B8"}
|
1
|
+
.CodeMirror{font-family:monospace;height:300px;color:black;direction:ltr}.CodeMirror-lines{padding:4px 0}.CodeMirror pre{padding:0 4px}.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{background-color:white}.CodeMirror-gutters{border-right:1px solid #ddd;background-color:#f7f7f7;white-space:nowrap}.CodeMirror-linenumber{padding:0 3px 0 5px;min-width:20px;text-align:right;color:#999;white-space:nowrap}.CodeMirror-guttermarker{color:black}.CodeMirror-guttermarker-subtle{color:#999}.CodeMirror-cursor{border-left:1px solid black;border-right:0;width:0}.CodeMirror div.CodeMirror-secondarycursor{border-left:1px solid silver}.cm-fat-cursor .CodeMirror-cursor{width:auto;border:0!important;background:#7e7}.cm-fat-cursor div.CodeMirror-cursors{z-index:1}.cm-fat-cursor-mark{background-color:rgba(20,255,20,0.5);-webkit-animation:blink 1.06s steps(1) infinite;-moz-animation:blink 1.06s steps(1) infinite;animation:blink 1.06s steps(1) infinite}.cm-animate-fat-cursor{width:auto;border:0;-webkit-animation:blink 1.06s steps(1) infinite;-moz-animation:blink 1.06s steps(1) infinite;animation:blink 1.06s steps(1) infinite;background-color:#7e7}@-moz-keyframes blink{50%{background-color:transparent}}@-webkit-keyframes blink{50%{background-color:transparent}}@keyframes blink{50%{background-color:transparent}}.cm-tab{display:inline-block;text-decoration:inherit}.CodeMirror-rulers{position:absolute;left:0;right:0;top:-50px;bottom:-20px;overflow:hidden}.CodeMirror-ruler{border-left:1px solid #ccc;top:0;bottom:0;position:absolute}.cm-s-default .cm-header{color:blue}.cm-s-default .cm-quote{color:#090}.cm-negative{color:#d44}.cm-positive{color:#292}.cm-header,.cm-strong{font-weight:bold}.cm-em{font-style:italic}.cm-link{text-decoration:underline}.cm-strikethrough{text-decoration:line-through}.cm-s-default .cm-keyword{color:#708}.cm-s-default .cm-atom{color:#219}.cm-s-default .cm-number{color:#164}.cm-s-default .cm-def{color:#00f}.cm-s-default .cm-variable-2{color:#05a}.cm-s-default .cm-variable-3,.cm-s-default .cm-type{color:#085}.cm-s-default .cm-comment{color:#a50}.cm-s-default .cm-string{color:#a11}.cm-s-default .cm-string-2{color:#f50}.cm-s-default .cm-meta{color:#555}.cm-s-default .cm-qualifier{color:#555}.cm-s-default .cm-builtin{color:#30a}.cm-s-default .cm-bracket{color:#997}.cm-s-default .cm-tag{color:#170}.cm-s-default .cm-attribute{color:#00c}.cm-s-default .cm-hr{color:#999}.cm-s-default .cm-link{color:#00c}.cm-s-default .cm-error{color:#f00}.cm-invalidchar{color:#f00}.CodeMirror-composing{border-bottom:2px solid}div.CodeMirror span.CodeMirror-matchingbracket{color:#0b0}div.CodeMirror span.CodeMirror-nonmatchingbracket{color:#a22}.CodeMirror-matchingtag{background:rgba(255,150,0,.3)}.CodeMirror-activeline-background{background:#e8f2ff}.CodeMirror{position:relative;overflow:hidden;background:white}.CodeMirror-scroll{overflow:scroll!important;margin-bottom:-30px;margin-right:-30px;padding-bottom:30px;height:100%;outline:0;position:relative}.CodeMirror-sizer{position:relative;border-right:30px solid transparent}.CodeMirror-vscrollbar,.CodeMirror-hscrollbar,.CodeMirror-scrollbar-filler,.CodeMirror-gutter-filler{position:absolute;z-index:6;display:none}.CodeMirror-vscrollbar{right:0;top:0;overflow-x:hidden;overflow-y:scroll}.CodeMirror-hscrollbar{bottom:0;left:0;overflow-y:hidden;overflow-x:scroll}.CodeMirror-scrollbar-filler{right:0;bottom:0}.CodeMirror-gutter-filler{left:0;bottom:0}.CodeMirror-gutters{position:absolute;left:0;top:0;min-height:100%;z-index:3}.CodeMirror-gutter{white-space:normal;height:100%;display:inline-block;vertical-align:top;margin-bottom:-30px}.CodeMirror-gutter-wrapper{position:absolute;z-index:4;background:none!important;border:none!important}.CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}.CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}.CodeMirror-gutter-wrapper ::selection{background-color:transparent}.CodeMirror-gutter-wrapper ::-moz-selection{background-color:transparent}.CodeMirror-lines{cursor:text;min-height:1px}.CodeMirror pre{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;border-width:0;background:transparent;font-family:inherit;font-size:inherit;margin:0;white-space:pre;word-wrap:normal;line-height:inherit;color:inherit;z-index:2;position:relative;overflow:visible;-webkit-tap-highlight-color:transparent;-webkit-font-variant-ligatures:contextual;font-variant-ligatures:contextual}.CodeMirror-wrap pre{word-wrap:break-word;white-space:pre-wrap;word-break:normal}.CodeMirror-linebackground{position:absolute;left:0;right:0;top:0;bottom:0;z-index:0}.CodeMirror-linewidget{position:relative;z-index:2;padding:.1px}.CodeMirror-rtl pre{direction:rtl}.CodeMirror-code{outline:0}.CodeMirror-scroll,.CodeMirror-sizer,.CodeMirror-gutter,.CodeMirror-gutters,.CodeMirror-linenumber{-moz-box-sizing:content-box;box-sizing:content-box}.CodeMirror-measure{position:absolute;width:100%;height:0;overflow:hidden;visibility:hidden}.CodeMirror-cursor{position:absolute;pointer-events:none}.CodeMirror-measure pre{position:static}div.CodeMirror-cursors{visibility:hidden;position:relative;z-index:3}div.CodeMirror-dragcursors{visibility:visible}.CodeMirror-focused div.CodeMirror-cursors{visibility:visible}.CodeMirror-selected{background:#d9d9d9}.CodeMirror-focused .CodeMirror-selected{background:#d7d4f0}.CodeMirror-crosshair{cursor:crosshair}.CodeMirror-line::selection,.CodeMirror-line>span::selection,.CodeMirror-line>span>span::selection{background:#d7d4f0}.CodeMirror-line::-moz-selection,.CodeMirror-line>span::-moz-selection,.CodeMirror-line>span>span::-moz-selection{background:#d7d4f0}.cm-searching{background-color:#ffa;background-color:rgba(255,255,0,.4)}.cm-force-border{padding-right:.1px}@media print{.CodeMirror div.CodeMirror-cursors{visibility:hidden}}.cm-tab-wrap-hack:after{content:''}span.CodeMirror-selectedtext{background:0}.CodeMirror{font:13px/1.4em monospace;text-align:left}.CodeMirror .activeline{background:#e8f2ff}.CodeMirror .CodeMirror-foldmarker{color:blue;-ms-text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;-webkit-text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;font-family:arial;line-height:.3;cursor:pointer}.CodeMirror-matchingtag{background:#ff9600;background:rgba(255,150,0,0.3)}.searchCodeButton span,.autoFormat span,.CommentSelectedRange span,.UncommentSelectedRange span{width:16px;height:16px;margin-left:6px}.searchCodeButton span{background:url("../images/searchcode.png") no-repeat}.autoFormat span{background:url("../images/autoformat.png") no-repeat}.CommentSelectedRange span{background:url("../images/commentselectedrange.png") no-repeat}.UncommentSelectedRange span{background:url("../images/uncommentselectedrange.png") no-repeat}.cke_reset_all .CodeMirror-scroll *{word-wrap:break-word;white-space:pre-wrap;word-break:normal}.cke_reset_all .cm-s-cobalt *,.cke_reset_all .cm-s-erlang-dark *,.cke_reset_all .cm-s-lesser-dark *,.cke_reset_all .cm-s-monokai *,.cke_reset_all .cm-s-night *,.cke_reset_all .cm-s-rubyblue *,.cke_reset_all .cm-s-twilight *,.cke_reset_all .cm-s-xq-dark *,.cke_reset_all .cm-s-base16-dark *,.cke_reset_all .cm-s-3024-night *,.cke_reset_all .cm-s-the-matrix *,.cke_reset_all .cm-s-paraiso-dark *,.cke_reset_all .cm-s-paraiso-light *{color:inherit;font:inherit}.cm-s-cobalt .CodeMirror-selected{background:#b36539!important}.cm-s-erlang-dark .CodeMirror-selected{background:#b36539!important}.cm-s-lesser-dark .CodeMirror-selected{background:#45443b!important}.cm-s-monokai .CodeMirror-selected{background:#49483e!important}.cm-s-night .CodeMirror-selected{background:#447!important}.cm-s-rubyblue .CodeMirror-selected{background:#38566f!important}.cm-s-twilight .CodeMirror-selected{background:#323232!important}.cm-s-xq-dark .CodeMirror-selected{background:#a8f!important}.cm-s-the-matrix .CodeMirror-selected{background:#494949!important}.cm-s-mbo .CodeMirror-selected{background:#716c62!important}.cm-s-blackboard .activeline,.cm-s-cobalt .activeline,.cm-s-erlang-dark .activeline,.cm-s-lesser-dark .activeline,.cm-s-monokai .activeline,.cm-s-night .activeline,.cm-s-rubyblue .activeline,.cm-s-vibrant-ink .activeline,.cm-s-xq-dark .activeline,.cm-s-base16-dark .activeline,.cm-s-3024-night .activeline,.cm-s-paraiso-light .activeline,.cm-s-paraiso-dark .activeline,.cm-s-pastel-on-dark .activeline{background:#757575}.cm-s-pastel-on-dark .activeline{background:#404040}.cm-s-mbo .activeline{background:#716c62}.cm-s-twilight .activeline{background:#494949}.cm-s-the-matrix .activeline{background:#060}.CodeMirror-focused .cm-matchhighlight{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAIAAAACCAYAAABytg0kAAAAFklEQVQI12NgYGBgkKzc8x9CMDAwAAAmhwSbidEoSQAAAABJRU5ErkJggg==);background-position:bottom;background-repeat:repeat-x}.CodeMirror-hints{position:absolute;z-index:10;overflow:hidden;list-style:none;margin:0;padding:2px;-webkit-box-shadow:2px 3px 5px #000;-ms-box-shadow:2px 3px 5px #000;box-shadow:2px 3px 5px #000;border-radius:3px;border:1px solid silver;background:white;font-size:90%;font-family:monospace;max-height:20em;overflow-y:auto}.CodeMirror-hint{margin:0;padding:0 4px;border-radius:2px;max-width:19em;overflow:hidden;white-space:pre;color:black;cursor:pointer}.CodeMirror-hint-active{background:#08f;color:white}.cm-trailingspace{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAQAAAACCAYAAAB/qH1jAAAABmJLR0QA/wD/AP+gvaeTAAAACXBIWXMAAAsTAAALEwEAmpwYAAAAB3RJTUUH3QUXCToH00Y1UgAAACFJREFUCNdjPMDBUc/AwNDAAAFMTAwMDA0OP34wQgX/AQBYgwYEx4f9lQAAAABJRU5ErkJggg==);background-position:bottom left;background-repeat:repeat-x}.CodeMirror-dialog{position:absolute;left:0;right:0;background:inherit;z-index:15;padding:.1em .8em;overflow:hidden;color:inherit}.CodeMirror-dialog-top{border-bottom:1px solid #eee;top:0}.CodeMirror-dialog-bottom{border-top:1px solid #eee;bottom:0}.CodeMirror-dialog input{border:0;outline:0;background:transparent;width:20em;color:inherit;font-family:monospace}.CodeMirror-dialog button{font-size:70%}.CodeMirror-hints{position:absolute;z-index:10;overflow:hidden;list-style:none;margin:0;padding:2px;-webkit-box-shadow:2px 3px 5px rgba(0,0,0,.2);-moz-box-shadow:2px 3px 5px rgba(0,0,0,.2);box-shadow:2px 3px 5px rgba(0,0,0,.2);border-radius:3px;border:1px solid silver;background:white;font-size:90%;font-family:monospace;max-height:20em;overflow-y:auto}.CodeMirror-hint{margin:0;padding:0 4px;border-radius:2px;white-space:pre;color:black;cursor:pointer}li.CodeMirror-hint-active{background:#08f;color:white}.CodeMirror-foldmarker{color:blue;text-shadow:#b9f 1px 1px 2px,#b9f -1px -1px 2px,#b9f 1px -1px 2px,#b9f -1px 1px 2px;font-family:arial;line-height:.3;cursor:pointer}.CodeMirror-foldgutter{width:.7em}.CodeMirror-foldgutter-open,.CodeMirror-foldgutter-folded{cursor:pointer}.CodeMirror-foldgutter-open:after{content:"\25BE"}.CodeMirror-foldgutter-folded:after{content:"\25B8"}
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
Binary file
|
@@ -1,2 +1,2 @@
|
|
1
|
-
!function(){function t(t,e){for(var n=0;n
|
2
|
-
if(e&&-1!==e.toLowerCase().indexOf(t))return"";var n="",i="",r=0,s=!0;do{if(this.pos>=this.input.length)return i;if(n=this.input.charAt(this.pos),this.pos++,this.Utils.in_array(n,this.Utils.whitespace)){if(!s){this.line_char_count--;continue}if("\n"===n||"\r"===n){i+="\n",this.line_char_count=0;continue}}i+=n,this.line_char_count++,s=!0,T&&"{"===n&&i.length&&"{"===i.charAt(i.length-2)&&(i+=this.get_unformatted("}}"),r=i.length)}while(-1===i.toLowerCase().indexOf(t,r));return i},this.get_token=function(){var t;if("TK_TAG_SCRIPT"===this.last_token||"TK_TAG_STYLE"===this.last_token){var e=this.last_token.substr(7);return t=this.get_contents_to(e),"string"!=typeof t?t:[t,"TK_"+e]}if("CONTENT"===this.current_mode)return t=this.get_content(),"string"!=typeof t?t:[t,"TK_CONTENT"];if("TAG"===this.current_mode){if("string"!=typeof(t=this.get_tag()))return t;return[t,"TK_TAG_"+this.tag_type]}},this.get_full_indent=function(t){return t=this.indent_level+t||0,t<1?"":Array(t+1).join(this.indent_string)},this.is_unformatted=function(t,e){if(!this.Utils.in_array(t,e))return!1;if("a"!==t.toLowerCase()||!this.Utils.in_array("a",e))return!0;var n=this.get_tag(!0),i=(n||"").match(/^\s*<\s*\/?([a-z]*)\s*[^>]*>\s*$/);return!(i&&!this.Utils.in_array(i,e))},this.printer=function(n,i,r,s,_){this.input=n||"",this.input=this.input.replace(/\r\n|[\r\u2028\u2029]/g,"\n"),this.output=[],this.indent_character=i,this.indent_string="",this.indent_size=r,this.brace_style=_,this.indent_level=0,this.wrap_line_length=s,this.line_char_count=0;for(var a=0;a
|
1
|
+
!function(){var e=function(e){function t(i){if(n[i])return n[i].exports;var r=n[i]={i:i,l:!1,exports:{}};return e[i].call(r.exports,r,r.exports,t),r.l=!0,r.exports}var n={};return t.m=e,t.c=n,t.i=function(e){return e},t.d=function(e,n,i){t.o(e,n)||Object.defineProperty(e,n,{configurable:!1,enumerable:!0,get:i})},t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=6)}([function(e,t){var n="ªµºÀ-ÖØ-öø-ˁˆ-ˑˠ-ˤˬˮͰ-ʹͶͷͺ-ͽΆΈ-ΊΌΎ-ΡΣ-ϵϷ-ҁҊ-ԧԱ-Ֆՙա-ևא-תװ-ײؠ-يٮٯٱ-ۓەۥۦۮۯۺ-ۼۿܐܒ-ܯݍ-ޥޱߊ-ߪߴߵߺࠀ-ࠕࠚࠤࠨࡀ-ࡘࢠࢢ-ࢬऄ-हऽॐक़-ॡॱ-ॷॹ-ॿঅ-ঌএঐও-নপ-রলশ-হঽৎড়ঢ়য়-ৡৰৱਅ-ਊਏਐਓ-ਨਪ-ਰਲਲ਼ਵਸ਼ਸਹਖ਼-ੜਫ਼ੲ-ੴઅ-ઍએ-ઑઓ-નપ-રલળવ-હઽૐૠૡଅ-ଌଏଐଓ-ନପ-ରଲଳଵ-ହଽଡ଼ଢ଼ୟ-ୡୱஃஅ-ஊஎ-ஐஒ-கஙசஜஞடணதந-பம-ஹௐఅ-ఌఎ-ఐఒ-నప-ళవ-హఽౘౙౠౡಅ-ಌಎ-ಐಒ-ನಪ-ಳವ-ಹಽೞೠೡೱೲഅ-ഌഎ-ഐഒ-ഺഽൎൠൡൺ-ൿඅ-ඖක-නඳ-රලව-ෆก-ะาำเ-ๆກຂຄງຈຊຍດ-ທນ-ຟມ-ຣລວສຫອ-ະາຳຽເ-ໄໆໜ-ໟༀཀ-ཇཉ-ཬྈ-ྌက-ဪဿၐ-ၕၚ-ၝၡၥၦၮ-ၰၵ-ႁႎႠ-ჅჇჍა-ჺჼ-ቈቊ-ቍቐ-ቖቘቚ-ቝበ-ኈኊ-ኍነ-ኰኲ-ኵኸ-ኾዀዂ-ዅወ-ዖዘ-ጐጒ-ጕጘ-ፚᎀ-ᎏᎠ-Ᏼᐁ-ᙬᙯ-ᙿᚁ-ᚚᚠ-ᛪᛮ-ᛰᜀ-ᜌᜎ-ᜑᜠ-ᜱᝀ-ᝑᝠ-ᝬᝮ-ᝰក-ឳៗៜᠠ-ᡷᢀ-ᢨᢪᢰ-ᣵᤀ-ᤜᥐ-ᥭᥰ-ᥴᦀ-ᦫᧁ-ᧇᨀ-ᨖᨠ-ᩔᪧᬅ-ᬳᭅ-ᭋᮃ-ᮠᮮᮯᮺ-ᯥᰀ-ᰣᱍ-ᱏᱚ-ᱽᳩ-ᳬᳮ-ᳱᳵᳶᴀ-ᶿḀ-ἕἘ-Ἕἠ-ὅὈ-Ὅὐ-ὗὙὛὝὟ-ώᾀ-ᾴᾶ-ᾼιῂ-ῄῆ-ῌῐ-ΐῖ-Ίῠ-Ῥῲ-ῴῶ-ῼⁱⁿₐ-ₜℂℇℊ-ℓℕℙ-ℝℤΩℨK-ℭℯ-ℹℼ-ℿⅅ-ⅉⅎⅠ-ↈⰀ-Ⱞⰰ-ⱞⱠ-ⳤⳫ-ⳮⳲⳳⴀ-ⴥⴧⴭⴰ-ⵧⵯⶀ-ⶖⶠ-ⶦⶨ-ⶮⶰ-ⶶⶸ-ⶾⷀ-ⷆⷈ-ⷎⷐ-ⷖⷘ-ⷞⸯ々-〇〡-〩〱-〵〸-〼ぁ-ゖゝ-ゟァ-ヺー-ヿㄅ-ㄭㄱ-ㆎㆠ-ㆺㇰ-ㇿ㐀-䶵一-鿌ꀀ-ꒌꓐ-ꓽꔀ-ꘌꘐ-ꘟꘪꘫꙀ-ꙮꙿ-ꚗꚠ-ꛯꜗ-ꜟꜢ-ꞈꞋ-ꞎꞐ-ꞓꞠ-Ɦꟸ-ꠁꠃ-ꠅꠇ-ꠊꠌ-ꠢꡀ-ꡳꢂ-ꢳꣲ-ꣷꣻꤊ-ꤥꤰ-ꥆꥠ-ꥼꦄ-ꦲꧏꨀ-ꨨꩀ-ꩂꩄ-ꩋꩠ-ꩶꩺꪀ-ꪯꪱꪵꪶꪹ-ꪽꫀꫂꫛ-ꫝꫠ-ꫪꫲ-ꫴꬁ-ꬆꬉ-ꬎꬑ-ꬖꬠ-ꬦꬨ-ꬮꯀ-ꯢ가-힣ힰ-ퟆퟋ-ퟻ豈-舘並-龎ff-stﬓ-ﬗיִײַ-ﬨשׁ-זּטּ-לּמּנּסּףּפּצּ-ﮱﯓ-ﴽﵐ-ﶏﶒ-ﷇﷰ-ﷻﹰ-ﹴﹶ-ﻼA-Za-zヲ-하-ᅦᅧ-ᅬᅭ-ᅲᅳ-ᅵ",i=new RegExp("["+n+"]"),r=new RegExp("["+n+"̀-ͯ҃-֑҇-ׇֽֿׁׂׅׄؐ-ؚؠ-ىٲ-ۓۧ-ۨۻ-ۼܰ-݊ࠀ-ࠔࠛ-ࠣࠥ-ࠧࠩ-࠭ࡀ-ࡗࣤ-ࣾऀ-ःऺ-़ा-ॏ॑-ॗॢ-ॣ०-९ঁ-ঃ়া-ৄেৈৗয়-ৠਁ-ਃ਼ਾ-ੂੇੈੋ-੍ੑ੦-ੱੵઁ-ઃ઼ા-ૅે-ૉો-્ૢ-ૣ૦-૯ଁ-ଃ଼ା-ୄେୈୋ-୍ୖୗୟ-ୠ୦-୯ஂா-ூெ-ைொ-்ௗ௦-௯ఁ-ఃె-ైొ-్ౕౖౢ-ౣ౦-౯ಂಃ಼ಾ-ೄೆ-ೈೊ-್ೕೖೢ-ೣ೦-೯ംഃെ-ൈൗൢ-ൣ൦-൯ංඃ්ා-ුූෘ-ෟෲෳิ-ฺเ-ๅ๐-๙ິ-ູ່-ໍ໐-໙༘༙༠-༩༹༵༷ཁ-ཇཱ-྄྆-྇ྍ-ྗྙ-ྼ࿆က-ဩ၀-၉ၧ-ၭၱ-ၴႂ-ႍႏ-ႝ፝-፟ᜎ-ᜐᜠ-ᜰᝀ-ᝐᝲᝳក-ឲ៝០-៩᠋-᠍᠐-᠙ᤠ-ᤫᤰ-᤻ᥑ-ᥭᦰ-ᧀᧈ-ᧉ᧐-᧙ᨀ-ᨕᨠ-ᩓ᩠-᩿᩼-᪉᪐-᪙ᭆ-ᭋ᭐-᭙᭫-᭳᮰-᮹᯦-᯳ᰀ-ᰢ᱀-᱉ᱛ-ᱽ᳐-᳒ᴀ-ᶾḁ-ἕ‿⁀⁔⃐-⃥⃜⃡-⃰ⶁ-ⶖⷠ-ⷿ〡-〨゙゚Ꙁ-ꙭꙴ-꙽ꚟ꛰-꛱ꟸ-ꠀ꠆ꠋꠣ-ꠧꢀ-ꢁꢴ-꣄꣐-꣙ꣳ-ꣷ꤀-꤉ꤦ-꤭ꤰ-ꥅꦀ-ꦃ꦳-꧀ꨀ-ꨧꩀ-ꩁꩌ-ꩍ꩐-꩙ꩻꫠ-ꫩꫲ-ꫳꯀ-ꯡ꯬꯭꯰-꯹ﬠ-ﬨ︀-️︠-︦︳︴﹍-﹏0-9_]");t.newline=/[\n\r\u2028\u2029]/,t.lineBreak=new RegExp("\r\n|"+t.newline.source),t.allLineBreaks=new RegExp(t.lineBreak.source,"g"),t.isIdentifierStart=function(e){return e<65?36===e||64===e:e<91||(e<97?95===e:e<123||e>=170&&i.test(String.fromCharCode(e)))},t.isIdentifierChar=function(e){return e<48?36===e:e<58||!(e<65)&&(e<91||(e<97?95===e:e<123||e>=170&&r.test(String.fromCharCode(e))))}},function(e,t,n){function i(e,t){if(!t.multiline_frame&&t.mode!==T.ForInitializer&&t.mode!==T.Conditional){var n=t.start_line_index;e.remove_indent(n)}}function r(e,t){for(var n=0;n
|
2
|
+
t.n=function(e){var n=e&&e.__esModule?function(){return e.default}:function(){return e};return t.d(n,"a",n),n},t.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},t.p="",t(t.s=3)}([function(e,t,n){function i(e){return e.replace(/^\s+/g,"")}function r(e){return e.replace(/\s+$/g,"")}function s(e,t,n,s){function _(){function e(e){var t="";return{add:function(n){var i=t+n.toLowerCase();t=i.length<=e.length?i:i.substr(i.length-e.length,e.length)},doesNotMatch:function(){return-1===t.indexOf(e)}}}return this.pos=0,this.token="",this.current_mode="CONTENT",this.tags={parent:"parent1",parentcount:1,parent1:""},this.tag_type="",this.token_text=this.last_token=this.last_text=this.token_type="",this.newlines=0,this.indent_content=h,this.indent_body_inner_html=u,this.indent_head_inner_html=p,this.Utils={whitespace:"\n\r\t ".split(""),single_token:t.void_elements||["area","base","br","col","embed","hr","img","input","keygen","link","menuitem","meta","param","source","track","wbr","!doctype","?xml","?php","basefont","isindex"],extra_liners:S,in_array:function(e,t){for(var n=0;n
|
@@ -1,2 +1,2 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/comment/continuecomment.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){function t(t){if(t.getOption("disableInput"))return e.Pass;for(var i,r=t.listSelections(),o=[],a=0;a
|
2
|
-
;return null!=t?t:(e.ignoreCase?"i":"")+(e.global?"g":"")+(e.multiline?"m":"")}function n(e){return e.global?e:new RegExp(e.source,t(e)+"g")}function i(e){return/\\s|\\n|\n|\\W|\\D|\[\^/.test(e.source)}function r(e,t,i){t=n(t);for(var r=i.line,o=i.ch,a=e.lastLine();r<=a;r++,o=0){t.lastIndex=o;var l=e.getLine(r),s=t.exec(l);if(s)return{from:g(r,s.index),to:g(r,s.index+s[0].length),match:s}}}function o(e,t,o){if(!i(t))return r(e,t,o);t=n(t);for(var a,l=1,s=o.line,c=e.lastLine();s<=c;){for(var f=0;f
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/comment/continuecomment.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){function t(t){if(t.getOption("disableInput"))return e.Pass;for(var i,o=t.listSelections(),r=[],s=0;s
|
2
|
+
;if(e.line!=this.startPos.line||t.length-e.ch!=this.startLen-this.startPos.ch||e.ch
|
data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.addons.search.min.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/search/searchcursor",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";function n(e){var n=e.flags;return null!=n?n:(e.ignoreCase?"i":"")+(e.global?"g":"")+(e.multiline?"m":"")}function t(e){return e.global?e:new RegExp(e.source,n(e)+"g")}function o(e){return/\\s|\\n|\n|\\W|\\D|\[\^/.test(e.source)}function r(e,n,o){n=t(n);for(var r=o.line,i=o.ch,s=e.lastLine();r<=s;r++,i=0){n.lastIndex=i;var c=e.getLine(r),l=n.exec(c);if(l)return{from:g(r,l.index),to:g(r,l.index+l[0].length),match:l}}}function i(e,n,i){if(!o(n))return r(e,n,i);n=t(n);for(var s,c=1,l=i.line,a=e.lastLine();l<=a;){for(var u=0;u
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/search/searchcursor",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";function n(e){var n=e.flags;return null!=n?n:(e.ignoreCase?"i":"")+(e.global?"g":"")+(e.multiline?"m":"")}function t(e,t){for(var o=n(e),r=o,i=0;i
|
@@ -1,6 +1 @@
|
|
1
|
-
!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define("codemirror.js",t):e.CodeMirror=t()}(this,function(){"use strict";function e(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}function t(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function r(e,r){return t(e).appendChild(r)}function n(e,t,r,n){var i=document.createElement(e);if(r&&(i.className=r),n&&(i.style.cssText=n),"string"==typeof t)i.appendChild(document.createTextNode(t));else if(t)for(var o=0;o
|
2
|
-
var i,o=$t(t.map,r,n),l=o.node,s=o.start,a=o.end,u=o.collapse;if(3==l.nodeType){for(var c=0;c<4;c++){for(;s&&S(t.line.text.charAt(o.coverStart+s));)--s;for(;o.coverStart+a<o.coverEnd&&S(t.line.text.charAt(o.coverStart+a));)++a;if(i=ml&&yl<9&&0==s&&a==o.coverEnd-o.coverStart?l.parentNode.getBoundingClientRect():qt(Hl(l,s,a).getClientRects(),n),i.left||i.right||0==s)break;a=s,s-=1,u="right"}ml&&yl<11&&(i=Qt(e.display.measure,i))}else{s>0&&(u=n="right");var f;i=e.options.lineWrapping&&(f=l.getClientRects()).length>1?f["right"==n?f.length-1:0]:l.getBoundingClientRect()}if(ml&&yl<9&&!s&&(!i||!i.left&&!i.right)){var h=l.parentNode.getClientRects()[0];i=h?{left:h.left,right:h.left+br(e.display),top:h.top,bottom:h.bottom}:bs}for(var d=i.top-t.rect.top,p=i.bottom-t.rect.top,g=(d+p)/2,v=t.view.measure.heights,m=0;m<v.length-1&&!(g<v[m]);m++);var y=m?v[m-1]:0,b=v[m],w={left:("right"==u?i.right:i.left)-t.rect.left,right:("left"==u?i.left:i.right)-t.rect.left,top:y,bottom:b};return i.left||i.right||(w.bogus=!0),e.options.singleCursorHeightPerLine||(w.rtop=d,w.rbottom=p),w}function Qt(e,t){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!Re(e))return t;var r=screen.logicalXDPI/screen.deviceXDPI,n=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*r,right:t.right*r,top:t.top*n,bottom:t.bottom*n}}function Jt(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t<e.rest.length;t++)e.measure.caches[t]={}}function er(e){e.display.externalMeasure=null,t(e.display.lineMeasure);for(var r=0;r<e.display.view.length;r++)Jt(e.display.view[r])}function tr(e){er(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function rr(){return xl&&Ml?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function nr(){return xl&&Ml?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function ir(e){var t=0;if(e.widgets)for(var r=0;r<e.widgets.length;++r)e.widgets[r].above&&(t+=Ft(e.widgets[r]));return t}function or(e,t,r,n,i){if(!i){var o=ir(t);r.top+=o,r.bottom+=o}if("line"==n)return r;n||(n="local");var l=ye(t);if("local"==n?l+=Et(e.display):l-=e.display.viewOffset,"page"==n||"window"==n){var s=e.display.lineSpace.getBoundingClientRect();l+=s.top+("window"==n?0:nr());var a=s.left+("window"==n?0:rr());r.left+=a,r.right+=a}return r.top+=l,r.bottom+=l,r}function lr(e,t,r){if("div"==r)return t;var n=t.left,i=t.top;if("page"==r)n-=rr(),i-=nr();else if("local"==r||!r){var o=e.display.sizer.getBoundingClientRect();n+=o.left,i+=o.top}var l=e.display.lineSpace.getBoundingClientRect();return{left:n-l.left,top:i-l.top}}function sr(e,t,r,n,i){return n||(n=M(e.doc,t.line)),or(e,n,jt(e,n,t.ch,i),r)}function ar(e,t,r,n,i,o){function l(t,l){var s=_t(e,i,t,l?"right":"left",o);return l?s.left=s.right:s.right=s.left,or(e,n,s,r)}function s(e,t,r){var n=a[t],i=1==n.level;return l(r?e-1:e,i!=r)}n=n||M(e.doc,t.line),i||(i=Yt(e,n));var a=Se(n,e.doc.direction),u=t.ch,c=t.sticky;if(u>=n.text.length?(u=n.text.length,c="before"):u<=0&&(u=0,c="after"),!a)return l("before"==c?u-1:u,"before"==c);var f=Ce(a,u,c),h=Zl,d=s(u,f,"before"==c);return null!=h&&(d.other=s(u,h,"before"!=c)),d}function ur(e,t){var r=0;t=U(e.doc,t),e.options.lineWrapping||(r=br(e.display)*t.ch);var n=M(e.doc,t.line),i=ye(n)+Et(e.display);return{left:r,right:r,top:i,bottom:i+n.height}}function cr(e,t,r,n,i){var o=P(e,t,r);return o.xRel=i,n&&(o.outside=!0),o}function fr(e,t,r){var n=e.doc;if((r+=e.display.viewOffset)<0)return cr(n.first,0,null,!0,-1);var i=D(n,r),o=n.first+n.size-1;if(i>o)return cr(n.first+n.size-1,M(n,o).text.length,null,!0,1);t<0&&(t=0);for(var l=M(n,i);;){var s=gr(e,l,i,t,r),a=ue(l),u=a&&a.find(0,!0);if(!a||!(s.ch>u.from.ch||s.ch==u.from.ch&&s.xRel>0))return s;i=W(l=u.to.line)}}function hr(e,t,r,n){n-=ir(t);var i=t.text.length,o=k(function(t){return _t(e,r,t-1).bottom<=n},i,0);return i=k(function(t){return _t(e,r,t).top>n},o,i),{begin:o,end:i}}function dr(e,t,r,n){return r||(r=Yt(e,t)),hr(e,t,r,or(e,t,_t(e,r,n),"line").top)}function pr(e,t,r,n){return!(e.bottom<=r)&&(e.top>r||(n?e.left:e.right)>t)}function gr(e,t,r,n,i){i-=ye(t);var o=Yt(e,t),l=ir(t),s=0,a=t.text.length,u=!0,c=Se(t,e.doc.direction);if(c){var f=(e.options.lineWrapping?mr:vr)(e,t,r,o,c,n,i);u=1!=f.level,s=u?f.from:f.to-1,a=u?f.to:f.from-1}var h,d,p=null,g=null,v=k(function(t){var r=_t(e,o,t);return r.top+=l,r.bottom+=l,!!pr(r,n,i,!1)&&(r.top<=i&&r.left<=n&&(p=t,g=r),!0)},s,a),m=!1;if(g){var y=n-g.left<g.right-n,b=y==u;v=p+(b?0:1),d=b?"after":"before",h=y?g.left:g.right}else{u||v!=a&&v!=s||v++,d=0==v?"after":v==t.text.length?"before":_t(e,o,v-(u?1:0)).bottom+l<=i==u?"after":"before";var w=ar(e,P(r,v,d),"line",t,o);h=w.left,m=i<w.top||i>=w.bottom}return v=L(t.text,v,1),cr(r,v,d,m,n-h)}function vr(e,t,r,n,i,o,l){var s=k(function(s){var a=i[s],u=1!=a.level;return pr(ar(e,P(r,u?a.to:a.from,u?"before":"after"),"line",t,n),o,l,!0)},0,i.length-1),a=i[s];if(s>0){var u=1!=a.level,c=ar(e,P(r,u?a.from:a.to,u?"after":"before"),"line",t,n);pr(c,o,l,!0)&&c.top>l&&(a=i[s-1])}return a}function mr(e,t,r,n,i,o,l){var s=hr(e,t,n,l),a=s.begin,u=s.end;/\s/.test(t.text.charAt(u-1))&&u--;for(var c=null,f=null,h=0;h<i.length;h++){var d=i[h];if(!(d.from>=u||d.to<=a)){var p=1!=d.level,g=_t(e,n,p?Math.min(u,d.to)-1:Math.max(a,d.from)).right,v=g<o?o-g+1e9:g-o;(!c||f>v)&&(c=d,f=v)}}return c||(c=i[i.length-1]),c.from<a&&(c={from:a,to:c.to,level:c.level}),c.to>u&&(c={from:c.from,to:u,level:c.level}),c}function yr(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==ps){ps=n("pre");for(var i=0;i<49;++i)ps.appendChild(document.createTextNode("x")),ps.appendChild(n("br"));ps.appendChild(document.createTextNode("x"))}r(e.measure,ps);var o=ps.offsetHeight/50;return o>3&&(e.cachedTextHeight=o),t(e.measure),o||1}function br(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=n("span","xxxxxxxxxx"),i=n("pre",[t]);r(e.measure,i);var o=t.getBoundingClientRect(),l=(o.right-o.left)/10;return l>2&&(e.cachedCharWidth=l),l||10}function wr(e){for(var t=e.display,r={},n={},i=t.gutters.clientLeft,o=t.gutters.firstChild,l=0;o;o=o.nextSibling,++l)r[e.options.gutters[l]]=o.offsetLeft+o.clientLeft+i,n[e.options.gutters[l]]=o.clientWidth;return{fixedPos:xr(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:r,gutterWidth:n,wrapperWidth:t.wrapper.clientWidth}}function xr(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function Cr(e){var t=yr(e.display),r=e.options.lineWrapping,n=r&&Math.max(5,e.display.scroller.clientWidth/br(e.display)-3);return function(i){if(ve(e.doc,i))return 0;var o=0;if(i.widgets)for(var l=0;l<i.widgets.length;l++)i.widgets[l].height&&(o+=i.widgets[l].height);return r?o+(Math.ceil(i.text.length/n)||1)*t:o+t}}function Sr(e){var t=e.doc,r=Cr(e);t.iter(function(e){var t=r(e);t!=e.height&&A(e,t)})}function Lr(e,t,r,n){var i=e.display;if(!r&&"true"==Pe(t).getAttribute("cm-not-content"))return null;var o,l,s=i.lineSpace.getBoundingClientRect();try{o=t.clientX-s.left,l=t.clientY-s.top}catch(t){return null}var a,u=fr(e,o,l);if(n&&1==u.xRel&&(a=M(e.doc,u.line).text).length==u.ch){var c=f(a,a.length,e.options.tabSize)-a.length;u=P(u.line,Math.max(0,Math.round((o-It(e.display).left)/br(e.display))-c))}return u}function kr(e,t){if(t>=e.display.viewTo)return null;if((t-=e.display.viewFrom)<0)return null;for(var r=e.display.view,n=0;n<r.length;n++)if((t-=r[n].size)<0)return n}function Tr(e){e.display.input.showSelection(e.display.input.prepareSelection())}function Mr(e,t){void 0===t&&(t=!0);for(var r=e.doc,n={},i=n.cursors=document.createDocumentFragment(),o=n.selection=document.createDocumentFragment(),l=0;l<r.sel.ranges.length;l++)if(t||l!=r.sel.primIndex){var s=r.sel.ranges[l];if(!(s.from().line>=e.display.viewTo||s.to().line<e.display.viewFrom)){var a=s.empty();(a||e.options.showCursorWhenSelecting)&&Nr(e,s.head,i),a||Ar(e,s,o)}}return n}function Nr(e,t,r){var i=ar(e,t,"div",null,null,!e.options.singleCursorHeightPerLine),o=r.appendChild(n("div"," ","CodeMirror-cursor"));if(o.style.left=i.left+"px",o.style.top=i.top+"px",o.style.height=Math.max(0,i.bottom-i.top)*e.options.cursorHeight+"px",i.other){var l=r.appendChild(n("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));l.style.display="",l.style.left=i.other.left+"px",l.style.top=i.other.top+"px",l.style.height=.85*(i.other.bottom-i.other.top)+"px"}}function Or(e,t){return e.top-t.top||e.left-t.left}function Ar(e,t,r){function i(e,t,r,i){t<0&&(t=0),t=Math.round(t),i=Math.round(i),a.appendChild(n("div",null,"CodeMirror-selected","position: absolute; left: "+e+"px;\n top: "+t+"px; width: "+(null==r?f-e:r)+"px;\n height: "+(i-t)+"px"))}function o(t,r,n){function o(r,n){return sr(e,P(t,r),"div",d,n)}function l(t,r,n){var i=dr(e,d,null,t),l="ltr"==r==("after"==n)?"left":"right";return o("after"==n?i.begin:i.end-(/\s/.test(d.text.charAt(i.end-1))?2:1),l)[l]}var a,u,d=M(s,t),p=d.text.length,g=Se(d,s.direction);return xe(g,r||0,null==n?p:n,function(e,t,s,d){var v="ltr"==s,m=o(e,v?"left":"right"),y=o(t-1,v?"right":"left"),b=null==r&&0==e,w=null==n&&t==p,x=0==d,C=!g||d==g.length-1;if(y.top-m.top<=3){var S=(h?b:w)&&x,L=(h?w:b)&&C,k=S?c:(v?m:y).left,T=L?f:(v?y:m).right;i(k,m.top,T-k,m.bottom)}else{var M,N,O,A;v?(M=h&&b&&x?c:m.left,N=h?f:l(e,s,"before"),O=h?c:l(t,s,"after"),A=h&&w&&C?f:y.right):(M=h?l(e,s,"before"):c,N=!h&&b&&x?f:m.right,O=!h&&w&&C?c:y.left,A=h?l(t,s,"after"):f),i(M,m.top,N-M,m.bottom),m.bottom<y.top&&i(c,m.bottom,null,y.top),i(O,y.top,A-O,y.bottom)}(!a||Or(m,a)<0)&&(a=m),Or(y,a)<0&&(a=y),(!u||Or(m,u)<0)&&(u=m),Or(y,u)<0&&(u=y)}),{start:a,end:u}}var l=e.display,s=e.doc,a=document.createDocumentFragment(),u=It(e.display),c=u.left,f=Math.max(l.sizerWidth,Bt(e)-l.sizer.offsetLeft)-u.right,h="ltr"==s.direction,d=t.from(),p=t.to();if(d.line==p.line)o(d.line,d.ch,p.ch);else{var g=M(s,d.line),v=M(s,p.line),m=fe(g)==fe(v),y=o(d.line,d.ch,m?g.text.length+1:null).end,b=o(p.line,m?0:null,p.ch).start;m&&(y.top<b.top-2?(i(y.right,y.top,null,y.bottom),i(c,b.top,b.left,b.bottom)):i(y.right,y.top,b.left-y.right,y.bottom)),y.bottom<b.top&&i(c,y.bottom,null,b.top)}r.appendChild(a)}function Wr(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var r=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval(function(){return t.cursorDiv.style.visibility=(r=!r)?"":"hidden"},e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function Dr(e){e.state.focused||(e.display.input.focus(),Fr(e))}function Hr(e){e.state.delayingBlurEvent=!0,setTimeout(function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,Pr(e))},100)}function Fr(e,t){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(Te(e,"focus",e,t),e.state.focused=!0,s(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),bl&&setTimeout(function(){return e.display.input.reset(!0)},20)),e.display.input.receivedFocus()),Wr(e))}function Pr(e,t){e.state.delayingBlurEvent||(e.state.focused&&(Te(e,"blur",e,t),e.state.focused=!1,El(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout(function(){e.state.focused||(e.display.shift=!1)},150))}function Er(e){for(var t=e.display,r=t.lineDiv.offsetTop,n=0;n<t.view.length;n++){var i=t.view[n],o=void 0;if(!i.hidden){if(ml&&yl<8){var l=i.node.offsetTop+i.node.offsetHeight;o=l-r,r=l}else{var s=i.node.getBoundingClientRect();o=s.bottom-s.top}var a=i.line.height-o;if(o<2&&(o=yr(t)),(a>.005||a<-.005)&&(A(i.line,o),zr(i.line),i.rest))for(var u=0;u<i.rest.length;u++)zr(i.rest[u])}}}function zr(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t)e.widgets[t].height=e.widgets[t].node.parentNode.offsetHeight}function Ir(e,t,r){var n=r&&null!=r.top?Math.max(0,r.top):e.scroller.scrollTop;n=Math.floor(n-Et(e));var i=r&&null!=r.bottom?r.bottom:n+e.wrapper.clientHeight,o=D(t,n),l=D(t,i);if(r&&r.ensure){var s=r.ensure.from.line,a=r.ensure.to.line;s<o?(o=s,l=D(t,ye(M(t,s))+e.wrapper.clientHeight)):Math.min(a,t.lastLine())>=l&&(o=D(t,ye(M(t,a))-e.wrapper.clientHeight),l=a)}return{from:o,to:Math.max(l,o+1)}}function Rr(e){var t=e.display,r=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var n=xr(t)-t.scroller.scrollLeft+e.doc.scrollLeft,i=t.gutters.offsetWidth,o=n+"px",l=0;l<r.length;l++)if(!r[l].hidden){e.options.fixedGutter&&(r[l].gutter&&(r[l].gutter.style.left=o),r[l].gutterBackground&&(r[l].gutterBackground.style.left=o));var s=r[l].alignable;if(s)for(var a=0;a<s.length;a++)s[a].style.left=o}e.options.fixedGutter&&(t.gutters.style.left=n+i+"px")}}function Br(e){if(!e.options.lineNumbers)return!1;var t=e.doc,r=F(e.options,t.first+t.size-1),i=e.display;if(r.length!=i.lineNumChars){var o=i.measure.appendChild(n("div",[n("div",r)],"CodeMirror-linenumber CodeMirror-gutter-elt")),l=o.firstChild.offsetWidth,s=o.offsetWidth-l;return i.lineGutter.style.width="",i.lineNumInnerWidth=Math.max(l,i.lineGutter.offsetWidth-s)+1,i.lineNumWidth=i.lineNumInnerWidth+s,i.lineNumChars=i.lineNumInnerWidth?r.length:-1,i.lineGutter.style.width=i.lineNumWidth+"px",Dn(e),!0}return!1}function Gr(e,t){if(!Me(e,"scrollCursorIntoView")){var r=e.display,i=r.sizer.getBoundingClientRect(),o=null;if(t.top+i.top<0?o=!0:t.bottom+i.top>(window.innerHeight||document.documentElement.clientHeight)&&(o=!1),null!=o&&!kl){var l=n("div","",null,"position: absolute;\n top: "+(t.top-r.viewOffset-Et(e.display))+"px;\n height: "+(t.bottom-t.top+Rt(e)+r.barHeight)+"px;\n left: "+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(l),l.scrollIntoView(o),e.display.lineSpace.removeChild(l)}}}function Ur(e,t,r,n){null==n&&(n=0);var i;e.options.lineWrapping||t!=r||(t=t.ch?P(t.line,"before"==t.sticky?t.ch-1:t.ch,"after"):t,r="before"==t.sticky?P(t.line,t.ch+1,"before"):t);for(var o=0;o<5;o++){var l=!1,s=ar(e,t),a=r&&r!=t?ar(e,r):s;i={left:Math.min(s.left,a.left),top:Math.min(s.top,a.top)-n,right:Math.max(s.left,a.left),bottom:Math.max(s.bottom,a.bottom)+n};var u=Kr(e,i),c=e.doc.scrollTop,f=e.doc.scrollLeft;if(null!=u.scrollTop&&(Zr(e,u.scrollTop),Math.abs(e.doc.scrollTop-c)>1&&(l=!0)),null!=u.scrollLeft&&(Jr(e,u.scrollLeft),Math.abs(e.doc.scrollLeft-f)>1&&(l=!0)),!l)break}return i}function Vr(e,t){var r=Kr(e,t);null!=r.scrollTop&&Zr(e,r.scrollTop),null!=r.scrollLeft&&Jr(e,r.scrollLeft)}function Kr(e,t){var r=e.display,n=yr(e.display);t.top<0&&(t.top=0);var i=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:r.scroller.scrollTop,o=Gt(e),l={};t.bottom-t.top>o&&(t.bottom=t.top+o);var s=e.doc.height+zt(r),a=t.top<n,u=t.bottom>s-n;if(t.top<i)l.scrollTop=a?0:t.top;else if(t.bottom>i+o){var c=Math.min(t.top,(u?s:t.bottom)-o);c!=i&&(l.scrollTop=c)}var f=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:r.scroller.scrollLeft,h=Bt(e)-(e.options.fixedGutter?r.gutters.offsetWidth:0),d=t.right-t.left>h;return d&&(t.right=t.left+h),t.left<10?l.scrollLeft=0:t.left<f?l.scrollLeft=Math.max(0,t.left-(d?0:10)):t.right>h+f-3&&(l.scrollLeft=t.right+(d?0:10)-h),l}function jr(e,t){null!=t&&($r(e),e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+t)}function Xr(e){$r(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function Yr(e,t,r){null==t&&null==r||$r(e),null!=t&&(e.curOp.scrollLeft=t),null!=r&&(e.curOp.scrollTop=r)}function _r(e,t){$r(e),e.curOp.scrollToPos=t}function $r(e){var t=e.curOp.scrollToPos;if(t){e.curOp.scrollToPos=null;qr(e,ur(e,t.from),ur(e,t.to),t.margin)}}function qr(e,t,r,n){var i=Kr(e,{left:Math.min(t.left,r.left),top:Math.min(t.top,r.top)-n,right:Math.max(t.right,r.right),bottom:Math.max(t.bottom,r.bottom)+n});Yr(e,i.scrollLeft,i.scrollTop)}function Zr(e,t){Math.abs(e.doc.scrollTop-t)<2||(dl||An(e,{top:t}),Qr(e,t,!0),dl&&An(e),Sn(e,100))}function Qr(e,t,r){t=Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t),(e.display.scroller.scrollTop!=t||r)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function Jr(e,t,r,n){t=Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth),(r?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!n||(e.doc.scrollLeft=t,Rr(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function en(e){var t=e.display,r=t.gutters.offsetWidth,n=Math.round(e.doc.height+zt(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?r:0,docHeight:n,scrollHeight:n+Rt(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:r}}function tn(e,t){t||(t=en(e));var r=e.display.barWidth,n=e.display.barHeight;rn(e,t);for(var i=0;i<4&&r!=e.display.barWidth||n!=e.display.barHeight;i++)r!=e.display.barWidth&&e.options.lineWrapping&&Er(e),rn(e,en(e)),r=e.display.barWidth,n=e.display.barHeight}function rn(e,t){var r=e.display,n=r.scrollbars.update(t);r.sizer.style.paddingRight=(r.barWidth=n.right)+"px",r.sizer.style.paddingBottom=(r.barHeight=n.bottom)+"px",r.heightForcer.style.borderBottom=n.bottom+"px solid transparent",n.right&&n.bottom?(r.scrollbarFiller.style.display="block",r.scrollbarFiller.style.height=n.bottom+"px",r.scrollbarFiller.style.width=n.right+"px"):r.scrollbarFiller.style.display="",n.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(r.gutterFiller.style.display="block",r.gutterFiller.style.height=n.bottom+"px",r.gutterFiller.style.width=t.gutterWidth+"px"):r.gutterFiller.style.display=""}function nn(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&El(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new Cs[e.options.scrollbarStyle](function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),es(t,"mousedown",function(){e.state.focused&&setTimeout(function(){return e.display.input.focus()},0)}),t.setAttribute("cm-not-content","true")},function(t,r){"horizontal"==r?Jr(e,t):Zr(e,t)},e),e.display.scrollbars.addClass&&s(e.display.wrapper,e.display.scrollbars.addClass)}function on(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:null,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++Ss},mt(e.curOp)}function ln(e){bt(e.curOp,function(e){for(var t=0;t<e.ops.length;t++)e.ops[t].cm.curOp=null;sn(e)})}function sn(e){for(var t=e.ops,r=0;r<t.length;r++)an(t[r]);for(var n=0;n<t.length;n++)un(t[n]);for(var i=0;i<t.length;i++)cn(t[i]);for(var o=0;o<t.length;o++)fn(t[o]);for(var l=0;l<t.length;l++)hn(t[l])}function an(e){var t=e.cm,r=t.display;kn(t),e.updateMaxLine&&we(t),e.mustUpdate=e.viewChanged||e.forceUpdate||null!=e.scrollTop||e.scrollToPos&&(e.scrollToPos.from.line<r.viewFrom||e.scrollToPos.to.line>=r.viewTo)||r.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new Ls(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function un(e){e.updatedDisplay=e.mustUpdate&&Nn(e.cm,e.update)}function cn(e){var t=e.cm,r=t.display;e.updatedDisplay&&Er(t),e.barMeasure=en(t),r.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=jt(t,r.maxLine,r.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(r.scroller.clientWidth,r.sizer.offsetLeft+e.adjustWidthTo+Rt(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,r.sizer.offsetLeft+e.adjustWidthTo-Bt(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=r.input.prepareSelection())}function fn(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&Jr(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var r=e.focus&&e.focus==l();e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,r),(e.updatedDisplay||e.startHeight!=t.doc.height)&&tn(t,e.barMeasure),e.updatedDisplay&&Hn(t,e.barMeasure),e.selectionChanged&&Wr(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),r&&Dr(e.cm)}function hn(e){var t=e.cm,r=t.display,n=t.doc;if(e.updatedDisplay&&On(t,e.update),null==r.wheelStartX||null==e.scrollTop&&null==e.scrollLeft&&!e.scrollToPos||(r.wheelStartX=r.wheelStartY=null),null!=e.scrollTop&&Qr(t,e.scrollTop,e.forceScroll),null!=e.scrollLeft&&Jr(t,e.scrollLeft,!0,!0),e.scrollToPos){Gr(t,Ur(t,U(n,e.scrollToPos.from),U(n,e.scrollToPos.to),e.scrollToPos.margin))}var i=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(i)for(var l=0;l<i.length;++l)i[l].lines.length||Te(i[l],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&Te(o[s],"unhide");r.wrapper.offsetHeight&&(n.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&Te(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function dn(e,t){if(e.curOp)return t();on(e);try{return t()}finally{ln(e)}}function pn(e,t){return function(){if(e.curOp)return t.apply(e,arguments);on(e);try{return t.apply(e,arguments)}finally{ln(e)}}}function gn(e){return function(){if(this.curOp)return e.apply(this,arguments);on(this);try{return e.apply(this,arguments)}finally{ln(this)}}}function vn(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);on(t);try{return e.apply(this,arguments)}finally{ln(t)}}}function mn(e,t,r,n){null==t&&(t=e.doc.first),null==r&&(r=e.doc.first+e.doc.size),n||(n=0);var i=e.display;if(n&&r<i.viewTo&&(null==i.updateLineNumbers||i.updateLineNumbers>t)&&(i.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=i.viewTo)ql&&pe(e.doc,t)<i.viewTo&&bn(e);else if(r<=i.viewFrom)ql&&ge(e.doc,r+n)>i.viewFrom?bn(e):(i.viewFrom+=n,i.viewTo+=n);else if(t<=i.viewFrom&&r>=i.viewTo)bn(e);else if(t<=i.viewFrom){var o=wn(e,r,r+n,1);o?(i.view=i.view.slice(o.index),i.viewFrom=o.lineN,i.viewTo+=n):bn(e)}else if(r>=i.viewTo){var l=wn(e,t,t,-1);l?(i.view=i.view.slice(0,l.index),i.viewTo=l.lineN):bn(e)}else{var s=wn(e,t,t,-1),a=wn(e,r,r+n,1);s&&a?(i.view=i.view.slice(0,s.index).concat(vt(e,s.lineN,a.lineN)).concat(i.view.slice(a.index)),i.viewTo+=n):bn(e)}var u=i.externalMeasured;u&&(r<u.lineN?u.lineN+=n:t<u.lineN+u.size&&(i.externalMeasured=null))}function yn(e,t,r){e.curOp.viewChanged=!0;var n=e.display,i=e.display.externalMeasured;if(i&&t>=i.lineN&&t<i.lineN+i.size&&(n.externalMeasured=null),!(t<n.viewFrom||t>=n.viewTo)){var o=n.view[kr(e,t)];if(null!=o.node){var l=o.changes||(o.changes=[]);-1==h(l,r)&&l.push(r)}}}function bn(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function wn(e,t,r,n){var i,o=kr(e,t),l=e.display.view;if(!ql||r==e.doc.first+e.doc.size)return{index:o,lineN:r};for(var s=e.display.viewFrom,a=0;a<o;a++)s+=l[a].size;if(s!=t){if(n>0){if(o==l.length-1)return null;i=s+l[o].size-t,o++}else i=s-t;t+=i,r+=i}for(;pe(e.doc,r)!=r;){if(o==(n<0?0:l.length-1))return null;r+=n*l[o-(n<0?1:0)].size,o+=n}return{index:o,lineN:r}}function xn(e,t,r){var n=e.display;0==n.view.length||t>=n.viewTo||r<=n.viewFrom?(n.view=vt(e,t,r),n.viewFrom=t):(n.viewFrom>t?n.view=vt(e,t,n.viewFrom).concat(n.view):n.viewFrom<t&&(n.view=n.view.slice(kr(e,t))),n.viewFrom=t,n.viewTo<r?n.view=n.view.concat(vt(e,n.viewTo,r)):n.viewTo>r&&(n.view=n.view.slice(0,kr(e,r)))),n.viewTo=r}function Cn(e){for(var t=e.display.view,r=0,n=0;n<t.length;n++){var i=t[n];i.hidden||i.node&&!i.changes||++r}return r}function Sn(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,u(Ln,e))}function Ln(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var r=+new Date+e.options.workTime,n=qe(e,t.highlightFrontier),i=[];t.iter(n.line,Math.min(t.first+t.size,e.display.viewTo+500),function(o){if(n.line>=e.display.viewFrom){var l=o.styles,s=o.text.length>e.options.maxHighlightLength?je(t.mode,n.state):null,a=_e(e,o,n,!0);s&&(n.state=s),o.styles=a.styles;var u=o.styleClasses,c=a.classes;c?o.styleClasses=c:u&&(o.styleClasses=null);for(var f=!l||l.length!=o.styles.length||u!=c&&(!u||!c||u.bgClass!=c.bgClass||u.textClass!=c.textClass),h=0;!f&&h<l.length;++h)f=l[h]!=o.styles[h];f&&i.push(n.line),o.stateAfter=n.save(),n.nextLine()}else o.text.length<=e.options.maxHighlightLength&&Ze(e,o.text,n),o.stateAfter=n.line%5==0?n.save():null,n.nextLine();if(+new Date>r)return Sn(e,e.options.workDelay),!0}),t.highlightFrontier=n.line,t.modeFrontier=Math.max(t.modeFrontier,n.line),i.length&&dn(e,function(){for(var t=0;t<i.length;t++)yn(e,i[t],"text")})}}function kn(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Rt(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Rt(e)+"px",t.scrollbarsClipped=!0)}function Tn(e){if(e.hasFocus())return null;var t=l();if(!t||!o(e.display.lineDiv,t))return null;var r={activeElt:t};if(window.getSelection){var n=window.getSelection();n.anchorNode&&n.extend&&o(e.display.lineDiv,n.anchorNode)&&(r.anchorNode=n.anchorNode,r.anchorOffset=n.anchorOffset,r.focusNode=n.focusNode,r.focusOffset=n.focusOffset)}return r}function Mn(e){if(e&&e.activeElt&&e.activeElt!=l()&&(e.activeElt.focus(),e.anchorNode&&o(document.body,e.anchorNode)&&o(document.body,e.focusNode))){var t=window.getSelection(),r=document.createRange();r.setEnd(e.anchorNode,e.anchorOffset),r.collapse(!1),t.removeAllRanges(),t.addRange(r),t.extend(e.focusNode,e.focusOffset)}}function Nn(e,r){var n=e.display,i=e.doc;if(r.editorIsHidden)return bn(e),!1;if(!r.force&&r.visible.from>=n.viewFrom&&r.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==Cn(e))return!1;Br(e)&&(bn(e),r.dims=wr(e));var o=i.first+i.size,l=Math.max(r.visible.from-e.options.viewportMargin,i.first),s=Math.min(o,r.visible.to+e.options.viewportMargin);n.viewFrom<l&&l-n.viewFrom<20&&(l=Math.max(i.first,n.viewFrom)),n.viewTo>s&&n.viewTo-s<20&&(s=Math.min(o,n.viewTo)),ql&&(l=pe(e.doc,l),s=ge(e.doc,s));var a=l!=n.viewFrom||s!=n.viewTo||n.lastWrapHeight!=r.wrapperHeight||n.lastWrapWidth!=r.wrapperWidth;xn(e,l,s),n.viewOffset=ye(M(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var u=Cn(e);if(!a&&0==u&&!r.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var c=Tn(e);return u>4&&(n.lineDiv.style.display="none"),Wn(e,n.updateLineNumbers,r.dims),u>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,Mn(c),t(n.cursorDiv),t(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,a&&(n.lastWrapHeight=r.wrapperHeight,n.lastWrapWidth=r.wrapperWidth,Sn(e,400)),n.updateLineNumbers=null,!0}function On(e,t){for(var r=t.viewport,n=!0;(n&&e.options.lineWrapping&&t.oldDisplayWidth!=Bt(e)||(r&&null!=r.top&&(r={top:Math.min(e.doc.height+zt(e.display)-Gt(e),r.top)}),t.visible=Ir(e.display,e.doc,r),!(t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)))&&Nn(e,t);n=!1){Er(e);var i=en(e);Tr(e),tn(e,i),Hn(e,i),t.force=!1}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function An(e,t){var r=new Ls(e,t);if(Nn(e,r)){Er(e),On(e,r);var n=en(e);Tr(e),tn(e,n),Hn(e,n),r.finish()}}function Wn(e,r,n){function i(t){var r=t.nextSibling;return bl&&Ol&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),r}for(var o=e.display,l=e.options.lineNumbers,s=o.lineDiv,a=s.firstChild,u=o.view,c=o.viewFrom,f=0;f<u.length;f++){var d=u[f];if(d.hidden);else if(d.node&&d.node.parentNode==s){for(;a!=d.node;)a=i(a);var p=l&&null!=r&&r<=c&&d.lineNumber;d.changes&&(h(d.changes,"gutter")>-1&&(p=!1),Ct(e,d,c,n)),p&&(t(d.lineNumber),d.lineNumber.appendChild(document.createTextNode(F(e.options,c)))),a=d.node.nextSibling}else{var g=At(e,d,c,n);s.insertBefore(g,a)}c+=d.size}for(;a;)a=i(a)}function Dn(e){var t=e.display.gutters.offsetWidth;e.display.sizer.style.marginLeft=t+"px"}function Hn(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Rt(e)+"px"}function Fn(e){var r=e.display.gutters,i=e.options.gutters;t(r);for(var o=0;o<i.length;++o){var l=i[o],s=r.appendChild(n("div",null,"CodeMirror-gutter "+l));"CodeMirror-linenumbers"==l&&(e.display.lineGutter=s,s.style.width=(e.display.lineNumWidth||1)+"px")}r.style.display=o?"":"none",Dn(e)}function Pn(e){var t=h(e.gutters,"CodeMirror-linenumbers");-1==t&&e.lineNumbers?e.gutters=e.gutters.concat(["CodeMirror-linenumbers"]):t>-1&&!e.lineNumbers&&(e.gutters=e.gutters.slice(0),e.gutters.splice(t,1))}function En(e){var t=e.wheelDeltaX,r=e.wheelDeltaY;return null==t&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),null==r&&e.detail&&e.axis==e.VERTICAL_AXIS?r=e.detail:null==r&&(r=e.wheelDelta),{x:t,y:r}}function zn(e){var t=En(e);return t.x*=Ts,t.y*=Ts,t}function In(e,t){var r=En(t),n=r.x,i=r.y,o=e.display,l=o.scroller,s=l.scrollWidth>l.clientWidth,a=l.scrollHeight>l.clientHeight;if(n&&s||i&&a){if(i&&Ol&&bl)e:for(var u=t.target,c=o.view;u!=l;u=u.parentNode)for(var f=0;f<c.length;f++)if(c[f].node==u){e.display.currentWheelTarget=u;break e}if(n&&!dl&&!Cl&&null!=Ts)return i&&a&&Zr(e,Math.max(0,l.scrollTop+i*Ts)),Jr(e,Math.max(0,l.scrollLeft+n*Ts)),(!i||i&&a)&&We(t),void(o.wheelStartX=null);if(i&&null!=Ts){var h=i*Ts,d=e.doc.scrollTop,p=d+o.wrapper.clientHeight;h<0?d=Math.max(0,d+h-50):p=Math.min(e.doc.height,p+h+50),An(e,{top:d,bottom:p})}ks<20&&(null==o.wheelStartX?(o.wheelStartX=l.scrollLeft,o.wheelStartY=l.scrollTop,o.wheelDX=n,o.wheelDY=i,setTimeout(function(){if(null!=o.wheelStartX){var e=l.scrollLeft-o.wheelStartX,t=l.scrollTop-o.wheelStartY,r=t&&o.wheelDY&&t/o.wheelDY||e&&o.wheelDX&&e/o.wheelDX;o.wheelStartX=o.wheelStartY=null,r&&(Ts=(Ts*ks+r)/(ks+1),++ks)}},200)):(o.wheelDX+=n,o.wheelDY+=i))}}function Rn(e,t){var r=e[t];e.sort(function(e,t){return E(e.from(),t.from())}),t=h(e,r);for(var n=1;n<e.length;n++){var i=e[n],o=e[n-1];if(E(o.to(),i.from())>=0){var l=B(o.from(),i.from()),s=R(o.to(),i.to()),a=o.empty()?i.from()==i.head:o.from()==o.head;n<=t&&--t,e.splice(--n,2,new Ns(a?s:l,a?l:s))}}return new Ms(e,t)}function Bn(e,t){return new Ms([new Ns(e,t||e)],0)}function Gn(e){return e.text?P(e.from.line+e.text.length-1,g(e.text).length+(1==e.text.length?e.from.ch:0)):e.to}function Un(e,t){if(E(e,t.from)<0)return e;if(E(e,t.to)<=0)return Gn(t);var r=e.line+t.text.length-(t.to.line-t.from.line)-1,n=e.ch;return e.line==t.to.line&&(n+=Gn(t).ch-t.to.ch),P(r,n)}function Vn(e,t){for(var r=[],n=0;n<e.sel.ranges.length;n++){var i=e.sel.ranges[n];r.push(new Ns(Un(i.anchor,t),Un(i.head,t)))}return Rn(r,e.sel.primIndex)}function Kn(e,t,r){return e.line==t.line?P(r.line,e.ch-t.ch+r.ch):P(r.line+(e.line-t.line),e.ch)}function jn(e,t,r){for(var n=[],i=P(e.first,0),o=i,l=0;l<t.length;l++){var s=t[l],a=Kn(s.from,i,o),u=Kn(Gn(s),i,o);if(i=s.to,o=u,"around"==r){var c=e.sel.ranges[l],f=E(c.head,c.anchor)<0;n[l]=new Ns(f?u:a,f?a:u)}else n[l]=new Ns(a,a)}return new Ms(n,e.sel.primIndex)}function Xn(e){e.doc.mode=Ve(e.options,e.doc.modeOption),Yn(e)}function Yn(e){e.doc.iter(function(e){e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null)}),
|
3
|
-
e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,Sn(e,100),e.state.modeGen++,e.curOp&&mn(e)}function _n(e,t){return 0==t.from.ch&&0==t.to.ch&&""==g(t.text)&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function $n(e,t,r,n){function i(e){return r?r[e]:null}function o(e,r,i){ot(e,r,i,n),wt(e,"change",e,t)}function l(e,t){for(var r=[],o=e;o<t;++o)r.push(new ds(u[o],i(o),n));return r}var s=t.from,a=t.to,u=t.text,c=M(e,s.line),f=M(e,a.line),h=g(u),d=i(u.length-1),p=a.line-s.line;if(t.full)e.insert(0,l(0,u.length)),e.remove(u.length,e.size-u.length);else if(_n(e,t)){var v=l(0,u.length-1);o(f,f.text,d),p&&e.remove(s.line,p),v.length&&e.insert(s.line,v)}else if(c==f)if(1==u.length)o(c,c.text.slice(0,s.ch)+h+c.text.slice(a.ch),d);else{var m=l(1,u.length-1);m.push(new ds(h+c.text.slice(a.ch),d,n)),o(c,c.text.slice(0,s.ch)+u[0],i(0)),e.insert(s.line+1,m)}else if(1==u.length)o(c,c.text.slice(0,s.ch)+u[0]+f.text.slice(a.ch),i(0)),e.remove(s.line+1,p);else{o(c,c.text.slice(0,s.ch)+u[0],i(0)),o(f,h+f.text.slice(a.ch),d);var y=l(1,u.length-1);p>1&&e.remove(s.line+1,p-1),e.insert(s.line+1,y)}wt(e,"change",e,t)}function qn(e,t,r){function n(e,i,o){if(e.linked)for(var l=0;l<e.linked.length;++l){var s=e.linked[l];if(s.doc!=i){var a=o&&s.sharedHist;r&&!a||(t(s.doc,a),n(s.doc,e,a))}}}n(e,null,!0)}function Zn(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,Sr(e),Xn(e),Qn(e),e.options.lineWrapping||we(e),e.options.mode=t.modeOption,mn(e)}function Qn(e){("rtl"==e.doc.direction?s:El)(e.display.lineDiv,"CodeMirror-rtl")}function Jn(e){dn(e,function(){Qn(e),mn(e)})}function ei(e){this.done=[],this.undone=[],this.undoDepth=1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e||1}function ti(e,t){var r={from:I(t.from),to:Gn(t),text:N(e,t.from,t.to)};return ai(e,r,t.from.line,t.to.line+1),qn(e,function(e){return ai(e,r,t.from.line,t.to.line+1)},!0),r}function ri(e){for(;e.length;){if(!g(e).ranges)break;e.pop()}}function ni(e,t){return t?(ri(e.done),g(e.done)):e.done.length&&!g(e.done).ranges?g(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),g(e.done)):void 0}function ii(e,t,r,n){var i=e.history;i.undone.length=0;var o,l,s=+new Date;if((i.lastOp==n||i.lastOrigin==t.origin&&t.origin&&("+"==t.origin.charAt(0)&&e.cm&&i.lastModTime>s-e.cm.options.historyEventDelay||"*"==t.origin.charAt(0)))&&(o=ni(i,i.lastOp==n)))l=g(o.changes),0==E(t.from,t.to)&&0==E(t.from,l.to)?l.to=Gn(t):o.changes.push(ti(e,t));else{var a=g(i.done);for(a&&a.ranges||si(e.sel,i.done),o={changes:[ti(e,t)],generation:i.generation},i.done.push(o);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(r),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=s,i.lastOp=i.lastSelOp=n,i.lastOrigin=i.lastSelOrigin=t.origin,l||Te(e,"historyAdded")}function oi(e,t,r,n){var i=t.charAt(0);return"*"==i||"+"==i&&r.ranges.length==n.ranges.length&&r.somethingSelected()==n.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function li(e,t,r,n){var i=e.history,o=n&&n.origin;r==i.lastSelOp||o&&i.lastSelOrigin==o&&(i.lastModTime==i.lastSelTime&&i.lastOrigin==o||oi(e,o,g(i.done),t))?i.done[i.done.length-1]=t:si(t,i.done),i.lastSelTime=+new Date,i.lastSelOrigin=o,i.lastSelOp=r,n&&!1!==n.clearRedo&&ri(i.undone)}function si(e,t){var r=g(t);r&&r.ranges&&r.equals(e)||t.push(e)}function ai(e,t,r,n){var i=t["spans_"+e.id],o=0;e.iter(Math.max(e.first,r),Math.min(e.first+e.size,n),function(r){r.markedSpans&&((i||(i=t["spans_"+e.id]={}))[o]=r.markedSpans),++o})}function ui(e){if(!e)return null;for(var t,r=0;r<e.length;++r)e[r].marker.explicitlyCleared?t||(t=e.slice(0,r)):t&&t.push(e[r]);return t?t.length?t:null:e}function ci(e,t){var r=t["spans_"+e.id];if(!r)return null;for(var n=[],i=0;i<t.text.length;++i)n.push(ui(r[i]));return n}function fi(e,t){var r=ci(e,t),n=J(e,t);if(!r)return n;if(!n)return r;for(var i=0;i<r.length;++i){var o=r[i],l=n[i];if(o&&l)e:for(var s=0;s<l.length;++s){for(var a=l[s],u=0;u<o.length;++u)if(o[u].marker==a.marker)continue e;o.push(a)}else l&&(r[i]=l)}return r}function hi(e,t,r){for(var n=[],i=0;i<e.length;++i){var o=e[i];if(o.ranges)n.push(r?Ms.prototype.deepCopy.call(o):o);else{var l=o.changes,s=[];n.push({changes:s});for(var a=0;a<l.length;++a){var u=l[a],c=void 0;if(s.push({from:u.from,to:u.to,text:u.text}),t)for(var f in u)(c=f.match(/^spans_(\d+)$/))&&h(t,Number(c[1]))>-1&&(g(s)[f]=u[f],delete u[f])}}}return n}function di(e,t,r,n){if(n){var i=e.anchor;if(r){var o=E(t,i)<0;o!=E(r,i)<0?(i=t,t=r):o!=E(t,r)<0&&(t=r)}return new Ns(i,t)}return new Ns(r||t,t)}function pi(e,t,r,n,i){null==i&&(i=e.cm&&(e.cm.display.shift||e.extend)),wi(e,new Ms([di(e.sel.primary(),t,r,i)],0),n)}function gi(e,t,r){for(var n=[],i=e.cm&&(e.cm.display.shift||e.extend),o=0;o<e.sel.ranges.length;o++)n[o]=di(e.sel.ranges[o],t[o],null,i);wi(e,Rn(n,e.sel.primIndex),r)}function vi(e,t,r,n){var i=e.sel.ranges.slice(0);i[t]=r,wi(e,Rn(i,e.sel.primIndex),n)}function mi(e,t,r,n){wi(e,Bn(t,r),n)}function yi(e,t,r){var n={ranges:t.ranges,update:function(t){var r=this;this.ranges=[];for(var n=0;n<t.length;n++)r.ranges[n]=new Ns(U(e,t[n].anchor),U(e,t[n].head))},origin:r&&r.origin};return Te(e,"beforeSelectionChange",e,n),e.cm&&Te(e.cm,"beforeSelectionChange",e.cm,n),n.ranges!=t.ranges?Rn(n.ranges,n.ranges.length-1):t}function bi(e,t,r){var n=e.history.done,i=g(n);i&&i.ranges?(n[n.length-1]=t,xi(e,t,r)):wi(e,t,r)}function wi(e,t,r){xi(e,t,r),li(e,e.sel,e.cm?e.cm.curOp.id:NaN,r)}function xi(e,t,r){(Oe(e,"beforeSelectionChange")||e.cm&&Oe(e.cm,"beforeSelectionChange"))&&(t=yi(e,t,r)),Ci(e,Li(e,t,r&&r.bias||(E(t.primary().head,e.sel.primary().head)<0?-1:1),!0)),r&&!1===r.scroll||!e.cm||Xr(e.cm)}function Ci(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=e.cm.curOp.selectionChanged=!0,Ne(e.cm)),wt(e,"cursorActivity",e))}function Si(e){Ci(e,Li(e,e.sel,null,!1))}function Li(e,t,r,n){for(var i,o=0;o<t.ranges.length;o++){var l=t.ranges[o],s=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[o],a=Ti(e,l.anchor,s&&s.anchor,r,n),u=Ti(e,l.head,s&&s.head,r,n);(i||a!=l.anchor||u!=l.head)&&(i||(i=t.ranges.slice(0,o)),i[o]=new Ns(a,u))}return i?Rn(i,t.primIndex):t}function ki(e,t,r,n,i){var o=M(e,t.line);if(o.markedSpans)for(var l=0;l<o.markedSpans.length;++l){var s=o.markedSpans[l],a=s.marker;if((null==s.from||(a.inclusiveLeft?s.from<=t.ch:s.from<t.ch))&&(null==s.to||(a.inclusiveRight?s.to>=t.ch:s.to>t.ch))){if(i&&(Te(a,"beforeCursorEnter"),a.explicitlyCleared)){if(o.markedSpans){--l;continue}break}if(!a.atomic)continue;if(r){var u=a.find(n<0?1:-1),c=void 0;if((n<0?a.inclusiveRight:a.inclusiveLeft)&&(u=Mi(e,u,-n,u&&u.line==t.line?o:null)),u&&u.line==t.line&&(c=E(u,r))&&(n<0?c<0:c>0))return ki(e,u,t,n,i)}var f=a.find(n<0?-1:1);return(n<0?a.inclusiveLeft:a.inclusiveRight)&&(f=Mi(e,f,n,f.line==t.line?o:null)),f?ki(e,f,t,n,i):null}}return t}function Ti(e,t,r,n,i){var o=n||1,l=ki(e,t,r,o,i)||!i&&ki(e,t,r,o,!0)||ki(e,t,r,-o,i)||!i&&ki(e,t,r,-o,!0);return l||(e.cantEdit=!0,P(e.first,0))}function Mi(e,t,r,n){return r<0&&0==t.ch?t.line>e.first?U(e,P(t.line-1)):null:r>0&&t.ch==(n||M(e,t.line)).text.length?t.line<e.first+e.size-1?P(t.line+1,0):null:new P(t.line,t.ch+r)}function Ni(e){e.setSelection(P(e.firstLine(),0),P(e.lastLine()),Vl)}function Oi(e,t,r){var n={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return n.canceled=!0}};return r&&(n.update=function(t,r,i,o){t&&(n.from=U(e,t)),r&&(n.to=U(e,r)),i&&(n.text=i),void 0!==o&&(n.origin=o)}),Te(e,"beforeChange",e,n),e.cm&&Te(e.cm,"beforeChange",e.cm,n),n.canceled?null:{from:n.from,to:n.to,text:n.text,origin:n.origin}}function Ai(e,t,r){if(e.cm){if(!e.cm.curOp)return pn(e.cm,Ai)(e,t,r);if(e.cm.state.suppressEdits)return}if(!(Oe(e,"beforeChange")||e.cm&&Oe(e.cm,"beforeChange"))||(t=Oi(e,t,!0))){var n=$l&&!r&&te(e,t.from,t.to);if(n)for(var i=n.length-1;i>=0;--i)Wi(e,{from:n[i].from,to:n[i].to,text:i?[""]:t.text,origin:t.origin});else Wi(e,t)}}function Wi(e,t){if(1!=t.text.length||""!=t.text[0]||0!=E(t.from,t.to)){var r=Vn(e,t);ii(e,t,r,e.cm?e.cm.curOp.id:NaN),Fi(e,t,r,J(e,t));var n=[];qn(e,function(e,r){r||-1!=h(n,e.history)||(Ri(e.history,t),n.push(e.history)),Fi(e,t,null,J(e,t))})}}function Di(e,t,r){if(!e.cm||!e.cm.state.suppressEdits||r){for(var n,i=e.history,o=e.sel,l="undo"==t?i.done:i.undone,s="undo"==t?i.undone:i.done,a=0;a<l.length&&(n=l[a],r?!n.ranges||n.equals(e.sel):n.ranges);a++);if(a!=l.length){for(i.lastOrigin=i.lastSelOrigin=null;n=l.pop(),n.ranges;){if(si(n,s),r&&!n.equals(e.sel))return void wi(e,n,{clearRedo:!1});o=n}var u=[];si(o,s),s.push({changes:u,generation:i.generation}),i.generation=n.generation||++i.maxGeneration;for(var c=Oe(e,"beforeChange")||e.cm&&Oe(e.cm,"beforeChange"),f=n.changes.length-1;f>=0;--f){var d=function(r){var i=n.changes[r];if(i.origin=t,c&&!Oi(e,i,!1))return l.length=0,{};u.push(ti(e,i));var o=r?Vn(e,i):g(l);Fi(e,i,o,fi(e,i)),!r&&e.cm&&e.cm.scrollIntoView({from:i.from,to:Gn(i)});var s=[];qn(e,function(e,t){t||-1!=h(s,e.history)||(Ri(e.history,i),s.push(e.history)),Fi(e,i,null,fi(e,i))})}(f);if(d)return d.v}}}}function Hi(e,t){if(0!=t&&(e.first+=t,e.sel=new Ms(v(e.sel.ranges,function(e){return new Ns(P(e.anchor.line+t,e.anchor.ch),P(e.head.line+t,e.head.ch))}),e.sel.primIndex),e.cm)){mn(e.cm,e.first,e.first-t,t);for(var r=e.cm.display,n=r.viewFrom;n<r.viewTo;n++)yn(e.cm,n,"gutter")}}function Fi(e,t,r,n){if(e.cm&&!e.cm.curOp)return pn(e.cm,Fi)(e,t,r,n);if(t.to.line<e.first)return void Hi(e,t.text.length-1-(t.to.line-t.from.line));if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var i=t.text.length-1-(e.first-t.from.line);Hi(e,i),t={from:P(e.first,0),to:P(t.to.line+i,t.to.ch),text:[g(t.text)],origin:t.origin}}var o=e.lastLine();t.to.line>o&&(t={from:t.from,to:P(o,M(e,o).text.length),text:[t.text[0]],origin:t.origin}),t.removed=N(e,t.from,t.to),r||(r=Vn(e,t)),e.cm?Pi(e.cm,t,n):$n(e,t,n),xi(e,r,Vl)}}function Pi(e,t,r){var n=e.doc,i=e.display,o=t.from,l=t.to,s=!1,a=o.line;e.options.lineWrapping||(a=W(fe(M(n,o.line))),n.iter(a,l.line+1,function(e){if(e==i.maxLine)return s=!0,!0})),n.sel.contains(t.from,t.to)>-1&&Ne(e),$n(n,t,r,Cr(e)),e.options.lineWrapping||(n.iter(a,o.line+t.text.length,function(e){var t=be(e);t>i.maxLineLength&&(i.maxLine=e,i.maxLineLength=t,i.maxLineChanged=!0,s=!1)}),s&&(e.curOp.updateMaxLine=!0)),it(n,o.line),Sn(e,400);var u=t.text.length-(l.line-o.line)-1;t.full?mn(e):o.line!=l.line||1!=t.text.length||_n(e.doc,t)?mn(e,o.line,l.line+1,u):yn(e,o.line,"text");var c=Oe(e,"changes"),f=Oe(e,"change");if(f||c){var h={from:o,to:l,text:t.text,removed:t.removed,origin:t.origin};f&&wt(e,"change",e,h),c&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(h)}e.display.selForContextMenu=null}function Ei(e,t,r,n,i){if(n||(n=r),E(n,r)<0){var o;o=[n,r],r=o[0],n=o[1]}"string"==typeof t&&(t=e.splitLines(t)),Ai(e,{from:r,to:n,text:t,origin:i})}function zi(e,t,r,n){r<e.line?e.line+=n:t<e.line&&(e.line=t,e.ch=0)}function Ii(e,t,r,n){for(var i=0;i<e.length;++i){var o=e[i],l=!0;if(o.ranges){o.copied||(o=e[i]=o.deepCopy(),o.copied=!0);for(var s=0;s<o.ranges.length;s++)zi(o.ranges[s].anchor,t,r,n),zi(o.ranges[s].head,t,r,n)}else{for(var a=0;a<o.changes.length;++a){var u=o.changes[a];if(r<u.from.line)u.from=P(u.from.line+n,u.from.ch),u.to=P(u.to.line+n,u.to.ch);else if(t<=u.to.line){l=!1;break}}l||(e.splice(0,i+1),i=0)}}}function Ri(e,t){var r=t.from.line,n=t.to.line,i=t.text.length-(n-r)-1;Ii(e.done,r,n,i),Ii(e.undone,r,n,i)}function Bi(e,t,r,n){var i=t,o=t;return"number"==typeof t?o=M(e,G(e,t)):i=W(t),null==i?null:(n(o,i)&&e.cm&&yn(e.cm,i,r),o)}function Gi(e){var t=this;this.lines=e,this.parent=null;for(var r=0,n=0;n<e.length;++n)e[n].parent=t,r+=e[n].height;this.height=r}function Ui(e){var t=this;this.children=e;for(var r=0,n=0,i=0;i<e.length;++i){var o=e[i];r+=o.chunkSize(),n+=o.height,o.parent=t}this.size=r,this.height=n,this.parent=null}function Vi(e,t,r){ye(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&jr(e,r)}function Ki(e,t,r,n){var i=new Os(e,r,n),o=e.cm;return o&&i.noHScroll&&(o.display.alignWidgets=!0),Bi(e,t,"widget",function(t){var r=t.widgets||(t.widgets=[]);if(null==i.insertAt?r.push(i):r.splice(Math.min(r.length-1,Math.max(0,i.insertAt)),0,i),i.line=t,o&&!ve(e,t)){var n=ye(t)<e.scrollTop;A(t,t.height+Ft(i)),n&&jr(o,i.height),o.curOp.forceUpdate=!0}return!0}),wt(o,"lineWidgetAdded",o,i,"number"==typeof t?t:W(t)),i}function ji(e,t,r,n,o){if(n&&n.shared)return Xi(e,t,r,n,o);if(e.cm&&!e.cm.curOp)return pn(e.cm,ji)(e,t,r,n,o);var l=new Ws(e,o),s=E(t,r);if(n&&c(n,l,!1),s>0||0==s&&!1!==l.clearWhenEmpty)return l;if(l.replacedWith&&(l.collapsed=!0,l.widgetNode=i("span",[l.replacedWith],"CodeMirror-widget"),n.handleMouseEvents||l.widgetNode.setAttribute("cm-ignore-events","true"),n.insertLeft&&(l.widgetNode.insertLeft=!0)),l.collapsed){if(ce(e,t.line,t,r,l)||t.line!=r.line&&ce(e,r.line,t,r,l))throw new Error("Inserting collapsed marker partially overlapping an existing one");X()}l.addToHistory&&ii(e,{from:t,to:r,origin:"markText"},e.sel,NaN);var a,u=t.line,f=e.cm;if(e.iter(u,r.line+1,function(e){f&&l.collapsed&&!f.options.lineWrapping&&fe(e)==f.display.maxLine&&(a=!0),l.collapsed&&u!=t.line&&A(e,0),q(e,new Y(l,u==t.line?t.ch:null,u==r.line?r.ch:null)),++u}),l.collapsed&&e.iter(t.line,r.line+1,function(t){ve(e,t)&&A(t,0)}),l.clearOnEnter&&es(l,"beforeCursorEnter",function(){return l.clear()}),l.readOnly&&(j(),(e.history.done.length||e.history.undone.length)&&e.clearHistory()),l.collapsed&&(l.id=++As,l.atomic=!0),f){if(a&&(f.curOp.updateMaxLine=!0),l.collapsed)mn(f,t.line,r.line+1);else if(l.className||l.title||l.startStyle||l.endStyle||l.css)for(var h=t.line;h<=r.line;h++)yn(f,h,"text");l.atomic&&Si(f.doc),wt(f,"markerAdded",f,l)}return l}function Xi(e,t,r,n,i){n=c(n),n.shared=!1;var o=[ji(e,t,r,n,i)],l=o[0],s=n.widgetNode;return qn(e,function(e){s&&(n.widgetNode=s.cloneNode(!0)),o.push(ji(e,U(e,t),U(e,r),n,i));for(var a=0;a<e.linked.length;++a)if(e.linked[a].isParent)return;l=g(o)}),new Ds(o,l)}function Yi(e){return e.findMarks(P(e.first,0),e.clipPos(P(e.lastLine())),function(e){return e.parent})}function _i(e,t){for(var r=0;r<t.length;r++){var n=t[r],i=n.find(),o=e.clipPos(i.from),l=e.clipPos(i.to);if(E(o,l)){var s=ji(e,o,l,n.primary,n.primary.type);n.markers.push(s),s.parent=n}}}function $i(e){for(var t=0;t<e.length;t++)!function(t){var r=e[t],n=[r.primary.doc];qn(r.primary.doc,function(e){return n.push(e)});for(var i=0;i<r.markers.length;i++){var o=r.markers[i];-1==h(n,o.doc)&&(o.parent=null,r.markers.splice(i--,1))}}(t)}function qi(e){var t=this;if(Ji(t),!Me(t,e)&&!Pt(t.display,e)){We(e),ml&&(Ps=+new Date);var r=Lr(t,e,!0),n=e.dataTransfer.files;if(r&&!t.isReadOnly())if(n&&n.length&&window.FileReader&&window.File)for(var i=n.length,o=Array(i),l=0,s=0;s<i;++s)!function(e,n){if(!t.options.allowDropFileTypes||-1!=h(t.options.allowDropFileTypes,e.type)){var s=new FileReader;s.onload=pn(t,function(){var e=s.result;if(/[\x00-\x08\x0e-\x1f]{2}/.test(e)&&(e=""),o[n]=e,++l==i){r=U(t.doc,r);var a={from:r,to:r,text:t.doc.splitLines(o.join(t.doc.lineSeparator())),origin:"paste"};Ai(t.doc,a),bi(t.doc,Bn(r,Gn(a)))}}),s.readAsText(e)}}(n[s],s);else{if(t.state.draggingText&&t.doc.sel.contains(r)>-1)return t.state.draggingText(e),void setTimeout(function(){return t.display.input.focus()},20);try{var a=e.dataTransfer.getData("Text");if(a){var u;if(t.state.draggingText&&!t.state.draggingText.copy&&(u=t.listSelections()),xi(t.doc,Bn(r,r)),u)for(var c=0;c<u.length;++c)Ei(t.doc,"",u[c].anchor,u[c].head,"drag");t.replaceSelection(a,"around","paste"),t.display.input.focus()}}catch(e){}}}}function Zi(e,t){if(ml&&(!e.state.draggingText||+new Date-Ps<100))return void Fe(t);if(!Me(e,t)&&!Pt(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!Sl)){var r=n("img",null,null,"position: fixed; left: 0; top: 0;");r.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",Cl&&(r.width=r.height=1,e.display.wrapper.appendChild(r),r._top=r.offsetTop),t.dataTransfer.setDragImage(r,0,0),Cl&&r.parentNode.removeChild(r)}}function Qi(e,t){var i=Lr(e,t);if(i){var o=document.createDocumentFragment();Nr(e,i,o),e.display.dragCursor||(e.display.dragCursor=n("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),r(e.display.dragCursor,o)}}function Ji(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function eo(e){if(document.getElementsByClassName)for(var t=document.getElementsByClassName("CodeMirror"),r=0;r<t.length;r++){var n=t[r].CodeMirror;n&&e(n)}}function to(){Es||(ro(),Es=!0)}function ro(){var e;es(window,"resize",function(){null==e&&(e=setTimeout(function(){e=null,eo(no)},100))}),es(window,"blur",function(){return eo(Pr)})}function no(e){var t=e.display;t.lastWrapHeight==t.wrapper.clientHeight&&t.lastWrapWidth==t.wrapper.clientWidth||(t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize())}function io(e){var t=e.split(/-(?!$)/);e=t[t.length-1];for(var r,n,i,o,l=0;l<t.length-1;l++){var s=t[l];if(/^(cmd|meta|m)$/i.test(s))o=!0;else if(/^a(lt)?$/i.test(s))r=!0;else if(/^(c|ctrl|control)$/i.test(s))n=!0;else{if(!/^s(hift)?$/i.test(s))throw new Error("Unrecognized modifier name: "+s);i=!0}}return r&&(e="Alt-"+e),n&&(e="Ctrl-"+e),o&&(e="Cmd-"+e),i&&(e="Shift-"+e),e}function oo(e){var t={};for(var r in e)if(e.hasOwnProperty(r)){var n=e[r];if(/^(name|fallthrough|(de|at)tach)$/.test(r))continue;if("..."==n){delete e[r];continue}for(var i=v(r.split(" "),io),o=0;o<i.length;o++){var l=void 0,s=void 0;o==i.length-1?(s=i.join(" "),l=n):(s=i.slice(0,o+1).join(" "),l="...");var a=t[s];if(a){if(a!=l)throw new Error("Inconsistent bindings for "+s)}else t[s]=l}delete e[r]}for(var u in t)e[u]=t[u];return e}function lo(e,t,r,n){t=co(t);var i=t.call?t.call(e,n):t[e];if(!1===i)return"nothing";if("..."===i)return"multi";if(null!=i&&r(i))return"handled";if(t.fallthrough){if("[object Array]"!=Object.prototype.toString.call(t.fallthrough))return lo(e,t.fallthrough,r,n);for(var o=0;o<t.fallthrough.length;o++){var l=lo(e,t.fallthrough[o],r,n);if(l)return l}}}function so(e){var t="string"==typeof e?e:zs[e.keyCode];return"Ctrl"==t||"Alt"==t||"Shift"==t||"Mod"==t}function ao(e,t,r){var n=e;return t.altKey&&"Alt"!=n&&(e="Alt-"+e),(Fl?t.metaKey:t.ctrlKey)&&"Ctrl"!=n&&(e="Ctrl-"+e),(Fl?t.ctrlKey:t.metaKey)&&"Cmd"!=n&&(e="Cmd-"+e),!r&&t.shiftKey&&"Shift"!=n&&(e="Shift-"+e),e}function uo(e,t){if(Cl&&34==e.keyCode&&e.char)return!1;var r=zs[e.keyCode];return null!=r&&!e.altGraphKey&&ao(r,e,t)}function co(e){return"string"==typeof e?Gs[e]:e}function fo(e,t){for(var r=e.doc.sel.ranges,n=[],i=0;i<r.length;i++){for(var o=t(r[i]);n.length&&E(o.from,g(n).to)<=0;){var l=n.pop();if(E(l.from,o.from)<0){o.from=l.from;break}}n.push(o)}dn(e,function(){for(var t=n.length-1;t>=0;t--)Ei(e.doc,"",n[t].from,n[t].to,"+delete");Xr(e)})}function ho(e,t,r){var n=L(e.text,t+r,r);return n<0||n>e.text.length?null:n}function po(e,t,r){var n=ho(e,t.ch,r);return null==n?null:new P(t.line,n,r<0?"after":"before")}function go(e,t,r,n,i){if(e){var o=Se(r,t.doc.direction);if(o){var l,s=i<0?g(o):o[0],a=i<0==(1==s.level),u=a?"after":"before";if(s.level>0||"rtl"==t.doc.direction){var c=Yt(t,r);l=i<0?r.text.length-1:0;var f=_t(t,c,l).top;l=k(function(e){return _t(t,c,e).top==f},i<0==(1==s.level)?s.from:s.to-1,l),"before"==u&&(l=ho(r,l,1))}else l=i<0?s.to:s.from;return new P(n,l,u)}}return new P(n,i<0?r.text.length:0,i<0?"before":"after")}function vo(e,t,r,n){var i=Se(t,e.doc.direction);if(!i)return po(t,r,n);r.ch>=t.text.length?(r.ch=t.text.length,r.sticky="before"):r.ch<=0&&(r.ch=0,r.sticky="after");var o=Ce(i,r.ch,r.sticky),l=i[o];if("ltr"==e.doc.direction&&l.level%2==0&&(n>0?l.to>r.ch:l.from<r.ch))return po(t,r,n);var s,a=function(e,r){return ho(t,e instanceof P?e.ch:e,r)},u=function(r){return e.options.lineWrapping?(s=s||Yt(e,t),dr(e,t,s,r)):{begin:0,end:t.text.length}},c=u("before"==r.sticky?a(r,-1):r.ch);if("rtl"==e.doc.direction||1==l.level){var f=1==l.level==n<0,h=a(r,f?1:-1);if(null!=h&&(f?h<=l.to&&h<=c.end:h>=l.from&&h>=c.begin)){var d=f?"before":"after";return new P(r.line,h,d)}}var p=function(e,t,n){for(var o=function(e,t){return t?new P(r.line,a(e,1),"before"):new P(r.line,e,"after")};e>=0&&e<i.length;e+=t){var l=i[e],s=t>0==(1!=l.level),u=s?n.begin:a(n.end,-1);if(l.from<=u&&u<l.to)return o(u,s);if(u=s?l.from:a(l.to,-1),n.begin<=u&&u<n.end)return o(u,s)}},g=p(o+n,n,c);if(g)return g;var v=n>0?c.end:a(c.begin,-1);return null==v||n>0&&v==t.text.length||!(g=p(n>0?0:i.length-1,n,u(v)))?null:g}function mo(e,t){var r=M(e.doc,t),n=fe(r);return n!=r&&(t=W(n)),go(!0,e,n,t,1)}function yo(e,t){var r=M(e.doc,t),n=he(r);return n!=r&&(t=W(n)),go(!0,e,r,t,-1)}function bo(e,t){var r=mo(e,t.line),n=M(e.doc,r.line),i=Se(n,e.doc.direction);if(!i||0==i[0].level){var o=Math.max(0,n.text.search(/\S/)),l=t.line==r.line&&t.ch<=o&&t.ch;return P(r.line,l?0:o,r.sticky)}return r}function wo(e,t,r){if("string"==typeof t&&!(t=Us[t]))return!1;e.display.input.ensurePolled();var n=e.display.shift,i=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),r&&(e.display.shift=!1),i=t(e)!=Ul}finally{e.display.shift=n,e.state.suppressEdits=!1}return i}function xo(e,t,r){for(var n=0;n<e.state.keyMaps.length;n++){var i=lo(t,e.state.keyMaps[n],r,e);if(i)return i}return e.options.extraKeys&&lo(t,e.options.extraKeys,r,e)||lo(t,e.options.keyMap,r,e)}function Co(e,t,r,n){var i=e.state.keySeq;if(i){if(so(t))return"handled";Vs.set(50,function(){e.state.keySeq==i&&(e.state.keySeq=null,e.display.input.reset())}),t=i+" "+t}var o=xo(e,t,n);return"multi"==o&&(e.state.keySeq=t),"handled"==o&&wt(e,"keyHandled",e,t,r),"handled"!=o&&"multi"!=o||(We(r),Wr(e)),i&&!o&&/\'$/.test(t)?(We(r),!0):!!o}function So(e,t){var r=uo(t,!0);return!!r&&(t.shiftKey&&!e.state.keySeq?Co(e,"Shift-"+r,t,function(t){return wo(e,t,!0)})||Co(e,r,t,function(t){if("string"==typeof t?/^go[A-Z]/.test(t):t.motion)return wo(e,t)}):Co(e,r,t,function(t){return wo(e,t)}))}function Lo(e,t,r){return Co(e,"'"+r+"'",t,function(t){return wo(e,t,!0)})}function ko(e){var t=this;if(t.curOp.focus=l(),!Me(t,e)){ml&&yl<11&&27==e.keyCode&&(e.returnValue=!1);var r=e.keyCode;t.display.shift=16==r||e.shiftKey;var n=So(t,e);Cl&&(Ks=n?r:null,!n&&88==r&&!is&&(Ol?e.metaKey:e.ctrlKey)&&t.replaceSelection("",null,"cut")),18!=r||/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)||To(t)}}function To(e){function t(e){18!=e.keyCode&&e.altKey||(El(r,"CodeMirror-crosshair"),ke(document,"keyup",t),ke(document,"mouseover",t))}var r=e.display.lineDiv;s(r,"CodeMirror-crosshair"),es(document,"keyup",t),es(document,"mouseover",t)}function Mo(e){16==e.keyCode&&(this.doc.sel.shift=!1),Me(this,e)}function No(e){var t=this;if(!(Pt(t.display,e)||Me(t,e)||e.ctrlKey&&!e.altKey||Ol&&e.metaKey)){var r=e.keyCode,n=e.charCode;if(Cl&&r==Ks)return Ks=null,void We(e);if(!Cl||e.which&&!(e.which<10)||!So(t,e)){var i=String.fromCharCode(null==n?r:n);"\b"!=i&&(Lo(t,e,i)||t.display.input.onKeyPress(e))}}}function Oo(e,t){var r=+new Date;return Ys&&Ys.compare(r,e,t)?(Xs=Ys=null,"triple"):Xs&&Xs.compare(r,e,t)?(Ys=new js(r,e,t),Xs=null,"double"):(Xs=new js(r,e,t),Ys=null,"single")}function Ao(e){var t=this,r=t.display;if(!(Me(t,e)||r.activeTouch&&r.input.supportsTouch())){if(r.input.ensurePolled(),r.shift=e.shiftKey,Pt(r,e))return void(bl||(r.scroller.draggable=!1,setTimeout(function(){return r.scroller.draggable=!0},100)));if(!Ro(t,e)){var n=Lr(t,e),i=Ee(e),o=n?Oo(n,i):"single";window.focus(),1==i&&t.state.selectingText&&t.state.selectingText(e),n&&Wo(t,i,n,o,e)||(1==i?n?Ho(t,n,o,e):Pe(e)==r.scroller&&We(e):2==i?(n&&pi(t.doc,n),setTimeout(function(){return r.input.focus()},20)):3==i&&(Pl?Bo(t,e):Hr(t)))}}}function Wo(e,t,r,n,i){var o="Click";return"double"==n?o="Double"+o:"triple"==n&&(o="Triple"+o),o=(1==t?"Left":2==t?"Middle":"Right")+o,Co(e,ao(o,i),i,function(t){if("string"==typeof t&&(t=Us[t]),!t)return!1;var n=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),n=t(e,r)!=Ul}finally{e.state.suppressEdits=!1}return n})}function Do(e,t,r){var n=e.getOption("configureMouse"),i=n?n(e,t,r):{};if(null==i.unit){var o=Al?r.shiftKey&&r.metaKey:r.altKey;i.unit=o?"rectangle":"single"==t?"char":"double"==t?"word":"line"}return(null==i.extend||e.doc.extend)&&(i.extend=e.doc.extend||r.shiftKey),null==i.addNew&&(i.addNew=Ol?r.metaKey:r.ctrlKey),null==i.moveOnDrag&&(i.moveOnDrag=!(Ol?r.altKey:r.ctrlKey)),i}function Ho(e,t,r,n){ml?setTimeout(u(Dr,e),0):e.curOp.focus=l();var i,o=Do(e,r,n),s=e.doc.sel;e.options.dragDrop&&ts&&!e.isReadOnly()&&"single"==r&&(i=s.contains(t))>-1&&(E((i=s.ranges[i]).from(),t)<0||t.xRel>0)&&(E(i.to(),t)>0||t.xRel<0)?Fo(e,n,t,o):Eo(e,n,t,o)}function Fo(e,t,r,n){var i=e.display,o=!1,l=pn(e,function(t){bl&&(i.scroller.draggable=!1),e.state.draggingText=!1,ke(document,"mouseup",l),ke(document,"mousemove",s),ke(i.scroller,"dragstart",a),ke(i.scroller,"drop",l),o||(We(t),n.addNew||pi(e.doc,r,null,null,n.extend),bl||ml&&9==yl?setTimeout(function(){document.body.focus(),i.input.focus()},20):i.input.focus())}),s=function(e){o=o||Math.abs(t.clientX-e.clientX)+Math.abs(t.clientY-e.clientY)>=10},a=function(){return o=!0};bl&&(i.scroller.draggable=!0),e.state.draggingText=l,l.copy=!n.moveOnDrag,i.scroller.dragDrop&&i.scroller.dragDrop(),es(document,"mouseup",l),es(document,"mousemove",s),es(i.scroller,"dragstart",a),es(i.scroller,"drop",l),Hr(e),setTimeout(function(){return i.input.focus()},20)}function Po(e,t,r){if("char"==r)return new Ns(t,t);if("word"==r)return e.findWordAt(t);if("line"==r)return new Ns(P(t.line,0),U(e.doc,P(t.line+1,0)));var n=r(e,t);return new Ns(n.from,n.to)}function Eo(e,t,r,n){function i(t){if(0!=E(m,t))if(m=t,"rectangle"==n.unit){for(var i=[],o=e.options.tabSize,l=f(M(u,r.line).text,r.ch,o),s=f(M(u,t.line).text,t.ch,o),a=Math.min(l,s),g=Math.max(l,s),v=Math.min(r.line,t.line),y=Math.min(e.lastLine(),Math.max(r.line,t.line));v<=y;v++){var b=M(u,v).text,w=d(b,a,o);a==g?i.push(new Ns(P(v,w),P(v,w))):b.length>w&&i.push(new Ns(P(v,w),P(v,d(b,g,o))))}i.length||i.push(new Ns(r,r)),wi(u,Rn(p.ranges.slice(0,h).concat(i),h),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var x,C=c,S=Po(e,t,n.unit),L=C.anchor;E(S.anchor,L)>0?(x=S.head,L=B(C.from(),S.anchor)):(x=S.anchor,L=R(C.to(),S.head));var k=p.ranges.slice(0);k[h]=zo(e,new Ns(U(u,L),x)),wi(u,Rn(k,h),Kl)}}function o(t){var r=++b,s=Lr(e,t,!0,"rectangle"==n.unit);if(s)if(0!=E(s,m)){e.curOp.focus=l(),i(s);var c=Ir(a,u);(s.line>=c.to||s.line<c.from)&&setTimeout(pn(e,function(){b==r&&o(t)}),150)}else{var f=t.clientY<y.top?-20:t.clientY>y.bottom?20:0;f&&setTimeout(pn(e,function(){b==r&&(a.scroller.scrollTop+=f,o(t))}),50)}}function s(t){e.state.selectingText=!1,b=1/0,We(t),a.input.focus(),ke(document,"mousemove",w),ke(document,"mouseup",x),u.history.lastSelOrigin=null}var a=e.display,u=e.doc;We(t);var c,h,p=u.sel,g=p.ranges;if(n.addNew&&!n.extend?(h=u.sel.contains(r),c=h>-1?g[h]:new Ns(r,r)):(c=u.sel.primary(),h=u.sel.primIndex),"rectangle"==n.unit)n.addNew||(c=new Ns(r,r)),r=Lr(e,t,!0,!0),h=-1;else{var v=Po(e,r,n.unit);c=n.extend?di(c,v.anchor,v.head,n.extend):v}n.addNew?-1==h?(h=g.length,wi(u,Rn(g.concat([c]),h),{scroll:!1,origin:"*mouse"})):g.length>1&&g[h].empty()&&"char"==n.unit&&!n.extend?(wi(u,Rn(g.slice(0,h).concat(g.slice(h+1)),0),{scroll:!1,origin:"*mouse"}),p=u.sel):vi(u,h,c,Kl):(h=0,wi(u,new Ms([c],0),Kl),p=u.sel);var m=r,y=a.wrapper.getBoundingClientRect(),b=0,w=pn(e,function(e){Ee(e)?o(e):s(e)}),x=pn(e,s);e.state.selectingText=x,es(document,"mousemove",w),es(document,"mouseup",x)}function zo(e,t){var r=t.anchor,n=t.head,i=M(e.doc,r.line);if(0==E(r,n)&&r.sticky==n.sticky)return t;var o=Se(i);if(!o)return t;var l=Ce(o,r.ch,r.sticky),s=o[l];if(s.from!=r.ch&&s.to!=r.ch)return t;var a=l+(s.from==r.ch==(1!=s.level)?0:1);if(0==a||a==o.length)return t;var u;if(n.line!=r.line)u=(n.line-r.line)*("ltr"==e.doc.direction?1:-1)>0;else{var c=Ce(o,n.ch,n.sticky),f=c-l||(n.ch-r.ch)*(1==s.level?-1:1);u=c==a-1||c==a?f<0:f>0}var h=o[a+(u?-1:0)],d=u==(1==h.level),p=d?h.from:h.to,g=d?"after":"before";return r.ch==p&&r.sticky==g?t:new Ns(new P(r.line,p,g),n)}function Io(e,t,r,n){var i,o;if(t.touches)i=t.touches[0].clientX,o=t.touches[0].clientY;else try{i=t.clientX,o=t.clientY}catch(t){return!1}if(i>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;n&&We(t);var l=e.display,s=l.lineDiv.getBoundingClientRect();if(o>s.bottom||!Oe(e,r))return He(t);o-=s.top-l.viewOffset;for(var a=0;a<e.options.gutters.length;++a){var u=l.gutters.childNodes[a];if(u&&u.getBoundingClientRect().right>=i){return Te(e,r,e,D(e.doc,o),e.options.gutters[a],t),He(t)}}}function Ro(e,t){return Io(e,t,"gutterClick",!0)}function Bo(e,t){Pt(e.display,t)||Go(e,t)||Me(e,t,"contextmenu")||e.display.input.onContextMenu(t)}function Go(e,t){return!!Oe(e,"gutterContextMenu")&&Io(e,t,"gutterContextMenu",!1)}function Uo(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),tr(e)}function Vo(e){Fn(e),mn(e),Rr(e)}function Ko(e,t,r){if(!t!=!(r&&r!=_s)){var n=e.display.dragFunctions,i=t?es:ke;i(e.display.scroller,"dragstart",n.start),i(e.display.scroller,"dragenter",n.enter),i(e.display.scroller,"dragover",n.over),i(e.display.scroller,"dragleave",n.leave),i(e.display.scroller,"drop",n.drop)}}function jo(e){e.options.lineWrapping?(s(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(El(e.display.wrapper,"CodeMirror-wrap"),we(e)),Sr(e),mn(e),tr(e),setTimeout(function(){return tn(e)},100)}function Xo(e,t){var r=this;if(!(this instanceof Xo))return new Xo(e,t);this.options=t=t?c(t):{},c($s,t,!1),Pn(t);var n=t.value;"string"==typeof n&&(n=new Fs(n,t.mode,null,t.lineSeparator,t.direction)),this.doc=n;var i=new Xo.inputStyles[t.inputStyle](this),o=this.display=new T(e,n,i);o.wrapper.CodeMirror=this,Fn(this),Uo(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),nn(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:!1,cutIncoming:!1,selectingText:!1,draggingText:!1,highlight:new Il,keySeq:null,specialChars:null},t.autofocus&&!Nl&&o.input.focus(),ml&&yl<11&&setTimeout(function(){return r.display.input.reset(!0)},20),Yo(this),to(),on(this),this.curOp.forceUpdate=!0,Zn(this,n),t.autofocus&&!Nl||this.hasFocus()?setTimeout(u(Fr,this),20):Pr(this);for(var l in qs)qs.hasOwnProperty(l)&&qs[l](r,t[l],_s);Br(this),t.finishInit&&t.finishInit(this);for(var s=0;s<Zs.length;++s)Zs[s](r);ln(this),bl&&t.lineWrapping&&"optimizelegibility"==getComputedStyle(o.lineDiv).textRendering&&(o.lineDiv.style.textRendering="auto")}function Yo(e){function t(){i.activeTouch&&(o=setTimeout(function(){return i.activeTouch=null},1e3),l=i.activeTouch,l.end=+new Date)}function r(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}function n(e,t){if(null==t.left)return!0;var r=t.left-e.left,n=t.top-e.top;return r*r+n*n>400}var i=e.display;es(i.scroller,"mousedown",pn(e,Ao)),ml&&yl<11?es(i.scroller,"dblclick",pn(e,function(t){if(!Me(e,t)){var r=Lr(e,t);if(r&&!Ro(e,t)&&!Pt(e.display,t)){We(t);var n=e.findWordAt(r);pi(e.doc,n.anchor,n.head)}}})):es(i.scroller,"dblclick",function(t){return Me(e,t)||We(t)}),Pl||es(i.scroller,"contextmenu",function(t){return Bo(e,t)});var o,l={end:0};es(i.scroller,"touchstart",function(t){if(!Me(e,t)&&!r(t)&&!Ro(e,t)){i.input.ensurePolled(),clearTimeout(o);var n=+new Date;i.activeTouch={start:n,moved:!1,prev:n-l.end<=300?l:null},1==t.touches.length&&(i.activeTouch.left=t.touches[0].pageX,i.activeTouch.top=t.touches[0].pageY)}}),es(i.scroller,"touchmove",function(){i.activeTouch&&(i.activeTouch.moved=!0)}),
|
4
|
-
es(i.scroller,"touchend",function(r){var o=i.activeTouch;if(o&&!Pt(i,r)&&null!=o.left&&!o.moved&&new Date-o.start<300){var l,s=e.coordsChar(i.activeTouch,"page");l=!o.prev||n(o,o.prev)?new Ns(s,s):!o.prev.prev||n(o,o.prev.prev)?e.findWordAt(s):new Ns(P(s.line,0),U(e.doc,P(s.line+1,0))),e.setSelection(l.anchor,l.head),e.focus(),We(r)}t()}),es(i.scroller,"touchcancel",t),es(i.scroller,"scroll",function(){i.scroller.clientHeight&&(Zr(e,i.scroller.scrollTop),Jr(e,i.scroller.scrollLeft,!0),Te(e,"scroll",e))}),es(i.scroller,"mousewheel",function(t){return In(e,t)}),es(i.scroller,"DOMMouseScroll",function(t){return In(e,t)}),es(i.wrapper,"scroll",function(){return i.wrapper.scrollTop=i.wrapper.scrollLeft=0}),i.dragFunctions={enter:function(t){Me(e,t)||Fe(t)},over:function(t){Me(e,t)||(Qi(e,t),Fe(t))},start:function(t){return Zi(e,t)},drop:pn(e,qi),leave:function(t){Me(e,t)||Ji(e)}};var s=i.input.getField();es(s,"keyup",function(t){return Mo.call(e,t)}),es(s,"keydown",pn(e,ko)),es(s,"keypress",pn(e,No)),es(s,"focus",function(t){return Fr(e,t)}),es(s,"blur",function(t){return Pr(e,t)})}function _o(e,t,r,n){var i,o=e.doc;null==r&&(r="add"),"smart"==r&&(o.mode.indent?i=qe(e,t).state:r="prev");var l=e.options.tabSize,s=M(o,t),a=f(s.text,null,l);s.stateAfter&&(s.stateAfter=null);var u,c=s.text.match(/^\s*/)[0];if(n||/\S/.test(s.text)){if("smart"==r&&((u=o.mode.indent(i,s.text.slice(c.length),s.text))==Ul||u>150)){if(!n)return;r="prev"}}else u=0,r="not";"prev"==r?u=t>o.first?f(M(o,t-1).text,null,l):0:"add"==r?u=a+e.options.indentUnit:"subtract"==r?u=a-e.options.indentUnit:"number"==typeof r&&(u=a+r),u=Math.max(0,u);var h="",d=0;if(e.options.indentWithTabs)for(var g=Math.floor(u/l);g;--g)d+=l,h+="\t";if(d<u&&(h+=p(u-d)),h!=c)return Ei(o,h,P(t,0),P(t,c.length),"+input"),s.stateAfter=null,!0;for(var v=0;v<o.sel.ranges.length;v++){var m=o.sel.ranges[v];if(m.head.line==t&&m.head.ch<c.length){var y=P(t,c.length);vi(o,v,new Ns(y,y));break}}}function $o(e){Qs=e}function qo(e,t,r,n,i){var o=e.doc;e.display.shift=!1,n||(n=o.sel);var l=e.state.pasteIncoming||"paste"==i,s=rs(t),a=null;if(l&&n.ranges.length>1)if(Qs&&Qs.text.join("\n")==t){if(n.ranges.length%Qs.text.length==0){a=[];for(var u=0;u<Qs.text.length;u++)a.push(o.splitLines(Qs.text[u]))}}else s.length==n.ranges.length&&e.options.pasteLinesPerSelection&&(a=v(s,function(e){return[e]}));for(var c,f=n.ranges.length-1;f>=0;f--){var h=n.ranges[f],d=h.from(),p=h.to();h.empty()&&(r&&r>0?d=P(d.line,d.ch-r):e.state.overwrite&&!l?p=P(p.line,Math.min(M(o,p.line).text.length,p.ch+g(s).length)):Qs&&Qs.lineWise&&Qs.text.join("\n")==t&&(d=p=P(d.line,0))),c=e.curOp.updateInput;var m={from:d,to:p,text:a?a[f%a.length]:s,origin:i||(l?"paste":e.state.cutIncoming?"cut":"+input")};Ai(e.doc,m),wt(e,"inputRead",e,m)}t&&!l&&Qo(e,t),Xr(e),e.curOp.updateInput=c,e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=!1}function Zo(e,t){var r=e.clipboardData&&e.clipboardData.getData("Text");if(r)return e.preventDefault(),t.isReadOnly()||t.options.disableInput||dn(t,function(){return qo(t,r,0,null,"paste")}),!0}function Qo(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var r=e.doc.sel,n=r.ranges.length-1;n>=0;n--){var i=r.ranges[n];if(!(i.head.ch>100||n&&r.ranges[n-1].head.line==i.head.line)){var o=e.getModeAt(i.head),l=!1;if(o.electricChars){for(var s=0;s<o.electricChars.length;s++)if(t.indexOf(o.electricChars.charAt(s))>-1){l=_o(e,i.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(M(e.doc,i.head.line).text.slice(0,i.head.ch))&&(l=_o(e,i.head.line,"smart"));l&&wt(e,"electricInput",e,i.head.line)}}}function Jo(e){for(var t=[],r=[],n=0;n<e.doc.sel.ranges.length;n++){var i=e.doc.sel.ranges[n].head.line,o={anchor:P(i,0),head:P(i+1,0)};r.push(o),t.push(e.getRange(o.anchor,o.head))}return{text:t,ranges:r}}function el(e,t){e.setAttribute("autocorrect","off"),e.setAttribute("autocapitalize","off"),e.setAttribute("spellcheck",!!t)}function tl(){var e=n("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),t=n("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return bl?e.style.width="1000px":e.setAttribute("wrap","off"),Tl&&(e.style.border="1px solid black"),el(e),t}function rl(e,t,r,n,i){function o(){var n=t.line+r;return!(n<e.first||n>=e.first+e.size)&&(t=new P(n,t.ch,t.sticky),u=M(e,n))}function l(n){var l;if(null==(l=i?vo(e.cm,u,t,r):po(u,t,r))){if(n||!o())return!1;t=go(i,e.cm,u,t.line,r)}else t=l;return!0}var s=t,a=r,u=M(e,t.line);if("char"==n)l();else if("column"==n)l(!0);else if("word"==n||"group"==n)for(var c=null,f="group"==n,h=e.cm&&e.cm.getHelper(t,"wordChars"),d=!0;!(r<0)||l(!d);d=!1){var p=u.text.charAt(t.ch)||"\n",g=x(p,h)?"w":f&&"\n"==p?"n":!f||/\s/.test(p)?null:"p";if(!f||d||g||(g="s"),c&&c!=g){r<0&&(r=1,l(),t.sticky="after");break}if(g&&(c=g),r>0&&!l(!d))break}var v=Ti(e,t,s,a,!0);return z(s,v)&&(v.hitSide=!0),v}function nl(e,t,r,n){var i,o=e.doc,l=t.left;if("page"==n){var s=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),a=Math.max(s-.5*yr(e.display),3);i=(r>0?t.bottom:t.top)+r*a}else"line"==n&&(i=r>0?t.bottom+3:t.top-3);for(var u;u=fr(e,l,i),u.outside;){if(r<0?i<=0:i>=o.height){u.hitSide=!0;break}i+=5*r}return u}function il(e,t){var r=Xt(e,t.line);if(!r||r.hidden)return null;var n=M(e.doc,t.line),i=Vt(r,n,t.line),o=Se(n,e.doc.direction),l="left";if(o){l=Ce(o,t.ch)%2?"right":"left"}var s=$t(i.map,t.ch,l);return s.offset="right"==s.collapse?s.end:s.start,s}function ol(e){for(var t=e;t;t=t.parentNode)if(/CodeMirror-gutter-wrapper/.test(t.className))return!0;return!1}function ll(e,t){return t&&(e.bad=!0),e}function sl(e,t,r,n,i){function o(e){return function(t){return t.id==e}}function l(){c&&(u+=f,c=!1)}function s(e){e&&(l(),u+=e)}function a(t){if(1==t.nodeType){var r=t.getAttribute("cm-text");if(null!=r)return void s(r||t.textContent.replace(/\u200b/g,""));var u,h=t.getAttribute("cm-marker");if(h){var d=e.findMarks(P(n,0),P(i+1,0),o(+h));return void(d.length&&(u=d[0].find(0))&&s(N(e.doc,u.from,u.to).join(f)))}if("false"==t.getAttribute("contenteditable"))return;var p=/^(pre|div|p)$/i.test(t.nodeName);p&&l();for(var g=0;g<t.childNodes.length;g++)a(t.childNodes[g]);p&&(c=!0)}else 3==t.nodeType&&s(t.nodeValue)}for(var u="",c=!1,f=e.doc.lineSeparator();a(t),t!=r;)t=t.nextSibling;return u}function al(e,t,r){var n;if(t==e.display.lineDiv){if(!(n=e.display.lineDiv.childNodes[r]))return ll(e.clipPos(P(e.display.viewTo-1)),!0);t=null,r=0}else for(n=t;;n=n.parentNode){if(!n||n==e.display.lineDiv)return null;if(n.parentNode&&n.parentNode==e.display.lineDiv)break}for(var i=0;i<e.display.view.length;i++){var o=e.display.view[i];if(o.node==n)return ul(o,t,r)}}function ul(e,t,r){function n(t,r,n){for(var i=-1;i<(f?f.length:0);i++)for(var o=i<0?c.map:f[i],l=0;l<o.length;l+=3){var s=o[l+2];if(s==t||s==r){var a=W(i<0?e.line:e.rest[i]),u=o[l]+n;return(n<0||s!=t)&&(u=o[l+(n?1:0)]),P(a,u)}}}var i=e.text.firstChild,l=!1;if(!t||!o(i,t))return ll(P(W(e.line),0),!0);if(t==i&&(l=!0,t=i.childNodes[r],r=0,!t)){var s=e.rest?g(e.rest):e.line;return ll(P(W(s),s.text.length),l)}var a=3==t.nodeType?t:null,u=t;for(a||1!=t.childNodes.length||3!=t.firstChild.nodeType||(a=t.firstChild,r&&(r=a.nodeValue.length));u.parentNode!=i;)u=u.parentNode;var c=e.measure,f=c.maps,h=n(a,u,r);if(h)return ll(h,l);for(var d=u.nextSibling,p=a?a.nodeValue.length-r:0;d;d=d.nextSibling){if(h=n(d,d.firstChild,0))return ll(P(h.line,h.ch-p),l);p+=d.textContent.length}for(var v=u.previousSibling,m=r;v;v=v.previousSibling){if(h=n(v,v.firstChild,-1))return ll(P(h.line,h.ch+m),l);m+=v.textContent.length}}function cl(e,t){function r(){e.value=a.getValue()}if(t=t?c(t):{},t.value=e.value,!t.tabindex&&e.tabIndex&&(t.tabindex=e.tabIndex),!t.placeholder&&e.placeholder&&(t.placeholder=e.placeholder),null==t.autofocus){var n=l();t.autofocus=n==e||null!=e.getAttribute("autofocus")&&n==document.body}var i;if(e.form&&(es(e.form,"submit",r),!t.leaveSubmitMethodAlone)){var o=e.form;i=o.submit;try{var s=o.submit=function(){r(),o.submit=i,o.submit(),o.submit=s}}catch(e){}}t.finishInit=function(t){t.save=r,t.getTextArea=function(){return e},t.toTextArea=function(){t.toTextArea=isNaN,r(),e.parentNode.removeChild(t.getWrapperElement()),e.style.display="",e.form&&(ke(e.form,"submit",r),"function"==typeof e.form.submit&&(e.form.submit=i))}},e.style.display="none";var a=Xo(function(t){return e.parentNode.insertBefore(t,e.nextSibling)},t);return a}var fl=navigator.userAgent,hl=navigator.platform,dl=/gecko\/\d/i.test(fl),pl=/MSIE \d/.test(fl),gl=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(fl),vl=/Edge\/(\d+)/.exec(fl),ml=pl||gl||vl,yl=ml&&(pl?document.documentMode||6:+(vl||gl)[1]),bl=!vl&&/WebKit\//.test(fl),wl=bl&&/Qt\/\d+\.\d+/.test(fl),xl=!vl&&/Chrome\//.test(fl),Cl=/Opera\//.test(fl),Sl=/Apple Computer/.test(navigator.vendor),Ll=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(fl),kl=/PhantomJS/.test(fl),Tl=!vl&&/AppleWebKit/.test(fl)&&/Mobile\/\w+/.test(fl),Ml=/Android/.test(fl),Nl=Tl||Ml||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(fl),Ol=Tl||/Mac/.test(hl),Al=/\bCrOS\b/.test(fl),Wl=/win/i.test(hl),Dl=Cl&&fl.match(/Version\/(\d*\.\d*)/);Dl&&(Dl=Number(Dl[1])),Dl&&Dl>=15&&(Cl=!1,bl=!0);var Hl,Fl=Ol&&(wl||Cl&&(null==Dl||Dl<12.11)),Pl=dl||ml&&yl>=9,El=function(t,r){var n=t.className,i=e(r).exec(n);if(i){var o=n.slice(i.index+i[0].length);t.className=n.slice(0,i.index)+(o?i[1]+o:"")}};Hl=document.createRange?function(e,t,r,n){var i=document.createRange();return i.setEnd(n||e,r),i.setStart(e,t),i}:function(e,t,r){var n=document.body.createTextRange();try{n.moveToElementText(e.parentNode)}catch(e){return n}return n.collapse(!0),n.moveEnd("character",r),n.moveStart("character",t),n};var zl=function(e){e.select()};Tl?zl=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:ml&&(zl=function(e){try{e.select()}catch(e){}});var Il=function(){this.id=null};Il.prototype.set=function(e,t){clearTimeout(this.id),this.id=setTimeout(t,e)};var Rl,Bl,Gl=30,Ul={toString:function(){return"CodeMirror.Pass"}},Vl={scroll:!1},Kl={origin:"*mouse"},jl={origin:"+move"},Xl=[""],Yl=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,_l=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/,$l=!1,ql=!1,Zl=null,Ql=function(){function e(e){return e<=247?r.charAt(e):1424<=e&&e<=1524?"R":1536<=e&&e<=1785?n.charAt(e-1536):1774<=e&&e<=2220?"r":8192<=e&&e<=8203?"w":8204==e?"b":"L"}function t(e,t,r){this.level=e,this.from=t,this.to=r}var r="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",n="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111",i=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,o=/[stwN]/,l=/[LRr]/,s=/[Lb1n]/,a=/[1n]/;return function(r,n){var u="ltr"==n?"L":"R";if(0==r.length||"ltr"==n&&!i.test(r))return!1;for(var c=r.length,f=[],h=0;h<c;++h)f.push(e(r.charCodeAt(h)));for(var d=0,p=u;d<c;++d){var v=f[d];"m"==v?f[d]=p:p=v}for(var m=0,y=u;m<c;++m){var b=f[m];"1"==b&&"r"==y?f[m]="n":l.test(b)&&(y=b,"r"==b&&(f[m]="R"))}for(var w=1,x=f[0];w<c-1;++w){var C=f[w];"+"==C&&"1"==x&&"1"==f[w+1]?f[w]="1":","!=C||x!=f[w+1]||"1"!=x&&"n"!=x||(f[w]=x),x=C}for(var S=0;S<c;++S){var L=f[S];if(","==L)f[S]="N";else if("%"==L){var k=void 0;for(k=S+1;k<c&&"%"==f[k];++k);for(var T=S&&"!"==f[S-1]||k<c&&"1"==f[k]?"1":"N",M=S;M<k;++M)f[M]=T;S=k-1}}for(var N=0,O=u;N<c;++N){var A=f[N];"L"==O&&"1"==A?f[N]="L":l.test(A)&&(O=A)}for(var W=0;W<c;++W)if(o.test(f[W])){var D=void 0;for(D=W+1;D<c&&o.test(f[D]);++D);for(var H="L"==(W?f[W-1]:u),F="L"==(D<c?f[D]:u),P=H==F?H?"L":"R":u,E=W;E<D;++E)f[E]=P;W=D-1}for(var z,I=[],R=0;R<c;)if(s.test(f[R])){var B=R;for(++R;R<c&&s.test(f[R]);++R);I.push(new t(0,B,R))}else{var G=R,U=I.length;for(++R;R<c&&"L"!=f[R];++R);for(var V=G;V<R;)if(a.test(f[V])){G<V&&I.splice(U,0,new t(1,G,V));var K=V;for(++V;V<R&&a.test(f[V]);++V);I.splice(U,0,new t(2,K,V)),G=V}else++V;G<R&&I.splice(U,0,new t(1,G,R))}return"ltr"==n&&(1==I[0].level&&(z=r.match(/^\s+/))&&(I[0].from=z[0].length,I.unshift(new t(0,0,z[0].length))),1==g(I).level&&(z=r.match(/\s+$/))&&(g(I).to-=z[0].length,I.push(new t(0,c-z[0].length,c)))),"rtl"==n?I.reverse():I}}(),Jl=[],es=function(e,t,r){if(e.addEventListener)e.addEventListener(t,r,!1);else if(e.attachEvent)e.attachEvent("on"+t,r);else{var n=e._handlers||(e._handlers={});n[t]=(n[t]||Jl).concat(r)}},ts=function(){if(ml&&yl<9)return!1;var e=n("div");return"draggable"in e||"dragDrop"in e}(),rs=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,r=[],n=e.length;t<=n;){var i=e.indexOf("\n",t);-1==i&&(i=e.length);var o=e.slice(t,"\r"==e.charAt(i-1)?i-1:i),l=o.indexOf("\r");-1!=l?(r.push(o.slice(0,l)),t+=l+1):(r.push(o),t=i+1)}return r}:function(e){return e.split(/\r\n?|\n/)},ns=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(e){return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch(e){}return!(!t||t.parentElement()!=e)&&0!=t.compareEndPoints("StartToEnd",t)},is=function(){var e=n("div");return"oncopy"in e||(e.setAttribute("oncopy","return;"),"function"==typeof e.oncopy)}(),os=null,ls={},ss={},as={},us=function(e,t,r){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=r};us.prototype.eol=function(){return this.pos>=this.string.length},us.prototype.sol=function(){return this.pos==this.lineStart},us.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},us.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},us.prototype.eat=function(e){var t=this.string.charAt(this.pos);if("string"==typeof e?t==e:t&&(e.test?e.test(t):e(t)))return++this.pos,t},us.prototype.eatWhile=function(e){for(var t=this.pos;this.eat(e););return this.pos>t},us.prototype.eatSpace=function(){for(var e=this,t=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++e.pos;return this.pos>t},us.prototype.skipToEnd=function(){this.pos=this.string.length},us.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},us.prototype.backUp=function(e){this.pos-=e},us.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=f(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?f(this.string,this.lineStart,this.tabSize):0)},us.prototype.indentation=function(){return f(this.string,null,this.tabSize)-(this.lineStart?f(this.string,this.lineStart,this.tabSize):0)},us.prototype.match=function(e,t,r){if("string"!=typeof e){var n=this.string.slice(this.pos).match(e);return n&&n.index>0?null:(n&&!1!==t&&(this.pos+=n[0].length),n)}var i=function(e){return r?e.toLowerCase():e};if(i(this.string.substr(this.pos,e.length))==i(e))return!1!==t&&(this.pos+=e.length),!0},us.prototype.current=function(){return this.string.slice(this.start,this.pos)},us.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},us.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},us.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};var cs=function(e,t){this.state=e,this.lookAhead=t},fs=function(e,t,r,n){this.state=t,this.doc=e,this.line=r,this.maxLookAhead=n||0,this.baseTokens=null,this.baseTokenPos=1};fs.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return null!=t&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},fs.prototype.baseToken=function(e){var t=this;if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)t.baseTokenPos+=2;var r=this.baseTokens[this.baseTokenPos+1];return{type:r&&r.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},fs.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},fs.fromSaved=function(e,t,r){return t instanceof cs?new fs(e,je(e.mode,t.state),r,t.lookAhead):new fs(e,je(e.mode,t),r)},fs.prototype.save=function(e){var t=!1!==e?je(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new cs(t,this.maxLookAhead):t};var hs=function(e,t,r){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=r},ds=function(e,t,r){this.text=e,ne(this,t),this.height=r?r(this):1};ds.prototype.lineNo=function(){return W(this)},Ae(ds);var ps,gs={},vs={},ms=null,ys=null,bs={left:0,right:0,top:0,bottom:0},ws=function(e,t,r){this.cm=r;var i=this.vert=n("div",[n("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),o=this.horiz=n("div",[n("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");e(i),e(o),es(i,"scroll",function(){i.clientHeight&&t(i.scrollTop,"vertical")}),es(o,"scroll",function(){o.clientWidth&&t(o.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,ml&&yl<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};ws.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,r=e.scrollHeight>e.clientHeight+1,n=e.nativeBarWidth;if(r){this.vert.style.display="block",this.vert.style.bottom=t?n+"px":"0";var i=e.viewHeight-(t?n:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=r?n+"px":"0",this.horiz.style.left=e.barLeft+"px";var o=e.viewWidth-e.barLeft-(r?n:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==n&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:r?n:0,bottom:t?n:0}},ws.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},ws.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},ws.prototype.zeroWidthHack=function(){var e=Ol&&!Ll?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new Il,this.disableVert=new Il},ws.prototype.enableZeroWidthBar=function(e,t,r){function n(){var i=e.getBoundingClientRect();("vert"==r?document.elementFromPoint(i.right-1,(i.top+i.bottom)/2):document.elementFromPoint((i.right+i.left)/2,i.bottom-1))!=e?e.style.pointerEvents="none":t.set(1e3,n)}e.style.pointerEvents="auto",t.set(1e3,n)},ws.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var xs=function(){};xs.prototype.update=function(){return{bottom:0,right:0}},xs.prototype.setScrollLeft=function(){},xs.prototype.setScrollTop=function(){},xs.prototype.clear=function(){};var Cs={native:ws,null:xs},Ss=0,Ls=function(e,t,r){var n=e.display;this.viewport=t,this.visible=Ir(n,e.doc,t),this.editorIsHidden=!n.wrapper.offsetWidth,this.wrapperHeight=n.wrapper.clientHeight,this.wrapperWidth=n.wrapper.clientWidth,this.oldDisplayWidth=Bt(e),this.force=r,this.dims=wr(e),this.events=[]};Ls.prototype.signal=function(e,t){Oe(e,t)&&this.events.push(arguments)},Ls.prototype.finish=function(){for(var e=this,t=0;t<this.events.length;t++)Te.apply(null,e.events[t])};var ks=0,Ts=null;ml?Ts=-.53:dl?Ts=15:xl?Ts=-.7:Sl&&(Ts=-1/3);var Ms=function(e,t){this.ranges=e,this.primIndex=t};Ms.prototype.primary=function(){return this.ranges[this.primIndex]},Ms.prototype.equals=function(e){var t=this;if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var r=0;r<this.ranges.length;r++){var n=t.ranges[r],i=e.ranges[r];if(!z(n.anchor,i.anchor)||!z(n.head,i.head))return!1}return!0},Ms.prototype.deepCopy=function(){for(var e=this,t=[],r=0;r<this.ranges.length;r++)t[r]=new Ns(I(e.ranges[r].anchor),I(e.ranges[r].head));return new Ms(t,this.primIndex)},Ms.prototype.somethingSelected=function(){for(var e=this,t=0;t<this.ranges.length;t++)if(!e.ranges[t].empty())return!0;return!1},Ms.prototype.contains=function(e,t){var r=this;t||(t=e);for(var n=0;n<this.ranges.length;n++){var i=r.ranges[n];if(E(t,i.from())>=0&&E(e,i.to())<=0)return n}return-1};var Ns=function(e,t){this.anchor=e,this.head=t};Ns.prototype.from=function(){return B(this.anchor,this.head)},Ns.prototype.to=function(){return R(this.anchor,this.head)},Ns.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch},Gi.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var r=this,n=e,i=e+t;n<i;++n){var o=r.lines[n];r.height-=o.height,lt(o),wt(o,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,r){var n=this;this.height+=r,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var i=0;i<t.length;++i)t[i].parent=n},iterN:function(e,t,r){for(var n=this,i=e+t;e<i;++e)if(r(n.lines[e]))return!0}},Ui.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){var r=this;this.size-=t;for(var n=0;n<this.children.length;++n){var i=r.children[n],o=i.chunkSize();if(e<o){var l=Math.min(t,o-e),s=i.height;if(i.removeInner(e,l),r.height-=s-i.height,o==l&&(r.children.splice(n--,1),i.parent=null),0==(t-=l))break;e=0}else e-=o}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof Gi))){var a=[];this.collapse(a),this.children=[new Gi(a)],this.children[0].parent=this}},collapse:function(e){for(var t=this,r=0;r<this.children.length;++r)t.children[r].collapse(e)},insertInner:function(e,t,r){var n=this;this.size+=t.length,this.height+=r;for(var i=0;i<this.children.length;++i){var o=n.children[i],l=o.chunkSize();if(e<=l){if(o.insertInner(e,t,r),o.lines&&o.lines.length>50){for(var s=o.lines.length%25+25,a=s;a<o.lines.length;){var u=new Gi(o.lines.slice(a,a+=25));o.height-=u.height,n.children.splice(++i,0,u),u.parent=n}o.lines=o.lines.slice(0,s),n.maybeSpill()}break}e-=l}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=e.children.splice(e.children.length-5,5),r=new Ui(t);if(e.parent){e.size-=r.size,e.height-=r.height;var n=h(e.parent.children,e);e.parent.children.splice(n+1,0,r)}else{var i=new Ui(e.children);i.parent=e,e.children=[i,r],e=i}r.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,r){for(var n=this,i=0;i<this.children.length;++i){var o=n.children[i],l=o.chunkSize();if(e<l){var s=Math.min(t,l-e);if(o.iterN(e,s,r))return!0;if(0==(t-=s))break;e=0}else e-=l}}};var Os=function(e,t,r){var n=this;if(r)for(var i in r)r.hasOwnProperty(i)&&(n[i]=r[i]);this.doc=e,this.node=t};Os.prototype.clear=function(){var e=this,t=this.doc.cm,r=this.line.widgets,n=this.line,i=W(n);if(null!=i&&r){for(var o=0;o<r.length;++o)r[o]==e&&r.splice(o--,1);r.length||(n.widgets=null);var l=Ft(this);A(n,Math.max(0,n.height-l)),t&&(dn(t,function(){Vi(t,n,-l),yn(t,i,"widget")}),wt(t,"lineWidgetCleared",t,this,i))}},Os.prototype.changed=function(){var e=this,t=this.height,r=this.doc.cm,n=this.line;this.height=null;var i=Ft(this)-t;i&&(A(n,n.height+i),r&&dn(r,function(){r.curOp.forceUpdate=!0,Vi(r,n,i),wt(r,"lineWidgetChanged",r,e,W(n))}))},Ae(Os);var As=0,Ws=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++As};Ws.prototype.clear=function(){var e=this;if(!this.explicitlyCleared){var t=this.doc.cm,r=t&&!t.curOp;if(r&&on(t),Oe(this,"clear")){var n=this.find();n&&wt(this,"clear",n.from,n.to)}for(var i=null,o=null,l=0;l<this.lines.length;++l){var s=e.lines[l],a=_(s.markedSpans,e);t&&!e.collapsed?yn(t,W(s),"text"):t&&(null!=a.to&&(o=W(s)),null!=a.from&&(i=W(s))),s.markedSpans=$(s.markedSpans,a),null==a.from&&e.collapsed&&!ve(e.doc,s)&&t&&A(s,yr(t.display))}if(t&&this.collapsed&&!t.options.lineWrapping)for(var u=0;u<this.lines.length;++u){var c=fe(e.lines[u]),f=be(c);f>t.display.maxLineLength&&(t.display.maxLine=c,t.display.maxLineLength=f,t.display.maxLineChanged=!0)}null!=i&&t&&this.collapsed&&mn(t,i,o+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,t&&Si(t.doc)),t&&wt(t,"markerCleared",t,this,i,o),r&&ln(t),this.parent&&this.parent.clear()}},Ws.prototype.find=function(e,t){var r=this;null==e&&"bookmark"==this.type&&(e=1);for(var n,i,o=0;o<this.lines.length;++o){var l=r.lines[o],s=_(l.markedSpans,r);if(null!=s.from&&(n=P(t?l:W(l),s.from),-1==e))return n;if(null!=s.to&&(i=P(t?l:W(l),s.to),1==e))return i}return n&&{from:n,to:i}},Ws.prototype.changed=function(){var e=this,t=this.find(-1,!0),r=this,n=this.doc.cm;t&&n&&dn(n,function(){var i=t.line,o=W(t.line),l=Xt(n,o);if(l&&(Jt(l),n.curOp.selectionChanged=n.curOp.forceUpdate=!0),n.curOp.updateMaxLine=!0,!ve(r.doc,i)&&null!=r.height){var s=r.height;r.height=null;var a=Ft(r)-s;a&&A(i,i.height+a)}wt(n,"markerChanged",n,e)})},Ws.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;t.maybeHiddenMarkers&&-1!=h(t.maybeHiddenMarkers,this)||(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},Ws.prototype.detachLine=function(e){if(this.lines.splice(h(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},Ae(Ws);var Ds=function(e,t){var r=this;this.markers=e,this.primary=t;for(var n=0;n<e.length;++n)e[n].parent=r};Ds.prototype.clear=function(){var e=this;if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var t=0;t<this.markers.length;++t)e.markers[t].clear();wt(this,"clear")}},Ds.prototype.find=function(e,t){return this.primary.find(e,t)},Ae(Ds);var Hs=0,Fs=function(e,t,r,n,i){if(!(this instanceof Fs))return new Fs(e,t,r,n,i);null==r&&(r=0),Ui.call(this,[new Gi([new ds("",null)])]),this.first=r,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=r;var o=P(r,0);this.sel=Bn(o),this.history=new ei(null),this.id=++Hs,this.modeOption=t,this.lineSep=n,this.direction="rtl"==i?"rtl":"ltr",this.extend=!1,"string"==typeof e&&(e=this.splitLines(e)),$n(this,{from:o,to:o,text:e}),wi(this,Bn(o),Vl)};Fs.prototype=b(Ui.prototype,{constructor:Fs,iter:function(e,t,r){r?this.iterN(e-this.first,t-e,r):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var r=0,n=0;n<t.length;++n)r+=t[n].height;this.insertInner(e-this.first,t,r)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=O(this,this.first,this.first+this.size);return!1===e?t:t.join(e||this.lineSeparator())},setValue:vn(function(e){var t=P(this.first,0),r=this.first+this.size-1;Ai(this,{from:t,to:P(r,M(this,r).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&Yr(this.cm,0,0),wi(this,Bn(t),Vl)}),replaceRange:function(e,t,r,n){t=U(this,t),r=r?U(this,r):t,Ei(this,e,t,r,n)},getRange:function(e,t,r){var n=N(this,U(this,e),U(this,t));return!1===r?n:n.join(r||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(H(this,e))return M(this,e)},getLineNumber:function(e){return W(e)},getLineHandleVisualStart:function(e){return"number"==typeof e&&(e=M(this,e)),fe(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return U(this,e)},getCursor:function(e){var t=this.sel.primary();return null==e||"head"==e?t.head:"anchor"==e?t.anchor:"end"==e||"to"==e||!1===e?t.to():t.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:vn(function(e,t,r){mi(this,U(this,"number"==typeof e?P(e,t||0):e),null,r)}),setSelection:vn(function(e,t,r){mi(this,U(this,e),U(this,t||e),r)}),extendSelection:vn(function(e,t,r){pi(this,U(this,e),t&&U(this,t),r)}),extendSelections:vn(function(e,t){gi(this,K(this,e),t)}),extendSelectionsBy:vn(function(e,t){gi(this,K(this,v(this.sel.ranges,e)),t)}),setSelections:vn(function(e,t,r){var n=this;if(e.length){for(var i=[],o=0;o<e.length;o++)i[o]=new Ns(U(n,e[o].anchor),U(n,e[o].head));null==t&&(t=Math.min(e.length-1,this.sel.primIndex)),wi(this,Rn(i,t),r)}}),addSelection:vn(function(e,t,r){var n=this.sel.ranges.slice(0);n.push(new Ns(U(this,e),U(this,t||e))),wi(this,Rn(n,n.length-1),r)}),getSelection:function(e){for(var t,r=this,n=this.sel.ranges,i=0;i<n.length;i++){var o=N(r,n[i].from(),n[i].to());t=t?t.concat(o):o}return!1===e?t:t.join(e||this.lineSeparator())},getSelections:function(e){for(var t=this,r=[],n=this.sel.ranges,i=0;i<n.length;i++){var o=N(t,n[i].from(),n[i].to());!1!==e&&(o=o.join(e||t.lineSeparator())),r[i]=o}return r},replaceSelection:function(e,t,r){for(var n=[],i=0;i<this.sel.ranges.length;i++)n[i]=e;this.replaceSelections(n,t,r||"+input")},replaceSelections:vn(function(e,t,r){for(var n=this,i=[],o=this.sel,l=0;l<o.ranges.length;l++){var s=o.ranges[l];i[l]={from:s.from(),to:s.to(),text:n.splitLines(e[l]),origin:r}}for(var a=t&&"end"!=t&&jn(this,i,t),u=i.length-1;u>=0;u--)Ai(n,i[u]);a?bi(this,a):this.cm&&Xr(this.cm)}),undo:vn(function(){Di(this,"undo")}),redo:vn(function(){Di(this,"redo")}),undoSelection:vn(function(){Di(this,"undo",!0)}),redoSelection:vn(function(){Di(this,"redo",!0)}),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,r=0,n=0;n<e.done.length;n++)e.done[n].ranges||++t;for(var i=0;i<e.undone.length;i++)e.undone[i].ranges||++r;return{undo:t,redo:r}},clearHistory:function(){this.history=new ei(this.history.maxGeneration)},
|
5
|
-
markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:hi(this.history.done),undone:hi(this.history.undone)}},setHistory:function(e){var t=this.history=new ei(this.history.maxGeneration);t.done=hi(e.done.slice(0),null,!0),t.undone=hi(e.undone.slice(0),null,!0)},setGutterMarker:vn(function(e,t,r){return Bi(this,e,"gutter",function(e){var n=e.gutterMarkers||(e.gutterMarkers={});return n[t]=r,!r&&C(n)&&(e.gutterMarkers=null),!0})}),clearGutter:vn(function(e){var t=this;this.iter(function(r){r.gutterMarkers&&r.gutterMarkers[e]&&Bi(t,r,"gutter",function(){return r.gutterMarkers[e]=null,C(r.gutterMarkers)&&(r.gutterMarkers=null),!0})})}),lineInfo:function(e){var t;if("number"==typeof e){if(!H(this,e))return null;if(t=e,!(e=M(this,e)))return null}else if(null==(t=W(e)))return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:vn(function(t,r,n){return Bi(this,t,"gutter"==r?"gutter":"class",function(t){var i="text"==r?"textClass":"background"==r?"bgClass":"gutter"==r?"gutterClass":"wrapClass";if(t[i]){if(e(n).test(t[i]))return!1;t[i]+=" "+n}else t[i]=n;return!0})}),removeLineClass:vn(function(t,r,n){return Bi(this,t,"gutter"==r?"gutter":"class",function(t){var i="text"==r?"textClass":"background"==r?"bgClass":"gutter"==r?"gutterClass":"wrapClass",o=t[i];if(!o)return!1;if(null==n)t[i]=null;else{var l=o.match(e(n));if(!l)return!1;var s=l.index+l[0].length;t[i]=o.slice(0,l.index)+(l.index&&s!=o.length?" ":"")+o.slice(s)||null}return!0})}),addLineWidget:vn(function(e,t,r){return Ki(this,e,t,r)}),removeLineWidget:function(e){e.clear()},markText:function(e,t,r){return ji(this,U(this,e),U(this,t),r,r&&r.type||"range")},setBookmark:function(e,t){var r={replacedWith:t&&(null==t.nodeType?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return e=U(this,e),ji(this,e,e,r,"bookmark")},findMarksAt:function(e){e=U(this,e);var t=[],r=M(this,e.line).markedSpans;if(r)for(var n=0;n<r.length;++n){var i=r[n];(null==i.from||i.from<=e.ch)&&(null==i.to||i.to>=e.ch)&&t.push(i.marker.parent||i.marker)}return t},findMarks:function(e,t,r){e=U(this,e),t=U(this,t);var n=[],i=e.line;return this.iter(e.line,t.line+1,function(o){var l=o.markedSpans;if(l)for(var s=0;s<l.length;s++){var a=l[s];null!=a.to&&i==e.line&&e.ch>=a.to||null==a.from&&i!=e.line||null!=a.from&&i==t.line&&a.from>=t.ch||r&&!r(a.marker)||n.push(a.marker.parent||a.marker)}++i}),n},getAllMarks:function(){var e=[];return this.iter(function(t){var r=t.markedSpans;if(r)for(var n=0;n<r.length;++n)null!=r[n].from&&e.push(r[n].marker)}),e},posFromIndex:function(e){var t,r=this.first,n=this.lineSeparator().length;return this.iter(function(i){var o=i.text.length+n;if(o>e)return t=e,!0;e-=o,++r}),U(this,P(r,t))},indexFromPos:function(e){e=U(this,e);var t=e.ch;if(e.line<this.first||e.ch<0)return 0;var r=this.lineSeparator().length;return this.iter(this.first,e.line,function(e){t+=e.text.length+r}),t},copy:function(e){var t=new Fs(O(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,r=this.first+this.size;null!=e.from&&e.from>t&&(t=e.from),null!=e.to&&e.to<r&&(r=e.to);var n=new Fs(O(this,t,r),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(n.history=this.history),(this.linked||(this.linked=[])).push({doc:n,sharedHist:e.sharedHist}),n.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],_i(n,Yi(this)),n},unlinkDoc:function(e){var t=this;if(e instanceof Xo&&(e=e.doc),this.linked)for(var r=0;r<this.linked.length;++r){var n=t.linked[r];if(n.doc==e){t.linked.splice(r,1),e.unlinkDoc(t),$i(Yi(t));break}}if(e.history==this.history){var i=[e.id];qn(e,function(e){return i.push(e.id)},!0),e.history=new ei(null),e.history.done=hi(this.history.done,i),e.history.undone=hi(this.history.undone,i)}},iterLinkedDocs:function(e){qn(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):rs(e)},lineSeparator:function(){return this.lineSep||"\n"},setDirection:vn(function(e){"rtl"!=e&&(e="ltr"),e!=this.direction&&(this.direction=e,this.iter(function(e){return e.order=null}),this.cm&&Jn(this.cm))})}),Fs.prototype.eachLine=Fs.prototype.iter;for(var Ps=0,Es=!1,zs={3:"Enter",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",127:"Delete",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Is=0;Is<10;Is++)zs[Is+48]=zs[Is+96]=String(Is);for(var Rs=65;Rs<=90;Rs++)zs[Rs]=String.fromCharCode(Rs);for(var Bs=1;Bs<=12;Bs++)zs[Bs+111]=zs[Bs+63235]="F"+Bs;var Gs={};Gs.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Gs.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Gs.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Gs.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Gs.default=Ol?Gs.macDefault:Gs.pcDefault;var Us={selectAll:Ni,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),Vl)},killLine:function(e){return fo(e,function(t){if(t.empty()){var r=M(e.doc,t.head.line).text.length;return t.head.ch==r&&t.head.line<e.lastLine()?{from:t.head,to:P(t.head.line+1,0)}:{from:t.head,to:P(t.head.line,r)}}return{from:t.from(),to:t.to()}})},deleteLine:function(e){return fo(e,function(t){return{from:P(t.from().line,0),to:U(e.doc,P(t.to().line+1,0))}})},delLineLeft:function(e){return fo(e,function(e){return{from:P(e.from().line,0),to:e.from()}})},delWrappedLineLeft:function(e){return fo(e,function(t){var r=e.charCoords(t.head,"div").top+5;return{from:e.coordsChar({left:0,top:r},"div"),to:t.from()}})},delWrappedLineRight:function(e){return fo(e,function(t){var r=e.charCoords(t.head,"div").top+5,n=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:r},"div");return{from:t.from(),to:n}})},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(P(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(P(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy(function(t){return mo(e,t.head.line)},{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy(function(t){return bo(e,t.head)},{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy(function(t){return yo(e,t.head.line)},{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy(function(t){var r=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:r},"div")},jl)},goLineLeft:function(e){return e.extendSelectionsBy(function(t){var r=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:r},"div")},jl)},goLineLeftSmart:function(e){return e.extendSelectionsBy(function(t){var r=e.cursorCoords(t.head,"div").top+5,n=e.coordsChar({left:0,top:r},"div");return n.ch<e.getLine(n.line).search(/\S/)?bo(e,t.head):n},jl)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"char")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection("\t")},insertSoftTab:function(e){for(var t=[],r=e.listSelections(),n=e.options.tabSize,i=0;i<r.length;i++){var o=r[i].from(),l=f(e.getLine(o.line),o.ch,n);t.push(p(n-l%n))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return dn(e,function(){for(var t=e.listSelections(),r=[],n=0;n<t.length;n++)if(t[n].empty()){var i=t[n].head,o=M(e.doc,i.line).text;if(o)if(i.ch==o.length&&(i=new P(i.line,i.ch-1)),i.ch>0)i=new P(i.line,i.ch+1),e.replaceRange(o.charAt(i.ch-1)+o.charAt(i.ch-2),P(i.line,i.ch-2),i,"+transpose");else if(i.line>e.doc.first){var l=M(e.doc,i.line-1).text;l&&(i=new P(i.line,1),e.replaceRange(o.charAt(0)+e.doc.lineSeparator()+l.charAt(l.length-1),P(i.line-1,l.length-1),i,"+transpose"))}r.push(new Ns(i,i))}e.setSelections(r)})},newlineAndIndent:function(e){return dn(e,function(){for(var t=e.listSelections(),r=t.length-1;r>=0;r--)e.replaceRange(e.doc.lineSeparator(),t[r].anchor,t[r].head,"+input");t=e.listSelections();for(var n=0;n<t.length;n++)e.indentLine(t[n].from().line,null,!0);Xr(e)})},openLine:function(e){return e.replaceSelection("\n","start")},toggleOverwrite:function(e){return e.toggleOverwrite()}},Vs=new Il,Ks=null,js=function(e,t,r){this.time=e,this.pos=t,this.button=r};js.prototype.compare=function(e,t,r){return this.time+400>e&&0==E(t,this.pos)&&r==this.button};var Xs,Ys,_s={toString:function(){return"CodeMirror.Init"}},$s={},qs={};Xo.defaults=$s,Xo.optionHandlers=qs;var Zs=[];Xo.defineInitHook=function(e){return Zs.push(e)};var Qs=null,Js=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new Il,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};Js.prototype.init=function(e){function t(e){if(!Me(i,e)){if(i.somethingSelected())$o({lineWise:!1,text:i.getSelections()}),"cut"==e.type&&i.replaceSelection("",null,"cut");else{if(!i.options.lineWiseCopyCut)return;var t=Jo(i);$o({lineWise:!0,text:t.text}),"cut"==e.type&&i.operation(function(){i.setSelections(t.ranges,0,Vl),i.replaceSelection("",null,"cut")})}if(e.clipboardData){e.clipboardData.clearData();var r=Qs.text.join("\n");if(e.clipboardData.setData("Text",r),e.clipboardData.getData("Text")==r)return void e.preventDefault()}var l=tl(),s=l.firstChild;i.display.lineSpace.insertBefore(l,i.display.lineSpace.firstChild),s.value=Qs.text.join("\n");var a=document.activeElement;zl(s),setTimeout(function(){i.display.lineSpace.removeChild(l),a.focus(),a==o&&n.showPrimarySelection()},50)}}var r=this,n=this,i=n.cm,o=n.div=e.lineDiv;el(o,i.options.spellcheck),es(o,"paste",function(e){Me(i,e)||Zo(e,i)||yl<=11&&setTimeout(pn(i,function(){return r.updateFromDOM()}),20)}),es(o,"compositionstart",function(e){r.composing={data:e.data,done:!1}}),es(o,"compositionupdate",function(e){r.composing||(r.composing={data:e.data,done:!1})}),es(o,"compositionend",function(e){r.composing&&(e.data!=r.composing.data&&r.readFromDOMSoon(),r.composing.done=!0)}),es(o,"touchstart",function(){return n.forceCompositionEnd()}),es(o,"input",function(){r.composing||r.readFromDOMSoon()}),es(o,"copy",t),es(o,"cut",t)},Js.prototype.prepareSelection=function(){var e=Mr(this.cm,!1);return e.focus=this.cm.state.focused,e},Js.prototype.showSelection=function(e,t){e&&this.cm.display.view.length&&((e.focus||t)&&this.showPrimarySelection(),this.showMultipleSelections(e))},Js.prototype.showPrimarySelection=function(){var e=window.getSelection(),t=this.cm,r=t.doc.sel.primary(),n=r.from(),i=r.to();if(t.display.viewTo==t.display.viewFrom||n.line>=t.display.viewTo||i.line<t.display.viewFrom)return void e.removeAllRanges();var o=al(t,e.anchorNode,e.anchorOffset),l=al(t,e.focusNode,e.focusOffset);if(!o||o.bad||!l||l.bad||0!=E(B(o,l),n)||0!=E(R(o,l),i)){var s=t.display.view,a=n.line>=t.display.viewFrom&&il(t,n)||{node:s[0].measure.map[2],offset:0},u=i.line<t.display.viewTo&&il(t,i);if(!u){var c=s[s.length-1].measure,f=c.maps?c.maps[c.maps.length-1]:c.map;u={node:f[f.length-1],offset:f[f.length-2]-f[f.length-3]}}if(!a||!u)return void e.removeAllRanges();var h,d=e.rangeCount&&e.getRangeAt(0);try{h=Hl(a.node,a.offset,u.offset,u.node)}catch(e){}h&&(!dl&&t.state.focused?(e.collapse(a.node,a.offset),h.collapsed||(e.removeAllRanges(),e.addRange(h))):(e.removeAllRanges(),e.addRange(h)),d&&null==e.anchorNode?e.addRange(d):dl&&this.startGracePeriod()),this.rememberSelection()}},Js.prototype.startGracePeriod=function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout(function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation(function(){return e.cm.curOp.selectionChanged=!0})},20)},Js.prototype.showMultipleSelections=function(e){r(this.cm.display.cursorDiv,e.cursors),r(this.cm.display.selectionDiv,e.selection)},Js.prototype.rememberSelection=function(){var e=window.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},Js.prototype.selectionInEditor=function(){var e=window.getSelection();if(!e.rangeCount)return!1;var t=e.getRangeAt(0).commonAncestorContainer;return o(this.div,t)},Js.prototype.focus=function(){"nocursor"!=this.cm.options.readOnly&&(this.selectionInEditor()||this.showSelection(this.prepareSelection(),!0),this.div.focus())},Js.prototype.blur=function(){this.div.blur()},Js.prototype.getField=function(){return this.div},Js.prototype.supportsTouch=function(){return!0},Js.prototype.receivedFocus=function(){function e(){t.cm.state.focused&&(t.pollSelection(),t.polling.set(t.cm.options.pollInterval,e))}var t=this;this.selectionInEditor()?this.pollSelection():dn(this.cm,function(){return t.cm.curOp.selectionChanged=!0}),this.polling.set(this.cm.options.pollInterval,e)},Js.prototype.selectionChanged=function(){var e=window.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},Js.prototype.pollSelection=function(){if(null==this.readDOMTimeout&&!this.gracePeriod&&this.selectionChanged()){var e=window.getSelection(),t=this.cm;if(Ml&&xl&&this.cm.options.gutters.length&&ol(e.anchorNode))return this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),void this.focus();if(!this.composing){this.rememberSelection();var r=al(t,e.anchorNode,e.anchorOffset),n=al(t,e.focusNode,e.focusOffset);r&&n&&dn(t,function(){wi(t.doc,Bn(r,n),Vl),(r.bad||n.bad)&&(t.curOp.selectionChanged=!0)})}}},Js.prototype.pollContent=function(){null!=this.readDOMTimeout&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var e=this.cm,t=e.display,r=e.doc.sel.primary(),n=r.from(),i=r.to();if(0==n.ch&&n.line>e.firstLine()&&(n=P(n.line-1,M(e.doc,n.line-1).length)),i.ch==M(e.doc,i.line).text.length&&i.line<e.lastLine()&&(i=P(i.line+1,0)),n.line<t.viewFrom||i.line>t.viewTo-1)return!1;var o,l,s;n.line==t.viewFrom||0==(o=kr(e,n.line))?(l=W(t.view[0].line),s=t.view[0].node):(l=W(t.view[o].line),s=t.view[o-1].node.nextSibling);var a,u,c=kr(e,i.line);if(c==t.view.length-1?(a=t.viewTo-1,u=t.lineDiv.lastChild):(a=W(t.view[c+1].line)-1,u=t.view[c+1].node.previousSibling),!s)return!1;for(var f=e.doc.splitLines(sl(e,s,u,l,a)),h=N(e.doc,P(l,0),P(a,M(e.doc,a).text.length));f.length>1&&h.length>1;)if(g(f)==g(h))f.pop(),h.pop(),a--;else{if(f[0]!=h[0])break;f.shift(),h.shift(),l++}for(var d=0,p=0,v=f[0],m=h[0],y=Math.min(v.length,m.length);d<y&&v.charCodeAt(d)==m.charCodeAt(d);)++d;for(var b=g(f),w=g(h),x=Math.min(b.length-(1==f.length?d:0),w.length-(1==h.length?d:0));p<x&&b.charCodeAt(b.length-p-1)==w.charCodeAt(w.length-p-1);)++p;if(1==f.length&&1==h.length&&l==n.line)for(;d&&d>n.ch&&b.charCodeAt(b.length-p-1)==w.charCodeAt(w.length-p-1);)d--,p++;f[f.length-1]=b.slice(0,b.length-p).replace(/^\u200b+/,""),f[0]=f[0].slice(d).replace(/\u200b+$/,"");var C=P(l,d),S=P(a,h.length?g(h).length-p:0);return f.length>1||f[0]||E(C,S)?(Ei(e.doc,f,C,S,"+input"),!0):void 0},Js.prototype.ensurePolled=function(){this.forceCompositionEnd()},Js.prototype.reset=function(){this.forceCompositionEnd()},Js.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Js.prototype.readFromDOMSoon=function(){var e=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout(function(){if(e.readDOMTimeout=null,e.composing){if(!e.composing.done)return;e.composing=null}e.updateFromDOM()},80))},Js.prototype.updateFromDOM=function(){var e=this;!this.cm.isReadOnly()&&this.pollContent()||dn(this.cm,function(){return mn(e.cm)})},Js.prototype.setUneditable=function(e){e.contentEditable="false"},Js.prototype.onKeyPress=function(e){0!=e.charCode&&(e.preventDefault(),this.cm.isReadOnly()||pn(this.cm,qo)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0))},Js.prototype.readOnlyChanged=function(e){this.div.contentEditable=String("nocursor"!=e)},Js.prototype.onContextMenu=function(){},Js.prototype.resetPosition=function(){},Js.prototype.needsContentAttribute=!0;var ea=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new Il,this.hasSelection=!1,this.composing=null};ea.prototype.init=function(e){function t(e){if(!Me(i,e)){if(i.somethingSelected())$o({lineWise:!1,text:i.getSelections()});else{if(!i.options.lineWiseCopyCut)return;var t=Jo(i);$o({lineWise:!0,text:t.text}),"cut"==e.type?i.setSelections(t.ranges,null,Vl):(n.prevInput="",l.value=t.text.join("\n"),zl(l))}"cut"==e.type&&(i.state.cutIncoming=!0)}}var r=this,n=this,i=this.cm,o=this.wrapper=tl(),l=this.textarea=o.firstChild;e.wrapper.insertBefore(o,e.wrapper.firstChild),Tl&&(l.style.width="0px"),es(l,"input",function(){ml&&yl>=9&&r.hasSelection&&(r.hasSelection=null),n.poll()}),es(l,"paste",function(e){Me(i,e)||Zo(e,i)||(i.state.pasteIncoming=!0,n.fastPoll())}),es(l,"cut",t),es(l,"copy",t),es(e.scroller,"paste",function(t){Pt(e,t)||Me(i,t)||(i.state.pasteIncoming=!0,n.focus())}),es(e.lineSpace,"selectstart",function(t){Pt(e,t)||We(t)}),es(l,"compositionstart",function(){var e=i.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:i.markText(e,i.getCursor("to"),{className:"CodeMirror-composing"})}}),es(l,"compositionend",function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)})},ea.prototype.prepareSelection=function(){var e=this.cm,t=e.display,r=e.doc,n=Mr(e);if(e.options.moveInputWithCursor){var i=ar(e,r.sel.primary().head,"div"),o=t.wrapper.getBoundingClientRect(),l=t.lineDiv.getBoundingClientRect();n.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,i.top+l.top-o.top)),n.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,i.left+l.left-o.left))}return n},ea.prototype.showSelection=function(e){var t=this.cm,n=t.display;r(n.cursorDiv,e.cursors),r(n.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},ea.prototype.reset=function(e){if(!this.contextMenuPending&&!this.composing){var t=this.cm;if(t.somethingSelected()){this.prevInput="";var r=t.getSelection();this.textarea.value=r,t.state.focused&&zl(this.textarea),ml&&yl>=9&&(this.hasSelection=r)}else e||(this.prevInput=this.textarea.value="",ml&&yl>=9&&(this.hasSelection=null))}},ea.prototype.getField=function(){return this.textarea},ea.prototype.supportsTouch=function(){return!1},ea.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!Nl||l()!=this.textarea))try{this.textarea.focus()}catch(e){}},ea.prototype.blur=function(){this.textarea.blur()},ea.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},ea.prototype.receivedFocus=function(){this.slowPoll()},ea.prototype.slowPoll=function(){var e=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){e.poll(),e.cm.state.focused&&e.slowPoll()})},ea.prototype.fastPoll=function(){function e(){r.poll()||t?(r.pollingFast=!1,r.slowPoll()):(t=!0,r.polling.set(60,e))}var t=!1,r=this;r.pollingFast=!0,r.polling.set(20,e)},ea.prototype.poll=function(){var e=this,t=this.cm,r=this.textarea,n=this.prevInput;if(this.contextMenuPending||!t.state.focused||ns(r)&&!n&&!this.composing||t.isReadOnly()||t.options.disableInput||t.state.keySeq)return!1;var i=r.value;if(i==n&&!t.somethingSelected())return!1;if(ml&&yl>=9&&this.hasSelection===i||Ol&&/[\uf700-\uf7ff]/.test(i))return t.display.input.reset(),!1;if(t.doc.sel==t.display.selForContextMenu){var o=i.charCodeAt(0);if(8203!=o||n||(n=""),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var l=0,s=Math.min(n.length,i.length);l<s&&n.charCodeAt(l)==i.charCodeAt(l);)++l;return dn(t,function(){qo(t,i.slice(l),n.length-l,null,e.composing?"*compose":null),i.length>1e3||i.indexOf("\n")>-1?r.value=e.prevInput="":e.prevInput=i,e.composing&&(e.composing.range.clear(),e.composing.range=t.markText(e.composing.start,t.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},ea.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},ea.prototype.onKeyPress=function(){ml&&yl>=9&&(this.hasSelection=null),this.fastPoll()},ea.prototype.onContextMenu=function(e){function t(){if(null!=l.selectionStart){var e=i.somethingSelected(),t=""+(e?l.value:"");l.value="⇚",l.value=t,n.prevInput=e?"":"",l.selectionStart=1,l.selectionEnd=t.length,o.selForContextMenu=i.doc.sel}}function r(){if(n.contextMenuPending=!1,n.wrapper.style.cssText=c,l.style.cssText=u,ml&&yl<9&&o.scrollbars.setScrollTop(o.scroller.scrollTop=a),null!=l.selectionStart){(!ml||ml&&yl<9)&&t();var e=0,r=function(){o.selForContextMenu==i.doc.sel&&0==l.selectionStart&&l.selectionEnd>0&&""==n.prevInput?pn(i,Ni)(i):e++<10?o.detectingSelectAll=setTimeout(r,500):(o.selForContextMenu=null,o.input.reset())};o.detectingSelectAll=setTimeout(r,200)}}var n=this,i=n.cm,o=i.display,l=n.textarea,s=Lr(i,e),a=o.scroller.scrollTop;if(s&&!Cl){i.options.resetSelectionOnContextMenu&&-1==i.doc.sel.contains(s)&&pn(i,wi)(i.doc,Bn(s),Vl);var u=l.style.cssText,c=n.wrapper.style.cssText;n.wrapper.style.cssText="position: absolute";var f=n.wrapper.getBoundingClientRect();l.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(e.clientY-f.top-5)+"px; left: "+(e.clientX-f.left-5)+"px;\n z-index: 1000; background: "+(ml?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);";var h;if(bl&&(h=window.scrollY),o.input.focus(),bl&&window.scrollTo(null,h),o.input.reset(),i.somethingSelected()||(l.value=n.prevInput=" "),n.contextMenuPending=!0,o.selForContextMenu=i.doc.sel,clearTimeout(o.detectingSelectAll),ml&&yl>=9&&t(),Pl){Fe(e);var d=function(){ke(window,"mouseup",d),setTimeout(r,20)};es(window,"mouseup",d)}else setTimeout(r,50)}},ea.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled="nocursor"==e},ea.prototype.setUneditable=function(){},ea.prototype.needsContentAttribute=!1,function(e){function t(t,n,i,o){e.defaults[t]=n,i&&(r[t]=o?function(e,t,r){r!=_s&&i(e,t,r)}:i)}var r=e.optionHandlers;e.defineOption=t,e.Init=_s,t("value","",function(e,t){return e.setValue(t)},!0),t("mode",null,function(e,t){e.doc.modeOption=t,Xn(e)},!0),t("indentUnit",2,Xn,!0),t("indentWithTabs",!1),t("smartIndent",!0),t("tabSize",4,function(e){Yn(e),tr(e),mn(e)},!0),t("lineSeparator",null,function(e,t){if(e.doc.lineSep=t,t){var r=[],n=e.doc.first;e.doc.iter(function(e){for(var i=0;;){var o=e.text.indexOf(t,i);if(-1==o)break;i=o+t.length,r.push(P(n,o))}n++});for(var i=r.length-1;i>=0;i--)Ei(e.doc,t,r[i],P(r[i].line,r[i].ch+t.length))}}),t("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff]/g,function(e,t,r){e.state.specialChars=new RegExp(t.source+(t.test("\t")?"":"|\t"),"g"),r!=_s&&e.refresh()}),t("specialCharPlaceholder",ut,function(e){return e.refresh()},!0),t("electricChars",!0),t("inputStyle",Nl?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),t("spellcheck",!1,function(e,t){return e.getInputField().spellcheck=t},!0),t("rtlMoveVisually",!Wl),t("wholeLineUpdateBefore",!0),t("theme","default",function(e){Uo(e),Vo(e)},!0),t("keyMap","default",function(e,t,r){var n=co(t),i=r!=_s&&co(r);i&&i.detach&&i.detach(e,n),n.attach&&n.attach(e,i||null)}),t("extraKeys",null),t("configureMouse",null),t("lineWrapping",!1,jo,!0),t("gutters",[],function(e){Pn(e.options),Vo(e)},!0),t("fixedGutter",!0,function(e,t){e.display.gutters.style.left=t?xr(e.display)+"px":"0",e.refresh()},!0),t("coverGutterNextToScrollbar",!1,function(e){return tn(e)},!0),t("scrollbarStyle","native",function(e){nn(e),tn(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)},!0),t("lineNumbers",!1,function(e){Pn(e.options),Vo(e)},!0),t("firstLineNumber",1,Vo,!0),t("lineNumberFormatter",function(e){return e},Vo,!0),t("showCursorWhenSelecting",!1,Tr,!0),t("resetSelectionOnContextMenu",!0),t("lineWiseCopyCut",!0),t("pasteLinesPerSelection",!0),t("readOnly",!1,function(e,t){"nocursor"==t&&(Pr(e),e.display.input.blur()),e.display.input.readOnlyChanged(t)}),t("disableInput",!1,function(e,t){t||e.display.input.reset()},!0),t("dragDrop",!0,Ko),t("allowDropFileTypes",null),t("cursorBlinkRate",530),t("cursorScrollMargin",0),t("cursorHeight",1,Tr,!0),t("singleCursorHeightPerLine",!0,Tr,!0),t("workTime",100),t("workDelay",100),t("flattenSpans",!0,Yn,!0),t("addModeClass",!1,Yn,!0),t("pollInterval",100),t("undoDepth",200,function(e,t){return e.doc.history.undoDepth=t}),t("historyEventDelay",1250),t("viewportMargin",10,function(e){return e.refresh()},!0),t("maxHighlightLength",1e4,Yn,!0),t("moveInputWithCursor",!0,function(e,t){t||e.display.input.resetPosition()}),t("tabindex",null,function(e,t){return e.display.input.getField().tabIndex=t||""}),t("autofocus",null),t("direction","ltr",function(e,t){return e.doc.setDirection(t)},!0)}(Xo),function(e){var t=e.optionHandlers,r=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,r){var n=this.options,i=n[e];n[e]==r&&"mode"!=e||(n[e]=r,t.hasOwnProperty(e)&&pn(this,t[e])(this,r,i),Te(this,"optionChange",this,e))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](co(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,r=0;r<t.length;++r)if(t[r]==e||t[r].name==e)return t.splice(r,1),!0},addOverlay:gn(function(t,r){var n=t.token?t:e.getMode(this.options,t);if(n.startState)throw new Error("Overlays may not be stateful.");m(this.state.overlays,{mode:n,modeSpec:t,opaque:r&&r.opaque,priority:r&&r.priority||0},function(e){return e.priority}),this.state.modeGen++,mn(this)}),removeOverlay:gn(function(e){for(var t=this,r=this.state.overlays,n=0;n<r.length;++n){var i=r[n].modeSpec;if(i==e||"string"==typeof e&&i.name==e)return r.splice(n,1),t.state.modeGen++,void mn(t)}}),indentLine:gn(function(e,t,r){"string"!=typeof t&&"number"!=typeof t&&(t=null==t?this.options.smartIndent?"smart":"prev":t?"add":"subtract"),H(this.doc,e)&&_o(this,e,t,r)}),indentSelection:gn(function(e){for(var t=this,r=this.doc.sel.ranges,n=-1,i=0;i<r.length;i++){var o=r[i];if(o.empty())o.head.line>n&&(_o(t,o.head.line,e,!0),n=o.head.line,i==t.doc.sel.primIndex&&Xr(t));else{var l=o.from(),s=o.to(),a=Math.max(n,l.line);n=Math.min(t.lastLine(),s.line-(s.ch?0:1))+1;for(var u=a;u<n;++u)_o(t,u,e);var c=t.doc.sel.ranges;0==l.ch&&r.length==c.length&&c[i].from().ch>0&&vi(t.doc,i,new Ns(l,c[i].to()),Vl)}}}),getTokenAt:function(e,t){return et(this,e,t)},getLineTokens:function(e,t){return et(this,P(e),t,!0)},getTokenTypeAt:function(e){e=U(this.doc,e);var t,r=$e(this,M(this.doc,e.line)),n=0,i=(r.length-1)/2,o=e.ch;if(0==o)t=r[2];else for(;;){var l=n+i>>1;if((l?r[2*l-1]:0)>=o)i=l;else{if(!(r[2*l+1]<o)){t=r[2*l+2];break}n=l+1}}var s=t?t.indexOf("overlay "):-1;return s<0?t:0==s?null:t.slice(0,s-1)},getModeAt:function(t){var r=this.doc.mode;return r.innerMode?e.innerMode(r,this.getTokenAt(t).state).mode:r},getHelper:function(e,t){return this.getHelpers(e,t)[0]},getHelpers:function(e,t){var n=this,i=[];if(!r.hasOwnProperty(t))return i;var o=r[t],l=this.getModeAt(e);if("string"==typeof l[t])o[l[t]]&&i.push(o[l[t]]);else if(l[t])for(var s=0;s<l[t].length;s++){var a=o[l[t][s]];a&&i.push(a)}else l.helperType&&o[l.helperType]?i.push(o[l.helperType]):o[l.name]&&i.push(o[l.name]);for(var u=0;u<o._global.length;u++){var c=o._global[u];c.pred(l,n)&&-1==h(i,c.val)&&i.push(c.val)}return i},getStateAfter:function(e,t){var r=this.doc;return e=G(r,null==e?r.first+r.size-1:e),qe(this,e+1,t).state},cursorCoords:function(e,t){var r,n=this.doc.sel.primary()
|
6
|
-
;return r=null==e?n.head:"object"==typeof e?U(this.doc,e):e?n.from():n.to(),ar(this,r,t||"page")},charCoords:function(e,t){return sr(this,U(this.doc,e),t||"page")},coordsChar:function(e,t){return e=lr(this,e,t||"page"),fr(this,e.left,e.top)},lineAtHeight:function(e,t){return e=lr(this,{top:e,left:0},t||"page").top,D(this.doc,e+this.display.viewOffset)},heightAtLine:function(e,t,r){var n,i=!1;if("number"==typeof e){var o=this.doc.first+this.doc.size-1;e<this.doc.first?e=this.doc.first:e>o&&(e=o,i=!0),n=M(this.doc,e)}else n=e;return or(this,n,{top:0,left:0},t||"page",r||i).top+(i?this.doc.height-ye(n):0)},defaultTextHeight:function(){return yr(this.display)},defaultCharWidth:function(){return br(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,r,n,i){var o=this.display;e=ar(this,U(this.doc,e));var l=e.bottom,s=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),o.sizer.appendChild(t),"over"==n)l=e.top;else if("above"==n||"near"==n){var a=Math.max(o.wrapper.clientHeight,this.doc.height),u=Math.max(o.sizer.clientWidth,o.lineSpace.clientWidth);("above"==n||e.bottom+t.offsetHeight>a)&&e.top>t.offsetHeight?l=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=a&&(l=e.bottom),s+t.offsetWidth>u&&(s=u-t.offsetWidth)}t.style.top=l+"px",t.style.left=t.style.right="","right"==i?(s=o.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==i?s=0:"middle"==i&&(s=(o.sizer.clientWidth-t.offsetWidth)/2),t.style.left=s+"px"),r&&Vr(this,{left:s,top:l,right:s+t.offsetWidth,bottom:l+t.offsetHeight})},triggerOnKeyDown:gn(ko),triggerOnKeyPress:gn(No),triggerOnKeyUp:Mo,triggerOnMouseDown:gn(Ao),execCommand:function(e){if(Us.hasOwnProperty(e))return Us[e].call(null,this)},triggerElectric:gn(function(e){Qo(this,e)}),findPosH:function(e,t,r,n){var i=this,o=1;t<0&&(o=-1,t=-t);for(var l=U(this.doc,e),s=0;s<t&&(l=rl(i.doc,l,o,r,n),!l.hitSide);++s);return l},moveH:gn(function(e,t){var r=this;this.extendSelectionsBy(function(n){return r.display.shift||r.doc.extend||n.empty()?rl(r.doc,n.head,e,t,r.options.rtlMoveVisually):e<0?n.from():n.to()},jl)}),deleteH:gn(function(e,t){var r=this.doc.sel,n=this.doc;r.somethingSelected()?n.replaceSelection("",null,"+delete"):fo(this,function(r){var i=rl(n,r.head,e,t,!1);return e<0?{from:i,to:r.head}:{from:r.head,to:i}})}),findPosV:function(e,t,r,n){var i=this,o=1,l=n;t<0&&(o=-1,t=-t);for(var s=U(this.doc,e),a=0;a<t;++a){var u=ar(i,s,"div");if(null==l?l=u.left:u.left=l,s=nl(i,u,o,r),s.hitSide)break}return s},moveV:gn(function(e,t){var r=this,n=this.doc,i=[],o=!this.display.shift&&!n.extend&&n.sel.somethingSelected();if(n.extendSelectionsBy(function(l){if(o)return e<0?l.from():l.to();var s=ar(r,l.head,"div");null!=l.goalColumn&&(s.left=l.goalColumn),i.push(s.left);var a=nl(r,s,e,t);return"page"==t&&l==n.sel.primary()&&jr(r,sr(r,a,"div").top-s.top),a},jl),i.length)for(var l=0;l<n.sel.ranges.length;l++)n.sel.ranges[l].goalColumn=i[l]}),findWordAt:function(e){var t=this.doc,r=M(t,e.line).text,n=e.ch,i=e.ch;if(r){var o=this.getHelper(e,"wordChars");"before"!=e.sticky&&i!=r.length||!n?++i:--n;for(var l=r.charAt(n),s=x(l,o)?function(e){return x(e,o)}:/\s/.test(l)?function(e){return/\s/.test(e)}:function(e){return!/\s/.test(e)&&!x(e)};n>0&&s(r.charAt(n-1));)--n;for(;i<r.length&&s(r.charAt(i));)++i}return new Ns(P(e.line,n),P(e.line,i))},toggleOverwrite:function(e){null!=e&&e==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?s(this.display.cursorDiv,"CodeMirror-overwrite"):El(this.display.cursorDiv,"CodeMirror-overwrite"),Te(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==l()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:gn(function(e,t){Yr(this,e,t)}),getScrollInfo:function(){var e=this.display.scroller;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight-Rt(this)-this.display.barHeight,width:e.scrollWidth-Rt(this)-this.display.barWidth,clientHeight:Gt(this),clientWidth:Bt(this)}},scrollIntoView:gn(function(e,t){null==e?(e={from:this.doc.sel.primary().head,to:null},null==t&&(t=this.options.cursorScrollMargin)):"number"==typeof e?e={from:P(e,0),to:null}:null==e.from&&(e={from:e,to:null}),e.to||(e.to=e.from),e.margin=t||0,null!=e.from.line?_r(this,e):qr(this,e.from,e.to,e.margin)}),setSize:gn(function(e,t){var r=this,n=function(e){return"number"==typeof e||/^\d+$/.test(String(e))?e+"px":e};null!=e&&(this.display.wrapper.style.width=n(e)),null!=t&&(this.display.wrapper.style.height=n(t)),this.options.lineWrapping&&er(this);var i=this.display.viewFrom;this.doc.iter(i,this.display.viewTo,function(e){if(e.widgets)for(var t=0;t<e.widgets.length;t++)if(e.widgets[t].noHScroll){yn(r,i,"widget");break}++i}),this.curOp.forceUpdate=!0,Te(this,"refresh",this)}),operation:function(e){return dn(this,e)},startOperation:function(){return on(this)},endOperation:function(){return ln(this)},refresh:gn(function(){var e=this.display.cachedTextHeight;mn(this),this.curOp.forceUpdate=!0,tr(this),Yr(this,this.doc.scrollLeft,this.doc.scrollTop),Dn(this),(null==e||Math.abs(e-yr(this.display))>.5)&&Sr(this),Te(this,"refresh",this)}),swapDoc:gn(function(e){var t=this.doc;return t.cm=null,Zn(this,e),tr(this),this.display.input.reset(),Yr(this,e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,wt(this,"swapDoc",this,t),t}),getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},Ae(e),e.registerHelper=function(t,n,i){r.hasOwnProperty(t)||(r[t]=e[t]={_global:[]}),r[t][n]=i},e.registerGlobalHelper=function(t,n,i,o){e.registerHelper(t,n,o),r[t]._global.push({pred:i,val:o})}}(Xo);var ta="iter insert remove copy getEditor constructor".split(" ");for(var ra in Fs.prototype)Fs.prototype.hasOwnProperty(ra)&&h(ta,ra)<0&&(Xo.prototype[ra]=function(e){return function(){return e.apply(this.doc,arguments)}}(Fs.prototype[ra]));return Ae(Fs),Xo.inputStyles={textarea:ea,contenteditable:Js},Xo.defineMode=function(e){Xo.defaults.mode||"null"==e||(Xo.defaults.mode=e),Be.apply(this,arguments)},Xo.defineMIME=Ge,Xo.defineMode("null",function(){return{token:function(e){return e.skipToEnd()}}}),Xo.defineMIME("text/plain","null"),Xo.defineExtension=function(e,t){Xo.prototype[e]=t},Xo.defineDocExtension=function(e,t){Fs.prototype[e]=t},Xo.fromTextArea=cl,function(e){e.off=ke,e.on=es,e.wheelEventPixels=zn,e.Doc=Fs,e.splitLines=rs,e.countColumn=f,e.findColumn=d,e.isWordChar=w,e.Pass=Ul,e.signal=Te,e.Line=ds,e.changeEnd=Gn,e.scrollbarModel=Cs,e.Pos=P,e.cmpPos=E,e.modes=ls,e.mimeModes=ss,e.resolveMode=Ue,e.getMode=Ve,e.modeExtensions=as,e.extendMode=Ke,e.copyState=je,e.startState=Ye,e.innerMode=Xe,e.commands=Us,e.keyMap=Gs,e.keyName=uo,e.isModifierKey=so,e.lookupKey=lo,e.normalizeKeyMap=oo,e.StringStream=us,e.SharedTextMarker=Ds,e.TextMarker=Ws,e.LineWidget=Os,e.e_preventDefault=We,e.e_stopPropagation=De,e.e_stop=Fe,e.addClass=s,e.contains=o,e.rmClass=El,e.keyNames=zs}(Xo),Xo.version="5.31.0",Xo}),function(e){"function"==typeof e.define&&e.define("core",["codemirror.js"],function(t){e.CodeMirror=t})}(this);
|
1
|
+
(function(b,a){typeof exports==="object"&&typeof module!=="undefined"?module.exports=a():typeof define==="function"&&define.amd?define("codemirror.js",a):(b.CodeMirror=a())}(this,(function(){var ez=navigator.userAgent;var eK=navigator.platform;var cP=/gecko\/\d/i.test(ez);var fs=/MSIE \d/.test(ez);var b3=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(ez);var c3=/Edge\/(\d+)/.exec(ez);var ef=fs||b3||c3;var n=ef&&(fs?document.documentMode||6:+(c3||b3)[1]);var dt=!c3&&/WebKit\//.test(ez);var ei=dt&&/Qt\/\d+\.\d+/.test(ez);var dJ=!c3&&/Chrome\//.test(ez);var eB=/Opera\//.test(ez);var aM=/Apple Computer/.test(navigator.vendor);var dB=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(ez);var ge=/PhantomJS/.test(ez);var fM=!c3&&/AppleWebKit/.test(ez)&&/Mobile\/\w+/.test(ez);var aX=/Android/.test(ez);var eQ=fM||aX||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(ez);var ct=fM||/Mac/.test(eK);var gx=/\bCrOS\b/.test(ez);var a0=/win/i.test(eK);var ba=eB&&ez.match(/Version\/(\d*\.\d*)/);if(ba){ba=Number(ba[1])}if(ba&&ba>=15){eB=false;dt=true}var cb=ct&&(ei||eB&&(ba==null||ba<12.11));var g9=cP||(ef&&n>=9);function X(i){return new RegExp("(^|\\s)"+i+"(?:$|\\s)\\s*")}var h=function(hl,i){var hm=hl.className;var hk=X(i).exec(hm);if(hk){var hn=hm.slice(hk.index+hk[0].length);hl.className=hm.slice(0,hk.index)+(hn?hk[1]+hn:"")}};function eA(hk){for(var i=hk.childNodes.length;i>0;--i){hk.removeChild(hk.firstChild)}return hk}function cd(i,hk){return eA(i).appendChild(hk)}function g0(hk,ho,hn,hm){var hp=document.createElement(hk);if(hn){hp.className=hn}if(hm){hp.style.cssText=hm}if(typeof ho=="string"){hp.appendChild(document.createTextNode(ho))}else{if(ho){for(var hl=0;hl
|
data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.bbcodemixed.min.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
(function(a){if(typeof exports=="object"&&typeof module=="object"){a(require("../../lib/codemirror"))}else{if(typeof define=="function"&&define.amd){define(["../../lib/codemirror"],a)}else{a(CodeMirror)}}})(function(a){var b={autoSelfClosers:{area:true,base:true,br:true,col:true,command:true,embed:true,frame:true,hr:true,img:true,input:true,keygen:true,link:true,meta:true,param:true,source:true,track:true,wbr:true,menuitem:true},implicitlyClosed:{dd:true,li:true,optgroup:true,option:true,p:true,rp:true,rt:true,tbody:true,td:true,tfoot:true,th:true,tr:true},contextGrabbers:{dd:{dd:true,dt:true},dt:{dd:true,dt:true},li:{li:true},option:{option:true,optgroup:true},optgroup:{optgroup:true},p:{address:true,article:true,aside:true,blockquote:true,dir:true,div:true,dl:true,fieldset:true,footer:true,form:true,h1:true,h2:true,h3:true,h4:true,h5:true,h6:true,header:true,hgroup:true,hr:true,menu:true,nav:true,ol:true,p:true,pre:true,section:true,table:true,ul:true},rp:{rp:true,rt:true},rt:{rp:true,rt:true},tbody:{tbody:true,tfoot:true},td:{td:true,th:true},tfoot:{tbody:true},th:{td:true,th:true},thead:{tbody:true,tfoot:true},tr:{tr:true}},doNotIndent:{pre:true},allowUnquoted:true,allowMissing:true,caseFold:true};var c={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:false,allowMissing:false,caseFold:false};a.defineMode("xml",function(m,y){var r=m.indentUnit;var z={};var l=y.htmlMode?b:c;for(var f in l){z[f]=l[f]}for(var f in y){z[f]=y[f]}var g,h;function p(G,F){function D(H){F.tokenize=H;return H(G,F)}var E=G.next();if(E=="<"){if(G.eat("!")){if(G.eat("[")){if(G.match("CDATA[")){return D(x("atom","]]>"))}else{return null}}else{if(G.match("--")){return D(x("comment","-->"))}else{if(G.match("DOCTYPE",true,true)){G.eatWhile(/[\w\._\-]/);return D(A(1))}else{return null}}}}else{if(G.eat("?")){G.eatWhile(/[\w\._\-]/);F.tokenize=x("meta","?>");return"meta"}else{g=G.eat("/")?"closeTag":"openTag";F.tokenize=o;return"tag bracket"}}}else{if(E=="&"){var C;if(G.eat("#")){if(G.eat("x")){C=G.eatWhile(/[a-fA-F\d]/)&&G.eat(";")}else{C=G.eatWhile(/[\d]/)&&G.eat(";")}}else{C=G.eatWhile(/[\w\.\-:]/)&&G.eat(";")}return C?"atom":"error"}else{G.eatWhile(/[^&<]/);return null}}}p.isInText=true;function o(F,E){var D=F.next();if(D==">"||(D=="/"&&F.eat(">"))){E.tokenize=p;g=D==">"?"endTag":"selfcloseTag";return"tag bracket"}else{if(D=="="){g="equals";return null}else{if(D=="<"){E.tokenize=p;E.state=n;E.tagName=E.tagStart=null;var C=E.tokenize(F,E);return C?C+" tag error":"tag error"}else{if(/[\'\"]/.test(D)){E.tokenize=k(D);E.stringStartCol=F.column();return E.tokenize(F,E)}else{F.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/);return"word"}}}}}function k(C){var D=function(F,E){while(!F.eol()){if(F.next()==C){E.tokenize=o;break}}return"string"};D.isInAttribute=true;return D}function x(D,C){return function(F,E){while(!F.eol()){if(F.match(C)){E.tokenize=p;break}F.next()}return D}}function A(C){return function(F,E){var D;while((D=F.next())!=null){if(D=="<"){E.tokenize=A(C+1);return E.tokenize(F,E)}else{if(D==">"){if(C==1){E.tokenize=p;break}else{E.tokenize=A(C-1);return E.tokenize(F,E)}}}}return"meta"}}function t(D,C,E){this.prev=D.context;this.tagName=C;this.indent=D.indented;this.startOfLine=E;if(z.doNotIndent.hasOwnProperty(C)||(D.context&&D.context.noIndent)){this.noIndent=true}}function w(C){if(C.context){C.context=C.context.prev}}function s(E,D){var C;while(true){if(!E.context){return}C=E.context.tagName;if(!z.contextGrabbers.hasOwnProperty(C)||!z.contextGrabbers[C].hasOwnProperty(D)){return}w(E)}}function n(C,E,D){if(C=="openTag"){D.tagStart=E.column();return d}else{if(C=="closeTag"){return v}else{return n}}}function d(C,E,D){if(C=="word"){D.tagName=E.current();h="tag";return e}else{h="error";return d}}function v(D,F,E){if(D=="word"){var C=F.current();if(E.context&&E.context.tagName!=C&&z.implicitlyClosed.hasOwnProperty(E.context.tagName)){w(E)}if((E.context&&E.context.tagName==C)||z.matchClosing===false){h="tag";return u}else{h="tag error";return B}}else{h="error";return B}}function u(D,C,E){if(D!="endTag"){h="error";return u}w(E);return n}function B(C,E,D){h="error";return u(C,E,D)}function e(F,D,G){if(F=="word"){h="attribute";return j}else{if(F=="endTag"||F=="selfcloseTag"){var E=G.tagName,C=G.tagStart;G.tagName=G.tagStart=null;if(F=="selfcloseTag"||z.autoSelfClosers.hasOwnProperty(E)){s(G,E)}else{s(G,E);G.context=new t(G,E,C==G.indented)}return n}}h="error";return e}function j(C,E,D){if(C=="equals"){return q}if(!z.allowMissing){h="error"}return e(C,E,D)}function q(C,E,D){if(C=="string"){return i}if(C=="word"&&z.allowUnquoted){h="string";return e}h="error";return e(C,E,D)}function i(C,E,D){if(C=="string"){return i}return e(C,E,D)}return{startState:function(C){var D={tokenize:p,state:n,indented:C||0,tagName:null,tagStart:null,context:null};if(C!=null){D.baseIndent=C}return D},token:function(E,D){if(!D.tagName&&E.sol()){D.indented=E.indentation()}if(E.eatSpace()){return null}g=null;var C=D.tokenize(E,D);if((C||g)&&C!="comment"){h=null;D.state=D.state(g||C,E,D);if(h){C=h=="error"?C+" error":h}}return C},indent:function(H,D,G){var F=H.context;if(H.tokenize.isInAttribute){if(H.tagStart==H.indented){return H.stringStartCol+1}else{return H.indented+r}}if(F&&F.noIndent){return a.Pass}if(H.tokenize!=o&&H.tokenize!=p){return G?G.match(/^(\s*)/)[0].length:0}if(H.tagName){if(z.multilineTagIndentPastTag!==false){return H.tagStart+H.tagName.length+2}else{return H.tagStart+r*(z.multilineTagIndentFactor||1)}}if(z.alignCDATA&&/$/,blockCommentStart:"",configuration:z.htmlMode?"html":"xml",helperType:z.htmlMode?"html":"xml",skipAttribute:function(C){if(C.state==q){C.state=e}}}});a.defineMIME("text/xml","xml");a.defineMIME("application/xml","xml");if(!a.mimeModes.hasOwnProperty("text/html")){a.defineMIME("text/html",{name:"xml",htmlMode:true})}});(function(a){if(typeof exports=="object"&&typeof module=="object"){a(require("../../lib/codemirror"))}else{if(typeof define=="function"&&define.amd){define(["../../lib/codemirror"],a)}else{a(CodeMirror)}}})(function(a){a.defineMode("javascript",function(ag,ar){var n=ag.indentUnit;var D=ar.statementIndent;var aH=ar.jsonld;var C=ar.json||aH;var g=ar.typescript;var aC=ar.wordCharacters||/[\w$\xa1-\uffff]/;var aA=function(){function a0(a2){return{type:a2,style:"keyword"}}var aV=a0("keyword a"),aT=a0("keyword b"),aS=a0("keyword c"),aR=a0("keyword d");var aU=a0("operator"),aY={type:"atom",style:"atom"};var aW={"if":a0("if"),"while":aV,"with":aV,"else":aT,"do":aT,"try":aT,"finally":aT,"return":aR,"break":aR,"continue":aR,"new":a0("new"),"delete":aS,"void":aS,"throw":aS,"debugger":a0("debugger"),"var":a0("var"),"const":a0("var"),let:a0("var"),"function":a0("function"),"catch":a0("catch"),"for":a0("for"),"switch":a0("switch"),"case":a0("case"),"default":a0("default"),"in":aU,"typeof":aU,"instanceof":aU,"true":aY,"false":aY,"null":aY,"undefined":aY,"NaN":aY,"Infinity":aY,"this":a0("this"),"class":a0("class"),"super":a0("atom"),yield:aS,"export":a0("export"),"import":a0("import"),"extends":aS,await:aS};if(g){var a1={type:"variable",style:"type"};var aX={"interface":a0("class"),"implements":aS,namespace:aS,module:a0("module"),"enum":a0("module"),"public":a0("modifier"),"private":a0("modifier"),"protected":a0("modifier"),"abstract":a0("modifier"),readonly:a0("modifier"),string:a1,number:a1,"boolean":a1,any:a1};for(var aZ in aX){aW[aZ]=aX[aZ]}}return aW}();var U=/[+\-*&%=<>!?|~^@]/;var az=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function I(aU){var aS=false,aR,aT=false;while((aR=aU.next())!=null){if(!aS){if(aR=="/"&&!aT){return}if(aR=="["){aT=true}else{if(aT&&aR=="]"){aT=false}}}aS=!aS&&aR=="\\"}}var Y,J;function Q(aT,aS,aR){Y=aT;J=aR;return aS}function aa(aV,aT){var aR=aV.next();if(aR=='"'||aR=="'"){aT.tokenize=X(aR);return aT.tokenize(aV,aT)}else{if(aR=="."&&aV.match(/^\d+(?:[eE][+\-]?\d+)?/)){return Q("number","number")}else{if(aR=="."&&aV.match("..")){return Q("spread","meta")}else{if(/[\[\]{}\(\),;\:\.]/.test(aR)){return Q(aR)}else{if(aR=="="&&aV.eat(">")){return Q("=>","operator")}else{if(aR=="0"&&aV.eat(/x/i)){aV.eatWhile(/[\da-f]/i);return Q("number","number")}else{if(aR=="0"&&aV.eat(/o/i)){aV.eatWhile(/[0-7]/i);return Q("number","number")}else{if(aR=="0"&&aV.eat(/b/i)){aV.eatWhile(/[01]/i);return Q("number","number")}else{if(/\d/.test(aR)){aV.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/);return Q("number","number")}else{if(aR=="/"){if(aV.eat("*")){aT.tokenize=aG;return aG(aV,aT)}else{if(aV.eat("/")){aV.skipToEnd();return Q("comment","comment")}else{if(aO(aV,aT,1)){I(aV);aV.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/);return Q("regexp","string-2")}else{aV.eat("=");return Q("operator","operator",aV.current())}}}}else{if(aR=="`"){aT.tokenize=aI;return aI(aV,aT)}else{if(aR=="#"){aV.skipToEnd();return Q("error","error")}else{if(U.test(aR)){if(aR!=">"||!aT.lexical||aT.lexical.type!=">"){if(aV.eat("=")){if(aR=="!"||aR=="="){aV.eat("=")}}else{if(/[<>*+\-]/.test(aR)){aV.eat(aR);if(aR==">"){aV.eat(aR)}}}}return Q("operator","operator",aV.current())}else{if(aC.test(aR)){aV.eatWhile(aC);var aU=aV.current();if(aT.lastType!="."){if(aA.propertyIsEnumerable(aU)){var aS=aA[aU];return Q(aS.type,aS.style,aU)}if(aU=="async"&&aV.match(/^\s*[\(\w]/,false)){return Q("async","keyword",aU)}}return Q("variable","variable",aU)}}}}}}}}}}}}}}}function X(aR){return function(aV,aT){var aU=false,aS;if(aH&&aV.peek()=="@"&&aV.match(az)){aT.tokenize=aa;return Q("jsonld-keyword","meta")}while((aS=aV.next())!=null){if(aS==aR&&!aU){break}aU=!aU&&aS=="\\"}if(!aU){aT.tokenize=aa}return Q("string","string")}}function aG(aU,aT){var aR=false,aS;while(aS=aU.next()){if(aS=="/"&&aR){aT.tokenize=aa;break}aR=(aS=="*")}return Q("comment","comment")}function aI(aU,aS){var aT=false,aR;while((aR=aU.next())!=null){if(!aT&&(aR=="`"||aR=="$"&&aU.eat("{"))){aS.tokenize=aa;break}aT=!aT&&aR=="\\"}return Q("quasi","string-2",aU.current())}var o="([{}])";function aE(aZ,aT){if(aT.fatArrowAt){aT.fatArrowAt=null}var aY=aZ.string.indexOf("=>",aZ.start);if(aY<0){return}if(g){var aV=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(aZ.string.slice(aZ.start,aY));if(aV){aY=aV.index}}var aW=0,aU=false;for(var aX=aY-1;aX>=0;--aX){var aR=aZ.string.charAt(aX);var aS=o.indexOf(aR);if(aS>=0&&aS<3){if(!aW){++aX;break}if(--aW==0){if(aR=="("){aU=true}break}}else{if(aS>=3&&aS<6){++aW}else{if(aC.test(aR)){aU=true}else{if(/["'\/]/.test(aR)){return}else{if(aU&&!aW){++aX;break}}}}}}if(aU&&!aW){aT.fatArrowAt=aX}}var b={atom:true,number:true,variable:true,string:true,regexp:true,"this":true,"jsonld-keyword":true};function O(aW,aS,aR,aV,aT,aU){this.indented=aW;this.column=aS;this.type=aR;this.prev=aT;this.info=aU;if(aV!=null){this.align=aV}}function v(aU,aT){for(var aS=aU.localVars;aS;aS=aS.next){if(aS.name==aT){return true}}for(var aR=aU.context;aR;aR=aR.prev){for(var aS=aR.vars;aS;aS=aS.next){if(aS.name==aT){return true}}}}function f(aV,aS,aR,aU,aW){var aX=aV.cc;H.state=aV;H.stream=aW;H.marked=null,H.cc=aX;H.style=aS;if(!aV.lexical.hasOwnProperty("align")){aV.lexical.align=true}while(true){var aT=aX.length?aX.pop():C?av:aN;if(aT(aR,aU)){while(aX.length&&aX[aX.length-1].lex){aX.pop()()}if(H.marked){return H.marked}if(aR=="variable"&&v(aV,aU)){return"variable-2"}return aS}}}var H={state:null,column:null,marked:null,cc:null};function ah(){for(var aR=arguments.length-1;aR>=0;aR--){H.cc.push(arguments[aR])}}function am(){ah.apply(null,arguments);return true}function aD(aS){function aR(aV){for(var aU=aV;aU;aU=aU.next){if(aU.name==aS){return true}}return false}var aT=H.state;H.marked="def";if(aT.context){if(aR(aT.localVars)){return}aT.localVars={name:aS,next:aT.localVars}}else{if(aR(aT.globalVars)){return}if(ar.globalVars){aT.globalVars={name:aS,next:aT.globalVars}}}}var t={name:"this",next:{name:"arguments"}};function z(){H.state.context={prev:H.state.context,vars:H.state.localVars};H.state.localVars=t}function A(){H.state.localVars=H.state.context.vars;H.state.context=H.state.context.prev}function aL(aS,aT){var aR=function(){var aW=H.state,aU=aW.indented;if(aW.lexical.type=="stat"){aU=aW.lexical.indented}else{for(var aV=aW.lexical;aV&&aV.type==")"&&aV.align;aV=aV.prev){aU=aV.indented}}aW.lexical=new O(aU,H.stream.column(),aS,null,aW.lexical,aT)};aR.lex=true;return aR}function h(){var aR=H.state;if(aR.lexical.prev){if(aR.lexical.type==")"){aR.indented=aR.lexical.indented}aR.lexical=aR.lexical.prev}}h.lex=true;function u(aR){function aS(aT){if(aT==aR){return am()}else{if(aR==";"){return ah()}else{return am(aS)}}}return aS}function aN(aR,aS){if(aR=="var"){return am(aL("vardef",aS.length),c,u(";"),h)}if(aR=="keyword a"){return am(aL("form"),aw,aN,h)}if(aR=="keyword b"){return am(aL("form"),aN,h)}if(aR=="keyword d"){return H.stream.match(/^\s*$/,false)?am():am(aL("stat"),aq,u(";"),h)}if(aR=="debugger"){return am(u(";"))}if(aR=="{"){return am(aL("}"),B,h)}if(aR==";"){return am()}if(aR=="if"){if(H.state.lexical.info=="else"&&H.state.cc[H.state.cc.length-1]==h){H.state.cc.pop()()}return am(aL("form"),aw,aN,h,d)}if(aR=="function"){return am(R)}if(aR=="for"){return am(aL("form"),x,aN,h)}if(aR=="variable"){if(g&&aS=="type"){H.marked="keyword";return am(j,u("operator"),j,u(";"))}if(g&&aS=="declare"){H.marked="keyword";return am(aN)}else{return am(aL("stat"),aP)}}if(aR=="switch"){return am(aL("form"),aw,u("{"),aL("}","switch"),B,h,h)}if(aR=="case"){return am(av,u(":"))}if(aR=="default"){return am(u(":"))}if(aR=="catch"){return am(aL("form"),z,u("("),al,u(")"),aN,h,A)}if(aR=="class"){return am(aL("form"),ac,h)}if(aR=="export"){return am(aL("stat"),aM,h)}if(aR=="import"){return am(aL("stat"),an,h)}if(aR=="module"){return am(aL("form"),i,u("{"),aL("}"),B,h,h)}if(aR=="async"){return am(aN)}if(aS=="@"){return am(av,aN)}return ah(aL("stat"),av,u(";"),h)}function av(aR){return af(aR,false)}function aK(aR){return af(aR,true)}function aw(aR){if(aR!="("){return ah()}return am(aL(")"),av,u(")"),h)}function af(aS,aU){if(H.state.fatArrowAt==H.stream.start){var aR=aU?S:ad;if(aS=="("){return am(z,aL(")"),aB(al,")"),h,u("=>"),aR,A)}else{if(aS=="variable"){return ah(z,i,u("=>"),aR,A)}}}var aT=aU?k:ai;if(b.hasOwnProperty(aS)){return am(aT)}if(aS=="function"){return am(R,aT)}if(aS=="class"){return am(aL("form"),M,h)}if(aS=="keyword c"||aS=="async"){return am(aU?aK:av)}if(aS=="("){return am(aL(")"),aq,u(")"),h,aT)}if(aS=="operator"||aS=="spread"){return am(aU?aK:av)}if(aS=="["){return am(aL("]"),p,h,aT)}if(aS=="{"){return aF(w,"}",null,aT)}if(aS=="quasi"){return ah(V,aT)}if(aS=="new"){return am(L(aU))}return am()}function aq(aR){if(aR.match(/[;\}\)\],]/)){return ah()}return ah(av)}function ai(aR,aS){if(aR==","){return am(av)}return k(aR,aS,false)}function k(aR,aT,aV){var aS=aV==false?ai:k;var aU=aV==false?av:aK;if(aR=="=>"){return am(z,aV?S:ad,A)}if(aR=="operator"){if(/\+\+|--/.test(aT)||g&&aT=="!"){return am(aS)}if(aT=="?"){return am(av,u(":"),aU)}return am(aU)}if(aR=="quasi"){return ah(V,aS)}if(aR==";"){return}if(aR=="("){return aF(aK,")","call",aS)}if(aR=="."){return am(at,aS)}if(aR=="["){return am(aL("]"),aq,u("]"),h,aS)}if(g&&aT=="as"){H.marked="keyword";return am(j,aS)}if(aR=="regexp"){H.state.lastType=H.marked="operator";H.stream.backUp(H.stream.pos-H.stream.start-1);return am(aU)}}function V(aR,aS){if(aR!="quasi"){return ah()}if(aS.slice(aS.length-2)!="${"){return am(V)}return am(av,s)}function s(aR){if(aR=="}"){H.marked="string-2";H.state.tokenize=aI;return am(V)}}function ad(aR){aE(H.stream,H.state);return ah(aR=="{"?aN:av)}function S(aR){aE(H.stream,H.state);return ah(aR=="{"?aN:aK)}function L(aR){return function(aS){if(aS=="."){return am(aR?q:ab)}else{if(aS=="variable"&&g){return am(e,aR?k:ai)}else{return ah(aR?aK:av)}}}}function ab(aR,aS){if(aS=="target"){H.marked="keyword";return am(ai)}}function q(aR,aS){if(aS=="target"){H.marked="keyword";return am(k)}}function aP(aR){if(aR==":"){return am(h,aN)}return ah(ai,u(";"),h)}function at(aR){if(aR=="variable"){H.marked="property";return am()}}function w(aS,aT){if(aS=="async"){H.marked="property";return am(w)}else{if(aS=="variable"||H.style=="keyword"){H.marked="property";if(aT=="get"||aT=="set"){return am(N)}var aR;if(g&&H.state.fatArrowAt==H.stream.start&&(aR=H.stream.match(/^\s*:\s*/,false))){H.state.fatArrowAt=H.stream.pos+aR[0].length}return am(P)}else{if(aS=="number"||aS=="string"){H.marked=aH?"property":(H.style+" property");return am(P)}else{if(aS=="jsonld-keyword"){return am(P)}else{if(aS=="modifier"){return am(w)}else{if(aS=="["){return am(av,u("]"),P)}else{if(aS=="spread"){return am(aK,P)}else{if(aT=="*"){H.marked="keyword";return am(w)}else{if(aS==":"){return ah(P)}}}}}}}}}}function N(aR){if(aR!="variable"){return ah(P)}H.marked="property";return am(R)}function P(aR){if(aR==":"){return am(aK)}if(aR=="("){return ah(R)}}function aB(aU,aR,aS){function aT(aW,aX){if(aS?aS.indexOf(aW)>-1:aW==","){var aV=H.state.lexical;if(aV.info=="call"){aV.pos=(aV.pos||0)+1}return am(function(aY,aZ){if(aY==aR||aZ==aR){return ah()}return ah(aU)},aT)}if(aW==aR||aX==aR){return am()}return am(u(aR))}return function(aV,aW){if(aV==aR||aW==aR){return am()}return ah(aU,aT)}}function aF(aU,aR,aT){for(var aS=3;aS
|
1
|
+
(function(a){if(typeof exports=="object"&&typeof module=="object"){a(require("../../lib/codemirror"))}else{if(typeof define=="function"&&define.amd){define(["../../lib/codemirror"],a)}else{a(CodeMirror)}}})(function(a){var b={autoSelfClosers:{area:true,base:true,br:true,col:true,command:true,embed:true,frame:true,hr:true,img:true,input:true,keygen:true,link:true,meta:true,param:true,source:true,track:true,wbr:true,menuitem:true},implicitlyClosed:{dd:true,li:true,optgroup:true,option:true,p:true,rp:true,rt:true,tbody:true,td:true,tfoot:true,th:true,tr:true},contextGrabbers:{dd:{dd:true,dt:true},dt:{dd:true,dt:true},li:{li:true},option:{option:true,optgroup:true},optgroup:{optgroup:true},p:{address:true,article:true,aside:true,blockquote:true,dir:true,div:true,dl:true,fieldset:true,footer:true,form:true,h1:true,h2:true,h3:true,h4:true,h5:true,h6:true,header:true,hgroup:true,hr:true,menu:true,nav:true,ol:true,p:true,pre:true,section:true,table:true,ul:true},rp:{rp:true,rt:true},rt:{rp:true,rt:true},tbody:{tbody:true,tfoot:true},td:{td:true,th:true},tfoot:{tbody:true},th:{td:true,th:true},thead:{tbody:true,tfoot:true},tr:{tr:true}},doNotIndent:{pre:true},allowUnquoted:true,allowMissing:true,caseFold:true};var c={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:false,allowMissing:false,allowMissingTagName:false,caseFold:false};a.defineMode("xml",function(m,y){var r=m.indentUnit;var z={};var l=y.htmlMode?b:c;for(var f in l){z[f]=l[f]}for(var f in y){z[f]=y[f]}var g,h;function p(G,F){function D(H){F.tokenize=H;return H(G,F)}var E=G.next();if(E=="<"){if(G.eat("!")){if(G.eat("[")){if(G.match("CDATA[")){return D(x("atom","]]>"))}else{return null}}else{if(G.match("--")){return D(x("comment","-->"))}else{if(G.match("DOCTYPE",true,true)){G.eatWhile(/[\w\._\-]/);return D(A(1))}else{return null}}}}else{if(G.eat("?")){G.eatWhile(/[\w\._\-]/);F.tokenize=x("meta","?>");return"meta"}else{g=G.eat("/")?"closeTag":"openTag";F.tokenize=o;return"tag bracket"}}}else{if(E=="&"){var C;if(G.eat("#")){if(G.eat("x")){C=G.eatWhile(/[a-fA-F\d]/)&&G.eat(";")}else{C=G.eatWhile(/[\d]/)&&G.eat(";")}}else{C=G.eatWhile(/[\w\.\-:]/)&&G.eat(";")}return C?"atom":"error"}else{G.eatWhile(/[^&<]/);return null}}}p.isInText=true;function o(F,E){var D=F.next();if(D==">"||(D=="/"&&F.eat(">"))){E.tokenize=p;g=D==">"?"endTag":"selfcloseTag";return"tag bracket"}else{if(D=="="){g="equals";return null}else{if(D=="<"){E.tokenize=p;E.state=n;E.tagName=E.tagStart=null;var C=E.tokenize(F,E);return C?C+" tag error":"tag error"}else{if(/[\'\"]/.test(D)){E.tokenize=k(D);E.stringStartCol=F.column();return E.tokenize(F,E)}else{F.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/);return"word"}}}}}function k(C){var D=function(F,E){while(!F.eol()){if(F.next()==C){E.tokenize=o;break}}return"string"};D.isInAttribute=true;return D}function x(D,C){return function(F,E){while(!F.eol()){if(F.match(C)){E.tokenize=p;break}F.next()}return D}}function A(C){return function(F,E){var D;while((D=F.next())!=null){if(D=="<"){E.tokenize=A(C+1);return E.tokenize(F,E)}else{if(D==">"){if(C==1){E.tokenize=p;break}else{E.tokenize=A(C-1);return E.tokenize(F,E)}}}}return"meta"}}function t(D,C,E){this.prev=D.context;this.tagName=C;this.indent=D.indented;this.startOfLine=E;if(z.doNotIndent.hasOwnProperty(C)||(D.context&&D.context.noIndent)){this.noIndent=true}}function w(C){if(C.context){C.context=C.context.prev}}function s(E,D){var C;while(true){if(!E.context){return}C=E.context.tagName;if(!z.contextGrabbers.hasOwnProperty(C)||!z.contextGrabbers[C].hasOwnProperty(D)){return}w(E)}}function n(C,E,D){if(C=="openTag"){D.tagStart=E.column();return d}else{if(C=="closeTag"){return v}else{return n}}}function d(C,E,D){if(C=="word"){D.tagName=E.current();h="tag";return e}else{if(z.allowMissingTagName&&C=="endTag"){h="tag bracket";return e(C,E,D)}else{h="error";return d}}}function v(D,F,E){if(D=="word"){var C=F.current();if(E.context&&E.context.tagName!=C&&z.implicitlyClosed.hasOwnProperty(E.context.tagName)){w(E)}if((E.context&&E.context.tagName==C)||z.matchClosing===false){h="tag";return u}else{h="tag error";return B}}else{if(z.allowMissingTagName&&D=="endTag"){h="tag bracket";return u(D,F,E)}else{h="error";return B}}}function u(D,C,E){if(D!="endTag"){h="error";return u}w(E);return n}function B(C,E,D){h="error";return u(C,E,D)}function e(F,D,G){if(F=="word"){h="attribute";return j}else{if(F=="endTag"||F=="selfcloseTag"){var E=G.tagName,C=G.tagStart;G.tagName=G.tagStart=null;if(F=="selfcloseTag"||z.autoSelfClosers.hasOwnProperty(E)){s(G,E)}else{s(G,E);G.context=new t(G,E,C==G.indented)}return n}}h="error";return e}function j(C,E,D){if(C=="equals"){return q}if(!z.allowMissing){h="error"}return e(C,E,D)}function q(C,E,D){if(C=="string"){return i}if(C=="word"&&z.allowUnquoted){h="string";return e}h="error";return e(C,E,D)}function i(C,E,D){if(C=="string"){return i}return e(C,E,D)}return{startState:function(C){var D={tokenize:p,state:n,indented:C||0,tagName:null,tagStart:null,context:null};if(C!=null){D.baseIndent=C}return D},token:function(E,D){if(!D.tagName&&E.sol()){D.indented=E.indentation()}if(E.eatSpace()){return null}g=null;var C=D.tokenize(E,D);if((C||g)&&C!="comment"){h=null;D.state=D.state(g||C,E,D);if(h){C=h=="error"?C+" error":h}}return C},indent:function(H,D,G){var F=H.context;if(H.tokenize.isInAttribute){if(H.tagStart==H.indented){return H.stringStartCol+1}else{return H.indented+r}}if(F&&F.noIndent){return a.Pass}if(H.tokenize!=o&&H.tokenize!=p){return G?G.match(/^(\s*)/)[0].length:0}if(H.tagName){if(z.multilineTagIndentPastTag!==false){return H.tagStart+H.tagName.length+2}else{return H.tagStart+r*(z.multilineTagIndentFactor||1)}}if(z.alignCDATA&&/$/,blockCommentStart:"",configuration:z.htmlMode?"html":"xml",helperType:z.htmlMode?"html":"xml",skipAttribute:function(C){if(C.state==q){C.state=e}}}});a.defineMIME("text/xml","xml");a.defineMIME("application/xml","xml");if(!a.mimeModes.hasOwnProperty("text/html")){a.defineMIME("text/html",{name:"xml",htmlMode:true})}});(function(a){if(typeof exports=="object"&&typeof module=="object"){a(require("../../lib/codemirror"))}else{if(typeof define=="function"&&define.amd){define(["../../lib/codemirror"],a)}else{a(CodeMirror)}}})(function(a){a.defineMode("javascript",function(an,aA){var p=an.indentUnit;var F=aA.statementIndent;var aT=aA.jsonld;var D=aA.json||aT;var h=aA.typescript;var aL=aA.wordCharacters||/[\w$\xa1-\uffff]/;var aJ=function(){function a8(bc){return{type:bc,style:"keyword"}}var a5=a8("keyword a"),bb=a8("keyword b"),ba=a8("keyword c"),a9=a8("keyword d");var a6=a8("operator"),a7={type:"atom",style:"atom"};return{"if":a8("if"),"while":a5,"with":a5,"else":bb,"do":bb,"try":bb,"finally":bb,"return":a9,"break":a9,"continue":a9,"new":a8("new"),"delete":ba,"void":ba,"throw":ba,"debugger":a8("debugger"),"var":a8("var"),"const":a8("var"),let:a8("var"),"function":a8("function"),"catch":a8("catch"),"for":a8("for"),"switch":a8("switch"),"case":a8("case"),"default":a8("default"),"in":a6,"typeof":a6,"instanceof":a6,"true":a7,"false":a7,"null":a7,"undefined":a7,"NaN":a7,"Infinity":a7,"this":a8("this"),"class":a8("class"),"super":a8("atom"),yield:ba,"export":a8("export"),"import":a8("import"),"extends":ba,await:ba}}();var Y=/[+\-*&%=<>!?|~^@]/;var aI=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function J(a8){var a6=false,a5,a7=false;while((a5=a8.next())!=null){if(!a6){if(a5=="/"&&!a7){return}if(a5=="["){a7=true}else{if(a7&&a5=="]"){a7=false}}}a6=!a6&&a5=="\\"}}var ad,K;function S(a7,a6,a5){ad=a7;K=a5;return a6}function af(a9,a7){var a5=a9.next();if(a5=='"'||a5=="'"){a7.tokenize=ac(a5);return a7.tokenize(a9,a7)}else{if(a5=="."&&a9.match(/^\d+(?:[eE][+\-]?\d+)?/)){return S("number","number")}else{if(a5=="."&&a9.match("..")){return S("spread","meta")}else{if(/[\[\]{}\(\),;\:\.]/.test(a5)){return S(a5)}else{if(a5=="="&&a9.eat(">")){return S("=>","operator")}else{if(a5=="0"&&a9.match(/^(?:x[\da-f]+|o[0-7]+|b[01]+)n?/i)){return S("number","number")}else{if(/\d/.test(a5)){a9.match(/^\d*(?:n|(?:\.\d*)?(?:[eE][+\-]?\d+)?)?/);return S("number","number")}else{if(a5=="/"){if(a9.eat("*")){a7.tokenize=aS;return aS(a9,a7)}else{if(a9.eat("/")){a9.skipToEnd();return S("comment","comment")}else{if(a1(a9,a7,1)){J(a9);a9.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/);return S("regexp","string-2")}else{a9.eat("=");return S("operator","operator",a9.current())}}}}else{if(a5=="`"){a7.tokenize=aV;return aV(a9,a7)}else{if(a5=="#"){a9.skipToEnd();return S("error","error")}else{if(Y.test(a5)){if(a5!=">"||!a7.lexical||a7.lexical.type!=">"){if(a9.eat("=")){if(a5=="!"||a5=="="){a9.eat("=")}}else{if(/[<>*+\-]/.test(a5)){a9.eat(a5);if(a5==">"){a9.eat(a5)}}}}return S("operator","operator",a9.current())}else{if(aL.test(a5)){a9.eatWhile(aL);var a8=a9.current();if(a7.lastType!="."){if(aJ.propertyIsEnumerable(a8)){var a6=aJ[a8];return S(a6.type,a6.style,a8)}if(a8=="async"&&a9.match(/^(\s|\/\*.*?\*\/)*[\[\(\w]/,false)){return S("async","keyword",a8)}}return S("variable","variable",a8)}}}}}}}}}}}}}function ac(a5){return function(a9,a7){var a8=false,a6;if(aT&&a9.peek()=="@"&&a9.match(aI)){a7.tokenize=af;return S("jsonld-keyword","meta")}while((a6=a9.next())!=null){if(a6==a5&&!a8){break}a8=!a8&&a6=="\\"}if(!a8){a7.tokenize=af}return S("string","string")}}function aS(a8,a7){var a5=false,a6;while(a6=a8.next()){if(a6=="/"&&a5){a7.tokenize=af;break}a5=(a6=="*")}return S("comment","comment")}function aV(a8,a6){var a7=false,a5;while((a5=a8.next())!=null){if(!a7&&(a5=="`"||a5=="$"&&a8.eat("{"))){a6.tokenize=af;break}a7=!a7&&a5=="\\"}return S("quasi","string-2",a8.current())}var q="([{}])";function aP(bd,a7){if(a7.fatArrowAt){a7.fatArrowAt=null}var bc=bd.string.indexOf("=>",bd.start);if(bc<0){return}if(h){var a9=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(bd.string.slice(bd.start,bc));if(a9){bc=a9.index}}var ba=0,a8=false;for(var bb=bc-1;bb>=0;--bb){var a5=bd.string.charAt(bb);var a6=q.indexOf(a5);if(a6>=0&&a6<3){if(!ba){++bb;break}if(--ba==0){if(a5=="("){a8=true}break}}else{if(a6>=3&&a6<6){++ba}else{if(aL.test(a5)){a8=true}else{if(/["'\/]/.test(a5)){return}else{if(a8&&!ba){++bb;break}}}}}}if(a8&&!ba){a7.fatArrowAt=bb}}var b={atom:true,number:true,variable:true,string:true,regexp:true,"this":true,"jsonld-keyword":true};function Q(ba,a6,a5,a9,a7,a8){this.indented=ba;this.column=a6;this.type=a5;this.prev=a7;this.info=a8;if(a9!=null){this.align=a9}}function x(a8,a7){for(var a6=a8.localVars;a6;a6=a6.next){if(a6.name==a7){return true}}for(var a5=a8.context;a5;a5=a5.prev){for(var a6=a5.vars;a6;a6=a6.next){if(a6.name==a7){return true}}}}function g(a9,a6,a5,a8,ba){var bb=a9.cc;I.state=a9;I.stream=ba;I.marked=null,I.cc=bb;I.style=a6;if(!a9.lexical.hasOwnProperty("align")){a9.lexical.align=true}while(true){var a7=bb.length?bb.pop():D?aE:aZ;if(a7(a5,a8)){while(bb.length&&bb[bb.length-1].lex){bb.pop()()}if(I.marked){return I.marked}if(a5=="variable"&&x(a9,a8)){return"variable-2"}return a6}}}var I={state:null,column:null,marked:null,cc:null};function ap(){for(var a5=arguments.length-1;a5>=0;a5--){I.cc.push(arguments[a5])}}function av(){ap.apply(null,arguments);return true}function f(a6,a7){for(var a5=a7;a5;a5=a5.next){if(a5.name==a6){return true}}return false}function aO(a5){var a6=I.state;I.marked="def";if(a6.context){if(a6.lexical.info=="var"&&a6.context&&a6.context.block){var a7=aN(a5,a6.context);if(a7!=null){a6.context=a7;return}}else{if(!f(a5,a6.localVars)){a6.localVars=new a0(a5,a6.localVars);return}}}if(aA.globalVars&&!f(a5,a6.globalVars)){a6.globalVars=new a0(a5,a6.globalVars)}}function aN(a6,a7){if(!a7){return null}else{if(a7.block){var a5=aN(a6,a7.prev);if(!a5){return null}if(a5==a7.prev){return a7}return new P(a5,a7.vars,true)}else{if(f(a6,a7.vars)){return a7}else{return new P(a7.prev,new a0(a6,a7.vars),false)}}}}function aB(a5){return a5=="public"||a5=="private"||a5=="protected"||a5=="abstract"||a5=="readonly"}function P(a5,a6,a7){this.prev=a5;this.vars=a6;this.block=a7}function a0(a5,a6){this.name=a5;this.next=a6}var v=new a0("this",new a0("arguments",null));function A(){I.state.context=new P(I.state.context,I.state.localVars,false);I.state.localVars=v}function al(){I.state.context=new P(I.state.context,I.state.localVars,true);I.state.localVars=null}function B(){I.state.localVars=I.state.context.vars;I.state.context=I.state.context.prev}B.lex=true;function aX(a6,a7){var a5=function(){var ba=I.state,a8=ba.indented;if(ba.lexical.type=="stat"){a8=ba.lexical.indented}else{for(var a9=ba.lexical;a9&&a9.type==")"&&a9.align;a9=a9.prev){a8=a9.indented}}ba.lexical=new Q(a8,I.stream.column(),a6,null,ba.lexical,a7)};a5.lex=true;return a5}function i(){var a5=I.state;if(a5.lexical.prev){if(a5.lexical.type==")"){a5.indented=a5.lexical.indented}a5.lexical=a5.lexical.prev}}i.lex=true;function w(a5){function a6(a7){if(a7==a5){return av()}else{if(a5==";"||a7=="}"||a7==")"||a7=="]"){return ap()}else{return av(a6)}}}return a6}function aZ(a5,a6){if(a5=="var"){return av(aX("vardef",a6),c,w(";"),i)}if(a5=="keyword a"){return av(aX("form"),aF,aZ,i)}if(a5=="keyword b"){return av(aX("form"),aZ,i)}if(a5=="keyword d"){return I.stream.match(/^\s*$/,false)?av():av(aX("stat"),az,w(";"),i)}if(a5=="debugger"){return av(w(";"))}if(a5=="{"){return av(aX("}"),al,C,i,B)}if(a5==";"){return av()}if(a5=="if"){if(I.state.lexical.info=="else"&&I.state.cc[I.state.cc.length-1]==i){I.state.cc.pop()()}return av(aX("form"),aF,aZ,i,d)}if(a5=="function"){return av(T)}if(a5=="for"){return av(aX("form"),z,aZ,i)}if(a5=="class"||(h&&a6=="interface")){I.marked="keyword";return av(aX("form",a5=="class"?a5:a6),ai,i)}if(a5=="variable"){if(h&&a6=="declare"){I.marked="keyword";return av(aZ)}else{if(h&&(a6=="module"||a6=="enum"||a6=="type")&&I.stream.match(/^\s*\w/,false)){I.marked="keyword";if(a6=="enum"){return av(aM)}else{if(a6=="type"){return av(ao,w("operator"),k,w(";"))}else{return av(aX("form"),j,w("{"),aX("}"),C,i,i)}}}else{if(h&&a6=="namespace"){I.marked="keyword";return av(aX("form"),aE,aZ,i)}else{if(h&&a6=="abstract"){I.marked="keyword";return av(aZ)}else{return av(aX("stat"),a2)}}}}}if(a5=="switch"){return av(aX("form"),aF,w("{"),aX("}","switch"),al,C,i,i,B)}if(a5=="case"){return av(aE,w(":"))}if(a5=="default"){return av(w(":"))}if(a5=="catch"){return av(aX("form"),A,W,aZ,i,B)}if(a5=="export"){return av(aX("stat"),aY,i)}if(a5=="import"){return av(aX("stat"),aw,i)}if(a5=="async"){return av(aZ)}if(a6=="@"){return av(aE,aZ)}return ap(aX("stat"),aE,w(";"),i)}function W(a5){if(a5=="("){return av(au,w(")"))}}function aE(a5,a6){return am(a5,a6,false)}function aW(a5,a6){return am(a5,a6,true)}function aF(a5){if(a5!="("){return ap()}return av(aX(")"),aE,w(")"),i)}function am(a6,a7,a9){if(I.state.fatArrowAt==I.stream.start){var a5=a9?U:aj;if(a6=="("){return av(A,aX(")"),aK(au,")"),i,w("=>"),a5,B)}else{if(a6=="variable"){return ap(A,j,w("=>"),a5,B)}}}var a8=a9?l:ar;if(b.hasOwnProperty(a6)){return av(a8)}if(a6=="function"){return av(T,a8)}if(a6=="class"||(h&&a7=="interface")){I.marked="keyword";return av(aX("form"),N,i)}if(a6=="keyword c"||a6=="async"){return av(a9?aW:aE)}if(a6=="("){return av(aX(")"),az,w(")"),i,a8)}if(a6=="operator"||a6=="spread"){return av(a9?aW:aE)}if(a6=="["){return av(aX("]"),r,i,a8)}if(a6=="{"){return aQ(y,"}",null,a8)}if(a6=="quasi"){return ap(Z,a8)}if(a6=="new"){return av(M(a9))}if(a6=="import"){return av(aE)}return av()}function az(a5){if(a5.match(/[;\}\)\],]/)){return ap()}return ap(aE)}function ar(a5,a6){if(a5==","){return av(aE)}return l(a5,a6,false)}function l(a5,a7,a9){var a6=a9==false?ar:l;var a8=a9==false?aE:aW;if(a5=="=>"){return av(A,a9?U:aj,B)}if(a5=="operator"){if(/\+\+|--/.test(a7)||h&&a7=="!"){return av(a6)}if(h&&a7=="<"&&I.stream.match(/^([^>]|<.*?>)*>\s*\(/,false)){return av(aX(">"),aK(k,">"),i,a6)}if(a7=="?"){return av(aE,w(":"),a8)}return av(a8)}if(a5=="quasi"){return ap(Z,a6)}if(a5==";"){return}if(a5=="("){return aQ(aW,")","call",a6)}if(a5=="."){return av(aC,a6)}if(a5=="["){return av(aX("]"),az,w("]"),i,a6)}if(h&&a7=="as"){I.marked="keyword";return av(k,a6)}if(a5=="regexp"){I.state.lastType=I.marked="operator";I.stream.backUp(I.stream.pos-I.stream.start-1);return av(a8)}}function Z(a5,a6){if(a5!="quasi"){return ap()}if(a6.slice(a6.length-2)!="${"){return av(Z)}return av(aE,u)}function u(a5){if(a5=="}"){I.marked="string-2";I.state.tokenize=aV;return av(Z)}}function aj(a5){aP(I.stream,I.state);return ap(a5=="{"?aZ:aE)}function U(a5){aP(I.stream,I.state);return ap(a5=="{"?aZ:aW)}function M(a5){return function(a6){if(a6=="."){return av(a5?s:ah)}else{if(a6=="variable"&&h){return av(e,a5?l:ar)}else{return ap(a5?aW:aE)}}}}function ah(a5,a6){if(a6=="target"){I.marked="keyword";return av(ar)}}function s(a5,a6){if(a6=="target"){I.marked="keyword";return av(l)}}function a2(a5){if(a5==":"){return av(i,aZ)}return ap(ar,w(";"),i)}function aC(a5){if(a5=="variable"){I.marked="property";return av()}}function y(a6,a7){if(a6=="async"){I.marked="property";return av(y)}else{if(a6=="variable"||I.style=="keyword"){I.marked="property";if(a7=="get"||a7=="set"){return av(O)}var a5;if(h&&I.state.fatArrowAt==I.stream.start&&(a5=I.stream.match(/^\s*:\s*/,false))){I.state.fatArrowAt=I.stream.pos+a5[0].length}return av(R)}else{if(a6=="number"||a6=="string"){I.marked=aT?"property":(I.style+" property");return av(R)}else{if(a6=="jsonld-keyword"){return av(R)}else{if(h&&aB(a7)){I.marked="keyword";return av(y)}else{if(a6=="["){return av(aE,ae,w("]"),R)}else{if(a6=="spread"){return av(aW,R)}else{if(a7=="*"){I.marked="keyword";return av(y)}else{if(a6==":"){return ap(R)}}}}}}}}}}function O(a5){if(a5!="variable"){return ap(R)}I.marked="property";return av(T)}function R(a5){if(a5==":"){return av(aW)}if(a5=="("){return ap(T)}}function aK(a8,a5,a6){function a7(ba,bb){if(a6?a6.indexOf(ba)>-1:ba==","){var a9=I.state.lexical;if(a9.info=="call"){a9.pos=(a9.pos||0)+1}return av(function(bc,bd){if(bc==a5||bd==a5){return ap()}return ap(a8)},a7)}if(ba==a5||bb==a5){return av()}if(a6&&a6.indexOf(";")>-1){return ap(a8)}return av(w(a5))}return function(a9,ba){if(a9==a5||ba==a5){return av()}return ap(a8,a7)}}function aQ(a8,a5,a7){for(var a6=3;a6
|
data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.handlebars.min.js
ADDED
@@ -0,0 +1 @@
|
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/mode/simple.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";function t(e,t){if(!e.hasOwnProperty(t))throw new Error("Undefined state "+t+" in simple mode")}function n(e,t){if(!e)return/(?:)/;var n="";return e instanceof RegExp?(e.ignoreCase&&(n="i"),e=e.source):e=String(e),new RegExp((!1===t?"":"^")+"(?:"+e+")",n)}function r(e){if(!e)return null;if(e.apply)return e;if("string"==typeof e)return e.replace(/\./g," ");for(var t=[],n=0;n<e.length;n++)t.push(e[n]&&e[n].replace(/\./g," "));return t}function o(e,o){(e.next||e.push)&&t(o,e.next||e.push),this.regex=n(e.regex),this.token=r(e.token),this.data=e}function i(e,t){return function(n,r){if(r.pending){var o=r.pending.shift();return 0==r.pending.length&&(r.pending=null),n.pos+=o.text.length,o.token}if(r.local){if(r.local.end&&n.match(r.local.end)){var i=r.local.endToken||null;return r.local=r.localState=null,i}var a,i=r.local.mode.token(n,r.localState);return r.local.endScan&&(a=r.local.endScan.exec(n.current()))&&(n.pos=n.start+a.index),i}for(var d=e[r.state],s=0;s<d.length;s++){var c=d[s],u=(!c.data.sol||n.sol())&&n.match(c.regex);if(u){c.data.next?r.state=c.data.next:c.data.push?((r.stack||(r.stack=[])).push(r.state),r.state=c.data.push):c.data.pop&&r.stack&&r.stack.length&&(r.state=r.stack.pop()),c.data.mode&&l(t,r,c.data.mode,c.token),c.data.indent&&r.indent.push(n.indentation()+t.indentUnit),c.data.dedent&&r.indent.pop();var f=c.token;if(f&&f.apply&&(f=f(u)),u.length>2&&c.token&&"string"!=typeof c.token){r.pending=[];for(var m=2;m<u.length;m++)u[m]&&r.pending.push({text:u[m],token:c.token[m-1]});return n.backUp(u[0].length-(u[1]?u[1].length:0)),f[0]}return f&&f.join?f[0]:f}}return n.next(),null}}function a(e,t){if(e===t)return!0;if(!e||"object"!=typeof e||!t||"object"!=typeof t)return!1;var n=0;for(var r in e)if(e.hasOwnProperty(r)){if(!t.hasOwnProperty(r)||!a(e[r],t[r]))return!1;n++}for(var r in t)t.hasOwnProperty(r)&&n--;return 0==n}function l(t,r,o,i){var l;if(o.persistent)for(var d=r.persistentStates;d&&!l;d=d.next)(o.spec?a(o.spec,d.spec):o.mode==d.mode)&&(l=d);var s=l?l.mode:o.mode||e.getMode(t,o.spec),c=l?l.state:e.startState(s);o.persistent&&!l&&(r.persistentStates={mode:s,spec:o.spec,state:c,next:r.persistentStates}),r.localState=c,r.local={mode:s,end:o.end&&n(o.end),endScan:o.end&&!1!==o.forceEnd&&n(o.end,!1),endToken:i&&i.join?i[i.length-1]:i}}function d(e,t){for(var n=0;n<t.length;n++)if(t[n]===e)return!0}function s(t,n){return function(r,o,i){if(r.local&&r.local.mode.indent)return r.local.mode.indent(r.localState,o,i);if(null==r.indent||r.local||n.dontIndentStates&&d(r.state,n.dontIndentStates)>-1)return e.Pass;var a=r.indent.length-1,l=t[r.state];e:for(;;){for(var s=0;s<l.length;s++){var c=l[s];if(c.data.dedent&&!1!==c.data.dedentIfLineStart){var u=c.regex.exec(o);if(u&&u[0]){a--,(c.next||c.push)&&(l=t[c.next||c.push]),o=o.slice(u[0].length);continue e}}}break}return a<0?0:r.indent[a]}}e.defineSimpleMode=function(t,n){e.defineMode(t,function(t){return e.simpleMode(t,n)})},e.simpleMode=function(n,r){t(r,"start");var a={},l=r.meta||{},d=!1;for(var c in r)if(c!=l&&r.hasOwnProperty(c))for(var u=a[c]=[],f=r[c],m=0;m<f.length;m++){var p=f[m];u.push(new o(p,r)),(p.indent||p.dedent)&&(d=!0)}var g={startState:function(){return{state:"start",pending:null,local:null,localState:null,indent:d?[]:null}},copyState:function(t){var n={state:t.state,pending:t.pending,local:t.local,localState:null,indent:t.indent&&t.indent.slice(0)};t.localState&&(n.localState=e.copyState(t.local.mode,t.localState)),t.stack&&(n.stack=t.stack.slice(0));for(var r=t.persistentStates;r;r=r.next)n.persistentStates={mode:r.mode,spec:r.spec,state:r.state==t.localState?n.localState:e.copyState(r.mode,r.state),next:n.persistentStates};return n},token:i(a,n),innerMode:function(e){return e.local&&{mode:e.local.mode,state:e.localState}},indent:s(a,l)};if(l)for(var h in l)l.hasOwnProperty(h)&&(g[h]=l[h]);return g}}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/mode/multiplex",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.multiplexingMode=function(t){function n(e,t,n,r){if("string"==typeof t){var o=e.indexOf(t,n);return r&&o>-1?o+t.length:o}var i=t.exec(n?e.slice(n):e);return i?i.index+n+(r?i[0].length:0):-1}var r=Array.prototype.slice.call(arguments,1);return{startState:function(){return{outer:e.startState(t),innerActive:null,inner:null}},copyState:function(n){return{outer:e.copyState(t,n.outer),innerActive:n.innerActive,inner:n.innerActive&&e.copyState(n.innerActive.mode,n.inner)}},token:function(o,i){if(i.innerActive){var a=i.innerActive,l=o.string;if(!a.close&&o.sol())return i.innerActive=i.inner=null,this.token(o,i);var d=a.close?n(l,a.close,o.pos,a.parseDelimiters):-1;if(d==o.pos&&!a.parseDelimiters)return o.match(a.close),i.innerActive=i.inner=null,a.delimStyle&&a.delimStyle+" "+a.delimStyle+"-close";d>-1&&(o.string=l.slice(0,d));var s=a.mode.token(o,i.inner);return d>-1&&(o.string=l),d==o.pos&&a.parseDelimiters&&(i.innerActive=i.inner=null),a.innerStyle&&(s=s?s+" "+a.innerStyle:a.innerStyle),s}for(var c=1/0,l=o.string,u=0;u<r.length;++u){var f=r[u],d=n(l,f.open,o.pos);if(d==o.pos){f.parseDelimiters||o.match(f.open),i.innerActive=f;var m=0;if(t.indent){var p=t.indent(i.outer,"","");p!==e.Pass&&(m=p)}return i.inner=e.startState(f.mode,m),f.delimStyle&&f.delimStyle+" "+f.delimStyle+"-open"}-1!=d&&d<c&&(c=d)}c!=1/0&&(o.string=l.slice(0,c));var g=t.token(o,i.outer);return c!=1/0&&(o.string=l),g},indent:function(n,r,o){var i=n.innerActive?n.innerActive.mode:t;return i.indent?i.indent(n.innerActive?n.inner:n.outer,r,o):e.Pass},blankLine:function(n){var o=n.innerActive?n.innerActive.mode:t;if(o.blankLine&&o.blankLine(n.innerActive?n.inner:n.outer),n.innerActive)"\n"===n.innerActive.close&&(n.innerActive=n.inner=null);else for(var i=0;i<r.length;++i){var a=r[i];"\n"===a.open&&(n.innerActive=a,n.inner=e.startState(a.mode,o.indent?o.indent(n.outer,"",""):0))}},electricChars:t.electricChars,innerMode:function(e){return e.inner?{state:e.inner,mode:e.innerActive.mode}:{state:e.outer,mode:t}}}}}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../../addon/mode/simple"),require("../../addon/mode/multiplex")):"function"==typeof define&&define.amd?define("mode/handlebars/handlebars.js",["../../lib/codemirror","../../addon/mode/simple","../../addon/mode/multiplex"],e):e(CodeMirror)}(function(e){"use strict";e.defineSimpleMode("handlebars-tags",{start:[{regex:/\{\{!--/,push:"dash_comment",token:"comment"},{regex:/\{\{!/,push:"comment",token:"comment"},{regex:/\{\{/,push:"handlebars",token:"tag"}],handlebars:[{regex:/\}\}/,pop:!0,token:"tag"},{regex:/"(?:[^\\"]|\\.)*"?/,token:"string"},{regex:/'(?:[^\\']|\\.)*'?/,token:"string"},{regex:/>|[#\/]([A-Za-z_]\w*)/,token:"keyword"},{regex:/(?:else|this)\b/,token:"keyword"},{regex:/\d+/i,token:"number"},{regex:/=|~|@|true|false/,token:"atom"},{regex:/(?:\.\.\/)*(?:[A-Za-z_][\w\.]*)+/,token:"variable-2"}],dash_comment:[{regex:/--\}\}/,pop:!0,token:"comment"},{regex:/./,token:"comment"}],comment:[{regex:/\}\}/,pop:!0,token:"comment"},{regex:/./,token:"comment"}],meta:{blockCommentStart:"{{--",blockCommentEnd:"--}}"}}),e.defineMode("handlebars",function(t,n){var r=e.getMode(t,"handlebars-tags");return n&&n.base?e.multiplexingMode(e.getMode(t,n.base),{open:"{{",close:"}}",mode:r,parseDelimiters:!0}):r}),e.defineMIME("text/x-handlebars-template","handlebars")}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/xml/xml.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},n={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};e.defineMode("xml",function(r,o){function i(e,t){function n(n){return t.tokenize=n,n(e,t)}var r=e.next();if("<"==r)return e.eat("!")?e.eat("[")?e.match("CDATA[")?n(d("atom","]]>")):null:e.match("--")?n(d("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),n(s(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=d("meta","?>"),"meta"):(T=e.eat("/")?"closeTag":"openTag",t.tokenize=a,"tag bracket");if("&"==r){var o;return o=e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"),o?"atom":"error"}return e.eatWhile(/[^&<]/),null}function a(e,t){var n=e.next();if(">"==n||"/"==n&&e.eat(">"))return t.tokenize=i,T=">"==n?"endTag":"selfcloseTag","tag bracket";if("="==n)return T="equals",null;if("<"==n){t.tokenize=i,t.state=m,t.tagName=t.tagStart=null;var r=t.tokenize(e,t);return r?r+" tag error":"tag error"}return/[\'\"]/.test(n)?(t.tokenize=l(n),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function l(e){var t=function(t,n){for(;!t.eol();)if(t.next()==e){n.tokenize=a;break}return"string"};return t.isInAttribute=!0,t}function d(e,t){return function(n,r){for(;!n.eol();){if(n.match(t)){r.tokenize=i;break}n.next()}return e}}function s(e){return function(t,n){for(var r;null!=(r=t.next());){if("<"==r)return n.tokenize=s(e+1),n.tokenize(t,n);if(">"==r){if(1==e){n.tokenize=i;break}return n.tokenize=s(e-1),n.tokenize(t,n)}}return"meta"}}function c(e,t,n){this.prev=e.context,this.tagName=t,this.indent=e.indented,this.startOfLine=n,(w.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function u(e){e.context&&(e.context=e.context.prev)}function f(e,t){for(var n;;){if(!e.context)return;if(n=e.context.tagName,!w.contextGrabbers.hasOwnProperty(n)||!w.contextGrabbers[n].hasOwnProperty(t))return;u(e)}}function m(e,t,n){return"openTag"==e?(n.tagStart=t.column(),p):"closeTag"==e?g:m}function p(e,t,n){return"word"==e?(n.tagName=t.current(),C="tag",v):w.allowMissingTagName&&"endTag"==e?(C="tag bracket",v(e,t,n)):(C="error",p)}function g(e,t,n){if("word"==e){var r=t.current();return n.context&&n.context.tagName!=r&&w.implicitlyClosed.hasOwnProperty(n.context.tagName)&&u(n),n.context&&n.context.tagName==r||!1===w.matchClosing?(C="tag",h):(C="tag error",x)}return w.allowMissingTagName&&"endTag"==e?(C="tag bracket",h(e,t,n)):(C="error",x)}function h(e,t,n){return"endTag"!=e?(C="error",h):(u(n),m)}function x(e,t,n){return C="error",h(e,t,n)}function v(e,t,n){if("word"==e)return C="attribute",k;if("endTag"==e||"selfcloseTag"==e){var r=n.tagName,o=n.tagStart;return n.tagName=n.tagStart=null,"selfcloseTag"==e||w.autoSelfClosers.hasOwnProperty(r)?f(n,r):(f(n,r),n.context=new c(n,r,o==n.indented)),m}return C="error",v}function k(e,t,n){return"equals"==e?b:(w.allowMissing||(C="error"),v(e,t,n))}function b(e,t,n){return"string"==e?S:"word"==e&&w.allowUnquoted?(C="string",v):(C="error",v(e,t,n))}function S(e,t,n){return"string"==e?S:v(e,t,n)}var y=r.indentUnit,w={},M=o.htmlMode?t:n;for(var A in M)w[A]=M[A];for(var A in o)w[A]=o[A];var T,C;return i.isInText=!0,{startState:function(e){var t={tokenize:i,state:m,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;T=null;var n=t.tokenize(e,t);return(n||T)&&"comment"!=n&&(C=null,t.state=t.state(T||n,e,t),C&&(n="error"==C?n+" error":C)),n},indent:function(t,n,r){var o=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+y;if(o&&o.noIndent)return e.Pass;if(t.tokenize!=a&&t.tokenize!=i)return r?r.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==w.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+y*(w.multilineTagIndentFactor||1);if(w.alignCDATA&&/<!\[CDATA\[/.test(n))return 0;var l=n&&/^<(\/)?([\w_:\.-]*)/.exec(n);if(l&&l[1])for(;o;){if(o.tagName==l[2]){o=o.prev;break}if(!w.implicitlyClosed.hasOwnProperty(o.tagName))break;o=o.prev}else if(l)for(;o;){var d=w.contextGrabbers[o.tagName];if(!d||!d.hasOwnProperty(l[2]))break;o=o.prev}for(;o&&o.prev&&!o.startOfLine;)o=o.prev;return o?o.indent+y:t.baseIndent||0},electricInput:/<\/[\s\w:]+>$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:w.htmlMode?"html":"xml",helperType:w.htmlMode?"html":"xml",skipAttribute:function(e){e.state==b&&(e.state=v)}}}),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(e){"function"==typeof e.define&&e.define("modeHandlebars",["mode/handlebars/handlebars.js"],function(){})}(this);
|
data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.htmlmixed.min.js
CHANGED
@@ -1,2 +1,2 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/xml/xml",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},r={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,caseFold:!1};e.defineMode("xml",function(n,o){function i(e,t){function r(r){return t.tokenize=r,r(e,t)}var n=e.next();if("<"==n)return e.eat("!")?e.eat("[")?e.match("CDATA[")?r(s("atom","]]>")):null:e.match("--")?r(s("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),r(c(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=s("meta","?>"),"meta"):(S=e.eat("/")?"closeTag":"openTag",t.tokenize=a,"tag bracket");if("&"==n){var o;return o=e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"),o?"atom":"error"}return e.eatWhile(/[^&<]/),null}function a(e,t){var r=e.next();if(">"==r||"/"==r&&e.eat(">"))return t.tokenize=i,S=">"==r?"endTag":"selfcloseTag","tag bracket";if("="==r)return S="equals",null;if("<"==r){t.tokenize=i,t.state=m,t.tagName=t.tagStart=null;var n=t.tokenize(e,t);return n?n+" tag error":"tag error"}return/[\'\"]/.test(r)?(t.tokenize=l(r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function l(e){var t=function(t,r){for(;!t.eol();)if(t.next()==e){r.tokenize=a;break}return"string"};return t.isInAttribute=!0,t}function s(e,t){return function(r,n){for(;!r.eol();){if(r.match(t)){n.tokenize=i;break}r.next()}return e}}function c(e){return function(t,r){for(var n;null!=(n=t.next());){if("<"==n)return r.tokenize=c(e+1),r.tokenize(t,r);if(">"==n){if(1==e){r.tokenize=i;break}return r.tokenize=c(e-1),r.tokenize(t,r)}}return"meta"}}function d(e,t,r){this.prev=e.context,this.tagName=t,this.indent=e.indented,this.startOfLine=r,(z.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function u(e){e.context&&(e.context=e.context.prev)}function p(e,t){for(var r;;){if(!e.context)return;if(r=e.context.tagName,!z.contextGrabbers.hasOwnProperty(r)||!z.contextGrabbers[r].hasOwnProperty(t))return;u(e)}}function m(e,t,r){return"openTag"==e?(r.tagStart=t.column(),f):"closeTag"==e?h:m}function f(e,t,r){return"word"==e?(r.tagName=t.current(),T="tag",y):(T="error",f)}function h(e,t,r){if("word"==e){var n=t.current();return r.context&&r.context.tagName!=n&&z.implicitlyClosed.hasOwnProperty(r.context.tagName)&&u(r),r.context&&r.context.tagName==n||!1===z.matchClosing?(T="tag",g):(T="tag error",b)}return T="error",b}function g(e,t,r){return"endTag"!=e?(T="error",g):(u(r),m)}function b(e,t,r){return T="error",g(e,t,r)}function y(e,t,r){if("word"==e)return T="attribute",v;if("endTag"==e||"selfcloseTag"==e){var n=r.tagName,o=r.tagStart;return r.tagName=r.tagStart=null,"selfcloseTag"==e||z.autoSelfClosers.hasOwnProperty(n)?p(r,n):(p(r,n),r.context=new d(r,n,o==r.indented)),m}return T="error",y}function v(e,t,r){return"equals"==e?k:(z.allowMissing||(T="error"),y(e,t,r))}function k(e,t,r){return"string"==e?w:"word"==e&&z.allowUnquoted?(T="string",y):(T="error",y(e,t,r))}function w(e,t,r){return"string"==e?w:y(e,t,r)}var x=n.indentUnit,z={},M=o.htmlMode?t:r;for(var j in M)z[j]=M[j];for(var j in o)z[j]=o[j];var S,T;return i.isInText=!0,{startState:function(e){var t={tokenize:i,state:m,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;S=null;var r=t.tokenize(e,t);return(r||S)&&"comment"!=r&&(T=null,t.state=t.state(S||r,e,t),T&&(r="error"==T?r+" error":T)),r},indent:function(t,r,n){var o=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+x;if(o&&o.noIndent)return e.Pass;if(t.tokenize!=a&&t.tokenize!=i)return n?n.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==z.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+x*(z.multilineTagIndentFactor||1);if(z.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:z.htmlMode?"html":"xml",helperType:z.htmlMode?"html":"xml",skipAttribute:function(e){e.state==k&&(e.state=y)}}}),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function o(e,t,r){return je=e,Se=r,t}function i(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=a(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return o("number","number");if("."==r&&e.match(".."))return o("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return o(r);if("="==r&&e.eat(">"))return o("=>","operator");if("0"==r&&e.eat(/x/i))return e.eatWhile(/[\da-f]/i),o("number","number");if("0"==r&&e.eat(/o/i))return e.eatWhile(/[0-7]/i),o("number","number");if("0"==r&&e.eat(/b/i))return e.eatWhile(/[01]/i),o("number","number");if(/\d/.test(r))return e.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/),o("number","number");if("/"==r)return e.eat("*")?(t.tokenize=l,l(e,t)):e.eat("/")?(e.skipToEnd(),o("comment","comment")):Me(e,t,1)?(n(e),e.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/),o("regexp","string-2")):(e.eat("="),o("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),o("error","error");if(Oe.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),o("operator","operator",e.current());if(Ie.test(r)){e.eatWhile(Ie);var i=e.current();if("."!=t.lastType){if(Ee.propertyIsEnumerable(i)){var c=Ee[i];return o(c.type,c.style,i)}if("async"==i&&e.match(/^\s*[\(\w]/,!1))return o("async","keyword",i)}return o("variable","variable",i)}}function a(e){return function(t,r){var n,a=!1;if(Ce&&"@"==t.peek()&&t.match(Ne))return r.tokenize=i,o("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||a);)a=!a&&"\\"==n;return a||(r.tokenize=i),o("string","string")}}function l(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=i;break}n="*"==r}return o("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=i;break}n=!n&&"\\"==r}return o("quasi","string-2",e.current())}function c(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if(Pe){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var o=0,i=!1,a=r-1;a>=0;--a){var l=e.string.charAt(a),s=Ke.indexOf(l);if(s>=0&&s<3){if(!o){++a;break}if(0==--o){"("==l&&(i=!0);break}}else if(s>=3&&s<6)++o;else if(Ie.test(l))i=!0;else{if(/["'\/]/.test(l))return;if(i&&!o){++a;break}}}i&&!o&&(t.fatArrowAt=a)}}function d(e,t,r,n,o,i){this.indented=e,this.column=t,this.type=r,this.prev=o,this.info=i,null!=n&&(this.align=n)}function u(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function p(e,t,r,n,o){var i=e.cc;for(Ve.state=e,Ve.stream=o,Ve.marked=null,Ve.cc=i,Ve.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((i.length?i.pop():qe?x:w)(r,n)){for(;i.length&&i[i.length-1].lex;)i.pop()();return Ve.marked?Ve.marked:"variable"==r&&u(e,n)?"variable-2":t}}}function m(){for(var e=arguments.length-1;e>=0;e--)Ve.cc.push(arguments[e])}function f(){return m.apply(null,arguments),!0}function h(e){function t(t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}var n=Ve.state;if(Ve.marked="def",n.context){if(t(n.localVars))return;n.localVars={name:e,next:n.localVars}}else{if(t(n.globalVars))return;r.globalVars&&(n.globalVars={name:e,next:n.globalVars})}}function g(){Ve.state.context={prev:Ve.state.context,vars:Ve.state.localVars},Ve.state.localVars=Be}function b(){Ve.state.localVars=Ve.state.context.vars,Ve.state.context=Ve.state.context.prev}function y(e,t){var r=function(){var r=Ve.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var o=r.lexical;o&&")"==o.type&&o.align;o=o.prev)n=o.indented;r.lexical=new d(n,Ve.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function v(){var e=Ve.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function k(e){function t(r){return r==e?f():";"==e?m():f(t)}return t}function w(e,t){return"var"==e?f(y("vardef",t.length),Z,k(";"),v):"keyword a"==e?f(y("form"),M,w,v):"keyword b"==e?f(y("form"),w,v):"keyword d"==e?Ve.stream.match(/^\s*$/,!1)?f():f(y("stat"),S,k(";"),v):"debugger"==e?f(k(";")):"{"==e?f(y("}"),F,v):";"==e?f():"if"==e?("else"==Ve.state.lexical.info&&Ve.state.cc[Ve.state.cc.length-1]==v&&Ve.state.cc.pop()(),f(y("form"),M,w,v,re)):"function"==e?f(se):"for"==e?f(y("form"),ne,w,v):"variable"==e?Pe&&"type"==t?(Ve.marked="keyword",f(U,k("operator"),U,k(";"))):Pe&&"declare"==t?(Ve.marked="keyword",f(w)):f(y("stat"),K):"switch"==e?f(y("form"),M,k("{"),y("}","switch"),F,v,v):"case"==e?f(x,k(":")):"default"==e?f(k(":")):"catch"==e?f(y("form"),g,k("("),ce,k(")"),w,v,b):"class"==e?f(y("form"),ue,v):"export"==e?f(y("stat"),he,v):"import"==e?f(y("stat"),be,v):"module"==e?f(y("form"),J,k("{"),y("}"),F,v,v):"async"==e?f(w):"@"==t?f(x,w):m(y("stat"),x,k(";"),v)}function x(e){return j(e,!1)}function z(e){return j(e,!0)}function M(e){return"("!=e?m():f(y(")"),x,k(")"),v)}function j(e,t){if(Ve.state.fatArrowAt==Ve.stream.start){var r=t?I:P;if("("==e)return f(g,y(")"),_(ce,")"),v,k("=>"),r,b);if("variable"==e)return m(g,J,k("=>"),r,b)}var n=t?A:T;return $e.hasOwnProperty(e)?f(n):"function"==e?f(se,n):"class"==e?f(y("form"),de,v):"keyword c"==e||"async"==e?f(t?z:x):"("==e?f(y(")"),S,k(")"),v,n):"operator"==e||"spread"==e?f(t?z:x):"["==e?f(y("]"),xe,v,n):"{"==e?L(V,"}",null,n):"quasi"==e?m(C,n):"new"==e?f(E(t)):f()}function S(e){return e.match(/[;\}\)\],]/)?m():m(x)}function T(e,t){return","==e?f(x):A(e,t,!1)}function A(e,t,r){var n=0==r?T:A,o=0==r?x:z;return"=>"==e?f(g,r?I:P,b):"operator"==e?/\+\+|--/.test(t)||Pe&&"!"==t?f(n):"?"==t?f(x,k(":"),o):f(o):"quasi"==e?m(C,n):";"!=e?"("==e?L(z,")","call",n):"."==e?f($,n):"["==e?f(y("]"),S,k("]"),v,n):Pe&&"as"==t?(Ve.marked="keyword",f(U,n)):"regexp"==e?(Ve.state.lastType=Ve.marked="operator",Ve.stream.backUp(Ve.stream.pos-Ve.stream.start-1),f(o)):void 0:void 0}function C(e,t){return"quasi"!=e?m():"${"!=t.slice(t.length-2)?f(C):f(x,q)}function q(e){if("}"==e)return Ve.marked="string-2",Ve.state.tokenize=s,f(C)}function P(e){return c(Ve.stream,Ve.state),m("{"==e?w:x)}function I(e){return c(Ve.stream,Ve.state),m("{"==e?w:z)}function E(e){return function(t){return"."==t?f(e?N:O):"variable"==t&&Pe?f(X,e?A:T):m(e?z:x)}}function O(e,t){if("target"==t)return Ve.marked="keyword",f(T)}function N(e,t){if("target"==t)return Ve.marked="keyword",f(A)}function K(e){return":"==e?f(v,w):m(T,k(";"),v)}function $(e){if("variable"==e)return Ve.marked="property",f()}function V(e,t){if("async"==e)return Ve.marked="property",f(V);if("variable"==e||"keyword"==Ve.style){if(Ve.marked="property","get"==t||"set"==t)return f(B);var r;return Pe&&Ve.state.fatArrowAt==Ve.stream.start&&(r=Ve.stream.match(/^\s*:\s*/,!1))&&(Ve.state.fatArrowAt=Ve.stream.pos+r[0].length),f(W)}return"number"==e||"string"==e?(Ve.marked=Ce?"property":Ve.style+" property",f(W)):"jsonld-keyword"==e?f(W):"modifier"==e?f(V):"["==e?f(x,k("]"),W):"spread"==e?f(z,W):"*"==t?(Ve.marked="keyword",f(V)):":"==e?m(W):void 0}function B(e){return"variable"!=e?m(W):(Ve.marked="property",f(se))}function W(e){return":"==e?f(z):"("==e?m(se):void 0}function _(e,t,r){function n(o,i){if(r?r.indexOf(o)>-1:","==o){var a=Ve.state.lexical;return"call"==a.info&&(a.pos=(a.pos||0)+1),f(function(r,n){return r==t||n==t?m():m(e)},n)}return o==t||i==t?f():f(k(t))}return function(r,o){return r==t||o==t?f():m(e,n)}}function L(e,t,r){for(var n=3;n
|
2
|
-
;var n=["domain","regexp","url","url-prefix"],o=t(n),i=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],a=t(i),l=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover"],s=t(l),c=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],d=t(c),u=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","baseline-shift","binding","bleed","bookmark-label","bookmark-level","bookmark-state","bookmark-target","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-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","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","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-feature-settings","font-family","font-kerning","font-language-override","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-weight","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","max-height","max-width","min-height","min-width","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotation","rotation-point","ruby-align","ruby-overhang","ruby-position","ruby-span","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-outline","text-overflow","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],p=t(u),m=["scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-3d-light-color","scrollbar-track-color","shape-inside","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","zoom"],f=t(m),h=["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"],g=t(h),b=["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"],y=t(b),v=["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","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","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","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],k=t(v),w=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],x=t(w),z=n.concat(i).concat(l).concat(c).concat(u).concat(m).concat(v).concat(w);e.registerHelper("hintWords","css",z),e.defineMIME("text/css",{documentTypes:o,mediaTypes:a,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:g,counterDescriptors:y,colorKeywords:k,valueKeywords:x,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:a,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:x,fontProperties:g,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},":":function(e){return!!e.match(/\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:a,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:x,fontProperties:g,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:o,mediaTypes:a,mediaFeatures:s,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:g,counterDescriptors:y,colorKeywords:k,valueKeywords:x,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css",helperType:"gss"})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../xml/xml"),require("../javascript/javascript"),require("../css/css")):"function"==typeof define&&define.amd?define("mode/htmlmixed/htmlmixed",["../../lib/codemirror","../xml/xml","../javascript/javascript","../css/css"],e):e(CodeMirror)}(function(e){"use strict";function t(e,t,r){var n=e.current(),o=n.search(t);return o>-1?e.backUp(n.length-o):n.match(/<\/?$/)&&(e.backUp(n.length),e.match(t,!1)||e.match(n)),r}function r(e){var t=s[e];return t||(s[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}function n(e,t){var n=e.match(r(t));return n?/^\s*(.*?)\s*$/.exec(n[2])[1]:""}function o(e,t){return new RegExp((t?"^":"")+"","i")}function i(e,t){for(var r in e)for(var n=t[r]||(t[r]=[]),o=e[r],i=o.length-1;i>=0;i--)n.unshift(o[i])}function a(e,t){for(var r=0;r
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/xml/xml",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},r={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};e.defineMode("xml",function(n,o){function a(e,t){function r(r){return t.tokenize=r,r(e,t)}var n=e.next();if("<"==n)return e.eat("!")?e.eat("[")?e.match("CDATA[")?r(s("atom","]]>")):null:e.match("--")?r(s("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),r(c(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=s("meta","?>"),"meta"):(S=e.eat("/")?"closeTag":"openTag",t.tokenize=i,"tag bracket");if("&"==n){var o;return o=e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"),o?"atom":"error"}return e.eatWhile(/[^&<]/),null}function i(e,t){var r=e.next();if(">"==r||"/"==r&&e.eat(">"))return t.tokenize=a,S=">"==r?"endTag":"selfcloseTag","tag bracket";if("="==r)return S="equals",null;if("<"==r){t.tokenize=a,t.state=m,t.tagName=t.tagStart=null;var n=t.tokenize(e,t);return n?n+" tag error":"tag error"}return/[\'\"]/.test(r)?(t.tokenize=l(r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function l(e){var t=function(t,r){for(;!t.eol();)if(t.next()==e){r.tokenize=i;break}return"string"};return t.isInAttribute=!0,t}function s(e,t){return function(r,n){for(;!r.eol();){if(r.match(t)){n.tokenize=a;break}r.next()}return e}}function c(e){return function(t,r){for(var n;null!=(n=t.next());){if("<"==n)return r.tokenize=c(e+1),r.tokenize(t,r);if(">"==n){if(1==e){r.tokenize=a;break}return r.tokenize=c(e-1),r.tokenize(t,r)}}return"meta"}}function d(e,t,r){this.prev=e.context,this.tagName=t,this.indent=e.indented,this.startOfLine=r,(M.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function u(e){e.context&&(e.context=e.context.prev)}function p(e,t){for(var r;;){if(!e.context)return;if(r=e.context.tagName,!M.contextGrabbers.hasOwnProperty(r)||!M.contextGrabbers[r].hasOwnProperty(t))return;u(e)}}function m(e,t,r){return"openTag"==e?(r.tagStart=t.column(),f):"closeTag"==e?h:m}function f(e,t,r){return"word"==e?(r.tagName=t.current(),T="tag",y):M.allowMissingTagName&&"endTag"==e?(T="tag bracket",y(e,t,r)):(T="error",f)}function h(e,t,r){if("word"==e){var n=t.current();return r.context&&r.context.tagName!=n&&M.implicitlyClosed.hasOwnProperty(r.context.tagName)&&u(r),r.context&&r.context.tagName==n||!1===M.matchClosing?(T="tag",g):(T="tag error",b)}return M.allowMissingTagName&&"endTag"==e?(T="tag bracket",g(e,t,r)):(T="error",b)}function g(e,t,r){return"endTag"!=e?(T="error",g):(u(r),m)}function b(e,t,r){return T="error",g(e,t,r)}function y(e,t,r){if("word"==e)return T="attribute",v;if("endTag"==e||"selfcloseTag"==e){var n=r.tagName,o=r.tagStart;return r.tagName=r.tagStart=null,"selfcloseTag"==e||M.autoSelfClosers.hasOwnProperty(n)?p(r,n):(p(r,n),r.context=new d(r,n,o==r.indented)),m}return T="error",y}function v(e,t,r){return"equals"==e?k:(M.allowMissing||(T="error"),y(e,t,r))}function k(e,t,r){return"string"==e?w:"word"==e&&M.allowUnquoted?(T="string",y):(T="error",y(e,t,r))}function w(e,t,r){return"string"==e?w:y(e,t,r)}var x=n.indentUnit,M={},z=o.htmlMode?t:r;for(var j in z)M[j]=z[j];for(var j in o)M[j]=o[j];var S,T;return a.isInText=!0,{startState:function(e){var t={tokenize:a,state:m,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;S=null;var r=t.tokenize(e,t);return(r||S)&&"comment"!=r&&(T=null,t.state=t.state(S||r,e,t),T&&(r="error"==T?r+" error":T)),r},indent:function(t,r,n){var o=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+x;if(o&&o.noIndent)return e.Pass;if(t.tokenize!=i&&t.tokenize!=a)return n?n.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==M.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+x*(M.multilineTagIndentFactor||1);if(M.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:M.htmlMode?"html":"xml",helperType:M.htmlMode?"html":"xml",skipAttribute:function(e){e.state==k&&(e.state=y)}}}),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function o(e,t,r){return Be=e,_e=r,t}function a(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=i(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return o("number","number");if("."==r&&e.match(".."))return o("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return o(r);if("="==r&&e.eat(">"))return o("=>","operator");if("0"==r&&e.match(/^(?:x[\da-f]+|o[0-7]+|b[01]+)n?/i))return o("number","number");if(/\d/.test(r))return e.match(/^\d*(?:n|(?:\.\d*)?(?:[eE][+\-]?\d+)?)?/),o("number","number");if("/"==r)return e.eat("*")?(t.tokenize=l,l(e,t)):e.eat("/")?(e.skipToEnd(),o("comment","comment")):Ve(e,t,1)?(n(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),o("regexp","string-2")):(e.eat("="),o("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),o("error","error");if(Ye.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),o("operator","operator",e.current());if(He.test(r)){e.eatWhile(He);var a=e.current();if("."!=t.lastType){if(Ge.propertyIsEnumerable(a)){var c=Ge[a];return o(c.type,c.style,a)}if("async"==a&&e.match(/^(\s|\/\*.*?\*\/)*[\[\(\w]/,!1))return o("async","keyword",a)}return o("variable","variable",a)}}function i(e){return function(t,r){var n,i=!1;if(Fe&&"@"==t.peek()&&t.match(Re))return r.tokenize=a,o("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||i);)i=!i&&"\\"==n;return i||(r.tokenize=a),o("string","string")}}function l(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=a;break}n="*"==r}return o("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=a;break}n=!n&&"\\"==r}return o("quasi","string-2",e.current())}function c(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if(Ue){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var o=0,a=!1,i=r-1;i>=0;--i){var l=e.string.charAt(i),s=Xe.indexOf(l);if(s>=0&&s<3){if(!o){++i;break}if(0==--o){"("==l&&(a=!0);break}}else if(s>=3&&s<6)++o;else if(He.test(l))a=!0;else{if(/["'\/]/.test(l))return;if(a&&!o){++i;break}}}a&&!o&&(t.fatArrowAt=i)}}function d(e,t,r,n,o,a){this.indented=e,this.column=t,this.type=r,this.prev=o,this.info=a,null!=n&&(this.align=n)}function u(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function p(e,t,r,n,o){var a=e.cc;for(Je.state=e,Je.stream=o,Je.marked=null,Je.cc=a,Je.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((a.length?a.pop():De?C:T)(r,n)){for(;a.length&&a[a.length-1].lex;)a.pop()();return Je.marked?Je.marked:"variable"==r&&u(e,n)?"variable-2":t}}}function m(){for(var e=arguments.length-1;e>=0;e--)Je.cc.push(arguments[e])}function f(){return m.apply(null,arguments),!0}function h(e,t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}function g(e){var t=Je.state;if(Je.marked="def",t.context)if("var"==t.lexical.info&&t.context&&t.context.block){var n=b(e,t.context);if(null!=n)return void(t.context=n)}else if(!h(e,t.localVars))return void(t.localVars=new k(e,t.localVars));r.globalVars&&!h(e,t.globalVars)&&(t.globalVars=new k(e,t.globalVars))}function b(e,t){if(t){if(t.block){var r=b(e,t.prev);return r?r==t.prev?t:new v(r,t.vars,!0):null}return h(e,t.vars)?t:new v(t.prev,new k(e,t.vars),!1)}return null}function y(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function v(e,t,r){this.prev=e,this.vars=t,this.block=r}function k(e,t){this.name=e,this.next=t}function w(){Je.state.context=new v(Je.state.context,Je.state.localVars,!1),Je.state.localVars=Qe}function x(){Je.state.context=new v(Je.state.context,Je.state.localVars,!0),Je.state.localVars=null}function M(){Je.state.localVars=Je.state.context.vars,Je.state.context=Je.state.context.prev}function z(e,t){var r=function(){var r=Je.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var o=r.lexical;o&&")"==o.type&&o.align;o=o.prev)n=o.indented;r.lexical=new d(n,Je.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function j(){var e=Je.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function S(e){function t(r){return r==e?f():";"==e||"}"==r||")"==r||"]"==r?m():f(t)}return t}function T(e,t){return"var"==e?f(z("vardef",t),se,S(";"),j):"keyword a"==e?f(z("form"),P,T,j):"keyword b"==e?f(z("form"),T,j):"keyword d"==e?Je.stream.match(/^\s*$/,!1)?f():f(z("stat"),E,S(";"),j):"debugger"==e?f(S(";")):"{"==e?f(z("}"),x,X,j,M):";"==e?f():"if"==e?("else"==Je.state.lexical.info&&Je.state.cc[Je.state.cc.length-1]==j&&Je.state.cc.pop()(),f(z("form"),P,T,j,fe)):"function"==e?f(ye):"for"==e?f(z("form"),he,T,j):"class"==e||Ue&&"interface"==t?(Je.marked="keyword",f(z("form","class"==e?e:t),Me,j)):"variable"==e?Ue&&"declare"==t?(Je.marked="keyword",f(T)):Ue&&("module"==t||"enum"==t||"type"==t)&&Je.stream.match(/^\s*\w/,!1)?(Je.marked="keyword","enum"==t?f(Ne):"type"==t?f(ke,S("operator"),ee,S(";")):f(z("form"),ce,S("{"),z("}"),X,j,j)):Ue&&"namespace"==t?(Je.marked="keyword",f(z("form"),C,T,j)):Ue&&"abstract"==t?(Je.marked="keyword",f(T)):f(z("stat"),F):"switch"==e?f(z("form"),P,S("{"),z("}","switch"),x,X,j,j,M):"case"==e?f(C,S(":")):"default"==e?f(S(":")):"catch"==e?f(z("form"),w,A,T,j,M):"export"==e?f(z("stat"),Te,j):"import"==e?f(z("stat"),Ce,j):"async"==e?f(T):"@"==t?f(C,T):m(z("stat"),C,S(";"),j)}function A(e){if("("==e)return f(we,S(")"))}function C(e,t){return I(e,t,!1)}function q(e,t){return I(e,t,!0)}function P(e){return"("!=e?m():f(z(")"),C,S(")"),j)}function I(e,t,r){if(Je.state.fatArrowAt==Je.stream.start){var n=r?B:V;if("("==e)return f(w,z(")"),Y(we,")"),j,S("=>"),n,M);if("variable"==e)return m(w,ce,S("=>"),n,M)}var o=r?N:O;return Ze.hasOwnProperty(e)?f(o):"function"==e?f(ye,o):"class"==e||Ue&&"interface"==t?(Je.marked="keyword",f(z("form"),xe,j)):"keyword c"==e||"async"==e?f(r?q:C):"("==e?f(z(")"),E,S(")"),j,o):"operator"==e||"spread"==e?f(r?q:C):"["==e?f(z("]"),Oe,j,o):"{"==e?R(U,"}",null,o):"quasi"==e?m($,o):"new"==e?f(_(r)):"import"==e?f(C):f()}function E(e){return e.match(/[;\}\)\],]/)?m():m(C)}function O(e,t){return","==e?f(C):N(e,t,!1)}function N(e,t,r){var n=0==r?O:N,o=0==r?C:q;return"=>"==e?f(w,r?B:V,M):"operator"==e?/\+\+|--/.test(t)||Ue&&"!"==t?f(n):Ue&&"<"==t&&Je.stream.match(/^([^>]|<.*?>)*>\s*\(/,!1)?f(z(">"),Y(ee,">"),j,n):"?"==t?f(C,S(":"),o):f(o):"quasi"==e?m($,n):";"!=e?"("==e?R(q,")","call",n):"."==e?f(D,n):"["==e?f(z("]"),E,S("]"),j,n):Ue&&"as"==t?(Je.marked="keyword",f(ee,n)):"regexp"==e?(Je.state.lastType=Je.marked="operator",Je.stream.backUp(Je.stream.pos-Je.stream.start-1),f(o)):void 0:void 0}function $(e,t){return"quasi"!=e?m():"${"!=t.slice(t.length-2)?f($):f(C,K)}function K(e){if("}"==e)return Je.marked="string-2",Je.state.tokenize=s,f($)}function V(e){return c(Je.stream,Je.state),m("{"==e?T:C)}function B(e){return c(Je.stream,Je.state),m("{"==e?T:q)}function _(e){return function(t){return"."==t?f(e?L:W):"variable"==t&&Ue?f(ae,e?N:O):m(e?q:C)}}function W(e,t){if("target"==t)return Je.marked="keyword",f(O)}function L(e,t){if("target"==t)return Je.marked="keyword",f(N)}function F(e){return":"==e?f(j,T):m(O,S(";"),j)}function D(e){if("variable"==e)return Je.marked="property",f()}function U(e,t){if("async"==e)return Je.marked="property",f(U);if("variable"==e||"keyword"==Je.style){if(Je.marked="property","get"==t||"set"==t)return f(H);var r;return Ue&&Je.state.fatArrowAt==Je.stream.start&&(r=Je.stream.match(/^\s*:\s*/,!1))&&(Je.state.fatArrowAt=Je.stream.pos+r[0].length),f(G)}return"number"==e||"string"==e?(Je.marked=Fe?"property":Je.style+" property",f(G)):"jsonld-keyword"==e?f(G):Ue&&y(t)?(Je.marked="keyword",f(U)):"["==e?f(C,Z,S("]"),G):"spread"==e?f(q,G):"*"==t?(Je.marked="keyword",f(U)):":"==e?m(G):void 0}function H(e){return"variable"!=e?m(G):(Je.marked="property",f(ye))}function G(e){return":"==e?f(q):"("==e?m(ye):void 0}function Y(e,t,r){function n(o,a){if(r?r.indexOf(o)>-1:","==o){var i=Je.state.lexical;return"call"==i.info&&(i.pos=(i.pos||0)+1),f(function(r,n){return r==t||n==t?m():m(e)},n)}return o==t||a==t?f():r&&r.indexOf(";")>-1?m(e):f(S(t))}return function(r,o){return r==t||o==t?f():m(e,n)}}function R(e,t,r){for(var n=3;n
|
2
|
+
;var n=["domain","regexp","url","url-prefix"],o=t(n),a=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],i=t(a),l=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover"],s=t(l),c=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],d=t(c),u=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","baseline-shift","binding","bleed","bookmark-label","bookmark-level","bookmark-state","bookmark-target","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-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","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","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-feature-settings","font-family","font-kerning","font-language-override","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-weight","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","max-height","max-width","min-height","min-width","mix-blend-mode","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotation","rotation-point","ruby-align","ruby-overhang","ruby-position","ruby-span","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-outline","text-overflow","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],p=t(u),m=["scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-3d-light-color","scrollbar-track-color","shape-inside","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","zoom"],f=t(m),h=["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"],g=t(h),b=["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"],y=t(b),v=["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","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","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","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],k=t(v),w=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],x=t(w),M=n.concat(a).concat(l).concat(c).concat(u).concat(m).concat(v).concat(w);e.registerHelper("hintWords","css",M),e.defineMIME("text/css",{documentTypes:o,mediaTypes:i,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:g,counterDescriptors:y,colorKeywords:k,valueKeywords:x,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:x,fontProperties:g,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},":":function(e){return!!e.match(/\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:d,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:x,fontProperties:g,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:o,mediaTypes:i,mediaFeatures:s,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:g,counterDescriptors:y,colorKeywords:k,valueKeywords:x,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css",helperType:"gss"})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../xml/xml"),require("../javascript/javascript"),require("../css/css")):"function"==typeof define&&define.amd?define("mode/htmlmixed/htmlmixed",["../../lib/codemirror","../xml/xml","../javascript/javascript","../css/css"],e):e(CodeMirror)}(function(e){"use strict";function t(e,t,r){var n=e.current(),o=n.search(t);return o>-1?e.backUp(n.length-o):n.match(/<\/?$/)&&(e.backUp(n.length),e.match(t,!1)||e.match(n)),r}function r(e){var t=s[e];return t||(s[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}function n(e,t){var n=e.match(r(t));return n?/^\s*(.*?)\s*$/.exec(n[2])[1]:""}function o(e,t){return new RegExp((t?"^":"")+"","i")}function a(e,t){for(var r in e)for(var n=t[r]||(t[r]=[]),o=e[r],a=o.length-1;a>=0;a--)n.unshift(o[a])}function i(e,t){for(var r=0;r
|
data/vendor/assets/javascripts/ckeditor/plugins/codemirror/js/codemirror.mode.javascript.min.js
CHANGED
@@ -1 +1 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function a(e,t,r){return Ve=e,Ae=r,t}function i(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=o(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return a("number","number");if("."==r&&e.match(".."))return a("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return a(r);if("="==r&&e.eat(">"))return a("=>","operator");if("0"==r&&e.eat(/x/i))return e.eatWhile(/[\da-f]/i),a("number","number");if("0"==r&&e.eat(/o/i))return e.eatWhile(/[0-7]/i),a("number","number");if("0"==r&&e.eat(/b/i))return e.eatWhile(/[01]/i),a("number","number");if(/\d/.test(r))return e.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/),a("number","number");if("/"==r)return e.eat("*")?(t.tokenize=c,c(e,t)):e.eat("/")?(e.skipToEnd(),a("comment","comment")):Me(e,t,1)?(n(e),e.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/),a("regexp","string-2")):(e.eat("="),a("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),a("error","error");if(Oe.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),a("operator","operator",e.current());if(Ce.test(r)){e.eatWhile(Ce);var i=e.current();if("."!=t.lastType){if(qe.propertyIsEnumerable(i)){var u=qe[i];return a(u.type,u.style,i)}if("async"==i&&e.match(/^\s*[\(\w]/,!1))return a("async","keyword",i)}return a("variable","variable",i)}}function o(e){return function(t,r){var n,o=!1;if(Ie&&"@"==t.peek()&&t.match(Pe))return r.tokenize=i,a("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||o);)o=!o&&"\\"==n;return o||(r.tokenize=i),a("string","string")}}function c(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=i;break}n="*"==r}return a("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=i;break}n=!n&&"\\"==r}return a("quasi","string-2",e.current())}function u(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if($e){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var a=0,i=!1,o=r-1;o>=0;--o){var c=e.string.charAt(o),s=Se.indexOf(c);if(s>=0&&s<3){if(!a){++o;break}if(0==--a){"("==c&&(i=!0);break}}else if(s>=3&&s<6)++a;else if(Ce.test(c))i=!0;else{if(/["'\/]/.test(c))return;if(i&&!a){++o;break}}}i&&!a&&(t.fatArrowAt=o)}}function f(e,t,r,n,a,i){this.indented=e,this.column=t,this.type=r,this.prev=a,this.info=i,null!=n&&(this.align=n)}function l(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function d(e,t,r,n,a){var i=e.cc;for(Ne.state=e,Ne.stream=a,Ne.marked=null,Ne.cc=i,Ne.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((i.length?i.pop():Te?g:h)(r,n)){for(;i.length&&i[i.length-1].lex;)i.pop()();return Ne.marked?Ne.marked:"variable"==r&&l(e,n)?"variable-2":t}}}function p(){for(var e=arguments.length-1;e>=0;e--)Ne.cc.push(arguments[e])}function m(){return p.apply(null,arguments),!0}function v(e){function t(t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}var n=Ne.state;if(Ne.marked="def",n.context){if(t(n.localVars))return;n.localVars={name:e,next:n.localVars}}else{if(t(n.globalVars))return;r.globalVars&&(n.globalVars={name:e,next:n.globalVars})}}function y(){Ne.state.context={prev:Ne.state.context,vars:Ne.state.localVars},Ne.state.localVars=Ue}function k(){Ne.state.localVars=Ne.state.context.vars,Ne.state.context=Ne.state.context.prev}function b(e,t){var r=function(){var r=Ne.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var a=r.lexical;a&&")"==a.type&&a.align;a=a.prev)n=a.indented;r.lexical=new f(n,Ne.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function x(){var e=Ne.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function w(e){function t(r){return r==e?m():";"==e?p():m(t)}return t}function h(e,t){return"var"==e?m(b("vardef",t.length),Y,w(";"),x):"keyword a"==e?m(b("form"),M,h,x):"keyword b"==e?m(b("form"),h,x):"keyword d"==e?Ne.stream.match(/^\s*$/,!1)?m():m(b("stat"),A,w(";"),x):"debugger"==e?m(w(";")):"{"==e?m(b("}"),D,x):";"==e?m():"if"==e?("else"==Ne.state.lexical.info&&Ne.state.cc[Ne.state.cc.length-1]==x&&Ne.state.cc.pop()(),m(b("form"),M,h,x,re)):"function"==e?m(se):"for"==e?m(b("form"),ne,h,x):"variable"==e?$e&&"type"==t?(Ne.marked="keyword",m(G,w("operator"),G,w(";"))):$e&&"declare"==t?(Ne.marked="keyword",m(h)):m(b("stat"),S):"switch"==e?m(b("form"),M,w("{"),b("}","switch"),D,x,x):"case"==e?m(g,w(":")):"default"==e?m(w(":")):"catch"==e?m(b("form"),y,w("("),ue,w(")"),h,x,k):"class"==e?m(b("form"),le,x):"export"==e?m(b("stat"),ve,x):"import"==e?m(b("stat"),ke,x):"module"==e?m(b("form"),Z,w("{"),b("}"),D,x,x):"async"==e?m(h):"@"==t?m(g,h):p(b("stat"),g,w(";"),x)}function g(e){return V(e,!1)}function j(e){return V(e,!0)}function M(e){return"("!=e?p():m(b(")"),g,w(")"),x)}function V(e,t){if(Ne.state.fatArrowAt==Ne.stream.start){var r=t?C:$;if("("==e)return m(y,b(")"),H(ue,")"),x,w("=>"),r,k);if("variable"==e)return p(y,Z,w("=>"),r,k)}var n=t?z:E;return We.hasOwnProperty(e)?m(n):"function"==e?m(se,n):"class"==e?m(b("form"),fe,x):"keyword c"==e||"async"==e?m(t?j:g):"("==e?m(b(")"),A,w(")"),x,n):"operator"==e||"spread"==e?m(t?j:g):"["==e?m(b("]"),ge,x,n):"{"==e?J(N,"}",null,n):"quasi"==e?p(I,n):"new"==e?m(q(t)):m()}function A(e){return e.match(/[;\}\)\],]/)?p():p(g)}function E(e,t){return","==e?m(g):z(e,t,!1)}function z(e,t,r){var n=0==r?E:z,a=0==r?g:j;return"=>"==e?m(y,r?C:$,k):"operator"==e?/\+\+|--/.test(t)||$e&&"!"==t?m(n):"?"==t?m(g,w(":"),a):m(a):"quasi"==e?p(I,n):";"!=e?"("==e?J(j,")","call",n):"."==e?m(W,n):"["==e?m(b("]"),A,w("]"),x,n):$e&&"as"==t?(Ne.marked="keyword",m(G,n)):"regexp"==e?(Ne.state.lastType=Ne.marked="operator",Ne.stream.backUp(Ne.stream.pos-Ne.stream.start-1),m(a)):void 0:void 0}function I(e,t){return"quasi"!=e?p():"${"!=t.slice(t.length-2)?m(I):m(g,T)}function T(e){if("}"==e)return Ne.marked="string-2",Ne.state.tokenize=s,m(I)}function $(e){return u(Ne.stream,Ne.state),p("{"==e?h:g)}function C(e){return u(Ne.stream,Ne.state),p("{"==e?h:j)}function q(e){return function(t){return"."==t?m(e?P:O):"variable"==t&&$e?m(X,e?z:E):p(e?j:g)}}function O(e,t){if("target"==t)return Ne.marked="keyword",m(E)}function P(e,t){if("target"==t)return Ne.marked="keyword",m(z)}function S(e){return":"==e?m(x,h):p(E,w(";"),x)}function W(e){if("variable"==e)return Ne.marked="property",m()}function N(e,t){if("async"==e)return Ne.marked="property",m(N);if("variable"==e||"keyword"==Ne.style){if(Ne.marked="property","get"==t||"set"==t)return m(U);var r;return $e&&Ne.state.fatArrowAt==Ne.stream.start&&(r=Ne.stream.match(/^\s*:\s*/,!1))&&(Ne.state.fatArrowAt=Ne.stream.pos+r[0].length),m(B)}return"number"==e||"string"==e?(Ne.marked=Ie?"property":Ne.style+" property",m(B)):"jsonld-keyword"==e?m(B):"modifier"==e?m(N):"["==e?m(g,w("]"),B):"spread"==e?m(j,B):"*"==t?(Ne.marked="keyword",m(N)):":"==e?p(B):void 0}function U(e){return"variable"!=e?p(B):(Ne.marked="property",m(se))}function B(e){return":"==e?m(j):"("==e?p(se):void 0}function H(e,t,r){function n(a,i){if(r?r.indexOf(a)>-1:","==a){var o=Ne.state.lexical;return"call"==o.info&&(o.pos=(o.pos||0)+1),m(function(r,n){return r==t||n==t?p():p(e)},n)}return a==t||i==t?m():m(w(t))}return function(r,a){return r==t||a==t?m():p(e,n)}}function J(e,t,r){for(var n=3;n
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript.js",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function a(e,t,r){return Be=e,He=r,t}function i(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=o(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return a("number","number");if("."==r&&e.match(".."))return a("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return a(r);if("="==r&&e.eat(">"))return a("=>","operator");if("0"==r&&e.match(/^(?:x[\da-f]+|o[0-7]+|b[01]+)n?/i))return a("number","number");if(/\d/.test(r))return e.match(/^\d*(?:n|(?:\.\d*)?(?:[eE][+\-]?\d+)?)?/),a("number","number");if("/"==r)return e.eat("*")?(t.tokenize=c,c(e,t)):e.eat("/")?(e.skipToEnd(),a("comment","comment")):Ue(e,t,1)?(n(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),a("regexp","string-2")):(e.eat("="),a("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),a("error","error");if(Qe.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),a("operator","operator",e.current());if(Ke.test(r)){e.eatWhile(Ke);var i=e.current();if("."!=t.lastType){if(Le.propertyIsEnumerable(i)){var u=Le[i];return a(u.type,u.style,i)}if("async"==i&&e.match(/^(\s|\/\*.*?\*\/)*[\[\(\w]/,!1))return a("async","keyword",i)}return a("variable","variable",i)}}function o(e){return function(t,r){var n,o=!1;if(De&&"@"==t.peek()&&t.match(Re))return r.tokenize=i,a("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||o);)o=!o&&"\\"==n;return o||(r.tokenize=i),a("string","string")}}function c(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=i;break}n="*"==r}return a("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=i;break}n=!n&&"\\"==r}return a("quasi","string-2",e.current())}function u(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if(Ge){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var a=0,i=!1,o=r-1;o>=0;--o){var c=e.string.charAt(o),s=Xe.indexOf(c);if(s>=0&&s<3){if(!a){++o;break}if(0==--a){"("==c&&(i=!0);break}}else if(s>=3&&s<6)++a;else if(Ke.test(c))i=!0;else{if(/["'\/]/.test(c))return;if(i&&!a){++o;break}}}i&&!a&&(t.fatArrowAt=o)}}function f(e,t,r,n,a,i){this.indented=e,this.column=t,this.type=r,this.prev=a,this.info=i,null!=n&&(this.align=n)}function l(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function d(e,t,r,n,a){var i=e.cc;for(Ze.state=e,Ze.stream=a,Ze.marked=null,Ze.cc=i,Ze.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((i.length?i.pop():Fe?I:E)(r,n)){for(;i.length&&i[i.length-1].lex;)i.pop()();return Ze.marked?Ze.marked:"variable"==r&&l(e,n)?"variable-2":t}}}function p(){for(var e=arguments.length-1;e>=0;e--)Ze.cc.push(arguments[e])}function m(){return p.apply(null,arguments),!0}function v(e,t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}function k(e){var t=Ze.state;if(Ze.marked="def",t.context)if("var"==t.lexical.info&&t.context&&t.context.block){var n=y(e,t.context);if(null!=n)return void(t.context=n)}else if(!v(e,t.localVars))return void(t.localVars=new x(e,t.localVars));r.globalVars&&!v(e,t.globalVars)&&(t.globalVars=new x(e,t.globalVars))}function y(e,t){if(t){if(t.block){var r=y(e,t.prev);return r?r==t.prev?t:new b(r,t.vars,!0):null}return v(e,t.vars)?t:new b(t.prev,new x(e,t.vars),!1)}return null}function w(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function b(e,t,r){this.prev=e,this.vars=t,this.block=r}function x(e,t){this.name=e,this.next=t}function h(){Ze.state.context=new b(Ze.state.context,Ze.state.localVars,!1),Ze.state.localVars=_e}function g(){Ze.state.context=new b(Ze.state.context,Ze.state.localVars,!0),Ze.state.localVars=null}function j(){Ze.state.localVars=Ze.state.context.vars,Ze.state.context=Ze.state.context.prev}function M(e,t){var r=function(){var r=Ze.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var a=r.lexical;a&&")"==a.type&&a.align;a=a.prev)n=a.indented;r.lexical=new f(n,Ze.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function V(){var e=Ze.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function A(e){function t(r){return r==e?m():";"==e||"}"==r||")"==r||"]"==r?p():m(t)}return t}function E(e,t){return"var"==e?m(M("vardef",t),se,A(";"),V):"keyword a"==e?m(M("form"),$,E,V):"keyword b"==e?m(M("form"),E,V):"keyword d"==e?Ze.stream.match(/^\s*$/,!1)?m():m(M("stat"),O,A(";"),V):"debugger"==e?m(A(";")):"{"==e?m(M("}"),g,X,V,j):";"==e?m():"if"==e?("else"==Ze.state.lexical.info&&Ze.state.cc[Ze.state.cc.length-1]==V&&Ze.state.cc.pop()(),m(M("form"),$,E,V,me)):"function"==e?m(we):"for"==e?m(M("form"),ve,E,V):"class"==e||Ge&&"interface"==t?(Ze.marked="keyword",m(M("form","class"==e?e:t),je,V)):"variable"==e?Ge&&"declare"==t?(Ze.marked="keyword",m(E)):Ge&&("module"==t||"enum"==t||"type"==t)&&Ze.stream.match(/^\s*\w/,!1)?(Ze.marked="keyword","enum"==t?m(Pe):"type"==t?m(xe,A("operator"),ee,A(";")):m(M("form"),ue,A("{"),M("}"),X,V,V)):Ge&&"namespace"==t?(Ze.marked="keyword",m(M("form"),I,E,V)):Ge&&"abstract"==t?(Ze.marked="keyword",m(E)):m(M("stat"),D):"switch"==e?m(M("form"),$,A("{"),M("}","switch"),g,X,V,V,j):"case"==e?m(I,A(":")):"default"==e?m(A(":")):"catch"==e?m(M("form"),h,z,E,V,j):"export"==e?m(M("stat"),Ee,V):"import"==e?m(M("stat"),Ie,V):"async"==e?m(E):"@"==t?m(I,E):p(M("stat"),I,A(";"),V)}function z(e){if("("==e)return m(he,A(")"))}function I(e,t){return C(e,t,!1)}function T(e,t){return C(e,t,!0)}function $(e){return"("!=e?p():m(M(")"),I,A(")"),V)}function C(e,t,r){if(Ze.state.fatArrowAt==Ze.stream.start){var n=r?B:U;if("("==e)return m(h,M(")"),Q(he,")"),V,A("=>"),n,j);if("variable"==e)return p(h,ue,A("=>"),n,j)}var a=r?P:q;return Ye.hasOwnProperty(e)?m(a):"function"==e?m(we,a):"class"==e||Ge&&"interface"==t?(Ze.marked="keyword",m(M("form"),ge,V)):"keyword c"==e||"async"==e?m(r?T:I):"("==e?m(M(")"),O,A(")"),V,a):"operator"==e||"spread"==e?m(r?T:I):"["==e?m(M("]"),qe,V,a):"{"==e?R(G,"}",null,a):"quasi"==e?p(S,a):"new"==e?m(H(r)):"import"==e?m(I):m()}function O(e){return e.match(/[;\}\)\],]/)?p():p(I)}function q(e,t){return","==e?m(I):P(e,t,!1)}function P(e,t,r){var n=0==r?q:P,a=0==r?I:T;return"=>"==e?m(h,r?B:U,j):"operator"==e?/\+\+|--/.test(t)||Ge&&"!"==t?m(n):Ge&&"<"==t&&Ze.stream.match(/^([^>]|<.*?>)*>\s*\(/,!1)?m(M(">"),Q(ee,">"),V,n):"?"==t?m(I,A(":"),a):m(a):"quasi"==e?p(S,n):";"!=e?"("==e?R(T,")","call",n):"."==e?m(F,n):"["==e?m(M("]"),O,A("]"),V,n):Ge&&"as"==t?(Ze.marked="keyword",m(ee,n)):"regexp"==e?(Ze.state.lastType=Ze.marked="operator",Ze.stream.backUp(Ze.stream.pos-Ze.stream.start-1),m(a)):void 0:void 0}function S(e,t){return"quasi"!=e?p():"${"!=t.slice(t.length-2)?m(S):m(I,N)}function N(e){if("}"==e)return Ze.marked="string-2",Ze.state.tokenize=s,m(S)}function U(e){return u(Ze.stream,Ze.state),p("{"==e?E:I)}function B(e){return u(Ze.stream,Ze.state),p("{"==e?E:T)}function H(e){return function(t){return"."==t?m(e?W:J):"variable"==t&&Ge?m(ie,e?P:q):p(e?T:I)}}function J(e,t){if("target"==t)return Ze.marked="keyword",m(q)}function W(e,t){if("target"==t)return Ze.marked="keyword",m(P)}function D(e){return":"==e?m(V,E):p(q,A(";"),V)}function F(e){if("variable"==e)return Ze.marked="property",m()}function G(e,t){if("async"==e)return Ze.marked="property",m(G);if("variable"==e||"keyword"==Ze.style){if(Ze.marked="property","get"==t||"set"==t)return m(K);var r;return Ge&&Ze.state.fatArrowAt==Ze.stream.start&&(r=Ze.stream.match(/^\s*:\s*/,!1))&&(Ze.state.fatArrowAt=Ze.stream.pos+r[0].length),m(L)}return"number"==e||"string"==e?(Ze.marked=De?"property":Ze.style+" property",m(L)):"jsonld-keyword"==e?m(L):Ge&&w(t)?(Ze.marked="keyword",m(G)):"["==e?m(I,Y,A("]"),L):"spread"==e?m(T,L):"*"==t?(Ze.marked="keyword",m(G)):":"==e?p(L):void 0}function K(e){return"variable"!=e?p(L):(Ze.marked="property",m(we))}function L(e){return":"==e?m(T):"("==e?p(we):void 0}function Q(e,t,r){function n(a,i){if(r?r.indexOf(a)>-1:","==a){var o=Ze.state.lexical;return"call"==o.info&&(o.pos=(o.pos||0)+1),m(function(r,n){return r==t||n==t?p():p(e)},n)}return a==t||i==t?m():r&&r.indexOf(";")>-1?p(e):m(A(t))}return function(r,a){return r==t||a==t?m():p(e,n)}}function R(e,t,r){for(var n=3;n
|
@@ -1,3 +1,3 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/xml/xml",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},r={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,caseFold:!1};e.defineMode("xml",function(n,a){function i(e,t){function r(r){return t.tokenize=r,r(e,t)}var n=e.next();if("<"==n)return e.eat("!")?e.eat("[")?e.match("CDATA[")?r(s("atom","]]>")):null:e.match("--")?r(s("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),r(c(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=s("meta","?>"),"meta"):(M=e.eat("/")?"closeTag":"openTag",t.tokenize=o,"tag bracket");if("&"==n){var a;return a=e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"),a?"atom":"error"}return e.eatWhile(/[^&<]/),null}function o(e,t){var r=e.next();if(">"==r||"/"==r&&e.eat(">"))return t.tokenize=i,M=">"==r?"endTag":"selfcloseTag","tag bracket";if("="==r)return M="equals",null;if("<"==r){t.tokenize=i,t.state=m,t.tagName=t.tagStart=null;var n=t.tokenize(e,t);return n?n+" tag error":"tag error"}return/[\'\"]/.test(r)?(t.tokenize=l(r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function l(e){var t=function(t,r){for(;!t.eol();)if(t.next()==e){r.tokenize=o;break}return"string"};return t.isInAttribute=!0,t}function s(e,t){return function(r,n){for(;!r.eol();){if(r.match(t)){n.tokenize=i;break}r.next()}return e}}function c(e){return function(t,r){for(var n;null!=(n=t.next());){if("<"==n)return r.tokenize=c(e+1),r.tokenize(t,r);if(">"==n){if(1==e){r.tokenize=i;break}return r.tokenize=c(e-1),r.tokenize(t,r)}}return"meta"}}function u(e,t,r){this.prev=e.context,this.tagName=t,this.indent=e.indented,this.startOfLine=r,(x.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function d(e){e.context&&(e.context=e.context.prev)}function p(e,t){for(var r;;){if(!e.context)return;if(r=e.context.tagName,!x.contextGrabbers.hasOwnProperty(r)||!x.contextGrabbers[r].hasOwnProperty(t))return;d(e)}}function m(e,t,r){return"openTag"==e?(r.tagStart=t.column(),f):"closeTag"==e?g:m}function f(e,t,r){return"word"==e?(r.tagName=t.current(),z="tag",y):(z="error",f)}function g(e,t,r){if("word"==e){var n=t.current();return r.context&&r.context.tagName!=n&&x.implicitlyClosed.hasOwnProperty(r.context.tagName)&&d(r),r.context&&r.context.tagName==n||!1===x.matchClosing?(z="tag",_):(z="tag error",h)}return z="error",h}function _(e,t,r){return"endTag"!=e?(z="error",_):(d(r),m)}function h(e,t,r){return z="error",_(e,t,r)}function y(e,t,r){if("word"==e)return z="attribute",b;if("endTag"==e||"selfcloseTag"==e){var n=r.tagName,a=r.tagStart;return r.tagName=r.tagStart=null,"selfcloseTag"==e||x.autoSelfClosers.hasOwnProperty(n)?p(r,n):(p(r,n),r.context=new u(r,n,a==r.indented)),m}return z="error",y}function b(e,t,r){return"equals"==e?k:(x.allowMissing||(z="error"),y(e,t,r))}function k(e,t,r){return"string"==e?v:"word"==e&&x.allowUnquoted?(z="string",y):(z="error",y(e,t,r))}function v(e,t,r){return"string"==e?v:y(e,t,r)}var w=n.indentUnit,x={},q=a.htmlMode?t:r;for(var S in q)x[S]=q[S];for(var S in a)x[S]=a[S];var M,z;return i.isInText=!0,{startState:function(e){var t={tokenize:i,state:m,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;M=null;var r=t.tokenize(e,t);return(r||M)&&"comment"!=r&&(z=null,t.state=t.state(M||r,e,t),z&&(r="error"==z?r+" error":z)),r},indent:function(t,r,n){var a=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+w;if(a&&a.noIndent)return e.Pass;if(t.tokenize!=o&&t.tokenize!=i)return n?n.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==x.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+w*(x.multilineTagIndentFactor||1);if(x.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:x.htmlMode?"html":"xml",helperType:x.htmlMode?"html":"xml",skipAttribute:function(e){e.state==k&&(e.state=y)}}}),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function a(e,t,r){return Se=e,Me=r,t}function i(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=o(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return a("number","number");if("."==r&&e.match(".."))return a("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return a(r);if("="==r&&e.eat(">"))return a("=>","operator");if("0"==r&&e.eat(/x/i))return e.eatWhile(/[\da-f]/i),a("number","number");if("0"==r&&e.eat(/o/i))return e.eatWhile(/[0-7]/i),a("number","number");if("0"==r&&e.eat(/b/i))return e.eatWhile(/[01]/i),a("number","number");if(/\d/.test(r))return e.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/),a("number","number");if("/"==r)return e.eat("*")?(t.tokenize=l,l(e,t)):e.eat("/")?(e.skipToEnd(),a("comment","comment")):qe(e,t,1)?(n(e),e.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/),a("regexp","string-2")):(e.eat("="),a("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),a("error","error");if(Ae.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),a("operator","operator",e.current());if(Ie.test(r)){e.eatWhile(Ie);var i=e.current();if("."!=t.lastType){if(Ee.propertyIsEnumerable(i)){var c=Ee[i];return a(c.type,c.style,i)}if("async"==i&&e.match(/^\s*[\(\w]/,!1))return a("async","keyword",i)}return a("variable","variable",i)}}function o(e){return function(t,r){var n,o=!1;if(Ce&&"@"==t.peek()&&t.match(Le))return r.tokenize=i,a("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||o);)o=!o&&"\\"==n;return o||(r.tokenize=i),a("string","string")}}function l(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=i;break}n="*"==r}return a("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=i;break}n=!n&&"\\"==r}return a("quasi","string-2",e.current())}function c(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if(Pe){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var a=0,i=!1,o=r-1;o>=0;--o){var l=e.string.charAt(o),s=Oe.indexOf(l);if(s>=0&&s<3){if(!a){++o;break}if(0==--a){"("==l&&(i=!0);break}}else if(s>=3&&s<6)++a;else if(Ie.test(l))i=!0;else{if(/["'\/]/.test(l))return;if(i&&!a){++o;break}}}i&&!a&&(t.fatArrowAt=o)}}function u(e,t,r,n,a,i){this.indented=e,this.column=t,this.type=r,this.prev=a,this.info=i,null!=n&&(this.align=n)}function d(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function p(e,t,r,n,a){var i=e.cc;for($e.state=e,$e.stream=a,$e.marked=null,$e.cc=i,$e.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((i.length?i.pop():je?w:v)(r,n)){for(;i.length&&i[i.length-1].lex;)i.pop()();return $e.marked?$e.marked:"variable"==r&&d(e,n)?"variable-2":t}}}function m(){for(var e=arguments.length-1;e>=0;e--)$e.cc.push(arguments[e])}function f(){return m.apply(null,arguments),!0}function g(e){function t(t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}var n=$e.state;if($e.marked="def",n.context){if(t(n.localVars))return;n.localVars={name:e,next:n.localVars}}else{if(t(n.globalVars))return;r.globalVars&&(n.globalVars={name:e,next:n.globalVars})}}function _(){$e.state.context={prev:$e.state.context,vars:$e.state.localVars},$e.state.localVars=Fe}function h(){$e.state.localVars=$e.state.context.vars,$e.state.context=$e.state.context.prev}function y(e,t){var r=function(){var r=$e.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var a=r.lexical;a&&")"==a.type&&a.align;a=a.prev)n=a.indented;r.lexical=new u(n,$e.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function b(){var e=$e.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function k(e){function t(r){return r==e?f():";"==e?m():f(t)}return t}function v(e,t){return"var"==e?f(y("vardef",t.length),X,k(";"),b):"keyword a"==e?f(y("form"),q,v,b):"keyword b"==e?f(y("form"),v,b):"keyword d"==e?$e.stream.match(/^\s*$/,!1)?f():f(y("stat"),M,k(";"),b):"debugger"==e?f(k(";")):"{"==e?f(y("}"),V,b):";"==e?f():"if"==e?("else"==$e.state.lexical.info&&$e.state.cc[$e.state.cc.length-1]==b&&$e.state.cc.pop()(),f(y("form"),q,v,b,re)):"function"==e?f(se):"for"==e?f(y("form"),ne,v,b):"variable"==e?Pe&&"type"==t?($e.marked="keyword",f(W,k("operator"),W,k(";"))):Pe&&"declare"==t?($e.marked="keyword",f(v)):f(y("stat"),O):"switch"==e?f(y("form"),q,k("{"),y("}","switch"),V,b,b):"case"==e?f(w,k(":")):"default"==e?f(k(":")):"catch"==e?f(y("form"),_,k("("),ce,k(")"),v,b,h):"class"==e?f(y("form"),de,b):"export"==e?f(y("stat"),ge,b):"import"==e?f(y("stat"),he,b):"module"==e?f(y("form"),Q,k("{"),y("}"),V,b,b):"async"==e?f(v):"@"==t?f(w,v):m(y("stat"),w,k(";"),b)}function w(e){return S(e,!1)}function x(e){return S(e,!0)}function q(e){return"("!=e?m():f(y(")"),w,k(")"),b)}function S(e,t){if($e.state.fatArrowAt==$e.stream.start){var r=t?I:P;if("("==e)return f(_,y(")"),K(ce,")"),b,k("=>"),r,h);if("variable"==e)return m(_,Q,k("=>"),r,h)}var n=t?T:z;return De.hasOwnProperty(e)?f(n):"function"==e?f(se,n):"class"==e?f(y("form"),ue,b):"keyword c"==e||"async"==e?f(t?x:w):"("==e?f(y(")"),M,k(")"),b,n):"operator"==e||"spread"==e?f(t?x:w):"["==e?f(y("]"),we,b,n):"{"==e?N($,"}",null,n):"quasi"==e?m(C,n):"new"==e?f(E(t)):f()}function M(e){return e.match(/[;\}\)\],]/)?m():m(w)}function z(e,t){return","==e?f(w):T(e,t,!1)}function T(e,t,r){var n=0==r?z:T,a=0==r?w:x;return"=>"==e?f(_,r?I:P,h):"operator"==e?/\+\+|--/.test(t)||Pe&&"!"==t?f(n):"?"==t?f(w,k(":"),a):f(a):"quasi"==e?m(C,n):";"!=e?"("==e?N(x,")","call",n):"."==e?f(D,n):"["==e?f(y("]"),M,k("]"),b,n):Pe&&"as"==t?($e.marked="keyword",f(W,n)):"regexp"==e?($e.state.lastType=$e.marked="operator",$e.stream.backUp($e.stream.pos-$e.stream.start-1),f(a)):void 0:void 0}function C(e,t){return"quasi"!=e?m():"${"!=t.slice(t.length-2)?f(C):f(w,j)}function j(e){if("}"==e)return $e.marked="string-2",$e.state.tokenize=s,f(C)}function P(e){return c($e.stream,$e.state),m("{"==e?v:w)}function I(e){return c($e.stream,$e.state),m("{"==e?v:x)}function E(e){return function(t){return"."==t?f(e?L:A):"variable"==t&&Pe?f(Y,e?T:z):m(e?x:w)}}function A(e,t){if("target"==t)return $e.marked="keyword",f(z)}function L(e,t){if("target"==t)return $e.marked="keyword",f(T)}function O(e){return":"==e?f(b,v):m(z,k(";"),b)}function D(e){if("variable"==e)return $e.marked="property",f()}function $(e,t){if("async"==e)return $e.marked="property",f($);if("variable"==e||"keyword"==$e.style){if($e.marked="property","get"==t||"set"==t)return f(F);var r;return Pe&&$e.state.fatArrowAt==$e.stream.start&&(r=$e.stream.match(/^\s*:\s*/,!1))&&($e.state.fatArrowAt=$e.stream.pos+r[0].length),f(B)}return"number"==e||"string"==e?($e.marked=Ce?"property":$e.style+" property",f(B)):"jsonld-keyword"==e?f(B):"modifier"==e?f($):"["==e?f(w,k("]"),B):"spread"==e?f(x,B):"*"==t?($e.marked="keyword",f($)):":"==e?m(B):void 0}function F(e){return"variable"!=e?m(B):($e.marked="property",f(se))}function B(e){return":"==e?f(x):"("==e?m(se):void 0}function K(e,t,r){function n(a,i){if(r?r.indexOf(a)>-1:","==a){var o=$e.state.lexical;return"call"==o.info&&(o.pos=(o.pos||0)+1),f(function(r,n){return r==t||n==t?m():m(e)},n)}return a==t||i==t?f():f(k(t))}return function(r,a){return r==t||a==t?f():m(e,n)}}function N(e,t,r){for(var n=3;n
|
2
|
-
;var n=["domain","regexp","url","url-prefix"],a=t(n),i=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],o=t(i),l=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover"],s=t(l),c=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],u=t(c),d=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","baseline-shift","binding","bleed","bookmark-label","bookmark-level","bookmark-state","bookmark-target","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-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","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","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-feature-settings","font-family","font-kerning","font-language-override","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-weight","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","max-height","max-width","min-height","min-width","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotation","rotation-point","ruby-align","ruby-overhang","ruby-position","ruby-span","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-outline","text-overflow","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],p=t(d),m=["scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-3d-light-color","scrollbar-track-color","shape-inside","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","zoom"],f=t(m),g=["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"],_=t(g),h=["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"],y=t(h),b=["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","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","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","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],k=t(b),v=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],w=t(v),x=n.concat(i).concat(l).concat(c).concat(d).concat(m).concat(b).concat(v);e.registerHelper("hintWords","css",x),e.defineMIME("text/css",{documentTypes:a,mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:_,counterDescriptors:y,colorKeywords:k,valueKeywords:w,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:w,fontProperties:_,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},":":function(e){return!!e.match(/\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:w,fontProperties:_,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:a,mediaTypes:o,mediaFeatures:s,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:_,counterDescriptors:y,colorKeywords:k,valueKeywords:w,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css",helperType:"gss"})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../xml/xml"),require("../javascript/javascript"),require("../css/css")):"function"==typeof define&&define.amd?define("mode/htmlmixed/htmlmixed",["../../lib/codemirror","../xml/xml","../javascript/javascript","../css/css"],e):e(CodeMirror)}(function(e){"use strict";function t(e,t,r){var n=e.current(),a=n.search(t);return a>-1?e.backUp(n.length-a):n.match(/<\/?$/)&&(e.backUp(n.length),e.match(t,!1)||e.match(n)),r}function r(e){var t=s[e];return t||(s[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}function n(e,t){var n=e.match(r(t));return n?/^\s*(.*?)\s*$/.exec(n[2])[1]:""}function a(e,t){return new RegExp((t?"^":"")+"","i")}function i(e,t){for(var r in e)for(var n=t[r]||(t[r]=[]),a=e[r],i=a.length-1;i>=0;i--)n.unshift(a[i])}function o(e,t){for(var r=0;r
|
3
|
-
return e.eatWhile(/[\w\$_]/),"meta"},'"':function(e,t){return!!e.match('""')&&(t.tokenize=_,t.tokenize(e,t))},"'":function(e){return e.eatWhile(/[\w\$_\xa1-\uffff]/),"atom"},"=":function(e,r){var n=r.context;return!("}"!=n.type||!n.align||!e.eat(">"))&&(r.context=new t(n.indented,n.column,n.type,n.info,null,n.prev),"operator")}},modeProps:{closeBrackets:{triples:'"'}}}),g("text/x-kotlin",{name:"clike",keywords:o("package as typealias class interface this super val var fun for is in This throw return break continue object if else while do try when !in !is as? file import where by get set abstract enum open inner override private public internal protected catch finally out final vararg reified dynamic companion constructor init sealed field property receiver param sparam lateinit data inline noinline tailrec external annotation crossinline const operator infix suspend"),types:o("Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable Compiler Double Exception Float Integer Long Math Number Object Package Pair Process Runtime Runnable SecurityManager Short StackTraceElement StrictMath String StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void"),intendSwitch:!1,indentStatements:!1,multiLineStrings:!0,number:/^(?:0x[a-f\d_]+|0b[01_]+|(?:[\d_]+\.?\d*|\.\d+)(?:e[-+]?[\d_]+)?)(u|ll?|l|f)?/i,blockKeywords:o("catch class do else finally for if where try while enum"),defKeywords:o("class val var object interface fun"),atoms:o("true false null this"),hooks:{'"':function(e,t){return t.tokenize=h(e.match('""')),t.tokenize(e,t)}},modeProps:{closeBrackets:{triples:'"'}}}),g(["x-shader/x-vertex","x-shader/x-fragment"],{name:"clike",keywords:o("sampler1D sampler2D sampler3D samplerCube sampler1DShadow sampler2DShadow const attribute uniform varying break continue discard return for while do if else struct in out inout"),types:o("float int bool void vec2 vec3 vec4 ivec2 ivec3 ivec4 bvec2 bvec3 bvec4 mat2 mat3 mat4"),blockKeywords:o("for while do if else struct"),builtin:o("radians degrees sin cos tan asin acos atan pow exp log exp2 sqrt inversesqrt abs sign floor ceil fract mod min max clamp mix step smoothstep length distance dot cross normalize ftransform faceforward reflect refract matrixCompMult lessThan lessThanEqual greaterThan greaterThanEqual equal notEqual any all not texture1D texture1DProj texture1DLod texture1DProjLod texture2D texture2DProj texture2DLod texture2DProjLod texture3D texture3DProj texture3DLod texture3DProjLod textureCube textureCubeLod shadow1D shadow2D shadow1DProj shadow2DProj shadow1DLod shadow2DLod shadow1DProjLod shadow2DProjLod dFdx dFdy fwidth noise1 noise2 noise3 noise4"),atoms:o("true false gl_FragColor gl_SecondaryColor gl_Normal gl_Vertex gl_MultiTexCoord0 gl_MultiTexCoord1 gl_MultiTexCoord2 gl_MultiTexCoord3 gl_MultiTexCoord4 gl_MultiTexCoord5 gl_MultiTexCoord6 gl_MultiTexCoord7 gl_FogCoord gl_PointCoord gl_Position gl_PointSize gl_ClipVertex gl_FrontColor gl_BackColor gl_FrontSecondaryColor gl_BackSecondaryColor gl_TexCoord gl_FogFragCoord gl_FragCoord gl_FrontFacing gl_FragData gl_FragDepth gl_ModelViewMatrix gl_ProjectionMatrix gl_ModelViewProjectionMatrix gl_TextureMatrix gl_NormalMatrix gl_ModelViewMatrixInverse gl_ProjectionMatrixInverse gl_ModelViewProjectionMatrixInverse gl_TexureMatrixTranspose gl_ModelViewMatrixInverseTranspose gl_ProjectionMatrixInverseTranspose gl_ModelViewProjectionMatrixInverseTranspose gl_TextureMatrixInverseTranspose gl_NormalScale gl_DepthRange gl_ClipPlane gl_Point gl_FrontMaterial gl_BackMaterial gl_LightSource gl_LightModel gl_FrontLightModelProduct gl_BackLightModelProduct gl_TextureColor gl_EyePlaneS gl_EyePlaneT gl_EyePlaneR gl_EyePlaneQ gl_FogParameters gl_MaxLights gl_MaxClipPlanes gl_MaxTextureUnits gl_MaxTextureCoords gl_MaxVertexAttribs gl_MaxVertexUniformComponents gl_MaxVaryingFloats gl_MaxVertexTextureImageUnits gl_MaxTextureImageUnits gl_MaxFragmentUniformComponents gl_MaxCombineTextureImageUnits gl_MaxDrawBuffers"),indentSwitch:!1,hooks:{"#":s},modeProps:{fold:["brace","include"]}}),g("text/x-nesc",{name:"clike",keywords:o(b+"as atomic async call command component components configuration event generic implementation includes interface module new norace nx_struct nx_union post provides signal task uses abstract extends"),types:o(k),blockKeywords:o("case do else for if switch while struct"),atoms:o("null true false"),hooks:{"#":s},modeProps:{fold:["brace","include"]}}),g("text/x-objectivec",{name:"clike",keywords:o(b+"inline restrict _Bool _Complex _Imaginary BOOL Class bycopy byref id IMP in inout nil oneway out Protocol SEL self super atomic nonatomic retain copy readwrite readonly"),types:o(k),atoms:o("YES NO NULL NILL ON OFF true false"),hooks:{"@":function(e){return e.eatWhile(/[\w\$]/),"keyword"},"#":s,indent:function(e,t,r){if("statement"==t.type&&/^@\w/.test(r))return t.indented}},modeProps:{fold:"brace"}}),g("text/x-squirrel",{name:"clike",keywords:o("base break clone continue const default delete enum extends function in class foreach local resume return this throw typeof yield constructor instanceof static"),types:o(k),blockKeywords:o("case catch class else for foreach if switch try while"),defKeywords:o("function local class"),typeFirstDefinitions:!0,atoms:o("true false null"),hooks:{"#":s},modeProps:{fold:["brace","include"]}});var v=null;g("text/x-ceylon",{name:"clike",keywords:o("abstracts alias assembly assert assign break case catch class continue dynamic else exists extends finally for function given if import in interface is let module new nonempty object of out outer package return satisfies super switch then this throw try value void while"),types:function(e){var t=e.charAt(0);return t===t.toUpperCase()&&t!==t.toLowerCase()},blockKeywords:o("case catch class dynamic else finally for function if interface module new object switch try while"),defKeywords:o("class dynamic function interface module object package value"),builtin:o("abstract actual aliased annotation by default deprecated doc final formal late license native optional sealed see serializable shared suppressWarnings tagged throws variable"),isPunctuationChar:/[\[\]{}\(\),;\:\.`]/,isOperatorChar:/[+\-*&%=<>!?|^~:\/]/,numberStart:/[\d#$]/,number:/^(?:#[\da-fA-F_]+|\$[01_]+|[\d_]+[kMGTPmunpf]?|[\d_]+\.[\d_]+(?:[eE][-+]?\d+|[kMGTPmunpf]|)|)/i,multiLineStrings:!0,typeFirstDefinitions:!0,atoms:o("true false null larger smaller equal empty finished"),indentSwitch:!1,styleDefs:!1,hooks:{"@":function(e){return e.eatWhile(/[\w\$_]/),"meta"},'"':function(e,t){return t.tokenize=y(e.match('""')?"triple":"single"),t.tokenize(e,t)},"`":function(e,t){return!(!v||!e.match("`"))&&(t.tokenize=v,v=null,t.tokenize(e,t))},"'":function(e){return e.eatWhile(/[\w\$_\xa1-\uffff]/),"atom"},token:function(e,t,r){if(("variable"==r||"type"==r)&&"."==t.prevToken)return"variable-2"}},modeProps:{fold:["brace","import"],closeBrackets:{triples:'"'}}})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../htmlmixed/htmlmixed"),require("../clike/clike")):"function"==typeof define&&define.amd?define("mode/php/php.js",["../../lib/codemirror","../htmlmixed/htmlmixed","../clike/clike"],e):e(CodeMirror)}(function(e){"use strict";function t(e){for(var t={},r=e.split(" "),n=0;n
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/xml/xml",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";var t={autoSelfClosers:{area:!0,base:!0,br:!0,col:!0,command:!0,embed:!0,frame:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0,menuitem:!0},implicitlyClosed:{dd:!0,li:!0,optgroup:!0,option:!0,p:!0,rp:!0,rt:!0,tbody:!0,td:!0,tfoot:!0,th:!0,tr:!0},contextGrabbers:{dd:{dd:!0,dt:!0},dt:{dd:!0,dt:!0},li:{li:!0},option:{option:!0,optgroup:!0},optgroup:{optgroup:!0},p:{address:!0,article:!0,aside:!0,blockquote:!0,dir:!0,div:!0,dl:!0,fieldset:!0,footer:!0,form:!0,h1:!0,h2:!0,h3:!0,h4:!0,h5:!0,h6:!0,header:!0,hgroup:!0,hr:!0,menu:!0,nav:!0,ol:!0,p:!0,pre:!0,section:!0,table:!0,ul:!0},rp:{rp:!0,rt:!0},rt:{rp:!0,rt:!0},tbody:{tbody:!0,tfoot:!0},td:{td:!0,th:!0},tfoot:{tbody:!0},th:{td:!0,th:!0},thead:{tbody:!0,tfoot:!0},tr:{tr:!0}},doNotIndent:{pre:!0},allowUnquoted:!0,allowMissing:!0,caseFold:!0},r={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,allowMissingTagName:!1,caseFold:!1};e.defineMode("xml",function(n,a){function o(e,t){function r(r){return t.tokenize=r,r(e,t)}var n=e.next();if("<"==n)return e.eat("!")?e.eat("[")?e.match("CDATA[")?r(s("atom","]]>")):null:e.match("--")?r(s("comment","--\x3e")):e.match("DOCTYPE",!0,!0)?(e.eatWhile(/[\w\._\-]/),r(c(1))):null:e.eat("?")?(e.eatWhile(/[\w\._\-]/),t.tokenize=s("meta","?>"),"meta"):(T=e.eat("/")?"closeTag":"openTag",t.tokenize=i,"tag bracket");if("&"==n){var a;return a=e.eat("#")?e.eat("x")?e.eatWhile(/[a-fA-F\d]/)&&e.eat(";"):e.eatWhile(/[\d]/)&&e.eat(";"):e.eatWhile(/[\w\.\-:]/)&&e.eat(";"),a?"atom":"error"}return e.eatWhile(/[^&<]/),null}function i(e,t){var r=e.next();if(">"==r||"/"==r&&e.eat(">"))return t.tokenize=o,T=">"==r?"endTag":"selfcloseTag","tag bracket";if("="==r)return T="equals",null;if("<"==r){t.tokenize=o,t.state=m,t.tagName=t.tagStart=null;var n=t.tokenize(e,t);return n?n+" tag error":"tag error"}return/[\'\"]/.test(r)?(t.tokenize=l(r),t.stringStartCol=e.column(),t.tokenize(e,t)):(e.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function l(e){var t=function(t,r){for(;!t.eol();)if(t.next()==e){r.tokenize=i;break}return"string"};return t.isInAttribute=!0,t}function s(e,t){return function(r,n){for(;!r.eol();){if(r.match(t)){n.tokenize=o;break}r.next()}return e}}function c(e){return function(t,r){for(var n;null!=(n=t.next());){if("<"==n)return r.tokenize=c(e+1),r.tokenize(t,r);if(">"==n){if(1==e){r.tokenize=o;break}return r.tokenize=c(e-1),r.tokenize(t,r)}}return"meta"}}function u(e,t,r){this.prev=e.context,this.tagName=t,this.indent=e.indented,this.startOfLine=r,(x.doNotIndent.hasOwnProperty(t)||e.context&&e.context.noIndent)&&(this.noIndent=!0)}function d(e){e.context&&(e.context=e.context.prev)}function p(e,t){for(var r;;){if(!e.context)return;if(r=e.context.tagName,!x.contextGrabbers.hasOwnProperty(r)||!x.contextGrabbers[r].hasOwnProperty(t))return;d(e)}}function m(e,t,r){return"openTag"==e?(r.tagStart=t.column(),f):"closeTag"==e?g:m}function f(e,t,r){return"word"==e?(r.tagName=t.current(),z="tag",y):x.allowMissingTagName&&"endTag"==e?(z="tag bracket",y(e,t,r)):(z="error",f)}function g(e,t,r){if("word"==e){var n=t.current();return r.context&&r.context.tagName!=n&&x.implicitlyClosed.hasOwnProperty(r.context.tagName)&&d(r),r.context&&r.context.tagName==n||!1===x.matchClosing?(z="tag",_):(z="tag error",h)}return x.allowMissingTagName&&"endTag"==e?(z="tag bracket",_(e,t,r)):(z="error",h)}function _(e,t,r){return"endTag"!=e?(z="error",_):(d(r),m)}function h(e,t,r){return z="error",_(e,t,r)}function y(e,t,r){if("word"==e)return z="attribute",b;if("endTag"==e||"selfcloseTag"==e){var n=r.tagName,a=r.tagStart;return r.tagName=r.tagStart=null,"selfcloseTag"==e||x.autoSelfClosers.hasOwnProperty(n)?p(r,n):(p(r,n),r.context=new u(r,n,a==r.indented)),m}return z="error",y}function b(e,t,r){return"equals"==e?k:(x.allowMissing||(z="error"),y(e,t,r))}function k(e,t,r){return"string"==e?v:"word"==e&&x.allowUnquoted?(z="string",y):(z="error",y(e,t,r))}function v(e,t,r){return"string"==e?v:y(e,t,r)}var w=n.indentUnit,x={},q=a.htmlMode?t:r;for(var S in q)x[S]=q[S];for(var S in a)x[S]=a[S];var T,z;return o.isInText=!0,{startState:function(e){var t={tokenize:o,state:m,indented:e||0,tagName:null,tagStart:null,context:null};return null!=e&&(t.baseIndent=e),t},token:function(e,t){if(!t.tagName&&e.sol()&&(t.indented=e.indentation()),e.eatSpace())return null;T=null;var r=t.tokenize(e,t);return(r||T)&&"comment"!=r&&(z=null,t.state=t.state(T||r,e,t),z&&(r="error"==z?r+" error":z)),r},indent:function(t,r,n){var a=t.context;if(t.tokenize.isInAttribute)return t.tagStart==t.indented?t.stringStartCol+1:t.indented+w;if(a&&a.noIndent)return e.Pass;if(t.tokenize!=i&&t.tokenize!=o)return n?n.match(/^(\s*)/)[0].length:0;if(t.tagName)return!1!==x.multilineTagIndentPastTag?t.tagStart+t.tagName.length+2:t.tagStart+w*(x.multilineTagIndentFactor||1);if(x.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:x.htmlMode?"html":"xml",helperType:x.htmlMode?"html":"xml",skipAttribute:function(e){e.state==k&&(e.state=y)}}}),e.defineMIME("text/xml","xml"),e.defineMIME("application/xml","xml"),e.mimeModes.hasOwnProperty("text/html")||e.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("mode/javascript/javascript",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("javascript",function(t,r){function n(e){for(var t,r=!1,n=!1;null!=(t=e.next());){if(!r){if("/"==t&&!n)return;"["==t?n=!0:n&&"]"==t&&(n=!1)}r=!r&&"\\"==t}}function a(e,t,r){return Fe=e,$e=r,t}function o(e,t){var r=e.next();if('"'==r||"'"==r)return t.tokenize=i(r),t.tokenize(e,t);if("."==r&&e.match(/^\d+(?:[eE][+\-]?\d+)?/))return a("number","number");if("."==r&&e.match(".."))return a("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(r))return a(r);if("="==r&&e.eat(">"))return a("=>","operator");if("0"==r&&e.match(/^(?:x[\da-f]+|o[0-7]+|b[01]+)n?/i))return a("number","number");if(/\d/.test(r))return e.match(/^\d*(?:n|(?:\.\d*)?(?:[eE][+\-]?\d+)?)?/),a("number","number");if("/"==r)return e.eat("*")?(t.tokenize=l,l(e,t)):e.eat("/")?(e.skipToEnd(),a("comment","comment")):De(e,t,1)?(n(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),a("regexp","string-2")):(e.eat("="),a("operator","operator",e.current()));if("`"==r)return t.tokenize=s,s(e,t);if("#"==r)return e.skipToEnd(),a("error","error");if(He.test(r))return">"==r&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=r&&"="!=r||e.eat("="):/[<>*+\-]/.test(r)&&(e.eat(r),">"==r&&e.eat(r))),a("operator","operator",e.current());if(We.test(r)){e.eatWhile(We);var o=e.current();if("."!=t.lastType){if(Ge.propertyIsEnumerable(o)){var c=Ge[o];return a(c.type,c.style,o)}if("async"==o&&e.match(/^(\s|\/\*.*?\*\/)*[\[\(\w]/,!1))return a("async","keyword",o)}return a("variable","variable",o)}}function i(e){return function(t,r){var n,i=!1;if(Ue&&"@"==t.peek()&&t.match(Ze))return r.tokenize=o,a("jsonld-keyword","meta");for(;null!=(n=t.next())&&(n!=e||i);)i=!i&&"\\"==n;return i||(r.tokenize=o),a("string","string")}}function l(e,t){for(var r,n=!1;r=e.next();){if("/"==r&&n){t.tokenize=o;break}n="*"==r}return a("comment","comment")}function s(e,t){for(var r,n=!1;null!=(r=e.next());){if(!n&&("`"==r||"$"==r&&e.eat("{"))){t.tokenize=o;break}n=!n&&"\\"==r}return a("quasi","string-2",e.current())}function c(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var r=e.string.indexOf("=>",e.start);if(!(r<0)){if(Ve){var n=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,r));n&&(r=n.index)}for(var a=0,o=!1,i=r-1;i>=0;--i){var l=e.string.charAt(i),s=Xe.indexOf(l);if(s>=0&&s<3){if(!a){++i;break}if(0==--a){"("==l&&(o=!0);break}}else if(s>=3&&s<6)++a;else if(We.test(l))o=!0;else{if(/["'\/]/.test(l))return;if(o&&!a){++i;break}}}o&&!a&&(t.fatArrowAt=i)}}function u(e,t,r,n,a,o){this.indented=e,this.column=t,this.type=r,this.prev=a,this.info=o,null!=n&&(this.align=n)}function d(e,t){for(var r=e.localVars;r;r=r.next)if(r.name==t)return!0;for(var n=e.context;n;n=n.prev)for(var r=n.vars;r;r=r.next)if(r.name==t)return!0}function p(e,t,r,n,a){var o=e.cc;for(Qe.state=e,Qe.stream=a,Qe.marked=null,Qe.cc=o,Qe.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;){if((o.length?o.pop():Re?C:z)(r,n)){for(;o.length&&o[o.length-1].lex;)o.pop()();return Qe.marked?Qe.marked:"variable"==r&&d(e,n)?"variable-2":t}}}function m(){for(var e=arguments.length-1;e>=0;e--)Qe.cc.push(arguments[e])}function f(){return m.apply(null,arguments),!0}function g(e,t){for(var r=t;r;r=r.next)if(r.name==e)return!0;return!1}function _(e){var t=Qe.state;if(Qe.marked="def",t.context)if("var"==t.lexical.info&&t.context&&t.context.block){var n=h(e,t.context);if(null!=n)return void(t.context=n)}else if(!g(e,t.localVars))return void(t.localVars=new k(e,t.localVars));r.globalVars&&!g(e,t.globalVars)&&(t.globalVars=new k(e,t.globalVars))}function h(e,t){if(t){if(t.block){var r=h(e,t.prev);return r?r==t.prev?t:new b(r,t.vars,!0):null}return g(e,t.vars)?t:new b(t.prev,new k(e,t.vars),!1)}return null}function y(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function b(e,t,r){this.prev=e,this.vars=t,this.block=r}function k(e,t){this.name=e,this.next=t}function v(){Qe.state.context=new b(Qe.state.context,Qe.state.localVars,!1),Qe.state.localVars=Je}function w(){Qe.state.context=new b(Qe.state.context,Qe.state.localVars,!0),Qe.state.localVars=null}function x(){Qe.state.localVars=Qe.state.context.vars,Qe.state.context=Qe.state.context.prev}function q(e,t){var r=function(){var r=Qe.state,n=r.indented;if("stat"==r.lexical.type)n=r.lexical.indented;else for(var a=r.lexical;a&&")"==a.type&&a.align;a=a.prev)n=a.indented;r.lexical=new u(n,Qe.stream.column(),e,null,r.lexical,t)};return r.lex=!0,r}function S(){var e=Qe.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function T(e){function t(r){return r==e?f():";"==e||"}"==r||")"==r||"]"==r?m():f(t)}return t}function z(e,t){return"var"==e?f(q("vardef",t),se,T(";"),S):"keyword a"==e?f(q("form"),I,z,S):"keyword b"==e?f(q("form"),z,S):"keyword d"==e?Qe.stream.match(/^\s*$/,!1)?f():f(q("stat"),E,T(";"),S):"debugger"==e?f(T(";")):"{"==e?f(q("}"),w,X,S,x):";"==e?f():"if"==e?("else"==Qe.state.lexical.info&&Qe.state.cc[Qe.state.cc.length-1]==S&&Qe.state.cc.pop()(),f(q("form"),I,z,S,fe)):"function"==e?f(ye):"for"==e?f(q("form"),ge,z,S):"class"==e||Ve&&"interface"==t?(Qe.marked="keyword",f(q("form","class"==e?e:t),xe,S)):"variable"==e?Ve&&"declare"==t?(Qe.marked="keyword",f(z)):Ve&&("module"==t||"enum"==t||"type"==t)&&Qe.stream.match(/^\s*\w/,!1)?(Qe.marked="keyword","enum"==t?f(Ae):"type"==t?f(ke,T("operator"),ee,T(";")):f(q("form"),ce,T("{"),q("}"),X,S,S)):Ve&&"namespace"==t?(Qe.marked="keyword",f(q("form"),C,z,S)):Ve&&"abstract"==t?(Qe.marked="keyword",f(z)):f(q("stat"),U):"switch"==e?f(q("form"),I,T("{"),q("}","switch"),w,X,S,S,x):"case"==e?f(C,T(":")):"default"==e?f(T(":")):"catch"==e?f(q("form"),v,M,z,S,x):"export"==e?f(q("stat"),ze,S):"import"==e?f(q("stat"),Ce,S):"async"==e?f(z):"@"==t?f(C,z):m(q("stat"),C,T(";"),S)}function M(e){if("("==e)return f(ve,T(")"))}function C(e,t){return P(e,t,!1)}function j(e,t){return P(e,t,!0)}function I(e){return"("!=e?m():f(q(")"),C,T(")"),S)}function P(e,t,r){if(Qe.state.fatArrowAt==Qe.stream.start){var n=r?F:D;if("("==e)return f(v,q(")"),H(ve,")"),S,T("=>"),n,x);if("variable"==e)return m(v,ce,T("=>"),n,x)}var a=r?A:N;return Ye.hasOwnProperty(e)?f(a):"function"==e?f(ye,a):"class"==e||Ve&&"interface"==t?(Qe.marked="keyword",f(q("form"),we,S)):"keyword c"==e||"async"==e?f(r?j:C):"("==e?f(q(")"),E,T(")"),S,a):"operator"==e||"spread"==e?f(r?j:C):"["==e?f(q("]"),Ne,S,a):"{"==e?Z(V,"}",null,a):"quasi"==e?m(L,a):"new"==e?f($(r)):"import"==e?f(C):f()}function E(e){return e.match(/[;\}\)\],]/)?m():m(C)}function N(e,t){return","==e?f(C):A(e,t,!1)}function A(e,t,r){var n=0==r?N:A,a=0==r?C:j;return"=>"==e?f(v,r?F:D,x):"operator"==e?/\+\+|--/.test(t)||Ve&&"!"==t?f(n):Ve&&"<"==t&&Qe.stream.match(/^([^>]|<.*?>)*>\s*\(/,!1)?f(q(">"),H(ee,">"),S,n):"?"==t?f(C,T(":"),a):f(a):"quasi"==e?m(L,n):";"!=e?"("==e?Z(j,")","call",n):"."==e?f(R,n):"["==e?f(q("]"),E,T("]"),S,n):Ve&&"as"==t?(Qe.marked="keyword",f(ee,n)):"regexp"==e?(Qe.state.lastType=Qe.marked="operator",Qe.stream.backUp(Qe.stream.pos-Qe.stream.start-1),f(a)):void 0:void 0}function L(e,t){return"quasi"!=e?m():"${"!=t.slice(t.length-2)?f(L):f(C,O)}function O(e){if("}"==e)return Qe.marked="string-2",Qe.state.tokenize=s,f(L)}function D(e){return c(Qe.stream,Qe.state),m("{"==e?z:C)}function F(e){return c(Qe.stream,Qe.state),m("{"==e?z:j)}function $(e){return function(t){return"."==t?f(e?K:B):"variable"==t&&Ve?f(oe,e?A:N):m(e?j:C)}}function B(e,t){if("target"==t)return Qe.marked="keyword",f(N)}function K(e,t){if("target"==t)return Qe.marked="keyword",f(A)}function U(e){return":"==e?f(S,z):m(N,T(";"),S)}function R(e){if("variable"==e)return Qe.marked="property",f()}function V(e,t){if("async"==e)return Qe.marked="property",f(V);if("variable"==e||"keyword"==Qe.style){if(Qe.marked="property","get"==t||"set"==t)return f(W);var r;return Ve&&Qe.state.fatArrowAt==Qe.stream.start&&(r=Qe.stream.match(/^\s*:\s*/,!1))&&(Qe.state.fatArrowAt=Qe.stream.pos+r[0].length),f(G)}return"number"==e||"string"==e?(Qe.marked=Ue?"property":Qe.style+" property",f(G)):"jsonld-keyword"==e?f(G):Ve&&y(t)?(Qe.marked="keyword",f(V)):"["==e?f(C,Y,T("]"),G):"spread"==e?f(j,G):"*"==t?(Qe.marked="keyword",f(V)):":"==e?m(G):void 0}function W(e){return"variable"!=e?m(G):(Qe.marked="property",f(ye))}function G(e){return":"==e?f(j):"("==e?m(ye):void 0}function H(e,t,r){function n(a,o){if(r?r.indexOf(a)>-1:","==a){var i=Qe.state.lexical;return"call"==i.info&&(i.pos=(i.pos||0)+1),f(function(r,n){return r==t||n==t?m():m(e)},n)}return a==t||o==t?f():r&&r.indexOf(";")>-1?m(e):f(T(t))}return function(r,a){return r==t||a==t?f():m(e,n)}}function Z(e,t,r){for(var n=3;n
|
2
|
+
;var n=["domain","regexp","url","url-prefix"],a=t(n),o=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],i=t(o),l=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover"],s=t(l),c=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],u=t(c),d=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-repeat","background-size","baseline-shift","binding","bleed","bookmark-label","bookmark-level","bookmark-state","bookmark-target","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-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","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","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-feature-settings","font-family","font-kerning","font-language-override","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-weight","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","max-height","max-width","min-height","min-width","mix-blend-mode","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotation","rotation-point","ruby-align","ruby-overhang","ruby-position","ruby-span","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-outline","text-overflow","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],p=t(d),m=["scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-3d-light-color","scrollbar-track-color","shape-inside","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","zoom"],f=t(m),g=["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"],_=t(g),h=["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"],y=t(h),b=["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","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","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","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],k=t(b),v=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],w=t(v),x=n.concat(o).concat(l).concat(c).concat(d).concat(m).concat(b).concat(v);e.registerHelper("hintWords","css",x),e.defineMIME("text/css",{documentTypes:a,mediaTypes:i,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:_,counterDescriptors:y,colorKeywords:k,valueKeywords:w,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:w,fontProperties:_,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},":":function(e){return!!e.match(/\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:i,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:p,nonStandardPropertyKeywords:f,colorKeywords:k,valueKeywords:w,fontProperties:_,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=r,r(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:a,mediaTypes:i,mediaFeatures:s,propertyKeywords:p,nonStandardPropertyKeywords:f,fontProperties:_,counterDescriptors:y,colorKeywords:k,valueKeywords:w,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=r,r(e,t))}},name:"css",helperType:"gss"})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../xml/xml"),require("../javascript/javascript"),require("../css/css")):"function"==typeof define&&define.amd?define("mode/htmlmixed/htmlmixed",["../../lib/codemirror","../xml/xml","../javascript/javascript","../css/css"],e):e(CodeMirror)}(function(e){"use strict";function t(e,t,r){var n=e.current(),a=n.search(t);return a>-1?e.backUp(n.length-a):n.match(/<\/?$/)&&(e.backUp(n.length),e.match(t,!1)||e.match(n)),r}function r(e){var t=s[e];return t||(s[e]=new RegExp("\\s+"+e+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}function n(e,t){var n=e.match(r(t));return n?/^\s*(.*?)\s*$/.exec(n[2])[1]:""}function a(e,t){return new RegExp((t?"^":"")+"","i")}function o(e,t){for(var r in e)for(var n=t[r]||(t[r]=[]),a=e[r],o=a.length-1;o>=0;o--)n.unshift(a[o])}function i(e,t){for(var r=0;r
|
3
|
+
types:i("AnyVal App Application Array BufferedIterator BigDecimal BigInt Char Console Either Enumeration Equiv Error Exception Fractional Function IndexedSeq Int Integral Iterable Iterator List Map Numeric Nil NotNull Option Ordered Ordering PartialFunction PartialOrdering Product Proxy Range Responder Seq Serializable Set Specializable Stream StringBuilder StringContext Symbol Throwable Traversable TraversableOnce Tuple Unit Vector Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable Compiler Double Exception Float Integer Long Math Number Object Package Pair Process Runtime Runnable SecurityManager Short StackTraceElement StrictMath String StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void"),multiLineStrings:!0,blockKeywords:i("catch class enum do else finally for forSome if match switch try while"),defKeywords:i("class enum def object package trait type val var"),atoms:i("true false null"),indentStatements:!1,indentSwitch:!1,isOperatorChar:/[+\-*&%=<>!?|\/#:@]/,hooks:{"@":function(e){return e.eatWhile(/[\w\$_]/),"meta"},'"':function(e,t){return!!e.match('""')&&(t.tokenize=b,t.tokenize(e,t))},"'":function(e){return e.eatWhile(/[\w\$_\xa1-\uffff]/),"atom"},"=":function(e,r){var n=r.context;return!("}"!=n.type||!n.align||!e.eat(">"))&&(r.context=new t(n.indented,n.column,n.type,n.info,null,n.prev),"operator")},"/":function(e,t){return!!e.eat("*")&&(t.tokenize=k(1),t.tokenize(e,t))}},modeProps:{closeBrackets:{pairs:'()[]{}""',triples:'"'}}}),y("text/x-kotlin",{name:"clike",keywords:i("package as typealias class interface this super val operator var fun for is in This throw return annotation break continue object if else while do try when !in !is as? file import where by get set abstract enum open inner override private public internal protected catch finally out final vararg reified dynamic companion constructor init sealed field property receiver param sparam lateinit data inline noinline tailrec external annotation crossinline const operator infix suspend actual expect setparam"),types:i("Boolean Byte Character CharSequence Class ClassLoader Cloneable Comparable Compiler Double Exception Float Integer Long Math Number Object Package Pair Process Runtime Runnable SecurityManager Short StackTraceElement StrictMath String StringBuffer System Thread ThreadGroup ThreadLocal Throwable Triple Void Annotation Any BooleanArray ByteArray Char CharArray DeprecationLevel DoubleArray Enum FloatArray Function Int IntArray Lazy LazyThreadSafetyMode LongArray Nothing ShortArray Unit"),intendSwitch:!1,indentStatements:!1,multiLineStrings:!0,number:/^(?:0x[a-f\d_]+|0b[01_]+|(?:[\d_]+(\.\d+)?|\.\d+)(?:e[-+]?[\d_]+)?)(u|ll?|l|f)?/i,blockKeywords:i("catch class do else finally for if where try while enum"),defKeywords:i("class val var object interface fun"),atoms:i("true false null this"),hooks:{"@":function(e){return e.eatWhile(/[\w\$_]/),"meta"},"*":function(e,t){return"."==t.prevToken?"variable":"operator"},'"':function(e,t){return t.tokenize=v(e.match('""')),t.tokenize(e,t)},indent:function(e,t,r,n){var a=r&&r.charAt(0);return"}"!=e.prevToken&&")"!=e.prevToken||""!=r?"operator"==e.prevToken&&"}"!=r||"variable"==e.prevToken&&"."==a||("}"==e.prevToken||")"==e.prevToken)&&"."==a?2*n+t.indented:t.align&&"}"==t.type?t.indented+(e.context.type==(r||"").charAt(0)?0:n):void 0:e.indented}},modeProps:{closeBrackets:{triples:'"'}}}),y(["x-shader/x-vertex","x-shader/x-fragment"],{name:"clike",keywords:i("sampler1D sampler2D sampler3D samplerCube sampler1DShadow sampler2DShadow const attribute uniform varying break continue discard return for while do if else struct in out inout"),types:i("float int bool void vec2 vec3 vec4 ivec2 ivec3 ivec4 bvec2 bvec3 bvec4 mat2 mat3 mat4"),blockKeywords:i("for while do if else struct"),builtin:i("radians degrees sin cos tan asin acos atan pow exp log exp2 sqrt inversesqrt abs sign floor ceil fract mod min max clamp mix step smoothstep length distance dot cross normalize ftransform faceforward reflect refract matrixCompMult lessThan lessThanEqual greaterThan greaterThanEqual equal notEqual any all not texture1D texture1DProj texture1DLod texture1DProjLod texture2D texture2DProj texture2DLod texture2DProjLod texture3D texture3DProj texture3DLod texture3DProjLod textureCube textureCubeLod shadow1D shadow2D shadow1DProj shadow2DProj shadow1DLod shadow2DLod shadow1DProjLod shadow2DProjLod dFdx dFdy fwidth noise1 noise2 noise3 noise4"),atoms:i("true false gl_FragColor gl_SecondaryColor gl_Normal gl_Vertex gl_MultiTexCoord0 gl_MultiTexCoord1 gl_MultiTexCoord2 gl_MultiTexCoord3 gl_MultiTexCoord4 gl_MultiTexCoord5 gl_MultiTexCoord6 gl_MultiTexCoord7 gl_FogCoord gl_PointCoord gl_Position gl_PointSize gl_ClipVertex gl_FrontColor gl_BackColor gl_FrontSecondaryColor gl_BackSecondaryColor gl_TexCoord gl_FogFragCoord gl_FragCoord gl_FrontFacing gl_FragData gl_FragDepth gl_ModelViewMatrix gl_ProjectionMatrix gl_ModelViewProjectionMatrix gl_TextureMatrix gl_NormalMatrix gl_ModelViewMatrixInverse gl_ProjectionMatrixInverse gl_ModelViewProjectionMatrixInverse gl_TexureMatrixTranspose gl_ModelViewMatrixInverseTranspose gl_ProjectionMatrixInverseTranspose gl_ModelViewProjectionMatrixInverseTranspose gl_TextureMatrixInverseTranspose gl_NormalScale gl_DepthRange gl_ClipPlane gl_Point gl_FrontMaterial gl_BackMaterial gl_LightSource gl_LightModel gl_FrontLightModelProduct gl_BackLightModelProduct gl_TextureColor gl_EyePlaneS gl_EyePlaneT gl_EyePlaneR gl_EyePlaneQ gl_FogParameters gl_MaxLights gl_MaxClipPlanes gl_MaxTextureUnits gl_MaxTextureCoords gl_MaxVertexAttribs gl_MaxVertexUniformComponents gl_MaxVaryingFloats gl_MaxVertexTextureImageUnits gl_MaxTextureImageUnits gl_MaxFragmentUniformComponents gl_MaxCombineTextureImageUnits gl_MaxDrawBuffers"),indentSwitch:!1,hooks:{"#":u},modeProps:{fold:["brace","include"]}}),y("text/x-nesc",{name:"clike",keywords:i(x+" as atomic async call command component components configuration event generic implementation includes interface module new norace nx_struct nx_union post provides signal task uses abstract extends"),types:s,blockKeywords:i(T),atoms:i("null true false"),hooks:{"#":u},modeProps:{fold:["brace","include"]}}),y("text/x-objectivec",{name:"clike",keywords:i(x+" bycopy byref in inout oneway out self super atomic nonatomic retain copy readwrite readonly strong weak assign typeof nullable nonnull null_resettable _cmd @interface @implementation @end @protocol @encode @property @synthesize @dynamic @class @public @package @private @protected @required @optional @try @catch @finally @import @selector @encode @defs @synchronized @autoreleasepool @compatibility_alias @available"),types:c,builtin:i("FOUNDATION_EXPORT FOUNDATION_EXTERN NS_INLINE NS_FORMAT_FUNCTION NS_RETURNS_RETAINED NS_ERROR_ENUM NS_RETURNS_NOT_RETAINED NS_RETURNS_INNER_POINTER NS_DESIGNATED_INITIALIZER NS_ENUM NS_OPTIONS NS_REQUIRES_NIL_TERMINATION NS_ASSUME_NONNULL_BEGIN NS_ASSUME_NONNULL_END NS_SWIFT_NAME NS_REFINED_FOR_SWIFT"),blockKeywords:i(T+" @synthesize @try @catch @finally @autoreleasepool @synchronized"),defKeywords:i("struct enum union @interface @implementation @protocol @class"),dontIndentStatements:/^@.*$/,typeFirstDefinitions:!0,atoms:i("YES NO NULL Nil nil true false nullptr"),isReservedIdentifier:p,hooks:{"#":u,"*":d},modeProps:{fold:["brace","include"]}}),y("text/x-squirrel",{name:"clike",keywords:i("base break clone continue const default delete enum extends function in class foreach local resume return this throw typeof yield constructor instanceof static"),types:s,blockKeywords:i("case catch class else for foreach if switch try while"),defKeywords:i("function local class"),typeFirstDefinitions:!0,atoms:i("true false null"),hooks:{"#":u},modeProps:{fold:["brace","include"]}});var z=null;y("text/x-ceylon",{name:"clike",keywords:i("abstracts alias assembly assert assign break case catch class continue dynamic else exists extends finally for function given if import in interface is let module new nonempty object of out outer package return satisfies super switch then this throw try value void while"),types:function(e){var t=e.charAt(0);return t===t.toUpperCase()&&t!==t.toLowerCase()},blockKeywords:i("case catch class dynamic else finally for function if interface module new object switch try while"),defKeywords:i("class dynamic function interface module object package value"),builtin:i("abstract actual aliased annotation by default deprecated doc final formal late license native optional sealed see serializable shared suppressWarnings tagged throws variable"),isPunctuationChar:/[\[\]{}\(\),;\:\.`]/,isOperatorChar:/[+\-*&%=<>!?|^~:\/]/,numberStart:/[\d#$]/,number:/^(?:#[\da-fA-F_]+|\$[01_]+|[\d_]+[kMGTPmunpf]?|[\d_]+\.[\d_]+(?:[eE][-+]?\d+|[kMGTPmunpf]|)|)/i,multiLineStrings:!0,typeFirstDefinitions:!0,atoms:i("true false null larger smaller equal empty finished"),indentSwitch:!1,styleDefs:!1,hooks:{"@":function(e){return e.eatWhile(/[\w\$_]/),"meta"},'"':function(e,t){return t.tokenize=w(e.match('""')?"triple":"single"),t.tokenize(e,t)},"`":function(e,t){return!(!z||!e.match("`"))&&(t.tokenize=z,z=null,t.tokenize(e,t))},"'":function(e){return e.eatWhile(/[\w\$_\xa1-\uffff]/),"atom"},token:function(e,t,r){if(("variable"==r||"type"==r)&&"."==t.prevToken)return"variable-2"}},modeProps:{fold:["brace","import"],closeBrackets:{triples:'"'}}})}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../htmlmixed/htmlmixed"),require("../clike/clike")):"function"==typeof define&&define.amd?define("mode/php/php.js",["../../lib/codemirror","../htmlmixed/htmlmixed","../clike/clike"],e):e(CodeMirror)}(function(e){"use strict";function t(e){for(var t={},r=e.split(" "),n=0;n
|
@@ -1 +1 @@
|
|
1
|
-
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/mode/multiplex",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.multiplexingMode=function(n){function t(e,n,t,i){if("string"==typeof n){var r=e.indexOf(n,t);return i&&r>-1?r+n.length:r}var o=n.exec(t?e.slice(t):e);return o?o.index+t+(i?o[0].length:0):-1}var i=Array.prototype.slice.call(arguments,1);return{startState:function(){return{outer:e.startState(n),innerActive:null,inner:null}},copyState:function(t){return{outer:e.copyState(n,t.outer),innerActive:t.innerActive,inner:t.innerActive&&e.copyState(t.innerActive.mode,t.inner)}},token:function(r,o){if(o.innerActive){var a=o.innerActive,c=r.string;if(!a.close&&r.sol())return o.innerActive=o.inner=null,this.token(r,o);var s=a.close?t(c,a.close,r.pos,a.parseDelimiters):-1;if(s==r.pos&&!a.parseDelimiters)return r.match(a.close),o.innerActive=o.inner=null,a.delimStyle&&a.delimStyle+" "+a.delimStyle+"-close";s>-1&&(r.string=c.slice(0,s));var l=a.mode.token(r,o.inner);return s>-1&&(r.string=c),s==r.pos&&a.parseDelimiters&&(o.innerActive=o.inner=null),a.innerStyle&&(l=l?l+" "+a.innerStyle:a.innerStyle),l}for(var d=1/0,c=r.string,u=0;u<i.length;++u){var
|
1
|
+
!function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror")):"function"==typeof define&&define.amd?define("addon/mode/multiplex",["../../lib/codemirror"],e):e(CodeMirror)}(function(e){"use strict";e.multiplexingMode=function(n){function t(e,n,t,i){if("string"==typeof n){var r=e.indexOf(n,t);return i&&r>-1?r+n.length:r}var o=n.exec(t?e.slice(t):e);return o?o.index+t+(i?o[0].length:0):-1}var i=Array.prototype.slice.call(arguments,1);return{startState:function(){return{outer:e.startState(n),innerActive:null,inner:null}},copyState:function(t){return{outer:e.copyState(n,t.outer),innerActive:t.innerActive,inner:t.innerActive&&e.copyState(t.innerActive.mode,t.inner)}},token:function(r,o){if(o.innerActive){var a=o.innerActive,c=r.string;if(!a.close&&r.sol())return o.innerActive=o.inner=null,this.token(r,o);var s=a.close?t(c,a.close,r.pos,a.parseDelimiters):-1;if(s==r.pos&&!a.parseDelimiters)return r.match(a.close),o.innerActive=o.inner=null,a.delimStyle&&a.delimStyle+" "+a.delimStyle+"-close";s>-1&&(r.string=c.slice(0,s));var l=a.mode.token(r,o.inner);return s>-1&&(r.string=c),s==r.pos&&a.parseDelimiters&&(o.innerActive=o.inner=null),a.innerStyle&&(l=l?l+" "+a.innerStyle:a.innerStyle),l}for(var d=1/0,c=r.string,u=0;u<i.length;++u){var f=i[u],s=t(c,f.open,r.pos);if(s==r.pos){f.parseDelimiters||r.match(f.open),o.innerActive=f;var m=0;if(n.indent){var p=n.indent(o.outer,"","");p!==e.Pass&&(m=p)}return o.inner=e.startState(f.mode,m),f.delimStyle&&f.delimStyle+" "+f.delimStyle+"-open"}-1!=s&&s<d&&(d=s)}d!=1/0&&(r.string=c.slice(0,d));var v=n.token(r,o.outer);return d!=1/0&&(r.string=c),v},indent:function(t,i,r){var o=t.innerActive?t.innerActive.mode:n;return o.indent?o.indent(t.innerActive?t.inner:t.outer,i,r):e.Pass},blankLine:function(t){var r=t.innerActive?t.innerActive.mode:n;if(r.blankLine&&r.blankLine(t.innerActive?t.inner:t.outer),t.innerActive)"\n"===t.innerActive.close&&(t.innerActive=t.inner=null);else for(var o=0;o<i.length;++o){var a=i[o];"\n"===a.open&&(t.innerActive=a,t.inner=e.startState(a.mode,r.indent?r.indent(t.outer,"",""):0))}},electricChars:n.electricChars,innerMode:function(e){return e.inner?{state:e.inner,mode:e.innerActive.mode}:{state:e.outer,mode:n}}}}}),function(e){"object"==typeof exports&&"object"==typeof module?e(require("../../lib/codemirror"),require("../../addon/mode/multiplex")):"function"==typeof define&&define.amd?define("mode/twig/twig.js",["../../lib/codemirror","../../addon/mode/multiplex"],e):e(CodeMirror)}(function(e){"use strict";e.defineMode("twig:inner",function(){function e(e,a){var c=e.peek();if(a.incomment)return e.skipTo("#}")?(e.eatWhile(/\#|}/),a.incomment=!1):e.skipToEnd(),"comment";if(a.intag){if(a.operator){if(a.operator=!1,e.match(r))return"atom";if(e.match(o))return"number"}if(a.sign){if(a.sign=!1,e.match(r))return"atom";if(e.match(o))return"number"}if(a.instring)return c==a.instring&&(a.instring=!1),e.next(),"string";if("'"==c||'"'==c)return a.instring=c,e.next(),"string";if(e.match(a.intag+"}")||e.eat("-")&&e.match(a.intag+"}"))return a.intag=!1,"tag";if(e.match(t))return a.operator=!0,"operator";if(e.match(i))a.sign=!0;else if(e.eat(" ")||e.sol()){if(e.match(n))return"keyword";if(e.match(r))return"atom";if(e.match(o))return"number";e.sol()&&e.next()}else e.next();return"variable"}if(e.eat("{")){if(e.eat("#"))return a.incomment=!0,e.skipTo("#}")?(e.eatWhile(/\#|}/),a.incomment=!1):e.skipToEnd(),"comment";if(c=e.eat(/\{|%/))return a.intag=c,"{"==c&&(a.intag="}"),e.eat("-"),"tag"}e.next()}var n=["and","as","autoescape","endautoescape","block","do","endblock","else","elseif","extends","for","endfor","embed","endembed","filter","endfilter","flush","from","if","endif","in","is","include","import","not","or","set","spaceless","endspaceless","with","endwith","trans","endtrans","blocktrans","endblocktrans","macro","endmacro","use","verbatim","endverbatim"],t=/^[+\-*&%=<>!?|~^]/,i=/^[:\[\(\{]/,r=["true","false","null","empty","defined","divisibleby","divisible by","even","odd","iterable","sameas","same as"],o=/^(\d[+\-\*\/])?\d+(\.\d+)?/;return n=new RegExp("(("+n.join(")|(")+"))\\b"),r=new RegExp("(("+r.join(")|(")+"))\\b"),{startState:function(){return{}},token:function(n,t){return e(n,t)}}}),e.defineMode("twig",function(n,t){var i=e.getMode(n,"twig:inner");return t&&t.base?e.multiplexingMode(e.getMode(n,t.base),{open:/\{[{#%]/,close:/[}#%]\}/,mode:i,parseDelimiters:!0}):i}),e.defineMIME("text/x-twig","twig")}),function(e){"function"==typeof e.define&&e.define("modeTwig",["mode/twig/twig.js"],function(){})}(this);
|
@@ -7,10 +7,10 @@
|
|
7
7
|
*/
|
8
8
|
|
9
9
|
(function() {
|
10
|
-
CKEDITOR.plugins.add(
|
11
|
-
icons:
|
12
|
-
lang:
|
13
|
-
version:
|
10
|
+
CKEDITOR.plugins.add("codemirror", {
|
11
|
+
icons: "searchcode,autoformat,commentselectedrange,uncommentselectedrange,autocomplete", // %REMOVE_LINE_CORE%
|
12
|
+
lang: "af,ar,bg,bn,bs,ca,cs,cy,da,de,el,en-au,en-ca,en-gb,en,eo,es,et,eu,fa,fi,fo,fr-ca,fr,gl,gu,he,hi,hr,hu,is,it,ja,ka,km,ko,ku,lt,lv,mk,mn,ms,nb,nl,no,pl,pt-br,pt,ro,ru,sk,sl,sr-latn,sr,sv,th,tr,ug,uk,vi,zh-cn,zh", // %REMOVE_LINE_CORE%
|
13
|
+
version: "1.17.11",
|
14
14
|
init: function (editor) {
|
15
15
|
var rootPath = this.path,
|
16
16
|
defaultConfig = {
|
@@ -27,7 +27,7 @@
|
|
27
27
|
indentWithTabs: false,
|
28
28
|
lineNumbers: true,
|
29
29
|
lineWrapping: true,
|
30
|
-
mode:
|
30
|
+
mode: "htmlmixed",
|
31
31
|
matchBrackets: true,
|
32
32
|
maxHighlightLineLength: 1000,
|
33
33
|
matchTags: true,
|
@@ -38,7 +38,7 @@
|
|
38
38
|
showTrailingSpace: true,
|
39
39
|
showUncommentButton: true,
|
40
40
|
styleActiveLine: true,
|
41
|
-
theme:
|
41
|
+
theme: "default",
|
42
42
|
useBeautifyOnStart: false
|
43
43
|
};
|
44
44
|
|
@@ -58,59 +58,66 @@
|
|
58
58
|
if (editor.plugins.bbcode && config.mode.indexOf("bbcode") <= 0) {
|
59
59
|
config.mode = "bbcode";
|
60
60
|
}
|
61
|
-
var requirePresent = "function" === typeof require;
|
62
|
-
|
61
|
+
var requirePresent = "function" === typeof require && "function" === typeof require.config;
|
62
|
+
var pluginRequire;
|
63
63
|
if (requirePresent){
|
64
|
-
var
|
65
|
-
|
64
|
+
var requireContext = config.requireContext || "_";
|
65
|
+
var location = CKEDITOR.getUrl("plugins/codemirror/js");
|
66
|
+
pluginRequire = require.config({
|
67
|
+
context: requireContext,
|
66
68
|
packages: [{
|
67
|
-
name:
|
69
|
+
name: "codemirror",
|
70
|
+
location: location,
|
71
|
+
main: "codemirror.min.js"
|
72
|
+
}, {
|
73
|
+
name: "codemirror-mode-handlebars",
|
68
74
|
location: location,
|
69
|
-
main:
|
75
|
+
main: "codemirror.mode.handlebars.min.js"
|
70
76
|
}, {
|
71
|
-
name:
|
77
|
+
name: "codemirror-mode-twig",
|
72
78
|
location: location,
|
73
|
-
main:
|
79
|
+
main: "codemirror.mode.twig.min.js"
|
74
80
|
}, {
|
75
|
-
name:
|
81
|
+
name: "codemirror-mode-html",
|
76
82
|
location: location,
|
77
|
-
main:
|
83
|
+
main: "codemirror.mode.htmlmixed.min.js"
|
78
84
|
}, {
|
79
|
-
name:
|
85
|
+
name: "codemirror-mode-php",
|
80
86
|
location: location,
|
81
|
-
main:
|
87
|
+
main: "codemirror.mode.php.min.js"
|
82
88
|
}, {
|
83
|
-
name:
|
89
|
+
name: "codemirror-mode-js",
|
84
90
|
location: location,
|
85
|
-
main:
|
91
|
+
main: "codemirror.mode.js.min.js"
|
86
92
|
}, {
|
87
|
-
name:
|
93
|
+
name: "codemirror-addons",
|
88
94
|
location: location,
|
89
|
-
main:
|
95
|
+
main: "codemirror.addons.min.js"
|
90
96
|
}, {
|
91
|
-
name:
|
97
|
+
name: "codemirror-addon-search",
|
92
98
|
location: location,
|
93
|
-
main:
|
99
|
+
main: "codemirror.addons.search.min.js"
|
94
100
|
}, {
|
95
|
-
name:
|
101
|
+
name: "codemirror-beautify",
|
96
102
|
location: location,
|
97
|
-
main:
|
103
|
+
main: "beautify.min.js"
|
98
104
|
}],
|
99
105
|
bundles: {
|
100
|
-
'codemirror': [
|
101
|
-
'codemirror-mode-
|
102
|
-
'codemirror-mode-
|
103
|
-
'codemirror-mode-
|
104
|
-
'codemirror-mode-
|
105
|
-
'codemirror-
|
106
|
-
'codemirror-
|
107
|
-
'codemirror-
|
106
|
+
'codemirror': ["core", "codemirror.js"],
|
107
|
+
'codemirror-mode-handlebars': ["modeHandlebars"],
|
108
|
+
'codemirror-mode-twig': ["modeTwig"],
|
109
|
+
'codemirror-mode-html': ["modeHtml"],
|
110
|
+
'codemirror-mode-php': ["modePHP"],
|
111
|
+
'codemirror-mode-js': ["modeJS"],
|
112
|
+
'codemirror-addons': ["addons"],
|
113
|
+
'codemirror-addon-search': ["addonSearch"],
|
114
|
+
'codemirror-beautify': ["beautifyModule"]
|
108
115
|
},
|
109
116
|
map: {
|
110
117
|
'*': {
|
111
118
|
//all the requires pointing to ../../lib/codemirror from addons will be redirected to module named codemirror.js
|
112
119
|
//which is located in bundle 'codemirror' whose js file is codemirror.min.js
|
113
|
-
'lib/codemirror':
|
120
|
+
'lib/codemirror': "codemirror.js"
|
114
121
|
}
|
115
122
|
}
|
116
123
|
});
|
@@ -119,7 +126,7 @@
|
|
119
126
|
if (editor.elementMode === CKEDITOR.ELEMENT_MODE_INLINE || editor.plugins.sourcedialog) {
|
120
127
|
|
121
128
|
// Override Source Dialog
|
122
|
-
CKEDITOR.dialog.add(
|
129
|
+
CKEDITOR.dialog.add("sourcedialog", function (editor) {
|
123
130
|
var sizeDialog = CKEDITOR.document.getWindow().getViewPaneSize(),
|
124
131
|
minWidth = Math.min(sizeDialog.width - 70, 800),
|
125
132
|
minHeight = sizeDialog.height / 1.5,
|
@@ -131,7 +138,7 @@
|
|
131
138
|
height = size.height / 1.5;
|
132
139
|
|
133
140
|
window["codemirror_" + editor.id] = CodeMirror.fromTextArea(textarea, {
|
134
|
-
mode: config.mode,
|
141
|
+
mode: config.mode === "handlebars" ? { name: "handlebars", base: "text/html" } : config.mode,
|
135
142
|
matchBrackets: config.matchBrackets,
|
136
143
|
maxHighlightLineLength: config.maxHighlightLineLength,
|
137
144
|
matchTags: config.matchTags,
|
@@ -150,8 +157,9 @@
|
|
150
157
|
showCursorWhenSelecting: true,
|
151
158
|
styleActiveLine: config.styleActiveLine,
|
152
159
|
viewportMargin: Infinity,
|
153
|
-
//extraKeys: {"Ctrl-Space": "autocomplete"},
|
154
160
|
extraKeys: {
|
161
|
+
"Ctrl-Space":
|
162
|
+
"autocomplete",
|
155
163
|
"Ctrl-Q": function (codeMirror_Editor) {
|
156
164
|
if (config.enableCodeFolding) {
|
157
165
|
window["foldFunc_" + editor.id](codeMirror_Editor, codeMirror_Editor.getCursor().line);
|
@@ -163,8 +171,8 @@
|
|
163
171
|
});
|
164
172
|
|
165
173
|
|
166
|
-
var holderHeight = height +
|
167
|
-
var holderWidth = width +
|
174
|
+
var holderHeight = height + "px";
|
175
|
+
var holderWidth = width + "px";
|
168
176
|
|
169
177
|
// Store config so we can access it within commands etc.
|
170
178
|
window["codemirror_" + editor.id].config = config;
|
@@ -172,8 +180,8 @@
|
|
172
180
|
if (config.autoFormatOnStart) {
|
173
181
|
if (config.useBeautifyOnStart) {
|
174
182
|
var indent_size = 4,
|
175
|
-
indent_char =
|
176
|
-
brace_style =
|
183
|
+
indent_char = " ",
|
184
|
+
brace_style = "collapse"; //collapse, expand, end-expand
|
177
185
|
|
178
186
|
var source = window["codemirror_" + editor.id].getValue();
|
179
187
|
|
@@ -198,7 +206,7 @@
|
|
198
206
|
|
199
207
|
window["codemirror_" + editor.id].on("change", function () {
|
200
208
|
window["codemirror_" + editor.id].save();
|
201
|
-
editor.fire(
|
209
|
+
editor.fire("change", this);
|
202
210
|
});
|
203
211
|
|
204
212
|
|
@@ -209,13 +217,13 @@
|
|
209
217
|
window["codemirror_" + editor.id].on("gutterClick", window["foldFunc_" + editor.id]);
|
210
218
|
}
|
211
219
|
// Run config.onLoad callback, if present.
|
212
|
-
if (typeof config.onLoad ===
|
220
|
+
if (typeof config.onLoad === "function") {
|
213
221
|
config.onLoad(window["codemirror_" + editor.id], editor);
|
214
222
|
}
|
215
223
|
|
216
224
|
// inherit blur event
|
217
225
|
window["codemirror_" + editor.id].on("blur", function () {
|
218
|
-
editor.fire(
|
226
|
+
editor.fire("blur", this);
|
219
227
|
});
|
220
228
|
|
221
229
|
window["codemirror_" + editor.id].on("keypress", function (codeMirror_Editor, evt) {
|
@@ -242,7 +250,7 @@
|
|
242
250
|
|
243
251
|
start = OffSetToLineChannel(window["codemirror_" + editor.id], textRange.startOffset);
|
244
252
|
|
245
|
-
if (typeof (textRange.endOffset) ==
|
253
|
+
if (typeof (textRange.endOffset) == "undefined") {
|
246
254
|
window["codemirror_" + editor.id].focus();
|
247
255
|
window["codemirror_" + editor.id].setCursor(start);
|
248
256
|
} else {
|
@@ -260,14 +268,14 @@
|
|
260
268
|
minHeight: minHeight,
|
261
269
|
resizable: CKEDITOR.DIALOG_RESIZE_BOTH,
|
262
270
|
onLoad: function() {
|
263
|
-
this.on(
|
271
|
+
this.on("resize",
|
264
272
|
function (event) {
|
265
273
|
var parts = event.sender.parts;
|
266
274
|
var title = parts.title;
|
267
275
|
var footer = parts.footer;
|
268
276
|
|
269
|
-
var holderHeight = (event.data.height - title.$.offsetHeight - footer.$.offsetHeight) +
|
270
|
-
var holderWidth = event.data.width +
|
277
|
+
var holderHeight = (event.data.height - title.$.offsetHeight - footer.$.offsetHeight) + "px";
|
278
|
+
var holderWidth = event.data.width + "px";
|
271
279
|
|
272
280
|
window["codemirror_" + editor.id].setSize(holderWidth, holderHeight);
|
273
281
|
},
|
@@ -275,33 +283,33 @@
|
|
275
283
|
},
|
276
284
|
onShow: function (event) {
|
277
285
|
// Set Elements
|
278
|
-
this.getContentElement(
|
279
|
-
this.getContentElement(
|
286
|
+
this.getContentElement("main", "data").focus();
|
287
|
+
this.getContentElement("main", "AutoComplete").setValue(config.autoCloseTags, true);
|
280
288
|
|
281
|
-
var textArea = this.getContentElement(
|
289
|
+
var textArea = this.getContentElement("main", "data").getInputElement().$;
|
282
290
|
|
283
291
|
// Load the content
|
284
|
-
this.setValueOf(
|
292
|
+
this.setValueOf("main", "data", oldData = editor.getData());
|
285
293
|
|
286
294
|
if (config.autoLoadCodeMirror) {
|
287
295
|
|
288
|
-
if (!IsStyleSheetAlreadyLoaded(rootPath +
|
289
|
-
CKEDITOR.document.appendStyleSheet(rootPath +
|
296
|
+
if (!IsStyleSheetAlreadyLoaded(rootPath + "css/codemirror.min.css")) {
|
297
|
+
CKEDITOR.document.appendStyleSheet(rootPath + "css/codemirror.min.css");
|
290
298
|
}
|
291
299
|
|
292
300
|
if (config.theme.length &&
|
293
|
-
config.theme !=
|
294
|
-
!IsStyleSheetAlreadyLoaded(rootPath +
|
295
|
-
CKEDITOR.document.appendStyleSheet(rootPath +
|
301
|
+
config.theme != "default" &&
|
302
|
+
!IsStyleSheetAlreadyLoaded(rootPath + "theme/" + config.theme + ".css")) {
|
303
|
+
CKEDITOR.document.appendStyleSheet(rootPath + "theme/" + config.theme + ".css");
|
296
304
|
}
|
297
305
|
if(requirePresent) {
|
298
|
-
|
306
|
+
pluginRequire(getCodeMirrorDependencies(),function (codemirror, addons){
|
299
307
|
loadCodeMirrorInline(editor, textArea, event.sender);
|
300
308
|
});
|
301
309
|
} else {
|
302
|
-
if (typeof (CodeMirror) ==
|
310
|
+
if (typeof (CodeMirror) == "undefined") {
|
303
311
|
|
304
|
-
CKEDITOR.scriptLoader.load(rootPath +
|
312
|
+
CKEDITOR.scriptLoader.load(rootPath + "js/codemirror.min.js",
|
305
313
|
function() {
|
306
314
|
|
307
315
|
CKEDITOR.scriptLoader.load(getCodeMirrorScripts(),
|
@@ -312,7 +320,7 @@
|
|
312
320
|
|
313
321
|
|
314
322
|
} else {
|
315
|
-
if (CodeMirror.prototype[
|
323
|
+
if (CodeMirror.prototype["autoFormatAll"]) {
|
316
324
|
loadCodeMirrorInline(editor, textArea, event.sender);
|
317
325
|
} else {
|
318
326
|
// loading the add-on scripts.
|
@@ -332,8 +340,8 @@
|
|
332
340
|
// Free Memory
|
333
341
|
window["codemirror_" + editor.id] = null;
|
334
342
|
|
335
|
-
editor.fire(
|
336
|
-
editor.fire(
|
343
|
+
editor.fire("blur", this);
|
344
|
+
editor.fire("focus", this);
|
337
345
|
}
|
338
346
|
},
|
339
347
|
onOk: (function () {
|
@@ -358,21 +366,21 @@
|
|
358
366
|
window["codemirror_" + editor.id] = null;
|
359
367
|
|
360
368
|
// Remove CR from input data for reliable comparison with editor data.
|
361
|
-
var newData = this.getValueOf(
|
369
|
+
var newData = this.getValueOf("main", "data").replace(/\r/g, "");
|
362
370
|
|
363
371
|
// Avoid unnecessary setData. Also preserve selection
|
364
372
|
// when user changed his mind and goes back to wysiwyg editing.
|
365
373
|
if (newData === oldData) {
|
366
|
-
editor.fire(
|
367
|
-
editor.fire(
|
374
|
+
editor.fire("blur", this);
|
375
|
+
editor.fire("focus", this);
|
368
376
|
return true;
|
369
377
|
}
|
370
378
|
|
371
379
|
// Set data asynchronously to avoid errors in IE.
|
372
380
|
CKEDITOR.env.ie ? CKEDITOR.tools.setTimeout(setData, 0, this, newData) : setData.call(this, newData);
|
373
381
|
|
374
|
-
editor.fire(
|
375
|
-
editor.fire(
|
382
|
+
editor.fire("blur", this);
|
383
|
+
editor.fire("focus", this);
|
376
384
|
|
377
385
|
// Don't let the dialog close before setData is over.
|
378
386
|
return false;
|
@@ -380,29 +388,29 @@
|
|
380
388
|
})(),
|
381
389
|
|
382
390
|
contents: [{
|
383
|
-
id:
|
391
|
+
id: "main",
|
384
392
|
label: editor.lang.sourcedialog.title,
|
385
393
|
elements: [
|
386
394
|
{
|
387
|
-
type:
|
388
|
-
style:
|
389
|
-
widths: [
|
395
|
+
type: "hbox",
|
396
|
+
style: "width: 80px;margin:0;",
|
397
|
+
widths: ["20px", "20px", "20px", "20px"],
|
390
398
|
children: [
|
391
399
|
{
|
392
|
-
type:
|
393
|
-
id:
|
394
|
-
label:
|
400
|
+
type: "button",
|
401
|
+
id: "searchCode",
|
402
|
+
label: "",
|
395
403
|
title: lang.searchCode,
|
396
|
-
'class':
|
404
|
+
'class': "searchCodeButton",
|
397
405
|
onClick: function() {
|
398
406
|
CodeMirror.commands.find(window["codemirror_" + editor.id]);
|
399
407
|
}
|
400
408
|
}, {
|
401
|
-
type:
|
402
|
-
id:
|
403
|
-
label:
|
409
|
+
type: "button",
|
410
|
+
id: "autoFormat",
|
411
|
+
label: "",
|
404
412
|
title: lang.autoFormat,
|
405
|
-
'class':
|
413
|
+
'class': "autoFormat",
|
406
414
|
onClick: function() {
|
407
415
|
var range = {
|
408
416
|
from: window["codemirror_" + editor.id].getCursor(true),
|
@@ -411,11 +419,11 @@
|
|
411
419
|
window["codemirror_" + editor.id].autoFormatRange(range.from, range.to);
|
412
420
|
}
|
413
421
|
}, {
|
414
|
-
type:
|
415
|
-
id:
|
416
|
-
label:
|
422
|
+
type: "button",
|
423
|
+
id: "CommentSelectedRange",
|
424
|
+
label: "",
|
417
425
|
title: lang.commentSelectedRange,
|
418
|
-
'class':
|
426
|
+
'class': "CommentSelectedRange",
|
419
427
|
onClick: function () {
|
420
428
|
var range = {
|
421
429
|
from: window["codemirror_" + editor.id].getCursor(true),
|
@@ -424,11 +432,11 @@
|
|
424
432
|
window["codemirror_" + editor.id].commentRange(true, range.from, range.to);
|
425
433
|
}
|
426
434
|
}, {
|
427
|
-
type:
|
428
|
-
id:
|
429
|
-
label:
|
435
|
+
type: "button",
|
436
|
+
id: "UncommentSelectedRange",
|
437
|
+
label: "",
|
430
438
|
title: lang.uncommentSelectedRange,
|
431
|
-
'class':
|
439
|
+
'class': "UncommentSelectedRange",
|
432
440
|
onClick: function () {
|
433
441
|
var range = {
|
434
442
|
from: window["codemirror_" + editor.id].getCursor(true),
|
@@ -441,23 +449,23 @@
|
|
441
449
|
}
|
442
450
|
}]
|
443
451
|
}, {
|
444
|
-
type:
|
445
|
-
id:
|
452
|
+
type: "checkbox",
|
453
|
+
id: "AutoComplete",
|
446
454
|
label: lang.autoCompleteToggle,
|
447
455
|
title: lang.autoCompleteToggle,
|
448
456
|
onChange: function () {
|
449
457
|
window["codemirror_" + editor.id].setOption("autoCloseTags", this.getValue());
|
450
458
|
}
|
451
459
|
}, {
|
452
|
-
type:
|
453
|
-
id:
|
454
|
-
dir:
|
455
|
-
inputStyle:
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
'class':
|
460
|
+
type: "textarea",
|
461
|
+
id: "data",
|
462
|
+
dir: "ltr",
|
463
|
+
inputStyle: "cursor:auto;" +
|
464
|
+
"width:" + minWidth + "px;" +
|
465
|
+
"height:" + minHeight + "px;" +
|
466
|
+
"tab-size:4;" +
|
467
|
+
"text-align:left;",
|
468
|
+
'class': "cke_source cke_enable_context_menu"
|
461
469
|
}
|
462
470
|
]
|
463
471
|
}]
|
@@ -506,8 +514,8 @@
|
|
506
514
|
};
|
507
515
|
|
508
516
|
editor.commands.find.exec = function() {
|
509
|
-
if (editor.mode ===
|
510
|
-
editor.openDialog(
|
517
|
+
if (editor.mode === "wysiwyg") {
|
518
|
+
editor.openDialog("find");
|
511
519
|
} else {
|
512
520
|
CodeMirror.commands.find(window["codemirror_" + editor.id]);
|
513
521
|
}
|
@@ -522,8 +530,10 @@
|
|
522
530
|
};
|
523
531
|
|
524
532
|
editor.commands.replace.exec = function () {
|
525
|
-
if (editor.mode ===
|
526
|
-
editor.openDialog(
|
533
|
+
if (editor.mode === "wysiwyg") {
|
534
|
+
editor.openDialog("find", function () {
|
535
|
+
this.selectPage("replace");
|
536
|
+
});
|
527
537
|
} else {
|
528
538
|
CodeMirror.commands.replace(window["codemirror_" + editor.id]);
|
529
539
|
}
|
@@ -544,11 +554,11 @@
|
|
544
554
|
editorFocus: false,
|
545
555
|
readOnly: 1,
|
546
556
|
exec: function(editorInstance) {
|
547
|
-
if (editorInstance.mode ===
|
548
|
-
editorInstance.fire(
|
557
|
+
if (editorInstance.mode === "wysiwyg") {
|
558
|
+
editorInstance.fire("saveSnapshot");
|
549
559
|
}
|
550
|
-
editorInstance.getCommand(
|
551
|
-
editorInstance.setMode(editorInstance.mode ===
|
560
|
+
editorInstance.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED);
|
561
|
+
editorInstance.setMode(editorInstance.mode === "source" ? "wysiwyg" : "source");
|
552
562
|
},
|
553
563
|
canUndo: false
|
554
564
|
},
|
@@ -638,30 +648,30 @@
|
|
638
648
|
};
|
639
649
|
}
|
640
650
|
|
641
|
-
editor.addMode(
|
651
|
+
editor.addMode("source", function (callback) {
|
642
652
|
if (!config.autoLoadCodeMirror) {
|
643
653
|
return;
|
644
654
|
}
|
645
655
|
|
646
|
-
if (!IsStyleSheetAlreadyLoaded(rootPath +
|
647
|
-
CKEDITOR.document.appendStyleSheet(rootPath +
|
656
|
+
if (!IsStyleSheetAlreadyLoaded(rootPath + "css/codemirror.min.css")) {
|
657
|
+
CKEDITOR.document.appendStyleSheet(rootPath + "css/codemirror.min.css");
|
648
658
|
}
|
649
659
|
|
650
660
|
if (config.theme.length &&
|
651
|
-
config.theme !=
|
652
|
-
!IsStyleSheetAlreadyLoaded(rootPath +
|
653
|
-
CKEDITOR.document.appendStyleSheet(rootPath +
|
661
|
+
config.theme != "default" &&
|
662
|
+
!IsStyleSheetAlreadyLoaded(rootPath + "theme/" + config.theme + ".css")) {
|
663
|
+
CKEDITOR.document.appendStyleSheet(rootPath + "theme/" + config.theme + ".css");
|
654
664
|
}
|
655
665
|
|
656
666
|
if (requirePresent) {
|
657
|
-
|
667
|
+
pluginRequire(getCodeMirrorDependencies(), function () {
|
658
668
|
loadCodeMirror(editor);
|
659
669
|
callback();
|
660
670
|
});
|
661
671
|
} else {
|
662
|
-
if (typeof (CodeMirror) ==
|
672
|
+
if (typeof (CodeMirror) == "undefined") {
|
663
673
|
|
664
|
-
CKEDITOR.scriptLoader.load(rootPath +
|
674
|
+
CKEDITOR.scriptLoader.load(rootPath + "js/codemirror.min.js",
|
665
675
|
function() {
|
666
676
|
|
667
677
|
CKEDITOR.scriptLoader.load(getCodeMirrorScripts(),
|
@@ -671,7 +681,7 @@
|
|
671
681
|
});
|
672
682
|
});
|
673
683
|
} else {
|
674
|
-
if (CodeMirror.prototype[
|
684
|
+
if (CodeMirror.prototype["autoFormatAll"]) {
|
675
685
|
loadCodeMirror(editor);
|
676
686
|
callback();
|
677
687
|
} else {
|
@@ -687,127 +697,134 @@
|
|
687
697
|
|
688
698
|
});
|
689
699
|
function getCodeMirrorDependencies() {
|
690
|
-
var dependencies = [
|
700
|
+
var dependencies = ["core", "addons"];
|
691
701
|
switch (config.mode) {
|
692
702
|
case "bbcode":
|
693
703
|
case "bbcodemixed":
|
694
|
-
dependencies.push(
|
704
|
+
dependencies.push("modeHtml");
|
695
705
|
break;
|
696
706
|
case "application/x-httpd-php":
|
697
|
-
dependencies.push(
|
707
|
+
dependencies.push("modePHP");
|
698
708
|
break;
|
699
709
|
case "text/javascript":
|
700
|
-
dependencies.push(
|
710
|
+
dependencies.push("modeJs");
|
711
|
+
break;
|
712
|
+
case "handlebars":
|
713
|
+
dependencies.push("modeHandlebars");
|
701
714
|
break;
|
702
715
|
case "twig":
|
703
|
-
dependencies.push(
|
716
|
+
dependencies.push("modeTwig");
|
704
717
|
break;
|
705
718
|
case "htmlmixed":
|
706
719
|
case "text/html":
|
707
720
|
default:
|
708
|
-
dependencies.push(
|
721
|
+
dependencies.push("modeHtml");
|
709
722
|
}
|
710
723
|
|
711
724
|
if (config.useBeautifyOnStart) {
|
712
|
-
dependencies.push(
|
725
|
+
dependencies.push("beautifyModule");
|
713
726
|
}
|
714
727
|
|
715
728
|
if (config.enableSearchTools) {
|
716
|
-
dependencies.push(
|
729
|
+
dependencies.push("addonSearch");
|
717
730
|
}
|
718
731
|
return dependencies;
|
719
732
|
}
|
720
733
|
|
721
734
|
function getCodeMirrorScripts() {
|
722
|
-
var scriptFiles = [rootPath +
|
735
|
+
var scriptFiles = [rootPath + "js/codemirror.addons.min.js"];
|
723
736
|
|
724
737
|
switch (config.mode) {
|
738
|
+
case 'handlebars':
|
739
|
+
{
|
740
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.handlebars.min.js");
|
741
|
+
}
|
725
742
|
case "bbcode":
|
726
743
|
{
|
727
|
-
scriptFiles.push(rootPath +
|
744
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.bbcode.min.js");
|
728
745
|
}
|
729
746
|
|
730
747
|
break;
|
731
748
|
case "bbcodemixed":
|
732
749
|
{
|
733
|
-
scriptFiles.push(rootPath +
|
750
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.bbcodemixed.min.js");
|
734
751
|
}
|
735
752
|
|
736
753
|
break;
|
737
754
|
case "htmlmixed":
|
738
755
|
{
|
739
|
-
scriptFiles.push(rootPath +
|
756
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.htmlmixed.min.js");
|
740
757
|
}
|
741
758
|
|
742
759
|
break;
|
743
760
|
case "text/html":
|
744
761
|
{
|
745
|
-
scriptFiles.push(rootPath +
|
762
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.htmlmixed.min.js");
|
746
763
|
}
|
747
764
|
|
748
765
|
break;
|
749
766
|
case "application/x-httpd-php":
|
750
767
|
{
|
751
|
-
scriptFiles.push(rootPath +
|
768
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.php.min.js");
|
752
769
|
}
|
753
770
|
|
754
771
|
break;
|
755
772
|
case "text/javascript":
|
756
773
|
{
|
757
|
-
scriptFiles.push(rootPath +
|
774
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.javascript.min.js");
|
758
775
|
}
|
759
776
|
|
760
777
|
break;
|
761
778
|
case "twig":
|
762
779
|
{
|
763
|
-
scriptFiles.push(rootPath +
|
780
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.twig.min.js");
|
764
781
|
}
|
765
782
|
|
766
783
|
break;
|
767
784
|
default:
|
768
|
-
scriptFiles.push(rootPath +
|
785
|
+
scriptFiles.push(rootPath + "js/codemirror.mode.htmlmixed.min.js");
|
769
786
|
}
|
770
787
|
|
771
788
|
if (config.useBeautifyOnStart) {
|
772
|
-
scriptFiles.push(rootPath +
|
789
|
+
scriptFiles.push(rootPath + "js/beautify.min.js");
|
773
790
|
}
|
774
791
|
|
775
792
|
if (config.enableSearchTools) {
|
776
|
-
scriptFiles.push(rootPath +
|
793
|
+
scriptFiles.push(rootPath + "js/codemirror.addons.search.min.js");
|
777
794
|
}
|
778
795
|
return scriptFiles;
|
779
796
|
}
|
780
797
|
|
781
798
|
function loadCodeMirror(editor) {
|
782
|
-
var contentsSpace = editor.ui.space(
|
783
|
-
textarea = contentsSpace.getDocument().createElement(
|
799
|
+
var contentsSpace = editor.ui.space("contents"),
|
800
|
+
textarea = contentsSpace.getDocument().createElement("textarea");
|
784
801
|
|
785
802
|
textarea.setStyles(
|
786
803
|
CKEDITOR.tools.extend({
|
787
804
|
// IE7 has overflow the <textarea> from wrapping table cell.
|
788
|
-
width: CKEDITOR.env.ie7Compat ?
|
789
|
-
height:
|
790
|
-
resize:
|
791
|
-
outline:
|
792
|
-
'text-align':
|
805
|
+
width: CKEDITOR.env.ie7Compat ? "99%" : "100%",
|
806
|
+
height: "100%",
|
807
|
+
resize: "none",
|
808
|
+
outline: "none",
|
809
|
+
'text-align': "left"
|
793
810
|
},
|
794
|
-
CKEDITOR.tools.cssVendorPrefix(
|
795
|
-
var ariaLabel = [editor.lang.editor, editor.name].join(
|
811
|
+
CKEDITOR.tools.cssVendorPrefix("tab-size", editor.config.sourceAreaTabSize || 4)));
|
812
|
+
var ariaLabel = [editor.lang.editor, editor.name].join(",");
|
796
813
|
textarea.setAttributes({
|
797
|
-
dir:
|
814
|
+
dir: "ltr",
|
798
815
|
tabIndex: CKEDITOR.env.webkit ? -1 : editor.tabIndex,
|
799
|
-
'role':
|
816
|
+
'role': "textbox",
|
800
817
|
'aria-label': ariaLabel
|
801
818
|
});
|
802
|
-
textarea.addClass(
|
803
|
-
textarea.addClass(
|
804
|
-
textarea.addClass(
|
805
|
-
editor.ui.space(
|
819
|
+
textarea.addClass("cke_source");
|
820
|
+
textarea.addClass("cke_reset");
|
821
|
+
textarea.addClass("cke_enable_context_menu");
|
822
|
+
editor.ui.space("contents").append(textarea);
|
806
823
|
window["editable_" + editor.id] = editor.editable(new sourceEditable(editor, textarea));
|
807
824
|
// Fill the textarea with the current editor data.
|
808
825
|
window["editable_" + editor.id].setData(editor.getData(1));
|
809
826
|
window["editable_" + editor.id].editorID = editor.id;
|
810
|
-
editor.fire(
|
827
|
+
editor.fire("ariaWidget", this);
|
811
828
|
|
812
829
|
var sourceAreaElement = window["editable_" + editor.id],
|
813
830
|
holderElement = sourceAreaElement.getParent();
|
@@ -857,6 +874,7 @@
|
|
857
874
|
}
|
858
875
|
|
859
876
|
var extraKeys = {
|
877
|
+
"Ctrl-Space": "autocomplete",
|
860
878
|
"Ctrl-Q": function(codeMirror_Editor) {
|
861
879
|
if (config.enableCodeFolding) {
|
862
880
|
window["foldFunc_" + editor.id](codeMirror_Editor, codeMirror_Editor.getCursor().line);
|
@@ -867,7 +885,7 @@
|
|
867
885
|
addCKEditorKeystrokes(extraKeys);
|
868
886
|
|
869
887
|
window["codemirror_" + editor.id] = CodeMirror.fromTextArea(sourceAreaElement.$, {
|
870
|
-
mode: config.mode,
|
888
|
+
mode: config.mode === "handlebars" ? { name: "handlebars", base: "text/html" } : config.mode,
|
871
889
|
matchBrackets: config.matchBrackets,
|
872
890
|
maxHighlightLineLength: config.maxHighlightLineLength,
|
873
891
|
matchTags: config.matchTags,
|
@@ -891,16 +909,16 @@
|
|
891
909
|
gutters: ["CodeMirror-linenumbers", "CodeMirror-foldgutter"]
|
892
910
|
});
|
893
911
|
|
894
|
-
var holderHeight = holderElement.$.clientHeight == 0 ? editor.ui.space(
|
895
|
-
var holderWidth = holderElement.$.clientWidth +
|
912
|
+
var holderHeight = holderElement.$.clientHeight == 0 ? editor.ui.space("contents").getStyle("height") : holderElement.$.clientHeight + "px";
|
913
|
+
var holderWidth = holderElement.$.clientWidth + "px";
|
896
914
|
|
897
915
|
// Store config so we can access it within commands etc.
|
898
916
|
window["codemirror_" + editor.id].config = config;
|
899
917
|
if (config.autoFormatOnStart) {
|
900
918
|
if (config.useBeautifyOnStart) {
|
901
919
|
var indent_size = 4;
|
902
|
-
var indent_char =
|
903
|
-
var brace_style =
|
920
|
+
var indent_char = " ";
|
921
|
+
var brace_style = "collapse"; //collapse, expand, end-expand
|
904
922
|
|
905
923
|
var source = window["codemirror_" + editor.id].getValue();
|
906
924
|
|
@@ -925,7 +943,7 @@
|
|
925
943
|
|
926
944
|
window["codemirror_" + editor.id].on("change", function () {
|
927
945
|
window["codemirror_" + editor.id].save();
|
928
|
-
editor.fire(
|
946
|
+
editor.fire("change", this);
|
929
947
|
});
|
930
948
|
|
931
949
|
window["codemirror_" + editor.id].setSize(null, holderHeight);
|
@@ -936,13 +954,13 @@
|
|
936
954
|
}
|
937
955
|
|
938
956
|
// Run config.onLoad callback, if present.
|
939
|
-
if (typeof config.onLoad ===
|
957
|
+
if (typeof config.onLoad === "function") {
|
940
958
|
config.onLoad(window["codemirror_" + editor.id], editor);
|
941
959
|
}
|
942
960
|
|
943
961
|
// inherit blur event
|
944
962
|
window["codemirror_" + editor.id].on("blur", function () {
|
945
|
-
editor.fire(
|
963
|
+
editor.fire("blur", this);
|
946
964
|
});
|
947
965
|
|
948
966
|
window["codemirror_" + editor.id].on("keypress", function (codeMirror_Editor, evt) {
|
@@ -964,65 +982,65 @@
|
|
964
982
|
});
|
965
983
|
}
|
966
984
|
|
967
|
-
editor.addCommand(
|
985
|
+
editor.addCommand("source", sourcearea.commands.source);
|
968
986
|
if (editor.ui.addButton) {
|
969
|
-
editor.ui.addButton(
|
987
|
+
editor.ui.addButton("Source", {
|
970
988
|
label: editor.lang.codemirror.toolbar,
|
971
|
-
command:
|
972
|
-
toolbar:
|
989
|
+
command: "source",
|
990
|
+
toolbar: "mode,10"
|
973
991
|
});
|
974
992
|
}
|
975
993
|
if (config.enableCodeFormatting) {
|
976
|
-
editor.addCommand(
|
977
|
-
editor.addCommand(
|
978
|
-
editor.addCommand(
|
979
|
-
editor.addCommand(
|
980
|
-
editor.addCommand(
|
994
|
+
editor.addCommand("searchCode", sourcearea.commands.searchCode);
|
995
|
+
editor.addCommand("autoFormat", sourcearea.commands.autoFormat);
|
996
|
+
editor.addCommand("commentSelectedRange", sourcearea.commands.commentSelectedRange);
|
997
|
+
editor.addCommand("uncommentSelectedRange", sourcearea.commands.uncommentSelectedRange);
|
998
|
+
editor.addCommand("autoCompleteToggle", sourcearea.commands.autoCompleteToggle);
|
981
999
|
|
982
1000
|
if (editor.ui.addButton) {
|
983
1001
|
if (config.showFormatButton || config.showCommentButton || config.showUncommentButton || config.showSearchButton) {
|
984
|
-
editor.ui.add(
|
1002
|
+
editor.ui.add("-", CKEDITOR.UI_SEPARATOR, { toolbar: "mode,30" });
|
985
1003
|
}
|
986
1004
|
if (config.showSearchButton && config.enableSearchTools) {
|
987
|
-
editor.ui.addButton(
|
1005
|
+
editor.ui.addButton("searchCode", {
|
988
1006
|
label: lang.searchCode,
|
989
|
-
command:
|
990
|
-
toolbar:
|
1007
|
+
command: "searchCode",
|
1008
|
+
toolbar: "mode,40"
|
991
1009
|
});
|
992
1010
|
}
|
993
1011
|
if (config.showFormatButton) {
|
994
|
-
editor.ui.addButton(
|
1012
|
+
editor.ui.addButton("autoFormat", {
|
995
1013
|
label: lang.autoFormat,
|
996
|
-
command:
|
997
|
-
toolbar:
|
1014
|
+
command: "autoFormat",
|
1015
|
+
toolbar: "mode,50"
|
998
1016
|
});
|
999
1017
|
}
|
1000
1018
|
if (config.showCommentButton) {
|
1001
|
-
editor.ui.addButton(
|
1019
|
+
editor.ui.addButton("CommentSelectedRange", {
|
1002
1020
|
label: lang.commentSelectedRange,
|
1003
|
-
command:
|
1004
|
-
toolbar:
|
1021
|
+
command: "commentSelectedRange",
|
1022
|
+
toolbar: "mode,60"
|
1005
1023
|
});
|
1006
1024
|
}
|
1007
1025
|
if (config.showUncommentButton) {
|
1008
|
-
editor.ui.addButton(
|
1026
|
+
editor.ui.addButton("UncommentSelectedRange", {
|
1009
1027
|
label: lang.uncommentSelectedRange,
|
1010
|
-
command:
|
1011
|
-
toolbar:
|
1028
|
+
command: "uncommentSelectedRange",
|
1029
|
+
toolbar: "mode,70"
|
1012
1030
|
});
|
1013
1031
|
}
|
1014
1032
|
if (config.showAutoCompleteButton) {
|
1015
|
-
editor.ui.addButton(
|
1033
|
+
editor.ui.addButton("AutoComplete", {
|
1016
1034
|
label: lang.autoCompleteToggle,
|
1017
|
-
command:
|
1018
|
-
toolbar:
|
1035
|
+
command: "autoCompleteToggle",
|
1036
|
+
toolbar: "mode,80"
|
1019
1037
|
});
|
1020
1038
|
}
|
1021
1039
|
}
|
1022
1040
|
}
|
1023
1041
|
|
1024
|
-
editor.on(
|
1025
|
-
if (editor.mode ===
|
1042
|
+
editor.on("beforeModeUnload", function (evt) {
|
1043
|
+
if (editor.mode === "source" && editor.plugins.textselection && !editor.config.fullPage) {
|
1026
1044
|
|
1027
1045
|
var range = editor.getTextSelection();
|
1028
1046
|
|
@@ -1041,11 +1059,11 @@
|
|
1041
1059
|
evt.data = range.content;
|
1042
1060
|
}
|
1043
1061
|
});
|
1044
|
-
editor.on(
|
1045
|
-
editor.getCommand(
|
1062
|
+
editor.on("mode", function () {
|
1063
|
+
editor.getCommand("source").setState(editor.mode === "source" ? CKEDITOR.TRISTATE_ON : CKEDITOR.TRISTATE_OFF);
|
1046
1064
|
|
1047
|
-
if (editor.mode ===
|
1048
|
-
editor.getCommand(
|
1065
|
+
if (editor.mode === "source") {
|
1066
|
+
editor.getCommand("autoCompleteToggle").setState(window["codemirror_" + editor.id].config.autoCloseTags ? CKEDITOR.TRISTATE_ON : CKEDITOR.TRISTATE_OFF);
|
1049
1067
|
|
1050
1068
|
if (editor.plugins.textselection && textRange && !editor.config.fullPage) {
|
1051
1069
|
|
@@ -1056,7 +1074,7 @@
|
|
1056
1074
|
|
1057
1075
|
start = OffSetToLineChannel(window["codemirror_" + editor.id], textRange.startOffset);
|
1058
1076
|
|
1059
|
-
if (typeof (textRange.endOffset) ==
|
1077
|
+
if (typeof (textRange.endOffset) == "undefined") {
|
1060
1078
|
window["codemirror_" + editor.id].focus();
|
1061
1079
|
window["codemirror_" + editor.id].setCursor(start);
|
1062
1080
|
} else {
|
@@ -1068,22 +1086,22 @@
|
|
1068
1086
|
}
|
1069
1087
|
|
1070
1088
|
});
|
1071
|
-
editor.on(
|
1072
|
-
if (window["editable_" + editor.id] && editor.mode ===
|
1089
|
+
editor.on("resize", function() {
|
1090
|
+
if (window["editable_" + editor.id] && editor.mode === "source") {
|
1073
1091
|
var holderElement = window["editable_" + editor.id].getParent();
|
1074
|
-
var holderHeight = holderElement.$.clientHeight +
|
1075
|
-
var holderWidth = holderElement.$.clientWidth +
|
1092
|
+
var holderHeight = holderElement.$.clientHeight + "px";
|
1093
|
+
var holderWidth = holderElement.$.clientWidth + "px";
|
1076
1094
|
window["codemirror_" + editor.id].setSize(holderWidth, holderHeight);
|
1077
1095
|
}
|
1078
1096
|
});
|
1079
1097
|
|
1080
|
-
editor.on(
|
1081
|
-
if (window["editable_" + editor.id] && editor.mode ===
|
1098
|
+
editor.on("readOnly", function () {
|
1099
|
+
if (window["editable_" + editor.id] && editor.mode === "source") {
|
1082
1100
|
window["codemirror_" + editor.id].setOption("readOnly", this.readOnly);
|
1083
1101
|
}
|
1084
1102
|
});
|
1085
1103
|
|
1086
|
-
editor.on(
|
1104
|
+
editor.on("instanceReady", function (evt) {
|
1087
1105
|
|
1088
1106
|
//editor.container.getPrivate().events.contextmenu.listeners.splice(0, 1);
|
1089
1107
|
|
@@ -1092,7 +1110,7 @@
|
|
1092
1110
|
// Replace Complete SelectAll command from the plugin, otherwise it will not work in IE10
|
1093
1111
|
if (selectAllCommand != null) {
|
1094
1112
|
selectAllCommand.exec = function () {
|
1095
|
-
if (editor.mode ===
|
1113
|
+
if (editor.mode === "source") {
|
1096
1114
|
window["codemirror_" + editor.id].setSelection({
|
1097
1115
|
line: 0,
|
1098
1116
|
ch: 0
|
@@ -1102,8 +1120,8 @@
|
|
1102
1120
|
});
|
1103
1121
|
} else {
|
1104
1122
|
var editable = editor.editable();
|
1105
|
-
if (editable.is(
|
1106
|
-
editor.document.$.execCommand(
|
1123
|
+
if (editable.is("body"))
|
1124
|
+
editor.document.$.execCommand("SelectAll", false, null);
|
1107
1125
|
else {
|
1108
1126
|
var range = editor.createRange();
|
1109
1127
|
range.selectNodeContents(editable);
|
@@ -1118,15 +1136,15 @@
|
|
1118
1136
|
}
|
1119
1137
|
});
|
1120
1138
|
|
1121
|
-
if (typeof (jQuery) !=
|
1122
|
-
jQuery('a[data-toggle="tab"]').on(
|
1139
|
+
if (typeof (jQuery) != "undefined" && jQuery('a[data-toggle="tab"]') && window["codemirror_" + editor.id]) {
|
1140
|
+
jQuery('a[data-toggle="tab"]').on("shown.bs.tab", function() {
|
1123
1141
|
window["codemirror_" + editor.id].refresh();
|
1124
1142
|
});
|
1125
1143
|
}
|
1126
1144
|
|
1127
|
-
editor.on(
|
1145
|
+
editor.on("setData", function(data) {
|
1128
1146
|
|
1129
|
-
if (window["editable_" + data.editor.id] && data.editor.mode ===
|
1147
|
+
if (window["editable_" + data.editor.id] && data.editor.mode === "source") {
|
1130
1148
|
window["codemirror_" + data.editor.id].setValue(data.data.dataValue);
|
1131
1149
|
}
|
1132
1150
|
});
|
@@ -1139,11 +1157,11 @@
|
|
1139
1157
|
|
1140
1158
|
this.setValue(data);
|
1141
1159
|
|
1142
|
-
if (window["editable_" + this.editor.id] && this.editor.mode ===
|
1160
|
+
if (window["editable_" + this.editor.id] && this.editor.mode === "source") {
|
1143
1161
|
window["codemirror_" + this.editor.id].setValue(data);
|
1144
1162
|
}
|
1145
1163
|
|
1146
|
-
this.editor.fire(
|
1164
|
+
this.editor.fire("dataReady");
|
1147
1165
|
},
|
1148
1166
|
getData: function() {
|
1149
1167
|
return this.getValue();
|
@@ -1157,7 +1175,7 @@
|
|
1157
1175
|
},
|
1158
1176
|
// Read-only support for textarea.
|
1159
1177
|
setReadOnly: function(isReadOnly) {
|
1160
|
-
this[(isReadOnly ?
|
1178
|
+
this[(isReadOnly ? "set" : "remove") + "Attribute"]("readOnly", "readonly");
|
1161
1179
|
},
|
1162
1180
|
editorID: null,
|
1163
1181
|
detach: function() {
|
@@ -1185,12 +1203,12 @@ CKEDITOR.plugins.sourcearea = {
|
|
1185
1203
|
editorFocus: false,
|
1186
1204
|
readOnly: 1,
|
1187
1205
|
exec: function(editor) {
|
1188
|
-
if (editor.mode ===
|
1189
|
-
editor.fire(
|
1206
|
+
if (editor.mode === "wysiwyg") {
|
1207
|
+
editor.fire("saveSnapshot");
|
1190
1208
|
}
|
1191
1209
|
|
1192
|
-
editor.getCommand(
|
1193
|
-
editor.setMode(editor.mode ===
|
1210
|
+
editor.getCommand("source").setState(CKEDITOR.TRISTATE_DISABLED);
|
1211
|
+
editor.setMode(editor.mode === "source" ? "wysiwyg" : "source");
|
1194
1212
|
},
|
1195
1213
|
canUndo: false
|
1196
1214
|
},
|
@@ -1213,7 +1231,7 @@ CKEDITOR.plugins.sourcearea = {
|
|
1213
1231
|
},
|
1214
1232
|
editorFocus: false,
|
1215
1233
|
readOnly: 0,
|
1216
|
-
exec: function
|
1234
|
+
exec: function(editor) {
|
1217
1235
|
var range = {
|
1218
1236
|
from: window["codemirror_" + editor.id].getCursor(true),
|
1219
1237
|
to: window["codemirror_" + editor.id].getCursor(false)
|
@@ -1229,7 +1247,7 @@ CKEDITOR.plugins.sourcearea = {
|
|
1229
1247
|
},
|
1230
1248
|
editorFocus: false,
|
1231
1249
|
readOnly: 0,
|
1232
|
-
exec: function
|
1250
|
+
exec: function(editor) {
|
1233
1251
|
var range = {
|
1234
1252
|
from: window["codemirror_" + editor.id].getCursor(true),
|
1235
1253
|
to: window["codemirror_" + editor.id].getCursor(false)
|
@@ -1266,7 +1284,7 @@ CKEDITOR.plugins.sourcearea = {
|
|
1266
1284
|
},
|
1267
1285
|
editorFocus: false,
|
1268
1286
|
readOnly: 1,
|
1269
|
-
exec: function
|
1287
|
+
exec: function(editor) {
|
1270
1288
|
if (this.state == CKEDITOR.TRISTATE_ON) {
|
1271
1289
|
window["codemirror_" + editor.id].setOption("autoCloseTags", false);
|
1272
1290
|
} else if (this.state == CKEDITOR.TRISTATE_OFF) {
|
@@ -1308,4 +1326,4 @@ function OffSetToLineChannel(ed, n) {
|
|
1308
1326
|
|
1309
1327
|
function IsStyleSheetAlreadyLoaded(href) {
|
1310
1328
|
return CKEDITOR.document.getHead().findOne('link[href="' + href + '"]') != null;
|
1311
|
-
}
|
1329
|
+
}
|