diff --git a/README.md b/README.md index c0bebc56..8d8ed08e 100644 --- a/README.md +++ b/README.md @@ -12,7 +12,7 @@ * Email templates * Large CSV list import files -Subscribe to Mailtrain Newsletter [here](http://mailtrain.org/subscription/EysIv8sAx) (uses Mailtrain obviously) +Subscribe to Mailtrain Newsletter [here](https://mailtrain.org/subscription/S18sew2wM) (uses Mailtrain obviously) ## Hardware Requirements * 1 vCPU @@ -30,6 +30,7 @@ Depending on how you have configured your system and Docker you may need to prep * Download Mailtrain files using git: `git clone git://github.com/Mailtrain-org/mailtrain.git` (or download [zipped repo](https://github.com/Mailtrain-org/mailtrain/archive/master.zip)) and open Mailtrain folder `cd mailtrain` * Copy the file `docker-compose.override.yml.tmpl` to `docker-compose.override.yml` and modify it if you need to. * Bring up the stack with: `docker-compose up -d` +* Start: `docker-compose start` * Open [http://localhost:3000/](http://localhost:3000/) (change the host name `localhost` to the name of the host where you are deploying the system). * Authenticate as user `admin` with password `test` * Navigate to [http://localhost:3000/settings](http://localhost:3000/settings) and update service configuration. @@ -58,4 +59,4 @@ For more information, please [read the docs](http://docs.mailtrain.org/). * Versions 1.22.0 and up **GPL-V3.0** * Versions 1.21.0 and up: **EUPL-1.1** * Versions 1.19.0 and up: **MIT** - * Up to versions 1.18.0 **GPL-V3.0** \ No newline at end of file + * Up to versions 1.18.0 **GPL-V3.0** diff --git a/languages/de_DE.mo b/languages/de_DE.mo index fafb242b..3f1d6bd0 100644 Binary files a/languages/de_DE.mo and b/languages/de_DE.mo differ diff --git a/languages/de_DE.po b/languages/de_DE.po index 4ee3db99..8002764e 100644 --- a/languages/de_DE.po +++ b/languages/de_DE.po @@ -3,14 +3,14 @@ msgstr "" "Project-Id-Version: \n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2017-05-04 00:45+0200\n" -"PO-Revision-Date: 2017-05-04 00:46+0200\n" +"PO-Revision-Date: 2018-03-07 14:12+0100\n" "Last-Translator: \n" "Language-Team: \n" "Language: de_DE\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" -"X-Generator: Poedit 2.0.1\n" +"X-Generator: Poedit 2.0.6\n" "Plural-Forms: nplurals=2; plural=(n != 1);\n" #: views/archive/layout.hbs:1 views/layout.hbs:1 @@ -872,7 +872,7 @@ msgstr "Hallo [FIRST_NAME/Customer]," #: views/emails/stationery-html.hbs:2 views/emails/stationery-text.hbs:2 msgid "Cheers," -msgstr "Viele Grüsse," +msgstr "Viele Grüße," #: views/index.hbs:1 msgid "List Management" @@ -918,16 +918,16 @@ msgstr "Mailtrain bietet auch benutzerdefinierte Formulare." #: views/index.hbs:8 msgid "List Segmentation" -msgstr "Listen Segementierung" +msgstr "Segmentierung" #: views/index.hbs:9 msgid "" "Send messages only to list subscribers that match predefined segmentation " "rules. No need to create separate lists with small differences." msgstr "" -"Senden Sie nur Nachrichten an Abonnenten welche die vordefinierten " -"Segmentierungsregeln erfüllen. Keine Notwendigkeit, separate Listen mit " -"kleinen Unterschieden zu erstellen." +"Senden Sie nur Nachrichten an Abonnenten, welche die vordefinierten " +"Segmentierungsregeln erfüllen. Es besteht keine Notwendigkeit, separate " +"Listen mit kleinen Unterschieden zu erstellen." #: views/index.hbs:11 msgid "RSS Campaigns" @@ -954,7 +954,7 @@ msgid "" msgstr "" "Wenn für eine Liste ein benutzerdefiniertes Feld für den GPG-Public-Key " "vorhanden ist, können Abonnenten ihren GPG-Public-Key hochladen, um " -"verschlüsselte E-Mails dieser der Liste zu empfangen." +"verschlüsselte E-Mails der Liste zu empfangen." #: views/index.hbs:17 msgid "Click Stats" @@ -984,7 +984,7 @@ msgstr "" #: views/index.hbs:23 msgid "Send via Any Provider" -msgstr "Sende mit " +msgstr "Sende mit" #: views/index.hbs:24 msgid "" @@ -1121,7 +1121,7 @@ msgstr "Liste erstellen" #: views/lists/create.hbs:6 views/lists/edit.hbs:7 msgid "List Name" -msgstr "Linstennamen" +msgstr "Name der Liste" #: views/lists/create.hbs:9 views/lists/edit.hbs:15 msgid "Allow public users to subscribe themselves" @@ -1472,7 +1472,7 @@ msgstr "ID" #: views/lists/lists.hbs:7 views/reports/partials/report-fields.hbs:10 msgid "Subscribers" -msgstr "Abonnenten " +msgstr "Abonnenten" #: views/lists/segments/create.hbs:3 views/lists/segments/edit.hbs:3 #: views/lists/segments/rule-configure.hbs:3 @@ -1966,7 +1966,7 @@ msgstr "Mosaico öffnen" #: views/partials/plaintext.hbs:1 msgid "Template content (plaintext)" -msgstr "Vorlagen-Inhalt (Klartext) " +msgstr "Vorlagen-Inhalt (Klartext)" #: views/report-templates/create.hbs:2 views/report-templates/edit.hbs:2 #: views/report-templates/report-templates.hbs:2 @@ -2386,7 +2386,7 @@ msgstr "VERP verwenden um bounces zu erfassen" #: views/settings.hbs:71 msgid "Server hostname" -msgstr "Server Hostname" +msgstr "Hostname" #: views/settings.hbs:72 msgid "The VERP server hostname, eg. bounces.example.com" @@ -2462,7 +2462,7 @@ msgstr "" #: views/settings.hbs:84 msgid "DKIM Signing by ZoneMTA" -msgstr "DKIM Signing by ZoneMTA" +msgstr "DKIM Signing durch ZoneMTA" #: views/settings.hbs:85 msgid "" @@ -2507,7 +2507,7 @@ msgstr "DKIM Domain" #: views/settings.hbs:91 msgid "Domain name for the DKIM key" -msgstr "Domain-Name für den DKIM Key" +msgstr "Domain-Name für den DKIM-Key" #: views/settings.hbs:92 msgid "Leave blank to use the sender email address domain" @@ -2582,7 +2582,7 @@ msgstr "Ihr Abonnement für unsere Liste wurde bestätigt" #: views/subscription/mail-subscription-confirmed-html.mjml.hbs:3 msgid "If you want to modify your subscription then you can " -msgstr "Wenn Sie Ihr Abonnement ändern möchten, dann können Sie" +msgstr "Wenn Sie Ihr Abonnement ändern möchten, dann können Sie " #: views/subscription/mail-subscription-confirmed-html.mjml.hbs:4 #: views/subscription/mail-subscription-confirmed-text.hbs:4 @@ -2731,7 +2731,7 @@ msgstr "Einstellungen aktualisieren" #: views/subscription/web-subscribe.mjml.hbs:1 msgid "Subscribe to List" -msgstr "Diese Liste Abonnieren" +msgstr "Diese Liste abonnieren" #: views/subscription/web-subscribed.mjml.hbs:3 msgid "Thank you for subscribing!" @@ -2900,7 +2900,7 @@ msgstr "Ihre E-Mail-Adresse" #: views/users/account.hbs:9 msgid "" -"This address is used for account recovery in case you loose your password" +"This address is used for account recovery in case you lose your password" msgstr "" "Diese Adresse wird für die Wiederherstellung des Kontos verwendet, falls Sie " "Ihr Passwort vergessen haben" @@ -3185,7 +3185,7 @@ msgstr "Wähle Sie Ihr neues Passwort" #: views/users/reset.hbs:5 msgid "Please enter a new password." -msgstr "Bitte geben Sie ein neues Passwort ein" +msgstr "Bitte geben Sie ein neues Passwort ein." #: lib/editor-helpers.js:17 routes/templates.js:95 msgid "Could not find template with specified ID" @@ -3488,11 +3488,11 @@ msgid "Could not save subscription" msgstr "Abonnement konnte nicht gespeichert werden" #: lib/models/subscriptions.js:441 lib/models/subscriptions.js:471 -msgid "Missing Subbscription ID" +msgid "Missing Subscription ID" msgstr "Abonnement-ID fehlt" #: lib/models/subscriptions.js:499 -msgid "Missing Subbscription email address" +msgid "Missing Subscription email address" msgstr "Abonnement-E-Mail-Adresse fehlt" #: lib/models/subscriptions.js:578 lib/models/subscriptions.js:827 @@ -3650,6 +3650,22 @@ msgstr "Eingeloggt als %s" msgid "Incorrect username or password" msgstr "Falscher Benutzername oder Passwort" +#: lib/subscription-mail-helpers.js:39 +msgid "%s: Email Address Already Registered" +msgstr "%s: Email-Adresse bereits registriert" + +#: lib/subscription-mail-helpers.js:49 +msgid "%s: Please Confirm Email Change in Subscription" +msgstr "%s: Bitte bestätigen Sie die Änderung der Email-Adresse" + +#: lib/subscription-mail-helpers.js:69 +msgid "%s: Please Confirm Unsubscription" +msgstr "%s: Bitte bestätigen Sie die Kündigung des Abonnements" + +#: lib/subscription-mail-helpers.js:76 +msgid "%s: Unsubscription Confirmed" +msgstr "%s: Kündigung des Abonnements bestätigt" + #: lib/tools.js:148 msgid "Blocked email address \"%s\"" msgstr "Gesperrte E-Mail-Adresse \"%s\"" @@ -4593,3 +4609,31 @@ msgstr "Unbekannter Trigger-Typ %s" #~ msgid "Yes, subscribe me to this list:" #~ msgstr "Ja, tragen Sie mich in diese Liste ein:" + +#: lib/models/subscriptions.js:910 routes/subscription.js:472 +#: routes/subscription.js:544 routes/subscription.js:580 +#: routes/subscription.js:696 routes/subscription.js:771 +msgid "Subscription not found in this list" +msgstr "Das Abonnement wurde in dieser Liste nicht gefunden" + +#: views/subscription/web-confirm-unsubscription-notice.mjml.hbs:2 +msgid "" +"We need to confirm your email address. To complete the unsubscription " +"process, please click the link in the email we just sent you." +msgstr "" +"Wir müssen Ihre E-Mail-Adresse bestätigen. Um die Kündigung Ihres Abonnements abzuschließen, " +"klicken Sie bitte auf den Link in der E-Mail, die wir Ihnen gerade geschickt " +"haben." + +msgid "Please Confirm Unsubscription" +msgstr "Bitte bestätigen Sie die Kündigung Ihres Abonnements" + +msgid "Yes, unsubscribe me from this list" +msgstr "Ja, ich möchte dieses Abonnement kündigen" + +msgid "" +"If you received this email by mistake, simply delete it. You won't be " +"unsubscribed if you don't click the confirmation link above." +msgstr "" +"Wenn Sie diese E-Mail versehentlich erhalten haben, löschen Sie sie einfach. " +"Ihr Abonnement wird nicht gekündigt, wenn Sie nicht auf den Bestätigungslink oben klicken." diff --git a/languages/es_ES.mo b/languages/es_ES.mo index 818a6306..214acc8a 100644 Binary files a/languages/es_ES.mo and b/languages/es_ES.mo differ diff --git a/languages/es_ES.po b/languages/es_ES.po index 998c3e56..8abe4590 100644 --- a/languages/es_ES.po +++ b/languages/es_ES.po @@ -3027,7 +3027,7 @@ msgstr "Tu dirección email" #: views/users/account.hbs:9 msgid "" -"This address is used for account recovery in case you loose your password" +"This address is used for account recovery in case you lose your password" msgstr "" "Este email es usado para recuperar una cuenta en caso de que no recuerdes la " "contraseña" @@ -3614,18 +3614,14 @@ msgstr "El segmento especificado no se encontra" msgid "Selected rule not found" msgstr "La regla seleccionada no se encontra" -#: lib/models/subscriptions.js:254 lib/models/subscriptions.js:284 -msgid "Missing Subbscription ID" +#: lib/models/subscriptions.js:254 lib/models/subscriptions.js:284 lib/models/subscriptions.js:391 +msgid "Missing Subscription ID" msgstr "Falta el ID de Suscripción" #: lib/models/subscriptions.js:312 -msgid "Missing Subbscription email address" +msgid "Missing Subscription email address" msgstr "Falta el correo electrónico de suscripción" -#: lib/models/subscriptions.js:391 -msgid "Missing Subscription ID" -msgstr "Falta el ID de suscripción" - #: lib/models/subscriptions.js:567 lib/models/subscriptions.js:817 msgid "Missing subscription ID" msgstr "Falta el ID de suscripción" diff --git a/languages/et.mo b/languages/et.mo index a067cb9c..18e5f344 100644 Binary files a/languages/et.mo and b/languages/et.mo differ diff --git a/languages/et.po b/languages/et.po index 0f3d3f2b..88ad5bdb 100644 --- a/languages/et.po +++ b/languages/et.po @@ -2300,7 +2300,7 @@ msgstr "" #: views/users/account.hbs:9 msgid "" -"This address is used for account recovery in case you loose your password" +"This address is used for account recovery in case you lose your password" msgstr "" #: views/users/account.hbs:10 @@ -2770,11 +2770,11 @@ msgid "Could not save subscription" msgstr "" #: lib/models/subscriptions.js:507 lib/models/subscriptions.js:537 -msgid "Missing Subbscription ID" +msgid "Missing Subscription ID" msgstr "" #: lib/models/subscriptions.js:565 -msgid "Missing Subbscription email address" +msgid "Missing Subscription email address" msgstr "" #: lib/models/subscriptions.js:644 lib/models/subscriptions.js:893 diff --git a/languages/it_IT.mo b/languages/it_IT.mo new file mode 100644 index 00000000..7e5a8f97 Binary files /dev/null and b/languages/it_IT.mo differ diff --git a/languages/it_IT.po b/languages/it_IT.po new file mode 100644 index 00000000..b35ef79f --- /dev/null +++ b/languages/it_IT.po @@ -0,0 +1,4661 @@ +msgid "" +msgstr "" +"Project-Id-Version: \n" +"Language-Team: \n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2018-04-11 12:42+0200\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: 8bit\n" +"POT-Creation-Date: 2018-04-05 15:43+0200\n" +"X-Generator: Poedit 1.8.7.1\n" +"Last-Translator: \n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"Language: it\n" + +#: views/archive/layout.hbs:1 views/layout.hbs:1 +msgid "Self hosted email newsletter app" +msgstr "Applicazione di newsletter self-hosted" + +#: views/blacklist.hbs:1 views/campaigns/blacklisted.hbs:1 +#: views/campaigns/bounced.hbs:1 views/campaigns/campaigns.hbs:1 +#: views/campaigns/clicked.hbs:1 views/campaigns/complained.hbs:1 +#: views/campaigns/create-rss.hbs:1 views/campaigns/create-triggered.hbs:1 +#: views/campaigns/create.hbs:1 views/campaigns/delivered.hbs:1 +#: views/campaigns/edit-rss.hbs:1 views/campaigns/edit-triggered.hbs:1 +#: views/campaigns/edit.hbs:1 views/campaigns/opened.hbs:1 +#: views/campaigns/unsubscribed.hbs:1 views/campaigns/upload-attachment.hbs:1 +#: views/campaigns/view.hbs:1 views/lists/create.hbs:1 views/lists/edit.hbs:1 +#: views/lists/fields/create.hbs:1 views/lists/fields/edit.hbs:1 +#: views/lists/fields/fields.hbs:1 views/lists/forms/create.hbs:1 +#: views/lists/forms/edit.hbs:1 views/lists/forms/forms.hbs:1 +#: views/lists/lists.hbs:1 views/lists/segments/create.hbs:1 +#: views/lists/segments/edit.hbs:1 views/lists/segments/rule-configure.hbs:1 +#: views/lists/segments/rule-create.hbs:1 views/lists/segments/rule-edit.hbs:1 +#: views/lists/segments/segments.hbs:1 views/lists/segments/view.hbs:1 +#: views/lists/subscription/add.hbs:1 views/lists/subscription/edit.hbs:1 +#: views/lists/subscription/import-failed.hbs:1 +#: views/lists/subscription/import-preview.hbs:1 +#: views/lists/subscription/import.hbs:1 views/lists/view.hbs:1 +#: views/report-templates/create.hbs:1 views/report-templates/edit.hbs:1 +#: views/report-templates/report-templates.hbs:1 +#: views/reports/create-select-template.hbs:1 views/reports/create.hbs:1 +#: views/reports/edit.hbs:1 views/reports/output.hbs:1 +#: views/reports/reports.hbs:1 views/reports/view.hbs:1 views/settings.hbs:1 +#: views/templates/create.hbs:1 views/templates/edit.hbs:1 +#: views/templates/templates.hbs:1 views/triggers/create-select.hbs:1 +#: views/triggers/create.hbs:1 views/triggers/edit.hbs:1 +#: views/triggers/triggered.hbs:1 views/triggers/triggers.hbs:1 +#: views/users/account.hbs:1 views/users/api.hbs:1 views/users/forgot.hbs:1 +#: views/users/login.hbs:1 views/users/reset.hbs:1 app.js:169 +msgid "Home" +msgstr "Home" + +#: views/blacklist.hbs:2 views/blacklist.hbs:3 views/layout.hbs:7 +#: views/lists/subscription/edit.hbs:15 +msgid "Blacklist" +msgstr "Lista nera" + +#: views/blacklist.hbs:4 views/users/api.hbs:76 +msgid "Add email to blacklist" +msgstr "Aggiungi email alla lista nera" + +#: views/blacklist.hbs:5 +msgid "Add" +msgstr "Aggiungi" + +#: views/blacklist.hbs:6 +msgid "Email" +msgstr "Email" + +#: views/campaigns/blacklisted.hbs:2 views/campaigns/bounced.hbs:2 +#: views/campaigns/campaigns.hbs:2 views/campaigns/campaigns.hbs:7 +#: views/campaigns/clicked.hbs:2 views/campaigns/complained.hbs:2 +#: views/campaigns/create-rss.hbs:2 views/campaigns/create-triggered.hbs:2 +#: views/campaigns/create.hbs:2 views/campaigns/delivered.hbs:2 +#: views/campaigns/edit-rss.hbs:2 views/campaigns/edit-triggered.hbs:2 +#: views/campaigns/edit.hbs:2 views/campaigns/opened.hbs:2 +#: views/campaigns/unsubscribed.hbs:2 views/campaigns/upload-attachment.hbs:2 +#: views/campaigns/view.hbs:2 lib/tools.js:133 routes/campaigns.js:35 +msgid "Campaigns" +msgstr "Campagne" + +#: views/campaigns/blacklisted.hbs:3 views/campaigns/blacklisted.hbs:4 +msgid "Blacklisted info" +msgstr "Informazioni lista nera" + +#: views/campaigns/blacklisted.hbs:5 views/campaigns/bounced.hbs:5 +#: views/campaigns/clicked.hbs:5 views/campaigns/complained.hbs:5 +#: views/campaigns/delivered.hbs:5 views/campaigns/edit-rss.hbs:5 +#: views/campaigns/edit-triggered.hbs:5 views/campaigns/edit.hbs:5 +#: views/campaigns/opened.hbs:5 views/campaigns/unsubscribed.hbs:5 +#: views/campaigns/upload-attachment.hbs:6 +msgid "View campaign" +msgstr "Vedi campagna" + +#: views/campaigns/blacklisted.hbs:6 +msgid "Subscribers who blacklisted by global blacklist:" +msgstr "Iscritti in lista nera derivati dalla lista nera globale:" + +#: views/campaigns/blacklisted.hbs:7 views/campaigns/bounced.hbs:7 +#: views/campaigns/clicked.hbs:15 views/campaigns/complained.hbs:7 +#: views/campaigns/delivered.hbs:7 views/campaigns/opened.hbs:9 +#: views/campaigns/unsubscribed.hbs:7 +#: views/lists/subscription/import-failed.hbs:8 views/lists/view.hbs:19 +#: views/triggers/triggered.hbs:6 +msgid "Address" +msgstr "Indirizzo" + +#: views/campaigns/blacklisted.hbs:8 views/campaigns/bounced.hbs:8 +#: views/campaigns/clicked.hbs:16 views/campaigns/complained.hbs:8 +#: views/campaigns/delivered.hbs:8 views/campaigns/opened.hbs:10 +#: views/campaigns/unsubscribed.hbs:8 views/lists/subscription/add.hbs:6 +#: views/lists/subscription/edit.hbs:7 +#: views/lists/subscription/import-preview.hbs:7 views/lists/view.hbs:20 +#: views/subscription/partials/subscription-custom-fields.hbs:3 +#: views/triggers/triggered.hbs:7 +msgid "First Name" +msgstr "Nome" + +#: views/campaigns/blacklisted.hbs:9 views/campaigns/bounced.hbs:9 +#: views/campaigns/clicked.hbs:17 views/campaigns/complained.hbs:9 +#: views/campaigns/delivered.hbs:9 views/campaigns/opened.hbs:11 +#: views/campaigns/unsubscribed.hbs:9 views/lists/subscription/add.hbs:7 +#: views/lists/subscription/edit.hbs:8 +#: views/lists/subscription/import-preview.hbs:8 views/lists/view.hbs:21 +#: views/subscription/partials/subscription-custom-fields.hbs:4 +#: views/triggers/triggered.hbs:8 +msgid "Last Name" +msgstr "Cognome" + +#: views/campaigns/blacklisted.hbs:10 +msgid "Reason" +msgstr "Ragione" + +#: views/campaigns/blacklisted.hbs:11 +msgid "Time" +msgstr "Tempo" + +#: views/campaigns/bounced.hbs:3 views/campaigns/bounced.hbs:4 +msgid "Bounced info" +msgstr "Informazioni rimbalzo" + +#: views/campaigns/bounced.hbs:6 +msgid "Subscribers who bounced and were unsubscribed:" +msgstr "Iscritti che hanno rimbalzato e sono stati rimossi:" + +#: views/campaigns/bounced.hbs:10 views/campaigns/complained.hbs:10 +#: views/campaigns/delivered.hbs:10 views/campaigns/unsubscribed.hbs:10 +msgid "SMTP response" +msgstr "Risposta SMTP" + +#: views/campaigns/bounced.hbs:11 +msgid "Bounce time" +msgstr "Tempo di rimbalzo" + +#: views/campaigns/campaigns.hbs:3 views/campaigns/create-triggered.hbs:26 +#: views/campaigns/create.hbs:3 views/campaigns/create.hbs:4 +#: views/campaigns/create.hbs:28 +msgid "Create Campaign" +msgstr "Crea Campagna" + +#: views/campaigns/campaigns.hbs:4 +msgid "Regular Campaign" +msgstr "Campagna regolare" + +#: views/campaigns/campaigns.hbs:5 +msgid "RSS Campaign" +msgstr "Campagna RSS" + +#: views/campaigns/campaigns.hbs:6 +msgid "Triggered Campaign" +msgstr "Campagna attivabile" + +#: views/campaigns/campaigns.hbs:8 views/campaigns/create-rss.hbs:6 +#: views/campaigns/create-triggered.hbs:5 views/campaigns/create.hbs:5 +#: views/campaigns/edit-rss.hbs:8 views/campaigns/edit-triggered.hbs:9 +#: views/campaigns/edit.hbs:10 views/campaigns/view.hbs:73 +#: views/lists/create.hbs:5 views/lists/edit.hbs:6 +#: views/lists/fields/fields.hbs:6 views/lists/forms/forms.hbs:6 +#: views/lists/lists.hbs:5 views/lists/segments/segments.hbs:6 +#: views/report-templates/partials/report-template-fields.hbs:1 +#: views/report-templates/report-templates.hbs:10 +#: views/reports/partials/report-fields.hbs:1 +#: views/reports/partials/report-fields.hbs:5 +#: views/reports/partials/report-fields.hbs:9 views/reports/reports.hbs:6 +#: views/templates/templates.hbs:5 views/triggers/triggers.hbs:5 +msgid "Name" +msgstr "Nome" + +#: views/campaigns/campaigns.hbs:9 views/campaigns/create-rss.hbs:8 +#: views/campaigns/create-triggered.hbs:7 views/campaigns/create.hbs:7 +#: views/campaigns/edit-rss.hbs:10 views/campaigns/edit-triggered.hbs:11 +#: views/campaigns/edit.hbs:12 views/campaigns/view.hbs:74 +#: views/lists/create.hbs:7 views/lists/edit.hbs:10 +#: views/lists/forms/edit.hbs:9 views/lists/forms/forms.hbs:7 +#: views/lists/lists.hbs:8 views/mosaico/editor.hbs:3 +#: views/partials/merge-tag-reference.hbs:4 +#: views/report-templates/partials/report-template-fields.hbs:3 +#: views/report-templates/report-templates.hbs:11 +#: views/reports/partials/report-fields.hbs:3 +#: views/reports/partials/report-fields.hbs:6 views/reports/reports.hbs:8 +#: views/templates/create.hbs:9 views/templates/edit.hbs:8 +#: views/templates/templates.hbs:6 views/triggers/create.hbs:7 +#: views/triggers/edit.hbs:8 views/triggers/triggers.hbs:7 +msgid "Description" +msgstr "Descrizione" + +#: views/campaigns/campaigns.hbs:10 views/campaigns/view.hbs:75 +#: views/lists/view.hbs:22 views/lists/view.hbs:30 +#: views/triggers/triggers.hbs:6 +msgid "Status" +msgstr "Stato" + +#: views/campaigns/campaigns.hbs:11 views/campaigns/view.hbs:76 +#: views/lists/view.hbs:23 views/lists/view.hbs:24 +#: views/report-templates/report-templates.hbs:12 +#: views/reports/partials/report-fields.hbs:7 views/reports/reports.hbs:9 +msgid "Created" +msgstr "Creato" + +#: views/campaigns/clicked.hbs:3 views/campaigns/clicked.hbs:4 +msgid "Link info" +msgstr "Informazioni link" + +#: views/campaigns/clicked.hbs:6 views/campaigns/view.hbs:63 +msgid "URL" +msgstr "URL" + +#: views/campaigns/clicked.hbs:7 views/campaigns/view.hbs:64 +msgid "Clicks" +msgstr "Clicks" + +#: views/campaigns/clicked.hbs:8 views/campaigns/view.hbs:65 +msgid "% of clicks" +msgstr "% di clicks" + +#: views/campaigns/clicked.hbs:9 views/campaigns/view.hbs:66 +msgid "% of messages" +msgstr "% di messagi" + +#: views/campaigns/clicked.hbs:10 views/campaigns/view.hbs:69 +msgid "Aggregated clicks" +msgstr "Clicks aggregati" + +#: views/campaigns/clicked.hbs:11 +msgid "Subscribers who clicked on a link:" +msgstr "Iscritti che hanno cliccato un link:" + +#: views/campaigns/clicked.hbs:12 +msgid "Subscribers who clicked on this link:" +msgstr "Iscritti che hanno cliccato questo link:" + +#: views/campaigns/clicked.hbs:13 views/campaigns/opened.hbs:7 +msgid "Stats by country" +msgstr "Statistiche per nazione" + +#: views/campaigns/clicked.hbs:14 views/campaigns/opened.hbs:8 +msgid "Stats by device type" +msgstr "Statistiche per tipo di dispositivo" + +#: views/campaigns/clicked.hbs:18 +msgid "First click time" +msgstr "Tempo primo click" + +#: views/campaigns/clicked.hbs:19 +msgid "Click count" +msgstr "Conteggio clicks" + +#: views/campaigns/complained.hbs:3 views/campaigns/complained.hbs:4 +msgid "Complained info" +msgstr "Informazioni reclamo" + +#: views/campaigns/complained.hbs:6 +msgid "Subscribers who complained and were unsubscribed:" +msgstr "Iscritti che hanno reclamato e sono stati rimossi" + +#: views/campaigns/complained.hbs:11 +msgid "Complain time" +msgstr "Tempo reclamo" + +#: views/campaigns/create-rss.hbs:3 views/campaigns/create-rss.hbs:4 +#: views/campaigns/create-rss.hbs:21 +msgid "Create RSS Campaign" +msgstr "Crea campagna RSS" + +#: views/campaigns/create-rss.hbs:5 views/campaigns/edit-rss.hbs:6 +msgid "" +"RSS campaign sets up a tracker against selected RSS feed address. Whenever a " +"new entry is found from this feed it is sent to selected list as an email " +"message." +msgstr "" +"Le campagne RSS configurano un registratore per gli indirizzi dei feed RSS. " +"Qualvolta un nuovo elemento venga trovato per il feed, viene inviato alle " +"liste selezionate come una email." + +#: views/campaigns/create-rss.hbs:7 views/campaigns/create-triggered.hbs:6 +#: views/campaigns/create.hbs:6 views/campaigns/edit-rss.hbs:9 +#: views/campaigns/edit-triggered.hbs:10 views/campaigns/edit.hbs:11 +msgid "Campaign Name" +msgstr "Nome campagna" + +#: views/campaigns/create-rss.hbs:9 views/campaigns/create-triggered.hbs:8 +#: views/campaigns/create.hbs:8 views/campaigns/edit-rss.hbs:11 +#: views/campaigns/edit-triggered.hbs:12 views/campaigns/edit.hbs:13 +#: views/lists/create.hbs:8 views/lists/edit.hbs:11 +#: views/report-templates/partials/report-template-fields.hbs:4 +#: views/reports/partials/report-fields.hbs:4 views/templates/create.hbs:11 +#: views/templates/edit.hbs:10 views/triggers/create.hbs:9 +#: views/triggers/edit.hbs:10 +msgid "HTML is allowed" +msgstr "HTML è consentito" + +#: views/campaigns/create-rss.hbs:10 views/campaigns/create-triggered.hbs:9 +#: views/campaigns/create.hbs:9 views/campaigns/edit-rss.hbs:12 +#: views/campaigns/edit-triggered.hbs:13 views/campaigns/edit.hbs:14 +#: views/campaigns/view.hbs:6 views/triggers/create-select.hbs:6 +#: views/triggers/create.hbs:10 views/triggers/edit.hbs:12 +#: views/triggers/triggers.hbs:8 +msgid "List" +msgstr "Lista" + +#: views/campaigns/create-rss.hbs:11 views/campaigns/create-triggered.hbs:10 +#: views/campaigns/create-triggered.hbs:14 views/campaigns/create.hbs:10 +#: views/campaigns/create.hbs:14 views/campaigns/edit-rss.hbs:13 +#: views/campaigns/edit-triggered.hbs:14 views/campaigns/edit.hbs:15 +#: views/lists/fields/create.hbs:27 views/lists/fields/edit.hbs:28 +#: views/lists/segments/create.hbs:9 views/lists/segments/edit.hbs:10 +#: views/lists/segments/rule-create.hbs:7 views/lists/subscription/add.hbs:10 +#: views/lists/subscription/add.hbs:12 views/lists/subscription/edit.hbs:11 +#: views/lists/subscription/import-preview.hbs:5 +#: views/reports/partials/report-select-template.hbs:2 +#: views/subscription/partials/subscription-custom-fields.hbs:9 +#: views/templates/create.hbs:8 views/triggers/create-select.hbs:7 +#: views/triggers/create.hbs:17 views/triggers/create.hbs:20 +#: views/triggers/create.hbs:22 views/triggers/create.hbs:26 +#: views/triggers/edit.hbs:19 views/triggers/edit.hbs:22 +#: views/triggers/edit.hbs:24 views/triggers/edit.hbs:28 +msgid "Select" +msgstr "Seleziona" + +#: views/campaigns/create-rss.hbs:12 views/campaigns/create-triggered.hbs:11 +#: views/campaigns/create.hbs:11 views/campaigns/edit-rss.hbs:14 +#: views/campaigns/edit-triggered.hbs:15 views/campaigns/edit.hbs:16 +#: views/triggers/create-select.hbs:8 views/triggers/create.hbs:11 +#: views/triggers/edit.hbs:13 +msgid "subscribers" +msgstr "Iscritti" + +#: views/campaigns/create-rss.hbs:13 views/campaigns/edit-rss.hbs:15 +msgid "RSS Feed Url" +msgstr "URL del feed RSS" + +#: views/campaigns/create-rss.hbs:14 views/campaigns/edit-rss.hbs:16 +msgid "" +"New entries from this RSS URL are sent out to list subscribers as email " +"messages" +msgstr "" +"I nuovi elementi per questo feed RSS sono inviati agli iscritti come " +"messaggi email." + +#: views/campaigns/create-rss.hbs:15 views/campaigns/create-triggered.hbs:18 +#: views/campaigns/create.hbs:18 views/campaigns/edit-rss.hbs:18 +#: views/campaigns/edit-triggered.hbs:16 views/campaigns/edit.hbs:17 +#: views/campaigns/view.hbs:12 +msgid "Email \"from name\"" +msgstr "Email da \"Nome\"" + +#: views/campaigns/create-rss.hbs:16 views/campaigns/create-triggered.hbs:19 +#: views/campaigns/create.hbs:19 views/campaigns/edit-rss.hbs:19 +#: views/campaigns/edit-triggered.hbs:17 views/campaigns/edit.hbs:18 +#: views/settings.hbs:23 +msgid "This is the name your emails will come from" +msgstr "Questo è il nome che verrà' visualizzato come mittente" + +#: views/campaigns/create-rss.hbs:17 views/campaigns/create-triggered.hbs:20 +#: views/campaigns/create.hbs:20 views/campaigns/edit-rss.hbs:20 +#: views/campaigns/edit-triggered.hbs:18 views/campaigns/edit.hbs:19 +#: views/campaigns/view.hbs:13 +msgid "Email \"from\" address" +msgstr "Email dall'indirizzo" + +#: views/campaigns/create-rss.hbs:18 views/campaigns/create-triggered.hbs:21 +#: views/campaigns/edit-rss.hbs:21 views/campaigns/edit-triggered.hbs:19 +#: views/settings.hbs:25 +msgid "This is the address people will send replies to" +msgstr "Questo è l'indirizzo a cui gli iscritti risponderanno" + +#: views/campaigns/create-rss.hbs:19 views/campaigns/create-triggered.hbs:24 +#: views/campaigns/create.hbs:26 views/campaigns/edit-rss.hbs:22 +#: views/campaigns/edit-triggered.hbs:22 views/campaigns/edit.hbs:25 +msgid "Disable opened tracking" +msgstr "Disabilita tracciamento aperture" + +#: views/campaigns/create-rss.hbs:20 views/campaigns/create-triggered.hbs:25 +#: views/campaigns/create.hbs:27 views/campaigns/edit-rss.hbs:23 +#: views/campaigns/edit-triggered.hbs:23 views/campaigns/edit.hbs:26 +msgid "Disable clicked tracking" +msgstr "Disabilita tracciamento clicks" + +#: views/campaigns/create-triggered.hbs:3 +#: views/campaigns/create-triggered.hbs:4 +msgid "Create Triggered Campaign" +msgstr "Crea una campagna attivabile" + +#: views/campaigns/create-triggered.hbs:12 views/campaigns/create.hbs:12 +#: views/campaigns/edit-triggered.hbs:7 views/campaigns/edit.hbs:7 +#: views/lists/fields/create.hbs:31 views/lists/fields/edit.hbs:33 +#: views/reports/reports.hbs:7 views/templates/create.hbs:13 +msgid "Template" +msgstr "Template" + +#: views/campaigns/create-triggered.hbs:13 views/campaigns/create.hbs:13 +msgid "Select a template:" +msgstr "Seleziona un template:" + +#: views/campaigns/create-triggered.hbs:15 views/campaigns/create.hbs:15 +msgid "Selecting a template creates a campaign specific copy from it" +msgstr "Selezionando un template, si crea una copia su cui andare a lavorare" + +#: views/campaigns/create-triggered.hbs:16 views/campaigns/create.hbs:16 +msgid "Or alternatively use an URL as the message content source:" +msgstr "In alternativa utilizza un URL per il contenuto del messaggio:" + +#: views/campaigns/create-triggered.hbs:17 views/campaigns/create.hbs:17 +#: views/campaigns/edit-triggered.hbs:26 views/campaigns/edit.hbs:29 +msgid "" +"If a message is sent then this URL will be POSTed to using Merge Tags as " +"POST body. Use this if you want to generate the HTML message yourself" +msgstr "" +"Se un messaggio viene inviato questa URL verrà' richiamata assorbendo i " +"merge tags come body del messaggio. Utilizza questa opzione se vuoi scrivere " +"tu l'HTML del messaggio" + +#: views/campaigns/create-triggered.hbs:22 views/campaigns/create.hbs:24 +#: views/campaigns/edit-triggered.hbs:20 views/campaigns/edit.hbs:23 +#: views/campaigns/view.hbs:15 +msgid "Email \"subject line\"" +msgstr "Oggetto dell'email" + +#: views/campaigns/create-triggered.hbs:23 views/campaigns/create.hbs:25 +#: views/campaigns/edit-triggered.hbs:21 views/campaigns/edit.hbs:24 +#: views/settings.hbs:27 +msgid "Keep it relevant and non-spammy" +msgstr "Ricordati di mantenerla rilevante e non creare spam" + +#: views/campaigns/create.hbs:21 views/campaigns/edit.hbs:20 +msgid "" +"This is the address people will send replies to unless reply-to address is " +"set" +msgstr "" +"Questo è l'indirizzo a cui gli iscritti risponderanno se non specifichi un " +"indirizzo email 'reply-to'" + +#: views/campaigns/create.hbs:22 views/campaigns/edit.hbs:21 +#: views/campaigns/view.hbs:14 +msgid "Email \"reply-to\" address" +msgstr "Indirizzo email 'reply-to'" + +#: views/campaigns/create.hbs:23 views/campaigns/edit.hbs:22 +msgid "If set, this is the address people will send replies to" +msgstr "Se impostato, questo sarà' l'indirizzo a cui le persone risponderanno" + +#: views/campaigns/delivered.hbs:3 views/campaigns/delivered.hbs:4 +msgid "Delivered info" +msgstr "Informazioni della consegna" + +#: views/campaigns/delivered.hbs:6 +msgid "Subscribers who received the message and did not bounce/unsubscribe:" +msgstr "" +"Iscritti che hanno ricevuto il messaggio e non hanno reclamato e non si sono " +"rimossi" + +#: views/campaigns/delivered.hbs:11 +msgid "Delivery time" +msgstr "Ora di consegna" + +#: views/campaigns/edit-rss.hbs:3 views/campaigns/edit-rss.hbs:4 +msgid "Edit RSS Campaign" +msgstr "Modifica campagna RSS" + +#: views/campaigns/edit-rss.hbs:7 views/campaigns/edit-triggered.hbs:8 +#: views/campaigns/edit.hbs:9 views/settings.hbs:4 views/users/account.hbs:6 +msgid "General Settings" +msgstr "Impostazioni generali" + +#: views/campaigns/edit-rss.hbs:17 +msgid "" +"Use special merge tag [RSS_ENTRY] to mark the position for the RSS post " +"content. Additionally you can use any valid merge tag as well." +msgstr "" +"Utilizza tag di assorbimento speciali [RSS_ENTRY] per evidenziare il " +"contenuto del messaggio all'interno del RSS. Puoi inoltre utilizzare " +"qualsiasi tag di merge valido." + +#: views/campaigns/edit-rss.hbs:24 views/campaigns/edit-triggered.hbs:27 +#: views/campaigns/edit.hbs:35 +msgid "Delete Campaign" +msgstr "Cancella " + +#: views/campaigns/edit-rss.hbs:25 views/campaigns/edit-triggered.hbs:28 +#: views/campaigns/edit.hbs:36 views/lists/edit.hbs:20 +#: views/lists/fields/edit.hbs:39 views/lists/forms/edit.hbs:33 +#: views/lists/forms/forms.hbs:12 views/lists/segments/edit.hbs:14 +#: views/lists/segments/rule-edit.hbs:38 views/lists/subscription/edit.hbs:18 +#: views/reports/edit.hbs:6 views/settings.hbs:97 views/templates/edit.hbs:13 +#: views/triggers/edit.hbs:30 views/users/account.hbs:18 +msgid "Update" +msgstr "Aggiorna" + +#: views/campaigns/edit-triggered.hbs:3 views/campaigns/edit-triggered.hbs:4 +msgid "Edit Triggered Campaign" +msgstr "Modifica campagna azionabile" + +#: views/campaigns/edit-triggered.hbs:6 views/campaigns/edit.hbs:6 +#: routes/forms.js:143 +msgid "General" +msgstr "Generale" + +#: views/campaigns/edit-triggered.hbs:24 views/campaigns/edit.hbs:27 +msgid "Template Settings" +msgstr "Impostazioni Template" + +#: views/campaigns/edit-triggered.hbs:25 views/campaigns/edit.hbs:28 +msgid "Template URL" +msgstr "URL Template" + +#: views/campaigns/edit.hbs:3 views/campaigns/edit.hbs:4 +#: views/campaigns/upload-attachment.hbs:3 +#: views/campaigns/upload-attachment.hbs:5 views/campaigns/view.hbs:3 +msgid "Edit Campaign" +msgstr "Modifica Campagna" + +#: views/campaigns/edit.hbs:8 views/campaigns/edit.hbs:30 +msgid "Attachments" +msgstr "Allegati" + +#: views/campaigns/edit.hbs:31 +msgid "File" +msgstr "File" + +#: views/campaigns/edit.hbs:32 +msgid "Size" +msgstr "Dimensione" + +#: views/campaigns/edit.hbs:33 views/campaigns/view.hbs:68 +#: views/lists/fields/fields.hbs:12 views/lists/forms/forms.hbs:9 +#: views/lists/view.hbs:33 +msgid "No data available in table" +msgstr "Non ci sono dati disponibili nella tabella" + +#: views/campaigns/edit.hbs:34 views/campaigns/upload-attachment.hbs:4 +msgid "Add Attachment" +msgstr "Aggiungi allegato" + +#: views/campaigns/opened.hbs:3 views/campaigns/opened.hbs:4 +msgid "Opened info" +msgstr "Informazioni apertura" + +#: views/campaigns/opened.hbs:6 +msgid "Subscribers who opened this message:" +msgstr "Iscritti che hanno aperto il messaggio:" + +#: views/campaigns/opened.hbs:12 +msgid "First open" +msgstr "Prima apertura" + +#: views/campaigns/opened.hbs:13 +msgid "Opened count" +msgstr "Numero di aperture" + +#: views/campaigns/unsubscribed.hbs:3 views/campaigns/unsubscribed.hbs:4 +msgid "Unsubscribed info" +msgstr "Informazioni utenti rimossi" + +#: views/campaigns/unsubscribed.hbs:6 +msgid "Subscribers who unsubscribed:" +msgstr "Iscritti che si sono rimossi:" + +#: views/campaigns/unsubscribed.hbs:11 views/campaigns/view.hbs:28 +#: views/lists/subscription/import.hbs:13 routes/lists.js:206 +msgid "Unsubscribed" +msgstr "Rimossi" + +#: views/campaigns/upload-attachment.hbs:7 +msgid "Upload" +msgstr "Carica" + +#: views/campaigns/view.hbs:4 +msgid "Overview" +msgstr "Panoramica" + +#: views/campaigns/view.hbs:5 +msgid "Links" +msgstr "Links" + +#: views/campaigns/view.hbs:7 +msgid "Feed URL" +msgstr "Feed URL" + +#: views/campaigns/view.hbs:8 +msgid "Last check" +msgstr "Ultimo controllo" + +#: views/campaigns/view.hbs:9 +msgid "Not yet checked" +msgstr "Non ancora controllati" + +#: views/campaigns/view.hbs:10 +msgid "activate campaign to start checking feed for new messages" +msgstr "attiva la campagna per controllare il feed per nuovi messaggi" + +#: views/campaigns/view.hbs:11 +msgid "RSS status" +msgstr "Stato RSS" + +#: views/campaigns/view.hbs:16 +msgid "Preview campaign as" +msgstr "Guarda l'anteprima come" + +#: views/campaigns/view.hbs:17 +msgid "Add new test user" +msgstr "Aggiungi un utente di test" + +#: views/campaigns/view.hbs:18 +msgid "No test users yet, create one here" +msgstr "Non sono presenti utenti di test, creane uno qui" + +#: views/campaigns/view.hbs:19 +msgid "Go" +msgstr "Vai" + +#: views/campaigns/view.hbs:20 lib/models/triggers.js:26 +msgid "Delivered" +msgstr "Consegnato" + +#: views/campaigns/view.hbs:21 +msgid "List subscribers who received this message" +msgstr "Elenca iscritti che hanno ricevuto il messaggio" + +#: views/campaigns/view.hbs:22 +msgid "Blacklisted" +msgstr "In lista nera" + +#: views/campaigns/view.hbs:23 +msgid "List subscribers who blacklisted by global blacklist" +msgstr "Lista degli iscritti in lista nera per la lista nera globale" + +#: views/campaigns/view.hbs:24 routes/lists.js:206 +msgid "Bounced" +msgstr "Rimbalzato" + +#: views/campaigns/view.hbs:25 +msgid "List subscribers who bounced" +msgstr "Lista utenti che hanno rimbalzato" + +#: views/campaigns/view.hbs:26 +msgid "Complaints" +msgstr "Reclami" + +#: views/campaigns/view.hbs:27 +msgid "List subscribers who complained for this message" +msgstr "Lista degli iscritti che hanno fatto un reclamo per questo messaggio" + +#: views/campaigns/view.hbs:29 +msgid "List subscribers who unsubscribed after this message" +msgstr "" +"Lista degli utenti che si sono cancellati in seguito a questo messaggio" + +#: views/campaigns/view.hbs:30 +msgid "Opened" +msgstr "Aperta" + +#: views/campaigns/view.hbs:31 +msgid "List subscribers who opened this message" +msgstr "Lista degli iscritti che hanno aperto questo messaggio" + +#: views/campaigns/view.hbs:32 +msgid "Clicked" +msgstr "Cliccate" + +#: views/campaigns/view.hbs:33 views/campaigns/view.hbs:70 +msgid "List subscribers who clicked on a link" +msgstr "Lista degli iscritti che hanno cliccato su di un link" + +#: views/campaigns/view.hbs:34 +msgid "" +"Are you sure? This action would start sending messages to the selected list" +msgstr "" +"Sei sicuro? Questa azione farà iniziare l'invio dei messaggi alla lista " +"selezionata" + +#: views/campaigns/view.hbs:35 +msgid "Delay sending" +msgstr "Ritarda invio" + +#: views/campaigns/view.hbs:36 +msgid "hours" +msgstr "ore" + +#: views/campaigns/view.hbs:37 +msgid "minutes" +msgstr "minuti" + +#: views/campaigns/view.hbs:38 +msgid "Send to subscribers:" +msgstr "Invia agli iscritti:" + +#: views/campaigns/view.hbs:39 +msgid "Are you sure? This action would reset scheduling" +msgstr "Sei sicuro? Questa azione resetterà la programmazione" + +#: views/campaigns/view.hbs:40 +msgid "Cancel" +msgstr "Annulla" + +#: views/campaigns/view.hbs:41 +msgid "Sending scheduled" +msgstr "Invio programmato" + +#: views/campaigns/view.hbs:42 views/campaigns/view.hbs:54 +msgid "Pause" +msgstr "Pausa" + +#: views/campaigns/view.hbs:43 routes/campaigns.js:253 +msgid "Sending" +msgstr "Invio in corso" + +#: views/campaigns/view.hbs:44 views/campaigns/view.hbs:48 +msgid "" +"Are you sure? This action would resume sending messages to the selected list" +msgstr "" +"Sei sicuro? Questa azione riprenderà l'invio dei messaggi alla lista " +"selzionata" + +#: views/campaigns/view.hbs:45 views/campaigns/view.hbs:49 +msgid "Are you sure? This action would reset all stats about current progress" +msgstr "" +"Sei sicuro? Questa azione resetterà tutte le statistiche riguardanti il " +"progresso attuale" + +#: views/campaigns/view.hbs:46 +msgid "Resume" +msgstr "Riprendi" + +#: views/campaigns/view.hbs:47 views/campaigns/view.hbs:51 +msgid "Reset" +msgstr "Resetta" + +#: views/campaigns/view.hbs:50 +msgid "Continue" +msgstr "Continua" + +#: views/campaigns/view.hbs:52 +msgid "" +"All messages sent! Hit \"Continue\" if you you want to send this campaign to " +"new subscribers" +msgstr "" +"Tutti i messaggi inviati! Premi \"Continua\" se vuoi inviare questa campagna " +"ai nuovi iscritti" + +#: views/campaigns/view.hbs:53 +msgid "" +"Are you sure? This action would pause sending new entries in RSS feed as " +"email messages to the selected list" +msgstr "" +"Sei sicuro? Questa azione metterà in pausa l'invio dei nuovi ingressi dal " +"feed RSS come email alla lista selezionata" + +#: views/campaigns/view.hbs:55 views/campaigns/view.hbs:59 +msgid "Campaign status:" +msgstr "Stato campagna:" + +#: views/campaigns/view.hbs:56 +msgid "ACTIVE" +msgstr "ATTIVA" + +#: views/campaigns/view.hbs:57 +msgid "" +"Are you sure? This action would start sending new entries in RSS feed as " +"email messages to the selected list" +msgstr "" +"Sei sicuro? Questa azione iniziera ad inviare i nuovi ingressi dal feed RSS " +"come email alla lista selezionata" + +#: views/campaigns/view.hbs:58 +msgid "Activate" +msgstr "Attiva" + +#: views/campaigns/view.hbs:60 +msgid "INACTIVE" +msgstr "INATTIVA" + +#: views/campaigns/view.hbs:61 +msgid "" +"This is a triggered campaign. Messages are only sent to subscribers that hit " +"some trigger that invokes this campaign" +msgstr "" +"Questa e' una campagna innescabile. I messaggi sono inviati solo agli " +"iscritti che hanno innescato questa campagna" + +#: views/campaigns/view.hbs:62 +msgid "see more" +msgstr "guarda di più" + +#: views/campaigns/view.hbs:67 +msgid "List subscribers who clicked this link" +msgstr "Lista iscritti che hanno cliccato questo link" + +#: views/campaigns/view.hbs:71 +msgid "" +"Clicks are counted as unique subscribers that clicked on a specific link or " +"on any link (in aggregated view)" +msgstr "" +"I clicks sono contati come iscritti unici che hanno cliccato un link " +"specifico o (nella vista aggregata) su di un qualsiasi link" + +#: views/campaigns/view.hbs:72 +msgid "" +"If a new entry is found from campaign feed a new subcampaign is created of " +"that entry and it will be listed here" +msgstr "" +"Se un nuovo ingresso è trovato nel feed della campagna, una nuova sotto-" +"campagna verrà creata per quella entry e sarà visualizzata ui" + +#: views/emails/password-reset-html.hbs:1 +#: views/emails/password-reset-text.hbs:1 +msgid "Change your password" +msgstr "Cambia la tua password" + +#: views/emails/password-reset-html.hbs:2 +#: views/emails/password-reset-text.hbs:2 +msgid "We have received a password change request for your Mailtrain account:" +msgstr "" +"Abbiamo ricevuto una richiesta di cambio password per il tuo account " +"Mailtrain" + +#: views/emails/password-reset-html.hbs:3 +#: views/emails/password-reset-text.hbs:3 +msgid "Reset password" +msgstr "Cambia password" + +#: views/emails/password-reset-html.hbs:4 +#: views/emails/password-reset-text.hbs:4 +msgid "" +"If you did not ask to change your password, then you can ignore this email " +"and your password will not be changed." +msgstr "" +"Se non hai chiesto tu di cambiare password, puoi ignorare questa email e la " +"tua password resterà la stessa." + +#: views/emails/rss-html.hbs:1 views/emails/stationery-html.hbs:3 +#: views/emails/stationery-text.hbs:3 +msgid "Preferences" +msgstr "Preferenze" + +#: views/emails/rss-html.hbs:2 views/emails/stationery-html.hbs:4 +#: views/emails/stationery-text.hbs:4 views/lists/forms/edit.hbs:20 +#: views/lists/subscription/edit.hbs:16 +#: views/subscription/partials/subscription-unsubscribe-form.hbs:2 +#: views/subscription/web-manage.mjml.hbs:3 +#: views/subscription/web-unsubscribe.mjml.hbs:1 +#: views/subscription/web-unsubscribe.mjml.hbs:2 routes/forms.js:223 +#: routes/lists.js:288 +msgid "Unsubscribe" +msgstr "Cancella iscrizione" + +#: views/emails/rss-html.hbs:3 views/emails/stationery-html.hbs:5 +#: views/emails/stationery-text.hbs:5 +msgid "View this email in your browser" +msgstr "Guarda questa email nel tuo browser" + +#: views/emails/stationery-html.hbs:1 views/emails/stationery-text.hbs:1 +msgid "Hey [FIRST_NAME/Customer]," +msgstr "Ciao [FIRST_NAME/Customer]," + +#: views/emails/stationery-html.hbs:2 views/emails/stationery-text.hbs:2 +msgid "Cheers," +msgstr "Ringraziandoti" + +#: views/index.hbs:1 +msgid "List Management" +msgstr "Gestione lista" + +#: views/index.hbs:2 +msgid "" +"Mailtrain allows you to easily manage even very large lists. Million " +"subscribers? Not a problem. You can add subscribers manually, through the " +"API or import from a CSV file. All lists come with support for custom fields " +"and merge tags as well." +msgstr "" +"Mailtrain ti permette di gestire facilmente grosse liste. Milioni di " +"iscritti? Nessun problema. Puoi aggiungere iscritti manualmente, via API " +"oppure importarli tramite CSV. Tutte le liste hanno la possibilità di " +"aggiungere campi personalizzati e tag di merge." + +#: views/index.hbs:3 views/index.hbs:7 views/index.hbs:10 views/index.hbs:13 +#: views/index.hbs:16 views/index.hbs:19 views/index.hbs:22 views/index.hbs:25 +#: views/index.hbs:28 +msgid "Show more" +msgstr "Guarda di più" + +#: views/index.hbs:4 views/lists/fields/create.hbs:3 +#: views/lists/fields/edit.hbs:3 views/lists/fields/fields.hbs:3 +#: views/lists/fields/fields.hbs:5 views/lists/view.hbs:6 +msgid "Custom Fields" +msgstr "Campi personalizzati" + +#: views/index.hbs:5 +msgid "" +"Text fields, numbers, drop downs or checkboxes, Mailtrain has them all. " +"Every custom field can be included in the generated newsletters through " +"merge tags." +msgstr "" +"Campi di testo, numeri, drop downs o segni di spunta, Mailtrain li " +"implementa tutti. Ogni campo personalizzato può essere incluso nella " +"newsletter generata tramite i tag di merge." + +#: views/index.hbs:6 +msgid "Mailtrain also supports custom forms." +msgstr "Mailtrain supporta form personalizzati" + +#: views/index.hbs:8 +msgid "List Segmentation" +msgstr "Segmentazione della lista" + +#: views/index.hbs:9 +msgid "" +"Send messages only to list subscribers that match predefined segmentation " +"rules. No need to create separate lists with small differences." +msgstr "" +"Invia messaggi solo agli iscritti che rientrano in una regola di " +"segmentazione predefinita. Non c'è bisogno di creare liste separate con " +"piccole differenze." + +#: views/index.hbs:11 +msgid "RSS Campaigns" +msgstr "Campagne RSS" + +#: views/index.hbs:12 +msgid "" +"Setup Mailtrain to track RSS feeds and if a new entry is detected in a feed " +"then Mailtrain auto-generates a new campaign using entry data as message " +"contents and sends it to selected subscribers." +msgstr "" +"Configura Mailtrain per tracciare i feed RSS e se viene identificato un " +"nuovo ingresso Mailtrain auto genera una nuova campagna utilizzando i dati " +"del contenuto del messaggio del feed e lo invia agli iscritti selezionati." + +#: views/index.hbs:14 +msgid "GPG Encryption" +msgstr "Crittografia GPG" + +#: views/index.hbs:15 +msgid "" +"If a list has a custom field for a GPG Public Key set then subscribers can " +"upload their GPG public key to receive encrypted messages from the list." +msgstr "" +"Se una lista ha un campo personalizzato per un set di chiave pubblica GPG " +"allora gli iscritti possono caricare la loro chiave GPG pubblica per " +"ricevere messaggi criptati dalla lista." + +#: views/index.hbs:17 +msgid "Click Stats" +msgstr "Statistiche click" + +#: views/index.hbs:18 +msgid "" +"After a campaign is sent, check individual click statistics for every link " +"included in the message." +msgstr "" +"Dopo che una campagna è stata inviata, controlla le statistiche di ogni " +"click per ogni link incluso nel messaggio." + +#: views/index.hbs:20 +msgid "Template Editors" +msgstr "Editors dei templates" + +#: views/index.hbs:21 +msgid "" +"Mailtrain ships with GrapeJS and Mosaico built in, two advanced template " +"editors. Mailtrain also offers a code editor if you prefer to handcraft the " +"HTML yourself." +msgstr "" +"Mailtrain include GrapeJS e Mosaico, due editors di template avanzati. " +"Mailtrain offre inoltre un editor di codice se preferisci scrivere tu l'HTML." + +#: views/index.hbs:23 +msgid "Send via Any Provider" +msgstr "Invia tramite qualsiasi provider" + +#: views/index.hbs:24 +msgid "" +"You can use any provider that supports SMTP protocol to send out your " +"newsletters. Bounce and complaints handling via webhooks is supported for " +"SES, SparkPost, SendGrid and Mailgun, also for Postfix and ZoneMTA." +msgstr "" +"Puoi utilizzare qualsiasi provider che supporti SMTP per inviare la tua " +"newsletter. La gestione di rimbalzi e reclami via webhooks è supportata per " +"SES, SparkPost, SendGrid, Mailgun, Postfix e ZoneMTA." + +#: views/index.hbs:26 lib/tools.js:137 +msgid "Automation" +msgstr "Automazione" + +#: views/index.hbs:27 +msgid "" +"Define automation triggers to send specific messages when a user activates " +"the trigger." +msgstr "" +"Definisci gli inneschi di automazione per l'invio di messaggi specifici " +"quando un utente innesca una azione specifica." + +#: views/layout.hbs:2 +msgid "Toggle navigation" +msgstr "Attiva navigazione" + +#: views/layout.hbs:3 +msgid "Wiki" +msgstr "Wiki" + +#: views/layout.hbs:4 +msgid "Blog" +msgstr "Blog" + +#: views/layout.hbs:5 views/users/account.hbs:2 views/users/account.hbs:3 +msgid "Account" +msgstr "Account" + +#: views/layout.hbs:6 views/settings.hbs:2 views/settings.hbs:3 +msgid "Settings" +msgstr "Impostazioni" + +#: views/layout.hbs:8 views/users/api.hbs:2 views/users/api.hbs:3 +msgid "API" +msgstr "API" + +#: views/layout.hbs:9 +msgid "Log out" +msgstr "Esci" + +#: views/layout.hbs:10 views/users/forgot.hbs:2 views/users/login.hbs:2 +#: views/users/login.hbs:3 views/users/login.hbs:9 views/users/reset.hbs:2 +msgid "Sign in" +msgstr "Log in" + +#: views/layout.hbs:11 +msgid "Self Hosted Newsletter App Built on Top of Nodemailer" +msgstr "" +"Applicazione per newsletter self hosted costruita sulla base di Nodemailer" + +#: views/layout.hbs:12 views/layout.hbs:14 +msgid "Source on GitHub" +msgstr "Sorgenti su GitHub" + +#: views/layout.hbs:13 +msgid "Subscribe to Our Newsletter" +msgstr "Iscriviti alla nostra Newsletter" + +#: views/lists/create.hbs:2 views/lists/edit.hbs:2 +#: views/lists/fields/create.hbs:2 views/lists/fields/edit.hbs:2 +#: views/lists/fields/fields.hbs:2 views/lists/forms/create.hbs:2 +#: views/lists/forms/edit.hbs:2 views/lists/forms/forms.hbs:2 +#: views/lists/lists.hbs:2 views/lists/lists.hbs:4 +#: views/lists/segments/create.hbs:2 views/lists/segments/edit.hbs:2 +#: views/lists/segments/rule-configure.hbs:2 +#: views/lists/segments/rule-create.hbs:2 views/lists/segments/rule-edit.hbs:2 +#: views/lists/segments/segments.hbs:2 views/lists/segments/view.hbs:2 +#: views/lists/subscription/add.hbs:2 views/lists/subscription/edit.hbs:2 +#: views/lists/subscription/import-failed.hbs:2 +#: views/lists/subscription/import-preview.hbs:2 +#: views/lists/subscription/import.hbs:2 views/lists/view.hbs:2 +#: lib/tools.js:125 routes/lists.js:59 +msgid "Lists" +msgstr "Liste" + +#: views/lists/create.hbs:3 views/lists/create.hbs:4 views/lists/create.hbs:13 +#: views/lists/lists.hbs:3 +msgid "Create List" +msgstr "Crea Lista" + +#: views/lists/create.hbs:6 views/lists/edit.hbs:7 +msgid "List Name" +msgstr "Nome lista" + +#: views/lists/create.hbs:9 views/lists/edit.hbs:15 +#: views/triggers/create.hbs:15 views/triggers/edit.hbs:17 +msgid "Subscription" +msgstr "Iscrizione" + +#: views/lists/create.hbs:10 views/lists/edit.hbs:16 +msgid "Allow public users to subscribe themselves" +msgstr "Permetti utenti pubblici di iscriversi da soli" + +#: views/lists/create.hbs:11 views/lists/edit.hbs:17 +msgid "Unsubscription" +msgstr "Cancellazione iscrizione" + +#: views/lists/create.hbs:12 views/lists/edit.hbs:18 +msgid "Select how an unsuscription request by subscriber is handled." +msgstr "" +"Seleziona come una richiesta di rimozione dell'iscrizione viene gestita." + +#: views/lists/edit.hbs:3 views/lists/edit.hbs:4 views/lists/view.hbs:8 +msgid "Edit List" +msgstr "Modifica lista" + +#: views/lists/edit.hbs:5 +msgid "View List" +msgstr "Guarda Lista" + +#: views/lists/edit.hbs:8 +msgid "List ID" +msgstr "ID lista" + +#: views/lists/edit.hbs:9 +msgid "This is the list ID displayed to the subscribers" +msgstr "Questo è l'ID della lista mostrato agli iscritti" + +#: views/lists/edit.hbs:12 +msgid "Custom Form" +msgstr "Form personalizzato" + +#: views/lists/edit.hbs:13 views/lists/forms/forms.hbs:11 +msgid "Default Mailtrain Form" +msgstr "Form predefinito di Mailtrain" + +#: views/lists/edit.hbs:14 +msgid "" +"The custom form used for this list. You can create a form here." +msgstr "" +"Il form personalizzato per questa lista. Puoi creare un form qui." + +#: views/lists/edit.hbs:19 +msgid "Delete List" +msgstr "Cancella lista" + +#: views/lists/fields/create.hbs:4 +msgid "Create Field" +msgstr "Crea campo" + +#: views/lists/fields/create.hbs:5 views/lists/fields/fields.hbs:4 +msgid "Create Custom Field" +msgstr "Crea campo personalizzato" + +#: views/lists/fields/create.hbs:6 views/lists/fields/create.hbs:7 +#: views/lists/fields/edit.hbs:7 views/lists/fields/edit.hbs:8 +msgid "Field Name" +msgstr "Nome campo" + +#: views/lists/fields/create.hbs:8 views/lists/fields/edit.hbs:9 +msgid "Field Type" +msgstr "Tipo campo" + +#: views/lists/fields/create.hbs:9 views/lists/fields/edit.hbs:10 +#: lib/models/fields.js:17 +msgid "Text" +msgstr "Testo" + +#: views/lists/fields/create.hbs:10 views/lists/fields/edit.hbs:11 +#: lib/models/fields.js:21 +msgid "Number" +msgstr "Numero" + +#: views/lists/fields/create.hbs:11 views/lists/fields/edit.hbs:12 +#: lib/models/fields.js:18 +msgid "Website" +msgstr "Sito web" + +#: views/lists/fields/create.hbs:12 views/lists/fields/edit.hbs:13 +#: lib/models/fields.js:20 +msgid "GPG Public Key" +msgstr "Chiave pubblica GPG" + +#: views/lists/fields/create.hbs:13 views/lists/fields/edit.hbs:14 +#: lib/models/fields.js:19 +msgid "Multi-line text" +msgstr "Testo multi linea" + +#: views/lists/fields/create.hbs:14 views/lists/fields/edit.hbs:15 +msgid "JSON" +msgstr "JSON" + +#: views/lists/fields/create.hbs:15 views/lists/fields/edit.hbs:16 +msgid "Date" +msgstr "Data" + +#: views/lists/fields/create.hbs:16 views/lists/fields/edit.hbs:17 +msgid "Date (MM/DD/YYYY)" +msgstr "Data (MM/GG/ANNO)" + +#: views/lists/fields/create.hbs:17 views/lists/fields/edit.hbs:18 +#: lib/models/fields.js:26 +msgid "Date (DD/MM/YYYY)" +msgstr "Data (GG/MM/ANNO)" + +#: views/lists/fields/create.hbs:18 views/lists/fields/edit.hbs:19 +msgid "Birthday" +msgstr "Compleanno" + +#: views/lists/fields/create.hbs:19 views/lists/fields/edit.hbs:20 +#: lib/models/fields.js:27 +msgid "Birthday (MM/DD)" +msgstr "Compleanno (MM/GG)" + +#: views/lists/fields/create.hbs:20 views/lists/fields/edit.hbs:21 +#: lib/models/fields.js:28 +msgid "Birthday (DD/MM)" +msgstr "Compleanno (GG/MM)" + +#: views/lists/fields/create.hbs:21 views/lists/fields/edit.hbs:22 +msgid "Grouped" +msgstr "Raggruppati" + +#: views/lists/fields/create.hbs:22 views/lists/fields/edit.hbs:23 +msgid "Drop Downs" +msgstr "Drop Downs" + +#: views/lists/fields/create.hbs:23 views/lists/fields/edit.hbs:24 +#: lib/models/fields.js:22 +msgid "Radio Buttons" +msgstr "Radio Buttons" + +#: views/lists/fields/create.hbs:24 views/lists/fields/edit.hbs:25 +#: lib/models/fields.js:23 +msgid "Checkboxes" +msgstr "Checkboxes" + +#: views/lists/fields/create.hbs:25 views/lists/fields/edit.hbs:26 +msgid "Option for a group value" +msgstr "Option for group value" + +#: views/lists/fields/create.hbs:26 views/lists/fields/edit.hbs:27 +msgid "Group" +msgstr "Group" + +#: views/lists/fields/create.hbs:28 views/lists/fields/edit.hbs:29 +msgid "Required for group options" +msgstr "Richiesto per le group options" + +#: views/lists/fields/create.hbs:29 views/lists/fields/create.hbs:30 +#: views/lists/fields/edit.hbs:35 views/lists/fields/edit.hbs:36 +#: views/lists/fields/fields.hbs:9 +msgid "Default merge tag value" +msgstr "Valore di merge tag di default" + +#: views/lists/fields/create.hbs:32 views/lists/fields/edit.hbs:34 +msgid "" +"For group elements like checkboxes you can control the appearance of the " +"merge tag with an optional template. The template uses handlebars syntax and " +"you can find all values from {{values}} array, for example " +"{{#each values}} {{this}} {{/each}}. If template is not defined " +"then multiple values are joined with commas. You can also use this template " +"to render JSON values (if the JSON is an array then the array is exposed as " +"values, otherwise you can access the JSON keys directly)." +msgstr "" +"Per i gruppi di elementi come i checkboxes, puoi controllare l'aspetto " +"visivo del merge tag con un template opzionale. Il template usa la sintassi " +"di handlebars e puoi trovare tutti i valori dall'array {{values}}, per esempio {{#each values}} {{this}} {{/each}}. Se il " +"template non è definito allora i valori multipli vengono uniti dalla " +"virgola. Puoi anche utilizzare questo template per visualizzare valori JSON " +"(se il valore JSON è un array allora l'array viene esposto come " +"values, altrimenti puoi accedere direttamente alle keys del " +"JSON)." + +#: views/lists/fields/create.hbs:33 views/lists/fields/edit.hbs:37 +msgid "Visible" +msgstr "Visibile" + +#: views/lists/fields/create.hbs:34 +msgid "Add Field" +msgstr "Aggiungi campo" + +#: views/lists/fields/edit.hbs:4 +msgid "Edit Field" +msgstr "Modifica campo" + +#: views/lists/fields/edit.hbs:5 +msgid "Edit Custom Field" +msgstr "Modifica campo personalizzato" + +#: views/lists/fields/edit.hbs:6 +msgid "Back to fields" +msgstr "Indietro ai campi" + +#: views/lists/fields/edit.hbs:30 views/lists/fields/fields.hbs:8 +#: views/mosaico/editor.hbs:2 views/partials/merge-tag-reference.hbs:3 +msgid "Merge tag" +msgstr "Merge tag" + +#: views/lists/fields/edit.hbs:31 +msgid "Merge Tag" +msgstr "Merge Tag" + +#: views/lists/fields/edit.hbs:32 +msgid "Put this tag in your content:" +msgstr "Metti questo tag nel tuo contenuto:" + +#: views/lists/fields/edit.hbs:38 +msgid "Delete Field" +msgstr "Elimina campo" + +#: views/lists/fields/fields.hbs:7 views/lists/view.hbs:26 +#: views/report-templates/partials/report-template-fields.hbs:5 +msgid "Type" +msgstr "Tipo" + +#: views/lists/fields/fields.hbs:10 views/lists/fields/fields.hbs:11 +#: views/lists/forms/edit.hbs:26 views/lists/forms/forms.hbs:8 +#: views/lists/segments/segments.hbs:8 views/lists/segments/view.hbs:12 +#: views/triggers/triggers.hbs:14 routes/campaigns.js:276 +#: routes/campaigns.js:568 routes/campaigns.js:657 routes/campaigns.js:706 +#: routes/lists.js:170 routes/lists.js:257 routes/report-templates.js:51 +#: routes/templates.js:183 routes/triggers.js:297 +msgid "Edit" +msgstr "Modifica" + +#: views/lists/forms/create.hbs:3 views/lists/forms/edit.hbs:3 +#: views/lists/forms/forms.hbs:3 views/lists/forms/forms.hbs:5 +#: views/lists/view.hbs:5 +msgid "Custom Forms" +msgstr "Form personalizzati" + +#: views/lists/forms/create.hbs:4 +msgid "Create Form" +msgstr "Crea form" + +#: views/lists/forms/create.hbs:5 views/lists/forms/forms.hbs:4 +msgid "Create Custom Form" +msgstr "Crea form personalizzato" + +#: views/lists/forms/create.hbs:6 views/lists/forms/create.hbs:7 +#: views/lists/forms/edit.hbs:7 views/lists/forms/edit.hbs:8 +msgid "Form Name" +msgstr "Nome form" + +#: views/lists/forms/create.hbs:8 +msgid "Add Form" +msgstr "Aggiungi form" + +#: views/lists/forms/edit.hbs:4 +msgid "Edit Form" +msgstr "Modifica Form" + +#: views/lists/forms/edit.hbs:5 +msgid "Edit Custom Form" +msgstr "Modifica form personalizzato" + +#: views/lists/forms/edit.hbs:6 +msgid "Back to forms" +msgstr "Indietro ai forms" + +#: views/lists/forms/edit.hbs:10 +msgid "Optional comments about this form" +msgstr "Commenti opzionali per questo form" + +#: views/lists/forms/edit.hbs:11 +msgid "Form Preview" +msgstr "Anteprima Form" + +#: views/lists/forms/edit.hbs:12 +msgid "" +"Note: These links are solely for a quick preview. If you submit a preview " +"form you'll get redirected to the list's default form." +msgstr "" +"Nota: Questi links sono solo per un'anteprima veloce. Se confermi l'invio di " +"un form in anteprima verrai rediretto al form di default della lista." + +#: views/lists/forms/edit.hbs:13 views/lists/subscription/add.hbs:16 +#: views/subscription/mail-unsubscription-confirmed-html.mjml.hbs:4 +#: views/subscription/mail-unsubscription-confirmed-text.hbs:4 +#: routes/forms.js:157 routes/lists.js:288 +msgid "Subscribe" +msgstr "Iscriviti" + +#: views/lists/forms/edit.hbs:14 +msgid "Confirm Subscription Notice" +msgstr "Notifica iscrizione confermata" + +#: views/lists/forms/edit.hbs:15 +msgid "Confirm Unsubscription Notice" +msgstr "Conferma notifica di cancellazione iscrizione" + +#: views/lists/forms/edit.hbs:16 +msgid "Subscribed Notice" +msgstr "Notifica iscrizione" + +#: views/lists/forms/edit.hbs:17 +msgid "Updated Notice" +msgstr "Notifica di aggiornamento" + +#: views/lists/forms/edit.hbs:18 +msgid "Unsubscribed Notice" +msgstr "Notifica di cancellazione di iscrizione" + +#: views/lists/forms/edit.hbs:19 +msgid "Manual Unsubscribe Notice" +msgstr "Notifica di cancellazione iscrizione manuale" + +#: views/lists/forms/edit.hbs:21 routes/forms.js:205 +msgid "Manage" +msgstr "Gestisci" + +#: views/lists/forms/edit.hbs:22 +msgid "Manage Address" +msgstr "Gestisci indirizzo" + +#: views/lists/forms/edit.hbs:23 +msgid "Create a test user for additional options" +msgstr "Crea un utente di test per le opzioni aggiuntive" + +#: views/lists/forms/edit.hbs:24 views/report-templates/create.hbs:3 +#: views/report-templates/edit.hbs:3 +#: views/report-templates/report-templates.hbs:3 views/templates/create.hbs:2 +#: views/templates/edit.hbs:2 views/templates/templates.hbs:2 +#: views/templates/templates.hbs:4 lib/tools.js:129 routes/templates.js:27 +msgid "Templates" +msgstr "Templates" + +#: views/lists/forms/edit.hbs:25 +msgid "Fields" +msgstr "Campi" + +#: views/lists/forms/edit.hbs:27 +msgid "Form Fields" +msgstr "Campi del form" + +#: views/lists/forms/edit.hbs:28 +msgid "Fields hidden on subscription page:" +msgstr "Campi nascosti sulla pagina di iscrizione:" + +#: views/lists/forms/edit.hbs:29 +msgid "Fields shown on subscription page:" +msgstr "Campi mostrati sulla pagina di iscrizione:" + +#: views/lists/forms/edit.hbs:30 +msgid "Fields hidden on preferences page:" +msgstr "Campi nascosti sulla pagina delle preferenze:" + +#: views/lists/forms/edit.hbs:31 +msgid "Fields shown on preferences page:" +msgstr "Campi mostrati sulla pagina delle preferenze:" + +#: views/lists/forms/edit.hbs:32 +msgid "Delete Form" +msgstr "Cancella form" + +#: views/lists/forms/forms.hbs:10 +msgid "The default form for this list is:" +msgstr "Il form di default per questa lista:" + +#: views/lists/lists.hbs:6 +msgid "ID" +msgstr "ID" + +#: views/lists/lists.hbs:7 views/reports/partials/report-fields.hbs:10 +msgid "Subscribers" +msgstr "Iscritti" + +#: views/lists/segments/create.hbs:3 views/lists/segments/edit.hbs:3 +#: views/lists/segments/rule-configure.hbs:3 +#: views/lists/segments/rule-create.hbs:3 views/lists/segments/rule-edit.hbs:3 +#: views/lists/segments/segments.hbs:3 views/lists/segments/segments.hbs:5 +#: views/lists/segments/view.hbs:3 views/lists/view.hbs:7 +#: views/lists/view.hbs:14 +msgid "Segments" +msgstr "Segmenti" + +#: views/lists/segments/create.hbs:4 views/lists/segments/create.hbs:5 +#: views/lists/segments/rule-configure.hbs:4 +#: views/lists/segments/rule-create.hbs:4 views/lists/segments/rule-edit.hbs:4 +#: views/lists/segments/segments.hbs:4 +msgid "Create Segment" +msgstr "Crea segmento" + +#: views/lists/segments/create.hbs:6 views/lists/segments/create.hbs:7 +#: views/lists/segments/edit.hbs:7 views/lists/segments/edit.hbs:8 +msgid "Segment Name" +msgstr "Nome segmento" + +#: views/lists/segments/create.hbs:8 views/lists/segments/edit.hbs:9 +msgid "Rule match" +msgstr "Regola di corrispondenza" + +#: views/lists/segments/create.hbs:10 views/lists/segments/edit.hbs:11 +msgid "All rules must match" +msgstr "Tutte le regole devono corrispondere con" + +#: views/lists/segments/create.hbs:11 views/lists/segments/edit.hbs:12 +msgid "Any rule can match" +msgstr "Qualsiasi regola può corrispondere con" + +#: views/lists/segments/create.hbs:12 +msgid "Add Segment" +msgstr "Aggiungi segmento" + +#: views/lists/segments/edit.hbs:4 views/lists/segments/edit.hbs:5 +#: views/lists/segments/view.hbs:6 views/lists/view.hbs:12 +msgid "Edit Segment" +msgstr "Modifica segmento" + +#: views/lists/segments/edit.hbs:6 +msgid "Back to segments" +msgstr "Indietro ai segmenti" + +#: views/lists/segments/edit.hbs:13 +msgid "Delete Segment" +msgstr "Elimina segmento" + +#: views/lists/segments/rule-configure.hbs:5 +#: views/lists/segments/rule-create.hbs:5 views/lists/segments/rule-edit.hbs:5 +#: views/lists/segments/view.hbs:4 +msgid "Create Rule" +msgstr "Crea regola" + +#: views/lists/segments/rule-configure.hbs:6 +#: views/lists/segments/rule-create.hbs:6 views/lists/segments/rule-edit.hbs:6 +#: views/lists/segments/view.hbs:10 +msgid "Rule" +msgstr "Regola" + +#: views/lists/segments/rule-configure.hbs:7 +#: views/lists/segments/rule-configure.hbs:8 +#: views/lists/segments/rule-configure.hbs:10 +#: views/lists/segments/rule-configure.hbs:13 +#: views/lists/segments/rule-configure.hbs:25 +#: views/lists/segments/rule-configure.hbs:30 +#: views/lists/segments/rule-edit.hbs:7 views/lists/segments/rule-edit.hbs:8 +#: views/lists/segments/rule-edit.hbs:10 views/lists/segments/rule-edit.hbs:15 +#: views/lists/segments/rule-edit.hbs:29 views/lists/segments/rule-edit.hbs:34 +#: views/lists/segments/view.hbs:11 +msgid "Value" +msgstr "Valore" + +#: views/lists/segments/rule-configure.hbs:9 +#: views/lists/segments/rule-edit.hbs:9 +msgid "" +"Use % for wildcard character, e.g. \"%test\" to match all values that end " +"with \"test\"" +msgstr "" +"Usa % come carattere jolly, per esempio \"%test\" fa passare tutti i valori " +"che finiscono con \"test\"" + +#: views/lists/segments/rule-configure.hbs:11 +#: views/lists/segments/rule-configure.hbs:14 +#: views/lists/segments/rule-configure.hbs:26 +#: views/lists/segments/rule-edit.hbs:11 views/lists/segments/rule-edit.hbs:16 +#: views/lists/segments/rule-edit.hbs:30 +msgid "Use exact match" +msgstr "Usa corrispondenza esatta" + +#: views/lists/segments/rule-configure.hbs:12 +#: views/lists/segments/rule-configure.hbs:15 +#: views/lists/segments/rule-configure.hbs:27 +#: views/lists/segments/rule-edit.hbs:12 views/lists/segments/rule-edit.hbs:17 +#: views/lists/segments/rule-edit.hbs:31 +msgid "Use range match" +msgstr "Usa range di corrispondenza" + +#: views/lists/segments/rule-configure.hbs:16 +#: views/lists/segments/rule-edit.hbs:20 +msgid "Use relative range match" +msgstr "Usa range di corrispondenza relativo" + +#: views/lists/segments/rule-configure.hbs:17 +#: views/lists/segments/rule-configure.hbs:28 +#: views/lists/segments/rule-edit.hbs:13 views/lists/segments/rule-edit.hbs:18 +#: views/lists/segments/rule-edit.hbs:21 views/lists/segments/rule-edit.hbs:32 +msgid "From" +msgstr "Da" + +#: views/lists/segments/rule-configure.hbs:18 +#: views/lists/segments/rule-configure.hbs:22 +#: views/lists/segments/rule-edit.hbs:22 views/lists/segments/rule-edit.hbs:26 +msgid "days" +msgstr "giorni" + +#: views/lists/segments/rule-configure.hbs:19 +#: views/lists/segments/rule-configure.hbs:23 +#: views/lists/segments/rule-edit.hbs:23 views/lists/segments/rule-edit.hbs:27 +msgid "before today" +msgstr "prima di oggi" + +#: views/lists/segments/rule-configure.hbs:20 +#: views/lists/segments/rule-configure.hbs:24 +#: views/lists/segments/rule-edit.hbs:24 views/lists/segments/rule-edit.hbs:28 +msgid "after today" +msgstr "dopo di oggi" + +#: views/lists/segments/rule-configure.hbs:21 +#: views/lists/segments/rule-configure.hbs:29 +#: views/lists/segments/rule-edit.hbs:14 views/lists/segments/rule-edit.hbs:19 +#: views/lists/segments/rule-edit.hbs:25 views/lists/segments/rule-edit.hbs:33 +msgid "to" +msgstr "a" + +#: views/lists/segments/rule-configure.hbs:31 +#: views/lists/segments/rule-edit.hbs:35 lib/models/segments.js:156 +#: lib/models/segments.js:418 +msgid "Selected" +msgstr "Selezionati" + +#: views/lists/segments/rule-configure.hbs:32 +#: views/lists/segments/rule-edit.hbs:36 lib/models/segments.js:156 +#: lib/models/segments.js:418 +msgid "Not selected" +msgstr "Non selezionati" + +#: views/lists/segments/rule-configure.hbs:33 +msgid "Add Rule" +msgstr "Aggiungi regola" + +#: views/lists/segments/rule-create.hbs:8 +#: views/lists/subscription/import.hbs:18 +#: views/reports/create-select-template.hbs:5 +#: views/triggers/create-select.hbs:9 +msgid "Next" +msgstr "Avanti" + +#: views/lists/segments/rule-edit.hbs:37 +msgid "Delete Rule" +msgstr "Cancella regola" + +#: views/lists/segments/segments.hbs:7 +msgid "Match" +msgstr "Corrispondi" + +#: views/lists/segments/view.hbs:5 views/lists/view.hbs:13 +msgid "Segment" +msgstr "Segmento" + +#: views/lists/segments/view.hbs:7 +msgid "Match rules" +msgstr "Corrisponde alla regola" + +#: views/lists/segments/view.hbs:8 +msgid "Matching subscribers" +msgstr "Iscritti corrispondenti" + +#: views/lists/segments/view.hbs:9 +msgid "show" +msgstr "mostra" + +#: views/lists/subscription/add.hbs:3 views/lists/subscription/add.hbs:4 +msgid "Add subscriber" +msgstr "Aggiungi iscritto" + +#: views/lists/subscription/add.hbs:5 +#: views/subscription/partials/subscription-custom-fields.hbs:1 +#: views/users/account.hbs:7 +msgid "Email Address" +msgstr "Indirizzo Email" + +#: views/lists/subscription/add.hbs:8 views/lists/subscription/edit.hbs:9 +#: views/settings.hbs:80 views/settings.hbs:95 +#: views/subscription/partials/subscription-custom-fields.hbs:6 +msgid "Begins with" +msgstr "Inizia con" + +#: views/lists/subscription/add.hbs:9 views/lists/subscription/edit.hbs:10 +msgid "" +"Insert a GPG public key that will be used to encrypt messages sent this " +"subscriber" +msgstr "" +"Inserisci chiave pubblica GPG che verrà usata per crittografare i messaggi " +"per questo iscritto" + +#: views/lists/subscription/add.hbs:11 views/lists/subscription/edit.hbs:12 +#: views/lists/subscription/import-preview.hbs:9 +msgid "Timezone" +msgstr "Fuso orario" + +#: views/lists/subscription/add.hbs:13 views/lists/subscription/edit.hbs:13 +msgid "Test user?" +msgstr "Utente di test?" + +#: views/lists/subscription/add.hbs:14 views/lists/subscription/edit.hbs:14 +msgid "" +"If checked then this subscription can be used for previewing campaign " +"messages" +msgstr "" +"Se selezionato, questa iscrizione può essere usata per l'anteprima dei " +"messaggi della campagna" + +#: views/lists/subscription/add.hbs:15 +msgid "" +"This person will not receive a confirmation email so make sure that you have " +"permission to email them." +msgstr "" +"Questa persona non riceverà una email di conferma, quindi assicurati di " +"avere il permesso di inviargli emails." + +#: views/lists/subscription/edit.hbs:3 views/lists/subscription/edit.hbs:4 +msgid "Edit subscriber" +msgstr "Modifica iscrizione" + +#: views/lists/subscription/edit.hbs:5 +#: views/lists/subscription/import-failed.hbs:5 +msgid "Back to list" +msgstr "Indietro alla lista" + +#: views/lists/subscription/edit.hbs:6 +#: views/lists/subscription/import-preview.hbs:6 +#: views/subscription/partials/subscription-unsubscribe-form.hbs:1 +#: lib/helpers.js:42 lib/models/segments.js:11 +msgid "Email address" +msgstr "Indirizzo email" + +#: views/lists/subscription/edit.hbs:17 +msgid "Delete Subscription" +msgstr "Elimina iscrizione" + +#: views/lists/subscription/import-failed.hbs:3 +msgid "Import status" +msgstr "Stato dell' Import" + +#: views/lists/subscription/import-failed.hbs:4 +msgid "Failed addresses" +msgstr "Indiirizzi falliti" + +#: views/lists/subscription/import-failed.hbs:6 +msgid "" +"Role-based addresses like postmaster@example.com are blocked when importing. " +"Subscribers with role-based email addresses can join your list using the " +"subscription form" +msgstr "" +"Gli indirizzi di ruolo come postmaster@example.com sono bloccati durante " +"l'import. Questi indirizzi possono iscriversi alla tua lista con il form di " +"iscrizione online." + +#: views/lists/subscription/import-failed.hbs:7 +msgid "see here" +msgstr "guarda qui" + +#: views/lists/subscription/import-failed.hbs:9 +msgid "Fail reason" +msgstr "Motivo di errore" + +#: views/lists/subscription/import-preview.hbs:3 +#: views/lists/subscription/import-preview.hbs:4 +#: views/lists/subscription/import.hbs:3 views/lists/subscription/import.hbs:4 +msgid "Import subscribers" +msgstr "Importa iscritti" + +#: views/lists/subscription/import-preview.hbs:10 views/users/api.hbs:21 +#: views/users/api.hbs:36 views/users/api.hbs:44 views/users/api.hbs:52 +#: views/users/api.hbs:64 views/users/api.hbs:75 views/users/api.hbs:83 +#: views/users/api.hbs:91 views/users/api.hbs:96 +msgid "Example" +msgstr "Esempio" + +#: views/lists/subscription/import-preview.hbs:11 +msgid "Start import" +msgstr "Inizia import" + +#: views/lists/subscription/import.hbs:5 +msgid "CSV File" +msgstr "File CSV" + +#: views/lists/subscription/import.hbs:6 +msgid "The first line must contain column headings" +msgstr "La prima linea deve contenere le intestazioni di colonna" + +#: views/lists/subscription/import.hbs:7 +msgid "CSV delimiter" +msgstr "Delimitatore file CSV" + +#: views/lists/subscription/import.hbs:8 +msgid "Categorize the imported subscribers as" +msgstr "Categorizza gli iscritti importati come" + +#: views/lists/subscription/import.hbs:9 routes/lists.js:206 +msgid "Subscribed" +msgstr "Iscritto" + +#: views/lists/subscription/import.hbs:10 +msgid "Regular subscriber addresses" +msgstr "Indirizzi regolari degli iscritti" + +#: views/lists/subscription/import.hbs:11 +msgid "Subscribed (Force)" +msgstr "Iscrizione (Forzata)" + +#: views/lists/subscription/import.hbs:12 +msgid "Regular subscriber addresses, resubscribe users that have unsubscribed" +msgstr "" +"Indirizzi regolari degli utenti registrati, riscrizione utenti che hanno " +"cancellato l'iscrizione" + +#: views/lists/subscription/import.hbs:14 +msgid "Suppressed emails that will be unsubscribed from your list" +msgstr "Email soppresse che saranno cancellate dalla tua lista" + +#: views/lists/subscription/import.hbs:15 +msgid "Check imported emails" +msgstr "Controlla le emails importate" + +#: views/lists/subscription/import.hbs:16 views/triggers/triggers.hbs:12 +msgid "Enabled" +msgstr "Abilitato" + +#: views/lists/subscription/import.hbs:17 views/triggers/triggers.hbs:13 +msgid "Disabled" +msgstr "Disabilitato" + +#: views/lists/view.hbs:3 +msgid "Subscription Form" +msgstr "Form di iscrizione" + +#: views/lists/view.hbs:4 +msgid "List Actions" +msgstr "Lista azioni" + +#: views/lists/view.hbs:9 views/triggers/create-select.hbs:3 +#: views/triggers/create-select.hbs:4 views/triggers/create.hbs:3 +#: views/triggers/create.hbs:4 views/triggers/create.hbs:27 +#: views/triggers/triggers.hbs:3 +msgid "Create Trigger" +msgstr "Crea innesco" + +#: views/lists/view.hbs:10 +msgid "Add Subscriber" +msgstr "Aggiungi iscrizione" + +#: views/lists/view.hbs:11 +msgid "Import Subscribers" +msgstr "Importa iscrizioni" + +#: views/lists/view.hbs:15 +msgid "Create New Segment" +msgstr "Crea nuovo segmento" + +#: views/lists/view.hbs:16 +msgid "Filter" +msgstr "Filtra" + +#: views/lists/view.hbs:17 +msgid "Subscriptions" +msgstr "Iscrizioni" + +#: views/lists/view.hbs:18 +msgid "Imports" +msgstr "Importazioni" + +#: views/lists/view.hbs:25 routes/campaigns.js:255 routes/lists.js:300 +msgid "Finished" +msgstr "Finito" + +#: views/lists/view.hbs:27 +msgid "Added" +msgstr "Aggiunto" + +#: views/lists/view.hbs:28 +msgid "Updated" +msgstr "Aggiornato" + +#: views/lists/view.hbs:29 +msgid "Failed" +msgstr "Errore" + +#: views/lists/view.hbs:31 +msgid "" +"Are you sure? This action should only be called to resolve stalled imports" +msgstr "" +"Sei sicuro? Questa azione deve essere chiamata solo per risolvere " +"importazioni in stato di stallo" + +#: views/lists/view.hbs:32 +msgid "Restart" +msgstr "Riavvia" + +#: views/mosaico/editor.hbs:1 views/partials/merge-tag-reference.hbs:1 +msgid "Merge tag reference" +msgstr "Referenza dei tag di merge" + +#: views/mosaico/editor.hbs:4 +msgid "MOSAICO Responsive Email Designer" +msgstr "MOSAICO REsponsive Email Designer" + +#: views/mosaico/editor.hbs:5 +msgid "Sucessfully saved" +msgstr "Salvato con successo" + +#: views/mosaico/editor.hbs:6 +msgid "An error occured while saving the document" +msgstr "Errore durante il salvataggio del documento" + +#: views/mosaico/editor.hbs:7 +msgid "Unsaved changes will be lost. Close now?" +msgstr "Le modifiche non salvate andranno perdute, Chiudere ora?" + +#: views/mosaico/editor.hbs:8 views/mosaico/editor.hbs:9 +msgid "Tags" +msgstr "Tags" + +#: views/partials/codeeditor.hbs:1 views/partials/grapejs.hbs:1 +#: views/partials/mosaico.hbs:1 views/partials/summernote.hbs:1 +msgid "Template content (HTML)" +msgstr "Contenuto template (HTML)" + +#: views/partials/editor-navbar.hbs:1 +msgid "SAVE" +msgstr "SALVA" + +#: views/partials/editor-navbar.hbs:2 +msgid "SAVING" +msgstr "STO SALVANDO" + +#: views/partials/editor-navbar.hbs:3 +msgid "CLOSE" +msgstr "CHIUDI" + +#: views/partials/grapejs.hbs:2 +msgid "Open GrapeJS" +msgstr "Apri GrapeJS" + +#: views/partials/html-preview.hbs:1 +msgid "Toggle HTML preview" +msgstr "Attiva anteprima HTML" + +#: views/partials/html-to-text.hbs:1 +msgid "" +"To extract the text from HTML click here." +msgstr "" +"Per estrarre il testo dal codice HTML clicca qui." + +#: views/partials/html-to-text.hbs:2 +msgid "" +"Please note that your existing plaintext in the field above will be " +"overwritten. This feature uses the Premailer API, a third party " +"service. Their Terms of Service and Privacy Policy apply." +msgstr "" +"Per favore nota che il tuo testo nel campo qui sopra verrà sovrascritto. " +"Questa caratteristica usa le Premailer API, un servizio di " +"terzi. I loro Termini per il servizio e la loro Privacy Policy è applicato." + +#: views/partials/html-to-text.hbs:3 +msgid "An error occurred while talking to the server" +msgstr "C'è stato un errore nel comunicare con il server" + +#: views/partials/merge-tag-reference.hbs:2 +msgid "" +"Merge tags are tags that are replaced before sending out the message. The " +"format of the merge tag is the following: [TAG_NAME] or " +"[TAG_NAME/fallback] where fallback is an optional " +"text value used when TAG_NAME is empty." +msgstr "" +"Merge tags sono tags che sono sostituiti prima dell'invio del messaggio. Il " +"formato del merge tag è il seguente [TAG_NAME] oppure " +"[TAG_NAME/fallback] dove fallback è un valore " +"opzionale di testo utilizzato quando TAG_NAME è vuoto." + +#: views/partials/modal-carousel.hbs:1 +msgid "{{title}}" +msgstr "{{}}" + +#: views/partials/mosaico.hbs:2 +msgid "Open Mosaico" +msgstr "Apri Mosaico" + +#: views/partials/plaintext.hbs:1 +msgid "Template content (plaintext)" +msgstr "Contenuto del template (test semplice)" + +#: views/report-templates/create.hbs:2 views/report-templates/edit.hbs:2 +#: views/report-templates/report-templates.hbs:2 +#: views/reports/create-select-template.hbs:2 views/reports/create.hbs:2 +#: views/reports/edit.hbs:2 views/reports/output.hbs:2 +#: views/reports/reports.hbs:2 views/reports/reports.hbs:5 +#: views/reports/view.hbs:2 lib/tools.js:144 routes/reports.js:31 +msgid "Reports" +msgstr "Reports" + +#: views/report-templates/create.hbs:4 views/report-templates/create.hbs:6 +#: views/report-templates/report-templates.hbs:4 views/templates/create.hbs:3 +#: views/templates/create.hbs:4 views/templates/create.hbs:12 +#: views/templates/templates.hbs:3 +msgid "Create Template" +msgstr "Crea template" + +#: views/report-templates/create.hbs:5 routes/report-templates.js:231 +msgid "Create Report Template" +msgstr "Crea Template di report" + +#: views/report-templates/edit.hbs:4 views/templates/edit.hbs:3 +#: views/templates/edit.hbs:4 +msgid "Edit Template" +msgstr "Modifica Template" + +#: views/report-templates/edit.hbs:5 routes/report-templates.js:262 +msgid "Edit Report Template" +msgstr "Modifica template report" + +#: views/report-templates/edit.hbs:6 views/templates/edit.hbs:12 +msgid "Delete Template" +msgstr "Elimina template" + +#: views/report-templates/edit.hbs:7 +msgid "Update and Stay" +msgstr "Salva e continua" + +#: views/report-templates/edit.hbs:8 +msgid "Update and Leave" +msgstr "Salva ed esci" + +#: views/report-templates/partials/report-template-fields.hbs:2 +msgid "Template Name" +msgstr "Nome template" + +#: views/report-templates/partials/report-template-fields.hbs:6 +msgid "User selectable fields" +msgstr "Campi selezionabili dagli utenti" + +#: views/report-templates/partials/report-template-fields.hbs:7 +msgid "Data processing code" +msgstr "Codice che processa data" + +#: views/report-templates/partials/report-template-fields.hbs:8 +msgid "Rendering template" +msgstr "Template di rendering" + +#: views/report-templates/report-templates.hbs:5 +msgid "Blank" +msgstr "Vuoto" + +#: views/report-templates/report-templates.hbs:6 +msgid "All Subscribers" +msgstr "Tutti gli iscritti" + +#: views/report-templates/report-templates.hbs:7 +msgid "Grouped Subscribers" +msgstr "Iscritti raggruppati" + +#: views/report-templates/report-templates.hbs:8 +msgid "Export List as CSV" +msgstr "Esporta lista come CSV" + +#: views/report-templates/report-templates.hbs:9 views/reports/reports.hbs:4 +#: routes/report-templates.js:29 +msgid "Report Templates" +msgstr "Templates di report" + +#: views/reports/create-select-template.hbs:3 +#: views/reports/create-select-template.hbs:4 views/reports/create.hbs:3 +#: views/reports/create.hbs:4 views/reports/create.hbs:5 +#: views/reports/reports.hbs:3 routes/reports.js:81 +msgid "Create Report" +msgstr "Crea report" + +#: views/reports/edit.hbs:3 views/reports/edit.hbs:4 routes/reports.js:151 +msgid "Edit Report" +msgstr "Modifica Report" + +#: views/reports/edit.hbs:5 +msgid "Delete Report" +msgstr "Elimina report" + +#: views/reports/partials/report-fields.hbs:2 +msgid "Report Name" +msgstr "Nome report" + +#: views/reports/partials/report-fields.hbs:8 +#: views/reports/partials/report-fields.hbs:11 +msgid "" +"Select a campaign in the table above by clicking on the respective row " +"number." +msgstr "" +"Seleziona una campagna nella tabella qui sopra cliccando sul numero della " +"riga." + +#: views/reports/partials/report-select-template.hbs:1 +msgid "Report Template" +msgstr "Template del report" + +#: views/settings.hbs:5 +msgid "Service Address (URL)" +msgstr "Indirizzo del servizio (URL)" + +#: views/settings.hbs:6 +msgid "Enter the URL this service can be reached from" +msgstr "Inserisci l'URL a cui puoi accedere a questo servizio" + +#: views/settings.hbs:7 +msgid "Admin Email" +msgstr "Email amministratore" + +#: views/settings.hbs:8 +msgid "" +"Enter the email address that will be used as \"from\" for system messages" +msgstr "" +"Inserisci l'indirizzo mail che verra' utilizzato nel campo \"Da\" per i " +"messaggi di sistemi" + +#: views/settings.hbs:9 +msgid "Disable WYSIWYG editor" +msgstr "Disabilita l'editor avanzato WYSIWYG" + +#: views/settings.hbs:10 +msgid "If checked then message editor displays HTML code without the preview" +msgstr "" +"Se selezionato l'editor del messaggio visualizza il codice HTML senza " +"anteprima" + +#: views/settings.hbs:11 +msgid "Disable subscription confirmation messages" +msgstr "Disabilita i messaggi di conferma iscrizione" + +#: views/settings.hbs:12 +msgid "" +"If checked then do not send a confirmation message that states the " +"subscriber is now subscribed or unsubscribed. This does not disable double " +"opt-in messages." +msgstr "" +"Se selezionato il software non invia messaggi di avvenuta iscrizione e " +"cancellazione. Questo non disabilita l'invio di messaggi per i link di " +"conferma delle azioni." + +#: views/settings.hbs:13 +msgid "Tracking ID" +msgstr "ID Tracciamento" + +#: views/settings.hbs:14 +msgid "Enter Google Analytics tracking code" +msgstr "Inserisci il codice di tracciamento di Google Analytics" + +#: views/settings.hbs:15 +msgid "Frontpage shout out" +msgstr "Annuncio pagina iniziale" + +#: views/settings.hbs:16 +msgid "HTML code shown in the front page header section" +msgstr "Codice HTML visualizzato nell'header dell'home page" + +#: views/settings.hbs:17 +msgid "Campaign defaults" +msgstr "Valori predefiniti campagna" + +#: views/settings.hbs:18 +msgid "Sender name" +msgstr "Nome mittente" + +#: views/settings.hbs:19 +msgid "Sender name, eg. My Awesome Company Ltd." +msgstr "Nome mittente, per esempio : Super Compagnia S.r.l." + +#: views/settings.hbs:20 +msgid "Default address" +msgstr "Indirizzo predefinito" + +#: views/settings.hbs:21 +msgid "" +"Contact address to provide, eg. 1234 Main Street, Anywhere, MA 01234, USA" +msgstr "" +"Indirizzo fisico di contatto, per esempio: via Duomo 71, Milano, 20100 (MI)" + +#: views/settings.hbs:22 +msgid "Default \"from name\"" +msgstr "Valore predefinito nome mittente" + +#: views/settings.hbs:24 +msgid "Default \"from\" email" +msgstr "Valore predefinito email mittente" + +#: views/settings.hbs:26 +msgid "Default \"subject line\"" +msgstr "Valore predefinito oggetto" + +#: views/settings.hbs:28 +msgid "Default homepage (URL)" +msgstr "Valore predefinito sito (URL)" + +#: views/settings.hbs:29 +msgid "URL to redirect the subscribed users to, eg. http://example.com/" +msgstr "" +"URL a cui reindirizzare gli utenti iscritti alla newsletter, per esempio " +"http://example.com" + +#: views/settings.hbs:30 +msgid "Mailer Settings" +msgstr "Impostazioni mailer" + +#: views/settings.hbs:31 +msgid "These settings are required to send out e-mail messages" +msgstr "Queste impostazioni sono richieste per inviare messaggi email" + +#: views/settings.hbs:32 +msgid "SMTP" +msgstr "" + +#: views/settings.hbs:33 +msgid "AWS SES" +msgstr "" + +#: views/settings.hbs:34 +msgid "Use SMTP for sending mail" +msgstr "Usa SMTP per spedire le email" + +#: views/settings.hbs:35 +msgid "Hostname" +msgstr "" + +#: views/settings.hbs:36 +msgid "Port" +msgstr "" + +#: views/settings.hbs:37 +msgid "Port, eg. 465. Autodetected if left blank" +msgstr "" + +#: views/settings.hbs:38 +msgid "Encryption" +msgstr "Crittografia" + +#: views/settings.hbs:39 +msgid "Disable SMTP authentication" +msgstr "Disabilita autenticazione SMTP" + +#: views/settings.hbs:40 views/users/forgot.hbs:9 views/users/login.hbs:4 +#: views/users/login.hbs:5 +msgid "Username" +msgstr "Nome utente" + +#: views/settings.hbs:41 +msgid "Username, eg. myaccount@example.com" +msgstr "Nome utente (per esempio account@example.com)" + +#: views/settings.hbs:42 views/settings.hbs:43 views/users/login.hbs:6 +#: views/users/login.hbs:7 +msgid "Password" +msgstr "" + +#: views/settings.hbs:44 +msgid "Use SES API for sending mail" +msgstr "" + +#: views/settings.hbs:45 +msgid "Access Key" +msgstr "" + +#: views/settings.hbs:46 +msgid "AWS Access Key Id" +msgstr "" + +#: views/settings.hbs:47 +msgid "Secret Key" +msgstr "" + +#: views/settings.hbs:48 +msgid "AWS Secret Access Key" +msgstr "" + +#: views/settings.hbs:49 +msgid "Region" +msgstr "Regione" + +#: views/settings.hbs:50 +msgid "Checking" +msgstr "Controllo" + +#: views/settings.hbs:51 +msgid "Check Mailer config" +msgstr "Controlla la configurazione del mailer" + +#: views/settings.hbs:52 +msgid "Advanced Mailer settings" +msgstr "Impostazioni Mailer avanzate" + +#: views/settings.hbs:53 +msgid "Log SMTP transactions" +msgstr "" + +#: views/settings.hbs:54 +msgid "Allow self-signed certificates" +msgstr "" + +#: views/settings.hbs:55 +msgid "Max connections" +msgstr "Massime connessioni" + +#: views/settings.hbs:56 +msgid "The count of max connections, eg. 10" +msgstr "Numero massimo di connessioni (per esempio 10)" + +#: views/settings.hbs:57 +msgid "" +"The count of maximum simultaneous connections to make against the SMTP " +"server (defaults to 5). This limit is per sending process." +msgstr "" + +#: views/settings.hbs:58 +msgid "Max messages" +msgstr "Massimo messaggi" + +#: views/settings.hbs:59 +msgid "The count of max messages, eg. 100" +msgstr "Il numero dei messaggi massimi, per esempio 1000" + +#: views/settings.hbs:60 +msgid "" +"The number of messages to send through a single connection before the " +"connection is closed and reopened (defaults to 100)" +msgstr "" + +#: views/settings.hbs:61 +msgid "Throttling" +msgstr "" + +#: views/settings.hbs:62 +msgid "Messages per hour eg. 1000" +msgstr "Messaggi all'ora" + +#: views/settings.hbs:63 +msgid "" +"Maximum number of messages to send in an hour. Leave empty or zero for no " +"throttling. If your provider uses a different speed limit (messages/minute " +"or messages/second) then convert this limit into messages/hour (1m/s => " +"3600m/h). This limit is per sending process." +msgstr "" +"Numero di messaggi massimo da inviare all'ora. Lascia il campo vuoto o con 0 " +"per non rallentare. Se il tuo provider usa diversi limiti di velocità di " +"invio (messaggi al minuto o al secondo), converti il valore per adattarlo (1 " +"mail / secondo => 3600 mail / ora ). Questo valore è per ogni singolo " +"processo di invio." + +#: views/settings.hbs:64 +msgid "VERP bounce handling" +msgstr "" + +#: views/settings.hbs:65 +msgid "" +"Mailtrain is able to use VERP based routing to detect bounces. In this case " +"the message is sent to the recipient using a custom VERP address as the " +"return path of the message. If the message is not accepted a bounce email is " +"sent to this special VERP address and thus a bounce is detected." +msgstr "" + +#: views/settings.hbs:66 +msgid "" +"To get VERP working you need to set up a DNS MX record that points to your " +"Mailtrain hostname. You must also ensure that Mailtrain VERP interface is " +"available from port 25 of your server (port 25 usually requires root user " +"privileges). This way if anyone tries to send email to someuser@verp-" +"hostname then the email should end up to this server." +msgstr "" + +#: views/settings.hbs:67 +msgid "" +"VERP usually only works if you are using your own SMTP server. Regular relay " +"services (SES, SparkPost, Gmail etc.) tend to remove the VERP address from " +"the message." +msgstr "" + +#: views/settings.hbs:68 +msgid "Use VERP to catch bounces" +msgstr "" + +#: views/settings.hbs:69 +msgid "Server hostname" +msgstr "" + +#: views/settings.hbs:70 +msgid "The VERP server hostname, eg. bounces.example.com" +msgstr "" + +#: views/settings.hbs:71 +msgid "" +"VERP bounce handling server hostname. This hostname is used in the SMTP " +"envelope FROM address and the MX DNS records should point to this server" +msgstr "" + +#: views/settings.hbs:72 +msgid "" +"VERP bounce handling server is not enabled. Modify your server configuration " +"file and restart server to enable it" +msgstr "" + +#: views/settings.hbs:73 +msgid "GPG Signing" +msgstr "" + +#: views/settings.hbs:74 +msgid "" +"Only messages that are encrypted can be signed. Subsribers who have not set " +"up a GPG public key in their profile receive normal email messages. Users " +"with GPG key set receive encrypted messages and if you have signing key also " +"set, the messages are signed with this key." +msgstr "" + +#: views/settings.hbs:75 +msgid "" +"Do not use sensitive keys here. The private key and passphrase are not " +"encrypted in the database." +msgstr "" + +#: views/settings.hbs:76 +msgid "Private Key Passphrase" +msgstr "" + +#: views/settings.hbs:77 +msgid "Passphrase for the key if set" +msgstr "" + +#: views/settings.hbs:78 +msgid "Only fill this if your private key is encrypted with a passphrase" +msgstr "" + +#: views/settings.hbs:79 +msgid "GPG Private Key" +msgstr "" + +#: views/settings.hbs:81 +msgid "" +"This value is optional. If you do not provide a private key GPG encrypted " +"messages are sent without signing." +msgstr "" + +#: views/settings.hbs:82 +msgid "DKIM Signing by ZoneMTA" +msgstr "" + +#: views/settings.hbs:83 +msgid "" +"If you are using ZoneMTA then Mailtrain can provide a DKIM key for signing " +"all outgoing messages. Other services usually provide their own means to " +"DKIM sign your messages" +msgstr "" + +#: views/settings.hbs:84 +msgid "" +"Do not use sensitive keys here. The private key is not encrypted in the " +"database." +msgstr "" + +#: views/settings.hbs:85 +msgid "ZoneMTA DKIM API Key" +msgstr "" + +#: views/settings.hbs:86 +msgid "Some secret value" +msgstr "" + +#: views/settings.hbs:87 +msgid "" +"Secret value known to ZoneMTA for requesting DKIM key information. If this " +"value was generated by the Mailtrain installation script then you can keep " +"it as it is" +msgstr "" + +#: views/settings.hbs:88 +msgid "DKIM domain" +msgstr "" + +#: views/settings.hbs:89 +msgid "Domain name for the DKIM key" +msgstr "" + +#: views/settings.hbs:90 +msgid "Leave blank to use the sender email address domain" +msgstr "" + +#: views/settings.hbs:91 views/settings.hbs:92 +msgid "DKIM key selector" +msgstr "" + +#: views/settings.hbs:93 +msgid "Signing is disabled without a valid selector value" +msgstr "" + +#: views/settings.hbs:94 +msgid "DKIM Private Key" +msgstr "" + +#: views/settings.hbs:96 +msgid "" +"This value is optional. If you do not provide a private key then messages " +"are not signed." +msgstr "" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:1 +#: views/subscription/mail-already-subscribed-text.hbs:1 +#: lib/models/subscriptions.js:174 lib/models/subscriptions.js:895 +msgid "Email address already registered" +msgstr "Indirizzo email già registrato" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:2 +#: views/subscription/mail-already-subscribed-text.hbs:2 +msgid "" +"We have received a subscription request. Your email address is however " +"already registered." +msgstr "" +"Abbiamo ricevuto una richiesta di iscrizione alla nostra newsletter. La tua " +"email è già registrata." + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:3 +#: views/subscription/mail-already-subscribed-text.hbs:3 +msgid "" +"If you received this email by mistake, simply delete it. Your existing " +"subscription won't be affected." +msgstr "" +"Se tu ricevi questa email per errore, cancellala semplicemente. La tua " +"registrazione non subirà alcuna modifica." + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:4 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:3 +msgid "If you want to modify your subscription then you can " +msgstr "Se vuoi modificare la tua iscrizione allora puoi" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:5 +#: views/subscription/mail-already-subscribed-text.hbs:5 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:4 +#: views/subscription/mail-subscription-confirmed-text.hbs:4 +msgid "manage your preferences" +msgstr "gestire le tue preferenze" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:6 +#: views/subscription/mail-already-subscribed-text.hbs:6 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:5 +#: views/subscription/mail-subscription-confirmed-text.hbs:5 +#: views/users/login.hbs:10 +msgid "or" +msgstr "oppure" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:7 +#: views/subscription/mail-already-subscribed-text.hbs:7 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:6 +#: views/subscription/mail-subscription-confirmed-text.hbs:6 +msgid "unsubscribe here" +msgstr "cancellare l'iscrizione qui" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:8 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:7 +#: views/subscription/web-confirm-subscription-notice.mjml.hbs:3 +#: views/subscription/web-confirm-unsubscription-notice.mjml.hbs:3 +#: views/subscription/web-manual-unsubscribe-notice.mjml.hbs:4 +#: views/subscription/web-subscribed-notice.mjml.hbs:4 +#: views/subscription/web-unsubscribed-notice.mjml.hbs:3 +#: views/subscription/web-updated-notice.mjml.hbs:3 +msgid "Return to our website" +msgstr "Torna sul nostro sito" + +#: views/subscription/mail-already-subscribed-html.mjml.hbs:9 +#: views/subscription/mail-already-subscribed-text.hbs:8 +#: views/subscription/mail-confirm-address-change-html.mjml.hbs:4 +#: views/subscription/mail-confirm-address-change-text.hbs:4 +#: views/subscription/mail-confirm-subscription-html.mjml.hbs:4 +#: views/subscription/mail-confirm-subscription-text.hbs:4 +#: views/subscription/mail-confirm-unsubscription-html.mjml.hbs:4 +#: views/subscription/mail-confirm-unsubscription-text.hbs:4 +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:8 +#: views/subscription/mail-subscription-confirmed-text.hbs:7 +#: views/subscription/mail-unsubscription-confirmed-html.mjml.hbs:5 +#: views/subscription/mail-unsubscription-confirmed-text.hbs:5 +msgid "For questions about this list, please contact:" +msgstr "Per domande riguardanti questa newsletter, contatta:" + +#: views/subscription/mail-already-subscribed-text.hbs:4 +#: views/subscription/mail-subscription-confirmed-text.hbs:3 +msgid "If you want to modify your subscription then you can:" +msgstr "Se vuoi modificare la tua iscrizione allora puoi:" + +#: views/subscription/mail-confirm-address-change-html.mjml.hbs:1 +#: views/subscription/mail-confirm-address-change-text.hbs:1 +msgid "Please Confirm Subscription Address Change" +msgstr "Per favore conferma il cambio dell'indirizzo dell'iscrizione" + +#: views/subscription/mail-confirm-address-change-html.mjml.hbs:2 +#: views/subscription/mail-confirm-address-change-text.hbs:2 +msgid "Yes, subscribe this email address to the list" +msgstr "Sì, iscrivimi alla lista" + +#: views/subscription/mail-confirm-address-change-html.mjml.hbs:3 +#: views/subscription/mail-confirm-subscription-html.mjml.hbs:3 +msgid "" +"If you received this email by mistake, simply delete it. You won't be " +"subscribed if you don't click the confirmation link above." +msgstr "" +"Se ricevi questa email per errore, semplicemente cancellala. Non verrai " +"registrato se non clicchi sul link di conferma qui sopra." + +#: views/subscription/mail-confirm-address-change-text.hbs:3 +#: views/subscription/mail-confirm-subscription-text.hbs:3 +msgid "" +"If you received this email by mistake, simply delete it. You won't be " +"subscribed unless you click the confirmation link above." +msgstr "" +"Se ricevi questa email per errore, semplicemente cancellala. Non verrai " +"registrato se non clicchi sul link di conferma qui sopra." + +#: views/subscription/mail-confirm-subscription-html.mjml.hbs:1 +#: views/subscription/mail-confirm-subscription-text.hbs:1 +#: views/subscription/mail-confirm-unsubscription-text.hbs:1 +#: routes/subscription.js:432 +msgid "Please Confirm Subscription" +msgstr "Per favore conferma la tua iscrizione" + +#: views/subscription/mail-confirm-subscription-html.mjml.hbs:2 +#: views/subscription/mail-confirm-subscription-text.hbs:2 +msgid "Yes, subscribe me to this list" +msgstr "Sì, iscrivimi a questa lista" + +#: views/subscription/mail-confirm-unsubscription-html.mjml.hbs:1 +msgid "Please Confirm Unsubscription" +msgstr "Per favore conferma la cancellazione dell'iscrizione" + +#: views/subscription/mail-confirm-unsubscription-html.mjml.hbs:2 +#: views/subscription/mail-confirm-unsubscription-text.hbs:2 +msgid "Yes, unsubscribe me from this list" +msgstr "Sì, cancella la mia iscrizione alla lista" + +#: views/subscription/mail-confirm-unsubscription-html.mjml.hbs:3 +msgid "" +"If you received this email by mistake, simply delete it. You won't be " +"unsubscribed if you don't click the confirmation link above." +msgstr "" +"Se ricevi questo messaggio per errore, cancellalo pure. Non sarai cancellato " +"dalla tua iscrizione se non clicchi sul link di conferma." + +#: views/subscription/mail-confirm-unsubscription-text.hbs:3 +msgid "" +"If you received this email by mistake, simply delete it. You won't be " +"unsubscribed unless you click the confirmation link above." +msgstr "" +"Se ricevi questo messaggio per errore, cancellalo pure. Non sarai cancellato " +"dalla tua iscrizione se non clicchi sul link di conferma." + +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:1 +#: views/subscription/mail-subscription-confirmed-text.hbs:1 +#: views/subscription/web-subscribed-notice.mjml.hbs:1 +msgid "Subscription Confirmed" +msgstr "Iscrizione confermata" + +#: views/subscription/mail-subscription-confirmed-html.mjml.hbs:2 +msgid "Your subscription to our list has been confirmed" +msgstr "La tua iscrizione alla nostra lista è stata confermata" + +#: views/subscription/mail-subscription-confirmed-text.hbs:2 +#: views/subscription/web-subscribed-notice.mjml.hbs:2 +msgid "Your subscription to our list has been confirmed." +msgstr "La tua iscrizione alla nostra lista è stata confermata." + +#: views/subscription/mail-unsubscription-confirmed-html.mjml.hbs:1 +#: views/subscription/mail-unsubscription-confirmed-text.hbs:1 +msgid "You Are Now Unsubscribed" +msgstr "La tua iscrizione è stata cancellata" + +#: views/subscription/mail-unsubscription-confirmed-html.mjml.hbs:2 +msgid "We have removed your email address from our list" +msgstr "Ti abbiamo rimosso dalla nostra lista" + +#: views/subscription/mail-unsubscription-confirmed-html.mjml.hbs:3 +#: views/subscription/mail-unsubscription-confirmed-text.hbs:3 +msgid "If you unsubscribed by mistake, you can re-subscribe at:" +msgstr "Se ti sei cancellato per sbaglio, puoi iscriverti nuovamente qui:" + +#: views/subscription/mail-unsubscription-confirmed-text.hbs:2 +msgid "We have removed your email address from our list." +msgstr "Abbiamo rimosso la tua email dalla nostra lista." + +#: views/subscription/partials/subscription-custom-fields.hbs:2 +msgid "want to change it?" +msgstr "vuoi cambiarlo?" + +#: views/subscription/partials/subscription-custom-fields.hbs:5 +msgid "Download signature verification key" +msgstr "Scarica la chiave di verifica" + +#: views/subscription/partials/subscription-custom-fields.hbs:7 +msgid "" +"Insert your GPG public key here to encrypt messages sent to your address" +msgstr "" +"Inserisci la tua chiave pubblica GPG qui per cifrare i messaggi inviati al " +"tuo server" + +#: views/subscription/partials/subscription-custom-fields.hbs:8 +msgid "optional" +msgstr "opzionale" + +#: views/subscription/partials/subscription-flash-messages.hbs:1 +#: views/subscription/partials/subscription-flash-messages.hbs:3 +msgid "Warning!" +msgstr "Attenzione!" + +#: views/subscription/partials/subscription-flash-messages.hbs:2 +msgid "If JavaScript was not enabled then no confirmation message was sent" +msgstr "" +"Se JavaScript non è abilitato, non verrà inviato alcun messaggio di conferma" + +#: views/subscription/partials/subscription-flash-messages.hbs:4 +msgid "JavaScript must be enabled in order for this form to work" +msgstr "" +"JavaScript deve essere abilitato per il funzionamento di questo modulo da " +"compilare" + +#: views/subscription/partials/subscription-manage-address-form.hbs:1 +msgid "Existing Email Address" +msgstr "Indirizzo email esistente" + +#: views/subscription/partials/subscription-manage-address-form.hbs:2 +msgid "New Email Address" +msgstr "Nuovo indirizzo email" + +#: views/subscription/partials/subscription-manage-address-form.hbs:3 +msgid "Your new email address" +msgstr "Il tuo nuovo indirizzo email" + +#: views/subscription/partials/subscription-manage-address-form.hbs:4 +msgid "" +"You will receive a confirmation request to your new email address that you " +"need to accept before your email is actually changed" +msgstr "" +"Riceverai una richiesta di conferma al tuo nuovo indirizzo di posta e devi " +"confermarlo per far sì che la modifica abbia effetto" + +#: views/subscription/partials/subscription-manage-address-form.hbs:5 +#: views/subscription/web-manage-address.mjml.hbs:2 +msgid "Update Email Address" +msgstr "Aggiorna indirizzo email" + +#: views/subscription/partials/subscription-manage-form.hbs:1 +#: views/subscription/web-manage.mjml.hbs:2 +msgid "Update Profile" +msgstr "Aggiorna profilo" + +#: views/subscription/partials/subscription-subscribe-form.hbs:1 +#: views/subscription/web-subscribe.mjml.hbs:2 +#: views/subscription/widget-subscribe.hbs:1 +msgid "Subscribe to list" +msgstr "Iscrivita alla lista" + +#: views/subscription/web-confirm-subscription-notice.mjml.hbs:1 +#: views/subscription/web-confirm-unsubscription-notice.mjml.hbs:1 +#: views/subscription/widget-subscribe.hbs:4 +msgid "Almost Finished" +msgstr "Quasi finito" + +#: views/subscription/web-confirm-subscription-notice.mjml.hbs:2 +#: views/subscription/widget-subscribe.hbs:5 +msgid "" +"We need to confirm your email address. To complete the subscription process, " +"please click the link in the email we just sent you." +msgstr "" +"Dobbiamo confermare il tuo indirizzo email. Per completare l'iscrizione, " +"clicca sul link che ti abbiamo inviato al tuo indirizzo email." + +#: views/subscription/web-confirm-unsubscription-notice.mjml.hbs:2 +msgid "" +"We need to confirm your email address. To complete the unsubscription " +"process, please click the link in the email we just sent you." +msgstr "" +"Abbiamo bisogno che confermi il tuo indirizzo email. Per completare il " +"processo di rimossione, si prega di cliccare il link che ti abbiamo appena " +"spedito." + +#: views/subscription/web-manage-address.mjml.hbs:1 +msgid "Update Your Email Address" +msgstr "Aggiorna il tuo indirizzo email" + +#: views/subscription/web-manage.mjml.hbs:1 +msgid "Update Your Preferences" +msgstr "Aggiorna le tue preferenze" + +#: views/subscription/web-manual-unsubscribe-notice.mjml.hbs:1 +msgid "Online Unsubscription Is Not Possible" +msgstr "La rimozione dell'iscrizione non è fattibile online" + +#: views/subscription/web-manual-unsubscribe-notice.mjml.hbs:2 +msgid "Please contact us at" +msgstr "Puoi contattarci all'indirizzo " + +#: views/subscription/web-manual-unsubscribe-notice.mjml.hbs:3 +msgid "to get removed from the list" +msgstr "per essere rimosso dalla lista" + +#: views/subscription/web-subscribe.mjml.hbs:1 +msgid "Subscribe to List" +msgstr "Iscriviti alla lista" + +#: views/subscription/web-subscribed-notice.mjml.hbs:3 +msgid "Thank you for subscribing!" +msgstr "Grazie per la tua iscrizione!" + +#: views/subscription/web-unsubscribed-notice.mjml.hbs:1 +msgid "Unsubscribe Successful" +msgstr "Rimozione eseguita con successo" + +#: views/subscription/web-unsubscribed-notice.mjml.hbs:2 +msgid "You have been removed from:" +msgstr "Se stato rimosso da:" + +#: views/subscription/web-updated-notice.mjml.hbs:1 +msgid "Profile Updated" +msgstr "Profilo Aggiornato" + +#: views/subscription/web-updated-notice.mjml.hbs:2 +msgid "Your profile information has been updated." +msgstr "Le informazioni del tuo profilo sono stato aggiornate." + +#: views/subscription/widget-subscribe.hbs:2 +msgid "Sending ..." +msgstr "Invio ..." + +#: views/subscription/widget-subscribe.hbs:3 +msgid "It looks like you are already subscribed to this list." +msgstr "Sembra che tu ti sia già iscritto a questa lista." + +#: views/templates/create.hbs:5 views/templates/edit.hbs:6 +msgid "Template name" +msgstr "Nome Template" + +#: views/templates/create.hbs:6 views/templates/edit.hbs:7 +msgid "Name for this template, eg. Newsletter" +msgstr "Nome di questo template eg. Newsletter promozioni" + +#: views/templates/create.hbs:7 +msgid "HTML Editor" +msgstr "Editor HTML" + +#: views/templates/create.hbs:10 views/templates/edit.hbs:9 +msgid "Optional comments about this template" +msgstr "Commenti opzionali per questo template" + +#: views/templates/edit.hbs:5 +msgid "Back to templates" +msgstr "Indietro ai templates" + +#: views/templates/edit.hbs:11 +msgid "Duplicate" +msgstr "Duplica" + +#: views/triggers/create-select.hbs:2 views/triggers/create.hbs:2 +#: views/triggers/edit.hbs:2 views/triggers/triggered.hbs:2 +#: views/triggers/triggers.hbs:2 views/triggers/triggers.hbs:4 +msgid "Automation Triggers" +msgstr "Trigger di automazione" + +#: views/triggers/create-select.hbs:5 +msgid "Select a list for the trigger" +msgstr "Seleziona una lista per questo trigger" + +#: views/triggers/create.hbs:5 views/triggers/edit.hbs:6 +msgid "Trigger name" +msgstr "Nome trigger" + +#: views/triggers/create.hbs:6 views/triggers/edit.hbs:7 +msgid "Name for this trigger, eg. Inactive subscribers" +msgstr "Nome per questo trigger, per esempio: iscritti inattivi" + +#: views/triggers/create.hbs:8 views/triggers/edit.hbs:9 +msgid "Optional comments about this trigger" +msgstr "Commenti opzionali per questo trigger" + +#: views/triggers/create.hbs:12 views/triggers/edit.hbs:14 +msgid "Trigger rule" +msgstr "Regola trigger" + +#: views/triggers/create.hbs:13 views/triggers/edit.hbs:15 +msgid "Trigger fires" +msgstr "Attivazione trigger" + +#: views/triggers/create.hbs:14 views/triggers/edit.hbs:16 +msgid "days after:" +msgstr "dopo giorni:" + +#: views/triggers/create.hbs:16 views/triggers/create.hbs:21 +#: views/triggers/edit.hbs:18 views/triggers/edit.hbs:23 +msgid "Event" +msgstr "Evento" + +#: views/triggers/create.hbs:18 views/triggers/create.hbs:19 +#: views/triggers/create.hbs:25 views/triggers/edit.hbs:20 +#: views/triggers/edit.hbs:21 views/triggers/edit.hbs:27 +msgid "Campaign" +msgstr "Campagna" + +#: views/triggers/create.hbs:23 views/triggers/edit.hbs:25 +msgid "Trigger action" +msgstr "Azione trigger" + +#: views/triggers/create.hbs:24 views/triggers/edit.hbs:26 +msgid "Send campaign" +msgstr "Invia campagna" + +#: views/triggers/edit.hbs:3 views/triggers/edit.hbs:4 +msgid "Edit Trigger" +msgstr "Modifica trigger" + +#: views/triggers/edit.hbs:5 +msgid "Back to triggers" +msgstr "Indietro ai triggers" + +#: views/triggers/edit.hbs:11 +msgid "Trigger is enabled" +msgstr "Il trigger è abilitato" + +#: views/triggers/edit.hbs:29 +msgid "Delete Trigger" +msgstr "Elimina trigger" + +#: views/triggers/triggered.hbs:3 +msgid "Triggered" +msgstr "Trigger azionato" + +#: views/triggers/triggered.hbs:4 +msgid "Triggered subscribers" +msgstr "Iscritti con trigger azionati" + +#: views/triggers/triggered.hbs:5 +msgid "Subscribers who caused this trigger to fire" +msgstr "Iscritti che hanno azionato questo trigger" + +#: views/triggers/triggered.hbs:9 +msgid "Triggered time" +msgstr "Ora azionamento Trigger" + +#: views/triggers/triggers.hbs:9 +msgid "Trigger" +msgstr "" + +#: views/triggers/triggers.hbs:10 +msgid "Target Campaign" +msgstr "Campagna targetizzata" + +#: views/triggers/triggers.hbs:11 +msgid "Triggered count" +msgstr "Conteggio trigger azionati" + +#: views/users/account.hbs:4 +msgid "This account is managed through LDAP." +msgstr "Questo account è controllato tramite LDAP." + +#: views/users/account.hbs:5 +msgid "Associated Email Address" +msgstr "Indirizzo email associato" + +#: views/users/account.hbs:8 +msgid "Your e-mail address" +msgstr "Il tuo indirizzo email" + +#: views/users/account.hbs:9 +msgid "" +"This address is used for account recovery in case you lose your password" +msgstr "Questo indirizzo è utilizzato per il recupero della password" + +#: views/users/account.hbs:10 +msgid "Password change" +msgstr "Cambia password" + +#: views/users/account.hbs:11 +msgid "" +"You only need to fill out this form if you want to change your current " +"password" +msgstr "" +"Hai bisogno di completare questo form solo se vuoi cambiare la tua password " +"attuale" + +#: views/users/account.hbs:12 views/users/account.hbs:13 +msgid "Current Password" +msgstr "Password attuale" + +#: views/users/account.hbs:14 views/users/account.hbs:15 +#: views/users/reset.hbs:6 views/users/reset.hbs:7 +msgid "New Password" +msgstr "Nuova password" + +#: views/users/account.hbs:16 views/users/reset.hbs:8 +msgid "Confirm Password" +msgstr "Conferma password" + +#: views/users/account.hbs:17 views/users/reset.hbs:9 +msgid "Confirm New Password" +msgstr "Conferma nuova password" + +#: views/users/api.hbs:4 +msgid "Are you sure? Resetting would invalidate the currently existing token." +msgstr "Sei sicuro? Il reset invaliderà i tokens che esistono al momento" + +#: views/users/api.hbs:5 +msgid "Are you sure?" +msgstr "Sei sicuro?" + +#: views/users/api.hbs:6 +msgid "Reset Access Token" +msgstr "Resetta token di accesso" + +#: views/users/api.hbs:7 +msgid "Generate Access Token" +msgstr "Genera token di accesso" + +#: views/users/api.hbs:8 +msgid "Personal access token:" +msgstr "Token di accesso personale:" + +#: views/users/api.hbs:9 +msgid "Access token not yet generated" +msgstr "Token di accesso non generato" + +#: views/users/api.hbs:10 +msgid "Notes about the API" +msgstr "Note sull'API" + +#: views/users/api.hbs:11 +msgid "" +"API response is a JSON structure with error and data properties. If the response error has a value set then " +"the request failed." +msgstr "" +"La risposta API è una struttura JSON con proprietà error e " +"data. Se la risposta ha il valore error impostato, " +"la richiesta è fallita." + +#: views/users/api.hbs:12 +msgid "" +"You need to define proper Content-Type when making a request. " +"You can either use application/x-www-form-urlencoded for normal " +"form data or application/json for a JSON payload. Using " +"multipart/form-data is not supported." +msgstr "" +"Devi definire il giusto Content-Type quando esegui una " +"richiesta. Puoi usare application/x-www-form-urlencoded per i " +"dati dei form normali, oppure application/json per JSON " +"payload. Non è supportato multipart/form-data." + +#: views/users/api.hbs:13 +msgid "Get list of subscriptions" +msgstr "Ottieni lista delle iscrizioni" + +#: views/users/api.hbs:14 +msgid "" +"Retrieve a list of subscriptions to the list referenced by :listId. All " +"fields of the subscribers will be returned. Note that custom fields will " +"have generated names." +msgstr "" +"Ottieni una lista delle iscrizioni alla lista :listId. Tutti i campi degli " +"iscritti saranno restituiti. Nota che i campi personalizzati avranno dei " +"nomi automaticamente generati." + +#: views/users/api.hbs:15 views/users/api.hbs:24 views/users/api.hbs:26 +#: views/users/api.hbs:39 views/users/api.hbs:41 views/users/api.hbs:47 +#: views/users/api.hbs:49 views/users/api.hbs:55 views/users/api.hbs:57 +#: views/users/api.hbs:67 views/users/api.hbs:78 views/users/api.hbs:80 +#: views/users/api.hbs:86 views/users/api.hbs:88 views/users/api.hbs:94 +msgid "arguments" +msgstr "argomenti" + +#: views/users/api.hbs:16 views/users/api.hbs:25 views/users/api.hbs:40 +#: views/users/api.hbs:48 views/users/api.hbs:56 views/users/api.hbs:68 +#: views/users/api.hbs:79 views/users/api.hbs:87 views/users/api.hbs:95 +msgid "your personal access token" +msgstr "il tuo token di accesso personale" + +#: views/users/api.hbs:17 views/users/api.hbs:69 +msgid "Start position" +msgstr "Posizionale di inizio" + +#: views/users/api.hbs:18 views/users/api.hbs:70 +msgid "optional, default 0" +msgstr "opzionale, 0 di default" + +#: views/users/api.hbs:19 +msgid "limit subscription count in response" +msgstr "limita il numero di iscrizioni in risposta" + +#: views/users/api.hbs:20 views/users/api.hbs:72 +msgid "optional, default 10000" +msgstr "opzionale, default 10000" + +#: views/users/api.hbs:22 +msgid "Add subscription" +msgstr "Aggiungi iscrizione" + +#: views/users/api.hbs:23 +msgid "" +"This API call either inserts a new subscription or updates existing. Fields " +"not included are left as is, so if you update only LAST_NAME value, then " +"FIRST_NAME is kept untouched for an existing subscription." +msgstr "" +"Questa chiamata API aggiunge o aggiorna una iscrizione. I campi non inclusi " +"saranno lasciati come erano, quindi se si aggiorna LAST_NAME, FIRST_NAME " +"rimarrà invariato per quella iscrizione." + +#: views/users/api.hbs:27 views/users/api.hbs:42 views/users/api.hbs:50 +msgid "subscriber's email address" +msgstr "indirizzo email dell'iscritto" + +#: views/users/api.hbs:28 views/users/api.hbs:43 views/users/api.hbs:51 +#: views/users/api.hbs:59 views/users/api.hbs:82 views/users/api.hbs:90 +msgid "required" +msgstr "richiesto" + +#: views/users/api.hbs:29 +msgid "subscriber's first name" +msgstr "nome dell'iscritto" + +#: views/users/api.hbs:30 +msgid "subscriber's last name" +msgstr "cognome dell'iscritto" + +#: views/users/api.hbs:31 +msgid "" +"subscriber's timezone (eg. \"Europe/Tallinn\", \"PST\" or \"UTC\"). If not " +"set defaults to \"UTC\"" +msgstr "" +"timezone dell'iscritto (esempio: \"Europe/Tallinn\", \"PST\" or \"UTC\"). Se " +"non impostato il valore di default è \"UTC\"" + +#: views/users/api.hbs:32 +msgid "" +"custom field value. Use yes/no for option group values (checkboxes, radios, " +"drop downs)" +msgstr "" +"valore dei campi personalizzati. Usa si/no per i valori dei gruppi di " +"opzioni (checkboxes, radios, drop downs) " + +#: views/users/api.hbs:33 +msgid "Additional POST arguments" +msgstr "" + +#: views/users/api.hbs:34 +msgid "" +"set to \"yes\" if you want to make sure the email is marked as subscribed " +"even if it was previously marked as unsubscribed. If the email was already " +"unsubscribed/blocked then subscription status is not changed" +msgstr "" +"selezionare \"sì\" se vuoi essere sicuro che la mail venga salvata come " +"iscritta anche se precedentemente cancellata. Se la mail si era già " +"cancellata o bloccata, lo stato di iscrizione non cambierà." + +#: views/users/api.hbs:35 +msgid "" +"set to \"yes\" if you want to send confirmation email to the subscriber " +"before actually marking as subscribed" +msgstr "" +"selezionare \"sì\" se vuoi inviare la mail di conferma all'email " +"delliscrizione prima di salvarlo come iscritto" + +#: views/users/api.hbs:37 +msgid "Remove subscription" +msgstr "Rimuovi iscrizione" + +#: views/users/api.hbs:38 +msgid "This API call marks a subscription as unsubscribed" +msgstr "Questa chiamata API segna una iscrizione come rimossa." + +#: views/users/api.hbs:45 +msgid "Delete subscription" +msgstr "Cancella iscrizione" + +#: views/users/api.hbs:46 +msgid "This API call deletes a subscription" +msgstr "Questa API cancella una iscrizione" + +#: views/users/api.hbs:53 +msgid "Add new custom field" +msgstr "Aggiungi un campo personalizzato" + +#: views/users/api.hbs:54 +msgid "This API call creates a new custom field for a list." +msgstr "Questa chiamata API crea un nuovo campo personalizzato per una lista." + +#: views/users/api.hbs:58 +msgid "field name" +msgstr "nome campo" + +#: views/users/api.hbs:60 +msgid "one of the following types:" +msgstr "uno dei seguenti tipi:" + +#: views/users/api.hbs:61 +msgid "" +"If the type is 'option' then you also need to specify the parent element ID" +msgstr "" +"Se il tipo è 'option' devi anche specificare l'ID dell'elemento parente" + +#: views/users/api.hbs:62 +msgid "" +"Template for the group element. If not set, then values of the elements are " +"joined with commas" +msgstr "" +"Template per il gruppo di elementi. Se non impostato, allora i valori " +"verranno separati da una virgola" + +#: views/users/api.hbs:63 +msgid "" +"if not visible then the subscriber can not view or modify this value at the " +"profile page" +msgstr "" +"se non visibile l'iscritto non potrà modificare questo valore nella pagina " +"del profilo" + +#: views/users/api.hbs:65 +msgid "Get list of blacklisted emails" +msgstr "Ottieni emails in lista nera" + +#: views/users/api.hbs:66 +msgid "This API call get list of blacklisted emails." +msgstr "Questa chiamata API ottiene una lista delle email in lista nera." + +#: views/users/api.hbs:71 +msgid "limit emails count in response" +msgstr "limita il numero di emails nella risposta" + +#: views/users/api.hbs:73 +msgid "filter by part of email" +msgstr "filtra per parte della email" + +#: views/users/api.hbs:74 +msgid "optional, default ''" +msgstr "opzionale, default ''" + +#: views/users/api.hbs:77 +msgid "This API call either add emails to blacklist" +msgstr "Questa chiamata API aggiunge emails alla lista nera" + +#: views/users/api.hbs:81 views/users/api.hbs:89 +msgid "email address" +msgstr "indirizzo email" + +#: views/users/api.hbs:84 +msgid "Delete email from blacklist" +msgstr "Cancella email dalla lista nera." + +#: views/users/api.hbs:85 +msgid "This API call either delete emails from blacklist" +msgstr "Questa chiamata API cancella emails dalla lista nera" + +#: views/users/api.hbs:92 +msgid "Get the lists a user has subscribed to" +msgstr "Ottini le listi a cui un utente si è iscritto" + +#: views/users/api.hbs:93 +msgid "Retrieve the lists that the user with :email has subscribed to. " +msgstr "Ottieni le liste a cui l'utente con :email si è iscritto" + +#: views/users/forgot.hbs:3 views/users/reset.hbs:3 +msgid "Password Reset" +msgstr "Resetta password" + +#: views/users/forgot.hbs:4 +msgid "Reset your password?" +msgstr "Resettare la password?" + +#: views/users/forgot.hbs:5 +msgid "Accounts are managed through LDAP." +msgstr "Gli accounts sono gestiti tramite LDAP." + +#: views/users/forgot.hbs:6 views/users/reset.hbs:10 +msgid "Reset Password" +msgstr "Resetta password" + +#: views/users/forgot.hbs:7 +msgid "" +"Please provide the username or email address that you used when you signed " +"up for your Mailtrain account." +msgstr "" +"Si prega di inserire lo username o la email inserita al momento della " +"registrazione." + +#: views/users/forgot.hbs:8 +msgid "We will send you an email that will allow you to reset your password." +msgstr "Ti invieremo una email che ti permetterà di cambiare password." + +#: views/users/forgot.hbs:10 +msgid "Username or email address" +msgstr "Username o email" + +#: views/users/forgot.hbs:11 +msgid "Send verification email" +msgstr "Invia email di verifica" + +#: views/users/login.hbs:8 +msgid "Remember me" +msgstr "Ricordati di me" + +#: views/users/login.hbs:11 views/users/login.hbs:12 +msgid "Forgot password?" +msgstr "Password dimenticata?" + +#: views/users/reset.hbs:4 +msgid "Choose your new password" +msgstr "Scegli la tua nuova password" + +#: views/users/reset.hbs:5 +msgid "Please enter a new password." +msgstr "Inserire una nuova password." + +#: lib/editor-helpers.js:17 routes/templates.js:95 +msgid "Could not find template with specified ID" +msgstr "Template con l'ID specificato non trovato" + +#: lib/editor-helpers.js:33 routes/archive.js:145 routes/campaigns.js:131 +#: routes/campaigns.js:284 routes/campaigns.js:379 routes/campaigns.js:427 +#: routes/campaigns.js:467 routes/campaigns.js:844 routes/campaigns.js:867 +#: routes/campaigns.js:886 routes/campaigns.js:908 routes/triggers.js:146 +msgid "Could not find campaign with specified ID" +msgstr "Campagna con l'ID specificato non trovata" + +#: lib/editor-helpers.js:47 routes/editorapi.js:320 +msgid "Invalid resource type" +msgstr "Tipo di risorsa invalida" + +#: lib/feed.js:31 +msgid "Bad status code %s" +msgstr "Codice %s di stato sbagliato " + +#: lib/helpers.js:33 +msgid "URL that points to the unsubscribe page" +msgstr "URL per la pagina di rimozione dall'iscrizione" + +#: lib/helpers.js:36 +msgid "URL that points to the preferences page of the subscriber" +msgstr "URL per la pagina delle preferenze dell'iscritto" + +#: lib/helpers.js:39 +msgid "URL to preview the message in a browser" +msgstr "URL per l'anteprima del messaggio nel browser" + +#: lib/helpers.js:45 lib/models/segments.js:31 +msgid "First name" +msgstr "Nome" + +#: lib/helpers.js:48 lib/models/segments.js:35 +msgid "Last name" +msgstr "Cognome" + +#: lib/helpers.js:51 +msgid "Full name (first and last name combined)" +msgstr "Nome e Cognome" + +#: lib/helpers.js:54 +msgid "Unique ID that identifies the recipient" +msgstr "ID unico che identifica il destinatario" + +#: lib/helpers.js:57 +msgid "Unique ID that identifies the list used for this campaign" +msgstr "ID unico che identifica la lista usata per questa campagna" + +#: lib/helpers.js:60 +msgid "Unique ID that identifies current campaign" +msgstr "ID unico che identifica la campagna corrente" + +#: lib/helpers.js:68 lib/helpers.js:80 +msgid "content from an RSS entry" +msgstr "contenuto dal messaggio RSS" + +#: lib/helpers.js:71 +msgid "RSS entry title" +msgstr "Titolo RSS entry" + +#: lib/helpers.js:74 +msgid "RSS entry date" +msgstr "" + +#: lib/helpers.js:77 +msgid "RSS entry link" +msgstr "" + +#: lib/helpers.js:83 +msgid "RSS entry summary" +msgstr "" + +#: lib/helpers.js:86 +msgid "RSS entry image URL" +msgstr "" + +#: lib/mailer.js:245 +msgid "Invalid mail transport" +msgstr "Trasporto mail invalido" + +#: lib/models/campaigns.js:105 lib/models/campaigns.js:132 +#: lib/models/campaigns.js:205 lib/models/campaigns.js:328 +#: lib/models/campaigns.js:590 lib/models/campaigns.js:723 +msgid "Missing Campaign ID" +msgstr "ID campagna mancante" + +#: lib/models/campaigns.js:241 +msgid "Emtpy or too large attahcment" +msgstr "Allegato troppo grande o mancante" + +#: lib/models/campaigns.js:408 lib/models/campaigns.js:600 +msgid "Campaign Name must be set" +msgstr "Il nome della campagna è obbligatorio" + +#: lib/models/campaigns.js:412 +msgid "RSS URL must be set and needs to be a valid URL" +msgstr "" + +#: lib/models/campaigns.js:568 +msgid "Selected template not found" +msgstr "Template selezionato non trovato" + +#: lib/models/campaigns.js:924 +msgid "Invalid or missing message ID" +msgstr "ID messaggio mancante o invalido" + +#: lib/models/campaigns.js:1065 +msgid "Unrecognized message status" +msgstr "Stato del messaggio non riconosciuto" + +#: lib/models/confirmations.js:27 +msgid "Could not store confirmation data" +msgstr "Impossibile salvare i dati di conferma" + +#: lib/models/fields.js:24 +msgid "Drop Down" +msgstr "Drop Down" + +#: lib/models/fields.js:25 +msgid "Date (MM/DD/YYY)" +msgstr "Data (MM/GG/AAAA)" + +#: lib/models/fields.js:29 +msgid "JSON value for custom rendering" +msgstr "Valore JSON per visualizzazione personalizzata" + +#: lib/models/fields.js:30 +msgid "Option" +msgstr "Opzione" + +#: lib/models/fields.js:53 lib/models/fields.js:98 lib/models/fields.js:123 +#: lib/models/forms.js:46 lib/models/lists.js:115 lib/models/lists.js:150 +#: lib/models/lists.js:264 lib/models/segments.js:43 lib/models/segments.js:176 +#: lib/models/subscriptions.js:79 lib/models/subscriptions.js:390 +#: lib/models/subscriptions.js:566 lib/models/subscriptions.js:657 +#: lib/models/subscriptions.js:710 lib/models/subscriptions.js:773 +#: lib/models/subscriptions.js:816 +msgid "Missing List ID" +msgstr "ID lista mancante" + +#: lib/models/fields.js:129 +msgid "Option field requires a group to be selected" +msgstr "Il campo Option richiede la selezione di un gruppo" + +#: lib/models/fields.js:149 lib/models/fields.js:199 +msgid "Missing Field ID" +msgstr "ID campo manvante" + +#: lib/models/fields.js:153 lib/models/segments.js:185 +#: lib/models/segments.js:225 +msgid "Field Name must be set" +msgstr "Il nome del campo deve essere impostato" + +#: lib/models/fields.js:216 +msgid "Custom field not found" +msgstr "Campo personalizzato non trovato" + +#: lib/models/fields.js:289 +msgid "Unknown column type %s" +msgstr "Tipo di colonna %s non riconosciuto" + +#: lib/models/fields.js:293 +msgid "Missing column name" +msgstr "nome colonna mancante" + +#: lib/models/fields.js:297 +msgid "Missing list ID" +msgstr "ID lista mancante" + +#: lib/models/fields.js:305 +msgid "Provided List ID not found" +msgstr "ID lista non trovato" + +#: lib/models/forms.js:70 lib/models/forms.js:113 lib/models/forms.js:201 +#: lib/models/forms.js:291 +msgid "Missing Form ID" +msgstr "ID Form mancante" + +#: lib/models/forms.js:121 lib/models/forms.js:205 +msgid "Form Name must be set" +msgstr "Il nome del form è obbligatorio" + +#: lib/models/forms.js:307 +msgid "Custom form not found" +msgstr "Form personalizzato non trovato" + +#: lib/models/links.js:337 routes/campaigns.js:533 routes/campaigns.js:581 +#: routes/campaigns.js:621 routes/campaigns.js:671 services/sender.js:305 +msgid "Campaign not found" +msgstr "Campagna non trovata" + +#: lib/models/links.js:345 routes/lists.js:181 services/sender.js:312 +msgid "List not found" +msgstr "Lista non trovat" + +#: lib/models/links.js:353 +msgid "Subscription not found" +msgstr "Iscrizione non trovata" + +#: lib/models/lists.js:166 lib/models/lists.js:210 +msgid "List Name must be set" +msgstr "Il nome della lista è obbligatorio" + +#: lib/models/lists.js:293 +msgid "Missing List CID" +msgstr "CID lista mancante" + +#: lib/models/report-templates.js:26 lib/models/report-templates.js:70 +#: lib/models/report-templates.js:142 +msgid "Missing report template ID" +msgstr "ID template di reportistica mancante" + +#: lib/models/report-templates.js:77 +msgid "Report template name must be set" +msgstr "Il nome del template di report è obbligatorio" + +#: lib/models/reports.js:40 lib/models/reports.js:110 lib/models/reports.js:188 +msgid "Missing report ID" +msgstr "ID report mancante" + +#: lib/models/reports.js:116 +msgid "Report name must be set" +msgstr "Il nome del report è obblicatorio" + +#: lib/models/segments.js:15 +msgid "Signup country" +msgstr "Nazione di registrazione" + +#: lib/models/segments.js:19 lib/models/triggers.js:12 +msgid "Sign up date" +msgstr "Data registrazione" + +#: lib/models/segments.js:23 lib/models/triggers.js:16 +msgid "Latest open" +msgstr "Ultima apertura" + +#: lib/models/segments.js:27 lib/models/triggers.js:20 +msgid "Latest click" +msgstr "Ultimo click" + +#: lib/models/segments.js:69 lib/models/segments.js:216 +#: lib/models/segments.js:256 lib/models/segments.js:278 +msgid "Missing Segment ID" +msgstr "ID segmento mancante" + +#: lib/models/segments.js:85 lib/models/segments.js:549 +#: lib/models/segments.js:658 +msgid "Segment not found" +msgstr "Segmento non trovato" + +#: lib/models/segments.js:146 lib/models/segments.js:147 +#: lib/models/segments.js:408 lib/models/segments.js:409 +msgid "%s days after today" +msgstr "%s giorni a partire da oggi" + +#: lib/models/segments.js:146 lib/models/segments.js:147 +#: lib/models/segments.js:408 lib/models/segments.js:409 +msgid "%s days before today" +msgstr "$s giorni fa" + +#: lib/models/segments.js:148 lib/models/segments.js:410 +msgid "today" +msgstr "oggi" + +#: lib/models/segments.js:189 lib/models/segments.js:229 +msgid "Invalid segment rule type" +msgstr "Tipo di regola del segmento non valido" + +#: lib/models/segments.js:289 lib/models/segments.js:454 routes/segments.js:266 +#: routes/segments.js:300 routes/segments.js:370 routes/segments.js:381 +msgid "Selected segment not found" +msgstr "Segmento selezionato non trovato" + +#: lib/models/segments.js:294 lib/models/segments.js:459 routes/segments.js:272 +#: routes/segments.js:306 routes/segments.js:387 +msgid "Invalid rule type" +msgstr "Tipo di regola non valida" + +#: lib/models/segments.js:358 lib/models/segments.js:434 +#: lib/models/segments.js:524 +msgid "Missing Rule ID" +msgstr "ID regola mancante" + +#: lib/models/segments.js:374 +msgid "Specified rule not found" +msgstr "Regola specificata non trovata" + +#: lib/models/segments.js:385 +msgid "Specified segment not found" +msgstr "Segmento selezionato non trovato" + +#: lib/models/segments.js:445 +msgid "Selected rule not found" +msgstr "Regola selezionata non trovata" + +#: lib/models/subscriptions.js:257 lib/models/subscriptions.js:287 +#: lib/models/subscriptions.js:394 +msgid "Missing Subscription ID" +msgstr "ID iscrizione mancante" + +#: lib/models/subscriptions.js:315 +msgid "Missing Subscription email address" +msgstr "Indirizzo email di iscrizione mancante" + +#: lib/models/subscriptions.js:570 lib/models/subscriptions.js:820 +msgid "Missing subscription ID" +msgstr "ID di iscrizione mancante" + +#: lib/models/subscriptions.js:661 lib/models/subscriptions.js:714 +#: lib/models/subscriptions.js:750 +msgid "Missing Import ID" +msgstr "ID di import mancante" + +#: lib/models/subscriptions.js:842 +msgid "Unknown subscription ID" +msgstr "ID iscrizione sconosciuto" + +#: lib/models/subscriptions.js:847 routes/subscription.js:639 +msgid "Nothing seems to be changed" +msgstr "Nulla sembra essere cambiato" + +#: lib/models/subscriptions.js:913 routes/subscription.js:473 +#: routes/subscription.js:545 routes/subscription.js:581 +#: routes/subscription.js:697 routes/subscription.js:772 +msgid "Subscription not found in this list" +msgstr "Iscrizione non trovata nella lista" + +#: lib/models/templates.js:26 lib/models/templates.js:102 +#: lib/models/templates.js:157 +msgid "Missing Template ID" +msgstr "ID template mancante" + +#: lib/models/templates.js:55 lib/models/templates.js:106 +msgid "Template Name must be set" +msgstr "Nome template obbligatorio" + +#: lib/models/templates.js:147 +msgid "Template does not exist" +msgstr "Il template non esiste" + +#: lib/models/triggers.js:29 +msgid "Has Opened" +msgstr "Ha aperto" + +#: lib/models/triggers.js:32 +msgid "Has Clicked" +msgstr "Ha cliccato" + +#: lib/models/triggers.js:35 +msgid "Not Opened" +msgstr "Non aperto" + +#: lib/models/triggers.js:38 +msgid "Not Clicked" +msgstr "Non cliccato" + +#: lib/models/triggers.js:178 lib/models/triggers.js:215 +msgid "Missing or invalid list ID" +msgstr "ID Lista mancante on non valido" + +#: lib/models/triggers.js:182 lib/models/triggers.js:267 +msgid "Days in the past are not allowed" +msgstr "Giorni nel passato non sono permessi" + +#: lib/models/triggers.js:186 lib/models/triggers.js:207 +#: lib/models/triggers.js:271 lib/models/triggers.js:292 +msgid "Missing or invalid trigger rule" +msgstr "Regola di trigger mancante o non valido" + +#: lib/models/triggers.js:193 lib/models/triggers.js:278 +msgid "Invalid subscription configuration" +msgstr "Configurazione di iscrizione non valida" + +#: lib/models/triggers.js:200 lib/models/triggers.js:285 +msgid "Invalid campaign configuration" +msgstr "Configurazione della campagna non valid" + +#: lib/models/triggers.js:203 lib/models/triggers.js:288 +msgid "A campaing can not be a target for itself" +msgstr "Una campagna non può' essere il target di sè stessa" + +#: lib/models/triggers.js:236 +msgid "Could not store trigger row" +msgstr "Impossibile salvare la riga di trigger" + +#: lib/models/triggers.js:253 +msgid "Missing or invalid Trigger ID" +msgstr "ID trigger mancante o non valido" + +#: lib/models/triggers.js:320 +msgid "Missing Trigger ID" +msgstr "ID trigger mancante" + +#: lib/models/users.js:103 +msgid "Could not store user row" +msgstr "Impossibile salvare riga utente" + +#: lib/models/users.js:173 +msgid "Email Address must be set" +msgstr "Indirizzo email obbligatorio" + +#: lib/models/users.js:184 +msgid "Failed to check user data" +msgstr "Controllo dati inseriti fallito" + +#: lib/models/users.js:195 +msgid "" +"Can't change email as another user with the same email address already exists" +msgstr "" +"Impossibile cambiare indirizzo email poiché esiste un account già associato " +"all'indirizzo" + +#: lib/models/users.js:212 +msgid "Incorrect current password" +msgstr "Password corrente errata" + +#: lib/models/users.js:216 +msgid "New password not set" +msgstr "Nuova password non impostata" + +#: lib/models/users.js:220 +msgid "Passwords do not match" +msgstr "Le password non corrispondono" + +#: lib/models/users.js:258 +msgid "User ID not set" +msgstr "ID utente non impostato" + +#: lib/models/users.js:286 +msgid "Username must be set" +msgstr "Il nome utente è obbligatorio" + +#: lib/models/users.js:323 +msgid "Mailer password change request" +msgstr "Richiesta cambio password del Mailer" + +#: lib/models/users.js:347 lib/models/users.js:367 +msgid "Missing username or reset token" +msgstr "nome utente o tocken di accesso invalido" + +#: lib/models/users.js:371 +msgid "Invalid new password" +msgstr "Nuova password non valida" + +#: lib/passport.js:49 +msgid "%s logged out" +msgstr "%s è uscito" + +#: lib/passport.js:63 +msgid "Failed to authenticate user" +msgstr "Impossibile verificare utente" + +#: lib/passport.js:79 +msgid "Logged in as %s" +msgstr "Connesso come %s" + +#: lib/passport.js:179 +msgid "Incorrect username or password" +msgstr "Nome utente o password errata" + +#: lib/subscription-mail-helpers.js:28 +msgid "%s: Subscription Confirmed" +msgstr "%s: Iscrizione confermata" + +#: lib/subscription-mail-helpers.js:39 +msgid "%s: Email Address Already Registered" +msgstr "%s: Indirizzo email già iscritto" + +#: lib/subscription-mail-helpers.js:49 +msgid "%s: Please Confirm Email Change in Subscription" +msgstr "%s: Per favore conferma il cambio di indirizzo email nell'iscrizione" + +#: lib/subscription-mail-helpers.js:59 +msgid "%s: Please Confirm Subscription" +msgstr "%s: Per favore conferma la tua iscrizione" + +#: lib/subscription-mail-helpers.js:69 +msgid "%s: Please Confirm Unsubscription" +msgstr "%s: Per favore conferma l'intenzione di rimuovere l'iscrizione" + +#: lib/subscription-mail-helpers.js:76 +msgid "%s: Unsubscription Confirmed" +msgstr "%s: Rimozione dell'iscrizione confermata" + +#: lib/tools.js:154 +msgid "Blocked email address \"%s\"" +msgstr "Email \"%s\" bloccata" + +#: lib/tools.js:163 +msgid "Invalid email address \"%s\"." +msgstr "Email \"%s\" invalida." + +#: lib/tools.js:166 +msgid "MX record not found for domain" +msgstr "Non trovo gli MX records per il dominio" + +#: lib/tools.js:169 +msgid "Address domain not found" +msgstr "Dominio dell'indirizzo non trovato" + +#: lib/tools.js:172 +msgid "Address domain name is required" +msgstr "Il dominio dell'indirizzo è obbligatorio" + +#: routes/archive.js:31 routes/archive.js:43 routes/archive.js:55 app.js:230 +msgid "Not Found" +msgstr "Non trovato" + +#: routes/archive.js:121 services/sender.js:449 +msgid "Received status code %s from %s" +msgstr "Ricevuto codice di stato %s da %s" + +#: routes/archive.js:153 routes/campaigns.js:894 +msgid "Attachment not found" +msgstr "Allegato non trovato" + +#: routes/blacklist.js:13 routes/campaigns.js:26 routes/editorapi.js:32 +#: routes/fields.js:13 routes/forms.js:16 routes/grapejs.js:15 +#: routes/lists.js:50 routes/mosaico.js:14 routes/report-templates.js:20 +#: routes/reports.js:22 routes/segments.js:13 routes/settings.js:23 +#: routes/templates.js:18 routes/triggers.js:18 routes/users.js:75 +#: routes/users.js:120 +msgid "Need to be logged in to access restricted content" +msgstr "Devi aver effettuato l'accesso per accedere ai contenuti riservati" + +#: routes/campaigns.js:117 +msgid "Could not create campaign" +msgstr "Impossibile creare la campagna" + +#: routes/campaigns.js:120 +msgid "Campaign “%s” created" +msgstr "Campagna \"%s\" creata" + +#: routes/campaigns.js:209 +msgid "Campaign settings updated" +msgstr "Impostazioni della campagna aggiornate" + +#: routes/campaigns.js:211 +msgid "Campaign settings not updated" +msgstr "Impostazioni della campagna non aggiornata" + +#: routes/campaigns.js:227 routes/campaigns.js:744 +msgid "Campaign deleted" +msgstr "Campagna eliminata" + +#: routes/campaigns.js:229 routes/campaigns.js:746 +msgid "Could not delete specified campaign" +msgstr "Impossibile cancellare la campagna selezionata" + +#: routes/campaigns.js:248 +msgid "Idling" +msgstr "Aspettando" + +#: routes/campaigns.js:251 +msgid "Scheduled" +msgstr "In programma" + +#: routes/campaigns.js:257 +msgid "Paused" +msgstr "In pausa" + +#: routes/campaigns.js:259 +msgid "Inactive" +msgstr "Inattiva" + +#: routes/campaigns.js:261 +msgid "Active" +msgstr "Attiva" + +#: routes/campaigns.js:263 +msgid "Other" +msgstr "Altro" + +#: routes/campaigns.js:421 +msgid "Unknown status selector" +msgstr "Selettore di stato non trovato" + +#: routes/campaigns.js:762 +msgid "Scheduled sending" +msgstr "Invio programmato" + +#: routes/campaigns.js:764 +msgid "Could not schedule sending" +msgstr "Impossibile programmare l'invio" + +#: routes/campaigns.js:776 +msgid "Sending resumed" +msgstr "Invio ripreso" + +#: routes/campaigns.js:778 +msgid "Could not resume sending" +msgstr "Impossibile riprendere invio" + +#: routes/campaigns.js:790 +msgid "Sending reset" +msgstr "Reset invio" + +#: routes/campaigns.js:792 +msgid "Could not reset sending" +msgstr "Impossibile resettare l'invio" + +#: routes/campaigns.js:804 routes/campaigns.js:832 +msgid "Sending paused" +msgstr "Invio in pausa" + +#: routes/campaigns.js:806 routes/campaigns.js:834 +msgid "Could not pause sending" +msgstr "Impossibile mettere in pausa l'invio" + +#: routes/campaigns.js:818 +msgid "Sending activated" +msgstr "Invio attivato" + +#: routes/campaigns.js:820 +msgid "Could not activate sending" +msgstr "Impossibile attivare l'invio" + +#: routes/campaigns.js:855 +msgid "Attachment uploaded" +msgstr "Allegato caricato" + +#: routes/campaigns.js:857 +msgid "Could not store attachment" +msgstr "Impossibile salvare allegato" + +#: routes/campaigns.js:874 +msgid "Attachment deleted" +msgstr "Allegato eliminato" + +#: routes/campaigns.js:876 +msgid "Could not delete attachment" +msgstr "Impossibile eliminare allegato" + +#: routes/editorapi.js:38 +msgid "Invalid editor name" +msgstr "Nome editor invalido" + +#: routes/editorapi.js:146 +msgid "Method not supported" +msgstr "Metodo non supportato" + +#: routes/editorapi.js:381 +msgid "Invalid resource type or ID" +msgstr "ID o tipo di risorsa invalido" + +#: routes/fields.js:28 routes/fields.js:64 routes/fields.js:118 +#: routes/forms.js:31 routes/forms.js:63 routes/forms.js:94 +#: routes/segments.js:28 routes/segments.js:59 routes/segments.js:102 +#: routes/segments.js:151 routes/segments.js:223 routes/segments.js:255 +#: routes/segments.js:289 routes/segments.js:336 routes/segments.js:359 +msgid "Selected list ID not found" +msgstr "ID lista selezionata non trovata" + +#: routes/fields.js:102 +msgid "Could not create custom field" +msgstr "Impossibile creare campo personalizzato" + +#: routes/fields.js:129 +msgid "Selected field not found" +msgstr "Campo selezionato non trovato" + +#: routes/fields.js:165 +msgid "Field settings updated" +msgstr "Impostazioni campo aggiornate" + +#: routes/fields.js:167 +msgid "Field settings not updated" +msgstr "Impostazioni campo non aggiornate" + +#: routes/fields.js:183 +msgid "Custom field deleted" +msgstr "Campo personalizzato eliminato" + +#: routes/fields.js:185 +msgid "Could not delete specified field" +msgstr "Impossibile eliminare campo specificato" + +#: routes/forms.js:78 +msgid "Could not create custom form" +msgstr "Impossibile creare campo personalizzato" + +#: routes/forms.js:105 +msgid "Selected form not found" +msgstr "Form selezionato non trovato" + +#: routes/forms.js:136 +msgid "The plaintext version for this email" +msgstr "La versione di solo testo della mail" + +#: routes/forms.js:137 +msgid "Custom forms use MJML for formatting" +msgstr "I form personalizzati usano MJML per la formattazione" + +#: routes/forms.js:138 +msgid "See the MJML documentation here" +msgstr "" +"Guarda la documentazione di MJML qui" + +#: routes/forms.js:146 +msgid "Layout" +msgstr "Layout" + +#: routes/forms.js:152 +msgid "Form Input Style" +msgstr "Stile input del form" + +#: routes/forms.js:154 +msgid "" +"This CSS stylesheet defines the appearance of form input elements and alerts" +msgstr "" +"Questo stylesheet CSS definisce lo stile degli elementi di input dei form e " +"degli alert" + +#: routes/forms.js:160 +msgid "Web - Subscribe" +msgstr "Web - Iscriviti" + +#: routes/forms.js:165 +msgid "Web - Confirm Subscription Notice" +msgstr "Web - Notifica di conferma dell'iscrizione" + +#: routes/forms.js:170 +msgid "Mail - Confirm Subscription (MJML)" +msgstr "Mail - Conferma di iscrizione (MJML)" + +#: routes/forms.js:175 +msgid "Mail - Confirm Subscription (Text)" +msgstr "Mail - Conferma di iscrizione (Testo)" + +#: routes/forms.js:180 +msgid "Mail - Already Subscribed (MJML)" +msgstr "Mail - Già iscritto (MJML)" + +#: routes/forms.js:185 +msgid "Mail - Already Subscribed (Text)" +msgstr "Mail - Già iscritto (Testo)" + +#: routes/forms.js:190 +msgid "Web - Subscribed Notice" +msgstr "Web - Notifica di iscrizione" + +#: routes/forms.js:195 +msgid "Mail - Subscription Confirmed (MJML)" +msgstr "Mail - Conferma di iscrizione (MJML)" + +#: routes/forms.js:200 +msgid "Mail - Subscription Confirmed (Text)" +msgstr "Mail - Conferma di iscrizione (Testo)" + +#: routes/forms.js:208 +msgid "Web - Manage Preferences" +msgstr "Web - Gestisci l preferenze" + +#: routes/forms.js:213 +msgid "Web - Manage Address" +msgstr "Web - Gestisci indirizzo" + +#: routes/forms.js:218 +msgid "Web - Updated Notice" +msgstr "Web - Notifica di aggiornamento" + +#: routes/forms.js:226 +msgid "Web - Unsubscribe" +msgstr "Web - Rimozione iscrizione" + +#: routes/forms.js:231 +msgid "Web - Confirm Unsubscription Notice" +msgstr "Web - Conferma la notifica di rimozione dell'iscrizione" + +#: routes/forms.js:236 +msgid "Mail - Confirm Unsubscription (MJML)" +msgstr "Mail - Conferma la rimozione dell'iscrizione (MJML)" + +#: routes/forms.js:241 +msgid "Mail - Confirm Unsubscription (Text)" +msgstr "Mail - Conferma la rimozione dell'iscrizione (Text)" + +#: routes/forms.js:246 +msgid "Mail - Confirm Address Change (MJML)" +msgstr "Mail - Conferma il cambio di indirizzo (MJML)" + +#: routes/forms.js:251 +msgid "Mail - Confirm Address Change (Text)" +msgstr "Mail - Conferma il cambio di indirizzo (Testo)" + +#: routes/forms.js:256 +msgid "Web - Unsubscribed Notice" +msgstr "Web - Notifica di rimozione" + +#: routes/forms.js:261 +msgid "Mail - Unsubscription Confirmed (MJML)" +msgstr "Mail - Rimozione confermata (MJML)" + +#: routes/forms.js:266 +msgid "Mail - Unsubscription Confirmed (Text)" +msgstr "Mail - Rimozione confermata (Text)" + +#: routes/forms.js:271 +msgid "Web - Manual Unsubscribe Notice" +msgstr "Web - Notifica di rimozione manuale" + +#: routes/forms.js:309 +msgid "Form settings updated" +msgstr "Impostazioni form aggiornate" + +#: routes/forms.js:311 +msgid "Form settings not updated" +msgstr "Impostazioni form non aggiornate" + +#: routes/forms.js:327 +msgid "Custom form deleted" +msgstr "Form personalizzato non cancellato" + +#: routes/forms.js:329 +msgid "Could not delete specified form" +msgstr "Impossibile eliminare il form specificato" + +#: routes/index.js:11 +msgid "Self Hosted Newsletter App" +msgstr "Applicazione di newsletter self-hosted" + +#: routes/links.js:39 +msgid "Oops, we couldn't find a link for the URL you clicked" +msgstr "Oops, non riusciamo a trovare un link per l'URL che hai cliccato" + +#: routes/lists.js:82 +msgid "Could not create list" +msgstr "Impossibile creare lista" + +#: routes/lists.js:85 +msgid "List created" +msgstr "Lista creata" + +#: routes/lists.js:93 routes/lists.js:271 routes/lists.js:336 +#: routes/lists.js:375 routes/lists.js:444 routes/lists.js:469 +#: routes/lists.js:514 routes/lists.js:536 routes/lists.js:565 +#: routes/lists.js:657 routes/lists.js:714 routes/lists.js:741 +msgid "Could not find list with specified ID" +msgstr "Impossibile trovare la lista dell'ID specificato" + +#: routes/lists.js:122 +msgid "List settings updated" +msgstr "Impostazioni lista aggiornate" + +#: routes/lists.js:124 +msgid "List settings not updated" +msgstr "Impostazioni lista non aggiornate" + +#: routes/lists.js:142 +msgid "List deleted" +msgstr "Lista cancellata" + +#: routes/lists.js:144 +msgid "Could not delete specified list" +msgstr "Impossibile cancellare la lista specificata" + +#: routes/lists.js:206 +msgid "Unknown" +msgstr "Sconosciuto" + +#: routes/lists.js:206 +msgid "Complained" +msgstr "Reclamato" + +#: routes/lists.js:237 +msgid "Invalid key" +msgstr "Chiave invalida" + +#: routes/lists.js:239 +msgid "Expired key" +msgstr "Chiave scaduta" + +#: routes/lists.js:241 +msgid "Revoked key" +msgstr "Chiave revocate" + +#: routes/lists.js:288 +msgid "Force Subscribe" +msgstr "Forza iscrizione" + +#: routes/lists.js:291 +msgid "Initializing" +msgstr "Inizializzando" + +#: routes/lists.js:294 +msgid "Initialized" +msgstr "Inizializzato" + +#: routes/lists.js:297 +msgid "Importing" +msgstr "Importando" + +#: routes/lists.js:303 +msgid "Errored" +msgstr "Errore" + +#: routes/lists.js:381 routes/lists.js:450 routes/lists.js:475 +msgid "Could not find subscriber with specified ID" +msgstr "Iscritto con ID specificato non trovato" + +#: routes/lists.js:427 +msgid "Could not add subscription" +msgstr "Impossibile aggiungere iscrizione" + +#: routes/lists.js:432 +msgid "%s was successfully added to your list" +msgstr "%s aggiunto alla lista con successo" + +#: routes/lists.js:434 +msgid "%s was not added to your list" +msgstr "%s non aggiunto alla lista" + +#: routes/lists.js:456 +msgid "Could not unsubscribe user" +msgstr "Impossibile rimuovere iscrizione utente" + +#: routes/lists.js:459 +msgid "%s was successfully unsubscribed from your list" +msgstr "Rimozione iscrizione % dalla lista avvenuta con successo" + +#: routes/lists.js:479 +msgid "%s was successfully removed from your list" +msgstr "Iscrizione %s cancellata con successo" + +#: routes/lists.js:491 +msgid "Another subscriber with email address %s already exists" +msgstr "Una iscrizione con l'email %s esiste già" + +#: routes/lists.js:498 +msgid "Subscription settings updated" +msgstr "Impostazioni di iscrizione aggiornate" + +#: routes/lists.js:500 +msgid "Subscription settings not updated" +msgstr "Impostazioni di iscrizione non aggiornate" + +#: routes/lists.js:542 routes/lists.js:663 routes/lists.js:699 +#: routes/lists.js:727 routes/lists.js:747 +msgid "Could not find import data with specified ID" +msgstr "Impossibile trovare dati di importo per l'ID specificato" + +#: routes/lists.js:573 +msgid "Could not process CSV" +msgstr "Impossibile elaborare CSV" + +#: routes/lists.js:589 +msgid "Could not create importer" +msgstr "Impossibile creare una importazione" + +#: routes/lists.js:643 +msgid "Empty file" +msgstr "File vuoto" + +#: routes/lists.js:646 +msgid "Too few rows" +msgstr "Troppe poche righe" + +#: routes/lists.js:703 +msgid "Import started" +msgstr "Importazione iniziato" + +#: routes/lists.js:731 +msgid "Import restarted" +msgstr "Importazione riniziato" + +#: routes/lists.js:797 +msgid "One-step (i.e. no email with confirmation link)" +msgstr "Uno step (no email con link di conferma)" + +#: routes/lists.js:803 +msgid "" +"One-step with unsubscription form (i.e. no email with confirmation link)" +msgstr "Uno step con form di cancellazione (no email con link di conferma)" + +#: routes/lists.js:809 +msgid "Two-step (i.e. an email with confirmation link will be sent)" +msgstr "Due step (una email con link di conferma viene inviata)" + +#: routes/lists.js:815 +msgid "" +"Two-step with unsubscription form (i.e. an email with confirmation link will " +"be sent)" +msgstr "" +"Form di cancellazione a due step (una mail con link di conferma viene " +"inviata)" + +#: routes/lists.js:821 +msgid "" +"Manual (i.e. unsubscription has to be performed by the list administrator)" +msgstr "" +"Manuale (p.es. la cancellazione deve essere eseguita dall'amministratore " +"della lista)" + +#: routes/report-templates.js:246 +msgid "Could not create report template" +msgstr "Impossibile creare il template di report" + +#: routes/report-templates.js:249 +msgid "Report template “%s” created" +msgstr "Template report \"%s\" creato" + +#: routes/report-templates.js:257 +msgid "Could not find report template with specified ID" +msgstr "Impossibile trovare il template del report specificato" + +#: routes/report-templates.js:280 +msgid "Report template updated" +msgstr "Template report aggiornato" + +#: routes/report-templates.js:282 +msgid "Report template not updated" +msgstr "Template report non aggiornato" + +#: routes/report-templates.js:298 +msgid "Report template deleted" +msgstr "Template report eliminato" + +#: routes/report-templates.js:300 +msgid "Could not delete specified report template" +msgstr "Impossibile eliminare il template del report" + +#: routes/reports.js:124 routes/reports.js:130 +msgid "Could not create report" +msgstr "Impossibile creare il report" + +#: routes/reports.js:135 +msgid "Report “%s” created" +msgstr "Creato report \"%s\"" + +#: routes/reports.js:146 routes/reports.js:224 routes/reports.js:239 +#: routes/reports.js:265 routes/reports.js:275 +msgid "Could not find report with specified ID" +msgstr "Impossibile trovare il report con l'ID specificato" + +#: routes/reports.js:188 routes/reports.js:194 +msgid "Could not update report" +msgstr "Impossibile aggiornare il report" + +#: routes/reports.js:197 +msgid "Report updated" +msgstr "Report aggiornato" + +#: routes/reports.js:199 +msgid "Report not updated" +msgstr "Report non aggiornato" + +#: routes/reports.js:212 +msgid "Report deleted" +msgstr "Report eliminato" + +#: routes/reports.js:214 +msgid "Could not delete specified report" +msgstr "Impossibile eliminare il report specificato" + +#: routes/reports.js:230 +msgid "Could not find report template" +msgstr "Template di reportistica non trovato" + +#: routes/reports.js:260 +msgid "Unknown type of template" +msgstr "Tipo di template sconosciuto" + +#: routes/segments.js:86 +msgid "Could not create segment" +msgstr "Impossibile creare segmento" + +#: routes/segments.js:89 +msgid "Segment created" +msgstr "Segmento creato" + +#: routes/segments.js:113 +msgid "Selected segment ID not found" +msgstr "Segmento selezionato non trovato" + +#: routes/segments.js:188 +msgid "Segment settings updated" +msgstr "Impostazioni segmento aggiornate" + +#: routes/segments.js:190 +msgid "Segment settings not updated" +msgstr "Impostazioni segmento non aggiornate" + +#: routes/segments.js:206 +msgid "Segment deleted" +msgstr "Segmento cancellato" + +#: routes/segments.js:208 +msgid "Could not delete specified segment" +msgstr "Impossibile eliminare il segmento specifcato" + +#: routes/segments.js:342 +msgid "Could not create rule" +msgstr "Impossibile creare la regola" + +#: routes/segments.js:345 +msgid "Rule created" +msgstr "Regola creata" + +#: routes/segments.js:410 +msgid "Rule settings updated" +msgstr "Impostazioni regola aggiornate" + +#: routes/segments.js:412 +msgid "Rule settings not updated" +msgstr "Impostazioni regola non aggiornate" + +#: routes/segments.js:428 +msgid "Rule deleted" +msgstr "Regola cancellata" + +#: routes/segments.js:430 +msgid "Could not delete specified rule" +msgstr "Impossibile eliminare la regola specificata" + +#: routes/settings.js:39 +msgid "Use TLS" +msgstr "Usa TLS" + +#: routes/settings.js:40 +msgid "usually selected for port 465" +msgstr "usualmente selezionata per la porta 465" + +#: routes/settings.js:44 +msgid "Use STARTTLS" +msgstr "Usa STARTTLS" + +#: routes/settings.js:45 +msgid "usually selected for port 587 and 25" +msgstr "usualmente selezionate per le porte 587 e 25" + +#: routes/settings.js:49 +msgid "Do not use encryption" +msgstr "Non usare crittografia" + +#: routes/settings.js:115 +msgid "Settings updated" +msgstr "Impostazioni aggiornate" + +#: routes/settings.js:173 +msgid "Invalid mail transport type" +msgstr "Tipo di trasporto mail invalido" + +#: routes/settings.js:184 +msgid "Invalid Access Key" +msgstr "Chiave di accesso invalida" + +#: routes/settings.js:187 +msgid "Invalid AWS credentials" +msgstr "Credenziali AWS invalide" + +#: routes/settings.js:190 +msgid "Connection refused, check hostname and port." +msgstr "Connessione rifiutata, controlla hostname e porta." + +#: routes/settings.js:195 +msgid "" +"Did not receive greeting message from server. This might happen when " +"connecting to a TLS port without using TLS." +msgstr "" +"Non ho ricevuto il messaggio di saluto dal server. Questo può succedere " +"quando ci si connette ad una porta TLS senza utilizzare TLS." + +#: routes/settings.js:197 +msgid "Did not receive greeting message from server." +msgstr "Non ho ricevuto il messaggio di saluto dal server." + +#: routes/settings.js:200 +msgid "" +"Connection timed out. Check your firewall settings, destination port is " +"probably blocked." +msgstr "" +"Tempo di connessione scaduto. Controlla il tuo firewall, le porte sono " +"probabilmente chiuse." + +#: routes/settings.js:205 +msgid "Authentication not accepted, server expects STARTTLS to be used." +msgstr "" +"Autenticazione non accettata, il server richiede l'utilizzo di STARTTLS." + +#: routes/settings.js:207 +msgid "Authentication failed, check username and password." +msgstr "Autenticazione fallita, controlla il nome utente e la password." + +#: routes/settings.js:217 +msgid "Failed Mailer verification." +msgstr "Verifica delle impostazioni di invio mail fallita." + +#: routes/settings.js:217 +msgid "Server responded with: \"%s\"" +msgstr "Il Server ha risposto con: \"%s\"" + +#: routes/settings.js:221 +msgid "Mailer settings verified, ready to send some mail!" +msgstr "" +"Impostazioni di invio mail verificate, il software è pronto per inviare " +"delle mail!" + +#: routes/subscription.js:33 +msgid "Not allowed by CORS" +msgstr "Non permesso dalle impostazioni CORS" + +#: routes/subscription.js:61 routes/subscription.js:176 +#: routes/subscription.js:286 routes/subscription.js:382 +#: routes/subscription.js:459 routes/subscription.js:535 +#: routes/subscription.js:566 routes/subscription.js:626 +#: routes/subscription.js:682 routes/subscription.js:760 +#: routes/subscription.js:897 +msgid "Selected list not found" +msgstr "Lista selezionata non trovata" + +#: routes/subscription.js:93 +msgid "Could not save subscription" +msgstr "Impossibile salvare l'iscrizione" + +#: routes/subscription.js:118 +msgid "Subscriber info corrupted or missing" +msgstr "Informazioni iscritto corrotte o mancanti" + +#: routes/subscription.js:136 +msgid "Email address changed" +msgstr "Indirizzo email aggiornato" + +#: routes/subscription.js:179 routes/subscription.js:385 +msgid "The list does not allow public subscriptions." +msgstr "L'iscrizione alla lista non è pubblica." + +#: routes/subscription.js:355 routes/subscription.js:357 +msgid "Email address not set" +msgstr "Indirizzo email non impostato" + +#: routes/subscription.js:653 +msgid "" +"An email with further instructions has been sent to the provided address" +msgstr "" +"Una email con ulteriori istruzioni è stata inviata all'indirizzo fornito" + +#: routes/subscription.js:861 routes/subscription.js:877 +msgid "Public key is not set" +msgstr "la chiave pubblica non è impostata" + +#: routes/templates.js:84 +msgid "Could not create template" +msgstr "Impossibile creare template" + +#: routes/templates.js:87 +msgid "Template created" +msgstr "Template creato" + +#: routes/templates.js:126 +msgid "Template settings updated" +msgstr "Impostazioni template aggiornate" + +#: routes/templates.js:128 +msgid "Template settings not updated" +msgstr "Impostazioni template non aggiornate" + +#: routes/templates.js:144 +msgid "Template duplicated" +msgstr "Template duplicato" + +#: routes/templates.js:146 +msgid "Could not duplicate specified template" +msgstr "Impossibile duplicare il template specificato" + +#: routes/templates.js:157 +msgid "Template deleted" +msgstr "Template cancellato" + +#: routes/templates.js:159 +msgid "Could not delete specified template" +msgstr "Impossibile eliminare il template selezionato" + +#: routes/triggers.js:62 routes/triggers.js:79 routes/triggers.js:154 +msgid "Could not find selected list" +msgstr "Lista selezionata non trovata" + +#: routes/triggers.js:131 +msgid "Could not create trigger" +msgstr "Impossibile creare il trigger" + +#: routes/triggers.js:138 +msgid "Trigger “%s” created" +msgstr "Trigger \"%s\" creato" + +#: routes/triggers.js:214 +msgid "Trigger settings updated" +msgstr "Impostazioni trigger aggiornate" + +#: routes/triggers.js:216 +msgid "Trigger settings not updated" +msgstr "Impostazioni trigger non aggiornate" + +#: routes/triggers.js:228 +msgid "Trigger deleted" +msgstr "Trigger cancellato" + +#: routes/triggers.js:230 +msgid "Could not delete specified trigger" +msgstr "Impossibile eliminare il trigger specificato" + +#: routes/triggers.js:242 +msgid "Could not find trigger with specified ID" +msgstr "Trigger non trovato con l'ID specificato" + +#: routes/triggers.js:255 +msgid "Trigger not found" +msgstr "Trigger non trovato" + +#: routes/users.js:32 +msgid "" +"An email with password reset instructions has been sent to your email " +"address, if it exists on our system." +msgstr "" +"Una mail con le istruzioni di ripristino password sono state inviate alla " +"tua mail, se esiste nel sistema." + +#: routes/users.js:46 routes/users.js:64 +msgid "Unknown or expired reset token" +msgstr "Token sconosciuto o scaduto" + +#: routes/users.js:66 +msgid "Your password has been changed successfully" +msgstr "La tua password è stata cambiata con successo" + +#: routes/users.js:87 +msgid "User data not found" +msgstr "Dati utente non trovati" + +#: routes/users.js:110 +msgid "Access token updated" +msgstr "Token di accesso aggiornati" + +#: routes/users.js:112 +msgid "Access token not updated" +msgstr "Token di access non aggiornati" + +#: routes/users.js:139 +msgid "Account information updated" +msgstr "Informazioni account aggiornate" + +#: routes/users.js:141 +msgid "Account information not updated" +msgstr "Informazioni account non aggiornate" + +#: services/feedcheck.js:51 +msgid "Feed error: %s" +msgstr "Errore feed %s" + +#: services/feedcheck.js:54 +msgid "Found %s new campaign messages from feed" +msgstr "Trovato un nuovo messaggio %s per la campagna dal feed" + +#: services/feedcheck.js:56 +msgid "Found nothing new from the feed" +msgstr "Nulla di nuovo dal feed" + +#: services/feedcheck.js:146 +msgid "RSS entry %s" +msgstr "RSS %s" + +#: services/importer.js:249 +msgid "Could not access import file" +msgstr "Impossibile accedere al file da importare" + +#: services/triggers.js:51 +msgid "Unknown trigger type %s" +msgstr "Trigger %s sconosciuto" diff --git a/obsolete/lib/models/campaigns.js b/obsolete/lib/models/campaigns.js index 8d7bc899..e9b178ea 100644 --- a/obsolete/lib/models/campaigns.js +++ b/obsolete/lib/models/campaigns.js @@ -16,7 +16,7 @@ let _ = require('../translate')._; let util = require('util'); let tableHelpers = require('../table-helpers'); -let allowedKeys = ['description', 'from', 'address', 'reply_to', 'subject', 'editor_name', 'editor_data', 'template', 'source_url', 'list', 'segment', 'html', 'text', 'click_tracking_disabled', 'open_tracking_disabled']; +let allowedKeys = ['description', 'from', 'address', 'reply_to', 'subject', 'editor_name', 'editor_data', 'template', 'source_url', 'list', 'segment', 'html', 'text', 'click_tracking_disabled', 'open_tracking_disabled', 'unsubscribe']; module.exports.list = (start, limit, callback) => { tableHelpers.list('campaigns', ['*'], 'scheduled', null, start, limit, callback); diff --git a/obsolete/lib/models/lists.js b/obsolete/lib/models/lists.js index 11103b48..8b1d8a8e 100644 --- a/obsolete/lib/models/lists.js +++ b/obsolete/lib/models/lists.js @@ -11,7 +11,7 @@ const UnsubscriptionMode = require('../../shared/lists').UnsubscriptionMode; module.exports.UnsubscriptionMode = UnsubscriptionMode; -let allowedKeys = ['description', 'default_form', 'public_subscribe', 'unsubscription_mode']; +let allowedKeys = ['description', 'default_form', 'public_subscribe', 'unsubscription_mode', 'listunsubscribe_disabled']; module.exports.list = (start, limit, callback) => { tableHelpers.list('lists', ['*'], 'name', null, start, limit, callback); @@ -150,6 +150,7 @@ module.exports.update = (id, updates, callback) => { // The update can be only partial when executed from forms/:list if (!data.customFormChangeOnly) { data.publicSubscribe = data.publicSubscribe ? 1 : 0; + data.listunsubscribeDisabled = data.listunsubscribeDisabled ? 1 : 0; data.unsubscriptionMode = Number(data.unsubscriptionMode); let name = (data.name || '').toString().trim(); diff --git a/obsolete/lib/models/segments.js b/obsolete/lib/models/segments.js index 47a3afbc..209f12e7 100644 --- a/obsolete/lib/models/segments.js +++ b/obsolete/lib/models/segments.js @@ -156,7 +156,7 @@ module.exports.get = (id, callback) => { rule.formatted = rule.value.value ? _('Selected') : _('Not selected'); break; default: - rule.formatted = rule.value.value || ''; + rule.formatted = (rule.value.negate ? '!= ' : '') + (rule.value.value || ''); } return rule; @@ -327,6 +327,7 @@ module.exports.createRule = (segmentId, rule, callback) => { break; default: value = { + negate: Number(rule.negate) ? 1 : 0, value: rule.value }; } @@ -418,7 +419,7 @@ module.exports.getRule = (id, callback) => { rule.formatted = rule.value.value ? _('Selected') : _('Not selected'); break; default: - rule.formatted = rule.value.value || ''; + rule.formatted = (rule.value.negate ? '!= ' : '') + (rule.value.value || ''); } return callback(null, rule); @@ -491,6 +492,7 @@ module.exports.updateRule = (id, rule, callback) => { break; default: value = { + negate: Number(rule.negate) ? 1 : 0, value: rule.value }; } @@ -573,7 +575,8 @@ module.exports.getQuery = (id, prefix, callback) => { segment.rules.forEach(rule => { switch (rule.columnType.type) { case 'string': - query.push(prefix + '`' + rule.columnType.column + '` LIKE ?'); + let condition = rule.value.negate ? 'NOT LIKE' : 'LIKE'; + query.push(prefix + '`' + rule.columnType.column + '` ' + condition + ' ?'); values.push(rule.value.value); break; case 'boolean': diff --git a/obsolete/lib/models/subscriptions.js b/obsolete/lib/models/subscriptions.js index 0ba6d091..941a3352 100644 --- a/obsolete/lib/models/subscriptions.js +++ b/obsolete/lib/models/subscriptions.js @@ -247,7 +247,7 @@ module.exports.get = (listId, cid, callback) => { cid = (cid || '').toString().trim(); if (!cid) { - return callback(new Error(_('Missing Subbscription ID'))); + return callback(new Error(_('Missing Subscription ID'))); } db.getConnection((err, connection) => { @@ -277,7 +277,7 @@ module.exports.getById = (listId, id, callback) => { id = Number(id) || 0; if (!id) { - return callback(new Error(_('Missing Subbscription ID'))); + return callback(new Error(_('Missing Subscription ID'))); } db.getConnection((err, connection) => { @@ -305,7 +305,7 @@ module.exports.getById = (listId, id, callback) => { module.exports.getByEmail = (listId, email, callback) => { if (!email) { - return callback(new Error(_('Missing Subbscription email address'))); + return callback(new Error(_('Missing Subscription email address'))); } db.getConnection((err, connection) => { diff --git a/obsolete/lib/models/triggers.js b/obsolete/lib/models/triggers.js index 6d2e49c6..b87125c4 100644 --- a/obsolete/lib/models/triggers.js +++ b/obsolete/lib/models/triggers.js @@ -1,8 +1,10 @@ 'use strict'; +let log = require('npmlog'); let tools = require('../tools'); let db = require('../db'); let lists = require('./lists'); +let segments = require('./segments'); let util = require('util'); let _ = require('../translate')._; let tableHelpers = require('../table-helpers'); @@ -55,7 +57,9 @@ module.exports.list = callback => { '`triggers`.`description` AS `description`', '`triggers`.`enabled` AS `enabled`', '`triggers`.`list` AS `list`', + '`triggers`.`segment` AS `segment`', '`lists`.`name` AS `list_name`', + '`segments`.`name` AS `segment_name`', '`source`.`id` AS `source_campaign`', '`source`.`name` AS `source_campaign_name`', '`dest`.`id` AS `dest_campaign`', @@ -69,7 +73,7 @@ module.exports.list = callback => { '`triggers`.`created` AS `created`' ]; - let query = 'SELECT ' + tableFields.join(', ') + ' FROM `triggers` LEFT JOIN `campaigns` `source` ON `source`.`id`=`triggers`.`source_campaign` LEFT JOIN `campaigns` `dest` ON `dest`.`id`=`triggers`.`dest_campaign` LEFT JOIN `lists` ON `lists`.`id`=`triggers`.`list` LEFT JOIN `custom_fields` ON `custom_fields`.`list` = `triggers`.`list` AND `custom_fields`.`column`=`triggers`.`column` ORDER BY `triggers`.`name`'; + let query = 'SELECT ' + tableFields.join(', ') + ' FROM `triggers` LEFT JOIN `campaigns` `source` ON `source`.`id`=`triggers`.`source_campaign` LEFT JOIN `campaigns` `dest` ON `dest`.`id`=`triggers`.`dest_campaign` LEFT JOIN `lists` ON `lists`.`id`=`triggers`.`list` LEFT JOIN `segments` ON `segments`.`id`=`triggers`.`segment` LEFT JOIN `custom_fields` ON `custom_fields`.`list` = `triggers`.`list` AND `custom_fields`.`column`=`triggers`.`column` ORDER BY `triggers`.`name`'; connection.query(query, (err, rows) => { connection.release(); if (err) { @@ -105,32 +109,70 @@ module.exports.getQuery = (id, callback) => { let intervalQuery = (column, seconds, treshold) => column + ' <= NOW() - INTERVAL ' + seconds + ' SECOND AND ' + column + ' >= NOW() - INTERVAL ' + (treshold + seconds) + ' SECOND'; - let query = false; - switch (trigger.rule) { - case 'subscription': - query = 'SELECT id FROM `subscription__' + trigger.list + '` subscription WHERE ' + intervalQuery('`' + trigger.column + '`', trigger.seconds, treshold) + ' AND id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; - case 'campaign': - switch (trigger.column) { - case 'delivered': - query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; - case 'not_clicked': - query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=0 WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' AND tracker.created IS NULL AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; - case 'not_opened': - query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=-1 WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' AND tracker.created IS NULL AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; - case 'clicked': - query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=0 WHERE campaign.status=1 AND ' + intervalQuery('`tracker`.`created`', trigger.seconds, treshold) + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; - case 'opened': - query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=-1 WHERE campaign.status=1 AND ' + intervalQuery('`tracker`.`created`', trigger.seconds, treshold) + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; - break; + + let getSegmentQuery = (segmentId, next) => { + segmentId = Number(segmentId); + if (!segmentId) { + return next(null, { + where: '', + values: [] + }); + } + + segments.getQuery(segmentId, 'subscription', next); + }; + + getSegmentQuery(trigger.segment, (err, queryData) => { + if (err) { + log.err('Triggers', err); + return null; + } + + let query = false; + let querySegmentSubscription = ''; + let querySegmentTriggertable = ''; + if (trigger.segment > 0) + { + querySegmentSubscription = (queryData.where ? ' AND (' + queryData.where + ')' : ''); + querySegmentTriggertable = ' AND triggertable.`segment` = ' + trigger.segment; + } + + switch (trigger.rule) { + case 'subscription': + query = 'SELECT id FROM `subscription__' + trigger.list + '` subscription WHERE status=1 AND ' + intervalQuery('`' + trigger.column + '`', trigger.seconds, treshold) + ' ' + querySegmentSubscription + ' AND id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + case 'campaign': + switch (trigger.column) { + case 'delivered': + query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' ' + querySegmentSubscription + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + case 'not_clicked': + query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=0 WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' AND tracker.created IS NULL ' + querySegmentSubscription + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + case 'not_opened': + query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=-1 WHERE campaign.status=1 AND ' + intervalQuery('`campaign`.`created`', trigger.seconds, treshold) + ' AND tracker.created IS NULL ' + querySegmentSubscription + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + case 'clicked': + query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=0 WHERE campaign.status=1 AND ' + intervalQuery('`tracker`.`created`', trigger.seconds, treshold) + ' ' + querySegmentSubscription + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + case 'opened': + query = 'SELECT subscription.id AS id FROM `subscription__' + trigger.list + '` subscription LEFT JOIN `campaign__' + trigger.sourceCampaign + '` campaign ON campaign.list=' + trigger.list + ' AND subscription.id=campaign.subscription LEFT JOIN `campaign_tracker__' + trigger.sourceCampaign + '` tracker ON tracker.list=campaign.list AND tracker.subscriber=subscription.id AND tracker.link=-1 WHERE campaign.status=1 AND ' + intervalQuery('`tracker`.`created`', trigger.seconds, treshold) + ' ' + querySegmentSubscription + ' AND subscription.id NOT IN (SELECT subscription FROM `trigger__' + id + '` triggertable WHERE triggertable.`list` = ' + trigger.list + ' ' + querySegmentTriggertable + ' AND triggertable.`subscription` = subscription.`id`) LIMIT ' + limit; + break; + } + break; + } + + if (trigger.segment > 0) { + let values = queryData.values.concat([trigger.list, trigger.segment]); + for (let i = 0; i < values.length; i++) { + query = query.replace('?', db.escape(values[i])); } - break; - } - callback(null, query); + } + + callback(null, query); + + }); + }); }; @@ -168,6 +210,7 @@ module.exports.create = (trigger, callback) => { let name = (trigger.name || '').toString().trim(); let description = (trigger.description || '').toString().trim(); let listId = Number(trigger.list) || 0; + let segmentId = Number(trigger.segmentId) || 0; let seconds = (Number(trigger.days) || 0) * 24 * 3600; let rule = (trigger.rule || '').toString().toLowerCase().trim(); let destCampaign = Number(trigger.destCampaign) || 0; @@ -220,8 +263,8 @@ module.exports.create = (trigger, callback) => { return callback(err); } - let keys = ['name', 'description', 'list', 'source_campaign', 'rule', 'column', 'seconds', 'dest_campaign', 'last_check']; - let values = [name, description, list.id, sourceCampaign, rule, column, seconds, destCampaign]; + let keys = ['name', 'description', 'list', 'segment', 'source_campaign', 'rule', 'column', 'seconds', 'dest_campaign', 'last_check']; + let values = [name, description, list.id, segmentId, sourceCampaign, rule, column, seconds, destCampaign]; let query = 'INSERT INTO `triggers` (`' + keys.join('`, `') + '`) VALUES (' + values.map(() => '?').join(', ') + ', NOW())'; diff --git a/obsolete/public/grapejs/dist/css/grapes.min.css b/obsolete/public/grapejs/dist/css/grapes.min.css index e8cce15b..c321b38e 100644 --- a/obsolete/public/grapejs/dist/css/grapes.min.css +++ b/obsolete/public/grapejs/dist/css/grapes.min.css @@ -1,6 +1,4 @@ -.CodeMirror{font-family:monospace;height:300px;color:#000}.CodeMirror-lines{padding:4px 0}.CodeMirror pre{padding:0 4px}.CodeMirror-gutter-filler,.CodeMirror-scrollbar-filler{background-color:#fff}.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:#000}.CodeMirror-guttermarker-subtle{color:#999}.CodeMirror-cursor{border-left:1px solid #000;border-right:none;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-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:#00f}.cm-s-default .cm-quote{color:#090}.cm-negative{color:#d44}.cm-positive{color:#292}.cm-header,.cm-strong{font-weight:700}.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{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,.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-invalidchar,.cm-s-default .cm-error{color:red}.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:#fff}.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-gutter-filler,.CodeMirror-hscrollbar,.CodeMirror-scrollbar-filler,.CodeMirror-vscrollbar{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:0 0!important;border:none!important;-webkit-user-select:none;-moz-user-select:none;user-select:none}.CodeMirror-gutter-background{position:absolute;top:0;bottom:0;z-index:4}.CodeMirror-gutter-elt{position:absolute;cursor:default;z-index:4}.CodeMirror-lines{cursor:text;min-height:1px}.CodeMirror pre{-moz-border-radius:0;-webkit-border-radius:0;border-radius:0;border-width:0;background:0 0;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:none;font-variant-ligatures:none}.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-code{outline:0}.CodeMirror-gutter,.CodeMirror-gutters,.CodeMirror-linenumber,.CodeMirror-scroll,.CodeMirror-sizer{-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}.CodeMirror-focused div.CodeMirror-cursors,div.CodeMirror-dragcursors{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:#ffa;background: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 0} -.cm-s-hopscotch.CodeMirror{background:#322931;color:#d5d3d5}.cm-s-hopscotch div.CodeMirror-selected{background:#433b42!important}.cm-s-hopscotch .CodeMirror-gutters{background:#322931;border-right:0}.cm-s-hopscotch .CodeMirror-linenumber{color:#797379}.cm-s-hopscotch .CodeMirror-cursor{border-left:1px solid #989498!important}.cm-s-hopscotch span.cm-comment{color:#b33508}.cm-s-hopscotch span.cm-atom,.cm-s-hopscotch span.cm-number{color:#c85e7c}.cm-s-hopscotch span.cm-attribute,.cm-s-hopscotch span.cm-property{color:#8fc13e}.cm-s-hopscotch span.cm-keyword{color:#dd464c}.cm-s-hopscotch span.cm-string{color:#fdcc59}.cm-s-hopscotch span.cm-variable{color:#8fc13e}.cm-s-hopscotch span.cm-variable-2{color:#1290bf}.cm-s-hopscotch span.cm-def{color:#fd8b19}.cm-s-hopscotch span.cm-error{background:#dd464c;color:#989498}.cm-s-hopscotch span.cm-bracket{color:#d5d3d5}.cm-s-hopscotch span.cm-tag{color:#dd464c}.cm-s-hopscotch span.cm-link{color:#c85e7c}.cm-s-hopscotch .CodeMirror-matchingbracket{text-decoration:underline;color:#fff!important}.cm-s-hopscotch .CodeMirror-activeline-background{background:#302020} -@charset "UTF-8";.sp-alpha-handle,.sp-slider{opacity:.8;background-color:#ccc}.fa-fw,.fa-li,.sp-container button{text-align:center}.fa,.gjs-fonts::before{text-rendering:auto;-moz-osx-font-smoothing:grayscale}.gjs-cv-canvas,.gjs-grabbing,.sp-container,.sp-replacer{overflow:hidden}.sp-container{position:absolute;top:0;left:0;display:inline-block;z-index:9999994}.sp-container.sp-flat,.sp-top{position:relative}.sp-container,.sp-container *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.sp-top{width:100%;display:inline-block}.sp-alpha-handle,.sp-color,.sp-dragger,.sp-hue,.sp-sat,.sp-slider,.sp-top-inner,.sp-val{position:absolute}.sp-top-inner{top:0;left:0;bottom:0;right:0}.sp-color{top:0;left:0;bottom:0}.sp-hue{top:0;right:0;bottom:0;height:100%}.sp-clear-enabled .sp-hue{top:33px;height:77.5%}.sp-fill{padding-top:80%}.sp-sat,.sp-val{top:0;left:0;right:0;bottom:0}.sp-alpha-enabled .sp-top{margin-bottom:18px}.sp-alpha-enabled .sp-alpha{display:block}.sp-alpha,.sp-clear{display:none}.sp-alpha-handle{top:-4px;bottom:-4px;left:50%;background:#fff;opacity:.8}.sp-alpha{bottom:-14px;right:0;left:0;height:8px}.sp-alpha-inner{border:1px solid #333}.sp-clear.sp-clear-display{background-position:center}.sp-clear-enabled .sp-clear{display:block;position:absolute;top:0;right:0;bottom:0;left:84%;height:28px}.sp-alpha,.sp-alpha-handle,.sp-clear,.sp-container,.sp-container button,.sp-container.sp-dragging .sp-input,.sp-dragger,.sp-preview,.sp-replacer,.sp-slider{-webkit-user-select:none;-moz-user-select:-moz-none;-o-user-select:none;user-select:none}.sp-container.sp-buttons-disabled .sp-button-container,.sp-container.sp-input-disabled .sp-input-container,.sp-container.sp-palette-buttons-disabled .sp-palette-button-container,.sp-initial-disabled .sp-initial,.sp-palette-disabled .sp-palette-container,.sp-palette-only .sp-picker-container{display:none}.sp-sat{background-image:-webkit-gradient(linear,0 0,100% 0,from(#FFF),to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(left,#FFF,rgba(204,154,129,0));background-image:-moz-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:-o-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:-ms-linear-gradient(left,#fff,rgba(204,154,129,0));background-image:linear-gradient(to right,#fff,rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr=#FFFFFFFF, endColorstr=#00CC9A81)";filter:progid:DXImageTransform.Microsoft.gradient(GradientType=1, startColorstr='#FFFFFFFF', endColorstr='#00CC9A81')}.sp-val{background-image:-webkit-gradient(linear,0 100%,0 0,from(#000),to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-moz-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-o-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:-ms-linear-gradient(bottom,#000,rgba(204,154,129,0));background-image:linear-gradient(to top,#000,rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(startColorstr=#00CC9A81, endColorstr=#FF000000)";filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00CC9A81', endColorstr='#FF000000')}.sp-hue{background:-moz-linear-gradient(top,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%);background:-ms-linear-gradient(top,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%);background:-o-linear-gradient(top,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%);background:-webkit-gradient(linear,left top,left bottom,from(red),color-stop(.17,#ff0),color-stop(.33,#0f0),color-stop(.5,#0ff),color-stop(.67,#00f),color-stop(.83,#f0f),to(red));background:-webkit-linear-gradient(top,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%);background:linear-gradient(to bottom,red 0,#ff0 17%,#0f0 33%,#0ff 50%,#00f 67%,#f0f 83%,red 100%)}.sp-1{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0000', endColorstr='#ffff00')}.sp-2{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffff00', endColorstr='#00ff00')}.sp-3{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ff00', endColorstr='#00ffff')}.sp-4{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ffff', endColorstr='#0000ff')}.sp-5{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#0000ff', endColorstr='#ff00ff')}.sp-6{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00ff', endColorstr='#ff0000')}.sp-hidden{display:none!important}.sp-cf:after,.sp-cf:before{content:"";display:table}.sp-cf:after{clear:both}@media (max-device-width:480px){.sp-color{right:40%}.sp-hue{left:63%}.sp-fill{padding-top:60%}}.sp-dragger{border-radius:5px;height:5px;width:5px;border:1px solid #fff;top:0;left:0}.sp-slider{top:0;right:-1px;background:#fff;opacity:.8}.sp-container{border:1px solid #f0c49B;padding:0}.sp-clear,.sp-color,.sp-container,.sp-container button,.sp-container input,.sp-hue{font:400 12px "Lucida Grande","Lucida Sans Unicode","Lucida Sans",Geneva,Verdana,sans-serif;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;-ms-box-sizing:border-box;box-sizing:border-box}.gjs-btnt,.gjs-com-dashed *,.gjs-cv-canvas,.gjs-cv-canvas *,.gjs-editor,.gjs-input,.gjs-pn-btn,.gjs-pn-panel,.gjs-select{box-sizing:border-box}.sp-top{margin-bottom:3px}.sp-clear,.sp-color,.sp-hue{border:1px solid #666}.sp-input-container{float:right;width:100px;margin-bottom:4px}.sp-initial-disabled .sp-input-container,.sp-input{width:100%}.sp-input{font-size:12px!important;border:1px inset;padding:4px 5px;margin:0;background:0 0;border-radius:3px;color:#222}.sp-input:focus{border:1px solid orange}.sp-input.sp-validation-error{border:1px solid red;background:#fdd}.sp-palette-container,.sp-picker-container{float:left;position:relative;padding:10px 10px 300px;margin-bottom:-290px}.sp-picker-container{width:172px}.sp-palette-only .sp-palette-container{border:0}.sp-palette .sp-thumb-el{display:block;position:relative;float:left;cursor:pointer}.sp-palette .sp-thumb-el.sp-thumb-active,.sp-palette .sp-thumb-el:hover{border-color:orange}.sp-thumb-el{position:relative}.sp-initial{float:left;border:1px solid #333}.sp-initial span{width:30px;height:25px;border:none;display:block;float:left;margin:0}.sp-initial .sp-clear-display{background-position:center}.sp-button-container,.sp-palette-button-container{float:right}.sp-replacer{margin:0;cursor:pointer;padding:4px;display:inline-block;border:1px solid #91765d;background:#eee;color:#333;vertical-align:middle}.sp-replacer.sp-active,.sp-replacer:hover{border-color:#F0C49B;color:#111}.sp-replacer.sp-disabled{cursor:default;border-color:silver;color:silver}.sp-dd{padding:2px 0;height:16px;line-height:16px;float:left;font-size:10px}.sp-preview{width:25px;height:20px;border:1px solid #222;margin-right:5px;float:left;z-index:0}.sp-palette{max-width:220px}.sp-palette .sp-thumb-el{width:16px;height:16px;margin:2px 1px;border:1px solid #d0d0d0}.sp-container{padding-bottom:0}.sp-container button{background-color:#eee;background-image:-webkit-linear-gradient(top,#eee,#ccc);background-image:-moz-linear-gradient(top,#eee,#ccc);background-image:-ms-linear-gradient(top,#eee,#ccc);background-image:-o-linear-gradient(top,#eee,#ccc);background-image:linear-gradient(to bottom,#eee,#ccc);border:1px solid #ccc;border-bottom:1px solid #bbb;border-radius:3px;font-size:14px;line-height:1;vertical-align:middle}.sp-container button:hover{background-color:#ddd;background-image:-webkit-linear-gradient(top,#ddd,#bbb);background-image:-moz-linear-gradient(top,#ddd,#bbb);background-image:-ms-linear-gradient(top,#ddd,#bbb);background-image:-o-linear-gradient(top,#ddd,#bbb);background-image:linear-gradient(to bottom,#ddd,#bbb);border:1px solid #bbb;border-bottom:1px solid #999;cursor:pointer}.sp-container button:active{border:1px solid #aaa;border-bottom:1px solid #888;-webkit-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-moz-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-ms-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee;-o-box-shadow:inset 0 0 5px 2px #aaa,0 1px 0 0 #eee}.sp-cancel{margin:0 5px 0 0;padding:2px;vertical-align:middle}.fa.fa-pull-left,.fa.pull-left{margin-right:.3em}.sp-palette span.sp-thumb-active,.sp-palette span:hover{border-color:#000}.sp-alpha,.sp-preview,.sp-thumb-el{position:relative;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.sp-alpha-inner,.sp-preview-inner,.sp-thumb-inner{display:block;position:absolute;top:0;left:0;bottom:0;right:0}.fa,.fa-stack{display:inline-block}.sp-palette .sp-thumb-inner{background-position:50% 50%;background-repeat:no-repeat}.sp-palette .sp-thumb-light.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAIVJREFUeNpiYBhsgJFMffxAXABlN5JruT4Q3wfi/0DsT64h8UD8HmpIPCWG/KemIfOJCUB+Aoacx6EGBZyHBqI+WsDCwuQ9mhxeg2A210Ntfo8klk9sOMijaURm7yc1UP2RNCMbKE9ODK1HM6iegYLkfx8pligC9lCD7KmRof0ZhjQACDAAceovrtpVBRkAAAAASUVORK5CYII=)}.sp-palette .sp-thumb-dark.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjEwMPRyoQAAAMdJREFUOE+tkgsNwzAMRMugEAahEAahEAZhEAqlEAZhEAohEAYh81X2dIm8fKpEspLGvudPOsUYpxE2BIJCroJmEW9qJ+MKaBFhEMNabSy9oIcIPwrB+afvAUFoK4H0tMaQ3XtlrggDhOVVMuT4E5MMG0FBbCEYzjYT7OxLEvIHQLY2zWwQ3D+9luyOQTfKDiFD3iUIfPk8VqrKjgAiSfGFPecrg6HN6m/iBcwiDAo7WiBeawa+Kwh7tZoSCGLMqwlSAzVDhoK+6vH4G0P5wdkAAAAASUVORK5CYII=)}.sp-clear-display{background-repeat:no-repeat;background-position:center;background-image:url(data:image/gif;base64,R0lGODlhFAAUAPcAAAAAAJmZmZ2dnZ6enqKioqOjo6SkpKWlpaampqenp6ioqKmpqaqqqqurq/Hx8fLy8vT09PX19ff39/j4+Pn5+fr6+vv7+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAUABQAAAihAP9FoPCvoMGDBy08+EdhQAIJCCMybCDAAYUEARBAlFiQQoMABQhKUJBxY0SPICEYHBnggEmDKAuoPMjS5cGYMxHW3IiT478JJA8M/CjTZ0GgLRekNGpwAsYABHIypcAgQMsITDtWJYBR6NSqMico9cqR6tKfY7GeBCuVwlipDNmefAtTrkSzB1RaIAoXodsABiZAEFB06gIBWC1mLVgBa0AAOw==)}/*! - * Font Awesome 4.5.0 by @davegandy - http://fontawesome.io - @fontawesome +.sp-container{position:absolute;top:0;left:0;display:inline-block;*display:inline;*zoom:1;z-index:9999994;overflow:hidden}.sp-container.sp-flat{position:relative}.sp-container,.sp-container *{-webkit-box-sizing:content-box;-moz-box-sizing:content-box;box-sizing:content-box}.sp-top{position:relative;width:100%;display:inline-block}.sp-top-inner{position:absolute;top:0;left:0;bottom:0;right:0}.sp-color{position:absolute;top:0;left:0;bottom:0;right:20%}.sp-hue{position:absolute;top:0;right:0;bottom:0;left:84%;height:100%}.sp-clear-enabled .sp-hue{top:33px;height:77.5%}.sp-fill{padding-top:80%}.sp-sat,.sp-val{position:absolute;top:0;left:0;right:0;bottom:0}.sp-alpha-enabled .sp-top{margin-bottom:18px}.sp-alpha-enabled .sp-alpha{display:block}.sp-alpha-handle{position:absolute;top:-4px;bottom:-4px;width:6px;left:50%;cursor:pointer;border:1px solid black;background:white;opacity:.8}.sp-alpha{display:none;position:absolute;bottom:-14px;right:0;left:0;height:8px}.sp-alpha-inner{border:solid 1px #333}.sp-clear{display:none}.sp-clear.sp-clear-display{background-position:center}.sp-clear-enabled .sp-clear{display:block;position:absolute;top:0px;right:0;bottom:0;left:84%;height:28px}.sp-container,.sp-replacer,.sp-preview,.sp-dragger,.sp-slider,.sp-alpha,.sp-clear,.sp-alpha-handle,.sp-container.sp-dragging .sp-input,.sp-container button{-webkit-user-select:none;-moz-user-select:-moz-none;-o-user-select:none;user-select:none}.sp-container.sp-input-disabled .sp-input-container{display:none}.sp-container.sp-buttons-disabled .sp-button-container{display:none}.sp-container.sp-palette-buttons-disabled .sp-palette-button-container{display:none}.sp-palette-only .sp-picker-container{display:none}.sp-palette-disabled .sp-palette-container{display:none}.sp-initial-disabled .sp-initial{display:none}.sp-sat{background-image:-webkit-gradient(linear, 0 0, 100% 0, from(#fff), to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(left, #fff, rgba(204,154,129,0));background-image:-moz-linear-gradient(left, #fff, rgba(204,154,129,0));background-image:-o-linear-gradient(left, #fff, rgba(204,154,129,0));background-image:-ms-linear-gradient(left, #fff, rgba(204,154,129,0));background-image:linear-gradient(to right, #fff, rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr=#FFFFFFFF, endColorstr=#00CC9A81)";filter:progid:DXImageTransform.Microsoft.gradient(GradientType = 1, startColorstr='#FFFFFFFF', endColorstr='#00CC9A81')}.sp-val{background-image:-webkit-gradient(linear, 0 100%, 0 0, from(#000), to(rgba(204,154,129,0)));background-image:-webkit-linear-gradient(bottom, #000, rgba(204,154,129,0));background-image:-moz-linear-gradient(bottom, #000, rgba(204,154,129,0));background-image:-o-linear-gradient(bottom, #000, rgba(204,154,129,0));background-image:-ms-linear-gradient(bottom, #000, rgba(204,154,129,0));background-image:linear-gradient(to top, #000, rgba(204,154,129,0));-ms-filter:"progid:DXImageTransform.Microsoft.gradient(startColorstr=#00CC9A81, endColorstr=#FF000000)";filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00CC9A81', endColorstr='#FF000000')}.sp-hue{background:-moz-linear-gradient(top, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%);background:-ms-linear-gradient(top, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%);background:-o-linear-gradient(top, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%);background:-webkit-gradient(linear, left top, left bottom, from(red), color-stop(0.17, #ff0), color-stop(0.33, lime), color-stop(0.5, cyan), color-stop(0.67, blue), color-stop(0.83, #f0f), to(red));background:-webkit-linear-gradient(top, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%);background:linear-gradient(to bottom, red 0%, #ff0 17%, lime 33%, cyan 50%, blue 67%, #f0f 83%, red 100%)}.sp-1{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff0000', endColorstr='#ffff00')}.sp-2{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ffff00', endColorstr='#00ff00')}.sp-3{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ff00', endColorstr='#00ffff')}.sp-4{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#00ffff', endColorstr='#0000ff')}.sp-5{height:16%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#0000ff', endColorstr='#ff00ff')}.sp-6{height:17%;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr='#ff00ff', endColorstr='#ff0000')}.sp-hidden{display:none !important}.sp-cf:before,.sp-cf:after{content:"";display:table}.sp-cf:after{clear:both}.sp-cf{*zoom:1}@media (max-device-width: 480px){.sp-color{right:40%}.sp-hue{left:63%}.sp-fill{padding-top:60%}}.sp-dragger{border-radius:5px;height:5px;width:5px;border:1px solid #fff;background:#000;cursor:pointer;position:absolute;top:0;left:0}.sp-slider{position:absolute;top:0;cursor:pointer;height:3px;left:-1px;right:-1px;border:1px solid #000;background:white;opacity:.8}.sp-container{border-radius:0;background-color:#ECECEC;border:solid 1px #f0c49B;padding:0}.sp-container,.sp-container button,.sp-container input,.sp-color,.sp-hue,.sp-clear{font:normal 12px "Lucida Grande", "Lucida Sans Unicode", "Lucida Sans", Geneva, Verdana, sans-serif;-webkit-box-sizing:border-box;-moz-box-sizing:border-box;-ms-box-sizing:border-box;box-sizing:border-box}.sp-top{margin-bottom:3px}.sp-color,.sp-hue,.sp-clear{border:solid 1px #666}.sp-input-container{float:right;width:100px;margin-bottom:4px}.sp-initial-disabled .sp-input-container{width:100%}.sp-input{font-size:12px !important;border:1px inset;padding:4px 5px;margin:0;width:100%;background:transparent;border-radius:3px;color:#222}.sp-input:focus{border:1px solid orange}.sp-input.sp-validation-error{border:1px solid red;background:#fdd}.sp-picker-container,.sp-palette-container{float:left;position:relative;padding:10px;padding-bottom:300px;margin-bottom:-290px}.sp-picker-container{width:172px;border-left:solid 1px #fff}.sp-palette-container{border-right:solid 1px #ccc}.sp-palette-only .sp-palette-container{border:0}.sp-palette .sp-thumb-el{display:block;position:relative;float:left;width:24px;height:15px;margin:3px;cursor:pointer;border:solid 2px transparent}.sp-palette .sp-thumb-el:hover,.sp-palette .sp-thumb-el.sp-thumb-active{border-color:orange}.sp-thumb-el{position:relative}.sp-initial{float:left;border:solid 1px #333}.sp-initial span{width:30px;height:25px;border:none;display:block;float:left;margin:0}.sp-initial .sp-clear-display{background-position:center}.sp-palette-button-container,.sp-button-container{float:right}.sp-replacer{margin:0;overflow:hidden;cursor:pointer;padding:4px;display:inline-block;*zoom:1;*display:inline;border:solid 1px #91765d;background:#eee;color:#333;vertical-align:middle}.sp-replacer:hover,.sp-replacer.sp-active{border-color:#F0C49B;color:#111}.sp-replacer.sp-disabled{cursor:default;border-color:silver;color:silver}.sp-dd{padding:2px 0;height:16px;line-height:16px;float:left;font-size:10px}.sp-preview{position:relative;width:25px;height:20px;border:solid 1px #222;margin-right:5px;float:left;z-index:0}.sp-palette{*width:220px;max-width:220px}.sp-palette .sp-thumb-el{width:16px;height:16px;margin:2px 1px;border:solid 1px #d0d0d0}.sp-container{padding-bottom:0}.sp-container button{background-color:#eeeeee;background-image:-webkit-linear-gradient(top, #eee, #ccc);background-image:-moz-linear-gradient(top, #eee, #ccc);background-image:-ms-linear-gradient(top, #eee, #ccc);background-image:-o-linear-gradient(top, #eee, #ccc);background-image:linear-gradient(to bottom, #eee, #ccc);border:1px solid #ccc;border-bottom:1px solid #bbb;border-radius:3px;color:#333;font-size:14px;line-height:1;padding:5px 4px;text-align:center;text-shadow:0 1px 0 #eee;vertical-align:middle}.sp-container button:hover{background-color:#dddddd;background-image:-webkit-linear-gradient(top, #ddd, #bbb);background-image:-moz-linear-gradient(top, #ddd, #bbb);background-image:-ms-linear-gradient(top, #ddd, #bbb);background-image:-o-linear-gradient(top, #ddd, #bbb);background-image:linear-gradient(to bottom, #ddd, #bbb);border:1px solid #bbb;border-bottom:1px solid #999;cursor:pointer;text-shadow:0 1px 0 #ddd}.sp-container button:active{border:1px solid #aaa;border-bottom:1px solid #888;-webkit-box-shadow:inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee;-moz-box-shadow:inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee;-ms-box-shadow:inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee;-o-box-shadow:inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee;box-shadow:inset 0 0 5px 2px #aaaaaa, 0 1px 0 0 #eeeeee}.sp-cancel{font-size:11px;color:#d93f3f !important;margin:0;padding:2px;margin-right:5px;vertical-align:middle;text-decoration:none}.sp-cancel:hover{color:#d93f3f !important;text-decoration:underline}.sp-palette span:hover,.sp-palette span.sp-thumb-active{border-color:#000}.sp-preview,.sp-alpha,.sp-thumb-el{position:relative;background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.sp-preview-inner,.sp-alpha-inner,.sp-thumb-inner{display:block;position:absolute;top:0;left:0;bottom:0;right:0}.sp-palette .sp-thumb-inner{background-position:50% 50%;background-repeat:no-repeat}.sp-palette .sp-thumb-light.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAIVJREFUeNpiYBhsgJFMffxAXABlN5JruT4Q3wfi/0DsT64h8UD8HmpIPCWG/KemIfOJCUB+Aoacx6EGBZyHBqI+WsDCwuQ9mhxeg2A210Ntfo8klk9sOMijaURm7yc1UP2RNCMbKE9ODK1HM6iegYLkfx8pligC9lCD7KmRof0ZhjQACDAAceovrtpVBRkAAAAASUVORK5CYII=)}.sp-palette .sp-thumb-dark.sp-thumb-active .sp-thumb-inner{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABIAAAASCAYAAABWzo5XAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAAadEVYdFNvZnR3YXJlAFBhaW50Lk5FVCB2My41LjEwMPRyoQAAAMdJREFUOE+tkgsNwzAMRMugEAahEAahEAZhEAqlEAZhEAohEAYh81X2dIm8fKpEspLGvudPOsUYpxE2BIJCroJmEW9qJ+MKaBFhEMNabSy9oIcIPwrB+afvAUFoK4H0tMaQ3XtlrggDhOVVMuT4E5MMG0FBbCEYzjYT7OxLEvIHQLY2zWwQ3D+9luyOQTfKDiFD3iUIfPk8VqrKjgAiSfGFPecrg6HN6m/iBcwiDAo7WiBeawa+Kwh7tZoSCGLMqwlSAzVDhoK+6vH4G0P5wdkAAAAASUVORK5CYII=)}.sp-clear-display{background-repeat:no-repeat;background-position:center;background-image:url(data:image/gif;base64,R0lGODlhFAAUAPcAAAAAAJmZmZ2dnZ6enqKioqOjo6SkpKWlpaampqenp6ioqKmpqaqqqqurq/Hx8fLy8vT09PX19ff39/j4+Pn5+fr6+vv7+wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH5BAEAAP8ALAAAAAAUABQAAAihAP9FoPCvoMGDBy08+EdhQAIJCCMybCDAAYUEARBAlFiQQoMABQhKUJBxY0SPICEYHBnggEmDKAuoPMjS5cGYMxHW3IiT478JJA8M/CjTZ0GgLRekNGpwAsYABHIypcAgQMsITDtWJYBR6NSqMico9cqR6tKfY7GeBCuVwlipDNmefAtTrkSzB1RaIAoXodsABiZAEFB06gIBWC1mLVgBa0AAOw==)}/*! + * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) - */@font-face{font-family:FontAwesome;src:url(../fonts/fontawesome-webfont.eot?v=4.5.0);src:url(../fonts/fontawesome-webfont.eot?#iefix&v=4.5.0) format("embedded-opentype"),url(../fonts/fontawesome-webfont.woff2?v=4.5.0) format("woff2"),url(../fonts/fontawesome-webfont.woff?v=4.5.0) format("woff"),url(../fonts/fontawesome-webfont.ttf?v=4.5.0) format("truetype"),url(../fonts/fontawesome-webfont.svg?v=4.5.0#fontawesomeregular) format("svg");font-weight:400;font-style:normal}.fa{font:normal normal normal 14px/1 FontAwesome;font-size:inherit;-webkit-font-smoothing:antialiased}.fa-lg{font-size:1.3333333333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.2857142857em}.fa-ul{padding-left:0;margin-left:2.1428571429em;list-style-type:none}.fa.fa-pull-right,.fa.pull-right{margin-left:.3em}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.1428571429em;width:2.1428571429em;top:.1428571429em}.fa-li.fa-lg{left:-1.8571428571em}.fa-border{padding:.2em .25em .15em;border:.08em solid #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right,.pull-right{float:right}.pull-left{float:left}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0);transform:rotate(0)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=1);-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=3);-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=0);-webkit-transform:scale(-1,1);-ms-transform:scale(-1,1);transform:scale(-1,1)}.fa-flip-vertical{filter:progid:DXImageTransform.Microsoft.BasicImage(rotation=2);-webkit-transform:scale(1,-1);-ms-transform:scale(1,-1);transform:scale(1,-1)}:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-rotate-90{filter:none}.gjs-clm-tags #gjs-clm-close,.gjs-freezed,.gjs-nv-freezed,.opac50{opacity:.5;filter:alpha(opacity=50)}.fa-stack{position:relative;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-close:before,.fa-remove:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-cog:before,.fa-gear:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-repeat:before,.fa-rotate-right:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-image:before,.fa-photo:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-exclamation-triangle:before,.fa-warning:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-cogs:before,.fa-gears:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-floppy-o:before,.fa-save:before{content:""}.fa-square:before{content:""}.fa-bars:before,.fa-navicon:before,.fa-reorder:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-sort:before,.fa-unsorted:before{content:""}.fa-sort-desc:before,.fa-sort-down:before{content:""}.fa-sort-asc:before,.fa-sort-up:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-gavel:before,.fa-legal:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-bolt:before,.fa-flash:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-clipboard:before,.fa-paste:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-chain-broken:before,.fa-unlink:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-caret-square-o-down:before,.fa-toggle-down:before{content:""}.fa-caret-square-o-up:before,.fa-toggle-up:before{content:""}.fa-caret-square-o-right:before,.fa-toggle-right:before{content:""}.fa-eur:before,.fa-euro:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-inr:before,.fa-rupee:before{content:""}.fa-cny:before,.fa-jpy:before,.fa-rmb:before,.fa-yen:before{content:""}.fa-rouble:before,.fa-rub:before,.fa-ruble:before{content:""}.fa-krw:before,.fa-won:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-caret-square-o-left:before,.fa-toggle-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-try:before,.fa-turkish-lira:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-bank:before,.fa-institution:before,.fa-university:before{content:""}.fa-graduation-cap:before,.fa-mortar-board:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-image-o:before,.fa-file-photo-o:before,.fa-file-picture-o:before{content:""}.fa-file-archive-o:before,.fa-file-zip-o:before{content:""}.fa-file-audio-o:before,.fa-file-sound-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-ring:before,.fa-life-saver:before,.fa-support:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-rebel:before{content:""}.fa-empire:before,.fa-ge:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-hacker-news:before,.fa-y-combinator-square:before,.fa-yc-square:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-paper-plane:before,.fa-send:before{content:""}.fa-paper-plane-o:before,.fa-send-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-futbol-o:before,.fa-soccer-ball-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-ils:before,.fa-shekel:before,.fa-sheqel:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-bed:before,.fa-hotel:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-y-combinator:before,.fa-yc:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-paper-o:before,.fa-hand-stop-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-television:before,.fa-tv:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.fa-reddit-alien:before{content:""}.fa-edge:before{content:""}.fa-credit-card-alt:before{content:""}.fa-codiepie:before{content:""}.fa-modx:before{content:""}.fa-fort-awesome:before{content:""}.fa-usb:before{content:""}.fa-product-hunt:before{content:""}.fa-mixcloud:before{content:""}.fa-scribd:before{content:""}.fa-pause-circle:before{content:""}.fa-pause-circle-o:before{content:""}.fa-stop-circle:before{content:""}.fa-stop-circle-o:before{content:""}.fa-shopping-bag:before{content:""}.fa-shopping-basket:before{content:""}.fa-hashtag:before{content:""}.fa-bluetooth:before{content:""}.fa-bluetooth-b:before{content:""}.fa-percent:before{content:""}@font-face{font-family:font3336;src:url(../fonts/main-fonts.eot?v=20);src:url(../fonts/main-fonts.woff?v=20) format("woff"),url(../fonts/main-fonts.ttf?v=20) format("truetype"),url(../fonts/main-fonts.svg?v=20) format("svg"),url(../fonts/main-fonts.eot?v=20) format("embedded-opentype");font-weight:400;font-style:normal}.gjs-fonts::before{display:block;font:normal normal normal 14px font3336;-webkit-font-smoothing:antialiased;font-size:5em}.gjs-block-label,.gjs-editor,.gjs-mdl-container{font-family:Helvetica,sans-serif}.gjs-f-b1::before{content:'Q'}.gjs-f-b2::before{content:'W'}.gjs-f-b3::before{content:'E'}.gjs-f-b37::before{content:'R'}.gjs-f-hero::before{content:'T'}.gjs-f-h1p::before{content:'y'}.gjs-f-3ba::before{content:'u'}.gjs-f-image::before{content:'I'}.gjs-f-text::before{content:'o'}.gjs-f-quo::before{content:'p'}.gjs-f-button::before{content:'B'}.gjs-f-divider::before{content:'D'}.gjs-clm-tags #gjs-clm-new,.gjs-invis-invis,.gjs-no-app{background-color:transparent;border:none;color:inherit}.gjs-no-app{height:10px}.gjs-test::btn{color:'#fff'}.checker-bg,.gjs-checker-bg,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box,.gjs-field-colorp-c,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==)}.gjs-grabbing,.gjs-grabbing *,.gjs-nav-comp-name,.gjs-no-user-select{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el,.gjs-margin-v-el,.gjs-no-pointer-events,.gjs-padding-v-el,.gjs-resizer-c{pointer-events:none}.gjs-bdrag,.gjs-drag-helper{pointer-events:none!important;position:absolute!important;z-index:10!important}#gjs-rte-toolbar,.gjs-bg-main,.gjs-block,.gjs-clm-select option,.gjs-clm-tags .gjs-sm-colorp-c,.gjs-field-select option,.gjs-mdl-dialog,.gjs-nv-item .gjs-nv-title-c,.gjs-off-prv,.gjs-pn-panel,.gjs-select option,.gjs-sm-sector .gjs-sm-colorp-c,.gjs-sm-select option,.gjs-sm-unit option,.sp-container{background-color:#444}#gjs-rte-toolbar .gjs-rte-btn,.gjs-btn-prim,.gjs-btnt,.gjs-clm-tags .gjs-sm-composite.gjs-clm-field,.gjs-clm-tags .gjs-sm-field.gjs-sm-composite,.gjs-clm-tags .gjs-sm-stack #gjs-sm-add,.gjs-color-main,.gjs-mdl-dialog,.gjs-off-prv,.gjs-pn-btn,.gjs-pn-panel,.gjs-sm-sector .gjs-sm-composite.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-composite,.gjs-sm-sector .gjs-sm-stack #gjs-sm-add{color:#ddd}.gjs-btnt.gjs-pn-active,.gjs-color-active,.gjs-pn-btn.gjs-pn-active{color:#f8f8f8}.gjs-bdrag{width:auto}.gjs-drag-helper{background-color:#3b97e3!important;transform:scale(.3)!important;transform-origin:top left!important;-webkit-transform-origin:top left!important;margin:15px!important;transition:none!important;outline:0!important}.gjs-grabbing,.gjs-grabbing *{cursor:grabbing!important;cursor:-webkit-grabbing!important}.gjs-off-prv{position:relative;z-index:10;padding:5px;cursor:pointer}.gjs-editor-cont ::-webkit-scrollbar-track{background:rgba(0,0,0,.1)}.gjs-editor-cont ::-webkit-scrollbar-thumb{background-color:rgba(255,255,255,.2)}.gjs-editor-cont ::-webkit-scrollbar{width:8px}.clear{clear:both}.gjs-clm-tags #gjs-clm-close,.gjs-clm-tags #gjs-clm-tag-label,.gjs-com-no-select,.gjs-com-no-select img,.no-select{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.gjs-editor{background-color:#444;position:relative;height:100%}.gjs-btn-prim,.gjs-btn-prim:active{background-color:rgba(255,255,255,.1)}.gjs-freezed,.gjs-nv-freezed{pointer-events:none}.gjs-btn-prim{border-radius:2px;cursor:pointer;padding:.5em;border:none}.gjs-input,.gjs-select{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.1);border-radius:2px;box-shadow:1px 1px 0 rgba(255,255,255,.1);color:#ddd;padding:.5em 1em}div.gjs-select{padding:0}.gjs-select select{padding-right:10px}.gjs-select select:-moz-focusring,.gjs-select:-moz-focusring{color:transparent;text-shadow:0 0 0 rgba(255,255,255,.7)}.gjs-btn-prim:focus,.gjs-button:focus,.gjs-input:focus,.gjs-select select:focus,.gjs-select:focus{outline:0}.gjs-traits-label{border-bottom:1px solid rgba(0,0,0,.3);font-size:13px;font-weight:lighter;margin-bottom:5px;padding:10px;text-align:left}.gjs-trt-trait{display:flex;justify-content:start;padding:5px 10px;font-size:.75em;font-weight:lighter}.gjs-trt-trait .gjs-label{width:30%;text-align:left}.gjs-trt-trait .gjs-field{width:70%}.gjs-cv-canvas{background-color:rgba(0,0,0,.15);position:absolute;width:85%;height:100%;bottom:0;left:0;padding-top:40px;z-index:1}.gjs-cv-canvas>iframe{height:100%;outline:0;width:100%;border:none;margin:0 auto;display:block}.gjs-cv-canvas .gjs-ghost{display:none;pointer-events:none;background-color:#5b5b5b;border:2px dashed #ccc;position:absolute;z-index:10;opacity:.55;filter:alpha(opacity=55)}.gjs-cv-canvas .gjs-highlighter,.gjs-cv-canvas .gjs-highlighter-sel{position:absolute;outline:#3b97e3 solid 1px;pointer-events:none}.gjs-cv-canvas .gjs-highlighter-warning{outline:#ffca6f solid 3px}.gjs-cv-canvas .gjs-highlighter-sel{outline:#3b97e3 solid 3px}.gjs-cv-canvas #gjs-tools{width:100%;position:absolute;top:0;left:0;outline:0}.gjs-cv-canvas>div:first-child{background-color:#fff;position:relative;height:100%;overflow:auto;width:100%}.dragged,.gjs-resizer-c,.gjs-resizer-h,.gjs-toolbar{position:absolute}.gjs-frame{transition:width .35s ease}.gjs-toolbar{background-color:#3b97e3;color:#fff;z-index:10}.gjs-toolbar-item{padding:5px 7px;font-size:.8rem;cursor:pointer}.gjs-resizer-c{z-index:9}.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el,.gjs-margin-v-el,.gjs-padding-v-el{opacity:.1;filter:alpha(opacity=10);position:absolute;background-color:#ff0}.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el{opacity:.2;filter:alpha(opacity=20)}.gjs-fixedpadding-v-el,.gjs-padding-v-el{background-color:navy}.gjs-resizer-h{pointer-events:all;border:3px solid #3b97e3;width:10px;height:10px;background-color:#fff;margin:-5px}.gjs-resizer-h-tl{top:0;left:0;cursor:nwse-resize}.gjs-resizer-h-tr{top:0;right:0;cursor:nesw-resize}.gjs-resizer-h-tc{top:0;margin:-5px auto;left:0;right:0;cursor:ns-resize}.gjs-resizer-h-cl,.gjs-resizer-h-cr{margin:auto -5px;cursor:ew-resize;bottom:0;top:0}.gjs-resizer-h-cl{left:0}.gjs-resizer-h-cr{right:0}.gjs-resizer-h-bl{bottom:0;left:0;cursor:nesw-resize}.gjs-resizer-h-bc{bottom:0;margin:-5px auto;left:0;right:0;cursor:ns-resize}.gjs-resizer-h-br{bottom:0;right:0;cursor:nwse-resize}.gjs-resizing .gjs-badge,.gjs-resizing .gjs-highlighter{display:none!important}.gjs-resizing-tl *{cursor:nwse-resize!important}.gjs-resizing-tr *{cursor:nesw-resize!important}.gjs-resizing-tc *{cursor:ns-resize!important}.gjs-resizing-cl *,.gjs-resizing-cr *{cursor:ew-resize!important}.gjs-resizing-bl *{cursor:nesw-resize!important}.gjs-resizing-bc *{cursor:ns-resize!important}.gjs-resizing-br *{cursor:nwse-resize!important}.btn-cl,.gjs-am-assets-cont #gjs-am-close,.gjs-mdl-dialog .gjs-mdl-btn-close{opacity:.3;filter:alpha(opacity=30);font-size:25px;cursor:pointer}.btn-cl:hover,.gjs-am-assets-cont #gjs-am-close:hover,.gjs-mdl-dialog .gjs-mdl-btn-close:hover{opacity:.7;filter:alpha(opacity=70)}.dragged,.gjs-nv-opac50{opacity:.5;filter:alpha(opacity=50)}#commands.panel{min-width:35px;height:100%;z-index:3}#options.panel{z-index:4;bottom:0}#views.panel{width:16.5%;font-weight:lighter;color:#ddd;right:0;top:0;z-index:3;height:100%;padding:0}#views.panel .c{height:100%}#commands.panel,#options.panel{width:3.5%;left:0}#options .c{display:table;margin:0 auto}body.dragging,body.dragging *{cursor:move!important}.dragged{z-index:2000}ol.example li.placeholder{position:relative}ol.example li.placeholder:before{position:absolute}.no-dots,.ui-resizable-handle{border:none!important;margin:0!important;outline:0!important}.gjs-com-dashed *{outline:#888 dashed 1px;outline-offset:-2px}.gjs-cv-canvas .gjs-comp-selected{outline:#3b97e3 solid 3px!important}.gjs-com-hover,div.gjs-com-hover{outline:#3b97e3 solid 1px}.gjs-com-hover-delete,div.gjs-com-hover-delete{outline:#dd3636 solid 2px;opacity:.5;filter:alpha(opacity=50)}.gjs-com-hover-move,div.gjs-com-hover-move{outline:#ffca6f solid 3px}.gjs-badge,.gjs-com-badge,.gjs-com-badge-red{pointer-events:none;background-color:#3b97e3;color:#fff;padding:2px 5px;position:absolute;z-index:1;font-size:12px;outline:0;display:none}.gjs-com-badge-red{background-color:#dd3636}.gjs-badge-warning{background-color:#ffca6f}.gjs-com-placeholder,.gjs-nv-placeholder,.gjs-placeholder{position:absolute;z-index:10;pointer-events:none;display:none}.gjs-nv-placeholder,.gjs-placeholder{border-style:solid!important;border-color:#62c462;outline:0;box-sizing:border-box}.gjs-com-placeholder-int,.gjs-nv-placeholder-int,.gjs-placeholder-int{background-color:#62c462;box-shadow:0 0 3px rgba(0,0,0,.2);height:100%;width:100%;pointer-events:none;padding:1.5px;outline:0}.gjs-pn-panel{display:inline-block;padding:5px;position:absolute;text-align:center;z-index:3}.gjs-pn-panel#gjs-pn-commands,.gjs-pn-panel#gjs-pn-options2{width:85%;left:0;top:0;box-shadow:0 0 5px rgba(0,0,0,.3)}.gjs-pn-panel#gjs-pn-options{right:15%;top:0}.gjs-pn-panel#gjs-pn-options2{bottom:150px;height:auto}.gjs-pn-panel .icon-redo,.gjs-pn-panel .icon-undo{font-size:20px;height:30px;width:25px}.gjs-pn-panel#gjs-pn-views{border-bottom:2px solid rgba(0,0,0,.3);right:0;width:15%;z-index:4}.gjs-pn-panel#gjs-pn-views-container{height:100%;padding:42px 0 0;right:0;width:15%;overflow:auto;box-shadow:0 0 5px rgba(0,0,0,.3)}.gjs-pn-buttons{align-items:center;display:flex;justify-content:center}.gjs-btnt,.gjs-pn-btn{height:30px;width:30px;line-height:21px;background-color:transparent;border:none;font-size:18px;margin-right:5px;border-radius:2px;cursor:pointer;padding:5px;position:relative}.gjs-btnt.gjs-pn-active,.gjs-pn-btn.gjs-pn-active{background-color:rgba(0,0,0,.15);box-shadow:0 0 3px rgba(0,0,0,.25) inset}.gjs-btnt>.gjs-pn-arrow-rd,.gjs-pn-btn>.gjs-pn-arrow-rd{border-bottom:5px solid rgba(255,255,255,.7);border-left:5px solid transparent;bottom:2px;right:2px;position:absolute}.gjs-btnt>.gjs-pn-buttons,.gjs-pn-btn>.gjs-pn-buttons{background-color:#444;border-radius:2px;position:absolute;display:none;left:50px;top:0;padding:5px}.gjs-btnt>.gjs-pn-buttons.gjs-pn-visible,.gjs-pn-btn>.gjs-pn-buttons.gjs-pn-visible{display:block}.gjs-btnt>.gjs-pn-buttons>.gjs-pn-arrow-l,.gjs-pn-btn>.gjs-pn-buttons>.gjs-pn-arrow-l{border-bottom:5px solid transparent;border-right:5px solid #444;border-top:5px solid transparent;left:-5px;top:15px;position:absolute}.gjs-nv-navigator{position:relative;height:100%}.gjs-nv-navigator #gjs-nv-placeholder{width:100%;position:absolute}.gjs-nv-navigator #gjs-nv-placeholder #gjs-nv-plh-int{height:100%;padding:1px}.gjs-nv-navigator #gjs-nv-placeholder #gjs-nv-plh-int.gjs-nv-insert{background-color:#62c462}.gjs-nv-navigator .gjs-nv-item{font-weight:lighter;text-align:left;position:relative;background-color:rgba(0,0,0,.1)}.gjs-nv-navigator .gjs-nv-item.gjs-nv-hide{opacity:.55;filter:alpha(opacity=55)}.gjs-nv-navigator .gjs-nv-item #gjs-nv-counter{font-size:10px;position:absolute;right:27px;top:9px}.gjs-nv-navigator .gjs-nv-item #gjs-nv-btn-eye{height:auto!important;width:auto!important;font-size:13px;left:0;top:0;padding:7px 5px 7px 10px;position:absolute;cursor:pointer;z-index:1}.gjs-nv-item #gjs-nv-caret{font-size:7px;width:8px;padding:5px;cursor:pointer;opacity:.7;filter:alpha(opacity=70)}.gjs-nv-item #gjs-nv-caret:hover{opacity:1;filter:alpha(opacity=100)}.gjs-nv-title{background-color:rgba(0,0,0,.1);font-size:11px;letter-spacing:1px;padding:3px 10px 5px 30px;border-bottom:1px solid rgba(0,0,0,.3);border-top:1px solid rgba(255,255,255,.1);display:flex;align-items:center}.gjs-nv-item .gjs-nv-children .gjs-nv-title{border-left:1px solid rgba(5,5,5,.3)}.gjs-nv-item>.gjs-nv-children{margin-left:7px;display:none}.gjs-nv-item.open>.gjs-nv-children{display:block}.gjs-nv-item>.gjs-nv-no-chld>#gjs-nv-caret::before{content:''}.gjs-nv-no-chld>#gjs-nv-caret{display:none}.gjs-nv-item>#gjs-nv-move{position:absolute;cursor:move;font-size:12px;right:0;top:0;padding:7px 10px 7px 5px}.gjs-nv-selected .gjs-nv-title{background-color:rgba(255,255,255,.1)}.gjs-nv-nav-item-edit{visibility:hidden;padding:5px;font-size:10px;opacity:.7;filter:alpha(opacity=70)}.gjs-nv-nav-item-edit:hover{opacity:1;filter:alpha(opacity=100)}.gjs-nv-title-c:hover .gjs-nv-nav-item-edit{visibility:visible;cursor:pointer}.gjs-nav-comp-name{padding:5px;box-sizing:content-box}.btn.expand,.gjs-nv-navigator .gjs-nv-item .expand#gjs-nv-btn-eye{background-image:none}.gjs-comp-image-placeholder{display:block;background-color:#f5f5f5;color:#777;height:50px;width:50px;line-height:50px;outline:#ffca6f solid 3px;outline-offset:-3px;text-align:center;font-size:16.67px;cursor:pointer}.gjs-field-checkbox input,.gjs-radio-item input{display:none}.gjs-comp-image-placeholder.fa-picture-o::after{content:"\f03e"}.gjs-label{line-height:18px}.gjs-field{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.1);box-shadow:1px 1px 0 rgba(255,255,255,.1);border-radius:2px;box-sizing:border-box;padding:0;position:relative}.gjs-field input,.gjs-field select,.gjs-field textarea{-webkit-appearance:none;-moz-appearance:none;appearance:none;color:rgba(255,255,255,.7);border:none;background-color:transparent;box-sizing:border-box;width:100%;position:relative;padding:3px 4px 4px;z-index:1}.gjs-field textarea{resize:vertical}.gjs-field select{height:20px;padding-right:12px}.gjs-field option{padding:3px 0}.gjs-field .gjs-sel-arrow{height:100%;width:9px;position:absolute;right:0;top:0;z-index:0}.gjs-field .gjs-d-s-arrow{bottom:7px;border-top:4px solid rgba(255,255,255,.7);position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;cursor:pointer}.gjs-field-color input{padding-right:22px;box-sizing:border-box}.gjs-field-colorp{border-left:1px solid rgba(0,0,0,.3);box-sizing:border-box;height:100%;padding:2px;position:absolute;right:0;top:0;width:22px;z-index:10}.gjs-field-colorp .gjs-checker-bg,.gjs-field-colorp .gjs-field-colorp-c{height:100%;width:100%;border-radius:1px}.gjs-field-colorp-c{height:100%;position:relative;width:100%}.gjs-field-color-picker{background-color:#ddd;cursor:pointer;height:100%;width:100%;box-shadow:0 0 1px rgba(0,0,0,.3);border-radius:1px;position:absolute;top:0}.gjs-field-radio{float:left;overflow:hidden;padding:0;width:auto}.gjs-field-checkbox{padding:0;width:auto!important}.gjs-field-checkbox input:checked+.gjs-chk-icon{border-color:rgba(255,255,255,.5);border-width:0 2px 2px 0;border-style:solid}.gjs-radio-item{float:left;border-left:1px solid rgba(0,0,0,.3)}.gjs-radio-item:first-child{border:none}.gjs-radio-item:hover{background:rgba(0,0,0,.3)}.gjs-radio-item input:checked+.gjs-radio-item-label{background-color:rgba(255,255,255,.2)}.gjs-radio-item-label{cursor:pointer;display:block;padding:5px}.gjs-field-units{position:absolute;right:0;top:0}.gjs-field-units select{padding:0 12px 0 0}.gjs-field-unit{position:absolute;right:10px;top:3px;font-size:10px;color:rgba(255,255,255,.7);cursor:pointer}.gjs-field-arrows{z-index:10;cursor:ns-resize;height:100%;position:absolute;right:0;top:0;width:9px}.gjs-field-arrow-d,.gjs-field-arrow-u{position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(255,255,255,.7);bottom:4px;cursor:pointer}.gjs-field-arrow-u{border-bottom:4px solid rgba(255,255,255,.7);border-top:none;top:4px}.gjs-field-select{padding:0}.gjs-field-range{background-color:transparent;border:none;box-shadow:none;padding:0}.gjs-field-range input{margin:0}.gjs-field-range input::-moz-range-thumb{height:10px;width:10px;border:1px solid rgba(0,0,0,.3);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-webkit-slider-thumb{-webkit-appearance:none;margin-top:-5px;height:10px;width:10px;border:1px solid rgba(0,0,0,.3);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-ms-thumb{height:10px;width:10px;border:1px solid rgba(0,0,0,.3);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-moz-range-track{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.15);border-radius:1px;height:2px}.gjs-field-range input::-webkit-slider-runnable-track{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.15);border-radius:1px;height:2px}.gjs-field-range input::-ms-track{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.15);border-radius:1px;height:2px}.gjs-chk-icon{-ms-transform:rotate(45deg);-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);transform:rotate(45deg);box-sizing:border-box;display:block;height:14px;margin:0 5px;width:6px;cursor:pointer}.gjs-add-trasp{background:0 0;border:none;color:#ddd;cursor:pointer;font-size:1em;border-radius:2px;opacity:.75;filter:alpha(opacity=75)}.gjs-add-trasp:hover{opacity:1;filter:alpha(opacity=100)}.gjs-add-trasp:active{background-color:rgba(0,0,0,.2)}.gjs-devices-c{display:flex;align-items:center;padding:4px}.gjs-devices-c .gjs-device-label{flex-grow:2;font-size:.7em;text-align:left;margin-right:10px}.gjs-devices-c .gjs-select{flex-grow:20}.gjs-devices-c .gjs-add-trasp{flex-grow:1;margin-left:5px}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close,.gjs-sm-close-btn,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close{display:block;font-size:23px;position:absolute;cursor:pointer;right:5px;top:0;opacity:.2;filter:alpha(opacity=20)}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close:hover,.gjs-sm-close-btn:hover,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close:hover{opacity:.7;filter:alpha(opacity=70)}.gjs-sm-header{font-size:11px;font-weight:lighter;padding:10px}.gjs-clm-tags,.gjs-sm-sector{clear:both;border-bottom:1px solid rgba(0,0,0,.3);font-weight:lighter;text-align:left}.gjs-clm-tags #gjs-sm-caret,.gjs-sm-sector #gjs-sm-caret{padding-right:5px;font-size:11px}.gjs-clm-tags .gjs-sm-title,.gjs-sm-sector .gjs-sm-title{background-color:rgba(0,0,0,.1);font-size:13px;letter-spacing:1px;padding:12px 10px 12px 20px;border-top:1px solid rgba(255,255,255,.1);cursor:pointer}.gjs-clm-tags .gjs-sm-label,.gjs-sm-sector .gjs-sm-label{margin:5px 5px 2px 0}.gjs-clm-tags .gjs-clm-field,.gjs-clm-tags .gjs-sm-field,.gjs-sm-sector .gjs-clm-field,.gjs-sm-sector .gjs-sm-field{width:100%;position:relative}.gjs-clm-tags .gjs-clm-field input,.gjs-clm-tags .gjs-clm-field select,.gjs-clm-tags .gjs-sm-field input,.gjs-clm-tags .gjs-sm-field select,.gjs-sm-sector .gjs-clm-field input,.gjs-sm-sector .gjs-clm-field select,.gjs-sm-sector .gjs-sm-field input,.gjs-sm-sector .gjs-sm-field select{background-color:transparent;color:rgba(255,255,255,.7);border:none;width:100%}.gjs-clm-tags .gjs-clm-field input,.gjs-clm-tags .gjs-sm-field input,.gjs-sm-sector .gjs-clm-field input,.gjs-sm-sector .gjs-sm-field input{box-sizing:border-box}.gjs-clm-tags .gjs-clm-field select,.gjs-clm-tags .gjs-sm-field select,.gjs-sm-sector .gjs-clm-field select,.gjs-sm-sector .gjs-sm-field select{position:relative;z-index:1;-webkit-appearance:none;-moz-appearance:none;appearance:none}.gjs-clm-tags .gjs-clm-field select::-ms-expand,.gjs-clm-tags .gjs-sm-field select::-ms-expand,.gjs-sm-sector .gjs-clm-field select::-ms-expand,.gjs-sm-sector .gjs-sm-field select::-ms-expand{display:none}.gjs-clm-tags .gjs-clm-field select:-moz-focusring,.gjs-clm-tags .gjs-sm-field select:-moz-focusring,.gjs-sm-sector .gjs-clm-field select:-moz-focusring,.gjs-sm-sector .gjs-sm-field select:-moz-focusring{color:transparent;text-shadow:0 0 0 rgba(255,255,255,.7)}.gjs-clm-tags .gjs-clm-field input:focus,.gjs-clm-tags .gjs-clm-field select:focus,.gjs-clm-tags .gjs-sm-field input:focus,.gjs-clm-tags .gjs-sm-field select:focus,.gjs-sm-sector .gjs-clm-field input:focus,.gjs-sm-sector .gjs-clm-field select:focus,.gjs-sm-sector .gjs-sm-field input:focus,.gjs-sm-sector .gjs-sm-field select:focus{outline:0}.gjs-clm-tags .gjs-clm-field .gjs-sm-unit,.gjs-clm-tags .gjs-sm-field .gjs-sm-unit,.gjs-sm-sector .gjs-clm-field .gjs-sm-unit,.gjs-sm-sector .gjs-sm-field .gjs-sm-unit{position:absolute;right:10px;top:3px;font-size:10px;color:rgba(255,255,255,.7);cursor:pointer}.gjs-clm-tags .gjs-clm-field .gjs-clm-sel-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-int-arrows,.gjs-clm-tags .gjs-clm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-int-arrows,.gjs-clm-tags .gjs-sm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-int-arrows,.gjs-sm-sector .gjs-clm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-sm-field .gjs-clm-sel-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-int-arrows,.gjs-sm-sector .gjs-sm-field .gjs-sm-sel-arrow{height:100%;width:9px;position:absolute;right:0;top:0;cursor:ns-resize}.gjs-clm-tags .gjs-clm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-sel-arrow{cursor:pointer}.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-u-arrow{position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;cursor:pointer}.gjs-clm-tags .gjs-clm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-u-arrow{border-bottom:4px solid rgba(255,255,255,.7);top:4px}.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow{border-top:4px solid rgba(255,255,255,.7);bottom:4px}.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow{bottom:7px}.gjs-clm-tags .gjs-clm-select,.gjs-clm-tags .gjs-sm-color.gjs-clm-field,.gjs-clm-tags .gjs-sm-field.gjs-sm-color,.gjs-clm-tags .gjs-sm-field.gjs-sm-input,.gjs-clm-tags .gjs-sm-field.gjs-sm-integer,.gjs-clm-tags .gjs-sm-field.gjs-sm-list,.gjs-clm-tags .gjs-sm-field.gjs-sm-select,.gjs-clm-tags .gjs-sm-input.gjs-clm-field,.gjs-clm-tags .gjs-sm-integer.gjs-clm-field,.gjs-clm-tags .gjs-sm-list.gjs-clm-field,.gjs-clm-tags .gjs-sm-select.gjs-clm-field,.gjs-sm-sector .gjs-clm-select,.gjs-sm-sector .gjs-sm-color.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-color,.gjs-sm-sector .gjs-sm-field.gjs-sm-input,.gjs-sm-sector .gjs-sm-field.gjs-sm-integer,.gjs-sm-sector .gjs-sm-field.gjs-sm-list,.gjs-sm-sector .gjs-sm-field.gjs-sm-select,.gjs-sm-sector .gjs-sm-input.gjs-clm-field,.gjs-sm-sector .gjs-sm-integer.gjs-clm-field,.gjs-sm-sector .gjs-sm-list.gjs-clm-field,.gjs-sm-sector .gjs-sm-select.gjs-clm-field{background-color:rgba(0,0,0,.3);border:1px solid rgba(0,0,0,.1);box-shadow:1px 1px 0 rgba(255,255,255,.1);color:rgba(255,255,255,.7);border-radius:2px;box-sizing:border-box;padding:0 5px}.gjs-clm-tags .gjs-sm-composite.gjs-clm-field,.gjs-clm-tags .gjs-sm-field.gjs-sm-composite,.gjs-sm-sector .gjs-sm-composite.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-composite{border-radius:2px;background-color:rgba(0,0,0,.1);border:1px solid rgba(0,0,0,.25)}.gjs-clm-tags .gjs-clm-select,.gjs-clm-tags .gjs-sm-field.gjs-sm-select,.gjs-clm-tags .gjs-sm-select.gjs-clm-field,.gjs-sm-sector .gjs-clm-select,.gjs-sm-sector .gjs-sm-field.gjs-sm-select,.gjs-sm-sector .gjs-sm-select.gjs-clm-field{padding:0}.gjs-clm-tags .gjs-clm-select select,.gjs-clm-tags .gjs-sm-field.gjs-sm-select select,.gjs-clm-tags .gjs-sm-select.gjs-clm-field select,.gjs-sm-sector .gjs-clm-select select,.gjs-sm-sector .gjs-sm-field.gjs-sm-select select,.gjs-sm-sector .gjs-sm-select.gjs-clm-field select{height:20px}.gjs-clm-tags .gjs-clm-select option,.gjs-clm-tags .gjs-sm-field.gjs-sm-select option,.gjs-clm-tags .gjs-sm-select.gjs-clm-field option,.gjs-sm-sector .gjs-clm-select option,.gjs-sm-sector .gjs-sm-field.gjs-sm-select option,.gjs-sm-sector .gjs-sm-select.gjs-clm-field option{padding:3px 0}.gjs-clm-tags .gjs-sm-field.gjs-sm-list,.gjs-clm-tags .gjs-sm-list.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-list,.gjs-sm-sector .gjs-sm-list.gjs-clm-field{width:auto;padding:0;overflow:hidden;float:left}.gjs-clm-tags .gjs-sm-field.gjs-sm-list input,.gjs-clm-tags .gjs-sm-list.gjs-clm-field input,.gjs-sm-sector .gjs-sm-field.gjs-sm-list input,.gjs-sm-sector .gjs-sm-list.gjs-clm-field input{display:none}.gjs-clm-tags .gjs-sm-field.gjs-sm-list label,.gjs-clm-tags .gjs-sm-list.gjs-clm-field label,.gjs-sm-sector .gjs-sm-field.gjs-sm-list label,.gjs-sm-sector .gjs-sm-list.gjs-clm-field label{cursor:pointer;padding:5px;display:block}.gjs-clm-tags .gjs-sm-field.gjs-sm-list .gjs-sm-radio:checked+label,.gjs-clm-tags .gjs-sm-list.gjs-clm-field .gjs-sm-radio:checked+label,.gjs-sm-sector .gjs-sm-field.gjs-sm-list .gjs-sm-radio:checked+label,.gjs-sm-sector .gjs-sm-list.gjs-clm-field .gjs-sm-radio:checked+label{background-color:rgba(255,255,255,.2)}.gjs-clm-tags .gjs-sm-field.gjs-sm-list .gjs-sm-icon,.gjs-clm-tags .gjs-sm-list.gjs-clm-field .gjs-sm-icon,.gjs-sm-sector .gjs-sm-field.gjs-sm-list .gjs-sm-icon,.gjs-sm-sector .gjs-sm-list.gjs-clm-field .gjs-sm-icon{background-repeat:no-repeat;background-position:center;text-shadow:none;line-height:normal}.gjs-clm-tags .gjs-sm-field.gjs-sm-integer select,.gjs-clm-tags .gjs-sm-integer.gjs-clm-field select,.gjs-sm-sector .gjs-sm-field.gjs-sm-integer select,.gjs-sm-sector .gjs-sm-integer.gjs-clm-field select{width:auto;padding:0}.gjs-clm-tags .gjs-sm-list .gjs-sm-el,.gjs-sm-sector .gjs-sm-list .gjs-sm-el{float:left;border-left:1px solid rgba(0,0,0,.3)}.gjs-clm-tags .gjs-sm-list .gjs-sm-el:first-child,.gjs-sm-sector .gjs-sm-list .gjs-sm-el:first-child{border:none}.gjs-clm-tags .gjs-sm-list .gjs-sm-el:hover,.gjs-sm-sector .gjs-sm-list .gjs-sm-el:hover{background:rgba(0,0,0,.3)}.gjs-clm-tags .gjs-sm-properties,.gjs-sm-sector .gjs-sm-properties{font-size:11px;padding:10px 5px}.gjs-clm-tags .gjs-sm-property,.gjs-sm-sector .gjs-sm-property{box-sizing:border-box;float:left;width:50%;margin-bottom:5px;padding:0 5px}.gjs-clm-tags .gjs-sm-property.gjs-sm-composite,.gjs-clm-tags .gjs-sm-property.gjs-sm-file,.gjs-clm-tags .gjs-sm-property.gjs-sm-list,.gjs-clm-tags .gjs-sm-property.gjs-sm-stack,.gjs-sm-sector .gjs-sm-property.gjs-sm-composite,.gjs-sm-sector .gjs-sm-property.gjs-sm-file,.gjs-sm-sector .gjs-sm-property.gjs-sm-list,.gjs-sm-sector .gjs-sm-property.gjs-sm-stack{width:100%}.gjs-clm-tags .gjs-sm-property .gjs-sm-btn,.gjs-sm-sector .gjs-sm-property .gjs-sm-btn{background-color:rgba(33,33,33,.3);border-radius:2px;box-shadow:1px 1px 0 rgba(5,5,5,.3),1px 1px 0 rgba(43,43,43,.3) inset;padding:5px;position:relative;text-align:center;height:auto;width:100%;cursor:pointer;color:#ddd;box-sizing:border-box;text-shadow:-1px -1px 0 rgba(0,0,0,.3);border:none;opacity:.85;filter:alpha(opacity=85)}.gjs-clm-tags .gjs-sm-property .gjs-sm-btn-c,.gjs-sm-sector .gjs-sm-property .gjs-sm-btn-c{box-sizing:border-box;float:left;width:100%;padding:0 5px}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box{background-color:rgba(255,255,255,.05);border-radius:2px;margin-top:5px;position:relative;overflow:hidden}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box.gjs-sm-show,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box.gjs-sm-show{border:1px solid rgba(252,252,252,.05);padding:3px 5px}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close{display:block}.gjs-clm-tags .gjs-sm-property.gjs-sm-file .gjs-sm-show #gjs-sm-preview-file,.gjs-sm-sector .gjs-sm-property.gjs-sm-file .gjs-sm-show #gjs-sm-preview-file{height:50px}.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-file,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-file{background-size:auto 100%;background-repeat:no-repeat;background-position:center center}.gjs-clm-tags .gjs-sm-property .gjs-sm-layers,.gjs-sm-sector .gjs-sm-property .gjs-sm-layers{margin-top:5px;min-height:30px}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer{background-color:rgba(255,255,255,.055);border-radius:2px;box-shadow:1px 1px 0 rgba(0,0,0,.2),1px 1px 0 rgba(255,255,255,.055) inset;margin:2px;padding:7px;position:relative;cursor:pointer}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box{height:15px;position:absolute;right:27px;top:6px;width:15px}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-preview,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-preview-box,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-preview,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-preview-box{border-radius:2px}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer{display:block;font-size:23px;position:absolute;cursor:pointer;right:5px;top:0;opacity:.5;filter:alpha(opacity=50)}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer:hover,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer:hover{opacity:.8;filter:alpha(opacity=80)}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box #gjs-sm-preview,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box #gjs-sm-preview{background-color:#fff;height:100%;width:100%;background-size:cover!important}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer.gjs-sm-active,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer.gjs-sm-active{background-color:rgba(255,255,255,.12)}.gjs-clm-tags .gjs-sm-property .gjs-sm-layer.gjs-sm-no-preview #gjs-sm-preview-box,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer.gjs-sm-no-preview #gjs-sm-preview-box{display:none}.gjs-clm-tags #gjs-sm-text-shadow #gjs-sm-preview::after,.gjs-sm-sector #gjs-sm-text-shadow #gjs-sm-preview::after{color:#000;content:"T";font-weight:900;line-height:17px;padding:0 4px}.gjs-clm-tags .gjs-sm-stack .gjs-sm-properties,.gjs-sm-sector .gjs-sm-stack .gjs-sm-properties{padding-top:5px}.gjs-clm-tags .gjs-sm-stack #gjs-sm-add,.gjs-sm-sector .gjs-sm-stack #gjs-sm-add{background:0 0;border:none;cursor:pointer;font-size:22px;line-height:10px;position:absolute;right:0;top:-20px;opacity:.75}.gjs-clm-tags .gjs-sm-stack #gjs-sm-add:hover,.gjs-sm-sector .gjs-sm-stack #gjs-sm-add:hover{opacity:1;filter:alpha(opacity=100)}.gjs-clm-tags .gjs-sm-colorp-c,.gjs-sm-sector .gjs-sm-colorp-c{height:100%;width:20px;position:absolute;right:0;top:0;box-sizing:border-box;border-radius:2px;padding:2px}.gjs-clm-tags .gjs-sm-colorp-c .gjs-checker-bg,.gjs-clm-tags .gjs-sm-colorp-c .gjs-field-colorp-c,.gjs-sm-sector .gjs-sm-colorp-c .gjs-checker-bg,.gjs-sm-sector .gjs-sm-colorp-c .gjs-field-colorp-c{height:100%;width:100%;border-radius:1px}.gjs-clm-tags .gjs-sm-color-picker,.gjs-sm-sector .gjs-sm-color-picker{background-color:#ddd;cursor:pointer;height:16px;width:100%;margin-top:-16px;box-shadow:0 0 1px rgba(0,0,0,.3);border-radius:1px}.gjs-clm-tags .gjs-sm-btn-upload #gjs-sm-upload,.gjs-sm-sector .gjs-sm-btn-upload #gjs-sm-upload{left:0;top:0;position:absolute;width:100%;opacity:0;cursor:pointer}.gjs-clm-tags .gjs-sm-btn-upload #gjs-sm-label,.gjs-sm-sector .gjs-sm-btn-upload #gjs-sm-label{padding:2px 0}.gjs-sm-layer>#gjs-sm-move{opacity:.7;filter:alpha(opacity=70);cursor:move;font-size:12px;float:left;margin:0 5px 0 0}.gjs-sm-layer>#gjs-sm-move:hover{opacity:.9;filter:alpha(opacity=90)}.gjs-blocks-c{display:flex;flex-wrap:wrap;justify-content:flex-start}.gjs-block{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none;width:45%;padding:1em;box-sizing:border-box;height:90px;cursor:all-scroll;font-size:11px;font-weight:lighter;display:flex;flex-direction:column;justify-content:flex-end;border:1px solid rgba(0,0,0,.2);border-radius:3px;margin:10px 2.5% 5px;box-shadow:0 1px 0 0 rgba(0,0,0,.15);transition:all .2s ease 0s;transition-property:box-shadow,color}.gjs-block:hover{box-shadow:0 3px 4px 0 rgba(0,0,0,.15)}.gjs-block.fa{font-size:2em;line-height:2em;padding:11px}.gjs-block-label{line-height:normal;font-size:.65rem;font-weight:400}.gjs-block.gjs-bdrag{width:auto;padding:0}.gjs-clm-tags{font-size:11px;padding:10px 5px}.gjs-clm-tags #gjs-clm-label,.gjs-clm-tags #gjs-clm-sel{padding:7px 0;float:left}.gjs-clm-tags #gjs-clm-sel{font-style:italic;margin-left:5px}.gjs-clm-tags #gjs-clm-status-c{float:right}.gjs-clm-tags #gjs-clm-tags-field{clear:both;padding:5px;margin-bottom:5px}.gjs-clm-tags #gjs-clm-tags-c{display:inline-block;vertical-align:top}.gjs-clm-tags #gjs-clm-add-tag{background-color:rgba(255,255,255,.15);border-radius:2px;padding:5px 6px;box-shadow:1px 1px 0 rgba(255,255,255,.2) inset;border:1px solid rgba(0,0,0,.15);cursor:pointer}.gjs-clm-tags #gjs-clm-new{color:#ddd;padding:5px 6px;display:none}.gjs-clm-tags .gjs-clm-tag{background-color:#804f7b;border:1px solid #5a3857;box-shadow:1px 1px #9c6196 inset;text-shadow:1px 1px #6a4166;display:inline-block;border-radius:3px;margin:0 3px 3px 0;padding:4px;cursor:default}.gjs-clm-tags #gjs-clm-close{font-size:20px;line-height:0;cursor:pointer;color:rgba(255,255,255,.9)}.gjs-clm-tags #gjs-clm-close:hover{opacity:.7;filter:alpha(opacity=70)}.gjs-clm-tags #gjs-clm-checkbox{color:rgba(255,255,255,.9);vertical-align:middle;cursor:pointer;font-size:9px}.gjs-clm-tags #gjs-clm-tag-label{cursor:text}.gjs-clm-tags #gjs-clm-tag-label input{width:auto;padding:0 4px}.gjs-mdl-backlayer,.gjs-mdl-container{position:absolute;top:0;left:0;width:100%;height:100%}.gjs-mdl-backlayer{background-color:#000;z-index:1;opacity:.5;filter:alpha(opacity=50)}.gjs-mdl-container{z-index:10}.gjs-mdl-dialog{text-shadow:-1px -1px 0 rgba(0,0,0,.05);animation:gjs-slide-down 215ms;margin:30px auto 0;max-width:850px;width:90%;border-radius:3px;font-weight:lighter;position:relative;z-index:2}.gjs-mdl-dialog .gjs-mdl-btn-close{position:absolute;right:15px;top:5px}.gjs-mdl-active .gjs-mdl-dialog{animation:gjs-mdl-slide-down 216ms}.gjs-mdl-content,.gjs-mdl-header{padding:10px 15px;clear:both}.gjs-mdl-header{position:relative;border-bottom:1px solid rgba(0,0,0,.3);padding:15px 15px 7px}.gjs-mdl-content{border-top:1px solid rgba(255,255,255,.1)}.gjs-export-dl::after{content:"";clear:both;display:block;margin-bottom:10px}.gjs-am-assets{height:290px;overflow:auto;clear:both}.gjs-am-assets-header{padding:5px}.gjs-am-add-asset .gjs-am-add-field{width:70%;float:left}.gjs-am-add-asset button{width:25%;float:right}.gjs-am-add-field input{padding:6px}.gjs-am-assets-cont{background-color:rgba(0,0,0,.1);border-radius:3px;box-sizing:border-box;padding:10px;width:45%;float:right;height:325px;overflow:hidden}.gjs-am-assets-cont #gjs-am-preview-cont{position:relative;height:70px;width:30%;background-color:#444;border-radius:2px;float:left;overflow:hidden}.gjs-am-assets-cont #gjs-am-preview{position:absolute;background-position:center center;background-size:cover;background-repeat:no-repeat;height:100%;width:100%;z-index:1}.gjs-am-assets-cont #gjs-am-preview-bg{position:absolute;height:100%;width:100%;opacity:.5;filter:alpha(opacity=50);z-index:0}.gjs-am-assets-cont .gjs-am-highlight{background-color:rgba(255,255,255,.1)}.gjs-am-assets-cont .gjs-am-asset{border-bottom:1px solid rgba(0,0,0,.3);padding:5px;cursor:pointer;position:relative}.gjs-am-assets-cont .gjs-am-asset:hover #gjs-am-close{display:block}.gjs-am-assets-cont #gjs-am-close{position:absolute;right:5px;top:0;display:none}.gjs-am-assets-cont #gjs-am-meta{width:70%;float:left;font-size:12px;padding:5px 0 0 5px;box-sizing:border-box}.gjs-am-assets-cont #gjs-am-meta>div{margin-bottom:5px}.gjs-am-assets-cont #gjs-am-meta #gjs-am-dimensions{font-size:10px;opacity:.5;filter:alpha(opacity=50)}.gjs-am-file-uploader{width:55%;float:left}.gjs-am-file-uploader>form{background-color:rgba(0,0,0,.1);border:2px dashed;border-radius:3px;position:relative;text-align:center;margin-bottom:15px}#gjs-rte-toolbar .gjs-rte-btn.btn-info,.gjs-cm-editor #gjs-cm-title{background-color:rgba(0,0,0,.3)}.gjs-am-file-uploader>form.gjs-am-hover{border:2px solid #62c462;color:#75cb75}.gjs-am-file-uploader>form.gjs-am-disabled{border-color:red}.gjs-am-file-uploader>form #gjs-am-uploadFile{opacity:0;filter:alpha(opacity=0);padding:150px 10px;width:100%;box-sizing:border-box}.gjs-am-file-uploader #gjs-am-title{position:absolute;padding:150px 10px;width:100%}.gjs-cm-editor-c{float:left;box-sizing:border-box;width:50%}.gjs-cm-editor-c .CodeMirror{height:450px}.gjs-cm-editor{font-size:12px}.gjs-cm-editor#gjs-cm-htmlmixed{padding-right:10px;border-right:1px solid rgba(0,0,0,.3)}.gjs-cm-editor#gjs-cm-htmlmixed #gjs-cm-title{color:#a97d44}.gjs-cm-editor#gjs-cm-css{padding-left:10px;border-left:1px solid rgba(255,255,255,.1)}.gjs-cm-editor#gjs-cm-css #gjs-cm-title{color:#ddca7e}.gjs-cm-editor #gjs-cm-title{font-size:12px;padding:5px 10px 3px;text-align:right}#gjs-rte-toolbar{display:none;border:1px solid rgba(0,0,0,.3);position:absolute;border-radius:3px;z-index:10}#gjs-rte-toolbar .gjs-rte-btn{display:inline-block;padding:5px;min-width:25px;border-right:1px solid rgba(0,0,0,.3);text-align:center;cursor:pointer;outline:0}#gjs-rte-toolbar .gjs-rte-btn:last-child{border-right:none}#gjs-rte-toolbar .gjs-rte-btn:hover{background-color:rgba(255,255,255,.1)}#gjs-rte-toolbar select{height:16px}.sp-hue,.sp-slider{cursor:row-resize}.sp-color,.sp-dragger{cursor:crosshair}.sp-alpha-handle,.sp-alpha-inner{cursor:col-resize}.sp-hue{left:90%}.sp-color{right:15%}.sp-container{border:1px solid rgba(0,0,0,.3);box-shadow:0 0 7px rgba(0,0,0,.3);border-radius:3px}.sp-picker-container{border:none}.colpick_dark .colpick_color{outline:rgba(0,0,0,.3) solid 1px}.sp-cancel,.sp-cancel:hover{bottom:-8px;color:#777!important;font-size:25px;left:0;position:absolute;text-decoration:none}.sp-alpha-handle{border:1px solid #555;width:4px}.sp-color,.sp-hue{border:1px solid #333}.sp-slider{border:1px solid #555;height:3px;left:-4px;width:22px}.sp-dragger{background:0 0;box-shadow:0 0 0 1px #111}.sp-button-container{float:none;width:100%;position:relative;text-align:right}.sp-container button,.sp-container button:active,.sp-container button:hover{background:rgba(0,0,0,.3);border-color:rgba(0,0,0,.3);color:#ddd;text-shadow:none;box-shadow:none;padding:3px 5px}.sp-palette-container{border:none;float:none;margin:0;padding:5px 10px 0}.sp-palette .sp-thumb-el,.sp-palette .sp-thumb-el:hover{border:1px solid rgba(0,0,0,.9)}.sp-palette .sp-thumb-el.sp-thumb-active,.sp-palette .sp-thumb-el:hover{border-color:rgba(0,0,0,.9)}.gjs-hidden{display:none}@keyframes gjs-slide-down{0%{transform:translate(0,-3rem);opacity:0}100%{transform:translate(0,0);opacity:1}}@keyframes gjs-slide-up{0%{transform:translate(0,0);opacity:1}100%{transform:translate(0,-3rem);opacity:0}} + */@font-face{font-family:'FontAwesome';src:url("../fonts/fontawesome-webfont.eot?v=4.7.0");src:url("../fonts/fontawesome-webfont.eot?#iefix&v=4.7.0") format("embedded-opentype"),url("../fonts/fontawesome-webfont.woff2?v=4.7.0") format("woff2"),url("../fonts/fontawesome-webfont.woff?v=4.7.0") format("woff"),url("../fonts/fontawesome-webfont.ttf?v=4.7.0") format("truetype"),url("../fonts/fontawesome-webfont.svg?v=4.7.0#fontawesomeregular") format("svg");font-weight:normal;font-style:normal}.fa{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14286em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14286em;width:2.14286em;top:.14286em;text-align:center}.fa-li.fa-lg{left:-1.85714em}.fa-border{padding:.2em .25em .15em;border:solid 0.08em #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa.fa-pull-left{margin-right:.3em}.fa.fa-pull-right{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left{margin-right:.3em}.fa.pull-right{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s infinite linear;animation:fa-spin 2s infinite linear}.fa-pulse{-webkit-animation:fa-spin 1s infinite steps(8);animation:fa-spin 1s infinite steps(8)}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}100%{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scale(-1, 1);-ms-transform:scale(-1, 1);transform:scale(-1, 1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scale(1, -1);-ms-transform:scale(1, -1);transform:scale(1, -1)}:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270,:root .fa-flip-horizontal,:root .fa-flip-vertical{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-remove:before,.fa-close:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-gear:before,.fa-cog:before{content:""}.fa-trash-o:before{content:""}.fa-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-rotate-right:before,.fa-repeat:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-photo:before,.fa-image:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before{content:""}.fa-check-circle:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-warning:before,.fa-exclamation-triangle:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-gears:before,.fa-cogs:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before{content:""}.fa-arrow-circle-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-save:before,.fa-floppy-o:before{content:""}.fa-square:before{content:""}.fa-navicon:before,.fa-reorder:before,.fa-bars:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-unsorted:before,.fa-sort:before{content:""}.fa-sort-down:before,.fa-sort-desc:before{content:""}.fa-sort-up:before,.fa-sort-asc:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-legal:before,.fa-gavel:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-flash:before,.fa-bolt:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-paste:before,.fa-clipboard:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-unlink:before,.fa-chain-broken:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-toggle-down:before,.fa-caret-square-o-down:before{content:""}.fa-toggle-up:before,.fa-caret-square-o-up:before{content:""}.fa-toggle-right:before,.fa-caret-square-o-right:before{content:""}.fa-euro:before,.fa-eur:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-rupee:before,.fa-inr:before{content:""}.fa-cny:before,.fa-rmb:before,.fa-yen:before,.fa-jpy:before{content:""}.fa-ruble:before,.fa-rouble:before,.fa-rub:before{content:""}.fa-won:before,.fa-krw:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-toggle-left:before,.fa-caret-square-o-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-turkish-lira:before,.fa-try:before{content:""}.fa-plus-square-o:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-institution:before,.fa-bank:before,.fa-university:before{content:""}.fa-mortar-board:before,.fa-graduation-cap:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper-pp:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-photo-o:before,.fa-file-picture-o:before,.fa-file-image-o:before{content:""}.fa-file-zip-o:before,.fa-file-archive-o:before{content:""}.fa-file-sound-o:before,.fa-file-audio-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-saver:before,.fa-support:before,.fa-life-ring:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-resistance:before,.fa-rebel:before{content:""}.fa-ge:before,.fa-empire:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-y-combinator-square:before,.fa-yc-square:before,.fa-hacker-news:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-send:before,.fa-paper-plane:before{content:""}.fa-send-o:before,.fa-paper-plane-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-soccer-ball-o:before,.fa-futbol-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-shekel:before,.fa-sheqel:before,.fa-ils:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-hotel:before,.fa-bed:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-yc:before,.fa-y-combinator:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery:before,.fa-battery-full:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-stop-o:before,.fa-hand-paper-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-tv:before,.fa-television:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.fa-reddit-alien:before{content:""}.fa-edge:before{content:""}.fa-credit-card-alt:before{content:""}.fa-codiepie:before{content:""}.fa-modx:before{content:""}.fa-fort-awesome:before{content:""}.fa-usb:before{content:""}.fa-product-hunt:before{content:""}.fa-mixcloud:before{content:""}.fa-scribd:before{content:""}.fa-pause-circle:before{content:""}.fa-pause-circle-o:before{content:""}.fa-stop-circle:before{content:""}.fa-stop-circle-o:before{content:""}.fa-shopping-bag:before{content:""}.fa-shopping-basket:before{content:""}.fa-hashtag:before{content:""}.fa-bluetooth:before{content:""}.fa-bluetooth-b:before{content:""}.fa-percent:before{content:""}.fa-gitlab:before{content:""}.fa-wpbeginner:before{content:""}.fa-wpforms:before{content:""}.fa-envira:before{content:""}.fa-universal-access:before{content:""}.fa-wheelchair-alt:before{content:""}.fa-question-circle-o:before{content:""}.fa-blind:before{content:""}.fa-audio-description:before{content:""}.fa-volume-control-phone:before{content:""}.fa-braille:before{content:""}.fa-assistive-listening-systems:before{content:""}.fa-asl-interpreting:before,.fa-american-sign-language-interpreting:before{content:""}.fa-deafness:before,.fa-hard-of-hearing:before,.fa-deaf:before{content:""}.fa-glide:before{content:""}.fa-glide-g:before{content:""}.fa-signing:before,.fa-sign-language:before{content:""}.fa-low-vision:before{content:""}.fa-viadeo:before{content:""}.fa-viadeo-square:before{content:""}.fa-snapchat:before{content:""}.fa-snapchat-ghost:before{content:""}.fa-snapchat-square:before{content:""}.fa-pied-piper:before{content:""}.fa-first-order:before{content:""}.fa-yoast:before{content:""}.fa-themeisle:before{content:""}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:""}.fa-fa:before,.fa-font-awesome:before{content:""}.fa-handshake-o:before{content:""}.fa-envelope-open:before{content:""}.fa-envelope-open-o:before{content:""}.fa-linode:before{content:""}.fa-address-book:before{content:""}.fa-address-book-o:before{content:""}.fa-vcard:before,.fa-address-card:before{content:""}.fa-vcard-o:before,.fa-address-card-o:before{content:""}.fa-user-circle:before{content:""}.fa-user-circle-o:before{content:""}.fa-user-o:before{content:""}.fa-id-badge:before{content:""}.fa-drivers-license:before,.fa-id-card:before{content:""}.fa-drivers-license-o:before,.fa-id-card-o:before{content:""}.fa-quora:before{content:""}.fa-free-code-camp:before{content:""}.fa-telegram:before{content:""}.fa-thermometer-4:before,.fa-thermometer:before,.fa-thermometer-full:before{content:""}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:""}.fa-thermometer-2:before,.fa-thermometer-half:before{content:""}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:""}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:""}.fa-shower:before{content:""}.fa-bathtub:before,.fa-s15:before,.fa-bath:before{content:""}.fa-podcast:before{content:""}.fa-window-maximize:before{content:""}.fa-window-minimize:before{content:""}.fa-window-restore:before{content:""}.fa-times-rectangle:before,.fa-window-close:before{content:""}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:""}.fa-bandcamp:before{content:""}.fa-grav:before{content:""}.fa-etsy:before{content:""}.fa-imdb:before{content:""}.fa-ravelry:before{content:""}.fa-eercast:before{content:""}.fa-microchip:before{content:""}.fa-snowflake-o:before{content:""}.fa-superpowers:before{content:""}.fa-wpexplorer:before{content:""}.fa-meetup:before{content:""}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0, 0, 0, 0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}.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:none;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{0%{}50%{background-color:transparent}100%{}}@-webkit-keyframes blink{0%{}50%{background-color:transparent}100%{}}@keyframes blink{0%{}50%{background-color:transparent}100%{}}.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,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:none;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:0.1px}.CodeMirror-rtl pre{direction:rtl}.CodeMirror-code{outline:none}.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,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:none}.cm-s-hopscotch.CodeMirror{background:#322931;color:#d5d3d5}.cm-s-hopscotch div.CodeMirror-selected{background:#433b42 !important}.cm-s-hopscotch .CodeMirror-gutters{background:#322931;border-right:0px}.cm-s-hopscotch .CodeMirror-linenumber{color:#797379}.cm-s-hopscotch .CodeMirror-cursor{border-left:1px solid #989498 !important}.cm-s-hopscotch span.cm-comment{color:#b33508}.cm-s-hopscotch span.cm-atom{color:#c85e7c}.cm-s-hopscotch span.cm-number{color:#c85e7c}.cm-s-hopscotch span.cm-property,.cm-s-hopscotch span.cm-attribute{color:#8fc13e}.cm-s-hopscotch span.cm-keyword{color:#dd464c}.cm-s-hopscotch span.cm-string{color:#fdcc59}.cm-s-hopscotch span.cm-variable{color:#8fc13e}.cm-s-hopscotch span.cm-variable-2{color:#1290bf}.cm-s-hopscotch span.cm-def{color:#fd8b19}.cm-s-hopscotch span.cm-error{background:#dd464c;color:#989498}.cm-s-hopscotch span.cm-bracket{color:#d5d3d5}.cm-s-hopscotch span.cm-tag{color:#dd464c}.cm-s-hopscotch span.cm-link{color:#c85e7c}.cm-s-hopscotch .CodeMirror-matchingbracket{text-decoration:underline;color:white !important}.cm-s-hopscotch .CodeMirror-activeline-background{background:#302020}@font-face{font-family:'font3336';src:url("../fonts/main-fonts.eot?v=20");src:url("../fonts/main-fonts.woff?v=20") format("woff"),url("../fonts/main-fonts.ttf?v=20") format("truetype"),url("../fonts/main-fonts.svg?v=20") format("svg"),url("../fonts/main-fonts.eot?v=20") format("embedded-opentype");font-weight:normal;font-style:normal}.gjs-one-bg{background-color:#444}.gjs-one-color{color:#444}.gjs-one-color-h:hover{color:#444}.gjs-two-bg{background-color:#ddd}.gjs-two-color{color:#ddd}.gjs-two-color-h:hover{color:#ddd}.gjs-three-bg{background-color:#804f7b}.gjs-three-color{color:#804f7b}.gjs-three-color-h:hover{color:#804f7b}.gjs-four-bg{background-color:#d278c9}.gjs-four-color{color:#d278c9}.gjs-four-color-h:hover{color:#d278c9}.gjs-bg-main,.gjs-off-prv,.gjs-sm-sector .gjs-sm-colorp-c,.gjs-clm-tags .gjs-sm-colorp-c{background-color:#444}.gjs-color-main,.gjs-off-prv,.gjs-sm-sector .gjs-sm-stack #gjs-sm-add,.gjs-clm-tags .gjs-sm-stack #gjs-sm-add{color:#ddd;fill:#ddd}.gjs-color-active{color:#f8f8f8;fill:#f8f8f8}.gjs-color-warn{color:#ffca6f;fill:#ffca6f}.gjs-color-hl{color:#71b7f1;fill:#71b7f1}.gjs-fonts::before{display:block;font:normal normal normal 14px font3336;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;font-size:5em}.gjs-f-b1::before{content:'Q'}.gjs-f-b2::before{content:'W'}.gjs-f-b3::before{content:'E'}.gjs-f-b37::before{content:'R'}.gjs-f-hero::before{content:'T'}.gjs-f-h1p::before{content:'y'}.gjs-f-3ba::before{content:'u'}.gjs-f-image::before{content:'I'}.gjs-f-text::before{content:'o'}.gjs-f-quo::before{content:'p'}.gjs-f-button::before{content:'B'}.gjs-f-divider::before{content:'D'}.gjs-invis-invis,.gjs-clm-tags #gjs-clm-new,.gjs-no-app{background-color:transparent;border:none;color:inherit}.gjs-no-app{height:10px}.gjs-test::btn{color:'#fff'}.opac50,.gjs-clm-tags #gjs-clm-close{opacity:.5;filter:alpha(opacity=50)}.gjs-checker-bg,.gjs-field-colorp-c,.checker-bg,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box{background-image:url("data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAIAAADZF8uwAAAAGUlEQVQYV2M4gwH+YwCGIasIUwhT25BVBADtzYNYrHvv4gAAAABJRU5ErkJggg==")}.gjs-no-user-select,.gjs-grabbing,.gjs-grabbing *,.gjs-layer-name,.gjs-rte-toolbar{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.gjs-no-pointer-events,.gjs-resizer-c,.gjs-margin-v-el,.gjs-padding-v-el,.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el{pointer-events:none}.gjs-bdrag{pointer-events:none !important;position:absolute !important;z-index:10 !important;width:auto}.gjs-drag-helper{background-color:#3b97e3 !important;pointer-events:none !important;position:absolute !important;z-index:10 !important;transform:scale(0.3) !important;transform-origin:top left !important;-webkit-transform-origin:top left !important;margin:15px !important;transition:none !important;outline:none !important}.gjs-grabbing,.gjs-grabbing *{cursor:grabbing !important;cursor:-webkit-grabbing !important}.gjs-grabbing{overflow:hidden}.gjs-off-prv{position:relative;z-index:10;padding:5px;cursor:pointer}.gjs-editor-cont ::-webkit-scrollbar-track{background:rgba(0,0,0,0.1)}.gjs-editor-cont ::-webkit-scrollbar-thumb{background-color:rgba(255,255,255,0.2)}.gjs-editor-cont ::-webkit-scrollbar{width:8px}.clear{clear:both}.no-select,.gjs-com-no-select,.gjs-com-no-select img,.gjs-category-title,.gjs-sm-sector .gjs-sm-title,.gjs-clm-tags .gjs-sm-title,.gjs-block-category .gjs-title,.gjs-layer-title,.gjs-clm-tags #gjs-clm-close{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none}.gjs-editor{font-family:Helvetica,sans-serif;font-size:.75rem;position:relative;box-sizing:border-box;height:100%}.gjs-freezed,.gjs-freezed{opacity:.5;filter:alpha(opacity=50);pointer-events:none}.gjs-traits-label{border-bottom:1px solid rgba(0,0,0,0.2);font-weight:lighter;margin-bottom:5px;padding:10px;text-align:left}.gjs-trt-header{font-weight:lighter;padding:10px}.gjs-trt-trait{display:flex;justify-content:start;padding:5px 10px;font-weight:lighter}.gjs-trt-traits{font-size:.75rem}.gjs-trt-trait .gjs-label{width:30%;text-align:left;text-overflow:ellipsis;overflow:hidden}.gjs-trt-trait .gjs-field{width:70%}.gjs-cv-canvas{background-color:rgba(0,0,0,0.15);box-sizing:border-box;width:85%;height:calc(100% - 40px);bottom:0;overflow:hidden;z-index:1;position:absolute;left:0;top:40px}.gjs-cv-canvas .gjs-ghost{display:none;pointer-events:none;background-color:#5b5b5b;border:2px dashed #ccc;position:absolute;z-index:10;opacity:.55;filter:alpha(opacity=55)}.gjs-cv-canvas .gjs-highlighter,.gjs-cv-canvas .gjs-highlighter-sel{position:absolute;outline:1px solid #3b97e3;outline-offset:-1px;pointer-events:none}.gjs-cv-canvas .gjs-highlighter-warning{outline:3px solid #ffca6f}.gjs-cv-canvas .gjs-highlighter-sel{outline:3px solid #3b97e3}.gjs-cv-canvas #gjs-tools{width:100%;position:absolute;top:0;left:0;outline:none}.gjs-cv-canvas>div:first-child{background-color:#fff;position:relative;height:100%;overflow:auto;width:100%}.gjs-cv-canvas *{box-sizing:border-box}.gjs-frame{outline:medium none;height:100%;width:100%;border:none;margin:auto;display:block;transition:width 0.35s ease,height 0.35s ease;position:absolute;top:0;bottom:0;left:0;right:0}.gjs-toolbar{position:absolute;background-color:#3b97e3;color:white;z-index:10;top:0;left:0}.gjs-toolbar-item{padding:5px 7px;font-size:0.8rem;cursor:pointer;width:26px;vertical-align:middle;display:inline-block}.gjs-toolbar-item svg{fill:currentColor;vertical-align:middle}.gjs-resizer-c{position:absolute;left:0;top:0;width:100%;height:100%;z-index:9}.gjs-margin-v-el,.gjs-padding-v-el,.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el{opacity:.1;filter:alpha(opacity=10);position:absolute;background-color:yellow}.gjs-fixedmargin-v-el,.gjs-fixedpadding-v-el{opacity:.2;filter:alpha(opacity=20)}.gjs-padding-v-el,.gjs-fixedpadding-v-el{background-color:navy}.gjs-resizer-h{pointer-events:all;position:absolute;border:3px solid #3b97e3;width:10px;height:10px;background-color:#fff;margin:-5px}.gjs-resizer-h-tl{top:0;left:0;cursor:nwse-resize}.gjs-resizer-h-tr{top:0;right:0;cursor:nesw-resize}.gjs-resizer-h-tc{top:0;margin:-5px auto;left:0;right:0;cursor:ns-resize}.gjs-resizer-h-cl{left:0;margin:auto -5px;top:0;bottom:0;cursor:ew-resize}.gjs-resizer-h-cr{margin:auto -5px;top:0;bottom:0;right:0;cursor:ew-resize}.gjs-resizer-h-bl{bottom:0;left:0;cursor:nesw-resize}.gjs-resizer-h-bc{bottom:0;margin:-5px auto;left:0;right:0;cursor:ns-resize}.gjs-resizer-h-br{bottom:0;right:0;cursor:nwse-resize}.gjs-pn-panel .gjs-resizer-h{background-color:rgba(0,0,0,0.2);border:none;opacity:0;transition:opacity 0.25s}.gjs-pn-panel .gjs-resizer-h:hover{opacity:1}.gjs-pn-panel .gjs-resizer-h-tc,.gjs-pn-panel .gjs-resizer-h-bc{margin:0 auto;width:100%}.gjs-pn-panel .gjs-resizer-h-cr,.gjs-pn-panel .gjs-resizer-h-cl{margin:auto 0;height:100%}.gjs-resizing .gjs-highlighter,.gjs-resizing .gjs-badge{display:none !important}.gjs-resizing-tl *{cursor:nwse-resize !important}.gjs-resizing-tr *{cursor:nesw-resize !important}.gjs-resizing-tc *{cursor:ns-resize !important}.gjs-resizing-cl *{cursor:ew-resize !important}.gjs-resizing-cr *{cursor:ew-resize !important}.gjs-resizing-bl *{cursor:nesw-resize !important}.gjs-resizing-bc *{cursor:ns-resize !important}.gjs-resizing-br *{cursor:nwse-resize !important}.btn-cl,.gjs-mdl-btn-close,.gjs-am-close{opacity:.3;filter:alpha(opacity=30);font-size:25px;cursor:pointer}.btn-cl:hover,.gjs-mdl-btn-close:hover,.gjs-am-close:hover{opacity:.7;filter:alpha(opacity=70)}.no-dots,.ui-resizable-handle{border:none !important;margin:0 !important;outline:none !important}.gjs-com-dashed *{outline:1px dashed #888;outline-offset:-2px;box-sizing:border-box}.gjs-cv-canvas .gjs-comp-selected{outline:3px solid #3b97e3 !important}*.gjs-com-hover,div.gjs-com-hover{outline:1px solid #3b97e3}*.gjs-com-hover-delete,div.gjs-com-hover-delete{outline:2px solid #dd3636;opacity:.5;filter:alpha(opacity=50)}*.gjs-com-hover-move,div.gjs-com-hover-move{outline:3px solid #ffca6f}.gjs-com-badge,.gjs-com-badge-red,.gjs-badge{pointer-events:none;background-color:#3b97e3;color:#fff;padding:2px 5px;position:absolute;z-index:1;font-size:12px;outline:none;display:none}.gjs-com-badge-red{background-color:#dd3636}.gjs-badge-warning{background-color:#ffca6f}.gjs-placeholder,.gjs-com-placeholder,.gjs-placeholder{position:absolute;z-index:10;pointer-events:none;display:none}.gjs-placeholder,.gjs-placeholder{border-style:solid !important;border-color:#62c462;outline:none;box-sizing:border-box;transition:top .2s,left .2s,width .2s,height .2s}.gjs-placeholder-int,.gjs-com-placeholder-int,.gjs-placeholder-int{background-color:#62c462;box-shadow:0 0 3px rgba(0,0,0,0.2);height:100%;width:100%;pointer-events:none;padding:1.5px;outline:none}.gjs-pn-panel{display:inline-block;position:absolute;box-sizing:border-box;text-align:center;padding:5px;z-index:3}.gjs-pn-panel .icon-undo,.gjs-pn-panel .icon-redo{font-size:20px;height:30px;width:25px}.gjs-pn-commands{width:85%;left:0;top:0;box-shadow:0 0 5px rgba(0,0,0,0.2)}.gjs-pn-options{right:15%;top:0}.gjs-pn-views{border-bottom:2px solid rgba(0,0,0,0.2);right:0;width:15%;z-index:4}.gjs-pn-views-container{height:100%;padding:42px 0 0;right:0;width:15%;overflow:auto;box-shadow:0 0 5px rgba(0,0,0,0.2)}.gjs-pn-buttons{align-items:center;display:flex;justify-content:space-between}.gjs-pn-btn{box-sizing:border-box;min-height:30px;min-width:30px;line-height:21px;background-color:transparent;border:none;font-size:18px;margin-right:5px;border-radius:2px;padding:4px;position:relative;cursor:pointer}.gjs-pn-btn.gjs-pn-active{background-color:rgba(0,0,0,0.15);box-shadow:0 0 3px rgba(0,0,0,0.25) inset}.gjs-pn-btn svg{fill:currentColor}.gjs-comp-image-placeholder{display:block;background-color:#f5f5f5;color:#777;height:50px;width:50px;line-height:50px;outline:3px solid #ffca6f;outline-offset:-3px;text-align:center;font-size:16.66667px;cursor:pointer}.gjs-comp-image-placeholder.fa-picture-o::after{content:"\f03e"}.gjs-label{line-height:18px}.gjs-fields{display:flex}.gjs-select{padding:0;width:100%}.gjs-select select{padding-right:10px}.gjs-select:-moz-focusring,.gjs-select select:-moz-focusring{color:transparent;text-shadow:0 0 0 rgba(255,255,255,0.7)}.gjs-input:focus,.gjs-button:focus,.gjs-btn-prim:focus,.gjs-select:focus,.gjs-select select:focus{outline:none}.gjs-field input,.gjs-field select,.gjs-field textarea{-webkit-appearance:none;-moz-appearance:none;appearance:none;color:inherit;border:none;background-color:transparent;box-sizing:border-box;width:100%;position:relative;padding:5px;z-index:1}.gjs-field input:focus,.gjs-field select:focus,.gjs-field textarea:focus{outline:none}.gjs-field-range{flex:9 1 auto}.gjs-field-integer input{padding-right:30px}.gjs-select option,.gjs-clm-select option,.gjs-sm-select option,.gjs-fields option,.gjs-sm-unit option{background-color:#444;color:#ddd}.gjs-field{background-color:rgba(0,0,0,0.2);border:none;box-shadow:none;border-radius:2px;box-sizing:border-box;padding:0;position:relative}.gjs-field textarea{resize:vertical}.gjs-field .gjs-sel-arrow{height:100%;width:9px;position:absolute;right:0;top:0;z-index:0}.gjs-field .gjs-d-s-arrow{bottom:0;top:0;margin:auto;right:5px;border-top:4px solid rgba(255,255,255,0.7);position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;cursor:pointer}.gjs-field-arrows{position:absolute;cursor:ns-resize;margin:auto;height:20px;width:9px;z-index:10;bottom:0;right:3px;top:0}.gjs-field-color,.gjs-field-radio{width:100%}.gjs-field-color input{padding-right:22px;box-sizing:border-box}.gjs-field-colorp{border-left:1px solid rgba(0,0,0,0.2);box-sizing:border-box;height:100%;padding:2px;position:absolute;right:0;top:0;width:22px;z-index:10}.gjs-field-colorp .gjs-checker-bg,.gjs-field-colorp .gjs-field-colorp-c{height:100%;width:100%;border-radius:1px}.gjs-field-colorp-c{height:100%;position:relative;width:100%}.gjs-field-color-picker{background-color:#ddd;cursor:pointer;height:100%;width:100%;box-shadow:0 0 1px rgba(0,0,0,0.2);border-radius:1px;position:absolute;top:0}.gjs-field-checkbox{padding:0;width:auto !important}.gjs-field-checkbox input{display:none}.gjs-field-checkbox input:checked+.gjs-chk-icon{border-color:rgba(255,255,255,0.5);border-width:0 2px 2px 0;border-style:solid}.gjs-radio-item{flex:1 1 auto;text-align:center;border-left:1px solid rgba(0,0,0,0.2)}.gjs-radio-item:first-child{border:none}.gjs-radio-item:hover{background:rgba(0,0,0,0.2)}.gjs-radio-item input{display:none}.gjs-radio-item input:checked+.gjs-radio-item-label{background-color:rgba(255,255,255,0.2)}.gjs-radio-items{display:flex}.gjs-radio-item-label{cursor:pointer;display:block;padding:5px}.gjs-field-units{position:absolute;margin:auto;right:10px;bottom:0;top:0}.gjs-field-unit{position:absolute;right:10px;top:3px;font-size:10px;color:rgba(255,255,255,0.7);cursor:pointer}.gjs-field-arrow-u,.gjs-field-arrow-d{position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;border-top:4px solid rgba(255,255,255,0.7);bottom:4px;cursor:pointer}.gjs-field-arrow-u{border-bottom:4px solid rgba(255,255,255,0.7);border-top:none;top:4px}.gjs-field-select{padding:0}.gjs-field-range{background-color:transparent;border:none;box-shadow:none;padding:0}.gjs-field-range input{margin:0;height:100%}.gjs-field-range input:focus{outline:none}.gjs-field-range input::-webkit-slider-thumb{-webkit-appearance:none;margin-top:-4px;height:10px;width:10px;border:1px solid rgba(0,0,0,0.2);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-moz-range-thumb{height:10px;width:10px;border:1px solid rgba(0,0,0,0.2);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-ms-thumb{height:10px;width:10px;border:1px solid rgba(0,0,0,0.2);border-radius:100%;background-color:#ddd;cursor:pointer}.gjs-field-range input::-moz-range-track{background-color:rgba(0,0,0,0.2);border-radius:1px;margin-top:3px;height:3px}.gjs-field-range input::-webkit-slider-runnable-track{background-color:rgba(0,0,0,0.2);border-radius:1px;margin-top:3px;height:3px}.gjs-field-range input::-ms-track{background-color:rgba(0,0,0,0.2);border-radius:1px;margin-top:3px;height:3px}.gjs-btn-prim{color:inherit;background-color:rgba(255,255,255,0.1);border-radius:2px;padding:3px 6px;padding:5px;cursor:pointer;border:none}.gjs-btn-prim:active{background-color:rgba(255,255,255,0.1)}.gjs-chk-icon{-ms-transform:rotate(45deg);-webkit-transform:rotate(45deg);-moz-transform:rotate(45deg);transform:rotate(45deg);box-sizing:border-box;display:block;height:14px;margin:0 5px;width:6px;cursor:pointer}.gjs-add-trasp{background:none;border:none;color:#ddd;cursor:pointer;font-size:1em;border-radius:2px;opacity:.75;filter:alpha(opacity=75)}.gjs-add-trasp:hover{opacity:1;filter:alpha(opacity=100)}.gjs-add-trasp:active{background-color:rgba(0,0,0,0.2)}.gjs-devices-c{display:flex;align-items:center;padding:3px}.gjs-devices-c .gjs-device-label{flex-grow:2;text-align:left;margin-right:10px}.gjs-devices-c .gjs-select{flex-grow:20}.gjs-devices-c .gjs-add-trasp{flex-grow:1;margin-left:5px}.gjs-category-open,.gjs-sm-sector.gjs-sm-open,.gjs-sm-open.gjs-clm-tags,.gjs-block-category.gjs-open{border-bottom:1px solid rgba(0,0,0,0.25)}.gjs-category-title,.gjs-sm-sector .gjs-sm-title,.gjs-clm-tags .gjs-sm-title,.gjs-block-category .gjs-title,.gjs-layer-title{font-weight:lighter;background-color:rgba(0,0,0,0.1);letter-spacing:1px;padding:9px 10px 9px 20px;border-bottom:1px solid rgba(0,0,0,0.25);text-align:left;position:relative;cursor:pointer}.gjs-sm-clear{line-height:0;cursor:pointer}.gjs-sm-header{font-weight:lighter;padding:10px}.gjs-sm-properties{font-size:.75rem;padding:10px 5px;display:flex;flex-wrap:wrap;align-items:flex-end;box-sizing:border-box;width:100%}.gjs-sm-label{margin:5px 5px 3px 0}.gjs-sm-close-btn,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close{display:block;font-size:23px;position:absolute;cursor:pointer;right:5px;top:0;opacity:.2;filter:alpha(opacity=20)}.gjs-sm-close-btn:hover,.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close:hover,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close:hover{opacity:.7;filter:alpha(opacity=70)}.gjs-sm-sector,.gjs-clm-tags{clear:both;font-weight:lighter;text-align:left}.gjs-sm-sector #gjs-sm-caret,.gjs-clm-tags #gjs-sm-caret{padding-right:5px;font-size:11px}.gjs-sm-sector .gjs-sm-field,.gjs-clm-tags .gjs-sm-field,.gjs-sm-sector .gjs-clm-field,.gjs-clm-tags .gjs-clm-field{width:100%;position:relative}.gjs-sm-sector .gjs-sm-field input,.gjs-clm-tags .gjs-sm-field input,.gjs-sm-sector .gjs-clm-field input,.gjs-clm-tags .gjs-clm-field input,.gjs-sm-sector .gjs-sm-field select,.gjs-clm-tags .gjs-sm-field select,.gjs-sm-sector .gjs-clm-field select,.gjs-clm-tags .gjs-clm-field select{background-color:transparent;color:rgba(255,255,255,0.7);border:none;width:100%}.gjs-sm-sector .gjs-sm-field input,.gjs-clm-tags .gjs-sm-field input,.gjs-sm-sector .gjs-clm-field input,.gjs-clm-tags .gjs-clm-field input{box-sizing:border-box}.gjs-sm-sector .gjs-sm-field select,.gjs-clm-tags .gjs-sm-field select,.gjs-sm-sector .gjs-clm-field select,.gjs-clm-tags .gjs-clm-field select{position:relative;z-index:1;-webkit-appearance:none;-moz-appearance:none;appearance:none}.gjs-sm-sector .gjs-sm-field select::-ms-expand,.gjs-clm-tags .gjs-sm-field select::-ms-expand,.gjs-sm-sector .gjs-clm-field select::-ms-expand,.gjs-clm-tags .gjs-clm-field select::-ms-expand{display:none}.gjs-sm-sector .gjs-sm-field select:-moz-focusring,.gjs-clm-tags .gjs-sm-field select:-moz-focusring,.gjs-sm-sector .gjs-clm-field select:-moz-focusring,.gjs-clm-tags .gjs-clm-field select:-moz-focusring{color:transparent;text-shadow:0 0 0 rgba(255,255,255,0.7)}.gjs-sm-sector .gjs-sm-field input:focus,.gjs-clm-tags .gjs-sm-field input:focus,.gjs-sm-sector .gjs-clm-field input:focus,.gjs-clm-tags .gjs-clm-field input:focus,.gjs-sm-sector .gjs-sm-field select:focus,.gjs-clm-tags .gjs-sm-field select:focus,.gjs-sm-sector .gjs-clm-field select:focus,.gjs-clm-tags .gjs-clm-field select:focus{outline:none}.gjs-sm-sector .gjs-sm-field .gjs-sm-unit,.gjs-clm-tags .gjs-sm-field .gjs-sm-unit,.gjs-sm-sector .gjs-clm-field .gjs-sm-unit,.gjs-clm-tags .gjs-clm-field .gjs-sm-unit{position:absolute;right:10px;top:3px;font-size:10px;color:rgba(255,255,255,0.7);cursor:pointer}.gjs-sm-sector .gjs-sm-field .gjs-clm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-sel-arrow,.gjs-clm-tags .gjs-clm-field .gjs-clm-sel-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-int-arrows,.gjs-clm-tags .gjs-sm-field .gjs-sm-int-arrows,.gjs-sm-sector .gjs-clm-field .gjs-sm-int-arrows,.gjs-clm-tags .gjs-clm-field .gjs-sm-int-arrows,.gjs-sm-sector .gjs-sm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-sel-arrow{height:100%;width:9px;position:absolute;right:0;top:0;cursor:ns-resize}.gjs-sm-sector .gjs-sm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-sel-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-sel-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-sel-arrow{cursor:pointer}.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-u-arrow{position:absolute;height:0;width:0;border-left:3px solid transparent;border-right:4px solid transparent;cursor:pointer}.gjs-sm-sector .gjs-sm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-u-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-u-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-u-arrow{border-bottom:4px solid rgba(255,255,255,0.7);top:4px}.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow{border-top:4px solid rgba(255,255,255,0.7);bottom:4px}.gjs-sm-sector .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-clm-d-s-arrow,.gjs-sm-sector .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-sm-field .gjs-sm-d-s-arrow,.gjs-sm-sector .gjs-clm-field .gjs-sm-d-s-arrow,.gjs-clm-tags .gjs-clm-field .gjs-sm-d-s-arrow{bottom:7px}.gjs-sm-sector .gjs-sm-field.gjs-sm-color,.gjs-clm-tags .gjs-sm-field.gjs-sm-color,.gjs-sm-sector .gjs-sm-color.gjs-clm-field,.gjs-clm-tags .gjs-sm-color.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-input,.gjs-clm-tags .gjs-sm-field.gjs-sm-input,.gjs-sm-sector .gjs-sm-input.gjs-clm-field,.gjs-clm-tags .gjs-sm-input.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-integer,.gjs-clm-tags .gjs-sm-field.gjs-sm-integer,.gjs-sm-sector .gjs-sm-integer.gjs-clm-field,.gjs-clm-tags .gjs-sm-integer.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-list,.gjs-clm-tags .gjs-sm-field.gjs-sm-list,.gjs-sm-sector .gjs-sm-list.gjs-clm-field,.gjs-clm-tags .gjs-sm-list.gjs-clm-field,.gjs-sm-sector .gjs-sm-field.gjs-sm-select,.gjs-clm-tags .gjs-sm-field.gjs-sm-select,.gjs-sm-sector .gjs-sm-select.gjs-clm-field,.gjs-clm-tags .gjs-sm-select.gjs-clm-field,.gjs-sm-sector .gjs-clm-select,.gjs-clm-tags .gjs-clm-select{background-color:rgba(0,0,0,0.2);border:1px solid rgba(0,0,0,0.1);box-shadow:1px 1px 0 rgba(255,255,255,0.1);color:rgba(255,255,255,0.7);border-radius:2px;box-sizing:border-box;padding:0 5px}.gjs-sm-sector .gjs-sm-field.gjs-sm-composite,.gjs-clm-tags .gjs-sm-field.gjs-sm-composite,.gjs-sm-sector .gjs-sm-composite.gjs-clm-field,.gjs-clm-tags .gjs-sm-composite.gjs-clm-field{border-radius:2px}.gjs-sm-sector .gjs-sm-field.gjs-sm-select,.gjs-clm-tags .gjs-sm-field.gjs-sm-select,.gjs-sm-sector .gjs-sm-select.gjs-clm-field,.gjs-clm-tags .gjs-sm-select.gjs-clm-field,.gjs-sm-sector .gjs-clm-select,.gjs-clm-tags .gjs-clm-select{padding:0}.gjs-sm-sector .gjs-sm-field.gjs-sm-select select,.gjs-clm-tags .gjs-sm-field.gjs-sm-select select,.gjs-sm-sector .gjs-sm-select.gjs-clm-field select,.gjs-clm-tags .gjs-sm-select.gjs-clm-field select,.gjs-sm-sector .gjs-clm-select select,.gjs-clm-tags .gjs-clm-select select{height:20px}.gjs-sm-sector .gjs-sm-field.gjs-sm-select option,.gjs-clm-tags .gjs-sm-field.gjs-sm-select option,.gjs-sm-sector .gjs-sm-select.gjs-clm-field option,.gjs-clm-tags .gjs-sm-select.gjs-clm-field option,.gjs-sm-sector .gjs-clm-select option,.gjs-clm-tags .gjs-clm-select option{padding:3px 0}.gjs-sm-sector .gjs-sm-field.gjs-sm-composite,.gjs-clm-tags .gjs-sm-field.gjs-sm-composite,.gjs-sm-sector .gjs-sm-composite.gjs-clm-field,.gjs-clm-tags .gjs-sm-composite.gjs-clm-field{background-color:rgba(0,0,0,0.1);border:1px solid rgba(0,0,0,0.25)}.gjs-sm-sector .gjs-sm-field.gjs-sm-list,.gjs-clm-tags .gjs-sm-field.gjs-sm-list,.gjs-sm-sector .gjs-sm-list.gjs-clm-field,.gjs-clm-tags .gjs-sm-list.gjs-clm-field{width:auto;padding:0;overflow:hidden;float:left}.gjs-sm-sector .gjs-sm-field.gjs-sm-list input,.gjs-clm-tags .gjs-sm-field.gjs-sm-list input,.gjs-sm-sector .gjs-sm-list.gjs-clm-field input,.gjs-clm-tags .gjs-sm-list.gjs-clm-field input{display:none}.gjs-sm-sector .gjs-sm-field.gjs-sm-list label,.gjs-clm-tags .gjs-sm-field.gjs-sm-list label,.gjs-sm-sector .gjs-sm-list.gjs-clm-field label,.gjs-clm-tags .gjs-sm-list.gjs-clm-field label{cursor:pointer;padding:5px;display:block}.gjs-sm-sector .gjs-sm-field.gjs-sm-list .gjs-sm-radio:checked+label,.gjs-clm-tags .gjs-sm-field.gjs-sm-list .gjs-sm-radio:checked+label,.gjs-sm-sector .gjs-sm-list.gjs-clm-field .gjs-sm-radio:checked+label,.gjs-clm-tags .gjs-sm-list.gjs-clm-field .gjs-sm-radio:checked+label{background-color:rgba(255,255,255,0.2)}.gjs-sm-sector .gjs-sm-field.gjs-sm-list .gjs-sm-icon,.gjs-clm-tags .gjs-sm-field.gjs-sm-list .gjs-sm-icon,.gjs-sm-sector .gjs-sm-list.gjs-clm-field .gjs-sm-icon,.gjs-clm-tags .gjs-sm-list.gjs-clm-field .gjs-sm-icon{background-repeat:no-repeat;background-position:center;text-shadow:none;line-height:normal}.gjs-sm-sector .gjs-sm-field.gjs-sm-integer select,.gjs-clm-tags .gjs-sm-field.gjs-sm-integer select,.gjs-sm-sector .gjs-sm-integer.gjs-clm-field select,.gjs-clm-tags .gjs-sm-integer.gjs-clm-field select{width:auto;padding:0}.gjs-sm-sector .gjs-sm-list .gjs-sm-el,.gjs-clm-tags .gjs-sm-list .gjs-sm-el{float:left;border-left:1px solid rgba(0,0,0,0.2)}.gjs-sm-sector .gjs-sm-list .gjs-sm-el:first-child,.gjs-clm-tags .gjs-sm-list .gjs-sm-el:first-child{border:none}.gjs-sm-sector .gjs-sm-list .gjs-sm-el:hover,.gjs-clm-tags .gjs-sm-list .gjs-sm-el:hover{background:rgba(0,0,0,0.2)}.gjs-sm-sector .gjs-sm-slider .gjs-field-integer,.gjs-clm-tags .gjs-sm-slider .gjs-field-integer{flex:1 1 65px}.gjs-sm-sector .gjs-sm-property,.gjs-clm-tags .gjs-sm-property{box-sizing:border-box;float:left;width:50%;margin-bottom:5px;padding:0 5px}.gjs-sm-sector .gjs-sm-property.gjs-sm-composite,.gjs-clm-tags .gjs-sm-property.gjs-sm-composite,.gjs-sm-sector .gjs-sm-property.gjs-sm-file,.gjs-clm-tags .gjs-sm-property.gjs-sm-file,.gjs-sm-sector .gjs-sm-property.gjs-sm-list,.gjs-clm-tags .gjs-sm-property.gjs-sm-list,.gjs-sm-sector .gjs-sm-property.gjs-sm-radio,.gjs-clm-tags .gjs-sm-property.gjs-sm-radio,.gjs-sm-sector .gjs-sm-property.gjs-sm-stack,.gjs-clm-tags .gjs-sm-property.gjs-sm-stack,.gjs-sm-sector .gjs-sm-property.gjs-sm-slider,.gjs-clm-tags .gjs-sm-property.gjs-sm-slider,.gjs-sm-sector .gjs-sm-property.gjs-sm-color,.gjs-clm-tags .gjs-sm-property.gjs-sm-color{width:100%}.gjs-sm-sector .gjs-sm-property .gjs-sm-btn,.gjs-clm-tags .gjs-sm-property .gjs-sm-btn{background-color:rgba(33,33,33,0.2);border-radius:2px;box-shadow:1px 1px 0 rgba(5,5,5,0.2),1px 1px 0 rgba(43,43,43,0.2) inset;padding:5px;position:relative;text-align:center;height:auto;width:100%;cursor:pointer;color:#ddd;box-sizing:border-box;text-shadow:-1px -1px 0 rgba(0,0,0,0.2);border:none;opacity:.85;filter:alpha(opacity=85)}.gjs-sm-sector .gjs-sm-property .gjs-sm-btn-c,.gjs-clm-tags .gjs-sm-property .gjs-sm-btn-c{box-sizing:border-box;float:left;width:100%}.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box{background-color:rgba(255,255,255,0.05);border-radius:2px;margin-top:5px;position:relative;overflow:hidden}.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box.gjs-sm-show,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box.gjs-sm-show{border:1px solid rgba(252,252,252,0.05);padding:3px 20px}.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-box #gjs-sm-close{top:-5px;display:block}.gjs-sm-sector .gjs-sm-property.gjs-sm-file .gjs-sm-show #gjs-sm-preview-file,.gjs-clm-tags .gjs-sm-property.gjs-sm-file .gjs-sm-show #gjs-sm-preview-file{height:50px}.gjs-sm-sector .gjs-sm-property.gjs-sm-file #gjs-sm-preview-file,.gjs-clm-tags .gjs-sm-property.gjs-sm-file #gjs-sm-preview-file{background-size:auto 100%;background-repeat:no-repeat;background-position:center center}.gjs-sm-sector .gjs-sm-property .gjs-sm-layers,.gjs-clm-tags .gjs-sm-property .gjs-sm-layers{margin-top:5px;padding:1px 3px;min-height:30px}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer{background-color:rgba(255,255,255,0.055);border-radius:2px;margin:2px 0;padding:7px;position:relative;cursor:pointer}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box{height:15px;position:absolute;right:27px;top:6px;width:15px}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-preview,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-preview,.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-preview-box,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-preview-box{border-radius:2px}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer{display:block;font-size:23px;position:absolute;cursor:pointer;right:5px;top:0;opacity:.5;filter:alpha(opacity=50)}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer:hover,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer #gjs-sm-close-layer:hover{opacity:.8;filter:alpha(opacity=80)}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box #gjs-sm-preview,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer>#gjs-sm-preview-box #gjs-sm-preview{background-color:white;height:100%;width:100%;background-size:cover !important}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer.gjs-sm-active,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer.gjs-sm-active{background-color:rgba(255,255,255,0.12)}.gjs-sm-sector .gjs-sm-property .gjs-sm-layer.gjs-sm-no-preview #gjs-sm-preview-box,.gjs-clm-tags .gjs-sm-property .gjs-sm-layer.gjs-sm-no-preview #gjs-sm-preview-box{display:none}.gjs-sm-sector #gjs-sm-text-shadow #gjs-sm-preview::after,.gjs-clm-tags #gjs-sm-text-shadow #gjs-sm-preview::after{color:#000;content:"T";font-weight:900;line-height:17px;padding:0 4px}.gjs-sm-sector .gjs-sm-stack .gjs-sm-properties,.gjs-clm-tags .gjs-sm-stack .gjs-sm-properties{padding:5px 0 0}.gjs-sm-sector .gjs-sm-stack #gjs-sm-add,.gjs-clm-tags .gjs-sm-stack #gjs-sm-add{background:none;border:none;cursor:pointer;outline:none;font-size:22px;line-height:10px;position:absolute;right:0;top:-17px;opacity:0.75}.gjs-sm-sector .gjs-sm-stack #gjs-sm-add:hover,.gjs-clm-tags .gjs-sm-stack #gjs-sm-add:hover{opacity:1;filter:alpha(opacity=100)}.gjs-sm-sector .gjs-sm-colorp-c,.gjs-clm-tags .gjs-sm-colorp-c{height:100%;width:20px;position:absolute;right:0;top:0;box-sizing:border-box;border-radius:2px;padding:2px}.gjs-sm-sector .gjs-sm-colorp-c .gjs-checker-bg,.gjs-clm-tags .gjs-sm-colorp-c .gjs-checker-bg,.gjs-sm-sector .gjs-sm-colorp-c .gjs-field-colorp-c,.gjs-clm-tags .gjs-sm-colorp-c .gjs-field-colorp-c{height:100%;width:100%;border-radius:1px}.gjs-sm-sector .gjs-sm-color-picker,.gjs-clm-tags .gjs-sm-color-picker{background-color:#ddd;cursor:pointer;height:16px;width:100%;margin-top:-16px;box-shadow:0 0 1px rgba(0,0,0,0.2);border-radius:1px}.gjs-sm-sector .gjs-sm-btn-upload #gjs-sm-upload,.gjs-clm-tags .gjs-sm-btn-upload #gjs-sm-upload{left:0;top:0;position:absolute;width:100%;opacity:0;cursor:pointer}.gjs-sm-sector .gjs-sm-btn-upload #gjs-sm-label,.gjs-clm-tags .gjs-sm-btn-upload #gjs-sm-label{padding:2px 0}.gjs-sm-layer>#gjs-sm-move{opacity:.7;filter:alpha(opacity=70);cursor:move;font-size:12px;float:left;margin:0 5px 0 0}.gjs-sm-layer>#gjs-sm-move:hover{opacity:.9;filter:alpha(opacity=90)}.gjs-blocks-c{display:flex;flex-wrap:wrap;justify-content:flex-start}.gjs-block-categories{display:flex;flex-direction:column}.gjs-block-category{width:100%}.gjs-block-category .gjs-caret-icon{margin-right:5px}.gjs-block{-moz-user-select:none;-khtml-user-select:none;-webkit-user-select:none;-ms-user-select:none;-o-user-select:none;user-select:none;width:45%;min-width:45px;padding:1em;box-sizing:border-box;min-height:90px;cursor:all-scroll;font-size:11px;font-weight:lighter;text-align:center;display:flex;flex-direction:column;justify-content:space-between;border:1px solid rgba(0,0,0,0.2);border-radius:3px;margin:10px 2.5% 5px;box-shadow:0 1px 0 0 rgba(0,0,0,0.15);transition:all 0.2s ease 0s;transition-property:box-shadow, color}.gjs-block:hover{box-shadow:0 3px 4px 0 rgba(0,0,0,0.15)}.gjs-block svg{fill:currentColor}.gjs-block-svg{width:54px;fill:currentColor}.gjs-block-svg-path{fill:currentColor}.gjs-block.fa{font-size:2em;line-height:2em;padding:11px}.gjs-block-label{line-height:normal;font-size:0.65rem;font-weight:normal;font-family:Helvetica, sans-serif;overflow:hidden;text-overflow:ellipsis}.gjs-block.gjs-bdrag{width:auto;padding:0}.gjs-selected-parent{border:1px solid #ffca6f}.gjs-opac50{opacity:.5;filter:alpha(opacity=50)}.gjs-layer{font-weight:lighter;text-align:left;position:relative;background-color:rgba(0,0,0,0.1);font-size:.75rem}.gjs-layer-hidden{opacity:.55;filter:alpha(opacity=55)}.gjs-layer-count{position:absolute;right:27px;top:9px}.gjs-layer-vis{height:auto !important;width:auto !important;left:0;top:0;padding:7px 5px 7px 10px;position:absolute;cursor:pointer;z-index:1}.gjs-layer-caret{font-size:0.5rem;width:8px;padding:2px;cursor:pointer;position:absolute;left:-9px;top:6px;opacity:.7;filter:alpha(opacity=70)}.gjs-layer-caret:hover{opacity:1;filter:alpha(opacity=100)}.gjs-layer-title{padding:3px 10px 5px 30px;display:flex;align-items:center}.gjs-layer-title-inn{position:relative}.gjs-layer-name{padding:5px;display:inline-block;box-sizing:content-box}.gjs-layer>.gjs-layer-children{display:none}.gjs-layer.open>.gjs-layer-children{display:block}.gjs-layer-no-chld>.gjs-layer-title-inn>.gjs-layer-caret{display:none}.gjs-layer-move{padding:7px 10px 7px 5px;position:absolute;font-size:12px;cursor:move;right:0;top:0}.gjs-layer.gjs-hovered .gjs-layer-title{background-color:rgba(255,255,255,0.015)}.gjs-layer.gjs-selected .gjs-layer-title{background-color:rgba(255,255,255,0.1)}.gjs-layers{position:relative;height:100%}.gjs-layers #gjs-placeholder{width:100%;position:absolute}.gjs-layers #gjs-placeholder #gjs-plh-int{height:100%;padding:1px}.gjs-layers #gjs-placeholder #gjs-plh-int.gjs-insert{background-color:#62c462}.gjs-clm-tags{font-size:.75rem;padding:10px 5px}.gjs-clm-tags #gjs-clm-label,.gjs-clm-tags #gjs-clm-sel{padding:7px 0;float:left}.gjs-clm-tags #gjs-clm-sel{font-style:italic;margin-left:5px}.gjs-clm-tags #gjs-clm-status-c{float:right}.gjs-clm-tags #gjs-clm-tags-field{clear:both;padding:5px;margin-bottom:5px}.gjs-clm-tags #gjs-clm-tags-c{display:inline-block;vertical-align:top}.gjs-clm-tags #gjs-clm-add-tag{background-color:rgba(255,255,255,0.15);border-radius:2px;padding:5px 6px;box-shadow:1px 1px 0 rgba(255,255,255,0.2) inset;border:1px solid rgba(0,0,0,0.15);cursor:pointer}.gjs-clm-tags #gjs-clm-new{color:#ddd;padding:5px 6px;display:none}.gjs-clm-tags .gjs-clm-tag{display:inline-block;border-radius:3px;margin:0 3px 3px 0;padding:5px;cursor:default}.gjs-clm-tags #gjs-clm-close{font-size:20px;line-height:0;cursor:pointer;color:rgba(255,255,255,0.9)}.gjs-clm-tags #gjs-clm-close:hover{opacity:.7;filter:alpha(opacity=70)}.gjs-clm-tags #gjs-clm-checkbox{color:rgba(255,255,255,0.9);vertical-align:middle;cursor:pointer;font-size:9px}.gjs-clm-tags #gjs-clm-tag-label{padding:0 3px;cursor:text}.gjs-mdl-container{font-family:Helvetica,sans-serif;overflow-y:auto;position:fixed;background-color:rgba(0,0,0,0.5);display:flex;top:0;left:0;right:0;bottom:0;z-index:100}.gjs-mdl-dialog{text-shadow:-1px -1px 0 rgba(0,0,0,0.05);animation:gjs-slide-down 0.215s;margin:auto;max-width:850px;width:90%;border-radius:3px;font-weight:lighter;position:relative;z-index:2}.gjs-mdl-title{font-size:1rem}.gjs-mdl-btn-close{position:absolute;right:15px;top:5px}.gjs-mdl-active .gjs-mdl-dialog{animation:gjs-mdl-slide-down 0.216s}.gjs-mdl-header,.gjs-mdl-content{padding:10px 15px;clear:both}.gjs-mdl-header{position:relative;border-bottom:1px solid rgba(0,0,0,0.2);padding:15px 15px 7px}.gjs-export-dl::after{content:"";clear:both;display:block;margin-bottom:10px}.gjs-dropzone{display:none;opacity:0;position:absolute;top:0;left:0;z-index:11;width:100%;height:100%;transition:opacity 0.25s;pointer-events:none}.gjs-dropzone-active .gjs-dropzone{display:block;opacity:1}.gjs-am-assets{height:290px;overflow:auto;clear:both;display:flex;flex-wrap:wrap;align-items:flex-start;align-content:flex-start}.gjs-am-assets-header{padding:5px}.gjs-am-add-asset .gjs-am-add-field{width:70%;float:left}.gjs-am-add-asset button{width:25%;float:right}.gjs-am-preview-cont{position:relative;height:70px;width:30%;background-color:#444;border-radius:2px;float:left;overflow:hidden}.gjs-am-preview{position:absolute;background-position:center center;background-size:cover;background-repeat:no-repeat;height:100%;width:100%;z-index:1}.gjs-am-preview-bg{opacity:.5;filter:alpha(opacity=50);position:absolute;height:100%;width:100%;z-index:0}.gjs-am-dimensions{opacity:.5;filter:alpha(opacity=50);font-size:10px}.gjs-am-meta{width:70%;float:left;font-size:12px;padding:5px 0 0 5px;box-sizing:border-box}.gjs-am-meta>div{margin-bottom:5px}.gjs-am-close{cursor:pointer;position:absolute;right:5px;top:0;display:none}.gjs-am-asset{border-bottom:1px solid rgba(0,0,0,0.2);padding:5px;cursor:pointer;position:relative;box-sizing:border-box;width:100%}.gjs-am-asset:hover .gjs-am-close{display:block}.gjs-am-highlight{background-color:rgba(255,255,255,0.1)}.gjs-am-assets-cont{background-color:rgba(0,0,0,0.1);border-radius:3px;box-sizing:border-box;padding:10px;width:45%;float:right;height:325px;overflow:hidden}.gjs-am-file-uploader{width:55%;float:left}.gjs-am-file-uploader>form{background-color:rgba(0,0,0,0.1);border:2px dashed;border-radius:3px;position:relative;text-align:center;margin-bottom:15px}.gjs-am-file-uploader>form.gjs-am-hover{border:2px solid #62c462;color:#75cb75}.gjs-am-file-uploader>form.gjs-am-disabled{border-color:red}.gjs-am-file-uploader>form #gjs-am-uploadFile{opacity:0;filter:alpha(opacity=0);padding:150px 10px;width:100%;box-sizing:border-box}.gjs-am-file-uploader #gjs-am-title{position:absolute;padding:150px 10px;width:100%}.gjs-cm-editor-c{float:left;box-sizing:border-box;width:50%}.gjs-cm-editor-c .CodeMirror{height:450px}.gjs-cm-editor{font-size:12px}.gjs-cm-editor#gjs-cm-htmlmixed{padding-right:10px;border-right:1px solid rgba(0,0,0,0.2)}.gjs-cm-editor#gjs-cm-htmlmixed #gjs-cm-title{color:#a97d44}.gjs-cm-editor#gjs-cm-css{padding-left:10px}.gjs-cm-editor#gjs-cm-css #gjs-cm-title{color:#ddca7e}.gjs-cm-editor #gjs-cm-title{background-color:rgba(0,0,0,0.2);font-size:12px;padding:5px 10px 3px;text-align:right}.gjs-rte-toolbar{border:1px solid rgba(0,0,0,0.2);position:absolute;border-radius:3px;z-index:10}.gjs-rte-actionbar{display:flex}.gjs-rte-action{display:flex;align-items:center;justify-content:center;padding:5px;min-width:25px;border-right:1px solid rgba(0,0,0,0.2);text-align:center;cursor:pointer;outline:none}.gjs-rte-action:last-child{border-right:none}.gjs-rte-action:hover{background-color:rgba(255,255,255,0.1)}.gjs-rte-active{background-color:rgba(0,0,0,0.2)}.gjs-editor-cont .sp-hue,.gjs-editor-cont .sp-slider{cursor:row-resize}.gjs-editor-cont .sp-color,.gjs-editor-cont .sp-dragger{cursor:crosshair}.gjs-editor-cont .sp-alpha-inner,.gjs-editor-cont .sp-alpha-handle{cursor:col-resize}.gjs-editor-cont .sp-hue{left:90%}.gjs-editor-cont .sp-color{right:15%}.gjs-editor-cont .sp-container{border:1px solid rgba(0,0,0,0.2);box-shadow:0 0 7px rgba(0,0,0,0.2);border-radius:3px}.gjs-editor-cont .sp-picker-container{border:none}.gjs-editor-cont .colpick_dark .colpick_color{outline:1px solid rgba(0,0,0,0.2)}.gjs-editor-cont .sp-cancel,.gjs-editor-cont .sp-cancel:hover{bottom:-8px;color:#777 !important;font-size:25px;left:0;position:absolute;text-decoration:none}.gjs-editor-cont .sp-alpha-handle{background-color:#ccc;border:1px solid #555;width:4px}.gjs-editor-cont .sp-color,.gjs-editor-cont .sp-hue{border:1px solid #333333}.gjs-editor-cont .sp-slider{background-color:#ccc;border:1px solid #555;height:3px;left:-4px;width:22px}.gjs-editor-cont .sp-dragger{background:transparent;box-shadow:0 0 0 1px #111}.gjs-editor-cont .sp-button-container{float:none;width:100%;position:relative;text-align:right}.gjs-editor-cont .sp-container button,.gjs-editor-cont .sp-container button:hover,.gjs-editor-cont .sp-container button:active{background:rgba(0,0,0,0.2);border-color:rgba(0,0,0,0.2);color:#ddd;text-shadow:none;box-shadow:none;padding:3px 5px}.gjs-editor-cont .sp-palette-container{border:none;float:none;margin:0;padding:5px 10px 0}.gjs-editor-cont .sp-palette .sp-thumb-el,.gjs-editor-cont .sp-palette .sp-thumb-el:hover{border:1px solid rgba(0,0,0,0.9)}.gjs-editor-cont .sp-palette .sp-thumb-el:hover,.gjs-editor-cont .sp-palette .sp-thumb-el.sp-thumb-active{border-color:rgba(0,0,0,0.9)}.gjs-hidden{display:none}@keyframes gjs-slide-down{0%{transform:translate(0, -3rem);opacity:0}100%{transform:translate(0, 0);opacity:1}}@keyframes gjs-slide-up{0%{transform:translate(0, 0);opacity:1}100%{transform:translate(0, -3rem);opacity:0}}.cm-s-hopscotch span.cm-error{color:#ffffff} diff --git a/obsolete/public/grapejs/dist/css/grapesjs-preset-newsletter.css b/obsolete/public/grapejs/dist/css/grapesjs-preset-newsletter.css index 13f90f64..9776fcc2 100644 --- a/obsolete/public/grapejs/dist/css/grapesjs-preset-newsletter.css +++ b/obsolete/public/grapejs/dist/css/grapesjs-preset-newsletter.css @@ -1,4 +1,5 @@ -/* #008f73 #4c9790 */ +/* Class names prefixes */ +/* Colors / Theme */ .gjs-clm-tags .gjs-sm-title, .gjs-sm-sector .gjs-sm-title { border-top: none; } @@ -42,8 +43,7 @@ .gjs-sm-sector .gjs-sm-composite.gjs-clm-field, .gjs-sm-sector .gjs-sm-field.gjs-sm-composite, .gjs-sm-sector .gjs-sm-stack #gjs-sm-add { - color: #a0aabf; - /* #a0aabf #d0d6e2 */ } + color: #a0aabf; } #gjs-rte-toolbar, .gjs-bg-main, diff --git a/obsolete/public/grapejs/dist/css/material.css b/obsolete/public/grapejs/dist/css/material.css index 1bc89d6b..91ed6cef 100644 --- a/obsolete/public/grapejs/dist/css/material.css +++ b/obsolete/public/grapejs/dist/css/material.css @@ -50,4 +50,4 @@ .cm-s-material .CodeMirror-matchingbracket { text-decoration: underline; color: white !important; -} \ No newline at end of file +} diff --git a/obsolete/public/grapejs/dist/css/toastr.min.css b/obsolete/public/grapejs/dist/css/toastr.min.css index 095b99ca..9b283103 100644 --- a/obsolete/public/grapejs/dist/css/toastr.min.css +++ b/obsolete/public/grapejs/dist/css/toastr.min.css @@ -3,4 +3,4 @@ * please go to https://cdnjs.com/libraries/toastr.js and pick a certain version you want to use, * make sure you copy the url from the website since the url may change between versions. * */ -.toast-title{font-weight:700}.toast-message{-ms-word-wrap:break-word;word-wrap:break-word}.toast-message a,.toast-message label{color:#FFF}.toast-message a:hover{color:#CCC;text-decoration:none}.toast-close-button{position:relative;right:-.3em;top:-.3em;float:right;font-size:20px;font-weight:700;color:#FFF;-webkit-text-shadow:0 1px 0 #fff;text-shadow:0 1px 0 #fff;opacity:.8;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=80);filter:alpha(opacity=80);line-height:1}.toast-close-button:focus,.toast-close-button:hover{color:#000;text-decoration:none;cursor:pointer;opacity:.4;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=40);filter:alpha(opacity=40)}.rtl .toast-close-button{left:-.3em;float:left;right:.3em}button.toast-close-button{padding:0;cursor:pointer;background:0 0;border:0;-webkit-appearance:none}.toast-top-center{top:0;right:0;width:100%}.toast-bottom-center{bottom:0;right:0;width:100%}.toast-top-full-width{top:0;right:0;width:100%}.toast-bottom-full-width{bottom:0;right:0;width:100%}.toast-top-left{top:12px;left:12px}.toast-top-right{top:12px;right:12px}.toast-bottom-right{right:12px;bottom:12px}.toast-bottom-left{bottom:12px;left:12px}#toast-container{position:fixed;z-index:999999;pointer-events:none}#toast-container *{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}#toast-container>div{position:relative;pointer-events:auto;overflow:hidden;margin:0 0 6px;padding:15px 15px 15px 50px;width:300px;-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-position:15px center;background-repeat:no-repeat;-moz-box-shadow:0 0 12px #999;-webkit-box-shadow:0 0 12px #999;box-shadow:0 0 12px #999;color:#FFF;opacity:.8;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=80);filter:alpha(opacity=80)}#toast-container>div.rtl{direction:rtl;padding:15px 50px 15px 15px;background-position:right 15px center}#toast-container>div:hover{-moz-box-shadow:0 0 12px #000;-webkit-box-shadow:0 0 12px #000;box-shadow:0 0 12px #000;opacity:1;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=100);filter:alpha(opacity=100);cursor:pointer}#toast-container>.toast-info{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=)!important}#toast-container>.toast-error{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII=)!important}#toast-container>.toast-success{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg==)!important}#toast-container>.toast-warning{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=)!important}#toast-container.toast-bottom-center>div,#toast-container.toast-top-center>div{width:300px;margin-left:auto;margin-right:auto}#toast-container.toast-bottom-full-width>div,#toast-container.toast-top-full-width>div{width:96%;margin-left:auto;margin-right:auto}.toast{background-color:#030303}.toast-success{background-color:#51A351}.toast-error{background-color:#BD362F}.toast-info{background-color:#2F96B4}.toast-warning{background-color:#F89406}.toast-progress{position:absolute;left:0;bottom:0;height:4px;background-color:#000;opacity:.4;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=40);filter:alpha(opacity=40)}@media all and (max-width:240px){#toast-container>div{padding:8px 8px 8px 50px;width:11em}#toast-container>div.rtl{padding:8px 50px 8px 8px}#toast-container .toast-close-button{right:-.2em;top:-.2em}#toast-container .rtl .toast-close-button{left:-.2em;right:.2em}}@media all and (min-width:241px) and (max-width:480px){#toast-container>div{padding:8px 8px 8px 50px;width:18em}#toast-container>div.rtl{padding:8px 50px 8px 8px}#toast-container .toast-close-button{right:-.2em;top:-.2em}#toast-container .rtl .toast-close-button{left:-.2em;right:.2em}}@media all and (min-width:481px) and (max-width:768px){#toast-container>div{padding:15px 15px 15px 50px;width:25em}#toast-container>div.rtl{padding:15px 50px 15px 15px}} \ No newline at end of file +.toast-title{font-weight:700}.toast-message{-ms-word-wrap:break-word;word-wrap:break-word}.toast-message a,.toast-message label{color:#FFF}.toast-message a:hover{color:#CCC;text-decoration:none}.toast-close-button{position:relative;right:-.3em;top:-.3em;float:right;font-size:20px;font-weight:700;color:#FFF;-webkit-text-shadow:0 1px 0 #fff;text-shadow:0 1px 0 #fff;opacity:.8;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=80);filter:alpha(opacity=80);line-height:1}.toast-close-button:focus,.toast-close-button:hover{color:#000;text-decoration:none;cursor:pointer;opacity:.4;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=40);filter:alpha(opacity=40)}.rtl .toast-close-button{left:-.3em;float:left;right:.3em}button.toast-close-button{padding:0;cursor:pointer;background:0 0;border:0;-webkit-appearance:none}.toast-top-center{top:0;right:0;width:100%}.toast-bottom-center{bottom:0;right:0;width:100%}.toast-top-full-width{top:0;right:0;width:100%}.toast-bottom-full-width{bottom:0;right:0;width:100%}.toast-top-left{top:12px;left:12px}.toast-top-right{top:12px;right:12px}.toast-bottom-right{right:12px;bottom:12px}.toast-bottom-left{bottom:12px;left:12px}#toast-container{position:fixed;z-index:999999;pointer-events:none}#toast-container *{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}#toast-container>div{position:relative;pointer-events:auto;overflow:hidden;margin:0 0 6px;padding:15px 15px 15px 50px;width:300px;-moz-border-radius:3px;-webkit-border-radius:3px;border-radius:3px;background-position:15px center;background-repeat:no-repeat;-moz-box-shadow:0 0 12px #999;-webkit-box-shadow:0 0 12px #999;box-shadow:0 0 12px #999;color:#FFF;opacity:.8;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=80);filter:alpha(opacity=80)}#toast-container>div.rtl{direction:rtl;padding:15px 50px 15px 15px;background-position:right 15px center}#toast-container>div:hover{-moz-box-shadow:0 0 12px #000;-webkit-box-shadow:0 0 12px #000;box-shadow:0 0 12px #000;opacity:1;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=100);filter:alpha(opacity=100);cursor:pointer}#toast-container>.toast-info{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGwSURBVEhLtZa9SgNBEMc9sUxxRcoUKSzSWIhXpFMhhYWFhaBg4yPYiWCXZxBLERsLRS3EQkEfwCKdjWJAwSKCgoKCcudv4O5YLrt7EzgXhiU3/4+b2ckmwVjJSpKkQ6wAi4gwhT+z3wRBcEz0yjSseUTrcRyfsHsXmD0AmbHOC9Ii8VImnuXBPglHpQ5wwSVM7sNnTG7Za4JwDdCjxyAiH3nyA2mtaTJufiDZ5dCaqlItILh1NHatfN5skvjx9Z38m69CgzuXmZgVrPIGE763Jx9qKsRozWYw6xOHdER+nn2KkO+Bb+UV5CBN6WC6QtBgbRVozrahAbmm6HtUsgtPC19tFdxXZYBOfkbmFJ1VaHA1VAHjd0pp70oTZzvR+EVrx2Ygfdsq6eu55BHYR8hlcki+n+kERUFG8BrA0BwjeAv2M8WLQBtcy+SD6fNsmnB3AlBLrgTtVW1c2QN4bVWLATaIS60J2Du5y1TiJgjSBvFVZgTmwCU+dAZFoPxGEEs8nyHC9Bwe2GvEJv2WXZb0vjdyFT4Cxk3e/kIqlOGoVLwwPevpYHT+00T+hWwXDf4AJAOUqWcDhbwAAAAASUVORK5CYII=)!important}#toast-container>.toast-error{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAHOSURBVEhLrZa/SgNBEMZzh0WKCClSCKaIYOED+AAKeQQLG8HWztLCImBrYadgIdY+gIKNYkBFSwu7CAoqCgkkoGBI/E28PdbLZmeDLgzZzcx83/zZ2SSXC1j9fr+I1Hq93g2yxH4iwM1vkoBWAdxCmpzTxfkN2RcyZNaHFIkSo10+8kgxkXIURV5HGxTmFuc75B2RfQkpxHG8aAgaAFa0tAHqYFfQ7Iwe2yhODk8+J4C7yAoRTWI3w/4klGRgR4lO7Rpn9+gvMyWp+uxFh8+H+ARlgN1nJuJuQAYvNkEnwGFck18Er4q3egEc/oO+mhLdKgRyhdNFiacC0rlOCbhNVz4H9FnAYgDBvU3QIioZlJFLJtsoHYRDfiZoUyIxqCtRpVlANq0EU4dApjrtgezPFad5S19Wgjkc0hNVnuF4HjVA6C7QrSIbylB+oZe3aHgBsqlNqKYH48jXyJKMuAbiyVJ8KzaB3eRc0pg9VwQ4niFryI68qiOi3AbjwdsfnAtk0bCjTLJKr6mrD9g8iq/S/B81hguOMlQTnVyG40wAcjnmgsCNESDrjme7wfftP4P7SP4N3CJZdvzoNyGq2c/HWOXJGsvVg+RA/k2MC/wN6I2YA2Pt8GkAAAAASUVORK5CYII=)!important}#toast-container>.toast-success{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAADsSURBVEhLY2AYBfQMgf///3P8+/evAIgvA/FsIF+BavYDDWMBGroaSMMBiE8VC7AZDrIFaMFnii3AZTjUgsUUWUDA8OdAH6iQbQEhw4HyGsPEcKBXBIC4ARhex4G4BsjmweU1soIFaGg/WtoFZRIZdEvIMhxkCCjXIVsATV6gFGACs4Rsw0EGgIIH3QJYJgHSARQZDrWAB+jawzgs+Q2UO49D7jnRSRGoEFRILcdmEMWGI0cm0JJ2QpYA1RDvcmzJEWhABhD/pqrL0S0CWuABKgnRki9lLseS7g2AlqwHWQSKH4oKLrILpRGhEQCw2LiRUIa4lwAAAABJRU5ErkJggg==)!important}#toast-container>.toast-warning{background-image:url(data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAABgAAAAYCAYAAADgdz34AAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAAJcEhZcwAADsMAAA7DAcdvqGQAAAGYSURBVEhL5ZSvTsNQFMbXZGICMYGYmJhAQIJAICYQPAACiSDB8AiICQQJT4CqQEwgJvYASAQCiZiYmJhAIBATCARJy+9rTsldd8sKu1M0+dLb057v6/lbq/2rK0mS/TRNj9cWNAKPYIJII7gIxCcQ51cvqID+GIEX8ASG4B1bK5gIZFeQfoJdEXOfgX4QAQg7kH2A65yQ87lyxb27sggkAzAuFhbbg1K2kgCkB1bVwyIR9m2L7PRPIhDUIXgGtyKw575yz3lTNs6X4JXnjV+LKM/m3MydnTbtOKIjtz6VhCBq4vSm3ncdrD2lk0VgUXSVKjVDJXJzijW1RQdsU7F77He8u68koNZTz8Oz5yGa6J3H3lZ0xYgXBK2QymlWWA+RWnYhskLBv2vmE+hBMCtbA7KX5drWyRT/2JsqZ2IvfB9Y4bWDNMFbJRFmC9E74SoS0CqulwjkC0+5bpcV1CZ8NMej4pjy0U+doDQsGyo1hzVJttIjhQ7GnBtRFN1UarUlH8F3xict+HY07rEzoUGPlWcjRFRr4/gChZgc3ZL2d8oAAAAASUVORK5CYII=)!important}#toast-container.toast-bottom-center>div,#toast-container.toast-top-center>div{width:300px;margin-left:auto;margin-right:auto}#toast-container.toast-bottom-full-width>div,#toast-container.toast-top-full-width>div{width:96%;margin-left:auto;margin-right:auto}.toast{background-color:#030303}.toast-success{background-color:#51A351}.toast-error{background-color:#BD362F}.toast-info{background-color:#2F96B4}.toast-warning{background-color:#F89406}.toast-progress{position:absolute;left:0;bottom:0;height:4px;background-color:#000;opacity:.4;-ms-filter:progid:DXImageTransform.Microsoft.Alpha(Opacity=40);filter:alpha(opacity=40)}@media all and (max-width:240px){#toast-container>div{padding:8px 8px 8px 50px;width:11em}#toast-container>div.rtl{padding:8px 50px 8px 8px}#toast-container .toast-close-button{right:-.2em;top:-.2em}#toast-container .rtl .toast-close-button{left:-.2em;right:.2em}}@media all and (min-width:241px) and (max-width:480px){#toast-container>div{padding:8px 8px 8px 50px;width:18em}#toast-container>div.rtl{padding:8px 50px 8px 8px}#toast-container .toast-close-button{right:-.2em;top:-.2em}#toast-container .rtl .toast-close-button{left:-.2em;right:.2em}}@media all and (min-width:481px) and (max-width:768px){#toast-container>div{padding:15px 15px 15px 50px;width:25em}#toast-container>div.rtl{padding:15px 50px 15px 15px}} diff --git a/obsolete/public/grapejs/dist/css/tooltip.css b/obsolete/public/grapejs/dist/css/tooltip.css index c9a3160d..01bf81b7 100644 --- a/obsolete/public/grapejs/dist/css/tooltip.css +++ b/obsolete/public/grapejs/dist/css/tooltip.css @@ -85,4 +85,4 @@ -webkit-transform: translate(-0.5rem, 50%); -ms-transform: translate(-0.5rem, 50%); transform: translate(-0.5rem, 50%); -} \ No newline at end of file +} diff --git a/obsolete/public/grapejs/dist/js/grapes.min.js b/obsolete/public/grapejs/dist/js/grapes.min.js index 49d2c98b..5ae4a192 100644 --- a/obsolete/public/grapejs/dist/js/grapes.min.js +++ b/obsolete/public/grapejs/dist/js/grapes.min.js @@ -1,17 +1,13 @@ -/*! grapesjs - v0.5.41 */ -!function(a,b){"function"==typeof define&&define.amd?define([],b):"object"==typeof exports&&"object"==typeof module?module.exports=b():a.grapesjs=a.GrapesJS=b()}(this,function(){var a,b,c;!function(d){function e(a,b){return v.call(a,b)}function f(a,b){var c,d,e,f,g,h,i,j,k,l,m,n,o=b&&b.split("/"),p=t.map,q=p&&p["*"]||{};if(a){for(a=a.split("/"),g=a.length-1,t.nodeIdCompat&&x.test(a[g])&&(a[g]=a[g].replace(x,"")),"."===a[0].charAt(0)&&o&&(n=o.slice(0,o.length-1),a=n.concat(a)),k=0;k0&&(a.splice(k-1,2),k-=2)}a=a.join("/")}if((o||q)&&p){for(c=a.split("/"),k=c.length;k>0;k-=1){if(d=c.slice(0,k).join("/"),o)for(l=o.length;l>0;l-=1)if(e=p[o.slice(0,l).join("/")],e&&(e=e[d])){f=e,h=k;break}if(f)break;!i&&q&&q[d]&&(i=q[d],j=k)}!f&&i&&(f=i,h=j),f&&(c.splice(0,h,f),a=c.join("/"))}return a}function g(a,b){return function(){var c=w.call(arguments,0);return"string"!=typeof c[0]&&1===c.length&&c.push(null),o.apply(d,c.concat([a,b]))}}function h(a){return function(b){return f(b,a)}}function i(a){return function(b){r[a]=b}}function j(a){if(e(s,a)){var b=s[a];delete s[a],u[a]=!0,n.apply(d,b)}if(!e(r,a)&&!e(u,a))throw new Error("No "+a);return r[a]}function k(a){var b,c=a?a.indexOf("!"):-1;return c>-1&&(b=a.substring(0,c),a=a.substring(c+1,a.length)),[b,a]}function l(a){return a?k(a):[]}function m(a){return function(){return t&&t.config&&t.config[a]||{}}}var n,o,p,q,r={},s={},t={},u={},v=Object.prototype.hasOwnProperty,w=[].slice,x=/\.js$/;p=function(a,b){var c,d=k(a),e=d[0],g=b[1];return a=d[1],e&&(e=f(e,g),c=j(e)),e?a=c&&c.normalize?c.normalize(a,h(g)):f(a,g):(a=f(a,g),d=k(a),e=d[0],a=d[1],e&&(c=j(e))),{f:e?e+"!"+a:a,n:a,pr:e,p:c}},q={require:function(a){return g(a)},exports:function(a){var b=r[a];return"undefined"!=typeof b?b:r[a]={}},module:function(a){return{id:a,uri:"",exports:r[a],config:m(a)}}},n=function(a,b,c,f){var h,k,m,n,o,t,v,w=[],x=typeof c;if(f=f||a,t=l(f),"undefined"===x||"function"===x){for(b=!b.length&&c.length?["require","exports","module"]:b,o=0;o
",attributes:{"class":"gjs-fonts gjs-f-b1"}},{id:"b2",label:"2 Blocks",content:'
",attributes:{"class":"gjs-fonts gjs-f-b2"}},{id:"b3",label:"3 Blocks",content:'
",attributes:{"class":"gjs-fonts gjs-f-b3"}},{id:"b4",label:"3/7 Block",content:'
",attributes:{"class":"gjs-fonts gjs-f-b37"}},{id:"hero",label:"Hero section",content:'
Build your templates without coding
Try it now
',attributes:{"class":"gjs-fonts gjs-f-hero"}},{id:"h1p",label:"Text section",content:'

Insert title here

Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua

',attributes:{"class":"gjs-fonts gjs-f-h1p"}},{id:"3ba",label:"Badges",content:'
Adam Smith
CEO
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore ipsum dolor sit
ftln
John Black
Software Engineer
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore ipsum dolor sit
ftln
Jessica White
Web Designer
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore ipsum dolor sit
ftln
',attributes:{"class":"gjs-fonts gjs-f-3ba"}},{id:"text",label:"Text",attributes:{"class":"gjs-fonts gjs-f-text"},content:{type:"text",content:"Insert your text here",style:{padding:"10px"},activeOnRender:1}},{id:"image",label:"Image",attributes:{"class":"gjs-fonts gjs-f-image"},content:{style:{color:"black"},type:"image",activeOnRender:1}},{id:"quo",label:"Quote",content:'
Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore ipsum dolor sit
',attributes:{"class":"fa fa-quote-right"}},{id:"link",label:"Link",attributes:{"class":"fa fa-link"},content:{type:"link",content:"Link",style:{color:"#d983a6"}}},{id:"map",label:"Map",attributes:{"class":"fa fa-map-o"},content:{type:"map",style:{height:"350px"}}},{id:"video",label:"Video",attributes:{"class":"fa fa-youtube-play"},content:{type:"video",src:"img/video2.webm",style:{height:"350px",width:"615px"}}}]}}}),function(){function a(a){function b(b,c,d,e,f,g){for(;f>=0&&f0?0:h-1;return arguments.length<3&&(e=c[g?g[i]:i],i+=a),b(c,d,e,g,i,h)}}function b(a){return function(b,c,d){c=v(c,d);for(var e=A(b),f=a>0?0:e-1;f>=0&&f0?g=f>=0?f:Math.max(f+h,g):h=f>=0?Math.min(f+1,h):f+h+1;else if(c&&f&&h)return f=c(d,e),d[f]===e?f:-1;if(e!==e)return f=b(l.call(d,g,h),t.isNaN),f>=0?f+g:-1;for(f=a>0?g:h-1;f>=0&&f=0&&b<=z};t.each=t.forEach=function(a,b,c){b=u(b,c);var d,e;if(B(a))for(d=0,e=a.length;d=0},t.invoke=function(a,b){var c=l.call(arguments,2),d=t.isFunction(b);return t.map(a,function(a){var e=d?b:a[b];return null==e?e:e.apply(a,c)})},t.pluck=function(a,b){return t.map(a,t.property(b))},t.where=function(a,b){return t.filter(a,t.matcher(b))},t.findWhere=function(a,b){return t.find(a,t.matcher(b))},t.max=function(a,b,c){var d,e,f=-(1/0),g=-(1/0);if(null==b&&null!=a){a=B(a)?a:t.values(a);for(var h=0,i=a.length;hf&&(f=d)}else b=v(b,c),t.each(a,function(a,c,d){e=b(a,c,d),(e>g||e===-(1/0)&&f===-(1/0))&&(f=a,g=e)});return f},t.min=function(a,b,c){var d,e,f=1/0,g=1/0;if(null==b&&null!=a){a=B(a)?a:t.values(a);for(var h=0,i=a.length;hd||void 0===c)return 1;if(cb?(g&&(clearTimeout(g),g=null),h=j,f=a.apply(d,e),g||(d=e=null)):g||c.trailing===!1||(g=setTimeout(i,k)),f}},t.debounce=function(a,b,c){var d,e,f,g,h,i=function(){var j=t.now()-g;j=0?d=setTimeout(i,b-j):(d=null,c||(h=a.apply(f,e),d||(f=e=null)))};return function(){f=this,e=arguments,g=t.now();var j=c&&!d;return d||(d=setTimeout(i,b)),j&&(h=a.apply(f,e),f=e=null),h}},t.wrap=function(a,b){return t.partial(b,a)},t.negate=function(a){return function(){return!a.apply(this,arguments)}},t.compose=function(){var a=arguments,b=a.length-1;return function(){for(var c=b,d=a[b].apply(this,arguments);c--;)d=a[c].call(this,d);return d}},t.after=function(a,b){return function(){if(--a<1)return b.apply(this,arguments)}},t.before=function(a,b){var c;return function(){return--a>0&&(c=b.apply(this,arguments)),a<=1&&(b=null),c}},t.once=t.partial(t.before,2);var F=!{toString:null}.propertyIsEnumerable("toString"),G=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];t.keys=function(a){if(!t.isObject(a))return[];if(p)return p(a);var b=[];for(var c in a)t.has(a,c)&&b.push(c);return F&&e(a,b),b},t.allKeys=function(a){if(!t.isObject(a))return[];var b=[];for(var c in a)b.push(c);return F&&e(a,b),b},t.values=function(a){for(var b=t.keys(a),c=b.length,d=Array(c),e=0;e":">",'"':""","'":"'","`":"`"},J=t.invert(I),K=function(a){var b=function(b){return a[b]},c="(?:"+t.keys(a).join("|")+")",d=RegExp(c),e=RegExp(c,"g");return function(a){return a=null==a?"":""+a,d.test(a)?a.replace(e,b):a}};t.escape=K(I),t.unescape=K(J),t.result=function(a,b,c){var d=null==a?void 0:a[b];return void 0===d&&(d=c),t.isFunction(d)?d.call(a):d};var L=0;t.uniqueId=function(a){var b=++L+"";return a?a+b:b},t.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var M=/(.)^/,N={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},O=/\\|'|\r|\n|\u2028|\u2029/g,P=function(a){return"\\"+N[a]};t.template=function(a,b,c){!b&&c&&(b=c),b=t.defaults({},b,t.templateSettings);var d=RegExp([(b.escape||M).source,(b.interpolate||M).source,(b.evaluate||M).source].join("|")+"|$","g"),e=0,f="__p+='";a.replace(d,function(b,c,d,g,h){return f+=a.slice(e,h).replace(O,P),e=h+b.length,c?f+="'+\n((__t=("+c+"))==null?'':_.escape(__t))+\n'":d?f+="'+\n((__t=("+d+"))==null?'':__t)+\n'":g&&(f+="';\n"+g+"\n__p+='"),b}),f+="';\n",b.variable||(f="with(obj||{}){\n"+f+"}\n"),f="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+f+"return __p;\n";try{var g=new Function(b.variable||"obj","_",f)}catch(h){throw h.source=f,h}var i=function(a){return g.call(this,a,t)},j=b.variable||"obj";return i.source="function("+j+"){\n"+f+"}",i},t.chain=function(a){var b=t(a);return b._chain=!0,b};var Q=function(a,b){return a._chain?t(b).chain():b};t.mixin=function(a){t.each(t.functions(a),function(b){var c=t[b]=a[b];t.prototype[b]=function(){var a=[this._wrapped];return k.apply(a,arguments),Q(this,c.apply(t,a))}})},t.mixin(t),t.each(["pop","push","reverse","shift","sort","splice","unshift"],function(a){var b=h[a];t.prototype[a]=function(){var c=this._wrapped;return b.apply(c,arguments),"shift"!==a&&"splice"!==a||0!==c.length||delete c[0],Q(this,c)}}),t.each(["concat","join","slice"],function(a){var b=h[a];t.prototype[a]=function(){return Q(this,b.apply(this._wrapped,arguments))}}),t.prototype.value=function(){return this._wrapped},t.prototype.valueOf=t.prototype.toJSON=t.prototype.value,t.prototype.toString=function(){return""+this._wrapped},"function"==typeof c&&c.amd&&c("underscore",[],function(){return t})}.call(this),c("jquery",[],function(){return jQuery}),function(a){var d="object"==typeof self&&self.self===self&&self||"object"==typeof global&&global.global===global&&global;if("function"==typeof c&&c.amd)c("backbone",["underscore","jquery","exports"],function(b,c,e){d.Backbone=a(d,e,b,c)});else if("undefined"!=typeof exports){var e,f=b("underscore");try{e=b("jquery")}catch(g){}a(d,exports,f,e)}else d.Backbone=a(d,{},d._,d.jQuery||d.Zepto||d.ender||d.$)}(function(a,b,c,d){var e=a.Backbone,f=Array.prototype.slice;b.VERSION="1.3.3",b.$=d,b.noConflict=function(){return a.Backbone=e,this},b.emulateHTTP=!1,b.emulateJSON=!1;var g=function(a,b,d){switch(a){case 1:return function(){return c[b](this[d])};case 2:return function(a){return c[b](this[d],a)};case 3:return function(a,e){return c[b](this[d],i(a,this),e)};case 4:return function(a,e,f){return c[b](this[d],i(a,this),e,f)};default:return function(){var a=f.call(arguments);return a.unshift(this[d]),c[b].apply(c,a)}}},h=function(a,b,d){c.each(b,function(b,e){c[e]&&(a.prototype[e]=g(b,e,d))})},i=function(a,b){return c.isFunction(a)?a:c.isObject(a)&&!b._isModel(a)?j(a):c.isString(a)?function(b){return b.get(a)}:a},j=function(a){var b=c.matches(a);return function(a){return b(a.attributes)}},k=b.Events={},l=/\s+/,m=function(a,b,d,e,f){var g,h=0;if(d&&"object"==typeof d){void 0!==e&&"context"in f&&void 0===f.context&&(f.context=e);for(g=c.keys(d);hthis.length&&(e=this.length),e<0&&(e+=this.length+1);var f,g,h=[],i=[],j=[],k=[],l={},m=b.add,n=b.merge,o=b.remove,p=!1,q=this.comparator&&null==e&&b.sort!==!1,r=c.isString(this.comparator)?this.comparator:null;for(g=0;g7),this._useHashChange=this._wantsHashChange&&this._hasHashChange,this._wantsPushState=!!this.options.pushState,this._hasPushState=!(!this.history||!this.history.pushState),this._usePushState=this._wantsPushState&&this._hasPushState,this.fragment=this.getFragment(),this.root=("/"+this.root+"/").replace(L,"/"),this._wantsHashChange&&this._wantsPushState){if(!this._hasPushState&&!this.atRoot()){var b=this.root.slice(0,-1)||"/";return this.location.replace(b+"#"+this.getPath()),!0}this._hasPushState&&this.atRoot()&&this.navigate(this.getHash(),{replace:!0})}if(!this._hasHashChange&&this._wantsHashChange&&!this._usePushState){this.iframe=document.createElement("iframe"),this.iframe.src="javascript:0",this.iframe.style.display="none",this.iframe.tabIndex=-1;var d=document.body,e=d.insertBefore(this.iframe,d.firstChild).contentWindow;e.document.open(),e.document.close(),e.location.hash="#"+this.fragment}var f=window.addEventListener||function(a,b){return attachEvent("on"+a,b)};if(this._usePushState?f("popstate",this.checkUrl,!1):this._useHashChange&&!this.iframe?f("hashchange",this.checkUrl,!1):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),!this.options.silent)return this.loadUrl()},stop:function(){var a=window.removeEventListener||function(a,b){return detachEvent("on"+a,b)};this._usePushState?a("popstate",this.checkUrl,!1):this._useHashChange&&!this.iframe&&a("hashchange",this.checkUrl,!1),this.iframe&&(document.body.removeChild(this.iframe),this.iframe=null),this._checkUrlInterval&&clearInterval(this._checkUrlInterval),J.started=!1},route:function(a,b){this.handlers.unshift({route:a,callback:b})},checkUrl:function(a){var b=this.getFragment();return b===this.fragment&&this.iframe&&(b=this.getHash(this.iframe.contentWindow)),b!==this.fragment&&(this.iframe&&this.navigate(b),void this.loadUrl())},loadUrl:function(a){return!!this.matchRoot()&&(a=this.fragment=this.getFragment(a),c.some(this.handlers,function(b){if(b.route.test(a))return b.callback(a),!0}))},navigate:function(a,b){if(!J.started)return!1;b&&b!==!0||(b={trigger:!!b}),a=this.getFragment(a||"");var c=this.root;""!==a&&"?"!==a.charAt(0)||(c=c.slice(0,-1)||"/");var d=c+a;if(a=this.decodeFragment(a.replace(M,"")),this.fragment!==a){if(this.fragment=a,this._usePushState)this.history[b.replace?"replaceState":"pushState"]({},document.title,d);else{if(!this._wantsHashChange)return this.location.assign(d);if(this._updateHash(this.location,a,b.replace),this.iframe&&a!==this.getHash(this.iframe.contentWindow)){var e=this.iframe.contentWindow;b.replace||(e.document.open(),e.document.close()),this._updateHash(e.location,a,b.replace)}}return b.trigger?this.loadUrl(a):void 0}},_updateHash:function(a,b,c){if(c){var d=a.href.replace(/(javascript:|#).*$/,"");a.replace(d+"#"+b)}else a.hash="#"+b}}),b.history=new J;var N=function(a,b){var d,e=this;return d=a&&c.has(a,"constructor")?a.constructor:function(){return e.apply(this,arguments)},c.extend(d,e,b),d.prototype=c.create(e.prototype,a),d.prototype.constructor=d,d.__super__=e.prototype,d};t.extend=v.extend=E.extend=A.extend=J.extend=N;var O=function(){throw new Error('A "url" property or function must be specified')},P=function(a,b){var c=b.error;b.error=function(d){c&&c.call(b.context,a,d,b),a.trigger("error",a,d,b)}};return b}),function(a){"function"==typeof c&&c.amd?c("backboneUndo",["underscore","backbone"],a):"undefined"!=typeof exports?module.exports=a(b("underscore"),b("backbone")):a(_,Backbone)}(function(a,b){function c(a,b,c){return c.length<=4?a.call(b,c[0],c[1],c[2],c[3]):a.apply(b,c)}function d(a,b){return n.call(a,b)}function e(b,c){return null!=b&&(a.isArray(c)||(c=d(arguments,1)),a.all(c,function(a){return a in b}))}function f(){this.registeredObjects=[],this.cidIndexes=[]}function g(b,c,d,e){for(var f,g=0,h=c.length;ga.maximumStackLength&&(a.shift(),a.pointer--)}}}function l(){}function m(b,c,d,f){if("object"==typeof c)return a.each(c,function(a,c){2===b?m(b,a,d,f):m(b,c,a,d)});switch(b){case 0:e(d,"undo","redo","on")&&a.all(a.pick(d,"undo","redo","on"),a.isFunction)&&(f[c]=d);break;case 1:f[c]&&a.isObject(d)&&(f[c]=a.extend({},f[c],d));break;case 2:delete f[c]}return this}var n=Array.prototype.slice,o=function(){function b(){d++,c=!0,a.defer(function(){c=!1})}var c=!1,d=-1;return function(){return c||b(),d}}();f.prototype={isRegistered:function(b){return b&&b.cid?this.registeredObjects[b.cid]:a.contains(this.registeredObjects,b)},register:function(a){return!this.isRegistered(a)&&(a&&a.cid?(this.registeredObjects[a.cid]=a,this.cidIndexes.push(a.cid)):this.registeredObjects.push(a),!0)},unregister:function(b){if(this.isRegistered(b)){if(b&&b.cid)delete this.registeredObjects[b.cid],this.cidIndexes.splice(a.indexOf(this.cidIndexes,b.cid),1);else{var c=a.indexOf(this.registeredObjects,b);this.registeredObjects.splice(c,1)}return!0}return!1},get:function(){return a.map(this.cidIndexes,function(a){return this.registeredObjects[a]},this).concat(this.registeredObjects)}};var p={add:{undo:function(a,b,c,d){a.remove(c,d)},redo:function(a,b,c,d){d.index&&(d.at=d.index),a.add(c,d)},on:function(b,c,d){return{object:c,before:void 0,after:b,options:a.clone(d)}}},remove:{undo:function(a,b,c,d){"index"in d&&(d.at=d.index),a.add(b,d)},redo:function(a,b,c,d){a.remove(b,d)},on:function(b,c,d){return{object:c,before:b,after:void 0,options:a.clone(d)}}},change:{undo:function(b,c,d,e){a.isEmpty(c)?a.each(a.keys(d),b.unset,b):(b.set(c),e&&e.unsetData&&e.unsetData.before&&e.unsetData.before.length&&a.each(e.unsetData.before,b.unset,b))},redo:function(b,c,d,e){a.isEmpty(d)?a.each(a.keys(c),b.unset,b):(b.set(d),e&&e.unsetData&&e.unsetData.after&&e.unsetData.after.length&&a.each(e.unsetData.after,b.unset,b))},on:function(b,c){var d=b.changedAttributes(),e=a.keys(d),f=a.pick(b.previousAttributes(),e),g=a.keys(f),h=(c||(c={})).unsetData={after:[],before:[]};return e.length!=g.length&&(e.length>g.length?a.each(e,function(a){a in f||h.before.push(a)},this):a.each(g,function(a){a in d||h.after.push(a)})),{object:b,before:f,after:d,options:a.clone(c)}}},reset:{undo:function(a,b,c){a.reset(b)},redo:function(a,b,c){a.reset(c)},on:function(b,c){return{object:b,before:c.previousModels,after:a.clone(b.models)}}}};l.prototype=p;var q=b.Model.extend({defaults:{type:null,object:null,before:null,after:null,magicFusionIndex:null},undo:function(a){h("undo",this.attributes)},redo:function(a){h("redo",this.attributes)}}),r=b.Collection.extend({model:q,pointer:-1,track:!1,isCurrentlyUndoRedoing:!1,maximumStackLength:1/0,setMaxLength:function(a){this.maximumStackLength=a}}),s=b.Model.extend({defaults:{maximumStackLength:1/0,track:!1},initialize:function(b){this.stack=new r,this.objectRegistry=new f,this.undoTypes=new l,this.stack.setMaxLength(this.get("maximumStackLength")),this.on("change:maximumStackLength",function(a,b){this.stack.setMaxLength(b)},this),b&&b.track&&this.startTracking(),b&&b.register&&(a.isArray(b.register)||a.isArguments(b.register)?c(this.register,this,b.register):this.register(b.register))},startTracking:function(){this.set("track",!0),this.stack.track=!0},stopTracking:function(){this.set("track",!1),this.stack.track=!1},isTracking:function(){return this.get("track")},_addToStack:function(a){k(this.stack,a,d(arguments,1),this.undoTypes)},register:function(){g("on",arguments,this._addToStack,this)},unregister:function(){g("off",arguments,this._addToStack,this)},unregisterAll:function(){c(this.unregister,this,this.objectRegistry.get())},undo:function(a){i("undo",this,this.stack,a)},undoAll:function(){i("undo",this,this.stack,!1,!0)},redo:function(a){i("redo",this,this.stack,a)},redoAll:function(){i("redo",this,this.stack,!1,!0)},isAvailable:function(a){var b=this.stack,c=b.length;switch(a){case"undo":return c>0&&b.pointer>-1;case"redo":return c>0&&b.pointer0;for(f in v)(!v[f]&&b(e.mods,+f)>-1||v[f]&&b(e.mods,+f)==-1)&&(i=!1);(0!=e.mods.length||v[16]||v[18]||v[17]||v[91])&&!i||e.method(a,e)===!1&&(a.preventDefault?a.preventDefault():a.returnValue=!1,a.stopPropagation&&a.stopPropagation(),a.cancelBubble&&(a.cancelBubble=!0))}}function f(a){var c,d=a.keyCode,e=b(A,d);if(e>=0&&A.splice(e,1),93!=d&&224!=d||(d=91),d in v){v[d]=!1;for(c in x)x[c]==d&&(h[c]=!1)}}function g(){for(t in v)v[t]=!1;for(t in x)h[t]=!1}function h(a,b,c){var d,e;d=p(a),void 0===c&&(c=b,b="all");for(var f=0;f1&&(e=q(a),a=[a[a.length-1]]),a=a[0],a=z(a),a in u||(u[a]=[]),u[a].push({shortcut:d[f],scope:b,method:c,key:d[f],mods:e})}function i(a,b){var d,e,f,g,h,i=[];for(d=p(a),g=0;g1&&(i=q(e),a=e[e.length-1]),a=z(a),void 0===b&&(b=n()),!u[a])return;for(f=0;fg||g>h+j-e||i+e>f||f>i+k-e)&&(d=1),!!d},findPosition:function(a,b,c){for(var d={index:0,method:"before"},e=0,f=0,g=0,h=0,i=0,j=0,k=0,l=0,m=0,n=a.length;mf||h&&j>=h||e&&gg?d.h=Math.round(d.w/g):d.w=Math.round(d.h*g)}return~e.indexOf("l")&&(d.l=c.w-d.w),~e.indexOf("t")&&(d.t=c.h-d.h),d}}}}),c("Utils/main",["require","./Sorter","./Resizer"],function(a){var b=function(){var b=a("./Sorter"),c=a("./Resizer");return{name:"Utils",init:function(){return this},Sorter:b,Resizer:c}};return b}),c("Utils",["Utils/main"],function(a){return a}),c("StorageManager/config/config",[],function(){return{id:"gjs-",autosave:1,autoload:1,type:"local",stepsBeforeSave:1,storeComponents:!1,storeStyles:!1,storeHtml:!0,storeCss:!0,checkLocal:!0,params:{},urlStore:"",urlLoad:"",beforeSend:function(a,b){},onComplete:function(a,b){},contentTypeJson:!1}}),c("StorageManager/model/LocalStorage",["backbone"],function(a){return a.Model.extend({defaults:{checkLocal:!0},store:function(a,b){this.checkStorageEnvironment();for(var c in a)localStorage.setItem(c,a[c]);"function"==typeof b&&b()},load:function(a){this.checkStorageEnvironment();for(var b={},c=0,d=a.length;c/im,j=/]*>\s*([\s\S]+)\s*<\/body>/im,k="undefined"!=typeof location&&location.href,l=k&&location.protocol&&location.protocol.replace(/\:/,""),m=k&&location.hostname,n=k&&(location.port||void 0),o={},p=a.config&&a.config()||{};return c={version:"2.0.12",strip:function(a){if(a){a=a.replace(i,"");var b=a.match(j);b&&(a=b[1])}else a="";return a},jsEscape:function(a){return a.replace(/(['\\])/g,"\\$1").replace(/[\f]/g,"\\f").replace(/[\b]/g,"\\b").replace(/[\n]/g,"\\n").replace(/[\t]/g,"\\t").replace(/[\r]/g,"\\r").replace(/[\u2028]/g,"\\u2028").replace(/[\u2029]/g,"\\u2029")},createXhr:p.createXhr||function(){var a,b,c;if("undefined"!=typeof XMLHttpRequest)return new XMLHttpRequest;if("undefined"!=typeof ActiveXObject)for(b=0;b<3;b+=1){c=h[b];try{a=new ActiveXObject(c)}catch(d){}if(a){h=[c];break}}return a},parseName:function(a){var b,c,d,e=!1,f=a.indexOf("."),g=0===a.indexOf("./")||0===a.indexOf("../");return f!==-1&&(!g||f>1)?(b=a.substring(0,f),c=a.substring(f+1,a.length)):b=a,d=c||b,f=d.indexOf("!"),f!==-1&&(e="strip"===d.substring(f+1),d=d.substring(0,f),c?c=d:b=d),{moduleName:b,ext:c,strip:e}},xdRegExp:/^((\w+)\:)?\/\/([^\/\\]+)/,useXhr:function(a,b,d,e){var f,g,h,i=c.xdRegExp.exec(a);return!i||(f=i[2],g=i[3],g=g.split(":"),h=g[1],g=g[0],!(f&&f!==b||g&&g.toLowerCase()!==d.toLowerCase()||(h||g)&&h!==e))},finishLoad:function(a,b,d,e){d=b?c.strip(d):d,p.isBuild&&(o[a]=d),e(d)},load:function(a,b,d,e){if(e&&e.isBuild&&!e.inlineText)return void d();p.isBuild=e&&e.isBuild;var f=c.parseName(a),g=f.moduleName+(f.ext?"."+f.ext:""),h=b.toUrl(g),i=p.useXhr||c.useXhr;return 0===h.indexOf("empty:")?void d():void(!k||i(h,l,m,n)?c.get(h,function(b){c.finishLoad(a,f.strip,b,d)},function(a){d.error&&d.error(a)}):b([g],function(a){c.finishLoad(f.moduleName+"."+f.ext,f.strip,a,d)}))},write:function(a,b,d,e){if(o.hasOwnProperty(b)){var f=c.jsEscape(o[b]);d.asModule(a+"!"+b,"define(function () { return '"+f+"';});\n")}},writeFile:function(a,b,d,e,f){var g=c.parseName(b),h=g.ext?"."+g.ext:"",i=g.moduleName+h,j=d.toUrl(g.moduleName+h)+".js";c.load(i,d,function(b){var d=function(a){return e(j,a)};d.asModule=function(a,b){return e.asModule(a,j,b)},c.write(a,i,d,f)},f)}},"node"===p.env||!p.env&&"undefined"!=typeof process&&process.versions&&process.versions.node&&!process.versions["node-webkit"]?(d=b.nodeRequire("fs"),c.get=function(a,b,c){try{var e=d.readFileSync(a,"utf8");0===e.indexOf("\ufeff")&&(e=e.substring(1)),b(e)}catch(f){c&&c(f)}}):"xhr"===p.env||!p.env&&c.createXhr()?c.get=function(a,b,d,e){var f,g=c.createXhr();if(g.open("GET",a,!0),e)for(f in e)e.hasOwnProperty(f)&&g.setRequestHeader(f.toLowerCase(),e[f]);p.onXhr&&p.onXhr(g,a),g.onreadystatechange=function(c){var e,f;4===g.readyState&&(e=g.status||0,e>399&&e<600?(f=new Error(a+" HTTP status: "+e),f.xhr=g,d&&d(f)):b(g.responseText),p.onXhrComplete&&p.onXhrComplete(g,a))},g.send(null)}:"rhino"===p.env||!p.env&&"undefined"!=typeof Packages&&"undefined"!=typeof java?c.get=function(a,b){var c,d,e="utf-8",f=new java.io.File(a),g=java.lang.System.getProperty("line.separator"),h=new java.io.BufferedReader(new java.io.InputStreamReader(new java.io.FileInputStream(f),e)),i="";try{for(c=new java.lang.StringBuffer,d=h.readLine(),d&&d.length()&&65279===d.charAt(0)&&(d=d.substring(1)),null!==d&&c.append(d);null!==(d=h.readLine());)c.append(g),c.append(d);i=String(c.toString())}finally{h.close()}b(i)}:("xpconnect"===p.env||!p.env&&"undefined"!=typeof Components&&Components.classes&&Components.interfaces)&&(e=Components.classes,f=Components.interfaces,Components.utils["import"]("resource://gre/modules/FileUtils.jsm"),g="@mozilla.org/windows-registry-key;1"in e,c.get=function(a,b){var c,d,h,i={};g&&(a=a.replace(/\//g,"\\")),h=new FileUtils.File(a);try{c=e["@mozilla.org/network/file-input-stream;1"].createInstance(f.nsIFileInputStream),c.init(h,1,0,!1),d=e["@mozilla.org/intl/converter-input-stream;1"].createInstance(f.nsIConverterInputStream),d.init(c,"utf-8",c.available(),f.nsIConverterInputStream.DEFAULT_REPLACEMENT_CHARACTER),d.readString(c.available(),i),d.close(),c.close(),b(i.value)}catch(j){throw new Error((h&&h.path||"")+": "+j)}}),c}),c("text!DeviceManager/template/devices.html",[],function(){return'
<%= deviceLabel %>
\n
\n \n \n \n
\n
\n
\n
\n'}),c("DeviceManager/view/DevicesView",["backbone","text!./../template/devices.html"],function(a,b){return a.View.extend({template:_.template(b),events:{change:"updateDevice"},initialize:function(a){this.config=a.config||{},this.em=this.config.em,this.ppfx=this.config.pStylePrefix||"",this.events["click ."+this.ppfx+"add-trasp"]=this.startAdd,this.listenTo(this.em,"change:device",this.updateSelect),this.delegateEvents()},startAdd:function(){},updateDevice:function(){var a=this.em;if(a){var b=this.devicesEl,c=b?b.val():"";a.set("device",c)}},updateSelect:function(){var a=this.em,b=this.devicesEl;if(a&&a.getDeviceModel&&b){var c=a.getDeviceModel(),d=c?c.get("name"):"";b.val(d)}},getOptions:function(){var a="";return this.collection.each(function(b){var c=b.get("name");a+='"}),a},render:function(){var a=this.ppfx;return this.$el.html(this.template({ppfx:a,deviceLabel:this.config.deviceLabel})),this.devicesEl=this.$el.find("."+a+"devices"),this.devicesEl.append(this.getOptions()),this.el.className=a+"devices-c",this}})}),c("DeviceManager/main",["require","./config/config","./model/Devices","./view/DevicesView"],function(a){return function(){var b,c,d={},e=a("./config/config"),f=a("./model/Devices"),g=a("./view/DevicesView");return{name:"DeviceManager",init:function(a){d=a||{};for(var h in e)h in d||(d[h]=e[h]);return b=new f(d.devices),c=new g({collection:b,config:d}),this},add:function(a,c,d){var e=d||{};return e.name=a,e.width=c,b.add(e)},get:function(a){return b.get(a)},getAll:function(){return b},render:function(){return c.render().el}}}}),c("DeviceManager",["DeviceManager/main"],function(a){return a}),c("Parser/config/config",[],function(){return{textTags:["br","b","i","u"]}}),c("Parser/model/ParserCss",["require"],function(a){return function(a){return{parseSelector:function(a){for(var b=[],c=[],d=a.split(","),e=0,f=d.length;e\n
<%= label %>
\n
\n \n
\n \n \n \n
\n
\n
\n
\n
\n
\n\n
\n
\n \n \n
\n
\n
Selected
\n
\n
\n
\n'}),c("text!SelectorManager/template/classTag.html",[],function(){return'\n \n />\n \n'}),c("SelectorManager/view/ClassTagView",["backbone","text!./../template/classTag.html"],function(a,b){return a.View.extend({template:_.template(b),events:{},initialize:function(a){this.config=a.config||{},this.coll=a.coll||null,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.inputProp="readonly",this.target=this.config.em,this.className=this.pfx+"tag",this.closeId=this.pfx+"close",this.chkId=this.pfx+"checkbox",this.labelId=this.pfx+"tag-label",this.events["click #"+this.closeId]="removeTag",this.events["click #"+this.chkId]="changeStatus",this.events["dblclick #"+this.labelId]="startEditTag",this.events["keypress #"+this.labelId+" input"]="updateInputLabel",this.events["blur #"+this.labelId+" input"]="endEditTag",this.listenTo(this.model,"change:active",this.updateStatus),this.delegateEvents()},startEditTag:function(){this.$labelInput.prop(this.inputProp,!1)},endEditTag:function(){var a=this.$labelInput.val(),b=this.model.escapeName(a);if(this.target){var c=this.target.get("SelectorManager");c&&(c.get(b)?this.$labelInput.val(this.model.get("label")):this.model.set({name:b,label:a}))}this.$labelInput.prop(this.inputProp,!0)},changeStatus:function(){this.model.set("active",!this.model.get("active")),this.target.trigger("targetClassUpdated")},removeTag:function(a){var b=this.target.get("selectedComponent");b&&b.get("classes").remove(this.model),this.coll&&(this.coll.remove(this.model),this.target.trigger("targetClassRemoved")),this.remove()},updateStatus:function(){this.$chk||(this.$chk=this.$el.find("#"+this.pfx+"checkbox")),this.model.get("active")?(this.$chk.removeClass("fa-circle-o").addClass("fa-dot-circle-o"),this.$el.removeClass("opac50")):(this.$chk.removeClass("fa-dot-circle-o").addClass("fa-circle-o"),this.$el.addClass("opac50"))},updateInputLabel:function(){this.$labelInput||(this.$labelInput=this.$el.find("input"));var a=this.$labelInput.val().length-1;a=a<1?1:a,this.$labelInput.attr("size",a)},render:function(){return this.$el.html(this.template({label:this.model.get("label"),pfx:this.pfx,ppfx:this.ppfx,inputProp:this.inputProp})),this.updateStatus(),this.$el.attr("class",this.className),this.updateInputLabel(),this}})}),c("SelectorManager/view/ClassTagsView",["backbone","text!./../template/classTags.html","./ClassTagView"],function(a,b,c){return a.View.extend({template:_.template(b),events:{},initialize:function(a){this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.className=this.pfx+"tags",this.addBtnId=this.pfx+"add-tag",this.newInputId=this.pfx+"new",this.stateInputId=this.pfx+"states",this.stateInputC=this.pfx+"input-c",this.states=this.config.states||[],this.events["click #"+this.addBtnId]="startNewTag",this.events["blur #"+this.newInputId]="endNewTag",this.events["keyup #"+this.newInputId]="onInputKeyUp",this.events["change #"+this.stateInputId]="stateChanged",this.target=this.config.em,this.listenTo(this.target,"change:selectedComponent",this.componentChanged),this.listenTo(this.target,"targetClassUpdated",this.updateSelector),this.listenTo(this.collection,"add",this.addNew),this.listenTo(this.collection,"reset",this.renderClasses),this.listenTo(this.collection,"remove",this.tagRemoved),this.delegateEvents()},tagRemoved:function(a){this.updateStateVis()},getStateOptions:function(){for(var a="",b=0;b'+this.states[b].label+"";return a},addNew:function(a){this.addToClasses(a)},startNewTag:function(a){this.$addBtn.hide(),this.$input.show().focus()},endNewTag:function(a){this.$addBtn.show(),this.$input.hide().val("")},onInputKeyUp:function(a){13===a.keyCode?this.addNewTag(this.$input.val()):27===a.keyCode&&this.endNewTag()},componentChanged:function(a){this.compTarget=this.target.get("selectedComponent"),this.compTarget&&this.getStates().val(this.compTarget.get("state"));var b=this.compTarget?this.compTarget.get("classes").models:[];this.collection.reset(b),this.updateStateVis()},updateStateVis:function(){this.collection.length?this.getStatesC().css("display","block"):this.getStatesC().css("display","none"),this.updateSelector()},updateSelector:function(){if(this.compTarget=this.target.get("selectedComponent"),this.compTarget&&this.compTarget.get){var a="",b=this.compTarget.get("classes");b.each(function(b){b.get("active")&&(a+="."+b.get("name"))});var c=this.compTarget.get("state");a=c?a+":"+c:a;var d=this.el.querySelector("#"+this.pfx+"sel");d&&(d.innerHTML=a)}},stateChanged:function(a){this.compTarget&&(this.compTarget.set("state",this.$states.val()),this.target&&this.target.trigger("targetStateUpdated"),this.updateSelector())},addNewTag:function(a){if(a){if(this.target){var b=this.target.get("SelectorManager"),c=b.add(a);if(this.compTarget){var d=this.compTarget.get("classes"),e=d.length;d.add(c);var f=d.length;this.collection.add(c),f>e&&this.target.trigger("targetClassAdded"),this.updateStateVis()}}this.endNewTag()}},addToClasses:function(a,b){var d=b||null,e=new c({model:a,config:this.config,coll:this.collection}),f=e.render().el;return d?d.appendChild(f):this.getClasses().append(f),f},renderClasses:function(){var a=document.createDocumentFragment();return this.collection.each(function(b){this.addToClasses(b,a)},this),this.getClasses()&&this.getClasses().empty().append(a),this},getClasses:function(){return this.$classes||(this.$classes=this.$el.find("#"+this.pfx+"tags-c")),this.$classes},getStates:function(){return this.$states||(this.$states=this.$el.find("#"+this.stateInputId)),this.$states},getStatesC:function(){return this.$statesC||(this.$statesC=this.$el.find("#"+this.stateInputC)),this.$statesC},render:function(){return this.$el.html(this.template({label:this.config.label,statesLabel:this.config.statesLabel,pfx:this.pfx,ppfx:this.ppfx})),this.$input=this.$el.find("input#"+this.newInputId),this.$addBtn=this.$el.find("#"+this.addBtnId),this.$classes=this.$el.find("#"+this.pfx+"tags-c"),this.$states=this.$el.find("#"+this.stateInputId),this.$statesC=this.$el.find("#"+this.stateInputC),this.$states.append(this.getStateOptions()),this.renderClasses(),this.$el.attr("class",this.className),this}})}),c("SelectorManager/main",["require","./config/config","./model/Selectors","./view/ClassTagsView"],function(a){return function(b){var c=b||{},d=a("./config/config");Selectors=a("./model/Selectors"),ClassTagsView=a("./view/ClassTagsView");var e,f;return{name:"SelectorManager",init:function(a){c=a||{};for(var b in d)b in c||(c[b]=d[b]);var g=c.pStylePrefix;return g&&(c.stylePrefix=g+c.stylePrefix),e=new Selectors(c.selectors,{em:c.em,config:c}),f=new ClassTagsView({collection:e,config:c}),this},add:function(a,b){var c=b||{};return c.name=a.name||a,e.add(c)},get:function(a){return e.where({name:a})[0]},getAll:function(){return e},render:function(a){if(a){var b=new ClassTagsView({collection:new Selectors(a),config:c});return b.render().el}return f.render().el}}}}),c("SelectorManager",["SelectorManager/main"],function(a){return a}),c("ModalDialog/config/config",[],function(){return{stylePrefix:"mdl-",title:"",content:"",backdrop:!0}}),c("ModalDialog/model/Modal",["backbone"],function(a){return a.Model.extend({ -defaults:{title:"",content:"",open:!1}})}),c("text!ModalDialog/template/modal.html",[],function(){return'
\n
\n
<%= title %>
\n
\n
\n
\n
<%= content %>
\n
\n
\n
\n
\n\n'}),c("ModalDialog/view/ModalView",["backbone","text!./../template/modal.html"],function(a,b){return a.View.extend({template:_.template(b),events:{},initialize:function(a){this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.listenTo(this.model,"change:open",this.updateOpen),this.listenTo(this.model,"change:title",this.updateTitle),this.listenTo(this.model,"change:content",this.updateContent),this.events["click ."+this.pfx+"btn-close"]="hide",this.config.backdrop&&(this.events["click ."+this.pfx+"backlayer"]="hide"),this.delegateEvents()},getCollector:function(){return this.$collector||(this.$collector=this.$el.find("."+this.pfx+"collector")),this.$collector},getContent:function(){return this.$content||(this.$content=this.$el.find("."+this.pfx+"content #"+this.pfx+"c")),this.$content},getTitle:function(){return this.$title||(this.$title=this.$el.find("."+this.pfx+"title")),this.$title.get(0)},updateContent:function(){var a=this.getContent();this.getCollector().append(a.children()),a.html(this.model.get("content"))},updateTitle:function(){var a=this.getTitle();a&&(a.innerHTML=this.model.get("title"))},updateOpen:function(){this.model.get("open")?this.$el.show():this.$el.hide()},hide:function(){this.model.set("open",0)},show:function(){this.model.set("open",1)},render:function(){var a=this.model.toJSON();return a.pfx=this.pfx,this.$el.html(this.template(a)),this.$el.attr("class",this.pfx+"container"),this.updateOpen(),this}})}),c("ModalDialog/main",["require","./config/config","./model/Modal","./view/ModalView"],function(a){return function(){var b,c,d={},e=a("./config/config"),f=a("./model/Modal"),g=a("./view/ModalView");return{name:"Modal",init:function(a){d=a||{};for(var h in e)h in d||(d[h]=e[h]);var i=d.pStylePrefix;return i&&(d.stylePrefix=i+d.stylePrefix),b=new f(d),c=new g({model:b,config:d}),d.em&&d.em.on("loaded",function(){this.render().appendTo(d.em.config.el||"body")},this),this},open:function(){return c.show(),this},close:function(){return c.hide(),this},isOpen:function(){return!!b.get("open")},setTitle:function(a){return b.set("title",a),this},getTitle:function(){return b.get("title")},setContent:function(a){return b.set("content"," "),b.set("content",a),this},getContent:function(){return b.get("content")},getContentEl:function(){return c.getContent().get(0)},getModel:function(){return b},render:function(){return c.render().$el}}}}),c("ModalDialog",["ModalDialog/main"],function(a){return a}),c("CodeManager/config/config",[],function(){return{stylePrefix:"cm-",inlineCss:!1}}),c("CodeManager/model/HtmlGenerator",["backbone"],function(a){return a.Model.extend({build:function(a,b){var c=a.get("components")||a,d="";return c.each(function(a){d+=a.toHTML({cssc:b})},this),d}})}),c("CodeManager/model/CssGenerator",["backbone"],function(a){return a.Model.extend({initialize:function(){this.compCls=[]},buildFromModel:function(a){var b="",c=a.get("style"),d=a.get("classes");if(d&&d.each(function(a){this.compCls.push(a.get("name"))},this),c&&0!==Object.keys(c).length){b+="#"+a.cid+"{";for(var e in c)c.hasOwnProperty(e)&&(b+=e+":"+c[e]+";");b+="}"}return b},buildFromComp:function(a){var b=a.get("components")||a,c="";return b.each(function(a){var b=a.get("components");c+=this.buildFromModel(a),b.length&&(c+=this.buildFromComp(b))},this),c},build:function(a,b){this.compCls=[];var c=this.buildFromModel(a);c+=this.buildFromComp(a);this.compCls;if(b){var d=b.getAll(),e={};d.each(function(a){var b=a.get("mediaText");if(b){var d=e[b];return void(d?d.push(a):e[b]=[a])}c+=this.buildFromRule(a)},this);for(var f in e){for(var g=e[f],h="",i=0,j=g.length;i-1&&(h=1)}),g&&h||c){g+=f?":"+f:"",g+=c?(g?", ":"")+c:"";var j="";if(e&&0!==Object.keys(e).length)for(var k in e)e.hasOwnProperty(k)&&(j+=k+":"+e[k]+";");j&&(b+=g+"{"+j+"}")}return b}})}),c("CodeManager/model/JsonGenerator",["backbone"],function(a){return a.Model.extend({build:function(b){var c=b.toJSON();return this.beforeEach(c),_.each(c,function(b,d){var e=c[d];if(e instanceof a.Model)c[d]=this.build(e);else if(e instanceof a.Collection){var f=e;c[d]=[],f.length&&f.each(function(a,b){c[d][b]=this.build(a)},this)}},this),c},beforeEach:function(a){delete a.status}})}),c("CodeManager/model/JsGenerator",["backbone"],function(a){return a.Model.extend({mapModel:function(a){var b="",c=a.get("script"),d=a.get("type"),e=a.get("components"),f=a.cid;if(c){var g=a.get("attributes");g=_.extend({},g,{id:f}),a.set("attributes",g);var h="function(){"+c+"}";if(h="function"==typeof c?c.toString():h,a.get("scriptUpdated"))this.mapJs[d+"-"+f]={ids:[f],code:h};else{var i=this.mapJs[d];i?i.ids.push(f):this.mapJs[d]={ids:[f],code:h}}}return e.each(function(a){b+=this.mapModel(a)},this),b},build:function(a){this.mapJs={},this.mapModel(a);var b="";for(var c in this.mapJs){var d=this.mapJs[c],e="#"+d.ids.join(", #");b+='var items = document.querySelectorAll("'+e+'");for (var i = 0, len = items.length; i < len; i++) {('+d.code+".bind(items[i]))();}"}return b}})}),function(a,b){"object"==typeof exports&&"undefined"!=typeof module?module.exports=b():"function"==typeof c&&c.amd?c("codemirror/lib/codemirror",b):a.CodeMirror=b()}(this,function(){"use strict";function a(a){return new RegExp("(^|\\s)"+a+"(?:$|\\s)\\s*")}function b(a){for(var b=a.childNodes.length;b>0;--b)a.removeChild(a.firstChild);return a}function c(a,c){return b(a).appendChild(c)}function d(a,b,c,d){var e=document.createElement(a);if(c&&(e.className=c),d&&(e.style.cssText=d),"string"==typeof b)e.appendChild(document.createTextNode(b));else if(b)for(var f=0;f=b)return g+(b-f);g+=h-f,g+=c-g%c,f=h+1}}function l(){this.id=null}function m(a,b){for(var c=0;c=b)return d+Math.min(g,b-e);if(e+=f-d,e+=c-e%c,d=f+1,e>=b)return d}}function o(a){for(;Hg.length<=a;)Hg.push(p(Hg)+" ");return Hg[a]}function p(a){return a[a.length-1]}function q(a,b){for(var c=[],d=0;d"€"&&(a.toUpperCase()!=a.toLowerCase()||Ig.test(a))}function v(a,b){return b?!!(b.source.indexOf("\\w")>-1&&u(a))||b.test(a):u(a)}function w(a){for(var b in a)if(a.hasOwnProperty(b)&&a[b])return!1;return!0}function x(a){return a.charCodeAt(0)>=768&&Jg.test(a)}function y(a,b,c){var e=this;this.input=c,e.scrollbarFiller=d("div",null,"CodeMirror-scrollbar-filler"),e.scrollbarFiller.setAttribute("cm-not-content","true"),e.gutterFiller=d("div",null,"CodeMirror-gutter-filler"),e.gutterFiller.setAttribute("cm-not-content","true"),e.lineDiv=d("div",null,"CodeMirror-code"),e.selectionDiv=d("div",null,null,"position: relative; z-index: 1"),e.cursorDiv=d("div",null,"CodeMirror-cursors"),e.measure=d("div",null,"CodeMirror-measure"),e.lineMeasure=d("div",null,"CodeMirror-measure"),e.lineSpace=d("div",[e.measure,e.lineMeasure,e.selectionDiv,e.cursorDiv,e.lineDiv],null,"position: relative; outline: none"),e.mover=d("div",[d("div",[e.lineSpace],"CodeMirror-lines")],null,"position: relative"),e.sizer=d("div",[e.mover],"CodeMirror-sizer"),e.sizerWidth=null,e.heightForcer=d("div",null,null,"position: absolute; height: "+Cg+"px; width: 1px;"),e.gutters=d("div",null,"CodeMirror-gutters"),e.lineGutter=null,e.scroller=d("div",[e.sizer,e.heightForcer,e.gutters],"CodeMirror-scroll"),e.scroller.setAttribute("tabIndex","-1"),e.wrapper=d("div",[e.scrollbarFiller,e.gutterFiller,e.scroller],"CodeMirror"),gg&&hg<8&&(e.gutters.style.zIndex=-1,e.scroller.style.paddingRight=0),ig||dg&&qg||(e.scroller.draggable=!0),a&&(a.appendChild?a.appendChild(e.wrapper):a(e.wrapper)),e.viewFrom=e.viewTo=b.first,e.reportedViewFrom=e.reportedViewTo=b.first,e.view=[],e.renderedView=null,e.externalMeasured=null,e.viewOffset=0,e.lastWrapHeight=e.lastWrapWidth=0,e.updateLineNumbers=null,e.nativeBarWidth=e.barHeight=e.barWidth=0,e.scrollbarsClipped=!1,e.lineNumWidth=e.lineNumInnerWidth=e.lineNumChars=null,e.alignWidgets=!1,e.cachedCharWidth=e.cachedTextHeight=e.cachedPaddingH=null,e.maxLine=null,e.maxLineLength=0,e.maxLineChanged=!1,e.wheelDX=e.wheelDY=e.wheelStartX=e.wheelStartY=null,e.shift=!1,e.selForContextMenu=null,e.activeTouch=null,c.init(e)}function z(a,b){if(b-=a.first,b<0||b>=a.size)throw new Error("There is no line "+(b+a.first)+" in the document.");for(var c=a;!c.lines;)for(var d=0;;++d){var e=c.children[d],f=e.chunkSize();if(b=a.first&&bc?H(c,z(a,c).text.length):O(b,z(a,b.line).text.length)}function O(a,b){var c=a.ch;return null==c||c>b?H(a.line,b):c<0?H(a.line,0):a}function P(a,b){for(var c=[],d=0;d=b:f.to>b);(d||(d=[])).push(new S(g,f.from,i?null:f.to))}}return d}function X(a,b,c){var d;if(a)for(var e=0;e=b:f.to>b);if(h||f.from==b&&"bookmark"==g.type&&(!c||f.marker.insertLeft)){var i=null==f.from||(g.inclusiveLeft?f.from<=b:f.from0&&h)for(var v=0;v0)){var k=[i,1],l=I(j.from,h.from),n=I(j.to,h.to);(l<0||!g.inclusiveLeft&&!l)&&k.push({from:j.from,to:h.from}),(n>0||!g.inclusiveRight&&!n)&&k.push({from:h.to,to:j.to}),e.splice.apply(e,k),i+=k.length-1}}return e}function _(a){var b=a.markedSpans;if(b){for(var c=0;c=0&&l<=0||k<=0&&l>=0)&&(k<=0&&(i.marker.inclusiveRight&&e.inclusiveLeft?I(j.to,c)>=0:I(j.to,c)>0)||k>=0&&(i.marker.inclusiveRight&&e.inclusiveLeft?I(j.from,d)<=0:I(j.from,d)<0)))return!0}}}function ia(a){for(var b;b=fa(a);)a=b.find(-1,!0).line;return a}function ja(a){for(var b,c;b=ga(a);)a=b.find(1,!0).line,(c||(c=[])).push(a);return c}function ka(a,b){var c=z(a,b),d=ia(c);return c==d?b:D(d)}function la(a,b){if(b>a.lastLine())return b;var c,d=z(a,b);if(!ma(a,d))return b;for(;c=ga(d);)d=c.find(1,!0).line;return D(d)+1}function ma(a,b){var c=Lg&&b.markedSpans;if(c)for(var d=void 0,e=0;eb.maxLineLength&&(b.maxLineLength=c,b.maxLine=a)})}function ra(a,b,c,d){if(!a)return d(b,c,"ltr");for(var e=!1,f=0;fb||b==c&&g.to==b)&&(d(Math.max(g.from,b),Math.min(g.to,c),1==g.level?"rtl":"ltr"),e=!0)}e||d(b,c,"ltr")}function sa(a){return a.level%2?a.to:a.from}function ta(a){return a.level%2?a.from:a.to}function ua(a){var b=Ba(a);return b?sa(b[0]):0}function va(a){var b=Ba(a);return b?ta(p(b)):a.text.length}function wa(a,b,c){var d=a[0].level;return b==d||c!=d&&bb)return d;if(e.from==b||e.to==b){if(null!=c)return wa(a,e.level,a[c].level)?(e.from!=e.to&&(Mg=c),d):(e.from!=e.to&&(Mg=d),c);c=d}}return c}function ya(a,b,c,d){if(!d)return b+c;do b+=c;while(b>0&&x(a.text.charAt(b)));return b}function za(a,b,c,d){var e=Ba(a);if(!e)return Aa(a,b,c,d);for(var f=xa(e,b),g=e[f],h=ya(a,b,g.level%2?-c:c,d);;){if(h>g.from&&h0==g.level%2?g.to:g.from);if(g=e[f+=c],!g)return null;h=c>0==g.level%2?ya(a,g.to,-1,d):ya(a,g.from,1,d)}}function Aa(a,b,c,d){var e=b+c;if(d)for(;e>0&&x(a.text.charAt(e));)e+=c;return e<0||e>a.text.length?null:e}function Ba(a){var b=a.order;return null==b&&(b=a.order=Ng(a.text)),b}function Ca(a,b){return a._handlers&&a._handlers[b]||Og}function Da(a,b,c){if(a.removeEventListener)a.removeEventListener(b,c,!1);else if(a.detachEvent)a.detachEvent("on"+b,c);else{var d=a._handlers,e=d&&d[b];if(e){var f=m(e,c);f>-1&&(d[b]=e.slice(0,f).concat(e.slice(f+1)))}}}function Ea(a,b){var c=Ca(a,b);if(c.length)for(var d=Array.prototype.slice.call(arguments,2),e=0;e0}function Ia(a){a.prototype.on=function(a,b){Pg(this,a,b)},a.prototype.off=function(a,b){Da(this,a,b)}}function Ja(a){a.preventDefault?a.preventDefault():a.returnValue=!1}function Ka(a){a.stopPropagation?a.stopPropagation():a.cancelBubble=!0}function La(a){return null!=a.defaultPrevented?a.defaultPrevented:0==a.returnValue}function Ma(a){Ja(a),Ka(a)}function Na(a){return a.target||a.srcElement}function Oa(a){var b=a.which;return null==b&&(1&a.button?b=1:2&a.button?b=3:4&a.button&&(b=2)),rg&&a.ctrlKey&&1==b&&(b=3),b}function Pa(a){if(null==Ag){var b=d("span","​");c(a,d("span",[b,document.createTextNode("x")])),0!=a.firstChild.offsetHeight&&(Ag=b.offsetWidth<=1&&b.offsetHeight>2&&!(gg&&hg<8))}var e=Ag?d("span","​"):d("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return e.setAttribute("cm-text",""),e}function Qa(a){if(null!=Bg)return Bg;var d=c(a,document.createTextNode("AخA")),e=vg(d,0,1).getBoundingClientRect(),f=vg(d,1,2).getBoundingClientRect();return b(a),!(!e||e.left==e.right)&&(Bg=f.right-e.right<3)}function Ra(a){if(null!=Ug)return Ug;var b=c(a,d("span","x")),e=b.getBoundingClientRect(),f=vg(b,0,1).getBoundingClientRect();return Ug=Math.abs(e.left-f.left)>1}function Sa(a,b){arguments.length>2&&(b.dependencies=Array.prototype.slice.call(arguments,2)),Vg[a]=b}function Ta(a,b){Wg[a]=b}function Ua(a){if("string"==typeof a&&Wg.hasOwnProperty(a))a=Wg[a];else if(a&&"string"==typeof a.name&&Wg.hasOwnProperty(a.name)){var b=Wg[a.name];"string"==typeof b&&(b={name:b}),a=t(b,a),a.name=b.name}else{if("string"==typeof a&&/^[\w\-]+\/[\w\-]+\+xml$/.test(a))return Ua("application/xml");if("string"==typeof a&&/^[\w\-]+\/[\w\-]+\+json$/.test(a))return Ua("application/json")}return"string"==typeof a?{name:a}:a||{name:"null"}}function Va(a,b){b=Ua(b);var c=Vg[b.name];if(!c)return Va(a,"text/plain");var d=c(a,b);if(Xg.hasOwnProperty(b.name)){var e=Xg[b.name];for(var f in e)e.hasOwnProperty(f)&&(d.hasOwnProperty(f)&&(d["_"+f]=d[f]),d[f]=e[f])}if(d.name=b.name,b.helperType&&(d.helperType=b.helperType),b.modeProps)for(var g in b.modeProps)d[g]=b.modeProps[g];return d}function Wa(a,b){var c=Xg.hasOwnProperty(a)?Xg[a]:Xg[a]={};j(b,c)}function Xa(a,b){if(b===!0)return b;if(a.copyState)return a.copyState(b);var c={};for(var d in b){var e=b[d];e instanceof Array&&(e=e.concat([])),c[d]=e}return c}function Ya(a,b){for(var c;a.innerMode&&(c=a.innerMode(b),c&&c.mode!=a);)b=c.state,a=c.mode;return c||{mode:a,state:b}}function Za(a,b,c){return!a.startState||a.startState(b,c)}function $a(a,b,c,d){var e=[a.state.modeGen],f={};gb(a,b.text,a.doc.mode,c,function(a,b){return e.push(a,b)},f,d);for(var g=function(c){var d=a.state.overlays[c],g=1,h=0;gb(a,b.text,d.mode,!0,function(a,b){for(var c=g;ha&&e.splice(g,1,a,e[g+1],f),g+=2,h=Math.min(a,f)}if(b)if(d.opaque)e.splice(c,g-c,a,"overlay "+b),g=c+2;else for(;ca.options.maxHighlightLength?Xa(a.doc.mode,d):d);b.stateAfter=d,b.styles=e.styles,e.classes?b.styleClasses=e.classes:b.styleClasses&&(b.styleClasses=null),c===a.doc.frontier&&a.doc.frontier++}return b.styles}function ab(a,b,c){var d=a.doc,e=a.display;if(!d.mode.startState)return!0;var f=hb(a,b,c),g=f>d.first&&z(d,f-1).stateAfter;return g=g?Xa(d.mode,g):Za(d.mode),d.iter(f,b,function(c){bb(a,c.text,g);var h=f==b-1||f%5==0||f>=e.viewFrom&&fb.start)return f}throw new Error("Mode "+a.name+" failed to advance stream.")}function eb(a,b,c,d){var e,f=function(a){return{start:l.start,end:l.pos,string:l.current(),type:e||null,state:a?Xa(g.mode,k):k}},g=a.doc,h=g.mode;b=N(g,b);var i,j=z(g,b.line),k=ab(a,b.line,c),l=new Yg(j.text,a.options.tabSize);for(d&&(i=[]);(d||l.posa.options.maxHighlightLength?(h=!1,g&&bb(a,b,d,l.pos),l.pos=b.length,i=null):i=fb(db(c,l,d,m),f),m){var n=m[0].name;n&&(i="m-"+(i?n+" "+i:n))}if(!h||k!=i){for(;jg;--h){if(h<=f.first)return f.first;var i=z(f,h-1);if(i.stateAfter&&(!c||h<=f.frontier))return h;var j=k(i.text,null,a.options.tabSize);(null==e||d>j)&&(e=h-1,d=j)}return e}function ib(a,b,c){this.text=a,aa(this,b),this.height=c?c(this):1}function jb(a,b,c,d){a.text=b,a.stateAfter&&(a.stateAfter=null),a.styles&&(a.styles=null),null!=a.order&&(a.order=null),_(a),aa(a,c);var e=d?d(a):1;e!=a.height&&C(a,e)}function kb(a){a.parent=null,_(a)}function lb(a,b){if(!a||/^\s*$/.test(a))return null;var c=b.addModeClass?_g:$g;return c[a]||(c[a]=a.replace(/\S+/g,"cm-$&"))}function mb(a,b){var c=d("span",null,null,ig?"padding-right: .1px":null),e={pre:d("pre",[c],"CodeMirror-line"),content:c,col:0,pos:0,cm:a,trailingSpace:!1,splitSpaces:(gg||ig)&&a.getOption("lineWrapping")};b.measure={};for(var f=0;f<=(b.rest?b.rest.length:0);f++){var g=f?b.rest[f-1]:b.line,i=void 0;e.pos=0,e.addToken=ob,Qa(a.display.measure)&&(i=Ba(g))&&(e.addToken=qb(e.addToken,i)),e.map=[];var j=b!=a.display.externalMeasured&&D(g);sb(g,e,_a(a,g,j)),g.styleClasses&&(g.styleClasses.bgClass&&(e.bgClass=h(g.styleClasses.bgClass,e.bgClass||"")),g.styleClasses.textClass&&(e.textClass=h(g.styleClasses.textClass,e.textClass||""))),0==e.map.length&&e.map.push(0,0,e.content.appendChild(Pa(a.display.measure))),0==f?(b.measure.map=e.map,b.measure.cache={}):((b.measure.maps||(b.measure.maps=[])).push(e.map),(b.measure.caches||(b.measure.caches=[])).push({}))}if(ig){var k=e.content.lastChild;(/\bcm-tab\b/.test(k.className)||k.querySelector&&k.querySelector(".cm-tab"))&&(e.content.className="cm-tab-wrap-hack")}return Ea(a,"renderLine",a,b.line,e.pre),e.pre.className&&(e.textClass=h(e.pre.className,e.textClass||"")),e}function nb(a){var b=d("span","•","cm-invalidchar");return b.title="\\u"+a.charCodeAt(0).toString(16),b.setAttribute("aria-label",b.title),b}function ob(a,b,c,e,f,g,h){if(b){var i,j=a.splitSpaces?pb(b,a.trailingSpace):b,k=a.cm.state.specialChars,l=!1;if(k.test(b)){i=document.createDocumentFragment();for(var m=0;;){k.lastIndex=m;var n=k.exec(b),p=n?n.index-m:b.length-m;if(p){var q=document.createTextNode(j.slice(m,m+p));gg&&hg<9?i.appendChild(d("span",[q])):i.appendChild(q),a.map.push(a.pos,a.pos+p,q),a.col+=p,a.pos+=p}if(!n)break;m+=p+1;var r=void 0;if("\t"==n[0]){var s=a.cm.options.tabSize,t=s-a.col%s;r=i.appendChild(d("span",o(t),"cm-tab")),r.setAttribute("role","presentation"),r.setAttribute("cm-text","\t"),a.col+=t}else"\r"==n[0]||"\n"==n[0]?(r=i.appendChild(d("span","\r"==n[0]?"␍":"␤","cm-invalidchar")),r.setAttribute("cm-text",n[0]),a.col+=1):(r=a.cm.options.specialCharPlaceholder(n[0]),r.setAttribute("cm-text",n[0]),gg&&hg<9?i.appendChild(d("span",[r])):i.appendChild(r),a.col+=1);a.map.push(a.pos,a.pos+1,r),a.pos++}}else a.col+=b.length,i=document.createTextNode(j),a.map.push(a.pos,a.pos+b.length,i),gg&&hg<9&&(l=!0),a.pos+=b.length;if(a.trailingSpace=32==j.charCodeAt(b.length-1),c||e||f||l||h){var u=c||"";e&&(u+=e),f&&(u+=f);var v=d("span",[i],u,h);return g&&(v.title=g),a.content.appendChild(v)}a.content.appendChild(i)}}function pb(a,b){if(a.length>1&&!/ /.test(a))return a;for(var c=b,d="",e=0;ej&&l.from<=j));m++);if(l.to>=k)return a(c,d,e,f,g,h,i);a(c,d.slice(0,l.to-j),e,f,null,h,i),f=null,d=d.slice(l.to-j),j=l.to}}}function rb(a,b,c,d){var e=!d&&c.widgetNode;e&&a.map.push(a.pos,a.pos+b,e),!d&&a.cm.display.input.needsContentAttribute&&(e||(e=a.content.appendChild(document.createElement("span"))),e.setAttribute("cm-marker",c.id)),e&&(a.cm.display.input.setUneditable(e),a.content.appendChild(e)),a.pos+=b,a.trailingSpace=!1}function sb(a,b,c){var d=a.markedSpans,e=a.text,f=0;if(d)for(var g,h,i,j,k,l,m,n=e.length,o=0,p=1,q="",r=0;;){if(r==o){i=j=k=l=h="",m=null,r=1/0;for(var s=[],t=void 0,u=0;uo||w.collapsed&&v.to==o&&v.from==o)?(null!=v.to&&v.to!=o&&r>v.to&&(r=v.to,j=""),w.className&&(i+=" "+w.className),w.css&&(h=(h?h+";":"")+w.css),w.startStyle&&v.from==o&&(k+=" "+w.startStyle),w.endStyle&&v.to==r&&(t||(t=[])).push(w.endStyle,v.to),w.title&&!l&&(l=w.title),w.collapsed&&(!m||da(m.marker,w)<0)&&(m=v)):v.from>o&&r>v.from&&(r=v.from)}if(t)for(var x=0;x=n)break;for(var z=Math.min(n,r);;){if(q){var A=o+q.length;if(!m){var B=A>z?q.slice(0,z-o):q;b.addToken(b,B,g?g+i:i,k,o+B.length==r?j:"",l,h)}if(A>=z){q=q.slice(z-o),o=z;break}o=A,k=""}q=e.slice(f,f=c[p++]),g=lb(c[p++],b.cm.options)}}else for(var C=1;C2&&f.push((i.bottom+j.top)/2-c.top)}}f.push(c.bottom-c.top)}}function Vb(a,b,c){if(a.line==b)return{map:a.measure.map,cache:a.measure.cache};for(var d=0;dc)return{map:a.measure.maps[e],cache:a.measure.caches[e],before:!0}}function Wb(a,b){b=ia(b);var d=D(b),e=a.display.externalMeasured=new tb(a.doc,b,d);e.lineN=d;var f=e.built=mb(a,e);return e.text=f.pre,c(a.display.lineMeasure,f.pre),e}function Xb(a,b,c,d){return $b(a,Zb(a,b),c,d)}function Yb(a,b){if(b>=a.display.viewFrom&&b=c.lineN&&bb)&&(f=i-h,e=f-1,b>=i&&(g="right")),null!=e){if(d=a[j+2],h==i&&c==(d.insertLeft?"left":"right")&&(g=c),"left"==c&&0==e)for(;j&&a[j-2]==a[j-3]&&a[j-1].insertLeft;)d=a[(j-=3)+2],g="left";if("right"==c&&e==i-h)for(;j=0&&(c=a[e]).left==c.right;e--);return c}function bc(a,b,c,d){var e,f=_b(b.map,c,d),g=f.node,h=f.start,i=f.end,j=f.collapse;if(3==g.nodeType){for(var k=0;k<4;k++){for(;h&&x(b.line.text.charAt(f.coverStart+h));)--h;for(;f.coverStart+i0&&(j=d="right");var l;e=a.options.lineWrapping&&(l=g.getClientRects()).length>1?l["right"==d?l.length-1:0]:g.getBoundingClientRect()}if(gg&&hg<9&&!h&&(!e||!e.left&&!e.right)){var m=g.parentNode.getClientRects()[0];e=m?{left:m.left,right:m.left+rc(a.display),top:m.top,bottom:m.bottom}:ch}for(var n=e.top-b.rect.top,o=e.bottom-b.rect.top,p=(n+o)/2,q=b.view.measure.heights,r=0;rc.from?g(a-1):g(a,d)}d=d||z(a.doc,b.line),e||(e=Zb(a,d));var i=Ba(d),j=b.ch;if(!i)return g(j);var k=xa(i,j),l=h(j,k);return null!=Mg&&(l.other=h(j,Mg)),l}function mc(a,b){var c=0;b=N(a.doc,b),a.options.lineWrapping||(c=rc(a.display)*b.ch);var d=z(a.doc,b.line),e=oa(d)+Ob(a.display);return{left:c,right:c,top:e,bottom:e+d.height}}function nc(a,b,c,d){var e=H(a,b);return e.xRel=d,c&&(e.outside=!0),e}function oc(a,b,c){var d=a.doc;if(c+=a.display.viewOffset,c<0)return nc(d.first,0,!0,-1);var e=E(d,c),f=d.first+d.size-1;if(e>f)return nc(d.first+d.size-1,z(d,f).text.length,!0,1);b<0&&(b=0);for(var g=z(d,e);;){var h=pc(a,g,e,b,c),i=ga(g),j=i&&i.find(0,!0);if(!i||!(h.ch>j.from.ch||h.ch==j.from.ch&&h.xRel>0))return h;e=D(g=j.to.line)}}function pc(a,b,c,d,e){function f(d){var e=lc(a,H(c,d),"line",b,j);return h=!0,g>e.bottom?e.left-i:gq)return nc(c,n,r,1);for(;;){if(k?n==m||n==za(b,m,1):n-m<=1){var s=d0&&s1){var v=$b(a,j,s,"right");g<=v.bottom&&g>=v.top&&Math.abs(d-v.right)1?1:0);return w}var y=Math.ceil(l/2),z=m+y;if(k){z=m;for(var A=0;Ad?(n=z,q=B,(r=h)&&(q+=1e3),l=y):(m=z,o=B,p=h,l-=y)}}function qc(a){if(null!=a.cachedTextHeight)return a.cachedTextHeight;if(null==Zg){Zg=d("pre");for(var e=0;e<49;++e)Zg.appendChild(document.createTextNode("x")),Zg.appendChild(d("br"));Zg.appendChild(document.createTextNode("x"))}c(a.measure,Zg);var f=Zg.offsetHeight/50;return f>3&&(a.cachedTextHeight=f),b(a.measure),f||1}function rc(a){if(null!=a.cachedCharWidth)return a.cachedCharWidth;var b=d("span","xxxxxxxxxx"),e=d("pre",[b]);c(a.measure,e);var f=b.getBoundingClientRect(),g=(f.right-f.left)/10;return g>2&&(a.cachedCharWidth=g),g||10}function sc(a){for(var b=a.display,c={},d={},e=b.gutters.clientLeft,f=b.gutters.firstChild,g=0;f;f=f.nextSibling,++g)c[a.options.gutters[g]]=f.offsetLeft+f.clientLeft+e,d[a.options.gutters[g]]=f.clientWidth;return{fixedPos:tc(b),gutterTotalWidth:b.gutters.offsetWidth,gutterLeft:c,gutterWidth:d,wrapperWidth:b.wrapper.clientWidth}}function tc(a){return a.scroller.getBoundingClientRect().left-a.sizer.getBoundingClientRect().left}function uc(a){var b=qc(a.display),c=a.options.lineWrapping,d=c&&Math.max(5,a.display.scroller.clientWidth/rc(a.display)-3);return function(e){if(ma(a.doc,e))return 0;var f=0;if(e.widgets)for(var g=0;g=a.display.viewTo)return null;if(b-=a.display.viewFrom,b<0)return null;for(var c=a.display.view,d=0;d=a.display.viewTo||h.to().line3&&(e(n,p.top,null,p.bottom),n=k,p.bottomi.bottom||j.bottom==i.bottom&&j.right>i.right)&&(i=j),n0?b.blinker=setInterval(function(){return b.cursorDiv.style.visibility=(c=!c)?"":"hidden"},a.options.cursorBlinkRate):a.options.cursorBlinkRate<0&&(b.cursorDiv.style.visibility="hidden")}}function Dc(a){a.state.focused||(a.display.input.focus(),Fc(a))}function Ec(a){a.state.delayingBlurEvent=!0,setTimeout(function(){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1,Gc(a))},100)}function Fc(a,b){a.state.delayingBlurEvent&&(a.state.delayingBlurEvent=!1),"nocursor"!=a.options.readOnly&&(a.state.focused||(Ea(a,"focus",a,b),a.state.focused=!0,g(a.display.wrapper,"CodeMirror-focused"),a.curOp||a.display.selForContextMenu==a.doc.sel||(a.display.input.reset(),ig&&setTimeout(function(){return a.display.input.reset(!0)},20)),a.display.input.receivedFocus()),Cc(a))}function Gc(a,b){a.state.delayingBlurEvent||(a.state.focused&&(Ea(a,"blur",a,b),a.state.focused=!1,yg(a.display.wrapper,"CodeMirror-focused")),clearInterval(a.display.blinker),setTimeout(function(){a.state.focused||(a.display.shift=!1)},150))}function Hc(a){var b=a.display,c=b.view;if(b.alignWidgets||b.gutters.firstChild&&a.options.fixedGutter){for(var d=tc(b)-b.scroller.scrollLeft+a.doc.scrollLeft,e=b.gutters.offsetWidth,f=d+"px",g=0;g.001||i<-.001)&&(C(e.line,f),Kc(e.line),e.rest))for(var j=0;j=g&&(f=E(b,oa(z(b,i))-a.wrapper.clientHeight),g=i)}return{from:f,to:Math.max(g,f+1)}}function Mc(a,b){Math.abs(a.doc.scrollTop-b)<2||(a.doc.scrollTop=b,dg||Ad(a,{top:b}),a.display.scroller.scrollTop!=b&&(a.display.scroller.scrollTop=b),a.display.scrollbars.setScrollTop(b),dg&&Ad(a),ud(a,100))}function Nc(a,b,c){(c?b==a.doc.scrollLeft:Math.abs(a.doc.scrollLeft-b)<2)||(b=Math.min(b,a.display.scroller.scrollWidth-a.display.scroller.clientWidth),a.doc.scrollLeft=b,Hc(a),a.display.scroller.scrollLeft!=b&&(a.display.scroller.scrollLeft=b),a.display.scrollbars.setScrollLeft(b))}function Oc(a){var b=a.wheelDeltaX,c=a.wheelDeltaY;return null==b&&a.detail&&a.axis==a.HORIZONTAL_AXIS&&(b=a.detail),null==c&&a.detail&&a.axis==a.VERTICAL_AXIS?c=a.detail:null==c&&(c=a.wheelDelta),{x:b,y:c}}function Pc(a){var b=Oc(a);return b.x*=eh,b.y*=eh,b}function Qc(a,b){var c=Oc(b),d=c.x,e=c.y,f=a.display,g=f.scroller,h=g.scrollWidth>g.clientWidth,i=g.scrollHeight>g.clientHeight;if(d&&h||e&&i){if(e&&rg&&ig)a:for(var j=b.target,k=f.view;j!=g;j=j.parentNode)for(var l=0;l(window.innerHeight||document.documentElement.clientHeight)&&(f=!1),null!=f&&!og){var g=d("div","​",null,"position: absolute;\n top: "+(b.top-c.viewOffset-Ob(a.display))+"px;\n height: "+(b.bottom-b.top+Rb(a)+c.barHeight)+"px;\n left: "+b.left+"px; width: 2px;");a.display.lineSpace.appendChild(g),g.scrollIntoView(f),a.display.lineSpace.removeChild(g)}}}function Yc(a,b,c,d){null==d&&(d=0);for(var e,f=0;f<5;f++){var g=!1;e=lc(a,b);var h=c&&c!=b?lc(a,c):e,i=$c(a,Math.min(e.left,h.left),Math.min(e.top,h.top)-d,Math.max(e.left,h.left),Math.max(e.bottom,h.bottom)+d),j=a.doc.scrollTop,k=a.doc.scrollLeft;if(null!=i.scrollTop&&(Mc(a,i.scrollTop),Math.abs(a.doc.scrollTop-j)>1&&(g=!0)),null!=i.scrollLeft&&(Nc(a,i.scrollLeft),Math.abs(a.doc.scrollLeft-k)>1&&(g=!0)),!g)break}return e}function Zc(a,b,c,d,e){var f=$c(a,b,c,d,e);null!=f.scrollTop&&Mc(a,f.scrollTop),null!=f.scrollLeft&&Nc(a,f.scrollLeft)}function $c(a,b,c,d,e){var f=a.display,g=qc(a.display);c<0&&(c=0);var h=a.curOp&&null!=a.curOp.scrollTop?a.curOp.scrollTop:f.scroller.scrollTop,i=Tb(a),j={};e-c>i&&(e=c+i);var k=a.doc.height+Pb(f),l=ck-g;if(ch+i){var n=Math.min(c,(m?k:e)-i);n!=h&&(j.scrollTop=n)}var o=a.curOp&&null!=a.curOp.scrollLeft?a.curOp.scrollLeft:f.scroller.scrollLeft,p=Sb(a)-(a.options.fixedGutter?f.gutters.offsetWidth:0),q=d-b>p;return q&&(d=b+p),b<10?j.scrollLeft=0:bp+o-3&&(j.scrollLeft=d+(q?0:10)-p),j}function _c(a,b,c){null==b&&null==c||bd(a),null!=b&&(a.curOp.scrollLeft=(null==a.curOp.scrollLeft?a.doc.scrollLeft:a.curOp.scrollLeft)+b),null!=c&&(a.curOp.scrollTop=(null==a.curOp.scrollTop?a.doc.scrollTop:a.curOp.scrollTop)+c)}function ad(a){bd(a);var b=a.getCursor(),c=b,d=b;a.options.lineWrapping||(c=b.ch?H(b.line,b.ch-1):b,d=H(b.line,b.ch+1)),a.curOp.scrollToPos={from:c,to:d,margin:a.options.cursorScrollMargin,isCursor:!0}}function bd(a){var b=a.curOp.scrollToPos;if(b){a.curOp.scrollToPos=null;var c=mc(a,b.from),d=mc(a,b.to),e=$c(a,Math.min(c.left,d.left),Math.min(c.top,d.top)-b.margin,Math.max(c.right,d.right),Math.max(c.bottom,d.bottom)+b.margin);a.scrollTo(e.scrollLeft,e.scrollTop)}}function cd(a){a.curOp={cm:a,viewChanged:!1,startHeight:a.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:++gh},vb(a.curOp)}function dd(a){var b=a.curOp;xb(b,function(a){for(var b=0;b=c.viewTo)||c.maxLineChanged&&b.options.lineWrapping,a.update=a.mustUpdate&&new wd(b,a.mustUpdate&&{top:a.scrollTop,ensure:a.scrollToPos},a.forceUpdate)}function gd(a){a.updatedDisplay=a.mustUpdate&&yd(a.cm,a.update)}function hd(a){var b=a.cm,c=b.display;a.updatedDisplay&&Jc(b),a.barMeasure=Rc(b),c.maxLineChanged&&!b.options.lineWrapping&&(a.adjustWidthTo=Xb(b,c.maxLine,c.maxLine.text.length).left+3,b.display.sizerWidth=a.adjustWidthTo,a.barMeasure.scrollWidth=Math.max(c.scroller.clientWidth,c.sizer.offsetLeft+a.adjustWidthTo+Rb(b)+b.display.barWidth),a.maxScrollLeft=Math.max(0,c.sizer.offsetLeft+a.adjustWidthTo-Sb(b))),(a.updatedDisplay||a.selectionChanged)&&(a.preparedSelection=c.input.prepareSelection(a.focus))}function id(a){var b=a.cm;null!=a.adjustWidthTo&&(b.display.sizer.style.minWidth=a.adjustWidthTo+"px",a.maxScrollLeftb)&&(e.updateLineNumbers=b),a.curOp.viewChanged=!0,b>=e.viewTo)Lg&&ka(a.doc,b)e.viewFrom?qd(a):(e.viewFrom+=d,e.viewTo+=d);else if(b<=e.viewFrom&&c>=e.viewTo)qd(a);else if(b<=e.viewFrom){var f=rd(a,c,c+d,1);f?(e.view=e.view.slice(f.index),e.viewFrom=f.lineN,e.viewTo+=d):qd(a)}else if(c>=e.viewTo){var g=rd(a,b,b,-1);g?(e.view=e.view.slice(0,g.index),e.viewTo=g.lineN):qd(a)}else{var h=rd(a,b,b,-1),i=rd(a,c,c+d,1);h&&i?(e.view=e.view.slice(0,h.index).concat(ub(a,h.lineN,i.lineN)).concat(e.view.slice(i.index)),e.viewTo+=d):qd(a)}var j=e.externalMeasured;j&&(c=e.lineN&&b=d.viewTo)){var f=d.view[xc(a,b)];if(null!=f.node){var g=f.changes||(f.changes=[]);m(g,c)==-1&&g.push(c)}}}function qd(a){a.display.viewFrom=a.display.viewTo=a.doc.first,a.display.view=[],a.display.viewOffset=0}function rd(a,b,c,d){var e,f=xc(a,b),g=a.display.view;if(!Lg||c==a.doc.first+a.doc.size)return{index:f,lineN:c};for(var h=a.display.viewFrom,i=0;i0){if(f==g.length-1)return null;e=h+g[f].size-b,f++}else e=h-b;b+=e,c+=e}for(;ka(a.doc,c)!=c;){if(f==(d<0?0:g.length-1))return null;c+=d*g[f-(d<0?1:0)].size,f+=d}return{index:f,lineN:c}}function sd(a,b,c){var d=a.display,e=d.view;0==e.length||b>=d.viewTo||c<=d.viewFrom?(d.view=ub(a,b,c),d.viewFrom=b):(d.viewFrom>b?d.view=ub(a,b,d.viewFrom).concat(d.view):d.viewFromc&&(d.view=d.view.slice(0,xc(a,c)))),d.viewTo=c}function td(a){for(var b=a.display.view,c=0,d=0;d=a.display.viewTo)){var c=+new Date+a.options.workTime,d=Xa(b.mode,ab(a,b.frontier)),e=[];b.iter(b.frontier,Math.min(b.first+b.size,a.display.viewTo+500),function(f){if(b.frontier>=a.display.viewFrom){var g=f.styles,h=f.text.length>a.options.maxHighlightLength,i=$a(a,f,h?Xa(b.mode,d):d,!0);f.styles=i.styles;var j=f.styleClasses,k=i.classes;k?f.styleClasses=k:j&&(f.styleClasses=null);for(var l=!g||g.length!=f.styles.length||j!=k&&(!j||!k||j.bgClass!=k.bgClass||j.textClass!=k.textClass),m=0;!l&&mc)return ud(a,a.options.workDelay),!0}),e.length&&kd(a,function(){for(var b=0;b=d.viewFrom&&c.visible.to<=d.viewTo&&(null==d.updateLineNumbers||d.updateLineNumbers>=d.viewTo)&&d.renderedView==d.view&&0==td(a))return!1;Ic(a)&&(qd(a),c.dims=sc(a));var g=e.first+e.size,h=Math.max(c.visible.from-a.options.viewportMargin,e.first),i=Math.min(g,c.visible.to+a.options.viewportMargin);d.viewFromi&&d.viewTo-i<20&&(i=Math.min(g,d.viewTo)),Lg&&(h=ka(a.doc,h),i=la(a.doc,i));var j=h!=d.viewFrom||i!=d.viewTo||d.lastWrapHeight!=c.wrapperHeight||d.lastWrapWidth!=c.wrapperWidth;sd(a,h,i),d.viewOffset=oa(z(a.doc,d.viewFrom)),a.display.mover.style.top=d.viewOffset+"px";var k=td(a);if(!j&&0==k&&!c.force&&d.renderedView==d.view&&(null==d.updateLineNumbers||d.updateLineNumbers>=d.viewTo))return!1; -var l=f();return k>4&&(d.lineDiv.style.display="none"),Bd(a,d.updateLineNumbers,c.dims),k>4&&(d.lineDiv.style.display=""),d.renderedView=d.view,l&&f()!=l&&l.offsetHeight&&l.focus(),b(d.cursorDiv),b(d.selectionDiv),d.gutters.style.height=d.sizer.style.minHeight=0,j&&(d.lastWrapHeight=c.wrapperHeight,d.lastWrapWidth=c.wrapperWidth,ud(a,400)),d.updateLineNumbers=null,!0}function zd(a,b){for(var c=b.viewport,d=!0;(d&&a.options.lineWrapping&&b.oldDisplayWidth!=Sb(a)||(c&&null!=c.top&&(c={top:Math.min(a.doc.height+Pb(a.display)-Tb(a),c.top)}),b.visible=Lc(a.display,a.doc,c),!(b.visible.from>=a.display.viewFrom&&b.visible.to<=a.display.viewTo)))&&yd(a,b);d=!1){Jc(a);var e=Rc(a);yc(a),Uc(a,e),Dd(a,e)}b.signal(a,"update",a),a.display.viewFrom==a.display.reportedViewFrom&&a.display.viewTo==a.display.reportedViewTo||(b.signal(a,"viewportChange",a,a.display.viewFrom,a.display.viewTo),a.display.reportedViewFrom=a.display.viewFrom,a.display.reportedViewTo=a.display.viewTo)}function Ad(a,b){var c=new wd(a,b);if(yd(a,c)){Jc(a),zd(a,c);var d=Rc(a);yc(a),Uc(a,d),Dd(a,d),c.finish()}}function Bd(a,c,d){function e(b){var c=b.nextSibling;return ig&&rg&&a.display.currentWheelTarget==b?b.style.display="none":b.parentNode.removeChild(b),c}for(var f=a.display,g=a.options.lineNumbers,h=f.lineDiv,i=h.firstChild,j=f.view,k=f.viewFrom,l=0;l-1&&(o=!1),Ab(a,n,k,d)),o&&(b(n.lineNumber),n.lineNumber.appendChild(document.createTextNode(G(a.options,k)))),i=n.node.nextSibling}else{var p=Ib(a,n,k,d);h.insertBefore(p,i)}k+=n.size}for(;i;)i=e(i)}function Cd(a){var b=a.display.gutters.offsetWidth;a.display.sizer.style.marginLeft=b+"px"}function Dd(a,b){a.display.sizer.style.minHeight=b.docHeight+"px",a.display.heightForcer.style.top=b.docHeight+"px",a.display.gutters.style.height=b.docHeight+a.display.barHeight+Rb(a)+"px"}function Ed(a){var c=a.display.gutters,e=a.options.gutters;b(c);for(var f=0;f-1&&!a.lineNumbers&&(a.gutters=a.gutters.slice(0),a.gutters.splice(b,1))}function Gd(a,b){this.ranges=a,this.primIndex=b}function Hd(a,b){this.anchor=a,this.head=b}function Id(a,b){var c=a[b];a.sort(function(a,b){return I(a.from(),b.from())}),b=m(a,c);for(var d=1;d=0){var g=L(f.from(),e.from()),h=K(f.to(),e.to()),i=f.empty()?e.from()==e.head:f.from()==f.head;d<=b&&--b,a.splice(--d,2,new Hd(i?h:g,i?g:h))}}return new Gd(a,b)}function Jd(a,b){return new Gd([new Hd(a,b||a)],0)}function Kd(a){return a.text?H(a.from.line+a.text.length-1,p(a.text).length+(1==a.text.length?a.from.ch:0)):a.to}function Ld(a,b){if(I(a,b.from)<0)return a;if(I(a,b.to)<=0)return Kd(b);var c=a.line+b.text.length-(b.to.line-b.from.line)-1,d=a.ch;return a.line==b.to.line&&(d+=Kd(b).ch-b.to.ch),H(c,d)}function Md(a,b){for(var c=[],d=0;d1&&a.remove(h.line+1,o-1),a.insert(h.line+1,s)}yb(a,"change",a,b)}function Td(a,b,c){function d(a,e,f){if(a.linked)for(var g=0;g1&&!a.done[a.done.length-2].ranges?(a.done.pop(),p(a.done)):void 0}function Zd(a,b,c,d){var e=a.history;e.undone.length=0;var f,g,h=+new Date;if((e.lastOp==d||e.lastOrigin==b.origin&&b.origin&&("+"==b.origin.charAt(0)&&a.cm&&e.lastModTime>h-a.cm.options.historyEventDelay||"*"==b.origin.charAt(0)))&&(f=Yd(e,e.lastOp==d)))g=p(f.changes),0==I(b.from,b.to)&&0==I(b.from,g.to)?g.to=Kd(b):f.changes.push(Wd(a,b));else{var i=p(e.done);for(i&&i.ranges||ae(a.sel,e.done),f={changes:[Wd(a,b)],generation:e.generation},e.done.push(f);e.done.length>e.undoDepth;)e.done.shift(),e.done[0].ranges||e.done.shift()}e.done.push(c),e.generation=++e.maxGeneration,e.lastModTime=e.lastSelTime=h,e.lastOp=e.lastSelOp=d,e.lastOrigin=e.lastSelOrigin=b.origin,g||Ea(a,"historyAdded")}function $d(a,b,c,d){var e=b.charAt(0);return"*"==e||"+"==e&&c.ranges.length==d.ranges.length&&c.somethingSelected()==d.somethingSelected()&&new Date-a.history.lastSelTime<=(a.cm?a.cm.options.historyEventDelay:500)}function _d(a,b,c,d){var e=a.history,f=d&&d.origin;c==e.lastSelOp||f&&e.lastSelOrigin==f&&(e.lastModTime==e.lastSelTime&&e.lastOrigin==f||$d(a,f,p(e.done),b))?e.done[e.done.length-1]=b:ae(b,e.done),e.lastSelTime=+new Date,e.lastSelOrigin=f,e.lastSelOp=c,d&&d.clearRedo!==!1&&Xd(e.undone)}function ae(a,b){var c=p(b);c&&c.ranges&&c.equals(a)||b.push(a)}function be(a,b,c,d){var e=b["spans_"+a.id],f=0;a.iter(Math.max(a.first,c),Math.min(a.first+a.size,d),function(c){c.markedSpans&&((e||(e=b["spans_"+a.id]={}))[f]=c.markedSpans),++f})}function ce(a){if(!a)return null;for(var b,c=0;c-1&&(p(h)[l]=j[l],delete j[l])}}}return d}function ge(a,b,c,d){if(a.cm&&a.cm.display.shift||a.extend){var e=b.anchor;if(d){var f=I(c,e)<0;f!=I(d,e)<0?(e=c,c=d):f!=I(c,d)<0&&(c=d)}return new Hd(e,c)}return new Hd(d||c,c)}function he(a,b,c,d){ne(a,new Gd([ge(a,a.sel.primary(),b,c)],0),d)}function ie(a,b,c){for(var d=[],e=0;e=b.ch:h.to>b.ch))){if(e&&(Ea(i,"beforeCursorEnter"),i.explicitlyCleared)){if(f.markedSpans){--g;continue}break}if(!i.atomic)continue;if(c){var j=i.find(d<0?1:-1),k=void 0;if((d<0?i.inclusiveRight:i.inclusiveLeft)&&(j=ue(a,j,-d,j&&j.line==b.line?f:null)),j&&j.line==b.line&&(k=I(j,c))&&(d<0?k<0:k>0))return se(a,j,b,d,e)}var l=i.find(d<0?-1:1);return(d<0?i.inclusiveLeft:i.inclusiveRight)&&(l=ue(a,l,d,l.line==b.line?f:null)),l?se(a,l,b,d,e):null}}return b}function te(a,b,c,d,e){var f=d||1,g=se(a,b,c,f,e)||!e&&se(a,b,c,f,!0)||se(a,b,c,-f,e)||!e&&se(a,b,c,-f,!0);return g?g:(a.cantEdit=!0,H(a.first,0))}function ue(a,b,c,d){return c<0&&0==b.ch?b.line>a.first?N(a,H(b.line-1)):null:c>0&&b.ch==(d||z(a,b.line)).text.length?b.line=0;--e)ye(a,{from:d[e].from,to:d[e].to,text:e?[""]:b.text});else ye(a,b)}}function ye(a,b){if(1!=b.text.length||""!=b.text[0]||0!=I(b.from,b.to)){var c=Md(a,b);Zd(a,b,c,a.cm?a.cm.curOp.id:NaN),Be(a,b,c,Y(a,b));var d=[];Td(a,function(a,c){c||m(d,a.history)!=-1||(Ge(a.history,b),d.push(a.history)),Be(a,b,null,Y(a,b))})}}function ze(a,b,c){if(!a.cm||!a.cm.state.suppressEdits||c){for(var d,e=a.history,f=a.sel,g="undo"==b?e.done:e.undone,h="undo"==b?e.undone:e.done,i=0;i=0;--n){var o=l(n);if(o)return o.v}}}}function Ae(a,b){if(0!=b&&(a.first+=b,a.sel=new Gd(q(a.sel.ranges,function(a){return new Hd(H(a.anchor.line+b,a.anchor.ch),H(a.head.line+b,a.head.ch))}),a.sel.primIndex),a.cm)){od(a.cm,a.first,a.first-b,b);for(var c=a.cm.display,d=c.viewFrom;da.lastLine())){if(b.from.linef&&(b={from:b.from,to:H(f,z(a,f).text.length),text:[b.text[0]],origin:b.origin}),b.removed=A(a,b.from,b.to),c||(c=Md(a,b)),a.cm?Ce(a.cm,b,d):Sd(a,b,d),oe(a,c,Eg)}}function Ce(a,b,c){var d=a.doc,e=a.display,f=b.from,g=b.to,h=!1,i=f.line;a.options.lineWrapping||(i=D(ia(z(d,f.line))),d.iter(i,g.line+1,function(a){if(a==e.maxLine)return h=!0,!0})),d.sel.contains(b.from,b.to)>-1&&Ga(a),Sd(d,b,c,uc(a)),a.options.lineWrapping||(d.iter(i,f.line+b.text.length,function(a){var b=pa(a);b>e.maxLineLength&&(e.maxLine=a,e.maxLineLength=b,e.maxLineChanged=!0,h=!1)}),h&&(a.curOp.updateMaxLine=!0)),d.frontier=Math.min(d.frontier,f.line),ud(a,400);var j=b.text.length-(g.line-f.line)-1;b.full?od(a):f.line!=g.line||1!=b.text.length||Rd(a.doc,b)?od(a,f.line,g.line+1,j):pd(a,f.line,"text");var k=Ha(a,"changes"),l=Ha(a,"change");if(l||k){var m={from:f,to:g,text:b.text,removed:b.removed,origin:b.origin};l&&yb(a,"change",a,m),k&&(a.curOp.changeObjs||(a.curOp.changeObjs=[])).push(m)}a.display.selForContextMenu=null}function De(a,b,c,d,e){if(d||(d=c),I(d,c)<0){var f=d;d=c,c=f}"string"==typeof b&&(b=a.splitLines(b)),xe(a,{from:c,to:d,text:b,origin:e})}function Ee(a,b,c,d){c0||0==h&&g.clearWhenEmpty!==!1)return g;if(g.replacedWith&&(g.collapsed=!0,g.widgetNode=d("span",[g.replacedWith],"CodeMirror-widget"),e.handleMouseEvents||g.widgetNode.setAttribute("cm-ignore-events","true"),e.insertLeft&&(g.widgetNode.insertLeft=!0)),g.collapsed){if(ha(a,b.line,b,c,g)||b.line!=c.line&&ha(a,c.line,b,c,g))throw new Error("Inserting collapsed marker partially overlapping an existing one");R()}g.addToHistory&&Zd(a,{from:b,to:c,origin:"markText"},a.sel,NaN);var i,k=b.line,l=a.cm;if(a.iter(k,c.line+1,function(a){l&&g.collapsed&&!l.options.lineWrapping&&ia(a)==l.display.maxLine&&(i=!0),g.collapsed&&k!=b.line&&C(a,0),V(a,new S(g,k==b.line?b.ch:null,k==c.line?c.ch:null)),++k}),g.collapsed&&a.iter(b.line,c.line+1,function(b){ma(a,b)&&C(b,0)}),g.clearOnEnter&&Pg(g,"beforeCursorEnter",function(){return g.clear()}),g.readOnly&&(Q(),(a.history.done.length||a.history.undone.length)&&a.clearHistory()),g.collapsed&&(g.id=++hh,g.atomic=!0),l){if(i&&(l.curOp.updateMaxLine=!0),g.collapsed)od(l,b.line,c.line+1);else if(g.className||g.title||g.startStyle||g.endStyle||g.css)for(var m=b.line;m<=c.line;m++)pd(l,m,"text");g.atomic&&qe(l.doc),yb(l,"markerAdded",l,g)}return g}function Pe(a,b){var c=this;this.markers=a,this.primary=b;for(var d=0;d-1)return b.state.draggingText(a),void setTimeout(function(){return b.display.input.focus()},20);try{var j=a.dataTransfer.getData("Text");if(j){var k;if(b.state.draggingText&&!b.state.draggingText.copy&&(k=b.listSelections()),oe(b.doc,Jd(c,c)),k)for(var l=0;l=0;b--)De(a.doc,"",d[b].from,d[b].to,"+delete");ad(a)})}function hf(a,b){var c=z(a.doc,b),d=ia(c);d!=c&&(b=D(d));var e=Ba(d),f=e?e[0].level%2?va(d):ua(d):0;return H(b,f)}function jf(a,b){for(var c,d=z(a.doc,b);c=ga(d);)d=c.find(1,!0).line,b=null;var e=Ba(d),f=e?e[0].level%2?ua(d):va(d):d.text.length;return H(null==b?D(d):b,f)}function kf(a,b){var c=hf(a,b.line),d=z(a.doc,c.line),e=Ba(d);if(!e||0==e[0].level){var f=Math.max(0,d.text.search(/\S/)),g=b.line==c.line&&b.ch<=f&&b.ch;return H(c.line,g?0:f)}return c}function lf(a,b,c){if("string"==typeof b&&(b=th[b],!b))return!1;a.display.input.ensurePolled();var d=a.display.shift,e=!1;try{a.isReadOnly()&&(a.state.suppressEdits=!0),c&&(a.display.shift=!1),e=b(a)!=Dg}finally{a.display.shift=d,a.state.suppressEdits=!1}return e}function mf(a,b,c){for(var d=0;de-400&&0==I(sh.pos,c)?d="triple":rh&&rh.time>e-400&&0==I(rh.pos,c)?(d="double",sh={time:e,pos:c}):(d="single",rh={time:e,pos:c});var g,h=a.doc.sel,j=rg?b.metaKey:b.ctrlKey;a.options.dragDrop&&Qg&&!a.isReadOnly()&&"single"==d&&(g=h.contains(c))>-1&&(I((g=h.ranges[g]).from(),c)<0||c.xRel>0)&&(I(g.to(),c)>0||c.xRel<0)?wf(a,b,c,j):xf(a,b,c,d,j)}function wf(a,b,c,d){var e=a.display,f=+new Date,g=ld(a,function(h){ig&&(e.scroller.draggable=!1),a.state.draggingText=!1,Da(document,"mouseup",g),Da(e.scroller,"drop",g),Math.abs(b.clientX-h.clientX)+Math.abs(b.clientY-h.clientY)<10&&(Ja(h),!d&&+new Date-200u&&e.push(new Hd(H(q,u),H(q,n(s,j,f))))}e.length||e.push(new Hd(c,c)),ne(l,Id(p.ranges.slice(0,o).concat(e),o),{origin:"*mouse",scroll:!1}),a.scrollIntoView(b)}else{var v=m,w=v.anchor,x=b;if("single"!=d){var y;y="double"==d?a.findWordAt(b):new Hd(H(b.line,0),N(l,H(b.line+1,0))),I(y.anchor,w)>0?(x=y.head,w=L(v.from(),y.anchor)):(x=y.anchor,w=K(v.to(),y.head))}var A=p.ranges.slice(0);A[o]=new Hd(N(l,w),x),ne(l,Id(A,o),Fg)}}function h(b){var c=++v,e=wc(a,b,!0,"rect"==d);if(e)if(0!=I(e,t)){a.curOp.focus=f(),g(e);var i=Lc(j,l);(e.line>=i.to||e.lineu.bottom?20:0;k&&setTimeout(ld(a,function(){v==c&&(j.scroller.scrollTop+=k,h(b))}),50)}}function i(b){a.state.selectingText=!1,v=1/0,Ja(b),j.input.focus(),Da(document,"mousemove",w),Da(document,"mouseup",x),l.history.lastSelOrigin=null}var j=a.display,l=a.doc;Ja(b);var m,o,p=l.sel,q=p.ranges;if(e&&!b.shiftKey?(o=l.sel.contains(c),m=o>-1?q[o]:new Hd(c,c)):(m=l.sel.primary(),o=l.sel.primIndex),sg?b.shiftKey&&b.metaKey:b.altKey)d="rect",e||(m=new Hd(c,c)),c=wc(a,b,!0,!0),o=-1;else if("double"==d){var r=a.findWordAt(c);m=a.display.shift||l.extend?ge(l,m,r.anchor,r.head):r}else if("triple"==d){var s=new Hd(H(c.line,0),N(l,H(c.line+1,0)));m=a.display.shift||l.extend?ge(l,m,s.anchor,s.head):s}else m=ge(l,m,c);e?o==-1?(o=q.length,ne(l,Id(q.concat([m]),o),{scroll:!1,origin:"*mouse"})):q.length>1&&q[o].empty()&&"single"==d&&!b.shiftKey?(ne(l,Id(q.slice(0,o).concat(q.slice(o+1)),0),{scroll:!1,origin:"*mouse"}),p=l.sel):je(l,o,m,Fg):(o=0,ne(l,new Gd([m],0),Fg),p=l.sel);var t=c,u=j.wrapper.getBoundingClientRect(),v=0,w=ld(a,function(a){Oa(a)?h(a):i(a)}),x=ld(a,i);a.state.selectingText=x,Pg(document,"mousemove",w),Pg(document,"mouseup",x)}function yf(a,b,c,d){var e,f;try{e=b.clientX,f=b.clientY}catch(b){return!1}if(e>=Math.floor(a.display.gutters.getBoundingClientRect().right))return!1;d&&Ja(b);var g=a.display,h=g.lineDiv.getBoundingClientRect();if(f>h.bottom||!Ha(a,c))return La(b);f-=h.top-g.viewOffset;for(var i=0;i=e){var k=E(a.doc,f),l=a.options.gutters[i];return Ea(a,c,a,k,l,b),La(b)}}}function zf(a,b){return yf(a,b,"gutterClick",!0)}function Af(a,b){Nb(a.display,b)||Bf(a,b)||Fa(a,b,"contextmenu")||a.display.input.onContextMenu(b)}function Bf(a,b){return!!Ha(a,"gutterContextMenu")&&yf(a,b,"gutterContextMenu",!1)}function Cf(a){a.display.wrapper.className=a.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+a.options.theme.replace(/(^|\s)\s*/g," cm-s-"),fc(a)}function Df(a){function b(b,d,e,f){a.defaults[b]=d,e&&(c[b]=f?function(a,b,c){c!=wh&&e(a,b,c)}:e)}var c=a.optionHandlers;a.defineOption=b,a.Init=wh,b("value","",function(a,b){return a.setValue(b)},!0),b("mode",null,function(a,b){a.doc.modeOption=b,Pd(a)},!0),b("indentUnit",2,Pd,!0),b("indentWithTabs",!1),b("smartIndent",!0),b("tabSize",4,function(a){Qd(a),fc(a),od(a)},!0),b("lineSeparator",null,function(a,b){if(a.doc.lineSep=b,b){var c=[],d=a.doc.first;a.doc.iter(function(a){for(var e=0;;){var f=a.text.indexOf(b,e);if(f==-1)break;e=f+b.length,c.push(H(d,f))}d++});for(var e=c.length-1;e>=0;e--)De(a.doc,b,c[e],H(c[e].line,c[e].ch+b.length))}}),b("specialChars",/[\u0000-\u001f\u007f\u00ad\u200b-\u200f\u2028\u2029\ufeff]/g,function(a,b,c){a.state.specialChars=new RegExp(b.source+(b.test("\t")?"":"|\t"),"g"),c!=wh&&a.refresh()}),b("specialCharPlaceholder",nb,function(a){return a.refresh()},!0),b("electricChars",!0),b("inputStyle",qg?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),b("spellcheck",!1,function(a,b){return a.getInputField().spellcheck=b},!0),b("rtlMoveVisually",!tg),b("wholeLineUpdateBefore",!0),b("theme","default",function(a){Cf(a),Ef(a)},!0),b("keyMap","default",function(a,b,c){var d=ff(b),e=c!=wh&&ff(c);e&&e.detach&&e.detach(a,d),d.attach&&d.attach(a,e||null)}),b("extraKeys",null),b("lineWrapping",!1,Gf,!0),b("gutters",[],function(a){Fd(a.options),Ef(a)},!0),b("fixedGutter",!0,function(a,b){a.display.gutters.style.left=b?tc(a.display)+"px":"0",a.refresh()},!0),b("coverGutterNextToScrollbar",!1,function(a){return Uc(a)},!0),b("scrollbarStyle","native",function(a){Wc(a),Uc(a),a.display.scrollbars.setScrollTop(a.doc.scrollTop),a.display.scrollbars.setScrollLeft(a.doc.scrollLeft)},!0),b("lineNumbers",!1,function(a){Fd(a.options),Ef(a)},!0),b("firstLineNumber",1,Ef,!0),b("lineNumberFormatter",function(a){ -return a},Ef,!0),b("showCursorWhenSelecting",!1,yc,!0),b("resetSelectionOnContextMenu",!0),b("lineWiseCopyCut",!0),b("readOnly",!1,function(a,b){"nocursor"==b?(Gc(a),a.display.input.blur(),a.display.disabled=!0):a.display.disabled=!1,a.display.input.readOnlyChanged(b)}),b("disableInput",!1,function(a,b){b||a.display.input.reset()},!0),b("dragDrop",!0,Ff),b("allowDropFileTypes",null),b("cursorBlinkRate",530),b("cursorScrollMargin",0),b("cursorHeight",1,yc,!0),b("singleCursorHeightPerLine",!0,yc,!0),b("workTime",100),b("workDelay",100),b("flattenSpans",!0,Qd,!0),b("addModeClass",!1,Qd,!0),b("pollInterval",100),b("undoDepth",200,function(a,b){return a.doc.history.undoDepth=b}),b("historyEventDelay",1250),b("viewportMargin",10,function(a){return a.refresh()},!0),b("maxHighlightLength",1e4,Qd,!0),b("moveInputWithCursor",!0,function(a,b){b||a.display.input.resetPosition()}),b("tabindex",null,function(a,b){return a.display.input.getField().tabIndex=b||""}),b("autofocus",null)}function Ef(a){Ed(a),od(a),setTimeout(function(){return Hc(a)},20)}function Ff(a,b,c){var d=c&&c!=wh;if(!b!=!d){var e=a.display.dragFunctions,f=b?Pg:Da;f(a.display.scroller,"dragstart",e.start),f(a.display.scroller,"dragenter",e.enter),f(a.display.scroller,"dragover",e.over),f(a.display.scroller,"dragleave",e.leave),f(a.display.scroller,"drop",e.drop)}}function Gf(a){a.options.lineWrapping?(g(a.display.wrapper,"CodeMirror-wrap"),a.display.sizer.style.minWidth="",a.display.sizerWidth=null):(yg(a.display.wrapper,"CodeMirror-wrap"),qa(a)),vc(a),od(a),fc(a),setTimeout(function(){return Uc(a)},100)}function Hf(a,b){var c=this;if(!(this instanceof Hf))return new Hf(a,b);this.options=b=b?j(b):{},j(xh,b,!1),Fd(b);var d=b.value;"string"==typeof d&&(d=new jh(d,b.mode,null,b.lineSeparator)),this.doc=d;var e=new Hf.inputStyles[b.inputStyle](this),f=this.display=new y(a,d,e);f.wrapper.CodeMirror=this,Ed(this),Cf(this),b.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),b.autofocus&&!qg&&f.input.focus(),Wc(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 l,keySeq:null,specialChars:null},gg&&hg<11&&setTimeout(function(){return c.display.input.reset(!0)},20),If(this),Ze(),cd(this),this.curOp.forceUpdate=!0,Ud(this,d),b.autofocus&&!qg||this.hasFocus()?setTimeout(i(Fc,this),20):Gc(this);for(var g in yh)yh.hasOwnProperty(g)&&yh[g](c,b[g],wh);Ic(this),b.finishInit&&b.finishInit(this);for(var h=0;h400}var e=a.display;Pg(e.scroller,"mousedown",ld(a,uf)),gg&&hg<11?Pg(e.scroller,"dblclick",ld(a,function(b){if(!Fa(a,b)){var c=wc(a,b);if(c&&!zf(a,b)&&!Nb(a.display,b)){Ja(b);var d=a.findWordAt(c);he(a.doc,d.anchor,d.head)}}})):Pg(e.scroller,"dblclick",function(b){return Fa(a,b)||Ja(b)}),xg||Pg(e.scroller,"contextmenu",function(b){return Af(a,b)});var f,g={end:0};Pg(e.scroller,"touchstart",function(b){if(!Fa(a,b)&&!c(b)){e.input.ensurePolled(),clearTimeout(f);var d=+new Date;e.activeTouch={start:d,moved:!1,prev:d-g.end<=300?g:null},1==b.touches.length&&(e.activeTouch.left=b.touches[0].pageX,e.activeTouch.top=b.touches[0].pageY)}}),Pg(e.scroller,"touchmove",function(){e.activeTouch&&(e.activeTouch.moved=!0)}),Pg(e.scroller,"touchend",function(c){var f=e.activeTouch;if(f&&!Nb(e,c)&&null!=f.left&&!f.moved&&new Date-f.start<300){var g,h=a.coordsChar(e.activeTouch,"page");g=!f.prev||d(f,f.prev)?new Hd(h,h):!f.prev.prev||d(f,f.prev.prev)?a.findWordAt(h):new Hd(H(h.line,0),N(a.doc,H(h.line+1,0))),a.setSelection(g.anchor,g.head),a.focus(),Ja(c)}b()}),Pg(e.scroller,"touchcancel",b),Pg(e.scroller,"scroll",function(){e.scroller.clientHeight&&(Mc(a,e.scroller.scrollTop),Nc(a,e.scroller.scrollLeft,!0),Ea(a,"scroll",a))}),Pg(e.scroller,"mousewheel",function(b){return Qc(a,b)}),Pg(e.scroller,"DOMMouseScroll",function(b){return Qc(a,b)}),Pg(e.wrapper,"scroll",function(){return e.wrapper.scrollTop=e.wrapper.scrollLeft=0}),e.dragFunctions={enter:function(b){Fa(a,b)||Ma(b)},over:function(b){Fa(a,b)||(We(a,b),Ma(b))},start:function(b){return Ve(a,b)},drop:ld(a,Ue),leave:function(b){Fa(a,b)||Xe(a)}};var h=e.input.getField();Pg(h,"keyup",function(b){return sf.call(a,b)}),Pg(h,"keydown",ld(a,qf)),Pg(h,"keypress",ld(a,tf)),Pg(h,"focus",function(b){return Fc(a,b)}),Pg(h,"blur",function(b){return Gc(a,b)})}function Jf(a,b,c,d){var e,f=a.doc;null==c&&(c="add"),"smart"==c&&(f.mode.indent?e=ab(a,b):c="prev");var g=a.options.tabSize,h=z(f,b),i=k(h.text,null,g);h.stateAfter&&(h.stateAfter=null);var j,l=h.text.match(/^\s*/)[0];if(d||/\S/.test(h.text)){if("smart"==c&&(j=f.mode.indent(e,h.text.slice(l.length),h.text),j==Dg||j>150)){if(!d)return;c="prev"}}else j=0,c="not";"prev"==c?j=b>f.first?k(z(f,b-1).text,null,g):0:"add"==c?j=i+a.options.indentUnit:"subtract"==c?j=i-a.options.indentUnit:"number"==typeof c&&(j=i+c),j=Math.max(0,j);var m="",n=0;if(a.options.indentWithTabs)for(var p=Math.floor(j/g);p;--p)n+=g,m+="\t";if(n1)if(Ah&&Ah.text.join("\n")==b){if(d.ranges.length%Ah.text.length==0){i=[];for(var j=0;j=0;l--){var m=d.ranges[l],n=m.from(),o=m.to();m.empty()&&(c&&c>0?n=H(n.line,n.ch-c):a.state.overwrite&&!g?o=H(o.line,Math.min(z(f,o.line).text.length,o.ch+p(h).length)):Ah&&Ah.lineWise&&Ah.text.join("\n")==b&&(n=o=H(n.line,0))),k=a.curOp.updateInput;var r={from:n,to:o,text:i?i[l%i.length]:h,origin:e||(g?"paste":a.state.cutIncoming?"cut":"+input")};xe(a.doc,r),yb(a,"inputRead",a,r)}b&&!g&&Nf(a,b),ad(a),a.curOp.updateInput=k,a.curOp.typing=!0,a.state.pasteIncoming=a.state.cutIncoming=!1}function Mf(a,b){var c=a.clipboardData&&a.clipboardData.getData("Text");if(c)return a.preventDefault(),b.isReadOnly()||b.options.disableInput||kd(b,function(){return Lf(b,c,0,null,"paste")}),!0}function Nf(a,b){if(a.options.electricChars&&a.options.smartIndent)for(var c=a.doc.sel,d=c.ranges.length-1;d>=0;d--){var e=c.ranges[d];if(!(e.head.ch>100||d&&c.ranges[d-1].head.line==e.head.line)){var f=a.getModeAt(e.head),g=!1;if(f.electricChars){for(var h=0;h-1){g=Jf(a,e.head.line,"smart");break}}else f.electricInput&&f.electricInput.test(z(a.doc,e.head.line).text.slice(0,e.head.ch))&&(g=Jf(a,e.head.line,"smart"));g&&yb(a,"electricInput",a,e.head.line)}}}function Of(a){for(var b=[],c=[],d=0;dd&&(Jf(b,f.head.line,a,!0),d=f.head.line,e==b.doc.sel.primIndex&&ad(b));else{var g=f.from(),h=f.to(),i=Math.max(d,g.line);d=Math.min(b.lastLine(),h.line-(h.ch?0:1))+1;for(var j=i;j0&&je(b.doc,e,new Hd(g,k[e].to()),Eg)}}}),getTokenAt:function(a,b){return eb(this,a,b)},getLineTokens:function(a,b){return eb(this,H(a),b,!0)},getTokenTypeAt:function(a){a=N(this.doc,a);var b,c=_a(this,z(this.doc,a.line)),d=0,e=(c.length-1)/2,f=a.ch;if(0==f)b=c[2];else for(;;){var g=d+e>>1;if((g?c[2*g-1]:0)>=f)e=g;else{if(!(c[2*g+1]f&&(a=f,e=!0),d=z(this.doc,a)}else d=a;return ic(this,d,{top:0,left:0},b||"page",c).top+(e?this.doc.height-oa(d):0)},defaultTextHeight:function(){return qc(this.display)},defaultCharWidth:function(){return rc(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(a,b,c,d,e){var f=this.display;a=lc(this,N(this.doc,a));var g=a.bottom,h=a.left;if(b.style.position="absolute",b.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(b),f.sizer.appendChild(b),"over"==d)g=a.top;else if("above"==d||"near"==d){var i=Math.max(f.wrapper.clientHeight,this.doc.height),j=Math.max(f.sizer.clientWidth,f.lineSpace.clientWidth);("above"==d||a.bottom+b.offsetHeight>i)&&a.top>b.offsetHeight?g=a.top-b.offsetHeight:a.bottom+b.offsetHeight<=i&&(g=a.bottom),h+b.offsetWidth>j&&(h=j-b.offsetWidth)}b.style.top=g+"px",b.style.left=b.style.right="","right"==e?(h=f.sizer.clientWidth-b.offsetWidth,b.style.right="0px"):("left"==e?h=0:"middle"==e&&(h=(f.sizer.clientWidth-b.offsetWidth)/2),b.style.left=h+"px"),c&&Zc(this,h,g,h+b.offsetWidth,g+b.offsetHeight)},triggerOnKeyDown:md(qf),triggerOnKeyPress:md(tf),triggerOnKeyUp:sf,execCommand:function(a){if(th.hasOwnProperty(a))return th[a].call(null,this)},triggerElectric:md(function(a){Nf(this,a)}),findPosH:function(a,b,c,d){var e=this,f=1;b<0&&(f=-1,b=-b);for(var g=N(this.doc,a),h=0;h0&&h(c.charAt(d-1));)--d;for(;e.5)&&vc(this),Ea(this,"refresh",this)}),swapDoc:md(function(a){var b=this.doc;return b.cm=null,Ud(this,a),fc(this),this.display.input.reset(),this.scrollTo(a.scrollLeft,a.scrollTop),this.curOp.forceScroll=!0,yb(this,"swapDoc",this,b),b}),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}},Ia(a),a.registerHelper=function(b,d,e){c.hasOwnProperty(b)||(c[b]=a[b]={_global:[]}),c[b][d]=e},a.registerGlobalHelper=function(b,d,e,f){a.registerHelper(b,d,f),c[b]._global.push({pred:e,val:f})}}function Sf(a,b,c,d,e){function f(){var b=h+c;return!(b=a.first+a.size)&&(h=b,k=z(a,b))}function g(a){var b=(e?za:Aa)(k,i,c,!0);if(null==b){if(a||!f())return!1;i=e?(c<0?va:ua)(k):c<0?k.text.length:0}else i=b;return!0}var h=b.line,i=b.ch,j=c,k=z(a,h);if("char"==d)g();else if("column"==d)g(!0);else if("word"==d||"group"==d)for(var l=null,m="group"==d,n=a.cm&&a.cm.getHelper(b,"wordChars"),o=!0;!(c<0)||g(!o);o=!1){var p=k.text.charAt(i)||"\n",q=v(p,n)?"w":m&&"\n"==p?"n":!m||/\s/.test(p)?null:"p";if(!m||o||q||(q="s"),l&&l!=q){c<0&&(c=1,g());break}if(q&&(l=q),c>0&&!g(!o))break}var r=te(a,H(h,i),b,j,!0);return I(b,r)||(r.hitSide=!0),r}function Tf(a,b,c,d){var e,f=a.doc,g=b.left;if("page"==d){var h=Math.min(a.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),i=Math.max(h-.5*qc(a.display),3);e=(c>0?b.bottom:b.top)+c*i}else"line"==d&&(e=c>0?b.bottom+3:b.top-3);for(var j;j=oc(a,g,e),j.outside;){if(c<0?e<=0:e>=f.height){j.hitSide=!0;break}e+=5*c}return j}function Uf(a){this.cm=a,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new l,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null}function Vf(a,b){var c=Yb(a,b.line);if(!c||c.hidden)return null;var d=z(a.doc,b.line),e=Vb(c,d,b.line),f=Ba(d),g="left";if(f){var h=xa(f,b.ch);g=h%2?"right":"left"}var i=_b(e.map,b.ch,g);return i.offset="right"==i.collapse?i.end:i.start,i}function Wf(a,b){return b&&(a.bad=!0),a}function Xf(a,b,c,d,e){function f(a){return function(b){return b.id==a}}function g(b){if(1==b.nodeType){var c=b.getAttribute("cm-text");if(null!=c)return void(h+=""==c?b.textContent.replace(/\u200b/g,""):c);var k,l=b.getAttribute("cm-marker");if(l){var m=a.findMarks(H(d,0),H(e+1,0),f(+l));return void(m.length&&(k=m[0].find())&&(h+=A(a.doc,k.from,k.to).join(j)))}if("false"==b.getAttribute("contenteditable"))return;for(var n=0;n=15&&(lg=!1,ig=!0);var vg,wg=rg&&(jg||lg&&(null==ug||ug<12.11)),xg=dg||gg&&hg>=9,yg=function(b,c){var d=b.className,e=a(c).exec(d);if(e){var f=d.slice(e.index+e[0].length);b.className=d.slice(0,e.index)+(f?e[1]+f:"")}};vg=document.createRange?function(a,b,c,d){var e=document.createRange();return e.setEnd(d||a,c),e.setStart(a,b),e}:function(a,b,c){var d=document.body.createTextRange();try{d.moveToElementText(a.parentNode)}catch(e){return d}return d.collapse(!0),d.moveEnd("character",c),d.moveStart("character",b),d};var zg=function(a){a.select()};pg?zg=function(a){a.selectionStart=0,a.selectionEnd=a.value.length}:gg&&(zg=function(a){try{a.select()}catch(b){}}),l.prototype.set=function(a,b){clearTimeout(this.id),this.id=setTimeout(b,a)};var Ag,Bg,Cg=30,Dg={toString:function(){return"CodeMirror.Pass"}},Eg={scroll:!1},Fg={origin:"*mouse"},Gg={origin:"+move"},Hg=[""],Ig=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/,Jg=/[\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]/,Kg=!1,Lg=!1,Mg=null,Ng=function(){function a(a){return a<=247?c.charAt(a):1424<=a&&a<=1524?"R":1536<=a&&a<=1773?d.charAt(a-1536):1774<=a&&a<=2220?"r":8192<=a&&a<=8203?"w":8204==a?"b":"L"}function b(a,b,c){this.level=a,this.from=b,this.to=c}var c="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",d="rrrrrrrrrrrr,rNNmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmrrrrrrrnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmNmmmm",e=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,f=/[stwN]/,g=/[LRr]/,h=/[Lb1n]/,i=/[1n]/,j="L";return function(c){if(!e.test(c))return!1;for(var d=c.length,k=[],l=0;l=this.string.length},sol:function(){return this.pos==this.lineStart},peek:function(){return this.string.charAt(this.pos)||void 0},next:function(){if(this.posb},eatSpace:function(){for(var a=this,b=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++a.pos;return this.pos>b},skipToEnd:function(){this.pos=this.string.length},skipTo:function(a){var b=this.string.indexOf(a,this.pos);if(b>-1)return this.pos=b,!0},backUp:function(a){this.pos-=a},column:function(){return this.lastColumnPos0?null:(d&&b!==!1&&(this.pos+=d[0].length),d)}var e=function(a){return c?a.toLowerCase():a},f=this.string.substr(this.pos,a.length);if(e(f)==e(a))return b!==!1&&(this.pos+=a.length),!0},current:function(){return this.string.slice(this.start,this.pos)},hideFirstChars:function(a,b){this.lineStart+=a;try{return b()}finally{this.lineStart-=a}}},Ia(ib),ib.prototype.lineNo=function(){return D(this)};var Zg,$g={},_g={},ah=null,bh=null,ch={left:0,right:0,top:0,bottom:0},dh=0,eh=null;gg?eh=-.53:dg?eh=15:kg?eh=-.7:mg&&(eh=-1/3),Sc.prototype=j({update:function(a){var b=a.scrollWidth>a.clientWidth+1,c=a.scrollHeight>a.clientHeight+1,d=a.nativeBarWidth;if(c){this.vert.style.display="block",this.vert.style.bottom=b?d+"px":"0";var e=a.viewHeight-(b?d:0);this.vert.firstChild.style.height=Math.max(0,a.scrollHeight-a.clientHeight+e)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(b){this.horiz.style.display="block",this.horiz.style.right=c?d+"px":"0",this.horiz.style.left=a.barLeft+"px";var f=a.viewWidth-a.barLeft-(c?d:0);this.horiz.firstChild.style.width=a.scrollWidth-a.clientWidth+f+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&a.clientHeight>0&&(0==d&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:c?d:0,bottom:b?d:0}},setScrollLeft:function(a){this.horiz.scrollLeft!=a&&(this.horiz.scrollLeft=a),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz)},setScrollTop:function(a){this.vert.scrollTop!=a&&(this.vert.scrollTop=a),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert)},zeroWidthHack:function(){var a=rg&&!ng?"12px":"18px";this.horiz.style.height=this.vert.style.width=a,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new l,this.disableVert=new l},enableZeroWidthBar:function(a,b){function c(){var d=a.getBoundingClientRect(),e=document.elementFromPoint(d.left+1,d.bottom-1);e!=a?a.style.pointerEvents="none":b.set(1e3,c); -}a.style.pointerEvents="auto",b.set(1e3,c)},clear:function(){var a=this.horiz.parentNode;a.removeChild(this.horiz),a.removeChild(this.vert)}},Sc.prototype),Tc.prototype=j({update:function(){return{bottom:0,right:0}},setScrollLeft:function(){},setScrollTop:function(){},clear:function(){}},Tc.prototype);var fh={"native":Sc,"null":Tc},gh=0;wd.prototype.signal=function(a,b){Ha(a,b)&&this.events.push(arguments)},wd.prototype.finish=function(){for(var a=this,b=0;b=0&&I(a,e.to())<=0)return d}return-1}},Hd.prototype={from:function(){return L(this.anchor,this.head)},to:function(){return K(this.anchor,this.head)},empty:function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch}},Ie.prototype={chunkSize:function(){return this.lines.length},removeInner:function(a,b){for(var c=this,d=a,e=a+b;d1||!(this.children[0]instanceof Ie))){var i=[];this.collapse(i),this.children=[new Ie(i)],this.children[0].parent=this}},collapse:function(a){for(var b=this,c=0;c50){for(var h=f.lines.length%25+25,i=h;i10);a.parent.maybeSpill()}},iterN:function(a,b,c){for(var d=this,e=0;eb.display.maxLineLength&&(b.display.maxLine=k,b.display.maxLineLength=l,b.display.maxLineChanged=!0)}null!=e&&b&&this.collapsed&&od(b,e,f+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,b&&qe(b.doc)),b&&yb(b,"markerCleared",b,this),c&&dd(b),this.parent&&this.parent.clear()}},Ne.prototype.find=function(a,b){var c=this;null==a&&"bookmark"==this.type&&(a=1);for(var d,e,f=0;f=0;j--)xe(d,e[j]);i?me(this,i):this.cm&&ad(this.cm)}),undo:nd(function(){ze(this,"undo")}),redo:nd(function(){ze(this,"redo")}),undoSelection:nd(function(){ze(this,"undo",!0)}),redoSelection:nd(function(){ze(this,"redo",!0)}),setExtending:function(a){this.extend=a},getExtending:function(){return this.extend},historySize:function(){for(var a=this.history,b=0,c=0,d=0;d=a.ch)&&b.push(e.marker.parent||e.marker)}return b},findMarks:function(a,b,c){a=N(this,a),b=N(this,b);var d=[],e=a.line;return this.iter(a.line,b.line+1,function(f){var g=f.markedSpans;if(g)for(var h=0;h=i.to||null==i.from&&e!=a.line||null!=i.from&&e==b.line&&i.from>=b.ch||c&&!c(i.marker)||d.push(i.marker.parent||i.marker)}++e}),d},getAllMarks:function(){var a=[];return this.iter(function(b){var c=b.markedSpans;if(c)for(var d=0;da?(b=a,!0):(a-=f,void++c)}),N(this,H(c,b))},indexFromPos:function(a){a=N(this,a);var b=a.ch;if(a.lineb&&(b=a.from),null!=a.to&&a.to0)e=new H(e.line,e.ch+1),a.replaceRange(f.charAt(e.ch-1)+f.charAt(e.ch-2),H(e.line,e.ch-2),e,"+transpose");else if(e.line>a.doc.first){var g=z(a.doc,e.line-1).text;g&&(e=new H(e.line,1),a.replaceRange(f.charAt(0)+a.doc.lineSeparator()+g.charAt(g.length-1),H(e.line-1,g.length-1),e,"+transpose"))}c.push(new Hd(e,e))}a.setSelections(c)})},newlineAndIndent:function(a){return kd(a,function(){for(var b=a.listSelections(),c=b.length-1;c>=0;c--)a.replaceRange(a.doc.lineSeparator(),b[c].anchor,b[c].head,"+input");b=a.listSelections();for(var d=0;da.firstLine()&&(d=H(d.line-1,z(a.doc,d.line-1).length)),e.ch==z(a.doc,e.line).text.length&&e.lineb.viewTo-1)return!1;var f,g,h;d.line==b.viewFrom||0==(f=xc(a,d.line))?(g=D(b.view[0].line),h=b.view[0].node):(g=D(b.view[f].line),h=b.view[f-1].node.nextSibling);var i,j,k=xc(a,e.line);if(k==b.view.length-1?(i=b.viewTo-1,j=b.lineDiv.lastChild):(i=D(b.view[k+1].line)-1,j=b.view[k+1].node.previousSibling),!h)return!1;for(var l=a.doc.splitLines(Xf(a,h,j,g,i)),m=A(a.doc,H(g,0),H(i,z(a.doc,i).text.length));l.length>1&&m.length>1;)if(p(l)==p(m))l.pop(),m.pop(),i--;else{if(l[0]!=m[0])break;l.shift(),m.shift(),g++}for(var n=0,o=0,q=l[0],r=m[0],s=Math.min(q.length,r.length);n1||l[0]||I(w,x)?(De(a.doc,l,w,x,"+input"),!0):void 0},ensurePolled:function(){this.forceCompositionEnd()},reset:function(){this.forceCompositionEnd()},forceCompositionEnd:function(){this.composing&&(this.composing=null,this.pollContent()||od(this.cm),this.div.blur(),this.div.focus())},readFromDOMSoon:function(){var a=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout(function(){a.readDOMTimeout=null,a.composing||!a.cm.isReadOnly()&&a.pollContent()||kd(a.cm,function(){return od(a.cm)})},80))},setUneditable:function(a){a.contentEditable="false"},onKeyPress:function(a){a.preventDefault(),this.cm.isReadOnly()||ld(this.cm,Lf)(this.cm,String.fromCharCode(null==a.charCode?a.keyCode:a.charCode),0)},readOnlyChanged:function(a){this.div.contentEditable=String("nocursor"!=a)},onContextMenu:s,resetPosition:s,needsContentAttribute:!0},Uf.prototype),$f.prototype=j({init:function(a){function b(a){if(!Fa(e,a)){if(e.somethingSelected())Kf({lineWise:!1,text:e.getSelections()}),d.inaccurateSelection&&(d.prevInput="",d.inaccurateSelection=!1,g.value=Ah.text.join("\n"),zg(g));else{if(!e.options.lineWiseCopyCut)return;var b=Of(e);Kf({lineWise:!0,text:b.text}),"cut"==a.type?e.setSelections(b.ranges,null,Eg):(d.prevInput="",g.value=b.text.join("\n"),zg(g))}"cut"==a.type&&(e.state.cutIncoming=!0)}}var c=this,d=this,e=this.cm,f=this.wrapper=Qf(),g=this.textarea=f.firstChild;a.wrapper.insertBefore(f,a.wrapper.firstChild),pg&&(g.style.width="0px"),Pg(g,"input",function(){gg&&hg>=9&&c.hasSelection&&(c.hasSelection=null),d.poll()}),Pg(g,"paste",function(a){Fa(e,a)||Mf(a,e)||(e.state.pasteIncoming=!0,d.fastPoll())}),Pg(g,"cut",b),Pg(g,"copy",b),Pg(a.scroller,"paste",function(b){Nb(a,b)||Fa(e,b)||(e.state.pasteIncoming=!0,d.focus())}),Pg(a.lineSpace,"selectstart",function(b){Nb(a,b)||Ja(b)}),Pg(g,"compositionstart",function(){var a=e.getCursor("from");d.composing&&d.composing.range.clear(),d.composing={start:a,range:e.markText(a,e.getCursor("to"),{className:"CodeMirror-composing"})}}),Pg(g,"compositionend",function(){d.composing&&(d.poll(),d.composing.range.clear(),d.composing=null)})},prepareSelection:function(){var a=this.cm,b=a.display,c=a.doc,d=zc(a);if(a.options.moveInputWithCursor){var e=lc(a,c.sel.primary().head,"div"),f=b.wrapper.getBoundingClientRect(),g=b.lineDiv.getBoundingClientRect();d.teTop=Math.max(0,Math.min(b.wrapper.clientHeight-10,e.top+g.top-f.top)),d.teLeft=Math.max(0,Math.min(b.wrapper.clientWidth-10,e.left+g.left-f.left))}return d},showSelection:function(a){var b=this.cm,d=b.display;c(d.cursorDiv,a.cursors),c(d.selectionDiv,a.selection),null!=a.teTop&&(this.wrapper.style.top=a.teTop+"px",this.wrapper.style.left=a.teLeft+"px")},reset:function(a){if(!this.contextMenuPending){var b,c,d=this.cm,e=d.doc;if(d.somethingSelected()){this.prevInput="";var f=e.sel.primary();b=Tg&&(f.to().line-f.from().line>100||(c=d.getSelection()).length>1e3);var g=b?"-":c||d.getSelection();this.textarea.value=g,d.state.focused&&zg(this.textarea),gg&&hg>=9&&(this.hasSelection=g)}else a||(this.prevInput=this.textarea.value="",gg&&hg>=9&&(this.hasSelection=null));this.inaccurateSelection=b}},getField:function(){return this.textarea},supportsTouch:function(){return!1},focus:function(){if("nocursor"!=this.cm.options.readOnly&&(!qg||f()!=this.textarea))try{this.textarea.focus()}catch(a){}},blur:function(){this.textarea.blur()},resetPosition:function(){this.wrapper.style.top=this.wrapper.style.left=0},receivedFocus:function(){this.slowPoll()},slowPoll:function(){var a=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){a.poll(),a.cm.state.focused&&a.slowPoll()})},fastPoll:function(){function a(){var d=c.poll();d||b?(c.pollingFast=!1,c.slowPoll()):(b=!0,c.polling.set(60,a))}var b=!1,c=this;c.pollingFast=!0,c.polling.set(20,a)},poll:function(){var a=this,b=this.cm,c=this.textarea,d=this.prevInput;if(this.contextMenuPending||!b.state.focused||Sg(c)&&!d&&!this.composing||b.isReadOnly()||b.options.disableInput||b.state.keySeq)return!1;var e=c.value; -if(e==d&&!b.somethingSelected())return!1;if(gg&&hg>=9&&this.hasSelection===e||rg&&/[\uf700-\uf7ff]/.test(e))return b.display.input.reset(),!1;if(b.doc.sel==b.display.selForContextMenu){var f=e.charCodeAt(0);if(8203!=f||d||(d="​"),8666==f)return this.reset(),this.cm.execCommand("undo")}for(var g=0,h=Math.min(d.length,e.length);g1e3||e.indexOf("\n")>-1?c.value=a.prevInput="":a.prevInput=e,a.composing&&(a.composing.range.clear(),a.composing.range=b.markText(a.composing.start,b.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},ensurePolled:function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},onKeyPress:function(){gg&&hg>=9&&(this.hasSelection=null),this.fastPoll()},onContextMenu:function(a){function b(){if(null!=g.selectionStart){var a=e.somethingSelected(),b="​"+(a?g.value:"");g.value="⇚",g.value=b,d.prevInput=a?"":"​",g.selectionStart=1,g.selectionEnd=b.length,f.selForContextMenu=e.doc.sel}}function c(){if(d.contextMenuPending=!1,d.wrapper.style.cssText=l,g.style.cssText=k,gg&&hg<9&&f.scrollbars.setScrollTop(f.scroller.scrollTop=i),null!=g.selectionStart){(!gg||gg&&hg<9)&&b();var a=0,c=function(){f.selForContextMenu==e.doc.sel&&0==g.selectionStart&&g.selectionEnd>0&&"​"==d.prevInput?ld(e,ve)(e):a++<10?f.detectingSelectAll=setTimeout(c,500):f.input.reset()};f.detectingSelectAll=setTimeout(c,200)}}var d=this,e=d.cm,f=e.display,g=d.textarea,h=wc(e,a),i=f.scroller.scrollTop;if(h&&!lg){var j=e.options.resetSelectionOnContextMenu;j&&e.doc.sel.contains(h)==-1&&ld(e,ne)(e.doc,Jd(h),Eg);var k=g.style.cssText,l=d.wrapper.style.cssText;d.wrapper.style.cssText="position: absolute";var m=d.wrapper.getBoundingClientRect();g.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(a.clientY-m.top-5)+"px; left: "+(a.clientX-m.left-5)+"px;\n z-index: 1000; background: "+(gg?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);";var n;if(ig&&(n=window.scrollY),f.input.focus(),ig&&window.scrollTo(null,n),f.input.reset(),e.somethingSelected()||(g.value=d.prevInput=" "),d.contextMenuPending=!0,f.selForContextMenu=e.doc.sel,clearTimeout(f.detectingSelectAll),gg&&hg>=9&&b(),xg){Ma(a);var o=function(){Da(window,"mouseup",o),setTimeout(c,20)};Pg(window,"mouseup",o)}else setTimeout(c,50)}},readOnlyChanged:function(a){a||this.reset()},setUneditable:s,needsContentAttribute:!1},$f.prototype),Df(Hf),Rf(Hf);var Bh="iter insert remove copy getEditor constructor".split(" ");for(var Ch in jh.prototype)jh.prototype.hasOwnProperty(Ch)&&m(Bh,Ch)<0&&(Hf.prototype[Ch]=function(a){return function(){return a.apply(this.doc,arguments)}}(jh.prototype[Ch]));return Ia(jh),Hf.inputStyles={textarea:$f,contenteditable:Uf},Hf.defineMode=function(a){Hf.defaults.mode||"null"==a||(Hf.defaults.mode=a),Sa.apply(this,arguments)},Hf.defineMIME=Ta,Hf.defineMode("null",function(){return{token:function(a){return a.skipToEnd()}}}),Hf.defineMIME("text/plain","null"),Hf.defineExtension=function(a,b){Hf.prototype[a]=b},Hf.defineDocExtension=function(a,b){jh.prototype[a]=b},Hf.fromTextArea=_f,ag(Hf),Hf.version="5.21.0",Hf}),function(a){"object"==typeof exports&&"object"==typeof module?a(b("../../lib/codemirror")):"function"==typeof c&&c.amd?c("codemirror/mode/xml/xml",["../../lib/codemirror"],a):a(CodeMirror)}(function(a){"use strict";var b={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},c={autoSelfClosers:{},implicitlyClosed:{},contextGrabbers:{},doNotIndent:{},allowUnquoted:!1,allowMissing:!1,caseFold:!1};a.defineMode("xml",function(d,e){function f(a,b){function c(c){return b.tokenize=c,c(a,b)}var d=a.next();if("<"==d)return a.eat("!")?a.eat("[")?a.match("CDATA[")?c(i("atom","]]>")):null:a.match("--")?c(i("comment","-->")):a.match("DOCTYPE",!0,!0)?(a.eatWhile(/[\w\._\-]/),c(j(1))):null:a.eat("?")?(a.eatWhile(/[\w\._\-]/),b.tokenize=i("meta","?>"),"meta"):(A=a.eat("/")?"closeTag":"openTag",b.tokenize=g,"tag bracket");if("&"==d){var e;return e=a.eat("#")?a.eat("x")?a.eatWhile(/[a-fA-F\d]/)&&a.eat(";"):a.eatWhile(/[\d]/)&&a.eat(";"):a.eatWhile(/[\w\.\-:]/)&&a.eat(";"),e?"atom":"error"}return a.eatWhile(/[^&<]/),null}function g(a,b){var c=a.next();if(">"==c||"/"==c&&a.eat(">"))return b.tokenize=f,A=">"==c?"endTag":"selfcloseTag","tag bracket";if("="==c)return A="equals",null;if("<"==c){b.tokenize=f,b.state=n,b.tagName=b.tagStart=null;var d=b.tokenize(a,b);return d?d+" tag error":"tag error"}return/[\'\"]/.test(c)?(b.tokenize=h(c),b.stringStartCol=a.column(),b.tokenize(a,b)):(a.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function h(a){var b=function(b,c){for(;!b.eol();)if(b.next()==a){c.tokenize=g;break}return"string"};return b.isInAttribute=!0,b}function i(a,b){return function(c,d){for(;!c.eol();){if(c.match(b)){d.tokenize=f;break}c.next()}return a}}function j(a){return function(b,c){for(var d;null!=(d=b.next());){if("<"==d)return c.tokenize=j(a+1),c.tokenize(b,c);if(">"==d){if(1==a){c.tokenize=f;break}return c.tokenize=j(a-1),c.tokenize(b,c)}}return"meta"}}function k(a,b,c){this.prev=a.context,this.tagName=b,this.indent=a.indented,this.startOfLine=c,(x.doNotIndent.hasOwnProperty(b)||a.context&&a.context.noIndent)&&(this.noIndent=!0)}function l(a){a.context&&(a.context=a.context.prev)}function m(a,b){for(var c;;){if(!a.context)return;if(c=a.context.tagName,!x.contextGrabbers.hasOwnProperty(c)||!x.contextGrabbers[c].hasOwnProperty(b))return;l(a)}}function n(a,b,c){return"openTag"==a?(c.tagStart=b.column(),o):"closeTag"==a?p:n}function o(a,b,c){return"word"==a?(c.tagName=b.current(),B="tag",s):(B="error",o)}function p(a,b,c){if("word"==a){var d=b.current();return c.context&&c.context.tagName!=d&&x.implicitlyClosed.hasOwnProperty(c.context.tagName)&&l(c),c.context&&c.context.tagName==d||x.matchClosing===!1?(B="tag",q):(B="tag error",r)}return B="error",r}function q(a,b,c){return"endTag"!=a?(B="error",q):(l(c),n)}function r(a,b,c){return B="error",q(a,b,c)}function s(a,b,c){if("word"==a)return B="attribute",t;if("endTag"==a||"selfcloseTag"==a){var d=c.tagName,e=c.tagStart;return c.tagName=c.tagStart=null,"selfcloseTag"==a||x.autoSelfClosers.hasOwnProperty(d)?m(c,d):(m(c,d),c.context=new k(c,d,e==c.indented)),n}return B="error",s}function t(a,b,c){return"equals"==a?u:(x.allowMissing||(B="error"),s(a,b,c))}function u(a,b,c){return"string"==a?v:"word"==a&&x.allowUnquoted?(B="string",s):(B="error",s(a,b,c))}function v(a,b,c){return"string"==a?v:s(a,b,c)}var w=d.indentUnit,x={},y=e.htmlMode?b:c;for(var z in y)x[z]=y[z];for(var z in e)x[z]=e[z];var A,B;return f.isInText=!0,{startState:function(a){var b={tokenize:f,state:n,indented:a||0,tagName:null,tagStart:null,context:null};return null!=a&&(b.baseIndent=a),b},token:function(a,b){if(!b.tagName&&a.sol()&&(b.indented=a.indentation()),a.eatSpace())return null;A=null;var c=b.tokenize(a,b);return(c||A)&&"comment"!=c&&(B=null,b.state=b.state(A||c,a,b),B&&(c="error"==B?c+" error":B)),c},indent:function(b,c,d){var e=b.context;if(b.tokenize.isInAttribute)return b.tagStart==b.indented?b.stringStartCol+1:b.indented+w;if(e&&e.noIndent)return a.Pass;if(b.tokenize!=g&&b.tokenize!=f)return d?d.match(/^(\s*)/)[0].length:0;if(b.tagName)return x.multilineTagIndentPastTag!==!1?b.tagStart+b.tagName.length+2:b.tagStart+w*(x.multilineTagIndentFactor||1);if(x.alignCDATA&&/$/,blockCommentStart:"",configuration:x.htmlMode?"html":"xml",helperType:x.htmlMode?"html":"xml",skipAttribute:function(a){a.state==u&&(a.state=s)}}}),a.defineMIME("text/xml","xml"),a.defineMIME("application/xml","xml"),a.mimeModes.hasOwnProperty("text/html")||a.defineMIME("text/html",{name:"xml",htmlMode:!0})}),function(a){"object"==typeof exports&&"object"==typeof module?a(b("../../lib/codemirror")):"function"==typeof c&&c.amd?c("codemirror/mode/javascript/javascript",["../../lib/codemirror"],a):a(CodeMirror)}(function(a){"use strict";function b(a,b,c){return/^(?:operator|sof|keyword c|case|new|[\[{}\(,;:]|=>)$/.test(b.lastType)||"quasi"==b.lastType&&/\{\s*$/.test(a.string.slice(0,a.pos-(c||0)))}a.defineMode("javascript",function(c,d){function e(a){for(var b,c=!1,d=!1;null!=(b=a.next());){if(!c){if("/"==b&&!d)return;"["==b?d=!0:d&&"]"==b&&(d=!1)}c=!c&&"\\"==b}}function f(a,b,c){return xa=a,ya=c,b}function g(a,c){var d=a.next();if('"'==d||"'"==d)return c.tokenize=h(d),c.tokenize(a,c);if("."==d&&a.match(/^\d+(?:[eE][+\-]?\d+)?/))return f("number","number");if("."==d&&a.match(".."))return f("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(d))return f(d);if("="==d&&a.eat(">"))return f("=>","operator");if("0"==d&&a.eat(/x/i))return a.eatWhile(/[\da-f]/i),f("number","number");if("0"==d&&a.eat(/o/i))return a.eatWhile(/[0-7]/i),f("number","number");if("0"==d&&a.eat(/b/i))return a.eatWhile(/[01]/i),f("number","number");if(/\d/.test(d))return a.match(/^\d*(?:\.\d*)?(?:[eE][+\-]?\d+)?/),f("number","number");if("/"==d)return a.eat("*")?(c.tokenize=i,i(a,c)):a.eat("/")?(a.skipToEnd(),f("comment","comment")):b(a,c,1)?(e(a),a.match(/^\b(([gimyu])(?![gimyu]*\2))+\b/),f("regexp","string-2")):(a.eatWhile(Ga),f("operator","operator",a.current()));if("`"==d)return c.tokenize=j,j(a,c);if("#"==d)return a.skipToEnd(),f("error","error");if(Ga.test(d))return a.eatWhile(Ga),f("operator","operator",a.current());if(Ea.test(d)){a.eatWhile(Ea);var g=a.current(),k=Fa.propertyIsEnumerable(g)&&Fa[g];return k&&"."!=c.lastType?f(k.type,k.style,g):f("variable","variable",g)}}function h(a){return function(b,c){var d,e=!1;if(Ba&&"@"==b.peek()&&b.match(Ha))return c.tokenize=g,f("jsonld-keyword","meta");for(;null!=(d=b.next())&&(d!=a||e);)e=!e&&"\\"==d;return e||(c.tokenize=g),f("string","string")}}function i(a,b){for(var c,d=!1;c=a.next();){if("/"==c&&d){b.tokenize=g;break}d="*"==c}return f("comment","comment")}function j(a,b){for(var c,d=!1;null!=(c=a.next());){if(!d&&("`"==c||"$"==c&&a.eat("{"))){b.tokenize=g;break}d=!d&&"\\"==c}return f("quasi","string-2",a.current())}function k(a,b){b.fatArrowAt&&(b.fatArrowAt=null);var c=a.string.indexOf("=>",a.start);if(!(c<0)){if(Da){var d=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(a.string.slice(a.start,c));d&&(c=d.index)}for(var e=0,f=!1,g=c-1;g>=0;--g){var h=a.string.charAt(g),i=Ia.indexOf(h);if(i>=0&&i<3){if(!e){++g;break}if(0==--e){"("==h&&(f=!0);break}}else if(i>=3&&i<6)++e;else if(Ea.test(h))f=!0;else{if(/["'\/]/.test(h))return;if(f&&!e){++g;break}}}f&&!e&&(b.fatArrowAt=g)}}function l(a,b,c,d,e,f){this.indented=a,this.column=b,this.type=c,this.prev=e,this.info=f,null!=d&&(this.align=d)}function m(a,b){for(var c=a.localVars;c;c=c.next)if(c.name==b)return!0;for(var d=a.context;d;d=d.prev)for(var c=d.vars;c;c=c.next)if(c.name==b)return!0}function n(a,b,c,d,e){var f=a.cc;for(Ka.state=a,Ka.stream=e,Ka.marked=null,Ka.cc=f,Ka.style=b,a.lexical.hasOwnProperty("align")||(a.lexical.align=!0);;){var g=f.length?f.pop():Ca?x:w;if(g(c,d)){for(;f.length&&f[f.length-1].lex;)f.pop()();return Ka.marked?Ka.marked:"variable"==c&&m(a,d)?"variable-2":b}}}function o(){for(var a=arguments.length-1;a>=0;a--)Ka.cc.push(arguments[a])}function p(){return o.apply(null,arguments),!0}function q(a){function b(b){for(var c=b;c;c=c.next)if(c.name==a)return!0;return!1}var c=Ka.state;if(Ka.marked="def",c.context){if(b(c.localVars))return;c.localVars={name:a,next:c.localVars}}else{if(b(c.globalVars))return;d.globalVars&&(c.globalVars={name:a,next:c.globalVars})}}function r(){Ka.state.context={prev:Ka.state.context,vars:Ka.state.localVars},Ka.state.localVars=La}function s(){Ka.state.localVars=Ka.state.context.vars,Ka.state.context=Ka.state.context.prev}function t(a,b){var c=function(){var c=Ka.state,d=c.indented;if("stat"==c.lexical.type)d=c.lexical.indented;else for(var e=c.lexical;e&&")"==e.type&&e.align;e=e.prev)d=e.indented;c.lexical=new l(d,Ka.stream.column(),a,null,c.lexical,b)};return c.lex=!0,c}function u(){var a=Ka.state;a.lexical.prev&&(")"==a.lexical.type&&(a.indented=a.lexical.indented),a.lexical=a.lexical.prev)}function v(a){function b(c){return c==a?p():";"==a?o():p(b)}return b}function w(a,b){return"var"==a?p(t("vardef",b.length),$,v(";"),u):"keyword a"==a?p(t("form"),z,w,u):"keyword b"==a?p(t("form"),w,u):"{"==a?p(t("}"),T,u):";"==a?p():"if"==a?("else"==Ka.state.lexical.info&&Ka.state.cc[Ka.state.cc.length-1]==u&&Ka.state.cc.pop()(),p(t("form"),z,w,u,da)):"function"==a?p(ja):"for"==a?p(t("form"),ea,w,u):"variable"==a?p(t("stat"),M):"switch"==a?p(t("form"),z,t("}","switch"),v("{"),T,u,u):"case"==a?p(x,v(":")):"default"==a?p(v(":")):"catch"==a?p(t("form"),r,v("("),ka,v(")"),w,u,s):"class"==a?p(t("form"),ma,u):"export"==a?p(t("stat"),qa,u):"import"==a?p(t("stat"),ra,u):"module"==a?p(t("form"),_,t("}"),v("{"),T,u,u):"type"==a?p(V,v("operator"),V,v(";")):"async"==a?p(w):o(t("stat"),x,v(";"),u)}function x(a){return A(a,!1)}function y(a){return A(a,!0)}function z(a){return"("!=a?o():p(t(")"),x,v(")"),u)}function A(a,b){if(Ka.state.fatArrowAt==Ka.stream.start){var c=b?I:H;if("("==a)return p(r,t(")"),R(_,")"),u,v("=>"),c,s);if("variable"==a)return o(r,_,v("=>"),c,s)}var d=b?E:D;return Ja.hasOwnProperty(a)?p(d):"function"==a?p(ja,d):"class"==a?p(t("form"),la,u):"keyword c"==a||"async"==a?p(b?C:B):"("==a?p(t(")"),B,v(")"),u,d):"operator"==a||"spread"==a?p(b?y:x):"["==a?p(t("]"),va,u,d):"{"==a?S(O,"}",null,d):"quasi"==a?o(F,d):"new"==a?p(J(b)):p()}function B(a){return a.match(/[;\}\)\],]/)?o():o(x)}function C(a){return a.match(/[;\}\)\],]/)?o():o(y)}function D(a,b){return","==a?p(x):E(a,b,!1)}function E(a,b,c){var d=0==c?D:E,e=0==c?x:y;return"=>"==a?p(r,c?I:H,s):"operator"==a?/\+\+|--/.test(b)?p(d):"?"==b?p(x,v(":"),e):p(e):"quasi"==a?o(F,d):";"!=a?"("==a?S(y,")","call",d):"."==a?p(N,d):"["==a?p(t("]"),B,v("]"),u,d):void 0:void 0}function F(a,b){return"quasi"!=a?o():"${"!=b.slice(b.length-2)?p(F):p(x,G)}function G(a){if("}"==a)return Ka.marked="string-2",Ka.state.tokenize=j,p(F)}function H(a){return k(Ka.stream,Ka.state),o("{"==a?w:x)}function I(a){return k(Ka.stream,Ka.state),o("{"==a?w:y)}function J(a){return function(b){return"."==b?p(a?L:K):o(a?y:x)}}function K(a,b){if("target"==b)return Ka.marked="keyword",p(D)}function L(a,b){if("target"==b)return Ka.marked="keyword",p(E)}function M(a){return":"==a?p(u,w):o(D,v(";"),u)}function N(a){if("variable"==a)return Ka.marked="property",p()}function O(a,b){return"async"==a?(Ka.marked="property",p(O)):"variable"==a||"keyword"==Ka.style?(Ka.marked="property",p("get"==b||"set"==b?P:Q)):"number"==a||"string"==a?(Ka.marked=Ba?"property":Ka.style+" property",p(Q)):"jsonld-keyword"==a?p(Q):"modifier"==a?p(O):"["==a?p(x,v("]"),Q):"spread"==a?p(x):":"==a?o(Q):void 0}function P(a){return"variable"!=a?o(Q):(Ka.marked="property",p(ja))}function Q(a){return":"==a?p(y):"("==a?o(ja):void 0}function R(a,b){function c(d,e){if(","==d){var f=Ka.state.lexical;return"call"==f.info&&(f.pos=(f.pos||0)+1),p(function(c,d){return c==b||d==b?o():o(a)},c)}return d==b||e==b?p():p(v(b))}return function(d,e){return d==b||e==b?p():o(a,c)}}function S(a,b,c){for(var d=3;d"==a)return p(V)}function X(a){return"variable"==a||"keyword"==Ka.style?(Ka.marked="property",p(X)):":"==a?p(V):void 0}function Y(a){return"variable"==a?p(Y):":"==a?p(V):void 0}function Z(a,b){return"<"==b?p(R(V,">"),Z):"["==a?p(v("]"),Z):void 0}function $(){return o(_,U,ba,ca)}function _(a,b){return"modifier"==a?p(_):"variable"==a?(q(b),p()):"spread"==a?p(_):"["==a?S(_,"]"):"{"==a?S(aa,"}"):void 0}function aa(a,b){return"variable"!=a||Ka.stream.match(/^\s*:/,!1)?("variable"==a&&(Ka.marked="property"),"spread"==a?p(_):"}"==a?o():p(v(":"),_,ba)):(q(b),p(ba))}function ba(a,b){if("="==b)return p(y)}function ca(a){if(","==a)return p($)}function da(a,b){if("keyword b"==a&&"else"==b)return p(t("form","else"),w,u)}function ea(a){if("("==a)return p(t(")"),fa,v(")"),u)}function fa(a){return"var"==a?p($,v(";"),ha):";"==a?p(ha):"variable"==a?p(ga):o(x,v(";"),ha)}function ga(a,b){return"in"==b||"of"==b?(Ka.marked="keyword",p(x)):p(D,ha)}function ha(a,b){return";"==a?p(ia):"in"==b||"of"==b?(Ka.marked="keyword",p(x)):o(x,v(";"),ia)}function ia(a){")"!=a&&p(x)}function ja(a,b){return"*"==b?(Ka.marked="keyword",p(ja)):"variable"==a?(q(b),p(ja)):"("==a?p(r,t(")"),R(ka,")"),u,U,w,s):void 0}function ka(a){return"spread"==a?p(ka):o(_,U,ba)}function la(a,b){return"variable"==a?ma(a,b):na(a,b)}function ma(a,b){if("variable"==a)return q(b),p(na)}function na(a,b){return"extends"==b||"implements"==b?p(Da?V:x,na):"{"==a?p(t("}"),oa,u):void 0}function oa(a,b){return"variable"==a||"keyword"==Ka.style?("static"==b||"get"==b||"set"==b||Da&&("public"==b||"private"==b||"protected"==b||"readonly"==b||"abstract"==b))&&Ka.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(Ka.marked="keyword",p(oa)):(Ka.marked="property",p(Da?pa:ja,oa)):"*"==b?(Ka.marked="keyword",p(oa)):";"==a?p(oa):"}"==a?p():void 0}function pa(a,b){return"?"==b?p(pa):":"==a?p(V,ba):o(ja)}function qa(a,b){return"*"==b?(Ka.marked="keyword",p(ua,v(";"))):"default"==b?(Ka.marked="keyword",p(x,v(";"))):o(w)}function ra(a){return"string"==a?p():o(sa,ua)}function sa(a,b){return"{"==a?S(sa,"}"):("variable"==a&&q(b),"*"==b&&(Ka.marked="keyword"),p(ta))}function ta(a,b){if("as"==b)return Ka.marked="keyword",p(sa)}function ua(a,b){if("from"==b)return Ka.marked="keyword",p(x)}function va(a){return"]"==a?p():o(R(y,"]"))}function wa(a,b){return"operator"==a.lastType||","==a.lastType||Ga.test(b.charAt(0))||/[,.]/.test(b.charAt(0))}var xa,ya,za=c.indentUnit,Aa=d.statementIndent,Ba=d.jsonld,Ca=d.json||Ba,Da=d.typescript,Ea=d.wordCharacters||/[\w$\xa1-\uffff]/,Fa=function(){function a(a){return{type:a,style:"keyword"}}var b=a("keyword a"),c=a("keyword b"),d=a("keyword c"),e=a("operator"),f={type:"atom",style:"atom"},g={"if":a("if"),"while":b,"with":b,"else":c,"do":c,"try":c,"finally":c,"return":d,"break":d,"continue":d,"new":a("new"),"delete":d,"throw":d,"debugger":d,"var":a("var"),"const":a("var"),"let":a("var"),"function":a("function"),"catch":a("catch"),"for":a("for"),"switch":a("switch"),"case":a("case"),"default":a("default"),"in":e,"typeof":e,"instanceof":e,"true":f,"false":f,"null":f,undefined:f,NaN:f,Infinity:f,"this":a("this"),"class":a("class"),"super":a("atom"),"yield":d,"export":a("export"),"import":a("import"),"extends":d,await:d,async:a("async")};if(Da){var h={type:"variable",style:"variable-3"},i={"interface":a("class"),"implements":d,namespace:d,module:a("module"),"enum":a("module"),type:a("type"),"public":a("modifier"),"private":a("modifier"),"protected":a("modifier"),"abstract":a("modifier"),as:e,string:h,number:h,"boolean":h,any:h};for(var j in i)g[j]=i[j]}return g}(),Ga=/[+\-*&%=<>!?|~^]/,Ha=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/,Ia="([{}])",Ja={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,"this":!0,"jsonld-keyword":!0},Ka={state:null,column:null,marked:null,cc:null},La={name:"this",next:{name:"arguments"}};return u.lex=!0,{startState:function(a){var b={tokenize:g,lastType:"sof",cc:[],lexical:new l((a||0)-za,0,"block",(!1)),localVars:d.localVars,context:d.localVars&&{vars:d.localVars},indented:a||0};return d.globalVars&&"object"==typeof d.globalVars&&(b.globalVars=d.globalVars),b},token:function(a,b){if(a.sol()&&(b.lexical.hasOwnProperty("align")||(b.lexical.align=!1),b.indented=a.indentation(),k(a,b)),b.tokenize!=i&&a.eatSpace())return null;var c=b.tokenize(a,b);return"comment"==xa?c:(b.lastType="operator"!=xa||"++"!=ya&&"--"!=ya?xa:"incdec",n(b,c,xa,ya,a))},indent:function(b,c){if(b.tokenize==i)return a.Pass;if(b.tokenize!=g)return 0;var e,f=c&&c.charAt(0),h=b.lexical;if(!/^\s*else\b/.test(c))for(var j=b.cc.length-1;j>=0;--j){var k=b.cc[j];if(k==u)h=h.prev;else if(k!=da)break}for(;("stat"==h.type||"form"==h.type)&&("}"==f||(e=b.cc[b.cc.length-1])&&(e==D||e==E)&&!/^[,\.=+\-*:?[\(]/.test(c));)h=h.prev;Aa&&")"==h.type&&"stat"==h.prev.type&&(h=h.prev);var l=h.type,m=f==l;return"vardef"==l?h.indented+("operator"==b.lastType||","==b.lastType?h.info+1:0):"form"==l&&"{"==f?h.indented:"form"==l?h.indented+za:"stat"==l?h.indented+(wa(b,c)?Aa||za:0):"switch"!=h.info||m||0==d.doubleIndentSwitch?h.align?h.column+(m?0:1):h.indented+(m?0:za):h.indented+(/^(?:case|default)\b/.test(c)?za:2*za)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:Ca?null:"/*",blockCommentEnd:Ca?null:"*/",lineComment:Ca?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:Ca?"json":"javascript",jsonldMode:Ba,jsonMode:Ca,expressionAllowed:b,skipExpression:function(a){var b=a.cc[a.cc.length-1];b!=x&&b!=y||a.cc.pop()}}}),a.registerHelper("wordChars","javascript",/[\w$]/),a.defineMIME("text/javascript","javascript"),a.defineMIME("text/ecmascript","javascript"),a.defineMIME("application/javascript","javascript"),a.defineMIME("application/x-javascript","javascript"),a.defineMIME("application/ecmascript","javascript"),a.defineMIME("application/json",{name:"javascript",json:!0}),a.defineMIME("application/x-json",{name:"javascript",json:!0}),a.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),a.defineMIME("text/typescript",{name:"javascript",typescript:!0}),a.defineMIME("application/typescript",{name:"javascript",typescript:!0})}),function(a){"object"==typeof exports&&"object"==typeof module?a(b("../../lib/codemirror")):"function"==typeof c&&c.amd?c("codemirror/mode/css/css",["../../lib/codemirror"],a):a(CodeMirror)}(function(a){"use strict";function b(a){for(var b={},c=0;c*\/]/.test(c)?d(null,"select-op"):"."==c&&a.match(/^-?[_a-z][_a-z0-9-]*/i)?d("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(c)?d(null,c):"u"==c&&a.match(/rl(-prefix)?\(/)||"d"==c&&a.match("omain(")||"r"==c&&a.match("egexp(")?(a.backUp(1),b.tokenize=g,d("property","word")):/[\w\\\-]/.test(c)?(a.eatWhile(/[\w\\\-]/),d("property","word")):d(null,null):/[\d.]/.test(a.peek())?(a.eatWhile(/[\w.%]/),d("number","unit")):a.match(/^-[\w\\\-]+/)?(a.eatWhile(/[\w\\\-]/),a.match(/^\s*:/,!1)?d("variable-2","variable-definition"):d("variable-2","variable")):a.match(/^\w+-/)?d("meta","meta"):void 0}function f(a){return function(b,c){for(var e,f=!1;null!=(e=b.next());){if(e==a&&!f){")"==a&&b.backUp(1);break}f=!f&&"\\"==e}return(e==a||!f&&")"!=a)&&(c.tokenize=null),d("string","string")}}function g(a,b){return a.next(),a.match(/\s*[\"\')]/,!1)?b.tokenize=null:b.tokenize=f(")"),d(null,"(")}function h(a,b,c){this.type=a,this.indent=b,this.prev=c}function i(a,b,c,d){return a.context=new h(c,b.indentation()+(d===!1?0:q),a.context),c}function j(a){return a.context.prev&&(a.context=a.context.prev),a.context.type}function k(a,b,c){return E[c.context.type](a,b,c)}function l(a,b,c,d){for(var e=d||1;e>0;e--)c.context=c.context.prev;return k(a,b,c)}function m(a){var b=a.current().toLowerCase();p=B.hasOwnProperty(b)?"atom":A.hasOwnProperty(b)?"keyword":"variable"}var n=c.inline;c.propertyKeywords||(c=a.resolveMode("text/css"));var o,p,q=b.indentUnit,r=c.tokenHooks,s=c.documentTypes||{},t=c.mediaTypes||{},u=c.mediaFeatures||{},v=c.mediaValueKeywords||{},w=c.propertyKeywords||{},x=c.nonStandardPropertyKeywords||{},y=c.fontProperties||{},z=c.counterDescriptors||{},A=c.colorKeywords||{},B=c.valueKeywords||{},C=c.allowNested,D=c.supportsAtComponent===!0,E={};return E.top=function(a,b,c){if("{"==a)return i(c,b,"block");if("}"==a&&c.context.prev)return j(c);if(D&&/@component/.test(a))return i(c,b,"atComponentBlock");if(/^@(-moz-)?document$/.test(a))return i(c,b,"documentTypes");if(/^@(media|supports|(-moz-)?document|import)$/.test(a))return i(c,b,"atBlock");if(/^@(font-face|counter-style)/.test(a))return c.stateArg=a,"restricted_atBlock_before";if(/^@(-(moz|ms|o|webkit)-)?keyframes$/.test(a))return"keyframes";if(a&&"@"==a.charAt(0))return i(c,b,"at");if("hash"==a)p="builtin";else if("word"==a)p="tag";else{if("variable-definition"==a)return"maybeprop";if("interpolation"==a)return i(c,b,"interpolation");if(":"==a)return"pseudo";if(C&&"("==a)return i(c,b,"parens")}return c.context.type},E.block=function(a,b,c){if("word"==a){var d=b.current().toLowerCase();return w.hasOwnProperty(d)?(p="property","maybeprop"):x.hasOwnProperty(d)?(p="string-2","maybeprop"):C?(p=b.match(/^\s*:(?:\s|$)/,!1)?"property":"tag","block"):(p+=" error","maybeprop")}return"meta"==a?"block":C||"hash"!=a&&"qualifier"!=a?E.top(a,b,c):(p="error","block")},E.maybeprop=function(a,b,c){return":"==a?i(c,b,"prop"):k(a,b,c)},E.prop=function(a,b,c){if(";"==a)return j(c);if("{"==a&&C)return i(c,b,"propBlock");if("}"==a||"{"==a)return l(a,b,c);if("("==a)return i(c,b,"parens");if("hash"!=a||/^#([0-9a-fA-f]{3,4}|[0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/.test(b.current())){if("word"==a)m(b);else if("interpolation"==a)return i(c,b,"interpolation")}else p+=" error";return"prop"},E.propBlock=function(a,b,c){return"}"==a?j(c):"word"==a?(p="property","maybeprop"):c.context.type},E.parens=function(a,b,c){return"{"==a||"}"==a?l(a,b,c):")"==a?j(c):"("==a?i(c,b,"parens"):"interpolation"==a?i(c,b,"interpolation"):("word"==a&&m(b),"parens")},E.pseudo=function(a,b,c){return"word"==a?(p="variable-3",c.context.type):k(a,b,c)},E.documentTypes=function(a,b,c){return"word"==a&&s.hasOwnProperty(b.current())?(p="tag",c.context.type):E.atBlock(a,b,c)},E.atBlock=function(a,b,c){if("("==a)return i(c,b,"atBlock_parens");if("}"==a||";"==a)return l(a,b,c);if("{"==a)return j(c)&&i(c,b,C?"block":"top");if("interpolation"==a)return i(c,b,"interpolation");if("word"==a){var d=b.current().toLowerCase();p="only"==d||"not"==d||"and"==d||"or"==d?"keyword":t.hasOwnProperty(d)?"attribute":u.hasOwnProperty(d)?"property":v.hasOwnProperty(d)?"keyword":w.hasOwnProperty(d)?"property":x.hasOwnProperty(d)?"string-2":B.hasOwnProperty(d)?"atom":A.hasOwnProperty(d)?"keyword":"error"}return c.context.type},E.atComponentBlock=function(a,b,c){return"}"==a?l(a,b,c):"{"==a?j(c)&&i(c,b,C?"block":"top",!1):("word"==a&&(p="error"),c.context.type)},E.atBlock_parens=function(a,b,c){return")"==a?j(c):"{"==a||"}"==a?l(a,b,c,2):E.atBlock(a,b,c)},E.restricted_atBlock_before=function(a,b,c){return"{"==a?i(c,b,"restricted_atBlock"):"word"==a&&"@counter-style"==c.stateArg?(p="variable","restricted_atBlock_before"):k(a,b,c)},E.restricted_atBlock=function(a,b,c){return"}"==a?(c.stateArg=null,j(c)):"word"==a?(p="@font-face"==c.stateArg&&!y.hasOwnProperty(b.current().toLowerCase())||"@counter-style"==c.stateArg&&!z.hasOwnProperty(b.current().toLowerCase())?"error":"property","maybeprop"):"restricted_atBlock"},E.keyframes=function(a,b,c){return"word"==a?(p="variable","keyframes"):"{"==a?i(c,b,"top"):k(a,b,c)},E.at=function(a,b,c){return";"==a?j(c):"{"==a||"}"==a?l(a,b,c):("word"==a?p="tag":"hash"==a&&(p="builtin"),"at")},E.interpolation=function(a,b,c){return"}"==a?j(c):"{"==a||";"==a?l(a,b,c):("word"==a?p="variable":"variable"!=a&&"("!=a&&")"!=a&&(p="error"),"interpolation")},{startState:function(a){return{tokenize:null,state:n?"block":"top",stateArg:null,context:new h(n?"block":"top",a||0,null)}},token:function(a,b){if(!b.tokenize&&a.eatSpace())return null;var c=(b.tokenize||e)(a,b);return c&&"object"==typeof c&&(o=c[1],c=c[0]),p=c,b.state=E[b.state](o,a,b),p},indent:function(a,b){var c=a.context,d=b&&b.charAt(0),e=c.indent;return"prop"!=c.type||"}"!=d&&")"!=d||(c=c.prev),c.prev&&("}"!=d||"block"!=c.type&&"top"!=c.type&&"interpolation"!=c.type&&"restricted_atBlock"!=c.type?(")"!=d||"parens"!=c.type&&"atBlock_parens"!=c.type)&&("{"!=d||"at"!=c.type&&"atBlock"!=c.type)||(e=Math.max(0,c.indent-q),c=c.prev):(c=c.prev,e=c.indent)),e},electricChars:"}",blockCommentStart:"/*",blockCommentEnd:"*/",fold:"brace"}});var d=["domain","regexp","url","url-prefix"],e=b(d),f=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],g=b(f),h=["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"],i=b(h),j=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],k=b(j),l=["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","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","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","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","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"],m=b(l),n=["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"],o=b(n),p=["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"],q=b(p),r=["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"],s=b(r),t=["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"],u=b(t),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","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","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","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","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","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","spell-out","square","square-button","start","static","status-bar","stretch","stroke","sub","subpixel-antialiased","super","sw-resize","symbolic","symbols","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","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","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=b(v),x=d.concat(f).concat(h).concat(j).concat(l).concat(n).concat(t).concat(v); -a.registerHelper("hintWords","css",x),a.defineMIME("text/css",{documentTypes:e,mediaTypes:g,mediaFeatures:i,mediaValueKeywords:k,propertyKeywords:m,nonStandardPropertyKeywords:o,fontProperties:q,counterDescriptors:s,colorKeywords:u,valueKeywords:w,tokenHooks:{"/":function(a,b){return!!a.eat("*")&&(b.tokenize=c,c(a,b))}},name:"css"}),a.defineMIME("text/x-scss",{mediaTypes:g,mediaFeatures:i,mediaValueKeywords:k,propertyKeywords:m,nonStandardPropertyKeywords:o,colorKeywords:u,valueKeywords:w,fontProperties:q,allowNested:!0,tokenHooks:{"/":function(a,b){return a.eat("/")?(a.skipToEnd(),["comment","comment"]):a.eat("*")?(b.tokenize=c,c(a,b)):["operator","operator"]},":":function(a){return!!a.match(/\s*\{/)&&[null,"{"]},$:function(a){return a.match(/^[\w-]+/),a.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(a){return!!a.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),a.defineMIME("text/x-less",{mediaTypes:g,mediaFeatures:i,mediaValueKeywords:k,propertyKeywords:m,nonStandardPropertyKeywords:o,colorKeywords:u,valueKeywords:w,fontProperties:q,allowNested:!0,tokenHooks:{"/":function(a,b){return a.eat("/")?(a.skipToEnd(),["comment","comment"]):a.eat("*")?(b.tokenize=c,c(a,b)):["operator","operator"]},"@":function(a){return a.eat("{")?[null,"interpolation"]:!a.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/,!1)&&(a.eatWhile(/[\w\\\-]/),a.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),a.defineMIME("text/x-gss",{documentTypes:e,mediaTypes:g,mediaFeatures:i,propertyKeywords:m,nonStandardPropertyKeywords:o,fontProperties:q,counterDescriptors:s,colorKeywords:u,valueKeywords:w,supportsAtComponent:!0,tokenHooks:{"/":function(a,b){return!!a.eat("*")&&(b.tokenize=c,c(a,b))}},name:"css",helperType:"gss"})}),function(a){"object"==typeof exports&&"object"==typeof module?a(b("../../lib/codemirror"),b("../xml/xml"),b("../javascript/javascript"),b("../css/css")):"function"==typeof c&&c.amd?c("codemirror/mode/htmlmixed/htmlmixed",["../../lib/codemirror","../xml/xml","../javascript/javascript","../css/css"],a):a(CodeMirror)}(function(a){"use strict";function b(a,b,c){var d=a.current(),e=d.search(b);return e>-1?a.backUp(d.length-e):d.match(/<\/?$/)&&(a.backUp(d.length),a.match(b,!1)||a.match(d)),c}function c(a){var b=i[a];return b?b:i[a]=new RegExp("\\s+"+a+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*")}function d(a,b){var d=a.match(c(b));return d?/^\s*(.*?)\s*$/.exec(d[2])[1]:""}function e(a,b){return new RegExp((b?"^":"")+"","i")}function f(a,b){for(var c in a)for(var d=b[c]||(b[c]=[]),e=a[c],f=e.length-1;f>=0;f--)d.unshift(e[f])}function g(a,b){for(var c=0;c\s\/]/.test(d.current())&&(h=f.htmlState.tagName&&f.htmlState.tagName.toLowerCase())&&k.hasOwnProperty(h))f.inTag=h+" ";else if(f.inTag&&m&&/>$/.test(d.current())){var n=/^([\S]+) (.*)/.exec(f.inTag);f.inTag=null;var o=">"==d.current()&&g(k[n[1]],n[2]),p=a.getMode(c,o),q=e(n[1],!0),r=e(n[1],!1);f.token=function(a,c){return a.match(q,!1)?(c.token=i,c.localState=c.localMode=null,null):b(a,r,c.localMode.token(a,c.localState))},f.localMode=p,f.localState=a.startState(p,j.indent(f.htmlState,""))}else f.inTag&&(f.inTag+=d.current(),d.eol()&&(f.inTag+=" "));return l}var j=a.getMode(c,{name:"xml",htmlMode:!0,multilineTagIndentFactor:d.multilineTagIndentFactor,multilineTagIndentPastTag:d.multilineTagIndentPastTag}),k={},l=d&&d.tags,m=d&&d.scriptTypes;if(f(h,k),l&&f(l,k),m)for(var n=m.length-1;n>=0;n--)k.script.unshift(["type",m[n].matches,m[n].mode]);return{startState:function(){var b=a.startState(j);return{token:i,inTag:null,localMode:null,localState:null,htmlState:b}},copyState:function(b){var c;return b.localState&&(c=a.copyState(b.localMode,b.localState)),{token:b.token,inTag:b.inTag,localMode:b.localMode,localState:c,htmlState:a.copyState(j,b.htmlState)}},token:function(a,b){return b.token(a,b)},indent:function(b,c){return!b.localMode||/^\s*<\//.test(c)?j.indent(b.htmlState,c):b.localMode.indent?b.localMode.indent(b.localState,c):a.Pass},innerMode:function(a){return{state:a.localState||a.htmlState,mode:a.localMode||j}}}},"xml","javascript","css"),a.defineMIME("text/html","htmlmixed")}),function(a){"object"==typeof exports&&"object"==typeof module?a(b("codemirror/lib/codemirror")):"function"==typeof c&&c.amd?c("formatting",["codemirror/lib/codemirror"],a):a(CodeMirror)}(function(a){a.extendMode("css",{commentStart:"/*",commentEnd:"*/",newlineAfterToken:function(a,b){return/^[;{}]$/.test(b)}}),a.extendMode("javascript",{commentStart:"/*",commentEnd:"*/",newlineAfterToken:function(a,b,c,d){return this.jsonMode?/^[\[,{]$/.test(b)||/^}/.test(c):(";"!=b||!d.lexical||")"!=d.lexical.type)&&(/^[;{}]$/.test(b)&&!/^;/.test(c))}});var b=/^(a|abbr|acronym|area|base|bdo|big|br|button|caption|cite|code|col|colgroup|dd|del|dfn|em|frame|hr|iframe|img|input|ins|kbd|label|legend|link|map|object|optgroup|option|param|q|samp|script|select|small|span|strong|sub|sup|textarea|tt|var)$/;a.extendMode("xml",{commentStart:"",newlineAfterToken:function(a,c,d,e){var f=!1;return"html"==this.configuration&&(f=!!e.context&&b.test(e.context.tagName)),!f&&("tag"==a&&/>$/.test(c)&&e.context||/^-1&&h>-1&&h>g&&(a=a.substr(0,g)+a.substring(g+f.commentStart.length,h)+a.substr(h+f.commentEnd.length)),e.replaceRange(a,c,d)}})}),a.defineExtension("autoIndentRange",function(a,b){var c=this;this.operation(function(){for(var d=a.line;d<=b.line;d++)c.indentLine(d,"smart")})}),a.defineExtension("autoFormatRange",function(b,c){function d(){j+="\n",l=!0,++k}for(var e=this,f=e.getMode(),g=e.getRange(b,c).split("\n"),h=a.copyState(f,e.getTokenAt(b).state),i=e.getOption("tabSize"),j="",k=0,l=0===b.ch,m=0;m\n\t
<%= label %>
\n\t
\n\n'}),c("CodeManager/view/EditorView",["backbone","text!./../template/editor.html"],function(a,b){return a.View.extend({template:_.template(b),initialize:function(a){this.config=a.config||{},this.pfx=this.config.stylePrefix},render:function(){var a=this.model.toJSON();return a.pfx=this.pfx,this.$el.html(this.template(a)),this.$el.attr("class",this.pfx+"editor-c"),this.$el.find("#"+this.pfx+"code").html(this.model.get("input")),this}})}),c("CodeManager/main",["require","./config/config","./model/HtmlGenerator","./model/CssGenerator","./model/JsonGenerator","./model/JsGenerator","./model/CodeMirrorEditor","./view/EditorView"],function(a){var b=function(){var b={},c=a("./config/config"),d=a("./model/HtmlGenerator"),e=a("./model/CssGenerator"),f=a("./model/JsonGenerator"),g=a("./model/JsGenerator"),h=a("./model/CodeMirrorEditor"),i=a("./view/EditorView"),j={},k={},l={},m={};return{getConfig:function(){return b},config:b,EditorView:i,name:"CodeManager",init:function(a){b=a||{};for(var i in c)i in b||(b[i]=c[i]);var j=b.pStylePrefix;return j&&(b.stylePrefix=j+b.stylePrefix),k.html=new d,k.css=new e,k.json=new f,k.js=new g,m.CodeMirror=new h,this},onLoad:function(){this.loadDefaultGenerators().loadDefaultViewers()},addGenerator:function(a,b){return j[a]=b,this},getGenerator:function(a){return j[a]||null},getGenerators:function(){return j},addViewer:function(a,b){return l[a]=b,this},getViewer:function(a){return l[a]||null},getViewers:function(){return l},updateViewer:function(a,b){a.setContent(b)},getCode:function(a,b,c){var d=this.getGenerator(b);return d?d.build(a,c):""},loadDefaultGenerators:function(){for(var a in k)this.addGenerator(a,k[a]);return this},loadDefaultViewers:function(){for(var a in m)this.addViewer(a,m[a]);return this}}};return b}),c("CodeManager",["CodeManager/main"],function(a){return a}),c("Panels/config/config",[],function(){var a="create-comp",b="move-comp",c="sw-visibility",d="export-template",e="open-sm",f="open-tm",g="open-layers",h="open-blocks",i="fullscreen",j="preview";return{stylePrefix:"pn-",defaults:[{id:"commands",buttons:[{id:a,command:a,className:"fa fa-pencil-square-o",attributes:{title:"Create element"},stopDefaultCommand:1},{id:b,command:b,className:"fa fa-arrows",attributes:{title:"Move elements"},stopDefaultCommand:1}]},{id:"options",buttons:[{active:!0,id:c,className:"fa fa-square-o",command:c,context:c,attributes:{title:"View components"}},{id:j,className:"fa fa-eye",command:j,context:j,stopDefaultCommand:1,attributes:{title:"Preview"}},{id:i,className:"fa fa-arrows-alt",command:i,context:i,attributes:{title:"Fullscreen"}},{id:d,className:"fa fa-code",command:d,attributes:{title:"View code"}}]},{id:"views",buttons:[{id:e,className:"fa fa-paint-brush",command:e,active:!0,attributes:{title:"Open Style Manager"}},{id:f,className:"fa fa-cog",command:f,attributes:{title:"Settings"}},{id:g,className:"fa fa-bars",command:g,attributes:{title:"Open Layer Manager"}},{id:h,className:"fa fa-th-large",command:h,attributes:{title:"Open Blocks"}}]}],em:null,delayBtnsShow:300}}),c("Panels/model/Button",["backbone","require"],function(a,b){return a.Model.extend({defaults:{id:"",className:"",command:"",context:"",buttons:[],attributes:{},options:{},active:!1,dragDrop:!1,runDefaultCommand:!0,stopDefaultCommand:!1},initialize:function(a){if(this.get("buttons").length){var c=b("./Buttons");this.set("buttons",new c(this.get("buttons")))}}})}),c("Panels/model/Buttons",["backbone","./Button"],function(a,b){return a.Collection.extend({model:b,deactivateAllExceptOne:function(a,b){this.forEach(function(c,d){c!==a&&(c.set("active",!1),b&&c.get("buttons").length&&c.get("buttons").deactivateAllExceptOne(a,b))})},deactivateAll:function(a){var b=a||"";this.forEach(function(a,c){a.get("context")==b&&(a.set("active",!1),a.get("buttons").length&&a.get("buttons").deactivateAll(b))})}})}),c("Panels/model/Panel",["backbone","./Buttons"],function(a,b){return a.Model.extend({defaults:{id:"",content:"",visible:!0,buttons:[]},initialize:function(a){this.btn=this.get("buttons")||[],this.buttons=new b(this.btn),this.set("buttons",this.buttons)}})}),c("Panels/model/Panels",["backbone","./Panel"],function(a,b){return a.Collection.extend({model:b})}),c("Panels/view/ButtonView",["backbone","require"],function(a,b){return a.View.extend({tagName:"span",initialize:function(a){_.bindAll(this,"startTimer","stopTimer","showButtons","hideButtons","closeOnKeyPress","onDrop","initSorter","stopDrag");var b=this.model.get("className");this.config=a.config||{},this.em=this.config.em||{},this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.id=this.pfx+this.model.get("id"),this.activeCls=this.pfx+"active",this.btnsVisCls=this.pfx+"visible",this.parentM=a.parentM||null,this.className=this.pfx+"btn"+(b?" "+b:""),this.listenTo(this.model,"change:active updateActive",this.updateActive),this.listenTo(this.model,"checkActive",this.checkActive),this.listenTo(this.model,"change:bntsVis",this.updateBtnsVis),this.listenTo(this.model,"change:attributes",this.updateAttributes),this.listenTo(this.model,"change:className",this.updateClassName),this.model.get("buttons").length&&(this.$el.on("mousedown",this.startTimer),this.$el.append($("
",{"class":this.pfx+"arrow-rd"}))),this.em&&this.em.get&&(this.commands=this.em.get("Commands")),this.events={},this.model.get("dragDrop")?(this.events.mousedown="initDrag",this.em.on("loaded",this.initSorter)):this.events.click="clicked",this.delegateEvents()},initSorter:function(){if(this.em.Canvas){var a=this.em.Canvas;this.canvasEl=a.getBody(),this.sorter=new this.em.Utils.Sorter({container:this.canvasEl,placer:a.getPlacerEl(),containerSel:"*",itemSel:"*",pfx:this.ppfx,onMove:this.onDrag,onEndMove:this.onDrop,document:a.getFrameEl().contentDocument,direction:"a",wmargin:1,nested:1});var b=a.getOffset();this.sorter.offTop=b.top,this.sorter.offLeft=b.left}},initDrag:function(){this.model.collection.deactivateAll(this.model.get("context")),this.sorter.startSort(this.el),this.sorter.setDropContent(this.model.get("options").content),this.canvasEl.style.cursor="grabbing",$(document).on("mouseup",this.stopDrag)},stopDrag:function(){$(document).off("mouseup",this.stopDrag),this.sorter.endMove()},onDrag:function(a){},onDrop:function(a){this.canvasEl.style.cursor="default"},updateClassName:function(){var a=this.model.get("className");this.$el.attr("class",this.pfx+"btn"+(a?" "+a:""))},updateAttributes:function(){this.$el.attr(this.model.get("attributes"))},updateBtnsVis:function(){this.$buttons&&(this.model.get("bntsVis")?this.$buttons.addClass(this.btnsVisCls):this.$buttons.removeClass(this.btnsVisCls))},startTimer:function(){this.timeout=setTimeout(this.showButtons,this.config.delayBtnsShow),$(document).on("mouseup",this.stopTimer)},stopTimer:function(){$(document).off("mouseup",this.stopTimer),this.timeout&&clearTimeout(this.timeout)},showButtons:function(){clearTimeout(this.timeout),this.model.set("bntsVis",!0),$(document).on("mousedown",this.hideButtons),$(document).on("keypress",this.closeOnKeyPress)},hideButtons:function(a){a&&$(a.target).trigger("click"),this.model.set("bntsVis",!1),$(document).off("mousedown",this.hideButtons),$(document).off("keypress",this.closeOnKeyPress)},closeOnKeyPress:function(a){var b=a.which||a.keyCode;27==b&&this.hideButtons()},updateActive:function(){var a=null,b=this.em&&this.em.get?this.em.get("Editor"):null,c=this.model.get("command");this.commands&&"string"==typeof c?a=this.commands.get(c):null!==c&&"object"==typeof c?a=c:"function"==typeof c&&(a={run:c}),this.model.get("active")?(this.model.collection.deactivateAll(this.model.get("context")),this.model.set("active",!0,{silent:!0}).trigger("checkActive"),this.parentM&&this.parentM.set("active",!0,{silent:!0}).trigger("checkActive"),a&&a.run&&(a.run(b,this.model,this.model.get("options")),b.trigger("run:"+c))):(this.$el.removeClass(this.activeCls),this.model.collection.deactivateAll(this.model.get("context")),this.parentM&&this.parentM.set("active",!1,{silent:!0}).trigger("checkActive"),a&&a.stop&&(a.stop(b,this.model,this.model.get("options")),b.trigger("stop:"+c)))},checkActive:function(){this.model.get("active")?this.$el.addClass(this.activeCls):this.$el.removeClass(this.activeCls)},clicked:function(a){if(!this.model.get("bntsVis")){this.parentM&&this.swapParent();var b=this.model.get("active");this.model.set("active",!b);this.em.get("Commands").get("select-comp");b?this.model.get("runDefaultCommand")&&this.em.runDefault():this.model.get("stopDefaultCommand")&&this.em.stopDefault()}},swapParent:function(){this.parentM.collection.deactivateAll(this.model.get("context")),this.parentM.set("attributes",this.model.get("attributes")),this.parentM.set("options",this.model.get("options")),this.parentM.set("command",this.model.get("command")),this.parentM.set("className",this.model.get("className")),this.parentM.set("active",!0,{silent:!0}).trigger("checkActive")},render:function(){if(this.updateAttributes(),this.$el.attr("class",this.className),this.model.get("buttons").length){var a=b("./ButtonsView"),c=new a({collection:this.model.get("buttons"),config:this.config,parentM:this.model});this.$buttons=c.render().$el,this.$buttons.append($("
",{"class":this.pfx+"arrow-l"})),this.$el.append(this.$buttons)}return this}})}),c("Panels/view/ButtonsView",["backbone","./ButtonView"],function(a,b){return a.View.extend({initialize:function(a){this.opt=a||{},this.config=this.opt.config||{},this.pfx=this.config.stylePrefix||"",this.parentM=this.opt.parentM||null,this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"reset",this.render),this.className=this.pfx+"buttons"},addTo:function(a){this.addToCollection(a)},addToCollection:function(a,c){var d=c||null,e=b,f=new e({model:a,config:this.config,parentM:this.parentM}),g=f.render().el;return d?d.appendChild(g):this.$el.append(g),g},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.addToCollection(b,a)},this),this.$el.append(a),this.$el.attr("class",_.result(this,"className")),this}})}),c("Panels/view/PanelView",["backbone","./ButtonsView"],function(a,b){return a.View.extend({initialize:function(a){this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.buttons=this.model.get("buttons"),this.className=this.pfx+"panel",this.id=this.pfx+this.model.get("id"),this.listenTo(this.model,"change:appendContent",this.appendContent),this.listenTo(this.model,"change:content",this.updateContent)},appendContent:function(){this.$el.append(this.model.get("appendContent"))},updateContent:function(){this.$el.html(this.model.get("content"))},render:function(){if(this.$el.attr("class",_.result(this,"className")),this.id&&this.$el.attr("id",this.id),this.buttons.length){var a=new b({collection:this.buttons,config:this.config});this.$el.append(a.render().el)}return this.$el.append(this.model.get("content")),this}})}),c("Panels/view/PanelsView",["backbone","./PanelView"],function(a,b){return a.View.extend({initialize:function(a){this.opt=a||{},this.config=this.opt.config||{},this.pfx=this.config.stylePrefix||"",this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"reset",this.render),this.className=this.pfx+"panels"},addTo:function(a){this.addToCollection(a)},addToCollection:function(a,c){var d=c||null,e=b,f=new e({model:a,config:this.config}),g=f.render().el;return d?d.appendChild(g):this.$el.append(g),g},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.addToCollection(b,a)},this),this.$el.append(a),this.$el.attr("class",_.result(this,"className")),this}})}),c("Panels/main",["require","./config/config","./model/Panel","./model/Panels","./view/PanelView","./view/PanelsView"],function(a){return function(){var b,c,d={},e=a("./config/config"),f=a("./model/Panel"),g=a("./model/Panels"),h=(a("./view/PanelView"),a("./view/PanelsView"));return{name:"Panels",init:function(a){d=a||{};for(var f in e)f in d||(d[f]=e[f]);var i=d.pStylePrefix;return i&&(d.stylePrefix=i+d.stylePrefix),b=new g(d.defaults),c=new h({collection:b,config:d}),this},getPanels:function(){return b},getPanelsEl:function(){return c.el},addPanel:function(a){return b.add(a)},getPanel:function(a){var c=b.where({id:a});return c.length?c[0]:null},addButton:function(a,b){var c=this.getPanel(a);return c?c.get("buttons").add(b):null},getButton:function(a,b){var c=this.getPanel(a);if(c){var d=c.get("buttons").where({id:b});return d.length?d[0]:null}return null},render:function(){return c.render().el},active:function(){this.getPanels().each(function(a){a.get("buttons").each(function(a){a.get("active")&&a.trigger("updateActive")})})},Panel:f}}}),c("Panels",["Panels/main"],function(a){return a}),c("RichTextEditor/config/config",[],function(){return{stylePrefix:"rte-",toolbarId:"toolbar",containerId:"wrapper",commands:[{command:"bold",title:"Bold","class":"fa fa-bold"},{command:"italic",title:"Italic","class":"fa fa-italic"},{command:"underline",title:"Underline","class":"fa fa-underline"},{command:"strikethrough",title:"Strikethrough","class":"fa fa-strikethrough",group:"format"},{command:"insertHTML",title:"Link","class":"fa fa-link",args:'${content}'}]}}),c("RichTextEditor/view/TextEditorView",["jquery"],function(a){var b=function(b){var c=a.Deferred(),d=new FileReader;return d.onload=function(a){c.resolve(a.target.result)},d.onerror=c.reject,d.onprogress=c.notify,d.readAsDataURL(b),c.promise()};return a.fn.cleanHtml=function(){var b=a(this).html();return b&&b.replace(/(
|\s|

<\/div>| )*$/,"")},a.fn.wysiwyg=function(c){var d,e,f,g=this,h=function(){var b=e.activeToolbarClass;b&&a(e.toolbarSelector).find(f).each(function(){var c=a(this),d=c.data(e.commandRole),f=g.get(0).ownerDocument;f.queryCommandState(d)?c.addClass(b):c.removeClass(b)})},i=function(a,b){var c=a.split(" "),d=c.shift(),e=c.join(" ")+(b||"");g.get(0).ownerDocument.execCommand("styleWithCSS",!1,!0),g.get(0).ownerDocument.execCommand(d,0,e),h(),g.trigger("change")},j=function(){var a=window.getSelection();if(a.getRangeAt&&a.rangeCount)return a.getRangeAt(0)},k=function(){d=j()},l=function(){var a=window.getSelection();if(d){try{a.removeAllRanges()}catch(b){document.body.createTextRange().select(),document.selection.empty()}a.addRange(d)}},m=function(c){g.focus(),a.each(c,function(c,d){/^image\//.test(d.type)?a.when(b(d)).done(function(a){i("insertimage",a)}).fail(function(a){e.fileUploadError("file-reader",a)}):e.fileUploadError("unsupported-file-type",d.type)})},n=function(a,b){l(),document.queryCommandSupported("hiliteColor")&&document.execCommand("hiliteColor",0,b||"transparent"),k(),a.data(e.selectionMarker,b)},o=function(b,c){b.find(f).unbind().click(function(){l();var b=g.get(0).ownerDocument,d=a(this),e=d.data(c.commandRole),f=d.data("args");f?(f=f.replace("${content}",b.getSelection()),i(e,f)):b.execCommand(e),k()}),b.find("[data-toggle=dropdown]").click(l);var d="[data-"+c.commandRole+"]";b.find("select"+d).on("webkitspeechchange change",function(){var b=this.value;l(),b&&(g.focus(),i(a(this).data(c.commandRole),b)),k()}),b.find("input[type=text]"+d,", select"+d).on("webkitspeechchange change",function(){var b=this.value;this.value="",l(),b&&(g.focus(),i(a(this).data(c.commandRole),b)),k()}).on("focus",function(){var b=a(this);b.data(c.selectionMarker)||(n(b,c.selectionColor),b.focus())}).on("blur",function(){var b=a(this);b.data(c.selectionMarker)&&n(b,!1)}),b.find("input[type=file][data-"+c.commandRole+"]").change(function(){l(),"file"===this.type&&this.files&&this.files.length>0&&m(this.files),k(),this.value=""})},p=function(){g.on("dragenter dragover",!1).on("drop",function(a){var b=a.originalEvent.dataTransfer;a.stopPropagation(),a.preventDefault(),b&&b.files&&b.files.length>0&&m(b.files)})};if("string"==typeof c&&"destroy"==c)return g.attr("contenteditable",!1).unbind("mouseup keyup mouseout dragenter dragover"),a(window).unbind("touchend"),this;e=a.extend({},a.fn.wysiwyg.defaults,c);var q="[data-"+e.commandRole+"]";return f="a"+q+",button"+q+",input[type=button]"+q+", select"+q,e.dragAndDropImages&&p(),o(a(e.toolbarSelector),e),g.attr("contenteditable",!0).on("mouseup keyup mouseout",function(){k(),h()}),a(window).bind("touchend",function(a){var b=g.is(a.target)||g.has(a.target).length>0,c=j(),d=c&&c.startContainer===c.endContainer&&c.startOffset===c.endOffset;d&&!b||(k(),h())}),this},a.fn.wysiwyg.defaults={toolbarSelector:"[data-role=editor-toolbar]",commandRole:"edit",activeToolbarClass:"btn-info",selectionMarker:"edit-focus-marker",selectionColor:"darkgrey",dragAndDropImages:!0,fileUploadError:function(a,b){console.log("File upload error",a,b)}},a}),c("RichTextEditor/model/CommandButton",["backbone"],function(a){return a.Model.extend({idAttribute:"command",defaults:{command:"",type:"",title:"","class":"",options:[]},initialize:function(){var a=this.get("options");a.length&&this.set("type","select")}})}),c("RichTextEditor/model/CommandButtons",["backbone","./CommandButton"],function(a,b){return a.Collection.extend({model:b})}),c("RichTextEditor/view/CommandButtonView",["backbone"],function(a){return a.View.extend({tagName:"a",initialize:function(a,b){this.config=b||{},this.ppfx=this.config.pStylePrefix||"",this.className=this.config.stylePrefix+"btn "+this.model.get("class")},render:function(){return this.$el.addClass(this.className),this}})}),c("RichTextEditor/view/CommandButtonSelectView",["backbone","./CommandButtonView"],function(a,b){return b.extend({initialize:function(a,c){b.prototype.initialize.apply(this,arguments)},getInput:function(){var a=this.model;if(!this.input){var b=a.get("command"),c='",this.input=$(c)}return this.input},getInputCont:function(){var a=this.getInput(),b=this.ppfx,c=$('
');return c.append(a)},render:function(){return b.prototype.render.apply(this,arguments),this.$el.html(this.getInputCont()),this}})}),c("RichTextEditor/view/CommandButtonsView",["backbone","./CommandButtonView","./CommandButtonSelectView"],function(a,b,c){return a.View.extend({attributes:{"data-role":"editor-toolbar"},initialize:function(a){this.config=a.config||{};var b=this.config.stylePrefix||"";this.id=b+this.config.toolbarId,this.listenTo(this.collection,"add",this.addTo),this.$el.data("helper",1)},addTo:function(a){this.add(a)},add:function(a,d){var e=d||null,f=b;switch(a.get("type")){case"select":f=c}var g=a.get("args"),h={title:a.get("title"),"data-edit":a.get("command")};g&&(h["data-args"]=g);var i=new f({model:a,attributes:h},this.config),j=i.render().el;e?e.appendChild(j):this.$el.append(j)},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.add(b,a)},this),this.$el.append(a),this.$el.attr("id",this.id),this}})}),c("RichTextEditor/main",["require","./config/config","./view/TextEditorView","./model/CommandButtons","./view/CommandButtonsView"],function(a){return function(){var b,c,d,e,f={},g=a("./config/config"),h=(a("./view/TextEditorView"),a("./model/CommandButtons")),i=a("./view/CommandButtonsView");return{customRte:null,name:"rte",init:function(a){e=this,f=a||{};for(var j in g)j in f||(f[j]=g[j]);var k=f.pStylePrefix;return k&&(f.stylePrefix=k+f.stylePrefix),b=f.stylePrefix,d=new h(f.commands),c=new i({collection:d,config:f}),this},add:function(a,b){var c=b||{};return c.command=a,d.add(c)},get:function(a){return d.where({command:a})[0]},getAll:function(){return d},udpatePosition:function(){var a="px",b=f.em.get("Canvas"),d=b.getTargetToElementDim(c.el,this.lastEl,{event:"rteToolbarPosUpdate"}),e=c.el.style;e.top=d.top+a,e.left=d.left+a},attach:function(a,b){this.lastEl=a.el;var d=a.getChildrenContainer(),e=this.customRte;return e?b=e.enable(d,b):$(d).wysiwyg({}).focus(),this.show(),f.em&&(setTimeout(this.udpatePosition.bind(this),0),f.em.off("change:canvasOffset",this.udpatePosition,this),f.em.on("change:canvasOffset",this.udpatePosition,this),f.em.off("canvasScroll",this.udpatePosition,this),f.em.on("canvasScroll",this.udpatePosition,this)),c.$el.on("mousedown",this.disableProp),b},detach:function(a,b){var d=this.customRte,e=a.getChildrenContainer();d?(a.model.set("content",e.innerHTML),d.disable(e,b)):$(e).wysiwyg("destroy"),this.hide(),c.$el.off("mousedown",this.disableProp)},focus:function(a,b){var c=this.customRte,d=a.getChildrenContainer();c?c.focus&&c.focus(d,b):this.attach(a)},show:function(){var a=c.el.style;a.display="block"},hide:function(){c.el.style.display="none"},disableProp:function(a){a.stopPropagation()},getToolbarEl:function(){return c.el},render:function(){return c.render().el}}}}),c("RichTextEditor",["RichTextEditor/main"],function(a){return a}),c("StyleManager/config/config",[],function(){return{stylePrefix:"sm-",sectors:[],textNoElement:"Select an element before using Style Manager",hideNotStylable:!0}}),c("StyleManager/model/Layer",["backbone"],function(a){return a.Model.extend({defaults:{index:"",value:"",values:{},active:!0,preview:!1},initialize:function(){var a=this.get("value");if(!a){var b="",c=this.get("values");for(var d in c)b+=" "+c[d];this.set("value",b.trim())}}})}),c("StyleManager/model/Layers",["backbone","./Layer"],function(a,b){return a.Collection.extend({model:b,initialize:function(){this.idx=1,this.on("add",this.onAdd),this.on("reset",this.onReset)},onAdd:function(a,b,c){c.noIncrement||a.set("index",this.idx++)},onReset:function(){this.idx=1}})}),c("StyleManager/model/Property",["backbone","./Layers","require"],function(a,b,c){return a.Model.extend({defaults:{name:"",property:"",type:"",units:[],unit:"",defaults:"",info:"",value:"",icon:"",preview:!1,detached:!1,visible:!0,functionName:"",properties:[],layers:[],list:[],fixedValues:["initial","inherit"]},initialize:function(a){var d=this.get("type"),e=this.get("name"),f=this.get("property"),g=this.get("properties");if(e||this.set("name",f.charAt(0).toUpperCase()+f.slice(1).replace(/-/g," ")),g.length){var h=c("./Properties");this.set("properties",new h(g))}switch(d){case"stack":this.set("layers",new b)}},getValue:function(){var a="",b=this.get("type");switch(b){case"integer":a=this.get("value")+this.get("unit");break;default:a=this.get("value")}return a}})}),c("StyleManager/model/Properties",["backbone","./Property"],function(a,b){return a.Collection.extend({model:b})}),c("StyleManager/model/PropertyFactory",["backbone"],function(a){return function(){return{build:function(a){var b=[];"string"==typeof a&&(a=[a]);for(var c=0,d=a.length;c\n\t
\n\t\t<%= label %>\n\t
\n
'}),c("text!StyleManager/templates/propertyInput.html",[],function(){return'
\n\tinput-holder\'>\n
\n
\n'}),c("StyleManager/view/PropertyView",["backbone","text!./../templates/propertyLabel.html","text!./../templates/propertyInput.html"],function(a,b,c){return a.View.extend({template:_.template(c),templateLabel:_.template(b),events:{change:"valueUpdated"},initialize:function(a){this.config=a.config||{},this.em=this.config.em,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.target=a.target||{},this.propTarget=a.propTarget||{},this.onChange=a.onChange||{},this.onInputRender=a.onInputRender||{},this.customValue=a.customValue||{},this.defaultValue=this.model.get("defaults"),this.property=this.model.get("property"),this.input=this.$input=null,this.className=this.pfx+"property",this.inputHolderId="#"+this.pfx+"input-holder",this.sector=this.model.collection&&this.model.collection.sector,this.model.get("value")||this.model.set("value",this.model.get("defaults")),this.listenTo(this.propTarget,"update",this.targetUpdated),this.listenTo(this.model,"destroy remove",this.remove),this.listenTo(this.model,"change:value",this.valueChanged),this.listenTo(this.model,"targetUpdated",this.targetUpdated),this.listenTo(this.model,"change:visible",this.updateVisibility)},getTarget:function(){return this.selectedComponent?this.selectedComponent:this.propTarget?this.propTarget.model:null},valueUpdated:function(){this.$input&&this.model.set("value",this.getInputValue())},targetUpdated:function(){this.selectedComponent=this.propTarget.model,this.helperComponent=this.propTarget.helper,this.checkVisibility(),this.getTarget()&&(this.sameValue()||this.renderInputRequest())},checkVisibility:function(){this.config.hideNotStylable&&(this.isTargetStylable()&&this.isComponentStylable()?this.show():this.hide(),this.sector&&this.sector.trigger("updateVisibility"))},sameValue:function(){return this.getComponentValue()==this.getValueForTarget()},getComponentValue:function(){var a=this.model,b=this.getTarget();if(b){var c=b.get("style")[this.property];if(c?this.componentValue=c:this.componentValue=this.defaultValue+(this.unit||""),a.get("functionName")){var d=this.fetchFromFunction(this.componentValue);d&&(this.componentValue=d)}if(this.customValue&&"function"==typeof this.customValue){var e=a.collection.indexOf(a),f=this.customValue(this,e);f&&(this.componentValue=f)}return this.componentValue}},getTargetValue:function(a){var b,c=a||{},d=this.model,e=this.getTarget();return e?(b=e.get("style")[d.get("property")],b||c.ignoreDefault||(b=this.getDefaultValue()),b):b},getDefaultValue:function(){return this.model.get("defaults")},fetchFromFunction:function(a){return a.substring(a.indexOf("(")+1,a.lastIndexOf(")"))},tryFetchFromFunction:function(a){if(!this.model.get("functionName"))return a;var b=a.indexOf("(")+1,c=a.lastIndexOf(")");return a.substring(b,c)},getValueForTarget:function(){return this.model.get("value")},getInputValue:function(){return this.$input?this.$input.val():""},valueChanged:function(a,b,c){var d=this.getValueForTarget(),e=this.config.em,f=this.model;if(this.$input&&this.setValue(d),this.getTarget()&&this.isTargetStylable()&&this.isComponentStylable()){value=this.getValueForTarget();var g=f.get("functionName");g&&(value=g+"("+value+")");var h=this.getTarget(),i=this.onChange;i&&"function"==typeof i?i(h,this,c):this.updateTargetStyle(value,null,c),e&&(e.trigger("component:update",f),e.trigger("component:styleUpdate",f),e.trigger("component:styleUpdate:"+f.get("property"),f))}},updateTargetStyle:function(a,b,c){var d=b||this.property,e=a||"",f=c?c.avoidStore:0,g=this.getTarget(),h=_.clone(g.get("style"));e?h[d]=e:delete h[d],g.set("style",h,{avoidStore:f}),this.helperComponent&&this.helperComponent.set("style",h,{avoidStore:f})},isTargetStylable:function(){var a=this.getTarget().get("stylable");return a instanceof Array&&(a=_.indexOf(a,this.property)>=0),a},isComponentStylable:function(){var a=this.em,b=a&&a.get("selectedComponent");if(!b)return!0;var c=b.get("stylable");return c instanceof Array&&(c=_.indexOf(c,this.property)>=0),c},setValue:function(a,b){var c=0===b?0:1,d=this.model.get("defaults"),e=this.model.get("value")||d;(a||c)&&(e=a),this.$input&&this.$input.val(e),this.model.set({value:e},{silent:!0})},updateVisibility:function(){this.el.style.display=this.model.get("visible")?"block":"none"},show:function(){this.model.set("visible",1)},hide:function(){this.model.set("visible",0)},renderLabel:function(){this.$el.html(this.templateLabel({pfx:this.pfx,ppfx:this.ppfx,icon:this.model.get("icon"),info:this.model.get("info"),label:this.model.get("name")}))},renderField:function(){this.renderTemplate(),this.renderInput(),delete this.componentValue},renderTemplate:function(){this.$el.append(this.template({pfx:this.pfx,ppfx:this.ppfx,icon:this.model.get("icon"),info:this.model.get("info"),label:this.model.get("name")}))},renderInput:function(){this.$input||(this.$input=$("",{placeholder:this.model.get("defaults"),type:"text"}),this.$el.find(this.inputHolderId).html(this.$input)),this.setValue(this.componentValue,0)},renderInputRequest:function(){this.renderInput()},cleanValue:function(){this.setValue("")},render:function(){return this.renderLabel(),this.renderField(),this.$el.attr("class",this.className),this}})}),c("text!Abstract/ui/templates/inputNumber.html",[],function(){return'input-holder\'>\nfield-units\'>\n
\n\t
\n\t
\n
\n'}),c("Abstract/ui/InputNumber",["backbone","text!./templates/inputNumber.html"],function(a,b){return a.View.extend({events:{},template:_.template(b),initialize:function(a){_.bindAll(this,"moveIncrement","upIncrement");var b=a||{},c=b.ppfx||"",d=b.contClass||c+"field";this.ppfx=c,this.docEl=$(document),this.inputCls=c+"input-number",this.unitCls=c+"input-unit",this.contClass=d,this.events["click ."+c+"field-arrow-u"]="upArrowClick",this.events["click ."+c+"field-arrow-d"]="downArrowClick",this.events["mousedown ."+c+"field-arrows"]="downIncrement",this.events["change ."+this.inputCls]="handleChange",this.events["change ."+this.unitCls]="handleUnitChange",this.listenTo(this.model,"change:unit change:value",this.handleModelChange),this.delegateEvents()},setValue:function(a,b){var c=b||{},d=this.validateInputValue(a,{deepCheck:1}),e={value:d.value};(d.unit||d.force)&&(e.unit=d.unit),this.model.set(e,c),c.silent&&this.handleModelChange()},handleChange:function(a){a.stopPropagation(),this.setValue(this.getInputEl().value)},handleUnitChange:function(a){a.stopPropagation();var b=this.getUnitEl().value;this.model.set("unit",b)},handleModelChange:function(){var a=this.model;this.getInputEl().value=a.get("value");var b=this.getUnitEl();b&&(b.value=a.get("unit"))},getInputEl:function(){return this.inputEl||(this.inputEl=$("",{type:"text","class":this.inputCls,placeholder:this.model.get("defaults")})),this.inputEl.get(0)},getUnitEl:function(){if(!this.unitEl){var a=this.model,b=a.get("units")||[];if(b.length){var c='",this.unitEl=$(c)}}return this.unitEl&&this.unitEl.get(0)},upArrowClick:function(){var a=this.model.get("value");a=isNaN(a)?1:parseInt(a,10)+1;var b=this.validateInputValue(a);this.model.set("value",b.value)},downArrowClick:function(){var a=this.model.get("value");a=isNaN(a)?0:parseInt(a,10)-1;var b=this.validateInputValue(a);this.model.set("value",b.value)},downIncrement:function(a){a.preventDefault(),this.moved=0;var b=this.model.get("value");b=isNaN(b)?0:parseInt(b,10);var c={y:a.pageY,val:b};this.docEl.mouseup(c,this.upIncrement),this.docEl.mousemove(c,this.moveIncrement)},moveIncrement:function(a){this.moved=1;var b=parseInt(a.data.val-a.pageY+a.data.y,10);return this.prValue=this.validateInputValue(b).value,this.model.set("value",this.prValue,{avoidStore:1}),!1},upIncrement:function(a){if(this.docEl.off("mouseup",this.upIncrement),this.docEl.off("mousemove",this.moveIncrement),this.prValue&&this.moved){var b=this.prValue-1;this.model.set("value",b,{avoidStore:1}).set("value",b+1)}},validateInputValue:function(a,b){var c=0,d=b||{},e=this.model,f=a||e.get("defaults"),g=e.get("units")||[],h=e.get("unit")||g.length&&g[0]||"",i=e.get("max"),j=e.get("min");if(d.deepCheck){var k=e.get("fixedValues")||[];if(f){var l=new RegExp("^"+k.join("|"),"g");if(k.length&&l.test(f))f=f.match(l)[0],h="",c=1;else{var m=f+"";f+="",f=parseFloat(f.replace(",",".")),f=isNaN(f)?e.get("defaults"):f;var n=m.replace(f,"");_.indexOf(g,n)>=0&&(h=n)}}}return"undefined"!=typeof i&&""!==i&&(f=f>i?i:f),"undefined"!=typeof j&&""!==j&&(f=f\n\tinput-holder\'>\n
\n
\n'}),c("StyleManager/view/PropertyRadioView",["backbone","./PropertyView","text!./../templates/propertyRadio.html"],function(a,b,c){return b.extend({template:_.template(c),initialize:function(a){b.prototype.initialize.apply(this,arguments),this.list=this.model.get("list")||[],this.className=this.className+" "+this.pfx+"list"},renderInput:function(){var a=this.pfx,b=this.ppfx,c=b+"radio-item-label",d=this.property;if(!this.$input&&this.list&&this.list.length){var e="";_.each(this.list,function(f){var g=f.className?f.className+" "+a+"icon "+c:"",h=d+"-"+f.value,i=f.name?f.name:f.value;titleAttr=f.title?'title="'+f.title+'"':"",e+='
"}),this.input=e,this.$inputEl=$(this.input),this.$el.find("#"+a+"input-holder").html(this.$inputEl),this.$input=this.$inputEl.find('input[name="'+this.property+'"]')}this.setValue(this.componentValue)},getInputValue:function(){return this.$input?this.$el.find("input:checked").val():""},setValue:function(a){var b=this.model.get("value")||this.defaultValue;a&&(b=a),this.$input&&this.$input.filter('[value="'+b+'"]').prop("checked",!0),this.model.set({value:b},{silent:!0})}})}),c("text!StyleManager/templates/propertySelect.html",[],function(){return'
\n\tinput-holder\'>\n\t
\n\t\t
\n\t
\n
\n
\n'}),c("StyleManager/view/PropertySelectView",["backbone","./PropertyView","text!./../templates/propertySelect.html"],function(a,b,c){return b.extend({template:_.template(c),initialize:function(a){b.prototype.initialize.apply(this,arguments),this.list=this.model.get("list")||[]},renderInput:function(){var a=this.pfx;if(!this.$input){var b="",this.input=b,this.$input=$(this.input),this.$el.find("#"+a+"input-holder").html(this.$input)}this.setValue(this.componentValue,0)}})}),c("text!Abstract/ui/templates/input.html",[],function(){return"\n"}),c("Abstract/ui/Input",["backbone","text!./templates/input.html"],function(a,b){return a.View.extend({events:{change:"handleChange"},template:_.template(b),initialize:function(a){var b=a||{},c=b.ppfx||"";this.target=b.target||{},this.inputClass=c+"field",this.inputHolderClass=c+"input-holder",this.ppfx=c,this.listenTo(this.model,"change:value",this.handleModelChange)},handleChange:function(a){a.stopPropagation(),this.setValue(this.getInputEl().value)},setValue:function(a,b){var c=b||{},d=this.model;d.set({value:a||d.get("defaults")},c),c.silent&&this.handleModelChange()},handleModelChange:function(){this.getInputEl().value=this.model.get("value")},getInputEl:function(){return this.inputEl||(this.inputEl=$("",{type:"text","class":this.inputCls,placeholder:this.model.get("defaults")})),this.inputEl.get(0)},render:function(){var a=this.$el;return a.addClass(this.inputClass),a.html(this.template({holderClass:this.inputHolderClass,ppfx:this.ppfx})),a.find("."+this.inputHolderClass).html(this.getInputEl()),this}})}),function(a){"use strict";"function"==typeof c&&c.amd?c("Spectrum",["jquery"],a):"object"==typeof exports&&"object"==typeof module?module.exports=a(b("jquery")):a(jQuery)}(function(a,b){"use strict";function c(b,c,d,e){for(var f=[],g=0;g')}else{var m="sp-clear-display";f.push(a("
").append(a('').attr("title",e.noColorSelectedText)).html())}}return"
"+f.join("")+"
"}function d(){for(var a=0;aMath.abs(b-e);ta=f?"x":"y"}}else ta=null;var g=!ta||"x"===ta,h=!ta||"y"===ta;g&&(ka=parseFloat(a/ba)),h&&(la=parseFloat((ca-b)/ca)),Xa=!1,U.showAlpha||(ma=1),K()},y,z),Ta?(H(Ta),L(),Va=U.preferredFormat||tinycolor(Ta).format,u(Ta)):L(),V&&C();var d=p?"mousedown.spectrum":"click.spectrum touchstart.spectrum";Ha.delegate(".sp-thumb-el",d,b),Ia.delegate(".sp-thumb-el:nth-child(1)",d,{ignore:!0},b)}function t(){if(X&&window.localStorage){try{var b=window.localStorage[X].split(",#");b.length>1&&(delete window.localStorage[X],a.each(b,function(a,b){u(b)}))}catch(c){}try{qa=window.localStorage[X].split(";")}catch(c){}}}function u(b){if(W){var c=tinycolor(b).toRgbString();if(!pa[c]&&a.inArray(c,qa)===-1)for(qa.push(c);qa.length>ra;)qa.shift();if(X&&window.localStorage)try{window.localStorage[X]=qa.join(";")}catch(d){}}}function v(){var a=[];if(U.showPalette)for(var b=0;bj&&j>e?Math.abs(l.left+e-j):0),l.top-=Math.min(l.top,l.top+f>k&&k>f?Math.abs(f+g-d):d),l}function h(){}function i(a){a.stopPropagation()}function j(a,b){var c=Array.prototype.slice,d=c.call(arguments,2);return function(){return a.apply(b,d.concat(c.call(arguments)))}}function k(b,c,d,e){function f(a){a.stopPropagation&&a.stopPropagation(),a.preventDefault&&a.preventDefault(),a.returnValue=!1}function g(a){if(k){if(p&&j.documentMode<9&&!a.button)return i();var d=a.originalEvent&&a.originalEvent.touches&&a.originalEvent.touches[0],e=d&&d.pageX||a.pageX,g=d&&d.pageY||a.pageY,h=Math.max(0,Math.min(e-l.left,n)),q=Math.max(0,Math.min(g-l.top,m));o&&f(a),c.apply(b,[h,q,a])}}function h(c){var e=c.which?3==c.which:2==c.button;e||k||d.apply(b,arguments)!==!1&&(k=!0,m=a(b).height(),n=a(b).width(),l=a(b).offset(),a(j).bind(q),a(j.body).addClass("sp-dragging"),g(c),f(c))}function i(){k&&(a(j).unbind(q),a(j.body).removeClass("sp-dragging"),setTimeout(function(){e.apply(b,arguments)},0)),k=!1}c=c||function(){},d=d||function(){},e=e||function(){};var j=document,k=!1,l={},m=0,n=0,o="ontouchstart"in window,q={};q.selectstart=f,q.dragstart=f,q["touchmove mousemove"]=g,q["touchend mouseup"]=i,a(b).bind("touchstart mousedown",h)}function l(a,b,c){var d;return function(){var e=this,f=arguments,g=function(){d=null,a.apply(e,f)};c&&clearTimeout(d),!c&&d||(d=setTimeout(g,b))}}function m(){return a.fn.spectrum.inputTypeColorSupport()}var n={beforeShow:h,move:h,change:h,show:h,hide:h,color:!1,flat:!1,showInput:!1,allowEmpty:!1,showButtons:!0,clickoutFiresChange:!0,showInitial:!1,showPalette:!1,showPaletteOnly:!1,hideAfterPaletteSelect:!1,togglePaletteOnly:!1,showSelectionPalette:!0,localStorageKey:!1,appendTo:"body",maxSelectionSize:7,cancelText:"cancel",chooseText:"choose",togglePaletteMoreText:"more",togglePaletteLessText:"less",clearText:"Clear Color Selection",noColorSelectedText:"No Color Selected",preferredFormat:!1,className:"",containerClassName:"",replacerClassName:"",showAlpha:!1,theme:"sp-light",palette:[["#ffffff","#000000","#ff0000","#ff8000","#ffff00","#008000","#0000ff","#4b0082","#9400d3"]],selectionPalette:[],disabled:!1,offset:null},o=[],p=!!/msie/i.exec(window.navigator.userAgent),q=function(){function a(a,b){return!!~(""+a).indexOf(b)}var b=document.createElement("div"),c=b.style;return c.cssText="background-color:rgba(0,0,0,.5)",a(c.backgroundColor,"rgba")||a(c.backgroundColor,"hsla")}(),r=["
","
","
","
"].join(""),s=function(){var a="";if(p)for(var b=1;b<=6;b++)a+="
";return["
","
","
","
","","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
",a,"
","
","
","
","
","","
","
","
","","","
","
","
"].join("")}(),t="spectrum.id";a.fn.spectrum=function(b,c){if("string"==typeof b){var d=this,e=Array.prototype.slice.call(arguments,1);return this.each(function(){var c=o[a(this).data(t)];if(c){var f=c[b];if(!f)throw new Error("Spectrum: no such method: '"+b+"'");"get"==b?d=c.get():"container"==b?d=c.container:"option"==b?d=c.option.apply(c,e):"destroy"==b?(c.destroy(),a(this).removeData(t)):f.apply(c,e)}}),d}return this.spectrum("destroy").each(function(){var c=a.extend({},b,a(this).data()),d=f(this,c);a(this).data(t,d.id)})},a.fn.spectrum.load=!0,a.fn.spectrum.loadOpts={},a.fn.spectrum.draggable=k,a.fn.spectrum.defaults=n,a.fn.spectrum.inputTypeColorSupport=function u(){if("undefined"==typeof u._cachedResult){var b=a("")[0];u._cachedResult="color"===b.type&&""!==b.value}return u._cachedResult},a.spectrum={},a.spectrum.localization={},a.spectrum.palettes={},a.fn.spectrum.processNativeColorInputs=function(){var b=a("input[type=color]");b.length&&!m()&&b.spectrum({preferredFormat:"hex6"})},function(){function a(a){var c={r:0,g:0,b:0},e=1,g=!1,h=!1;return"string"==typeof a&&(a=G(a)),"object"==typeof a&&(a.hasOwnProperty("r")&&a.hasOwnProperty("g")&&a.hasOwnProperty("b")?(c=b(a.r,a.g,a.b),g=!0,h="%"===String(a.r).substr(-1)?"prgb":"rgb"):a.hasOwnProperty("h")&&a.hasOwnProperty("s")&&a.hasOwnProperty("v")?(a.s=D(a.s),a.v=D(a.v),c=f(a.h,a.s,a.v),g=!0,h="hsv"):a.hasOwnProperty("h")&&a.hasOwnProperty("s")&&a.hasOwnProperty("l")&&(a.s=D(a.s),a.l=D(a.l),c=d(a.h,a.s,a.l),g=!0,h="hsl"),a.hasOwnProperty("a")&&(e=a.a)),e=w(e),{ok:g,format:a.format||h,r:M(255,N(c.r,0)),g:M(255,N(c.g,0)),b:M(255,N(c.b,0)),a:e}}function b(a,b,c){return{r:255*x(a,255),g:255*x(b,255),b:255*x(c,255)}}function c(a,b,c){a=x(a,255),b=x(b,255),c=x(c,255);var d,e,f=N(a,b,c),g=M(a,b,c),h=(f+g)/2;if(f==g)d=e=0;else{var i=f-g;switch(e=h>.5?i/(2-f-g):i/(f+g),f){case a:d=(b-c)/i+(b1&&(c-=1),c<1/6?a+6*(b-a)*c:c<.5?b:c<2/3?a+(b-a)*(2/3-c)*6:a}var e,f,g;if(a=x(a,360),b=x(b,100),c=x(c,100),0===b)e=f=g=c;else{var h=c<.5?c*(1+b):c+b-c*b,i=2*c-h;e=d(i,h,a+1/3),f=d(i,h,a),g=d(i,h,a-1/3)}return{r:255*e,g:255*f,b:255*g}}function e(a,b,c){a=x(a,255),b=x(b,255),c=x(c,255);var d,e,f=N(a,b,c),g=M(a,b,c),h=f,i=f-g;if(e=0===f?0:i/f,f==g)d=0;else{switch(f){case a:d=(b-c)/i+(b>1)+720)%360;--b;)d.h=(d.h+e)%360,f.push(P(d));return f}function u(a,b){b=b||6;for(var c=P(a).toHsv(),d=c.h,e=c.s,f=c.v,g=[],h=1/b;b--;)g.push(P({h:d,s:e,v:f})),f=(f+h)%1;return g}function v(a){var b={};for(var c in a)a.hasOwnProperty(c)&&(b[a[c]]=c);return b}function w(a){return a=parseFloat(a),(isNaN(a)||a<0||a>1)&&(a=1),a}function x(a,b){A(a)&&(a="100%");var c=B(a);return a=M(b,N(0,parseFloat(a))),c&&(a=parseInt(a*b,10)/100),K.abs(a-b)<1e-6?1:a%b/parseFloat(b)}function y(a){return M(1,N(0,a))}function z(a){return parseInt(a,16)}function A(a){return"string"==typeof a&&a.indexOf(".")!=-1&&1===parseFloat(a)}function B(a){return"string"==typeof a&&a.indexOf("%")!=-1}function C(a){return 1==a.length?"0"+a:""+a}function D(a){return a<=1&&(a=100*a+"%"),a}function E(a){return Math.round(255*parseFloat(a)).toString(16)}function F(a){return z(a)/255}function G(a){a=a.replace(H,"").replace(I,"").toLowerCase();var b=!1;if(Q[a])a=Q[a],b=!0;else if("transparent"==a)return{r:0,g:0,b:0,a:0,format:"name"};var c;return(c=S.rgb.exec(a))?{r:c[1],g:c[2],b:c[3]}:(c=S.rgba.exec(a))?{r:c[1],g:c[2],b:c[3],a:c[4]}:(c=S.hsl.exec(a))?{h:c[1],s:c[2],l:c[3]}:(c=S.hsla.exec(a))?{h:c[1],s:c[2],l:c[3],a:c[4]}:(c=S.hsv.exec(a))?{h:c[1],s:c[2],v:c[3]}:(c=S.hsva.exec(a))?{h:c[1],s:c[2],v:c[3],a:c[4]}:(c=S.hex8.exec(a))?{a:F(c[1]),r:z(c[2]),g:z(c[3]),b:z(c[4]),format:b?"name":"hex8"}:(c=S.hex6.exec(a))?{r:z(c[1]),g:z(c[2]),b:z(c[3]),format:b?"name":"hex"}:!!(c=S.hex3.exec(a))&&{r:z(c[1]+""+c[1]),g:z(c[2]+""+c[2]),b:z(c[3]+""+c[3]),format:b?"name":"hex"}}var H=/^[\s,#]+/,I=/\s+$/,J=0,K=Math,L=K.round,M=K.min,N=K.max,O=K.random,P=function(b,c){if(b=b?b:"",c=c||{},b instanceof P)return b;if(!(this instanceof P))return new P(b,c);var d=a(b);this._originalInput=b,this._r=d.r,this._g=d.g,this._b=d.b,this._a=d.a,this._roundA=L(100*this._a)/100,this._format=c.format||d.format,this._gradientType=c.gradientType,this._r<1&&(this._r=L(this._r)),this._g<1&&(this._g=L(this._g)),this._b<1&&(this._b=L(this._b)),this._ok=d.ok,this._tc_id=J++};P.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var a=this.toRgb();return(299*a.r+587*a.g+114*a.b)/1e3},setAlpha:function(a){return this._a=w(a),this._roundA=L(100*this._a)/100,this},toHsv:function(){var a=e(this._r,this._g,this._b);return{h:360*a.h,s:a.s,v:a.v,a:this._a}},toHsvString:function(){var a=e(this._r,this._g,this._b),b=L(360*a.h),c=L(100*a.s),d=L(100*a.v);return 1==this._a?"hsv("+b+", "+c+"%, "+d+"%)":"hsva("+b+", "+c+"%, "+d+"%, "+this._roundA+")"},toHsl:function(){var a=c(this._r,this._g,this._b);return{h:360*a.h,s:a.s,l:a.l,a:this._a}},toHslString:function(){var a=c(this._r,this._g,this._b),b=L(360*a.h),d=L(100*a.s),e=L(100*a.l);return 1==this._a?"hsl("+b+", "+d+"%, "+e+"%)":"hsla("+b+", "+d+"%, "+e+"%, "+this._roundA+")"},toHex:function(a){return g(this._r,this._g,this._b,a)},toHexString:function(a){return"#"+this.toHex(a)},toHex8:function(){return h(this._r,this._g,this._b,this._a)},toHex8String:function(){return"#"+this.toHex8()},toRgb:function(){return{r:L(this._r),g:L(this._g),b:L(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+L(this._r)+", "+L(this._g)+", "+L(this._b)+")":"rgba("+L(this._r)+", "+L(this._g)+", "+L(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:L(100*x(this._r,255))+"%",g:L(100*x(this._g,255))+"%",b:L(100*x(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+L(100*x(this._r,255))+"%, "+L(100*x(this._g,255))+"%, "+L(100*x(this._b,255))+"%)":"rgba("+L(100*x(this._r,255))+"%, "+L(100*x(this._g,255))+"%, "+L(100*x(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(R[g(this._r,this._g,this._b,!0)]||!1)},toFilter:function(a){var b="#"+h(this._r,this._g,this._b,this._a),c=b,d=this._gradientType?"GradientType = 1, ":"";if(a){var e=P(a);c=e.toHex8String()}return"progid:DXImageTransform.Microsoft.gradient("+d+"startColorstr="+b+",endColorstr="+c+")"},toString:function(a){var b=!!a;a=a||this._format;var c=!1,d=this._a<1&&this._a>=0,e=!b&&d&&("hex"===a||"hex6"===a||"hex3"===a||"name"===a);return e?"name"===a&&0===this._a?this.toName():this.toRgbString():("rgb"===a&&(c=this.toRgbString()),"prgb"===a&&(c=this.toPercentageRgbString()),"hex"!==a&&"hex6"!==a||(c=this.toHexString()),"hex3"===a&&(c=this.toHexString(!0)),"hex8"===a&&(c=this.toHex8String()),"name"===a&&(c=this.toName()),"hsl"===a&&(c=this.toHslString()),"hsv"===a&&(c=this.toHsvString()),c||this.toHexString())},_applyModification:function(a,b){var c=a.apply(null,[this].concat([].slice.call(b)));return this._r=c._r,this._g=c._g,this._b=c._b,this.setAlpha(c._a),this},lighten:function(){return this._applyModification(l,arguments)},brighten:function(){return this._applyModification(m,arguments)},darken:function(){return this._applyModification(n,arguments)},desaturate:function(){return this._applyModification(i,arguments)},saturate:function(){return this._applyModification(j,arguments)},greyscale:function(){return this._applyModification(k,arguments)},spin:function(){return this._applyModification(o,arguments)},_applyCombination:function(a,b){return a.apply(null,[this].concat([].slice.call(b)))},analogous:function(){return this._applyCombination(t,arguments)},complement:function(){return this._applyCombination(p,arguments)},monochromatic:function(){return this._applyCombination(u,arguments)},splitcomplement:function(){return this._applyCombination(s,arguments)},triad:function(){return this._applyCombination(q,arguments)},tetrad:function(){return this._applyCombination(r,arguments)}},P.fromRatio=function(a,b){if("object"==typeof a){var c={};for(var d in a)a.hasOwnProperty(d)&&("a"===d?c[d]=a[d]:c[d]=D(a[d]));a=c}return P(a,b)},P.equals=function(a,b){return!(!a||!b)&&P(a).toRgbString()==P(b).toRgbString()},P.random=function(){return P.fromRatio({r:O(),g:O(),b:O()})},P.mix=function(a,b,c){c=0===c?0:c||50;var d,e=P(a).toRgb(),f=P(b).toRgb(),g=c/100,h=2*g-1,i=f.a-e.a;d=h*i==-1?h:(h+i)/(1+h*i),d=(d+1)/2;var j=1-d,k={r:f.r*d+e.r*j,g:f.g*d+e.g*j,b:f.b*d+e.b*j,a:f.a*g+e.a*(1-g)};return P(k)},P.readability=function(a,b){var c=P(a),d=P(b),e=c.toRgb(),f=d.toRgb(),g=c.getBrightness(),h=d.getBrightness(),i=Math.max(e.r,f.r)-Math.min(e.r,f.r)+Math.max(e.g,f.g)-Math.min(e.g,f.g)+Math.max(e.b,f.b)-Math.min(e.b,f.b);return{brightness:Math.abs(g-h),color:i}},P.isReadable=function(a,b){var c=P.readability(a,b);return c.brightness>125&&c.color>500},P.mostReadable=function(a,b){for(var c=null,d=0,e=!1,f=0;f125&&g.color>500,i=3*(g.brightness/125)+g.color/500;(h&&!e||h&&e&&i>d||!h&&!e&&i>d)&&(e=h,d=i,c=P(b[f]))}return c};var Q=P.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},R=P.hexNames=v(Q),S=function(){var a="[-\\+]?\\d+%?",b="[-\\+]?\\d*\\.\\d+%?",c="(?:"+b+")|(?:"+a+")",d="[\\s|\\(]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")\\s*\\)?",e="[\\s|\\(]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")[,|\\s]+("+c+")\\s*\\)?";return{rgb:new RegExp("rgb"+d),rgba:new RegExp("rgba"+e),hsl:new RegExp("hsl"+d),hsla:new RegExp("hsla"+e),hsv:new RegExp("hsv"+d),hsva:new RegExp("hsva"+e),hex3:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex8:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();window.tinycolor=P}(),a(function(){a.fn.spectrum.load&&a.fn.spectrum.processNativeColorInputs()})}),c("text!Abstract/ui/templates/inputColor.html",[],function(){return'
input-holder\'>
\n
\n\t
\n\t\t
\n\t
\n
\n'}),c("Abstract/ui/InputColor",["backbone","./Input","Spectrum","text!./templates/inputColor.html"],function(a,b,c,d){return b.extend({template:_.template(d),initialize:function(a){b.prototype.initialize.apply(this,arguments);var c=this.ppfx;this.colorCls=c+"field-color-picker",this.inputClass=c+"field "+c+"field-color",this.colorHolderClass=c+"field-colorp-c",this.listenTo(this.model,"change:value",this.handleModelChange)},handleModelChange:function(){b.prototype.handleModelChange.apply(this,arguments);var a=this.model.get("value"),c=this.getColorEl();a="none"===a?"#fff":a,c.spectrum("set",a),c.get(0).style.backgroundColor=a},getColorEl:function(){if(!this.colorEl){var a=this.model,b=$("
",{"class":this.colorCls}),c=b.get(0).style,d=this.target&&this.target.config?this.target.config.el:"";b.spectrum({appendTo:d||"body",maxSelectionSize:8,showPalette:!0,showAlpha:!0,chooseText:"Ok",cancelText:"⨯",palette:[],move:function(a){var b=1==a.getAlpha()?a.toHexString():a.toRgbString();c.backgroundColor=b},change:function(b){var d=1==b.getAlpha()?b.toHexString():b.toRgbString();d=d.replace(/ /g,""),c.backgroundColor=d,a.set("value",d)}}),this.colorEl=b}return this.colorEl},render:function(){return b.prototype.render.apply(this,arguments),this.$el.find("."+this.colorHolderClass).html(this.getColorEl()),this}})}),c("StyleManager/view/PropertyColorView",["backbone","./PropertyView","Abstract/ui/InputColor"],function(a,b,c){return b.extend({renderTemplate:function(){},renderInput:function(){if(!this.input){var a=new c({target:this.target,model:this.model,ppfx:this.ppfx});this.input=a.render(),this.$el.append(this.input.$el),this.$input=this.input.inputEl,this.$color=this.input.colorEl}this.setValue(this.componentValue)},setValue:function(a){this.input.setValue(a,{silent:1})}})}),c("text!StyleManager/templates/propertyFile.html",[],function(){return'
\n\t
input-holder\'>\n\t\t
\n\t\t\t\n\t\t
\n\t\t
\n\t
\n\t
\n\t\t
\n\t\t
\n\t
\n
\n
'}),c("StyleManager/view/PropertyFileView",["backbone","./PropertyView","text!./../templates/propertyFile.html"],function(a,b,c){return b.extend({template:_.template(c),initialize:function(a){b.prototype.initialize.apply(this,arguments),this.assets=this.target.get("assets"),this.modal=this.target.get("Modal"),this.am=this.target.get("AssetManager"),this.className=this.className+" "+this.pfx+"file",this.events["click #"+this.pfx+"close"]="removeFile",this.events["click #"+this.pfx+"images"]="openAssetManager",this.delegateEvents()},renderInput:function(){this.$input||(this.$input=$("",{placeholder:this.defaultValue,type:"text"})),this.$preview||(this.$preview=this.$el.find("#"+this.pfx+"preview-file")),this.$previewBox||(this.$previewBox=this.$el.find("#"+this.pfx+"preview-box")),this.componentValue&&this.componentValue!=this.defaultValue?this.setPreviewView(1):this.setPreviewView(0),this.setValue(this.componentValue,0)},setPreviewView:function(a){this.$previewBox&&(a?this.$previewBox.addClass(this.pfx+"show"):this.$previewBox.removeClass(this.pfx+"show"))},spreadUrl:function(a){this.setValue(a),this.setPreviewView(1)},setPreview:function(a){this.$preview&&this.$preview.css("background-image","url("+a+")")},setValue:function(a,c){b.prototype.setValue.apply(this,arguments),this.setPreview(a)},renderTemplate:function(){this.$el.append(this.template({upload:"Upload",assets:"Images",pfx:this.pfx}))},cleanValue:function(){this.setPreviewView(0),this.model.set({value:""},{silent:!0})},removeFile:function(){this.model.set("value",this.defaultValue),b.prototype.cleanValue.apply(this,arguments),this.setPreviewView(0)},openAssetManager:function(a){var b=this;this.modal&&this.am&&(this.modal.setTitle("Select image"),this.modal.setContent(this.am.render()),this.am.setTarget(null),this.modal.open(),this.am.onSelect(function(c){b.modal.close(),b.spreadUrl(c.get("src")),b.valueChanged(a)}))}})}),c("text!StyleManager/templates/propertyComposite.html",[],function(){return'
\n\tinput-holder\'>\n
\n
'}),c("StyleManager/view/PropertyCompositeView",["backbone","./PropertyView","text!./../templates/propertyComposite.html","require"],function(a,b,c,d){return b.extend({template:_.template(c),initialize:function(a){b.prototype.initialize.apply(this,arguments),_.bindAll(this,"build"),this.config=a.config||{},this.className=this.className+" "+this.pfx+"composite"},valueUpdated:function(){this.model.get("detached")||b.prototype.valueUpdated.apply(this,arguments)},renderInput:function(){var a=this.model,b=a.get("properties")||[];if(b.length&&(this.$input||(this.$input=$("",{value:0,type:"hidden"})),this.props||(this.props=a.get("properties")),!this.$props)){this.props.each(function(b,c){b&&"composite"==b.get("type")&&(this.props.remove(b),console.warn("Nested composite types not yet allowed.")),b.parent=a},this);var c=d("./PropertiesView"),e=new c(this.getPropsConfig());this.$props=e.render().$el,this.$el.find("#"+this.pfx+"input-holder").html(this.$props)}},getPropsConfig:function(a){var b=this;return result={config:this.config,collection:this.props,target:this.target,propTarget:this.propTarget,onChange:function(a,c,d){var e=b.build();b.model.set("value",e,d)},customValue:function(a,c){return b.valueOnIndex(c,a)}},this.model.get("detached")&&delete result.onChange,result},getDefaultValue:function(){var a="";return this.props.each(function(b,c){a+=b.get("defaults")+b.get("unit")+" "}),a.replace(/ +$/,"")},valueOnIndex:function(a,b){var c=null,d=this.getComponentValue().split(" ");if(d.length&&d[a]&&(c=d[a],b&&b.model&&b.model.get("functionName"))){var e=this.fetchFromFunction(c);e&&(c=e)}return c},build:function(a,b,c){var d="";return this.model.get("properties").each(function(a){var b=a.getValue();func=a.get("functionName"),func&&(b=func+"("+b+")"),d+=b+" "}),d.replace(/ +$/,"")}})}),c("text!StyleManager/templates/propertyStack.html",[],function(){return"
field <%= pfx %>stack\">\n\t\n\t\n
\n
"}),c("text!StyleManager/templates/layer.html",[],function(){return'
\n \n
\n
<%= label %>
\n
\n\t
\n
\n
\n
\n
'}),c("StyleManager/view/LayerView",["backbone","text!./../templates/layer.html"],function(a,b){return a.View.extend({events:{click:"updateIndex"},template:_.template(b),initialize:function(a){this.stackModel=a.stackModel||{},this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.className=this.pfx+"layer",this.sorter=a.sorter||null,this.listenTo(this.model,"destroy remove",this.remove),this.listenTo(this.model,"change:value",this.valueChanged),this.listenTo(this.model,"change:props",this.showProps),this.events["click #"+this.pfx+"close-layer"]="remove",this.events["mousedown > #"+this.pfx+"move"]="initSorter",this.model.get("preview")||this.$el.addClass(this.pfx+"no-preview"),this.$el.data("model",this.model),this.delegateEvents()},initSorter:function(a){this.sorter&&this.sorter.startSort(this.el)},getProps:function(){return this.stackModel.get?this.stackModel.get("properties"):null},valueChanged:function(){var a=this.model.get("preview");if(a){this.$preview||(this.$preview=this.$el.find("#"+this.pfx+"preview"));var b=this.getProps(),c=this.$preview;"function"==typeof a?a(b,c):this.onPreview(b,c)}},onPreview:function(a,b){var c=this.model.get("value").split(" "),d=3,e="";if(a.each(function(a,b){var f=c[b]||"";if(f&&"integer"==a.get("type")){var g=parseInt(f,10),h=f.replace(g,"");g=isNaN(g)?0:g,g>d&&(g=d),g<-d&&(g=-d),f=g+h}e+=f+" "}),this.stackModel.get){var f=this.stackModel.get("property");f&&(this.$preview.get(0).style[f]=e)}},showProps:function(){this.$props=this.model.get("props"),this.$el.find("#"+this.pfx+"inputs").html(this.$props.show()),this.model.set({props:null},{silent:!0})},remove:function(b){this.$props&&this.$props.detach(),b&&b.stopPropagation&&b.stopPropagation(),a.View.prototype.remove.apply(this,arguments),this.model.collection.contains(this.model)&&this.model.collection.remove(this.model),this.stackModel&&this.stackModel.set&&(this.stackModel.set({stackIndex:null},{silent:!0}),this.stackModel.trigger("updateValue"))},updateIndex:function(a){var b=this.getIndex();this.stackModel.set("stackIndex",b),this.model.collection&&this.model.collection.trigger("deselectAll"),this.$el.addClass(this.pfx+"active")},getIndex:function(){var a=0,b=this.model;return b.collection&&(a=b.collection.indexOf(b)),a},render:function(){return this.$el.html(this.template({label:"Layer "+this.model.get("index"),pfx:this.pfx})),this.$el.attr("class",this.className),this.valueChanged(),this}})}),c("StyleManager/view/LayersView",["backbone","./LayerView"],function(a,b){return a.View.extend({initialize:function(a){this.config=a.config||{},this.stackModel=a.stackModel,this.preview=a.preview,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.className=this.pfx+"layers "+this.ppfx+"field",this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"deselectAll",this.deselectAll),this.listenTo(this.collection,"reset",this.render);var b=this.config.em||"",c=b?b.get("Utils"):"";this.sorter=c?new c.Sorter({container:this.el,containerSel:"."+this.pfx+"layers",itemSel:"."+this.pfx+"layer",pfx:this.config.pStylePrefix}):"",this.$el.data("model",{}),this.$el.data("collection",this.collection)},addTo:function(a){var b=this.collection.indexOf(a);this.addToCollection(a,null,b)},addToCollection:function(a,c,d){var e=c||null,f=b;"undefined"!=typeof this.preview&&a.set("preview",this.preview);var g=new f({model:a,stackModel:this.stackModel,config:this.config,sorter:this.sorter}),h=g.render().el;if(e)e.appendChild(h);else if("undefined"!=typeof d){var i="before";this.$el.children().length==d&&(d--,i="after"),d<0?this.$el.append(h):this.$el.children().eq(d)[i](h)}else this.$el.append(h);return h},deselectAll:function(){this.$el.find("."+this.pfx+"layer").removeClass(this.pfx+"active")},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.addToCollection(b,a)},this),this.$el.append(a),this.$el.attr("class",this.className),this.sorter&&(this.sorter.plh=null),this}})}),c("StyleManager/view/PropertyStackView",["backbone","./PropertyCompositeView","text!./../templates/propertyStack.html","./../model/Layers","./LayersView"],function(a,b,c,d,e){return b.extend({template:_.template(c),initialize:function(a){b.prototype.initialize.apply(this,arguments),this.model.set("stackIndex",null),this.className=this.pfx+"property "+this.pfx+"stack",this.events["click #"+this.pfx+"add"]="addLayer",this.listenTo(this.model,"change:stackIndex",this.indexChanged),this.listenTo(this.model,"updateValue",this.valueUpdated),this.delegateEvents()},targetUpdated:function(){this.model.get("detached")?(this.checkVisibility(),this.refreshLayers()):b.prototype.targetUpdated.apply(this,arguments)},getLayers:function(){return this.model.get("layers")},indexChanged:function(a){var b=this.model,c=this.getLayers().at(b.get("stackIndex"));c.set("props",this.$props),b.get("properties").each(function(a){a.trigger("targetUpdated")})},getStackValues:function(){return this.getLayers().pluck("value")},getPropsConfig:function(a){var c=this,d=b.prototype.getPropsConfig.apply(this,arguments);return d.onChange=function(a,b,d){var e=b.model,f=c.build();if(c.model.get("detached")){var g="";e.collection.indexOf(e);c.getLayers().each(function(a){var b=a.get("values")[e.get("property")];b&&(g+=(g?",":"")+b)}),b.updateTargetStyle(g,null,d)}else c.model.set("value",f,d)},d},valueOnIndex:function(a,b){var c=null,d=this.model.get("stackIndex");if(this.model.get("detached")){var e=b.getTargetValue(),f=(e+"").split(",");c=f[d],c=c?c.trim():b.getDefaultValue(),c=b.tryFetchFromFunction(c)}else{var g=this.getStackValues(),h=g[d];if(!h)return;var i=h.split(" ");i.length&&i[a]&&(c=i[a])}return c},build:function(){var a=this.model.get("stackIndex");if(null!==a){var c=b.prototype.build.apply(this,arguments),d=this.getLayers().at(a);if(d){var e={};return this.model.get("properties").each(function(a){var b=a.getValue(),c=a.get("functionName");c&&(b=c+"("+b+")"),e[a.get("property")]=b}),d.set("values",e), -d.set("value",c),this.createValue()}}},addLayer:function(a){if(this.getTarget()){var b=this.getLayers(),c=b.add({name:"test"}),d=b.indexOf(c);return c.set("value",this.getDefaultValue()),this.valueUpdated(),this.model.set("stackIndex",d),c}},valueUpdated:function(){var a=this.model;a.get("detached")?a.get("properties").each(function(a){a.trigger("change:value")}):a.set("value",this.createValue())},createValue:function(){return this.getStackValues().join(", ")},renderLayers:function(){return this.$field||(this.$field=this.$el.find("> ."+this.pfx+"field")),this.$layers||(this.$layers=new e({collection:this.getLayers(),stackModel:this.model,preview:this.model.get("preview"),config:this.config})),this.$field.append(this.$layers.render().el),this.$props.hide(),this},renderInput:function(){b.prototype.renderInput.apply(this,arguments),this.refreshLayers()},getLayersFromTarget:function(){var a=[],b=this.getTarget();if(!b)return a;var c=b.get("style");return this.model.get("properties").each(function(b){var d=c[b.get("property")];if(d)for(var e=d.split(","),f=0,g=e.length;f",{"class":"clear"})),this.$el.attr("class",this.pfx+"properties"),this}})}),c("text!StyleManager/templates/sector.html",[],function(){return'
\n \n <%= label %>\n
'}),c("StyleManager/view/SectorView",["backbone","./PropertiesView","text!./../templates/sector.html"],function(a,b,c){return a.View.extend({template:_.template(c),events:{},initialize:function(a){this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.target=a.target||{},this.propTarget=a.propTarget||{},this.open=this.model.get("open"),this.caretR="fa-caret-right",this.caretD="fa-caret-down",this.listenTo(this.model,"change:open",this.updateOpen),this.listenTo(this.model,"updateVisibility",this.updateVisibility),this.events["click ."+this.pfx+"title"]="toggle",this.delegateEvents()},updateVisibility:function(){var a;this.model.get("properties").each(function(b){b.get("visible")&&(a=1)}),this.el.style.display=a?"block":"none"},updateOpen:function(){this.model.get("open")?this.show():this.hide()},show:function(){this.$el.addClass(this.pfx+"open"),this.$el.find("."+this.pfx+"properties").show(),this.$caret.removeClass(this.caretR).addClass(this.caretD)},hide:function(){this.$el.removeClass(this.pfx+"open"),this.$el.find("."+this.pfx+"properties").hide(),this.$caret.removeClass(this.caretD).addClass(this.caretR)},toggle:function(){var a=this.model.get("open")?0:1;this.model.set("open",a)},render:function(){return this.$el.html(this.template({pfx:this.pfx,label:this.model.get("name")})),this.$caret=this.$el.find("#"+this.pfx+"caret"),this.renderProperties(),this.$el.attr("class",this.pfx+"sector no-select"),this.updateOpen(),this},renderProperties:function(){var a=this.model.get("properties");if(a){var c=new b({collection:a,target:this.target,propTarget:this.propTarget,config:this.config});this.$el.append(c.render().el)}}})}),c("StyleManager/view/SectorsView",["backbone","./SectorView"],function(a,b){return a.View.extend({initialize:function(b){this.config=b.config||{},this.pfx=this.config.stylePrefix||"",this.target=b.target||{},this.propTarget={},_.extend(this.propTarget,a.Events),this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"reset",this.render),this.listenTo(this.target,"change:selectedComponent targetClassAdded targetClassRemoved targetClassUpdated targetStateUpdated targetStyleUpdated change:device",this.targetUpdated)},addTo:function(a){this.addToCollection(a)},targetUpdated:function(){var a=this.target.get("selectedComponent");if(a){var b=this.target.get("Config").devicePreviewMode,c=a.get("classes"),d=this.propTarget,e=this.target.getDeviceModel(),f=b?"":a.get("state"),g=e&&!b&&e.get("width")?"(max-width: "+e.get("width")+")":"";if(d.helper=null,c.length){var h=this.target.get("CssComposer"),i=_.filter(c.models,function(a){return a.get("active")}),j=h.get(i,f,g);if(j||(j=h.add(i,f,g),j.set("style",a.get("style")),a.set("style",{})),f){var k=this.target.get("SelectorManager"),l=k.add("hc-state"),m=h.get([l]);m?(h.getAll().remove(m),h.getAll().add(m)):m=h.add([l]),m.set("style",j.get("style")),d.helper=m}return d.model=j,void d.trigger("update")}d.model=a,d.trigger("update")}},addToCollection:function(a,c){var d=c||null,e=b,f=new e({model:a,id:this.pfx+a.get("name").replace(" ","_").toLowerCase(),name:a.get("name"),properties:a.get("properties"),target:this.target,propTarget:this.propTarget,config:this.config}),g=f.render().el;return d?d.appendChild(g):this.$el.append(g),g},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.addToCollection(b,a)},this),this.$el.attr("id",this.pfx+"sectors"),this.$el.append(a),this}})}),c("StyleManager/main",["require","./config/config","./model/Sectors","./view/SectorsView"],function(a){return function(){var b,c,d={},e=a("./config/config"),f=a("./model/Sectors"),g=a("./view/SectorsView");return{name:"StyleManager",getConfig:function(){return d},init:function(a){d=a||{};for(var h in e)h in d||(d[h]=e[h]);var i=d.pStylePrefix;return i&&(d.stylePrefix=i+d.stylePrefix),b=new f(d.sectors),c=new g({collection:b,target:d.em,config:d}),this},addSector:function(a,c){var d=this.getSector(a);return d||(c.id=a,d=b.add(c)),d},getSector:function(a){var c=b.where({id:a});return c.length?c[0]:null},getSectors:function(){return b},addProperty:function(a,b){var c=null,d=this.getSector(a);return d&&(c=d.get("properties").add(b)),c},getProperty:function(a,b){var c=null,d=this.getSector(a);return d&&(c=d.get("properties").where({property:b}),c=1==c.length?c[0]:c),c},getProperties:function(a){var b=null,c=this.getSector(a);return c&&(b=c.get("properties")),b},getModelToStyle:function(a){var b=a.get("classes");if(d.em&&b&&b.length){var c=d.em.get("Config").devicePreviewMode,e=d.em.getDeviceModel(),f=c?"":a.get("state"),g=e&&!c?e.get("width"):"",h=d.em.get("CssComposer"),i=_.filter(b.models,function(a){return a.get("active")}),j=h.get(i,f,g);if(j)return j}return a},render:function(){return c.render().el}}}}),c("StyleManager",["StyleManager/main"],function(a){return a}),c("AssetManager/model/Asset",["backbone"],function(a){return a.Model.extend({idAttribute:"src",defaults:{type:"",src:""},getFilename:function(){return this.get("src").split("/").pop()},getExtension:function(){return this.getFilename().split(".").pop()}})}),c("AssetManager/model/AssetImage",["backbone","./Asset"],function(a,b){return b.extend({defaults:_.extend({},b.prototype.defaults,{type:"image",unitDim:"px",height:0,width:0})})}),c("AssetManager/model/Assets",["backbone","./Asset","./AssetImage"],function(a,b,c){return a.Collection.extend({model:c,initialize:function(a,b){this.model=function(a,b){var d;switch(a.type){default:d=new c(a,b)}return d}},addImg:function(a,b){return this.add({type:"image",src:a},b),this},add:function(b,c){var d=[];b=b instanceof Array?b:[b];for(var e=0,f=b.length;e\n
\n
\n
\n
\n\t
<%= name %>
\n\t
<%= dim %>
\n
\n
\n
'}),c("AssetManager/view/AssetImageView",["./AssetView","text!./../template/assetImage.html"],function(a,b){return a.extend({events:{click:"handleClick",dblclick:"handleDblClick"},template:_.template(b),initialize:function(b){a.prototype.initialize.apply(this,arguments),this.className+=" "+this.pfx+"asset-image",this.events["click #"+this.pfx+"close"]="removeItem",this.delegateEvents()},handleClick:function(){var a=this.config.onClick,b=this.model;b.collection.trigger("deselectAll"),this.$el.addClass(this.pfx+"highlight"),"function"==typeof a?a(b):this.updateTarget(b.get("src"))},handleDblClick:function(){var a=this.config.onDblClick,b=this.model;"function"==typeof a?a(b):this.updateTarget(b.get("src"));var c=b.collection.onSelect;"function"==typeof c&&c(this.model)},updateTarget:function(a){var b=this.model.collection.target;if(b&&b.set){var c=_.clone(b.get("attributes"));b.set("attributes",c),b.set("src",a)}},removeItem:function(a){a.stopPropagation(),this.model.collection.remove(this.model)},render:function(){var a=this.model.get("name"),b=this.model.get("width")&&this.model.get("height")?this.model.get("width")+" x "+this.model.get("height"):"";return a=a?a:this.model.get("src").split("/").pop(),a=a&&a.length>30?a.substring(0,30)+"...":a,b=b?b+(this.model.get("unitDim")?this.model.get("unitDim"):" px"):"",this.$el.html(this.template({name:a,src:this.model.get("src"),dim:b,pfx:this.pfx,ppfx:this.ppfx})),this.$el.attr("class",this.className),this}})}),c("text!AssetManager/template/fileUploader.html",[],function(){return'
\n\t
<%= title %>
\n\t multiple/>\n\t
\n
'}),c("AssetManager/view/FileUploader",["backbone","text!./../template/fileUploader.html"],function(a,b){return a.View.extend({template:_.template(b),events:{},initialize:function(a){this.options=a||{},this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.target=this.collection||{},this.uploadId=this.pfx+"uploadFile",this.disabled=!this.config.upload,this.events["change #"+this.uploadId]="uploadFile",this.delegateEvents()},uploadFile:function(a){for(var b=a.dataTransfer?a.dataTransfer.files:a.target.files,c=new FormData,d=0;d\n
\n
\n
\n \n
\n \n
\n
\n \n
\n
\n
\n
\n'}),c("AssetManager/view/AssetsView",["backbone","./AssetView","./AssetImageView","./FileUploader","text!./../template/assets.html"],function(a,b,c,d,e){return a.View.extend({template:_.template(e),initialize:function(a){this.options=a,this.config=a.config,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.listenTo(this.collection,"add",this.addToAsset),this.listenTo(this.collection,"deselectAll",this.deselectAll),this.className=this.pfx+"assets",this.events={},this.events.submit="addFromStr",this.delegateEvents()},addFromStr:function(a){a.preventDefault();var b=this.getInputUrl(),c=b.value.trim();if(c)return this.collection.addImg(c,{at:0}),this.getAssetsEl().scrollTop=0,b.value="",this},getAssetsEl:function(){return this.assets=this.el.querySelector("."+this.pfx+"assets"),this.assets},getInputUrl:function(){return this.inputUrl&&this.inputUrl.value||(this.inputUrl=this.el.querySelector("."+this.pfx+"add-asset input")),this.inputUrl},addToAsset:function(a){this.addAsset(a)},addAsset:function(a,d){var e=d||null,f=b;a.get("type").indexOf("image")>-1&&(f=c);var g=new f({model:a,config:this.config}),h=g.render().el;if(e)e.appendChild(h);else{var i=this.getAssetsEl();i&&i.insertBefore(h,i.firstChild)}return h},deselectAll:function(){this.$el.find("."+this.pfx+"highlight").removeClass(this.pfx+"highlight")},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.addAsset(b,a)},this),this.$el.html(this.template({pfx:this.pfx,ppfx:this.ppfx,btnText:this.config.addBtnText})),this.$el.find("."+this.pfx+"assets").append(a),this}})}),c("AssetManager/config/config",[],function(){return{assets:[],stylePrefix:"am-",upload:"http://localhost/assets/upload",uploadText:"Drop files here or click to upload",addBtnText:"Add image"}}),c("AssetManager/main",["require","./model/Assets","./view/AssetsView","./view/FileUploader","./config/config"],function(a){return function(){var b,c,d,e={},f=a("./model/Assets"),g=a("./view/AssetsView"),h=a("./view/FileUploader");return{name:"AssetManager",storageKey:"assets",init:function(i){e=i||{};var j=a("./config/config");for(var k in j)k in e||(e[k]=j[k]);var l=e.pStylePrefix;l&&(e.stylePrefix=l+e.stylePrefix),b=new f(e.assets);var m={collection:b,config:e};return c=new g(m),d=new h(m),this},add:function(a){return b.add(a)},get:function(a){return b.where({src:a})[0]},getAll:function(){return b},remove:function(a){var b=this.get(a);return this.getAll().remove(b),this},store:function(a){var b={},c=JSON.stringify(this.getAll().toJSON());return b[this.storageKey]=c,!a&&e.stm&&e.stm.store(b),b},load:function(a){var b=a||"",c=this.storageKey;!b&&e.stm&&(b=e.stm.load(c));var d=[];try{d=JSON.parse(b[c])}catch(f){}return this.getAll().add(d),d},render:function(a){return this.rendered&&!a||(this.rendered=c.render().$el.add(d.render().$el)),this.rendered},setTarget:function(a){c.collection.target=a},onSelect:function(a){c.collection.onSelect=a},onClick:function(a){e.onClick=a},onDblClick:function(a){e.onDblClick=a}}}}),c("AssetManager",["AssetManager/main"],function(a){return a}),c("CssComposer/config/config",[],function(){return{stylePrefix:"css-",staticRules:"",rules:[]}}),c("CssComposer/model/Selectors",["backbone","require"],function(a,b){return a.Collection.extend({initialize:function(a,c){this.model=function(a,c){var d;return this.ClassTag||(this.ClassTag=b("SelectorManager/model/Selector")),d=new this.ClassTag(a,c)}}})}),c("CssComposer/model/CssRule",["backbone","./Selectors"],function(a,b){return a.Model.extend({defaults:{selectors:{},selectorsAdd:"",style:{},mediaText:"",state:"",stylable:!0},initialize:function(a,c){if(this.config=a||{},this.sm=c?c.sm||{}:{},this.slct=this.config.selectors||[],this.sm.get){for(var d=[],e=0;e=0&&(c.css=d.em.getCss()),e.indexOf("styles")>=0&&(c.styles=JSON.stringify(b)),a||d.stm.store(c),c}},add:function(a,c,d,e){var g=c||"",h=d||"",i=e||{},j=this.get(a,g,h,i);return j?j:(i.state=g,i.mediaText=h,i.selectors="",j=new f(i),j.get("selectors").add(a),b.add(j),j)},get:function(a,c,d,e){var f=null;return b.each(function(b){f||b.compare(a,c,d,e)&&(f=b)}),f},getAll:function(){return b},addCollection:function(a,b){for(var c=b||{},e=[],f=a instanceof Array?a:[a],g=0,h=f.length;g=0&&this.set("void",!0),this.opt=e,this.sm=e?e.sm||{}:{},this.config=a||{},this.defaultC=this.config.components||[],this.defaultCl=this.normalizeClasses(this.get("classes")||this.config.classes||[]),this.components=new b(this.defaultC,e),this.components.parent=this,this.listenTo(this,"change:script",this.scriptUpdated),this.set("attributes",this.get("attributes")||{}),this.set("components",this.components),this.set("classes",new c(this.defaultCl));var f=new d;f.setTarget(this),f.add(this.get("traits")),this.set("traits",f),this.initToolbar();var g=["stylable"];g.forEach(function(a){var b=this.get(a);if("string"==typeof b){var c=b.split(",").map(function(a){return a.trim()});this.set(a,c)}},this),this.init()},init:function(){},scriptUpdated:function(){this.set("scriptUpdated",1)},initToolbar:function(){var a=this;if(!a.get("toolbar")){var b=[];a.get("draggable")&&b.push({attributes:{"class":"fa fa-arrows"},command:"tlb-move"}),a.get("copyable")&&b.push({attributes:{"class":"fa fa-clone"},command:"tlb-clone"}),a.get("removable")&&b.push({attributes:{"class":"fa fa-trash-o"},command:"tlb-delete"}),a.set("toolbar",b)}},loadTraits:function(a){var b=new d;b.setTarget(this),b.add(a),this.set("traits",b)},normalizeClasses:function(a){var b=[];if(this.sm.get){var c=this.sm.get("SelectorManager");if(c)return a.forEach(function(a){var d="";d="string"==typeof a?a:a.name;var e=c.add(d);b.push(e)}),b}},clone:function(a){var b=_.clone(this.attributes),c=this.get("components"),d=this.get("traits"),e=this.get("classes");return b.components=[],b.classes=[],b.traits=[],c.each(function(a,c){b.components[c]=a.clone(1)}),d.each(function(a,c){b.traits[c]=a.clone()}),e.each(function(a,c){b.classes[c]=a.get("name")}),b.status="",b.view="",a&&(this.opt.collection=null),new this.constructor(b,this.opt)},getName:function(){if(!this.name){var a=(this.cid.replace(/\D/g,""),this.get("type")),b=this.get("tagName");b="div"==b?"box":b,b=a?a:b,this.name=b.charAt(0).toUpperCase()+b.slice(1)}return this.name},toHTML:function(a){var b="",c=this,d=c.get("tagName"),e=c.get("void"),f="",g="",h=this.getAttrToHTML();for(var i in h){var j=h[i];g+=void 0!==typeof j&&""!==j?" "+i+'="'+j+'"':""}var k="";return c.get("classes").each(function(a){k+=" "+a.get("name")}),k=""!==k?' class="'+k.trim()+'"':"",_.isEmpty(c.get("style"))||(f=' id="'+c.cid+'" '),b+="<"+d+k+f+g+(e?"/":"")+">"+c.get("content"),c.get("components").each(function(a){b+=a.toHTML()}),e||(b+=""),b},getAttrToHTML:function(){var a=this.get("attributes")||{};return delete a.style,a},toJSON:function(){var b=a.Model.prototype.toJSON.apply(this,arguments),c=this.getScriptString();return c&&(b.script=c),b},getScriptString:function(a){var b=a||this.get("script");if("function"==typeof b){var c=b.toString().trim();c=c.replace(/^function\s?\(\)\s?\{/,""),c=c.replace(/\}$/,""),b=c}return b}},{isComponent:function(a){return{tagName:a.tagName?a.tagName.toLowerCase():""}}})}),c("DomComponents/view/ComponentsView",["backbone","require"],function(a,b){return a.View.extend({initialize:function(a){this.opts=a||{},this.config=a.config||{},this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"reset",this.render)},addTo:function(a){var b=this.collection.indexOf(a);this.addToCollection(a,null,b);var c=this.config.em;c&&(c.trigger("add:component",a),c.trigger("component:add",a))},addToCollection:function(a,c,d){this.compView||(this.compView=b("./ComponentView"));for(var e=c||null,f=this.compView,g=this.opts.defaultTypes,h=this.opts.componentTypes,i=a.get("type"),j=0;j=0&&(b.html=d.em.getHtml()),c.indexOf("components")>=0&&(b.components=JSON.stringify(d.em.getComponents())),a||d.stm.store(b),b}},getComponent:function(){return b},getWrapper:function(){return this.getComponent()},getComponents:function(){return this.getWrapper().get("components")},addComponent:function(a){return this.getComponents().add(a)},render:function(){return c.render().el},clear:function(){for(var a=this.getComponents(),b=0,c=a.length;b div")},render:function(){return this.$el.attr({"class":this.ppfx+"frame"}),this}})}),c("Canvas/view/CanvasView",["backbone","./FrameView"],function(a,b){return a.View.extend({initialize:function(a){_.bindAll(this,"renderBody","onFrameScroll","clearOff"),this.config=a.config||{},this.em=this.config.em||{},this.ppfx=this.config.pStylePrefix||"",this.className=this.config.stylePrefix+"canvas",this.listenTo(this.em,"change:canvasOffset",this.clearOff),this.frame=new b({model:this.model.get("frame"),config:this.config})},onFrameScroll:function(){var a="px",b=this.frame.el.contentDocument.body;this.toolsEl.style.top="-"+b.scrollTop+a,this.toolsEl.style.left="-"+b.scrollLeft+a,this.em.trigger("canvasScroll")},renderScripts:function(){var a=this.frame,b=this;a.el.onload=function(){function c(d){if(d.length>0){var e=document.createElement("script");e.type="text/javascript",e.src=d.shift(),e.onerror=e.onload=c.bind(null,d),a.el.contentDocument.head.appendChild(e)}else b.renderBody()}var d=b.config.scripts.slice(0);c(d)}},renderBody:function(){var a=this.model.get("frame").get("wrapper"),b=this.config.em;if(a){var c=this.ppfx,d=this.frame.$el.contents().find("body"),e=b.get("CssComposer"),f=b.get("Config");d.append(a.render()).append(e.render());var g=f.protectedCss,h="* {box-sizing: border-box;} body{margin:0;height:auto;background-color:#fff} #wrapper{min-height:100%; overflow:auto}."+c+"dashed :not([contenteditable]) > *[data-highlightable]{outline: 1px dashed rgba(170,170,170,0.7); outline-offset: -2px}."+c+"comp-selected{outline: 3px solid #3b97e3 !important}."+c+"no-select{user-select: none; -webkit-user-select:none; -moz-user-select: none}."+c+"freezed{opacity: 0.5; pointer-events: none}."+c+"no-pointer{pointer-events: none}."+c+"plh-image{background:#f5f5f5; border:none; height:50px; width:50px; display:block; outline:3px solid #ffca6f; cursor:pointer}."+c+"grabbing{cursor: grabbing; cursor: -webkit-grabbing}* ::-webkit-scrollbar-track {background: rgba(0, 0, 0, 0.1)}* ::-webkit-scrollbar-thumb {background: rgba(255, 255, 255, 0.2)}* ::-webkit-scrollbar {width: 10px}"+(f.canvasCss||"");h+=g||"",d.append(""),d.append(this.getJsContainer()),b.trigger("loaded"),this.frame.el.contentWindow.onscroll=this.onFrameScroll,this.frame.udpateOffset();var i=document,j=this.frame.el.contentDocument;j.addEventListener("keydown",function(a){i.dispatchEvent(new KeyboardEvent(a.type,a))}),j.addEventListener("keyup",function(a){i.dispatchEvent(new KeyboardEvent(a.type,a))})}},offset:function(a){var b=a.getBoundingClientRect(),c=a.ownerDocument.body;return{top:b.top+c.scrollTop,left:b.left+c.scrollLeft}},clearOff:function(){this.frmOff=null,this.cvsOff=null},getFrameOffset:function(){return this.frmOff||(this.frmOff=this.offset(this.frame.el)),this.frmOff},getCanvasOffset:function(){return this.cvsOff||(this.cvsOff=this.offset(this.el)),this.cvsOff},getElementPos:function(a){var b=this.getFrameOffset(),c=this.getCanvasOffset(),d=this.offset(a),e=d.top+b.top-c.top,f=d.left+b.left-c.left;return{top:e,left:f,height:a.offsetHeight,width:a.offsetWidth}},getPosition:function(){var a=this.frame.el.contentDocument.body,b=this.getFrameOffset(),c=this.getCanvasOffset();return{top:b.top+a.scrollTop-c.top,left:b.left+a.scrollLeft-c.left}},updateScript:function(a){a.scriptContainer||(a.scriptContainer=$("
"),this.getJsContainer().append(a.scriptContainer.get(0)));var b=a.model.cid,c=a.model.get("script"),d="function(){"+c+"}";d="function"==typeof c?c.toString():d,a.el.id=b,a.scriptContainer.html(""),a.scriptContainer.append('")},getJsContainer:function(){return this.jsContainer||(this.jsContainer=$("
",{"class":this.ppfx+"js-cont"}).get(0)),this.jsContainer},render:function(){if(this.wrapper=this.model.get("wrapper"),this.wrapper&&"function"==typeof this.wrapper.render){this.model.get("frame").set("wrapper",this.wrapper),this.$el.append(this.frame.render().el);var a=this.frame;0===this.config.scripts.length?a.el.onload=this.renderBody:this.renderScripts()}var b=this.ppfx;toolsEl=$("
",{id:b+"tools"}).get(0),this.hlEl=$("
",{"class":b+"highlighter"}).get(0),this.badgeEl=$("
",{"class":b+"badge"}).get(0),this.placerEl=$("
",{"class":b+"placeholder"}).get(0),this.placerIntEl=$("
",{"class":b+"placeholder-int"}).get(0),this.ghostEl=$("
",{"class":b+"ghost"}).get(0),this.toolbarEl=$("
",{"class":b+"toolbar"}).get(0),this.resizerEl=$("
",{"class":b+"resizer"}).get(0),this.offsetEl=$("
",{"class":b+"offset-v"}).get(0),this.fixedOffsetEl=$("
",{"class":b+"offset-fixed-v"}).get(0),this.placerEl.appendChild(this.placerIntEl),toolsEl.appendChild(this.hlEl),toolsEl.appendChild(this.badgeEl),toolsEl.appendChild(this.placerEl),toolsEl.appendChild(this.ghostEl),toolsEl.appendChild(this.toolbarEl),toolsEl.appendChild(this.resizerEl),toolsEl.appendChild(this.offsetEl),toolsEl.appendChild(this.fixedOffsetEl),this.$el.append(toolsEl);var c=this.em.get("rte");return c&&toolsEl.appendChild(c.render()),this.toolsEl=toolsEl,this.$el.attr({"class":this.className}),this}})}),c("Canvas/main",["require","./config/config","./model/Canvas","./view/CanvasView"],function(a){return function(){var b,c={},d=a("./config/config"),e=a("./model/Canvas"),f=a("./view/CanvasView");return{getCanvasView:function(){return f},name:"Canvas",init:function(a){c=a||{};for(var g in d)g in c||(c[g]=d[g]);var h=c.pStylePrefix;h&&(c.stylePrefix=h+c.stylePrefix),b=new e(a),f=new f({model:b,config:c});var i=c.em.get("DomComponents");return i&&this.setWrapper(i),this},setWrapper:function(a){b.set("wrapper",a)},getElement:function(){return f.el},getFrameEl:function(){return f.frame.el},getBody:function(){return f.frame.el.contentDocument.body},getWrapperEl:function(){return this.getBody().querySelector("#wrapper")},getToolsEl:function(){return f.toolsEl},getHighlighter:function(){return f.hlEl},getBadgeEl:function(){return f.badgeEl},getPlacerEl:function(){return f.placerEl},getGhostEl:function(){return f.ghostEl},getToolbarEl:function(){return f.toolbarEl},getResizerEl:function(){return f.resizerEl},getOffsetViewerEl:function(){return f.offsetEl},getFixedOffsetViewerEl:function(){return f.fixedOffsetEl},render:function(){return f.render().el},getOffset:function(){var a=this.offset(this.getFrameEl()),b=this.offset(this.getElement());return{top:a.top-b.top,left:a.left-b.left}},offset:function(a){var b=a.getBoundingClientRect();return{top:b.top+document.body.scrollTop,left:b.left+document.body.scrollLeft}},getElementPos:function(a){return f.getElementPos(a)},getTargetToElementDim:function(a,b,d){var e=d||{},g=f.getPosition(),h=e.elPos||f.getElementPos(b),i=d.toRight||0,j=e.targetHeight||a.offsetHeight,k=e.targetWidth||a.offsetWidth,l=e.event||null,m=h.top-j,n=h.left;n+=i?h.width:0,n=i?n-k:n;var o=nh.top+h.height?h.top+h.height:p;var q={top:p,left:o,elementTop:h.top,elementLeft:h.left,elementWidth:h.width,elementHeight:h.height,targetWidth:a.offsetWidth,targetHeight:a.offsetHeight,canvasTop:g.top,canvasLeft:g.left};return l&&c.em&&c.em.trigger(l,q),q},getMouseRelativePos:function(a,b){var c=b||{},d=0,e=0,f=c.subWinOffset,g=a.target.ownerDocument,h=g.defaultView||g.parentWindow,i=h.frameElement,j=f?h.pageYOffset:0,k=f?h.pageXOffset:0;if(i){var l=i.getBoundingClientRect();d=l.top||0,e=l.left||0}return{y:a.clientY+d-j,x:a.clientX+e-k}},getMouseRelativeCanvas:function(a,b){var c=this.getFrameEl(),d=this.getBody(),e=c.offsetTop||0,f=c.offsetLeft||0,g=d.scrollTop||0,h=d.scrollLeft||0;return{y:a.clientY+e+g,x:a.clientX+f+h}},getFrameWrapperEl:function(){return f.frame.getWrapper()}}}}),c("Canvas",["Canvas/main"],function(a){return a}),c("Commands/config/config",[],function(){return{ESCAPE_KEY:27,stylePrefix:"com-",defaults:[],em:null,firstCentered:!0,newFixedH:!1,minComponentH:50,minComponentW:50}}),c("Commands/view/CommandAbstract",["backbone"],function(a){return a.View.extend({initialize:function(a){this.config=a||{},this.editorModel=this.em=this.config.em||{},this.pfx=this.config.stylePrefix,this.ppfx=this.config.pStylePrefix,this.hoverClass=this.pfx+"hover",this.badgeClass=this.pfx+"badge",this.plhClass=this.pfx+"placeholder",this.freezClass=this.ppfx+"freezed",this.canvas=this.em.get&&this.em.get("Canvas"),this.em.get&&this.setElement(this.getCanvas()),this.canvas&&(this.$canvas=this.$el,this.$wrapper=$(this.getCanvasWrapper()),this.frameEl=this.canvas.getFrameEl(),this.canvasTool=this.getCanvasTools(),this.bodyEl=this.getCanvasBody()),this.init(this.config)},onFrameScroll:function(a){},getCanvas:function(){return this.canvas.getElement()},getCanvasBody:function(){return this.canvas.getBody()},getCanvasWrapper:function(){return this.canvas.getWrapperEl()},getCanvasTools:function(){return this.canvas.getToolsEl()},offset:function(a){var b=a.getBoundingClientRect();return{top:b.top+a.ownerDocument.body.scrollTop,left:b.left+a.ownerDocument.body.scrollLeft}},init:function(a){},run:function(a,b){},stop:function(a,b){}})}),c("Abstract/view/DomainViews",["backbone"],function(a){return a.View.extend({itemView:"",itemsView:"",itemType:"type",initialize:function(a,b){this.config=b||{}},addTo:function(a){ -this.add(a)},add:function(a,b){var c=b||null,d=this.itemView,e=a.get(this.itemType);this.itemsView&&this.itemsView[e]&&(d=this.itemsView[e]);var f=new d({model:a,config:this.config},this.config),g=f.render().el;c?c.appendChild(g):this.$el.append(g)},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.length&&this.collection.each(function(b){this.add(b,a)},this),this.$el.append(a),this}})}),c("DomComponents/view/ToolbarButtonView",["backbone"],function(a){return a.View.extend({events:{mousedown:"handleClick"},attributes:function(){return this.model.get("attributes")},initialize:function(a){this.editor=a.config.editor},handleClick:function(){var a=this.model.get("command");"function"==typeof a&&a(this.editor),"string"==typeof a&&this.editor.runCommand(a)},render:function(){var a=this.editor.getConfig();return this.el.className+=" "+a.stylePrefix+"toolbar-item",this}})}),c("DomComponents/view/ToolbarView",["backbone","Abstract/view/DomainViews","./ToolbarButtonView"],function(a,b,c){return b.extend({itemView:c,initialize:function(a){this.config={editor:a.editor||""},this.listenTo(this.collection,"reset",this.render)}})}),c("DomComponents/model/ToolbarButton",["backbone"],function(a){return a.Model.extend({defaults:{command:"",attributes:{}}})}),c("DomComponents/model/Toolbar",["backbone","./ToolbarButton"],function(a,b){return a.Collection.extend({model:b})}),c("Commands/view/SelectComponent",["require","DomComponents/view/ToolbarView","DomComponents/model/Toolbar"],function(a){var b=a("DomComponents/view/ToolbarView"),c=a("DomComponents/model/Toolbar");return{init:function(a){_.bindAll(this,"onHover","onOut","onClick","onKeyPress")},enable:function(){_.bindAll(this,"copyComp","pasteComp","onFrameScroll"),this.frameOff=this.canvasOff=this.adjScroll=null;var a=this.config.em.get("Config");this.startSelectComponent(),this.toggleClipboard(a.copyPaste);var b=this.config.em;b.on("component:update",this.updateAttached,this),b.on("change:canvasOffset",this.updateAttached,this),b.on("change:selectedComponent",this.updateToolbar,this)},toggleClipboard:function(a){var b=a||0;b?(key("⌘+c, ctrl+c",this.copyComp),key("⌘+v, ctrl+v",this.pasteComp)):(key.unbind("⌘+c, ctrl+c"),key.unbind("⌘+v, ctrl+v"))},copyComp:function(){var a=this.editorModel.get("selectedComponent");a&&a.get("copyable")&&this.editorModel.set("clipboard",a)},pasteComp:function(){var a=this.editorModel.get("clipboard"),b=this.editorModel.get("selectedComponent");if(a&&b&&b.collection){var c=b.collection.indexOf(b),d=a.clone();b.collection.add(d,{at:c+1})}},getCanvasBodyEl:function(){return this.$bodyEl||(this.$bodyEl=$(this.getCanvasBody())),this.$bodyEl},startSelectComponent:function(){this.toggleSelectComponent(1)},stopSelectComponent:function(){this.toggleSelectComponent()},toggleSelectComponent:function(a){var b="*",c=a?"on":"off";this.getCanvasBodyEl()[c]("mouseover",b,this.onHover)[c]("mouseout",b,this.onOut)[c]("click",b,this.onClick);var d=this.getContentWindow();d[c]("scroll",this.onFrameScroll),d[c]("keydown",this.onKeyPress)},onKeyPress:function(a){var b=a.which||a.keyCode,c=this.editorModel.get("selectedComponent"),d="BODY"!==this.frameEl.contentDocument.activeElement.tagName;if((8==b||46==b)&&(d||a.preventDefault(),c&&!d)){if(!c.get("removable"))return;c.set("status",""),c.destroy(),this.hideBadge(),this.clean(),this.hideHighlighter(),this.editorModel.set("selectedComponent",null)}},onHover:function(a){a.stopPropagation();var b=a.target;this.adjScroll||(this.adjScroll=1,this.onFrameScroll(a),this.updateAttached());var c=this.getElementPos(b);this.updateBadge(b,c),this.updateHighlighter(b,c),this.showElementOffset(b,c)},onOut:function(a){a.stopPropagation(),this.hideBadge(),this.hideHighlighter(),this.hideElementOffset()},showElementOffset:function(a,b){var c=$(a),d=c.data("model");d&&"selected"==d.get("status")||this.editor.runCommand("show-offset",{el:a,elPos:b})},hideElementOffset:function(a,b){this.editor.stopCommand("show-offset")},showFixedElementOffset:function(a,b){this.editor.runCommand("show-offset",{el:a,elPos:b,state:"Fixed"})},hideFixedElementOffset:function(a,b){this.editor&&this.editor.stopCommand("show-offset",{state:"Fixed"})},hideHighlighter:function(){this.canvas.getHighlighter().style.display="none"},onClick:function(a){var b=$(a.target).data("model");if(b){var c=b.get("stylable");(c instanceof Array||c)&&this.onSelect(a,a.target)}},updateBadge:function(a,b){var c=$(a);this.cacheEl=a;var d=c.data("model");if(d&&d.get("badgable")){var e=this.getBadge();e.innerHTML=d.getName();var f=e.style,g="px";f.display="block";var h=this.canvas.getCanvasView().getPosition(),i=e?e.offsetHeight:0,j=e?e.offsetWidth:0,k=b.top-i"),e=this.codeMirror.clone().set({label:c,codeName:a,theme:b,input:d[0]}),f=new this.cm.EditorView({model:e,config:this.cm.getConfig()}).render().$el;return e.init(d[0]),{el:e,$el:f}},enable:function(){if(!this.$editors){var a=this.buildEditor("htmlmixed","hopscotch","HTML"),b=this.buildEditor("css","hopscotch","CSS");this.htmlEditor=a.el,this.cssEditor=b.el,this.$editors=$("
",{"class":this.pfx+"export-dl"}),this.$editors.append(a.$el).append(b.$el)}this.modal&&(this.modal.setTitle("Export template"),this.modal.setContent(this.$editors),this.modal.open());var c=this.protCss||"";this.htmlEditor.setContent(this.em.getHtml()),this.cssEditor.setContent(c+this.cm.getCode(this.wrapper,"css",this.cssc)),this.sender&&this.sender.set("active",!1)},stop:function(){}}}),c("Commands/view/SwitchVisibility",[],function(){return{run:function(a){a.Canvas.getBody().className=this.ppfx+"dashed"},stop:function(a){a.Canvas.getBody().className=""}}}),c("Navigator/config/config",[],function(){return{stylePrefix:"nv-",sortable:1,hidable:1,hideTextnode:1,containerId:"navigator",itemClass:"item",itemsClass:"items"}}),c("text!Navigator/template/item.html",[],function(){return'<% if (hidable) { %>\n\t\n<% } %>\n\n
\n
\n \t\n\t\t\n\t\t\n
\n
\n\n
<%= (count ? count : \'\') %>
\n\n
\n\t\n
\n\n
\n'}),c("Navigator/view/ItemView",["backbone","text!./../template/item.html","require"],function(a,b,c){return a.View.extend({template:_.template(b),initialize:function(a){this.opt=a,this.config=a.config,this.em=a.config.em,this.ppfx=this.em.get("Config").stylePrefix,this.sorter=a.sorter||{},this.pfx=this.config.stylePrefix,"undefined"==typeof this.model.get("open")&&this.model.set("open",!1),this.listenTo(this.model.components,"remove add change reset",this.checkChildren),this.listenTo(this.model,"destroy remove",this.remove),this.listenTo(this.model,"change:status",this.updateStatus),this.listenTo(this.model,"change:open",this.updateOpening),this.className=this.pfx+"item no-select",this.editBtnCls=this.pfx+"nav-item-edit",this.inputNameCls=this.ppfx+"nav-comp-name",this.caretCls=this.ppfx+"nav-item-caret",this.titleCls=this.pfx+"title",this.customNameProp="custom-name",this.events={},this.events["click > #"+this.pfx+"btn-eye"]="toggleVisibility",this.events["click ."+this.caretCls]="toggleOpening",this.events["click ."+this.titleCls]="handleSelect",this.events["click ."+this.editBtnCls]="handleEdit",this.events["blur ."+this.inputNameCls]="handleEditEnd",this.$el.data("model",this.model),this.$el.data("collection",this.model.get("components")),a.config.sortable&&(this.events["mousedown > #"+this.pfx+"move"]="startSort"),this.delegateEvents()},handleEdit:function(a){a.stopPropagation();var b=this.getInputName();b.readOnly=!1,b.focus()},handleEditEnd:function(a){a.stopPropagation();var b=this.getInputName();b.readOnly=!0,this.model.set(this.customNameProp,b.value)},getInputName:function(){return this.inputName||(this.inputName=this.el.querySelector("."+this.inputNameCls)),this.inputName},updateOpening:function(){var a=this.opt.opened||{},b=this.model;b.get("open")?(this.$el.addClass("open"),this.$caret.addClass("fa-chevron-down"),a[b.cid]=b):(this.$el.removeClass("open"),this.$caret.removeClass("fa-chevron-down"),delete a[b.cid])},toggleOpening:function(a){a.stopPropagation(),this.model.components.length&&this.model.set("open",!this.model.get("open"))},handleSelect:function(a){a.stopPropagation();var b=this.em;if(b){var c=b.get("selectedComponent");c&&c.set("status",""),this.model.set("status","selected"),b.set("selectedComponent",this.model)}},startSort:function(a){this.sorter&&this.sorter.startSort(a.target)},freeze:function(){this.$el.addClass(this.pfx+"opac50"),this.model.set("open",0)},unfreeze:function(){this.$el.removeClass(this.pfx+"opac50")},updateStatus:function(a){var b=this.model.get("status"),c=this.pfx+"selected",d=this.$el;switch(b){case"selected":d.addClass(c);break;case"moving":break;default:d.removeClass(c)}},toggleVisibility:function(a){this.$eye||(this.$eye=this.$el.find("> #"+this.pfx+"btn-eye"));var b=_.clone(this.model.get("style")),c=this.pfx+"hide";this.isVisible()?(this.$el.addClass(c),this.$eye.addClass("fa-eye-slash"),b.display="none"):(this.$el.removeClass(c),this.$eye.removeClass("fa-eye-slash"),delete b.display),this.model.set("style",b)},isVisible:function(){var a=this.model.get("style"),b=a.display;if(!b||"none"!=b)return 1},checkChildren:function(){var a=this.countChildren(this.model),b=this.pfx,c="> ."+b+"title-c > ."+b+"title";this.$counter||(this.$counter=this.$el.find("> #"+b+"counter")),a?(this.$el.find(c).removeClass(b+"no-chld"),this.$counter.html(a)):(this.$el.find(c).addClass(b+"no-chld"),this.$counter.empty(),this.model.set("open",0))},countChildren:function(a){var b=0;return a.components.each(function(a){var c=this.opt.isCountable,d=this.config.hideTextnode;c&&!c(a,d)||b++},this),b},render:function(){var a=this.pfx,b=this.isVisible(),d=this.countChildren(this.model);return this.$el.html(this.template({title:this.model.get(this.customNameProp)||this.model.getName(),addClass:d?"":a+"no-chld",editBtnCls:this.editBtnCls,inputNameCls:this.inputNameCls,caretCls:this.caretCls,count:d,visible:b,hidable:this.config.hidable,prefix:a,ppfx:this.ppfx})),"undefined"==typeof ItemsView&&(ItemsView=c("./ItemsView")),this.$components=new ItemsView({collection:this.model.components,config:this.config,sorter:this.sorter,opened:this.opt.opened,parent:this.model}).render().$el,this.$el.find("."+a+"children").html(this.$components),this.$caret=this.$el.find("> ."+a+"title-c > ."+a+"title > #"+a+"caret"),this.model.get("draggable")&&this.config.sortable||this.$el.find("> #"+a+"move").detach(),b||(this.className+=" "+a+"hide"),this.$el.attr("class",_.result(this,"className")),this.updateOpening(),this.updateStatus(),this}})}),c("Navigator/view/ItemsView",["backbone","./ItemView"],function(a,b){return a.View.extend({initialize:function(a){if(this.opt=a,this.config=a.config,this.preview=a.preview,this.ppfx=a.config.pStylePrefix||"",this.pfx=a.config.stylePrefix||"",this.parent=a.parent,this.listenTo(this.collection,"add",this.addTo),this.listenTo(this.collection,"reset resetNavigator",this.render),this.className=this.pfx+"items",this.config.sortable&&!this.opt.sorter){var b=this.pfx,c=this.config.em.get("Utils");this.opt.sorter=new c.Sorter({container:this.el,containerSel:"."+b+"items",itemSel:"."+b+"item",ppfx:this.ppfx,pfx:b,nested:1})}this.sorter=this.opt.sorter||"",this.parent||(this.className+=" "+this.pfx+this.config.containerId),this.$el.data("collection",this.collection)},addTo:function(a){var b=this.collection.indexOf(a);this.addToCollection(a,null,b)},addToCollection:function(a,c,d){var e=c||null,f=b,g=new f({model:a,config:this.config,sorter:this.sorter,isCountable:this.isCountable,opened:this.opt.opened}),h=g.render().el;if(e)e.appendChild(h);else if("undefined"!=typeof d){var i="before";this.$el.children().length==d&&(d--,i="after"),d<0?this.$el.append(h):this.$el.children().eq(d)[i](h)}else this.$el.append(h);return h},isCountable:function(a,b){var c=a.get("type"),d=a.get("tagName");return("textnode"!=c&&"br"!=d||!b)&&!a.get("hiddenLayer")},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.isCountable(b,this.config.hideTextnode)&&this.addToCollection(b,a)},this),this.$el.append(a),this.$el.attr("class",_.result(this,"className")),this}})}),c("Navigator/main",["require","./config/config","./view/ItemsView"],function(a){function b(b,c){var d=c,e=a("./config/config"),f=a("./view/ItemsView");for(var g in e)g in d||(d[g]=e[g]);var h={collection:b,config:d,opened:c.opened||{}};this.ItemsView=new f(h)}return b.prototype={render:function(){return this.ItemsView.render().$el}},b}),c("Navigator",["Navigator/main"],function(a){return a}),c("Commands/view/OpenLayers",["Navigator"],function(a){return{run:function(b,c){if(!this.$layers){var d=b.DomComponents.getComponent().get("components"),e=b.getConfig(),f=b.Panels,g=e.layers.stylePrefix||"nv-";e.layers.stylePrefix=e.stylePrefix+g,e.layers.pStylePrefix=e.stylePrefix,e.layers.em=b.editor,e.layers.opened=b.editor.get("opened");var h=new a(d,e.layers);this.$layers=h.render(),f.getPanel("views-container")?this.panel=f.getPanel("views-container"):this.panel=f.addPanel({id:"views-container"}),this.panel.set("appendContent",this.$layers).trigger("change:appendContent")}this.$layers.show()},stop:function(){this.$layers&&this.$layers.hide()}}}),c("Commands/view/OpenStyleManager",["StyleManager"],function(a){return{run:function(a,b){if(this.sender=b,!this.$cn){var c=a.getConfig(),d=a.Panels;this.$cn=$("
"),this.$cn2=$("
"),this.$cn.append(this.$cn2);var e=a.DeviceManager;if(e&&c.showDevices){var f=d.addPanel({id:"devices-c"});f.set("appendContent",e.render()).trigger("change:appendContent")}var g=a.SelectorManager;g&&this.$cn2.append(g.render([])),this.$cn2.append(a.StyleManager.render());var h=a.StyleManager.getConfig();this.$header=$("
",{"class":h.stylePrefix+"header",text:h.textNoElement}),this.$cn.append(this.$header),d.getPanel("views-container")?this.panel=d.getPanel("views-container"):this.panel=d.addPanel({id:"views-container"}),this.panel.set("appendContent",this.$cn).trigger("change:appendContent"),this.target=a.editor,this.listenTo(this.target,"change:selectedComponent",this.toggleSm)}this.toggleSm()},toggleSm:function(){this.sender.get("active")&&(this.target.get("selectedComponent")?(this.$cn2.show(),this.$header.hide()):(this.$cn2.hide(),this.$header.show()))},stop:function(){this.$cn2&&this.$cn2.hide(),this.$header&&this.$header.hide()}}}),c("Commands/view/OpenTraitManager",[],function(){return{run:function(a,b){var c=a.Config,d=c.stylePrefix,e=a.TraitManager;if(!this.obj){var f=e.getTraitsViewer(),g=e.getConfig();this.obj=$("
").append('
'+g.labelContainer+"
").get(0),this.obj.appendChild(f.render().el);var h=a.Panels;h.getPanel("views-container")?panelC=h.getPanel("views-container"):panelC=h.addPanel({id:"views-container"}),panelC.set("appendContent",this.obj).trigger("change:appendContent")}this.obj.style.display="block"},stop:function(){this.obj&&(this.obj.style.display="none")}}}),c("Commands/view/OpenBlocks",[],function(){return{run:function(a,b){var c=a.Config,d=(c.stylePrefix,a.BlockManager);if(!this.blocks){this.blocks=$("
").get(0),this.blocks.appendChild(d.render());var e=a.Panels;e.getPanel("views-container")?panelC=e.getPanel("views-container"):panelC=e.addPanel({id:"views-container"}),panelC.set("appendContent",this.blocks).trigger("change:appendContent")}this.blocks.style.display="block"},stop:function(){this.blocks&&(this.blocks.style.display="none")}}}),c("Commands/view/OpenAssets",[],function(){return{run:function(a,b,c){var d=c||{},e=(a.getConfig(),a.Modal),f=a.AssetManager;f.onClick(d.onClick),f.onDblClick(d.onDblClick),f.setTarget(d.target),f.onSelect(d.onSelect),e.setTitle(d.modalTitle||"Select image"),e.setContent(f.render()),e.open()}}}),c("Commands/view/ShowOffset",[],function(){return{getOffsetMethod:function(a){var b=a||"";return"get"+b+"OffsetViewerEl"},run:function(a,b,c){var d=c||{},e=d.state||"",f=a.getConfig();if(f.showOffsets&&(f.showOffsetsSelected||"Fixed"!=e)){var g=a.Canvas,h=d.el||"",i=d.elPos||g.getElementPos(h),j=window.getComputedStyle(h),k=this.ppfx,l=e+"State",m=this.getOffsetMethod(e),n=g[m]();n.style.display="block";var o=this["marginT"+e],p=this["marginB"+e],q=this["marginL"+e],r=this["marginR"+e],s=this["padT"+e],t=this["padB"+e],u=this["padL"+e],v=this["padR"+e];if(!this[l]){var w=e.toLowerCase(),x=w+"margin-v",y=w+"padding-v",z=$("
",{"class":k+x}).get(0),A=$("
",{"class":k+y}).get(0),B=k+x+"-el",C=k+y+"-el";o=$("
",{"class":k+x+"-top "+B}).get(0),p=$("
",{"class":k+x+"-bottom "+B}).get(0),q=$("
",{"class":k+x+"-left "+B}).get(0),r=$("
",{"class":k+x+"-right "+B}).get(0),s=$("
",{"class":k+y+"-top "+C}).get(0),t=$("
",{"class":k+y+"-bottom "+C}).get(0),u=$("
",{"class":k+y+"-left "+C}).get(0),v=$("
",{"class":k+y+"-right "+C}).get(0),this["marginT"+e]=o,this["marginB"+e]=p,this["marginL"+e]=q,this["marginR"+e]=r,this["padT"+e]=s,this["padB"+e]=t,this["padL"+e]=u,this["padR"+e]=v,z.appendChild(o),z.appendChild(p),z.appendChild(q),z.appendChild(r),A.appendChild(s),A.appendChild(t),A.appendChild(u),A.appendChild(v),n.appendChild(z),n.appendChild(A),this[l]="1"}var D="px",E=j.marginLeft.replace(D,""),F=parseInt(j.marginTop.replace(D,"")),G=parseInt(j.marginBottom.replace(D,"")),H=o.style,I=p.style,J=q.style,K=r.style,L=s.style,M=t.style,N=u.style,O=v.style,P=parseInt(i.left);H.height=j.marginTop,H.width=j.width,H.top=i.top-j.marginTop.replace(D,"")+D,H.left=P+D,I.height=j.marginBottom,I.width=j.width,I.top=i.top+i.height+D,I.left=P+D;var Q=i.height+F+G+D,R=i.top-F+D;J.height=Q,J.width=j.marginLeft,J.top=R,J.left=P-E+D,K.height=Q,K.width=j.marginRight,K.top=R,K.left=P+i.width+D;var S=parseInt(j.paddingTop.replace(D,""));L.height=j.paddingTop,L.width=j.width,L.top=i.top+D,L.left=P+D;var T=parseInt(j.paddingBottom.replace(D,""));M.height=j.paddingBottom,M.width=j.width,M.top=i.top+i.height-T+D,M.left=P+D;var U=i.height-T-S+D,V=i.top+S+D;N.height=U,N.width=j.paddingLeft,N.top=V,N.left=i.left+D;var W=parseInt(j.paddingRight.replace(D,""));O.height=U,O.width=j.paddingRight,O.top=V,O.left=i.left+i.width-W+D}},stop:function(a,b,c){var d=c||{},e=d.state||"",f=this.getOffsetMethod(e),g=a.Canvas,h=g[f]();h.style.display="none"}}}),c("Commands/view/Fullscreen",[],function(){return{isEnabled:function(){var a=document;return a.fullscreenElement||a.webkitFullscreenElement||a.mozFullScreenElement?1:0},enable:function(a){var b="";return a.requestFullscreen?a.requestFullscreen():a.webkitRequestFullscreen?(b="webkit",a.webkitRequestFullscreen()):a.mozRequestFullScreen?(b="moz",a.mozRequestFullScreen()):a.msRequestFullscreen?a.msRequestFullscreen():console.warn("Fullscreen not supported"),b},disable:function(){var a=document;a.exitFullscreen?a.exitFullscreen():a.webkitExitFullscreen?a.webkitExitFullscreen():a.mozCancelFullScreen?a.mozCancelFullScreen():a.msExitFullscreen&&a.msExitFullscreen()},fsChanged:function(a,b){var c=(document,(a||"")+"fullscreenchange");this.isEnabled()||(this.stop(null,this.sender),document.removeEventListener(c,this.fsChanged))},run:function(a,b){this.sender=b;var c=this.enable(a.getContainer());this.fsChanged=this.fsChanged.bind(this,c), -document.addEventListener(c+"fullscreenchange",this.fsChanged),a&&a.trigger("change:canvasOffset")},stop:function(a,b){b&&b.set&&b.set("active",!1),this.disable(),a&&a.trigger("change:canvasOffset")}}}),c("Commands/view/Preview",[],function(){return{getPanels:function(a){return this.panels||(this.panels=a.Panels.getPanelsEl()),this.panels},tglPointers:function(a,b){var c=a.Canvas.getBody().querySelectorAll("."+this.ppfx+"no-pointer");_.each(c,function(a){a.style.pointerEvents=b?"":"all"})},run:function(a,b){b&&b.set&&b.set("active",!1),a.stopCommand("sw-visibility");var c=this,d=this.getPanels(a),e=a.Canvas.getElement(),f=a.getEl(),g=a.Config.stylePrefix;this.helper||(this.helper=document.createElement("span"),this.helper.className=g+"off-prv fa fa-eye-slash",f.appendChild(this.helper),this.helper.onclick=function(){c.stop(a)}),this.helper.style.display="inline-block",this.tglPointers(a),d.style.display="none";var h=e.style;h.width="100%",h.height="100%",h.top="0",h.left="0",h.padding="0",h.margin="0",a.trigger("change:canvasOffset")},stop:function(a,b){var c=this.getPanels(a);a.runCommand("sw-visibility"),a.getModel().runDefault(),c.style.display="block";var d=a.Canvas.getElement();d.setAttribute("style",""),this.helper&&(this.helper.style.display="none"),a.trigger("change:canvasOffset"),this.tglPointers(a,1)}}}),c("Commands/view/Resize",[],function(){return{run:function(a,b,c){var d=c&&c.el||"",e=a.Canvas,f=this.canvasResizer,g=c.options||{};if(!f){var h=e.getCanvasView();g.ratioDefault=1,g.appendTo=e.getResizerEl(),g.prefix=a.getConfig().stylePrefix,g.posFetcher=h.getElementPos.bind(h),g.mousePosFetcher=e.getMouseRelativePos,this.canvasResizer=a.Utils.Resizer.init(g),f=this.canvasResizer}f.setOptions(g),f.focus(d)},stop:function(){this.canvasResizer&&this.canvasResizer.blur()}}}),c("Commands/main",["require","./config/config","./view/CommandAbstract","./view/SelectComponent","./view/CreateComponent","./view/DeleteComponent","./view/ImageComponent","./view/MoveComponent","./view/TextComponent","./view/InsertCustom","./view/ExportTemplate","./view/SwitchVisibility","./view/OpenLayers","./view/OpenStyleManager","./view/OpenTraitManager","./view/OpenBlocks","./view/OpenAssets","./view/ShowOffset","./view/Fullscreen","./view/Preview","./view/Resize"],function(a){return function(){var b={},c={},d={},e=a("./config/config"),f=a("./view/CommandAbstract"),g=function(a,b){return delete b.initialize,c[a]=f.extend(b),this};return{name:"Commands",init:function(c){b=c||{};for(var f in e)f in b||(b[f]=e[f]);var g=b.pStylePrefix;g&&(b.stylePrefix=g+b.stylePrefix);for(var h in b.defaults){var i=b.defaults[h];i.id&&this.add(i.id,i)}return d["select-comp"]=a("./view/SelectComponent"),d["create-comp"]=a("./view/CreateComponent"),d["delete-comp"]=a("./view/DeleteComponent"),d["image-comp"]=a("./view/ImageComponent"),d["move-comp"]=a("./view/MoveComponent"),d["text-comp"]=a("./view/TextComponent"),d["insert-custom"]=a("./view/InsertCustom"),d["export-template"]=a("./view/ExportTemplate"),d["sw-visibility"]=a("./view/SwitchVisibility"),d["open-layers"]=a("./view/OpenLayers"),d["open-sm"]=a("./view/OpenStyleManager"),d["open-tm"]=a("./view/OpenTraitManager"),d["open-blocks"]=a("./view/OpenBlocks"),d["open-assets"]=a("./view/OpenAssets"),d["show-offset"]=a("./view/ShowOffset"),d.fullscreen=a("./view/Fullscreen"),d.preview=a("./view/Preview"),d.resize=a("./view/Resize"),d["tlb-delete"]={run:function(a){var b=a.getSelected();return b&&b.get("removable")?(b.set("status",""),b.destroy(),a.trigger("component:update",b),void a.editor.set("selectedComponent",null)):void console.warn("The element is not removable")}},d["tlb-clone"]={run:function(a){var b=a.getSelected();if(!b||!b.get("copyable"))return void console.warn("The element is not clonable");var c=b.collection,d=c.indexOf(b);c.add(b.clone(),{at:d+1}),a.trigger("component:update",b)}},d["tlb-move"]={run:function(a){var b=a.getSelected();if(!b||!b.get("draggable"))return void console.warn("The element is not draggable");var c=a.Canvas.getToolbarEl(),d=a.Commands.get("move-comp");d.onEndMoveFromModel=function(){a.editor.runDefault(),a.editor.set("selectedComponent",b),a.trigger("component:update",b)},a.editor.stopDefault(),d.initSorterFromModel(b),b.set("status","selected"),c.style.display="none"}},b.em&&(b.model=b.em.get("Canvas")),this},onLoad:function(){this.loadDefaultCommands()},add:g,get:function(a){var d=c[a];return"function"==typeof d&&(d=new d(b),c[a]=d),d},has:function(a){return!!c[a]},loadDefaultCommands:function(){for(var a in d)this.add(a,d[a]);return this}}}}),c("Commands",["Commands/main"],function(a){return a}),c("BlockManager/config/config",[],function(){return{blocks:[]}}),c("BlockManager/model/Block",["backbone"],function(a){return a.Model.extend({defaults:{label:"",content:"",attributes:{}}})}),c("BlockManager/model/Blocks",["backbone","./Block"],function(a,b){return a.Collection.extend({model:b})}),c("BlockManager/view/BlockView",["backbone"],function(a){return a.View.extend({events:{mousedown:"onDrag"},initialize:function(a,b){_.bindAll(this,"onDrop"),this.config=b||{},this.ppfx=this.config.pStylePrefix||"",this.listenTo(this.model,"destroy",this.remove),this.doc=$(document)},onDrag:function(a){if(this.config.getSorter){this.config.em.refreshCanvas();var b=this.config.getSorter();b.setDragHelper(this.el,a),b.startSort(this.el),b.setDropContent(this.model.get("content")),this.doc.on("mouseup",this.onDrop)}},onDrop:function(){this.doc.off("mouseup",this.onDrop),this.config.getSorter().endMove()},render:function(){var a=this.ppfx+"block";return this.$el.addClass(a),this.el.innerHTML='
'+this.model.get("label")+"
",this}})}),c("BlockManager/view/BlocksView",["backbone","./BlockView"],function(a,b){return a.View.extend({initialize:function(a,b){_.bindAll(this,"getSorter","onDrag","onDrop"),this.config=b||{},this.ppfx=this.config.pStylePrefix||"",this.listenTo(this.collection,"add",this.addTo),this.em=this.config.em,this.tac="test-tac",this.grabbingCls=this.ppfx+"grabbing",this.em&&(this.config.getSorter=this.getSorter,this.canvas=this.em.get("Canvas"))},getSorter:function(){if(this.em){if(!this.sorter){var a=this.em.get("Utils"),b=this.canvas;this.sorter=new a.Sorter({container:b.getBody(),placer:b.getPlacerEl(),containerSel:"*",itemSel:"*",pfx:this.ppfx,onStart:this.onDrag,onEndMove:this.onDrop,document:b.getFrameEl().contentDocument,direction:"a",wmargin:1,nested:1,em:this.em,canvasRelative:1})}return this.sorter}},onDrag:function(){this.em.stopDefault()},onDrop:function(a){this.em.runDefault(),a&&a.get&&(a.get("activeOnRender")&&(a.trigger("active"),a.set("activeOnRender",0)),this.em.initChildrenComp(a))},addTo:function(a){this.add(a)},add:function(a,c){var d=c||null,e=new b({model:a,attributes:a.get("attributes")},this.config),f=e.render().el;d?d.appendChild(f):this.$el.append(f)},render:function(){var a=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(b){this.add(b,a)},this),this.$el.append(a),this.$el.addClass(this.ppfx+"blocks-c"),this}})}),c("BlockManager/main",["require","./config/config","./model/Blocks","./view/BlocksView"],function(a){return function(){var b,c,d={},e=a("./config/config"),f=a("./model/Blocks"),g=a("./view/BlocksView");return{name:"BlockManager",init:function(a){d=a||{};for(var h in e)h in d||(d[h]=e[h]);return b=new f(d.blocks),c=new g({collection:b},d),this},add:function(a,c){var d=c||{};return d.id=a,b.add(d)},get:function(a){return b.get(a)},getAll:function(){return b},render:function(){return c.render().el}}}}),c("BlockManager",["BlockManager/main"],function(a){return a}),c("TraitManager/config/config",[],function(){return{stylePrefix:"trt-",labelContainer:"Component settings"}}),c("TraitManager/view/TraitView",["backbone"],function(a){return a.View.extend({events:{change:"onChange"},initialize:function(a){var b=this.model;this.config=a.config||{},this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.target=b.target,this.className=this.pfx+"trait",this.labelClass=this.ppfx+"label",this.fieldClass=this.ppfx+"field "+this.ppfx+"field-"+b.get("type"),this.inputhClass=this.ppfx+"input-holder",b.off("change:value",this.onValueChange),this.listenTo(b,"change:value",this.onValueChange),this.tmpl='
'},onChange:function(){this.model.set("value",this.getInputEl().value)},getValueForTarget:function(){return this.model.get("value")},onValueChange:function(){var a=this.model,b=this.target,c=a.get("name"),d=this.getValueForTarget();if(a.get("changeProp"))b.set(c,d);else{var e=_.clone(b.get("attributes"));e[c]=d,b.set("attributes",e)}},renderLabel:function(){this.$el.html('
'+this.getLabel()+"
")},getLabel:function(){var a=this.model,b=a.get("label")||a.get("name");return b.charAt(0).toUpperCase()+b.slice(1).replace(/-/g," ")},getInputEl:function(){if(!this.$input){var a=this.model,b=this.target,c=a.get("name"),d={placeholder:a.get("placeholder")||a.get("default"),type:a.get("type")||"text"};if(a.get("changeProp"))d.value=b.get(c);else{var e=b.get("attributes");d.value=a.get("value")||e[c]}a.get("min")&&(d.min=a.get("min")),a.get("max")&&(d.max=a.get("max")),this.$input=$("",d)}return this.$input.get(0)},getModelValue:function(){var a,b=this.model,c=this.target,d=b.get("name");if(b.get("changeProp"))a=c.get(d);else{var e=c.get("attributes");a=b.get("value")||e[d]}return a},renderField:function(){if(!this.$input){this.$el.append(this.tmpl);var a=this.getInputEl();this.$el.find("."+this.inputhClass).prepend(a)}},render:function(){return this.renderLabel(),this.renderField(),this.el.className=this.className,this}})}),c("TraitManager/view/TraitSelectView",["backbone","./TraitView"],function(a,b){return b.extend({initialize:function(a){b.prototype.initialize.apply(this,arguments);var c=this.ppfx;this.tmpl='
'},getInputEl:function(){if(!this.$input){var a=this.model,b=a.get("options")||[],c="",this.input=c,this.$input=$(this.input);var d=this.target,e=a.get("name"),f=a.get("value");if(a.get("changeProp"))f=f||d.get(e);else{var g=d.get("attributes");f=g[e]}f&&this.$input.val(f)}return this.$input.get(0)}})}),c("TraitManager/view/TraitCheckboxView",["./TraitView"],function(a){return a.extend({initialize:function(b){a.prototype.initialize.apply(this,arguments);var c=this.ppfx+"chk-icon";this.tmpl='
'},onChange:function(){this.model.set("value",this.getInputEl().checked)},getInputEl:function(){var b;this.$input||(b=1);var c=a.prototype.getInputEl.apply(this,arguments);if(b){var d=this.model,e=d.get("name"),f=this.target;if(d.get("changeProp"))c.checked=f.get(e);else{var g=f.get("attributes");c.checked=!!g[e]}}return c}})}),c("TraitManager/view/TraitNumberView",["./TraitView","Abstract/ui/InputNumber"],function(a,b){return a.extend({getValueForTarget:function(){var a=this.model,b=a.get("value"),c=a.get("unit");return b?b+c:""},getInputEl:function(){if(!this.$input){var a=this.getModelValue(),c=new b({contClass:this.ppfx+"field-int",model:this.model,ppfx:this.ppfx});this.input=c.render(),this.$input=this.input.inputEl,this.$unit=this.input.unitEl,this.model.set("value",a),this.$input.val(a)}return this.$input.get(0)},renderField:function(){this.$input||(this.$el.append(this.tmpl),this.getInputEl(),this.$el.find("."+this.inputhClass).prepend(this.input.el))}})}),c("TraitManager/view/TraitColorView",["./TraitView","Abstract/ui/InputColor"],function(a,b){return a.extend({getInputEl:function(){if(!this.$input){var a=this.getModelValue(),c=new b({contClass:this.ppfx+"field-color",model:this.model,ppfx:this.ppfx});this.input=c.render(),this.$input=this.input.colorEl,a=a||"",this.model.set("value",a).trigger("change:value")}return this.$input.get(0)},renderField:function(){this.$input||(this.getInputEl(),this.$el.append(this.input.el))}})}),c("TraitManager/view/TraitsView",["require","Abstract/view/DomainViews","./TraitView","./TraitSelectView","./TraitCheckboxView","./TraitNumberView","./TraitColorView"],function(a){var b=a("Abstract/view/DomainViews"),c=a("./TraitView"),d=a("./TraitSelectView"),e=a("./TraitCheckboxView"),f=a("./TraitNumberView"),g=a("./TraitColorView");return b.extend({itemView:c,itemsView:{text:c,number:f,select:d,checkbox:e,color:g},initialize:function(a){this.config=a.config||{},this.em=a.editor,this.pfx=this.config.stylePrefix||"",this.className=this.pfx+"traits",this.listenTo(this.em,"change:selectedComponent",this.updatedCollection),this.updatedCollection()},updatedCollection:function(){this.el.className=this.className;var a=this.em.get("selectedComponent");a&&(this.collection=a.get("traits"),this.render())}})}),c("TraitManager/main",["require","./config/config","./model/Traits","./view/TraitsView"],function(a){return function(){var b,c={},d=a("./config/config"),e=(a("./model/Traits"),a("./view/TraitsView"));return{TraitsView:e,name:"TraitManager",getConfig:function(){return c},init:function(a){c=a||{};for(var f in d)f in c||(c[f]=d[f]);var g=c.pStylePrefix;return g&&(c.stylePrefix=g+c.stylePrefix),b=new e({collection:[],editor:c.em,config:c}),this},getTraitsViewer:function(){return b},addType:function(a,c){var d=b.itemView;b.itemsView[a]=d.extend(c)},getType:function(a){return b.itemsView[a]}}}}),c("TraitManager",["TraitManager/main"],function(a){return a});var d=["Utils","StorageManager","DeviceManager","Parser","SelectorManager","ModalDialog","CodeManager","Panels","RichTextEditor","StyleManager","AssetManager","CssComposer","DomComponents","Canvas","Commands","BlockManager","TraitManager"];return c("editor/model/Editor",["backbone","backboneUndo","keymaster","Utils","StorageManager","DeviceManager","Parser","SelectorManager","ModalDialog","CodeManager","Panels","RichTextEditor","StyleManager","AssetManager","CssComposer","DomComponents","Canvas","Commands","BlockManager","TraitManager"],function(){return Backbone.Model.extend({defaults:{clipboard:null,designerMode:!1,selectedComponent:null,previousModel:null,changesCount:0,storables:[],toLoad:[],opened:{},device:""},initialize:function(a){this.config=a,this.set("Config",a),a.el&&a.fromElement&&(this.config.components=a.el.innerHTML),d.forEach(function(a){this.loadModule(a)},this),this.get("toLoad").forEach(function(a){a.onLoad()}),this.initUndoManager(),this.on("change:selectedComponent",this.componentSelected,this),this.on("change:changesCount",this.updateBeforeUnload,this)},updateBeforeUnload:function(){var a=this.get("changesCount");this.config.noticeOnUnload&&a?window.onbeforeunload=function(a){return 1}:window.onbeforeunload=null},loadModule:function(a){var c=this.config,d=new b(a)(),e=d.name.charAt(0).toLowerCase()+d.name.slice(1),f=c[e]||c[d.name]||{};f.pStylePrefix=c.pStylePrefix||"";var g=this.get("StorageManager");if(d.storageKey&&d.store&&d.load&&g){f.stm=g;var h=this.get("storables");h.push(d),this.set("storables",h)}return f.em=this,d.init(Object.create(f)),d["private"]||this.set(d.name,d),d.onLoad&&this.get("toLoad").push(d),this},init:function(a){this.set("Editor",a)},listenRules:function(a){this.stopListening(a,"add remove",this.listenRule),this.listenTo(a,"add remove",this.listenRule),a.each(function(a){this.listenRule(a)},this)},listenRule:function(a){this.stopListening(a,"change:style",this.ruleUpdated),this.listenTo(a,"change:style",this.ruleUpdated)},ruleUpdated:function(a,b,c){var d=this.get("changesCount")+1,e=c?c.avoidStore:0;this.set("changesCount",d);var f=this.get("StorageManager");f.isAutosave()&&d"+a+"":""},getCss:function(){var a=this.get("CssComposer"),b=this.get("DomComponents").getComponent(),c=this.config.protectedCss;return c+this.get("CodeManager").getCode(b,"css",a)},getJs:function(){var a=this.get("DomComponents").getWrapper();return this.get("CodeManager").getCode(a,"js").trim()},store:function(a){var b=this.get("StorageManager"),c={};if(b)return this.get("storables").forEach(function(a){var b=a.store(1);for(var d in b)c[d]=b[d]}),b.store(c,a),this.set("changesCount",0),this.trigger("storage:store",c),c},load:function(a){var b=this.getCacheLoad(1);return this.get("storables").forEach(function(a){a.load(b)}),b},getCacheLoad:function(a){var b=a?1:0;if(this.cacheLoad&&!b)return this.cacheLoad;var c=this.get("StorageManager"),d=[];return c?(this.get("storables").forEach(function(a){var b=a.storageKey;b="function"==typeof b?b():b,keys=b instanceof Array?b:[b],keys.forEach(function(a){d.push(a)})}),this.cacheLoad=c.load(d),this.trigger("storage:load",this.cacheLoad),this.cacheLoad):{}},getDeviceModel:function(){var a=this.get("device");return this.get("DeviceManager").get(a)},runDefault:function(){var a=this.get("Commands").get(this.config.defaultCommand);a&&!this.defaultRunning&&(a.stop(this,this),a.run(this,this),this.defaultRunning=1)},stopDefault:function(){var a=this.get("Commands").get(this.config.defaultCommand);a&&(a.stop(this,this),this.defaultRunning=0)},refreshCanvas:function(){this.set("canvasOffset",this.get("Canvas").getOffset())},clearSelection:function(a){var b=a||window;b.getSelection().removeAllRanges()}})}),c("editor/view/EditorView",["backbone"],function(a){return a.View.extend({initialize:function(){this.pn=this.model.get("Panels"),this.conf=this.model.config,this.className=this.conf.stylePrefix+"editor",this.model.on("loaded",function(){this.pn.active(),this.model.runDefault(),this.model.trigger("load")},this)},render:function(){var a=this.model,b=a.get("UndoManager"),c=a.get("DomComponents"),d=a.get("Config");d.loadCompsOnRender&&(d.clearOnRender&&c.clear(),c.getComponents().add(d.components),b.clear(),c.onLoad());var e=this.conf,f=$(e.el||"body "+e.container);return this.$el.empty(),e.width&&f.css("width",e.width),e.height&&f.css("height",e.height),this.$el.append(a.get("Canvas").render()),this.$el.append(this.pn.render()),this.$el.attr("class",this.className),f.addClass(e.stylePrefix+"editor-cont"),f.html(this.$el),this}})}),c("editor/main",["require","./config/config","./model/Editor","./view/EditorView"],function(a){var b=function(b){var c=b||{},d=a("./config/config"),e=a("./model/Editor"),f=a("./view/EditorView");for(var g in d)g in c||(c[g]=d[g]);c.pStylePrefix=c.stylePrefix;var h=new e(c),i=new f({model:h,config:c});return{editor:h,DomComponents:h.get("DomComponents"),CssComposer:h.get("CssComposer"),StorageManager:h.get("StorageManager"),AssetManager:h.get("AssetManager"),BlockManager:h.get("BlockManager"),TraitManager:h.get("TraitManager"),SelectorManager:h.get("SelectorManager"),CodeManager:h.get("CodeManager"),Commands:h.get("Commands"),Modal:h.get("Modal"),Panels:h.get("Panels"),StyleManager:h.get("StyleManager"),Canvas:h.get("Canvas"),UndoManager:h.get("UndoManager"),DeviceManager:h.get("DeviceManager"),RichTextEditor:h.get("rte"),Utils:h.get("Utils"),Config:h.get("Config"),init:function(){return h.init(this),this},getConfig:function(){return c},getHtml:function(){return h.getHtml()},getCss:function(){return h.getCss()},getJs:function(){return h.getJs()},getComponents:function(){return h.get("DomComponents").getComponents()},setComponents:function(a){return h.setComponents(a),this},addComponents:function(a){return this.getComponents().add(a)},getStyle:function(){return h.get("CssComposer").getAll()},setStyle:function(a){return h.setStyle(a),this},getSelected:function(){return h.getSelected()},setDevice:function(a){return h.set("device",a)},getDevice:function(){return h.get("device")},runCommand:function(a,b){var c,d=h.get("Commands").get(a);return d&&(c=d.run(this,this,b),this.trigger("run:"+a)),c},stopCommand:function(a,b){var c,d=h.get("Commands").get(a);return d&&(c=d.stop(this,this,b),this.trigger("stop:"+a)),c},store:function(a){return h.store(a)},load:function(){return h.load()},getContainer:function(){return c.el},refresh:function(){h.refreshCanvas()},setCustomRte:function(a){this.RichTextEditor.customRte=a},on:function(a,b){return h.on(a,b)},trigger:function(a){return h.trigger(a)},getEl:function(){return i.el},getModel:function(){return h},render:function(){return i.render().el}}};return b}),c("PluginManager/config/config",[],function(){return{plugins:[]}}),c("PluginManager/main",["require","./config/config"],function(a){return function(b){var c=b||{},d=a("./config/config");for(var e in d)e in c||(c[e]=d[e]);var f={};return{add:function(a,b){return f[a]?this:(f[a]=b,this)},get:function(a){return f[a]},getAll:function(){return f}}}}),c("PluginManager",["PluginManager/main"],function(a){return a}),c("grapesjs/main",["require","./config/config","editor/main","PluginManager"],function(a){return function(b){var c=a("./config/config"),d=a("editor/main"),e=a("PluginManager"),f=new e,g=[];return{editors:g,plugins:f,init:function(a){var b=a||{},e=b.container;for(var h in c)h in b||(b[h]=c[h]);if(!e)throw new Error("'container' is required");b.el=document.querySelector(e);var i=new d(b).init(),j=f.getAll();for(var k in j)if(!(b.plugins.indexOf(k)<0)){var l=b.pluginsOpts[k]||{},m=f.get(k);m(i,l)}return b.autorender&&i.render(),g.push(i),i}}}()}),b(["src/config/require-config.js"],function(){b(["grapesjs/main"],function(a){return a})}),c("main",function(){}),b("grapesjs/main")}); +/*! grapesjs - 0.14.25 */ +!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports.grapesjs=e():t.grapesjs=e()}(window,function(){return function(t){var e={};function n(i){if(e[i])return e[i].exports;var r=e[i]={i:i,l:!1,exports:{}};return t[i].call(r.exports,r,r.exports,n),r.l=!0,r.exports}return n.m=t,n.c=e,n.d=function(t,e,i){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:i})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var i=Object.create(null);if(n.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var r in t)n.d(i,r,function(e){return t[e]}.bind(null,r));return i},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=235)}([function(t,e,n){(function(i){var r,o;!function(s){var a="object"==typeof self&&self.self===self&&self||"object"==typeof i&&i.global===i&&i;r=[n(1),n(20),e],void 0===(o=function(t,e,n){a.Backbone=function(t,e,n,i){var r=t.Backbone,o=Array.prototype.slice;e.VERSION="1.3.3",e.$=i,e.noConflict=function(){return t.Backbone=r,this},e.emulateHTTP=!1,e.emulateJSON=!1;var s=function(t,e,i){n.each(e,function(e,r){n[r]&&(t.prototype[r]=function(t,e,i){switch(t){case 1:return function(){return n[e](this[i])};case 2:return function(t){return n[e](this[i],t)};case 3:return function(t,r){return n[e](this[i],a(t,this),r)};case 4:return function(t,r,o){return n[e](this[i],a(t,this),r,o)};default:return function(){var t=o.call(arguments);return t.unshift(this[i]),n[e].apply(n,t)}}}(e,r,i))})},a=function(t,e){return n.isFunction(t)?t:n.isObject(t)&&!e._isModel(t)?l(t):n.isString(t)?function(e){return e.get(t)}:t},l=function(t){var e=n.matches(t);return function(t){return e(t.attributes)}},c=e.Events={},u=/\s+/,h=function(t,e,i,r,o){var s,a=0;if(i&&"object"==typeof i){void 0!==r&&"context"in o&&void 0===o.context&&(o.context=r);for(s=n.keys(i);athis.length&&(r=this.length),r<0&&(r+=this.length+1);var o,s,a=[],l=[],c=[],u=[],h={},d=e.add,f=e.merge,p=e.remove,g=!1,v=this.comparator&&null==r&&!1!==e.sort,m=n.isString(this.comparator)?this.comparator:null;for(s=0;s7),this._useHashChange=this._wantsHashChange&&this._hasHashChange,this._wantsPushState=!!this.options.pushState,this._hasPushState=!(!this.history||!this.history.pushState),this._usePushState=this._wantsPushState&&this._hasPushState,this.fragment=this.getFragment(),this.root=("/"+this.root+"/").replace(D,"/"),this._wantsHashChange&&this._wantsPushState){if(!this._hasPushState&&!this.atRoot()){var e=this.root.slice(0,-1)||"/";return this.location.replace(e+"#"+this.getPath()),!0}this._hasPushState&&this.atRoot()&&this.navigate(this.getHash(),{replace:!0})}if(!this._hasHashChange&&this._wantsHashChange&&!this._usePushState){this.iframe=document.createElement("iframe"),this.iframe.src="javascript:0",this.iframe.style.display="none",this.iframe.tabIndex=-1;var i=document.body,r=i.insertBefore(this.iframe,i.firstChild).contentWindow;r.document.open(),r.document.close(),r.location.hash="#"+this.fragment}var o=window.addEventListener||function(t,e){return attachEvent("on"+t,e)};if(this._usePushState?o("popstate",this.checkUrl,!1):this._useHashChange&&!this.iframe?o("hashchange",this.checkUrl,!1):this._wantsHashChange&&(this._checkUrlInterval=setInterval(this.checkUrl,this.interval)),!this.options.silent)return this.loadUrl()},stop:function(){var t=window.removeEventListener||function(t,e){return detachEvent("on"+t,e)};this._usePushState?t("popstate",this.checkUrl,!1):this._useHashChange&&!this.iframe&&t("hashchange",this.checkUrl,!1),this.iframe&&(document.body.removeChild(this.iframe),this.iframe=null),this._checkUrlInterval&&clearInterval(this._checkUrlInterval),L.started=!1},route:function(t,e){this.handlers.unshift({route:t,callback:e})},checkUrl:function(t){var e=this.getFragment();if(e===this.fragment&&this.iframe&&(e=this.getHash(this.iframe.contentWindow)),e===this.fragment)return!1;this.iframe&&this.navigate(e),this.loadUrl()},loadUrl:function(t){return!!this.matchRoot()&&(t=this.fragment=this.getFragment(t),n.some(this.handlers,function(e){if(e.route.test(t))return e.callback(t),!0}))},navigate:function(t,e){if(!L.started)return!1;e&&!0!==e||(e={trigger:!!e}),t=this.getFragment(t||"");var n=this.root;""!==t&&"?"!==t.charAt(0)||(n=n.slice(0,-1)||"/");var i=n+t;if(t=this.decodeFragment(t.replace(I,"")),this.fragment!==t){if(this.fragment=t,this._usePushState)this.history[e.replace?"replaceState":"pushState"]({},document.title,i);else{if(!this._wantsHashChange)return this.location.assign(i);if(this._updateHash(this.location,t,e.replace),this.iframe&&t!==this.getHash(this.iframe.contentWindow)){var r=this.iframe.contentWindow;e.replace||(r.document.open(),r.document.close()),this._updateHash(r.location,t,e.replace)}}return e.trigger?this.loadUrl(t):void 0}},_updateHash:function(t,e,n){if(n){var i=t.href.replace(/(javascript:|#).*$/,"");t.replace(i+"#"+e)}else t.hash="#"+e}}),e.history=new L;y.extend=b.extend=M.extend=k.extend=L.extend=function(t,e){var i,r=this;i=t&&n.has(t,"constructor")?t.constructor:function(){return r.apply(this,arguments)};return n.extend(i,r,e),i.prototype=n.create(r.prototype,t),i.prototype.constructor=i,i.__super__=r.prototype,i};var F=function(){throw new Error('A "url" property or function must be specified')},R=function(t,e){var n=e.error;e.error=function(i){n&&n.call(e.context,t,i,e),t.trigger("error",t,i,e)}};return e}(a,n,t,e)}.apply(e,r))||(t.exports=o)}()}).call(this,n(11))},function(t,e,n){(function(t,n){var i;!function(){var r="object"==typeof self&&self.self===self&&self||"object"==typeof t&&t.global===t&&t||this||{},o=r._,s=Array.prototype,a=Object.prototype,l="undefined"!=typeof Symbol?Symbol.prototype:null,c=s.push,u=s.slice,h=a.toString,d=a.hasOwnProperty,f=Array.isArray,p=Object.keys,g=Object.create,v=function(){},m=function(t){return t instanceof m?t:this instanceof m?void(this._wrapped=t):new m(t)};void 0===e||e.nodeType?r._=m:(void 0!==n&&!n.nodeType&&n.exports&&(e=n.exports=m),e._=m),m.VERSION="1.9.1";var y,b=function(t,e,n){if(void 0===e)return t;switch(null==n?3:n){case 1:return function(n){return t.call(e,n)};case 3:return function(n,i,r){return t.call(e,n,i,r)};case 4:return function(n,i,r,o){return t.call(e,n,i,r,o)}}return function(){return t.apply(e,arguments)}},x=function(t,e,n){return m.iteratee!==y?m.iteratee(t,e):null==t?m.identity:m.isFunction(t)?b(t,e,n):m.isObject(t)&&!m.isArray(t)?m.matcher(t):m.property(t)};m.iteratee=y=function(t,e){return x(t,e,1/0)};var w=function(t,e){return e=null==e?t.length-1:+e,function(){for(var n=Math.max(arguments.length-e,0),i=Array(n),r=0;r=0&&e<=E};m.each=m.forEach=function(t,e,n){var i,r;if(e=b(e,n),A(t))for(i=0,r=t.length;i=3;return function(e,n,i,r){var o=!A(e)&&m.keys(e),s=(o||e).length,a=t>0?0:s-1;for(r||(i=e[o?o[a]:a],a+=t);a>=0&&a=0},m.invoke=w(function(t,e,n){var i,r;return m.isFunction(e)?r=e:m.isArray(e)&&(i=e.slice(0,-1),e=e[e.length-1]),m.map(t,function(t){var o=r;if(!o){if(i&&i.length&&(t=T(t,i)),null==t)return;o=t[e]}return null==o?o:o.apply(t,n)})}),m.pluck=function(t,e){return m.map(t,m.property(e))},m.where=function(t,e){return m.filter(t,m.matcher(e))},m.findWhere=function(t,e){return m.find(t,m.matcher(e))},m.max=function(t,e,n){var i,r,o=-1/0,s=-1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,l=(t=A(t)?t:m.values(t)).length;ao&&(o=i);else e=x(e,n),m.each(t,function(t,n,i){((r=e(t,n,i))>s||r===-1/0&&o===-1/0)&&(o=t,s=r)});return o},m.min=function(t,e,n){var i,r,o=1/0,s=1/0;if(null==e||"number"==typeof e&&"object"!=typeof t[0]&&null!=t)for(var a=0,l=(t=A(t)?t:m.values(t)).length;ai||void 0===n)return 1;if(n0?0:r-1;o>=0&&o0?s=o>=0?o:Math.max(o+a,s):a=o>=0?Math.min(o+1,a):o+a+1;else if(n&&o&&a)return i[o=n(i,r)]===r?o:-1;if(r!=r)return(o=e(u.call(i,s,a),m.isNaN))>=0?o+s:-1;for(o=t>0?s:a-1;o>=0&&oe?(i&&(clearTimeout(i),i=null),a=c,s=t.apply(r,o),i||(r=o=null)):i||!1===n.trailing||(i=setTimeout(l,u)),s};return c.cancel=function(){clearTimeout(i),a=0,i=r=o=null},c},m.debounce=function(t,e,n){var i,r,o=function(e,n){i=null,n&&(r=t.apply(e,n))},s=w(function(s){if(i&&clearTimeout(i),n){var a=!i;i=setTimeout(o,e),a&&(r=t.apply(this,s))}else i=m.delay(o,e,this,s);return r});return s.cancel=function(){clearTimeout(i),i=null},s},m.wrap=function(t,e){return m.partial(e,t)},m.negate=function(t){return function(){return!t.apply(this,arguments)}},m.compose=function(){var t=arguments,e=t.length-1;return function(){for(var n=e,i=t[e].apply(this,arguments);n--;)i=t[n].call(this,i);return i}},m.after=function(t,e){return function(){if(--t<1)return e.apply(this,arguments)}},m.before=function(t,e){var n;return function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=null),n}},m.once=m.partial(m.before,2),m.restArguments=w;var F=!{toString:null}.propertyIsEnumerable("toString"),R=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],j=function(t,e){var n=R.length,i=t.constructor,r=m.isFunction(i)&&i.prototype||a,o="constructor";for(S(t,o)&&!m.contains(e,o)&&e.push(o);n--;)(o=R[n])in t&&t[o]!==r[o]&&!m.contains(e,o)&&e.push(o)};m.keys=function(t){if(!m.isObject(t))return[];if(p)return p(t);var e=[];for(var n in t)S(t,n)&&e.push(n);return F&&j(t,e),e},m.allKeys=function(t){if(!m.isObject(t))return[];var e=[];for(var n in t)e.push(n);return F&&j(t,e),e},m.values=function(t){for(var e=m.keys(t),n=e.length,i=Array(n),r=0;r1&&(i=b(i,e[1])),e=m.allKeys(t)):(i=$,e=L(e,!1,!1),t=Object(t));for(var r=0,o=e.length;r1&&(n=e[1])):(e=m.map(L(e,!1,!1),String),i=function(t,n){return!m.contains(e,n)}),m.pick(t,i,n)}),m.defaults=z(m.allKeys,!0),m.create=function(t,e){var n=C(t);return e&&m.extendOwn(n,e),n},m.clone=function(t){return m.isObject(t)?m.isArray(t)?t.slice():m.extend({},t):t},m.tap=function(t,e){return e(t),t},m.isMatch=function(t,e){var n=m.keys(e),i=n.length;if(null==t)return!i;for(var r=Object(t),o=0;o":">",'"':""","'":"'","`":"`"},U=m.invert(W),q=function(t){var e=function(e){return t[e]},n="(?:"+m.keys(t).join("|")+")",i=RegExp(n),r=RegExp(n,"g");return function(t){return t=null==t?"":""+t,i.test(t)?t.replace(r,e):t}};m.escape=q(W),m.unescape=q(U),m.result=function(t,e,n){m.isArray(e)||(e=[e]);var i=e.length;if(!i)return m.isFunction(n)?n.call(t):n;for(var r=0;r/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var Y=/(.)^/,G={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},X=/\\|'|\r|\n|\u2028|\u2029/g,J=function(t){return"\\"+G[t]};m.template=function(t,e,n){!e&&n&&(e=n),e=m.defaults({},e,m.templateSettings);var i,r=RegExp([(e.escape||Y).source,(e.interpolate||Y).source,(e.evaluate||Y).source].join("|")+"|$","g"),o=0,s="__p+='";t.replace(r,function(e,n,i,r,a){return s+=t.slice(o,a).replace(X,J),o=a+e.length,n?s+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":i?s+="'+\n((__t=("+i+"))==null?'':__t)+\n'":r&&(s+="';\n"+r+"\n__p+='"),e}),s+="';\n",e.variable||(s="with(obj||{}){\n"+s+"}\n"),s="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+s+"return __p;\n";try{i=new Function(e.variable||"obj","_",s)}catch(t){throw t.source=s,t}var a=function(t){return i.call(this,t,m)},l=e.variable||"obj";return a.source="function("+l+"){\n"+s+"}",a},m.chain=function(t){var e=m(t);return e._chain=!0,e};var Z=function(t,e){return t._chain?m(e).chain():e};m.mixin=function(t){return m.each(m.functions(t),function(e){var n=m[e]=t[e];m.prototype[e]=function(){var t=[this._wrapped];return c.apply(t,arguments),Z(this,n.apply(m,t))}}),m},m.mixin(m),m.each(["pop","push","reverse","shift","sort","splice","unshift"],function(t){var e=s[t];m.prototype[t]=function(){var n=this._wrapped;return e.apply(n,arguments),"shift"!==t&&"splice"!==t||0!==n.length||delete n[0],Z(this,n)}}),m.each(["concat","join","slice"],function(t){var e=s[t];m.prototype[t]=function(){return Z(this,e.apply(this._wrapped,arguments))}}),m.prototype.value=function(){return this._wrapped},m.prototype.valueOf=m.prototype.toJSON=m.prototype.value,m.prototype.toString=function(){return String(this._wrapped)},void 0===(i=function(){return m}.apply(e,[]))||(n.exports=i)}()}).call(this,n(11),n(231)(t))},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.getUnitFromValue=e.normalizeFloat=e.shallowDiff=e.getElement=e.camelCase=e.getModel=e.matches=e.upFirst=e.hasDnd=e.off=e.on=void 0;var i=n(1),r=window.Element.prototype,o=r.matches||r.webkitMatchesSelector||r.mozMatchesSelector||r.msMatchesSelector,s=function(t){return t[0].toUpperCase()+t.toLowerCase().slice(1)};e.on=function(t,e,n){e=e.split(/\s+/),t=t instanceof Array?t:[t];for(var i=function(i){t.forEach(function(t){return t.addEventListener(e[i],n)})},r=0;r=0?s!==a&&(n[o]=a):n[o]=null}for(var l in e)e.hasOwnProperty(l)&&(0,i.isUndefined)(t[l])&&(n[l]=e[l]);return n},e.normalizeFloat=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=0;if(isNaN(t))return n;if(t=parseFloat(t),Math.floor(t)!==t){var r=e.toString().split(".")[1];i=r?r.length:0}return i?parseFloat(t.toFixed(i)):t},e.getUnitFromValue=function(t){return t.replace(parseFloat(t),"")}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)),r=n(1);var o=n(57);t.exports=i.default.View.extend({className:function(){return this.getClasses()},tagName:function(){return this.model.get("tagName")},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.model,n=t.config||{};this.opts=t,this.config=n,this.em=n.em||"",this.pfx=n.stylePrefix||"",this.ppfx=n.pStylePrefix||"",this.attr=e.get("attributes"),this.classe=this.attr.class||[];var i=this.$el,r=e.get("classes");this.listenTo(e,"change:style",this.updateStyle),this.listenTo(e,"change:attributes",this.updateAttributes),this.listenTo(e,"change:highlightable",this.updateHighlight),this.listenTo(e,"change:status",this.updateStatus),this.listenTo(e,"change:state",this.updateState),this.listenTo(e,"change:script",this.render),this.listenTo(e,"change:content",this.updateContent),this.listenTo(e,"change",this.handleChange),this.listenTo(e,"active",this.onActive),this.listenTo(r,"add remove change",this.updateClasses),i.data("model",e),i.data("collection",e.get("components")),e.view=this,r.length&&this.importClasses(),this.init()},init:function(){},onActive:function(){},handleChange:function(){var t=this.model;for(var e in t.emitUpdate(),t.changed)t.emitUpdate(e)},importClasses:function(){var t=this.config.em.get("SelectorManager");t&&this.model.get("classes").each(function(e){t.add(e.get("name"))})},updateState:function(t){var e="hc-state";this.model.get("state")?this.$el.addClass(e):this.$el.removeClass(e)},updateStatus:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=(this.em,this.el),n=this.model.get("status"),i=this.pfx,r=this.ppfx,o=i+"selected",s=o+"-parent",a=r+"freezed",l=r+"hovered",c=[o,s,a,l];this.$el.removeClass(c.join(" "));var u=e.getAttribute("class")||"",h="";switch(n){case"selected":h=u+" "+o;break;case"selected-parent":h=u+" "+s;break;case"freezed":h=u+" "+a;break;case"freezed-selected":h=u+" "+a+" "+o;break;case"hovered":h=t.avoidHover?"":u+" "+l}(h=h.trim())&&e.setAttribute("class",h)},updateHighlight:function(){var t=this.model.get("highlightable");this.setAttribute("data-highlightable",t?1:"")},updateStyle:function(){var t=this.em,e=this.model;if(t&&t.get("avoidInlineStyle")){this.el.id=e.getId();var n=e.getStyle();!(0,r.isEmpty)(n)&&e.setStyle(n)}else this.setAttribute("style",e.styleToString())},updateClasses:function(){var t=this.model.get("classes").pluck("name").join(" ");this.setAttribute("class",t),this.updateStatus()},setAttribute:function(t,e){var n=this.$el;e?n.attr(t,e):n.removeAttr(t)},getClasses:function(){var t=this.model.get("attributes").class||[];return(t=(0,r.isArray)(t)?t:[t]).length?t.join(" "):null},updateAttributes:function(){var t=this.model,e={"data-gjs-type":t.get("type")||"default"},n=t.get("attributes"),i=t.get("src");for(var r in n)e[r]=n[r];i&&(e.src=i),this.$el.attr(e),this.updateHighlight(),this.updateStyle()},updateContent:function(){this.getChildrenContainer().innerHTML=this.model.get("content")},prevDef:function(t){t.preventDefault()},updateScript:function(){if(this.model.get("script")){var t=this.em;if(t)t.get("Canvas").getCanvasView().updateScript(this)}},getChildrenContainer:function(){var t=this.el;return"function"==typeof this.getChildrenSelector?t=this.el.querySelector(this.getChildrenSelector()):this.getTemplate,t},renderChildren:function(){var t=this.getChildrenContainer(),e=new o({collection:this.model.get("components"),config:this.config,componentTypes:this.opts.componentTypes});e.render(t),this.childrenView=e;for(var n=Array.prototype.slice.call(e.el.childNodes),i=0,r=n.length;i0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},o=n.em,s=this.parent(),a=s&&s.attributes;if(a&&a.propagate){var l={},c=a.propagate;c.forEach(function(t){return l[t]=s.get(t)}),l.propagate=c,l=i({},l,e),this.set(l)}var u=this.get("propagate");u&&this.set("propagate",(0,r.isArray)(u)?u:[u]),n&&n.config&&n.config.voidElements.indexOf(this.get("tagName"))>=0&&this.set("void",!0),n.em=o,this.opt=n,this.em=o,this.config=n.config||{},this.ccid=g.createId(this),this.set("attributes",this.get("attributes")||{}),this.listenTo(this,"change:script",this.scriptUpdated),this.listenTo(this,"change:traits",this.traitsUpdated),this.listenTo(this,"change:tagName",this.tagUpdated),this.listenTo(this,"change:attributes",this.attrUpdated),this.initClasses(),this.loadTraits(),this.initComponents(),this.initToolbar(),this.set("status",""),["classes","traits"].forEach(function(e){return t.listenTo(t.get(e),"add remove change",function(){return t.emitUpdate(e)})}),this.init()},is:function(t){return!(this.get("type")!=t)},find:function(t){var e=[];return this.view.$el.find(t).each(function(t,n,i){var r=i.eq(n).data("model");r&&e.push(r)}),e},closest:function(t){var e=this.view.$el.closest(t);return e.length&&e.data("model")},tagUpdated:function(){var t=this.collection,e=t.indexOf(this);t.remove(this),t.add(this,{at:e})},replaceWith:function(t){var e=this.collection,n=e.indexOf(this);return e.remove(this),e.add(t,{at:n})},attrUpdated:function(){var t=this,e=i({},this.previous("attributes")),n=i({},this.get("attributes")),s=(0,o.shallowDiff)(e,n);(0,r.keys)(s).forEach(function(e){return t.trigger("change:attributes:"+e)})},setAttributes:function(t){var e=(t=i({},t)).class;e&&this.setClass(e),delete t.class;var n=t.style;n&&this.setStyle(n),delete t.style,this.set("attributes",t)},addAttributes:function(t){var e=i({},this.getAttributes(),t);this.setAttributes(e)},getStyle:function(){var t=this.em;if(t&&t.getConfig("avoidInlineStyle")){var e=this.get("state"),n=t.get("CssComposer").getIdRule(this.getId(),{state:e});if(this.rule=n,n)return n.getStyle()}return s.default.getStyle.call(this)},setStyle:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},a=this.em;if(a&&a.getConfig("avoidInlineStyle")){e=(0,r.isString)(e)?this.parseStyle(e):e,e=i({},e,this.get("style"));var l=this.get("state"),c=a.get("CssComposer"),u=this.getStyle();this.rule=c.setIdRule(this.getId(),e,i({},n,{state:l}));var h=(0,o.shallowDiff)(u,e);this.set("style",{},{silent:1}),(0,r.keys)(h).forEach(function(e){return t.trigger("change:style:"+e)})}else e=s.default.setStyle.apply(this,arguments);return e},getAttributes:function(){var t=this.em,e=[],n=i({},this.get("attributes")),o=t&&t.get("SelectorManager"),s=this.getId();if(this.get("classes").each(function(t){return e.push(t.get("name"))}),e.length&&(n.class=e.join(" ")),!(0,r.has)(n,"id")){var a=void 0;!function(t){return t&&t.getConfig("avoidInlineStyle")}(t)?(0,r.isEmpty)(this.getStyle())||(a=1):a=o&&o.get(s,o.Selector.TYPE_ID),a&&(n.id=this.getId())}return n},addClass:function(t){var e=this.em.get("SelectorManager").addClass(t);return this.get("classes").add(e)},setClass:function(t){return this.get("classes").reset(),this.addClass(t)},removeClass:function(t){var e=[];t=(0,r.isArray)(t)?t:[t];var n=this.get("classes"),i=c.TYPE_CLASS;return t.forEach(function(t){t.split(" ").forEach(function(t){var r=n.where({name:t,type:i})[0];r&&e.push(n.remove(r))})}),e},initClasses:function(){var t=this.normalizeClasses(this.get("classes")||[]);return this.set("classes",new u(t)),this},initComponents:function(){var t=new l(null,this.opt);return t.parent=this,!this.opt.avoidChildren&&t.reset(this.get("components")),this.set("components",t),this},init:function(){},append:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.components().add(t,e);return(0,r.isArray)(n)?n:[n]},components:function(t){var e=this.get("components");if((0,r.isUndefined)(t))return e;e.reset(),t&&this.append(t)},parent:function(){var t=this.collection;return t&&t.parent},scriptUpdated:function(){this.set("scriptUpdated",1)},traitsUpdated:function(){var t=0,e=i({},this.get("attributes")),n=this.get("traits");n instanceof h?(n.each(function(n){if(t=1,!n.get("changeProp")){var i=n.get("name"),r=n.getInitValue();i&&r&&(e[i]=r)}}),t&&this.set("attributes",e)):this.loadTraits()},initToolbar:function(){if(!this.get("toolbar")){var t=[];this.collection&&t.push({attributes:{class:"fa fa-arrow-up"},command:"select-parent"}),this.get("draggable")&&t.push({attributes:{class:"fa fa-arrows",draggable:!0},command:"tlb-move"}),this.get("copyable")&&t.push({attributes:{class:"fa fa-clone"},command:"tlb-clone"}),this.get("removable")&&t.push({attributes:{class:"fa fa-trash-o"},command:"tlb-delete"}),this.set("toolbar",t)}},loadTraits:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=new h([],this.opt);return n.setTarget(this),(t=t||this.get("traits")).length&&n.add(t),this.set("traits",n,e),this},normalizeClasses:function(t){var e=[],n=this.em;if(n){var i=n.get("SelectorManager");if(i)return t.forEach(function(t){var n="";n="string"==typeof t?t:t.name;var r=i.add(n);e.push(r)}),e}},clone:function(){var t=this.em,e=this.getStyle(),n=i({},this.attributes),o=i({},this.opt);return n.attributes=i({},n.attributes),delete n.attributes.id,n.components=[],n.classes=[],n.traits=[],this.get("components").each(function(t,e){n.components[e]=t.clone()}),this.get("traits").each(function(t,e){n.traits[e]=t.clone()}),this.get("classes").each(function(t,e){n.classes[e]=t.get("name")}),n.status="",n.view="",o.collection=null,t&&t.getConfig("avoidInlineStyle")&&!(0,r.isEmpty)(e)&&(n.style=e),new this.constructor(n,o)},getName:function(){var t=this.get("name")||this.get("custom-name"),e=this.get("tagName");e="div"==e?"box":e;var n=this.get("type")||e;return n=n.charAt(0).toUpperCase()+n.slice(1),t||n},getIcon:function(){var t=this.get("icon");return t?t+" ":""},toHTML:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=[],n=this.get("tagName"),i=this.get("void"),o=t.attributes,s=this.getAttrToHTML();for(var a in o&&((0,r.isFunction)(o)?s=o(this,s)||{}:(0,r.isObject)(o)&&(s=o)),s){var l=s[a],c=(0,r.isString)(l)?l.replace(/"/g,"""):l;(0,r.isUndefined)(c)||((0,r.isBoolean)(c)?c&&e.push(a):e.push(a+'="'+c+'"'))}var u="<"+n+(e.length?" "+e.join(" "):"")+(i?"/":"")+">"+this.get("content");return this.get("components").each(function(e){return u+=e.toHTML(t)}),!i&&(u+=""),u},getAttrToHTML:function(){var t=this.getAttributes();return delete t.style,t},toJSON:function(){for(var t=arguments.length,e=Array(t),n=0;n0&&void 0!==arguments[0]&&arguments[0];var t=this.em,e=this.getId();if(e){var n=g.createId(this);this.setId(n);var i=t&&t.get("CssComposer").getIdRule(e),r=i&&i.get("selectors").at(0);return r&&r.set("name",n),this}}},{isComponent:function(t){return{tagName:t.tagName?t.tagName.toLowerCase():""}},createId:function(t){var e=(++f).toString().length+2,n="i"+(Math.random()+1.1).toString(36).slice(-e);return d[n]=t,n},getList:function(){return d}});t.exports=g},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)),r=n(1),o=n(2);t.exports=i.default.View.extend({template:function(t){return'\n
\n '+this.templateLabel(t)+'\n
\n
\n '+this.templateInput(t)+"\n
\n "},templateLabel:function(t){var e=this.pfx;return'\n \n '+t.get("name")+'\n \n \n '},templateInput:function(t){return'\n
\n \n
\n '},events:function(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}({change:"inputValueChanged"},"click [data-clear-style]","clear"),initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};(0,r.bindAll)(this,"targetUpdated"),this.config=t.config||{};var e=this.config.em;this.em=e,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.target=t.target||{},this.propTarget=t.propTarget||{},this.onChange=t.onChange,this.onInputRender=t.onInputRender||{},this.customValue=t.customValue||{};var n=this.model;this.property=n.get("property"),this.input=null;var i=this.pfx;this.inputHolderId="#"+i+"input-holder",this.sector=n.collection&&n.collection.sector,n.view=this,n.get("value")||n.set("value",n.getDefaultValue()),e&&e.on("update:component:style:"+this.property,this.targetUpdated),this.listenTo(this.propTarget,"update",this.targetUpdated),this.listenTo(n,"destroy remove",this.remove),this.listenTo(n,"change:value",this.modelValueChanged),this.listenTo(n,"targetUpdated",this.targetUpdated),this.listenTo(n,"change:visible",this.updateVisibility),this.listenTo(n,"change:status",this.updateStatus);var o=this.init&&this.init.bind(this);o&&o()},updateStatus:function(){var t=this.model.get("status"),e=this.pfx,n=this.ppfx,i=this.config,r=n+"four-color",o=n+"color-warn",s=this.$el.children("."+e+"label"),a=this.getClearEl().style;switch(s.removeClass(r+" "+o),a.display="none",t){case"updated":s.addClass(r),i.clearProperties&&(a.display="inline");break;case"computed":s.addClass(o)}},clear:function(t){t&&t.stopPropagation(),this.model.clearValue(),this.targetUpdated()},getClearEl:function(){return this.clearEl||(this.clearEl=this.el.querySelector("[data-clear-style]")),this.clearEl},getTarget:function(){return this.getTargetModel()},getTargetModel:function(){return this.propTarget&&this.propTarget.model},getHelperModel:function(){return this.propTarget&&this.propTarget.helper},inputValueChanged:function(t){t&&t.stopPropagation(),this.model.setValue(this.getInputValue(),1,{fromInput:1}),this.elementUpdated()},elementUpdated:function(){this.setStatus("updated")},setStatus:function(t){this.model.set("status",t);var e=this.model.parent;e&&e.set("status",t)},targetUpdated:function(){if(this.checkVisibility()){var t=this.config,e=t.em,n=this.model,i="",r="",o=this.getTargetValue({ignoreDefault:1}),s=n.getDefaultValue(),a=this.getComputedValue();o?(i=o,t.highlightChanged&&(r="updated")):a&&t.showComputed&&a!=s?(i=a,t.highlightComputed&&(r="computed")):(i=s,r=""),n.setValue(i,0,{fromTarget:1}),this.setStatus(r),e&&(e.trigger("styleManager:change",this),e.trigger("styleManager:change:"+n.get("property"),this))}},checkVisibility:function(){var t=1;return this.config.hideNotStylable&&(this.isTargetStylable()&&this.isComponentStylable()?this.show():(this.hide(),t=0),this.sector&&this.sector.trigger("updateVisibility")),t},getTargetValue:function(){var t,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},n=this.model,i=this.getTargetModel(),r=this.customValue;if(!i)return t;if((t=i.getStyle()[n.get("property")])||e.ignoreDefault||(t=n.getDefaultValue()),"function"==typeof r&&!e.ignoreCustomValue){var o=r(this,n.collection.indexOf(n));o&&(t=o)}return t},getComputedValue:function(){var t=this.propTarget,e=t.computed||{},n=t.computedDefault||{},i=this.config.avoidComputed||[],r=this.model.get("property"),s=i.indexOf(r)<0,a=e[r],l=n[(0,o.camelCase)(r)];return e&&s&&l!==a&&a},getInputValue:function(){var t=this.getInputEl();return t?t.value:""},modelValueChanged:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=this.config.em,r=this.model,o=r.getFullValue(),s=this.getTarget(),a=this.onChange;n.fromInput||this.setValue(o),s&&this.isTargetStylable()&&this.isComponentStylable()&&(n.fromTarget||(a&&!n.fromParent?a(s,this,n):this.updateTargetStyle(o,null,n)),i&&(i.trigger("component:update",s),i.trigger("component:styleUpdate",s),i.trigger("component:styleUpdate:"+r.get("property"),s)))},updateTargetStyle:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=e||this.model.get("property"),r=this.getTarget(),o=r.getStyle();t?o[i]=t:delete o[i],r.setStyle(o,n);var s=this.getHelperModel();s&&s.setStyle(o,n)},isTargetStylable:function(t){var e=t||this.getTarget(),n=this.model,i=n.get("property"),o=n.get("toRequire"),s=e.get("unstylable"),a=e.get("stylable-require"),l=e.get("stylable");return(0,r.isArray)(l)&&(l=l.indexOf(i)>=0),(0,r.isArray)(s)&&(l=s.indexOf(i)<0),o&&(l=a&&a.indexOf(i)>=0||!t),l},isComponentStylable:function(){var t=this.em,e=t&&t.getSelected();return!e||this.isTargetStylable(e)},setRawValue:function(t){this.setValue(this.model.parseValue(t))},setValue:function(t){var e=this.model,n=(0,r.isUndefined)(t)?e.getDefaultValue():t,i=this.getInputEl();i&&(i.value=n)},getInputEl:function(){return this.input||(this.input=this.el.querySelector("input")),this.input},updateVisibility:function(){this.el.style.display=this.model.get("visible")?"block":"none"},show:function(){this.model.set("visible",1)},hide:function(){this.model.set("visible",0)},cleanValue:function(){this.setValue("")},render:function(){var t=this.pfx,e=this.model,n=this.el;n.innerHTML=this.template(e),n.className=t+"property "+t+e.get("type"),this.updateStatus();var i=this.onRender&&this.onRender.bind(this);i&&i(),this.setValue(e.get("value"),{targetUpdate:1})}})},function(t,e,n){t.exports=function(){"use strict";var t=navigator.userAgent,e=navigator.platform,n=/gecko\/\d/i.test(t),i=/MSIE \d/.test(t),r=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(t),o=/Edge\/(\d+)/.exec(t),s=i||r||o,a=s&&(i?document.documentMode||6:+(o||r)[1]),l=!o&&/WebKit\//.test(t),c=l&&/Qt\/\d+\.\d+/.test(t),u=!o&&/Chrome\//.test(t),h=/Opera\//.test(t),d=/Apple Computer/.test(navigator.vendor),f=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(t),p=/PhantomJS/.test(t),g=!o&&/AppleWebKit/.test(t)&&/Mobile\/\w+/.test(t),v=/Android/.test(t),m=g||v||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(t),y=g||/Mac/.test(e),b=/\bCrOS\b/.test(t),x=/win/i.test(e),w=h&&t.match(/Version\/(\d*\.\d*)/);w&&(w=Number(w[1])),w&&w>=15&&(h=!1,l=!0);var C=y&&(c||h&&(null==w||w<12.11)),k=n||s&&a>=9;function S(t){return new RegExp("(^|\\s)"+t+"(?:$|\\s)\\s*")}var T,E=function(t,e){var n=t.className,i=S(e).exec(n);if(i){var r=n.slice(i.index+i[0].length);t.className=n.slice(0,i.index)+(r?i[1]+r:"")}};function M(t){for(var e=t.childNodes.length;e>0;--e)t.removeChild(t.firstChild);return t}function A(t,e){return M(t).appendChild(e)}function O(t,e,n,i){var r=document.createElement(t);if(n&&(r.className=n),i&&(r.style.cssText=i),"string"==typeof e)r.appendChild(document.createTextNode(e));else if(e)for(var o=0;o=e)return s+(e-o);s+=a-o,s+=n-s%n,o=a+1}}g?I=function(t){t.selectionStart=0,t.selectionEnd=t.value.length}:s&&(I=function(t){try{t.select()}catch(t){}});var z=function(){this.id=null};function V(t,e){for(var n=0;n=e)return i+Math.min(s,e-r);if(r+=o-i,i=o+1,(r+=n-r%n)>=e)return i}}var K=[""];function Y(t){for(;K.length<=t;)K.push(G(K)+" ");return K[t]}function G(t){return t[t.length-1]}function X(t,e){for(var n=[],i=0;i"€"&&(t.toUpperCase()!=t.toLowerCase()||Q.test(t))}function et(t,e){return e?!!(e.source.indexOf("\\w")>-1&&tt(t))||e.test(t):tt(t)}function nt(t){for(var e in t)if(t.hasOwnProperty(e)&&t[e])return!1;return!0}var it=/[\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]/;function rt(t){return t.charCodeAt(0)>=768&&it.test(t)}function ot(t,e,n){for(;(n<0?e>0:en?-1:1;;){if(e==n)return e;var r=(e+n)/2,o=i<0?Math.ceil(r):Math.floor(r);if(o==e)return t(o)?e:n;t(o)?n=o:e=o+i}}function at(t,e){if((e-=t.first)<0||e>=t.size)throw new Error("There is no line "+(e+t.first)+" in the document.");for(var n=t;!n.lines;)for(var i=0;;++i){var r=n.children[i],o=r.chunkSize();if(e=t.first&&en?gt(n,at(t,n).text.length):function(t,e){var n=t.ch;return null==n||n>e?gt(t.line,e):n<0?gt(t.line,0):t}(e,at(t,e.line).text.length)}function kt(t,e){for(var n=[],i=0;i=e:o.to>e);(i||(i=[])).push(new Et(s,o.from,l?null:o.to))}}return i}(n,r,s),l=function(t,e,n){var i;if(t)for(var r=0;r=e:o.to>e);if(a||o.from==e&&"bookmark"==s.type&&(!n||o.marker.insertLeft)){var l=null==o.from||(s.inclusiveLeft?o.from<=e:o.from0&&a)for(var x=0;xe)&&(!n||It(n,o.marker)<0)&&(n=o.marker)}return n}function Vt(t,e,n,i,r){var o=at(t,e),s=Tt&&o.markedSpans;if(s)for(var a=0;a=0&&h<=0||u<=0&&h>=0)&&(u<=0&&(l.marker.inclusiveRight&&r.inclusiveLeft?vt(c.to,n)>=0:vt(c.to,n)>0)||u>=0&&(l.marker.inclusiveRight&&r.inclusiveLeft?vt(c.from,i)<=0:vt(c.from,i)<0)))return!0}}}function Ht(t){for(var e;e=Rt(t);)t=e.find(-1,!0).line;return t}function $t(t,e){var n=at(t,e),i=Ht(n);return n==i?e:ht(i)}function Bt(t,e){if(e>t.lastLine())return e;var n,i=at(t,e);if(!Wt(t,i))return e;for(;n=jt(i);)i=n.find(1,!0).line;return ht(i)+1}function Wt(t,e){var n=Tt&&e.markedSpans;if(n)for(var i=void 0,r=0;re.maxLineLength&&(e.maxLineLength=n,e.maxLine=t)})}var Gt=null;function Xt(t,e,n){var i;Gt=null;for(var r=0;re)return r;o.to==e&&(o.from!=o.to&&"before"==n?i=r:Gt=r),o.from==e&&(o.from!=o.to&&"before"!=n?i=r:Gt=r)}return null!=i?i:Gt}var Jt=function(){var t="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",e="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function n(n){return n<=247?t.charAt(n):1424<=n&&n<=1524?"R":1536<=n&&n<=1785?e.charAt(n-1536):1774<=n&&n<=2220?"r":8192<=n&&n<=8203?"w":8204==n?"b":"L"}var i=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,r=/[stwN]/,o=/[LRr]/,s=/[Lb1n]/,a=/[1n]/;function l(t,e,n){this.level=t,this.from=e,this.to=n}return function(t,e){var c="ltr"==e?"L":"R";if(0==t.length||"ltr"==e&&!i.test(t))return!1;for(var u=t.length,h=[],d=0;d-1&&(i[e]=r.slice(0,o).concat(r.slice(o+1)))}}}function ie(t,e){var n=ee(t,e);if(n.length)for(var i=Array.prototype.slice.call(arguments,2),r=0;r0}function ae(t){t.prototype.on=function(t,e){te(this,t,e)},t.prototype.off=function(t,e){ne(this,t,e)}}function le(t){t.preventDefault?t.preventDefault():t.returnValue=!1}function ce(t){t.stopPropagation?t.stopPropagation():t.cancelBubble=!0}function ue(t){return null!=t.defaultPrevented?t.defaultPrevented:0==t.returnValue}function he(t){le(t),ce(t)}function de(t){return t.target||t.srcElement}function fe(t){var e=t.which;return null==e&&(1&t.button?e=1:2&t.button?e=3:4&t.button&&(e=2)),y&&t.ctrlKey&&1==e&&(e=3),e}var pe,ge,ve=function(){if(s&&a<9)return!1;var t=O("div");return"draggable"in t||"dragDrop"in t}();function me(t){if(null==pe){var e=O("span","​");A(t,O("span",[e,document.createTextNode("x")])),0!=t.firstChild.offsetHeight&&(pe=e.offsetWidth<=1&&e.offsetHeight>2&&!(s&&a<8))}var n=pe?O("span","​"):O("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function ye(t){if(null!=ge)return ge;var e=A(t,document.createTextNode("AخA")),n=T(e,0,1).getBoundingClientRect(),i=T(e,1,2).getBoundingClientRect();return M(t),!(!n||n.left==n.right)&&(ge=i.right-n.right<3)}var be=3!="\n\nb".split(/\n/).length?function(t){for(var e=0,n=[],i=t.length;e<=i;){var r=t.indexOf("\n",e);-1==r&&(r=t.length);var o=t.slice(e,"\r"==t.charAt(r-1)?r-1:r),s=o.indexOf("\r");-1!=s?(n.push(o.slice(0,s)),e+=s+1):(n.push(o),e=r+1)}return n}:function(t){return t.split(/\r\n?|\n/)},xe=window.getSelection?function(t){try{return t.selectionStart!=t.selectionEnd}catch(t){return!1}}:function(t){var e;try{e=t.ownerDocument.selection.createRange()}catch(t){}return!(!e||e.parentElement()!=t)&&0!=e.compareEndPoints("StartToEnd",e)},we=function(){var t=O("div");return"oncopy"in t||(t.setAttribute("oncopy","return;"),"function"==typeof t.oncopy)}(),Ce=null,ke={},Se={};function Te(t){if("string"==typeof t&&Se.hasOwnProperty(t))t=Se[t];else if(t&&"string"==typeof t.name&&Se.hasOwnProperty(t.name)){var e=Se[t.name];"string"==typeof e&&(e={name:e}),(t=Z(e,t)).name=e.name}else{if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+xml$/.test(t))return Te("application/xml");if("string"==typeof t&&/^[\w\-]+\/[\w\-]+\+json$/.test(t))return Te("application/json")}return"string"==typeof t?{name:t}:t||{name:"null"}}function Ee(t,e){e=Te(e);var n=ke[e.name];if(!n)return Ee(t,"text/plain");var i=n(t,e);if(Me.hasOwnProperty(e.name)){var r=Me[e.name];for(var o in r)r.hasOwnProperty(o)&&(i.hasOwnProperty(o)&&(i["_"+o]=i[o]),i[o]=r[o])}if(i.name=e.name,e.helperType&&(i.helperType=e.helperType),e.modeProps)for(var s in e.modeProps)i[s]=e.modeProps[s];return i}var Me={};function Ae(t,e){var n=Me.hasOwnProperty(t)?Me[t]:Me[t]={};R(e,n)}function Oe(t,e){if(!0===e)return e;if(t.copyState)return t.copyState(e);var n={};for(var i in e){var r=e[i];r instanceof Array&&(r=r.concat([])),n[i]=r}return n}function Pe(t,e){for(var n;t.innerMode&&(n=t.innerMode(e))&&n.mode!=t;)e=n.state,t=n.mode;return n||{mode:t,state:e}}function _e(t,e,n){return!t.startState||t.startState(e,n)}var Le=function(t,e,n){this.pos=this.start=0,this.string=t,this.tabSize=e||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};Le.prototype.eol=function(){return this.pos>=this.string.length},Le.prototype.sol=function(){return this.pos==this.lineStart},Le.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Le.prototype.next=function(){if(this.pose},Le.prototype.eatSpace=function(){for(var t=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>t},Le.prototype.skipToEnd=function(){this.pos=this.string.length},Le.prototype.skipTo=function(t){var e=this.string.indexOf(t,this.pos);if(e>-1)return this.pos=e,!0},Le.prototype.backUp=function(t){this.pos-=t},Le.prototype.column=function(){return this.lastColumnPos0?null:(i&&!1!==e&&(this.pos+=i[0].length),i)}var r=function(t){return n?t.toLowerCase():t},o=this.string.substr(this.pos,t.length);if(r(o)==r(t))return!1!==e&&(this.pos+=t.length),!0},Le.prototype.current=function(){return this.string.slice(this.start,this.pos)},Le.prototype.hideFirstChars=function(t,e){this.lineStart+=t;try{return e()}finally{this.lineStart-=t}},Le.prototype.lookAhead=function(t){var e=this.lineOracle;return e&&e.lookAhead(t)},Le.prototype.baseToken=function(){var t=this.lineOracle;return t&&t.baseToken(this.pos)};var Ne=function(t,e){this.state=t,this.lookAhead=e},De=function(t,e,n,i){this.state=e,this.doc=t,this.line=n,this.maxLookAhead=i||0,this.baseTokens=null,this.baseTokenPos=1};function Ie(t,e,n,i){var r=[t.state.modeGen],o={};We(t,e.text,t.doc.mode,n,function(t,e){return r.push(t,e)},o,i);for(var s=n.state,a=function(i){n.baseTokens=r;var a=t.state.overlays[i],l=1,c=0;n.state=!0,We(t,e.text,a.mode,n,function(t,e){for(var n=l;ct&&r.splice(l,1,t,r[l+1],i),l+=2,c=Math.min(t,i)}if(e)if(a.opaque)r.splice(n,l-n,t,"overlay "+e),l=n+2;else for(;nt.options.maxHighlightLength&&Oe(t.doc.mode,i.state),o=Ie(t,e,i);r&&(i.state=r),e.stateAfter=i.save(!r),e.styles=o.styles,o.classes?e.styleClasses=o.classes:e.styleClasses&&(e.styleClasses=null),n===t.doc.highlightFrontier&&(t.doc.modeFrontier=Math.max(t.doc.modeFrontier,++t.doc.highlightFrontier))}return e.styles}function Re(t,e,n){var i=t.doc,r=t.display;if(!i.mode.startState)return new De(i,!0,e);var o=function(t,e,n){for(var i,r,o=t.doc,s=n?-1:e-(t.doc.mode.innerMode?1e3:100),a=e;a>s;--a){if(a<=o.first)return o.first;var l=at(o,a-1),c=l.stateAfter;if(c&&(!n||a+(c instanceof Ne?c.lookAhead:0)<=o.modeFrontier))return a;var u=j(l.text,null,t.options.tabSize);(null==r||i>u)&&(r=a-1,i=u)}return r}(t,e,n),s=o>i.first&&at(i,o-1).stateAfter,a=s?De.fromSaved(i,s,o):new De(i,_e(i.mode),o);return i.iter(o,e,function(n){je(t,n.text,a);var i=a.line;n.stateAfter=i==e-1||i%5==0||i>=r.viewFrom&&ie.start)return o}throw new Error("Mode "+t.name+" failed to advance stream.")}De.prototype.lookAhead=function(t){var e=this.doc.getLine(this.line+t);return null!=e&&t>this.maxLookAhead&&(this.maxLookAhead=t),e},De.prototype.baseToken=function(t){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=t;)this.baseTokenPos+=2;var e=this.baseTokens[this.baseTokenPos+1];return{type:e&&e.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-t}},De.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},De.fromSaved=function(t,e,n){return e instanceof Ne?new De(t,Oe(t.mode,e.state),n,e.lookAhead):new De(t,Oe(t.mode,e),n)},De.prototype.save=function(t){var e=!1!==t?Oe(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new Ne(e,this.maxLookAhead):e};var He=function(t,e,n){this.start=t.start,this.end=t.pos,this.string=t.current(),this.type=e||null,this.state=n};function $e(t,e,n,i){var r,o=t.doc,s=o.mode;e=Ct(o,e);var a,l=at(o,e.line),c=Re(t,e.line,n),u=new Le(l.text,t.options.tabSize,c);for(i&&(a=[]);(i||u.post.options.maxHighlightLength?(a=!1,s&&je(t,e,i,h.pos),h.pos=e.length,l=null):l=Be(Ve(n,h,i.state,d),o),d){var f=d[0].name;f&&(l="m-"+(l?f+" "+l:f))}if(!a||u!=l){for(;c1&&!/ /.test(t))return t;for(var n=e,i="",r=0;rc&&h.from<=c);d++);if(h.to>=u)return t(n,i,r,o,s,a,l);t(n,i.slice(0,h.to-c),r,o,null,a,l),o=null,i=i.slice(h.to-c),c=h.to}}}function tn(t,e,n,i){var r=!i&&n.widgetNode;r&&t.map.push(t.pos,t.pos+e,r),!i&&t.cm.display.input.needsContentAttribute&&(r||(r=t.content.appendChild(document.createElement("span"))),r.setAttribute("cm-marker",n.id)),r&&(t.cm.display.input.setUneditable(r),t.content.appendChild(r)),t.pos+=e,t.trailingSpace=!1}function en(t,e,n){var i=t.markedSpans,r=t.text,o=0;if(i)for(var s,a,l,c,u,h,d,f=r.length,p=0,g=1,v="",m=0;;){if(m==p){l=c=u=h=a="",d=null,m=1/0;for(var y=[],b=void 0,x=0;xp||C.collapsed&&w.to==p&&w.from==p)?(null!=w.to&&w.to!=p&&m>w.to&&(m=w.to,c=""),C.className&&(l+=" "+C.className),C.css&&(a=(a?a+";":"")+C.css),C.startStyle&&w.from==p&&(u+=" "+C.startStyle),C.endStyle&&w.to==m&&(b||(b=[])).push(C.endStyle,w.to),C.title&&!h&&(h=C.title),C.collapsed&&(!d||It(d.marker,C)<0)&&(d=w)):w.from>p&&m>w.from&&(m=w.from)}if(b)for(var k=0;k=f)break;for(var T=Math.min(f,m);;){if(v){var E=p+v.length;if(!d){var M=E>T?v.slice(0,T-p):v;e.addToken(e,M,s?s+l:l,u,p+M.length==m?c:"",h,a)}if(E>=T){v=v.slice(T-p),p=T;break}p=E,u=""}v=r.slice(o,o=n[g++]),s=Ge(n[g++],e.cm.options)}}else for(var A=1;An)return{map:t.measure.maps[r],cache:t.measure.caches[r],before:!0}}function On(t,e,n,i){return Ln(t,_n(t,e),n,i)}function Pn(t,e){if(e>=t.display.viewFrom&&e=n.lineN&&e2&&o.push((l.bottom+c.top)/2-n.top)}}o.push(n.bottom-n.top)}}(t,e.view,e.rect),e.hasHeights=!0),(o=function(t,e,n,i){var r,o=In(e.map,n,i),l=o.node,c=o.start,u=o.end,h=o.collapse;if(3==l.nodeType){for(var d=0;d<4;d++){for(;c&&rt(e.line.text.charAt(o.coverStart+c));)--c;for(;o.coverStart+u1}(t))return e;var n=screen.logicalXDPI/screen.deviceXDPI,i=screen.logicalYDPI/screen.deviceYDPI;return{left:e.left*n,right:e.right*n,top:e.top*i,bottom:e.bottom*i}}(t.display.measure,r))}else{var f;c>0&&(h=i="right"),r=t.options.lineWrapping&&(f=l.getClientRects()).length>1?f["right"==i?f.length-1:0]:l.getBoundingClientRect()}if(s&&a<9&&!c&&(!r||!r.left&&!r.right)){var p=l.parentNode.getClientRects()[0];r=p?{left:p.left,right:p.left+ei(t.display),top:p.top,bottom:p.bottom}:Dn}for(var g=r.top-e.rect.top,v=r.bottom-e.rect.top,m=(g+v)/2,y=e.view.measure.heights,b=0;be)&&(r=(o=l-a)-1,e>=l&&(s="right")),null!=r){if(i=t[c+2],a==l&&n==(i.insertLeft?"left":"right")&&(s=n),"left"==n&&0==r)for(;c&&t[c-2]==t[c-3]&&t[c-1].insertLeft;)i=t[2+(c-=3)],s="left";if("right"==n&&r==l-a)for(;c=0&&(n=t[r]).left==n.right;r--);return n}function Rn(t){if(t.measure&&(t.measure.cache={},t.measure.heights=null,t.rest))for(var e=0;e=i.text.length?(l=i.text.length,c="before"):l<=0&&(l=0,c="after"),!a)return s("before"==c?l-1:l,"before"==c);function u(t,e,n){var i=a[e],r=1==i.level;return s(n?t-1:t,r!=n)}var h=Xt(a,l,c),d=Gt,f=u(l,h,"before"==c);return null!=d&&(f.other=u(l,d,"before"!=c)),f}function Kn(t,e){var n=0;e=Ct(t.doc,e),t.options.lineWrapping||(n=ei(t.display)*e.ch);var i=at(t.doc,e.line),r=qt(i)+Cn(t.display);return{left:n,right:n,top:r,bottom:r+i.height}}function Yn(t,e,n,i,r){var o=gt(t,e,n);return o.xRel=r,i&&(o.outside=!0),o}function Gn(t,e,n){var i=t.doc;if((n+=t.display.viewOffset)<0)return Yn(i.first,0,null,!0,-1);var r=dt(i,n),o=i.first+i.size-1;if(r>o)return Yn(i.first+i.size-1,at(i,o).text.length,null,!0,1);e<0&&(e=0);for(var s=at(i,r);;){var a=Qn(t,s,r,e,n),l=zt(s,a.ch+(a.xRel>0?1:0));if(!l)return a;var c=l.find(1);if(c.line==r)return c;s=at(i,r=c.line)}}function Xn(t,e,n,i){i-=$n(e);var r=e.text.length,o=st(function(e){return Ln(t,n,e-1).bottom<=i},r,0);return r=st(function(e){return Ln(t,n,e).top>i},o,r),{begin:o,end:r}}function Jn(t,e,n,i){n||(n=_n(t,e));var r=Bn(t,e,Ln(t,n,i),"line").top;return Xn(t,e,n,r)}function Zn(t,e,n,i){return!(t.bottom<=n)&&(t.top>n||(i?t.left:t.right)>e)}function Qn(t,e,n,i,r){r-=qt(e);var o=_n(t,e),s=$n(e),a=0,l=e.text.length,c=!0,u=Zt(e,t.doc.direction);if(u){var h=(t.options.lineWrapping?function(t,e,n,i,r,o,s){var a=Xn(t,e,i,s),l=a.begin,c=a.end;/\s/.test(e.text.charAt(c-1))&&c--;for(var u=null,h=null,d=0;d=c||f.to<=l)){var p=1!=f.level,g=Ln(t,i,p?Math.min(c,f.to)-1:Math.max(l,f.from)).right,v=gv)&&(u=f,h=v)}}return u||(u=r[r.length-1]),u.fromc&&(u={from:u.from,to:c,level:u.level}),u}:function(t,e,n,i,r,o,s){var a=st(function(a){var l=r[a],c=1!=l.level;return Zn(qn(t,gt(n,c?l.to:l.from,c?"before":"after"),"line",e,i),o,s,!0)},0,r.length-1),l=r[a];if(a>0){var c=1!=l.level,u=qn(t,gt(n,c?l.from:l.to,c?"after":"before"),"line",e,i);Zn(u,o,s,!0)&&u.top>s&&(l=r[a-1])}return l})(t,e,n,o,u,i,r);c=1!=h.level,a=c?h.from:h.to-1,l=c?h.to:h.from-1}var d,f,p=null,g=null,v=st(function(e){var n=Ln(t,o,e);return n.top+=s,n.bottom+=s,!!Zn(n,i,r,!1)&&(n.top<=r&&n.left<=i&&(p=e,g=n),!0)},a,l),m=!1;if(g){var y=i-g.left=x.bottom}return v=ot(e.text,v,1),Yn(n,v,f,m,i-d)}function ti(t){if(null!=t.cachedTextHeight)return t.cachedTextHeight;if(null==Nn){Nn=O("pre");for(var e=0;e<49;++e)Nn.appendChild(document.createTextNode("x")),Nn.appendChild(O("br"));Nn.appendChild(document.createTextNode("x"))}A(t.measure,Nn);var n=Nn.offsetHeight/50;return n>3&&(t.cachedTextHeight=n),M(t.measure),n||1}function ei(t){if(null!=t.cachedCharWidth)return t.cachedCharWidth;var e=O("span","xxxxxxxxxx"),n=O("pre",[e]);A(t.measure,n);var i=e.getBoundingClientRect(),r=(i.right-i.left)/10;return r>2&&(t.cachedCharWidth=r),r||10}function ni(t){for(var e=t.display,n={},i={},r=e.gutters.clientLeft,o=e.gutters.firstChild,s=0;o;o=o.nextSibling,++s)n[t.options.gutters[s]]=o.offsetLeft+o.clientLeft+r,i[t.options.gutters[s]]=o.clientWidth;return{fixedPos:ii(e),gutterTotalWidth:e.gutters.offsetWidth,gutterLeft:n,gutterWidth:i,wrapperWidth:e.wrapper.clientWidth}}function ii(t){return t.scroller.getBoundingClientRect().left-t.sizer.getBoundingClientRect().left}function ri(t){var e=ti(t.display),n=t.options.lineWrapping,i=n&&Math.max(5,t.display.scroller.clientWidth/ei(t.display)-3);return function(r){if(Wt(t.doc,r))return 0;var o=0;if(r.widgets)for(var s=0;s=t.display.viewTo)return null;if((e-=t.display.viewFrom)<0)return null;for(var n=t.display.view,i=0;i=t.display.viewTo||a.to().linee||e==n&&s.to==e)&&(i(Math.max(s.from,e),Math.min(s.to,n),1==s.level?"rtl":"ltr",o),r=!0)}r||i(e,n,"ltr")}(g,n||0,null==i?d:i,function(t,e,r,h){var v="ltr"==r,m=f(t,v?"left":"right"),y=f(e-1,v?"right":"left"),b=null==n&&0==t,x=null==i&&e==d,w=0==h,C=!g||h==g.length-1;if(y.top-m.top<=3){var k=(c?b:x)&&w,S=(c?x:b)&&C,T=k?a:(v?m:y).left,E=S?l:(v?y:m).right;u(T,m.top,E-T,m.bottom)}else{var M,A,O,P;v?(M=c&&b&&w?a:m.left,A=c?l:p(t,r,"before"),O=c?a:p(e,r,"after"),P=c&&x&&C?l:y.right):(M=c?p(t,r,"before"):a,A=!c&&b&&w?l:m.right,O=!c&&x&&C?a:y.left,P=c?p(e,r,"after"):l),u(M,m.top,A-M,m.bottom),m.bottom0?e.blinker=setInterval(function(){return e.cursorDiv.style.visibility=(n=!n)?"":"hidden"},t.options.cursorBlinkRate):t.options.cursorBlinkRate<0&&(e.cursorDiv.style.visibility="hidden")}}function pi(t){t.state.focused||(t.display.input.focus(),vi(t))}function gi(t){t.state.delayingBlurEvent=!0,setTimeout(function(){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1,mi(t))},100)}function vi(t,e){t.state.delayingBlurEvent&&(t.state.delayingBlurEvent=!1),"nocursor"!=t.options.readOnly&&(t.state.focused||(ie(t,"focus",t,e),t.state.focused=!0,N(t.display.wrapper,"CodeMirror-focused"),t.curOp||t.display.selForContextMenu==t.doc.sel||(t.display.input.reset(),l&&setTimeout(function(){return t.display.input.reset(!0)},20)),t.display.input.receivedFocus()),fi(t))}function mi(t,e){t.state.delayingBlurEvent||(t.state.focused&&(ie(t,"blur",t,e),t.state.focused=!1,E(t.display.wrapper,"CodeMirror-focused")),clearInterval(t.display.blinker),setTimeout(function(){t.state.focused||(t.display.shift=!1)},150))}function yi(t){for(var e=t.display,n=e.lineDiv.offsetTop,i=0;i.005||u<-.005)&&(ut(r.line,o),bi(r.line),r.rest))for(var h=0;h=s&&(o=dt(e,qt(at(e,l))-t.wrapper.clientHeight),s=l)}return{from:o,to:Math.max(s,o+1)}}function wi(t){var e=t.display,n=e.view;if(e.alignWidgets||e.gutters.firstChild&&t.options.fixedGutter){for(var i=ii(e)-e.scroller.scrollLeft+t.doc.scrollLeft,r=e.gutters.offsetWidth,o=i+"px",s=0;so&&(e.bottom=e.top+o);var a=t.doc.height+kn(n),l=e.topa-i;if(e.topr+o){var u=Math.min(e.top,(c?a:e.bottom)-o);u!=r&&(s.scrollTop=u)}var h=t.curOp&&null!=t.curOp.scrollLeft?t.curOp.scrollLeft:n.scroller.scrollLeft,d=En(t)-(t.options.fixedGutter?n.gutters.offsetWidth:0),f=e.right-e.left>d;return f&&(e.right=e.left+d),e.left<10?s.scrollLeft=0:e.leftd+h-3&&(s.scrollLeft=e.right+(f?0:10)-d),s}function Si(t,e){null!=e&&(Mi(t),t.curOp.scrollTop=(null==t.curOp.scrollTop?t.doc.scrollTop:t.curOp.scrollTop)+e)}function Ti(t){Mi(t);var e=t.getCursor();t.curOp.scrollToPos={from:e,to:e,margin:t.options.cursorScrollMargin}}function Ei(t,e,n){null==e&&null==n||Mi(t),null!=e&&(t.curOp.scrollLeft=e),null!=n&&(t.curOp.scrollTop=n)}function Mi(t){var e=t.curOp.scrollToPos;if(e){t.curOp.scrollToPos=null;var n=Kn(t,e.from),i=Kn(t,e.to);Ai(t,n,i,e.margin)}}function Ai(t,e,n,i){var r=ki(t,{left:Math.min(e.left,n.left),top:Math.min(e.top,n.top)-i,right:Math.max(e.right,n.right),bottom:Math.max(e.bottom,n.bottom)+i});Ei(t,r.scrollLeft,r.scrollTop)}function Oi(t,e){Math.abs(t.doc.scrollTop-e)<2||(n||ar(t,{top:e}),Pi(t,e,!0),n&&ar(t),nr(t,100))}function Pi(t,e,n){e=Math.min(t.display.scroller.scrollHeight-t.display.scroller.clientHeight,e),(t.display.scroller.scrollTop!=e||n)&&(t.doc.scrollTop=e,t.display.scrollbars.setScrollTop(e),t.display.scroller.scrollTop!=e&&(t.display.scroller.scrollTop=e))}function _i(t,e,n,i){e=Math.min(e,t.display.scroller.scrollWidth-t.display.scroller.clientWidth),(n?e==t.doc.scrollLeft:Math.abs(t.doc.scrollLeft-e)<2)&&!i||(t.doc.scrollLeft=e,wi(t),t.display.scroller.scrollLeft!=e&&(t.display.scroller.scrollLeft=e),t.display.scrollbars.setScrollLeft(e))}function Li(t){var e=t.display,n=e.gutters.offsetWidth,i=Math.round(t.doc.height+kn(t.display));return{clientHeight:e.scroller.clientHeight,viewHeight:e.wrapper.clientHeight,scrollWidth:e.scroller.scrollWidth,clientWidth:e.scroller.clientWidth,viewWidth:e.wrapper.clientWidth,barLeft:t.options.fixedGutter?n:0,docHeight:i,scrollHeight:i+Tn(t)+e.barHeight,nativeBarWidth:e.nativeBarWidth,gutterWidth:n}}var Ni=function(t,e,n){this.cm=n;var i=this.vert=O("div",[O("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),r=this.horiz=O("div",[O("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");i.tabIndex=r.tabIndex=-1,t(i),t(r),te(i,"scroll",function(){i.clientHeight&&e(i.scrollTop,"vertical")}),te(r,"scroll",function(){r.clientWidth&&e(r.scrollLeft,"horizontal")}),this.checkedZeroWidth=!1,s&&a<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};Ni.prototype.update=function(t){var e=t.scrollWidth>t.clientWidth+1,n=t.scrollHeight>t.clientHeight+1,i=t.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=e?i+"px":"0";var r=t.viewHeight-(e?i:0);this.vert.firstChild.style.height=Math.max(0,t.scrollHeight-t.clientHeight+r)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(e){this.horiz.style.display="block",this.horiz.style.right=n?i+"px":"0",this.horiz.style.left=t.barLeft+"px";var o=t.viewWidth-t.barLeft-(n?i:0);this.horiz.firstChild.style.width=Math.max(0,t.scrollWidth-t.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&t.clientHeight>0&&(0==i&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?i:0,bottom:e?i:0}},Ni.prototype.setScrollLeft=function(t){this.horiz.scrollLeft!=t&&(this.horiz.scrollLeft=t),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},Ni.prototype.setScrollTop=function(t){this.vert.scrollTop!=t&&(this.vert.scrollTop=t),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},Ni.prototype.zeroWidthHack=function(){var t=y&&!f?"12px":"18px";this.horiz.style.height=this.vert.style.width=t,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new z,this.disableVert=new z},Ni.prototype.enableZeroWidthBar=function(t,e,n){t.style.pointerEvents="auto",e.set(1e3,function i(){var r=t.getBoundingClientRect(),o="vert"==n?document.elementFromPoint(r.right-1,(r.top+r.bottom)/2):document.elementFromPoint((r.right+r.left)/2,r.bottom-1);o!=t?t.style.pointerEvents="none":e.set(1e3,i)})},Ni.prototype.clear=function(){var t=this.horiz.parentNode;t.removeChild(this.horiz),t.removeChild(this.vert)};var Di=function(){};function Ii(t,e){e||(e=Li(t));var n=t.display.barWidth,i=t.display.barHeight;Fi(t,e);for(var r=0;r<4&&n!=t.display.barWidth||i!=t.display.barHeight;r++)n!=t.display.barWidth&&t.options.lineWrapping&&yi(t),Fi(t,Li(t)),n=t.display.barWidth,i=t.display.barHeight}function Fi(t,e){var n=t.display,i=n.scrollbars.update(e);n.sizer.style.paddingRight=(n.barWidth=i.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=i.bottom)+"px",n.heightForcer.style.borderBottom=i.bottom+"px solid transparent",i.right&&i.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=i.bottom+"px",n.scrollbarFiller.style.width=i.right+"px"):n.scrollbarFiller.style.display="",i.bottom&&t.options.coverGutterNextToScrollbar&&t.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=i.bottom+"px",n.gutterFiller.style.width=e.gutterWidth+"px"):n.gutterFiller.style.display=""}Di.prototype.update=function(){return{bottom:0,right:0}},Di.prototype.setScrollLeft=function(){},Di.prototype.setScrollTop=function(){},Di.prototype.clear=function(){};var Ri={native:Ni,null:Di};function ji(t){t.display.scrollbars&&(t.display.scrollbars.clear(),t.display.scrollbars.addClass&&E(t.display.wrapper,t.display.scrollbars.addClass)),t.display.scrollbars=new Ri[t.options.scrollbarStyle](function(e){t.display.wrapper.insertBefore(e,t.display.scrollbarFiller),te(e,"mousedown",function(){t.state.focused&&setTimeout(function(){return t.display.input.focus()},0)}),e.setAttribute("cm-not-content","true")},function(e,n){"horizontal"==n?_i(t,e):Oi(t,e)},t),t.display.scrollbars.addClass&&N(t.display.wrapper,t.display.scrollbars.addClass)}var zi=0;function Vi(t){t.curOp={cm:t,viewChanged:!1,startHeight:t.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:++zi},function(t){on?on.ops.push(t):t.ownsGroup=on={ops:[t],delayedCallbacks:[]}}(t.curOp)}function Hi(t){var e=t.curOp;!function(t,e){var n=t.ownsGroup;if(n)try{!function(t){var e=t.delayedCallbacks,n=0;do{for(;n=n.viewTo)||n.maxLineChanged&&e.options.lineWrapping,t.update=t.mustUpdate&&new rr(e,t.mustUpdate&&{top:t.scrollTop,ensure:t.scrollToPos},t.forceUpdate)}function Bi(t){t.updatedDisplay=t.mustUpdate&&or(t.cm,t.update)}function Wi(t){var e=t.cm,n=e.display;t.updatedDisplay&&yi(e),t.barMeasure=Li(e),n.maxLineChanged&&!e.options.lineWrapping&&(t.adjustWidthTo=On(e,n.maxLine,n.maxLine.text.length).left+3,e.display.sizerWidth=t.adjustWidthTo,t.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+t.adjustWidthTo+Tn(e)+e.display.barWidth),t.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+t.adjustWidthTo-En(e))),(t.updatedDisplay||t.selectionChanged)&&(t.preparedSelection=n.input.prepareSelection())}function Ui(t){var e=t.cm;null!=t.adjustWidthTo&&(e.display.sizer.style.minWidth=t.adjustWidthTo+"px",t.maxScrollLeft1&&(s=!0)),null!=c.scrollLeft&&(_i(t,c.scrollLeft),Math.abs(t.doc.scrollLeft-h)>1&&(s=!0)),!s)break}return r}(e,Ct(i,t.scrollToPos.from),Ct(i,t.scrollToPos.to),t.scrollToPos.margin);!function(t,e){if(!re(t,"scrollCursorIntoView")){var n=t.display,i=n.sizer.getBoundingClientRect(),r=null;if(e.top+i.top<0?r=!0:e.bottom+i.top>(window.innerHeight||document.documentElement.clientHeight)&&(r=!1),null!=r&&!p){var o=O("div","​",null,"position: absolute;\n top: "+(e.top-n.viewOffset-Cn(t.display))+"px;\n height: "+(e.bottom-e.top+Tn(t)+n.barHeight)+"px;\n left: "+e.left+"px; width: "+Math.max(2,e.right-e.left)+"px;");t.display.lineSpace.appendChild(o),o.scrollIntoView(r),t.display.lineSpace.removeChild(o)}}}(e,r)}var o=t.maybeHiddenMarkers,s=t.maybeUnhiddenMarkers;if(o)for(var a=0;ae)&&(r.updateLineNumbers=e),t.curOp.viewChanged=!0,e>=r.viewTo)Tt&&$t(t.doc,e)r.viewFrom?Qi(t):(r.viewFrom+=i,r.viewTo+=i);else if(e<=r.viewFrom&&n>=r.viewTo)Qi(t);else if(e<=r.viewFrom){var o=tr(t,n,n+i,1);o?(r.view=r.view.slice(o.index),r.viewFrom=o.lineN,r.viewTo+=i):Qi(t)}else if(n>=r.viewTo){var s=tr(t,e,e,-1);s?(r.view=r.view.slice(0,s.index),r.viewTo=s.lineN):Qi(t)}else{var a=tr(t,e,e,-1),l=tr(t,n,n+i,1);a&&l?(r.view=r.view.slice(0,a.index).concat(rn(t,a.lineN,l.lineN)).concat(r.view.slice(l.index)),r.viewTo+=i):Qi(t)}var c=r.externalMeasured;c&&(n=r.lineN&&e=i.viewTo)){var o=i.view[ai(t,e)];if(null!=o.node){var s=o.changes||(o.changes=[]);-1==V(s,n)&&s.push(n)}}}function Qi(t){t.display.viewFrom=t.display.viewTo=t.doc.first,t.display.view=[],t.display.viewOffset=0}function tr(t,e,n,i){var r,o=ai(t,e),s=t.display.view;if(!Tt||n==t.doc.first+t.doc.size)return{index:o,lineN:n};for(var a=t.display.viewFrom,l=0;l0){if(o==s.length-1)return null;r=a+s[o].size-e,o++}else r=a-e;e+=r,n+=r}for(;$t(t.doc,n)!=n;){if(o==(i<0?0:s.length-1))return null;n+=i*s[o-(i<0?1:0)].size,o+=i}return{index:o,lineN:n}}function er(t){for(var e=t.display.view,n=0,i=0;i=t.display.viewTo)){var n=+new Date+t.options.workTime,i=Re(t,e.highlightFrontier),r=[];e.iter(i.line,Math.min(e.first+e.size,t.display.viewTo+500),function(o){if(i.line>=t.display.viewFrom){var s=o.styles,a=o.text.length>t.options.maxHighlightLength?Oe(e.mode,i.state):null,l=Ie(t,o,i,!0);a&&(i.state=a),o.styles=l.styles;var c=o.styleClasses,u=l.classes;u?o.styleClasses=u:c&&(o.styleClasses=null);for(var h=!s||s.length!=o.styles.length||c!=u&&(!c||!u||c.bgClass!=u.bgClass||c.textClass!=u.textClass),d=0;!h&&dn)return nr(t,t.options.workDelay),!0}),e.highlightFrontier=i.line,e.modeFrontier=Math.max(e.modeFrontier,i.line),r.length&&Ki(t,function(){for(var e=0;e=n.viewFrom&&e.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==er(t))return!1;Ci(t)&&(Qi(t),e.dims=ni(t));var r=i.first+i.size,o=Math.max(e.visible.from-t.options.viewportMargin,i.first),s=Math.min(r,e.visible.to+t.options.viewportMargin);n.viewFroms&&n.viewTo-s<20&&(s=Math.min(r,n.viewTo)),Tt&&(o=$t(t.doc,o),s=Bt(t.doc,s));var a=o!=n.viewFrom||s!=n.viewTo||n.lastWrapHeight!=e.wrapperHeight||n.lastWrapWidth!=e.wrapperWidth;!function(t,e,n){var i=t.display;0==i.view.length||e>=i.viewTo||n<=i.viewFrom?(i.view=rn(t,e,n),i.viewFrom=e):(i.viewFrom>e?i.view=rn(t,e,i.viewFrom).concat(i.view):i.viewFromn&&(i.view=i.view.slice(0,ai(t,n)))),i.viewTo=n}(t,o,s),n.viewOffset=qt(at(t.doc,n.viewFrom)),t.display.mover.style.top=n.viewOffset+"px";var c=er(t);if(!a&&0==c&&!e.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var u=function(t){if(t.hasFocus())return null;var e=L();if(!e||!_(t.display.lineDiv,e))return null;var n={activeElt:e};if(window.getSelection){var i=window.getSelection();i.anchorNode&&i.extend&&_(t.display.lineDiv,i.anchorNode)&&(n.anchorNode=i.anchorNode,n.anchorOffset=i.anchorOffset,n.focusNode=i.focusNode,n.focusOffset=i.focusOffset)}return n}(t);return c>4&&(n.lineDiv.style.display="none"),function(t,e,n){var i=t.display,r=t.options.lineNumbers,o=i.lineDiv,s=o.firstChild;function a(e){var n=e.nextSibling;return l&&y&&t.display.currentWheelTarget==e?e.style.display="none":e.parentNode.removeChild(e),n}for(var c=i.view,u=i.viewFrom,h=0;h-1&&(f=!1),cn(t,d,u,n)),f&&(M(d.lineNumber),d.lineNumber.appendChild(document.createTextNode(pt(t.options,u)))),s=d.node.nextSibling}else{var p=vn(t,d,u,n);o.insertBefore(p,s)}u+=d.size}for(;s;)s=a(s)}(t,n.updateLineNumbers,e.dims),c>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,function(t){if(t&&t.activeElt&&t.activeElt!=L()&&(t.activeElt.focus(),t.anchorNode&&_(document.body,t.anchorNode)&&_(document.body,t.focusNode))){var e=window.getSelection(),n=document.createRange();n.setEnd(t.anchorNode,t.anchorOffset),n.collapse(!1),e.removeAllRanges(),e.addRange(n),e.extend(t.focusNode,t.focusOffset)}}(u),M(n.cursorDiv),M(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,a&&(n.lastWrapHeight=e.wrapperHeight,n.lastWrapWidth=e.wrapperWidth,nr(t,400)),n.updateLineNumbers=null,!0}function sr(t,e){for(var n=e.viewport,i=!0;(i&&t.options.lineWrapping&&e.oldDisplayWidth!=En(t)||(n&&null!=n.top&&(n={top:Math.min(t.doc.height+kn(t.display)-Mn(t),n.top)}),e.visible=xi(t.display,t.doc,n),!(e.visible.from>=t.display.viewFrom&&e.visible.to<=t.display.viewTo)))&&or(t,e);i=!1){yi(t);var r=Li(t);li(t),Ii(t,r),cr(t,r),e.force=!1}e.signal(t,"update",t),t.display.viewFrom==t.display.reportedViewFrom&&t.display.viewTo==t.display.reportedViewTo||(e.signal(t,"viewportChange",t,t.display.viewFrom,t.display.viewTo),t.display.reportedViewFrom=t.display.viewFrom,t.display.reportedViewTo=t.display.viewTo)}function ar(t,e){var n=new rr(t,e);if(or(t,n)){yi(t),sr(t,n);var i=Li(t);li(t),Ii(t,i),cr(t,i),n.finish()}}function lr(t){var e=t.display.gutters.offsetWidth;t.display.sizer.style.marginLeft=e+"px"}function cr(t,e){t.display.sizer.style.minHeight=e.docHeight+"px",t.display.heightForcer.style.top=e.docHeight+"px",t.display.gutters.style.height=e.docHeight+t.display.barHeight+Tn(t)+"px"}function ur(t){var e=t.display.gutters,n=t.options.gutters;M(e);for(var i=0;i-1&&!t.lineNumbers&&(t.gutters=t.gutters.slice(0),t.gutters.splice(e,1))}rr.prototype.signal=function(t,e){se(t,e)&&this.events.push(arguments)},rr.prototype.finish=function(){for(var t=0;ta.clientWidth,u=a.scrollHeight>a.clientHeight;if(r&&c||o&&u){if(o&&y&&l)t:for(var d=e.target,f=s.view;d!=a;d=d.parentNode)for(var p=0;p=0&&vt(t,i.to())<=0)return n}return-1};var yr=function(t,e){this.anchor=t,this.head=e};function br(t,e){var n=t[e];t.sort(function(t,e){return vt(t.from(),e.from())}),e=V(t,n);for(var i=1;i=0){var s=xt(o.from(),r.from()),a=bt(o.to(),r.to()),l=o.empty()?r.from()==r.head:o.from()==o.head;i<=e&&--e,t.splice(--i,2,new yr(l?a:s,l?s:a))}}return new mr(t,e)}function xr(t,e){return new mr([new yr(t,e||t)],0)}function wr(t){return t.text?gt(t.from.line+t.text.length-1,G(t.text).length+(1==t.text.length?t.from.ch:0)):t.to}function Cr(t,e){if(vt(t,e.from)<0)return t;if(vt(t,e.to)<=0)return wr(e);var n=t.line+e.text.length-(e.to.line-e.from.line)-1,i=t.ch;return t.line==e.to.line&&(i+=wr(e).ch-e.to.ch),gt(n,i)}function kr(t,e){for(var n=[],i=0;i1&&t.remove(a.line+1,p-1),t.insert(a.line+1,m)}an(t,"change",t,e)}function Or(t,e,n){!function t(i,r,o){if(i.linked)for(var s=0;sa-(t.cm?t.cm.options.historyEventDelay:500)||"*"==e.origin.charAt(0)))&&(o=function(t,e){return e?(Dr(t.done),G(t.done)):t.done.length&&!G(t.done).ranges?G(t.done):t.done.length>1&&!t.done[t.done.length-2].ranges?(t.done.pop(),G(t.done)):void 0}(r,r.lastOp==i)))s=G(o.changes),0==vt(e.from,e.to)&&0==vt(e.from,s.to)?s.to=wr(e):o.changes.push(Nr(t,e));else{var l=G(r.done);for(l&&l.ranges||Rr(t.sel,r.done),o={changes:[Nr(t,e)],generation:r.generation},r.done.push(o);r.done.length>r.undoDepth;)r.done.shift(),r.done[0].ranges||r.done.shift()}r.done.push(n),r.generation=++r.maxGeneration,r.lastModTime=r.lastSelTime=a,r.lastOp=r.lastSelOp=i,r.lastOrigin=r.lastSelOrigin=e.origin,s||ie(t,"historyAdded")}function Fr(t,e,n,i){var r=t.history,o=i&&i.origin;n==r.lastSelOp||o&&r.lastSelOrigin==o&&(r.lastModTime==r.lastSelTime&&r.lastOrigin==o||function(t,e,n,i){var r=e.charAt(0);return"*"==r||"+"==r&&n.ranges.length==i.ranges.length&&n.somethingSelected()==i.somethingSelected()&&new Date-t.history.lastSelTime<=(t.cm?t.cm.options.historyEventDelay:500)}(t,o,G(r.done),e))?r.done[r.done.length-1]=e:Rr(e,r.done),r.lastSelTime=+new Date,r.lastSelOrigin=o,r.lastSelOp=n,i&&!1!==i.clearRedo&&Dr(r.undone)}function Rr(t,e){var n=G(e);n&&n.ranges&&n.equals(t)||e.push(t)}function jr(t,e,n,i){var r=e["spans_"+t.id],o=0;t.iter(Math.max(t.first,n),Math.min(t.first+t.size,i),function(n){n.markedSpans&&((r||(r=e["spans_"+t.id]={}))[o]=n.markedSpans),++o})}function zr(t){if(!t)return null;for(var e,n=0;n-1&&(G(a)[h]=c[h],delete c[h])}}}return i}function $r(t,e,n,i){if(i){var r=t.anchor;if(n){var o=vt(e,r)<0;o!=vt(n,r)<0?(r=e,e=n):o!=vt(e,n)<0&&(e=n)}return new yr(r,e)}return new yr(n||e,e)}function Br(t,e,n,i,r){null==r&&(r=t.cm&&(t.cm.display.shift||t.extend)),Yr(t,new mr([$r(t.sel.primary(),e,n,r)],0),i)}function Wr(t,e,n){for(var i=[],r=t.cm&&(t.cm.display.shift||t.extend),o=0;o=e.ch:a.to>e.ch))){if(r&&(ie(l,"beforeCursorEnter"),l.explicitlyCleared)){if(o.markedSpans){--s;continue}break}if(!l.atomic)continue;if(n){var c=l.find(i<0?1:-1),u=void 0;if((i<0?l.inclusiveRight:l.inclusiveLeft)&&(c=eo(t,c,-i,c&&c.line==e.line?o:null)),c&&c.line==e.line&&(u=vt(c,n))&&(i<0?u<0:u>0))return Qr(t,c,e,i,r)}var h=l.find(i<0?-1:1);return(i<0?l.inclusiveLeft:l.inclusiveRight)&&(h=eo(t,h,i,h.line==e.line?o:null)),h?Qr(t,h,e,i,r):null}}return e}function to(t,e,n,i,r){var o=i||1,s=Qr(t,e,n,o,r)||!r&&Qr(t,e,n,o,!0)||Qr(t,e,n,-o,r)||!r&&Qr(t,e,n,-o,!0);return s||(t.cantEdit=!0,gt(t.first,0))}function eo(t,e,n,i){return n<0&&0==e.ch?e.line>t.first?Ct(t,gt(e.line-1)):null:n>0&&e.ch==(i||at(t,e.line)).text.length?e.line0)){var u=[l,1],h=vt(c.from,a.from),d=vt(c.to,a.to);(h<0||!s.inclusiveLeft&&!h)&&u.push({from:c.from,to:a.from}),(d>0||!s.inclusiveRight&&!d)&&u.push({from:a.to,to:c.to}),r.splice.apply(r,u),l+=u.length-3}}return r}(t,e.from,e.to);if(i)for(var r=i.length-1;r>=0;--r)oo(t,{from:i[r].from,to:i[r].to,text:r?[""]:e.text,origin:e.origin});else oo(t,e)}}function oo(t,e){if(1!=e.text.length||""!=e.text[0]||0!=vt(e.from,e.to)){var n=kr(t,e);Ir(t,e,n,t.cm?t.cm.curOp.id:NaN),lo(t,e,n,Ot(t,e));var i=[];Or(t,function(t,n){n||-1!=V(i,t.history)||(fo(t.history,e),i.push(t.history)),lo(t,e,null,Ot(t,e))})}}function so(t,e,n){var i=t.cm&&t.cm.state.suppressEdits;if(!i||n){for(var r,o=t.history,s=t.sel,a="undo"==e?o.done:o.undone,l="undo"==e?o.undone:o.done,c=0;c=0;--f){var p=d(f);if(p)return p.v}}}}function ao(t,e){if(0!=e&&(t.first+=e,t.sel=new mr(X(t.sel.ranges,function(t){return new yr(gt(t.anchor.line+e,t.anchor.ch),gt(t.head.line+e,t.head.ch))}),t.sel.primIndex),t.cm)){Ji(t.cm,t.first,t.first-e,e);for(var n=t.cm.display,i=n.viewFrom;it.lastLine())){if(e.from.lineo&&(e={from:e.from,to:gt(o,at(t,o).text.length),text:[e.text[0]],origin:e.origin}),e.removed=lt(t,e.from,e.to),n||(n=kr(t,e)),t.cm?function(t,e,n){var i=t.doc,r=t.display,o=e.from,s=e.to,a=!1,l=o.line;t.options.lineWrapping||(l=ht(Ht(at(i,o.line))),i.iter(l,s.line+1,function(t){if(t==r.maxLine)return a=!0,!0})),i.sel.contains(e.from,e.to)>-1&&oe(t),Ar(i,e,n,ri(t)),t.options.lineWrapping||(i.iter(l,o.line+e.text.length,function(t){var e=Kt(t);e>r.maxLineLength&&(r.maxLine=t,r.maxLineLength=e,r.maxLineChanged=!0,a=!1)}),a&&(t.curOp.updateMaxLine=!0)),function(t,e){if(t.modeFrontier=Math.min(t.modeFrontier,e),!(t.highlightFrontiern;i--){var r=at(t,i).stateAfter;if(r&&(!(r instanceof Ne)||i+r.lookAhead1||!(this.children[0]instanceof go))){var a=[];this.collapse(a),this.children=[new go(a)],this.children[0].parent=this}},collapse:function(t){for(var e=0;e50){for(var s=r.lines.length%25+25,a=s;a10);t.parent.maybeSpill()}},iterN:function(t,e,n){for(var i=0;i0||0==s&&!1!==o.clearWhenEmpty)return o;if(o.replacedWith&&(o.collapsed=!0,o.widgetNode=P("span",[o.replacedWith],"CodeMirror-widget"),i.handleMouseEvents||o.widgetNode.setAttribute("cm-ignore-events","true"),i.insertLeft&&(o.widgetNode.insertLeft=!0)),o.collapsed){if(Vt(t,e.line,e,n,o)||e.line!=n.line&&Vt(t,n.line,e,n,o))throw new Error("Inserting collapsed marker partially overlapping an existing one");Tt=!0}o.addToHistory&&Ir(t,{from:e,to:n,origin:"markText"},t.sel,NaN);var a,l=e.line,c=t.cm;if(t.iter(l,n.line+1,function(t){c&&o.collapsed&&!c.options.lineWrapping&&Ht(t)==c.display.maxLine&&(a=!0),o.collapsed&&l!=e.line&&ut(t,0),function(t,e){t.markedSpans=t.markedSpans?t.markedSpans.concat([e]):[e],e.marker.attachLine(t)}(t,new Et(o,l==e.line?e.ch:null,l==n.line?n.ch:null)),++l}),o.collapsed&&t.iter(e.line,n.line+1,function(e){Wt(t,e)&&ut(e,0)}),o.clearOnEnter&&te(o,"beforeCursorEnter",function(){return o.clear()}),o.readOnly&&(St=!0,(t.history.done.length||t.history.undone.length)&&t.clearHistory()),o.collapsed&&(o.id=++bo,o.atomic=!0),c){if(a&&(c.curOp.updateMaxLine=!0),o.collapsed)Ji(c,e.line,n.line+1);else if(o.className||o.title||o.startStyle||o.endStyle||o.css)for(var u=e.line;u<=n.line;u++)Zi(c,u,"text");o.atomic&&Jr(c.doc),an(c,"markerAdded",c,o)}return o}xo.prototype.clear=function(){if(!this.explicitlyCleared){var t=this.doc.cm,e=t&&!t.curOp;if(e&&Vi(t),se(this,"clear")){var n=this.find();n&&an(this,"clear",n.from,n.to)}for(var i=null,r=null,o=0;ot.display.maxLineLength&&(t.display.maxLine=c,t.display.maxLineLength=u,t.display.maxLineChanged=!0)}null!=i&&t&&this.collapsed&&Ji(t,i,r+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,t&&Jr(t.doc)),t&&an(t,"markerCleared",t,this,i,r),e&&Hi(t),this.parent&&this.parent.clear()}},xo.prototype.find=function(t,e){var n,i;null==t&&"bookmark"==this.type&&(t=1);for(var r=0;r=0;l--)ro(this,i[l]);a?Kr(this,a):this.cm&&Ti(this.cm)}),undo:Xi(function(){so(this,"undo")}),redo:Xi(function(){so(this,"redo")}),undoSelection:Xi(function(){so(this,"undo",!0)}),redoSelection:Xi(function(){so(this,"redo",!0)}),setExtending:function(t){this.extend=t},getExtending:function(){return this.extend},historySize:function(){for(var t=this.history,e=0,n=0,i=0;i=t.ch)&&e.push(r.marker.parent||r.marker)}return e},findMarks:function(t,e,n){t=Ct(this,t),e=Ct(this,e);var i=[],r=t.line;return this.iter(t.line,e.line+1,function(o){var s=o.markedSpans;if(s)for(var a=0;a=l.to||null==l.from&&r!=t.line||null!=l.from&&r==e.line&&l.from>=e.ch||n&&!n(l.marker)||i.push(l.marker.parent||l.marker)}++r}),i},getAllMarks:function(){var t=[];return this.iter(function(e){var n=e.markedSpans;if(n)for(var i=0;it)return e=t,!0;t-=o,++n}),Ct(this,gt(n,e))},indexFromPos:function(t){var e=(t=Ct(this,t)).ch;if(t.linee&&(e=t.from),null!=t.to&&t.to-1)return e.state.draggingText(t),void setTimeout(function(){return e.display.input.focus()},20);try{var u=t.dataTransfer.getData("Text");if(u){var h;if(e.state.draggingText&&!e.state.draggingText.copy&&(h=e.listSelections()),Gr(e.doc,xr(n,n)),h)for(var d=0;d=0;e--)co(t.doc,"",i[e].from,i[e].to,"+delete");Ti(t)})}function Ko(t,e,n){var i=ot(t.text,e+n,n);return i<0||i>t.text.length?null:i}function Yo(t,e,n){var i=Ko(t,e.ch,n);return null==i?null:new gt(e.line,i,n<0?"after":"before")}function Go(t,e,n,i,r){if(t){var o=Zt(n,e.doc.direction);if(o){var s,a=r<0?G(o):o[0],l=r<0==(1==a.level),c=l?"after":"before";if(a.level>0||"rtl"==e.doc.direction){var u=_n(e,n);s=r<0?n.text.length-1:0;var h=Ln(e,u,s).top;s=st(function(t){return Ln(e,u,t).top==h},r<0==(1==a.level)?a.from:a.to-1,s),"before"==c&&(s=Ko(n,s,1))}else s=r<0?a.to:a.from;return new gt(i,s,c)}}return new gt(i,r<0?n.text.length:0,r<0?"before":"after")}jo.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"},jo.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"},jo.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"},jo.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"]},jo.default=y?jo.macDefault:jo.pcDefault;var Xo={selectAll:no,singleSelection:function(t){return t.setSelection(t.getCursor("anchor"),t.getCursor("head"),B)},killLine:function(t){return qo(t,function(e){if(e.empty()){var n=at(t.doc,e.head.line).text.length;return e.head.ch==n&&e.head.line0)r=new gt(r.line,r.ch+1),t.replaceRange(o.charAt(r.ch-1)+o.charAt(r.ch-2),gt(r.line,r.ch-2),r,"+transpose");else if(r.line>t.doc.first){var s=at(t.doc,r.line-1).text;s&&(r=new gt(r.line,1),t.replaceRange(o.charAt(0)+t.doc.lineSeparator()+s.charAt(s.length-1),gt(r.line-1,s.length-1),r,"+transpose"))}n.push(new yr(r,r))}t.setSelections(n)})},newlineAndIndent:function(t){return Ki(t,function(){for(var e=t.listSelections(),n=e.length-1;n>=0;n--)t.replaceRange(t.doc.lineSeparator(),e[n].anchor,e[n].head,"+input");e=t.listSelections();for(var i=0;i-1&&(vt((r=c.ranges[r]).from(),e)<0||e.xRel>0)&&(vt(r.to(),e)>0||e.xRel<0)?function(t,e,n,i){var r=t.display,o=!1,c=Yi(t,function(e){l&&(r.scroller.draggable=!1),t.state.draggingText=!1,ne(r.wrapper.ownerDocument,"mouseup",c),ne(r.wrapper.ownerDocument,"mousemove",u),ne(r.scroller,"dragstart",h),ne(r.scroller,"drop",c),o||(le(e),i.addNew||Br(t.doc,n,null,null,i.extend),l||s&&9==a?setTimeout(function(){r.wrapper.ownerDocument.body.focus(),r.input.focus()},20):r.input.focus())}),u=function(t){o=o||Math.abs(e.clientX-t.clientX)+Math.abs(e.clientY-t.clientY)>=10},h=function(){return o=!0};l&&(r.scroller.draggable=!0),t.state.draggingText=c,c.copy=!i.moveOnDrag,r.scroller.dragDrop&&r.scroller.dragDrop(),te(r.wrapper.ownerDocument,"mouseup",c),te(r.wrapper.ownerDocument,"mousemove",u),te(r.scroller,"dragstart",h),te(r.scroller,"drop",c),gi(t),setTimeout(function(){return r.input.focus()},20)}(t,i,e,o):function(t,e,n,i){var r=t.display,o=t.doc;le(e);var s,a,l=o.sel,c=l.ranges;if(i.addNew&&!i.extend?(a=o.sel.contains(n),s=a>-1?c[a]:new yr(n,n)):(s=o.sel.primary(),a=o.sel.primIndex),"rectangle"==i.unit)i.addNew||(s=new yr(n,n)),n=si(t,e,!0,!0),a=-1;else{var u=ds(t,n,i.unit);s=i.extend?$r(s,u.anchor,u.head,i.extend):u}i.addNew?-1==a?(a=c.length,Yr(o,br(c.concat([s]),a),{scroll:!1,origin:"*mouse"})):c.length>1&&c[a].empty()&&"char"==i.unit&&!i.extend?(Yr(o,br(c.slice(0,a).concat(c.slice(a+1)),0),{scroll:!1,origin:"*mouse"}),l=o.sel):Ur(o,a,s,W):(a=0,Yr(o,new mr([s],0),W),l=o.sel);var h=n;function d(e){if(0!=vt(h,e))if(h=e,"rectangle"==i.unit){for(var r=[],c=t.options.tabSize,u=j(at(o,n.line).text,n.ch,c),d=j(at(o,e.line).text,e.ch,c),f=Math.min(u,d),p=Math.max(u,d),g=Math.min(n.line,e.line),v=Math.min(t.lastLine(),Math.max(n.line,e.line));g<=v;g++){var m=at(o,g).text,y=q(m,f,c);f==p?r.push(new yr(gt(g,y),gt(g,y))):m.length>y&&r.push(new yr(gt(g,y),gt(g,q(m,p,c))))}r.length||r.push(new yr(n,n)),Yr(o,br(l.ranges.slice(0,a).concat(r),a),{origin:"*mouse",scroll:!1}),t.scrollIntoView(e)}else{var b,x=s,w=ds(t,e,i.unit),C=x.anchor;vt(w.anchor,C)>0?(b=w.head,C=xt(x.from(),w.anchor)):(b=w.anchor,C=bt(x.to(),w.head));var k=l.ranges.slice(0);k[a]=function(t,e){var n=e.anchor,i=e.head,r=at(t.doc,n.line);if(0==vt(n,i)&&n.sticky==i.sticky)return e;var o=Zt(r);if(!o)return e;var s=Xt(o,n.ch,n.sticky),a=o[s];if(a.from!=n.ch&&a.to!=n.ch)return e;var l,c=s+(a.from==n.ch==(1!=a.level)?0:1);if(0==c||c==o.length)return e;if(i.line!=n.line)l=(i.line-n.line)*("ltr"==t.doc.direction?1:-1)>0;else{var u=Xt(o,i.ch,i.sticky),h=u-s||(i.ch-n.ch)*(1==a.level?-1:1);l=u==c-1||u==c?h<0:h>0}var d=o[c+(l?-1:0)],f=l==(1==d.level),p=f?d.from:d.to,g=f?"after":"before";return n.ch==p&&n.sticky==g?e:new yr(new gt(n.line,p,g),i)}(t,new yr(Ct(o,C),b)),Yr(o,br(k,a),W)}}var f=r.wrapper.getBoundingClientRect(),p=0;function g(e){t.state.selectingText=!1,p=1/0,le(e),r.input.focus(),ne(r.wrapper.ownerDocument,"mousemove",v),ne(r.wrapper.ownerDocument,"mouseup",m),o.history.lastSelOrigin=null}var v=Yi(t,function(e){0!==e.buttons&&fe(e)?function e(n){var s=++p,a=si(t,n,!0,"rectangle"==i.unit);if(a)if(0!=vt(a,h)){t.curOp.focus=L(),d(a);var l=xi(r,o);(a.line>=l.to||a.linef.bottom?20:0;c&&setTimeout(Yi(t,function(){p==s&&(r.scroller.scrollTop+=c,e(n))}),50)}}(e):g(e)}),m=Yi(t,g);t.state.selectingText=m,te(r.wrapper.ownerDocument,"mousemove",v),te(r.wrapper.ownerDocument,"mouseup",m)}(t,i,e,o)}(e,i,o,t):de(t)==n.scroller&&le(t):2==r?(i&&Br(e.doc,i),setTimeout(function(){return n.input.focus()},20)):3==r&&(k?gs(e,t):gi(e)))}}function ds(t,e,n){if("char"==n)return new yr(e,e);if("word"==n)return t.findWordAt(e);if("line"==n)return new yr(gt(e.line,0),Ct(t.doc,gt(e.line+1,0)));var i=n(t,e);return new yr(i.from,i.to)}function fs(t,e,n,i){var r,o;if(e.touches)r=e.touches[0].clientX,o=e.touches[0].clientY;else try{r=e.clientX,o=e.clientY}catch(e){return!1}if(r>=Math.floor(t.display.gutters.getBoundingClientRect().right))return!1;i&&le(e);var s=t.display,a=s.lineDiv.getBoundingClientRect();if(o>a.bottom||!se(t,n))return ue(e);o-=a.top-s.viewOffset;for(var l=0;l=r){var u=dt(t.doc,o),h=t.options.gutters[l];return ie(t,n,t,u,h,e),ue(e)}}}function ps(t,e){return fs(t,e,"gutterClick",!0)}function gs(t,e){wn(t.display,e)||function(t,e){return!!se(t,"gutterContextMenu")&&fs(t,e,"gutterContextMenu",!1)}(t,e)||re(t,e,"contextmenu")||t.display.input.onContextMenu(e)}function vs(t){t.display.wrapper.className=t.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+t.options.theme.replace(/(^|\s)\s*/g," cm-s-"),zn(t)}us.prototype.compare=function(t,e,n){return this.time+400>t&&0==vt(e,this.pos)&&n==this.button};var ms={toString:function(){return"CodeMirror.Init"}},ys={},bs={};function xs(t){ur(t),Ji(t),wi(t)}function ws(t,e,n){var i=n&&n!=ms;if(!e!=!i){var r=t.display.dragFunctions,o=e?te:ne;o(t.display.scroller,"dragstart",r.start),o(t.display.scroller,"dragenter",r.enter),o(t.display.scroller,"dragover",r.over),o(t.display.scroller,"dragleave",r.leave),o(t.display.scroller,"drop",r.drop)}}function Cs(t){t.options.lineWrapping?(N(t.display.wrapper,"CodeMirror-wrap"),t.display.sizer.style.minWidth="",t.display.sizerWidth=null):(E(t.display.wrapper,"CodeMirror-wrap"),Yt(t)),oi(t),Ji(t),zn(t),setTimeout(function(){return Ii(t)},100)}function ks(t,e){var i=this;if(!(this instanceof ks))return new ks(t,e);this.options=e=e?R(e):{},R(ys,e,!1),hr(e);var r=e.value;"string"==typeof r&&(r=new Eo(r,e.mode,null,e.lineSeparator,e.direction)),this.doc=r;var o=new ks.inputStyles[e.inputStyle](this),c=this.display=new function(t,e,i){var r=this;this.input=i,r.scrollbarFiller=O("div",null,"CodeMirror-scrollbar-filler"),r.scrollbarFiller.setAttribute("cm-not-content","true"),r.gutterFiller=O("div",null,"CodeMirror-gutter-filler"),r.gutterFiller.setAttribute("cm-not-content","true"),r.lineDiv=P("div",null,"CodeMirror-code"),r.selectionDiv=O("div",null,null,"position: relative; z-index: 1"),r.cursorDiv=O("div",null,"CodeMirror-cursors"),r.measure=O("div",null,"CodeMirror-measure"),r.lineMeasure=O("div",null,"CodeMirror-measure"),r.lineSpace=P("div",[r.measure,r.lineMeasure,r.selectionDiv,r.cursorDiv,r.lineDiv],null,"position: relative; outline: none");var o=P("div",[r.lineSpace],"CodeMirror-lines");r.mover=O("div",[o],null,"position: relative"),r.sizer=O("div",[r.mover],"CodeMirror-sizer"),r.sizerWidth=null,r.heightForcer=O("div",null,null,"position: absolute; height: "+H+"px; width: 1px;"),r.gutters=O("div",null,"CodeMirror-gutters"),r.lineGutter=null,r.scroller=O("div",[r.sizer,r.heightForcer,r.gutters],"CodeMirror-scroll"),r.scroller.setAttribute("tabIndex","-1"),r.wrapper=O("div",[r.scrollbarFiller,r.gutterFiller,r.scroller],"CodeMirror"),s&&a<8&&(r.gutters.style.zIndex=-1,r.scroller.style.paddingRight=0),l||n&&m||(r.scroller.draggable=!0),t&&(t.appendChild?t.appendChild(r.wrapper):t(r.wrapper)),r.viewFrom=r.viewTo=e.first,r.reportedViewFrom=r.reportedViewTo=e.first,r.view=[],r.renderedView=null,r.externalMeasured=null,r.viewOffset=0,r.lastWrapHeight=r.lastWrapWidth=0,r.updateLineNumbers=null,r.nativeBarWidth=r.barHeight=r.barWidth=0,r.scrollbarsClipped=!1,r.lineNumWidth=r.lineNumInnerWidth=r.lineNumChars=null,r.alignWidgets=!1,r.cachedCharWidth=r.cachedTextHeight=r.cachedPaddingH=null,r.maxLine=null,r.maxLineLength=0,r.maxLineChanged=!1,r.wheelDX=r.wheelDY=r.wheelStartX=r.wheelStartY=null,r.shift=!1,r.selForContextMenu=null,r.activeTouch=null,i.init(r)}(t,r,o);for(var u in c.wrapper.CodeMirror=this,ur(this),vs(this),e.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),ji(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 z,keySeq:null,specialChars:null},e.autofocus&&!m&&c.input.focus(),s&&a<11&&setTimeout(function(){return i.display.input.reset(!0)},20),function(t){var e=t.display;te(e.scroller,"mousedown",Yi(t,hs)),te(e.scroller,"dblclick",s&&a<11?Yi(t,function(e){if(!re(t,e)){var n=si(t,e);if(n&&!ps(t,e)&&!wn(t.display,e)){le(e);var i=t.findWordAt(n);Br(t.doc,i.anchor,i.head)}}}):function(e){return re(t,e)||le(e)}),k||te(e.scroller,"contextmenu",function(e){return gs(t,e)});var n,i={end:0};function r(){e.activeTouch&&(n=setTimeout(function(){return e.activeTouch=null},1e3),(i=e.activeTouch).end=+new Date)}function o(t,e){if(null==e.left)return!0;var n=e.left-t.left,i=e.top-t.top;return n*n+i*i>400}te(e.scroller,"touchstart",function(r){if(!re(t,r)&&!function(t){if(1!=t.touches.length)return!1;var e=t.touches[0];return e.radiusX<=1&&e.radiusY<=1}(r)&&!ps(t,r)){e.input.ensurePolled(),clearTimeout(n);var o=+new Date;e.activeTouch={start:o,moved:!1,prev:o-i.end<=300?i:null},1==r.touches.length&&(e.activeTouch.left=r.touches[0].pageX,e.activeTouch.top=r.touches[0].pageY)}}),te(e.scroller,"touchmove",function(){e.activeTouch&&(e.activeTouch.moved=!0)}),te(e.scroller,"touchend",function(n){var i=e.activeTouch;if(i&&!wn(e,n)&&null!=i.left&&!i.moved&&new Date-i.start<300){var s,a=t.coordsChar(e.activeTouch,"page");s=!i.prev||o(i,i.prev)?new yr(a,a):!i.prev.prev||o(i,i.prev.prev)?t.findWordAt(a):new yr(gt(a.line,0),Ct(t.doc,gt(a.line+1,0))),t.setSelection(s.anchor,s.head),t.focus(),le(n)}r()}),te(e.scroller,"touchcancel",r),te(e.scroller,"scroll",function(){e.scroller.clientHeight&&(Oi(t,e.scroller.scrollTop),_i(t,e.scroller.scrollLeft,!0),ie(t,"scroll",t))}),te(e.scroller,"mousewheel",function(e){return vr(t,e)}),te(e.scroller,"DOMMouseScroll",function(e){return vr(t,e)}),te(e.wrapper,"scroll",function(){return e.wrapper.scrollTop=e.wrapper.scrollLeft=0}),e.dragFunctions={enter:function(e){re(t,e)||he(e)},over:function(e){re(t,e)||(function(t,e){var n=si(t,e);if(n){var i=document.createDocumentFragment();ui(t,n,i),t.display.dragCursor||(t.display.dragCursor=O("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),t.display.lineSpace.insertBefore(t.display.dragCursor,t.display.cursorDiv)),A(t.display.dragCursor,i)}}(t,e),he(e))},start:function(e){return function(t,e){if(s&&(!t.state.draggingText||+new Date-Mo<100))he(e);else if(!re(t,e)&&!wn(t.display,e)&&(e.dataTransfer.setData("Text",t.getSelection()),e.dataTransfer.effectAllowed="copyMove",e.dataTransfer.setDragImage&&!d)){var n=O("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",h&&(n.width=n.height=1,t.display.wrapper.appendChild(n),n._top=n.offsetTop),e.dataTransfer.setDragImage(n,0,0),h&&n.parentNode.removeChild(n)}}(t,e)},drop:Yi(t,Ao),leave:function(e){re(t,e)||Oo(t)}};var l=e.input.getField();te(l,"keyup",function(e){return ss.call(t,e)}),te(l,"keydown",Yi(t,os)),te(l,"keypress",Yi(t,as)),te(l,"focus",function(e){return vi(t,e)}),te(l,"blur",function(e){return mi(t,e)})}(this),Lo(),Vi(this),this.curOp.forceUpdate=!0,Pr(this,r),e.autofocus&&!m||this.hasFocus()?setTimeout(F(vi,this),20):mi(this),bs)bs.hasOwnProperty(u)&&bs[u](i,e[u],ms);Ci(this),e.finishInit&&e.finishInit(this);for(var f=0;f150)){if(!i)return;n="prev"}}else c=0,n="not";"prev"==n?c=e>o.first?j(at(o,e-1).text,null,s):0:"add"==n?c=l+t.options.indentUnit:"subtract"==n?c=l-t.options.indentUnit:"number"==typeof n&&(c=l+n),c=Math.max(0,c);var h="",d=0;if(t.options.indentWithTabs)for(var f=Math.floor(c/s);f;--f)d+=s,h+="\t";if(d1)if(Es&&Es.text.join("\n")==e){if(i.ranges.length%Es.text.length==0){c=[];for(var u=0;u=0;h--){var d=i.ranges[h],f=d.from(),p=d.to();d.empty()&&(n&&n>0?f=gt(f.line,f.ch-n):t.state.overwrite&&!a?p=gt(p.line,Math.min(at(o,p.line).text.length,p.ch+G(l).length)):Es&&Es.lineWise&&Es.text.join("\n")==e&&(f=p=gt(f.line,0))),s=t.curOp.updateInput;var g={from:f,to:p,text:c?c[h%c.length]:l,origin:r||(a?"paste":t.state.cutIncoming?"cut":"+input")};ro(t.doc,g),an(t,"inputRead",t,g)}e&&!a&&Ps(t,e),Ti(t),t.curOp.updateInput=s,t.curOp.typing=!0,t.state.pasteIncoming=t.state.cutIncoming=!1}function Os(t,e){var n=t.clipboardData&&t.clipboardData.getData("Text");if(n)return t.preventDefault(),e.isReadOnly()||e.options.disableInput||Ki(e,function(){return As(e,n,0,null,"paste")}),!0}function Ps(t,e){if(t.options.electricChars&&t.options.smartIndent)for(var n=t.doc.sel,i=n.ranges.length-1;i>=0;i--){var r=n.ranges[i];if(!(r.head.ch>100||i&&n.ranges[i-1].head.line==r.head.line)){var o=t.getModeAt(r.head),s=!1;if(o.electricChars){for(var a=0;a-1){s=Ts(t,r.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(at(t.doc,r.head.line).text.slice(0,r.head.ch))&&(s=Ts(t,r.head.line,"smart"));s&&an(t,"electricInput",t,r.head.line)}}}function _s(t){for(var e=[],n=[],i=0;i=e.text.length?(n.ch=e.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var o=Xt(r,n.ch,n.sticky),s=r[o];if("ltr"==t.doc.direction&&s.level%2==0&&(i>0?s.to>n.ch:s.from=s.from&&d>=u.begin)){var f=h?"before":"after";return new gt(n.line,d,f)}}var p=function(t,e,i){for(var o=function(t,e){return e?new gt(n.line,l(t,1),"before"):new gt(n.line,t,"after")};t>=0&&t0==(1!=s.level),c=a?i.begin:l(i.end,-1);if(s.from<=c&&c0?u.end:l(u.begin,-1);return null==v||i>0&&v==e.text.length||!(g=p(i>0?0:r.length-1,i,c(v)))?null:g}(t.cm,a,e,n):Yo(a,e,n))){if(i||!function(){var i=e.line+n;return!(i=t.first+t.size)&&(e=new gt(i,e.ch,e.sticky),a=at(t,i))}())return!1;e=Go(r,t.cm,a,e.line,n)}else e=o;return!0}if("char"==i)l();else if("column"==i)l(!0);else if("word"==i||"group"==i)for(var c=null,u="group"==i,h=t.cm&&t.cm.getHelper(e,"wordChars"),d=!0;!(n<0)||l(!d);d=!1){var f=a.text.charAt(e.ch)||"\n",p=et(f,h)?"w":u&&"\n"==f?"n":!u||/\s/.test(f)?null:"p";if(!u||d||p||(p="s"),c&&c!=p){n<0&&(n=1,l(),e.sticky="after");break}if(p&&(c=p),n>0&&!l(!d))break}var g=to(t,e,o,s,!0);return mt(o,g)&&(g.hitSide=!0),g}function Is(t,e,n,i){var r,o,s=t.doc,a=e.left;if("page"==i){var l=Math.min(t.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),c=Math.max(l-.5*ti(t.display),3);r=(n>0?e.bottom:e.top)+n*c}else"line"==i&&(r=n>0?e.bottom+3:e.top-3);for(;(o=Gn(t,a,r)).outside;){if(n<0?r<=0:r>=s.height){o.hitSide=!0;break}r+=5*n}return o}var Fs=function(t){this.cm=t,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new z,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function Rs(t,e){var n=Pn(t,e.line);if(!n||n.hidden)return null;var i=at(t.doc,e.line),r=An(n,i,e.line),o=Zt(i,t.doc.direction),s="left";if(o){var a=Xt(o,e.ch);s=a%2?"right":"left"}var l=In(r.map,e.ch,s);return l.offset="right"==l.collapse?l.end:l.start,l}function js(t,e){return e&&(t.bad=!0),t}function zs(t,e,n){var i;if(e==t.display.lineDiv){if(!(i=t.display.lineDiv.childNodes[n]))return js(t.clipPos(gt(t.display.viewTo-1)),!0);e=null,n=0}else for(i=e;;i=i.parentNode){if(!i||i==t.display.lineDiv)return null;if(i.parentNode&&i.parentNode==t.display.lineDiv)break}for(var r=0;r=e.display.viewTo||o.line=e.display.viewFrom&&Rs(e,r)||{node:l[0].measure.map[2],offset:0},u=o.linei.firstLine()&&(s=gt(s.line-1,at(i.doc,s.line-1).length)),a.ch==at(i.doc,a.line).text.length&&a.liner.viewTo-1)return!1;s.line==r.viewFrom||0==(t=ai(i,s.line))?(e=ht(r.view[0].line),n=r.view[0].node):(e=ht(r.view[t].line),n=r.view[t-1].node.nextSibling);var l,c,u=ai(i,a.line);if(u==r.view.length-1?(l=r.viewTo-1,c=r.lineDiv.lastChild):(l=ht(r.view[u+1].line)-1,c=r.view[u+1].node.previousSibling),!n)return!1;for(var h=i.doc.splitLines(function(t,e,n,i,r){var o="",s=!1,a=t.doc.lineSeparator(),l=!1;function c(){s&&(o+=a,l&&(o+=a),s=l=!1)}function u(t){t&&(c(),o+=t)}function h(e){if(1==e.nodeType){var n=e.getAttribute("cm-text");if(n)return void u(n);var o,d=e.getAttribute("cm-marker");if(d){var f=t.findMarks(gt(i,0),gt(r+1,0),function(t){return function(e){return e.id==t}}(+d));return void(f.length&&(o=f[0].find(0))&&u(lt(t.doc,o.from,o.to).join(a)))}if("false"==e.getAttribute("contenteditable"))return;var p=/^(pre|div|p|li|table|br)$/i.test(e.nodeName);if(!/^br$/i.test(e.nodeName)&&0==e.textContent.length)return;p&&c();for(var g=0;g1&&d.length>1;)if(G(h)==G(d))h.pop(),d.pop(),l--;else{if(h[0]!=d[0])break;h.shift(),d.shift(),e++}for(var f=0,p=0,g=h[0],v=d[0],m=Math.min(g.length,v.length);fs.ch&&y.charCodeAt(y.length-p-1)==b.charCodeAt(b.length-p-1);)f--,p++;h[h.length-1]=y.slice(0,y.length-p).replace(/^\u200b+/,""),h[0]=h[0].slice(f).replace(/\u200b+$/,"");var w=gt(e,f),C=gt(l,d.length?G(d).length-p:0);return h.length>1||h[0]||vt(w,C)?(co(i.doc,h,w,C,"+input"),!0):void 0},Fs.prototype.ensurePolled=function(){this.forceCompositionEnd()},Fs.prototype.reset=function(){this.forceCompositionEnd()},Fs.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Fs.prototype.readFromDOMSoon=function(){var t=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout(function(){if(t.readDOMTimeout=null,t.composing){if(!t.composing.done)return;t.composing=null}t.updateFromDOM()},80))},Fs.prototype.updateFromDOM=function(){var t=this;!this.cm.isReadOnly()&&this.pollContent()||Ki(this.cm,function(){return Ji(t.cm)})},Fs.prototype.setUneditable=function(t){t.contentEditable="false"},Fs.prototype.onKeyPress=function(t){0==t.charCode||this.composing||(t.preventDefault(),this.cm.isReadOnly()||Yi(this.cm,As)(this.cm,String.fromCharCode(null==t.charCode?t.keyCode:t.charCode),0))},Fs.prototype.readOnlyChanged=function(t){this.div.contentEditable=String("nocursor"!=t)},Fs.prototype.onContextMenu=function(){},Fs.prototype.resetPosition=function(){},Fs.prototype.needsContentAttribute=!0;var Hs=function(t){this.cm=t,this.prevInput="",this.pollingFast=!1,this.polling=new z,this.hasSelection=!1,this.composing=null};Hs.prototype.init=function(t){var e=this,n=this,i=this.cm;this.createField(t);var r=this.textarea;function o(t){if(!re(i,t)){if(i.somethingSelected())Ms({lineWise:!1,text:i.getSelections()});else{if(!i.options.lineWiseCopyCut)return;var e=_s(i);Ms({lineWise:!0,text:e.text}),"cut"==t.type?i.setSelections(e.ranges,null,B):(n.prevInput="",r.value=e.text.join("\n"),I(r))}"cut"==t.type&&(i.state.cutIncoming=!0)}}t.wrapper.insertBefore(this.wrapper,t.wrapper.firstChild),g&&(r.style.width="0px"),te(r,"input",function(){s&&a>=9&&e.hasSelection&&(e.hasSelection=null),n.poll()}),te(r,"paste",function(t){re(i,t)||Os(t,i)||(i.state.pasteIncoming=!0,n.fastPoll())}),te(r,"cut",o),te(r,"copy",o),te(t.scroller,"paste",function(e){wn(t,e)||re(i,e)||(i.state.pasteIncoming=!0,n.focus())}),te(t.lineSpace,"selectstart",function(e){wn(t,e)||le(e)}),te(r,"compositionstart",function(){var t=i.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:t,range:i.markText(t,i.getCursor("to"),{className:"CodeMirror-composing"})}}),te(r,"compositionend",function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)})},Hs.prototype.createField=function(t){this.wrapper=Ns(),this.textarea=this.wrapper.firstChild},Hs.prototype.prepareSelection=function(){var t=this.cm,e=t.display,n=t.doc,i=ci(t);if(t.options.moveInputWithCursor){var r=qn(t,n.sel.primary().head,"div"),o=e.wrapper.getBoundingClientRect(),s=e.lineDiv.getBoundingClientRect();i.teTop=Math.max(0,Math.min(e.wrapper.clientHeight-10,r.top+s.top-o.top)),i.teLeft=Math.max(0,Math.min(e.wrapper.clientWidth-10,r.left+s.left-o.left))}return i},Hs.prototype.showSelection=function(t){var e=this.cm,n=e.display;A(n.cursorDiv,t.cursors),A(n.selectionDiv,t.selection),null!=t.teTop&&(this.wrapper.style.top=t.teTop+"px",this.wrapper.style.left=t.teLeft+"px")},Hs.prototype.reset=function(t){if(!this.contextMenuPending&&!this.composing){var e=this.cm;if(e.somethingSelected()){this.prevInput="";var n=e.getSelection();this.textarea.value=n,e.state.focused&&I(this.textarea),s&&a>=9&&(this.hasSelection=n)}else t||(this.prevInput=this.textarea.value="",s&&a>=9&&(this.hasSelection=null))}},Hs.prototype.getField=function(){return this.textarea},Hs.prototype.supportsTouch=function(){return!1},Hs.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!m||L()!=this.textarea))try{this.textarea.focus()}catch(t){}},Hs.prototype.blur=function(){this.textarea.blur()},Hs.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},Hs.prototype.receivedFocus=function(){this.slowPoll()},Hs.prototype.slowPoll=function(){var t=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,function(){t.poll(),t.cm.state.focused&&t.slowPoll()})},Hs.prototype.fastPoll=function(){var t=!1,e=this;e.pollingFast=!0,e.polling.set(20,function n(){var i=e.poll();i||t?(e.pollingFast=!1,e.slowPoll()):(t=!0,e.polling.set(60,n))})},Hs.prototype.poll=function(){var t=this,e=this.cm,n=this.textarea,i=this.prevInput;if(this.contextMenuPending||!e.state.focused||xe(n)&&!i&&!this.composing||e.isReadOnly()||e.options.disableInput||e.state.keySeq)return!1;var r=n.value;if(r==i&&!e.somethingSelected())return!1;if(s&&a>=9&&this.hasSelection===r||y&&/[\uf700-\uf7ff]/.test(r))return e.display.input.reset(),!1;if(e.doc.sel==e.display.selForContextMenu){var o=r.charCodeAt(0);if(8203!=o||i||(i="​"),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var l=0,c=Math.min(i.length,r.length);l1e3||r.indexOf("\n")>-1?n.value=t.prevInput="":t.prevInput=r,t.composing&&(t.composing.range.clear(),t.composing.range=e.markText(t.composing.start,e.getCursor("to"),{className:"CodeMirror-composing"}))}),!0},Hs.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},Hs.prototype.onKeyPress=function(){s&&a>=9&&(this.hasSelection=null),this.fastPoll()},Hs.prototype.onContextMenu=function(t){var e=this,n=e.cm,i=n.display,r=e.textarea,o=si(n,t),c=i.scroller.scrollTop;if(o&&!h){var u=n.options.resetSelectionOnContextMenu;u&&-1==n.doc.sel.contains(o)&&Yi(n,Yr)(n.doc,xr(o),B);var d=r.style.cssText,f=e.wrapper.style.cssText;e.wrapper.style.cssText="position: absolute";var p,g=e.wrapper.getBoundingClientRect();if(r.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(t.clientY-g.top-5)+"px; left: "+(t.clientX-g.left-5)+"px;\n z-index: 1000; background: "+(s?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",l&&(p=window.scrollY),i.input.focus(),l&&window.scrollTo(null,p),i.input.reset(),n.somethingSelected()||(r.value=e.prevInput=" "),e.contextMenuPending=!0,i.selForContextMenu=n.doc.sel,clearTimeout(i.detectingSelectAll),s&&a>=9&&m(),k){he(t);var v=function(){ne(window,"mouseup",v),setTimeout(y,20)};te(window,"mouseup",v)}else setTimeout(y,50)}function m(){if(null!=r.selectionStart){var t=n.somethingSelected(),o="​"+(t?r.value:"");r.value="⇚",r.value=o,e.prevInput=t?"":"​",r.selectionStart=1,r.selectionEnd=o.length,i.selForContextMenu=n.doc.sel}}function y(){if(e.contextMenuPending=!1,e.wrapper.style.cssText=f,r.style.cssText=d,s&&a<9&&i.scrollbars.setScrollTop(i.scroller.scrollTop=c),null!=r.selectionStart){(!s||s&&a<9)&&m();var t=0,o=function(){i.selForContextMenu==n.doc.sel&&0==r.selectionStart&&r.selectionEnd>0&&"​"==e.prevInput?Yi(n,no)(n):t++<10?i.detectingSelectAll=setTimeout(o,500):(i.selForContextMenu=null,i.input.reset())};i.detectingSelectAll=setTimeout(o,200)}}},Hs.prototype.readOnlyChanged=function(t){t||this.reset(),this.textarea.disabled="nocursor"==t},Hs.prototype.setUneditable=function(){},Hs.prototype.needsContentAttribute=!1,function(t){var e=t.optionHandlers;function n(n,i,r,o){t.defaults[n]=i,r&&(e[n]=o?function(t,e,n){n!=ms&&r(t,e,n)}:r)}t.defineOption=n,t.Init=ms,n("value","",function(t,e){return t.setValue(e)},!0),n("mode",null,function(t,e){t.doc.modeOption=e,Tr(t)},!0),n("indentUnit",2,Tr,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,function(t){Er(t),zn(t),Ji(t)},!0),n("lineSeparator",null,function(t,e){if(t.doc.lineSep=e,e){var n=[],i=t.doc.first;t.doc.iter(function(t){for(var r=0;;){var o=t.text.indexOf(e,r);if(-1==o)break;r=o+e.length,n.push(gt(i,o))}i++});for(var r=n.length-1;r>=0;r--)co(t.doc,e,n[r],gt(n[r].line,n[r].ch+e.length))}}),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b-\u200f\u2028\u2029\ufeff]/g,function(t,e,n){t.state.specialChars=new RegExp(e.source+(e.test("\t")?"":"|\t"),"g"),n!=ms&&t.refresh()}),n("specialCharPlaceholder",Je,function(t){return t.refresh()},!0),n("electricChars",!0),n("inputStyle",m?"contenteditable":"textarea",function(){throw new Error("inputStyle can not (yet) be changed in a running editor")},!0),n("spellcheck",!1,function(t,e){return t.getInputField().spellcheck=e},!0),n("rtlMoveVisually",!x),n("wholeLineUpdateBefore",!0),n("theme","default",function(t){vs(t),xs(t)},!0),n("keyMap","default",function(t,e,n){var i=Uo(e),r=n!=ms&&Uo(n);r&&r.detach&&r.detach(t,i),i.attach&&i.attach(t,r||null)}),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,Cs,!0),n("gutters",[],function(t){hr(t.options),xs(t)},!0),n("fixedGutter",!0,function(t,e){t.display.gutters.style.left=e?ii(t.display)+"px":"0",t.refresh()},!0),n("coverGutterNextToScrollbar",!1,function(t){return Ii(t)},!0),n("scrollbarStyle","native",function(t){ji(t),Ii(t),t.display.scrollbars.setScrollTop(t.doc.scrollTop),t.display.scrollbars.setScrollLeft(t.doc.scrollLeft)},!0),n("lineNumbers",!1,function(t){hr(t.options),xs(t)},!0),n("firstLineNumber",1,xs,!0),n("lineNumberFormatter",function(t){return t},xs,!0),n("showCursorWhenSelecting",!1,li,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("readOnly",!1,function(t,e){"nocursor"==e&&(mi(t),t.display.input.blur()),t.display.input.readOnlyChanged(e)}),n("disableInput",!1,function(t,e){e||t.display.input.reset()},!0),n("dragDrop",!0,ws),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,li,!0),n("singleCursorHeightPerLine",!0,li,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,Er,!0),n("addModeClass",!1,Er,!0),n("pollInterval",100),n("undoDepth",200,function(t,e){return t.doc.history.undoDepth=e}),n("historyEventDelay",1250),n("viewportMargin",10,function(t){return t.refresh()},!0),n("maxHighlightLength",1e4,Er,!0),n("moveInputWithCursor",!0,function(t,e){e||t.display.input.resetPosition()}),n("tabindex",null,function(t,e){return t.display.input.getField().tabIndex=e||""}),n("autofocus",null),n("direction","ltr",function(t,e){return t.doc.setDirection(e)},!0)}(ks),function(t){var e=t.optionHandlers,n=t.helpers={};t.prototype={constructor:t,focus:function(){window.focus(),this.display.input.focus()},setOption:function(t,n){var i=this.options,r=i[t];i[t]==n&&"mode"!=t||(i[t]=n,e.hasOwnProperty(t)&&Yi(this,e[t])(this,n,r),ie(this,"optionChange",this,t))},getOption:function(t){return this.options[t]},getDoc:function(){return this.doc},addKeyMap:function(t,e){this.state.keyMaps[e?"push":"unshift"](Uo(t))},removeKeyMap:function(t){for(var e=this.state.keyMaps,n=0;nn&&(Ts(this,r.head.line,t,!0),n=r.head.line,i==this.doc.sel.primIndex&&Ti(this));else{var o=r.from(),s=r.to(),a=Math.max(n,o.line);n=Math.min(this.lastLine(),s.line-(s.ch?0:1))+1;for(var l=a;l0&&Ur(this.doc,i,new yr(o,c[i].to()),B)}}}),getTokenAt:function(t,e){return $e(this,t,e)},getLineTokens:function(t,e){return $e(this,gt(t),e,!0)},getTokenTypeAt:function(t){t=Ct(this.doc,t);var e,n=Fe(this,at(this.doc,t.line)),i=0,r=(n.length-1)/2,o=t.ch;if(0==o)e=n[2];else for(;;){var s=i+r>>1;if((s?n[2*s-1]:0)>=o)r=s;else{if(!(n[2*s+1]o&&(t=o,r=!0),i=at(this.doc,t)}else i=t;return Bn(this,i,{top:0,left:0},e||"page",n||r).top+(r?this.doc.height-qt(i):0)},defaultTextHeight:function(){return ti(this.display)},defaultCharWidth:function(){return ei(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(t,e,n,i,r){var o=this.display,s=(t=qn(this,Ct(this.doc,t))).bottom,a=t.left;if(e.style.position="absolute",e.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(e),o.sizer.appendChild(e),"over"==i)s=t.top;else if("above"==i||"near"==i){var l=Math.max(o.wrapper.clientHeight,this.doc.height),c=Math.max(o.sizer.clientWidth,o.lineSpace.clientWidth);("above"==i||t.bottom+e.offsetHeight>l)&&t.top>e.offsetHeight?s=t.top-e.offsetHeight:t.bottom+e.offsetHeight<=l&&(s=t.bottom),a+e.offsetWidth>c&&(a=c-e.offsetWidth)}e.style.top=s+"px",e.style.left=e.style.right="","right"==r?(a=o.sizer.clientWidth-e.offsetWidth,e.style.right="0px"):("left"==r?a=0:"middle"==r&&(a=(o.sizer.clientWidth-e.offsetWidth)/2),e.style.left=a+"px"),n&&function(t,e){var n=ki(t,e);null!=n.scrollTop&&Oi(t,n.scrollTop),null!=n.scrollLeft&&_i(t,n.scrollLeft)}(this,{left:a,top:s,right:a+e.offsetWidth,bottom:s+e.offsetHeight})},triggerOnKeyDown:Gi(os),triggerOnKeyPress:Gi(as),triggerOnKeyUp:ss,triggerOnMouseDown:Gi(hs),execCommand:function(t){if(Xo.hasOwnProperty(t))return Xo[t].call(null,this)},triggerElectric:Gi(function(t){Ps(this,t)}),findPosH:function(t,e,n,i){var r=1;e<0&&(r=-1,e=-e);for(var o=Ct(this.doc,t),s=0;s0&&a(n.charAt(i-1));)--i;for(;r.5)&&oi(this),ie(this,"refresh",this)}),swapDoc:Gi(function(t){var e=this.doc;return e.cm=null,Pr(this,t),zn(this),this.display.input.reset(),Ei(this,t.scrollLeft,t.scrollTop),this.curOp.forceScroll=!0,an(this,"swapDoc",this,e),e}),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(t),t.registerHelper=function(e,i,r){n.hasOwnProperty(e)||(n[e]=t[e]={_global:[]}),n[e][i]=r},t.registerGlobalHelper=function(e,i,r,o){t.registerHelper(e,i,o),n[e]._global.push({pred:r,val:o})}}(ks);var $s="iter insert remove copy getEditor constructor".split(" ");for(var Bs in Eo.prototype)Eo.prototype.hasOwnProperty(Bs)&&V($s,Bs)<0&&(ks.prototype[Bs]=function(t){return function(){return t.apply(this.doc,arguments)}}(Eo.prototype[Bs]));return ae(Eo),ks.inputStyles={textarea:Hs,contenteditable:Fs},ks.defineMode=function(t){ks.defaults.mode||"null"==t||(ks.defaults.mode=t),function(t,e){arguments.length>2&&(e.dependencies=Array.prototype.slice.call(arguments,2)),ke[t]=e}.apply(this,arguments)},ks.defineMIME=function(t,e){Se[t]=e},ks.defineMode("null",function(){return{token:function(t){return t.skipToEnd()}}}),ks.defineMIME("text/plain","null"),ks.defineExtension=function(t,e){ks.prototype[t]=e},ks.defineDocExtension=function(t,e){Eo.prototype[t]=e},ks.fromTextArea=function(t,e){if((e=e?R(e):{}).value=t.value,!e.tabindex&&t.tabIndex&&(e.tabindex=t.tabIndex),!e.placeholder&&t.placeholder&&(e.placeholder=t.placeholder),null==e.autofocus){var n=L();e.autofocus=n==t||null!=t.getAttribute("autofocus")&&n==document.body}function i(){t.value=a.getValue()}var r;if(t.form&&(te(t.form,"submit",i),!e.leaveSubmitMethodAlone)){var o=t.form;r=o.submit;try{var s=o.submit=function(){i(),o.submit=r,o.submit(),o.submit=s}}catch(t){}}e.finishInit=function(e){e.save=i,e.getTextArea=function(){return t},e.toTextArea=function(){e.toTextArea=isNaN,i(),t.parentNode.removeChild(e.getWrapperElement()),t.style.display="",t.form&&(ne(t.form,"submit",i),"function"==typeof t.form.submit&&(t.form.submit=r))}},t.style.display="none";var a=ks(function(e){return t.parentNode.insertBefore(e,t.nextSibling)},e);return a},function(t){t.off=ne,t.on=te,t.wheelEventPixels=gr,t.Doc=Eo,t.splitLines=be,t.countColumn=j,t.findColumn=q,t.isWordChar=tt,t.Pass=$,t.signal=ie,t.Line=Ue,t.changeEnd=wr,t.scrollbarModel=Ri,t.Pos=gt,t.cmpPos=vt,t.modes=ke,t.mimeModes=Se,t.resolveMode=Te,t.getMode=Ee,t.modeExtensions=Me,t.extendMode=Ae,t.copyState=Oe,t.startState=_e,t.innerMode=Pe,t.commands=Xo,t.keyMap=jo,t.keyName=Wo,t.isModifierKey=$o,t.lookupKey=Ho,t.normalizeKeyMap=Vo,t.StringStream=Le,t.SharedTextMarker=Co,t.TextMarker=xo,t.LineWidget=mo,t.e_preventDefault=le,t.e_stopPropagation=ce,t.e_stop=he,t.addClass=N,t.contains=_,t.rmClass=E,t.keyNames=Do}(ks),ks.version="5.39.0",ks}()},function(t,e,n){"use strict";var i=o(n(1)),r=o(n(0));function o(t){return t&&t.__esModule?t:{default:t}}var s=n(13),a=r.default.$;t.exports=i.default.extend({},s,{init:function(t){i.default.bindAll(this,"startDraw","draw","endDraw","rollback"),this.config=t||{},this.hType=this.config.newFixedH?"height":"min-height",this.allowDraw=1},enable:function(){for(var t=arguments.length,e=Array(t),n=0;n1&&void 0!==arguments[1]?arguments[1]:{};if(t){var n=e.ctrlKey||e.metaKey,i=e.shiftKey,r=this.editor,s=r.getConfig("multipleSelection"),a=this.em;if(n&&s)r.selectToggle(t);else if(i&&s){a.clearSelection(r.Canvas.getWindow());var l=t.collection,c=l.indexOf(t),u=(r.getSelectedAll(),void 0),h=void 0;if(r.getSelectedAll().forEach(function(t){var e=t.collection,n=e.indexOf(t);e===l&&(nc&&(h=(0,o.isUndefined)(h)?n:Math.min(h,n)))}),!(0,o.isUndefined)(u))for(;u!==c;)r.selectAdd(l.at(u)),u++;if(!(0,o.isUndefined)(h))for(;h!==c;)r.selectAdd(l.at(h)),h--;r.selectAdd(t)}else r.select(t);this.initResize(t)}},updateBadge:function(t,e){var n=c(t),i=this.canvas,r=i.getConfig().customBadgeLabel;this.cacheEl=t;var o=n.data("model");if(o&&o.get("badgable")){var s=this.getBadge(),a=o.getIcon()+o.getName();a=r?r(o):a,s.innerHTML=a;var l=s.style;l.display="block";var u=i.getCanvasView().getPosition();if(u){var h=s?s.offsetHeight:0,d=s?s.offsetWidth:0,f=e.top-h1&&void 0!==arguments[1]?arguments[1]:{},i=n.el,r=n.config,o=n.resizer,a=r.keyHeight,l=r.keyWidth,h=r.currentUnit;g("add",0,n),p=e.get("StyleManager").getModelToStyle(c);var d=getComputedStyle(i),f=p.getStyle(),v=f[l]||d[l],m=f[a]||d[a];o.startDim.w=parseFloat(v),o.startDim.h=parseFloat(m),u=0,h&&(r.unitHeight=(0,s.getUnitFromValue)(m),r.unitWidth=(0,s.getUnitFromValue)(v))},onMove:function(){n.trigger("change:canvasOffset")},onEnd:function(t,e){g("remove",0,e),n.trigger("change:canvasOffset"),u=1},updateTarget:function(t,n){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(p){var r=i.store,o=i.selectedHandler,s=i.config,a=s.keyHeight,l=s.keyWidth,c=["tc","bc"].indexOf(o)>=0,u=["cl","cr"].indexOf(o)>=0,h=p.getStyle();c||(h[l]=n.w+s.unitWidth),u||(h[a]=n.h+s.unitHeight),p.setStyle(h,{avoidStore:1});e&&e.trigger("update:component:style:"+a+" update:component:style:"+l),r&&p.trigger("change:style",p,h,{})}}},"object"==(void 0===h?"undefined":r(h))&&(f=i({},f,h)),n.runCommand("resize",{el:d,options:f})):n.stopCommand("resize")},updateToolbar:function(t){var e=this,n=this.config.em,i=t==n?n.getSelected():t,r=this.canvas.getToolbarEl(),o=r.style;if(i){var s=i.get("toolbar");this.ppfx;if(n.get("Config").showToolbar&&s&&s.length){if(o.opacity="",o.display="",!this.toolbar){r.innerHTML="",this.toolbar=new l(s);var c=new a({collection:this.toolbar,editor:this.editor});r.appendChild(c.render().el)}this.toolbar.reset(s);var u=i.view;o.top="-100px",o.left=0,setTimeout(function(){return u&&e.updateToolbarPos(u.el)},0)}else o.display="none"}else o.opacity=0},updateToolbarPos:function(t,e){var n=this.canvas.getToolbarEl(),i=n.style;i.opacity=0;var r=this.canvas.getTargetToElementDim(n,t,{elPos:e,event:"toolbarPosUpdate"});if(r){var o=r.left+r.elementWidth-r.targetWidth;i.top=r.top+"px",i.left=(o<0?0:o)+"px",i.opacity=""}},getCanvasPosition:function(){return this.canvas.getCanvasView().getPosition()},clean:function(){this.selEl&&this.selEl.removeClass(this.hoverClass)},getBadge:function(){return this.canvas.getBadgeEl()},onFrameScroll:function(t){var e=this.cacheEl;if(e){var n=this.getElementPos(e);this.updateBadge(e,n);var i=this.em.getSelected();i&&this.updateToolbarPos(i.view.el)}},updateAttached:function(t){var e=this.em.getSelected();if(e){var n=e.view;this.updateToolbarPos(n.el),this.showFixedElementOffset(n.el)}},getElementPos:function(t,e){return this.canvas.getCanvasView().getElementPos(t)},hideBadge:function(){this.getBadge().style.display="none"},cleanPrevious:function(t){t&&t.set({status:"",state:""})},getContentWindow:function(){return this.frameEl.contentWindow},run:function(t){this.editor=t&&t.get("Editor"),this.enable(),this.onSelect()},stop:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=this.em;this.stopSelectComponent(),!n.preserveSelected&&i.setSelected(null),this.clean(),this.hideBadge(),this.hideFixedElementOffset(),this.canvas.getToolbarEl().style.display="none",i.off("component:update",this.updateAttached,this),i.off("change:canvasOffset",this.updateAttached,this)}}},function(t,e,n){"use strict";var i=n(1),r=n(0),o=r.$;t.exports=r.View.extend({events:{change:"onChange"},attributes:function(){return this.model.get("attributes")},initialize:function(t){var e=this.model,n=(e.get("name"),e.target);this.config=t.config||{},this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.target=n,this.className=this.pfx+"trait",this.labelClass=this.ppfx+"label",this.fieldClass=this.ppfx+"field "+this.ppfx+"field-"+e.get("type"),this.inputhClass=this.ppfx+"input-holder",e.off("change:value",this.onValueChange),this.listenTo(e,"change:value",this.onValueChange),e.view=this,this.tmpl='
'},onChange:function(){this.model.set("value",this.getInputEl().value)},getValueForTarget:function(){return this.model.get("value")},setInputValue:function(t){this.getInputEl().value=t},onValueChange:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=this.model;this.target,i.get("name");if(n.fromTarget)this.setInputValue(i.get("value"));else{var r=this.getValueForTarget();i.setTargetValue(r,n)}},renderLabel:function(){var t=this.getLabel();this.$el.html('
'+t+"
")},getLabel:function(){var t=this.model,e=t.get("label")||t.get("name");return e.charAt(0).toUpperCase()+e.slice(1).replace(/-/g," ")},getInputEl:function(){if(!this.$input){var t=this.model,e=t.get("placeholder")||t.get("default")||"",n=t.get("type")||"text",i=t.get("min"),r=t.get("max"),s=this.getModelValue(),a=o('');s&&(t.set({value:s},{silent:!0}),a.prop("value",s)),i&&a.prop("min",i),r&&a.prop("max",r),this.$input=a}return this.$input.get(0)},getModelValue:function(){var t=void 0,e=this.model,n=this.target,r=e.get("name");if(e.get("changeProp"))t=n.get(r);else{var o=n.get("attributes");t=e.get("value")||o[r]}return(0,i.isUndefined)(t)?"":t},renderField:function(){if(!this.$input){this.$el.append(this.tmpl);var t=this.getInputEl(),e=this.el.querySelector("."+this.inputhClass);e.insertBefore(t,e.childNodes[0])}},render:function(){return this.renderLabel(),this.renderField(),this.el.className=this.className,this}})},function(t,e,n){"use strict";var i=n(0).Model.extend({idAttribute:"name",defaults:{name:"",label:"",type:1,active:!0,private:!1,protected:!1},initialize:function(){var t=this.get("name"),e=this.get("label");t?e||this.set("label",t):this.set("name",e),this.set("name",i.escapeName(this.get("name")))},getFullName:function(){var t="";switch(this.get("type")){case 1:t=".";break;case 2:t="#"}return t+this.get("name")}},{TYPE_CLASS:1,TYPE_ID:2,escapeName:function(t){return(""+t).trim().replace(/([^a-z0-9\w-]+)/gi,"-")}});t.exports=i},function(t,e){var n;n=function(){return this}();try{n=n||Function("return this")()||(0,eval)("this")}catch(t){"object"==typeof window&&(n=window)}t.exports=n},function(t,e,n){"use strict";var i=r(n(1));r(n(0));function r(t){return t&&t.__esModule?t:{default:t}}var o=n(7);t.exports=i.default.extend({},o,{init:function(){for(var t=arguments.length,e=Array(t),n=0;n0&&void 0!==arguments[0]?arguments[0]:{};return this.set({value:void 0},t),this},setValue:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=this.parseValue(t);this.set(r,i({},n,{avoidStore:1})),e&&(this.set("value","",n),this.set(r,n))},setValueFromInput:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};this.setValue(t,e,i({},n,{fromInput:1}))},parseValue:function(t){var e={value:t},n="!important";if((0,r.isString)(t)&&-1!==t.indexOf(n)&&(e.value=t.replace(n,"").trim(),e.important=1),!this.get("functionName"))return e;var i=[],o=""+e.value,s=o.indexOf("(")+1,a=o.lastIndexOf(")");return i.push(s),a>=0&&i.push(a),e.value=String.prototype.substring.apply(o,i),e},getDefaultValue:function(){return this.get("defaults")},getFullValue:function(t){var e=this.get("functionName"),n=(0,r.isUndefined)(t)?this.get("value"):t;return e&&!(0,r.isUndefined)(n)&&(n=e+"("+n+")"),this.get("important")&&(n+=" !important"),n||""}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e/,f=/^\w+$/;function p(t,n){n=n||e;var i=h.test(t)?n.getElementsByClassName(t.slice(1)):f.test(t)?n.getElementsByTagName(t):n.querySelectorAll(t);return i}function g(n){if(!t){var i=(t=e.implementation.createHTMLDocument(null)).createElement("base");i.href=e.location.href,t.head.appendChild(i)}return t.body.innerHTML=n,t.body.childNodes}function v(t){"loading"!==e.readyState?setTimeout(t):e.addEventListener("DOMContentLoaded",t)}function m(t,i){if(!t)return this;if(t.cash&&t!==n)return t;var r,o=t,s=0;if(c(t))o=u.test(t)?e.getElementById(t.slice(1)):d.test(t)?g(t):p(t,i);else if(l(t))return v(t),this;if(!o)return this;if(o.nodeType||o===n)this[0]=o,this.length=1;else for(r=this.length=o.length;s=0&&o.splice(i,1)):(x(o,function(n){t.removeEventListener(e,n)}),o=[]))}function R(t,e){return"&"+encodeURIComponent(t)+"="+encodeURIComponent(e).replace(/%20/g,"+")}function j(t){var e=t.type;if(!e)return null;switch(e.toLowerCase()){case"select-one":return function(t){var e=t.selectedIndex;return e>=0?t.options[e].value:null}(t);case"select-multiple":return function(t){var e=[];return x(t.options,function(t){t.selected&&e.push(t.value)}),e.length?e:null}(t);case"radio":case"checkbox":return t.checked?t.value:null;default:return t.value?t.value:null}}function z(t,e,n){var i=c(e);i||!e.length?x(t,i?function(t){return t.insertAdjacentHTML(n?"afterbegin":"beforeend",e)}:function(t,i){return function(t,e,n){if(n){var i=t.childNodes[0];t.insertBefore(e,i)}else t.appendChild(e)}(t,0===i?e:e.cloneNode(!0),n)}):x(e,function(e){return z(t,e,n)})}y.prefixedProp=D,y.camelCase=N,b.extend({css:function(t,e){if(c(t))return t=D(t),arguments.length>1?this.each(function(n){return n.style[t]=e}):n.getComputedStyle(this[0])[t];for(var i in t)this.css(i,t[i]);return this}}),x(["Width","Height"],function(t){var e=t.toLowerCase();b[e]=function(){return this[0].getBoundingClientRect()[e]},b["inner"+t]=function(){return this[0]["client"+t]},b["outer"+t]=function(e){return this[0]["offset"+t]+(e?I(this,"margin"+("Width"===t?"Left":"Top"))+I(this,"margin"+("Width"===t?"Right":"Bottom")):0)}}),b.extend({off:function(t,e){return this.each(function(n){return F(n,t,e)})},on:function(t,e,n,i){var r;if(!c(t)){for(var o in t)this.on(o,e,t[o]);return this}return l(e)&&(n=e,e=null),"ready"===t?(v(n),this):(e&&(r=n,n=function(t){for(var n=t.target;!w(n,e);){if(n===this)return n=!1;n=n.parentNode}n&&r.call(n,t)}),this.each(function(e){var r=n;i&&(r=function(){n.apply(this,arguments),F(e,t,r)}),function(t,e,n){var i=M(t,"_cashEvents")||E(t,"_cashEvents",{});i[e]=i[e]||[],i[e].push(n),t.addEventListener(e,n)}(e,t,r)}))},one:function(t,e,n){return this.on(t,e,n,!0)},ready:v,trigger:function(t,n){var i=e.createEvent("HTMLEvents");return i.data=n,i.initEvent(t,!0,!1),this.each(function(t){return t.dispatchEvent(i)})}}),b.extend({serialize:function(){var t="";return x(this[0].elements||this,function(e){if(!e.disabled&&"FIELDSET"!==e.tagName){var n=e.name;switch(e.type.toLowerCase()){case"file":case"reset":case"submit":case"button":break;case"select-multiple":var i=j(e);null!==i&&x(i,function(e){t+=R(n,e)});break;default:var r=j(e);null!==r&&(t+=R(n,r))}}}),t.substr(1)},val:function(t){return void 0===t?j(this[0]):this.each(function(e){return e.value=t})}}),b.extend({after:function(t){return y(t).insertAfter(this),this},append:function(t){return z(this,t),this},appendTo:function(t){return z(y(t),this),this},before:function(t){return y(t).insertBefore(this),this},clone:function(){return y(this.map(function(t){return t.cloneNode(!0)}))},empty:function(){return this.html(""),this},html:function(t){if(void 0===t)return this[0].innerHTML;var e=t.nodeType?t[0].outerHTML:t;return this.each(function(t){return t.innerHTML=e})},insertAfter:function(t){var e=this;return y(t).each(function(t,n){var i=t.parentNode,r=t.nextSibling;e.each(function(t){i.insertBefore(0===n?t:t.cloneNode(!0),r)})}),this},insertBefore:function(t){var e=this;return y(t).each(function(t,n){var i=t.parentNode;e.each(function(e){i.insertBefore(0===n?e:e.cloneNode(!0),t)})}),this},prepend:function(t){return z(this,t,!0),this},prependTo:function(t){return z(y(t),this,!0),this},remove:function(){return this.each(function(t){return t.parentNode.removeChild(t)})},text:function(t){return void 0===t?this[0].textContent:this.each(function(e){return e.textContent=t})}});var V=e.documentElement;return b.extend({position:function(){var t=this[0];return{left:t.offsetLeft,top:t.offsetTop}},offset:function(){var t=this[0].getBoundingClientRect();return{top:t.top+n.pageYOffset-V.clientTop,left:t.left+n.pageXOffset-V.clientLeft}},offsetParent:function(){return y(this[0].offsetParent)}}),b.extend({children:function(t){var e=[];return this.each(function(t){s.apply(e,t.children)}),e=k(e),t?e.filter(function(e){return w(e,t)}):e},closest:function(t){return!t||this.length<1?y():this.is(t)?this.filter(t):this.parent().closest(t)},is:function(t){if(!t)return!1;var e=!1,n=C(t);return this.each(function(i){return!(e=n(i,t))}),e},find:function(t){if(!t||t.nodeType)return y(t&&this.has(t).length?t:null);var e=[];return this.each(function(n){s.apply(e,p(t,n))}),k(e)},has:function(t){var e=c(t)?function(e){return 0!==p(t,e).length}:function(e){return e.contains(t)};return this.filter(e)},next:function(){return y(this[0].nextElementSibling)},not:function(t){if(!t)return this;var e=C(t);return this.filter(function(n){return!e(n,t)})},parent:function(){var t=[];return this.each(function(e){e&&e.parentNode&&t.push(e.parentNode)}),k(t)},parents:function(t){var n,i=[];return this.each(function(r){for(n=r;n&&n.parentNode&&n!==e.body.parentNode;)n=n.parentNode,(!t||t&&w(n,t))&&i.push(n)}),k(i)},prev:function(){return y(this[0].previousElementSibling)},siblings:function(){var t=this.parent().children(),e=this[0];return t.filter(function(t){return t!==e})}}),y})?i.call(e,n,e,t):i)||(t.exports=r)},function(t,e,n){"use strict";t.exports={run:function(t,e,n){var i=n&&n.el||"",r=t.Canvas,o=this.dragger,s=n.options||{},a=r.getCanvasView();return s.prefix=t.getConfig().stylePrefix,s.mousePosFetcher=r.getMouseRelativePos,s.posFetcher=a.getElementPos.bind(a),o||(o=t.Utils.Dragger.init(s),this.dragger=o),o.setOptions(s),o.focus(i),s.event&&o.start(s.event),o},stop:function(){this.canvasResizer&&this.canvasResizer.blur()}}},function(t,e,n){"use strict";t.exports={run:function(t,e,n){var i=n||{},r=i.el||"",o=t.Canvas,s=this.canvasResizer,a=i.options||{},l=o.getCanvasView();return a.ratioDefault=1,a.appendTo=o.getResizerEl(),a.prefix=t.getConfig().stylePrefix,a.posFetcher=l.getElementPos.bind(l),a.mousePosFetcher=o.getMouseRelativePos,s&&!i.forceNew||(this.canvasResizer=t.Utils.Resizer.init(a),s=this.canvasResizer),s.setOptions(a),s.blur(),s.focus(r),s},stop:function(){var t=this.canvasResizer;t&&t.blur()}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(1));t.exports={getPanels:function(t){return this.panels||(this.panels=t.Panels.getPanelsEl()),this.panels},tglPointers:function(t,e){var n=t.Canvas.getBody().querySelectorAll("."+this.ppfx+"no-pointer");i.default.each(n,function(t){t.style.pointerEvents=e?"":"all"})},run:function(t,e){e&&e.set&&e.set("active",!1),t.stopCommand("sw-visibility"),t.getModel().stopDefault();var n=this.getPanels(t),i=t.Canvas.getElement(),r=t.getEl(),o=t.Config.stylePrefix;this.helper||(this.helper=document.createElement("span"),this.helper.className=o+"off-prv fa fa-eye-slash",r.appendChild(this.helper),this.helper.onclick=function(){t.stopCommand("preview")}),this.helper.style.display="inline-block",this.tglPointers(t),n.style.display="none";var s=i.style;s.width="100%",s.height="100%",s.top="0",s.left="0",s.padding="0",s.margin="0",t.trigger("change:canvasOffset")},stop:function(t,e){var n=this.getPanels(t);t.runCommand("sw-visibility"),t.getModel().runDefault(),n.style.display="block",t.Canvas.getElement().setAttribute("style",""),this.helper&&(this.helper.style.display="none"),t.trigger("change:canvasOffset"),this.tglPointers(t,1)}}},function(t,e,n){"use strict";t.exports={isEnabled:function(){var t=document;return t.fullscreenElement||t.webkitFullscreenElement||t.mozFullScreenElement?1:0},enable:function(t){var e="";return t.requestFullscreen?t.requestFullscreen():t.webkitRequestFullscreen?(e="webkit",t.webkitRequestFullscreen()):t.mozRequestFullScreen?(e="moz",t.mozRequestFullScreen()):t.msRequestFullscreen?t.msRequestFullscreen():console.warn("Fullscreen not supported"),e},disable:function(){var t=document;t.exitFullscreen?t.exitFullscreen():t.webkitExitFullscreen?t.webkitExitFullscreen():t.mozCancelFullScreen?t.mozCancelFullScreen():t.msExitFullscreen&&t.msExitFullscreen()},fsChanged:function(t,e){document;var n=(t||"")+"fullscreenchange";this.isEnabled()||(this.stop(null,this.sender),document.removeEventListener(n,this.fsChanged))},run:function(t,e){this.sender=e;var n=this.enable(t.getContainer());this.fsChanged=this.fsChanged.bind(this,n),document.addEventListener(n+"fullscreenchange",this.fsChanged),t&&t.trigger("change:canvasOffset")},stop:function(t,e){e&&e.set&&e.set("active",!1),this.disable(),t&&t.trigger("change:canvasOffset")}}},function(t,e,n){"use strict";t.exports={run:function(t){for(var e=t.getSelected(),n=e&&e.parent();n&&!n.get("selectable");)n=n.parent();n&&t.select(n)}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)).default.$;t.exports={getOffsetMethod:function(t){return"get"+(t||"")+"OffsetViewerEl"},run:function(t,e,n){var r=n||{},o=r.state||"",s=t.getConfig();if(s.showOffsets&&(s.showOffsetsSelected||"Fixed"!=o)){var a=t.Canvas,l=r.el||"",c=r.elPos||a.getElementPos(l),u=window.getComputedStyle(l),h=this.ppfx,d=o+"State",f=a[this.getOffsetMethod(o)]();f.style.display="block";var p=this["marginT"+o],g=this["marginB"+o],v=this["marginL"+o],m=this["marginR"+o],y=this["padT"+o],b=this["padB"+o],x=this["padL"+o],w=this["padR"+o];if(!this[d]){var C=o.toLowerCase(),k=C+"margin-v",S=C+"padding-v",T=i('
').get(0),E=i('
').get(0),M=h+k+"-el"+" "+(h+k),A=h+S+"-el"+" "+(h+S);p=i('
').get(0),g=i('
').get(0),v=i('
').get(0),m=i('
').get(0),y=i('
').get(0),b=i('
').get(0),x=i('
').get(0),w=i('
').get(0),this["marginT"+o]=p,this["marginB"+o]=g,this["marginL"+o]=v,this["marginR"+o]=m,this["padT"+o]=y,this["padB"+o]=b,this["padL"+o]=x,this["padR"+o]=w,T.appendChild(p),T.appendChild(g),T.appendChild(v),T.appendChild(m),E.appendChild(y),E.appendChild(b),E.appendChild(x),E.appendChild(w),f.appendChild(T),f.appendChild(E),this[d]="1"}var O=u.marginLeft.replace("px",""),P=parseInt(u.marginTop.replace("px","")),_=parseInt(u.marginBottom.replace("px","")),L=p.style,N=g.style,D=v.style,I=m.style,F=y.style,R=b.style,j=x.style,z=w.style,V=parseInt(c.left);L.height=u.marginTop,L.width=u.width,L.top=c.top-u.marginTop.replace("px","")+"px",L.left=V+"px",N.height=u.marginBottom,N.width=u.width,N.top=c.top+c.height+"px",N.left=V+"px";var H=c.height+P+_+"px",$=c.top-P+"px";D.height=H,D.width=u.marginLeft,D.top=$,D.left=V-O+"px",I.height=H,I.width=u.marginRight,I.top=$,I.left=V+c.width+"px";var B=parseInt(u.paddingTop.replace("px",""));F.height=u.paddingTop,F.width=u.width,F.top=c.top+"px",F.left=V+"px";var W=parseInt(u.paddingBottom.replace("px",""));R.height=u.paddingBottom,R.width=u.width,R.top=c.top+c.height-W+"px",R.left=V+"px";var U=c.height-W-B+"px",q=c.top+B+"px";j.height=U,j.width=u.paddingLeft,j.top=q,j.left=c.left+"px";var K=parseInt(u.paddingRight.replace("px",""));z.height=U,z.width=u.paddingRight,z.top=q,z.left=c.left+c.width-K+"px"}},stop:function(t,e,n){var i=(n||{}).state||"",r=this.getOffsetMethod(i);t.Canvas[r]().style.display="none"}}},function(t,e,n){"use strict";t.exports={run:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=t.Modal,r=t.AssetManager,o=r.getConfig(),s=r.getContainer(),a=n.modalTitle||o.modalTitle||"",l=n.types,c=n.accept;if(r.setTarget(n.target),r.onClick(n.onClick),r.onDblClick(n.onDblClick),r.onSelect(n.onSelect),!this.rendered||l){var u=r.getAll();l&&(u=u.filter(function(t){return-1!==l.indexOf(t.get("type"))})),r.render(u),this.rendered=1}if(c){var h=s.querySelector("input#"+o.stylePrefix+"uploadFile");h&&h.setAttribute("accept",c)}i.setTitle(a),i.setContent(s),i.open()}}},function(t,e,n){"use strict";t.exports={run:function(t,e){var n=t.BlockManager,i=t.Panels;if(!this.blocks){n.render();var r="views-container",o=document.createElement("div"),s=i.getPanel(r)||i.addPanel({id:r});o.appendChild(n.getContainer()),s.set("appendContent",o).trigger("change:appendContent"),this.blocks=o}this.blocks.style.display="block"},stop:function(){var t=this.blocks;t&&(t.style.display="none")}}},function(t,e,n){"use strict";var i=n(0).$;t.exports={run:function(t,e){this.sender=e;var n=t.Config.stylePrefix,r=t.TraitManager;if(!this.$cn){var o=r.getTraitsViewer(),s=r.getConfig();this.$cn=i("
"),this.$cn2=i("
"),this.$cn.append(this.$cn2),this.$header=i("
").append('
'+s.textNoElement+"
"),this.$cn.append(this.$header),this.$cn2.append('
'+s.labelContainer+"
"),this.$cn2.append(o.render().el);var a=t.Panels;(a.getPanel("views-container")?a.getPanel("views-container"):a.addPanel({id:"views-container"})).set("appendContent",this.$cn.get(0)).trigger("change:appendContent"),this.target=t.getModel(),this.listenTo(this.target,"component:toggled",this.toggleTm)}this.toggleTm()},toggleTm:function(){var t=this.sender;t&&t.get&&!t.get("active")||(1===this.target.getSelectedAll().length?(this.$cn2.show(),this.$header.hide()):(this.$cn2.hide(),this.$header.show()))},stop:function(){this.$cn2&&this.$cn2.hide(),this.$header&&this.$header.hide()}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));n(77);var r=i.default.$;t.exports={run:function(t,e){if(this.sender=e,!this.$cn){var n=t.getConfig(),i=t.Panels;this.$cn=r("
"),this.$cn2=r("
"),this.$cn.append(this.$cn2);var o=t.DeviceManager;if(o&&n.showDevices)i.addPanel({id:"devices-c"}).set("appendContent",o.render()).trigger("change:appendContent");var s=t.SelectorManager;s&&this.$cn2.append(s.render([])),this.$cn2.append(t.StyleManager.render());var a=t.StyleManager.getConfig(),l=a.stylePrefix;this.$header=r('
'+a.textNoElement+"
"),this.$cn.append(this.$header),i.getPanel("views-container")?this.panel=i.getPanel("views-container"):this.panel=i.addPanel({id:"views-container"}),this.panel.set("appendContent",this.$cn).trigger("change:appendContent"),this.target=t.editor,this.listenTo(this.target,"component:toggled",this.toggleSm)}this.toggleSm()},toggleSm:function(){var t=this.target,e=this.sender;e&&e.get&&!e.get("active")||(1===t.getSelectedAll().length?(this.$cn2.show(),this.$header.hide()):(this.$cn2.hide(),this.$header.show()))},stop:function(){this.$cn2&&this.$cn2.hide(),this.$header&&this.$header.hide()}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));n(54),i.default.$;t.exports={run:function(t){var e=t.LayerManager,n=t.Panels;if(!this.layers){var i="views-container",r=document.createElement("div"),o=n.getPanel(i)||n.addPanel({id:i});r.appendChild(e.render()),o.set("appendContent",r).trigger("change:appendContent"),this.layers=r}this.layers.style.display="block"},stop:function(){var t=this.layers;t&&(t.style.display="none")}}},function(t,e,n){"use strict";t.exports={run:function(t){t.Canvas.getBody().className=this.ppfx+"dashed"},stop:function(t){t.Canvas.getBody().className=""}}},function(t,e,n){"use strict";var i=r(n(1));r(n(0));function r(t){return t&&t.__esModule?t:{default:t}}var o=n(7);t.exports=i.default.extend({},o,{beforeDraw:function(t){t.type="text",t.style||(t.style={}),t.style.padding="10px"},afterDraw:function(t){t&&t.set&&(t.trigger("focus"),this.sender&&this.sender.set("active",!1))}})},function(t,e,n){"use strict";var i=s(n(1)),r=s(n(0)),o=n(2);function s(t){return t&&t.__esModule?t:{default:t}}var a=n(8),l=n(13),c=r.default.$;t.exports=i.default.extend({},l,a,{init:function(t){a.init.apply(this,arguments),i.default.bindAll(this,"initSorter","rollback","onEndMove"),this.opt=t,this.hoverClass=this.ppfx+"highlighter-warning",this.badgeClass=this.ppfx+"badge-warning",this.noSelClass=this.ppfx+"no-select"},enable:function(){for(var t=arguments.length,e=Array(t),n=0;n2&&void 0!==arguments[2]&&arguments[2];e&&e.set&&e.set("active",0);var n=t.getConfig(),r=t.Modal,o=n.stylePrefix;if(this.cm=t.CodeManager||null,!this.$editors){var s=this.buildEditor("htmlmixed","hopscotch","HTML"),a=this.buildEditor("css","hopscotch","CSS");this.htmlEditor=s.el,this.cssEditor=a.el;var l=i('
');l.append(s.$el).append(a.$el),this.$editors=l}r.setTitle(n.textViewCode),r.setContent(this.$editors),r.open(),this.htmlEditor.setContent(t.getHtml()),this.cssEditor.setContent(t.getCss())},stop:function(t){var e=t.Modal;e&&e.close()},buildEditor:function(t,e,n){var i=document.createElement("textarea");!this.codeMirror&&(this.codeMirror=this.cm.getViewer("CodeMirror"));var r=this.codeMirror.clone().set({label:n,codeName:t,theme:e,input:i}),o=new this.cm.EditorView({model:r,config:this.cm.getConfig()}).render().$el;return r.init(i),{el:r,$el:o}}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=i.default.$;t.exports=i.default.View.extend({initialize:function(t){this.config=t||{},this.editorModel=this.em=this.config.em||{},this.pfx=this.config.stylePrefix,this.ppfx=this.config.pStylePrefix,this.hoverClass=this.pfx+"hover",this.badgeClass=this.pfx+"badge",this.plhClass=this.pfx+"placeholder",this.freezClass=this.ppfx+"freezed",this.canvas=this.em.get&&this.em.get("Canvas"),this.em.get&&this.setElement(this.getCanvas()),this.canvas&&(this.$canvas=this.$el,this.$wrapper=r(this.getCanvasWrapper()),this.frameEl=this.canvas.getFrameEl(),this.canvasTool=this.getCanvasTools(),this.bodyEl=this.getCanvasBody()),this.init(this.config)},onFrameScroll:function(t){},getCanvas:function(){return this.canvas.getElement()},getCanvasBody:function(){return this.canvas.getBody()},getCanvasWrapper:function(){return this.canvas.getWrapperEl()},getCanvasTools:function(){return this.canvas.getToolsEl()},offset:function(t){var e=t.getBoundingClientRect();return{top:e.top+t.ownerDocument.body.scrollTop,left:e.left+t.ownerDocument.body.scrollLeft}},init:function(t){},callRun:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.id;if(t.trigger("run:"+n+":before",e),!e||!e.abort){var i=e.sender||t,r=this.run(t,i,e);return t.trigger("run:"+n,r,e),r}t.trigger("abort:"+n,e)},callStop:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.id,i=e.sender||t;t.trigger("stop:"+n+":before",e);var r=this.stop(t,i,e);return t.trigger("stop:"+n,r,e),r},run:function(t,e){},stop:function(t,e){}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e\n \n
\n
\n
\n
\n '},inputClass:function(){var t=this.ppfx;return this.opts.contClass||t+"field "+t+"field-integer"},initialize:function(){arguments.length>0&&void 0!==arguments[0]&&arguments[0];o.prototype.initialize.apply(this,arguments),(0,i.bindAll)(this,"moveIncrement","upIncrement"),this.doc=document,this.listenTo(this.model,"change:unit",this.handleModelChange)},setValue:function(t,e){var n=e||{},i=this.validateInputValue(t,{deepCheck:1}),r={value:i.value};(i.unit||i.force)&&(r.unit=i.unit),this.model.set(r,n),n.silent&&this.handleModelChange()},handleChange:function(t){t.stopPropagation(),this.setValue(this.getInputEl().value),this.elementUpdated()},handleUnitChange:function(t){t.stopPropagation();var e=this.getUnitEl().value;this.model.set("unit",e),this.elementUpdated()},elementUpdated:function(){this.model.trigger("el:change")},handleModelChange:function(){var t=this.model;this.getInputEl().value=t.get("value");var e=this.getUnitEl();e&&(e.value=t.get("unit")||"")},getUnitEl:function(){if(!this.unitEl){var t=this.model,e=t.get("units")||[];if(e.length){var n=[];e.forEach(function(e){var i=e==t.get("unit")?"selected":"";n.push("")});var i=document.createElement("div");i.innerHTML='",this.unitEl=i.firstChild}}return this.unitEl},upArrowClick:function(){var t=this.model,e=t.get("step"),n=parseInt(t.get("value"),10);n=this.normalizeValue(n+e);var i=this.validateInputValue(n);t.set("value",i.value),this.elementUpdated()},downArrowClick:function(){var t=this.model,e=t.get("step"),n=parseInt(t.get("value"),10),i=this.normalizeValue(n-e),r=this.validateInputValue(i);t.set("value",r.value),this.elementUpdated()},downIncrement:function(t){t.preventDefault(),this.moved=0;var e=this.model.get("value");e=this.normalizeValue(e),this.current={y:t.pageY,val:e},(0,r.on)(this.doc,"mousemove",this.moveIncrement),(0,r.on)(this.doc,"mouseup",this.upIncrement)},moveIncrement:function(t){this.moved=1;var e=this.model,n=e.get("step"),i=this.current,r=this.normalizeValue(i.val+(i.y-t.pageY)*n);return this.prValue=this.validateInputValue(r).value,e.set("value",this.prValue,{avoidStore:1}),!1},upIncrement:function(){var t=this.model,e=t.get("step");if((0,r.off)(this.doc,"mouseup",this.upIncrement),(0,r.off)(this.doc,"mousemove",this.moveIncrement),this.prValue&&this.moved){var n=this.prValue-e;t.set("value",n,{avoidStore:1}).set("value",n+e),this.elementUpdated()}},normalizeValue:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.model.get("step"),i=0;if(isNaN(t))return e;if(t=parseFloat(t),Math.floor(t)!==t){var r=n.toString().split(".")[1];i=r?r.length:0}return i?parseFloat(t.toFixed(i)):t},validateInputValue:function(t,n){var r=0,o=n||{},s=this.model,a=(0,i.isUndefined)(t)?"":t,l=s.get("units")||[],c=s.get("unit")||l.length&&l[0]||"",u=s.get("max"),h=s.get("min");if(o.deepCheck){var d=s.get("fixedValues")||[];if(a){var f=new RegExp("^"+d.join("|"),"g");if(d.length&&f.test(a))a=a.match(f)[0],c="",r=1;else{var p=a+"";a+="",a=parseFloat(a.replace(",",".")),a=isNaN(a)?"":a;var g=p.replace(a,"");e.indexOf(l,g)>=0&&(c=g)}}}return(0,i.isUndefined)(u)||""===u||(a=a>u?u:a),(0,i.isUndefined)(h)||""===h||(a=a\n \n
\n '},inputValueChanged:function(){if(!this.model.get("detached")){for(var t=arguments.length,e=Array(t),n=0;n'),this.input=this.$input.get(0)),this.props||(this.props=t.get("properties")),!this.$props)){this.props.each(function(e,n){e&&"composite"==e.get("type")&&(this.props.remove(e),console.warn("Nested composite types not yet allowed.")),e.parent=t},this);var i=new(n(16))(this.getPropsConfig());this.$props=i.render().$el,this.properties=i.properties,this.$el.find("#"+this.pfx+"input-holder").append(this.$props)}},getPropsConfig:function(t){var e=this,n=this.model,i={config:this.config,collection:this.props,target:this.target,propTarget:this.propTarget,onChange:function(t,e,i){n.set("value",n.getFullValue(),i)},customValue:function(t,n){return e.valueOnIndex(n,t)}};return n.get("detached")&&delete i.onChange,i},valueOnIndex:function(t,e){var n=void 0,i=this.getTargetValue({ignoreDefault:1});i?n=i.split(" ")[t]:n=e&&e.getTargetValue({ignoreCustomValue:1,ignoreDefault:1});return e&&(n=e.model.parseValue(n).value),n}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Model.extend({defaults:{id:"",label:"",open:!0,attributes:{}}})},function(t,e,n){"use strict";var i=n(1);t.exports={run:function(t){var e=t.getModel(),n=e.get("clipboard"),r=t.getSelected();n&&r&&!e.isEditing()&&(t.getSelectedAll().forEach(function(e){if(e){var r=e.collection,o=r.indexOf(e)+1,s=n.filter(function(t){return t.get("copyable")}),a=void 0;a=(0,i.contains)(n,e)&&e.get("copyable")?r.add(e.clone(),{at:o}):r.add(s.map(function(t){return t.clone()}),{at:o}),(a=(0,i.isArray)(a)?a:[a]).forEach(function(e){return t.trigger("component:clone",e)})}}),r.emitUpdate())}}},function(t,e,n){"use strict";t.exports={run:function(t){var e=t.getModel(),n=[].concat(function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e=0?r:t)}),e.length&&t.select(e)}}}},function(t,e,n){"use strict";t.exports={run:function(t){if(t.Canvas.hasFocus()&&!t.getModel().isEditing()){var e=[];t.getSelectedAll().forEach(function(t){var n=t.collection,i=n.indexOf(t),r=n.at(i+1);e.push(r||t)}),e.length&&t.select(e)}}}},function(t,e,n){"use strict";t.exports={run:function(t){if(t.Canvas.hasFocus()&&!t.getModel().isEditing()){var e=[];t.getSelectedAll().forEach(function(t){var n=t.parent();n&&e.push(n)}),e.length&&t.select(e)}}}},function(t,e,n){"use strict";t.exports={run:function(t){if(t.Canvas.hasFocus()&&!t.getModel().isEditing()){var e=[];t.getSelectedAll().forEach(function(t){var n=t.components(),i=n&&n.at(0);i&&e.push(i)}),e.length&&t.select(e)}}}},function(t,e,n){"use strict";var i=n(1);t.exports={run:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!t.getModel().isEditing()){var r=n.component||t.getSelectedAll();return r=(0,i.isArray)(r)?[].concat(function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e':"")+'\n
\n
\n
\n \n '+t.getIcon()+'\n '+h+'\n
\n
\n
\n
'+(r||"")+'
\n
\n \n
\n
'},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.opt=t,this.level=t.level,this.config=t.config,this.em=t.config.em,this.ppfx=this.em.get("Config").stylePrefix,this.sorter=t.sorter||"",this.pfx=this.config.stylePrefix;var e=this.pfx,n=this.ppfx,i=this.model,r=i.get("components");i.set("open",!1),this.listenTo(r,"remove add change reset",this.checkChildren),this.listenTo(i,"change:status",this.updateStatus),this.listenTo(i,"change:open",this.updateOpening),this.listenTo(i,"change:style:display",this.updateVisibility),this.className=e+"layer no-select "+n+"two-color",this.inputNameCls=n+"layer-name",this.clsTitleC=e+"layer-title-c",this.clsTitle=e+"layer-title",this.clsCaret=e+"layer-caret",this.clsCount=e+"layer-count",this.clsMove=e+"layer-move",this.clsChildren=e+"layer-children",this.clsNoChild=e+"layer-no-chld",this.$el.data("model",i),this.$el.data("collection",r),i.viewLayer=this},getVisibilityEl:function(){return this.eyeEl||(this.eyeEl=this.$el.children("."+this.pfx+"layer-vis")),this.eyeEl},updateVisibility:function(){var t=this.pfx+"layer-hidden",e="none"==this.model.getStyle().display?"addClass":"removeClass";this.$el[e](t),this.getVisibilityEl()[e]("fa-eye-slash")},toggleVisibility:function(t){t&&t.stopPropagation();var e=this.model,n=e.getStyle();"none"==n.display?delete n.display:n.display="none",e.setStyle(n)},handleEdit:function(t){t&&t.stopPropagation();var e=this.getInputName();e.contentEditable=!0,e.focus()},handleEditEnd:function(t){t&&t.stopPropagation();var e=this.getInputName(),n=e.textContent;e.contentEditable=!1,this.model.set({name:n})},getInputName:function(){return this.inputName||(this.inputName=this.el.querySelector("."+this.inputNameCls)),this.inputName},updateOpening:function(){var t=this.opt.opened||{},e=this.model;e.get("open")?(this.$el.addClass("open"),this.getCaret().addClass("fa-chevron-down"),t[e.cid]=e):(this.$el.removeClass("open"),this.getCaret().removeClass("fa-chevron-down"),delete t[e.cid])},toggleOpening:function(t){t.stopPropagation(),this.model.get("components").length&&this.model.set("open",!this.model.get("open"))},handleSelect:function(t){t.stopPropagation();var e=this.em,n=this.config;if(e){var i=this.model;e.setSelected(i,{fromLayers:1});var r=n.scrollCanvas;r&&e.get("Canvas").scrollTo(i,r)}},handleHover:function(t){t.stopPropagation();var e=this.em,n=this.config,i=this.model;e&&n.showHover&&e.setHovered(i,{fromLayers:1})},startSort:function(t){t.stopPropagation();var e=this.sorter;0===t.button&&e&&e.startSort(t.target)},freeze:function(){this.$el.addClass(this.pfx+"opac50"),this.model.set("open",0)},unfreeze:function(){this.$el.removeClass(this.pfx+"opac50")},updateStatus:function(t){s.prototype.updateStatus.apply(this,[{avoidHover:!this.config.highlightHover}])},isVisible:function(){var t=this.model.get("style").display;if(!t||"none"!=t)return 1},checkChildren:function(){var t=this.model,e=this.countChildren(t),n=(this.pfx,this.clsNoChild),i=this.$el.children("."+this.clsTitleC).children("."+this.clsTitle);this.cnt||(this.cnt=this.$el.children("."+this.clsCount)),e?(i.removeClass(n),this.cnt.html(e)):(i.addClass(n),this.cnt.empty(),t.set("open",0))},countChildren:function(t){var e=0;return t.get("components").each(function(t){var n=this.opt.isCountable,i=this.config.hideTextnode;n&&!n(t,i)||e++},this),e},getCaret:function(){if(!this.caret||!this.caret.length){this.pfx;this.caret=this.$el.children("."+this.clsTitleC).find("."+this.clsCaret)}return this.caret},setRoot:function(t){t=(0,i.isString)(t)?this.em.getWrapper().find(t)[0]:t;var e=(0,r.getModel)(t,a);e&&(this.stopListening(),this.model=e,this.initialize(this.opt),this.render())},render:function(){var t=this.model,e=this.pfx,r=this.isVisible(),o=this.$el.empty(),s=this.level+1;(0,i.isUndefined)(l)&&(l=n(113));var a=new l({collection:t.get("components"),config:this.config,sorter:this.sorter,opened:this.opt.opened,parent:t,level:s}).render().$el;return this.config.showWrapper||1!==s?(o.html(this.template(t)),o.find("."+this.clsChildren).append(a)):o.append(a),t.get("draggable")&&this.config.sortable||o.children("."+this.clsMove).remove(),!r&&(this.className+=" "+e+"hide"),o.attr("class",this.className),this.updateOpening(),this.updateStatus(),this.updateVisibility(),this}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};return(n=i({},r.default,e)).stylePrefix=e.pStylePrefix,t=n.em,this},getConfig:function(){return n},onLoad:function(){e=new o.default({level:0,config:n,opened:n.opened||{},model:t.get("DomComponents").getWrapper()}),t&&t.on("component:selected",this.componentChanged),this.componentChanged()},postRender:function(){var t=n.appendTo,e=n.root;(e&&this.setRoot(e),t)&&((0,s.isElement)(t)?t:document.querySelector(t)).appendChild(this.render())},setRoot:function(t){return e.setRoot(t),this},getRoot:function(){return e.model},getAll:function(){return e},componentChanged:function(e){if(!(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).fromLayers){var i=t.get("opened"),r=t.getSelected(),o=n.scrollLayers,s=r&&r.collection?r.collection.parent:null;for(var a in i)i[a].set("open",0);for(;s;)s.set("open",1),i[s.cid]=s,s=s.collection?s.collection.parent:null;if(r&&o){var l=r.viewLayer&&r.viewLayer.el;l&&l.scrollIntoView(o)}}},render:function(){return e.render().el}}}},function(t,e,n){"use strict";var i=n(2),r=n(3);t.exports=r.extend({events:{dblclick:"enableEditing",input:"onInput"},initialize:function(t){r.prototype.initialize.apply(this,arguments),this.disableEditing=this.disableEditing.bind(this);var e=this.model,n=this.em;this.listenTo(e,"focus active",this.enableEditing),this.listenTo(e,"change:content",this.updateContent),this.rte=n&&n.get("RichTextEditor")},enableEditing:function(t){t&&t.stopPropagation&&t.stopPropagation();var e=this.rte;if(!this.rteEnabled&&this.model.get("editable")){if(e)try{this.activeRte=e.enable(this,this.activeRte)}catch(t){console.error(t)}this.rteEnabled=1,this.toggleEvents(1)}},disableEditing:function(){var t=this.model,e=t.get("editable"),n=this.rte;if(n&&e){try{n.disable(this,this.activeRte)}catch(t){console.error(t)}var i=this.getChildrenContainer().innerHTML,r=t.get("components");if(r.length&&r.reset(),t.set("content",""),n.customRte)t.set("content",i);else{t.trigger("change:content",t),r.add(i),r.each(function(t){return function t(e){e.set({editable:0,highlightable:0,removable:0,draggable:0,copyable:0,toolbar:""}),e.get("components").each(function(e){return t(e)})}(t)}),r.trigger("resetNavigator")}}this.rteEnabled=0,this.toggleEvents()},onInput:function(t){var e=this.em;e&&e.trigger("change:canvasOffset")},disablePropagation:function(t){t.stopPropagation()},toggleEvents:function(t){var e=t?"on":"off",n={on:i.on,off:i.off};this.em.setEditing(t);var r=[this.el.ownerDocument,document];n.off(r,"mousedown",this.disableEditing),n[e](r,"mousedown",this.disableEditing),this.$el.off("mousedown",this.disablePropagation),this.$el[e]("mousedown",this.disablePropagation)}})},function(t,e,n){"use strict";n(0);var i=n(55);t.exports=i.extend({render:function(){for(var t=arguments.length,e=Array(t),n=0;n1&&void 0!==arguments[1]&&arguments[1];var e=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},n=this.config.em,i=this.collection.indexOf(t);this.addToCollection(t,null,i),n&&!e.temporary&&n.trigger("component:add",t)},addToCollection:function(t,e,i){this.compView||(this.compView=n(3));for(var o=e||null,s=this.compView,a=this.opts.componentTypes,l=t.get("type"),c=0;c1&&void 0!==arguments[1]?arguments[1]:{};this.listenTo(this,"add",this.onAdd),this.config=e.config,this.em=e.em,this.model=function(t,n){var i,r=e.componentTypes;n.em=e.em,n.config=e.config,n.componentTypes=r;for(var o=0;o1&&void 0!==arguments[1]?arguments[1]:{};if("string"==typeof t){var n=this.em.get("CssComposer"),i=this.em.get("Parser").parseHtml(t);if(t=i.html,i.css&&n){var o=e.avoidUpdateStyle;n.addCollection(i.css,{extend:1,avoidUpdateStyle:o})}}return r.Collection.prototype.add.apply(this,[t,e])},onAdd:function(t,e,n){var r=this.em,o=t.getStyle(),s=r&&r.getConfig("avoidInlineStyle");if(!(0,i.isEmpty)(o)&&!s&&r&&r.get&&r.getConfig("forceClass")){var a=t.cid;r.get("CssComposer").setClassRule(a,o);t.setStyle({}),t.addClass(a)}}})},function(t,e,n){"use strict";var i=n(0);t.exports=i.View.extend({itemView:"",itemsView:"",itemType:"type",initialize:function(t,e){this.config=e||{}},addTo:function(t){this.add(t)},add:function(t,e){var n=e||null,i=this.itemView,r=t.get(this.itemType);this.itemsView&&this.itemsView[r]&&(i=this.itemsView[r]);var o=new i({model:t,config:this.config},this.config).render().el;n?n.appendChild(o):this.$el.append(o)},render:function(){var t=document.createDocumentFragment();return this.$el.empty(),this.collection.length&&this.collection.each(function(e){this.add(e,t)},this),this.$el.append(t),this}})},function(t,e,n){"use strict";t.exports=n(0).View.extend({tagName:"style",initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.config=t.config||{};var e=this.model;this.listenTo(e,"change:style change:state change:mediaText",this.render),this.listenTo(e,"destroy remove",this.remove),this.listenTo(e.get("selectors"),"change",this.render)},render:function(){var t=this.model.get("important");return this.el.innerHTML=this.model.toCSS({important:t}),this}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};(0,r.isString)(e)&&(e=s(e));var a=this.getStyle(),l=i({},e);this.set("style",l,n);var c=(0,o.shallowDiff)(a,l);return(0,r.keys)(c).forEach(function(e){var n=t.em;t.trigger("change:style:"+e),n&&(n.trigger("styleable:change",t,e),n.trigger("styleable:change:"+e,t,e))}),l},addStyle:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"",n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};"string"==typeof t?t={prop:e}:n=e||{},t=this.extendStyle(t),this.setStyle(t,n)},removeStyle:function(t){var e=this.getStyle();delete e[t],this.setStyle(e)},styleToString:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=[],n=this.getStyle();for(var i in n){var o=t.important,s=(0,r.isArray)(o)?o.indexOf(i)>=0:o,a=n[i]+(s?" !important":"");a&&e.push(i+":"+a+";")}return e.join("")}}},function(t,e,n){"use strict";var i=n(1),r=a(i),o=a(n(0)),s=a(n(61));function a(t){return t&&t.__esModule?t:{default:t}}var l=n(19);t.exports=o.default.Model.extend(s.default).extend({defaults:{selectors:{},selectorsAdd:"",style:{},mediaText:"",state:"",stylable:!0,atRuleType:"",singleAtRule:0,important:0},initialize:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.config=t||{};var n=e.em,i=this.config.selectors||[];if(this.em=n,n){var r=n.get("SelectorManager"),o=[];i.forEach(function(t){o.push(r.add(t))}),i=o}this.set("selectors",new l(i))},getAtRule:function(){var t=this.get("atRuleType"),e=this.get("mediaText"),n=t?"@"+t:e?"@media":"";return n+(e&&n?" "+e:"")},selectorsToString:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=[],n=this.get("state"),i=this.get("selectorsAdd"),r=this.get("selectors").getFullString(),o=n?":"+n:"";return r&&e.push(""+r+o),i&&!t.skipAdd&&e.push(i),e.join(", ")},getDeclaration:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e="",n=this.selectorsToString(),i=this.styleToString(t),r=this.get("singleAtRule");return(n||r)&&i&&(e=r?i:n+"{"+i+"}"),e},toCSS:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e="",n=this.getAtRule(),i=this.getDeclaration(t);return i&&(e=i),n&&e&&(e=n+"{"+e+"}"),e},toJSON:function(){for(var t=arguments.length,e=Array(t),n=0;n3&&void 0!==arguments[3]?arguments[3]:{},o=e||"",s=n||"",a=i.selectorsAdd||"",l=i.atRuleType||"";t instanceof Array||t.models||(t=[t]);var c=r.default.map(t.models||t,function(t){return t.get("name")}),u=r.default.map(this.get("selectors").models,function(t){return t.get("name")});if(c.length!==u.length)return!1;for(var h=0;h\n
<%= title %>
\n multiple/>\n
\n \n '),events:{},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.options=t;var e=t.config||{};this.config=e,this.pfx=e.stylePrefix||"",this.ppfx=e.pStylePrefix||"",this.target=this.options.globalCollection||{},this.uploadId=this.pfx+"uploadFile",this.disabled=void 0!==e.disableUpload?e.disableUpload:!e.upload&&!e.embedAsBase64,this.events["change #"+this.uploadId]="uploadFile";var n=e.uploadFile;n?this.uploadFile=n.bind(this):e.embedAsBase64&&(this.uploadFile=this.constructor.embedAsBase64),this.delegateEvents()},onUploadStart:function(){var t=this.config.em;t&&t.trigger("asset:upload:start")},onUploadEnd:function(t){var e=this.config.em;e&&e.trigger("asset:upload:end",t)},onUploadError:function(t){var e=this.config.em;console.error(t),this.onUploadEnd(t),e&&e.trigger("asset:upload:error",t)},onUploadResponse:function(t,e){var n=this.config.em,i=this.config,r=this.target,o="string"==typeof t?JSON.parse(t):t;n&&n.trigger("asset:upload:response",o),i.autoAdd&&r&&r.add(o.data,{at:0}),this.onUploadEnd(t),e&&e(o)},uploadFile:function(t,e){for(var n=this,i=t.dataTransfer?t.dataTransfer.files:t.target.files,r=new FormData,s=this.config,a=s.params,l=0;l'+i.dropzoneContent+"
"),h(),"draggable"in o&&[o,a].forEach(function(t){t.ondragover=d,t.ondragleave=f,t.ondrop=p})},render:function(){return this.$el.html(this.template({title:this.config.uploadText,uploadId:this.uploadId,disabled:this.disabled,pfx:this.pfx})),this.initDrop(),this.$el.attr("class",this.pfx+"file-uploader"),this}},{embedAsBase64:function(t,e){var n=this,i=t.dataTransfer?t.dataTransfer.files:t.target.files,r={data:[]};if(FileReader){var o=[],s=/^(.+)\/(.+)$/,a=function(t){var e=new Promise(function(e,n){var i=new FileReader;i.addEventListener("load",function(r){var o=void 0,a=t.name,l=s.exec(t.type);if("image"===(o=l?l[1]:t.type)){var c={src:i.result,name:a,type:o,height:0,width:0},u=new Image;u.addEventListener("error",function(t){n(t)}),u.addEventListener("load",function(){c.height=u.height,c.width=u.width,e(c)}),u.src=c.src}else e(o?{src:i.result,name:a,type:o}:i.result)}),i.addEventListener("error",function(t){n(t)}),i.addEventListener("abort",function(t){n("Aborted")}),i.readAsDataURL(t)});o.push(e)},l=!0,c=!1,u=void 0;try{for(var h,d=i[Symbol.iterator]();!(l=(h=d.next()).done);l=!0){a(h.value)}}catch(t){c=!0,u=t}finally{try{!l&&d.return&&d.return()}finally{if(c)throw u}}Promise.all(o).then(function(t){r.data=t,n.onUploadResponse(r,e)},function(t){n.onUploadError(t)})}else this.onUploadError(new Error("Unsupported platform, FileReader is not defined"))}})},function(t,e,n){"use strict";(function(e){var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.View.extend({initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.options=t,this.collection=t.collection;var e=t.config||{};this.config=e,this.pfx=e.stylePrefix||"",this.ppfx=e.pStylePrefix||"",this.em=e.em,this.className=this.pfx+"asset",this.listenTo(this.model,"destroy remove",this.remove),this.model.view=this;var n=this.init&&this.init.bind(this);n&&n(t)},template:function(){var t=this.pfx;return'\n
\n '+this.getPreview()+'\n
\n
\n '+this.getInfo()+'\n
\n
\n ⨯\n
\n '},updateTarget:function(t){t&&t.set&&(t.set("attributes",e.clone(t.get("attributes"))),t.set("src",this.model.get("src")))},getPreview:function(){return""},getInfo:function(){return""},render:function(){var t=this.el;return t.innerHTML=this.template(this,this.model),t.className=this.className,this}})}).call(this,n(1))},function(t,e,n){"use strict";var i=n(1);t.exports=n(64).extend({events:{"click [data-toggle=asset-remove]":"onRemove",click:"onClick",dblclick:"onDblClick"},getPreview:function(){var t=this.pfx;return'\n
\n
\n '},getInfo:function(){var t=this.pfx,e=this.model,n=e.get("name"),i=e.get("width"),r=e.get("height"),o=e.get("unitDim"),s=i&&r?i+"x"+r+o:"";return'\n
'+(n=n||e.getFilename())+'
\n
'+s+"
\n "},init:function(t){var e=this.pfx;this.className+=" "+e+"asset-image"},onClick:function(){var t=this.config.onClick,e=this.model;this.collection.trigger("deselectAll"),this.$el.addClass(this.pfx+"highlight"),(0,i.isFunction)(t)?t(e):this.updateTarget(this.collection.target)},onDblClick:function(){var t=this.em,e=this.model,n=this.config.onDblClick;(0,i.isFunction)(n)?n(e):(this.updateTarget(this.collection.target),t&&t.get("Modal").close());var r=this.collection.onSelect;(0,i.isFunction)(r)&&r(e)},onRemove:function(t){t.stopImmediatePropagation(),this.model.collection.remove(this.model)}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};return this.set({value:void 0,unit:void 0},t),this},parseValue:function(t){var e=o.prototype.parseValue.apply(this,arguments),n=this.input.validateInputValue(e.value,{deepCheck:1}),i=n.value,r=n.unit;return e.value=i,e.unit=r,e},getFullValue:function(){var t=this.get("value"),e=this.get("unit");return t=""+(t=(0,r.isUndefined)(t)?"":t)+(e=!(0,r.isUndefined)(e)&&t?e:""),o.prototype.getFullValue.apply(this,[t])}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:[];return this.set("options",t),this},addOption:function(t){if(t){var e=this.getOptions();this.setOptions([].concat(function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e\n
\n
\n \n
\n
\n
\n
\n
\n
\n
\n
\n '},init:function(){var t=this.em;this.modal=t.get("Modal"),this.am=t.get("AssetManager"),this.events["click #"+this.pfx+"close"]="removeFile",this.events["click #"+this.pfx+"images"]="openAssetManager",this.delegateEvents()},onRender:function(){if(!this.$input){var t=this.model.getDefaultValue();this.$input=o('')}this.$preview||(this.$preview=this.$el.find("#"+this.pfx+"preview-file")),this.$previewBox||(this.$previewBox=this.$el.find("#"+this.pfx+"preview-box")),this.setValue(this.componentValue,0)},setValue:function(t,e){r.prototype.setValue.apply(this,arguments),this.setPreviewView(t&&t!=this.model.getDefaultValue()),this.setPreview(t)},setPreviewView:function(t){var e=this.$previewBox;e&&e[t?"addClass":"removeClass"](this.pfx+"show")},spreadUrl:function(t){this.model.set("value",t),this.setPreviewView(1)},setPreview:function(t){var e=this.$preview;t=t&&t.indexOf("url(")<0?"url("+t+")":t,e&&e.css("background-image",t)},cleanValue:function(){this.setPreviewView(0),this.model.set({value:""},{silent:!0})},removeFile:function(){this.model.set("value",this.model.getDefaultValue());for(var t=arguments.length,e=Array(t),n=0;n
\n
\n
\n
\n
\n
\n '},inputClass:function(){var t=this.ppfx;return t+"field "+t+"field-color"},holderClass:function(){return this.ppfx+"input-holder"},setValue:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.model.get("defaults"),i=(0,o.isUndefined)(t)?(0,o.isUndefined)(n)?"":n:t,r=this.getInputEl(),s=this.getColorEl(),a="none"!=i?i:"";r.value=i,s.get(0).style.backgroundColor=a,e.fromTarget&&(s.spectrum("set",a),this.noneColor="none"==i)},getColorEl:function(){if(!this.colorEl){var t=this,e=this.ppfx,n=this.model,r=c('
'),o=r.get(0).style,s=this.em&&this.em.config?this.em.config.el:"",a=this.em&&this.em.getConfig&&this.em.getConfig("colorPicker")||{},l=function(t){return(1==t.getAlpha()?t.toHexString():t.toRgbString()).replace(/ /g,"")},u=0,h=void 0;this.$el.find("[data-colorp-c]").append(r),r.spectrum(i({containerClassName:e+"one-bg "+e+"two-color",appendTo:s||"body",maxSelectionSize:8,showPalette:!0,showAlpha:!0,chooseText:"Ok",cancelText:"⨯",palette:[]},a,{move:function(t){var e=l(t);o.backgroundColor=e,n.setValueFromInput(e,0)},change:function(e){u=1;var i=l(e);o.backgroundColor=i,n.setValueFromInput(i),t.noneColor=0},show:function(t){u=0,h=l(t)},hide:function(e){!u&&h&&(t.noneColor&&(h=""),o.backgroundColor=h,r.spectrum("set",h),n.setValueFromInput(h,0))}})),this.colorEl=r}return this.colorEl},render:function(){return l.prototype.render.call(this),this.getColorEl(),this}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{};e=i({},e,{silent:1}),this.inputInst.setValue(t,e)},onRender:function(){if(!this.input){var t=this.ppfx,e=new r({target:this.target,model:this.model,ppfx:t}).render();this.el.querySelector("."+t+"fields").appendChild(e.el),this.$input=e.inputEl,this.$color=e.colorEl,this.input=this.$input.get(0),this.inputInst=e}}})},function(t,e,n){"use strict";var i=o(n(0)),r=o(n(5));function o(t){return t&&t.__esModule?t:{default:t}}i.default.$;t.exports=r.default.extend({templateInput:function(){var t=this.pfx,e=this.ppfx;return'\n
\n \n
\n
\n
\n
\n '},initialize:function(){for(var t=arguments.length,e=Array(t),n=0;n"+e+""});var i=this.el.querySelector("#"+t+"input-holder");i.innerHTML="",this.input=i.firstChild}}})},function(t,e,n){"use strict";t.exports=n(5).extend({templateInput:function(){this.pfx;var t=this.ppfx;return'\n
\n
\n '},onRender:function(){var t=this.pfx,e=this.ppfx,n=e+"radio-item-label",i=this.model,r=i.get("property"),o=i.get("list")||i.get("options")||[];if(!this.input&&o&&o.length){var s="";o.forEach(function(i){var o=i.className?i.className+" "+t+"icon "+n:"",a=r+"-"+i.value,l=i.name||i.value,c=i.title?'title="'+i.title+'"':"";s+='\n
\n \n \n
\n "});var a=this.el.querySelector("."+e+"field");a.innerHTML='
'+s+"
",this.input=a.firstChild}},getInputValue:function(){var t=this.getCheckedEl();return t?t.value:""},getCheckedEl:function(){var t=this.getInputEl();return t?t.querySelector("input:checked"):""},setValue:function(t){var e=this.model,n=t||e.get("value")||e.getDefaultValue(),i=this.getInputEl(),r=i?i.querySelector('[value="'+n+'"]'):"";if(r)r.checked=!0;else{var o=this.getCheckedEl();o&&(o.checked=!1)}}})},function(t,e,n){"use strict";var i=n(0),r=i.$;t.exports=i.View.extend({events:{change:"handleChange"},template:function(){return''},inputClass:function(){return this.ppfx+"field"},holderClass:function(){return this.ppfx+"input-holder"},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.ppfx||"";this.opts=t,this.ppfx=e,this.em=t.target||{},this.listenTo(this.model,"change:value",this.handleModelChange)},elementUpdated:function(){this.model.trigger("el:change")},setValue:function(t){var e=this.model,n=t||e.get("defaults"),i=this.getInputEl();i&&(i.value=n)},handleModelChange:function(t,e,n){this.setValue(e,n)},handleChange:function(t){t.stopPropagation();var e=this.getInputEl().value;this.model.set({value:e},{fromInput:1}),this.elementUpdated()},getInputEl:function(){if(!this.inputEl){var t=this.model.get("defaults")||"";this.inputEl=r('')}return this.inputEl.get(0)},render:function(){var t=this.$el;return t.addClass(this.inputClass()),t.html(this.template()),t.find("."+this.holderClass()).append(this.getInputEl()),this}})},function(t,e,n){"use strict";var i=n(43),r=n(168);t.exports=i.extend({templateInput:function(){var t=this.pfx;this.ppfx;return'\n
\n \n
\n
\n '},init:function(){var t=this.model;this.pfx;t.set("stackIndex",null),this.events["click [data-add-layer]"]="addLayer",this.listenTo(t,"change:stackIndex",this.indexChanged),this.listenTo(t,"updateValue",this.inputValueChanged),this.delegateEvents()},clear:function(t){t&&t.stopPropagation(),this.model.get("layers").reset(),this.model.clearValue(),this.targetUpdated()},targetUpdated:function(){if(this.model.get("detached"))this.checkVisibility();else{for(var t=arguments.length,e=Array(t),n=0;n0&&void 0!==arguments[0]&&arguments[0];return this.get("properties").each(function(t){return t.clearValue()}),r.prototype.clearValue.apply(this,arguments)},updateValues:function(){var t=this.getFullValue().split(this.get("separator"));this.get("properties").each(function(e,n){var i=t.length;t[n]||t[n%i+(1!=i&&i%2?1:0)]})},getDefaultValue:function(t){var e=this.get("defaults");return e&&!t?e:(e="",this.get("properties").each(function(t,n){return e+=t.getDefaultValue()+" "}),e.trim())},getFullValue:function(){return this.get("detached")?"":this.get("properties").getFullValue()}})},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var n=t.Model,i=t.View;e.default={types:[],initialize:function(t,e){var n=this;this.model=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=void 0,r=void 0,o=void 0;if(t&&t.type){var s=n.getBaseType();i=(o=n.getType(t.type))?o.model:s.model,r=o?o.view:s.view}else{var a=n.recognizeType(t);i=(o=a.type).model,r=o.view,t=a.attributes}var l=new i(t,e);return l.typeView=r,l};var i=this.init&&this.init.bind(this);i&&i()},recognizeType:function(t){for(var e=this.getTypes(),n=0;n1&&void 0!==arguments[1]?arguments[1]:{},n=e.model,r=void 0===n?{}:n,s=e.view,a=void 0===s?{}:s,l=this.getType(t);if(l)return new l.view(i({model:new l.model(r),config:o},a))},render:function(){return e.render().el}}}},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0;r--)n.context=n.context.prev;return M(t,e,n)}function O(t){var e=t.current().toLowerCase();o=m.hasOwnProperty(e)?"atom":v.hasOwnProperty(e)?"keyword":"variable"}var P={top:function(t,e,n){if("{"==t)return T(n,e,"block");if("}"==t&&n.context.prev)return E(n);if(x&&/@component/i.test(t))return T(n,e,"atComponentBlock");if(/^@(-moz-)?document$/i.test(t))return T(n,e,"documentTypes");if(/^@(media|supports|(-moz-)?document|import)$/i.test(t))return T(n,e,"atBlock");if(/^@(font-face|counter-style)/i.test(t))return n.stateArg=t,"restricted_atBlock_before";if(/^@(-(moz|ms|o|webkit)-)?keyframes$/i.test(t))return"keyframes";if(t&&"@"==t.charAt(0))return T(n,e,"at");if("hash"==t)o="builtin";else if("word"==t)o="tag";else{if("variable-definition"==t)return"maybeprop";if("interpolation"==t)return T(n,e,"interpolation");if(":"==t)return"pseudo";if(y&&"("==t)return T(n,e,"parens")}return n.context.type},block:function(t,e,n){if("word"==t){var i=e.current().toLowerCase();return d.hasOwnProperty(i)?(o="property","maybeprop"):f.hasOwnProperty(i)?(o="string-2","maybeprop"):y?(o=e.match(/^\s*:(?:\s|$)/,!1)?"property":"tag","block"):(o+=" error","maybeprop")}return"meta"==t?"block":y||"hash"!=t&&"qualifier"!=t?P.top(t,e,n):(o="error","block")},maybeprop:function(t,e,n){return":"==t?T(n,e,"prop"):M(t,e,n)},prop:function(t,e,n){if(";"==t)return E(n);if("{"==t&&y)return T(n,e,"propBlock");if("}"==t||"{"==t)return A(t,e,n);if("("==t)return T(n,e,"parens");if("hash"!=t||/^#([0-9a-fA-f]{3,4}|[0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/.test(e.current())){if("word"==t)O(e);else if("interpolation"==t)return T(n,e,"interpolation")}else o+=" error";return"prop"},propBlock:function(t,e,n){return"}"==t?E(n):"word"==t?(o="property","maybeprop"):n.context.type},parens:function(t,e,n){return"{"==t||"}"==t?A(t,e,n):")"==t?E(n):"("==t?T(n,e,"parens"):"interpolation"==t?T(n,e,"interpolation"):("word"==t&&O(e),"parens")},pseudo:function(t,e,n){return"meta"==t?"pseudo":"word"==t?(o="variable-3",n.context.type):M(t,e,n)},documentTypes:function(t,e,n){return"word"==t&&l.hasOwnProperty(e.current())?(o="tag",n.context.type):P.atBlock(t,e,n)},atBlock:function(t,e,n){if("("==t)return T(n,e,"atBlock_parens");if("}"==t||";"==t)return A(t,e,n);if("{"==t)return E(n)&&T(n,e,y?"block":"top");if("interpolation"==t)return T(n,e,"interpolation");if("word"==t){var i=e.current().toLowerCase();o="only"==i||"not"==i||"and"==i||"or"==i?"keyword":c.hasOwnProperty(i)?"attribute":u.hasOwnProperty(i)?"property":h.hasOwnProperty(i)?"keyword":d.hasOwnProperty(i)?"property":f.hasOwnProperty(i)?"string-2":m.hasOwnProperty(i)?"atom":v.hasOwnProperty(i)?"keyword":"error"}return n.context.type},atComponentBlock:function(t,e,n){return"}"==t?A(t,e,n):"{"==t?E(n)&&T(n,e,y?"block":"top",!1):("word"==t&&(o="error"),n.context.type)},atBlock_parens:function(t,e,n){return")"==t?E(n):"{"==t||"}"==t?A(t,e,n,2):P.atBlock(t,e,n)},restricted_atBlock_before:function(t,e,n){return"{"==t?T(n,e,"restricted_atBlock"):"word"==t&&"@counter-style"==n.stateArg?(o="variable","restricted_atBlock_before"):M(t,e,n)},restricted_atBlock:function(t,e,n){return"}"==t?(n.stateArg=null,E(n)):"word"==t?(o="@font-face"==n.stateArg&&!p.hasOwnProperty(e.current().toLowerCase())||"@counter-style"==n.stateArg&&!g.hasOwnProperty(e.current().toLowerCase())?"error":"property","maybeprop"):"restricted_atBlock"},keyframes:function(t,e,n){return"word"==t?(o="variable","keyframes"):"{"==t?T(n,e,"top"):M(t,e,n)},at:function(t,e,n){return";"==t?E(n):"{"==t||"}"==t?A(t,e,n):("word"==t?o="tag":"hash"==t&&(o="builtin"),"at")},interpolation:function(t,e,n){return"}"==t?E(n):"{"==t||";"==t?A(t,e,n):("word"==t?o="variable":"variable"!=t&&"("!=t&&")"!=t&&(o="error"),"interpolation")}};return{startState:function(t){return{tokenize:null,state:i?"block":"top",stateArg:null,context:new S(i?"block":"top",t||0,null)}},token:function(t,e){if(!e.tokenize&&t.eatSpace())return null;var n=(e.tokenize||function(t,e){var n=t.next();if(a[n]){var i=a[n](t,e);if(!1!==i)return i}return"@"==n?(t.eatWhile(/[\w\\\-]/),w("def",t.current())):"="==n||("~"==n||"|"==n)&&t.eat("=")?w(null,"compare"):'"'==n||"'"==n?(e.tokenize=C(n),e.tokenize(t,e)):"#"==n?(t.eatWhile(/[\w\\\-]/),w("atom","hash")):"!"==n?(t.match(/^\s*\w*/),w("keyword","important")):/\d/.test(n)||"."==n&&t.eat(/\d/)?(t.eatWhile(/[\w.%]/),w("number","unit")):"-"!==n?/[,+>*\/]/.test(n)?w(null,"select-op"):"."==n&&t.match(/^-?[_a-z][_a-z0-9-]*/i)?w("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(n)?w(null,n):("u"==n||"U"==n)&&t.match(/rl(-prefix)?\(/i)||("d"==n||"D"==n)&&t.match("omain(",!0,!0)||("r"==n||"R"==n)&&t.match("egexp(",!0,!0)?(t.backUp(1),e.tokenize=k,w("property","word")):/[\w\\\-]/.test(n)?(t.eatWhile(/[\w\\\-]/),w("property","word")):w(null,null):/[\d.]/.test(t.peek())?(t.eatWhile(/[\w.%]/),w("number","unit")):t.match(/^-[\w\\\-]+/)?(t.eatWhile(/[\w\\\-]/),t.match(/^\s*:/,!1)?w("variable-2","variable-definition"):w("variable-2","variable")):t.match(/^\w+-/)?w("meta","meta"):void 0})(t,e);return n&&"object"==typeof n&&(r=n[1],n=n[0]),o=n,"comment"!=r&&(e.state=P[e.state](r,t,e)),o},indent:function(t,e){var n=t.context,i=e&&e.charAt(0),r=n.indent;return"prop"!=n.type||"}"!=i&&")"!=i||(n=n.prev),n.prev&&("}"!=i||"block"!=n.type&&"top"!=n.type&&"interpolation"!=n.type&&"restricted_atBlock"!=n.type?(")"!=i||"parens"!=n.type&&"atBlock_parens"!=n.type)&&("{"!=i||"at"!=n.type&&"atBlock"!=n.type)||(r=Math.max(0,n.indent-s)):(n=n.prev,r=n.indent)),r},electricChars:"}",blockCommentStart:"/*",blockCommentEnd:"*/",blockCommentContinue:" * ",lineComment:b,fold:"brace"}});var n=["domain","regexp","url","url-prefix"],i=e(n),r=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],o=e(r),s=["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"],a=e(s),l=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive"],c=e(l),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"],h=e(u),d=["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=e(d),p=e(["font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"]),g=e(["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"]),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"],m=e(v),y=["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"],b=e(y),x=n.concat(r).concat(s).concat(l).concat(u).concat(d).concat(v).concat(y);function w(t,e){for(var n,i=!1;null!=(n=t.next());){if(i&&"/"==n){e.tokenize=null;break}i="*"==n}return["comment","comment"]}t.registerHelper("hintWords","css",x),t.defineMIME("text/css",{documentTypes:i,mediaTypes:o,mediaFeatures:a,mediaValueKeywords:c,propertyKeywords:h,nonStandardPropertyKeywords:f,fontProperties:p,counterDescriptors:g,colorKeywords:m,valueKeywords:b,tokenHooks:{"/":function(t,e){return!!t.eat("*")&&(e.tokenize=w,w(t,e))}},name:"css"}),t.defineMIME("text/x-scss",{mediaTypes:o,mediaFeatures:a,mediaValueKeywords:c,propertyKeywords:h,nonStandardPropertyKeywords:f,colorKeywords:m,valueKeywords:b,fontProperties:p,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(t,e){return t.eat("/")?(t.skipToEnd(),["comment","comment"]):t.eat("*")?(e.tokenize=w,w(t,e)):["operator","operator"]},":":function(t){return!!t.match(/\s*\{/,!1)&&[null,null]},$:function(t){return t.match(/^[\w-]+/),t.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(t){return!!t.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),t.defineMIME("text/x-less",{mediaTypes:o,mediaFeatures:a,mediaValueKeywords:c,propertyKeywords:h,nonStandardPropertyKeywords:f,colorKeywords:m,valueKeywords:b,fontProperties:p,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(t,e){return t.eat("/")?(t.skipToEnd(),["comment","comment"]):t.eat("*")?(e.tokenize=w,w(t,e)):["operator","operator"]},"@":function(t){return t.eat("{")?[null,"interpolation"]:!t.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(t.eatWhile(/[\w\\\-]/),t.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),t.defineMIME("text/x-gss",{documentTypes:i,mediaTypes:o,mediaFeatures:a,propertyKeywords:h,nonStandardPropertyKeywords:f,fontProperties:p,counterDescriptors:g,colorKeywords:m,valueKeywords:b,supportsAtComponent:!0,tokenHooks:{"/":function(t,e){return!!t.eat("*")&&(e.tokenize=w,w(t,e))}},name:"css",helperType:"gss"})}(n(6))},function(t,e,n){"use strict";t.exports=function(t){var e=t;return{compTypes:"",parseStyle:function(t){for(var e={},n=t.split(";"),i=0,r=n.length;i=0&&e<=k};function E(t){return function(e,n,i,r){n=y(n,r,4);var o=!T(e)&&m.keys(e),s=(o||e).length,a=t>0?0:s-1;return arguments.length<3&&(i=e[o?o[a]:a],a+=t),function(e,n,i,r,o,s){for(;o>=0&&o=0},m.invoke=function(t,e){var n=c.call(arguments,2),i=m.isFunction(e);return m.map(t,function(t){var r=i?e:t[e];return null==r?r:r.apply(t,n)})},m.pluck=function(t,e){return m.map(t,m.property(e))},m.where=function(t,e){return m.filter(t,m.matcher(e))},m.findWhere=function(t,e){return m.find(t,m.matcher(e))},m.max=function(t,e,n){var i,r,o=-1/0,s=-1/0;if(null==e&&null!=t)for(var a=0,l=(t=T(t)?t:m.values(t)).length;ao&&(o=i);else e=b(e,n),m.each(t,function(t,n,i){((r=e(t,n,i))>s||r===-1/0&&o===-1/0)&&(o=t,s=r)});return o},m.min=function(t,e,n){var i,r,o=1/0,s=1/0;if(null==e&&null!=t)for(var a=0,l=(t=T(t)?t:m.values(t)).length;ai||void 0===n)return 1;if(n0?0:r-1;o>=0&&o0?s=o>=0?o:Math.max(o+a,s):a=o>=0?Math.min(o+1,a):o+a+1;else if(n&&o&&a)return i[o=n(i,r)]===r?o:-1;if(r!=r)return(o=e(c.call(i,s,a),m.isNaN))>=0?o+s:-1;for(o=t>0?s:a-1;o>=0&&oe?(s&&(clearTimeout(s),s=null),a=c,o=t.apply(i,r),s||(i=r=null)):s||!1===n.trailing||(s=setTimeout(l,u)),o}},m.debounce=function(t,e,n){var i,r,o,s,a,l=function(){var c=m.now()-s;c=0?i=setTimeout(l,e-c):(i=null,n||(a=t.apply(o,r),i||(o=r=null)))};return function(){o=this,r=arguments,s=m.now();var c=n&&!i;return i||(i=setTimeout(l,e)),c&&(a=t.apply(o,r),o=r=null),a}},m.wrap=function(t,e){return m.partial(e,t)},m.negate=function(t){return function(){return!t.apply(this,arguments)}},m.compose=function(){var t=arguments,e=t.length-1;return function(){for(var n=e,i=t[e].apply(this,arguments);n--;)i=t[n].call(this,i);return i}},m.after=function(t,e){return function(){if(--t<1)return e.apply(this,arguments)}},m.before=function(t,e){var n;return function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=null),n}},m.once=m.partial(m.before,2);var L=!{toString:null}.propertyIsEnumerable("toString"),N=["valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"];function D(t,e){var n=N.length,i=t.constructor,r=m.isFunction(i)&&i.prototype||s,o="constructor";for(m.has(t,o)&&!m.contains(e,o)&&e.push(o);n--;)(o=N[n])in t&&t[o]!==r[o]&&!m.contains(e,o)&&e.push(o)}m.keys=function(t){if(!m.isObject(t))return[];if(f)return f(t);var e=[];for(var n in t)m.has(t,n)&&e.push(n);return L&&D(t,e),e},m.allKeys=function(t){if(!m.isObject(t))return[];var e=[];for(var n in t)e.push(n);return L&&D(t,e),e},m.values=function(t){for(var e=m.keys(t),n=e.length,i=Array(n),r=0;r":">",'"':""","'":"'","`":"`"},R=m.invert(F),j=function(t){var e=function(e){return t[e]},n="(?:"+m.keys(t).join("|")+")",i=RegExp(n),r=RegExp(n,"g");return function(t){return t=null==t?"":""+t,i.test(t)?t.replace(r,e):t}};m.escape=j(F),m.unescape=j(R),m.result=function(t,e,n){var i=null==t?void 0:t[e];return void 0===i&&(i=n),m.isFunction(i)?i.call(t):i};var z=0;m.uniqueId=function(t){var e=++z+"";return t?t+e:e},m.templateSettings={evaluate:/<%([\s\S]+?)%>/g,interpolate:/<%=([\s\S]+?)%>/g,escape:/<%-([\s\S]+?)%>/g};var V=/(.)^/,H={"'":"'","\\":"\\","\r":"r","\n":"n","\u2028":"u2028","\u2029":"u2029"},$=/\\|'|\r|\n|\u2028|\u2029/g,B=function(t){return"\\"+H[t]};m.template=function(t,e,n){!e&&n&&(e=n),e=m.defaults({},e,m.templateSettings);var i=RegExp([(e.escape||V).source,(e.interpolate||V).source,(e.evaluate||V).source].join("|")+"|$","g"),r=0,o="__p+='";t.replace(i,function(e,n,i,s,a){return o+=t.slice(r,a).replace($,B),r=a+e.length,n?o+="'+\n((__t=("+n+"))==null?'':_.escape(__t))+\n'":i?o+="'+\n((__t=("+i+"))==null?'':__t)+\n'":s&&(o+="';\n"+s+"\n__p+='"),e}),o+="';\n",e.variable||(o="with(obj||{}){\n"+o+"}\n"),o="var __t,__p='',__j=Array.prototype.join,print=function(){__p+=__j.call(arguments,'');};\n"+o+"return __p;\n";try{var s=new Function(e.variable||"obj","_",o)}catch(t){throw t.source=o,t}var a=function(t){return s.call(this,t,m)},l=e.variable||"obj";return a.source="function("+l+"){\n"+o+"}",a},m.chain=function(t){var e=m(t);return e._chain=!0,e};var W=function(t,e){return t._chain?m(e).chain():e};m.mixin=function(t){m.each(m.functions(t),function(e){var n=m[e]=t[e];m.prototype[e]=function(){var t=[this._wrapped];return l.apply(t,arguments),W(this,n.apply(m,t))}})},m.mixin(m),m.each(["pop","push","reverse","shift","sort","splice","unshift"],function(t){var e=o[t];m.prototype[t]=function(){var n=this._wrapped;return e.apply(n,arguments),"shift"!==t&&"splice"!==t||0!==n.length||delete n[0],W(this,n)}}),m.each(["concat","join","slice"],function(t){var e=o[t];m.prototype[t]=function(){return W(this,e.apply(this._wrapped,arguments))}}),m.prototype.value=function(){return this._wrapped},m.prototype.valueOf=m.prototype.toJSON=m.prototype.value,m.prototype.toString=function(){return""+this._wrapped},void 0===(i=function(){return m}.apply(e,[]))||(t.exports=i)}).call(this)},function(t,e,n){!function(e){var n,i={},r={16:!1,18:!1,17:!1,91:!1},o="all",s={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,command:91},a={backspace:8,tab:9,clear:12,enter:13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,del:46,delete:46,home:36,end:35,pageup:33,pagedown:34,",":188,".":190,"/":191,"`":192,"-":189,"=":187,";":186,"'":222,"[":219,"]":221,"\\":220},l=function(t){return a[t]||t.toUpperCase().charCodeAt(0)},c=[];for(n=1;n<20;n++)a["f"+n]=111+n;function u(t,e){for(var n=t.length;n--;)if(t[n]===e)return n;return-1}function h(t,e){if(t.length!=e.length)return!1;for(var n=0;n1&&(o=m(t),t=[t[t.length-1]]),t=t[0],(t=l(t))in i||(i[t]=[]),i[t].push({shortcut:r[s],scope:e,method:n,key:r[s],mods:o})}for(n in s)p[n]=!1;function g(){return o||"all"}function v(t){var e;return""==(e=(t=t.replace(/\s/g,"")).split(","))[e.length-1]&&(e[e.length-2]+=","),e}function m(t){for(var e=t.slice(0,t.length-1),n=0;n0,r)(!r[o]&&u(n.mods,+o)>-1||r[o]&&-1==u(n.mods,+o))&&(l=!1);(0!=n.mods.length||r[16]||r[18]||r[17]||r[91])&&!l||!1===n.method(t,n)&&(t.preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation&&t.stopPropagation(),t.cancelBubble&&(t.cancelBubble=!0))}}(t)}),y(document,"keyup",function(t){var e,n=t.keyCode,i=u(c,n);if(i>=0&&c.splice(i,1),93!=n&&224!=n||(n=91),n in r)for(e in r[n]=!1,s)s[e]==n&&(p[e]=!1)}),y(window,"focus",function(){for(n in r)r[n]=!1;for(n in s)p[n]=!1});var b=e.key;e.key=p,e.key.setScope=function(t){o=t||"all"},e.key.getScope=g,e.key.deleteScope=function(t){var e,n,r;for(e in i)for(n=i[e],r=0;r1&&(c=m(r),t=r[r.length-1]),t=l(t),void 0===e&&(e=g()),!i[t])return;for(o=0;o\n \n <%= label %>\n
\n
\n '),events:{},initialize:function(){arguments.length>0&&void 0!==arguments[0]&&arguments[0];var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.config=t;var e=this.config.pStylePrefix||"";this.pfx=e,this.caretR="fa fa-caret-right",this.caretD="fa fa-caret-down",this.iconClass=e+"caret-icon",this.activeClass=e+"open",this.className=e+"block-category",this.events["click ."+e+"title"]="toggle",this.listenTo(this.model,"change:open",this.updateVisibility),this.delegateEvents()},updateVisibility:function(){this.model.get("open")?this.open():this.close()},open:function(){this.el.className=this.className+" "+this.activeClass,this.getIconEl().className=this.iconClass+" "+this.caretD,this.getBlocksEl().style.display=""},close:function(){this.el.className=this.className,this.getIconEl().className=this.iconClass+" "+this.caretR,this.getBlocksEl().style.display="none"},toggle:function(){var t=this.model;t.set("open",!t.get("open"))},getIconEl:function(){return this.iconEl||(this.iconEl=this.el.querySelector("."+this.iconClass)),this.iconEl},getBlocksEl:function(){return this.blocksEl||(this.blocksEl=this.el.querySelector("."+this.pfx+"blocks-c")),this.blocksEl},append:function(t){this.getBlocksEl().appendChild(t)},render:function(){return this.el.innerHTML=this.template({pfx:this.pfx,label:this.model.get("label")}),this.el.className=this.className,this.$el.css({order:this.model.get("order")}),this.updateVisibility(),this}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)),r=n(1),o=n(2);t.exports=i.default.View.extend({events:{mousedown:"startDrag",dragstart:"handleDragStart",drag:"handleDrag",dragend:"handleDragEnd"},initialize:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.em=e.em,this.config=e,this.endDrag=this.endDrag.bind(this),this.ppfx=e.pStylePrefix||"",this.listenTo(this.model,"destroy remove",this.remove)},startDrag:function(t){var e=this.config;if(0===t.button&&e.getSorter&&!this.el.draggable){e.em.refreshCanvas();var n=e.getSorter();n.setDragHelper(this.el,t),n.setDropContent(this.model.get("content")),n.startSort(this.el),(0,o.on)(document,"mouseup",this.endDrag)}},handleDragStart:function(t){var e=this.em,n=this.model,i=n.get("content"),o=(0,r.isObject)(i),s=o?JSON.stringify(i):i;t.dataTransfer.setData("text",s),e.set("dragContent",i),e.trigger("block:drag:start",n,t)},handleDrag:function(t){this.em.trigger("block:drag",this.model,t)},handleDragEnd:function(){var t=this.em,e=this.model,n=t.get("dragResult");if(n){var i=n.get&&n.get("activeOnRender");(e.get("activate")||i)&&(n.trigger("active"),n.set("activeOnRender",0)),e.get("select")&&t.setSelected(n),e.get("resetId")&&n.onAll(function(t){return t.resetId()})}t.set({dragResult:null,dragContent:null}),t.trigger("block:drag:stop",n,e)},endDrag:function(t){(0,o.off)(document,"mouseup",this.endDrag);var e=this.config.getSorter();e.moved=0,e.endMove()},render:function(){var t=this.el,e=this.ppfx,n=e+"block",i=this.model.get("label");return t.className+=" "+n+" "+e+"one-bg "+e+"four-color-h",t.innerHTML='
'+i+"
",t.title=t.textContent.trim(),(0,o.hasDnd)(this.em)&&t.setAttribute("draggable",!0),this}})},function(t,e,n){"use strict";var i=n(1),r=n(92),o=n(91);t.exports=n(0).View.extend({initialize:function(t,e){(0,i.bindAll)(this,"getSorter","onDrag","onDrop"),this.config=e||{},this.categories=t.categories||"",this.renderedCategories=[];var n=this.config.pStylePrefix||"";this.ppfx=n,this.noCatClass=n+"blocks-no-cat",this.blockContClass=n+"blocks-c",this.catsClass=n+"block-categories";var r=this.collection;this.listenTo(r,"add",this.addTo),this.listenTo(r,"reset",this.render),this.em=this.config.em,this.tac="test-tac",this.grabbingCls=this.ppfx+"grabbing",this.em&&(this.config.getSorter=this.getSorter,this.canvas=this.em.get("Canvas"))},getSorter:function(){if(this.em){if(!this.sorter){var t=this.em.get("Utils"),e=this.canvas;this.sorter=new t.Sorter({container:e.getBody(),placer:e.getPlacerEl(),containerSel:"*",itemSel:"*",pfx:this.ppfx,onStart:this.onDrag,onEndMove:this.onDrop,onMove:this.onMove,document:e.getFrameEl().contentDocument,direction:"a",wmargin:1,nested:1,em:this.em,canvasRelative:1})}return this.sorter}},onDrag:function(t){this.em.stopDefault(),this.em.trigger("block:drag:start",t)},onMove:function(t){this.em.trigger("block:drag:move",t)},onDrop:function(t){var e=this.em;e.runDefault(),t&&t.get&&(t.get("activeOnRender")&&(t.trigger("active"),t.set("activeOnRender",0)),e.trigger("block:drag:stop",t))},addTo:function(t){this.add(t)},add:function(t,e){var n=e||null,s=new r({model:t,attributes:t.get("attributes")},this.config).render().el,a=t.get("category");if(a&&this.categories){(0,i.isString)(a)?a={id:a,label:a}:(0,i.isObject)(a)&&!a.id&&(a.id=a.label);var l=this.categories.add(a),c=l.get("id"),u=this.renderedCategories[c],h=this.getCategoriesEl();return t.set("category",l),!u&&h&&(u=new o({model:l},this.config).render(),this.renderedCategories[c]=u,h.appendChild(u.el)),void(u&&u.append(s))}n?n.appendChild(s):this.append(s)},getCategoriesEl:function(){return this.catsEl||(this.catsEl=this.el.querySelector("."+this.catsClass)),this.catsEl},getBlocksEl:function(){return this.blocksEl||(this.blocksEl=this.el.querySelector("."+this.noCatClass+" ."+this.blockContClass)),this.blocksEl},append:function(t){var e=this.getBlocksEl();e&&e.appendChild(t)},render:function(){var t=this,e=this.ppfx,n=document.createDocumentFragment();this.catsEl=null,this.blocksEl=null,this.renderedCategories=[],this.el.innerHTML='\n
\n
\n
\n
\n ',this.collection.each(function(e){return t.add(e,n)}),this.append(n);var i=this.blockContClass+"s "+e+"one-bg "+e+"two-color";return this.$el.addClass(i),this}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Collection.extend({model:n(44)})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(44);t.exports=i.default.Model.extend({defaults:{activate:0,select:0,resetId:0,label:"",content:"",category:"",attributes:{}},initialize:function(){arguments.length>0&&void 0!==arguments[0]&&arguments[0];var t=this.get("category");if(t&&"string"==typeof t)new r({id:t,label:t})}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(95);t.exports=i.default.Collection.extend({model:r})},function(t,e,n){"use strict";t.exports={appendTo:"",blocks:[]}},function(t,e,n){"use strict";var i=n(1);t.exports=function(){var t,e,r,o={},s=n(97),a=n(96),l=n(94),c=n(93),u=[];return{name:"BlockManager",init:function(n){var i=(o=n||{}).em;for(var h in s)h in o||(o[h]=s[h]);return t=new a([]),e=new a([]),u=new l,r=new c({collection:e,categories:u},o),t.listenTo(t,"add",function(t){e.add(t),i&&i.trigger("block:add",t)}),t.listenTo(t,"remove",function(t){e.remove(t),i&&i.trigger("block:remove",t)}),t.listenTo(t,"reset",function(t){e.reset(t.models)}),this},getConfig:function(){return o},onLoad:function(){var t=this.getAll();!t.length&&t.reset(o.blocks)},postRender:function(){var t=this.getConfig().appendTo;t&&((0,i.isElement)(t)?t:document.querySelector(t)).appendChild(this.render())},add:function(e,n){var i=n||{};return i.id=e,t.add(i)},get:function(e){return t.get(e)},getAll:function(){return t},getAllVisible:function(){return e},remove:function(e){return t.remove(e)},getCategories:function(){return u},getContainer:function(){return r.el},render:function(t){var e=t||this.getAll().models;return r.rendered||(r.render(),r.rendered=1),r.collection.reset(e),this.getContainer()}}}},function(t,e,n){var i={"./CanvasClear":52,"./CanvasClear.js":52,"./CommandAbstract":38,"./CommandAbstract.js":38,"./ComponentDelete":51,"./ComponentDelete.js":51,"./ComponentEnter":50,"./ComponentEnter.js":50,"./ComponentExit":49,"./ComponentExit.js":49,"./ComponentNext":48,"./ComponentNext.js":48,"./ComponentPrev":47,"./ComponentPrev.js":47,"./CopyComponent":46,"./CopyComponent.js":46,"./CreateComponent":7,"./CreateComponent.js":7,"./DeleteComponent":36,"./DeleteComponent.js":36,"./Drag":21,"./Drag.js":21,"./ExportTemplate":37,"./ExportTemplate.js":37,"./Fullscreen":24,"./Fullscreen.js":24,"./ImageComponent":35,"./ImageComponent.js":35,"./InsertCustom":12,"./InsertCustom.js":12,"./MoveComponent":34,"./MoveComponent.js":34,"./OpenAssets":27,"./OpenAssets.js":27,"./OpenBlocks":28,"./OpenBlocks.js":28,"./OpenLayers":31,"./OpenLayers.js":31,"./OpenStyleManager":30,"./OpenStyleManager.js":30,"./OpenTraitManager":29,"./OpenTraitManager.js":29,"./PasteComponent":45,"./PasteComponent.js":45,"./Preview":23,"./Preview.js":23,"./Resize":22,"./Resize.js":22,"./SelectComponent":8,"./SelectComponent.js":8,"./SelectParent":25,"./SelectParent.js":25,"./SelectPosition":13,"./SelectPosition.js":13,"./ShowOffset":26,"./ShowOffset.js":26,"./SwitchVisibility":32,"./SwitchVisibility.js":32,"./TextComponent":33,"./TextComponent.js":33};function r(t){var e=o(t);return n(e)}function o(t){var e=i[t];if(!(e+1)){var n=new Error("Cannot find module '"+t+"'");throw n.code="MODULE_NOT_FOUND",n}return e}r.keys=function(){return Object.keys(i)},r.resolve=o,t.exports=r,r.id=99},function(t,e,n){"use strict";var i=n(0);t.exports=i.Model.extend({defaults:{command:"",attributes:{}}})},function(t,e,n){"use strict";var i=n(0),r=n(100);t.exports=i.Collection.extend({model:r})},function(t,e,n){"use strict";var i=n(0);t.exports=i.View.extend({events:function(){return this.model.get("events")||{mousedown:"handleClick"}},attributes:function(){return this.model.get("attributes")},initialize:function(t){this.editor=t.config.editor},handleClick:function(t){t.preventDefault(),t.stopPropagation(),this.execCommand(t)},execCommand:function(t){var e={event:t},n=this.model.get("command"),i=this.editor;"function"==typeof n&&n(i,null,e),"string"==typeof n&&i.runCommand(n,e)},render:function(){var t=this.editor,e=this.$el,n=this.model,i=n.get("id"),r=n.get("label"),o=t.getConfig("stylePrefix");return e.addClass(o+"toolbar-item"),i&&e.addClass(o+"toolbar-item__"+i),r&&e.append(r),this}})},function(t,e,n){"use strict";n(0);var i=n(59),r=n(102);t.exports=i.extend({itemView:r,initialize:function(t){this.config={editor:t.editor||""},this.listenTo(this.collection,"reset",this.render)}})},function(t,e,n){"use strict";t.exports={ESCAPE_KEY:27,stylePrefix:"com-",defaults:[],em:null,firstCentered:!0,newFixedH:!1,minComponentH:50,minComponentW:50}},function(t,e,n){"use strict";var i=n(1);t.exports=function(){var t=void 0,e={},r={},o={},s=n(104),a=n(38);return{CommandAbstract:a,name:"Commands",init:function(i){for(var r in e=i||{},s)r in e||(e[r]=s[r]);t=e.em;var a=e.pStylePrefix;for(var l in a&&(e.stylePrefix=a+e.stylePrefix),e.defaults){var c=e.defaults[l];c.id&&this.add(c.id,c)}var u=n(37);return o["select-comp"]=n(8),o["create-comp"]=n(7),o["delete-comp"]=n(36),o["image-comp"]=n(35),o["move-comp"]=n(34),o["text-comp"]=n(33),o["insert-custom"]=n(12),o["export-template"]=u,o["sw-visibility"]=n(32),o["open-layers"]=n(31),o["open-sm"]=n(30),o["open-tm"]=n(29),o["open-blocks"]=n(28),o["open-assets"]=n(27),o["show-offset"]=n(26),o["select-parent"]=n(25),o.fullscreen=n(24),o.preview=n(23),o.resize=n(22),o.drag=n(21),o["tlb-delete"]={run:function(t){return t.runCommand("core:component-delete")}},o["tlb-clone"]={run:function(t){t.runCommand("core:copy"),t.runCommand("core:paste")}},o["tlb-move"]={run:function(t,e,n){var i=void 0,r=t.getModel(),o=n&&n.event,s=t.getSelected(),a=[].concat(function(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e1&&void 0!==arguments[1]?arguments[1]:{},i=void 0,r=this.get(e),o=t.get("Editor");return r&&(i=r.callRun(o,n)),i},stop:function(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=void 0,r=this.get(e),o=t.get("Editor");return r&&(i=r.callStop(o,n)),i},loadDefaultCommands:function(){for(var t in o)this.add(t,o[t]);return this},create:function(t){return new(a.extend(t))(e)}}}},function(t,e,n){"use strict";var i=n(1),r="transitionend oTransitionEnd transitionend webkitTransitionEnd";t.exports=n(0).View.extend({tagName:"iframe",attributes:{allowfullscreen:"allowfullscreen"},initialize:function(t){(0,i.bindAll)(this,"udpateOffset"),this.config=t.config||{},this.ppfx=this.config.pStylePrefix||"",this.em=this.config.em,this.listenTo(this.em,"change:device",this.updateDim)},updateDim:function(t){var e=this.em,n=e.getDeviceModel(),i=this.el.style,o=i.width||"",s=i.height||"",a=n?n.get("width"):"",l=n?n.get("height"):"",c=o==a&&s==l;i.width=a,i.height=l,this.udpateOffset(),e.stopDefault({preserveSelected:1}),c?this.udpateOffset():this.$el.on(r,this.udpateOffset)},udpateOffset:function(){var t=this.em,e=t.get("Canvas").getOffset();t.set("canvasOffset",e),t.runDefault({preserveSelected:1}),this.$el.off(r,this.udpateOffset)},getBody:function(){this.$el.contents().find("body")},getWrapper:function(){return this.$el.contents().find("body > div")},render:function(){return this.$el.attr({class:this.ppfx+"frame"}),this}})},function(t,e,n){"use strict";(function(e){var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)),r=n(2);var o=n(106),s=i.default.$;t.exports=i.default.View.extend({initialize:function(t){e.bindAll(this,"renderBody","onFrameScroll","clearOff"),(0,r.on)(window,"scroll resize",this.clearOff),this.config=t.config||{},this.em=this.config.em||{},this.ppfx=this.config.pStylePrefix||"",this.className=this.config.stylePrefix+"canvas",this.listenTo(this.em,"change:canvasOffset",this.clearOff),this.frame=new o({model:this.model.get("frame"),config:this.config})},isElInViewport:function(t){var e=(0,r.getElement)(t).getBoundingClientRect(),n=this.getFrameOffset(1),i=e.top,o=e.left;return i>=0&&o>=0&&i<=n.height&&o<=n.width},onFrameScroll:function(){var t=this.frame.el.contentDocument.body;this.toolsEl.style.top="-"+t.scrollTop+"px",this.toolsEl.style.left="-"+t.scrollLeft+"px",this.em.trigger("canvasScroll")},renderScripts:function(){var t=this.frame,e=this;t.el.onload=function(){!function n(i){if(i.length>0){var r=document.createElement("script");r.type="text/javascript",r.src=i.shift(),r.onerror=r.onload=n.bind(null,i),t.el.contentDocument.head.appendChild(r)}else e.renderBody()}(e.config.scripts.slice(0))}},renderBody:function(){var t=this.model.get("frame").get("wrapper"),e=this.config.em;if(t){var n=this.ppfx,i=s(this.frame.el.contentWindow.document.body),r=e.get("CssComposer"),o=e.get("Config"),a=this.config,l=o.protectedCss,c="";a.styles.forEach(function(t){c+=''});var u="\n "+(e.config.baseCss||"")+"\n\n ."+n+"dashed *[data-highlightable] {\n outline: 1px dashed rgba(170,170,170,0.7);\n outline-offset: -2px;\n }\n\n ."+n+"comp-selected {\n outline: 3px solid #3b97e3 !important;\n outline-offset: -3px;\n }\n\n ."+n+"comp-selected-parent {\n outline: 2px solid #ffca6f !important\n }\n\n ."+n+"no-select {\n user-select: none;\n -webkit-user-select:none;\n -moz-user-select: none;\n }\n\n ."+n+"freezed {\n opacity: 0.5;\n pointer-events: none;\n }\n\n ."+n+"no-pointer {\n pointer-events: none;\n }\n\n ."+n+"plh-image {\n background: #f5f5f5;\n border: none;\n height: 50px;\n width: 50px;\n display: block;\n outline: 3px solid #ffca6f;\n cursor: pointer;\n outline-offset: -2px\n }\n\n ."+n+"grabbing {\n cursor: grabbing;\n cursor: -webkit-grabbing;\n }\n\n "+(o.canvasCss||"")+"\n "+(l||"")+"\n ";c&&i.append(c),i.append(""),i.append(t.render()).append(r.render()),i.append(this.getJsContainer()),e.trigger("loaded"),this.frame.el.contentWindow.onscroll=this.onFrameScroll,this.frame.udpateOffset();var h=document,d=this.frame.el.contentDocument;[{event:"keydown keyup",class:"KeyboardEvent"}].forEach(function(t){return t.event.split(" ").forEach(function(e){d.addEventListener(e,function(e){return h.dispatchEvent(function(t,e){var n=void 0;try{n=new window[e](t.type,t)}catch(t){(n=document.createEvent(e)).initEvent(t.type,!0,!0)}return n.keyCodeVal=t.keyCode,["keyCode","which"].forEach(function(t){Object.defineProperty(n,t,{get:function(){return this.keyCodeVal}})}),n}(e,t.class))})})})}},offset:function(t){var e=t.getBoundingClientRect(),n=t.ownerDocument.body;return{top:e.top+n.scrollTop,left:e.left+n.scrollLeft,width:e.width,height:e.height}},clearOff:function(){this.frmOff=null,this.cvsOff=null},getFrameOffset:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0;return this.frmOff&&!t||(this.frmOff=this.offset(this.frame.el)),this.frmOff},getCanvasOffset:function(){return this.cvsOff||(this.cvsOff=this.offset(this.el)),this.cvsOff},getElementPos:function(t,e){var n=e||{},i=this.getFrameOffset(),r=this.getCanvasOffset(),o=this.offset(t),s=n.avoidFrameOffset?0:i.top,a=n.avoidFrameOffset?0:i.left;return{top:o.top+s-r.top,left:o.left+a-r.left,height:t.offsetHeight||t.clientHeight,width:t.offsetWidth||t.clientWidth}},getPosition:function(){var t=this.frame.el.contentDocument;if(t){var e=t.body,n=this.getFrameOffset(),i=this.getCanvasOffset();return{top:n.top+e.scrollTop-i.top,left:n.left+e.scrollLeft-i.left}}},updateScript:function(t){t.scriptContainer||(t.scriptContainer=s("
"),this.getJsContainer().appendChild(t.scriptContainer.get(0)));var e=t.model,n=e.getId();t.el.id=n,t.scriptContainer.html("");var i=document.createElement("script");i.innerHTML="\n setTimeout(function() {\n var item = document.getElementById('"+n+"');\n if (!item) return;\n (function(){\n "+e.getScriptString()+";\n }.bind(item))()\n }, 1);",setTimeout(function(){return t.scriptContainer.get(0).appendChild(i)},0)},getJsContainer:function(){return this.jsContainer||(this.jsContainer=s('
').get(0)),this.jsContainer},render:function(){if(this.wrapper=this.model.get("wrapper"),this.wrapper&&"function"==typeof this.wrapper.render){this.model.get("frame").set("wrapper",this.wrapper),this.$el.append(this.frame.render().el);var t=this.frame;0===this.config.scripts.length?t.el.onload=this.renderBody:this.renderScripts()}var e=this.ppfx;this.$el.append('\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n
\n ');var n=this.el,i=n.querySelector("#"+e+"tools");return this.hlEl=n.querySelector("."+e+"highlighter"),this.badgeEl=n.querySelector("."+e+"badge"),this.placerEl=n.querySelector("."+e+"placeholder"),this.ghostEl=n.querySelector("."+e+"ghost"),this.toolbarEl=n.querySelector("."+e+"toolbar"),this.resizerEl=n.querySelector("."+e+"resizer"),this.offsetEl=n.querySelector("."+e+"offset-v"),this.fixedOffsetEl=n.querySelector("."+e+"offset-fixed-v"),this.toolsEl=i,this.el.className=this.className,this}})}).call(this,n(1))},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Model.extend({defaults:{wrapper:"",width:"",height:"",attributes:{}}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(108);t.exports=i.default.Model.extend({defaults:{frame:"",wrapper:"",rulers:!1},initialize:function(t){var e=this.conf||{};this.set("frame",new r(e.frame))}})},function(t,e,n){"use strict";t.exports={stylePrefix:"cv-",rulers:!1,scripts:[],styles:[],customBadgeLabel:""}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(t,e){for(var n=0;n";this.sorter.setDropContent(o),this.sorter.startSort(),e.trigger("canvas:dragenter",n,o)}}},{key:"handleDragOver",value:function(t){t.preventDefault(),this.em.trigger("canvas:dragover",t)}},{key:"handleDrop",value:function(t){t.preventDefault();var e=t.dataTransfer,n=this.getContentByData(e).content;t.target.style.border="",n?this.sorter.setDropContent(n):this.sorter.moved=0,this.endDrop(0,t)}},{key:"getContentByData",value:function(t){var e=this.em,n=t.types,i=t.files,r=e.get("dragContent"),s=t.getData("text");if(i.length){s=[];for(var a=0;a=0)s=t.getData("text/html").replace(/<\/?meta[^>]*>/g,"");else if((0,o.indexOf)(n,"text/uri-list")>=0)s={type:"link",attributes:{href:s},content:s};else if((0,o.indexOf)(n,"text/json")>=0){var u=t.getData("text/json");u&&(s=JSON.parse(u))}var h={content:s};return e.trigger("canvas:dragdata",t,h),h}}]),t}();e.default=s},function(t,e,n){"use strict";var i=n(2),r=function(t){return t&&t.__esModule?t:{default:t}}(n(111));t.exports=function(){var t,e,o={},s=n(110),a=n(109),l=n(107);return{getCanvasView:function(){return l},name:"Canvas",init:function(e){for(var n in o=e||{},s)n in o||(o[n]=s[n]);var i=o.pStylePrefix;i&&(o.stylePrefix=i+o.stylePrefix),t=new a(e),l=new l({model:t,config:o});var r=o.em.get("DomComponents");return r&&this.setWrapper(r),this.startAutoscroll=this.startAutoscroll.bind(this),this.stopAutoscroll=this.stopAutoscroll.bind(this),this.autoscroll=this.autoscroll.bind(this),this},getConfig:function(){return o},setWrapper:function(e){t.set("wrapper",e)},getElement:function(){return l.el},getFrameEl:function(){return l.frame.el},getDocument:function(){return this.getFrameEl().contentDocument},getWindow:function(){return this.getFrameEl().contentWindow},getBody:function(){return l.frame.el.contentDocument.body},getWrapperEl:function(){return this.getBody().querySelector("#wrapper")},getToolsEl:function(){return l.toolsEl},getHighlighter:function(){return l.hlEl},getBadgeEl:function(){return l.badgeEl},getPlacerEl:function(){return l.placerEl},getGhostEl:function(){return l.ghostEl},getToolbarEl:function(){return l.toolbarEl},getResizerEl:function(){return l.resizerEl},getOffsetViewerEl:function(){return l.offsetEl},getFixedOffsetViewerEl:function(){return l.fixedOffsetEl},render:function(){return l.render().el},getOffset:function(){var t=this.offset(this.getFrameEl()),e=this.offset(this.getElement());return{top:t.top-e.top,left:t.left-e.left}},offset:function(t){return l.offset(t)},setCustomBadgeLabel:function(t){o.customBadgeLabel=t},getElementPos:function(t,e){return l.getElementPos(t,e)},getTargetToElementDim:function(t,e,n){var i=n||{},r=l.getPosition();if(r){var s=i.elPos||l.getElementPos(e),a=n.toRight||0,c=i.targetHeight||t.offsetHeight,u=i.targetWidth||t.offsetWidth,h=i.event||null,d=s.top-c,f=s.left;f+=a?s.width:0;var p=(f=a?f-u:f)s.top+s.height?s.top+s.height:g,left:p,elementTop:s.top,elementLeft:s.left,elementWidth:s.width,elementHeight:s.height,targetWidth:t.offsetWidth,targetHeight:t.offsetHeight,canvasTop:r.top,canvasLeft:r.left};return h&&o.em&&o.em.trigger(h,v),v}},getMouseRelativePos:function(t,e){var n=0,i=0,r=(e||{}).subWinOffset,o=t.target.ownerDocument,s=o.defaultView||o.parentWindow,a=s.frameElement,l=r?s.pageYOffset:0,c=r?s.pageXOffset:0;if(a){var u=a.getBoundingClientRect();n=u.top||0,i=u.left||0}return{y:t.clientY+n-l,x:t.clientX+i-c}},getMouseRelativeCanvas:function(t,e){var n=this.getFrameEl(),i=this.getBody(),r=n.offsetTop||0,o=n.offsetLeft||0,s=i.scrollTop||0,a=i.scrollLeft||0;return{y:t.clientY+r+s,x:t.clientX+o+a}},hasFocus:function(){return this.getDocument().hasFocus()},isInputFocused:function(){return"BODY"!==this.getFrameEl().contentDocument.activeElement.tagName},scrollTo:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(0,i.getElement)(t);this.getCanvasView().isElInViewport(n)&&!e.force||n.scrollIntoView(e)},startAutoscroll:function(){var t=this;this.dragging=1;var n=this.getScrollListeners();e=l.getFrameOffset(1),setTimeout(function(){(0,i.on)(n,"mousemove",t.autoscroll),(0,i.on)(n,"mouseup",t.stopAutoscroll)},0)},autoscroll:function(t){if(t.preventDefault(),this.dragging){var n=this.getFrameEl().contentWindow,i=n.document.body.scrollTop,r=t.clientY,o=e.height-50;r<50&&(i-=50-r),r>o&&(i+=r-o),n.scrollTo(0,i)}},stopAutoscroll:function(){this.dragging=0;var t=this.getScrollListeners();(0,i.off)(t,"mousemove",this.autoscroll),(0,i.off)(t,"mouseup",this.stopAutoscroll)},getScrollListeners:function(){return[this.getFrameEl().contentWindow,this.getElement()]},postRender:function(){(0,i.hasDnd)(o.em)&&(this.droppable=new r.default(o.em))},getFrameWrapperEl:function(){return l.frame.getWrapper()}}}},function(t,e,n){"use strict";var i=n(53);t.exports=n(0).View.extend({initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.opt=t;var e=t.config||{};this.level=t.level,this.config=e,this.preview=t.preview,this.ppfx=e.pStylePrefix||"",this.pfx=e.stylePrefix||"",this.parent=t.parent;var n=this.pfx,i=this.ppfx,r=this.parent,o=this.collection;this.listenTo(o,"add",this.addTo),this.listenTo(o,"reset resetNavigator",this.render),this.listenTo(o,"remove",this.removeChildren),this.className=n+"layers";var s=e.em;if(e.sortable&&!this.opt.sorter){var a=s.get("Utils");this.opt.sorter=new a.Sorter({container:e.sortContainer||this.el,containerSel:"."+this.className,itemSel:"."+n+"layer",ignoreViewChildren:1,onEndMove:function(t,e){var n=e.getSourceModel();s.setSelected(n,{forceChange:1})},avoidSelectOnEnd:1,nested:1,ppfx:i,pfx:n})}this.sorter=this.opt.sorter||"",this.$el.data("collection",o),r&&this.$el.data("model",r)},removeChildren:function(t){var e=t.viewLayer;e&&e.remove.apply(e)},addTo:function(t){var e=this.collection.indexOf(t);this.addToCollection(t,null,e)},addToCollection:function(t,e,n){var r=this.level,o=e||null,s=i;if(this.isCountable(t,this.config.hideTextnode)){var a=new s({level:r,model:t,config:this.config,sorter:this.sorter,isCountable:this.isCountable,opened:this.opt.opened}).render().el;if(o)o.appendChild(a);else if(void 0!==n){var l="before";this.$el.children().length==n&&(n--,l="after"),n<0?this.$el.append(a):this.$el.children().eq(n)[l](a)}else this.$el.append(a);return a}},isCountable:function(t,e){var n=t.get("type"),i=t.get("tagName");return!(("textnode"==n||"br"==i)&&e||!t.get("layerable"))},render:function(){var t=this,e=document.createDocumentFragment(),n=this.el;return n.innerHTML="",this.collection.each(function(n){return t.addToCollection(n,e)}),n.appendChild(e),n.className=this.className,this}})},function(t,e,n){"use strict";t.exports={stylePrefix:"",appendTo:"",sortable:1,hidable:1,hideTextnode:1,root:"",showWrapper:1,showHover:1,scrollCanvas:{behavior:"smooth"},scrollLayers:1,highlightHover:1}},function(t,e,n){"use strict";t.exports=n(0).View.extend({})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};return{build:function(e){var n=[];"string"==typeof e&&(e=[e]);for(var i=0;i1&&void 0!==arguments[1]?arguments[1]:{},n=this.target,o=this.get("name");if(!(0,r.isUndefined)(t))if(this.get("changeProp"))n.set(o,t,e);else{var s=i({},n.get("attributes"));s[o]=t,n.set("attributes",s,e)}},setValueFromInput:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r={value:t};this.set(r,i({},n,{avoidStore:1})),e&&(this.set("value","",n),this.set(r,n))},getInitValue:function(){var t=this.target,e=this.get("name"),n=void 0;if(t){var i=t.get("attributes");n=this.get("changeProp")?t.get(e):i[e]}return n||this.get("value")||this.get("default")}})},function(t,e,n){"use strict";var i=n(1),r=n(0),o=n(140),s=n(139);t.exports=r.Collection.extend({model:o,initialize:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.em=e.em||"",this.listenTo(this,"add",this.handleAdd)},handleAdd:function(t){var e=this.target;e&&(t.target=e)},setTarget:function(t){this.target=t},add:function(t,e){var n=this.em;if((0,i.isString)(t)||(0,i.isArray)(t)){var o=n&&n.get&&n.get("TraitManager"),a=o&&o.getConfig(),l=s(a);(0,i.isString)(t)&&(t=[t]);for(var c=0,u=t.length;c2&&void 0!==arguments[2]?arguments[2]:{},r=t.components(),o=s.get("UndoManager"),a=s.handleUpdates.bind(s),l=this.handleChanges.bind(this),c=this.handleRemoves.bind(this);o&&o.add(t),o&&r&&o.add(r);[[t,"change:style change:content change:attributes change:src",a],[r,"add",l],[r,"remove",c],[t.get("classes"),"add remove",a]].forEach(function(t){s.stopListening(t[0],t[1],t[2]),s.listenTo(t[0],t[1],t[2])}),!i.avoidStore&&a("","",i),r.each(function(t){return n.handleChanges(t,e,i)})},handleRemoves:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};!n.avoidStore&&s.handleUpdates(t,e,n)},load:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",e="";if(!t&&o.stm&&(t=o.em.getCacheLoad()),t.components)try{e=JSON.parse(t.components)}catch(t){}else t.html&&(e=t.html);var n=e&&e.constructor===Object;return(e&&e.length||n)&&(this.clear(),this.getComponents().reset(),n?this.getWrapper().set(e).initComponents().initClasses().loadTraits():this.getComponents().add(e)),e},store:function(t){if(o.stm){var e={},n=this.storageKey();if(n.indexOf("html")>=0&&(e.html=o.em.getHtml()),n.indexOf("components")>=0){var i=o.storeWrapper?this.getWrapper():this.getComponents();e.components=JSON.stringify(i)}return t||o.stm.store(e),e}},getComponent:function(){return t},getWrapper:function(){return this.getComponent()},getComponents:function(){return this.getWrapper().get("components")},addComponent:function(t){return this.getComponents().add(t)},render:function(){return e.render().el},clear:function(){return this.getComponents().reset(),this},setComponents:function(t){this.clear().addComponent(t)},addType:function(t,e){var n=this.getType(t);n?(n.model=e.model,n.view=e.view):(e.id=t,d.unshift(e))},getType:function(t){for(var e=d,n=0;n1&&void 0!==arguments[1]?arguments[1]:{};t&&(t.set({status:"selected"}),["component:selected","component:toggled"].forEach(function(i){return e.em.trigger(i,t,n)}))},selectRemove:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(t){this.em;t.set({status:"",state:""}),["component:deselected","component:toggled"].forEach(function(i){return e.em.trigger(i,t,n)})}},componentHovered:function(){var t=o.em,e=t.get("componentHovered"),n=t.previous("componentHovered");n&&"hovered"==n.get("status")&&n.set({status:"",state:""}),e&&(0,r.isEmpty)(e.get("status"))&&e.set("status","hovered")}}}},function(t,e,n){"use strict";var i=n(9),r=n(69);t.exports=i.extend({getInputEl:function(){if(!this.$input){var t=this.model,e=this.getModelValue(),n=new r({model:t,target:this.config.em,contClass:this.ppfx+"field-color",ppfx:this.ppfx}).render();this.$input=n.colorEl,n.setValue(e,{fromTarget:1}),this.input=n}return this.$input.get(0)},renderField:function(){this.$input||(this.getInputEl(),this.$el.append(this.input.el))}})},function(t,e,n){"use strict";var i=n(9),r=n(42);t.exports=i.extend({getValueForTarget:function(){var t=this.model,e=t.get("value"),n=t.get("unit");return e?e+n:""},getInputEl:function(){if(!this.$input){var t=this.getModelValue(),e=new r({contClass:this.ppfx+"field-int",model:this.model,ppfx:this.ppfx});this.input=e.render(),this.$input=this.input.inputEl,this.$unit=this.input.unitEl,this.model.set("value",t),this.$input.val(t)}return this.$input.get(0)},renderField:function(){this.$input||(this.$el.append(this.tmpl),this.getInputEl(),this.$el.find("."+this.inputhClass).prepend(this.input.el))}})},function(t,e,n){"use strict";var i=n(9);t.exports=i.extend({initialize:function(t){i.prototype.initialize.apply(this,arguments);var e=this.ppfx+"chk-icon";this.tmpl='
'},onChange:function(){this.model.set("value",this.getInputEl().checked)},getInputEl:function(){var t;this.$input||(t=1);for(var e=arguments.length,n=Array(e),r=0;r
'},getInputEl:function(){if(!this.$input){var t=this.model,n=t.get("options")||[],i="",this.input=i,this.$input=r(this.input);var o=this.target,s=t.get("name"),a=t.get("value");if(t.get("changeProp"))a=a||o.get(s);else a=o.get("attributes")[s];a&&this.$input.val(a)}return this.$input.get(0)}})}).call(this,n(1))},function(t,e,n){"use strict";var i=n(59),r=n(9),o=n(147),s=n(146),a=n(145),l=n(144);t.exports=i.extend({itemView:r,itemsView:{text:r,number:a,select:o,checkbox:s,color:l},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=t.config||{};this.config=e,this.em=t.editor,this.pfx=e.stylePrefix||"",this.ppfx=e.pStylePrefix||"",this.className=this.pfx+"traits";this.listenTo(this.em,"component:toggled",this.updatedCollection),this.updatedCollection()},updatedCollection:function(){var t=this.ppfx,e=this.em.getSelected();this.el.className=this.className+" "+t+"one-bg "+t+"two-color",e&&(this.collection=e.get("traits"),this.render())}})},function(t,e,n){"use strict";t.exports={stylePrefix:"trt-",appendTo:"",labelContainer:"Component settings",labelPlhText:"eg. Text here",labelPlhHref:"eg. https://google.com",optionsTarget:[{value:"",name:"This window"},{value:"_blank",name:"New window"}],textNoElement:"Select an element before using Trait Manager"}},function(t,e,n){"use strict";var i=n(1),r=n(149),o=n(148);t.exports=function(){var t={},e=void 0;return{TraitsView:o,name:"TraitManager",getConfig:function(){return t},init:function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};t=n,(0,i.defaults)(t,r);var s=t.pStylePrefix;return s&&(t.stylePrefix=""+s+t.stylePrefix),e=new o({collection:[],editor:t.em,config:t}),this},postRender:function(){var t=this.getConfig().appendTo;t&&((0,i.isElement)(t)?t:document.querySelector(t)).appendChild(this.render())},getTraitsViewer:function(){return e},addType:function(t,n){var i=e.itemView;e.itemsView[t]=i.extend(n)},getType:function(t){return e.itemsView[t]},render:function(){return e.render().el}}}},function(t,e,n){"use strict";t.exports=n(60).extend({_createElement:function(t){return document.createTextNode("")},render:function(){var t=this.model,e=t.get("important");return this.el.textContent=t.getDeclaration({important:e}),this}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(60),o=n(151),s=i.default.$,a=function(t,e){return t+(e?"-"+e.replace("%","pc"):"")};t.exports=i.default.View.extend({initialize:function(t){var e=t.config||{};this.atRules={},this.config=e,this.em=e.em,this.pfx=e.stylePrefix||"",this.className=this.pfx+"rules";var n=this.collection;this.listenTo(n,"add",this.addTo),this.listenTo(n,"reset",this.render)},addTo:function(t){this.addToCollection(t)},addToCollection:function(t,e){if(this.renderStarted){var n=e||null,i=void 0,s=void 0,l={model:t,config:this.config};if("keyframes"===t.get("atRuleType")){var c=t.getAtRule(),u=this.atRules[c];if(!u){var h=document.createElement("style");u=document.createTextNode(""),h.appendChild(document.createTextNode(c+"{")),h.appendChild(u),h.appendChild(document.createTextNode("}")),this.atRules[c]=u,i=h}s=new o(l),u.appendData(s.render().el.textContent)}else i=(s=new r(l)).render().el;var d=this.className,f=t.get("mediaText"),p=a(d),g=p;if(f&&(g=a(d,this.getMediaWidth(f))),i){var v=n||this.el,m=void 0;try{m=v.querySelector("#"+g)}catch(t){}m||(m=v.querySelector("#"+p)),m.appendChild(i)}return i}},getMediaWidth:function(t){return t&&t.replace("("+this.em.getConfig("mediaCondition")+": ","").replace(")","")},render:function(){var t=this;this.renderStarted=1,this.atRules={};var e=this.$el,n=document.createDocumentFragment(),i=this.className;return e.empty(),this.em.get("DeviceManager").getAll().map(function(t){return t.get("widthMedia")}).sort(function(t,e){return(e&&e.replace("px","")||Number.MAX_VALUE)-(t&&t.replace("px","")||Number.MAX_VALUE)}).forEach(function(t){s('
').appendTo(n)}),this.collection.each(function(e){return t.addToCollection(e,n)}),e.append(n),e.attr("class",i),this}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(62);t.exports=i.default.Collection.extend({initialize:function(t,e){e&&e.em&&(this.editor=e.em),this.model=function(t,n){return!n.em&&e&&e.em&&(n.em=e.em),new r(t,n)}},add:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return"string"==typeof t&&(t=this.editor.get("Parser").parseCss(t)),e.em=this.editor,i.default.Collection.prototype.add.apply(this,[t,e])}})},function(t,e,n){"use strict";t.exports={stylePrefix:"css-",staticRules:"",rules:[]}},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},n="change:style",i=o.get("UndoManager");i&&i.add(t);var r=o.handleUpdates.bind(o);o.stopListening(t,n,r),o.listenTo(t,n,r),!e.avoidStore&&r("","",e)},load:function(e){var n=e||"";!n&&s.stm&&(n=s.em.getCacheLoad());var i=n.styles||"";if(n.styles)try{i=JSON.parse(n.styles)}catch(t){}else n.css&&(i=s.em.get("Parser").parseCss(n.css));return(0,r.isArray)(i)?i.length&&t.reset(i):i&&t.reset(i),i},store:function(e){if(s.stm){var n={},i=this.storageKey();return i.indexOf("css")>=0&&(n.css=s.em.getCss()),i.indexOf("styles")>=0&&(n.styles=JSON.stringify(t)),e||s.stm.store(n),n}},add:function(e,n,r){var o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},a=n||"",c=r||"",u=i({},o),h=this.get(e,a,c,u);return h&&h.config&&!h.config.atRuleType?h:(u.state=a,u.mediaText=c,u.selectors="",(h=new l(u,s)).get("selectors").add(e),t.add(h),h)},get:function(e,n,i,r){var o=null;return t.each(function(t){o||t.compare(e,n,i,r)&&(o=t)}),o},getAll:function(){return t},clear:function(){return this.getAll().reset(),this},addCollection:function(t){for(var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=[],r=t instanceof Array?t:[t],o=0,a=r.length;o1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=n.state||"",r=n.mediaText||o.getCurrentMedia(),s=o.get("SelectorManager").add({name:t,type:d.TYPE_ID}),a=this.add(s,i,r);return a.setStyle(e,n),a},getIdRule:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.state||"",i=e.mediaText||o.getCurrentMedia(),r=o.get("SelectorManager").get(t,d.TYPE_ID);return r&&this.get(r,n,i)},setClassRule:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=n.state||"",r=n.mediaText||o.getCurrentMedia(),s=o.get("SelectorManager").add({name:t,type:d.TYPE_CLASS}),a=this.add(s,i,r);return a.setStyle(e,n),a},getClassRule:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=e.state||"",i=e.mediaText||o.getCurrentMedia(),r=o.get("SelectorManager").get(t,d.TYPE_CLASS);return r&&this.get(r,n,i)},render:function(){return e.render().el}}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));n(64),n(65),n(63);t.exports=i.default.View.extend({events:{submit:"handleSubmit"},template:function(t){var e=t.pfx,n=t.ppfx;return'\n
\n
\n
\n
\n \n
\n \n
\n
\n
\n
\n
\n
\n '},initialize:function(t){this.options=t,this.config=t.config,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"";var e=this.collection;this.listenTo(e,"reset",this.renderAssets),this.listenTo(e,"add",this.addToAsset),this.listenTo(e,"remove",this.removedAsset),this.listenTo(e,"deselectAll",this.deselectAll)},handleSubmit:function(t){t.preventDefault();var e=this.getAddInput(),n=e.value.trim(),i=this.config.handleAdd;n&&(e.value="",this.getAssetsEl().scrollTop=0,i?i.bind(this)(n):this.options.globalCollection.add(n,{at:0}))},getAssetsEl:function(){return this.el.querySelector("."+this.pfx+"assets")},getAddInput:function(){return this.inputUrl&&this.inputUrl.value||(this.inputUrl=this.el.querySelector("."+this.pfx+"add-asset input")),this.inputUrl},removedAsset:function(t){this.collection.length||this.toggleNoAssets()},addToAsset:function(t){1==this.collection.length&&this.toggleNoAssets(1),this.addAsset(t)},addAsset:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null,n=this.collection,i=this.config,r=new t.typeView({model:t,collection:n,config:i}).render().el;if(e)e.appendChild(r);else{var o=this.getAssetsEl();o&&o.insertBefore(r,o.firstChild)}return r},toggleNoAssets:function(t){var e=this.$el.find("."+this.pfx+"assets");if(t)e.empty();else{var n=this.config.noAssets;n&&e.append(n)}},deselectAll:function(){var t=this.pfx;this.$el.find("."+t+"highlight").removeClass(t+"highlight")},renderAssets:function(){var t=this,e=document.createDocumentFragment(),n=this.$el.find("."+this.pfx+"assets");n.empty(),this.toggleNoAssets(this.collection.length),this.collection.each(function(n){return t.addAsset(n,e)}),n.append(e)},render:function(){var t=this.options.fu.render().el;return this.$el.empty(),this.$el.append(t).append(this.template(this)),this.el.className=this.ppfx+"asset-manager",this.renderAssets(),this.rendered=1,this}})},function(t,e,n){"use strict";t.exports=n(0).Model.extend({idAttribute:"src",defaults:{type:"",src:""},getFilename:function(){return this.get("src").split("/").pop()},getExtension:function(){return this.getFilename().split(".").pop()}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{};return void 0===e.at&&(e.at=0),s.add(t,e)},get:function(t){return s.where({src:t})[0]},getAll:function(){return s},getAllVisible:function(){return a.collection},remove:function(t){var e=this.get(t);return this.getAll().remove(e),this},store:function(e){var n={},i=JSON.stringify(this.getAll().toJSON());return n[this.storageKey]=i,!e&&t.stm&&t.stm.store(n),n},load:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.storageKey,n=t[e]||[];if("string"==typeof n)try{n=JSON.parse(t[e])}catch(t){}return n&&n.length&&this.getAll().reset(n),n},getContainer:function(){return a.el},getAssetsEl:function(){return a.el.querySelector("[data-el=assets]")},render:function(t){var e=t||this.getAll().models;return a.rendered||a.render(),a.collection.reset(e),this.getContainer()},addType:function(t,e){this.getAll().addType(t,e)},getType:function(t){return this.getAll().getType(t)},getTypes:function(){return this.getAll().getTypes()},AssetsView:function(){return a},FileUploader:function(){return l},onLoad:function(){this.getAll().reset(t.assets)},postRender:function(e){t.dropzone&&l.initDropzone(e)},setTarget:function(t){a.collection.target=t},onSelect:function(t){a.collection.onSelect=t},onClick:function(e){t.onClick=e},onDblClick:function(e){t.onDblClick=e}}}},function(t,e,n){"use strict";var i=o(n(1)),r=o(n(0));function o(t){return t&&t.__esModule?t:{default:t}}var s=n(16);t.exports=r.default.View.extend({template:i.default.template('\n
\n \n <%= label %>\n
'),events:{"click [data-sector-title]":"toggle"},initialize:function(t){this.config=t.config||{},this.pfx=this.config.stylePrefix||"",this.target=t.target||{},this.propTarget=t.propTarget||{},this.caretR="fa-caret-right",this.caretD="fa-caret-down";var e=this.model;this.listenTo(e,"change:open",this.updateOpen),this.listenTo(e,"updateVisibility",this.updateVisibility),this.listenTo(e,"destroy remove",this.remove)},updateVisibility:function(){var t;this.model.get("properties").each(function(e){e.get("visible")&&(t=1)}),this.el.style.display=t?"block":"none"},updateOpen:function(){this.model.get("open")?this.show():this.hide()},show:function(){this.$el.addClass(this.pfx+"open"),this.getPropertiesEl().style.display="",this.$caret.removeClass(this.caretR).addClass(this.caretD)},hide:function(){this.$el.removeClass(this.pfx+"open"),this.getPropertiesEl().style.display="none",this.$caret.removeClass(this.caretD).addClass(this.caretR)},getPropertiesEl:function(){return this.$el.find("."+this.pfx+"properties").get(0)},toggle:function(t){var e=this.model.get("open")?0:1;this.model.set("open",e)},render:function(){return this.$el.html(this.template({pfx:this.pfx,label:this.model.get("name")})),this.$caret=this.$el.find("#"+this.pfx+"caret"),this.renderProperties(),this.$el.attr("class",this.pfx+"sector no-select"),this.updateOpen(),this},renderProperties:function(){var t=this.model.get("properties");if(t){var e=new s({collection:t,target:this.target,propTarget:this.propTarget,config:this.config});this.$el.append(e.render().el)}}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},e=t.config||{};this.pfx=e.stylePrefix||"",this.ppfx=e.pStylePrefix||"",this.target=t.target||{},this.config=e;var n={};(0,o.extend)(n,r.default.Events);var s=document.body,a=document.createElement("el-"+(new Date).getTime());s.appendChild(a),n.computedDefault=i({},window.getComputedStyle(a)),s.removeChild(a),this.propTarget=n;var l=this.collection;this.listenTo(l,"add",this.addTo),this.listenTo(l,"reset",this.render),this.listenTo(this.target,"component:toggled component:update:classes component:update:state change:device",this.targetUpdated)},addTo:function(t){this.addToCollection(t)},targetUpdated:function(){var t=this.target,e=this.propTarget,n=t.getSelected();if(n){var i=t.get("Config").devicePreviewMode?"":n.get("state"),r=n.getEl();if(e.helper=null,r){var o=i?":"+i:null;e.computed=window.getComputedStyle(r,o)}n=t.get("StyleManager").getModelToStyle(n),i&&function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},i=t.get("CssComposer"),r=i.getAll(),o=i.getClassRule("hc-state");o?(r.remove(o),r.add(o)):o=i.setClassRule("hc-state"),o.set("important",1),o.setStyle(n),e.helper=o}(n.getStyle()),e.model=n,e.trigger("update")}},addToCollection:function(t,e){var n=e||null,i=new s({model:t,id:this.pfx+t.get("name").replace(" ","_").toLowerCase(),name:t.get("name"),properties:t.get("properties"),target:this.target,propTarget:this.propTarget,config:this.config}).render().el;return n?n.appendChild(i):this.$el.append(i),i},render:function(){var t=this,e=document.createDocumentFragment(),n=this.$el,i=this.pfx,r=this.ppfx;return n.empty(),this.collection.each(function(n){return t.addToCollection(n,e)}),n.append(e),n.addClass(i+"sectors "+r+"one-bg "+r+"two-color"),this}})},function(t,e,n){"use strict";n(0);t.exports=function(){return{build:function(t){var e=[];"string"==typeof t&&(t=[t]);for(var n=0,i=t.length;n\n \n
\n '},getSliderEl:function(){return this.slider||(this.slider=this.el.querySelector("input[type=range]")),this.slider},inputValueChanged:function(){var t=this.model,e=t.get("step");this.getInputEl().value=this.getSliderEl().value;var n=this.getInputValue()-e;t.set("value",n,{avoidStore:1}).set("value",n+e),this.elementUpdated()},inputValueChangedSoft:function(){this.getInputEl().value=this.getSliderEl().value,this.model.set("value",this.getInputValue(),{avoidStore:1}),this.elementUpdated()},setValue:function(t){this.getSliderEl().value=t,this.inputInst.setValue(t,{silent:1})},onRender:function(){r.prototype.onRender.apply(this,arguments),this.model.get("showInput")||(this.inputInst.el.style.display="none")}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e\n \n
\n
'+("Layer "+t.get("index"))+'
\n
\n \t
\n
\n
\n ⨯\n
\n
\n
\n '},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.model;this.stackModel=t.stackModel||{},this.config=t.config||{},this.pfx=this.config.stylePrefix||"",this.sorter=t.sorter||null,this.propsConfig=t.propsConfig||{},this.customPreview=t.onPreview,this.listenTo(e,"destroy remove",this.remove),this.listenTo(e,"change:active",this.updateVisibility),this.listenTo(e.get("properties"),"change",this.updatePreview),e.get("preview")||this.$el.addClass(this.pfx+"no-preview"),e.view=this,e.set({droppable:0,draggable:1}),this.$el.data("model",e)},initSorter:function(t){this.sorter&&this.sorter.startSort(this.el)},remove:function(t){t&&t.stopPropagation&&t.stopPropagation();var e=this.model,n=e.collection,r=this.stackModel;i.default.View.prototype.remove.apply(this,arguments),n.contains(e)&&n.remove(e),r&&r.set&&(r.set({stackIndex:null},{silent:!0}),r.trigger("updateValue"))},onPreview:function(t){var e=t.split(" "),n=[];return this.model.get("properties").each(function(t,i){var r=e[i]||"";if(r&&"integer"==t.get("type")){var o=parseInt(r,10),s=r.replace(o,"");r=(o=(o=(o=isNaN(o)?0:o)>3?3:o)<-3?-3:o)+s}n.push(r)}),n.join(" ")},updatePreview:function(){var t=this.stackModel,e=this.customPreview,n=this.getPreviewEl(),i=this.model.getFullValue(),r=e?e(i):this.onPreview(i);r&&t&&n&&(n.style[t.get("property")]=r)},getPropertiesWrapper:function(){return this.propsWrapEl||(this.propsWrapEl=this.el.querySelector("[data-properties]")),this.propsWrapEl},getPreviewEl:function(){return this.previewEl||(this.previewEl=this.el.querySelector("[data-preview]")),this.previewEl},active:function(){var t=this.model,e=t.collection;e.active(e.indexOf(t))},updateVisibility:function(){var t=this.pfx,e=this.getPropertiesWrapper(),n=this.model.get("active");e.style.display=n?"":"none",this.$el[n?"addClass":"removeClass"](t+"active")},render:function(){var t=n(16),e=this.propsConfig,i=this.pfx+"layer",r=this.model,o=this.el,s=new t({collection:r.get("properties"),config:this.config,target:e.target,customValue:e.customValue,propTarget:e.propTarget,onChange:e.onChange}).render().el;return o.innerHTML=this.template(r),o.className=i,this.getPropertiesWrapper().appendChild(s),this.updateVisibility(),this.updatePreview(),this}})},function(t,e,n){"use strict";var i=n(0),r=n(167);t.exports=i.View.extend({initialize:function(t){this.config=t.config||{},this.stackModel=t.stackModel,this.preview=t.preview,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.propsConfig=t.propsConfig;var e=this.pfx,n=this.ppfx,i=this.collection;this.className=e+"layers "+n+"field",this.listenTo(i,"add",this.addTo),this.listenTo(i,"deselectAll",this.deselectAll),this.listenTo(i,"reset",this.render);var r=this.config.em||"",o=r?r.get("Utils"):"";this.sorter=o?new o.Sorter({container:this.el,ignoreViewChildren:1,containerSel:"."+e+"layers",itemSel:"."+e+"layer",pfx:this.config.pStylePrefix}):"",i.view=this,this.$el.data("model",i),this.$el.data("collection",i)},addTo:function(t){var e=this.collection.indexOf(t);this.addToCollection(t,null,e)},addToCollection:function(t,e,n){var i=e||null,o=this.stackModel,s=this.config,a=this.sorter,l=this.propsConfig;void 0!==this.preview&&t.set("preview",this.preview);var c=new r({model:t,config:s,sorter:a,stackModel:o,propsConfig:l}).render().el;if(i)i.appendChild(c);else if(void 0!==n){var u="before";this.$el.children().length==n&&(n--,u="after"),n<0?this.$el.append(c):this.$el.children().eq(n)[u](c)}else this.$el.append(c);return c},deselectAll:function(){this.$el.find("."+this.pfx+"layer").removeClass(this.pfx+"active")},render:function(){var t=document.createDocumentFragment();return this.$el.empty(),this.collection.each(function(e){this.addToCollection(e,t)},this),this.$el.append(t),this.$el.attr("class",this.className),this.sorter&&(this.sorter.plh=null),this}})},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.default=function(t,e){var n={beforeShow:h,move:h,change:h,show:h,hide:h,color:!1,flat:!1,showInput:!1,allowEmpty:!1,showButtons:!0,clickoutFiresChange:!0,showInitial:!1,showPalette:!1,showPaletteOnly:!1,hideAfterPaletteSelect:!1,togglePaletteOnly:!1,showSelectionPalette:!0,localStorageKey:!1,appendTo:"body",maxSelectionSize:7,cancelText:"cancel",chooseText:"choose",togglePaletteMoreText:"more",togglePaletteLessText:"less",clearText:"Clear Color Selection",noColorSelectedText:"No Color Selected",preferredFormat:!1,className:"",containerClassName:"",replacerClassName:"",showAlpha:!1,theme:"sp-light",palette:[["#ffffff","#000000","#ff0000","#ff8000","#ffff00","#008000","#0000ff","#4b0082","#9400d3"]],selectionPalette:[],disabled:!1,offset:null},r=[],o=!!/msie/i.exec(window.navigator.userAgent),s=function(){function t(t,e){return!!~(""+t).indexOf(e)}var e=document.createElement("div").style;return e.cssText="background-color:rgba(0,0,0,.5)",t(e.backgroundColor,"rgba")||t(e.backgroundColor,"hsla")}(),a=["
","
","
","
"].join(""),l=function(){var t="";if(o)for(var e=1;e<=6;e++)t+="
";return["
","
","
","
","","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
","
",t,"
","
","
","
","
","","
","
","
","","","
","
","
"].join("")}();function c(e,n,i,r){for(var o=[],a=0;a')}else{o.push(t("
").append(t('').attr("title",r.noColorSelectedText)).html())}}return"
"+o.join("")+"
"}function u(i,u){var h=function(e,i){var r=t.extend({},n,e);return r.callbacks={move:f(r.move,i),change:f(r.change,i),show:f(r.show,i),hide:f(r.hide,i),beforeShow:f(r.beforeShow,i)},r}(u,i),v=h.flat,m=h.showSelectionPalette,y=h.localStorageKey,b=h.theme,x=h.callbacks,w=function(t,e,n){var i;return function(){var r=this,o=arguments;n&&clearTimeout(i),!n&&i||(i=setTimeout(function(){i=null,t.apply(r,o)},e))}}(Vt,10),C=!1,k=!1,T=0,E=0,M=0,A=0,O=0,P=0,_=0,L=0,N=0,D=0,I=1,F=[],R=[],j={},z=h.selectionPalette.slice(0),V=h.maxSelectionSize,H="sp-dragging",$=null,B=i.ownerDocument,W=(B.body,t(i)),U=!1,q=t(l,B).addClass(b),K=q.find(".sp-picker-container"),Y=q.find(".sp-color"),G=q.find(".sp-dragger"),X=q.find(".sp-hue"),J=q.find(".sp-slider"),Z=q.find(".sp-alpha-inner"),Q=q.find(".sp-alpha"),tt=q.find(".sp-alpha-handle"),et=q.find(".sp-input"),nt=q.find(".sp-palette"),it=q.find(".sp-initial"),rt=q.find(".sp-cancel"),ot=q.find(".sp-clear"),st=q.find(".sp-choose"),at=q.find(".sp-palette-toggle"),lt=W.is("input"),ct=lt&&"color"===W.attr("type")&&g(),ut=lt&&!v,ht=ut?t(a).addClass(b).addClass(h.className).addClass(h.replacerClassName):t([]),dt=ut?ht:W,ft=ht.find(".sp-preview-inner"),pt=h.color||lt&&W.val(),gt=!1,vt=h.preferredFormat,mt=!h.showButtons||h.clickoutFiresChange,yt=!pt,bt=h.allowEmpty&&!ct;function xt(){if(h.showPaletteOnly&&(h.showPalette=!0),at.text(h.showPaletteOnly?h.togglePaletteMoreText:h.togglePaletteLessText),h.palette){F=h.palette.slice(0),R=t.isArray(F[0])?F:[F],j={};for(var e=0;e1&&(delete window.localStorage[y],t.each(e,function(t,e){Ct(e)}))}catch(t){}try{z=window.localStorage[y].split(";")}catch(t){}}}function Ct(e){if(m){var n=S(e).toRgbString();if(!j[n]&&-1===t.inArray(n,z))for(z.push(n);z.length>V;)z.shift();if(y&&window.localStorage)try{window.localStorage[y]=z.join(";")}catch(t){}}}function kt(){var e=It(),n=t.map(R,function(t,n){return c(t,e,"sp-palette-row sp-palette-row-"+n,h)});wt(),z&&n.push(c(function(){var t=[];if(h.showPalette)for(var e=0;ed&&d>i?Math.abs(p.left+i-d):0),p.top-=Math.min(p.top,p.top+r>f&&f>r?Math.abs(r+o-0):0),p}(q,dt))),jt(),h.showPalette&&kt(),W.trigger("reflow.spectrum"))}function Ht(){Lt(),U=!0,W.attr("disabled",!0),dt.addClass("sp-disabled")}!function(){if(o&&q.find("*:not(input)").attr("unselectable","on"),xt(),ut&&W.after(ht).hide(),bt||ot.hide(),v)W.after(q).hide();else{var e="parent"===h.appendTo?W.parent():t(h.appendTo);1!==e.length&&(e=t("body")),e.append(q)}function n(e){return e.data&&e.data.ignore?(Dt(t(e.target).closest(".sp-thumb-el").data("color")),Ft()):(Dt(t(e.target).closest(".sp-thumb-el").data("color")),Ft(),zt(!0),h.hideAfterPaletteSelect&&Lt()),!1}wt(),dt.bind("click.spectrum touchstart.spectrum",function(e){U||At(),e.stopPropagation(),t(e.target).is("input")||e.preventDefault()}),(W.is(":disabled")||!0===h.disabled)&&Ht(),q.click(d),et.change(Mt),et.bind("paste",function(){setTimeout(Mt,1)}),et.keydown(function(t){13==t.keyCode&&Mt()}),rt.text(h.cancelText),rt.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),Nt(),Lt()}),ot.attr("title",h.clearText),ot.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),yt=!0,Ft(),v&&zt(!0)}),st.text(h.chooseText),st.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),o&&et.is(":focus")&&et.trigger("change"),et.hasClass("sp-validation-error")||(zt(!0),Lt())}),at.text(h.showPaletteOnly?h.togglePaletteMoreText:h.togglePaletteLessText),at.bind("click.spectrum",function(t){t.stopPropagation(),t.preventDefault(),h.showPaletteOnly=!h.showPaletteOnly,h.showPaletteOnly||v||q.css("left","-="+(K.outerWidth(!0)+5)),xt()}),p(Q,function(t,e,n){I=t/O,yt=!1,n.shiftKey&&(I=Math.round(10*I)/10),Ft()},Tt,Et),p(X,function(t,e){L=parseFloat(e/A),yt=!1,h.showAlpha||(I=1),Ft()},Tt,Et),p(Y,function(t,e,n){if(n.shiftKey){if(!$){var i=N*T,r=E-D*E,o=Math.abs(t-i)>Math.abs(e-r);$=o?"x":"y"}}else $=null;var s=!$||"y"===$;(!$||"x"===$)&&(N=parseFloat(t/T)),s&&(D=parseFloat((E-e)/E)),yt=!1,h.showAlpha||(I=1),Ft()},Tt,Et),pt?(Dt(pt),Rt(),vt=h.preferredFormat||S(pt).format,Ct(pt)):Rt(),v&&Ot();var i=o?"mousedown.spectrum":"click.spectrum touchstart.spectrum";nt.delegate(".sp-thumb-el",i,n),it.delegate(".sp-thumb-el:nth-child(1)",i,{ignore:!0},n)}();var $t={show:Ot,hide:Lt,toggle:At,reflow:Vt,option:function(n,i){return n===e?t.extend({},h):i===e?h[n]:(h[n]=i,"preferredFormat"===n&&(vt=h.preferredFormat),void xt())},enable:function(){U=!1,W.attr("disabled",!1),dt.removeClass("sp-disabled")},disable:Ht,offset:function(t){h.offset=t,Vt()},set:function(t){Dt(t),zt()},get:It,destroy:function(){W.show(),dt.unbind("click.spectrum touchstart.spectrum"),q.remove(),ht.remove(),r[$t.id]=null},container:q};return $t.id=r.push($t)-1,$t}function h(){}function d(t){t.stopPropagation()}function f(t,e){var n=Array.prototype.slice,i=n.call(arguments,2);return function(){return t.apply(e,i.concat(n.call(arguments)))}}function p(e,n,i,r){n=n||function(){},i=i||function(){},r=r||function(){};var s=document,a=!1,l={},c=0,u=0,h="ontouchstart"in window,d={};function f(t){t.stopPropagation&&t.stopPropagation(),t.preventDefault&&t.preventDefault(),t.returnValue=!1}function p(t){if(a){if(o&&s.documentMode<9&&!t.button)return g();var i=t.originalEvent&&t.originalEvent.touches&&t.originalEvent.touches[0],r=i&&i.pageX||t.pageX,d=i&&i.pageY||t.pageY,p=Math.max(0,Math.min(r-l.left,u)),v=Math.max(0,Math.min(d-l.top,c));h&&f(t),n.apply(e,[p,v,t])}}function g(){a&&(t(s).unbind(d),t(s.body).removeClass("sp-dragging"),setTimeout(function(){r.apply(e,arguments)},0)),a=!1}d.selectstart=f,d.dragstart=f,d["touchmove mousemove"]=p,d["touchend mouseup"]=g,t(e).bind("touchstart mousedown",function(n){(n.which?3==n.which:2==n.button)||a||!1!==i.apply(e,arguments)&&(a=!0,c=t(e).height(),u=t(e).width(),l=t(e).offset(),t(s).bind(d),t(s.body).addClass("sp-dragging"),p(n),f(n))})}function g(){return t.fn.spectrum.inputTypeColorSupport()}t.fn.spectrum=function(e,n){if("string"==typeof e){var i=this,o=Array.prototype.slice.call(arguments,1);return this.each(function(){var n=r[t(this).data("spectrum.id")];if(n){var s=n[e];if(!s)throw new Error("Spectrum: no such method: '"+e+"'");"get"==e?i=n.get():"container"==e?i=n.container:"option"==e?i=n.option.apply(n,o):"destroy"==e?(n.destroy(),t(this).removeData("spectrum.id")):s.apply(n,o)}}),i}return this.spectrum("destroy").each(function(){var n=u(this,t.extend({},e,t(this).data()));t(this).data("spectrum.id",n.id)})},t.fn.spectrum.load=!0,t.fn.spectrum.loadOpts={},t.fn.spectrum.draggable=p,t.fn.spectrum.defaults=n,t.fn.spectrum.inputTypeColorSupport=function e(){if(void 0===e._cachedResult){var n=t("")[0];e._cachedResult="color"===n.type&&""!==n.value}return e._cachedResult},t.spectrum={},t.spectrum.localization={},t.spectrum.palettes={},t.fn.spectrum.processNativeColorInputs=function(){var e=t("input[type=color]");e.length&&!g()&&e.spectrum({preferredFormat:"hex6"})};var v=/^[\s,#]+/,m=/\s+$/,y=0,b=Math,x=b.round,w=b.min,C=b.max,k=b.random,S=function t(e,n){if(e=e||"",n=n||{},e instanceof t)return e;if(!(this instanceof t))return new t(e,n);var r=function(t){var e={r:0,g:0,b:0},n=1,r=!1,o=!1;"string"==typeof t&&(t=function(t){t=t.replace(v,"").replace(m,"").toLowerCase();var e,n=!1;if($[t])t=$[t],n=!0;else if("transparent"==t)return{r:0,g:0,b:0,a:0,format:"name"};if(e=X.rgb.exec(t))return{r:e[1],g:e[2],b:e[3]};if(e=X.rgba.exec(t))return{r:e[1],g:e[2],b:e[3],a:e[4]};if(e=X.hsl.exec(t))return{h:e[1],s:e[2],l:e[3]};if(e=X.hsla.exec(t))return{h:e[1],s:e[2],l:e[3],a:e[4]};if(e=X.hsv.exec(t))return{h:e[1],s:e[2],v:e[3]};if(e=X.hsva.exec(t))return{h:e[1],s:e[2],v:e[3],a:e[4]};if(e=X.hex8.exec(t))return{a:function(t){return K(t)/255}(e[1]),r:K(e[2]),g:K(e[3]),b:K(e[4]),format:n?"name":"hex8"};if(e=X.hex6.exec(t))return{r:K(e[1]),g:K(e[2]),b:K(e[3]),format:n?"name":"hex"};if(e=X.hex3.exec(t))return{r:K(e[1]+""+e[1]),g:K(e[2]+""+e[2]),b:K(e[3]+""+e[3]),format:n?"name":"hex"};return!1}(t));"object"==(void 0===t?"undefined":i(t))&&(t.hasOwnProperty("r")&&t.hasOwnProperty("g")&&t.hasOwnProperty("b")?(e=function(t,e,n){return{r:255*U(t,255),g:255*U(e,255),b:255*U(n,255)}}(t.r,t.g,t.b),r=!0,o="%"===String(t.r).substr(-1)?"prgb":"rgb"):t.hasOwnProperty("h")&&t.hasOwnProperty("s")&&t.hasOwnProperty("v")?(t.s=G(t.s),t.v=G(t.v),e=function(t,e,n){t=6*U(t,360),e=U(e,100),n=U(n,100);var i=b.floor(t),r=t-i,o=n*(1-e),s=n*(1-r*e),a=n*(1-(1-r)*e),l=i%6;return{r:255*[n,s,o,o,a,n][l],g:255*[a,n,n,s,o,o][l],b:255*[o,o,a,n,n,s][l]}}(t.h,t.s,t.v),r=!0,o="hsv"):t.hasOwnProperty("h")&&t.hasOwnProperty("s")&&t.hasOwnProperty("l")&&(t.s=G(t.s),t.l=G(t.l),e=function(t,e,n){var i,r,o;function s(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+6*(e-t)*n:n<.5?e:n<2/3?t+(e-t)*(2/3-n)*6:t}if(t=U(t,360),e=U(e,100),n=U(n,100),0===e)i=r=o=n;else{var a=n<.5?n*(1+e):n+e-n*e,l=2*n-a;i=s(l,a,t+1/3),r=s(l,a,t),o=s(l,a,t-1/3)}return{r:255*i,g:255*r,b:255*o}}(t.h,t.s,t.l),r=!0,o="hsl"),t.hasOwnProperty("a")&&(n=t.a));return n=W(n),{ok:r,format:t.format||o,r:w(255,C(e.r,0)),g:w(255,C(e.g,0)),b:w(255,C(e.b,0)),a:n}}(e);this._originalInput=e,this._r=r.r,this._g=r.g,this._b=r.b,this._a=r.a,this._roundA=x(100*this._a)/100,this._format=n.format||r.format,this._gradientType=n.gradientType,this._r<1&&(this._r=x(this._r)),this._g<1&&(this._g=x(this._g)),this._b<1&&(this._b=x(this._b)),this._ok=r.ok,this._tc_id=y++};function T(t,e,n){t=U(t,255),e=U(e,255),n=U(n,255);var i,r,o=C(t,e,n),s=w(t,e,n),a=(o+s)/2;if(o==s)i=r=0;else{var l=o-s;switch(r=a>.5?l/(2-o-s):l/(o+s),o){case t:i=(e-n)/l+(e>1)+720)%360;--e;)i.h=(i.h+r)%360,o.push(S(i));return o}function H(t,e){e=e||6;for(var n=S(t).toHsv(),i=n.h,r=n.s,o=n.v,s=[],a=1/e;e--;)s.push(S({h:i,s:r,v:o})),o=(o+a)%1;return s}S.prototype={isDark:function(){return this.getBrightness()<128},isLight:function(){return!this.isDark()},isValid:function(){return this._ok},getOriginalInput:function(){return this._originalInput},getFormat:function(){return this._format},getAlpha:function(){return this._a},getBrightness:function(){var t=this.toRgb();return(299*t.r+587*t.g+114*t.b)/1e3},setAlpha:function(t){return this._a=W(t),this._roundA=x(100*this._a)/100,this},toHsv:function(){var t=E(this._r,this._g,this._b);return{h:360*t.h,s:t.s,v:t.v,a:this._a}},toHsvString:function(){var t=E(this._r,this._g,this._b),e=x(360*t.h),n=x(100*t.s),i=x(100*t.v);return 1==this._a?"hsv("+e+", "+n+"%, "+i+"%)":"hsva("+e+", "+n+"%, "+i+"%, "+this._roundA+")"},toHsl:function(){var t=T(this._r,this._g,this._b);return{h:360*t.h,s:t.s,l:t.l,a:this._a}},toHslString:function(){var t=T(this._r,this._g,this._b),e=x(360*t.h),n=x(100*t.s),i=x(100*t.l);return 1==this._a?"hsl("+e+", "+n+"%, "+i+"%)":"hsla("+e+", "+n+"%, "+i+"%, "+this._roundA+")"},toHex:function(t){return M(this._r,this._g,this._b,t)},toHexString:function(t){return"#"+this.toHex(t)},toHex8:function(){return A(this._r,this._g,this._b,this._a)},toHex8String:function(){return"#"+this.toHex8()},toRgb:function(){return{r:x(this._r),g:x(this._g),b:x(this._b),a:this._a}},toRgbString:function(){return 1==this._a?"rgb("+x(this._r)+", "+x(this._g)+", "+x(this._b)+")":"rgba("+x(this._r)+", "+x(this._g)+", "+x(this._b)+", "+this._roundA+")"},toPercentageRgb:function(){return{r:x(100*U(this._r,255))+"%",g:x(100*U(this._g,255))+"%",b:x(100*U(this._b,255))+"%",a:this._a}},toPercentageRgbString:function(){return 1==this._a?"rgb("+x(100*U(this._r,255))+"%, "+x(100*U(this._g,255))+"%, "+x(100*U(this._b,255))+"%)":"rgba("+x(100*U(this._r,255))+"%, "+x(100*U(this._g,255))+"%, "+x(100*U(this._b,255))+"%, "+this._roundA+")"},toName:function(){return 0===this._a?"transparent":!(this._a<1)&&(B[M(this._r,this._g,this._b,!0)]||!1)},toFilter:function(t){var e="#"+A(this._r,this._g,this._b,this._a),n=e,i=this._gradientType?"GradientType = 1, ":"";t&&(n=S(t).toHex8String());return"progid:DXImageTransform.Microsoft.gradient("+i+"startColorstr="+e+",endColorstr="+n+")"},toString:function(t){var e=!!t;t=t||this._format;var n=!1,i=this._a<1&&this._a>=0;return e||!i||"hex"!==t&&"hex6"!==t&&"hex3"!==t&&"name"!==t?("rgb"===t&&(n=this.toRgbString()),"prgb"===t&&(n=this.toPercentageRgbString()),"hex"!==t&&"hex6"!==t||(n=this.toHexString()),"hex3"===t&&(n=this.toHexString(!0)),"hex8"===t&&(n=this.toHex8String()),"name"===t&&(n=this.toName()),"hsl"===t&&(n=this.toHslString()),"hsv"===t&&(n=this.toHsvString()),n||this.toHexString()):"name"===t&&0===this._a?this.toName():this.toRgbString()},_applyModification:function(t,e){var n=t.apply(null,[this].concat([].slice.call(e)));return this._r=n._r,this._g=n._g,this._b=n._b,this.setAlpha(n._a),this},lighten:function(){return this._applyModification(L,arguments)},brighten:function(){return this._applyModification(N,arguments)},darken:function(){return this._applyModification(D,arguments)},desaturate:function(){return this._applyModification(O,arguments)},saturate:function(){return this._applyModification(P,arguments)},greyscale:function(){return this._applyModification(_,arguments)},spin:function(){return this._applyModification(I,arguments)},_applyCombination:function(t,e){return t.apply(null,[this].concat([].slice.call(e)))},analogous:function(){return this._applyCombination(V,arguments)},complement:function(){return this._applyCombination(F,arguments)},monochromatic:function(){return this._applyCombination(H,arguments)},splitcomplement:function(){return this._applyCombination(z,arguments)},triad:function(){return this._applyCombination(R,arguments)},tetrad:function(){return this._applyCombination(j,arguments)}},S.fromRatio=function(t,e){if("object"==(void 0===t?"undefined":i(t))){var n={};for(var r in t)t.hasOwnProperty(r)&&(n[r]="a"===r?t[r]:G(t[r]));t=n}return S(t,e)},S.equals=function(t,e){return!(!t||!e)&&S(t).toRgbString()==S(e).toRgbString()},S.random=function(){return S.fromRatio({r:k(),g:k(),b:k()})},S.mix=function(t,e,n){n=0===n?0:n||50;var i,r=S(t).toRgb(),o=S(e).toRgb(),s=n/100,a=2*s-1,l=o.a-r.a,c=1-(i=((i=a*l==-1?a:(a+l)/(1+a*l))+1)/2),u={r:o.r*i+r.r*c,g:o.g*i+r.g*c,b:o.b*i+r.b*c,a:o.a*s+r.a*(1-s)};return S(u)},S.readability=function(t,e){var n=S(t),i=S(e),r=n.toRgb(),o=i.toRgb(),s=n.getBrightness(),a=i.getBrightness(),l=Math.max(r.r,o.r)-Math.min(r.r,o.r)+Math.max(r.g,o.g)-Math.min(r.g,o.g)+Math.max(r.b,o.b)-Math.min(r.b,o.b);return{brightness:Math.abs(s-a),color:l}},S.isReadable=function(t,e){var n=S.readability(t,e);return n.brightness>125&&n.color>500},S.mostReadable=function(t,e){for(var n=null,i=0,r=!1,o=0;o125&&s.color>500,l=s.brightness/125*3+s.color/500;(a&&!r||a&&r&&l>i||!a&&!r&&l>i)&&(r=a,i=l,n=S(e[o]))}return n};var $=S.names={aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"},B=S.hexNames=function(t){var e={};for(var n in t)t.hasOwnProperty(n)&&(e[t[n]]=n);return e}($);function W(t){return t=parseFloat(t),(isNaN(t)||t<0||t>1)&&(t=1),t}function U(t,e){(function(t){return"string"==typeof t&&-1!=t.indexOf(".")&&1===parseFloat(t)})(t)&&(t="100%");var n=function(t){return"string"==typeof t&&-1!=t.indexOf("%")}(t);return t=w(e,C(0,parseFloat(t))),n&&(t=parseInt(t*e,10)/100),b.abs(t-e)<1e-6?1:t%e/parseFloat(e)}function q(t){return w(1,C(0,t))}function K(t){return parseInt(t,16)}function Y(t){return 1==t.length?"0"+t:""+t}function G(t){return t<=1&&(t=100*t+"%"),t}var X=function(){var t="(?:[-\\+]?\\d*\\.\\d+%?)|(?:[-\\+]?\\d+%?)",e="[\\s|\\(]+("+t+")[,|\\s]+("+t+")[,|\\s]+("+t+")\\s*\\)?",n="[\\s|\\(]+("+t+")[,|\\s]+("+t+")[,|\\s]+("+t+")[,|\\s]+("+t+")\\s*\\)?";return{rgb:new RegExp("rgb"+e),rgba:new RegExp("rgba"+n),hsl:new RegExp("hsl"+e),hsla:new RegExp("hsla"+n),hsv:new RegExp("hsv"+e),hsva:new RegExp("hsva"+n),hex3:/^([0-9a-fA-F]{1})([0-9a-fA-F]{1})([0-9a-fA-F]{1})$/,hex6:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/,hex8:/^([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})([0-9a-fA-F]{2})$/}}();window.tinycolor=S,t(function(){t.fn.spectrum.load&&t.fn.spectrum.processNativeColorInputs()})}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Model.extend({defaults:{index:"",value:"",values:{},active:!1,preview:!1,properties:[]},initialize:function(){var t=n(18),e=this.get("properties"),i=this.get("value");if(this.set("properties",e instanceof t?e:new t(e)),!i){var r="",o=this.get("values");for(var s in o)r+=" "+o[s];this.set("value",r.trim())}},getPropertyValue:function(t){var e="";return this.get("properties").each(function(n){n.get("property")==t&&(e=n.getFullValue())}),e},getFullValue:function(){var t=[];return this.get("properties").each(function(e){return t.push(e.getFullValue())}),t.join(" ")}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;eB",attributes:{title:"Bold"},result:function(t){return t.exec("bold")}},italic:{name:"italic",icon:"I",attributes:{title:"Italic"},result:function(t){return t.exec("italic")}},underline:{name:"underline",icon:"U",attributes:{title:"Underline"},result:function(t){return t.exec("underline")}},strikethrough:{name:"strikethrough",icon:"S",attributes:{title:"Strike-through"},result:function(t){return t.exec("strikeThrough")}},link:{icon:'',name:"link",attributes:{style:"font-size:1.4rem;padding:0 4px 2px;",title:"Link"},result:function(t){return t.insertHTML(''+t.selection()+"")}}},l=function(){function t(){var e=this,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t);var r=n.el;if(r[s])return r[s];r[s]=this,this.setEl(r),this.updateActiveActions=this.updateActiveActions.bind(this);var o=n.actions||[];o.forEach(function(t,e){"string"==typeof t?t=a[t]:a[t.name]&&(t=i({},a[t.name],t)),o[e]=t});var l=o.length?o:Object.keys(a).map(function(t){return a[t]});n.classes=i({actionbar:"actionbar",button:"action",active:"active"},n.classes);var c=n.classes,u=n.actionbar;if(this.actionbar=u,this.settings=n,this.classes=c,this.actions=l,!u){var h=n.actionbarContainer;(u=document.createElement("div")).className=c.actionbar,h.appendChild(u),this.actionbar=u,l.forEach(function(t){return e.addAction(t)})}return n.styleWithCSS&&this.exec("styleWithCSS"),this.syncActions(),this}return r(t,[{key:"setEl",value:function(t){this.el=t,this.doc=t.ownerDocument}},{key:"updateActiveActions",value:function(){var t=this;this.getActions().forEach(function(e){var n=e.btn,i=e.update,r=t.classes.active,o=e.name,s=t.doc;n.className=n.className.replace(r,"").trim(),s.queryCommandSupported(o)&&s.queryCommandState(o)&&(n.className+=" "+r),i&&i(t,e)})}},{key:"enable",value:function(){return this.enabled?this:(this.actionbarEl().style.display="",this.el.contentEditable=!0,(0,o.on)(this.el,"mouseup keyup",this.updateActiveActions),this.syncActions(),this.updateActiveActions(),this.el.focus(),this.enabled=1,this)}},{key:"disable",value:function(){return this.actionbarEl().style.display="none",this.el.contentEditable=!1,(0,o.off)(this.el,"mouseup keyup",this.updateActiveActions),this.enabled=0,this}},{key:"syncActions",value:function(){var t=this;this.getActions().forEach(function(e){var n=e.event||"click";e.btn["on"+n]=function(n){e.result(t,e),t.updateActiveActions()}})}},{key:"addAction",value:function(t){var e=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).sync,n=document.createElement("span"),i=t.icon,r=t.attributes||{};for(var o in n.className=this.classes.button,t.btn=n,r)n.setAttribute(o,r[o]);"string"==typeof i?n.innerHTML=i:n.appendChild(i),this.actionbarEl().appendChild(n),e&&(this.actions.push(t),this.syncActions())}},{key:"getActions",value:function(){return this.actions}},{key:"selection",value:function(){return this.doc.getSelection()}},{key:"exec",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.doc.execCommand(t,!1,e)}},{key:"actionbarEl",value:function(){return this.actionbar}},{key:"insertHTML",value:function(t){var e=this.doc,n=e.getSelection();if(n&&n.rangeCount){var i=e.createElement("div"),r=n.getRangeAt(0);r.deleteContents(),i.innerHTML=t,Array.prototype.slice.call(i.childNodes).forEach(function(t){r.insertNode(t),t}),n.removeAllRanges(),n.addRange(r),this.el.focus()}}}]),t}();e.default=l},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(177)),r=n(2);t.exports=function(){var t={},e=n(176),o=void 0,s=void 0,a=void 0,l=function(){var t=o.style;t.top="-100px",t.left="-100px",t.display="none"};return{customRte:null,name:"RichTextEditor",init:function(){var n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};for(var i in t=n,e)i in t||(t[i]=e[i]);var s=t.pStylePrefix;return s&&(t.stylePrefix=s+t.stylePrefix),this.pfx=t.stylePrefix,t.actions||[],(o=document.createElement("div")).className=s+"rte-toolbar "+s+"one-bg",a=this.initRte(document.createElement("div")),(0,r.on)(o,"mousedown",function(t){return t.stopPropagation()}),this},postRender:function(t){var e=t.model.get("Canvas");o.style.pointerEvents="all",l(),e.getToolsEl().appendChild(o)},initRte:function(e){var n=this.pfx,r=o,s=this.actionbar,l=this.actions||t.actions,c={actionbar:n+"actionbar",button:n+"action",active:n+"active"},u=new i.default({el:e,classes:c,actions:l,actionbar:s,actionbarContainer:r});return a&&a.setEl(e),u.actionbar&&(this.actionbar=u.actionbar),u.actions&&(this.actions=u.actions),u},add:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};e.name=t,a.addAction(e,{sync:1})},get:function(t){var e=void 0;return a.getActions().forEach(function(n){n.name==t&&(e=n)}),e},getAll:function(){return a.getActions()},remove:function(t){var e=this.getAll(),n=this.get(t);if(n){var i=n.btn,r=e.indexOf(n);i.parentNode.removeChild(i),e.splice(r,1)}return n},getToolbarEl:function(){return o},udpatePosition:function(){var e=t.em.get("Canvas").getTargetToElementDim(o,s,{event:"rteToolbarPosUpdate"});if(e){t.adjustToolbar&&e.top<=e.canvasTop&&(e.top=e.elementTop+e.elementHeight);var n=o.style;n.top=e.top+"px",n.left=e.left+"px"}},enable:function(e,n){s=e.el;var i=t.em,r=e.getChildrenContainer(),a=this.customRte;if(o.style.display="",n=a?a.enable(r,n):this.initRte(r).enable(),i){setTimeout(this.udpatePosition.bind(this),0);var l="change:canvasOffset canvasScroll";i.off(l,this.udpatePosition,this),i.on(l,this.udpatePosition,this),i.trigger("rte:enable",e,n)}return n},disable:function(e,n){var i=t.em,r=this.customRte,o=e.getChildrenContainer();r?r.disable(o,n):n&&n.disable(),l(),i&&i.trigger("rte:disable",e,n)}}}},function(t,e,n){"use strict";var i=n(0),r=n(78);t.exports=i.View.extend({initialize:function(t){this.opt=t||{},this.config=this.opt.config||{},this.pfx=this.config.stylePrefix||"";var e=this.collection;this.listenTo(e,"add",this.addTo),this.listenTo(e,"reset",this.render),this.listenTo(e,"remove",this.onRemove),this.className=this.pfx+"panels"},onRemove:function(t){var e=t.view;e&&e.remove()},addTo:function(t){this.addToCollection(t)},addToCollection:function(t,e){var n=e||null,i=this.config,o=t.get("el"),s=new r({el:o,model:t,config:i}),a=s.render().el,l=t.get("appendTo");if(o);else if(l){document.querySelector(l).appendChild(a)}else n?n.appendChild(a):this.$el.append(a);return s.initResize(),a},render:function(){var t=this,e=this.$el,n=document.createDocumentFragment();return e.empty(),this.collection.each(function(e){return t.addToCollection(e,n)}),e.append(n),e.attr("class",this.className),this}})},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e\n \t
<%= label %>
\n \t
\n
'),initialize:function(t){this.config=t.config||{},this.pfx=this.config.stylePrefix},render:function(){var t=this.model.toJSON();return t.pfx=this.pfx,this.$el.html(this.template(t)),this.$el.attr("class",this.pfx+"editor-c"),this.$el.find("#"+this.pfx+"code").append(this.model.get("input")),this}})},function(t,e,n){!function(t){t.extendMode("css",{commentStart:"/*",commentEnd:"*/",newlineAfterToken:function(t,e){return/^[;{}]$/.test(e)}}),t.extendMode("javascript",{commentStart:"/*",commentEnd:"*/",newlineAfterToken:function(t,e,n,i){return this.jsonMode?/^[\[,{]$/.test(e)||/^}/.test(n):(";"!=e||!i.lexical||")"!=i.lexical.type)&&/^[;{}]$/.test(e)&&!/^;/.test(n)}});var e=/^(a|abbr|acronym|area|base|bdo|big|br|button|caption|cite|code|col|colgroup|dd|del|dfn|em|frame|hr|iframe|img|input|ins|kbd|label|legend|link|map|object|optgroup|option|param|q|samp|script|select|small|span|strong|sub|sup|textarea|tt|var)$/;t.extendMode("xml",{commentStart:"\x3c!--",commentEnd:"--\x3e",newlineAfterToken:function(t,n,i,r){var o=!1;return"html"==this.configuration&&(o=!!r.context&&e.test(r.context.tagName)),!o&&("tag"==t&&/>$/.test(n)&&r.context||/^-1&&a>-1&&a>s&&(t=t.substr(0,s)+t.substring(s+o.commentStart.length,a)+t.substr(a+o.commentEnd.length)),r.replaceRange(t,n,i)}})}),t.defineExtension("autoIndentRange",function(t,e){var n=this;this.operation(function(){for(var i=t.line;i<=e.line;i++)n.indentLine(i,"smart")})}),t.defineExtension("autoFormatRange",function(e,n){var i=this,r=i.getMode(),o=i.getRange(e,n).split("\n"),s=t.copyState(r,i.getTokenAt(e).state),a=i.getOption("tabSize"),l="",c=0,u=0===e.ch;function h(){l+="\n",u=!0,++c}for(var d=0;d!?|~^@]/,f=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function p(t,e,n){return i=t,r=n,e}function g(t,e){var n=t.next();if('"'==n||"'"==n)return e.tokenize=function(t){return function(e,n){var i,r=!1;if(a&&"@"==e.peek()&&e.match(f))return n.tokenize=g,p("jsonld-keyword","meta");for(;null!=(i=e.next())&&(i!=t||r);)r=!r&&"\\"==i;return r||(n.tokenize=g),p("string","string")}}(n),e.tokenize(t,e);if("."==n&&t.match(/^\d+(?:[eE][+\-]?\d+)?/))return p("number","number");if("."==n&&t.match(".."))return p("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(n))return p(n);if("="==n&&t.eat(">"))return p("=>","operator");if("0"==n&&t.match(/^(?:x[\da-f]+|o[0-7]+|b[01]+)n?/i))return p("number","number");if(/\d/.test(n))return t.match(/^\d*(?:n|(?:\.\d*)?(?:[eE][+\-]?\d+)?)?/),p("number","number");if("/"==n)return t.eat("*")?(e.tokenize=v,v(t,e)):t.eat("/")?(t.skipToEnd(),p("comment","comment")):qt(t,e,1)?(function(t){for(var e,n=!1,i=!1;null!=(e=t.next());){if(!n){if("/"==e&&!i)return;"["==e?i=!0:i&&"]"==e&&(i=!1)}n=!n&&"\\"==e}}(t),t.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),p("regexp","string-2")):(t.eat("="),p("operator","operator",t.current()));if("`"==n)return e.tokenize=m,m(t,e);if("#"==n)return t.skipToEnd(),p("error","error");if(d.test(n))return">"==n&&e.lexical&&">"==e.lexical.type||(t.eat("=")?"!"!=n&&"="!=n||t.eat("="):/[<>*+\-]/.test(n)&&(t.eat(n),">"==n&&t.eat(n))),p("operator","operator",t.current());if(u.test(n)){t.eatWhile(u);var i=t.current();if("."!=e.lastType){if(h.propertyIsEnumerable(i)){var r=h[i];return p(r.type,r.style,i)}if("async"==i&&t.match(/^(\s|\/\*.*?\*\/)*[\[\(\w]/,!1))return p("async","keyword",i)}return p("variable","variable",i)}}function v(t,e){for(var n,i=!1;n=t.next();){if("/"==n&&i){e.tokenize=g;break}i="*"==n}return p("comment","comment")}function m(t,e){for(var n,i=!1;null!=(n=t.next());){if(!i&&("`"==n||"$"==n&&t.eat("{"))){e.tokenize=g;break}i=!i&&"\\"==n}return p("quasi","string-2",t.current())}var y="([{}])";function b(t,e){e.fatArrowAt&&(e.fatArrowAt=null);var n=t.string.indexOf("=>",t.start);if(!(n<0)){if(c){var i=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(t.string.slice(t.start,n));i&&(n=i.index)}for(var r=0,o=!1,s=n-1;s>=0;--s){var a=t.string.charAt(s),l=y.indexOf(a);if(l>=0&&l<3){if(!r){++s;break}if(0==--r){"("==a&&(o=!0);break}}else if(l>=3&&l<6)++r;else if(u.test(a))o=!0;else{if(/["'\/]/.test(a))return;if(o&&!r){++s;break}}}o&&!r&&(e.fatArrowAt=s)}}var x={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,"jsonld-keyword":!0};function w(t,e,n,i,r,o){this.indented=t,this.column=e,this.type=n,this.prev=r,this.info=o,null!=i&&(this.align=i)}function C(t,e){for(var n=t.localVars;n;n=n.next)if(n.name==e)return!0;for(var i=t.context;i;i=i.prev)for(var n=i.vars;n;n=n.next)if(n.name==e)return!0}var k={state:null,column:null,marked:null,cc:null};function S(){for(var t=arguments.length-1;t>=0;t--)k.cc.push(arguments[t])}function T(){return S.apply(null,arguments),!0}function E(t,e){for(var n=e;n;n=n.next)if(n.name==t)return!0;return!1}function M(t){var e=k.state;if(k.marked="def",e.context)if("var"==e.lexical.info&&e.context&&e.context.block){var i=function t(e,n){if(n){if(n.block){var i=t(e,n.prev);return i?i==n.prev?n:new O(i,n.vars,!0):null}return E(e,n.vars)?n:new O(n.prev,new P(e,n.vars),!1)}return null}(t,e.context);if(null!=i)return void(e.context=i)}else if(!E(t,e.localVars))return void(e.localVars=new P(t,e.localVars));n.globalVars&&!E(t,e.globalVars)&&(e.globalVars=new P(t,e.globalVars))}function A(t){return"public"==t||"private"==t||"protected"==t||"abstract"==t||"readonly"==t}function O(t,e,n){this.prev=t,this.vars=e,this.block=n}function P(t,e){this.name=t,this.next=e}var _=new P("this",new P("arguments",null));function L(){k.state.context=new O(k.state.context,k.state.localVars,!1),k.state.localVars=_}function N(){k.state.context=new O(k.state.context,k.state.localVars,!0),k.state.localVars=null}function D(){k.state.localVars=k.state.context.vars,k.state.context=k.state.context.prev}function I(t,e){var n=function(){var n=k.state,i=n.indented;if("stat"==n.lexical.type)i=n.lexical.indented;else for(var r=n.lexical;r&&")"==r.type&&r.align;r=r.prev)i=r.indented;n.lexical=new w(i,k.stream.column(),t,null,n.lexical,e)};return n.lex=!0,n}function F(){var t=k.state;t.lexical.prev&&(")"==t.lexical.type&&(t.indented=t.lexical.indented),t.lexical=t.lexical.prev)}function R(t){return function e(n){return n==t?T():";"==t||"}"==n||")"==n||"]"==n?S():T(e)}}function j(t,e){return"var"==t?T(I("vardef",e),yt,R(";"),F):"keyword a"==t?T(I("form"),$,j,F):"keyword b"==t?T(I("form"),j,F):"keyword d"==t?k.stream.match(/^\s*$/,!1)?T():T(I("stat"),W,R(";"),F):"debugger"==t?T(R(";")):"{"==t?T(I("}"),N,st,F,D):";"==t?T():"if"==t?("else"==k.state.lexical.info&&k.state.cc[k.state.cc.length-1]==F&&k.state.cc.pop()(),T(I("form"),$,j,F,kt)):"function"==t?T(Ot):"for"==t?T(I("form"),St,j,F):"class"==t||c&&"interface"==e?(k.marked="keyword",T(I("form"),Lt,F)):"variable"==t?c&&"declare"==e?(k.marked="keyword",T(j)):c&&("module"==e||"enum"==e||"type"==e)&&k.stream.match(/^\s*\w/,!1)?(k.marked="keyword","enum"==e?T(Wt):"type"==e?T(ut,R("operator"),ut,R(";")):T(I("form"),bt,R("{"),I("}"),st,F,F)):c&&"namespace"==e?(k.marked="keyword",T(I("form"),V,st,F)):c&&"abstract"==e?(k.marked="keyword",T(j)):T(I("stat"),Q):"switch"==t?T(I("form"),$,R("{"),I("}","switch"),N,st,F,F,D):"case"==t?T(V,R(":")):"default"==t?T(R(":")):"catch"==t?T(I("form"),L,z,j,F,D):"export"==t?T(I("stat"),Ft,F):"import"==t?T(I("stat"),jt,F):"async"==t?T(j):"@"==e?T(V,j):S(I("stat"),V,R(";"),F)}function z(t){if("("==t)return T(Pt,R(")"))}function V(t,e){return B(t,e,!1)}function H(t,e){return B(t,e,!0)}function $(t){return"("!=t?S():T(I(")"),V,R(")"),F)}function B(t,e,n){if(k.state.fatArrowAt==k.stream.start){var i=n?X:G;if("("==t)return T(L,I(")"),rt(Pt,")"),F,R("=>"),i,D);if("variable"==t)return S(L,bt,R("=>"),i,D)}var r=n?q:U;return x.hasOwnProperty(t)?T(r):"function"==t?T(Ot,r):"class"==t||c&&"interface"==e?(k.marked="keyword",T(I("form"),_t,F)):"keyword c"==t||"async"==t?T(n?H:V):"("==t?T(I(")"),W,R(")"),F,r):"operator"==t||"spread"==t?T(n?H:V):"["==t?T(I("]"),Bt,F,r):"{"==t?ot(et,"}",null,r):"quasi"==t?S(K,r):"new"==t?T(function(t){return function(e){return"."==e?T(t?Z:J):"variable"==e&&c?T(gt,t?q:U):S(t?H:V)}}(n)):"import"==t?T(V):T()}function W(t){return t.match(/[;\}\)\],]/)?S():S(V)}function U(t,e){return","==t?T(V):q(t,e,!1)}function q(t,e,n){var i=0==n?U:q,r=0==n?V:H;return"=>"==t?T(L,n?X:G,D):"operator"==t?/\+\+|--/.test(e)||c&&"!"==e?T(i):c&&"<"==e&&k.stream.match(/^([^>]|<.*?>)*>\s*\(/,!1)?T(I(">"),rt(ut,">"),F,i):"?"==e?T(V,R(":"),r):T(r):"quasi"==t?S(K,i):";"!=t?"("==t?ot(H,")","call",i):"."==t?T(tt,i):"["==t?T(I("]"),W,R("]"),F,i):c&&"as"==e?(k.marked="keyword",T(ut,i)):"regexp"==t?(k.state.lastType=k.marked="operator",k.stream.backUp(k.stream.pos-k.stream.start-1),T(r)):void 0:void 0}function K(t,e){return"quasi"!=t?S():"${"!=e.slice(e.length-2)?T(K):T(V,Y)}function Y(t){if("}"==t)return k.marked="string-2",k.state.tokenize=m,T(K)}function G(t){return b(k.stream,k.state),S("{"==t?j:V)}function X(t){return b(k.stream,k.state),S("{"==t?j:H)}function J(t,e){if("target"==e)return k.marked="keyword",T(U)}function Z(t,e){if("target"==e)return k.marked="keyword",T(q)}function Q(t){return":"==t?T(F,j):S(U,R(";"),F)}function tt(t){if("variable"==t)return k.marked="property",T()}function et(t,e){if("async"==t)return k.marked="property",T(et);if("variable"==t||"keyword"==k.style){return k.marked="property","get"==e||"set"==e?T(nt):(c&&k.state.fatArrowAt==k.stream.start&&(n=k.stream.match(/^\s*:\s*/,!1))&&(k.state.fatArrowAt=k.stream.pos+n[0].length),T(it));var n}else{if("number"==t||"string"==t)return k.marked=a?"property":k.style+" property",T(it);if("jsonld-keyword"==t)return T(it);if(c&&A(e))return k.marked="keyword",T(et);if("["==t)return T(V,at,R("]"),it);if("spread"==t)return T(H,it);if("*"==e)return k.marked="keyword",T(et);if(":"==t)return S(it)}}function nt(t){return"variable"!=t?S(it):(k.marked="property",T(Ot))}function it(t){return":"==t?T(H):"("==t?S(Ot):void 0}function rt(t,e,n){function i(r,o){if(n?n.indexOf(r)>-1:","==r){var s=k.state.lexical;return"call"==s.info&&(s.pos=(s.pos||0)+1),T(function(n,i){return n==e||i==e?S():S(t)},i)}return r==e||o==e?T():T(R(e))}return function(n,r){return n==e||r==e?T():S(t,i)}}function ot(t,e,n){for(var i=3;i"),ut):void 0}function ht(t){if("=>"==t)return T(ut)}function dt(t,e){return"variable"==t||"keyword"==k.style?(k.marked="property",T(dt)):"?"==e?T(dt):":"==t?T(ut):"["==t?T(V,at,R("]"),dt):void 0}function ft(t,e){return"variable"==t&&k.stream.match(/^\s*[?:]/,!1)||"?"==e?T(ft):":"==t?T(ut):S(ut)}function pt(t,e){return"<"==e?T(I(">"),rt(ut,">"),F,pt):"|"==e||"."==t||"&"==e?T(ut):"["==t?T(R("]"),pt):"extends"==e||"implements"==e?(k.marked="keyword",T(ut)):void 0}function gt(t,e){if("<"==e)return T(I(">"),rt(ut,">"),F,pt)}function vt(){return S(ut,mt)}function mt(t,e){if("="==e)return T(ut)}function yt(t,e){return"enum"==e?(k.marked="keyword",T(Wt)):S(bt,at,wt,Ct)}function bt(t,e){return c&&A(e)?(k.marked="keyword",T(bt)):"variable"==t?(M(e),T()):"spread"==t?T(bt):"["==t?ot(bt,"]"):"{"==t?ot(xt,"}"):void 0}function xt(t,e){return"variable"!=t||k.stream.match(/^\s*:/,!1)?("variable"==t&&(k.marked="property"),"spread"==t?T(bt):"}"==t?S():T(R(":"),bt,wt)):(M(e),T(wt))}function wt(t,e){if("="==e)return T(H)}function Ct(t){if(","==t)return T(yt)}function kt(t,e){if("keyword b"==t&&"else"==e)return T(I("form","else"),j,F)}function St(t,e){return"await"==e?T(St):"("==t?T(I(")"),Tt,R(")"),F):void 0}function Tt(t){return"var"==t?T(yt,R(";"),Mt):";"==t?T(Mt):"variable"==t?T(Et):S(V,R(";"),Mt)}function Et(t,e){return"in"==e||"of"==e?(k.marked="keyword",T(V)):T(U,Mt)}function Mt(t,e){return";"==t?T(At):"in"==e||"of"==e?(k.marked="keyword",T(V)):S(V,R(";"),At)}function At(t){")"!=t&&T(V)}function Ot(t,e){return"*"==e?(k.marked="keyword",T(Ot)):"variable"==t?(M(e),T(Ot)):"("==t?T(L,I(")"),rt(Pt,")"),F,lt,j,D):c&&"<"==e?T(I(">"),rt(vt,">"),F,Ot):void 0}function Pt(t,e){return"@"==e&&T(V,Pt),"spread"==t?T(Pt):c&&A(e)?(k.marked="keyword",T(Pt)):S(bt,at,wt)}function _t(t,e){return"variable"==t?Lt(t,e):Nt(t,e)}function Lt(t,e){if("variable"==t)return M(e),T(Nt)}function Nt(t,e){return"<"==e?T(I(">"),rt(vt,">"),F,Nt):"extends"==e||"implements"==e||c&&","==t?("implements"==e&&(k.marked="keyword"),T(c?ut:V,Nt)):"{"==t?T(I("}"),Dt,F):void 0}function Dt(t,e){return"async"==t||"variable"==t&&("static"==e||"get"==e||"set"==e||c&&A(e))&&k.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(k.marked="keyword",T(Dt)):"variable"==t||"keyword"==k.style?(k.marked="property",T(c?It:Ot,Dt)):"["==t?T(V,at,R("]"),c?It:Ot,Dt):"*"==e?(k.marked="keyword",T(Dt)):";"==t?T(Dt):"}"==t?T():"@"==e?T(V,Dt):void 0}function It(t,e){return"?"==e?T(It):":"==t?T(ut,wt):"="==e?T(H):S(Ot)}function Ft(t,e){return"*"==e?(k.marked="keyword",T($t,R(";"))):"default"==e?(k.marked="keyword",T(V,R(";"))):"{"==t?T(rt(Rt,"}"),$t,R(";")):S(j)}function Rt(t,e){return"as"==e?(k.marked="keyword",T(R("variable"))):"variable"==t?S(H,Rt):void 0}function jt(t){return"string"==t?T():"("==t?S(V):S(zt,Vt,$t)}function zt(t,e){return"{"==t?ot(zt,"}"):("variable"==t&&M(e),"*"==e&&(k.marked="keyword"),T(Ht))}function Vt(t){if(","==t)return T(zt,Vt)}function Ht(t,e){if("as"==e)return k.marked="keyword",T(zt)}function $t(t,e){if("from"==e)return k.marked="keyword",T(V)}function Bt(t){return"]"==t?T():S(rt(H,"]"))}function Wt(){return S(I("form"),bt,R("{"),I("}"),rt(Ut,"}"),F,F)}function Ut(){return S(bt,wt)}function qt(t,e,n){return e.tokenize==g&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(e.lastType)||"quasi"==e.lastType&&/\{\s*$/.test(t.string.slice(0,t.pos-(n||0)))}return D.lex=!0,F.lex=!0,{startState:function(t){var e={tokenize:g,lastType:"sof",cc:[],lexical:new w((t||0)-o,0,"block",!1),localVars:n.localVars,context:n.localVars&&new O(null,null,!1),indented:t||0};return n.globalVars&&"object"==typeof n.globalVars&&(e.globalVars=n.globalVars),e},token:function(t,e){if(t.sol()&&(e.lexical.hasOwnProperty("align")||(e.lexical.align=!1),e.indented=t.indentation(),b(t,e)),e.tokenize!=v&&t.eatSpace())return null;var n=e.tokenize(t,e);return"comment"==i?n:(e.lastType="operator"!=i||"++"!=r&&"--"!=r?i:"incdec",function(t,e,n,i,r){var o=t.cc;for(k.state=t,k.stream=r,k.marked=null,k.cc=o,k.style=e,t.lexical.hasOwnProperty("align")||(t.lexical.align=!0);;){var s=o.length?o.pop():l?V:j;if(s(n,i)){for(;o.length&&o[o.length-1].lex;)o.pop()();return k.marked?k.marked:"variable"==n&&C(t,i)?"variable-2":e}}}(e,n,i,r,t))},indent:function(e,i){if(e.tokenize==v)return t.Pass;if(e.tokenize!=g)return 0;var r,a=i&&i.charAt(0),l=e.lexical;if(!/^\s*else\b/.test(i))for(var c=e.cc.length-1;c>=0;--c){var u=e.cc[c];if(u==F)l=l.prev;else if(u!=kt)break}for(;("stat"==l.type||"form"==l.type)&&("}"==a||(r=e.cc[e.cc.length-1])&&(r==U||r==q)&&!/^[,\.=+\-*:?[\(]/.test(i));)l=l.prev;s&&")"==l.type&&"stat"==l.prev.type&&(l=l.prev);var h=l.type,f=a==h;return"vardef"==h?l.indented+("operator"==e.lastType||","==e.lastType?l.info.length+1:0):"form"==h&&"{"==a?l.indented:"form"==h?l.indented+o:"stat"==h?l.indented+(function(t,e){return"operator"==t.lastType||","==t.lastType||d.test(e.charAt(0))||/[,.]/.test(e.charAt(0))}(e,i)?s||o:0):"switch"!=l.info||f||0==n.doubleIndentSwitch?l.align?l.column+(f?0:1):l.indented+(f?0:o):l.indented+(/^(?:case|default)\b/.test(i)?o:2*o)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:l?null:"/*",blockCommentEnd:l?null:"*/",blockCommentContinue:l?null:" * ",lineComment:l?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:l?"json":"javascript",jsonldMode:a,jsonMode:l,expressionAllowed:qt,skipExpression:function(t){var e=t.cc[t.cc.length-1];e!=V&&e!=H||t.cc.pop()}}}),t.registerHelper("wordChars","javascript",/[\w$]/),t.defineMIME("text/javascript","javascript"),t.defineMIME("text/ecmascript","javascript"),t.defineMIME("application/javascript","javascript"),t.defineMIME("application/x-javascript","javascript"),t.defineMIME("application/ecmascript","javascript"),t.defineMIME("application/json",{name:"javascript",json:!0}),t.defineMIME("application/x-json",{name:"javascript",json:!0}),t.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),t.defineMIME("text/typescript",{name:"javascript",typescript:!0}),t.defineMIME("application/typescript",{name:"javascript",typescript:!0})}(n(6))},function(t,e,n){!function(t){"use strict";var e={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};t.defineMode("xml",function(i,r){var o,s,a=i.indentUnit,l={},c=r.htmlMode?e:n;for(var u in c)l[u]=c[u];for(var u in r)l[u]=r[u];function h(t,e){function n(n){return e.tokenize=n,n(t,e)}var i=t.next();return"<"==i?t.eat("!")?t.eat("[")?t.match("CDATA[")?n(f("atom","]]>")):null:t.match("--")?n(f("comment","--\x3e")):t.match("DOCTYPE",!0,!0)?(t.eatWhile(/[\w\._\-]/),n(function t(e){return function(n,i){for(var r;null!=(r=n.next());){if("<"==r)return i.tokenize=t(e+1),i.tokenize(n,i);if(">"==r){if(1==e){i.tokenize=h;break}return i.tokenize=t(e-1),i.tokenize(n,i)}}return"meta"}}(1))):null:t.eat("?")?(t.eatWhile(/[\w\._\-]/),e.tokenize=f("meta","?>"),"meta"):(o=t.eat("/")?"closeTag":"openTag",e.tokenize=d,"tag bracket"):"&"==i?(t.eat("#")?t.eat("x")?t.eatWhile(/[a-fA-F\d]/)&&t.eat(";"):t.eatWhile(/[\d]/)&&t.eat(";"):t.eatWhile(/[\w\.\-:]/)&&t.eat(";"))?"atom":"error":(t.eatWhile(/[^&<]/),null)}function d(t,e){var n=t.next();if(">"==n||"/"==n&&t.eat(">"))return e.tokenize=h,o=">"==n?"endTag":"selfcloseTag","tag bracket";if("="==n)return o="equals",null;if("<"==n){e.tokenize=h,e.state=v,e.tagName=e.tagStart=null;var i=e.tokenize(t,e);return i?i+" tag error":"tag error"}return/[\'\"]/.test(n)?(e.tokenize=function(t){var e=function(e,n){for(;!e.eol();)if(e.next()==t){n.tokenize=d;break}return"string"};return e.isInAttribute=!0,e}(n),e.stringStartCol=t.column(),e.tokenize(t,e)):(t.match(/^[^\s\u00a0=<>\"\']*[^\s\u00a0=<>\"\'\/]/),"word")}function f(t,e){return function(n,i){for(;!n.eol();){if(n.match(e)){i.tokenize=h;break}n.next()}return t}}function p(t){t.context&&(t.context=t.context.prev)}function g(t,e){for(var n;;){if(!t.context)return;if(n=t.context.tagName,!l.contextGrabbers.hasOwnProperty(n)||!l.contextGrabbers[n].hasOwnProperty(e))return;p(t)}}function v(t,e,n){return"openTag"==t?(n.tagStart=e.column(),m):"closeTag"==t?y:v}function m(t,e,n){return"word"==t?(n.tagName=e.current(),s="tag",w):l.allowMissingTagName&&"endTag"==t?(s="tag bracket",w(t,0,n)):(s="error",m)}function y(t,e,n){if("word"==t){var i=e.current();return n.context&&n.context.tagName!=i&&l.implicitlyClosed.hasOwnProperty(n.context.tagName)&&p(n),n.context&&n.context.tagName==i||!1===l.matchClosing?(s="tag",b):(s="tag error",x)}return l.allowMissingTagName&&"endTag"==t?(s="tag bracket",b(t,0,n)):(s="error",x)}function b(t,e,n){return"endTag"!=t?(s="error",b):(p(n),v)}function x(t,e,n){return s="error",b(t,0,n)}function w(t,e,n){if("word"==t)return s="attribute",C;if("endTag"==t||"selfcloseTag"==t){var i=n.tagName,r=n.tagStart;return n.tagName=n.tagStart=null,"selfcloseTag"==t||l.autoSelfClosers.hasOwnProperty(i)?g(n,i):(g(n,i),n.context=new function(t,e,n){this.prev=t.context,this.tagName=e,this.indent=t.indented,this.startOfLine=n,(l.doNotIndent.hasOwnProperty(e)||t.context&&t.context.noIndent)&&(this.noIndent=!0)}(n,i,r==n.indented)),v}return s="error",w}function C(t,e,n){return"equals"==t?k:(l.allowMissing||(s="error"),w(t,0,n))}function k(t,e,n){return"string"==t?S:"word"==t&&l.allowUnquoted?(s="string",w):(s="error",w(t,0,n))}function S(t,e,n){return"string"==t?S:w(t,0,n)}return h.isInText=!0,{startState:function(t){var e={tokenize:h,state:v,indented:t||0,tagName:null,tagStart:null,context:null};return null!=t&&(e.baseIndent=t),e},token:function(t,e){if(!e.tagName&&t.sol()&&(e.indented=t.indentation()),t.eatSpace())return null;o=null;var n=e.tokenize(t,e);return(n||o)&&"comment"!=n&&(s=null,e.state=e.state(o||n,t,e),s&&(n="error"==s?n+" error":s)),n},indent:function(e,n,i){var r=e.context;if(e.tokenize.isInAttribute)return e.tagStart==e.indented?e.stringStartCol+1:e.indented+a;if(r&&r.noIndent)return t.Pass;if(e.tokenize!=d&&e.tokenize!=h)return i?i.match(/^(\s*)/)[0].length:0;if(e.tagName)return!1!==l.multilineTagIndentPastTag?e.tagStart+e.tagName.length+2:e.tagStart+a*(l.multilineTagIndentFactor||1);if(l.alignCDATA&&/$/,blockCommentStart:"\x3c!--",blockCommentEnd:"--\x3e",configuration:l.htmlMode?"html":"xml",helperType:l.htmlMode?"html":"xml",skipAttribute:function(t){t.state==k&&(t.state=w)}}}),t.defineMIME("text/xml","xml"),t.defineMIME("application/xml","xml"),t.mimeModes.hasOwnProperty("text/html")||t.defineMIME("text/html",{name:"xml",htmlMode:!0})}(n(6))},function(t,e,n){!function(t){"use strict";var e={script:[["lang",/(javascript|babel)/i,"javascript"],["type",/^(?:text|application)\/(?:x-)?(?:java|ecma)script$|^module$|^$/i,"javascript"],["type",/./,"text/plain"],[null,null,"javascript"]],style:[["lang",/^css$/i,"css"],["type",/^(text\/)?(x-)?(stylesheet|css)$/i,"css"],["type",/./,"text/plain"],[null,null,"css"]]},n={};function i(t,e){var i=t.match(function(t){var e=n[t];return e||(n[t]=new RegExp("\\s+"+t+"\\s*=\\s*('|\")?([^'\"]+)('|\")?\\s*"))}(e));return i?/^\s*(.*?)\s*$/.exec(i[2])[1]:""}function r(t,e){return new RegExp((e?"^":"")+"","i")}function o(t,e){for(var n in t)for(var i=e[n]||(e[n]=[]),r=t[n],o=r.length-1;o>=0;o--)i.unshift(r[o])}t.defineMode("htmlmixed",function(n,s){var a=t.getMode(n,{name:"xml",htmlMode:!0,multilineTagIndentFactor:s.multilineTagIndentFactor,multilineTagIndentPastTag:s.multilineTagIndentPastTag}),l={},c=s&&s.tags,u=s&&s.scriptTypes;if(o(e,l),c&&o(c,l),u)for(var h=u.length-1;h>=0;h--)l.script.unshift(["type",u[h].matches,u[h].mode]);function d(e,o){var s,c=a.token(e,o.htmlState),u=/\btag\b/.test(c);if(u&&!/[<>\s\/]/.test(e.current())&&(s=o.htmlState.tagName&&o.htmlState.tagName.toLowerCase())&&l.hasOwnProperty(s))o.inTag=s+" ";else if(o.inTag&&u&&/>$/.test(e.current())){var h=/^([\S]+) (.*)/.exec(o.inTag);o.inTag=null;var f=">"==e.current()&&function(t,e){for(var n=0;n-1?t.backUp(i.length-r):i.match(/<\/?$/)&&(t.backUp(i.length),t.match(e,!1)||t.match(i)),n}(t,v,e.localMode.token(t,e.localState))},o.localMode=p,o.localState=t.startState(p,a.indent(o.htmlState,""))}else o.inTag&&(o.inTag+=e.current(),e.eol()&&(o.inTag+=" "));return c}return{startState:function(){var e=t.startState(a);return{token:d,inTag:null,localMode:null,localState:null,htmlState:e}},copyState:function(e){var n;return e.localState&&(n=t.copyState(e.localMode,e.localState)),{token:e.token,inTag:e.inTag,localMode:e.localMode,localState:n,htmlState:t.copyState(a,e.htmlState)}},token:function(t,e){return e.token(t,e)},indent:function(e,n,i){return!e.localMode||/^\s*<\//.test(n)?a.indent(e.htmlState,n):e.localMode.indent?e.localMode.indent(e.localState,n,i):t.Pass},innerMode:function(t){return{state:t.localState||t.htmlState,mode:t.localMode||a}}}},"xml","javascript","css"),t.defineMIME("text/html","htmlmixed")}(n(6),n(189),n(188),n(81))},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e1&&void 0!==arguments[1]?arguments[1]:{},i="",r=this.em,o=r&&r.getConfig("avoidInlineStyle"),s=t.styleToString(),a=t.get("classes"),l=n.wrappesIsBody,c=t.get("wrapper");if(this.ids.push("#"+t.getId()),a.each(function(t){return e.compCls.push(t.getFullName())}),(!o||c)&&s){var u="#"+t.getId();i=(u=l&&c?"body":u)+"{"+s+"}"}return t.components().each(function(t){return i+=e.buildFromModel(t,n)}),i},build:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=n.cssc,o=n.em||"";this.em=o,this.compCls=[],this.ids=[];var s=this.buildFromModel(t,n),a=(0,i.isUndefined)(n.clearStyles)&&o?o.getConfig("clearStyles"):n.clearStyles;return r&&function(){var t=r.getAll(),i={},l=[];for(var c in t.each(function(t){var r=t.getAtRule();if(r){var o=i[r];o?o.push(t):i[r]=[t]}else s+=e.buildFromRule(t,l,n)}),i){var u="";i[c].forEach(function(t){return u+=e.buildFromRule(t,l,n)}),u&&(s+=c+"{"+u+"}")}o&&a&&t.remove(l)}(),s},buildFromRule:function(t,e){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r="",o=t.selectorsToString({skipAdd:1}),s=t.get("selectorsAdd"),a=t.get("singleAtRule"),l=void 0;if(t.get("selectors").each(function(t){var e=t.getFullName();(n.compCls.indexOf(e)>=0||n.ids.indexOf(e)>=0||i.keepUnusedStyles)&&(l=1)}),o&&l||s||a){var c=t.getDeclaration();c&&(r+=c)}else e.push(t);return r}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Model.extend({build:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.get("components");return e.exportWrapper?e.wrappesIsBody?""+this.buildModels(n)+"":t.toHTML():this.buildModels(n)},buildModels:function(t){var e="";return t.each(function(t){e+=t.toHTML()}),e}})},function(t,e,n){"use strict";t.exports={stylePrefix:"cm-",inlineCss:!1}},function(t,e,n){"use strict";var i=n(1);t.exports=function(){var t={},e=n(196),r=n(195),o=n(194),s=n(193),a=n(192),l=n(191),c=n(186),u={},h={},d={},f={};return{getConfig:function(){return t},config:t,EditorView:c,name:"CodeManager",init:function(n){for(var i in t=n||{},e)i in t||(t[i]=e[i]);var c=t.pStylePrefix;return c&&(t.stylePrefix=c+t.stylePrefix),h.html=new r,h.css=new o,h.json=new s,h.js=new a,f.CodeMirror=new l,this.loadDefaultGenerators().loadDefaultViewers(),this},addGenerator:function(t,e){return u[t]=e,this},getGenerator:function(t){return u[t]||null},getGenerators:function(){return u},addViewer:function(t,e){return d[t]=e,this},getViewer:function(t){return d[t]||null},getViewers:function(){return d},createViewer:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=(0,i.isUndefined)(t.type)?"CodeMirror":t.type,n=this.getViewer(e)&&this.getViewer(e).clone(),r=document.createElement("div"),o=document.createElement("textarea");return r.appendChild(o),n.set(t),n.init(o),n.setElement(r),n},updateViewer:function(t,e){t.setContent(e)},getCode:function(e,n){var i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};i.em=t.em;var r=this.getGenerator(n);return r?r.build(e,i):""},loadDefaultGenerators:function(){for(var t in h)this.addGenerator(t,h[t]);return this},loadDefaultViewers:function(){for(var t in f)this.addViewer(t,f[t]);return this}}}},function(t,e,n){"use strict";t.exports=n(0).View.extend({template:function(t){var e=t.pfx,n=t.ppfx,i=t.content;return'
\n
\n
'+t.title+'
\n
\n
\n
\n
'+i+'
\n
\n
\n
\n '},events:{click:"onClick","click [data-close-modal]":"hide"},initialize:function(t){var e=this.model,n=t.config||{},i=n.stylePrefix||"";this.config=n,this.pfx=i,this.ppfx=n.pStylePrefix||"",this.listenTo(e,"change:open",this.updateOpen),this.listenTo(e,"change:title",this.updateTitle),this.listenTo(e,"change:content",this.updateContent)},onClick:function(t){this.config.backdrop&&t.target===this.el&&this.hide()},getCollector:function(){return this.$collector||(this.$collector=this.$el.find("."+this.pfx+"collector")),this.$collector},getContent:function(){var t=this.pfx;return this.$content||(this.$content=this.$el.find("."+t+"content #"+t+"c")),this.$content},getTitle:function(){return this.$title||(this.$title=this.$el.find("."+this.pfx+"title")),this.$title.get(0)},updateContent:function(){var t=this.getContent(),e=t.children(),n=this.getCollector(),i=this.model.get("content");e.length&&n.append(e),t.empty().append(i)},updateTitle:function(){var t=this.getTitle();t&&(t.innerHTML=this.model.get("title"))},updateOpen:function(){this.el.style.display=this.model.get("open")?"":"none"},hide:function(){this.model.set("open",0)},show:function(){this.model.set("open",1)},render:function(){var t=this.$el,e=this.pfx,n=(this.ppfx,this.model.toJSON());return n.pfx=this.pfx,n.ppfx=this.ppfx,t.html(this.template(n)),t.attr("class",e+"container"),this.updateOpen(),this}})},function(t,e,n){"use strict";var i=n(0);t.exports=i.Model.extend({defaults:{title:"",content:"",open:!1}})},function(t,e,n){"use strict";t.exports={stylePrefix:"mdl-",title:"",content:"",backdrop:!0}},function(t,e,n){"use strict";t.exports=function(){var t,e,i={},r=n(200),o=n(199),s=n(198);return{name:"Modal",init:function(n){for(var a in i=n||{},r)a in i||(i[a]=r[a]);var l=i.pStylePrefix;return l&&(i.stylePrefix=l+i.stylePrefix),t=new o(i),e=new s({model:t,config:i}),this},postRender:function(t){var e=t.model.getConfig().el||t.el;this.render().appendTo(e)},open:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};return t.title&&this.setTitle(t.title),t.content&&this.setContent(t.content),e.show(),this},close:function(){return e.hide(),this},isOpen:function(){return!!t.get("open")},setTitle:function(e){return t.set("title",e),this},getTitle:function(){return t.get("title")},setContent:function(e){return t.set("content"," "),t.set("content",e),this},getContent:function(){return t.get("content")},getContentEl:function(){return e.getContent().get(0)},getModel:function(){return t},render:function(){return e.render().$el}}}},function(t,e,n){"use strict";var i=n(10);t.exports=n(0).View.extend({template:function(){var t=this.pfx;this.ppfx;return'\n \n '+(this.model.get("label")||"")+'\n \n ⨯\n \n '},events:{"click [data-tag-remove]":"removeTag","click [data-tag-status]":"changeStatus","dblclick [data-tag-name]":"startEditTag","focusout [data-tag-name]":"endEditTag"},initialize:function(t){this.config=t.config||{},this.coll=t.coll||null,this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.target=this.config.em,this.listenTo(this.model,"change:active",this.updateStatus)},getInputEl:function(){return this.inputEl||(this.inputEl=this.el.querySelector("[data-tag-name]")),this.inputEl},startEditTag:function(){var t=this.getInputEl();t.contentEditable=!0,t.focus()},endEditTag:function(){var t=this.model,e=this.getInputEl(),n=e.textContent,r=i.escapeName(n),o=this.target,s=o&&o.get("SelectorManager");e.contentEditable=!1,s&&(s.get(r)?e.innerText=t.get("label"):t.set({name:r,label:n}))},changeStatus:function(){this.model.set("active",!this.model.get("active"))},removeTag:function(t){var e=this,n=this.target,i=this.model,r=this.coll,o=(this.el,n&&n.getSelected());o&&(o.get,o.get("classes").remove(i)),r&&r.remove(i),setTimeout(function(){return e.remove()},0)},updateStatus:function(){var t="fa-check-square-o";this.$chk||(this.$chk=this.$el.find("#"+this.pfx+"checkbox")),this.model.get("active")?(this.$chk.removeClass("fa-square-o").addClass(t),this.$el.removeClass("opac50")):(this.$chk.removeClass(t).addClass("fa-square-o"),this.$el.addClass("opac50"))},render:function(){var t=this.pfx,e=this.ppfx;return this.$el.html(this.template()),this.$el.attr("class",t+"tag "+e+"three-bg"),this.updateStatus(),this}})},function(t,e,n){"use strict";var i=o(n(1)),r=o(n(0));function o(t){return t&&t.__esModule?t:{default:t}}var s=n(202);t.exports=r.default.View.extend({template:i.default.template('\n
\n
<%= label %>
\n
\n \n
\n \n \n \n
\n
\n
\n
\n
\n
\n
\n
\n
\n \n \n
\n
\n
<%= selectedLabel %>
\n
\n
\n
'),events:{},initialize:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.config=t.config||{},this.pfx=this.config.stylePrefix||"",this.ppfx=this.config.pStylePrefix||"",this.className=this.pfx+"tags",this.addBtnId=this.pfx+"add-tag",this.newInputId=this.pfx+"new",this.stateInputId=this.pfx+"states",this.stateInputC=this.pfx+"input-c",this.states=this.config.states||[],this.events["click #"+this.addBtnId]="startNewTag",this.events["blur #"+this.newInputId]="endNewTag",this.events["keyup #"+this.newInputId]="onInputKeyUp",this.events["change #"+this.stateInputId]="stateChanged",this.target=this.config.em,this.em=this.target,this.listenTo(this.target,"component:toggled",this.componentChanged),this.listenTo(this.target,"component:update:classes",this.updateSelector),this.listenTo(this.collection,"add",this.addNew),this.listenTo(this.collection,"reset",this.renderClasses),this.listenTo(this.collection,"remove",this.tagRemoved),this.delegateEvents()},tagRemoved:function(t){this.updateStateVis()},getStateOptions:function(){for(var t="",e=0;e'+this.states[e].label+"";return t},addNew:function(t){this.addToClasses(t)},startNewTag:function(t){this.$addBtn.get(0).style.display="none",this.$input.show().focus()},endNewTag:function(t){this.$addBtn.get(0).style.display="",this.$input.hide().val("")},onInputKeyUp:function(t){13===t.keyCode?this.addNewTag(this.$input.val()):27===t.keyCode&&this.endNewTag()},componentChanged:function(t){this.compTarget=this.target.getSelected();var e=this.compTarget,n=[];e&&(this.getStates().val(e.get("state")),n=e.get("classes").getValid()),this.collection.reset(n),this.updateStateVis()},updateStateVis:function(){var t=this.em,e=t&&t.getConfig("avoidInlineStyle");this.collection.length||e?this.getStatesC().css("display","block"):this.getStatesC().css("display","none"),this.updateSelector()},updateSelector:function(){var t=this.target.getSelected();if(this.compTarget=t,t&&t.get){var e=t.get("state"),n=this.collection,i=n.getFullString(n.getStyleable());i=i||"#"+t.getId(),i+=e?":"+e:"";var r=this.el.querySelector("#"+this.pfx+"sel");r&&(r.innerHTML=i)}},stateChanged:function(t){this.compTarget&&(this.compTarget.set("state",this.$states.val()),this.updateSelector())},addNewTag:function(t){var e=this.target,n=this.compTarget;if(t.trim()){if(e){var i=e.get("SelectorManager").add({label:t});if(n){var r=n.get("classes");r.length;r.add(i);r.length;this.collection.add(i),this.updateStateVis()}}this.endNewTag()}},addToClasses:function(t,e){var n=e||null,i=new s({model:t,config:this.config,coll:this.collection}).render().el;return n?n.appendChild(i):this.getClasses().append(i),i},renderClasses:function(){var t=document.createDocumentFragment();return this.collection.each(function(e){this.addToClasses(e,t)},this),this.getClasses()&&this.getClasses().empty().append(t),this},getClasses:function(){return this.$classes||(this.$classes=this.$el.find("#"+this.pfx+"tags-c")),this.$classes},getStates:function(){return this.$states||(this.$states=this.$el.find("#"+this.stateInputId)),this.$states},getStatesC:function(){return this.$statesC||(this.$statesC=this.$el.find("#"+this.stateInputC)),this.$statesC},render:function(){var t=this.ppfx,e=this.config,n=this.$el;return n.html(this.template({selectedLabel:e.selectedLabel,statesLabel:e.statesLabel,label:e.label,pfx:this.pfx,ppfx:this.ppfx})),this.$input=n.find("input#"+this.newInputId),this.$addBtn=n.find("#"+this.addBtnId),this.$classes=n.find("#"+this.pfx+"tags-c"),this.$states=n.find("#"+this.stateInputId),this.$statesC=n.find("#"+this.stateInputC),this.$states.append(this.getStateOptions()),this.renderClasses(),n.attr("class",this.className+" "+t+"one-bg "+t+"two-color"),this}})},function(t,e,n){"use strict";t.exports={stylePrefix:"clm-",appendTo:"",selectors:[],label:"Classes",statesLabel:"- State -",selectedLabel:"Selected",states:[{name:"hover",label:"Hover"},{name:"active",label:"Click"},{name:"nth-of-type(2n)",label:"Even/Odd"}]}},function(t,e,n){"use strict";var i=n(1),r=function(t){return(0,i.isString)(t)&&"#"==t[0]};t.exports=function(t){var e,o,s=t||{},a=n(204),l=n(10),c=n(19),u=n(203);return{Selector:l,Selectors:c,name:"SelectorManager",getConfig:function(){return s},init:function(t){for(var n in s=t||{},a)n in s||(s[n]=a[n]);var i=s.em,r=s.pStylePrefix;return r&&(s.stylePrefix=r+s.stylePrefix),o=new u({collection:new c([],{em:i,config:s}),config:s}),(e=new c(s.selectors)).on("add",function(t){return i.trigger("selector:add",t)}),this},postRender:function(){var t=this.getConfig().appendTo;t&&((0,i.isElement)(t)?t:document.querySelector(t)).appendChild(this.render([]))},add:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};(0,i.isObject)(t)?n=t:n.name=t,r(n.name)&&(n.name=n.name.substr(1),n.type=l.TYPE_ID),n.label&&!n.name&&(n.name=l.escapeName(n.label));var o=n.name,s=o?this.get(o,n.type):e.where(n)[0];return s||e.add(n)},addClass:function(t){var n=[];return(0,i.isString)(t)&&(t=t.trim().split(" ")),t.forEach(function(t){return n.push(e.add({name:t}))}),n},get:function(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.TYPE_CLASS;return r(t)&&(t=t.substr(1),n=l.TYPE_ID),e.where({name:t,type:n})[0]},getAll:function(){return e},render:function(t){return t?new u({collection:new c(t),config:s}).render().el:o.render().el}}}},function(t,e,n){"use strict";var i={4:"media",5:"font-face",6:"page",7:"keyframes",11:"counter-style",12:"supports",13:"document",14:"font-feature-values",15:"viewport"},r=(0,n(1).keys)(i),o=["5","6","11","15"];t.exports=function(t){return{parseSelector:function(){for(var t=[],e=[],n=(arguments.length>0&&void 0!==arguments[0]?arguments[0]:"").split(","),i=0,r=n.length;i=0;if(p)u=1,h=i[c],d=this.parseCondition(l);else if(r.indexOf(c)>=0){var g=this.parseNode(l);d=this.parseCondition(l);for(var v=0,m=g.length;v<%= deviceLabel %>
\n
\n \n \n \n
\n
\n
\n
\n '),events:{change:"updateDevice"},initialize:function(t){this.config=t.config||{},this.em=this.config.em,this.ppfx=this.config.pStylePrefix||"",this.events["click ."+this.ppfx+"add-trasp"]=this.startAdd,this.listenTo(this.em,"change:device",this.updateSelect),this.delegateEvents()},startAdd:function(){},updateDevice:function(){var t=this.em;if(t){var e=this.devicesEl,n=e?e.val():"";t.set("device",n)}},updateSelect:function(){var t=this.em,e=this.devicesEl;if(t&&t.getDeviceModel&&e){var n=t.getDeviceModel(),i=n?n.get("name"):"";e.val(i)}},getOptions:function(){var t="";return this.collection.each(function(e){var n=e.get("name");t+='"}),t},render:function(){var t=this.ppfx;return this.$el.html(this.template({ppfx:t,deviceLabel:this.config.deviceLabel})),this.devicesEl=this.$el.find("."+t+"devices"),this.devicesEl.append(this.getOptions()),this.el.className=t+"devices-c",this}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));t.exports=i.default.Model.extend({idAttribute:"name",defaults:{name:"",width:"",height:"",widthMedia:null},initialize:function(){null==this.get("widthMedia")&&this.set("widthMedia",this.get("width"))}})},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0));var r=n(210);t.exports=i.default.Collection.extend({model:r})},function(t,e,n){"use strict";t.exports={devices:[],deviceLabel:"Device"}},function(t,e,n){"use strict";t.exports=function(){var t,e,i={},r=n(212),o=n(211),s=n(209);return{name:"DeviceManager",init:function(n){for(var a in i=n||{},r)a in i||(i[a]=r[a]);return t=new o(i.devices),e=new s({collection:t,config:i}),this},add:function(e,n,i){var r=i||{};return r.name=e,r.width=n,t.add(r)},get:function(e){return t.get(e)},getAll:function(){return t},render:function(){return e.render().el}}}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){var e=this.constructor;return this.then(function(n){return e.resolve(t()).then(function(){return n})},function(n){return e.resolve(t()).then(function(){return e.reject(n)})})}},function(t,e){var n,i,r=t.exports={};function o(){throw new Error("setTimeout has not been defined")}function s(){throw new Error("clearTimeout has not been defined")}function a(t){if(n===setTimeout)return setTimeout(t,0);if((n===o||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:o}catch(t){n=o}try{i="function"==typeof clearTimeout?clearTimeout:s}catch(t){i=s}}();var l,c=[],u=!1,h=-1;function d(){u&&l&&(u=!1,l.length?c=l.concat(c):h=-1,c.length&&f())}function f(){if(!u){var t=a(d);u=!0;for(var e=c.length;e;){for(l=c,c=[];++h1)for(var n=1;n=0&&(t._idleTimeoutId=setTimeout(function(){t._onTimeout&&t._onTimeout()},e))},n(216),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(11))},function(t,e,n){"use strict";(function(t){Object.defineProperty(e,"__esModule",{value:!0});var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r=function(t){return t&&t.__esModule?t:{default:t}}(n(214));var o=setTimeout;function s(){}function a(t){if(!(this instanceof a))throw new TypeError("Promises must be constructed via new");if("function"!=typeof t)throw new TypeError("not a function");this._state=0,this._handled=!1,this._value=void 0,this._deferreds=[],d(t,this)}function l(t,e){for(;3===t._state;)t=t._value;0!==t._state?(t._handled=!0,a._immediateFn(function(){var n=1===t._state?e.onFulfilled:e.onRejected;if(null!==n){var i;try{i=n(t._value)}catch(t){return void u(e.promise,t)}c(e.promise,i)}else(1===t._state?c:u)(e.promise,t._value)})):t._deferreds.push(e)}function c(t,e){try{if(e===t)throw new TypeError("A promise cannot be resolved with itself.");if(e&&("object"===(void 0===e?"undefined":i(e))||"function"==typeof e)){var n=e.then;if(e instanceof a)return t._state=3,t._value=e,void h(t);if("function"==typeof n)return void d(function(t,e){return function(){t.apply(e,arguments)}}(n,e),t)}t._state=1,t._value=e,h(t)}catch(e){u(t,e)}}function u(t,e){t._state=2,t._value=e,h(t)}function h(t){2===t._state&&0===t._deferreds.length&&a._immediateFn(function(){t._handled||a._unhandledRejectionFn(t._value)});for(var e=0,n=t._deferreds.length;e1&&void 0!==arguments[1]?arguments[1]:{},n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:null,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:null,s=this.get("contentTypeJson"),a=this.get("headers")||{},l=this.get("params"),c=e.body||{},u=void 0,h=void 0;for(var d in l)c[d]=l[d];if((0,r.isUndefined)(a["X-Requested-With"])&&(a["X-Requested-With"]="XMLHttpRequest"),(0,r.isUndefined)(a["Content-Type"])&&s&&(a["Content-Type"]="application/json; charset=utf-8"),s)h=JSON.stringify(c);else for(var f in h=new FormData,c)h.append(f,c[f]);"post"===(u={method:e.method||"post",credentials:"include",headers:a}).method&&(u.body=h),this.onStart(),this.fetch(t,u).then(function(t){return 1==(t.status/200|0)?t.text():t.text().then(function(t){return Promise.reject(t)})}).then(function(t){return n.onResponse(t,i)}).catch(function(t){return n.onError(t,o)})}})},function(t,e,n){"use strict";var i=n(0);t.exports=i.Model.extend({defaults:{checkLocal:!0},store:function(t,e){for(var n in this.checkStorageEnvironment(),t)localStorage.setItem(n,t[n]);"function"==typeof e&&e()},load:function(t,e){this.checkStorageEnvironment();for(var n={},i=0,r=t.length;it.maximumStackLength&&(t.shift(),t.pointer--)}}}a.prototype={isRegistered:function(e){return e&&e.cid?this.registeredObjects[e.cid]:t.contains(this.registeredObjects,e)},register:function(t){return!this.isRegistered(t)&&(t&&t.cid?(this.registeredObjects[t.cid]=t,this.cidIndexes.push(t.cid)):this.registeredObjects.push(t),!0)},unregister:function(e){if(this.isRegistered(e)){if(e&&e.cid)delete this.registeredObjects[e.cid],this.cidIndexes.splice(t.indexOf(this.cidIndexes,e.cid),1);else{var n=t.indexOf(this.registeredObjects,e);this.registeredObjects.splice(n,1)}return!0}return!1},get:function(){return t.map(this.cidIndexes,function(t){return this.registeredObjects[t]},this).concat(this.registeredObjects)}};var d={add:{undo:function(t,e,n,i){t.remove(n,i)},redo:function(t,e,n,i){i.index&&(i.at=i.index),t.add(n,i)},on:function(e,n,i){return{object:n,before:void 0,after:e,options:t.clone(i)}}},remove:{undo:function(t,e,n,i){"index"in i&&(i.at=i.index),t.add(e,i)},redo:function(t,e,n,i){t.remove(e,i)},on:function(e,n,i){return{object:n,before:e,after:void 0,options:t.clone(i)}}},change:{undo:function(e,n,i,r){t.isEmpty(n)?t.each(t.keys(i),e.unset,e):(e.set(n),r&&r.unsetData&&r.unsetData.before&&r.unsetData.before.length&&t.each(r.unsetData.before,e.unset,e))},redo:function(e,n,i,r){t.isEmpty(i)?t.each(t.keys(n),e.unset,e):(e.set(i),r&&r.unsetData&&r.unsetData.after&&r.unsetData.after.length&&t.each(r.unsetData.after,e.unset,e))},on:function(e,n){var i=e.changedAttributes(),r=t.keys(i),o=t.pick(e.previousAttributes(),r),s=t.keys(o),a=(n||(n={})).unsetData={after:[],before:[]};return r.length!=s.length&&(r.length>s.length?t.each(r,function(t){t in o||a.before.push(t)},this):t.each(s,function(t){t in i||a.after.push(t)})),{object:e,before:o,after:i,options:t.clone(n)}}},reset:{undo:function(t,e,n){t.reset(e)},redo:function(t,e,n){t.reset(n)},on:function(e,n){return{object:e,before:n.previousModels,after:t.clone(e.models)}}}};function f(){}function p(e,n,i,r){if("object"==typeof n)return t.each(n,function(t,n){2===e?p(e,t,i,r):p(e,n,t,i)});switch(e){case 0:o(i,"undo","redo","on")&&t.all(t.pick(i,"undo","redo","on"),t.isFunction)&&(r[n]=i);break;case 1:r[n]&&t.isObject(i)&&(r[n]=t.extend({},r[n],i));break;case 2:delete r[n]}return this}f.prototype=d;var g=e.Model.extend({defaults:{type:null,object:null,before:null,after:null,magicFusionIndex:null},undo:function(t){c("undo",this.attributes)},redo:function(t){c("redo",this.attributes)}}),v=e.Collection.extend({model:g,pointer:-1,track:!1,isCurrentlyUndoRedoing:!1,maximumStackLength:1/0,setMaxLength:function(t){this.maximumStackLength=t}}),m=e.Model.extend({defaults:{maximumStackLength:1/0,track:!1},initialize:function(e){this.stack=new v,this.objectRegistry=new a,this.undoTypes=new f,this.stack.setMaxLength(this.get("maximumStackLength")),this.on("change:maximumStackLength",function(t,e){this.stack.setMaxLength(e)},this),e&&e.track&&this.startTracking(),e&&e.register&&(t.isArray(e.register)||t.isArguments(e.register)?i(this.register,this,e.register):this.register(e.register))},startTracking:function(){this.set("track",!0),this.stack.track=!0},stopTracking:function(){this.set("track",!1),this.stack.track=!1},isTracking:function(){return this.get("track")},_addToStack:function(t){h(this.stack,t,r(arguments,1),this.undoTypes)},register:function(){l("on",arguments,this._addToStack,this)},unregister:function(){l("off",arguments,this._addToStack,this)},unregisterAll:function(){i(this.unregister,this,this.objectRegistry.get())},undo:function(t){u("undo",this,this.stack,t)},undoAll:function(){u("undo",this,this.stack,!1,!0)},redo:function(t){u("redo",this,this.stack,t)},redoAll:function(){u("redo",this,this.stack,!1,!0)},isAvailable:function(t){var e=this.stack,n=e.length;switch(t){case"undo":return n>0&&e.pointer>-1;case"redo":return n>0&&e.pointer0&&void 0!==arguments[0]?arguments[0]:{};n=i({},a,s),t=n.em,this.em=t,(e=new r.default({track:!0,register:[]})).changeUndoType("change",{condition:!1}),e.changeUndoType("add",{on:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!n.avoidStore)return{object:e,before:void 0,after:t,options:i({},n)}}}),e.changeUndoType("remove",{on:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!n.avoidStore)return{object:e,before:t,after:void 0,options:i({},n)}}});var l={on:function(t,e){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};if(!o&&(o=t.previousAttributes()),!n.avoidStore){var i={object:t,before:o,after:t.toJSON()};return o=null,i}},undo:function(t,e,n,i){t.set(e)},redo:function(t,e,n,i){t.set(n)}};return["style","attributes","content","src"].forEach(function(t){return e.addUndoType("change:"+t,l)}),e.on("undo redo",function(){return t.trigger("component:toggled change:canvasOffset")}),["undo","redo"].forEach(function(n){return e.on(n,function(){return t.trigger(n)})}),this},getConfig:function(){return n},add:function(t){return e.register(t),this},remove:function(t){return e.unregister(t),this},removeAll:function(){return e.unregisterAll(),this},start:function(){return e.startTracking(),this},stop:function(){return e.stopTracking(),this},undo:function(){return t.get("Canvas").isInputFocused()||e.undo(1),this},undoAll:function(){return e.undoAll(),this},redo:function(){return t.get("Canvas").isInputFocused()||e.redo(1),this},redoAll:function(){return e.redoAll(),this},hasUndo:function(){return e.isAvailable("undo")},hasRedo:function(){return e.isAvailable("redo")},getStack:function(){return e.stack},clear:function(){return e.clear(),this},getInstance:function(){return e}}}},function(t,e,n){"use strict";var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},r=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{};return e=r({},a,n),t=e.em,this.em=t,this},onLoad:function(){var t=e.defaults;for(var n in t){var i=t[n];this.add(n,i.keys,i.handler)}},add:function(t,e,r){var a=this.em,l=a.get("Commands"),c=a.getEditor(),u={id:t,keys:e,handler:r};return n[t]&&this.remove(t),n[t]=u,s(e,function(e,n){"object"==(void 0===(r=(0,o.isString)(r)?l.get(r):r)?"undefined":i(r))?r.run(c):r(c);var s=[t,n.shortcut,e];a.trigger.apply(a,["keymap:emit"].concat(s)),a.trigger.apply(a,["keymap:emit:"+t].concat(s))}),a.trigger("keymap:add",u),u},get:function(t){return n[t]},getAll:function(){return n},remove:function(t){var e=this.em,i=this.get(t);if(i)return delete n[t],s.unbind(i.keys),e&&e.trigger("keymap:remove",i),i}}}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(0)).default.$;t.exports={setKey:function(t,e){},getElementRect:function(t){var e=this.opts.posFetcher||"";return e?e(t,{avoidFrameOffset:1}):function(t,e){var n=e||window,i=t.getBoundingClientRect();return{left:i.left+n.pageXOffset,top:i.top+n.pageYOffset,width:i.width,height:i.height}}(t)},init:function(t){return this.setOptions(t),this.handleMouseDown=this.handleMouseDown.bind(this),this.drag=this.drag.bind(this),this.move=this.move.bind(this),this.stop=this.stop.bind(this),this.setKey("up, right, down, left",this.handleKey),this},setOptions:function(t){this.opts=t||{}},focus:function(t){if(!t||t!==this.el){this.getDocumentEl(t),this.blur(),this.el=t,this.handlers=this.opts.dragHandlers||[t];var e=this.getElementRect(t);this.elRect=e,this.startTop=e.top,this.startLeft=e.left,this.getDocumentEl().on("mousedown",this.handleMouseDown)}},blur:function(){this.getDocumentEl().off("mousedown",this.handleMouseDown),this.el=null},start:function(t){this.startPos=this.getMousePos(t);var e=this.getDocumentEl();e.on("mousemove",this.drag),e.on("mouseup",this.stop);var n=this.opts.onStart;"function"==typeof n&&n(t,{docs:e,el:this.el,start:this.startPos,elRect:this.elRect}),this.drag(t)},stop:function(t){var e=this.getDocumentEl();e.off("mousemove",this.drag),e.off("mouseup",this.stop),this.lockedAxis=null;var n=this.opts.onEnd;"function"==typeof n&&n(t,{docs:e,delta:this.delta,end:{x:this.startLeft+this.delta.x,y:this.startTop+this.delta.y}})},handleMouseDown:function(t){var e=t.target;this.isHandler(e)&&this.start(t)},isHandler:function(t){var e=this.handlers;for(var n in e)if(e[n]===t)return!0;return!1},handleKey:function(t,e){switch(e.shortcut){case"up":this.move(0,-1);break;case"right":this.move(1,0);break;case"down":this.move(0,1);break;case"left":this.move(-1,0)}},getDocumentEl:function(t){t=t||this.el;if(!this.$doc){var e=[document];t&&e.push(t.ownerDocument),this.$doc=i(e)}return this.$doc},getMousePos:function(t){var e=this.opts.mousePosFetcher;return e?e(t):{x:t.clientX,y:t.clientY}},drag:function(t){var e=this.lockedAxis,n=this.getMousePos(t),i={x:n.x-this.startPos.x,y:n.y-this.startPos.y};if(t.shiftKey){if(!e){var r=i.x,o=i.y,s=Math.abs(r),a=Math.abs(o);o>=s||o<=-s?e="x":(r>a||r<-a)&&(e="y")}}else e=null;"x"===e&&(i.x=this.startPos.x),"y"===e&&(i.y=this.startPos.y),this.lockedAxis=e,this.delta=i,this.move(i.x,i.y);var l=this.opts.onDrag;"function"==typeof l&&l(t,{delta:i,current:{x:this.startLeft+i.x,y:this.startTop+i.y},lockedAxis:e}),0===t.which&&this.stop(t)},move:function(t,e){this.moveX(t),this.moveY(e)},moveX:function(t){var e=this.el,n=(this.opts,this.startLeft+t),i=this.opts.setX;"function"==typeof i?i(n,{el:e,start:this.startLeft,delta:t}):e.style.left=n+"px"},moveY:function(t){var e=this.el,n=(this.opts,this.startTop+t),i=this.opts.setY;"function"==typeof i?i(n,{el:e,start:this.startTop,delta:t}):e.style.top=n+"px"}}},function(t,e,n){"use strict";var i=function(){function t(t,e){for(var n=0;n0&&void 0!==arguments[0]?arguments[0]:{};return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,t),this.setOptions(e),(0,r.bindAll)(this,"handleKeyDown","handleMouseDown","move","stop"),this}return i(t,[{key:"getConfig",value:function(){return this.opts}},{key:"setOptions",value:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.opts=(0,r.defaults)(t,s),this.setup()}},{key:"setup",value:function(){var t=this.opts,e=t.prefix||"",n=t.appendTo||document.body,i=this.container;for(i||((i=document.createElement("div")).className=e+"resizer-c",n.appendChild(i),this.container=i);i.firstChild;)i.removeChild(i.firstChild);var r={};for(var o in["tl","tc","tr","cl","cr","bl","bc","br"].forEach(function(e){return r[e]=t[e]?function(t,e){var n=e.prefix||"",i=document.createElement("i");return i.className=n+"resizer-h "+n+"resizer-h-"+t,i.setAttribute("data-"+n+"handler",t),i}(e,t):""}),r){var s=r[o];s&&i.appendChild(s)}this.handlers=r,this.mousePosFetcher=t.mousePosFetcher,this.updateTarget=t.updateTarget,this.posFetcher=t.posFetcher,this.onStart=t.onStart,this.onMove=t.onMove,this.onEnd=t.onEnd}},{key:"toggleFrames",value:function(t){if(this.opts.silentFrames){var e=document.querySelectorAll("iframe");(0,r.each)(e,function(e){return e.style.pointerEvents=t?"none":""})}}},{key:"isHandler",value:function(t){var e=this.handlers;for(var n in e)if(e[n]===t)return!0;return!1}},{key:"getFocusedEl",value:function(){return this.el}},{key:"getDocumentEl",value:function(){return[this.el.ownerDocument,document]}},{key:"getElementPos",value:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=this.posFetcher||"";return n?n(t,e):function(t,e){var n=e||window,i=t.getBoundingClientRect();return{left:i.left+n.pageXOffset,top:i.top+n.pageYOffset,width:i.width,height:i.height}}(t)}},{key:"focus",value:function(t){if(!t||t!==this.el){this.el=t;var e=this.opts,n=this.getElementPos(t,{target:"container"}),i=this.container.style;e.avoidContainerUpdate||(i.left=n.left+"px",i.top=n.top+"px",i.width=n.width+"px",i.height=n.height+"px",i.display="block"),(0,o.on)(this.getDocumentEl(),"mousedown",this.handleMouseDown)}}},{key:"blur",value:function(){this.container.style.display="none",this.el&&((0,o.off)(this.getDocumentEl(),"mousedown",this.handleMouseDown),this.el=null)}},{key:"start",value:function(t){if(0===t.button){t.preventDefault(),t.stopPropagation();var e=this.el,n=this.opts||{},i="data-"+n.prefix+"handler",s=this.getElementPos(e,{target:"el"});this.handlerAttr=t.target.getAttribute(i),this.clickedHandler=t.target,this.startDim={t:s.top,l:s.left,w:s.width,h:s.height},this.rectDim={t:s.top,l:s.left,w:s.width,h:s.height},this.startPos={x:t.clientX,y:t.clientY};var a=this.getDocumentEl();(0,o.on)(a,"mousemove",this.move),(0,o.on)(a,"keydown",this.handleKeyDown),(0,o.on)(a,"mouseup",this.stop),(0,r.isFunction)(this.onStart)&&this.onStart(t,{docs:a,config:n,el:e,resizer:this}),this.toggleFrames(1),this.move(t)}}},{key:"move",value:function(t){var e=this.onMove,n=this.mousePosFetcher,i=n?n(t):{x:t.clientX,y:t.clientY};this.currentPos=i,this.delta={x:i.x-this.startPos.x,y:i.y-this.startPos.y},this.keys={shift:t.shiftKey,ctrl:t.ctrlKey,alt:t.altKey},this.rectDim=this.calc(this),this.updateRect(0),e&&e(t),0===t.which&&this.stop(t)}},{key:"stop",value:function(t){var e=this.opts,n=this.getDocumentEl();(0,o.off)(n,"mousemove",this.move),(0,o.off)(n,"keydown",this.handleKeyDown),(0,o.off)(n,"mouseup",this.stop),this.updateRect(1),this.toggleFrames(),(0,r.isFunction)(this.onEnd)&&this.onEnd(t,{docs:n,config:e})}},{key:"updateRect",value:function(t){var e=this.el,n=this.opts,i=this.rectDim,o=this.container.style,s=this.updateTarget,a=this.getSelectedHandler(),l=n.unitHeight,c=n.unitWidth,u=n.keyWidth,h=n.keyHeight;if((0,r.isFunction)(s))s(e,i,{store:t,selectedHandler:a,resizer:this,config:n});else{var d=e.style;d[u]=i.w+c,d[h]=i.h+l}var f=this.getElementPos(e,{target:"container"});n.avoidContainerUpdate||(o.left=f.left+"px",o.top=f.top+"px",o.width=f.width+"px",o.height=f.height+"px")}},{key:"getSelectedHandler",value:function(){var t=this.handlers;if(this.selectedHandler)for(var e in t)if(t[e]===this.selectedHandler)return e}},{key:"handleKeyDown",value:function(t){27===t.keyCode&&(this.rectDim=this.startDim,this.stop(t))}},{key:"handleMouseDown",value:function(t){var e=t.target;this.isHandler(e)?(this.selectedHandler=e,this.start(t)):e!==this.el&&(this.selectedHandler="",this.blur())}},{key:"calc",value:function(t){var e=void 0,n=this.opts||{},i=n.step,r=this.startDim,s=n.minDim,a=n.maxDim,l=t.delta.x,c=t.delta.y,u=r.w,h=r.h,d={t:0,l:0,w:u,h:h};if(t){var f=t.handlerAttr;~f.indexOf("r")&&(e=(0,o.normalizeFloat)(u+l*i,i),e=Math.max(s,e),a&&(e=Math.min(a,e)),d.w=e),~f.indexOf("b")&&(e=(0,o.normalizeFloat)(h+c*i,i),e=Math.max(s,e),a&&(e=Math.min(a,e)),d.h=e),~f.indexOf("l")&&(e=(0,o.normalizeFloat)(u-l*i,i),e=Math.max(s,e),a&&(e=Math.min(a,e)),d.w=e),~f.indexOf("t")&&(e=(0,o.normalizeFloat)(h-c*i,i),e=Math.max(s,e),a&&(e=Math.min(a,e)),d.h=e);var p=n.ratioDefault?!t.keys.shift:t.keys.shift;if(f.indexOf("c")<0&&p){var g=r.w/r.h;d.w/d.h>g?d.h=Math.round(d.w/g):d.w=Math.round(d.h*g)}return~f.indexOf("l")&&(d.l=r.w-d.w),~f.indexOf("t")&&(d.t=r.h-d.h),d}}}]),t}();t.exports={init:function(t){return new a(t)}}},function(t,e,n){"use strict";(function(e){var i=Object.assign||function(t){for(var e=1;es+c-10||ra+l-10)return 1},getCurrentPos:function(){var t=this.eventMove;return{x:t.pageX||0,y:t.pageY||0}},getDim:function(t){var e,n,i,r;if(this.canvasRelative&&this.em){var o=this.em.get("Canvas").getElementPos(t),s=window.getComputedStyle(t),a=parseFloat(s.marginTop),l=parseFloat(s.marginBottom),c=parseFloat(s.marginRight),u=parseFloat(s.marginLeft);e=o.top-a,n=o.left-u,i=o.height+a+l,r=o.width+u+c}else{var h=this.offset(t);e=this.relative?t.offsetTop:h.top-(this.wmargin?-1:1)*this.elT,n=this.relative?t.offsetLeft:h.left-(this.wmargin?-1:1)*this.elL,i=t.offsetHeight,r=t.offsetWidth}return[e,n,i,r]},getChildrenDim:function(t){var e=[];if(!t)return e;var n=this.getTargetModel(t);n&&n.view&&!this.ignoreViewChildren&&(t=n.view.getChildrenContainer());for(var i=t.children,r=0,o=i.length;rs||s>a+c-r||l+r>o||o>l+u-r)&&(i=1),!!i},findPosition:function(t,e,n){for(var i={index:0,method:"before"},r=0,o=0,s=0,a=0,l=0,c=0,u=0,h=0,d=0,f=t.length;do||a&&c>=a||r&&s0&&void 0!==arguments[0]?arguments[0]:{};this.config=e,this.set("Config",e),this.set("modules",[]),this.set("toLoad",[]),this.set("storables",[]);var n=e.el;n&&e.fromElement&&(this.config.components=n.innerHTML),this.attrsOrig=n?(0,r.toArray)(n.attributes).reduce(function(t,e){return t[e.nodeName]=e.nodeValue,t},{}):"",s.forEach(function(e){return t.loadModule(e)}),this.on("change:componentHovered",this.componentHovered,this),this.on("change:changesCount",this.updateChanges,this),[{from:"change:selectedComponent",to:"component:toggled"}].forEach(function(e){var n=e.from,i=e.to;t.listenTo(t,n,function(){for(var e=arguments.length,r=Array(e),o=0;o0&&void 0!==arguments[0]?arguments[0]:null,n=this.get("StorageManager");this.get("toLoad").forEach(function(t){t.onLoad()});var i=function(){t.get("modules").forEach(function(e){return e.postLoad&&e.postLoad(t)}),e&&e()};n&&n.canAutoload()?this.load(i):i()},updateChanges:function(){var t=this.get("StorageManager"),e=this.get("changesCount");this.config.noticeOnUnload&&e?window.onbeforeunload=function(t){return 1}:window.onbeforeunload=null,t.isAutosave()&&e>=t.getStepsBeforeSave()&&this.store()},loadModule:function(t){var e=this.config,n=new t,r=e[n.name.charAt(0).toLowerCase()+n.name.slice(1)]||e[n.name]||{};r.pStylePrefix=e.pStylePrefix||"";var o=this.get("StorageManager");if(n.storageKey&&n.store&&n.load&&o){r.stm=o;var s=this.get("storables");s.push(n),this.set("storables",s)}return r.em=this,n.init(i({},r)),!n.private&&this.set(n.name,n),n.onLoad&&this.get("toLoad").push(n),this.get("modules").push(n),this},init:function(t){this.set("Editor",t)},getEditor:function(){return this.get("Editor")},handleUpdates:function(t,e){var n=this,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};i.temporary||(c&&clearInterval(c),c=setTimeout(function(){i.avoidStore||n.set("changesCount",n.get("changesCount")+1,i)},0))},componentHovered:function(t,e,n){var i=this.previous("componentHovered");i&&this.trigger("component:unhovered",i,n),e&&this.trigger("component:hovered",e,n)},getSelected:function(){return this.get("selected").last()},getSelectedAll:function(){return this.get("selected").models},setSelected:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=(0,r.isArray)(t),s=i?t:[t],a=this.get("selected");i&&this.removeSelected(a.filter(function(t){return!(0,r.contains)(s,t)})),s.forEach(function(t){var r=(0,o.getModel)(t,u);r&&!r.get("selectable")||(!i&&e.removeSelected(a.filter(function(t){return t!==r})),e.addSelected(r,n))})},addSelected:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=(0,o.getModel)(t,u);((0,r.isArray)(i)?i:[i]).forEach(function(t){if(!t||t.get("selectable")){var i=e.get("selected");n.forceChange&&i.remove(t,n),i.push(t,n)}})},removeSelected:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};this.get("selected").remove((0,o.getModel)(t,u),e)},toggleSelected:function(t){var e=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=(0,o.getModel)(t,u);((0,r.isArray)(i)?i:[i]).forEach(function(t){e.get("selected").contains(t)?e.removeSelected(t,n):e.addSelected(t,n)})},setHovered:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=(0,o.getModel)(t,u);n&&!n.get("hoverable")||(e.forceChange&&this.set("componentHovered",""),this.set("componentHovered",n,e))},setComponents:function(t){return this.get("DomComponents").setComponents(t)},getComponents:function(){var t=this.get("DomComponents"),e=this.get("CodeManager");if(t&&e){var n=t.getComponents();return e.getCode(n,"json")}},setStyle:function(t){for(var e=this.get("CssComposer").getAll(),n=0,i=e.length;n"+i+"<\/script>":""},getCss:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.config,n=e.wrappesIsBody,i=t.avoidProtected,o=(0,r.isUndefined)(t.keepUnusedStyles)?e.keepUnusedStyles:t.keepUnusedStyles,s=this.get("CssComposer"),a=this.get("DomComponents").getComponent();return(i?"":e.protectedCss)+this.get("CodeManager").getCode(a,"css",{cssc:s,wrappesIsBody:n,keepUnusedStyles:o})},getJs:function(){var t=this.get("DomComponents").getWrapper();return this.get("CodeManager").getCode(t,"js").trim()},store:function(t){var e=this,n=this.get("StorageManager"),i={};if(n)return this.get("storables").forEach(function(t){var e=t.store(1);for(var n in e)i[n]=e[n]}),n.store(i,function(n){t&&t(n),e.set("changesCount",0),e.trigger("storage:store",i)}),i},load:function(){var t=this,e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:null;this.getCacheLoad(1,function(n){t.get("storables").forEach(function(t){return t.load(n)}),e&&e(n)})},getCacheLoad:function(t,e){var n=this,i=t?1:0;if(this.cacheLoad&&!i)return this.cacheLoad;var r=this.get("StorageManager"),o=[];if(!r)return{};this.get("storables").forEach(function(t){var e=t.storageKey;((e="function"==typeof e?e():e)instanceof Array?e:[e]).forEach(function(t){o.push(t)})}),r.load(o,function(t){n.cacheLoad=t,e&&e(t),setTimeout(function(){return n.trigger("storage:load",t)},0)})},getDeviceModel:function(){var t=this.get("device");return this.get("DeviceManager").get(t)},runDefault:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.get("Commands").get(this.config.defaultCommand);e&&!this.defaultRunning&&(e.stop(this,this,t),e.run(this,this,t),this.defaultRunning=1)},stopDefault:function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},e=this.get("Commands").get(this.config.defaultCommand);e&&(e.stop(this,this,t),this.defaultRunning=0)},refreshCanvas:function(){this.set("canvasOffset",this.get("Canvas").getOffset())},clearSelection:function(t){(t||window).getSelection().removeAllRanges()},getCurrentMedia:function(){var t=this.config,e=this.getDeviceModel(),n=t.mediaCondition,i=t.devicePreviewMode,r=e&&e.get("widthMedia");return e&&r&&!i?"("+n+": "+r+")":""},getWrapper:function(){return this.get("DomComponents").getWrapper()},getDirtyCount:function(){return this.get("changesCount")},destroyAll:function(){var t=this.attributes,e=t.DomComponents,n=t.CssComposer,i=t.UndoManager,r=t.Panels,o=t.Canvas;e.clear(),n.clear(),i.clear().removeAll(),r.getPanels().reset(),o.getCanvasView().remove(),this.view.remove(),this.stopListening(),u(this.config.el).empty().attr(this.attrsOrig)},setEditing:function(t){return this.set("editing",t),this},isEditing:function(){return!!this.get("editing")},data:function(t,e,n){if(t["_gjs-data"]||(t["_gjs-data"]={}),(0,r.isUndefined)(n))return t["_gjs-data"][e];t["_gjs-data"][e]=n}})},function(t,e,n){"use strict";t.exports={stylePrefix:"gjs-",components:"",style:"",fromElement:0,noticeOnUnload:!0,showOffsets:!1,showOffsetsSelected:!1,forceClass:!0,height:"900px",width:"100%",baseCss:"\n * {\n box-sizing: border-box;\n }\n html, body, #wrapper {\n min-height: 100%;\n }\n body {\n margin: 0;\n height: 100%;\n background-color: #fff\n }\n #wrapper {\n overflow: auto;\n overflow-x: hidden;\n }\n\n * ::-webkit-scrollbar-track {\n background: rgba(0, 0, 0, 0.1)\n }\n\n * ::-webkit-scrollbar-thumb {\n background: rgba(255, 255, 255, 0.2)\n }\n\n * ::-webkit-scrollbar {\n width: 10px\n }\n ",protectedCss:"* { box-sizing: border-box; } body {margin: 0;}",canvasCss:"",defaultCommand:"select-comp",showToolbar:1,allowScripts:0,showDevices:1,devicePreviewMode:0,mediaCondition:"max-width",tagVarStart:"{[ ",tagVarEnd:" ]}",keepEmptyTextNodes:0,jsInHtml:!0,nativeDnD:1,multipleSelection:1,exportWrapper:0,wrappesIsBody:1,avoidInlineStyle:0,avoidDefaults:0,clearStyles:0,el:"",undoManager:{},assetManager:{},canvas:{},layers:{},storageManager:{},rte:{},domComponents:{},modal:{},codeManager:{},panels:{},commands:{},cssComposer:{},selectorManager:{},deviceManager:{devices:[{name:"Desktop",width:""},{name:"Tablet",width:"768px",widthMedia:"992px"},{name:"Mobile landscape",width:"568px",widthMedia:"768px"},{name:"Mobile portrait",width:"320px",widthMedia:"480px"}]},styleManager:{sectors:[{name:"General",open:!1,buildProps:["float","display","position","top","right","left","bottom"]},{name:"Dimension",open:!1,buildProps:["width","height","max-width","min-height","margin","padding"]},{name:"Typography",open:!1,buildProps:["font-family","font-size","font-weight","letter-spacing","color","line-height","text-align","text-shadow"],properties:[{property:"text-align",list:[{value:"left",className:"fa fa-align-left"},{value:"center",className:"fa fa-align-center"},{value:"right",className:"fa fa-align-right"},{value:"justify",className:"fa fa-align-justify"}]}]},{name:"Decorations",open:!1,buildProps:["border-radius-c","background-color","border-radius","border","box-shadow","background"]},{name:"Extra",open:!1,buildProps:["transition","perspective","transform"]}]},blockManager:{},traitManager:{},textViewCode:"Code",keepUnusedStyles:0}},function(t,e,n){"use strict";var i=function(t){return t&&t.__esModule?t:{default:t}}(n(20));t.exports=function(t){var e=t||{},r=n(233),o=n(232),s=n(89);for(var a in r)a in e||(e[a]=r[a]);e.pStylePrefix=e.stylePrefix;var l=new o(e),c=new s({model:l,config:e});return{$:i.default,editor:l,DomComponents:l.get("DomComponents"),LayerManager:l.get("LayerManager"),CssComposer:l.get("CssComposer"),StorageManager:l.get("StorageManager"),AssetManager:l.get("AssetManager"),BlockManager:l.get("BlockManager"),TraitManager:l.get("TraitManager"),SelectorManager:l.get("SelectorManager"),CodeManager:l.get("CodeManager"),Commands:l.get("Commands"),Keymaps:l.get("Keymaps"),Modal:l.get("Modal"),Panels:l.get("Panels"),StyleManager:l.get("StyleManager"),Canvas:l.get("Canvas"),UndoManager:l.get("UndoManager"),DeviceManager:l.get("DeviceManager"),RichTextEditor:l.get("RichTextEditor"),Utils:l.get("Utils"),Config:l.get("Config"),init:function(){return l.init(this),this},getConfig:function(t){return l.getConfig(t)},getHtml:function(t){return l.getHtml(t)},getCss:function(t){return l.getCss(t)},getJs:function(){return l.getJs()},getComponents:function(){return l.get("DomComponents").getComponents()},setComponents:function(t){return l.setComponents(t),this},addComponents:function(t,e){return this.getComponents().add(t,e)},getStyle:function(){return l.get("CssComposer").getAll()},setStyle:function(t){return l.setStyle(t),this},getSelected:function(){return l.getSelected()},getSelectedAll:function(){return l.getSelectedAll()},getSelectedToStyle:function(){var t=l.getSelected();if(t)return this.StyleManager.getModelToStyle(t)},select:function(t){return l.setSelected(t),this},selectAdd:function(t){return l.addSelected(t),this},selectRemove:function(t){return l.removeSelected(t),this},selectToggle:function(t){return l.toggleSelected(t),this},setDevice:function(t){return l.set("device",t),this},getDevice:function(){return l.get("device")},runCommand:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=void 0,i=l.get("Commands").get(t);return i&&(n=i.callRun(this,e)),n},stopCommand:function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=void 0,i=l.get("Commands").get(t);return i&&(n=i.callStop(this,e)),n},store:function(t){return l.store(t)},load:function(t){return l.load(t)},getContainer:function(){return e.el},getDirtyCount:function(){return l.getDirtyCount()},refresh:function(){l.refreshCanvas()},setCustomRte:function(t){this.RichTextEditor.customRte=t},on:function(t,e){return l.on(t,e)},off:function(t,e){return l.off(t,e)},trigger:function(t){return l.trigger.apply(l,arguments)},destroy:function(){return l.destroyAll()},getEl:function(){return c.el},getModel:function(){return l},render:function(){var t=this;return l.on("loaded",function(){t.UndoManager.clear(),l.get("modules").forEach(function(t){t.postRender&&t.postRender(c)})}),c.render(),c.el}}}},function(t,e,n){"use strict";var i=Object.assign||function(t){for(var e=1;e0&&void 0!==arguments[0]?arguments[0]:{},a=r.container;if(!a)throw new Error("'container' is required");(r=i({},n,r)).el=(0,s.isElement)(a)?a:document.querySelector(a);var l=new o.default(r).init();return r.plugins.forEach(function(e){var n=t.get(e);n?n(l,r.pluginsOpts[e]||{}):console.warn("Plugin "+e+" not found")}),l.getModel().loadOnStart(),r.autorender&&l.render(),e.push(l),l}}}()}])}); +//# sourceMappingURL=grapes.min.js.map \ No newline at end of file diff --git a/obsolete/public/grapejs/dist/js/grapesjs-mjml.min.js b/obsolete/public/grapejs/dist/js/grapesjs-mjml.min.js index 7dbadd73..53272546 100644 --- a/obsolete/public/grapejs/dist/js/grapesjs-mjml.min.js +++ b/obsolete/public/grapejs/dist/js/grapesjs-mjml.min.js @@ -1,108 +1,69 @@ -/*! grapesjs-mjml - 0.0.7 */ -!function(t,e){"object"==typeof exports&&"object"==typeof module?module.exports=e():"function"==typeof define&&define.amd?define([],e):"object"==typeof exports?exports["grapesjs-mjml"]=e():t["grapesjs-mjml"]=e()}(this,function(){return function(t){function e(r){if(n[r])return n[r].exports;var o=n[r]={exports:{},id:r,loaded:!1};return t[r].call(o.exports,o,o.exports,e),o.loaded=!0,o.exports}var n={};return e.m=t,e.c=n,e.p="",e(0)}([function(t,e,n){"use strict";grapesjs.plugins.add("gjs-mjml",function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},r=e,o={codeViewerTheme:"hopscotch",importPlaceholder:"",modalTitleImport:"Import MJML",modalBtnImport:"Import",modalLabelImport:"",modalTitleExport:"Export MJML",modalLabelExport:"",overwriteExport:1,preMjml:"",postMjml:"",exportOnly:"",resetBlocks:1,resetDevices:1,resetStyleManager:1,columnsPadding:"10px 0"};for(var i in o)i in r||(r[i]=o[i]);var a=t.getConfig();if(a.forceClass=0,a.devicePreviewMode=1,n(1).default(t,r),n(2).default(t,r),n(684).default(t,r),n(687).default(t,r),n(688).default(t,r),r.resetDevices){var u=t.DeviceManager;u.getAll().reset(),u.add("Desktop",""),u.add("Mobile","320px")}})},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=t.BlockManager;e.resetBlocks&&n.getAll().reset(),n.add("mj-1-column",{label:"1 Column",content:"\n Content 1\n ",attributes:{class:"gjs-fonts gjs-f-b1","data-type":"mj-section"}}),n.add("mj-2-columns",{label:"2 Columns",content:"\n Content 1\n Content 2\n ",attributes:{class:"gjs-fonts gjs-f-b2","data-type":"mj-section"}}),n.add("mj-3-columns",{label:"3 Columns",content:"\n Content 1\n Content 2\n Content 3\n ",attributes:{class:"gjs-fonts gjs-f-b3","data-type":"mj-section"}}),n.add("mj-text",{label:"Text",content:"Insert text here",attributes:{class:"gjs-fonts gjs-f-text","data-type":"mj-text"}}),n.add("mj-button",{label:"Button",content:"Button",attributes:{class:"gjs-fonts gjs-f-button","data-type":"mj-button"}}),n.add("mj-image",{label:"Image",content:'',attributes:{class:"fa fa-image","data-type":"mj-image"}}),n.add("mj-divider",{label:"Divider",content:"",attributes:{class:"gjs-fonts gjs-f-divider","data-type":"mj-divider"}}),n.add("mj-social",{label:"Social",content:"",attributes:{class:"fa fa-share-alt","data-type":"mj-social"}})}},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o=n(3);e.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},i=t.DomComponents,a=i.getType("default"),u=i.getType("text"),s=i.getType("image"),c=i.getType("link"),l=a.model,f=a.view,p=u.model,h=u.view,d=s.model,v=s.view,g=c.model,m=c.view,y=n(680),_=document.createElement("div"),b={init:function(){var t=Object.assign({},this.get("attributes")),e=this.get("style");this.defaultStyle=e;for(var n in e)n in t||(t[n]=e[n]);this.set("attributes",t),this.set("style",t),this.listenTo(this,"change:style",this.handleStyleChange)},handleStyleChange:function(){var t=Object.assign({},this.get("attributes"),this.get("style"));this.set("attributes",t)},getMjmlAttributes:function(){var t=this.get("attributes")||{};delete t.style;var e=this.get("src");return e&&(t.src=e),t},getAttrToHTML:function(){var t=Object.assign({},this.get("attributes")||{}),e=Object.assign({},this.defaultStyle||{});delete t.style;for(var n in t)t[n]==e[n]&&delete t[n];return t},toHTML:function(t){var e="",n=this,o=n.get("tagName"),i=n.get("void"),a="",u=this.getAttrToHTML();for(var s in u){var c=u[s];a+=void 0!==("undefined"==typeof c?"undefined":r(c))&&""!==c?" "+s+'="'+c+'"':""}return e+="<"+o+a+(i?"/":"")+">"+n.get("content"),n.get("components").each(function(t){e+=t.toHTML()}),i||(e+=""),e}},w={init:function(){this.stopListening(this.model,"change:style"),this.listenTo(this.model,"change:attributes change:src",this.rerender)},rerender:function(){this.render(null,null,{},1)},getMjmlTemplate:function(){return{start:"",end:""}},getInnerMjmlTemplate:function(){var t=this.model,e=t.get("tagName"),n=t.getMjmlAttributes(),o="";for(var i in n){var a=n[i];o+=void 0!==("undefined"==typeof a?"undefined":r(a))&&""!==a?" "+i+'="'+a+'"':""}return{start:"<"+e+" "+o+">",end:""}},getTemplateFromEl:function(t){return t.firstChild.innerHTML},getTemplateFromMjml:function(){var t=this.getMjmlTemplate(),e=this.getInnerMjmlTemplate(),n=(0,o.mjml2html)(t.start+"\n "+e.start+e.end+t.end),r=n.html;r=r.replace(//,"");var i=r.indexOf("")+6,a=r.indexOf("");return r=r.substring(i,a).trim(),_.innerHTML=r,this.getTemplateFromEl(_)},renderChildren:function(t){var e=this.getChildrenContainer();t?this.componentsView.$parent=$(e):(this.componentsView=new y({collection:this.model.get("components"),config:this.config,defaultTypes:this.opts.defaultTypes,componentTypes:this.opts.componentTypes}),this.childNodes=this.componentsView.render($(e)).el.childNodes);for(var n=Array.prototype.slice.call(this.childNodes),r=0,o=n.length;r",end:""+t.end}},renderStyle:function(){this.el.style.cssText=this.el.getAttribute("style")+this.attributes.style},renderContent:function(){this.getChildrenContainer().innerHTML=this.model.get("content")}}))}),i.addType("mj-section",{model:l.extend(Object.assign({},b,{defaults:Object.assign({},l.prototype.defaults,{"custom-name":"Section",draggable:"[data-type=mj-container]",droppable:"[data-type=mj-column]",style:{"padding-top":"10px","padding-bottom":"10px","vertical-align":"top","text-align":"center"},stylable:["vertical-align","text-align","padding","padding-top","padding-left","padding-right","padding-bottom","background-color","background-url","background-repeat","background-size","border-radius","border-top-left-radius","border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius","border","border-width","border-style","border-color"]})}),{isComponent:function(t){if("MJ-SECTION"==t.tagName)return{type:"mj-section"}}}),view:f.extend(Object.assign({},w,{tagName:"div",attributes:{style:"pointer-events: all;","data-type":"mj-section"},getChildrenSelector:function(){return"tbody > tr > td"},init:function(){w.init.call(this),this.listenTo(this.model.get("components"),"add remove",this.render)}}))});var x=e.columnsPadding;i.addType("mj-column",{model:l.extend(Object.assign({},b,{defaults:Object.assign({},l.prototype.defaults,{"custom-name":"Column",draggable:"[data-type=mj-section]",stylable:["background-color","vertical-align","width","border-radius","border-top-left-radius","border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius","border","border-width","border-style","border-color"]})}),{isComponent:function(t){if("MJ-COLUMN"==t.tagName)return{type:"mj-column"}}}),view:f.extend(Object.assign({},w,{tagName:"div",attributes:{"data-type":"mj-column",style:"pointer-events: all;"+(x?"padding: "+x+";":"")},getTemplateFromMjml:function(){var t=this.getMjmlTemplate(),e=this.getInnerMjmlTemplate(),n=(0,o.mjml2html)(t.start+"\n "+e.start+e.end+t.end),r=n.html,i=[];_.innerHTML=r;var a=Array.from(_.querySelectorAll("style"));a.forEach(function(t){i.push(t.innerHTML)});var u=r.replace(//,""),s=u.indexOf("")+6,c=u.indexOf("");_.innerHTML=u.substring(s,c).trim();for(var l,f=this.getTemplateFromEl(_),p={},h=f.attributes,d=0,v=h.length;d"+e.style+""),this.getChildrenContainer().innerHTML=this.model.get("content"),this.renderChildren(),this.el.style.cssText=this.el.getAttribute("style")+this.attributes.style,this},getMjmlTemplate:function(){var t=this.model.collection.length-1;t=t?t:0;var e=Array(t).fill("").join("");return{start:"",end:e+""}},getTemplateFromEl:function(t){return t.firstChild.querySelector("div")},getChildrenSelector:function(){return"tbody"}}))}),i.addType("mj-text",{model:p.extend(Object.assign({},b,{defaults:Object.assign({},p.prototype.defaults,{"custom-name":"Text",draggable:"[data-type=mj-column]",highlightable:!1,stylable:["height","font-style","font-size","font-weight","font-family","color","line-height","letter-spacing","text-decoration","align","text-transform","padding","padding-top","padding-left","padding-right","padding-bottom","container-background-color"],style:{"padding-top":"10px","padding-bottom":"10px","padding-right":"25px","padding-left":"25px","font-size":"13px","line-height":"22px",align:"left"}})}),{isComponent:function(t){if("MJ-TEXT"==t.tagName)return{type:"mj-text",content:t.innerHTML,components:[]}}}),view:h.extend(Object.assign({},w,{tagName:"tr",attributes:{style:"pointer-events: all; display: table; width: 100%"},getMjmlTemplate:function(){return{start:"",end:""}},getTemplateFromEl:function(t){return t.querySelector("tr").innerHTML},getChildrenSelector:function(){return"div"},renderChildren:function(){w.renderChildren.call(this)},enableEditing:function(){h.prototype.enableEditing.apply(this,arguments),this.getChildrenContainer().style.pointerEvents="all"},disableEditing:function(){h.prototype.disableEditing.apply(this,arguments),this.getChildrenContainer().style.pointerEvents="none"}}))}),i.addType("mj-button",{model:g.extend(Object.assign({},b,{defaults:Object.assign({},g.prototype.defaults,{"custom-name":"Button",draggable:"[data-type=mj-column]",highlightable:!1,stylable:["width","height","background-color","container-background-color","font-style","font-size","font-weight","font-family","color","text-decoration","align","vertical-align","text-transform","padding","padding-top","padding-left","padding-right","padding-bottom","border-radius","border-top-left-radius","border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius","border","border-width","border-style","border-color"],style:{"background-color":"#414141","border-radius":"3px","font-size":"13px","font-weight":"400",color:"#ffffff","vertical-align":"middle","padding-bottom":"10px","padding-right":"25px","padding-left":"25px",align:"center"},traits:["href"]})}),{isComponent:function(t){if("MJ-BUTTON"==t.tagName)return{type:"mj-button"}}}),view:m.extend(Object.assign({},w,{tagName:"tr",attributes:{style:"pointer-events: all; display: table; width: 100%"},getMjmlTemplate:function(){return{start:"",end:""}},getTemplateFromEl:function(t){return t.querySelector("tr").innerHTML},getChildrenSelector:function(){return"a,p"},renderChildren:function(){w.renderChildren.call(this)}}))}),i.addType("mj-image",{model:d.extend(Object.assign({},b,{defaults:Object.assign({},d.prototype.defaults,{"custom-name":"Image",resizable:!1,highlightable:!1,draggable:"[data-type=mj-column]",stylable:["width","height","padding","padding-top","padding-left","padding-right","padding-bottom","border-radius","border-top-left-radius","border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius","border","border-width","border-style","border-color","container-background-color","align"],style:{"padding-top":"10px","padding-bottom":"10px","padding-right":"25px","padding-left":"25px",align:"center"},traits:["href","rel","alt","title"],void:!0})}),{isComponent:function(t){if("MJ-IMAGE"==t.tagName)return{type:"mj-image"}}}),view:v.extend(Object.assign({},w,{tagName:"tr",attributes:{style:"pointer-events: all; display: table; width: 100%; user-select: none;"},getMjmlTemplate:function(){return{start:"",end:""}},getTemplateFromEl:function(t){return t.querySelector("tr").innerHTML},getChildrenSelector:function(){return"img"}}))}),i.addType("mj-social",{model:l.extend(Object.assign({},b,{defaults:Object.assign({},l.prototype.defaults,{"custom-name":"Social",draggable:"[data-type=mj-column]",droppable:!1,stylable:["text-decoration","align","font-family","font-size","line-height","padding","padding-top","padding-left","padding-right","padding-bottom","border-radius","border-top-left-radius","border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius","container-background-color","color","facebook-icon-color","twitter-icon-color","google-icon-color","instagram-icon-color","linkedin-icon-color","pinterest-icon-color"],style:{align:"center","icon-size":"20px","font-size":"13px","line-height":"22px","facebook-icon-color":"#3b5998","twitter-icon-color":"#55acee","google-icon-color":"#dc4e41","instagram-icon-color":"#3f729b","linkedin-icon-color":"#0077b5","pinterest-icon-color":"#bd081c",display:"facebook twitter google"},traits:["display",{name:"facebook-content",value:"Share"},{name:"facebook-href",value:"[[SHORT_PERMALINK]]"},{name:"twitter-content",value:"Tweet"},{name:"twitter-href",value:"[[SHORT_PERMALINK]]"},{name:"google-content",value:"+1"},{name:"google-href",value:"[[SHORT_PERMALINK]]"},{name:"instagram-content",value:"Share"},{name:"instagram-href",value:"[[SHORT_PERMALINK]]"},{name:"linkedin-content",value:"Share"},{name:"linkedin-href",value:"[[SHORT_PERMALINK]]"},{name:"pinterest-content",value:"Pin it"},{name:"pinterest-href",value:"[[SHORT_PERMALINK]]"},{type:"select",label:"Mode",name:"mode",options:[{value:"horizontal",name:"Horizontal"},{value:"vertical",name:"Vertical"}]}],void:!0})}),{isComponent:function(t){if("MJ-SOCIAL"==t.tagName)return{type:"mj-social"}}}),view:f.extend(Object.assign({},w,{tagName:"tr",attributes:{style:"pointer-events: all; display: table; width: 100%"},getMjmlTemplate:function(){return{start:"",end:""}},getTemplateFromEl:function(t){return t.querySelector("tr").innerHTML},render:function(){this.renderAttributes(),this.el.innerHTML=this.getTemplateFromMjml();var t=this.model.get("content").trim();return t&&(this.getChildrenContainer().innerHTML=t),this.renderChildren(),this.el.style.cssText=this.attributes.style,this},getChildrenSelector:function(){return"img"}}))}),i.addType("mj-divider",{model:l.extend(Object.assign({},b,{defaults:Object.assign({},l.prototype.defaults,{"custom-name":"Divider",draggable:"[data-type=mj-column]",droppable:!1,style:{width:"100%","border-width":"4px","border-style":"solid","border-color":"#000000","padding-top":"10px","padding-bottom":"10px","padding-right":"25px","padding-left":"25px"},stylable:["padding","padding-top","padding-left","padding-right","padding-bottom","width","container-background-color","border-detached","border-width","border-style","border-color"]})}),{isComponent:function(t){if("MJ-DIVIDER"==t.tagName)return{type:"mj-divider"}}}),view:f.extend(Object.assign({},w,{tagName:"tr",attributes:{style:"pointer-events: all; display: table; width: 100%; user-select: none;"},getMjmlTemplate:function(){return{start:"",end:""}},getTemplateFromEl:function(t){return t.querySelector("tr").innerHTML},getChildrenSelector:function(){return"p"}}))})}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0});var o=n(4);Object.keys(o).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(e,t,{enumerable:!0,get:function(){return o[t]}})});var i=n(273),a=r(i),u=n(580),s=r(u),c=n(581),l=r(c),f=n(587),p=r(f),h=n(588),d=r(h),v=n(589),g=r(v),m=n(590),y=r(m),_=n(591),b=r(_),w=n(595),x=r(w),E=n(596),k=r(E),j=n(598),O=r(j),S=n(603),T=r(S),C=n(611),A=r(C),N=n(614),D=r(N),M=n(626),I=r(M),R=n(669),P=r(R),L=n(628),B=r(L),q=n(670),U=r(q),V=n(673),F=r(V),z=n(616),H=r(z),W=n(597),K=r(W),$=n(674),G=r($),J=n(675),Y=r(J),X=n(677),Q=r(X),Z=n(678),tt=r(Z),et=n(679),nt=r(et),rt=O.default.Accordion,ot=O.default.AccordionElement,it=O.default.AccordionTitle,at=O.default.AccordionText,ut=A.default.Hero,st=A.default.HeroContent,ct=D.default.Invoice,lt=D.default.InvoiceItem,ft=T.default.Carousel,pt=T.default.CarouselImage,ht=I.default.Navbar,dt=I.default.InlineLinks,vt=I.default.Link;[rt,ot,it,at,s.default,ft,pt,l.default,p.default,d.default,g.default,ut,st,y.default,b.default,dt,ct,lt,vt,x.default,k.default,ht,P.default,B.default,U.default,F.default,H.default,K.default,G.default].map(o.registerMJElement),(0,a.default)([Y.default,Q.default,tt.default,nt.default],function(t){return(0,o.registerMJHeadElement)(t)})},function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0}),e.mjml2html=e.MJMLValidator=e.version=e.mjIncludeRegexp=e.documentParser=e.rulesCollection=e.registerMJRule=e.formatValidationError=e.MJMLHeadElements=e.registerMJHeadElement=e.helpers=e.elements=e.registerMJElement=e.MJMLRenderer=e.MJMLElement=void 0;var i=n(5);Object.defineProperty(e,"mjIncludeRegexp",{enumerable:!0,get:function(){return i.includes}});var a=n(9),u=o(a),s=n(199),c=o(s),l=n(113),f=o(l),p=n(221),h=o(p),d=n(570),v=r(d),g=n(573),m=o(g);e.MJMLElement=m.default,e.MJMLRenderer=u.default,e.registerMJElement=l.registerMJElement,e.elements=f.default,e.helpers=v,e.registerMJHeadElement=p.registerMJHeadElement,e.MJMLHeadElements=h.default,e.formatValidationError=s.formatValidationError,e.registerMJRule=s.registerMJRule,e.rulesCollection=s.rulesCollection;e.documentParser=function t(e,r){var t=n(220).default;return t(e,r)},e.version=function(){return"3.3.2"},e.MJMLValidator=c.default,e.mjml2html=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return new u.default(t,e).render()}},function(t,e,n){(function(t){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0}),e.includes=void 0;var o=n(7),i=r(o),a=n(8),u=r(a),s=e.includes=/|>\s*<\/mj-include>)/g,c=function(t){return(/]*>([\s\S]*?)<\/mj-container>/.exec(t)||[])[1]},l=function(t){return(/]*>([\s\S]*?)<\/mj-head>/.exec(t)||[])[1]},f=function(t){return t.trim().match(/.mjml/)&&t||t+".mjml"},p=function(t){var e={content:c(t),head:l(t)};return e.content||e.head||(e.content=t),e},h=function t(e,n,r,o){var a=u.default.normalize(u.default.join(e,f(o))),c=void 0;try{c=i.default.readFileSync(a,"utf8")}catch(t){return""}var l=p(c),h=l.content,d=l.head;if(!h&&!d)throw new Error("Error while reading file: "+a+", file has no content ?");if(d){var v=n.length;d=d.replace(s,t.bind(void 0,u.default.resolve(u.default.dirname(a)),n)),n.splice(v-1,0,d)}return h&&(h=h.replace(s,t.bind(void 0,u.default.resolve(u.default.dirname(a)),n))),h||""};e.default=function(e,n){var r=n.filePath,o=[],i=e,a=r?u.default.dirname(r):t.cwd();return i=i.replace(s,h.bind(void 0,u.default.resolve(a),o)),o.length>0&&(i.indexOf("")==-1&&(i=i.replace("","\n \n \n")),i=i.replace("",o.join("\n")+"\n")),i}}).call(e,n(6))},function(t,e){function n(){throw new Error("setTimeout has not been defined")}function r(){throw new Error("clearTimeout has not been defined")}function o(t){if(l===setTimeout)return setTimeout(t,0);if((l===n||!l)&&setTimeout)return l=setTimeout,setTimeout(t,0);try{return l(t,0)}catch(e){try{return l.call(null,t,0)}catch(e){return l.call(this,t,0)}}}function i(t){if(f===clearTimeout)return clearTimeout(t);if((f===r||!f)&&clearTimeout)return f=clearTimeout,clearTimeout(t);try{return f(t)}catch(e){try{return f.call(null,t)}catch(e){return f.call(this,t)}}}function a(){v&&h&&(v=!1,h.length?d=h.concat(d):g=-1,d.length&&u())}function u(){if(!v){var t=o(a);v=!0;for(var e=d.length;e;){for(h=d,d=[];++g1)for(var n=1;n=0;r--){var o=t[r];"."===o?t.splice(r,1):".."===o?(t.splice(r,1),n++):n&&(t.splice(r,1),n--)}if(e)for(;n--;n)t.unshift("..");return t}function r(t,e){if(t.filter)return t.filter(e);for(var n=[],r=0;r=-1&&!o;i--){var a=i>=0?arguments[i]:t.cwd();if("string"!=typeof a)throw new TypeError("Arguments to path.resolve must be strings");a&&(e=a+"/"+e,o="/"===a.charAt(0))}return e=n(r(e.split("/"),function(t){return!!t}),!o).join("/"),(o?"/":"")+e||"."},e.normalize=function(t){var o=e.isAbsolute(t),i="/"===a(t,-1);return t=n(r(t.split("/"),function(t){return!!t}),!o).join("/"),t||o||(t="."),t&&i&&(t+="/"),(o?"/":"")+t},e.isAbsolute=function(t){return"/"===t.charAt(0)},e.join=function(){var t=Array.prototype.slice.call(arguments,0);return e.normalize(r(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},e.relative=function(t,n){function r(t){for(var e=0;e=0&&""===t[n];n--);return e>n?[]:t.slice(e,n-e+1)}t=e.resolve(t).substr(1),n=e.resolve(n).substr(1);for(var o=r(t.split("/")),i=r(n.split("/")),a=Math.min(o.length,i.length),u=a,s=0;s","<=","=>","{%","%}","{{{","}}}"],X=Math.floor(1099511627776*Math.random()).toString(16),Q="__MJML__"+X+"__",Z=function t(e){e.children&&e.children&&(0,g.default)(e.children,t),e.content&&(e.content=tt(e.content))},tt=function(t){return Y.reduce(function(t,e,n){return t.replace(new RegExp(e,"g"),""+Q+n)},t)},et=function(t){return Y.reduce(function(t,e,n){return t.replace(new RegExp(""+Q+n,"g"),e)},t)},nt=function(t){return(0,y.default)(t.children,["tagName","mj-body"])},rt=function(t){return(0,y.default)(t.children,["tagName","mj-head"])},ot=function(t){var e=n(463),r=e.minify;return r(t,{collapseWhitespace:!0,removeEmptyAttributes:!0,minifyCSS:!0})},it=function(t){return(0,R.html)(t,{indent_size:2,wrap_attributes_indent_size:2})},at=function(t,e){if(!e||0==e.length)return t;var r=n(464);return r(t,{extraCss:e.join("\n"),removeStyleTags:!1,applyStyleTags:!1,insertPreservedExtraCss:!1})},ut=function(){function t(e){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};o(this,t),(0,z.default)()||(0,p.default)(),this.attributes={container:(0,k.default)(),defaultAttributes:{},cssClasses:{},css:[],inlineCSS:[],fonts:(0,l.default)(O.default)},this.content=e,this.options=(0,x.default)(n,{level:"soft",disableMjStyle:!1,disableMjInclude:!1,disableMinify:!1}),"string"==typeof this.content&&this.parseDocument()}return i(t,[{key:"parseDocument",value:function(){this.options.disableMjInclude||(this.content=(0,I.default)(this.content,this.options)),this.content=(0,b.default)(this.content)}},{key:"validate",value:function(t){if("skip"==this.options.level)return void(this.errors=[]);if(this.errors=(0,L.default)(t),"strict"==this.options.level&&this.errors.length>0)throw new a.MJMLValidationError(this.errors)}},{key:"render",value:function(){var t=this;if(!this.content||!nt(this.content))throw new a.EmptyMJMLError(".render: No MJML to render in options "+this.options.toString());Z(this.content);var e=nt(this.content),n=rt(this.content);n&&n.children.length>0&&(0,g.default)(n.children,function(e){var n=e.tagName,r=V.default[n];r?r(e,t.attributes):(0,J.default)(!1,"No handler found for: "+n+", in mj-head, skipping it")});var r=e.children[0];this.validate(r);var o=q.default[r.tagName];if(!o)return{errors:this.errors};var i=W.default.createElement(o,{mjml:(0,s.parseInstance)(r,this.attributes)}),u=$.default.renderToStaticMarkup(i),c=this.attributes.container.replace("__content__",u||"").replace("__title__",this.attributes.title||"");return{errors:this.errors,html:this.postRender(c)}}},{key:"postRender",value:function(t){var e=this.attributes.inlineCSS,n=T.default.parseHTML(t);return(0,D.default)({$:n,fonts:this.attributes.fonts}),n=(0,u.fixLegacyAttrs)(n),n=(0,u.insertHeadCSS)(n,this.attributes.css),B.postRenders.forEach(function(t){"function"==typeof t&&(n=t(n))}),[this.options.disableMjStyle?void 0:(0,d.default)(at)(e),this.options.beautify?it:void 0,!this.options.disableMinify&&this.options.minify?ot:void 0,A.default.decode,et].filter(function(t){return"function"==typeof t}).reduce(function(t,e){return e(t)},T.default.getHTML(n))}}]),t}();e.default=ut},function(t,e){"use strict";function n(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}function r(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}function o(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}Object.defineProperty(e,"__esModule",{value:!0});var i=function(){function t(t,e){for(var n=0;n'+e.join("")+""),t):t},e.fixLegacyAttrs=function(t){var e=["align","valign","bgcolor","border","background"];return e.forEach(function(e){var n="data-legacy-"+e;t("["+n+"]").each(function(){t(this).attr(e,t(this).attr(n)),t(this).removeAttr(n)})}),t}},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e>>0;if(""+n!==e||4294967295===n)return NaN;e=n}return e<0?d(t)+e:e}function g(){return!0}function m(t,e,n){return(0===t||void 0!==n&&t<=-n)&&(void 0===e||void 0!==n&&e>=n)}function y(t,e){return b(t,e,0)}function _(t,e){return b(t,e,e)}function b(t,e,n){return void 0===t?n:t<0?Math.max(0,e+t):void 0===e?t:Math.min(e,t)}function w(t){this.next=t}function x(t,e,n,r){var o=0===t?e:1===t?n:[e,n];return r?r.value=o:r={value:o,done:!1},r}function E(){return{value:void 0,done:!0}}function k(t){return!!S(t)}function j(t){return t&&"function"==typeof t.next}function O(t){var e=S(t);return e&&e.call(t)}function S(t){var e=t&&(En&&t[En]||t[kn]);if("function"==typeof e)return e}function T(t){return t&&"number"==typeof t.length}function C(t){return null===t||void 0===t?B():i(t)?t.toSeq():V(t)}function A(t){return null===t||void 0===t?B().toKeyedSeq():i(t)?a(t)?t.toSeq():t.fromEntrySeq():q(t)}function N(t){return null===t||void 0===t?B():i(t)?a(t)?t.entrySeq():t.toIndexedSeq():U(t)}function D(t){return(null===t||void 0===t?B():i(t)?a(t)?t.entrySeq():t:U(t)).toSetSeq()}function M(t){this._array=t,this.size=t.length}function I(t){var e=Object.keys(t);this._object=t,this._keys=e,this.size=e.length}function R(t){this._iterable=t,this.size=t.length||t.size}function P(t){this._iterator=t,this._iteratorCache=[]}function L(t){return!(!t||!t[On])}function B(){return Sn||(Sn=new M([]))}function q(t){var e=Array.isArray(t)?new M(t).fromEntrySeq():j(t)?new P(t).fromEntrySeq():k(t)?new R(t).fromEntrySeq():"object"==typeof t?new I(t):void 0;if(!e)throw new TypeError("Expected Array or iterable object of [k, v] entries, or keyed object: "+t);return e}function U(t){var e=F(t);if(!e)throw new TypeError("Expected Array or iterable object of values: "+t);return e}function V(t){var e=F(t)||"object"==typeof t&&new I(t);if(!e)throw new TypeError("Expected Array or iterable object of values, or keyed object: "+t);return e}function F(t){return T(t)?new M(t):j(t)?new P(t):k(t)?new R(t):void 0}function z(t,e,n,r){var o=t._cache;if(o){for(var i=o.length-1,a=0;a<=i;a++){var u=o[n?i-a:a];if(e(u[1],r?u[0]:a,t)===!1)return a+1}return a}return t.__iterateUncached(e,n)}function H(t,e,n,r){var o=t._cache;if(o){var i=o.length-1,a=0;return new w(function(){var t=o[n?i-a:a];return a++>i?E():x(e,r?t[0]:a-1,t[1])})}return t.__iteratorUncached(e,n)}function W(t,e){return e?K(e,t,"",{"":t}):$(t)}function K(t,e,n,r){return Array.isArray(e)?t.call(r,n,N(e).map(function(n,r){return K(t,n,r,e)})):G(e)?t.call(r,n,A(e).map(function(n,r){return K(t,n,r,e)})):e}function $(t){return Array.isArray(t)?N(t).map($).toList():G(t)?A(t).map($).toMap():t}function G(t){return t&&(t.constructor===Object||void 0===t.constructor)}function J(t,e){if(t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1;if("function"==typeof t.valueOf&&"function"==typeof e.valueOf){if(t=t.valueOf(),e=e.valueOf(),t===e||t!==t&&e!==e)return!0;if(!t||!e)return!1}return!("function"!=typeof t.equals||"function"!=typeof e.equals||!t.equals(e))}function Y(t,e){if(t===e)return!0;if(!i(e)||void 0!==t.size&&void 0!==e.size&&t.size!==e.size||void 0!==t.__hash&&void 0!==e.__hash&&t.__hash!==e.__hash||a(t)!==a(e)||u(t)!==u(e)||c(t)!==c(e))return!1;if(0===t.size&&0===e.size)return!0;var n=!s(t);if(c(t)){var r=t.entries();return e.every(function(t,e){var o=r.next().value;return o&&J(o[1],t)&&(n||J(o[0],e))})&&r.next().done}var o=!1;if(void 0===t.size)if(void 0===e.size)"function"==typeof t.cacheResult&&t.cacheResult();else{o=!0;var l=t;t=e,e=l}var f=!0,p=e.__iterate(function(e,r){if(n?!t.has(e):o?!J(e,t.get(r,mn)):!J(t.get(r,mn),e))return f=!1,!1});return f&&t.size===p}function X(t,e){if(!(this instanceof X))return new X(t,e);if(this._value=t,this.size=void 0===e?1/0:Math.max(0,e),0===this.size){if(Tn)return Tn;Tn=this}}function Q(t,e){if(!t)throw new Error(e)}function Z(t,e,n){if(!(this instanceof Z))return new Z(t,e,n);if(Q(0!==n,"Cannot step a Range by 0"),t=t||0,void 0===e&&(e=1/0),n=void 0===n?1:Math.abs(n),e>>1&1073741824|3221225471&t}function it(t){if(t===!1||null===t||void 0===t)return 0;if("function"==typeof t.valueOf&&(t=t.valueOf(),t===!1||null===t||void 0===t))return 0;if(t===!0)return 1;var e=typeof t;if("number"===e){if(t!==t||t===1/0)return 0;var n=0|t;for(n!==t&&(n^=4294967295*t);t>4294967295;)t/=4294967295,n^=t;return ot(n)}if("string"===e)return t.length>Ln?at(t):ut(t);if("function"==typeof t.hashCode)return t.hashCode();if("object"===e)return st(t);if("function"==typeof t.toString)return ut(t.toString());throw new Error("Value type "+e+" cannot be hashed.")}function at(t){var e=Un[t];return void 0===e&&(e=ut(t),qn===Bn&&(qn=0,Un={}),qn++,Un[t]=e),e}function ut(t){for(var e=0,n=0;n0)switch(t.nodeType){case 1:return t.uniqueID;case 9:return t.documentElement&&t.documentElement.uniqueID}}function lt(t){Q(t!==1/0,"Cannot perform this action with an infinite size.")}function ft(t){return null===t||void 0===t?xt():pt(t)&&!c(t)?t:xt().withMutations(function(e){var r=n(t);lt(r.size),r.forEach(function(t,n){return e.set(n,t)})})}function pt(t){return!(!t||!t[Vn])}function ht(t,e){this.ownerID=t,this.entries=e}function dt(t,e,n){this.ownerID=t,this.bitmap=e,this.nodes=n}function vt(t,e,n){this.ownerID=t,this.count=e,this.nodes=n}function gt(t,e,n){this.ownerID=t,this.keyHash=e,this.entries=n}function mt(t,e,n){this.ownerID=t,this.keyHash=e,this.entry=n}function yt(t,e,n){this._type=e,this._reverse=n,this._stack=t._root&&bt(t._root)}function _t(t,e){return x(t,e[0],e[1])}function bt(t,e){return{node:t,index:0,__prev:e}}function wt(t,e,n,r){var o=Object.create(Fn);return o.size=t,o._root=e,o.__ownerID=n,o.__hash=r,o.__altered=!1,o}function xt(){return zn||(zn=wt(0))}function Et(t,e,n){var r,o;if(t._root){var i=l(yn),a=l(_n);if(r=kt(t._root,t.__ownerID,0,void 0,e,n,i,a),!a.value)return t;o=t.size+(i.value?n===mn?-1:1:0)}else{if(n===mn)return t;o=1,r=new ht(t.__ownerID,[[e,n]])}return t.__ownerID?(t.size=o,t._root=r,t.__hash=void 0,t.__altered=!0,t):r?wt(o,r):xt()}function kt(t,e,n,r,o,i,a,u){return t?t.update(e,n,r,o,i,a,u):i===mn?t:(f(u),f(a),new mt(e,r,[o,i]))}function jt(t){return t.constructor===mt||t.constructor===gt}function Ot(t,e,n,r,o){if(t.keyHash===r)return new gt(e,r,[t.entry,o]);var i,a=(0===n?t.keyHash:t.keyHash>>>n)&gn,u=(0===n?r:r>>>n)&gn,s=a===u?[Ot(t,e,n+dn,r,o)]:(i=new mt(e,r,o),a>>=1)a[u]=1&n?e[i++]:void 0;return a[r]=o,new vt(t,i+1,a)}function At(t,e,r){for(var o=[],a=0;a>1&1431655765,t=(858993459&t)+(t>>2&858993459),t=t+(t>>4)&252645135,t+=t>>8,t+=t>>16,127&t}function Pt(t,e,n,r){var o=r?t:h(t);return o[e]=n,o}function Lt(t,e,n,r){var o=t.length+1;if(r&&e+1===o)return t[e]=n,t;for(var i=new Array(o),a=0,u=0;u0&&oi?0:i-n,c=a-n;return c>vn&&(c=vn),function(){if(o===c)return Yn;var t=e?--c:o++;return r&&r[t]}}function o(t,r,o){var u,s=t&&t.array,c=o>i?0:i-o>>r,l=(a-o>>r)+1;return l>vn&&(l=vn),function(){for(;;){if(u){var t=u();if(t!==Yn)return t;u=null}if(c===l)return Yn;var i=e?--l:c++;u=n(s&&s[i],r-dn,o+(i<=t.size||e<0)return t.withMutations(function(t){e<0?Jt(t,e).set(0,n):Jt(t,0,e+1).set(e,n)});e+=t._origin;var r=t._tail,o=t._root,i=l(_n);return e>=Xt(t._capacity)?r=Kt(r,t.__ownerID,0,e,n,i):o=Kt(o,t.__ownerID,t._level,e,n,i),i.value?t.__ownerID?(t._root=o,t._tail=r,t.__hash=void 0,t.__altered=!0,t):zt(t._origin,t._capacity,t._level,o,r):t}function Kt(t,e,n,r,o,i){var a=r>>>n&gn,u=t&&a0){var c=t&&t.array[a],l=Kt(c,e,n-dn,r,o,i);return l===c?t:(s=$t(t,e),s.array[a]=l,s)}return u&&t.array[a]===o?t:(f(i),s=$t(t,e),void 0===o&&a===s.array.length-1?s.array.pop():s.array[a]=o,s)}function $t(t,e){return e&&t&&e===t.ownerID?t:new Vt(t?t.array.slice():[],e)}function Gt(t,e){if(e>=Xt(t._capacity))return t._tail;if(e<1<0;)n=n.array[e>>>r&gn],r-=dn;return n}}function Jt(t,e,n){void 0!==e&&(e|=0),void 0!==n&&(n|=0);var r=t.__ownerID||new p,o=t._origin,i=t._capacity,a=o+e,u=void 0===n?i:n<0?i+n:o+n;if(a===o&&u===i)return t;if(a>=u)return t.clear();for(var s=t._level,c=t._root,l=0;a+l<0;)c=new Vt(c&&c.array.length?[void 0,c]:[],r),s+=dn,l+=1<=1<f?new Vt([],r):d;if(d&&h>f&&adn;m-=dn){var y=f>>>m&gn;g=g.array[y]=$t(g.array[y],r)}g.array[f>>>dn&gn]=d}if(u=h)a-=h,u-=h,s=dn,c=null,v=v&&v.removeBefore(r,0,a);else if(a>o||h>>s&gn;if(_!==h>>>s&gn)break;_&&(l+=(1<o&&(c=c.removeBefore(r,s,a-l)),c&&ha&&(a=c.size),i(s)||(c=c.map(function(t){return W(t)})),o.push(c)}return a>t.size&&(t=t.setSize(a)),Mt(t,e,o)}function Xt(t){return t>>dn<=vn&&a.size>=2*i.size?(o=a.filter(function(t,e){return void 0!==t&&u!==e}),r=o.toKeyedSeq().map(function(t){return t[0]}).flip().toMap(),t.__ownerID&&(r.__ownerID=o.__ownerID=t.__ownerID)):(r=i.remove(e),o=u===a.size-1?a.pop():a.set(u,void 0))}else if(s){if(n===a.get(u)[1])return t;r=i,o=a.set(u,[e,n])}else r=i.set(e,a.size),o=a.set(a.size,[e,n]);return t.__ownerID?(t.size=r.size,t._map=r,t._list=o,t.__hash=void 0,t):te(r,o)}function re(t,e){this._iter=t,this._useKeys=e,this.size=t.size}function oe(t){this._iter=t,this.size=t.size}function ie(t){this._iter=t,this.size=t.size}function ae(t){this._iter=t,this.size=t.size}function ue(t){var e=Te(t);return e._iter=t,e.size=t.size,e.flip=function(){return t},e.reverse=function(){var e=t.reverse.apply(this);return e.flip=function(){return t.reverse()},e},e.has=function(e){return t.includes(e)},e.includes=function(e){return t.has(e)},e.cacheResult=Ce,e.__iterateUncached=function(e,n){var r=this;return t.__iterate(function(t,n){return e(n,t,r)!==!1},n)},e.__iteratorUncached=function(e,n){if(e===xn){var r=t.__iterator(e,n);return new w(function(){var t=r.next();if(!t.done){var e=t.value[0];t.value[0]=t.value[1],t.value[1]=e}return t})}return t.__iterator(e===wn?bn:wn,n)},e}function se(t,e,n){var r=Te(t);return r.size=t.size,r.has=function(e){return t.has(e)},r.get=function(r,o){var i=t.get(r,mn);return i===mn?o:e.call(n,i,r,t)},r.__iterateUncached=function(r,o){var i=this;return t.__iterate(function(t,o,a){return r(e.call(n,t,o,a),o,i)!==!1},o)},r.__iteratorUncached=function(r,o){var i=t.__iterator(xn,o);return new w(function(){var o=i.next();if(o.done)return o;var a=o.value,u=a[0];return x(r,u,e.call(n,a[1],u,t),o)})},r}function ce(t,e){var n=Te(t);return n._iter=t,n.size=t.size,n.reverse=function(){return t},t.flip&&(n.flip=function(){var e=ue(t);return e.reverse=function(){return t.flip()},e}),n.get=function(n,r){return t.get(e?n:-1-n,r)},n.has=function(n){return t.has(e?n:-1-n)},n.includes=function(e){return t.includes(e)},n.cacheResult=Ce,n.__iterate=function(e,n){var r=this;return t.__iterate(function(t,n){return e(t,n,r)},!n)},n.__iterator=function(e,n){return t.__iterator(e,!n)},n}function le(t,e,n,r){var o=Te(t);return r&&(o.has=function(r){var o=t.get(r,mn);return o!==mn&&!!e.call(n,o,r,t)},o.get=function(r,o){var i=t.get(r,mn);return i!==mn&&e.call(n,i,r,t)?i:o}),o.__iterateUncached=function(o,i){var a=this,u=0;return t.__iterate(function(t,i,s){if(e.call(n,t,i,s))return u++,o(t,r?i:u-1,a)},i),u},o.__iteratorUncached=function(o,i){var a=t.__iterator(xn,i),u=0;return new w(function(){for(;;){var i=a.next();if(i.done)return i;var s=i.value,c=s[0],l=s[1];if(e.call(n,l,c,t))return x(o,r?c:u++,l,i)}})},o}function fe(t,e,n){var r=ft().asMutable();return t.__iterate(function(o,i){r.update(e.call(n,o,i,t),0,function(t){return t+1})}),r.asImmutable()}function pe(t,e,n){var r=a(t),o=(c(t)?Qt():ft()).asMutable();t.__iterate(function(i,a){o.update(e.call(n,i,a,t),function(t){return t=t||[],t.push(r?[a,i]:i),t})});var i=Se(t);return o.map(function(e){return ke(t,i(e))})}function he(t,e,n,r){var o=t.size;if(void 0!==e&&(e|=0),void 0!==n&&(n===1/0?n=o:n|=0),m(e,n,o))return t;var i=y(e,o),a=_(n,o);if(i!==i||a!==a)return he(t.toSeq().cacheResult(),e,n,r);var u,s=a-i;s===s&&(u=s<0?0:s);var c=Te(t);return c.size=0===u?u:t.size&&u||void 0,!r&&L(t)&&u>=0&&(c.get=function(e,n){return e=v(this,e),e>=0&&eu)return E();var t=o.next();return r||e===wn?t:e===bn?x(e,s-1,void 0,t):x(e,s-1,t.value[1],t)})},c}function de(t,e,n){var r=Te(t);return r.__iterateUncached=function(r,o){var i=this;if(o)return this.cacheResult().__iterate(r,o);var a=0;return t.__iterate(function(t,o,u){return e.call(n,t,o,u)&&++a&&r(t,o,i)}),a},r.__iteratorUncached=function(r,o){var i=this;if(o)return this.cacheResult().__iterator(r,o);var a=t.__iterator(xn,o),u=!0;return new w(function(){if(!u)return E();var t=a.next();if(t.done)return t;var o=t.value,s=o[0],c=o[1];return e.call(n,c,s,i)?r===xn?t:x(r,s,c,t):(u=!1,E())})},r}function ve(t,e,n,r){var o=Te(t);return o.__iterateUncached=function(o,i){var a=this;if(i)return this.cacheResult().__iterate(o,i);var u=!0,s=0;return t.__iterate(function(t,i,c){if(!u||!(u=e.call(n,t,i,c)))return s++,o(t,r?i:s-1,a)}),s},o.__iteratorUncached=function(o,i){var a=this;if(i)return this.cacheResult().__iterator(o,i);var u=t.__iterator(xn,i),s=!0,c=0;return new w(function(){var t,i,l;do{if(t=u.next(),t.done)return r||o===wn?t:o===bn?x(o,c++,void 0,t):x(o,c++,t.value[1],t);var f=t.value;i=f[0],l=f[1],s&&(s=e.call(n,l,i,a))}while(s);return o===xn?t:x(o,i,l,t)})},o}function ge(t,e){var r=a(t),o=[t].concat(e).map(function(t){return i(t)?r&&(t=n(t)):t=r?q(t):U(Array.isArray(t)?t:[t]),t}).filter(function(t){return 0!==t.size});if(0===o.length)return t;if(1===o.length){var s=o[0];if(s===t||r&&a(s)||u(t)&&u(s))return s}var c=new M(o);return r?c=c.toKeyedSeq():u(t)||(c=c.toSetSeq()),c=c.flatten(!0),c.size=o.reduce(function(t,e){if(void 0!==t){var n=e.size;if(void 0!==n)return t+n}},0),c}function me(t,e,n){var r=Te(t);return r.__iterateUncached=function(r,o){function a(t,c){var l=this;t.__iterate(function(t,o){return(!e||c0}function Ee(t,n,r){var o=Te(t);return o.size=new M(r).map(function(t){return t.size}).min(),o.__iterate=function(t,e){for(var n,r=this.__iterator(wn,e),o=0;!(n=r.next()).done&&t(n.value,o++,this)!==!1;);return o},o.__iteratorUncached=function(t,o){var i=r.map(function(t){return t=e(t),O(o?t.reverse():t)}),a=0,u=!1;return new w(function(){var e;return u||(e=i.map(function(t){return t.next()}),u=e.some(function(t){return t.done})),u?E():x(t,a++,n.apply(null,e.map(function(t){return t.value})))})},o}function ke(t,e){return L(t)?e:t.constructor(e)}function je(t){if(t!==Object(t))throw new TypeError("Expected [K, V] tuple: "+t)}function Oe(t){return lt(t.size),d(t)}function Se(t){return a(t)?n:u(t)?r:o}function Te(t){return Object.create((a(t)?A:u(t)?N:D).prototype)}function Ce(){return this._iter.cacheResult?(this._iter.cacheResult(),this.size=this._iter.size,this):C.prototype.cacheResult.call(this)}function Ae(t,e){return t>e?1:te?-1:0}function on(t){if(t.size===1/0)return 0;var e=c(t),n=a(t),r=e?1:0,o=t.__iterate(n?e?function(t,e){r=31*r+un(it(t),it(e))|0}:function(t,e){r=r+un(it(t),it(e))|0}:e?function(t){r=31*r+it(t)|0}:function(t){r=r+it(t)|0});return an(o,r)}function an(t,e){return e=Nn(e,3432918353),e=Nn(e<<15|e>>>-15,461845907),e=Nn(e<<13|e>>>-13,5),e=(e+3864292196|0)^t,e=Nn(e^e>>>16,2246822507),e=Nn(e^e>>>13,3266489909),e=ot(e^e>>>16)}function un(t,e){return t^e+2654435769+(t<<6)+(t>>2)|0}var sn=Array.prototype.slice;t(n,e),t(r,e),t(o,e),e.isIterable=i,e.isKeyed=a,e.isIndexed=u,e.isAssociative=s,e.isOrdered=c,e.Keyed=n,e.Indexed=r,e.Set=o;var cn="@@__IMMUTABLE_ITERABLE__@@",ln="@@__IMMUTABLE_KEYED__@@",fn="@@__IMMUTABLE_INDEXED__@@",pn="@@__IMMUTABLE_ORDERED__@@",hn="delete",dn=5,vn=1<r?E():x(t,o,n[e?r-o++:o++])})},t(I,A),I.prototype.get=function(t,e){return void 0===e||this.has(t)?this._object[t]:e},I.prototype.has=function(t){return this._object.hasOwnProperty(t)},I.prototype.__iterate=function(t,e){for(var n=this._object,r=this._keys,o=r.length-1,i=0;i<=o;i++){var a=r[e?o-i:i];if(t(n[a],a,this)===!1)return i+1}return i},I.prototype.__iterator=function(t,e){var n=this._object,r=this._keys,o=r.length-1,i=0;return new w(function(){var a=r[e?o-i:i];return i++>o?E():x(t,a,n[a])})},I.prototype[pn]=!0,t(R,N),R.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);var n=this._iterable,r=O(n),o=0;if(j(r))for(var i;!(i=r.next()).done&&t(i.value,o++,this)!==!1;);return o},R.prototype.__iteratorUncached=function(t,e){if(e)return this.cacheResult().__iterator(t,e);var n=this._iterable,r=O(n);if(!j(r))return new w(E);var o=0;return new w(function(){var e=r.next();return e.done?e:x(t,o++,e.value)})},t(P,N),P.prototype.__iterateUncached=function(t,e){if(e)return this.cacheResult().__iterate(t,e);for(var n=this._iterator,r=this._iteratorCache,o=0;o=r.length){var e=n.next();if(e.done)return e;r[o]=e.value}return x(t,o,r[o++])})};var Sn;t(X,N),X.prototype.toString=function(){return 0===this.size?"Repeat []":"Repeat [ "+this._value+" "+this.size+" times ]"},X.prototype.get=function(t,e){return this.has(t)?this._value:e},X.prototype.includes=function(t){return J(this._value,t)},X.prototype.slice=function(t,e){var n=this.size;return m(t,e,n)?this:new X(this._value,_(e,n)-y(t,n))},X.prototype.reverse=function(){return this},X.prototype.indexOf=function(t){return J(this._value,t)?0:-1},X.prototype.lastIndexOf=function(t){return J(this._value,t)?this.size:-1},X.prototype.__iterate=function(t,e){for(var n=0;n=0&&e=0&&nn?E():x(t,i++,a)})},Z.prototype.equals=function(t){return t instanceof Z?this._start===t._start&&this._end===t._end&&this._step===t._step:Y(this,t)};var Cn;t(tt,e),t(et,tt),t(nt,tt),t(rt,tt),tt.Keyed=et,tt.Indexed=nt,tt.Set=rt;var An,Nn="function"==typeof Math.imul&&Math.imul(4294967295,2)===-2?Math.imul:function(t,e){t|=0,e|=0;var n=65535&t,r=65535&e;return n*r+((t>>>16)*r+n*(e>>>16)<<16>>>0)|0},Dn=Object.isExtensible,Mn=function(){try{return Object.defineProperty({},"@",{}),!0}catch(t){return!1}}(),In="function"==typeof WeakMap;In&&(An=new WeakMap);var Rn=0,Pn="__immutablehash__";"function"==typeof Symbol&&(Pn=Symbol(Pn));var Ln=16,Bn=255,qn=0,Un={};t(ft,et),ft.of=function(){var t=sn.call(arguments,0);return xt().withMutations(function(e){for(var n=0;n=t.length)throw new Error("Missing value for key: "+t[n]);e.set(t[n],t[n+1])}})},ft.prototype.toString=function(){return this.__toString("Map {","}")},ft.prototype.get=function(t,e){return this._root?this._root.get(0,void 0,t,e):e},ft.prototype.set=function(t,e){return Et(this,t,e)},ft.prototype.setIn=function(t,e){return this.updateIn(t,mn,function(){return e})},ft.prototype.remove=function(t){return Et(this,t,mn)},ft.prototype.deleteIn=function(t){return this.updateIn(t,function(){return mn})},ft.prototype.update=function(t,e,n){return 1===arguments.length?t(this):this.updateIn([t],e,n)},ft.prototype.updateIn=function(t,e,n){n||(n=e,e=void 0);var r=It(this,Ne(t),e,n);return r===mn?void 0:r},ft.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._root=null,this.__hash=void 0,this.__altered=!0,this):xt()},ft.prototype.merge=function(){return At(this,void 0,arguments)},ft.prototype.mergeWith=function(t){var e=sn.call(arguments,1);return At(this,t,e)},ft.prototype.mergeIn=function(t){var e=sn.call(arguments,1);return this.updateIn(t,xt(),function(t){return"function"==typeof t.merge?t.merge.apply(t,e):e[e.length-1]})},ft.prototype.mergeDeep=function(){return At(this,Nt,arguments)},ft.prototype.mergeDeepWith=function(t){var e=sn.call(arguments,1);return At(this,Dt(t),e)},ft.prototype.mergeDeepIn=function(t){var e=sn.call(arguments,1); -return this.updateIn(t,xt(),function(t){return"function"==typeof t.mergeDeep?t.mergeDeep.apply(t,e):e[e.length-1]})},ft.prototype.sort=function(t){return Qt(be(this,t))},ft.prototype.sortBy=function(t,e){return Qt(be(this,e,t))},ft.prototype.withMutations=function(t){var e=this.asMutable();return t(e),e.wasAltered()?e.__ensureOwner(this.__ownerID):this},ft.prototype.asMutable=function(){return this.__ownerID?this:this.__ensureOwner(new p)},ft.prototype.asImmutable=function(){return this.__ensureOwner()},ft.prototype.wasAltered=function(){return this.__altered},ft.prototype.__iterator=function(t,e){return new yt(this,t,e)},ft.prototype.__iterate=function(t,e){var n=this,r=0;return this._root&&this._root.iterate(function(e){return r++,t(e[1],e[0],n)},e),r},ft.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?wt(this.size,this._root,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},ft.isMap=pt;var Vn="@@__IMMUTABLE_MAP__@@",Fn=ft.prototype;Fn[Vn]=!0,Fn[hn]=Fn.remove,Fn.removeIn=Fn.deleteIn,ht.prototype.get=function(t,e,n,r){for(var o=this.entries,i=0,a=o.length;i=Hn)return St(t,s,r,o);var d=t&&t===this.ownerID,v=d?s:h(s);return p?u?c===l-1?v.pop():v[c]=v.pop():v[c]=[r,o]:v.push([r,o]),d?(this.entries=v,this):new ht(t,v)}},dt.prototype.get=function(t,e,n,r){void 0===e&&(e=it(n));var o=1<<((0===t?e:e>>>t)&gn),i=this.bitmap;return 0===(i&o)?r:this.nodes[Rt(i&o-1)].get(t+dn,e,n,r)},dt.prototype.update=function(t,e,n,r,o,i,a){void 0===n&&(n=it(r));var u=(0===e?n:n>>>e)&gn,s=1<=Wn)return Ct(t,p,c,u,d);if(l&&!d&&2===p.length&&jt(p[1^f]))return p[1^f];if(l&&d&&1===p.length&&jt(d))return d;var v=t&&t===this.ownerID,g=l?d?c:c^s:c|s,m=l?d?Pt(p,f,d,v):Bt(p,f,v):Lt(p,f,d,v);return v?(this.bitmap=g,this.nodes=m,this):new dt(t,g,m)},vt.prototype.get=function(t,e,n,r){void 0===e&&(e=it(n));var o=(0===t?e:e>>>t)&gn,i=this.nodes[o];return i?i.get(t+dn,e,n,r):r},vt.prototype.update=function(t,e,n,r,o,i,a){void 0===n&&(n=it(r));var u=(0===e?n:n>>>e)&gn,s=o===mn,c=this.nodes,l=c[u];if(s&&!l)return this;var f=kt(l,t,e+dn,n,r,o,i,a);if(f===l)return this;var p=this.count;if(l){if(!f&&(p--,p=0&&t>>e&gn;if(r>=this.array.length)return new Vt([],t);var o,i=0===r;if(e>0){var a=this.array[r];if(o=a&&a.removeBefore(t,e-dn,n),o===a&&i)return this}if(i&&!o)return this;var u=$t(this,t);if(!i)for(var s=0;s>>e&gn;if(r>=this.array.length)return this;var o;if(e>0){var i=this.array[r];if(o=i&&i.removeAfter(t,e-dn,n),o===i&&r===this.array.length-1)return this}var a=$t(this,t);return a.array.splice(r+1),o&&(a.array[r]=o),a};var Jn,Yn={};t(Qt,ft),Qt.of=function(){return this(arguments)},Qt.prototype.toString=function(){return this.__toString("OrderedMap {","}")},Qt.prototype.get=function(t,e){var n=this._map.get(t);return void 0!==n?this._list.get(n)[1]:e},Qt.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._map.clear(),this._list.clear(),this):ee()},Qt.prototype.set=function(t,e){return ne(this,t,e)},Qt.prototype.remove=function(t){return ne(this,t,mn)},Qt.prototype.wasAltered=function(){return this._map.wasAltered()||this._list.wasAltered()},Qt.prototype.__iterate=function(t,e){var n=this;return this._list.__iterate(function(e){return e&&t(e[1],e[0],n)},e)},Qt.prototype.__iterator=function(t,e){return this._list.fromEntrySeq().__iterator(t,e)},Qt.prototype.__ensureOwner=function(t){if(t===this.__ownerID)return this;var e=this._map.__ensureOwner(t),n=this._list.__ensureOwner(t);return t?te(e,n,t,this.__hash):(this.__ownerID=t,this._map=e,this._list=n,this)},Qt.isOrderedMap=Zt,Qt.prototype[pn]=!0,Qt.prototype[hn]=Qt.prototype.remove;var Xn;t(re,A),re.prototype.get=function(t,e){return this._iter.get(t,e)},re.prototype.has=function(t){return this._iter.has(t)},re.prototype.valueSeq=function(){return this._iter.valueSeq()},re.prototype.reverse=function(){var t=this,e=ce(this,!0);return this._useKeys||(e.valueSeq=function(){return t._iter.toSeq().reverse()}),e},re.prototype.map=function(t,e){var n=this,r=se(this,t,e);return this._useKeys||(r.valueSeq=function(){return n._iter.toSeq().map(t,e)}),r},re.prototype.__iterate=function(t,e){var n,r=this;return this._iter.__iterate(this._useKeys?function(e,n){return t(e,n,r)}:(n=e?Oe(this):0,function(o){return t(o,e?--n:n++,r)}),e)},re.prototype.__iterator=function(t,e){if(this._useKeys)return this._iter.__iterator(t,e);var n=this._iter.__iterator(wn,e),r=e?Oe(this):0;return new w(function(){var o=n.next();return o.done?o:x(t,e?--r:r++,o.value,o)})},re.prototype[pn]=!0,t(oe,N),oe.prototype.includes=function(t){return this._iter.includes(t)},oe.prototype.__iterate=function(t,e){var n=this,r=0;return this._iter.__iterate(function(e){return t(e,r++,n)},e)},oe.prototype.__iterator=function(t,e){var n=this._iter.__iterator(wn,e),r=0;return new w(function(){var e=n.next();return e.done?e:x(t,r++,e.value,e)})},t(ie,D),ie.prototype.has=function(t){return this._iter.includes(t)},ie.prototype.__iterate=function(t,e){var n=this;return this._iter.__iterate(function(e){return t(e,e,n)},e)},ie.prototype.__iterator=function(t,e){var n=this._iter.__iterator(wn,e);return new w(function(){var e=n.next();return e.done?e:x(t,e.value,e.value,e)})},t(ae,A),ae.prototype.entrySeq=function(){return this._iter.toSeq()},ae.prototype.__iterate=function(t,e){var n=this;return this._iter.__iterate(function(e){if(e){je(e);var r=i(e);return t(r?e.get(1):e[1],r?e.get(0):e[0],n)}},e)},ae.prototype.__iterator=function(t,e){var n=this._iter.__iterator(wn,e);return new w(function(){for(;;){var e=n.next();if(e.done)return e;var r=e.value;if(r){je(r);var o=i(r);return x(t,o?r.get(0):r[0],o?r.get(1):r[1],e)}}})},oe.prototype.cacheResult=re.prototype.cacheResult=ie.prototype.cacheResult=ae.prototype.cacheResult=Ce,t(De,et),De.prototype.toString=function(){return this.__toString(Ie(this)+" {","}")},De.prototype.has=function(t){return this._defaultValues.hasOwnProperty(t)},De.prototype.get=function(t,e){if(!this.has(t))return e;var n=this._defaultValues[t];return this._map?this._map.get(t,n):n},De.prototype.clear=function(){if(this.__ownerID)return this._map&&this._map.clear(),this;var t=this.constructor;return t._empty||(t._empty=Me(this,xt()))},De.prototype.set=function(t,e){if(!this.has(t))throw new Error('Cannot set unknown key "'+t+'" on '+Ie(this));if(this._map&&!this._map.has(t)){var n=this._defaultValues[t];if(e===n)return this}var r=this._map&&this._map.set(t,e);return this.__ownerID||r===this._map?this:Me(this,r)},De.prototype.remove=function(t){if(!this.has(t))return this;var e=this._map&&this._map.remove(t);return this.__ownerID||e===this._map?this:Me(this,e)},De.prototype.wasAltered=function(){return this._map.wasAltered()},De.prototype.__iterator=function(t,e){var r=this;return n(this._defaultValues).map(function(t,e){return r.get(e)}).__iterator(t,e)},De.prototype.__iterate=function(t,e){var r=this;return n(this._defaultValues).map(function(t,e){return r.get(e)}).__iterate(t,e)},De.prototype.__ensureOwner=function(t){if(t===this.__ownerID)return this;var e=this._map&&this._map.__ensureOwner(t);return t?Me(this,e,t):(this.__ownerID=t,this._map=e,this)};var Qn=De.prototype;Qn[hn]=Qn.remove,Qn.deleteIn=Qn.removeIn=Fn.removeIn,Qn.merge=Fn.merge,Qn.mergeWith=Fn.mergeWith,Qn.mergeIn=Fn.mergeIn,Qn.mergeDeep=Fn.mergeDeep,Qn.mergeDeepWith=Fn.mergeDeepWith,Qn.mergeDeepIn=Fn.mergeDeepIn,Qn.setIn=Fn.setIn,Qn.update=Fn.update,Qn.updateIn=Fn.updateIn,Qn.withMutations=Fn.withMutations,Qn.asMutable=Fn.asMutable,Qn.asImmutable=Fn.asImmutable,t(Le,rt),Le.of=function(){return this(arguments)},Le.fromKeys=function(t){return this(n(t).keySeq())},Le.prototype.toString=function(){return this.__toString("Set {","}")},Le.prototype.has=function(t){return this._map.has(t)},Le.prototype.add=function(t){return qe(this,this._map.set(t,!0))},Le.prototype.remove=function(t){return qe(this,this._map.remove(t))},Le.prototype.clear=function(){return qe(this,this._map.clear())},Le.prototype.union=function(){var t=sn.call(arguments,0);return t=t.filter(function(t){return 0!==t.size}),0===t.length?this:0!==this.size||this.__ownerID||1!==t.length?this.withMutations(function(e){for(var n=0;n=0;n--)e={value:arguments[n],next:e};return this.__ownerID?(this.size=t,this._head=e,this.__hash=void 0,this.__altered=!0,this):Ge(t,e)},Ke.prototype.pushAll=function(t){if(t=r(t),0===t.size)return this;lt(t.size);var e=this.size,n=this._head;return t.reverse().forEach(function(t){e++,n={value:t,next:n}}),this.__ownerID?(this.size=e,this._head=n,this.__hash=void 0,this.__altered=!0,this):Ge(e,n)},Ke.prototype.pop=function(){return this.slice(1)},Ke.prototype.unshift=function(){return this.push.apply(this,arguments)},Ke.prototype.unshiftAll=function(t){return this.pushAll(t)},Ke.prototype.shift=function(){return this.pop.apply(this,arguments)},Ke.prototype.clear=function(){return 0===this.size?this:this.__ownerID?(this.size=0,this._head=void 0,this.__hash=void 0,this.__altered=!0,this):Je()},Ke.prototype.slice=function(t,e){if(m(t,e,this.size))return this;var n=y(t,this.size),r=_(e,this.size);if(r!==this.size)return nt.prototype.slice.call(this,t,e);for(var o=this.size-n,i=this._head;n--;)i=i.next;return this.__ownerID?(this.size=o,this._head=i,this.__hash=void 0,this.__altered=!0,this):Ge(o,i)},Ke.prototype.__ensureOwner=function(t){return t===this.__ownerID?this:t?Ge(this.size,this._head,t,this.__hash):(this.__ownerID=t,this.__altered=!1,this)},Ke.prototype.__iterate=function(t,e){if(e)return this.reverse().__iterate(t);for(var n=0,r=this._head;r&&t(r.value,n++,this)!==!1;)r=r.next;return n},Ke.prototype.__iterator=function(t,e){if(e)return this.reverse().__iterator(t);var n=0,r=this._head;return new w(function(){if(r){var e=r.value;return r=r.next,x(t,n++,e)}return E()})},Ke.isStack=$e;var or="@@__IMMUTABLE_STACK__@@",ir=Ke.prototype;ir[or]=!0,ir.withMutations=Fn.withMutations,ir.asMutable=Fn.asMutable,ir.asImmutable=Fn.asImmutable,ir.wasAltered=Fn.wasAltered;var ar;e.Iterator=w,Ye(e,{toArray:function(){lt(this.size);var t=new Array(this.size||0);return this.valueSeq().__iterate(function(e,n){t[n]=e}),t},toIndexedSeq:function(){return new oe(this)},toJS:function(){return this.toSeq().map(function(t){return t&&"function"==typeof t.toJS?t.toJS():t}).__toJS()},toJSON:function(){return this.toSeq().map(function(t){return t&&"function"==typeof t.toJSON?t.toJSON():t}).__toJS()},toKeyedSeq:function(){return new re(this,!0)},toMap:function(){return ft(this.toKeyedSeq())},toObject:function(){lt(this.size);var t={};return this.__iterate(function(e,n){t[n]=e}),t},toOrderedMap:function(){return Qt(this.toKeyedSeq())},toOrderedSet:function(){return Fe(a(this)?this.valueSeq():this)},toSet:function(){return Le(a(this)?this.valueSeq():this)},toSetSeq:function(){return new ie(this)},toSeq:function(){return u(this)?this.toIndexedSeq():a(this)?this.toKeyedSeq():this.toSetSeq()},toStack:function(){return Ke(a(this)?this.valueSeq():this)},toList:function(){return qt(a(this)?this.valueSeq():this)},toString:function(){return"[Iterable]"},__toString:function(t,e){return 0===this.size?t+e:t+" "+this.toSeq().map(this.__toStringMapper).join(", ")+" "+e},concat:function(){var t=sn.call(arguments,0);return ke(this,ge(this,t))},includes:function(t){return this.some(function(e){return J(e,t)})},entries:function(){return this.__iterator(xn)},every:function(t,e){lt(this.size);var n=!0;return this.__iterate(function(r,o,i){if(!t.call(e,r,o,i))return n=!1,!1}),n},filter:function(t,e){return ke(this,le(this,t,e,!0))},find:function(t,e,n){var r=this.findEntry(t,e);return r?r[1]:n},forEach:function(t,e){return lt(this.size),this.__iterate(e?t.bind(e):t)},join:function(t){lt(this.size),t=void 0!==t?""+t:",";var e="",n=!0;return this.__iterate(function(r){n?n=!1:e+=t,e+=null!==r&&void 0!==r?r.toString():""}),e},keys:function(){return this.__iterator(bn)},map:function(t,e){return ke(this,se(this,t,e))},reduce:function(t,e,n){lt(this.size);var r,o;return arguments.length<2?o=!0:r=e,this.__iterate(function(e,i,a){o?(o=!1,r=e):r=t.call(n,r,e,i,a)}),r},reduceRight:function(t,e,n){var r=this.toKeyedSeq().reverse();return r.reduce.apply(r,arguments)},reverse:function(){return ke(this,ce(this,!0))},slice:function(t,e){return ke(this,he(this,t,e,!0))},some:function(t,e){return!this.every(Ze(t),e)},sort:function(t){return ke(this,be(this,t))},values:function(){return this.__iterator(wn)},butLast:function(){return this.slice(0,-1)},isEmpty:function(){return void 0!==this.size?0===this.size:!this.some(function(){return!0})},count:function(t,e){return d(t?this.toSeq().filter(t,e):this)},countBy:function(t,e){return fe(this,t,e)},equals:function(t){return Y(this,t)},entrySeq:function(){var t=this;if(t._cache)return new M(t._cache);var e=t.toSeq().map(Qe).toIndexedSeq();return e.fromEntrySeq=function(){return t.toSeq()},e},filterNot:function(t,e){return this.filter(Ze(t),e)},findEntry:function(t,e,n){var r=n;return this.__iterate(function(n,o,i){if(t.call(e,n,o,i))return r=[o,n],!1}),r},findKey:function(t,e){var n=this.findEntry(t,e);return n&&n[0]},findLast:function(t,e,n){return this.toKeyedSeq().reverse().find(t,e,n)},findLastEntry:function(t,e,n){return this.toKeyedSeq().reverse().findEntry(t,e,n)},findLastKey:function(t,e){return this.toKeyedSeq().reverse().findKey(t,e)},first:function(){return this.find(g)},flatMap:function(t,e){return ke(this,ye(this,t,e))},flatten:function(t){return ke(this,me(this,t,!0))},fromEntrySeq:function(){return new ae(this)},get:function(t,e){return this.find(function(e,n){return J(n,t)},void 0,e)},getIn:function(t,e){for(var n,r=this,o=Ne(t);!(n=o.next()).done;){var i=n.value;if(r=r&&r.get?r.get(i,mn):mn,r===mn)return e}return r},groupBy:function(t,e){return pe(this,t,e)},has:function(t){return this.get(t,mn)!==mn},hasIn:function(t){return this.getIn(t,mn)!==mn},isSubset:function(t){return t="function"==typeof t.includes?t:e(t),this.every(function(e){return t.includes(e)})},isSuperset:function(t){return t="function"==typeof t.isSubset?t:e(t),t.isSubset(this)},keyOf:function(t){return this.findKey(function(e){return J(e,t)})},keySeq:function(){return this.toSeq().map(Xe).toIndexedSeq()},last:function(){return this.toSeq().reverse().first()},lastKeyOf:function(t){return this.toKeyedSeq().reverse().keyOf(t)},max:function(t){return we(this,t)},maxBy:function(t,e){return we(this,e,t)},min:function(t){return we(this,t?tn(t):rn)},minBy:function(t,e){return we(this,e?tn(e):rn,t)},rest:function(){return this.slice(1)},skip:function(t){return this.slice(Math.max(0,t))},skipLast:function(t){return ke(this,this.toSeq().reverse().skip(t).reverse())},skipWhile:function(t,e){return ke(this,ve(this,t,e,!0))},skipUntil:function(t,e){return this.skipWhile(Ze(t),e)},sortBy:function(t,e){return ke(this,be(this,e,t))},take:function(t){return this.slice(0,Math.max(0,t))},takeLast:function(t){return ke(this,this.toSeq().reverse().take(t).reverse())},takeWhile:function(t,e){return ke(this,de(this,t,e))},takeUntil:function(t,e){return this.takeWhile(Ze(t),e)},valueSeq:function(){return this.toIndexedSeq()},hashCode:function(){return this.__hash||(this.__hash=on(this))}});var ur=e.prototype;ur[cn]=!0,ur[jn]=ur.values,ur.__toJS=ur.toArray,ur.__toStringMapper=en,ur.inspect=ur.toSource=function(){return this.toString()},ur.chain=ur.flatMap,ur.contains=ur.includes,Ye(n,{flip:function(){return ke(this,ue(this))},mapEntries:function(t,e){var n=this,r=0;return ke(this,this.toSeq().map(function(o,i){return t.call(e,[i,o],r++,n)}).fromEntrySeq())},mapKeys:function(t,e){var n=this;return ke(this,this.toSeq().flip().map(function(r,o){return t.call(e,r,o,n)}).flip())}});var sr=n.prototype;sr[ln]=!0,sr[jn]=ur.entries,sr.__toJS=ur.toObject,sr.__toStringMapper=function(t,e){return JSON.stringify(e)+": "+en(t)},Ye(r,{toKeyedSeq:function(){return new re(this,!1)},filter:function(t,e){return ke(this,le(this,t,e,!1))},findIndex:function(t,e){var n=this.findEntry(t,e);return n?n[0]:-1},indexOf:function(t){var e=this.keyOf(t);return void 0===e?-1:e},lastIndexOf:function(t){var e=this.lastKeyOf(t);return void 0===e?-1:e},reverse:function(){return ke(this,ce(this,!1))},slice:function(t,e){return ke(this,he(this,t,e,!1))},splice:function(t,e){var n=arguments.length;if(e=Math.max(0|e,0),0===n||2===n&&!e)return this;t=y(t,t<0?this.count():this.size);var r=this.slice(0,t);return ke(this,1===n?r:r.concat(h(arguments,2),this.slice(t+e)))},findLastIndex:function(t,e){var n=this.findLastEntry(t,e);return n?n[0]:-1},first:function(){return this.get(0)},flatten:function(t){return ke(this,me(this,t,!1))},get:function(t,e){return t=v(this,t),t<0||this.size===1/0||void 0!==this.size&&t>this.size?e:this.find(function(e,n){return n===t},void 0,e)},has:function(t){return t=v(this,t),t>=0&&(void 0!==this.size?this.size===1/0||t0){if(++e>=r)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var r=800,o=16,i=Date.now;t.exports=n},function(t,e,n){function r(t,e,n,a,u,s){return i(t)&&i(e)&&(s.set(e,t),o(t,e,void 0,r,s),s.delete(e)),t}var o=n(39),i=n(32);t.exports=r},function(t,e,n){function r(t,e,n,l,f){t!==e&&a(e,function(a,c){if(s(a))f||(f=new o),u(t,e,c,n,r,l,f);else{var p=l?l(t[c],a,c+"",t,e,f):void 0;void 0===p&&(p=a),i(t,c,p)}},c)}var o=n(40),i=n(70),a=n(72),u=n(74),s=n(32),c=n(103);t.exports=r},function(t,e,n){function r(t){var e=this.__data__=new o(t);this.size=e.size}var o=n(41),i=n(49),a=n(50),u=n(51),s=n(52),c=n(53);r.prototype.clear=i,r.prototype.delete=a,r.prototype.get=u,r.prototype.has=s,r.prototype.set=c,t.exports=r},function(t,e,n){function r(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e-1}var o=n(44);t.exports=r},function(t,e,n){function r(t,e){var n=this.__data__,r=o(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}var o=n(44);t.exports=r},function(t,e,n){function r(){this.__data__=new o,this.size=0}var o=n(41);t.exports=r},function(t,e){function n(t){var e=this.__data__,n=e.delete(t);return this.size=e.size,n}t.exports=n},function(t,e){function n(t){return this.__data__.get(t)}t.exports=n},function(t,e){function n(t){return this.__data__.has(t)}t.exports=n},function(t,e,n){function r(t,e){var n=this.__data__;if(n instanceof o){var r=n.__data__;if(!i||r.length-1&&t%1==0&&t<=r}var r=9007199254740991;t.exports=n},function(t,e,n){(function(t){var r=n(28),o=n(94),i="object"==typeof e&&e&&!e.nodeType&&e,a=i&&"object"==typeof t&&t&&!t.nodeType&&t,u=a&&a.exports===i,s=u?r.Buffer:void 0,c=s?s.isBuffer:void 0,l=c||o;t.exports=l}).call(e,n(76)(t))},function(t,e){function n(){return!1}t.exports=n},function(t,e,n){function r(t){if(!a(t)||o(t)!=u)return!1;var e=i(t);if(null===e)return!0;var n=f.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&l.call(n)==p}var o=n(26),i=n(83),a=n(88),u="[object Object]",s=Function.prototype,c=Object.prototype,l=s.toString,f=c.hasOwnProperty,p=l.call(Object);t.exports=r},function(t,e,n){var r=n(97),o=n(98),i=n(99),a=i&&i.isTypedArray,u=a?o(a):r;t.exports=u},function(t,e,n){function r(t){return a(t)&&i(t.length)&&!!N[o(t)]}var o=n(26),i=n(92),a=n(88),u="[object Arguments]",s="[object Array]",c="[object Boolean]",l="[object Date]",f="[object Error]",p="[object Function]",h="[object Map]",d="[object Number]",v="[object Object]",g="[object RegExp]",m="[object Set]",y="[object String]",_="[object WeakMap]",b="[object ArrayBuffer]",w="[object DataView]",x="[object Float32Array]",E="[object Float64Array]",k="[object Int8Array]",j="[object Int16Array]",O="[object Int32Array]",S="[object Uint8Array]",T="[object Uint8ClampedArray]",C="[object Uint16Array]",A="[object Uint32Array]",N={};N[x]=N[E]=N[k]=N[j]=N[O]=N[S]=N[T]=N[C]=N[A]=!0,N[u]=N[s]=N[b]=N[c]=N[w]=N[l]=N[f]=N[p]=N[h]=N[d]=N[v]=N[g]=N[m]=N[y]=N[_]=!1,t.exports=r},function(t,e){function n(t){return function(e){return t(e)}}t.exports=n},function(t,e,n){(function(t){var r=n(29),o="object"==typeof e&&e&&!e.nodeType&&e,i=o&&"object"==typeof t&&t&&!t.nodeType&&t,a=i&&i.exports===o,u=a&&r.process,s=function(){try{return u&&u.binding&&u.binding("util")}catch(t){}}();t.exports=s}).call(e,n(76)(t))},function(t,e,n){function r(t){return o(t,i(t))}var o=n(101),i=n(103);t.exports=r},function(t,e,n){function r(t,e,n,r){var a=!n;n||(n={});for(var u=-1,s=e.length;++u-1&&t%1==0&&t1?n[o-1]:void 0,u=o>2?n[2]:void 0;for(a=t.length>3&&"function"==typeof a?(o--,a):void 0,u&&i(n[0],n[1],u)&&(a=o<3?void 0:a,o=1),e=Object(e);++r2?r-2:0);for(var o=2;o-1}function d(t,e,n){for(var r=-1,o=null==t?0:t.length;++r-1;);return n}function q(t,e){for(var n=t.length;n--&&k(e,t[n],0)>-1;);return n}function U(t,e){for(var n=t.length,r=0;n--;)t[n]===e&&++r;return r}function V(t){return"\\"+nr[t]}function F(t,e){return null==t?ot:t[e]}function z(t){return $n.test(t)}function H(t){return Gn.test(t)}function W(t){for(var e,n=[];!(e=t.next()).done;)n.push(e.value);return n}function K(t){var e=-1,n=Array(t.size);return t.forEach(function(t,r){n[++e]=[r,t]}),n}function $(t,e){return function(n){return t(e(n))}}function G(t,e){for(var n=-1,r=t.length,o=0,i=[];++n>>1,Vt=[["ary",kt],["bind",mt],["bindKey",yt],["curry",bt],["curryRight",wt],["flip",Ot],["partial",xt],["partialRight",Et],["rearg",jt]],Ft="[object Arguments]",zt="[object Array]",Ht="[object AsyncFunction]",Wt="[object Boolean]",Kt="[object Date]",$t="[object DOMException]",Gt="[object Error]",Jt="[object Function]",Yt="[object GeneratorFunction]",Xt="[object Map]",Qt="[object Number]",Zt="[object Null]",te="[object Object]",ee="[object Promise]",ne="[object Proxy]",re="[object RegExp]",oe="[object Set]",ie="[object String]",ae="[object Symbol]",ue="[object Undefined]",se="[object WeakMap]",ce="[object WeakSet]",le="[object ArrayBuffer]",fe="[object DataView]",pe="[object Float32Array]",he="[object Float64Array]",de="[object Int8Array]",ve="[object Int16Array]",ge="[object Int32Array]",me="[object Uint8Array]",ye="[object Uint8ClampedArray]",_e="[object Uint16Array]",be="[object Uint32Array]",we=/\b__p \+= '';/g,xe=/\b(__p \+=) '' \+/g,Ee=/(__e\(.*?\)|\b__t\)) \+\n'';/g,ke=/&(?:amp|lt|gt|quot|#39);/g,je=/[&<>"']/g,Oe=RegExp(ke.source),Se=RegExp(je.source),Te=/<%-([\s\S]+?)%>/g,Ce=/<%([\s\S]+?)%>/g,Ae=/<%=([\s\S]+?)%>/g,Ne=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,De=/^\w*$/,Me=/^\./,Ie=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Re=/[\\^$.*+?()[\]{}|]/g,Pe=RegExp(Re.source),Le=/^\s+|\s+$/g,Be=/^\s+/,qe=/\s+$/,Ue=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,Ve=/\{\n\/\* \[wrapped with (.+)\] \*/,Fe=/,? & /,ze=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,He=/\\(\\)?/g,We=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,Ke=/\w*$/,$e=/^[-+]0x[0-9a-f]+$/i,Ge=/^0b[01]+$/i,Je=/^\[object .+?Constructor\]$/,Ye=/^0o[0-7]+$/i,Xe=/^(?:0|[1-9]\d*)$/,Qe=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,Ze=/($^)/,tn=/['\n\r\u2028\u2029\\]/g,en="\\ud800-\\udfff",nn="\\u0300-\\u036f",rn="\\ufe20-\\ufe2f",on="\\u20d0-\\u20ff",an=nn+rn+on,un="\\u2700-\\u27bf",sn="a-z\\xdf-\\xf6\\xf8-\\xff",cn="\\xac\\xb1\\xd7\\xf7",ln="\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf",fn="\\u2000-\\u206f",pn=" \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",hn="A-Z\\xc0-\\xd6\\xd8-\\xde",dn="\\ufe0e\\ufe0f",vn=cn+ln+fn+pn,gn="['’]",mn="["+en+"]",yn="["+vn+"]",_n="["+an+"]",bn="\\d+",wn="["+un+"]",xn="["+sn+"]",En="[^"+en+vn+bn+un+sn+hn+"]",kn="\\ud83c[\\udffb-\\udfff]",jn="(?:"+_n+"|"+kn+")",On="[^"+en+"]",Sn="(?:\\ud83c[\\udde6-\\uddff]){2}",Tn="[\\ud800-\\udbff][\\udc00-\\udfff]",Cn="["+hn+"]",An="\\u200d",Nn="(?:"+xn+"|"+En+")",Dn="(?:"+Cn+"|"+En+")",Mn="(?:"+gn+"(?:d|ll|m|re|s|t|ve))?",In="(?:"+gn+"(?:D|LL|M|RE|S|T|VE))?",Rn=jn+"?",Pn="["+dn+"]?",Ln="(?:"+An+"(?:"+[On,Sn,Tn].join("|")+")"+Pn+Rn+")*",Bn="\\d*(?:(?:1st|2nd|3rd|(?![123])\\dth)\\b)",qn="\\d*(?:(?:1ST|2ND|3RD|(?![123])\\dTH)\\b)",Un=Pn+Rn+Ln,Vn="(?:"+[wn,Sn,Tn].join("|")+")"+Un,Fn="(?:"+[On+_n+"?",_n,Sn,Tn,mn].join("|")+")",zn=RegExp(gn,"g"),Hn=RegExp(_n,"g"),Wn=RegExp(kn+"(?="+kn+")|"+Fn+Un,"g"),Kn=RegExp([Cn+"?"+xn+"+"+Mn+"(?="+[yn,Cn,"$"].join("|")+")",Dn+"+"+In+"(?="+[yn,Cn+Nn,"$"].join("|")+")",Cn+"?"+Nn+"+"+Mn,Cn+"+"+In,qn,Bn,bn,Vn].join("|"),"g"),$n=RegExp("["+An+en+an+dn+"]"),Gn=/[a-z][A-Z]|[A-Z]{2,}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,Jn=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],Yn=-1,Xn={};Xn[pe]=Xn[he]=Xn[de]=Xn[ve]=Xn[ge]=Xn[me]=Xn[ye]=Xn[_e]=Xn[be]=!0,Xn[Ft]=Xn[zt]=Xn[le]=Xn[Wt]=Xn[fe]=Xn[Kt]=Xn[Gt]=Xn[Jt]=Xn[Xt]=Xn[Qt]=Xn[te]=Xn[re]=Xn[oe]=Xn[ie]=Xn[se]=!1;var Qn={};Qn[Ft]=Qn[zt]=Qn[le]=Qn[fe]=Qn[Wt]=Qn[Kt]=Qn[pe]=Qn[he]=Qn[de]=Qn[ve]=Qn[ge]=Qn[Xt]=Qn[Qt]=Qn[te]=Qn[re]=Qn[oe]=Qn[ie]=Qn[ae]=Qn[me]=Qn[ye]=Qn[_e]=Qn[be]=!0,Qn[Gt]=Qn[Jt]=Qn[se]=!1;var Zn={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},tr={"&":"&","<":"<",">":">",'"':""","'":"'"},er={"&":"&","<":"<",">":">",""":'"',"'":"'"},nr={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},rr=parseFloat,or=parseInt,ir="object"==typeof t&&t&&t.Object===Object&&t,ar="object"==typeof self&&self&&self.Object===Object&&self,ur=ir||ar||Function("return this")(),sr="object"==typeof e&&e&&!e.nodeType&&e,cr=sr&&"object"==typeof o&&o&&!o.nodeType&&o,lr=cr&&cr.exports===sr,fr=lr&&ir.process,pr=function(){try{return fr&&fr.binding&&fr.binding("util")}catch(t){}}(),hr=pr&&pr.isArrayBuffer,dr=pr&&pr.isDate,vr=pr&&pr.isMap,gr=pr&&pr.isRegExp,mr=pr&&pr.isSet,yr=pr&&pr.isTypedArray,_r=T("length"),br=C(Zn),wr=C(tr),xr=C(er),Er=function t(e){function n(t){if(cs(t)&&!wp(t)&&!(t instanceof b)){if(t instanceof o)return t;if(bl.call(t,"__wrapped__"))return aa(t)}return new o(t)}function r(){}function o(t,e){this.__wrapped__=t,this.__actions__=[],this.__chain__=!!e,this.__index__=0,this.__values__=ot}function b(t){this.__wrapped__=t,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=Bt,this.__views__=[]}function C(){var t=new b(this.__wrapped__);return t.__actions__=Vo(this.__actions__),t.__dir__=this.__dir__,t.__filtered__=this.__filtered__,t.__iteratees__=Vo(this.__iteratees__),t.__takeCount__=this.__takeCount__,t.__views__=Vo(this.__views__),t}function X(){if(this.__filtered__){var t=new b(this);t.__dir__=-1,t.__filtered__=!0}else t=this.clone(),t.__dir__*=-1;return t}function et(){var t=this.__wrapped__.value(),e=this.__dir__,n=wp(t),r=e<0,o=n?t.length:0,i=Ai(0,o,this.__views__),a=i.start,u=i.end,s=u-a,c=r?u:a-1,l=this.__iteratees__,f=l.length,p=0,h=Yl(s,this.__takeCount__);if(!n||!r&&o==s&&h==s)return xo(t,this.__actions__);var d=[];t:for(;s--&&p-1}function fn(t,e){var n=this.__data__,r=Mn(n,t);return r<0?(++this.size,n.push([t,e])):n[r][1]=e,this}function pn(t){var e=-1,n=null==t?0:t.length;for(this.clear();++e=e?t:e)),t}function Un(t,e,n,r,o,i){var a,u=e&pt,s=e&ht,l=e&dt;if(n&&(a=o?n(t,r,o,i):n(t)),a!==ot)return a;if(!ss(t))return t;var f=wp(t);if(f){if(a=Mi(t),!u)return Vo(t,a)}else{var p=Nf(t),h=p==Jt||p==Yt;if(Ep(t))return Co(t,u);if(p==te||p==Ft||h&&!o){if(a=s||h?{}:Ii(t),!u)return s?Ho(t,Pn(a,t)):zo(t,Rn(a,t))}else{if(!Qn[p])return o?t:{};a=Ri(t,p,Un,u)}}i||(i=new wn);var d=i.get(t);if(d)return d;i.set(t,a);var v=l?s?xi:wi:s?Ws:Hs,g=f?ot:v(t);return c(g||t,function(r,o){g&&(o=r,r=t[o]),Dn(a,o,Un(r,e,n,o,t,i))}),a}function Vn(t){var e=Hs(t);return function(n){return Fn(n,t,e)}}function Fn(t,e,n){var r=n.length;if(null==t)return!r;for(t=fl(t);r--;){var o=n[r],i=e[o],a=t[o];if(a===ot&&!(o in t)||!i(a))return!1}return!0}function Wn(t,e,n){if("function"!=typeof t)throw new dl(st);return If(function(){t.apply(ot,n)},e)}function Kn(t,e,n,r){var o=-1,i=h,a=!0,u=t.length,s=[],c=e.length;if(!u)return s;n&&(e=v(e,R(n))),r?(i=d,a=!1):e.length>=at&&(i=L,a=!1,e=new yn(e));t:for(;++oo?0:o+n),r=r===ot||r>o?o:Os(r),r<0&&(r+=o),r=n>r?0:Ss(r);n0&&n(u)?e>1?er(u,e-1,n,r,o):g(o,u):r||(o[o.length]=u)}return o}function nr(t,e){return t&&wf(t,e,Hs)}function ir(t,e){return t&&xf(t,e,Hs)}function ar(t,e){return p(e,function(e){return is(t[e])})}function sr(t,e){e=So(e,t);for(var n=0,r=e.length;null!=t&&ne}function _r(t,e){return null!=t&&bl.call(t,e)}function Er(t,e){return null!=t&&e in fl(t)}function jr(t,e,n){return t>=Yl(e,n)&&t=120&&l.length>=120)?new yn(a&&l):ot}l=t[0];var f=-1,p=u[0];t:for(;++f-1;)u!==t&&Il.call(u,s,1),Il.call(t,s,1);return t}function eo(t,e){for(var n=t?e.length:0,r=n-1;n--;){var o=e[n];if(n==r||o!==i){var i=o;Bi(o)?Il.call(t,o,1):_o(t,o)}}return t}function no(t,e){return t+zl(Zl()*(e-t+1))}function ro(t,e,n,r){for(var o=-1,i=Jl(Fl((e-t)/(n||1)),0),a=al(i);i--;)a[r?i:++o]=t,t+=n;return a}function oo(t,e){var n="";if(!t||e<1||e>Rt)return n;do e%2&&(n+=t),e=zl(e/2),e&&(t+=t);while(e);return n}function io(t,e){return Rf(Xi(t,e,Ic),t+"")}function ao(t){return Tn(rc(t))}function uo(t,e){var n=rc(t);return na(n,qn(e,0,n.length))}function so(t,e,n,r){if(!ss(t))return t;e=So(e,t);for(var o=-1,i=e.length,a=i-1,u=t;null!=u&&++oo?0:o+e),n=n>o?o:n,n<0&&(n+=o),o=e>n?0:n-e>>>0,e>>>=0;for(var i=al(o);++r>>1,a=t[i];null!==a&&!bs(a)&&(n?a<=e:a=at){var c=e?null:Sf(t);if(c)return J(c);a=!1,o=L,s=new yn}else s=e?[]:u;t:for(;++r=r?t:lo(t,e,n)}function Co(t,e){if(e)return t.slice();var n=t.length,r=Al?Al(n):new t.constructor(n);return t.copy(r),r}function Ao(t){var e=new t.constructor(t.byteLength);return new Cl(e).set(new Cl(t)),e}function No(t,e){var n=e?Ao(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.byteLength)}function Do(t,e,n){var r=e?n(K(t),pt):K(t);return m(r,i,new t.constructor)}function Mo(t){var e=new t.constructor(t.source,Ke.exec(t));return e.lastIndex=t.lastIndex,e}function Io(t,e,n){var r=e?n(J(t),pt):J(t);return m(r,a,new t.constructor)}function Ro(t){return gf?fl(gf.call(t)):{}}function Po(t,e){var n=e?Ao(t.buffer):t.buffer;return new t.constructor(n,t.byteOffset,t.length)}function Lo(t,e){if(t!==e){var n=t!==ot,r=null===t,o=t===t,i=bs(t),a=e!==ot,u=null===e,s=e===e,c=bs(e);if(!u&&!c&&!i&&t>e||i&&a&&s&&!u&&!c||r&&a&&s||!n&&s||!o)return 1;if(!r&&!i&&!c&&t=u)return s;var c=n[r];return s*("desc"==c?-1:1)}}return t.index-e.index}function qo(t,e,n,r){for(var o=-1,i=t.length,a=n.length,u=-1,s=e.length,c=Jl(i-a,0),l=al(s+c),f=!r;++u1?n[o-1]:ot,a=o>2?n[2]:ot;for(i=t.length>3&&"function"==typeof i?(o--,i):ot,a&&qi(n[0],n[1],a)&&(i=o<3?ot:i,o=1),e=fl(e);++r-1?o[i?e[a]:a]:ot}}function ei(t){return bi(function(e){var n=e.length,r=n,i=o.prototype.thru;for(t&&e.reverse();r--;){var a=e[r];if("function"!=typeof a)throw new dl(st);if(i&&!u&&"wrapper"==Ei(a))var u=new o([],!0)}for(r=u?r:n;++r1&&y.reverse(),f&&su))return!1;var c=i.get(t);if(c&&i.get(e))return c==e;var l=-1,f=!0,p=n>?new yn:ot;for(i.set(t,e),i.set(e,t);++l1?"& ":"")+e[r],e=e.join(n>2?", ":" "),t.replace(Ue,"{\n/* [wrapped with "+e+"] */\n")}function Li(t){return wp(t)||bp(t)||!!(Rl&&t&&t[Rl])}function Bi(t,e){return e=null==e?Rt:e,!!e&&("number"==typeof t||Xe.test(t))&&t>-1&&t%1==0&&t0){if(++e>=Ct)return arguments[0]}else e=0;return t.apply(ot,arguments)}}function na(t,e){var n=-1,r=t.length,o=r-1;for(e=e===ot?r:e;++n=this.__values__.length,e=t?ot:this.__values__[this.__index__++];return{done:t,value:e}}function au(){return this}function uu(t){for(var e,n=this;n instanceof r;){var o=aa(n);o.__index__=0,o.__values__=ot,e?i.__wrapped__=o:e=o;var i=o;n=n.__wrapped__}return i.__wrapped__=t,e}function su(){var t=this.__wrapped__;if(t instanceof b){var e=t;return this.__actions__.length&&(e=new b(this)),e=e.reverse(),e.__actions__.push({func:nu,args:[Da],thisArg:ot}),new o(e,this.__chain__)}return this.thru(Da)}function cu(){return xo(this.__wrapped__,this.__actions__)}function lu(t,e,n){var r=wp(t)?f:$n;return n&&qi(t,e,n)&&(e=ot),r(t,ji(e,3))}function fu(t,e){var n=wp(t)?p:tr;return n(t,ji(e,3))}function pu(t,e){return er(yu(t,e),1)}function hu(t,e){return er(yu(t,e),It)}function du(t,e,n){return n=n===ot?1:Os(n),er(yu(t,e),n)}function vu(t,e){var n=wp(t)?c:_f;return n(t,ji(e,3))}function gu(t,e){var n=wp(t)?l:bf;return n(t,ji(e,3))}function mu(t,e,n,r){t=Yu(t)?t:rc(t),n=n&&!r?Os(n):0;var o=t.length;return n<0&&(n=Jl(o+n,0)),_s(t)?n<=o&&t.indexOf(e,n)>-1:!!o&&k(t,e,n)>-1}function yu(t,e){var n=wp(t)?v:Hr;return n(t,ji(e,3))}function _u(t,e,n,r){return null==t?[]:(wp(e)||(e=null==e?[]:[e]),n=r?ot:n,wp(n)||(n=null==n?[]:[n]),Yr(t,e,n))}function bu(t,e,n){var r=wp(t)?m:A,o=arguments.length<3;return r(t,ji(e,4),n,o,_f)}function wu(t,e,n){var r=wp(t)?y:A,o=arguments.length<3;return r(t,ji(e,4),n,o,bf)}function xu(t,e){var n=wp(t)?p:tr;return n(t,Pu(ji(e,3)))}function Eu(t){var e=wp(t)?Tn:ao;return e(t)}function ku(t,e,n){e=(n?qi(t,e,n):e===ot)?1:Os(e);var r=wp(t)?Cn:uo;return r(t,e)}function ju(t){var e=wp(t)?An:co;return e(t)}function Ou(t){if(null==t)return 0;if(Yu(t))return _s(t)?Z(t):t.length;var e=Nf(t);return e==Xt||e==oe?t.size:Vr(t).length}function Su(t,e,n){var r=wp(t)?_:fo;return n&&qi(t,e,n)&&(e=ot),r(t,ji(e,3))}function Tu(t,e){if("function"!=typeof e)throw new dl(st);return t=Os(t),function(){if(--t<1)return e.apply(this,arguments)}}function Cu(t,e,n){return e=n?ot:e,e=t&&null==e?t.length:e,hi(t,kt,ot,ot,ot,ot,e)}function Au(t,e){var n;if("function"!=typeof e)throw new dl(st);return t=Os(t),function(){return--t>0&&(n=e.apply(this,arguments)),t<=1&&(e=ot),n}}function Nu(t,e,n){e=n?ot:e;var r=hi(t,bt,ot,ot,ot,ot,ot,e);return r.placeholder=Nu.placeholder,r}function Du(t,e,n){e=n?ot:e;var r=hi(t,wt,ot,ot,ot,ot,ot,e);return r.placeholder=Du.placeholder,r}function Mu(t,e,n){function r(e){var n=p,r=h;return p=h=ot,y=e,v=t.apply(r,n)}function o(t){return y=t,g=If(u,e),_?r(t):v}function i(t){var n=t-m,r=t-y,o=e-n;return b?Yl(o,d-r):o}function a(t){var n=t-m,r=t-y;return m===ot||n>=e||n<0||b&&r>=d}function u(){var t=cp();return a(t)?s(t):void(g=If(u,i(t)))}function s(t){return g=ot,w&&p?r(t):(p=h=ot,v)}function c(){g!==ot&&Of(g),y=0,p=m=h=g=ot}function l(){return g===ot?v:s(cp())}function f(){var t=cp(),n=a(t);if(p=arguments,h=this,m=t,n){if(g===ot)return o(m);if(b)return g=If(u,e),r(m)}return g===ot&&(g=If(u,e)),v}var p,h,d,v,g,m,y=0,_=!1,b=!1,w=!0;if("function"!=typeof t)throw new dl(st);return e=Ts(e)||0,ss(n)&&(_=!!n.leading,b="maxWait"in n,d=b?Jl(Ts(n.maxWait)||0,e):d,w="trailing"in n?!!n.trailing:w),f.cancel=c,f.flush=l,f}function Iu(t){return hi(t,Ot)}function Ru(t,e){if("function"!=typeof t||null!=e&&"function"!=typeof e)throw new dl(st);var n=function(){var r=arguments,o=e?e.apply(this,r):r[0],i=n.cache;if(i.has(o))return i.get(o);var a=t.apply(this,r);return n.cache=i.set(o,a)||i,a};return n.cache=new(Ru.Cache||pn),n}function Pu(t){if("function"!=typeof t)throw new dl(st);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}function Lu(t){return Au(2,t)}function Bu(t,e){if("function"!=typeof t)throw new dl(st);return e=e===ot?e:Os(e),io(t,e)}function qu(t,e){if("function"!=typeof t)throw new dl(st);return e=null==e?0:Jl(Os(e),0),io(function(n){var r=n[e],o=To(n,0,e);return r&&g(o,r),u(t,this,o)})}function Uu(t,e,n){var r=!0,o=!0;if("function"!=typeof t)throw new dl(st);return ss(n)&&(r="leading"in n?!!n.leading:r,o="trailing"in n?!!n.trailing:o),Mu(t,e,{leading:r,maxWait:e,trailing:o})}function Vu(t){return Cu(t,1)}function Fu(t,e){return vp(Oo(e),t)}function zu(){if(!arguments.length)return[];var t=arguments[0];return wp(t)?t:[t]}function Hu(t){return Un(t,dt)}function Wu(t,e){return e="function"==typeof e?e:ot,Un(t,dt,e)}function Ku(t){return Un(t,pt|dt)}function $u(t,e){return e="function"==typeof e?e:ot,Un(t,pt|dt,e)}function Gu(t,e){return null==e||Fn(t,e,Hs(e))}function Ju(t,e){return t===e||t!==t&&e!==e}function Yu(t){return null!=t&&us(t.length)&&!is(t)}function Xu(t){return cs(t)&&Yu(t)}function Qu(t){return t===!0||t===!1||cs(t)&&fr(t)==Wt}function Zu(t){return cs(t)&&1===t.nodeType&&!ms(t)}function ts(t){if(null==t)return!0;if(Yu(t)&&(wp(t)||"string"==typeof t||"function"==typeof t.splice||Ep(t)||Tp(t)||bp(t)))return!t.length;var e=Nf(t);if(e==Xt||e==oe)return!t.size;if(Hi(t))return!Vr(t).length;for(var n in t)if(bl.call(t,n))return!1;return!0}function es(t,e){return Dr(t,e)}function ns(t,e,n){n="function"==typeof n?n:ot;var r=n?n(t,e):ot;return r===ot?Dr(t,e,ot,n):!!r}function rs(t){if(!cs(t))return!1;var e=fr(t);return e==Gt||e==$t||"string"==typeof t.message&&"string"==typeof t.name&&!ms(t)}function os(t){return"number"==typeof t&&Kl(t)}function is(t){if(!ss(t))return!1;var e=fr(t);return e==Jt||e==Yt||e==Ht||e==ne}function as(t){return"number"==typeof t&&t==Os(t)}function us(t){return"number"==typeof t&&t>-1&&t%1==0&&t<=Rt}function ss(t){var e=typeof t;return null!=t&&("object"==e||"function"==e)}function cs(t){return null!=t&&"object"==typeof t}function ls(t,e){return t===e||Rr(t,e,Si(e))}function fs(t,e,n){return n="function"==typeof n?n:ot,Rr(t,e,Si(e),n)}function ps(t){return gs(t)&&t!=+t}function hs(t){if(Df(t))throw new sl(ut);return Pr(t)}function ds(t){return null===t}function vs(t){return null==t}function gs(t){return"number"==typeof t||cs(t)&&fr(t)==Qt}function ms(t){if(!cs(t)||fr(t)!=te)return!1;var e=Nl(t);if(null===e)return!0;var n=bl.call(e,"constructor")&&e.constructor;return"function"==typeof n&&n instanceof n&&_l.call(n)==kl}function ys(t){return as(t)&&t>=-Rt&&t<=Rt}function _s(t){return"string"==typeof t||!wp(t)&&cs(t)&&fr(t)==ie}function bs(t){return"symbol"==typeof t||cs(t)&&fr(t)==ae}function ws(t){return t===ot}function xs(t){return cs(t)&&Nf(t)==se}function Es(t){return cs(t)&&fr(t)==ce}function ks(t){if(!t)return[];if(Yu(t))return _s(t)?tt(t):Vo(t);if(Pl&&t[Pl])return W(t[Pl]());var e=Nf(t),n=e==Xt?K:e==oe?J:rc;return n(t)}function js(t){if(!t)return 0===t?t:0;if(t=Ts(t),t===It||t===-It){var e=t<0?-1:1;return e*Pt}return t===t?t:0}function Os(t){var e=js(t),n=e%1;return e===e?n?e-n:e:0}function Ss(t){return t?qn(Os(t),0,Bt):0}function Ts(t){if("number"==typeof t)return t;if(bs(t))return Lt;if(ss(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=ss(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(Le,"");var n=Ge.test(t);return n||Ye.test(t)?or(t.slice(2),n?2:8):$e.test(t)?Lt:+t}function Cs(t){return Fo(t,Ws(t))}function As(t){return t?qn(Os(t),-Rt,Rt):0===t?t:0}function Ns(t){return null==t?"":mo(t)}function Ds(t,e){var n=yf(t);return null==e?n:Rn(n,e)}function Ms(t,e){return x(t,ji(e,3),nr)}function Is(t,e){return x(t,ji(e,3),ir)}function Rs(t,e){return null==t?t:wf(t,ji(e,3),Ws)}function Ps(t,e){return null==t?t:xf(t,ji(e,3),Ws)}function Ls(t,e){return t&&nr(t,ji(e,3))}function Bs(t,e){return t&&ir(t,ji(e,3))}function qs(t){return null==t?[]:ar(t,Hs(t))}function Us(t){return null==t?[]:ar(t,Ws(t))}function Vs(t,e,n){var r=null==t?ot:sr(t,e);return r===ot?n:r}function Fs(t,e){return null!=t&&Di(t,e,_r)}function zs(t,e){return null!=t&&Di(t,e,Er)}function Hs(t){return Yu(t)?Sn(t):Vr(t)}function Ws(t){return Yu(t)?Sn(t,!0):Fr(t)}function Ks(t,e){var n={};return e=ji(e,3),nr(t,function(t,r,o){Ln(n,e(t,r,o),t)}),n}function $s(t,e){var n={};return e=ji(e,3),nr(t,function(t,r,o){Ln(n,r,e(t,r,o))}),n}function Gs(t,e){return Js(t,Pu(ji(e)))}function Js(t,e){if(null==t)return{};var n=v(xi(t),function(t){return[t]});return e=ji(e),Qr(t,n,function(t,n){return e(t,n[0])})}function Ys(t,e,n){e=So(e,t);var r=-1,o=e.length;for(o||(o=1,t=ot);++re){var r=t;t=e,e=r}if(n||t%1||e%1){var o=Zl();return Yl(t+o*(e-t+rr("1e-"+((o+"").length-1))),e)}return no(t,e)}function sc(t){return th(Ns(t).toLowerCase())}function cc(t){return t=Ns(t),t&&t.replace(Qe,br).replace(Hn,"")}function lc(t,e,n){t=Ns(t),e=mo(e);var r=t.length;n=n===ot?r:qn(Os(n),0,r);var o=n;return n-=e.length,n>=0&&t.slice(n,o)==e}function fc(t){return t=Ns(t),t&&Se.test(t)?t.replace(je,wr):t}function pc(t){return t=Ns(t),t&&Pe.test(t)?t.replace(Re,"\\$&"):t}function hc(t,e,n){t=Ns(t),e=Os(e);var r=e?Z(t):0;if(!e||r>=e)return t;var o=(e-r)/2;return ai(zl(o),n)+t+ai(Fl(o),n)}function dc(t,e,n){t=Ns(t),e=Os(e);var r=e?Z(t):0;return e&&r>>0)?(t=Ns(t),t&&("string"==typeof e||null!=e&&!Op(e))&&(e=mo(e),!e&&z(t))?To(tt(t),0,n):t.split(e,n)):[]}function bc(t,e,n){return t=Ns(t),n=null==n?0:qn(Os(n),0,t.length),e=mo(e),t.slice(n,n+e.length)==e}function wc(t,e,r){var o=n.templateSettings;r&&qi(t,e,r)&&(e=ot),t=Ns(t),e=Mp({},e,o,di);var i,a,u=Mp({},e.imports,o.imports,di),s=Hs(u),c=P(u,s),l=0,f=e.interpolate||Ze,p="__p += '",h=pl((e.escape||Ze).source+"|"+f.source+"|"+(f===Ae?We:Ze).source+"|"+(e.evaluate||Ze).source+"|$","g"),d="//# sourceURL="+("sourceURL"in e?e.sourceURL:"lodash.templateSources["+ ++Yn+"]")+"\n";t.replace(h,function(e,n,r,o,u,s){return r||(r=o),p+=t.slice(l,s).replace(tn,V),n&&(i=!0,p+="' +\n__e("+n+") +\n'"),u&&(a=!0,p+="';\n"+u+";\n__p += '"),r&&(p+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),l=s+e.length,e}),p+="';\n";var v=e.variable;v||(p="with (obj) {\n"+p+"\n}\n"),p=(a?p.replace(we,""):p).replace(xe,"$1").replace(Ee,"$1;"),p="function("+(v||"obj")+") {\n"+(v?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(i?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+p+"return __p\n}";var g=eh(function(){return cl(s,d+"return "+p).apply(ot,c)});if(g.source=p,rs(g))throw g;return g}function xc(t){return Ns(t).toLowerCase()}function Ec(t){return Ns(t).toUpperCase()}function kc(t,e,n){if(t=Ns(t),t&&(n||e===ot))return t.replace(Le,"");if(!t||!(e=mo(e)))return t;var r=tt(t),o=tt(e),i=B(r,o),a=q(r,o)+1;return To(r,i,a).join("")}function jc(t,e,n){if(t=Ns(t),t&&(n||e===ot))return t.replace(qe,"");if(!t||!(e=mo(e)))return t;var r=tt(t),o=q(r,tt(e))+1;return To(r,0,o).join("")}function Oc(t,e,n){if(t=Ns(t),t&&(n||e===ot))return t.replace(Be,"");if(!t||!(e=mo(e)))return t;var r=tt(t),o=B(r,tt(e));return To(r,o).join("")}function Sc(t,e){var n=St,r=Tt;if(ss(e)){var o="separator"in e?e.separator:o;n="length"in e?Os(e.length):n,r="omission"in e?mo(e.omission):r}t=Ns(t);var i=t.length;if(z(t)){var a=tt(t);i=a.length}if(n>=i)return t;var u=n-Z(r);if(u<1)return r;var s=a?To(a,0,u).join(""):t.slice(0,u);if(o===ot)return s+r;if(a&&(u+=s.length-u),Op(o)){if(t.slice(u).search(o)){var c,l=s;for(o.global||(o=pl(o.source,Ns(Ke.exec(o))+"g")),o.lastIndex=0;c=o.exec(l);)var f=c.index;s=s.slice(0,f===ot?u:f)}}else if(t.indexOf(mo(o),u)!=u){var p=s.lastIndexOf(o);p>-1&&(s=s.slice(0,p))}return s+r}function Tc(t){return t=Ns(t),t&&Oe.test(t)?t.replace(ke,xr):t}function Cc(t,e,n){return t=Ns(t),e=n?ot:e,e===ot?H(t)?rt(t):w(t):t.match(e)||[]}function Ac(t){var e=null==t?0:t.length,n=ji();return t=e?v(t,function(t){if("function"!=typeof t[1])throw new dl(st);return[n(t[0]),t[1]]}):[],io(function(n){for(var r=-1;++rRt)return[];var n=Bt,r=Yl(t,Bt);e=ji(e),t-=Bt;for(var o=M(r,e);++n1?t[e-1]:ot;return n="function"==typeof n?(t.pop(),n):ot,Xa(t,n)}),tp=bi(function(t){var e=t.length,n=e?t[0]:0,r=this.__wrapped__,i=function(e){return Bn(e,t)};return!(e>1||this.__actions__.length)&&r instanceof b&&Bi(n)?(r=r.slice(n,+n+(e?1:0)),r.__actions__.push({func:nu,args:[i],thisArg:ot}),new o(r,this.__chain__).thru(function(t){return e&&!t.length&&t.push(ot),t})):this.thru(i)}),ep=Wo(function(t,e,n){bl.call(t,n)?++t[n]:Ln(t,n,1)}),np=ti(va),rp=ti(ga),op=Wo(function(t,e,n){bl.call(t,n)?t[n].push(e):Ln(t,n,[e])}),ip=io(function(t,e,n){var r=-1,o="function"==typeof e,i=Yu(t)?al(t.length):[];return _f(t,function(t){i[++r]=o?u(e,t,n):Tr(t,e,n)}),i}),ap=Wo(function(t,e,n){Ln(t,n,e)}),up=Wo(function(t,e,n){t[n?0:1].push(e)},function(){return[[],[]]}),sp=io(function(t,e){if(null==t)return[];var n=e.length;return n>1&&qi(t,e[0],e[1])?e=[]:n>2&&qi(e[0],e[1],e[2])&&(e=[e[0]]),Yr(t,er(e,1),[])}),cp=Ul||function(){return ur.Date.now()},lp=io(function(t,e,n){var r=mt;if(n.length){var o=G(n,ki(lp));r|=xt}return hi(t,r,e,n,o)}),fp=io(function(t,e,n){var r=mt|yt;if(n.length){var o=G(n,ki(fp));r|=xt}return hi(e,r,t,n,o)}),pp=io(function(t,e){return Wn(t,1,e)}),hp=io(function(t,e,n){return Wn(t,Ts(e)||0,n)});Ru.Cache=pn;var dp=jf(function(t,e){e=1==e.length&&wp(e[0])?v(e[0],R(ji())):v(er(e,1),R(ji()));var n=e.length;return io(function(r){for(var o=-1,i=Yl(r.length,n);++o=e}),bp=Cr(function(){return arguments}())?Cr:function(t){return cs(t)&&bl.call(t,"callee")&&!Ml.call(t,"callee")},wp=al.isArray,xp=hr?R(hr):Ar,Ep=Wl||Wc,kp=dr?R(dr):Nr,jp=vr?R(vr):Ir,Op=gr?R(gr):Lr,Sp=mr?R(mr):Br,Tp=yr?R(yr):qr,Cp=ci(zr),Ap=ci(function(t,e){return t<=e}),Np=Ko(function(t,e){if(Hi(e)||Yu(e))return void Fo(e,Hs(e),t);for(var n in e)bl.call(e,n)&&Dn(t,n,e[n])}),Dp=Ko(function(t,e){Fo(e,Ws(e),t)}),Mp=Ko(function(t,e,n,r){Fo(e,Ws(e),t,r)}),Ip=Ko(function(t,e,n,r){Fo(e,Hs(e),t,r)}),Rp=bi(Bn),Pp=io(function(t){return t.push(ot,di),u(Mp,ot,t)}),Lp=io(function(t){return t.push(ot,vi),u(Fp,ot,t)}),Bp=ri(function(t,e,n){t[e]=n},Dc(Ic)),qp=ri(function(t,e,n){bl.call(t,e)?t[e].push(n):t[e]=[n]},ji),Up=io(Tr),Vp=Ko(function(t,e,n){$r(t,e,n)}),Fp=Ko(function(t,e,n,r){$r(t,e,n,r)}),zp=bi(function(t,e){var n={};if(null==t)return n;var r=!1;e=v(e,function(e){return e=So(e,t),r||(r=e.length>1),e}),Fo(t,xi(t),n),r&&(n=Un(n,pt|ht|dt,gi));for(var o=e.length;o--;)_o(n,e[o]);return n}),Hp=bi(function(t,e){return null==t?{}:Xr(t,e)}),Wp=pi(Hs),Kp=pi(Ws),$p=Xo(function(t,e,n){return e=e.toLowerCase(),t+(n?sc(e):e)}),Gp=Xo(function(t,e,n){return t+(n?"-":"")+e.toLowerCase()}),Jp=Xo(function(t,e,n){return t+(n?" ":"")+e.toLowerCase()}),Yp=Yo("toLowerCase"),Xp=Xo(function(t,e,n){return t+(n?"_":"")+e.toLowerCase()}),Qp=Xo(function(t,e,n){return t+(n?" ":"")+th(e)}),Zp=Xo(function(t,e,n){return t+(n?" ":"")+e.toUpperCase()}),th=Yo("toUpperCase"),eh=io(function(t,e){try{return u(t,ot,e)}catch(t){return rs(t)?t:new sl(t)}}),nh=bi(function(t,e){return c(e,function(e){e=ra(e),Ln(t,e,lp(t[e],t))}),t}),rh=ei(),oh=ei(!0),ih=io(function(t,e){return function(n){return Tr(n,t,e)}}),ah=io(function(t,e){return function(n){return Tr(t,n,e)}}),uh=ii(v),sh=ii(f),ch=ii(_),lh=si(),fh=si(!0),ph=oi(function(t,e){return t+e},0),hh=fi("ceil"),dh=oi(function(t,e){return t/e},1),vh=fi("floor"),gh=oi(function(t,e){return t*e},1),mh=fi("round"),yh=oi(function(t,e){return t-e},0);return n.after=Tu,n.ary=Cu,n.assign=Np,n.assignIn=Dp,n.assignInWith=Mp,n.assignWith=Ip,n.at=Rp,n.before=Au,n.bind=lp,n.bindAll=nh,n.bindKey=fp,n.castArray=zu,n.chain=tu,n.chunk=ua,n.compact=sa,n.concat=ca,n.cond=Ac,n.conforms=Nc,n.constant=Dc,n.countBy=ep,n.create=Ds,n.curry=Nu,n.curryRight=Du,n.debounce=Mu,n.defaults=Pp,n.defaultsDeep=Lp,n.defer=pp,n.delay=hp,n.difference=Lf,n.differenceBy=Bf,n.differenceWith=qf,n.drop=la,n.dropRight=fa,n.dropRightWhile=pa,n.dropWhile=ha,n.fill=da,n.filter=fu,n.flatMap=pu,n.flatMapDeep=hu,n.flatMapDepth=du,n.flatten=ma,n.flattenDeep=ya,n.flattenDepth=_a,n.flip=Iu,n.flow=rh,n.flowRight=oh,n.fromPairs=ba,n.functions=qs,n.functionsIn=Us,n.groupBy=op,n.initial=Ea,n.intersection=Uf,n.intersectionBy=Vf,n.intersectionWith=Ff,n.invert=Bp,n.invertBy=qp,n.invokeMap=ip,n.iteratee=Rc,n.keyBy=ap,n.keys=Hs,n.keysIn=Ws,n.map=yu,n.mapKeys=Ks,n.mapValues=$s,n.matches=Pc,n.matchesProperty=Lc,n.memoize=Ru,n.merge=Vp,n.mergeWith=Fp,n.method=ih,n.methodOf=ah,n.mixin=Bc,n.negate=Pu,n.nthArg=Vc,n.omit=zp,n.omitBy=Gs,n.once=Lu,n.orderBy=_u,n.over=uh,n.overArgs=dp,n.overEvery=sh,n.overSome=ch,n.partial=vp,n.partialRight=gp,n.partition=up,n.pick=Hp,n.pickBy=Js,n.property=Fc,n.propertyOf=zc,n.pull=zf,n.pullAll=Ta,n.pullAllBy=Ca,n.pullAllWith=Aa,n.pullAt=Hf,n.range=lh,n.rangeRight=fh,n.rearg=mp,n.reject=xu,n.remove=Na,n.rest=Bu,n.reverse=Da,n.sampleSize=ku,n.set=Xs,n.setWith=Qs,n.shuffle=ju,n.slice=Ma,n.sortBy=sp,n.sortedUniq=Ua,n.sortedUniqBy=Va,n.split=_c,n.spread=qu,n.tail=Fa,n.take=za,n.takeRight=Ha,n.takeRightWhile=Wa,n.takeWhile=Ka,n.tap=eu,n.throttle=Uu,n.thru=nu,n.toArray=ks,n.toPairs=Wp,n.toPairsIn=Kp,n.toPath=Yc,n.toPlainObject=Cs,n.transform=Zs,n.unary=Vu,n.union=Wf,n.unionBy=Kf,n.unionWith=$f,n.uniq=$a,n.uniqBy=Ga,n.uniqWith=Ja,n.unset=tc,n.unzip=Ya,n.unzipWith=Xa,n.update=ec,n.updateWith=nc,n.values=rc,n.valuesIn=oc,n.without=Gf,n.words=Cc,n.wrap=Fu,n.xor=Jf,n.xorBy=Yf,n.xorWith=Xf,n.zip=Qf,n.zipObject=Qa,n.zipObjectDeep=Za,n.zipWith=Zf,n.entries=Wp,n.entriesIn=Kp,n.extend=Dp,n.extendWith=Mp,Bc(n,n),n.add=ph,n.attempt=eh,n.camelCase=$p,n.capitalize=sc,n.ceil=hh,n.clamp=ic,n.clone=Hu,n.cloneDeep=Ku,n.cloneDeepWith=$u,n.cloneWith=Wu,n.conformsTo=Gu,n.deburr=cc,n.defaultTo=Mc,n.divide=dh,n.endsWith=lc,n.eq=Ju,n.escape=fc,n.escapeRegExp=pc,n.every=lu,n.find=np,n.findIndex=va,n.findKey=Ms,n.findLast=rp,n.findLastIndex=ga,n.findLastKey=Is,n.floor=vh,n.forEach=vu,n.forEachRight=gu,n.forIn=Rs,n.forInRight=Ps,n.forOwn=Ls,n.forOwnRight=Bs,n.get=Vs,n.gt=yp,n.gte=_p,n.has=Fs,n.hasIn=zs,n.head=wa,n.identity=Ic,n.includes=mu,n.indexOf=xa,n.inRange=ac,n.invoke=Up,n.isArguments=bp,n.isArray=wp,n.isArrayBuffer=xp,n.isArrayLike=Yu,n.isArrayLikeObject=Xu,n.isBoolean=Qu,n.isBuffer=Ep,n.isDate=kp,n.isElement=Zu,n.isEmpty=ts,n.isEqual=es,n.isEqualWith=ns,n.isError=rs,n.isFinite=os,n.isFunction=is,n.isInteger=as,n.isLength=us,n.isMap=jp,n.isMatch=ls,n.isMatchWith=fs,n.isNaN=ps,n.isNative=hs,n.isNil=vs,n.isNull=ds,n.isNumber=gs,n.isObject=ss,n.isObjectLike=cs,n.isPlainObject=ms,n.isRegExp=Op,n.isSafeInteger=ys,n.isSet=Sp,n.isString=_s,n.isSymbol=bs,n.isTypedArray=Tp,n.isUndefined=ws,n.isWeakMap=xs,n.isWeakSet=Es,n.join=ka,n.kebabCase=Gp,n.last=ja,n.lastIndexOf=Oa,n.lowerCase=Jp,n.lowerFirst=Yp,n.lt=Cp,n.lte=Ap,n.max=Qc,n.maxBy=Zc,n.mean=tl,n.meanBy=el,n.min=nl,n.minBy=rl,n.stubArray=Hc,n.stubFalse=Wc,n.stubObject=Kc,n.stubString=$c,n.stubTrue=Gc,n.multiply=gh,n.nth=Sa,n.noConflict=qc,n.noop=Uc,n.now=cp,n.pad=hc,n.padEnd=dc,n.padStart=vc,n.parseInt=gc,n.random=uc,n.reduce=bu,n.reduceRight=wu,n.repeat=mc,n.replace=yc,n.result=Ys,n.round=mh,n.runInContext=t,n.sample=Eu,n.size=Ou,n.snakeCase=Xp,n.some=Su,n.sortedIndex=Ia,n.sortedIndexBy=Ra,n.sortedIndexOf=Pa,n.sortedLastIndex=La,n.sortedLastIndexBy=Ba,n.sortedLastIndexOf=qa,n.startCase=Qp,n.startsWith=bc,n.subtract=yh,n.sum=ol,n.sumBy=il,n.template=wc,n.times=Jc,n.toFinite=js,n.toInteger=Os,n.toLength=Ss,n.toLower=xc,n.toNumber=Ts,n.toSafeInteger=As,n.toString=Ns,n.toUpper=Ec,n.trim=kc,n.trimEnd=jc,n.trimStart=Oc,n.truncate=Sc,n.unescape=Tc,n.uniqueId=Xc,n.upperCase=Zp,n.upperFirst=th,n.each=vu,n.eachRight=gu,n.first=wa,Bc(n,function(){var t={};return nr(n,function(e,r){bl.call(n.prototype,r)||(t[r]=e)}),t}(),{chain:!1}),n.VERSION=it,c(["bind","bindKey","curry","curryRight","partial","partialRight"],function(t){n[t].placeholder=n}),c(["drop","take"],function(t,e){b.prototype[t]=function(n){n=n===ot?1:Jl(Os(n),0);var r=this.__filtered__&&!e?new b(this):this.clone();return r.__filtered__?r.__takeCount__=Yl(n,r.__takeCount__):r.__views__.push({size:Yl(n,Bt),type:t+(r.__dir__<0?"Right":"")}),r},b.prototype[t+"Right"]=function(e){return this.reverse()[t](e).reverse()}}),c(["filter","map","takeWhile"],function(t,e){var n=e+1,r=n==Nt||n==Mt;b.prototype[t]=function(t){var e=this.clone();return e.__iteratees__.push({iteratee:ji(t,3),type:n}),e.__filtered__=e.__filtered__||r,e}}),c(["head","last"],function(t,e){var n="take"+(e?"Right":"");b.prototype[t]=function(){return this[n](1).value()[0]}}),c(["initial","tail"],function(t,e){var n="drop"+(e?"":"Right");b.prototype[t]=function(){return this.__filtered__?new b(this):this[n](1)}}),b.prototype.compact=function(){return this.filter(Ic)},b.prototype.find=function(t){return this.filter(t).head()},b.prototype.findLast=function(t){return this.reverse().find(t)},b.prototype.invokeMap=io(function(t,e){return"function"==typeof t?new b(this):this.map(function(n){return Tr(n,t,e)})}),b.prototype.reject=function(t){return this.filter(Pu(ji(t)))},b.prototype.slice=function(t,e){t=Os(t);var n=this;return n.__filtered__&&(t>0||e<0)?new b(n):(t<0?n=n.takeRight(-t):t&&(n=n.drop(t)),e!==ot&&(e=Os(e),n=e<0?n.dropRight(-e):n.take(e-t)),n)},b.prototype.takeRightWhile=function(t){return this.reverse().takeWhile(t).reverse()},b.prototype.toArray=function(){return this.take(Bt)},nr(b.prototype,function(t,e){var r=/^(?:filter|find|map|reject)|While$/.test(e),i=/^(?:head|last)$/.test(e),a=n[i?"take"+("last"==e?"Right":""):e],u=i||/^find/.test(e);a&&(n.prototype[e]=function(){var e=this.__wrapped__,s=i?[1]:arguments,c=e instanceof b,l=s[0],f=c||wp(e),p=function(t){var e=a.apply(n,g([t],s));return i&&h?e[0]:e};f&&r&&"function"==typeof l&&1!=l.length&&(c=f=!1);var h=this.__chain__,d=!!this.__actions__.length,v=u&&!h,m=c&&!d;if(!u&&f){e=m?e:new b(this);var y=t.apply(e,s);return y.__actions__.push({func:nu,args:[p],thisArg:ot}),new o(y,h)}return v&&m?t.apply(this,s):(y=this.thru(p),v?i?y.value()[0]:y.value():y)})}),c(["pop","push","shift","sort","splice","unshift"],function(t){var e=vl[t],r=/^(?:push|sort|unshift)$/.test(t)?"tap":"thru",o=/^(?:pop|shift)$/.test(t);n.prototype[t]=function(){var t=arguments;if(o&&!this.__chain__){var n=this.value();return e.apply(wp(n)?n:[],t)}return this[r](function(n){return e.apply(wp(n)?n:[],t)})}}),nr(b.prototype,function(t,e){var r=n[e];if(r){var o=r.name+"",i=cf[o]||(cf[o]=[]);i.push({name:e,func:r})}}),cf[ni(ot,yt).name]=[{name:"wrapper",func:ot}],b.prototype.clone=C,b.prototype.reverse=X,b.prototype.value=et,n.prototype.at=tp,n.prototype.chain=ru,n.prototype.commit=ou,n.prototype.next=iu,n.prototype.plant=uu,n.prototype.reverse=su,n.prototype.toJSON=n.prototype.valueOf=n.prototype.value=cu,n.prototype.first=n.prototype.head,Pl&&(n.prototype[Pl]=au),n},kr=Er();ur._=kr,r=function(){return kr}.call(e,n,e,o),!(r!==ot&&(o.exports=r))}).call(this)}).call(e,function(){return this}(),n(76)(t))},function(t,e,n){function r(t){return o(t,i|a)}var o=n(117),i=1,a=4;t.exports=r},function(t,e,n){function r(t,e,n,S,T,C){var A,M=e&E,I=e&k,P=e&j;if(n&&(A=T?n(t,S,T,C):n(t)),void 0!==A)return A;if(!w(t))return t;var L=_(t);if(L){if(A=g(t),!M)return l(t,A)}else{var B=v(t),q=B==N||B==D;if(b(t))return c(t,M);if(B==R||B==O||q&&!T){if(A=I||q?{}:y(t),!M)return I?p(t,s(A,t)):f(t,u(A,t))}else{if(!Q[B])return T?t:{};A=m(t,B,r,M)}}C||(C=new o);var U=C.get(t);if(U)return U;C.set(t,A);var V=P?I?d:h:I?keysIn:x,F=L?void 0:V(t);return i(F||t,function(o,i){F&&(i=o,o=t[i]),a(A,i,r(o,e,n,i,t,C))}),A}var o=n(40),i=n(118),a=n(102),u=n(119),s=n(123),c=n(75),l=n(80),f=n(124),p=n(128),h=n(131),d=n(133),v=n(134),g=n(139),m=n(140),y=n(81),_=n(89),b=n(93),w=n(32),x=n(120),E=1,k=2,j=4,O="[object Arguments]",S="[object Array]",T="[object Boolean]",C="[object Date]",A="[object Error]",N="[object Function]",D="[object GeneratorFunction]",M="[object Map]",I="[object Number]",R="[object Object]",P="[object RegExp]",L="[object Set]",B="[object String]",q="[object Symbol]",U="[object WeakMap]",V="[object ArrayBuffer]",F="[object DataView]",z="[object Float32Array]",H="[object Float64Array]",W="[object Int8Array]",K="[object Int16Array]",$="[object Int32Array]",G="[object Uint8Array]",J="[object Uint8ClampedArray]",Y="[object Uint16Array]",X="[object Uint32Array]",Q={};Q[O]=Q[S]=Q[V]=Q[F]=Q[T]=Q[C]=Q[z]=Q[H]=Q[W]=Q[K]=Q[$]=Q[M]=Q[I]=Q[R]=Q[P]=Q[L]=Q[B]=Q[q]=Q[G]=Q[J]=Q[Y]=Q[X]=!0,Q[A]=Q[N]=Q[U]=!1,t.exports=r},function(t,e){function n(t,e){for(var n=-1,r=null==t?0:t.length;++np))return!1;var d=l.get(t);if(d&&l.get(e))return d==e;var v=-1,g=!0,m=n&s?new o:void 0;for(l.set(t,e),l.set(e,t);++v=e?t:e)),t}t.exports=n},function(t,e,n){function r(t){var e=o(t),n=e%1;return e===e?n?e-n:e:0}var o=n(196);t.exports=r},function(t,e,n){function r(t){if(!t)return 0===t?t:0;if(t=o(t),t===i||t===-i){var e=t<0?-1:1;return e*a}return t===t?t:0}var o=n(197),i=1/0,a=1.7976931348623157e308;t.exports=r},function(t,e,n){function r(t){if("number"==typeof t)return t;if(i(t))return a;if(o(t)){var e="function"==typeof t.valueOf?t.valueOf():t;t=o(e)?e+"":e}if("string"!=typeof t)return 0===t?t:+t;t=t.replace(u,"");var n=c.test(t);return n||l.test(t)?f(t.slice(2),n?2:8):s.test(t)?a:+t}var o=n(32),i=n(175),a=NaN,u=/^\s+|\s+$/g,s=/^[-+]0x[0-9a-f]+$/i,c=/^0b[01]+$/i,l=/^0o[0-7]+$/i,f=parseInt;t.exports=r},function(t,e,n){function r(t){if(null==t)return!0;if(s(t)&&(u(t)||"string"==typeof t||"function"==typeof t.splice||c(t)||f(t)||a(t)))return!t.length;var e=i(t);if(e==p||e==h)return!t.size;if(l(t))return!o(t).length;for(var n in t)if(v.call(t,n))return!1;return!0}var o=n(121),i=n(134),a=n(86),u=n(89),s=n(91),c=n(93),l=n(85),f=n(96),p="[object Map]",h="[object Set]",d=Object.prototype,v=d.hasOwnProperty;t.exports=r},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}function o(t){if(Array.isArray(t)){for(var e=0,n=Array(t.length);e0&&(r=a.default.apply(void 0,[r].concat(o(n.map(function(e){return t(e)}))))),(0,s.default)(r)});e.default=v},function(t,e,n){function r(){var t=arguments.length;if(!t)return[];for(var e=Array(t-1),n=arguments[0],r=t;r--;)e[r-1]=arguments[r];return o(u(n)?a(n):[n],i(e,1))}var o=n(130),i=n(201),a=n(80),u=n(89);t.exports=r},function(t,e,n){function r(t,e,n,a,u){var s=-1,c=t.length;for(n||(n=i),u||(u=[]);++s0&&n(l)?e>1?r(l,e-1,n,a,u):o(u,l):a||(u[u.length]=l)}return u}var o=n(130),i=n(202);t.exports=r},function(t,e,n){function r(t){return a(t)||i(t)||!!(u&&t&&t[u])}var o=n(27),i=n(86),a=n(89),u=o?o.isConcatSpreadable:void 0;t.exports=r},function(t,e,n){function r(t,e){var n=u(t)?o:i;return n(t,a(e,3))}var o=n(126),i=n(204),a=n(155),u=n(89);t.exports=r},function(t,e,n){function r(t,e){var n=[];return o(t,function(t,r,o){e(t,r,o)&&n.push(t)}),n}var o=n(190);t.exports=r},function(t,e,n){function r(t){return null==t?[]:o(t,i(t))}var o=n(206),i=n(120);t.exports=r},function(t,e,n){function r(t,e){return o(e,function(e){return t[e]})}var o=n(181);t.exports=r},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.default=function(t,e){var n=e.lineNumber,r=e.tagName;return{line:n,message:t,tagName:r,formattedMessage:"Line "+n+" ("+r+") — "+t}}},function(t,e,n){"use strict";function r(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e.default=t,e}function o(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0}),e.registerMJRule=void 0;var i=n(114),a=o(i),u=n(209),s=r(u),c=s;e.registerMJRule=function(t,e){return"function"!=typeof t||1!==t.length?(0,a.default)(!1,"Your rule must be a function and must have one parameter which is the element to validate"):void(e?c[e]=t:c[t.name]=t)};e.default=c},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var r=n(210);Object.keys(r).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(e,t,{enumerable:!0,get:function(){return r[t]}})});var o=n(217);Object.keys(o).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(e,t,{enumerable:!0,get:function(){return o[t]}})});var i=n(218);Object.keys(i).forEach(function(t){"default"!==t&&"__esModule"!==t&&Object.defineProperty(e,t,{enumerable:!0,get:function(){return i[t]}})})},function(t,e,n){"use strict";function r(t){return t&&t.__esModule?t:{default:t}}Object.defineProperty(e,"__esModule",{value:!0}),e.validateAttribute=void 0;var o=n(4),i=n(200),a=r(i),u=n(120),s=r(u),c=n(211),l=r(c),f=n(203),p=r(f),h=n(207),d=r(h),v=["mj-class"];e.validateAttribute=function(t){var e=t.attributes,n=t.tagName,r=o.elements[n];if(r){var i=(0,a.default)((0,s.default)(r.defaultMJMLDefinition.attributes),v),u=(0,p.default)((0,s.default)(e),function(t){return!(0,l.default)(i,t)});if(0!=u.length)return(0,d.default)((u.length>1?"Attributes":"Attribute")+" "+u.join(", ")+" "+(u.length>1?"are illegal":"is illegal"),t)}}},function(t,e,n){function r(t,e,n,r){t=i(t)?t:s(t),n=n&&!r?u(n):0;var l=t.length;return n<0&&(n=c(l+n,0)),a(t)?n<=l&&t.indexOf(e,n)>-1:!!l&&o(t,e,n)>-1}var o=n(212),i=n(91),a=n(216),u=n(195),s=n(205),c=Math.max;t.exports=r},function(t,e,n){function r(t,e,n){return e===e?a(t,e,n):o(t,i,n)}var o=n(213),i=n(214),a=n(215);t.exports=r},function(t,e){function n(t,e,n,r){for(var o=t.length,i=n+(r?1:-1);r?i--:++i/]*)>([^]*?)","gmi")},M=["mj-class","mj-all"],I=function(t){var e=[].concat(M);(0,_.default)(o({},a.default,s.default),function(t,n){var r=t.tagName||n;e.push(r)});var n=(0,S.default)(e,t.replace(/\$/g,"$"));return(0,h.default)(i.endingTags,u.endingTags).forEach(function(t){n=n.replace(D(t),v.default.replaceContentByCdata(t))}),n},R=function t(e,n){if(!e)throw new c.NullElementError("Null element found in mjmlElementParser");var r=n.substr(0,e.startIndex).match(/\n/g),o=r?r.length+1:1,a=e.tagName.toLowerCase(),u=(0,j.default)(v.default.getAttributes(e),function(t){return decodeURIComponent(t)}),s={tagName:a,attributes:u,lineNumber:o};if(i.endingTags.indexOf(a)!==-1){var l=v.default.parseXML(e);s.content=(0,C.default)(l(a).html().trim())}else{var p=v.default.getChildren(e);s.children=p?(0,f.default)((0,m.default)(p,function(t){return t.tagName}).map(function(e){return t(e,n)})):[]}return s},P=function(t){return(0,E.default)((0,f.default)((0,m.default)(v.default.getChildren(t),function(t){return t.tagName})),function(t){var e=v.default.parseXML(t),n=function t(n){var r=(0,w.default)(u.endingTags,n.tagName.toLowerCase());return{attributes:(0,j.default)(v.default.getAttributes(n),function(t){return decodeURIComponent(t)}),children:r?null:(0,f.default)((0,m.default)((0,N.default)(n.childNodes),function(t){return t.tagName})).map(t),content:r?(0,C.default)(e(n.tagName.toLowerCase()).html().trim()):null,tagName:n.tagName.toLowerCase()}};return n(t)})},L=function(t){var e=I(t),n=void 0,r=void 0;try{var o=v.default.parseXML(e);n=o("mjml > mj-body"),r=o("mjml > mj-head"),n.length>0&&(n=n.children().get(0))}catch(t){throw new c.ParseError("Error while parsing the file")}if(!n||n.length<1)throw new c.EmptyMJMLError('No root "" or "" found in the file, or "" doesn\'t contain a child element.');return{tagName:"mjml",children:[{tagName:"mj-head",children:r&&r.length>0?P(r.get(0)):[]},{tagName:"mj-body",children:[R(n,e)]}]}};e.default=L},function(t,e,n){"use strict";Object.defineProperty(e,"__esModule",{value:!0}),e.registerMJHeadElement=e.endingTags=void 0;var r=n(115),o=e.endingTags=[],i=(e.registerMJHeadElement=function(){for(var t=arguments.length,e=Array(t),n=0;n1)a=e[0],s=e[1],u=e[2];else{var c=e[0];a=c.name,s=c.handler,u=c.endingTag}u&&!(0,r.includes)(o,a)&&o.push(a),i[a]=s},{});e.default=i},function(t,e){function n(t){for(var e=-1,n=null==t?0:t.length,r=0,o=[];++e"+t+""))},a.getAttributes=function(t){var e={};return Array.prototype.slice.call(t.attributes).forEach(function(t){return e[t.name]=t.value}),e},a.getChildren=function(t){return t.children},a.replaceContentByCdata=function(t){return"<"+t+"$1>"},a.getHTML=function(t){var e=t()[0];return""+e.documentElement.outerHTML}}else{var c=n(226),l=c.load("",{decodeEntities:!1}),f=function(t,e){return l=l.load(t,e),function(t){return t?l(t):l}};a.parseHTML=function(t){return f(t,{xmlMode:!1,decodeEntities:!1})},a.parseXML=function(t){return f(t,{xmlMode:!0,decodeEntities:!1,withStartIndices:!0})},a.getAttributes=function(t){return t.attribs||{}},a.getChildren=function(t){return t.childNodes},a.replaceContentByCdata=function(t){return"<"+t+"$1>"},a.getHTML=function(t){return t().html()}}e.default=a},function(t,e){"use strict";Object.defineProperty(e,"__esModule",{value:!0});var n="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};e.default=function(){return"object"===("undefined"==typeof window?"undefined":n(window))&&"object"===("undefined"==typeof document?"undefined":n(document))&&9===document.nodeType&&!(window.process&&window.process.type)}},function(t,e,n){var r,o;/*! - * jQuery JavaScript Library v3.2.1 - * https://jquery.com/ - * - * Includes Sizzle.js - * https://sizzlejs.com/ - * - * Copyright JS Foundation and other contributors - * Released under the MIT license - * https://jquery.org/license - * - * Date: 2017-03-20T18:59Z - */ -!function(e,n){"use strict";"object"==typeof t&&"object"==typeof t.exports?t.exports=e.document?n(e,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return n(t)}:n(e)}("undefined"!=typeof window?window:this,function(n,i){"use strict";function a(t,e){e=e||at;var n=e.createElement("script");n.text=t,e.head.appendChild(n).parentNode.removeChild(n)}function u(t){var e=!!t&&"length"in t&&t.length,n=_t.type(t);return"function"!==n&&!_t.isWindow(t)&&("array"===n||0===e||"number"==typeof e&&e>0&&e-1 in t)}function s(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()}function c(t,e,n){return _t.isFunction(e)?_t.grep(t,function(t,r){return!!e.call(t,r,t)!==n}):e.nodeType?_t.grep(t,function(t){return t===e!==n}):"string"!=typeof e?_t.grep(t,function(t){return ft.call(e,t)>-1!==n}):Ct.test(e)?_t.filter(e,t,n):(e=_t.filter(e,t),_t.grep(t,function(t){return ft.call(e,t)>-1!==n&&1===t.nodeType}))}function l(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}function f(t){var e={};return _t.each(t.match(Rt)||[],function(t,n){e[n]=!0}),e}function p(t){return t}function h(t){throw t}function d(t,e,n,r){var o;try{t&&_t.isFunction(o=t.promise)?o.call(t).done(e).fail(n):t&&_t.isFunction(o=t.then)?o.call(t,e,n):e.apply(void 0,[t].slice(r))}catch(t){n.apply(void 0,[t])}}function v(){at.removeEventListener("DOMContentLoaded",v),n.removeEventListener("load",v),_t.ready()}function g(){this.expando=_t.expando+g.uid++}function m(t){return"true"===t||"false"!==t&&("null"===t?null:t===+t+""?+t:Ft.test(t)?JSON.parse(t):t)}function y(t,e,n){var r;if(void 0===n&&1===t.nodeType)if(r="data-"+e.replace(zt,"-$&").toLowerCase(),n=t.getAttribute(r),"string"==typeof n){try{n=m(n)}catch(t){}Vt.set(t,e,n)}else n=void 0;return n}function _(t,e,n,r){var o,i=1,a=20,u=r?function(){return r.cur()}:function(){return _t.css(t,e,"")},s=u(),c=n&&n[3]||(_t.cssNumber[e]?"":"px"),l=(_t.cssNumber[e]||"px"!==c&&+s)&&Wt.exec(_t.css(t,e));if(l&&l[3]!==c){c=c||l[3],n=n||[],l=+s||1;do i=i||".5",l/=i,_t.style(t,e,l+c);while(i!==(i=u()/s)&&1!==i&&--a)}return n&&(l=+l||+s||0,o=n[1]?l+(n[1]+1)*n[2]:+n[2],r&&(r.unit=c,r.start=l,r.end=o)),o}function b(t){var e,n=t.ownerDocument,r=t.nodeName,o=Jt[r];return o?o:(e=n.body.appendChild(n.createElement(r)),o=_t.css(e,"display"),e.parentNode.removeChild(e),"none"===o&&(o="block"),Jt[r]=o,o)}function w(t,e){for(var n,r,o=[],i=0,a=t.length;i-1)o&&o.push(i);else if(c=_t.contains(i.ownerDocument,i),a=x(f.appendChild(i),"script"),c&&E(a),n)for(l=0;i=a[l++];)Qt.test(i.type||"")&&n.push(i);return f}function j(){return!0}function O(){return!1}function S(){try{return at.activeElement}catch(t){}}function T(t,e,n,r,o,i){var a,u;if("object"==typeof e){"string"!=typeof n&&(r=r||n,n=void 0);for(u in e)T(t,u,n,r,e[u],i);return t}if(null==r&&null==o?(o=n,r=n=void 0):null==o&&("string"==typeof n?(o=r,r=void 0):(o=r,r=n,n=void 0)),o===!1)o=O;else if(!o)return t;return 1===i&&(a=o,o=function(t){return _t().off(t),a.apply(this,arguments)},o.guid=a.guid||(a.guid=_t.guid++)),t.each(function(){_t.event.add(this,e,o,r,n)})}function C(t,e){return s(t,"table")&&s(11!==e.nodeType?e:e.firstChild,"tr")?_t(">tbody",t)[0]||t:t}function A(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function N(t){var e=se.exec(t.type);return e?t.type=e[1]:t.removeAttribute("type"),t}function D(t,e){var n,r,o,i,a,u,s,c;if(1===e.nodeType){if(Ut.hasData(t)&&(i=Ut.access(t),a=Ut.set(e,i),c=i.events)){delete a.handle,a.events={};for(o in c)for(n=0,r=c[o].length;n1&&"string"==typeof d&&!mt.checkClone&&ue.test(d))return t.each(function(o){var i=t.eq(o);v&&(e[0]=d.call(this,o,i.html())),I(i,e,n,r)});if(p&&(o=k(e,t[0].ownerDocument,!1,t,r),i=o.firstChild,1===o.childNodes.length&&(o=i),i||r)){for(u=_t.map(x(o,"script"),A),s=u.length;f=0&&nE.cacheLength&&delete t[e.shift()],t[n+" "]=r}var e=[];return t}function r(t){return t[U]=!0,t}function o(t){var e=M.createElement("fieldset");try{return!!t(e)}catch(t){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function i(t,e){for(var n=t.split("|"),r=n.length;r--;)E.attrHandle[n[r]]=e}function a(t,e){var n=e&&t,r=n&&1===t.nodeType&&1===e.nodeType&&t.sourceIndex-e.sourceIndex;if(r)return r;if(n)for(;n=n.nextSibling;)if(n===e)return-1;return t?1:-1}function u(t){return function(e){var n=e.nodeName.toLowerCase();return"input"===n&&e.type===t}}function s(t){return function(e){var n=e.nodeName.toLowerCase();return("input"===n||"button"===n)&&e.type===t}}function c(t){return function(e){return"form"in e?e.parentNode&&e.disabled===!1?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&kt(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function l(t){return r(function(e){return e=+e,r(function(n,r){for(var o,i=t([],n.length,e),a=i.length;a--;)n[o=i[a]]&&(n[o]=!(r[o]=n[o]))})})}function f(t){return t&&"undefined"!=typeof t.getElementsByTagName&&t}function p(){}function h(t){for(var e=0,n=t.length,r="";e1?function(e,n,r){for(var o=t.length;o--;)if(!t[o](e,n,r))return!1;return!0}:t[0]}function g(t,n,r){for(var o=0,i=n.length;o-1&&(r[c]=!(a[c]=f))}}else _=m(_===a?_.splice(d,_.length):_),i?i(null,a,_,s):Q.apply(a,_)})}function _(t){for(var e,n,r,o=t.length,i=E.relative[t[0].type],a=i||E.relative[" "],u=i?1:0,s=d(function(t){return t===e},a,!0),c=d(function(t){return tt(e,t)>-1},a,!0),l=[function(t,n,r){var o=!i&&(r||n!==C)||((e=n).nodeType?s(t,n,r):c(t,n,r));return e=null,o}];u1&&v(l),u>1&&h(t.slice(0,u-1).concat({value:" "===t[u-2].type?"*":""})).replace(ut,"$1"),n,u0,i=t.length>0,a=function(r,a,u,s,c){var l,f,p,h=0,d="0",v=r&&[],g=[],y=C,_=r||i&&E.find.TAG("*",c),b=F+=null==y?1:Math.random()||.1,w=_.length;for(c&&(C=a===M||a||c);d!==w&&null!=(l=_[d]);d++){if(i&&l){for(f=0,a||l.ownerDocument===M||(D(l),u=!R);p=t[f++];)if(p(l,a||M,u)){s.push(l);break}c&&(F=b)}o&&((l=!p&&l)&&h--,r&&v.push(l))}if(h+=d,o&&d!==h){for(f=0;p=n[f++];)p(v,g,a,u);if(r){if(h>0)for(;d--;)v[d]||g[d]||(g[d]=Y.call(s));g=m(g)}Q.apply(s,g),c&&!r&&g.length>0&&h+n.length>1&&e.uniqueSort(s)}return c&&(F=b,C=y),v};return o?r(a):a}var w,x,E,k,j,O,S,T,C,A,N,D,M,I,R,P,L,B,q,U="sizzle"+1*new Date,V=t.document,F=0,z=0,H=n(),W=n(),K=n(),$=function(t,e){return t===e&&(N=!0),0},G={}.hasOwnProperty,J=[],Y=J.pop,X=J.push,Q=J.push,Z=J.slice,tt=function(t,e){for(var n=0,r=t.length;n+~]|"+nt+")"+nt+"*"),lt=new RegExp("="+nt+"*([^\\]'\"]*?)"+nt+"*\\]","g"),ft=new RegExp(it),pt=new RegExp("^"+rt+"$"),ht={ID:new RegExp("^#("+rt+")"),CLASS:new RegExp("^\\.("+rt+")"),TAG:new RegExp("^("+rt+"|[*])"),ATTR:new RegExp("^"+ot),PSEUDO:new RegExp("^"+it),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+nt+"*(even|odd|(([+-]|)(\\d*)n|)"+nt+"*(?:([+-]|)"+nt+"*(\\d+)|))"+nt+"*\\)|)","i"),bool:new RegExp("^(?:"+et+")$","i"),needsContext:new RegExp("^"+nt+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+nt+"*((?:-\\d)?\\d*)"+nt+"*\\)|)(?=[^-]|$)","i")},dt=/^(?:input|select|textarea|button)$/i,vt=/^h\d$/i,gt=/^[^{]+\{\s*\[native \w/,mt=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,yt=/[+~]/,_t=new RegExp("\\\\([\\da-f]{1,6}"+nt+"?|("+nt+")|.)","ig"),bt=function(t,e,n){var r="0x"+e-65536;return r!==r||n?e:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},wt=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,xt=function(t,e){return e?"\0"===t?"�":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t},Et=function(){D()},kt=d(function(t){return t.disabled===!0&&("form"in t||"label"in t)},{dir:"parentNode",next:"legend"});try{Q.apply(J=Z.call(V.childNodes),V.childNodes),J[V.childNodes.length].nodeType}catch(t){Q={apply:J.length?function(t,e){X.apply(t,Z.call(e))}:function(t,e){for(var n=t.length,r=0;t[n++]=e[r++];);t.length=n-1}}}x=e.support={},j=e.isXML=function(t){var e=t&&(t.ownerDocument||t).documentElement;return!!e&&"HTML"!==e.nodeName},D=e.setDocument=function(t){var e,n,r=t?t.ownerDocument||t:V;return r!==M&&9===r.nodeType&&r.documentElement?(M=r,I=M.documentElement,R=!j(M),V!==M&&(n=M.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",Et,!1):n.attachEvent&&n.attachEvent("onunload",Et)),x.attributes=o(function(t){return t.className="i",!t.getAttribute("className")}),x.getElementsByTagName=o(function(t){return t.appendChild(M.createComment("")),!t.getElementsByTagName("*").length}),x.getElementsByClassName=gt.test(M.getElementsByClassName),x.getById=o(function(t){return I.appendChild(t).id=U,!M.getElementsByName||!M.getElementsByName(U).length}),x.getById?(E.filter.ID=function(t){var e=t.replace(_t,bt);return function(t){return t.getAttribute("id")===e}},E.find.ID=function(t,e){if("undefined"!=typeof e.getElementById&&R){var n=e.getElementById(t);return n?[n]:[]}}):(E.filter.ID=function(t){var e=t.replace(_t,bt);return function(t){var n="undefined"!=typeof t.getAttributeNode&&t.getAttributeNode("id");return n&&n.value===e}},E.find.ID=function(t,e){if("undefined"!=typeof e.getElementById&&R){var n,r,o,i=e.getElementById(t);if(i){if(n=i.getAttributeNode("id"),n&&n.value===t)return[i];for(o=e.getElementsByName(t),r=0;i=o[r++];)if(n=i.getAttributeNode("id"),n&&n.value===t)return[i]}return[]}}),E.find.TAG=x.getElementsByTagName?function(t,e){return"undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t):x.qsa?e.querySelectorAll(t):void 0}:function(t,e){var n,r=[],o=0,i=e.getElementsByTagName(t);if("*"===t){for(;n=i[o++];)1===n.nodeType&&r.push(n);return r}return i},E.find.CLASS=x.getElementsByClassName&&function(t,e){if("undefined"!=typeof e.getElementsByClassName&&R)return e.getElementsByClassName(t)},L=[],P=[],(x.qsa=gt.test(M.querySelectorAll))&&(o(function(t){I.appendChild(t).innerHTML="",t.querySelectorAll("[msallowcapture^='']").length&&P.push("[*^$]="+nt+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||P.push("\\["+nt+"*(?:value|"+et+")"),t.querySelectorAll("[id~="+U+"-]").length||P.push("~="),t.querySelectorAll(":checked").length||P.push(":checked"),t.querySelectorAll("a#"+U+"+*").length||P.push(".#.+[+~]")}),o(function(t){t.innerHTML="";var e=M.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&P.push("name"+nt+"*[*^$|!~]?="),2!==t.querySelectorAll(":enabled").length&&P.push(":enabled",":disabled"),I.appendChild(t).disabled=!0,2!==t.querySelectorAll(":disabled").length&&P.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),P.push(",.*:")})),(x.matchesSelector=gt.test(B=I.matches||I.webkitMatchesSelector||I.mozMatchesSelector||I.oMatchesSelector||I.msMatchesSelector))&&o(function(t){x.disconnectedMatch=B.call(t,"*"),B.call(t,"[s!='']:x"),L.push("!=",it)}),P=P.length&&new RegExp(P.join("|")),L=L.length&&new RegExp(L.join("|")),e=gt.test(I.compareDocumentPosition),q=e||gt.test(I.contains)?function(t,e){var n=9===t.nodeType?t.documentElement:t,r=e&&e.parentNode;return t===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):t.compareDocumentPosition&&16&t.compareDocumentPosition(r)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},$=e?function(t,e){if(t===e)return N=!0,0;var n=!t.compareDocumentPosition-!e.compareDocumentPosition;return n?n:(n=(t.ownerDocument||t)===(e.ownerDocument||e)?t.compareDocumentPosition(e):1,1&n||!x.sortDetached&&e.compareDocumentPosition(t)===n?t===M||t.ownerDocument===V&&q(V,t)?-1:e===M||e.ownerDocument===V&&q(V,e)?1:A?tt(A,t)-tt(A,e):0:4&n?-1:1)}:function(t,e){if(t===e)return N=!0,0;var n,r=0,o=t.parentNode,i=e.parentNode,u=[t],s=[e];if(!o||!i)return t===M?-1:e===M?1:o?-1:i?1:A?tt(A,t)-tt(A,e):0;if(o===i)return a(t,e);for(n=t;n=n.parentNode;)u.unshift(n);for(n=e;n=n.parentNode;)s.unshift(n);for(;u[r]===s[r];)r++;return r?a(u[r],s[r]):u[r]===V?-1:s[r]===V?1:0},M):M},e.matches=function(t,n){return e(t,null,null,n)},e.matchesSelector=function(t,n){if((t.ownerDocument||t)!==M&&D(t),n=n.replace(lt,"='$1']"),x.matchesSelector&&R&&!K[n+" "]&&(!L||!L.test(n))&&(!P||!P.test(n)))try{var r=B.call(t,n);if(r||x.disconnectedMatch||t.document&&11!==t.document.nodeType)return r}catch(t){}return e(n,M,null,[t]).length>0},e.contains=function(t,e){return(t.ownerDocument||t)!==M&&D(t),q(t,e)},e.attr=function(t,e){(t.ownerDocument||t)!==M&&D(t);var n=E.attrHandle[e.toLowerCase()],r=n&&G.call(E.attrHandle,e.toLowerCase())?n(t,e,!R):void 0;return void 0!==r?r:x.attributes||!R?t.getAttribute(e):(r=t.getAttributeNode(e))&&r.specified?r.value:null},e.escape=function(t){return(t+"").replace(wt,xt)},e.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},e.uniqueSort=function(t){var e,n=[],r=0,o=0;if(N=!x.detectDuplicates,A=!x.sortStable&&t.slice(0),t.sort($),N){for(;e=t[o++];)e===t[o]&&(r=n.push(o));for(;r--;)t.splice(n[r],1)}return A=null,t},k=e.getText=function(t){var e,n="",r=0,o=t.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)n+=k(t)}else if(3===o||4===o)return t.nodeValue}else for(;e=t[r++];)n+=k(e);return n},E=e.selectors={cacheLength:50,createPseudo:r,match:ht,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(_t,bt),t[3]=(t[3]||t[4]||t[5]||"").replace(_t,bt),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||e.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&e.error(t[0]),t},PSEUDO:function(t){var e,n=!t[6]&&t[2];return ht.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":n&&ft.test(n)&&(e=O(n,!0))&&(e=n.indexOf(")",n.length-e)-n.length)&&(t[0]=t[0].slice(0,e),t[2]=n.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(_t,bt).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=H[t+" "];return e||(e=new RegExp("(^|"+nt+")"+t+"("+nt+"|$)"))&&H(t,function(t){return e.test("string"==typeof t.className&&t.className||"undefined"!=typeof t.getAttribute&&t.getAttribute("class")||"")})},ATTR:function(t,n,r){return function(o){var i=e.attr(o,t);return null==i?"!="===n:!n||(i+="","="===n?i===r:"!="===n?i!==r:"^="===n?r&&0===i.indexOf(r):"*="===n?r&&i.indexOf(r)>-1:"$="===n?r&&i.slice(-r.length)===r:"~="===n?(" "+i.replace(at," ")+" ").indexOf(r)>-1:"|="===n&&(i===r||i.slice(0,r.length+1)===r+"-"))}},CHILD:function(t,e,n,r,o){var i="nth"!==t.slice(0,3),a="last"!==t.slice(-4),u="of-type"===e;return 1===r&&0===o?function(t){return!!t.parentNode}:function(e,n,s){var c,l,f,p,h,d,v=i!==a?"nextSibling":"previousSibling",g=e.parentNode,m=u&&e.nodeName.toLowerCase(),y=!s&&!u,_=!1;if(g){if(i){for(;v;){for(p=e;p=p[v];)if(u?p.nodeName.toLowerCase()===m:1===p.nodeType)return!1;d=v="only"===t&&!d&&"nextSibling"}return!0}if(d=[a?g.firstChild:g.lastChild],a&&y){for(p=g,f=p[U]||(p[U]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),c=l[t]||[],h=c[0]===F&&c[1],_=h&&c[2],p=h&&g.childNodes[h];p=++h&&p&&p[v]||(_=h=0)||d.pop();)if(1===p.nodeType&&++_&&p===e){l[t]=[F,h,_];break}}else if(y&&(p=e,f=p[U]||(p[U]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),c=l[t]||[],h=c[0]===F&&c[1],_=h),_===!1)for(;(p=++h&&p&&p[v]||(_=h=0)||d.pop())&&((u?p.nodeName.toLowerCase()!==m:1!==p.nodeType)||!++_||(y&&(f=p[U]||(p[U]={}),l=f[p.uniqueID]||(f[p.uniqueID]={}),l[t]=[F,_]),p!==e)););return _-=o,_===r||_%r===0&&_/r>=0}}},PSEUDO:function(t,n){var o,i=E.pseudos[t]||E.setFilters[t.toLowerCase()]||e.error("unsupported pseudo: "+t);return i[U]?i(n):i.length>1?(o=[t,t,"",n],E.setFilters.hasOwnProperty(t.toLowerCase())?r(function(t,e){for(var r,o=i(t,n),a=o.length;a--;)r=tt(t,o[a]),t[r]=!(e[r]=o[a])}):function(t){return i(t,0,o)}):i}},pseudos:{not:r(function(t){var e=[],n=[],o=S(t.replace(ut,"$1"));return o[U]?r(function(t,e,n,r){for(var i,a=o(t,null,r,[]),u=t.length;u--;)(i=a[u])&&(t[u]=!(e[u]=i))}):function(t,r,i){return e[0]=t,o(e,null,i,n),e[0]=null,!n.pop()}}),has:r(function(t){return function(n){return e(t,n).length>0}}),contains:r(function(t){return t=t.replace(_t,bt),function(e){return(e.textContent||e.innerText||k(e)).indexOf(t)>-1}}),lang:r(function(t){return pt.test(t||"")||e.error("unsupported lang: "+t),t=t.replace(_t,bt).toLowerCase(),function(e){var n;do if(n=R?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return n=n.toLowerCase(),n===t||0===n.indexOf(t+"-");while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var n=t.location&&t.location.hash;return n&&n.slice(1)===e.id},root:function(t){return t===I},focus:function(t){return t===M.activeElement&&(!M.hasFocus||M.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:c(!1),disabled:c(!0),checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,t.selected===!0},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!E.pseudos.empty(t)},header:function(t){return vt.test(t.nodeName)},input:function(t){return dt.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:l(function(){return[0]}),last:l(function(t,e){return[e-1]}),eq:l(function(t,e,n){return[n<0?n+e:n]}),even:l(function(t,e){for(var n=0;n=0;)t.push(r);return t}),gt:l(function(t,e,n){for(var r=n<0?n+e:n;++r2&&"ID"===(a=i[0]).type&&9===e.nodeType&&R&&E.relative[i[1].type]){if(e=(E.find.ID(a.matches[0].replace(_t,bt),e)||[])[0],!e)return n;c&&(e=e.parentNode),t=t.slice(i.shift().value.length)}for(o=ht.needsContext.test(t)?0:i.length;o--&&(a=i[o],!E.relative[u=a.type]);)if((s=E.find[u])&&(r=s(a.matches[0].replace(_t,bt),yt.test(i[0].type)&&f(e.parentNode)||e))){if(i.splice(o,1),t=r.length&&h(i),!t)return Q.apply(n,r),n;break}}return(c||S(t,l))(r,e,!R,n,!e||yt.test(t)&&f(e.parentNode)||e),n},x.sortStable=U.split("").sort($).join("")===U,x.detectDuplicates=!!N,D(),x.sortDetached=o(function(t){return 1&t.compareDocumentPosition(M.createElement("fieldset"))}),o(function(t){return t.innerHTML="","#"===t.firstChild.getAttribute("href")})||i("type|href|height|width",function(t,e,n){if(!n)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}),x.attributes&&o(function(t){return t.innerHTML="",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")})||i("value",function(t,e,n){if(!n&&"input"===t.nodeName.toLowerCase())return t.defaultValue}),o(function(t){return null==t.getAttribute("disabled")})||i(et,function(t,e,n){var r;if(!n)return t[e]===!0?e.toLowerCase():(r=t.getAttributeNode(e))&&r.specified?r.value:null}),e}(n);_t.find=kt,_t.expr=kt.selectors,_t.expr[":"]=_t.expr.pseudos,_t.uniqueSort=_t.unique=kt.uniqueSort,_t.text=kt.getText,_t.isXMLDoc=kt.isXML,_t.contains=kt.contains,_t.escapeSelector=kt.escape;var jt=function(t,e,n){for(var r=[],o=void 0!==n;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(o&&_t(t).is(n))break;r.push(t)}return r},Ot=function(t,e){for(var n=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&n.push(t);return n},St=_t.expr.match.needsContext,Tt=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i,Ct=/^.[^:#\[\.,]*$/;_t.filter=function(t,e,n){var r=e[0];return n&&(t=":not("+t+")"),1===e.length&&1===r.nodeType?_t.find.matchesSelector(r,t)?[r]:[]:_t.find.matches(t,_t.grep(e,function(t){return 1===t.nodeType}))},_t.fn.extend({find:function(t){var e,n,r=this.length,o=this;if("string"!=typeof t)return this.pushStack(_t(t).filter(function(){for(e=0;e1?_t.uniqueSort(n):n},filter:function(t){return this.pushStack(c(this,t||[],!1))},not:function(t){return this.pushStack(c(this,t||[],!0))},is:function(t){return!!c(this,"string"==typeof t&&St.test(t)?_t(t):t||[],!1).length}});var At,Nt=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/,Dt=_t.fn.init=function(t,e,n){var r,o;if(!t)return this;if(n=n||At,"string"==typeof t){if(r="<"===t[0]&&">"===t[t.length-1]&&t.length>=3?[null,t,null]:Nt.exec(t),!r||!r[1]&&e)return!e||e.jquery?(e||n).find(t):this.constructor(e).find(t);if(r[1]){if(e=e instanceof _t?e[0]:e,_t.merge(this,_t.parseHTML(r[1],e&&e.nodeType?e.ownerDocument||e:at,!0)),Tt.test(r[1])&&_t.isPlainObject(e))for(r in e)_t.isFunction(this[r])?this[r](e[r]):this.attr(r,e[r]);return this}return o=at.getElementById(r[2]),o&&(this[0]=o,this.length=1),this}return t.nodeType?(this[0]=t,this.length=1,this):_t.isFunction(t)?void 0!==n.ready?n.ready(t):t(_t):_t.makeArray(t,this)};Dt.prototype=_t.fn,At=_t(at);var Mt=/^(?:parents|prev(?:Until|All))/,It={children:!0,contents:!0,next:!0,prev:!0};_t.fn.extend({has:function(t){var e=_t(t,this),n=e.length;return this.filter(function(){for(var t=0;t-1:1===n.nodeType&&_t.find.matchesSelector(n,t))){i.push(n);break}return this.pushStack(i.length>1?_t.uniqueSort(i):i)},index:function(t){return t?"string"==typeof t?ft.call(_t(t),this[0]):ft.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(_t.uniqueSort(_t.merge(this.get(),_t(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),_t.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return jt(t,"parentNode")},parentsUntil:function(t,e,n){return jt(t,"parentNode",n)},next:function(t){return l(t,"nextSibling")},prev:function(t){return l(t,"previousSibling")},nextAll:function(t){return jt(t,"nextSibling")},prevAll:function(t){return jt(t,"previousSibling")},nextUntil:function(t,e,n){return jt(t,"nextSibling",n)},prevUntil:function(t,e,n){return jt(t,"previousSibling",n)},siblings:function(t){return Ot((t.parentNode||{}).firstChild,t)},children:function(t){return Ot(t.firstChild)},contents:function(t){return s(t,"iframe")?t.contentDocument:(s(t,"template")&&(t=t.content||t),_t.merge([],t.childNodes))}},function(t,e){_t.fn[t]=function(n,r){var o=_t.map(this,e,n);return"Until"!==t.slice(-5)&&(r=n),r&&"string"==typeof r&&(o=_t.filter(r,o)),this.length>1&&(It[t]||_t.uniqueSort(o),Mt.test(t)&&o.reverse()),this.pushStack(o)}});var Rt=/[^\x20\t\r\n\f]+/g;_t.Callbacks=function(t){t="string"==typeof t?f(t):_t.extend({},t);var e,n,r,o,i=[],a=[],u=-1,s=function(){for(o=o||t.once,r=e=!0;a.length;u=-1)for(n=a.shift();++u-1;)i.splice(n,1),n<=u&&u--}),this},has:function(t){return t?_t.inArray(t,i)>-1:i.length>0},empty:function(){return i&&(i=[]),this},disable:function(){return o=a=[],i=n="",this},disabled:function(){return!i},lock:function(){return o=a=[],n||e||(i=n=""),this},locked:function(){return!!o},fireWith:function(t,n){return o||(n=n||[],n=[t,n.slice?n.slice():n],a.push(n),e||s()),this},fire:function(){return c.fireWith(this,arguments),this},fired:function(){return!!r}};return c},_t.extend({Deferred:function(t){var e=[["notify","progress",_t.Callbacks("memory"),_t.Callbacks("memory"),2],["resolve","done",_t.Callbacks("once memory"),_t.Callbacks("once memory"),0,"resolved"],["reject","fail",_t.Callbacks("once memory"),_t.Callbacks("once memory"),1,"rejected"]],r="pending",o={state:function(){return r},always:function(){return i.done(arguments).fail(arguments),this},catch:function(t){return o.then(null,t)},pipe:function(){var t=arguments;return _t.Deferred(function(n){_t.each(e,function(e,r){var o=_t.isFunction(t[r[4]])&&t[r[4]];i[r[1]](function(){var t=o&&o.apply(this,arguments);t&&_t.isFunction(t.promise)?t.promise().progress(n.notify).done(n.resolve).fail(n.reject):n[r[0]+"With"](this,o?[t]:arguments)})}),t=null}).promise()},then:function(t,r,o){function i(t,e,r,o){return function(){var u=this,s=arguments,c=function(){var n,c;if(!(t=a&&(r!==h&&(u=void 0,s=[n]),e.rejectWith(u,s))}};t?l():(_t.Deferred.getStackHook&&(l.stackTrace=_t.Deferred.getStackHook()),n.setTimeout(l))}}var a=0;return _t.Deferred(function(n){e[0][3].add(i(0,n,_t.isFunction(o)?o:p,n.notifyWith)),e[1][3].add(i(0,n,_t.isFunction(t)?t:p)),e[2][3].add(i(0,n,_t.isFunction(r)?r:h))}).promise()},promise:function(t){return null!=t?_t.extend(t,o):o}},i={};return _t.each(e,function(t,n){var a=n[2],u=n[5];o[n[1]]=a.add,u&&a.add(function(){r=u},e[3-t][2].disable,e[0][2].lock),a.add(n[3].fire),i[n[0]]=function(){return i[n[0]+"With"](this===i?void 0:this,arguments),this},i[n[0]+"With"]=a.fireWith}),o.promise(i),t&&t.call(i,i),i},when:function(t){var e=arguments.length,n=e,r=Array(n),o=st.call(arguments),i=_t.Deferred(),a=function(t){return function(n){r[t]=this,o[t]=arguments.length>1?st.call(arguments):n,--e||i.resolveWith(r,o)}};if(e<=1&&(d(t,i.done(a(n)).resolve,i.reject,!e),"pending"===i.state()||_t.isFunction(o[n]&&o[n].then)))return i.then();for(;n--;)d(o[n],a(n),i.reject);return i.promise()}});var Pt=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;_t.Deferred.exceptionHook=function(t,e){n.console&&n.console.warn&&t&&Pt.test(t.name)&&n.console.warn("jQuery.Deferred exception: "+t.message,t.stack,e)},_t.readyException=function(t){n.setTimeout(function(){throw t})};var Lt=_t.Deferred();_t.fn.ready=function(t){return Lt.then(t).catch(function(t){_t.readyException(t)}),this},_t.extend({isReady:!1,readyWait:1,ready:function(t){(t===!0?--_t.readyWait:_t.isReady)||(_t.isReady=!0,t!==!0&&--_t.readyWait>0||Lt.resolveWith(at,[_t]))}}),_t.ready.then=Lt.then,"complete"===at.readyState||"loading"!==at.readyState&&!at.documentElement.doScroll?n.setTimeout(_t.ready):(at.addEventListener("DOMContentLoaded",v),n.addEventListener("load",v));var Bt=function(t,e,n,r,o,i,a){var u=0,s=t.length,c=null==n;if("object"===_t.type(n)){o=!0;for(u in n)Bt(t,e,u,n[u],!0,i,a)}else if(void 0!==r&&(o=!0,_t.isFunction(r)||(a=!0),c&&(a?(e.call(t,r),e=null):(c=e,e=function(t,e,n){return c.call(_t(t),n)})),e))for(;u1,null,!0)},removeData:function(t){return this.each(function(){Vt.remove(this,t)})}}),_t.extend({queue:function(t,e,n){var r;if(t)return e=(e||"fx")+"queue",r=Ut.get(t,e),n&&(!r||Array.isArray(n)?r=Ut.access(t,e,_t.makeArray(n)):r.push(n)),r||[]},dequeue:function(t,e){e=e||"fx";var n=_t.queue(t,e),r=n.length,o=n.shift(),i=_t._queueHooks(t,e),a=function(){_t.dequeue(t,e)};"inprogress"===o&&(o=n.shift(),r--),o&&("fx"===e&&n.unshift("inprogress"),delete i.stop,o.call(t,a,i)),!r&&i&&i.empty.fire()},_queueHooks:function(t,e){var n=e+"queueHooks";return Ut.get(t,n)||Ut.access(t,n,{empty:_t.Callbacks("once memory").add(function(){Ut.remove(t,[e+"queue",n])})})}}),_t.fn.extend({queue:function(t,e){var n=2;return"string"!=typeof t&&(e=t,t="fx",n--),arguments.length\x20\t\r\n\f]+)/i,Qt=/^$|\/(?:java|ecma)script/i,Zt={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};Zt.optgroup=Zt.option,Zt.tbody=Zt.tfoot=Zt.colgroup=Zt.caption=Zt.thead, -Zt.th=Zt.td;var te=/<|&#?\w+;/;!function(){var t=at.createDocumentFragment(),e=t.appendChild(at.createElement("div")),n=at.createElement("input");n.setAttribute("type","radio"),n.setAttribute("checked","checked"),n.setAttribute("name","t"),e.appendChild(n),mt.checkClone=e.cloneNode(!0).cloneNode(!0).lastChild.checked,e.innerHTML="",mt.noCloneChecked=!!e.cloneNode(!0).lastChild.defaultValue}();var ee=at.documentElement,ne=/^key/,re=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,oe=/^([^.]*)(?:\.(.+)|)/;_t.event={global:{},add:function(t,e,n,r,o){var i,a,u,s,c,l,f,p,h,d,v,g=Ut.get(t);if(g)for(n.handler&&(i=n,n=i.handler,o=i.selector),o&&_t.find.matchesSelector(ee,o),n.guid||(n.guid=_t.guid++),(s=g.events)||(s=g.events={}),(a=g.handle)||(a=g.handle=function(e){return"undefined"!=typeof _t&&_t.event.triggered!==e.type?_t.event.dispatch.apply(t,arguments):void 0}),e=(e||"").match(Rt)||[""],c=e.length;c--;)u=oe.exec(e[c])||[],h=v=u[1],d=(u[2]||"").split(".").sort(),h&&(f=_t.event.special[h]||{},h=(o?f.delegateType:f.bindType)||h,f=_t.event.special[h]||{},l=_t.extend({type:h,origType:v,data:r,handler:n,guid:n.guid,selector:o,needsContext:o&&_t.expr.match.needsContext.test(o),namespace:d.join(".")},i),(p=s[h])||(p=s[h]=[],p.delegateCount=0,f.setup&&f.setup.call(t,r,d,a)!==!1||t.addEventListener&&t.addEventListener(h,a)),f.add&&(f.add.call(t,l),l.handler.guid||(l.handler.guid=n.guid)),o?p.splice(p.delegateCount++,0,l):p.push(l),_t.event.global[h]=!0)},remove:function(t,e,n,r,o){var i,a,u,s,c,l,f,p,h,d,v,g=Ut.hasData(t)&&Ut.get(t);if(g&&(s=g.events)){for(e=(e||"").match(Rt)||[""],c=e.length;c--;)if(u=oe.exec(e[c])||[],h=v=u[1],d=(u[2]||"").split(".").sort(),h){for(f=_t.event.special[h]||{},h=(r?f.delegateType:f.bindType)||h,p=s[h]||[],u=u[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=i=p.length;i--;)l=p[i],!o&&v!==l.origType||n&&n.guid!==l.guid||u&&!u.test(l.namespace)||r&&r!==l.selector&&("**"!==r||!l.selector)||(p.splice(i,1),l.selector&&p.delegateCount--,f.remove&&f.remove.call(t,l));a&&!p.length&&(f.teardown&&f.teardown.call(t,d,g.handle)!==!1||_t.removeEvent(t,h,g.handle),delete s[h])}else for(h in s)_t.event.remove(t,h+e[c],n,r,!0);_t.isEmptyObject(s)&&Ut.remove(t,"handle events")}},dispatch:function(t){var e,n,r,o,i,a,u=_t.event.fix(t),s=new Array(arguments.length),c=(Ut.get(this,"events")||{})[u.type]||[],l=_t.event.special[u.type]||{};for(s[0]=u,e=1;e=1))for(;c!==this;c=c.parentNode||this)if(1===c.nodeType&&("click"!==t.type||c.disabled!==!0)){for(i=[],a={},n=0;n-1:_t.find(o,this,null,[c]).length),a[o]&&i.push(r);i.length&&u.push({elem:c,handlers:i})}return c=this,s\x20\t\r\n\f]*)[^>]*)\/>/gi,ae=/\s*$/g;_t.extend({htmlPrefilter:function(t){return t.replace(ie,"<$1>")},clone:function(t,e,n){var r,o,i,a,u=t.cloneNode(!0),s=_t.contains(t.ownerDocument,t);if(!(mt.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||_t.isXMLDoc(t)))for(a=x(u),i=x(t),r=0,o=i.length;r0&&E(a,!s&&x(t,"script")),u},cleanData:function(t){for(var e,n,r,o=_t.event.special,i=0;void 0!==(n=t[i]);i++)if(qt(n)){if(e=n[Ut.expando]){if(e.events)for(r in e.events)o[r]?_t.event.remove(n,r):_t.removeEvent(n,r,e.handle);n[Ut.expando]=void 0}n[Vt.expando]&&(n[Vt.expando]=void 0)}}}),_t.fn.extend({detach:function(t){return R(this,t,!0)},remove:function(t){return R(this,t)},text:function(t){return Bt(this,function(t){return void 0===t?_t.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)})},null,t,arguments.length)},append:function(){return I(this,arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=C(this,t);e.appendChild(t)}})},prepend:function(){return I(this,arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=C(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return I(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return I(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(_t.cleanData(x(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return _t.clone(this,t,e)})},html:function(t){return Bt(this,function(t){var e=this[0]||{},n=0,r=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!ae.test(t)&&!Zt[(Xt.exec(t)||["",""])[1].toLowerCase()]){t=_t.htmlPrefilter(t);try{for(;n1)}}),_t.Tween=z,z.prototype={constructor:z,init:function(t,e,n,r,o,i){this.elem=t,this.prop=n,this.easing=o||_t.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=r,this.unit=i||(_t.cssNumber[n]?"":"px")},cur:function(){var t=z.propHooks[this.prop];return t&&t.get?t.get(this):z.propHooks._default.get(this)},run:function(t){var e,n=z.propHooks[this.prop];return this.options.duration?this.pos=e=_t.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),n&&n.set?n.set(this):z.propHooks._default.set(this),this}},z.prototype.init.prototype=z.prototype,z.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=_t.css(t.elem,t.prop,""),e&&"auto"!==e?e:0)},set:function(t){_t.fx.step[t.prop]?_t.fx.step[t.prop](t):1!==t.elem.nodeType||null==t.elem.style[_t.cssProps[t.prop]]&&!_t.cssHooks[t.prop]?t.elem[t.prop]=t.now:_t.style(t.elem,t.prop,t.now+t.unit)}}},z.propHooks.scrollTop=z.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},_t.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},_t.fx=z.prototype.init,_t.fx.step={};var _e,be,we=/^(?:toggle|show|hide)$/,xe=/queueHooks$/;_t.Animation=_t.extend(Y,{tweeners:{"*":[function(t,e){var n=this.createTween(t,e);return _(n.elem,t,Wt.exec(e),n),n}]},tweener:function(t,e){_t.isFunction(t)?(e=t,t=["*"]):t=t.match(Rt);for(var n,r=0,o=t.length;r1)},removeAttr:function(t){return this.each(function(){_t.removeAttr(this,t)})}}),_t.extend({attr:function(t,e,n){var r,o,i=t.nodeType;if(3!==i&&8!==i&&2!==i)return"undefined"==typeof t.getAttribute?_t.prop(t,e,n):(1===i&&_t.isXMLDoc(t)||(o=_t.attrHooks[e.toLowerCase()]||(_t.expr.match.bool.test(e)?Ee:void 0)),void 0!==n?null===n?void _t.removeAttr(t,e):o&&"set"in o&&void 0!==(r=o.set(t,n,e))?r:(t.setAttribute(e,n+""),n):o&&"get"in o&&null!==(r=o.get(t,e))?r:(r=_t.find.attr(t,e),null==r?void 0:r))},attrHooks:{type:{set:function(t,e){if(!mt.radioValue&&"radio"===e&&s(t,"input")){var n=t.value;return t.setAttribute("type",e),n&&(t.value=n),e}}}},removeAttr:function(t,e){var n,r=0,o=e&&e.match(Rt);if(o&&1===t.nodeType)for(;n=o[r++];)t.removeAttribute(n)}}),Ee={set:function(t,e,n){return e===!1?_t.removeAttr(t,n):t.setAttribute(n,n),n}},_t.each(_t.expr.match.bool.source.match(/\w+/g),function(t,e){var n=ke[e]||_t.find.attr;ke[e]=function(t,e,r){var o,i,a=e.toLowerCase();return r||(i=ke[a],ke[a]=o,o=null!=n(t,e,r)?a:null,ke[a]=i),o}});var je=/^(?:input|select|textarea|button)$/i,Oe=/^(?:a|area)$/i;_t.fn.extend({prop:function(t,e){return Bt(this,_t.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each(function(){delete this[_t.propFix[t]||t]})}}),_t.extend({prop:function(t,e,n){var r,o,i=t.nodeType;if(3!==i&&8!==i&&2!==i)return 1===i&&_t.isXMLDoc(t)||(e=_t.propFix[e]||e,o=_t.propHooks[e]),void 0!==n?o&&"set"in o&&void 0!==(r=o.set(t,n,e))?r:t[e]=n:o&&"get"in o&&null!==(r=o.get(t,e))?r:t[e]},propHooks:{tabIndex:{get:function(t){var e=_t.find.attr(t,"tabindex");return e?parseInt(e,10):je.test(t.nodeName)||Oe.test(t.nodeName)&&t.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),mt.optSelected||(_t.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),_t.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){_t.propFix[this.toLowerCase()]=this}),_t.fn.extend({addClass:function(t){var e,n,r,o,i,a,u,s=0;if(_t.isFunction(t))return this.each(function(e){_t(this).addClass(t.call(this,e,Q(this)))});if("string"==typeof t&&t)for(e=t.match(Rt)||[];n=this[s++];)if(o=Q(n),r=1===n.nodeType&&" "+X(o)+" "){for(a=0;i=e[a++];)r.indexOf(" "+i+" ")<0&&(r+=i+" ");u=X(r),o!==u&&n.setAttribute("class",u)}return this},removeClass:function(t){var e,n,r,o,i,a,u,s=0;if(_t.isFunction(t))return this.each(function(e){_t(this).removeClass(t.call(this,e,Q(this)))});if(!arguments.length)return this.attr("class","");if("string"==typeof t&&t)for(e=t.match(Rt)||[];n=this[s++];)if(o=Q(n),r=1===n.nodeType&&" "+X(o)+" "){for(a=0;i=e[a++];)for(;r.indexOf(" "+i+" ")>-1;)r=r.replace(" "+i+" "," ");u=X(r),o!==u&&n.setAttribute("class",u)}return this},toggleClass:function(t,e){var n=typeof t;return"boolean"==typeof e&&"string"===n?e?this.addClass(t):this.removeClass(t):_t.isFunction(t)?this.each(function(n){_t(this).toggleClass(t.call(this,n,Q(this),e),e)}):this.each(function(){var e,r,o,i;if("string"===n)for(r=0,o=_t(this),i=t.match(Rt)||[];e=i[r++];)o.hasClass(e)?o.removeClass(e):o.addClass(e);else void 0!==t&&"boolean"!==n||(e=Q(this),e&&Ut.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||t===!1?"":Ut.get(this,"__className__")||""))})},hasClass:function(t){var e,n,r=0;for(e=" "+t+" ";n=this[r++];)if(1===n.nodeType&&(" "+X(Q(n))+" ").indexOf(e)>-1)return!0;return!1}});var Se=/\r/g;_t.fn.extend({val:function(t){var e,n,r,o=this[0];{if(arguments.length)return r=_t.isFunction(t),this.each(function(n){var o;1===this.nodeType&&(o=r?t.call(this,n,_t(this).val()):t,null==o?o="":"number"==typeof o?o+="":Array.isArray(o)&&(o=_t.map(o,function(t){return null==t?"":t+""})),e=_t.valHooks[this.type]||_t.valHooks[this.nodeName.toLowerCase()],e&&"set"in e&&void 0!==e.set(this,o,"value")||(this.value=o))});if(o)return e=_t.valHooks[o.type]||_t.valHooks[o.nodeName.toLowerCase()],e&&"get"in e&&void 0!==(n=e.get(o,"value"))?n:(n=o.value,"string"==typeof n?n.replace(Se,""):null==n?"":n)}}}),_t.extend({valHooks:{option:{get:function(t){var e=_t.find.attr(t,"value");return null!=e?e:X(_t.text(t))}},select:{get:function(t){var e,n,r,o=t.options,i=t.selectedIndex,a="select-one"===t.type,u=a?null:[],c=a?i+1:o.length;for(r=i<0?c:a?i:0;r-1)&&(n=!0);return n||(t.selectedIndex=-1),i}}}}),_t.each(["radio","checkbox"],function(){_t.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=_t.inArray(_t(t).val(),e)>-1}},mt.checkOn||(_t.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})});var Te=/^(?:focusinfocus|focusoutblur)$/;_t.extend(_t.event,{trigger:function(t,e,r,o){var i,a,u,s,c,l,f,p=[r||at],h=dt.call(t,"type")?t.type:t,d=dt.call(t,"namespace")?t.namespace.split("."):[];if(a=u=r=r||at,3!==r.nodeType&&8!==r.nodeType&&!Te.test(h+_t.event.triggered)&&(h.indexOf(".")>-1&&(d=h.split("."),h=d.shift(),d.sort()),c=h.indexOf(":")<0&&"on"+h,t=t[_t.expando]?t:new _t.Event(h,"object"==typeof t&&t),t.isTrigger=o?2:3,t.namespace=d.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=r),e=null==e?[t]:_t.makeArray(e,[t]),f=_t.event.special[h]||{},o||!f.trigger||f.trigger.apply(r,e)!==!1)){if(!o&&!f.noBubble&&!_t.isWindow(r)){for(s=f.delegateType||h,Te.test(s+h)||(a=a.parentNode);a;a=a.parentNode)p.push(a),u=a;u===(r.ownerDocument||at)&&p.push(u.defaultView||u.parentWindow||n)}for(i=0;(a=p[i++])&&!t.isPropagationStopped();)t.type=i>1?s:f.bindType||h,l=(Ut.get(a,"events")||{})[t.type]&&Ut.get(a,"handle"),l&&l.apply(a,e),l=c&&a[c],l&&l.apply&&qt(a)&&(t.result=l.apply(a,e),t.result===!1&&t.preventDefault());return t.type=h,o||t.isDefaultPrevented()||f._default&&f._default.apply(p.pop(),e)!==!1||!qt(r)||c&&_t.isFunction(r[h])&&!_t.isWindow(r)&&(u=r[c],u&&(r[c]=null),_t.event.triggered=h,r[h](),_t.event.triggered=void 0,u&&(r[c]=u)),t.result}},simulate:function(t,e,n){var r=_t.extend(new _t.Event,n,{type:t,isSimulated:!0});_t.event.trigger(r,null,e)}}),_t.fn.extend({trigger:function(t,e){return this.each(function(){_t.event.trigger(t,e,this)})},triggerHandler:function(t,e){var n=this[0];if(n)return _t.event.trigger(t,e,n,!0)}}),_t.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(t,e){_t.fn[e]=function(t,n){return arguments.length>0?this.on(e,null,t,n):this.trigger(e)}}),_t.fn.extend({hover:function(t,e){return this.mouseenter(t).mouseleave(e||t)}}),mt.focusin="onfocusin"in n,mt.focusin||_t.each({focus:"focusin",blur:"focusout"},function(t,e){var n=function(t){_t.event.simulate(e,t.target,_t.event.fix(t))};_t.event.special[e]={setup:function(){var r=this.ownerDocument||this,o=Ut.access(r,e);o||r.addEventListener(t,n,!0),Ut.access(r,e,(o||0)+1)},teardown:function(){var r=this.ownerDocument||this,o=Ut.access(r,e)-1;o?Ut.access(r,e,o):(r.removeEventListener(t,n,!0),Ut.remove(r,e))}}});var Ce=n.location,Ae=_t.now(),Ne=/\?/;_t.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new n.DOMParser).parseFromString(t,"text/xml")}catch(t){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||_t.error("Invalid XML: "+t),e};var De=/\[\]$/,Me=/\r?\n/g,Ie=/^(?:submit|button|image|reset|file)$/i,Re=/^(?:input|select|textarea|keygen)/i;_t.param=function(t,e){var n,r=[],o=function(t,e){var n=_t.isFunction(e)?e():e;r[r.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==n?"":n)};if(Array.isArray(t)||t.jquery&&!_t.isPlainObject(t))_t.each(t,function(){o(this.name,this.value)});else for(n in t)Z(n,t[n],e,o);return r.join("&")},_t.fn.extend({serialize:function(){return _t.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=_t.prop(this,"elements");return t?_t.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!_t(this).is(":disabled")&&Re.test(this.nodeName)&&!Ie.test(t)&&(this.checked||!Yt.test(t))}).map(function(t,e){var n=_t(this).val();return null==n?null:Array.isArray(n)?_t.map(n,function(t){return{name:e.name,value:t.replace(Me,"\r\n")}}):{name:e.name,value:n.replace(Me,"\r\n")}}).get()}});var Pe=/%20/g,Le=/#.*$/,Be=/([?&])_=[^&]*/,qe=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ue=/^(?:about|app|app-storage|.+-extension|file|res|widget):$/,Ve=/^(?:GET|HEAD)$/,Fe=/^\/\//,ze={},He={},We="*/".concat("*"),Ke=at.createElement("a");Ke.href=Ce.href,_t.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:Ce.href,type:"GET",isLocal:Ue.test(Ce.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":We,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":_t.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?nt(nt(t,_t.ajaxSettings),e):nt(_t.ajaxSettings,t)},ajaxPrefilter:tt(ze),ajaxTransport:tt(He),ajax:function(t,e){function r(t,e,r,u){var c,p,h,b,w,x=e;l||(l=!0,s&&n.clearTimeout(s),o=void 0,a=u||"",E.readyState=t>0?4:0,c=t>=200&&t<300||304===t,r&&(b=rt(d,E,r)),b=ot(d,b,E,c),c?(d.ifModified&&(w=E.getResponseHeader("Last-Modified"),w&&(_t.lastModified[i]=w),w=E.getResponseHeader("etag"),w&&(_t.etag[i]=w)),204===t||"HEAD"===d.type?x="nocontent":304===t?x="notmodified":(x=b.state,p=b.data,h=b.error,c=!h)):(h=x,!t&&x||(x="error",t<0&&(t=0))),E.status=t,E.statusText=(e||x)+"",c?m.resolveWith(v,[p,x,E]):m.rejectWith(v,[E,x,h]),E.statusCode(_),_=void 0,f&&g.trigger(c?"ajaxSuccess":"ajaxError",[E,d,c?p:h]),y.fireWith(v,[E,x]),f&&(g.trigger("ajaxComplete",[E,d]),--_t.active||_t.event.trigger("ajaxStop")))}"object"==typeof t&&(e=t,t=void 0),e=e||{};var o,i,a,u,s,c,l,f,p,h,d=_t.ajaxSetup({},e),v=d.context||d,g=d.context&&(v.nodeType||v.jquery)?_t(v):_t.event,m=_t.Deferred(),y=_t.Callbacks("once memory"),_=d.statusCode||{},b={},w={},x="canceled",E={readyState:0,getResponseHeader:function(t){var e;if(l){if(!u)for(u={};e=qe.exec(a);)u[e[1].toLowerCase()]=e[2];e=u[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return l?a:null},setRequestHeader:function(t,e){return null==l&&(t=w[t.toLowerCase()]=w[t.toLowerCase()]||t,b[t]=e),this},overrideMimeType:function(t){return null==l&&(d.mimeType=t),this},statusCode:function(t){var e;if(t)if(l)E.always(t[E.status]);else for(e in t)_[e]=[_[e],t[e]];return this},abort:function(t){var e=t||x;return o&&o.abort(e),r(0,e),this}};if(m.promise(E),d.url=((t||d.url||Ce.href)+"").replace(Fe,Ce.protocol+"//"),d.type=e.method||e.type||d.method||d.type,d.dataTypes=(d.dataType||"*").toLowerCase().match(Rt)||[""],null==d.crossDomain){c=at.createElement("a");try{c.href=d.url,c.href=c.href,d.crossDomain=Ke.protocol+"//"+Ke.host!=c.protocol+"//"+c.host}catch(t){d.crossDomain=!0}}if(d.data&&d.processData&&"string"!=typeof d.data&&(d.data=_t.param(d.data,d.traditional)),et(ze,d,e,E),l)return E;f=_t.event&&d.global,f&&0===_t.active++&&_t.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!Ve.test(d.type),i=d.url.replace(Le,""),d.hasContent?d.data&&d.processData&&0===(d.contentType||"").indexOf("application/x-www-form-urlencoded")&&(d.data=d.data.replace(Pe,"+")):(h=d.url.slice(i.length),d.data&&(i+=(Ne.test(i)?"&":"?")+d.data,delete d.data),d.cache===!1&&(i=i.replace(Be,"$1"),h=(Ne.test(i)?"&":"?")+"_="+Ae++ +h),d.url=i+h),d.ifModified&&(_t.lastModified[i]&&E.setRequestHeader("If-Modified-Since",_t.lastModified[i]),_t.etag[i]&&E.setRequestHeader("If-None-Match",_t.etag[i])),(d.data&&d.hasContent&&d.contentType!==!1||e.contentType)&&E.setRequestHeader("Content-Type",d.contentType),E.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+We+"; q=0.01":""):d.accepts["*"]);for(p in d.headers)E.setRequestHeader(p,d.headers[p]);if(d.beforeSend&&(d.beforeSend.call(v,E,d)===!1||l))return E.abort();if(x="abort",y.add(d.complete),E.done(d.success),E.fail(d.error),o=et(He,d,e,E)){if(E.readyState=1,f&&g.trigger("ajaxSend",[E,d]),l)return E;d.async&&d.timeout>0&&(s=n.setTimeout(function(){E.abort("timeout")},d.timeout));try{l=!1,o.send(b,r)}catch(t){if(l)throw t;r(-1,t)}}else r(-1,"No Transport");return E},getJSON:function(t,e,n){return _t.get(t,e,n,"json")},getScript:function(t,e){return _t.get(t,void 0,e,"script")}}),_t.each(["get","post"],function(t,e){_t[e]=function(t,n,r,o){return _t.isFunction(n)&&(o=o||r,r=n,n=void 0),_t.ajax(_t.extend({url:t,type:e,dataType:o,data:n,success:r},_t.isPlainObject(t)&&t))}}),_t._evalUrl=function(t){return _t.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},_t.fn.extend({wrapAll:function(t){var e;return this[0]&&(_t.isFunction(t)&&(t=t.call(this[0])),e=_t(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this},wrapInner:function(t){return _t.isFunction(t)?this.each(function(e){_t(this).wrapInner(t.call(this,e))}):this.each(function(){var e=_t(this),n=e.contents();n.length?n.wrapAll(t):e.append(t)})},wrap:function(t){var e=_t.isFunction(t);return this.each(function(n){_t(this).wrapAll(e?t.call(this,n):t)})},unwrap:function(t){return this.parent(t).not("body").each(function(){_t(this).replaceWith(this.childNodes)}),this}}),_t.expr.pseudos.hidden=function(t){return!_t.expr.pseudos.visible(t)},_t.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length); -},_t.ajaxSettings.xhr=function(){try{return new n.XMLHttpRequest}catch(t){}};var $e={0:200,1223:204},Ge=_t.ajaxSettings.xhr();mt.cors=!!Ge&&"withCredentials"in Ge,mt.ajax=Ge=!!Ge,_t.ajaxTransport(function(t){var e,r;if(mt.cors||Ge&&!t.crossDomain)return{send:function(o,i){var a,u=t.xhr();if(u.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(a in t.xhrFields)u[a]=t.xhrFields[a];t.mimeType&&u.overrideMimeType&&u.overrideMimeType(t.mimeType),t.crossDomain||o["X-Requested-With"]||(o["X-Requested-With"]="XMLHttpRequest");for(a in o)u.setRequestHeader(a,o[a]);e=function(t){return function(){e&&(e=r=u.onload=u.onerror=u.onabort=u.onreadystatechange=null,"abort"===t?u.abort():"error"===t?"number"!=typeof u.status?i(0,"error"):i(u.status,u.statusText):i($e[u.status]||u.status,u.statusText,"text"!==(u.responseType||"text")||"string"!=typeof u.responseText?{binary:u.response}:{text:u.responseText},u.getAllResponseHeaders()))}},u.onload=e(),r=u.onerror=e("error"),void 0!==u.onabort?u.onabort=r:u.onreadystatechange=function(){4===u.readyState&&n.setTimeout(function(){e&&r()})},e=e("abort");try{u.send(t.hasContent&&t.data||null)}catch(t){if(e)throw t}},abort:function(){e&&e()}}}),_t.ajaxPrefilter(function(t){t.crossDomain&&(t.contents.script=!1)}),_t.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return _t.globalEval(t),t}}}),_t.ajaxPrefilter("script",function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),_t.ajaxTransport("script",function(t){if(t.crossDomain){var e,n;return{send:function(r,o){e=_t(" - + {{#switch editor.mode}} {{#case "mjml"}} - + {{/case}} {{#case "html"}} diff --git a/obsolete/views/lists/edit.hbs b/obsolete/views/lists/edit.hbs index cbe0b6cc..00cfd3e1 100644 --- a/obsolete/views/lists/edit.hbs +++ b/obsolete/views/lists/edit.hbs @@ -80,6 +80,17 @@
+
+ +
+
+ +
+
+
+
diff --git a/obsolete/views/lists/segments/rule-configure.hbs b/obsolete/views/lists/segments/rule-configure.hbs index 0d37b1c0..e7ffee6f 100644 --- a/obsolete/views/lists/segments/rule-configure.hbs +++ b/obsolete/views/lists/segments/rule-configure.hbs @@ -23,6 +23,20 @@
{{#if columnTypeString}} +
+ +
+ +
+
+
diff --git a/obsolete/views/lists/segments/rule-edit.hbs b/obsolete/views/lists/segments/rule-edit.hbs index 4cdee26b..9c78c044 100644 --- a/obsolete/views/lists/segments/rule-edit.hbs +++ b/obsolete/views/lists/segments/rule-edit.hbs @@ -28,6 +28,20 @@
{{#if columnTypeString}} +
+ +
+ +
+
+
diff --git a/obsolete/views/settings.hbs b/obsolete/views/settings.hbs index 52472225..9314bc45 100644 --- a/obsolete/views/settings.hbs +++ b/obsolete/views/settings.hbs @@ -74,6 +74,14 @@
+
+ +
+ + {{#translate}}Set a custom X-Mailer header value or leave empty to disable it{{/translate}} +
+
+
@@ -122,6 +130,13 @@  
+
+ +
+ + {{#translate}}Set a custom unsubscribe url.{{/translate}} +
+
diff --git a/obsolete/views/triggers/create-select.hbs b/obsolete/views/triggers/create-select.hbs index d36aab59..ab14c1be 100644 --- a/obsolete/views/triggers/create-select.hbs +++ b/obsolete/views/triggers/create-select.hbs @@ -17,9 +17,19 @@
diff --git a/obsolete/views/triggers/create.hbs b/obsolete/views/triggers/create.hbs index d79ec27f..8152b5dc 100644 --- a/obsolete/views/triggers/create.hbs +++ b/obsolete/views/triggers/create.hbs @@ -30,7 +30,7 @@
-

{{list.name}} – {{list.subscribers}} {{#translate}}subscribers{{/translate}}

+

{{list.name}} {{#if segment.id}}– {{segment.name}}{{/if}} – {{#if segment.id}} {{segmentSubscribers}} {{else}} {{list.subscribers}} {{/if}} {{#translate}}subscribers{{/translate}}

diff --git a/obsolete/views/triggers/edit.hbs b/obsolete/views/triggers/edit.hbs index ccee4e21..62c3c437 100644 --- a/obsolete/views/triggers/edit.hbs +++ b/obsolete/views/triggers/edit.hbs @@ -43,7 +43,7 @@
-

{{list.name}} – {{list.subscribers}} {{#translate}}subscribers{{/translate}}

+

{{list.name}} {{#if segment.id}}– {{segment.name}}{{/if}} – {{#if segment.id}} {{segmentSubscribers}} {{else}} {{list.subscribers}} {{/if}} {{#translate}}subscribers{{/translate}}

diff --git a/obsolete/views/triggers/triggers.hbs b/obsolete/views/triggers/triggers.hbs index 92e42e7a..d21869f2 100644 --- a/obsolete/views/triggers/triggers.hbs +++ b/obsolete/views/triggers/triggers.hbs @@ -64,7 +64,7 @@ {{description}} - {{listName}} + {{listName}}{{#if segment}} - {{segmentName}}{{/if}} {{{formatted}}} diff --git a/package.json b/package.json index 9e54b160..ed7a621a 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,7 @@ { "name": "mailtrain", - "version": "1.23.2", + "private": true, + "version": "1.24.0", "description": "Self hosted email newsletter app", "main": "index.js", "scripts": { diff --git a/setup/sql/upgrade-00030.sql b/setup/sql/upgrade-00030.sql new file mode 100644 index 00000000..15a21c01 --- /dev/null +++ b/setup/sql/upgrade-00030.sql @@ -0,0 +1,17 @@ +# Header section +# Define incrementing schema version number +SET @schema_version = '30'; + +# Upgrade script section +#### INSERT YOUR UPGRADE SCRIPT BELOW THIS LINE ###### + +ALTER TABLE `lists` ADD COLUMN `listunsubscribe_disabled` tinyint(4) unsigned DEFAULT 0 NOT NULL; + +#### INSERT YOUR UPGRADE SCRIPT ABOVE THIS LINE ###### + +# Footer section. Updates schema version in settings +LOCK TABLES `settings` WRITE; +/*!40000 ALTER TABLE `settings` DISABLE KEYS */; +INSERT INTO `settings` (`key`, `value`) VALUES('db_schema_version', @schema_version) ON DUPLICATE KEY UPDATE `value`=@schema_version; +/*!40000 ALTER TABLE `settings` ENABLE KEYS */; +UNLOCK TABLES; diff --git a/setup/sql/upgrade-00031.sql b/setup/sql/upgrade-00031.sql new file mode 100644 index 00000000..24e47fea --- /dev/null +++ b/setup/sql/upgrade-00031.sql @@ -0,0 +1,12 @@ +# Header section +# Define incrementing schema version number +SET @schema_version = '31'; + +# Add segment support for triggers +ALTER TABLE `triggers` ADD `segment` INT(11) UNSIGNED NOT NULL AFTER `list`; +ALTER TABLE `trigger` ADD `segment` INT(11) UNSIGNED NOT NULL AFTER `list`; + +# Footer section +LOCK TABLES `settings` WRITE; +INSERT INTO `settings` (`key`, `value`) VALUES('db_schema_version', @schema_version) ON DUPLICATE KEY UPDATE `value`=@schema_version; +UNLOCK TABLES; diff --git a/setup/sql/upgrade-00032.sql b/setup/sql/upgrade-00032.sql new file mode 100644 index 00000000..35c8cb42 --- /dev/null +++ b/setup/sql/upgrade-00032.sql @@ -0,0 +1,15 @@ +# Header section +# Define incrementing schema version number +SET @schema_version = '32'; + +# Set default X-Mailer header value +LOCK TABLES `settings` WRITE; +INSERT INTO `settings` (`key`, `value`) VALUES ('x_mailer','Mailtrain Mailer (+https://mailtrain.org)') ON DUPLICATE KEY UPDATE `value`='Mailtrain Mailer (+https://mailtrain.org)'; +UNLOCK TABLES; + +# Footer section. Updates schema version in settings +LOCK TABLES `settings` WRITE; +/*!40000 ALTER TABLE `settings` DISABLE KEYS */; +INSERT INTO `settings` (`key`, `value`) VALUES('db_schema_version', @schema_version) ON DUPLICATE KEY UPDATE `value`=@schema_version; +/*!40000 ALTER TABLE `settings` ENABLE KEYS */; +UNLOCK TABLES; diff --git a/setup/sql/upgrade-00033.sql b/setup/sql/upgrade-00033.sql new file mode 100644 index 00000000..885d59f9 --- /dev/null +++ b/setup/sql/upgrade-00033.sql @@ -0,0 +1,13 @@ +# Header section +# Define incrementing schema version number +SET @schema_version = '33'; + +# Adds new column 'unsubscribe' to campaign table. +ALTER TABLE campaigns ADD COLUMN `unsubscribe` VARCHAR(255) NOT NULL DEFAULT '' AFTER `subject`; + +# Footer section. Updates schema version in settings +LOCK TABLES `settings` WRITE; +/*!40000 ALTER TABLE `settings` DISABLE KEYS */; +INSERT INTO `settings` (`key`, `value`) VALUES('db_schema_version', @schema_version) ON DUPLICATE KEY UPDATE `value`=@schema_version; +/*!40000 ALTER TABLE `settings` ENABLE KEYS */; +UNLOCK TABLES;