survey-creator-core 1.12.6 → 1.12.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fonts.fontless.css +1 -1
- package/fonts.fontless.min.css +1 -1
- package/i18n/arabic.js +1 -1
- package/i18n/arabic.min.js.LICENSE.txt +1 -1
- package/i18n/bulgarian.js +1 -1
- package/i18n/bulgarian.min.js.LICENSE.txt +1 -1
- package/i18n/croatian.js +1 -1
- package/i18n/croatian.min.js.LICENSE.txt +1 -1
- package/i18n/czech.js +1 -1
- package/i18n/czech.min.js.LICENSE.txt +1 -1
- package/i18n/danish.js +1 -1
- package/i18n/danish.min.js.LICENSE.txt +1 -1
- package/i18n/dutch.js +1 -1
- package/i18n/dutch.min.js.LICENSE.txt +1 -1
- package/i18n/english.js +16 -2
- package/i18n/english.js.map +1 -1
- package/i18n/english.min.js +1 -1
- package/i18n/english.min.js.LICENSE.txt +1 -1
- package/i18n/finnish.js +1 -1
- package/i18n/finnish.min.js.LICENSE.txt +1 -1
- package/i18n/french.js +1 -1
- package/i18n/french.min.js.LICENSE.txt +1 -1
- package/i18n/german.js +1 -1
- package/i18n/german.min.js.LICENSE.txt +1 -1
- package/i18n/hebrew.js +1 -1
- package/i18n/hebrew.min.js.LICENSE.txt +1 -1
- package/i18n/hungarian.js +1 -1
- package/i18n/hungarian.min.js.LICENSE.txt +1 -1
- package/i18n/index.js +1 -1
- package/i18n/index.min.js.LICENSE.txt +1 -1
- package/i18n/indonesian.js +1 -1
- package/i18n/indonesian.min.js.LICENSE.txt +1 -1
- package/i18n/italian.js +1 -1
- package/i18n/italian.min.js.LICENSE.txt +1 -1
- package/i18n/japanese.js +1 -1
- package/i18n/japanese.min.js.LICENSE.txt +1 -1
- package/i18n/korean.js +1 -1
- package/i18n/korean.min.js.LICENSE.txt +1 -1
- package/i18n/malay.js +1 -1
- package/i18n/malay.min.js.LICENSE.txt +1 -1
- package/i18n/mongolian.js +1 -1
- package/i18n/mongolian.min.js.LICENSE.txt +1 -1
- package/i18n/norwegian.js +1 -1
- package/i18n/norwegian.min.js.LICENSE.txt +1 -1
- package/i18n/persian.js +1 -1
- package/i18n/persian.min.js.LICENSE.txt +1 -1
- package/i18n/polish.js +1 -1
- package/i18n/polish.min.js.LICENSE.txt +1 -1
- package/i18n/portuguese.js +1 -1
- package/i18n/portuguese.min.js.LICENSE.txt +1 -1
- package/i18n/romanian.js +1 -1
- package/i18n/romanian.min.js.LICENSE.txt +1 -1
- package/i18n/russian.js +1 -1
- package/i18n/russian.min.js.LICENSE.txt +1 -1
- package/i18n/simplified-chinese.js +1 -1
- package/i18n/simplified-chinese.min.js.LICENSE.txt +1 -1
- package/i18n/slovak.js +1 -1
- package/i18n/slovak.min.js.LICENSE.txt +1 -1
- package/i18n/spanish.js +1 -1
- package/i18n/spanish.min.js.LICENSE.txt +1 -1
- package/i18n/swedish.js +1 -1
- package/i18n/swedish.min.js.LICENSE.txt +1 -1
- package/i18n/tajik.js +1 -1
- package/i18n/tajik.min.js.LICENSE.txt +1 -1
- package/i18n/thai.js +1 -1
- package/i18n/thai.min.js.LICENSE.txt +1 -1
- package/i18n/traditional-chinese.js +1 -1
- package/i18n/traditional-chinese.min.js.LICENSE.txt +1 -1
- package/i18n/turkish.js +1 -1
- package/i18n/turkish.min.js.LICENSE.txt +1 -1
- package/package.json +2 -2
- package/survey-creator-core.css +523 -401
- package/survey-creator-core.fontless.css +522 -400
- package/survey-creator-core.fontless.css.map +1 -1
- package/survey-creator-core.fontless.min.css +23 -22
- package/survey-creator-core.i18n.js +1 -1
- package/survey-creator-core.i18n.min.js.LICENSE.txt +1 -1
- package/survey-creator-core.js +724 -101
- package/survey-creator-core.js.map +1 -1
- package/survey-creator-core.min.css +24 -23
- package/survey-creator-core.min.js +1 -1
- package/survey-creator-core.min.js.LICENSE.txt +1 -1
- package/themes/default-contrast.js +827 -0
- package/themes/default-contrast.js.map +1 -0
- package/themes/default-contrast.min.js +2 -0
- package/themes/default-contrast.min.js.LICENSE.txt +6 -0
- package/themes/default-dark.js +827 -0
- package/themes/default-dark.js.map +1 -0
- package/themes/default-dark.min.js +2 -0
- package/themes/default-dark.min.js.LICENSE.txt +6 -0
- package/themes/default-light.js +827 -0
- package/themes/default-light.js.map +1 -0
- package/themes/default-light.min.js +2 -0
- package/themes/default-light.min.js.LICENSE.txt +6 -0
- package/themes/entries/helpers.d.ts +5 -0
- package/themes/index.js +1018 -0
- package/themes/index.js.map +1 -0
- package/themes/index.min.js +2 -0
- package/themes/index.min.js.LICENSE.txt +6 -0
- package/themes/themes/default-contrast.d.ts +119 -0
- package/themes/themes/default-dark.d.ts +119 -0
- package/themes/themes/default-light.d.ts +119 -0
- package/themes/themes/default.d.ts +1215 -0
- package/themes/themes/index.d.ts +177 -0
- package/themes/themes/utils.d.ts +4 -0
- package/typings/components/action-container-view-model.d.ts +2 -1
- package/typings/components/page.d.ts +1 -2
- package/typings/components/side-bar/side-bar-header-model.d.ts +1 -1
- package/typings/components/side-bar/side-bar-model.d.ts +1 -0
- package/typings/components/side-bar/side-bar-page-model.d.ts +1 -0
- package/typings/components/tabs/designer-plugin.d.ts +8 -0
- package/typings/components/tabs/theme-plugin.d.ts +1 -1
- package/typings/components/tabs/themes.d.ts +2 -1
- package/typings/creator-base.d.ts +8 -1
- package/typings/creator-options.d.ts +1 -0
- package/typings/creator-theme/creator-theme-model-definition.d.ts +5 -0
- package/typings/creator-theme/creator-theme-model.d.ts +43 -0
- package/typings/creator-theme/creator-themes.d.ts +10 -0
- package/typings/editorLocalization.d.ts +14 -0
- package/typings/entries/index.d.ts +2 -0
- package/typings/localization/english.d.ts +14 -0
- package/typings/property-grid/index.d.ts +3 -0
- package/typings/property-grid/property-grid-view-model.d.ts +1 -0
- package/typings/themes/default-contrast.d.ts +119 -0
- package/typings/themes/default-dark.d.ts +119 -0
- package/typings/themes/default-light.d.ts +119 -0
- package/typings/themes/default.d.ts +1215 -0
- package/typings/themes/index.d.ts +177 -0
- package/typings/themes/utils.d.ts +4 -0
- package/typings/toolbox.d.ts +10 -2
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see survey-creator-core.min.js.LICENSE.txt */
|
|
2
|
-
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("survey-core"),require("survey-core/themes")):"function"==typeof define&&define.amd?define("survey-creator-core",["survey-core","survey-core/themes"],t):"object"==typeof exports?exports["survey-creator-core"]=t(require("survey-core"),require("survey-core/themes")):e.SurveyCreatorCore=t(e.Survey,e.SurveyTheme)}(this,((e,t)=>(()=>{var o={264:(e,t,o)=>{"use strict";o.r(t)},9281:(e,t,o)=>{"use strict";o.r(t)},1383:(e,t,o)=>{"use strict";o.r(t)},6195:(e,t,o)=>{"use strict";o.r(t)},2996:(e,t,o)=>{"use strict";o.r(t)},3952:(e,t,o)=>{"use strict";o.r(t)},7205:(e,t,o)=>{"use strict";o.r(t)},9671:(e,t,o)=>{"use strict";o.r(t)},4767:(e,t,o)=>{"use strict";o.r(t)},7167:(e,t,o)=>{"use strict";o.r(t)},9845:(e,t,o)=>{"use strict";o.r(t)},422:(e,t,o)=>{"use strict";o.r(t)},3140:(e,t,o)=>{"use strict";o.r(t)},3926:(e,t,o)=>{"use strict";o.r(t)},3844:(e,t,o)=>{"use strict";o.r(t)},9414:(e,t,o)=>{"use strict";o.r(t)},4880:(e,t,o)=>{"use strict";o.r(t)},4607:(e,t,o)=>{"use strict";o.r(t)},7231:(e,t,o)=>{"use strict";o.r(t)},8538:(e,t,o)=>{"use strict";o.r(t)},8445:(e,t,o)=>{"use strict";o.r(t)},3071:(e,t,o)=>{"use strict";o.r(t)},6681:(e,t,o)=>{"use strict";o.r(t)},5187:(e,t,o)=>{"use strict";o.r(t)},5876:(e,t,o)=>{"use strict";o.r(t)},1497:(e,t,o)=>{"use strict";o.r(t)},8380:(e,t,o)=>{"use strict";o.r(t)},790:(e,t,o)=>{"use strict";o.r(t)},5377:(e,t,o)=>{"use strict";o.r(t)},5625:(e,t,o)=>{"use strict";o.r(t)},4340:(e,t,o)=>{"use strict";o.r(t)},1868:(e,t,o)=>{"use strict";o.r(t)},9336:(e,t,o)=>{"use strict";o.r(t)},9991:(e,t,o)=>{"use strict";o.r(t)},6190:(e,t,o)=>{"use strict";o.r(t)},3193:(e,t,o)=>{"use strict";o.r(t)},326:(e,t,o)=>{"use strict";o.r(t)},9118:(e,t,o)=>{"use strict";o.r(t)},5175:(e,t,o)=>{"use strict";o.r(t)},1119:(e,t,o)=>{"use strict";o.r(t)},7671:(e,t,o)=>{"use strict";o.r(t)},4809:function(e,t){var o,i;o=function e(){"use strict";var t="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==t?t:{},o=!t.document&&!!t.postMessage,i=t.IS_PAPA_WORKER||!1,n={},r=0,a={parse:function(o,i){var s=(i=i||{}).dynamicTyping||!1;if(w(s)&&(i.dynamicTypingFunction=s,s={}),i.dynamicTyping=s,i.transform=!!w(i.transform)&&i.transform,i.worker&&a.WORKERS_SUPPORTED){var l=function(){if(!a.WORKERS_SUPPORTED)return!1;var o,i,s=(o=t.URL||t.webkitURL||null,i=e.toString(),a.BLOB_URL||(a.BLOB_URL=o.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",i,")();"],{type:"text/javascript"})))),l=new t.Worker(s);return l.onmessage=f,l.id=r++,n[l.id]=l}();return l.userStep=i.step,l.userChunk=i.chunk,l.userComplete=i.complete,l.userError=i.error,i.step=w(i.step),i.chunk=w(i.chunk),i.complete=w(i.complete),i.error=w(i.error),delete i.worker,void l.postMessage({input:o,config:i,workerId:l.id})}var h=null;return a.NODE_STREAM_INPUT,"string"==typeof o?(o=function(e){return 65279===e.charCodeAt(0)?e.slice(1):e}(o),h=i.download?new u(i):new c(i)):!0===o.readable&&w(o.read)&&w(o.on)?h=new d(i):(t.File&&o instanceof File||o instanceof Object)&&(h=new p(i)),h.stream(o)},unparse:function(e,t){var o=!1,i=!0,n=",",r="\r\n",s='"',l=s+s,u=!1,p=null,c=!1;!function(){if("object"==typeof t){if("string"!=typeof t.delimiter||a.BAD_DELIMITERS.filter((function(e){return-1!==t.delimiter.indexOf(e)})).length||(n=t.delimiter),("boolean"==typeof t.quotes||"function"==typeof t.quotes||Array.isArray(t.quotes))&&(o=t.quotes),"boolean"!=typeof t.skipEmptyLines&&"string"!=typeof t.skipEmptyLines||(u=t.skipEmptyLines),"string"==typeof t.newline&&(r=t.newline),"string"==typeof t.quoteChar&&(s=t.quoteChar),"boolean"==typeof t.header&&(i=t.header),Array.isArray(t.columns)){if(0===t.columns.length)throw new Error("Option columns is empty");p=t.columns}void 0!==t.escapeChar&&(l=t.escapeChar+s),("boolean"==typeof t.escapeFormulae||t.escapeFormulae instanceof RegExp)&&(c=t.escapeFormulae instanceof RegExp?t.escapeFormulae:/^[=+\-@\t\r].*$/)}}();var d=new RegExp(g(s),"g");if("string"==typeof e&&(e=JSON.parse(e)),Array.isArray(e)){if(!e.length||Array.isArray(e[0]))return h(null,e,u);if("object"==typeof e[0])return h(p||Object.keys(e[0]),e,u)}else if("object"==typeof e)return"string"==typeof e.data&&(e.data=JSON.parse(e.data)),Array.isArray(e.data)&&(e.fields||(e.fields=e.meta&&e.meta.fields||p),e.fields||(e.fields=Array.isArray(e.data[0])?e.fields:"object"==typeof e.data[0]?Object.keys(e.data[0]):[]),Array.isArray(e.data[0])||"object"==typeof e.data[0]||(e.data=[e.data])),h(e.fields||[],e.data||[],u);throw new Error("Unable to serialize unrecognized input");function h(e,t,o){var a="";"string"==typeof e&&(e=JSON.parse(e)),"string"==typeof t&&(t=JSON.parse(t));var s=Array.isArray(e)&&0<e.length,l=!Array.isArray(t[0]);if(s&&i){for(var u=0;u<e.length;u++)0<u&&(a+=n),a+=m(e[u],u);0<t.length&&(a+=r)}for(var p=0;p<t.length;p++){var c=s?e.length:t[p].length,d=!1,h=s?0===Object.keys(t[p]).length:0===t[p].length;if(o&&!s&&(d="greedy"===o?""===t[p].join("").trim():1===t[p].length&&0===t[p][0].length),"greedy"===o&&s){for(var g=[],f=0;f<c;f++){var y=l?e[f]:f;g.push(t[p][y])}d=""===g.join("").trim()}if(!d){for(var v=0;v<c;v++){0<v&&!h&&(a+=n);var b=s&&l?e[v]:v;a+=m(t[p][b],v)}p<t.length-1&&(!o||0<c&&!h)&&(a+=r)}}return a}function m(e,t){if(null==e)return"";if(e.constructor===Date)return JSON.stringify(e).slice(1,25);var i=!1;c&&"string"==typeof e&&c.test(e)&&(e="'"+e,i=!0);var r=e.toString().replace(d,l);return(i=i||!0===o||"function"==typeof o&&o(e,t)||Array.isArray(o)&&o[t]||function(e,t){for(var o=0;o<t.length;o++)if(-1<e.indexOf(t[o]))return!0;return!1}(r,a.BAD_DELIMITERS)||-1<r.indexOf(n)||" "===r.charAt(0)||" "===r.charAt(r.length-1))?s+r+s:r}}};if(a.RECORD_SEP=String.fromCharCode(30),a.UNIT_SEP=String.fromCharCode(31),a.BYTE_ORDER_MARK="\ufeff",a.BAD_DELIMITERS=["\r","\n",'"',a.BYTE_ORDER_MARK],a.WORKERS_SUPPORTED=!o&&!!t.Worker,a.NODE_STREAM_INPUT=1,a.LocalChunkSize=10485760,a.RemoteChunkSize=5242880,a.DefaultDelimiter=",",a.Parser=m,a.ParserHandle=h,a.NetworkStreamer=u,a.FileStreamer=p,a.StringStreamer=c,a.ReadableStreamStreamer=d,t.jQuery){var s=t.jQuery;s.fn.parse=function(e){var o=e.config||{},i=[];return this.each((function(e){if("INPUT"!==s(this).prop("tagName").toUpperCase()||"file"!==s(this).attr("type").toLowerCase()||!t.FileReader||!this.files||0===this.files.length)return!0;for(var n=0;n<this.files.length;n++)i.push({file:this.files[n],inputElem:this,instanceConfig:s.extend({},o)})})),n(),this;function n(){if(0!==i.length){var t,o,n,l=i[0];if(w(e.before)){var u=e.before(l.file,l.inputElem);if("object"==typeof u){if("abort"===u.action)return t=l.file,o=l.inputElem,n=u.reason,void(w(e.error)&&e.error({name:"AbortError"},t,o,n));if("skip"===u.action)return void r();"object"==typeof u.config&&(l.instanceConfig=s.extend(l.instanceConfig,u.config))}else if("skip"===u)return void r()}var p=l.instanceConfig.complete;l.instanceConfig.complete=function(e){w(p)&&p(e,l.file,l.inputElem),r()},a.parse(l.file,l.instanceConfig)}else w(e.complete)&&e.complete()}function r(){i.splice(0,1),n()}}}function l(e){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},function(e){var t=b(e);t.chunkSize=parseInt(t.chunkSize),e.step||e.chunk||(t.chunkSize=null),this._handle=new h(t),(this._handle.streamer=this)._config=t}.call(this,e),this.parseChunk=function(e,o){if(this.isFirstChunk&&w(this._config.beforeFirstChunk)){var n=this._config.beforeFirstChunk(e);void 0!==n&&(e=n)}this.isFirstChunk=!1,this._halted=!1;var r=this._partialLine+e;this._partialLine="";var s=this._handle.parse(r,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.aborted()){var l=s.meta.cursor;this._finished||(this._partialLine=r.substring(l-this._baseIndex),this._baseIndex=l),s&&s.data&&(this._rowCount+=s.data.length);var u=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(i)t.postMessage({results:s,workerId:a.WORKER_ID,finished:u});else if(w(this._config.chunk)&&!o){if(this._config.chunk(s,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);s=void 0,this._completeResults=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(s.data),this._completeResults.errors=this._completeResults.errors.concat(s.errors),this._completeResults.meta=s.meta),this._completed||!u||!w(this._config.complete)||s&&s.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||s&&s.meta.paused||this._nextChunk(),s}this._halted=!0},this._sendError=function(e){w(this._config.error)?this._config.error(e):i&&this._config.error&&t.postMessage({workerId:a.WORKER_ID,error:e,finished:!1})}}function u(e){var t;(e=e||{}).chunkSize||(e.chunkSize=a.RemoteChunkSize),l.call(this,e),this._nextChunk=o?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(e){this._input=e,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(t=new XMLHttpRequest,this._config.withCredentials&&(t.withCredentials=this._config.withCredentials),o||(t.onload=C(this._chunkLoaded,this),t.onerror=C(this._chunkError,this)),t.open(this._config.downloadRequestBody?"POST":"GET",this._input,!o),this._config.downloadRequestHeaders){var e=this._config.downloadRequestHeaders;for(var i in e)t.setRequestHeader(i,e[i])}if(this._config.chunkSize){var n=this._start+this._config.chunkSize-1;t.setRequestHeader("Range","bytes="+this._start+"-"+n)}try{t.send(this._config.downloadRequestBody)}catch(e){this._chunkError(e.message)}o&&0===t.status&&this._chunkError()}},this._chunkLoaded=function(){4===t.readyState&&(t.status<200||400<=t.status?this._chunkError():(this._start+=this._config.chunkSize?this._config.chunkSize:t.responseText.length,this._finished=!this._config.chunkSize||this._start>=function(e){var t=e.getResponseHeader("Content-Range");return null===t?-1:parseInt(t.substring(t.lastIndexOf("/")+1))}(t),this.parseChunk(t.responseText)))},this._chunkError=function(e){var o=t.statusText||e;this._sendError(new Error(o))}}function p(e){var t,o;(e=e||{}).chunkSize||(e.chunkSize=a.LocalChunkSize),l.call(this,e);var i="undefined"!=typeof FileReader;this.stream=function(e){this._input=e,o=e.slice||e.webkitSlice||e.mozSlice,i?((t=new FileReader).onload=C(this._chunkLoaded,this),t.onerror=C(this._chunkError,this)):t=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var e=this._input;if(this._config.chunkSize){var n=Math.min(this._start+this._config.chunkSize,this._input.size);e=o.call(e,this._start,n)}var r=t.readAsText(e,this._config.encoding);i||this._chunkLoaded({target:{result:r}})},this._chunkLoaded=function(e){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(e.target.result)},this._chunkError=function(){this._sendError(t.error)}}function c(e){var t;l.call(this,e=e||{}),this.stream=function(e){return t=e,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var e,o=this._config.chunkSize;return o?(e=t.substring(0,o),t=t.substring(o)):(e=t,t=""),this._finished=!t,this.parseChunk(e)}}}function d(e){l.call(this,e=e||{});var t=[],o=!0,i=!1;this.pause=function(){l.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){l.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(e){this._input=e,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){i&&1===t.length&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),t.length?this.parseChunk(t.shift()):o=!0},this._streamData=C((function(e){try{t.push("string"==typeof e?e:e.toString(this._config.encoding)),o&&(o=!1,this._checkIsFinished(),this.parseChunk(t.shift()))}catch(e){this._streamError(e)}}),this),this._streamError=C((function(e){this._streamCleanUp(),this._sendError(e)}),this),this._streamEnd=C((function(){this._streamCleanUp(),i=!0,this._streamData("")}),this),this._streamCleanUp=C((function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)}),this)}function h(e){var t,o,i,n=Math.pow(2,53),r=-n,s=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,l=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,u=this,p=0,c=0,d=!1,h=!1,f=[],y={data:[],errors:[],meta:{}};if(w(e.step)){var v=e.step;e.step=function(t){if(y=t,T())x();else{if(x(),0===y.data.length)return;p+=t.data.length,e.preview&&p>e.preview?o.abort():(y.data=y.data[0],v(y,u))}}}function C(t){return"greedy"===e.skipEmptyLines?""===t.join("").trim():1===t.length&&0===t[0].length}function x(){return y&&i&&(P("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+a.DefaultDelimiter+"'"),i=!1),e.skipEmptyLines&&(y.data=y.data.filter((function(e){return!C(e)}))),T()&&function(){if(y)if(Array.isArray(y.data[0])){for(var t=0;T()&&t<y.data.length;t++)y.data[t].forEach(o);y.data.splice(0,1)}else y.data.forEach(o);function o(t,o){w(e.transformHeader)&&(t=e.transformHeader(t,o)),f.push(t)}}(),function(){if(!y||!e.header&&!e.dynamicTyping&&!e.transform)return y;function t(t,o){var i,n=e.header?{}:[];for(i=0;i<t.length;i++){var r=i,a=t[i];e.header&&(r=i>=f.length?"__parsed_extra":f[i]),e.transform&&(a=e.transform(a,r)),a=S(r,a),"__parsed_extra"===r?(n[r]=n[r]||[],n[r].push(a)):n[r]=a}return e.header&&(i>f.length?P("FieldMismatch","TooManyFields","Too many fields: expected "+f.length+" fields but parsed "+i,c+o):i<f.length&&P("FieldMismatch","TooFewFields","Too few fields: expected "+f.length+" fields but parsed "+i,c+o)),n}var o=1;return!y.data.length||Array.isArray(y.data[0])?(y.data=y.data.map(t),o=y.data.length):y.data=t(y.data,0),e.header&&y.meta&&(y.meta.fields=f),c+=o,y}()}function T(){return e.header&&0===f.length}function S(t,o){return i=t,e.dynamicTypingFunction&&void 0===e.dynamicTyping[i]&&(e.dynamicTyping[i]=e.dynamicTypingFunction(i)),!0===(e.dynamicTyping[i]||e.dynamicTyping)?"true"===o||"TRUE"===o||"false"!==o&&"FALSE"!==o&&(function(e){if(s.test(e)){var t=parseFloat(e);if(r<t&&t<n)return!0}return!1}(o)?parseFloat(o):l.test(o)?new Date(o):""===o?null:o):o;var i}function P(e,t,o,i){var n={type:e,code:t,message:o};void 0!==i&&(n.row=i),y.errors.push(n)}this.parse=function(n,r,s){var l=e.quoteChar||'"';if(e.newline||(e.newline=function(e,t){e=e.substring(0,1048576);var o=new RegExp(g(t)+"([^]*?)"+g(t),"gm"),i=(e=e.replace(o,"")).split("\r"),n=e.split("\n"),r=1<n.length&&n[0].length<i[0].length;if(1===i.length||r)return"\n";for(var a=0,s=0;s<i.length;s++)"\n"===i[s][0]&&a++;return a>=i.length/2?"\r\n":"\r"}(n,l)),i=!1,e.delimiter)w(e.delimiter)&&(e.delimiter=e.delimiter(n),y.meta.delimiter=e.delimiter);else{var u=function(t,o,i,n,r){var s,l,u,p;r=r||[",","\t","|",";",a.RECORD_SEP,a.UNIT_SEP];for(var c=0;c<r.length;c++){var d=r[c],h=0,g=0,f=0;u=void 0;for(var y=new m({comments:n,delimiter:d,newline:o,preview:10}).parse(t),v=0;v<y.data.length;v++)if(i&&C(y.data[v]))f++;else{var b=y.data[v].length;g+=b,void 0!==u?0<b&&(h+=Math.abs(b-u),u=b):u=b}0<y.data.length&&(g/=y.data.length-f),(void 0===l||h<=l)&&(void 0===p||p<g)&&1.99<g&&(l=h,s=d,p=g)}return{successful:!!(e.delimiter=s),bestDelimiter:s}}(n,e.newline,e.skipEmptyLines,e.comments,e.delimitersToGuess);u.successful?e.delimiter=u.bestDelimiter:(i=!0,e.delimiter=a.DefaultDelimiter),y.meta.delimiter=e.delimiter}var p=b(e);return e.preview&&e.header&&p.preview++,t=n,o=new m(p),y=o.parse(t,r,s),x(),d?{meta:{paused:!0}}:y||{meta:{paused:!1}}},this.paused=function(){return d},this.pause=function(){d=!0,o.abort(),t=w(e.chunk)?"":t.substring(o.getCharIndex())},this.resume=function(){u.streamer._halted?(d=!1,u.streamer.parseChunk(t,!0)):setTimeout(u.resume,3)},this.aborted=function(){return h},this.abort=function(){h=!0,o.abort(),y.meta.aborted=!0,w(e.complete)&&e.complete(y),t=""}}function g(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function m(e){var t,o=(e=e||{}).delimiter,i=e.newline,n=e.comments,r=e.step,s=e.preview,l=e.fastMode,u=t=void 0===e.quoteChar||null===e.quoteChar?'"':e.quoteChar;if(void 0!==e.escapeChar&&(u=e.escapeChar),("string"!=typeof o||-1<a.BAD_DELIMITERS.indexOf(o))&&(o=","),n===o)throw new Error("Comment character same as delimiter");!0===n?n="#":("string"!=typeof n||-1<a.BAD_DELIMITERS.indexOf(n))&&(n=!1),"\n"!==i&&"\r"!==i&&"\r\n"!==i&&(i="\n");var p=0,c=!1;this.parse=function(a,d,h){if("string"!=typeof a)throw new Error("Input must be a string");var m=a.length,f=o.length,y=i.length,v=n.length,b=w(r),C=[],x=[],T=[],S=p=0;if(!a)return Z();if(e.header&&!d){var P=a.split(i)[0].split(o),E=[],V={},I=!1;for(var A in P){var O=P[A];w(e.transformHeader)&&(O=e.transformHeader(O,A));var N=O,L=V[O]||0;for(0<L&&(I=!0,N=O+"_"+L),V[O]=L+1;E.includes(N);)N=N+"_"+L;E.push(N)}if(I){var _=a.split(i);_[0]=E.join(o),a=_.join(i)}}if(l||!1!==l&&-1===a.indexOf(t)){for(var M=a.split(i),D=0;D<M.length;D++){if(T=M[D],p+=T.length,D!==M.length-1)p+=i.length;else if(h)return Z();if(!n||T.substring(0,v)!==n){if(b){if(C=[],Q(T.split(o)),z(),c)return Z()}else Q(T.split(o));if(s&&s<=D)return C=C.slice(0,s),Z(!0)}}return Z()}for(var k=a.indexOf(o,p),j=a.indexOf(i,p),R=new RegExp(g(u)+g(t),"g"),B=a.indexOf(t,p);;)if(a[p]!==t)if(n&&0===T.length&&a.substring(p,p+v)===n){if(-1===j)return Z();p=j+y,j=a.indexOf(i,p),k=a.indexOf(o,p)}else if(-1!==k&&(k<j||-1===j))T.push(a.substring(p,k)),p=k+f,k=a.indexOf(o,p);else{if(-1===j)break;if(T.push(a.substring(p,j)),G(j+y),b&&(z(),c))return Z();if(s&&C.length>=s)return Z(!0)}else for(B=p,p++;;){if(-1===(B=a.indexOf(t,B+1)))return h||x.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:C.length,index:p}),U();if(B===m-1)return U(a.substring(p,B).replace(R,t));if(t!==u||a[B+1]!==u){if(t===u||0===B||a[B-1]!==u){-1!==k&&k<B+1&&(k=a.indexOf(o,B+1)),-1!==j&&j<B+1&&(j=a.indexOf(i,B+1));var q=F(-1===j?k:Math.min(k,j));if(a.substr(B+1+q,f)===o){T.push(a.substring(p,B).replace(R,t)),a[p=B+1+q+f]!==t&&(B=a.indexOf(t,p)),k=a.indexOf(o,p),j=a.indexOf(i,p);break}var H=F(j);if(a.substring(B+1+H,B+1+H+y)===i){if(T.push(a.substring(p,B).replace(R,t)),G(B+1+H+y),k=a.indexOf(o,p),B=a.indexOf(t,p),b&&(z(),c))return Z();if(s&&C.length>=s)return Z(!0);break}x.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:C.length,index:p}),B++}}else B++}return U();function Q(e){C.push(e),S=p}function F(e){var t=0;if(-1!==e){var o=a.substring(B+1,e);o&&""===o.trim()&&(t=o.length)}return t}function U(e){return h||(void 0===e&&(e=a.substring(p)),T.push(e),p=m,Q(T),b&&z()),Z()}function G(e){p=e,Q(T),T=[],j=a.indexOf(i,p)}function Z(e){return{data:C,errors:x,meta:{delimiter:o,linebreak:i,aborted:c,truncated:!!e,cursor:S+(d||0)}}}function z(){r(Z()),C=[],x=[]}},this.abort=function(){c=!0},this.getCharIndex=function(){return p}}function f(e){var t=e.data,o=n[t.workerId],i=!1;if(t.error)o.userError(t.error,t.file);else if(t.results&&t.results.data){var r={abort:function(){i=!0,y(t.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:v,resume:v};if(w(o.userStep)){for(var a=0;a<t.results.data.length&&(o.userStep({data:t.results.data[a],errors:t.results.errors,meta:t.results.meta},r),!i);a++);delete t.results}else w(o.userChunk)&&(o.userChunk(t.results,r,t.file),delete t.results)}t.finished&&!i&&y(t.workerId,t.results)}function y(e,t){var o=n[e];w(o.userComplete)&&o.userComplete(t),o.terminate(),delete n[e]}function v(){throw new Error("Not implemented.")}function b(e){if("object"!=typeof e||null===e)return e;var t=Array.isArray(e)?[]:{};for(var o in e)t[o]=b(e[o]);return t}function C(e,t){return function(){e.apply(t,arguments)}}function w(e){return"function"==typeof e}return i&&(t.onmessage=function(e){var o=e.data;if(void 0===a.WORKER_ID&&o&&(a.WORKER_ID=o.workerId),"string"==typeof o.input)t.postMessage({workerId:a.WORKER_ID,results:a.parse(o.input,o.config),finished:!0});else if(t.File&&o.input instanceof File||o.input instanceof Object){var i=a.parse(o.input,o.config);i&&t.postMessage({workerId:a.WORKER_ID,results:i,finished:!0})}}),(u.prototype=Object.create(l.prototype)).constructor=u,(p.prototype=Object.create(l.prototype)).constructor=p,(c.prototype=Object.create(c.prototype)).constructor=c,(d.prototype=Object.create(l.prototype)).constructor=d,a},void 0===(i=o.apply(t,[]))||(e.exports=i)},6504:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 11H17V13H13V17H11V13H7V11H11V7H13V11ZM24 12C24 18.6 18.6 24 12 24C5.4 24 0 18.6 0 12C0 5.4 5.4 0 12 0C18.6 0 24 5.4 24 12ZM22 12C22 6.5 17.5 2 12 2C6.5 2 2 6.5 2 12C2 17.5 6.5 22 12 22C17.5 22 22 17.5 22 12Z"></path></svg>'},618:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 11H17V13H13V17H11V13H7V11H11V7H13V11ZM23 12C23 18.1 18.1 23 12 23C5.9 23 1 18.1 1 12C1 5.9 5.9 1 12 1C18.1 1 23 5.9 23 12ZM21 12C21 7 17 3 12 3C7 3 3 7 3 12C3 17 7 21 12 21C17 21 21 17 21 12Z"></path></svg>'},1797:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M9 7H12V9H9V12H7V9H4V7H7V4H9V7ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},6539:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M9 7H12V9H9V12H7V9H4V7H7V4H9V7ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},356:e=>{e.exports='<svg viewBox="0 0 24 20" xmlns="http://www.w3.org/2000/svg"><path d="M23.0336 15.4803L14.5736 1.45346C13.9936 0.487805 12.9936 0 12.0036 0C11.0136 0 10.0136 0.487805 9.43364 1.45346L0.973642 15.4803C-0.226358 17.4714 1.21364 20 3.54364 20H20.4536C22.7836 20 24.2236 17.4714 23.0236 15.4803H23.0336ZM21.3336 17.5112C21.2436 17.6605 20.9936 18.0189 20.4636 18.0189H3.54364C3.01364 18.0189 2.76364 17.6705 2.67364 17.5112C2.58364 17.3519 2.41364 16.9537 2.68364 16.5057L11.1436 2.47885C11.4036 2.04082 11.8336 1.99104 12.0036 1.99104C12.1736 1.99104 12.5936 2.04082 12.8636 2.47885L21.3136 16.5057C21.5836 16.9537 21.4136 17.3519 21.3236 17.5112H21.3336ZM13.0036 7.05824V12.0358C13.0036 12.5834 12.5536 13.0314 12.0036 13.0314C11.4536 13.0314 11.0036 12.5834 11.0036 12.0358V7.05824C11.0036 6.5107 11.4536 6.06272 12.0036 6.06272C12.5536 6.06272 13.0036 6.5107 13.0036 7.05824ZM13.0036 15.0224C13.0036 15.5699 12.5536 16.0179 12.0036 16.0179C11.4536 16.0179 11.0036 15.5699 11.0036 15.0224C11.0036 14.4749 11.4536 14.0269 12.0036 14.0269C12.5536 14.0269 13.0036 14.4749 13.0036 15.0224Z"></path></svg>'},631:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 1C5.9 1 1 5.9 1 12C1 18.1 5.9 23 12 23C18.1 23 23 18.1 23 12C23 5.9 18.1 1 12 1ZM12 21C7 21 3 17 3 12C3 7 7 3 12 3C17 3 21 7 21 12C21 17 17 21 12 21ZM16.3 8L17.7 9.4L10 17.1L6.3 13.4L7.7 12L10 14.3L16.3 8Z"></path></svg>'},4321:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17.01 11.59L13.01 15.59V6H11.01V15.59L7.00998 11.59L5.59998 13L12.01 19.41L18.43 13L17.01 11.59Z"></path></svg>'},1354:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M10.4 2.60001L11.8 4.00001L4.8 11H22V13H4.8L11.8 20L10.4 21.4L1 12L10.4 2.60001Z"></path></svg>'},1685:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 8.99999H4.39998L8.69998 13.3L7.29998 14.7L0.599976 7.99999L7.29998 1.29999L8.69998 2.69999L4.39998 6.99999H15V8.99999V8.99999Z"></path></svg>'},3153:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13.6 2.60001L12.2 4.00001L19.2 11H2V13H19.2L12.2 20L13.6 21.4L23 12L13.6 2.60001Z"></path></svg>'},3142:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M1 6.99999H11.6L7.3 2.69999L8.7 1.29999L15.4 7.99999L8.7 14.7L7.3 13.3L11.6 8.99999H1V6.99999Z"></path></svg>'},3422:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M18.43 11.01L12.01 4.60001L5.59998 11.01L7.00998 12.43L11.01 8.43001V18.01H13.01V8.43001L17.01 12.43L18.43 11.01Z"></path></svg>'},9331:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 11H17C19.8 11 22 8.8 22 6C22 3.2 19.8 1 17 1H7C4.2 1 2 3.2 2 6C2 8.8 4.2 11 7 11ZM7 3H17C18.7 3 20 4.3 20 6C20 7.7 18.7 9 17 9H7C5.3 9 4 7.7 4 6C4 4.3 5.3 3 7 3ZM5 6C5 4.9 5.9 4 7 4C8.1 4 9 4.9 9 6C9 7.1 8.1 8 7 8C5.9 8 5 7.1 5 6ZM19 18C19 19.1 18.1 20 17 20C15.9 20 15 19.1 15 18C15 16.9 15.9 16 17 16C18.1 16 19 16.9 19 18ZM17 13H7C4.2 13 2 15.2 2 18C2 20.8 4.2 23 7 23H17C19.8 23 22 20.8 22 18C22 15.2 19.8 13 17 13ZM17 21H7C5.3 21 4 19.7 4 18C4 16.3 5.3 15 7 15H17C18.7 15 20 16.3 20 18C20 19.7 18.7 21 17 21Z"></path></svg>'},7140:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 2V7H10L12 5C11.1 3.8 9.6 3 8 3C5.2 3 3 5.2 3 8H1C1 4.1 4.1 1 8 1C10.2 1 12.1 2 13.4 3.6L15 2ZM8 13C6.4 13 4.9 12.2 4 11L6 9H1V14L2.6 12.4C3.9 14 5.8 15 8 15C11.9 15 15 11.9 15 8H13C13 10.8 10.8 13 8 13Z"></path></svg>'},2678:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M19 8.90001L21 6.10001V19C21 20.1 20.1 21 19 21H5C3.9 21 3 20.1 3 19V5.00001C3 3.90001 3.9 3.00001 5 3.00001H19C19 3.00001 19 3.00001 19.1 3.00001L20.8 0.600006L22.4 1.80001L11.1 17.5L6.6 13L8 11.6L10.9 14.5L17.7 5.00001H5V19H19V8.90001Z"></path></svg>'},8020:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 20.1L1 12L3.1 9.9L9 15.9L20.9 4L23 6.1L9 20.1Z"></path></svg>'},5981:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M8 11L13 6H3L8 11Z"></path></svg>'},9380:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22.6 8.6L16.4 2.4C16 2 15.5 1.8 15 1.8C14.5 1.8 14 2 13.6 2.4L1.4 14.6C0.600003 15.4 0.600003 16.6 1.4 17.4L6 22H12L22.6 11.4C23.3 10.6 23.3 9.3 22.6 8.6ZM11.1 20H6.8L2.8 16L6.2 12.6L12.4 18.8L11.1 20ZM13.8 17.4L7.6 11.2L15 3.8L21.2 10L13.8 17.4ZM16 20H23V22H14L16 20Z"></path></svg>'},6907:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13.35 3.34999L12.65 2.64999L8.05002 7.24999L3.35002 2.64999L2.65002 3.34999L7.25002 8.04999L2.65002 12.65L3.35002 13.35L8.05002 8.74999L12.65 13.35L13.35 12.65L8.75002 8.04999L13.35 3.34999Z"></path></svg>'},9054:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM9 11C9 11.37 8.89 11.7 8.72 12C8.89 12.3 9 12.63 9 13V14.5C9 14.78 9.22 15 9.5 15H10C10.55 15 11 15.45 11 16C11 16.55 10.55 17 10 17H9.5C8.12 17 7 15.88 7 14.5V13C6.45 13 6 12.55 6 12C6 11.45 6.45 11 7 11V9.5C7 8.12 8.12 7 9.5 7H10C10.55 7 11 7.45 11 8C11 8.55 10.55 9 10 9H9.5C9.22 9 9 9.22 9 9.5V11ZM18 12C18 12.55 17.55 13 17 13V14.5C17 15.88 15.88 17 14.5 17H14C13.45 17 13 16.55 13 16C13 15.45 13.45 15 14 15H14.5C14.78 15 15 14.78 15 14.5V13C15 12.63 15.11 12.3 15.28 12C15.11 11.7 15 11.37 15 11V9.5C15 9.22 14.78 9 14.5 9H14C13.45 9 13 8.55 13 8C13 7.45 13.45 7 14 7H14.5C15.88 7 17 8.12 17 9.5V11C17.55 11 18 11.45 18 12Z"></path></svg>'},7678:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13 7H3V9H13V7Z"></path></svg>'},6845:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M12 9H4V7H12V9ZM16 0V16H0V0H16ZM14 2H2V14H14V2Z"></path></svg>'},9405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 5.6L19.4 12L13 18.4L11.6 17L15.6 13H2V11H15.6L11.6 7L13 5.6ZM20 2V22H22V2H20Z"></path></svg>'},4358:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g id="Collapse V 16x16"><path id="Vector" d="M11.71 12.29C12.1 12.68 12.1 13.31 11.71 13.7C11.51 13.9 11.26 13.99 11 13.99C10.74 13.99 10.49 13.89 10.29 13.7L9.00002 12.41V15C9.00002 15.55 8.55002 16 8.00002 16C7.45002 16 7.00002 15.55 7.00002 15V12.41L5.71002 13.7C5.32002 14.09 4.69002 14.09 4.30002 13.7C3.91002 13.31 3.91002 12.68 4.30002 12.29L7.30002 9.29C7.69002 8.9 8.32002 8.9 8.71002 9.29L11.71 12.29ZM7.29002 6.71C7.49002 6.91 7.74002 7 8.00002 7C8.26002 7 8.51002 6.9 8.71002 6.71L11.71 3.71C12.1 3.32 12.1 2.69 11.71 2.3C11.32 1.91 10.69 1.91 10.3 2.3L9.01002 3.59V1C9.01002 0.45 8.56002 0 8.01002 0C7.46002 0 7.01002 0.45 7.01002 1V3.59L5.72002 2.3C5.33002 1.91 4.70002 1.91 4.31002 2.3C3.92002 2.69 3.90002 3.32 4.29002 3.71L7.29002 6.71Z"></path></g></svg>'},943:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M2 6L3 5L8 10L13 5L14 6L8 12L2 6Z"></path></svg>'},6398:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 14.59L16.41 19L15 20.41L13 18.41V23H11V18.41L9 20.41L7.59 19L12 14.59ZM16.41 5L15 3.59L13 5.59V1H11V5.59L9 3.59L7.59 5L12 9.41L16.41 5ZM2 11V13H22V11H2Z"></path></svg>'},8813:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M3.31 15.0002C2.69 15.0002 2.11 14.7602 1.68 14.3202C0.780005 13.4202 0.780005 11.9502 1.68 11.0502L2.45 10.2802C2.45 10.1802 2.44 10.0802 2.44 9.98023C2.44 9.02023 2.81 8.12023 3.49 7.44023L5.6 5.33023C5.37 5.04023 5.25 4.68023 5.25 4.31023C5.25 3.86023 5.42 3.44023 5.74 3.12023C6.06 2.80023 6.48 2.63023 6.92 2.63023C7.29 2.63023 7.65 2.75023 7.94 2.98023L8.88 2.04023C9.56 1.36023 10.46 0.990234 11.41 0.990234C12.36 0.990234 13.27 1.36023 13.95 2.04023C14.63 2.72023 15 3.62023 15 4.58023C15 5.54023 14.63 6.44023 13.95 7.12023L12.94 8.13023C13.04 8.34023 13.09 8.58023 13.09 8.82023C13.09 9.27023 12.92 9.69023 12.6 10.0002C12.28 10.3102 11.86 10.4902 11.42 10.4902C11.18 10.4902 10.94 10.4402 10.73 10.3402L8.56 12.5102C7.88 13.1902 6.98 13.5602 6.03 13.5602C5.93 13.5602 5.83 13.5602 5.73 13.5402L4.97 14.3002C4.53 14.7402 3.95 14.9802 3.34 14.9802L3.31 15.0002Z" fill="black" fill-opacity="0.15"></path><path d="M14.0001 4.57969C14.0001 3.88969 13.7301 3.23969 13.2401 2.74969C12.2301 1.73969 10.5901 1.73969 9.58006 2.74969L7.94006 4.38969L7.39006 3.83969C7.13006 3.57969 6.70006 3.57969 6.44006 3.83969C6.18006 4.09969 6.18006 4.52969 6.44006 4.78969L6.99006 5.33969L4.18006 8.14969C3.69006 8.63969 3.42006 9.28969 3.42006 9.97969C3.42006 10.1997 3.46006 10.4097 3.51006 10.6197L2.38006 11.7497C1.87006 12.2597 1.87006 13.0897 2.38006 13.6097C2.64006 13.8697 2.97006 13.9897 3.31006 13.9897C3.65006 13.9897 3.98006 13.8597 4.24006 13.6097L5.37006 12.4797C5.58006 12.5297 5.79006 12.5697 6.01006 12.5697C6.70006 12.5697 7.35006 12.2997 7.84006 11.8097L10.6501 8.99969L10.9401 9.28969C11.0701 9.41969 11.2401 9.48969 11.4201 9.48969C11.6001 9.48969 11.7701 9.41969 11.9001 9.28969C12.1601 9.02969 12.1601 8.59969 11.9001 8.33969L11.6101 8.04969L13.2501 6.40969C13.7401 5.91969 14.0101 5.26969 14.0101 4.57969H14.0001ZM6.89006 10.8597C6.42006 11.3297 5.61006 11.3297 5.14006 10.8597C4.91006 10.6297 4.78006 10.3197 4.78006 9.98969C4.78006 9.65969 4.91006 9.34969 5.14006 9.11969L7.95006 6.30969L9.70006 8.05969L6.89006 10.8697V10.8597Z"></path></svg>'},6124:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 3H4C2.9 3 2 3.9 2 5V19C2 20.1 2.9 21 4 21H20C21.1 21 22 20.1 22 19V5C22 3.9 21.1 3 20 3ZM20 19H4V5H20V19ZM18 9H6V7H18V9ZM18 13H6V11H18V13ZM12 17H6V15H12V17Z"></path></svg>'},2739:e=>{e.exports='<svg viewBox="0 0 25 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_19827_2206)"><path d="M15.13 2.02C15.74 2.02 16.33 2.11 16.9 2.25L13.63 5.52C12.25 6.9 12.25 9.14 13.63 10.52C14.32 11.21 15.23 11.56 16.13 11.56C17.03 11.56 17.94 11.21 18.63 10.52L21.9 7.25C22.05 7.82 22.13 8.41 22.13 9.02C22.13 12.89 19 16.02 15.13 16.02C13.97 16.02 12.88 15.73 11.92 15.23L6.13 21.02C5.72 21.43 5.17 21.64 4.63 21.64C4.09 21.64 3.54 21.43 3.13 21.02C2.3 20.19 2.3 18.85 3.13 18.02L8.92 12.23C8.42 11.27 8.13 10.18 8.13 9.02C8.13 5.15 11.26 2.02 15.13 2.02ZM15.13 0.02C10.17 0.02 6.13 4.06 6.13 9.02C6.13 9.95 6.28 10.88 6.56 11.76L1.71 16.61C0.93 17.39 0.5 18.42 0.5 19.52C0.5 20.62 0.93 21.66 1.71 22.43C2.49 23.21 3.52 23.64 4.62 23.64C5.72 23.64 6.76 23.21 7.53 22.43L12.38 17.58C13.27 17.86 14.19 18.01 15.12 18.01C20.08 18.01 24.12 13.97 24.12 9.01C24.12 8.26 24.02 7.5 23.82 6.74C23.64 6.05 23.1 5.5 22.41 5.31C22.24 5.26 22.06 5.24 21.89 5.24C21.37 5.24 20.86 5.45 20.48 5.83L17.21 9.1C16.92 9.39 16.53 9.55 16.12 9.55C15.71 9.55 15.32 9.39 15.03 9.1C14.74 8.81 14.58 8.42 14.58 8.01C14.58 7.6 14.74 7.21 15.03 6.92L18.3 3.65C18.81 3.14 19 2.4 18.82 1.71C18.63 1.02 18.09 0.48 17.39 0.3C16.63 0.1 15.87 0 15.12 0L15.13 0.02Z"></path></g><defs><clipPath id="clip0_19827_2206"><rect width="24" height="24" transform="translate(0.5)"></rect></clipPath></defs></svg>'},2622:e=>{e.exports='<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21 1H9C7.9 1 7 1.9 7 3V7H3C1.9 7 1 7.9 1 9V21C1 22.1 1.9 23 3 23H15C16.1 23 17 22.1 17 21V17H21C22.1 17 23 16.1 23 15V3C23 1.9 22.1 1 21 1ZM15 21H3V9H15V21ZM21 15H17V9C17 7.9 16.1 7 15 7H9V3H21V15Z" fill="black" fill-opacity="0.45"></path></svg>'},6252:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C16.41 4 20 7.14 20 11C19.9901 11.928 19.7826 12.8433 19.3911 13.6847C18.9997 14.5262 18.4334 15.2746 17.73 15.88C17.5103 16.0801 17.338 16.3266 17.2256 16.6017C17.1132 16.8767 17.0634 17.1733 17.08 17.47C16.7752 17.2972 16.4304 17.2076 16.08 17.21C15.8237 17.212 15.5698 17.2594 15.33 17.35C14.2722 17.7789 13.1415 17.9996 12 18C7.59 18 4 14.86 4 11C4 7.14 7.59 4 12 4ZM12 2C6.48 2 2 6 2 11C2 16 6.48 20 12 20C13.4012 19.9996 14.7894 19.7314 16.09 19.21L20 22L19.07 17.36C19.9796 16.5667 20.711 15.5899 21.216 14.4937C21.721 13.3975 21.9882 12.2069 22 11C22 6 17.52 2 12 2Z"></path></svg>'},2583:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 2H14H11V1C11 0.4 10.6 0 10 0H7C6.4 0 6 0.4 6 1V2H3H2V4H3V14C3 15.1 3.9 16 5 16H12C13.1 16 14 15.1 14 14V4H15V2ZM7 1H10V2H7V1ZM12 14H5V4H12V14ZM7 13H6V5H7V13ZM9 13H8V5H9V13ZM11 13H10V5H11V13Z"></path></svg>'},405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 4H20H16V2C16 0.9 15.1 0 14 0H10C8.9 0 8 0.9 8 2V4H4H2V6H4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V6H22V4ZM10 2H14V4H10V2ZM18 20H6V6H8H16H18V20ZM14 8H16V18H14V8ZM11 8H13V18H11V8ZM8 8H10V18H8V8Z"></path></svg>'},4802:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M2.3 3.7L3.6 5C2 6.9 1 9.3 1 12C1 18.1 5.9 23 12 23C14.7 23 17.1 22 19 20.4L20.3 21.7L21.7 20.3L3.7 2.3L2.3 3.7ZM12 21C7 21 3 17 3 12C3 9.9 3.7 7.9 5 6.4L10.8 12.2C10.7 12.3 10.6 12.4 10.6 12.5C10.5 12.7 10.4 13 10.4 13.3C10.4 13.6 10.5 13.9 10.6 14.1C10.7 14.3 10.8 14.5 10.9 14.8C11 15 11.2 15.1 11.4 15.1C11.5 15.1 11.5 15.1 11.6 15.1H11.7C11.8 15.1 11.9 15.1 12.1 15C12.4 14.9 12.6 14.7 12.6 14.5V14.4V14.1L17.5 19C16.1 20.3 14.1 21 12 21ZM7.8 4.1L6.3 2.6C8 1.6 9.9 1 12 1C18.1 1 23 5.9 23 12C23 14.1 22.4 16 21.4 17.7L19.9 16.2C20.6 15 21 13.5 21 12C21 7 17 3 12 3C10.5 3 9 3.4 7.8 4.1ZM13.5 9.8C13.5 9.7 13.6 9.6 13.6 9.4C13.6 9 13.5 8.6 13.2 8.4C12.8 8 12.4 7.9 12 7.9C11.9 7.9 11.8 7.9 11.6 7.9L10.1 6.4C10.2 6.4 10.2 6.3 10.3 6.3C11.5 5.9 12.7 5.9 13.6 6.1C14.1 6.2 14.5 6.4 14.9 6.6C15.6 7.3 16 8.1 16 9.3C16 10.1 15.7 10.8 15.2 11.4L13.5 9.8ZM11.8 15.9C12.5 15.9 13 16.2 13.3 16.8C13.4 17 13.4 17.2 13.4 17.4C13.4 17.8 13.2 18.2 13 18.5C12.7 18.8 12.3 18.9 11.9 18.9C11.5 18.9 11.1 18.7 10.8 18.5C10.5 18.2 10.4 17.8 10.4 17.4C10.4 17 10.6 16.6 10.8 16.3C11 16 11.4 15.9 11.8 15.9Z"></path></svg>'},5869:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 1C5.9 1 1 5.9 1 12C1 18.1 5.9 23 12 23C18.1 23 23 18.1 23 12C23 5.9 18.1 1 12 1ZM12 21C7 21 3 17 3 12C3 7 7 3 12 3C17 3 21 7 21 12C21 17 17 21 12 21ZM13.3 16.8C13.4 17 13.4 17.2 13.4 17.4C13.4 17.8 13.2 18.2 13 18.5C12.7 18.8 12.3 18.9 11.9 18.9C11.5 18.9 11.1 18.7 10.8 18.5C10.5 18.2 10.4 17.8 10.4 17.4C10.4 17 10.6 16.6 10.8 16.3C11.1 16 11.5 15.8 11.9 15.8C12.5 15.9 13 16.2 13.3 16.8ZM16 9.3C16 10.4 15.5 11.2 14.6 11.9C14.4 12.1 14.1 12.2 13.9 12.4L13.3 12.8C13 13 12.9 13.1 12.9 13.1C12.8 13.2 12.8 13.3 12.8 13.4C12.8 13.6 12.7 13.8 12.7 14.1V14.4V14.5C12.6 14.7 12.4 14.9 12.2 15C12 15.1 11.9 15.1 11.8 15.1H11.7C11.6 15.1 11.6 15.1 11.5 15.1C11.3 15 11.1 14.9 11 14.8C10.9 14.6 10.7 14.4 10.7 14.1C10.6 13.8 10.5 13.6 10.5 13.3C10.5 13 10.6 12.7 10.7 12.5C10.8 12.3 11 12.1 11.2 11.9C11.4 11.7 11.6 11.6 11.8 11.5L12.4 11.2C13 10.9 13.2 10.7 13.3 10.6C13.6 10.3 13.7 9.9 13.7 9.5C13.7 9.1 13.6 8.7 13.3 8.5C12.8 8 12.4 7.9 12 7.9C10.9 7.9 10.6 8.4 10.6 8.8C10.4 9.3 10.4 9.4 10.4 9.4V9.6C10.4 9.7 10.4 9.7 10.4 9.8L10.5 10.2L10.2 10.3C9.6 10.6 9.1 10.6 8.7 10.4C8.6 10.3 8.4 10.1 8.3 10C8.1 9.7 8 9.4 8 9C8 8.6 8.1 8.3 8.2 8C8.3 7.7 8.5 7.5 8.7 7.3C8.9 7.1 9.1 6.9 9.4 6.7C9.7 6.6 10 6.4 10.3 6.3C11.5 5.9 12.7 5.9 13.6 6.1C14.1 6.2 14.5 6.4 14.9 6.6C15.6 7.3 16 8.1 16 9.3Z"></path></svg>'},4548:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 17V2H2V17H10V19C10 19.7956 9.68393 20.5587 9.12132 21.1213C8.55871 21.6839 7.79565 22 7 22H17C16.2044 22 15.4413 21.6839 14.8787 21.1213C14.3161 20.5587 14 19.7956 14 19V17H22ZM4 4H20V15H4V4Z"></path></svg>'},736:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M16 18H8V6H16V18ZM16 2H8C7.46957 2 6.96086 2.21071 6.58579 2.58579C6.21071 2.96086 6 3.46957 6 4V20C6 20.5304 6.21071 21.0391 6.58579 21.4142C6.96086 21.7893 7.46957 22 8 22H16C16.5304 22 17.0391 21.7893 17.4142 21.4142C17.7893 21.0391 18 20.5304 18 20V4C18 3.46957 17.7893 2.96086 17.4142 2.58579C17.0391 2.21071 16.5304 2 16 2Z"></path></svg>'},3441:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M23.41 5.99591L18 11.4059L16.59 9.99591L19.59 6.99591H17C13.5522 6.99591 10.2456 8.36555 7.80761 10.8035C5.36964 13.2415 4 16.5481 4 19.9959V21.9959H2V19.9959C2 16.0177 3.58035 12.2024 6.3934 9.38931C9.20644 6.57626 13.0218 4.99591 17 4.99591H19.59L16.59 1.99591L18 0.585907L23.41 5.99591Z"></path></svg>'},9364:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 18H4V6H20V18ZM21 4H3C2.46957 4 1.96086 4.21071 1.58579 4.58579C1.21071 4.96086 1 5.46957 1 6V18C1 18.5304 1.21071 19.0391 1.58579 19.4142C1.96086 19.7893 2.46957 20 3 20H21C21.5304 20 22.0391 19.7893 22.4142 19.4142C22.7893 19.0391 23 18.5304 23 18V6C23 5.46957 22.7893 4.96086 22.4142 4.58579C22.0391 4.21071 21.5304 4 21 4Z"></path></svg>'},6813:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 18.41L4.59 11L6 9.59L11 14.59V2H13V14.59L18 9.59L19.41 11L12 18.41ZM2 20V22H22V20H2Z"></path></svg>'},9531:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 6C13 4.9 13.9 4 15 4C16.1 4 17 4.9 17 6C17 7.1 16.1 8 15 8C13.9 8 13 7.1 13 6ZM9 4C7.9 4 7 4.9 7 6C7 7.1 7.9 8 9 8C10.1 8 11 7.1 11 6C11 4.9 10.1 4 9 4ZM15 10C13.9 10 13 10.9 13 12C13 13.1 13.9 14 15 14C16.1 14 17 13.1 17 12C17 10.9 16.1 10 15 10ZM9 10C7.9 10 7 10.9 7 12C7 13.1 7.9 14 9 14C10.1 14 11 13.1 11 12C11 10.9 10.1 10 9 10ZM15 16C13.9 16 13 16.9 13 18C13 19.1 13.9 20 15 20C16.1 20 17 19.1 17 18C17 16.9 16.1 16 15 16ZM9 16C7.9 16 7 16.9 7 18C7 19.1 7.9 20 9 20C10.1 20 11 19.1 11 18C11 16.9 10.1 16 9 16Z"></path></svg>'},1689:e=>{e.exports='<svg viewBox="0 0 24 16" xmlns="http://www.w3.org/2000/svg"><path d="M18 9C19.1 9 20 9.9 20 11C20 12.1 19.1 13 18 13C16.9 13 16 12.1 16 11C16 9.9 16.9 9 18 9ZM20 5C20 3.9 19.1 3 18 3C16.9 3 16 3.9 16 5C16 6.1 16.9 7 18 7C19.1 7 20 6.1 20 5ZM14 11C14 9.9 13.1 9 12 9C10.9 9 10 9.9 10 11C10 12.1 10.9 13 12 13C13.1 13 14 12.1 14 11ZM14 5C14 3.9 13.1 3 12 3C10.9 3 10 3.9 10 5C10 6.1 10.9 7 12 7C13.1 7 14 6.1 14 5ZM8 11C8 9.9 7.1 9 6 9C4.9 9 4 9.9 4 11C4 12.1 4.9 13 6 13C7.1 13 8 12.1 8 11ZM8 5C8 3.9 7.1 3 6 3C4.9 3 4 3.9 4 5C4 6.1 4.9 7 6 7C7.1 7 8 6.1 8 5Z"></path></svg>'},2483:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 15L17 10H7L12 15Z"></path></svg>'},3892:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M8 11L13 6H3L8 11Z"></path></svg>'},7382:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V6C2 7.1 2.9 8 4 8V20C4 21.1 4.9 22 6 22H20C21.1 22 22 21.1 22 20V8V6V4C22 2.9 21.1 2 20 2ZM20 20H6V8H20V20ZM4 6V4H20V6H4ZM18 12H8V10H18V12ZM18 16H8V14H18V16Z"></path></svg>'},2723:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_9500_71113)"><path d="M14 0H6C5.46957 0 4.96086 0.210714 4.58579 0.585786C4.21071 0.960859 4 1.46957 4 2V4H2C1.46957 4 0.960859 4.21071 0.585786 4.58579C0.210714 4.96086 0 5.46957 0 6L0 14C0 14.5304 0.210714 15.0391 0.585786 15.4142C0.960859 15.7893 1.46957 16 2 16H10C10.5304 16 11.0391 15.7893 11.4142 15.4142C11.7893 15.0391 12 14.5304 12 14V12H14C14.5304 12 15.0391 11.7893 15.4142 11.4142C15.7893 11.0391 16 10.5304 16 10V2C16 1.46957 15.7893 0.960859 15.4142 0.585786C15.0391 0.210714 14.5304 0 14 0V0ZM10 14H2V6H10V14ZM14 10H12V6C12 5.46957 11.7893 4.96086 11.4142 4.58579C11.0391 4.21071 10.5304 4 10 4H6V2H14V10Z"></path></g><defs><clipPath id="clip0_9500_71113"><rect width="16" height="16"></rect></clipPath></defs></svg>'},5669:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21.9 4.8L19.1 2C18.5 1.5 17.8 1.2 17 1.2C16.2 1.2 15.5 1.5 14.9 2.1L4.6 12.3C2.9 14 2 16.3 2 18.7V21C2 21.6 2.4 22 3 22H5.3C7.7 22 10 21.1 11.7 19.4L21.9 9.1C23.1 7.9 23.1 6 21.9 4.8ZM10.2 17.9C8.9 19.2 7.1 20 5.3 20H4V18.7C4 16.8 4.7 15.1 6.1 13.8L12.3 7.6L16.5 11.8L10.2 17.9ZM20.5 7.7L17.8 10.4L13.6 6.2L16.3 3.5C16.5 3.2 16.8 3.2 17 3.2C17.2 3.2 17.5 3.2 17.7 3.5L20.5 6.3C20.9 6.6 20.9 7.3 20.5 7.7Z"></path></svg>'},2290:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_2693_58208)"><path d="M15.3 2.8L13.2 0.7C12.7 0.2 12.2 0 11.6 0C11 0 10.4 0.2 10 0.7L2 8.6C0.7 9.9 0 11.7 0 13.5V15.3C0 15.7 0.3 16 0.8 16H2.6C4.4 16 6.2 15.3 7.5 14L15.4 6.1C16.2 5.2 16.2 3.7 15.3 2.8ZM6 12.6C5.1 13.5 3.8 14 2.5 14H2V13.5C2 12.2 2.5 10.9 3.4 10L8 5.4L10.6 8L6 12.6ZM13.9 4.7L12 6.6L9.4 4L11.3 2.1C11.4 2 11.5 2 11.6 2C11.7 2 11.7 2 11.8 2.1L13.9 4.2C14 4.3 14 4.5 13.9 4.7Z"></path></g><defs><clipPath id="clip0_2693_58208"><rect width="16" height="16"></rect></clipPath></defs></svg>'},9697:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M2.3 3.7L7.8 9.2L4.6 12.4C2.9 14.1 2 16.4 2 18.8V21.1C2 21.7 2.4 22.1 3 22.1H5.3C7.7 22.1 10 21.2 11.7 19.5L14.9 16.3L20.4 21.8L21.8 20.4L3.8 2.4L2.3 3.7ZM10.2 17.9C8.9 19.2 7.1 20 5.3 20H4V18.7C4 16.8 4.7 15.1 6.1 13.8L9.3 10.6L13.5 14.8L10.2 17.9ZM21.9 9.1L17.2 13.8L15.8 12.4L20.5 7.7C20.9 7.3 20.9 6.7 20.5 6.3L17.7 3.5C17.5 3.2 17.2 3.2 17 3.2C16.8 3.2 16.5 3.2 16.3 3.5L11.6 8.2L10.2 6.8L14.9 2.1C15.5 1.5 16.2 1.2 17 1.2C17.8 1.2 18.5 1.5 19.1 2.1L21.9 4.9C23.1 6 23.1 7.9 21.9 9.1Z"></path></svg>'},2485:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 14.41V23H11V14.41L8.71 16.7L7.3 15.29L12.01 10.58L16.72 15.29L15.31 16.7L13.02 14.41H13ZM20 3H4C2.9 3 2 3.9 2 5V19C2 20.1 2.9 21 4 21H9V19H4V5H20V19H15V21H20C21.1 21 22 20.1 22 19V5C22 3.9 21.1 3 20 3ZM5 6V8H8V6H5ZM19 6H9V8H19V6Z"></path></svg>'},7857:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_19289_560924)"><path d="M8 0C3.58 0 0 3.58 0 8C0 12.42 3.58 16 8 16C12.42 16 16 12.42 16 8C16 3.58 12.42 0 8 0ZM8 14C4.69 14 2 11.31 2 8C2 4.69 4.69 2 8 2C11.31 2 14 4.69 14 8C14 11.31 11.31 14 8 14ZM11.41 6L9.41 8L11.41 10L10 11.41L8 9.41L6 11.41L4.59 10L6.59 8L4.59 6L6 4.59L8 6.59L10 4.59L11.41 6Z"></path></g><defs><clipPath id="clip0_19289_560924"><rect width="16" height="16" fill="transparent"></rect></clipPath></defs></svg>'},7789:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13 7H9V3H7V7H3V9H7V13H9V9H13V7Z"></path></svg>'},7374:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M7 9H4V7H7V4H9V7H12V9H9V12H7V9ZM16 0V16H0V0H16ZM14 2H2V14H14V2Z"></path></svg>'},5208:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M19.9959 2H14.9959V22H21.9959V2H19.9959ZM19.9959 20H16.9959V4H19.9959V20ZM4.40588 11H12.9959V13H4.40588L8.40588 17L6.99588 18.41L0.585876 12L6.99588 5.59L8.40588 7L4.40588 11Z"></path></svg>'},2731:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g id="Expand V 16x16" clip-path="url(#clip0_2625_3196)"><path id="Vector" d="M4.29006 4.71006C3.90006 4.32006 3.90006 3.69006 4.29006 3.30006L7.29006 0.290059C7.68006 -0.0999414 8.31006 -0.0999414 8.70006 0.290059L11.7001 3.29006C12.0901 3.68006 12.0901 4.31006 11.7001 4.70006C11.5001 4.90006 11.2501 4.99006 10.9901 4.99006C10.7301 4.99006 10.4801 4.89006 10.2801 4.70006L8.99006 3.41006V6.00006C8.99006 6.55006 8.54006 7.00006 7.99006 7.00006C7.44006 7.00006 6.99006 6.55006 6.99006 6.00006V3.41006L5.70006 4.70006C5.31006 5.09006 4.68006 5.09006 4.29006 4.70006V4.71006ZM10.2901 11.2901L9.00006 12.5801V9.99006C9.00006 9.44006 8.55006 8.99006 8.00006 8.99006C7.45006 8.99006 7.00006 9.44006 7.00006 9.99006V12.5801L5.71006 11.2901C5.32006 10.9001 4.69006 10.9001 4.30006 11.2901C3.91006 11.6801 3.91006 12.3101 4.30006 12.7001L7.30006 15.7001C7.50006 15.9001 7.75006 15.9901 8.01006 15.9901C8.27006 15.9901 8.52006 15.8901 8.72006 15.7001L11.7201 12.7001C12.1101 12.3101 12.1101 11.6801 11.7201 11.2901C11.3301 10.9001 10.7001 10.9001 10.3101 11.2901H10.2901Z"></path></g><defs><clipPath id="clip0_2625_3196"><rect width="16" height="16" fill="white"></rect></clipPath></defs></svg>'},6294:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M6 14L5 13L10 8L5 3L6 2L12 8L6 14Z"></path></svg>'},5049:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9 6.83L7.59 5.42L12 1L16.41 5.41L15 6.82L13 4.82V10.41H11V4.83L9 6.83ZM13 20V14.41H11V20L9 18L7.59 19.41L12 23.82L16.41 19.41L15 18L13 20ZM20 8.41H15V10.41H20V14.41H15V16.41H20C21.1 16.41 22 15.51 22 14.41V10.41C22 9.31 21.1 8.41 20 8.41ZM9 14.41H4V10.41H9V8.41H4C2.9 8.41 2 9.31 2 10.41V14.41C2 15.51 2.9 16.41 4 16.41H9V14.41Z"></path></svg>'},1403:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M6 10.4059L4.59 8.99591L12 1.58591L19.41 8.99591L18 10.4059L13 5.40591V17.9959H11V5.40591L6 10.4059ZM2 19.9959V21.9959H22V19.9959H2Z"></path></svg>'},1399:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 0.5C19.4 0.2 18.7 0 17.8 0C15.9 0 14.3 0.8 13 2.3C11.5 4.1 10.1 7.1 9 11.5H6.2L5.8 13H8.5L8.3 14C8.2 14.4 8.1 14.9 7.9 15.7C7.7 16.4 7.6 17.1 7.5 17.6C6.8 20.6 6.1 21.9 5.6 22.4C5.6 22.1 5.5 21.8 5.2 21.6C4.7 21.3 3.8 21.2 3.3 21.8C3.1 22 3 22.4 3 22.7C3 23.1 3.1 23.4 3.4 23.6C3.7 23.9 4.2 24 4.8 24C5.4 24 6 23.9 6.5 23.6C7.9 23 9 21.7 9.8 19.6C10.2 18.5 10.8 16.7 11.4 14.1L11.7 12.9H15.1L15.5 11.4H12.1C13.1 7.2 14.2 4.2 15.3 2.7C15.6 2.3 15.9 2 16.2 1.8C16.6 1.5 16.8 1.5 17 1.5C17.2 1.5 17.4 1.5 17.7 1.6C17.5 1.9 17.5 2.2 17.5 2.5C17.5 2.9 17.7 3.3 18 3.6C18.7 4.1 19.8 4.1 20.5 3.6C20.8 3.2 21 2.8 21 2.3C21 1.5 20.7 0.9 20 0.5Z"></path></svg>'},9516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 5H2V3H13V5ZM10 7H2V9H10V7ZM2 17H10V15H2V17ZM13 11H2V13H13V11ZM23.4 14.9L17 21.3C16 22.4 14.5 23 13 23H11.6C11.3 23 11 22.7 11 22.4V21C11 19.5 11.6 18.1 12.7 17L19.1 10.6C19.4 10.2 19.9 10 20.4 10C20.9 10 21.4 10.2 21.7 10.6L23.4 12.3C24.2 13 24.2 14.2 23.4 14.9ZM21.9 13.6L20.3 12L14 18.3C13.4 19.1 13 20 13 21C14 21 14.9 20.6 15.6 19.9L21.9 13.6Z"></path></svg>'},271:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 9V7C22 5.9 21.1 5 20 5H12L10 3H4C2.9 3 2 3.9 2 5V9V10V21H22L24 9H22ZM4 5H9.2L10.6 6.4L11.2 7H12H20V9H4V5ZM20.3 19H4V11H21.6L20.3 19Z"></path></svg>'},4706:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_506_606)"><path opacity="0.75" d="M8.71 11.29L5.71 8.29C5.32 7.9 4.69 7.9 4.3 8.29C3.91 8.68 3.91 9.31 4.3 9.7L5.59 10.99H1C0.45 10.99 0 11.44 0 11.99C0 12.54 0.45 12.99 1 12.99H5.59L4.3 14.28C3.91 14.67 3.91 15.3 4.3 15.69C4.5 15.89 4.75 15.98 5.01 15.98C5.27 15.98 5.52 15.88 5.72 15.69L8.72 12.69C8.81 12.6 8.89 12.49 8.94 12.36C9.04 12.12 9.04 11.84 8.94 11.6C8.89 11.48 8.82 11.37 8.72 11.27L8.71 11.29Z" fill="black" fill-opacity="0.45"></path><path opacity="0.75" d="M15.71 10.29C15.32 9.89999 14.69 9.89999 14.3 10.29C13.91 10.68 13.91 11.31 14.3 11.7L16.3 13.7C16.5 13.9 16.75 13.99 17.01 13.99C17.27 13.99 17.52 13.89 17.72 13.7L23.72 7.69999C24.11 7.30999 24.11 6.67999 23.72 6.28999C23.33 5.89999 22.7 5.89999 22.31 6.28999L21.05 7.54999C19.99 6.57999 18.57 5.98999 17.02 5.98999C13.71 5.98999 11.02 8.67999 11.02 11.99C11.02 15.3 13.71 17.99 17.02 17.99C20.33 17.99 23.02 15.3 23.02 11.99C23.02 11.5 22.96 11.03 22.85 10.58L20.98 12.45C20.75 14.44 19.07 15.99 17.03 15.99C14.82 15.99 13.03 14.2 13.03 11.99C13.03 9.77999 14.82 7.98999 17.03 7.98999C18.03 7.98999 18.93 8.36999 19.63 8.97999L17.03 11.58L15.74 10.29H15.71Z"></path></g><defs><clipPath id="clip0_506_606"><rect width="24" height="24" fill="white"></rect></clipPath></defs></svg>'},3698:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7.85 6.64999L3.35 11.95L7.85 17.35L6.25 18.65L0.75 11.95L6.25 5.34999L7.85 6.64999ZM17.85 5.34999L16.25 6.64999L20.75 11.95L16.25 17.35L17.75 18.65L23.25 12.05L17.85 5.34999ZM8.15 20.65L10.05 21.25L16.05 3.24999L14.15 2.64999L8.15 20.65Z"></path></svg>'},5168:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM20 20H4V4H20V20ZM7 8C7 6.9 7.9 6 9 6C10.1 6 11 6.9 11 8C11 9.1 10.1 10 9 10C7.9 10 7 9.1 7 8ZM19 19H5L9 14L11 15L14 12L19 19Z"></path></svg>'},9630:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 5H4C2.9 5 2 5.9 2 7V20C2 21.1 2.9 22 4 22H17C18.1 22 19 21.1 19 20V7C19 5.9 18.1 5 17 5ZM17 20H4V7H17V20ZM6 11C6 9.9 6.9 9 8 9C9.1 9 10 9.9 10 11C10 12.1 9.1 13 8 13C6.9 13 6 12.1 6 11ZM16 19H5L16 14V19ZM22 4V17C22 18.1 21.1 19 20 19V17V4H7H5C5 2.9 5.9 2 7 2H20C21.1 2 22 2.9 22 4Z"></path></svg>'},5518:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 18.41L4.59 11L6 9.59L11 14.59V2H13V14.59L18 9.59L19.41 11L12 18.41ZM2 20V22H22V20H2Z"></path></svg>'},4925:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 7.003C12.4641 7.01107 12.9249 7.08171 13.37 7.213L11.54 9.053C10.9155 9.15262 10.3384 9.44704 9.89125 9.89423C9.44406 10.3414 9.14964 10.9185 9.05002 11.543L7.21002 13.373C7.07873 12.9279 7.00809 12.467 7.00002 12.003C7.00002 10.6769 7.5268 9.40515 8.46449 8.46747C9.40217 7.52978 10.6739 7.003 12 7.003ZM5.40002 15.183C4.39516 14.2466 3.52369 13.1766 2.81002 12.003C5.10002 8.223 8.47002 6.003 12 6.003C12.765 6.0082 13.5255 6.11925 14.26 6.333L15.86 4.733C14.6291 4.25486 13.3206 4.0074 12 4.003C7.24002 4.003 3.05002 7.173 0.52002 12.003C1.41557 13.7255 2.59165 15.2868 4.00002 16.623L5.40002 15.183ZM23.48 12.003C21 16.833 16.76 20.003 12 20.003C10.1707 19.9916 8.37315 19.5242 6.77002 18.643L2.71002 22.713L1.29002 21.293L21.29 1.293L22.71 2.713L18.94 6.473C20.8367 7.96509 22.3858 9.8521 23.48 12.003ZM14.7 10.723L10.7 14.723C11.1058 14.9158 11.5508 15.0116 12 15.003C12.7957 15.003 13.5587 14.6869 14.1213 14.1243C14.6839 13.5617 15 12.7986 15 12.003C14.9993 11.559 14.8967 11.1211 14.7 10.723ZM21.19 12.003C20.243 10.4087 18.9887 9.01851 17.5 7.913L16.16 9.263C16.7052 10.073 16.9975 11.0266 17 12.003C17 13.3291 16.4732 14.6009 15.5356 15.5385C14.5979 16.4762 13.3261 17.003 12 17.003C11.0237 17.0005 10.07 16.7081 9.26002 16.163L8.26002 17.163C9.43056 17.7122 10.707 17.9989 12 18.003C15.53 18.003 18.9 15.783 21.19 12.003Z"></path></svg>'},8516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 5L12 0L7 5H11V9H13V5H17Z"></path><path d="M13 19V15H11V19H7L12 24L17 19H13Z"></path></svg>'},6247:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17.75 8H15.25L13.35 13.08C12.2029 12.2588 11.2439 11.2027 10.537 9.98187C9.83 8.76107 9.39127 7.40364 9.25 6H14V4H9V2H7V4H2V6H6.91C6.73189 7.75797 6.09115 9.43736 5.05302 10.8672C4.01489 12.2971 2.61643 13.4263 1 14.14C1.32315 14.7296 1.69441 15.2915 2.11 15.82C4.82764 14.5445 6.96846 12.2966 8.11 9.52C9.02641 11.7596 10.5985 13.6698 12.62 15L10 22H12.42L13.79 18.13H19.16L20.56 22H23L17.75 8ZM14.46 16.16L15.73 12.53C16.0406 11.7049 16.2945 10.8596 16.49 10C16.55 10.26 16.67 10.66 16.84 11.21C17.01 11.76 17.14 12.15 17.24 12.41L18.55 16.2L14.46 16.16Z"></path></svg>'},2937:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21.93 9H21V7C21 6.46957 20.7893 5.96086 20.4142 5.58579C20.0391 5.21071 19.5304 5 19 5H10L8 3H4C3.46957 3 2.96086 3.21071 2.58579 3.58579C2.21071 3.96086 2 4.46957 2 5L2 21H21L23.89 11.63C23.9916 11.3244 24.0179 10.9988 23.9667 10.6809C23.9155 10.363 23.7882 10.0621 23.5958 9.80392C23.4034 9.54571 23.1514 9.33779 22.8614 9.19782C22.5714 9.05786 22.2519 8.99 21.93 9ZM4 5H7.17L8.59 6.41L9.17 7H19V9H6L4 15V5ZM22 11L19.54 19H4.77L7.44 11H22Z"></path></svg>'},9730:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M18 14.59L16.59 16L18.59 18H7.82C7.79 17.9 7.75 17.81 7.7 17.71L17.71 7.7C18.1 7.89 18.53 8 19 8C20.65 8 22 6.65 22 5C22 3.35 20.65 2 19 2C17.7 2 16.6 2.84 16.18 4H7.82C7.41 2.84 6.31 2 5 2C3.35 2 2 3.35 2 5C2 6.65 3.35 8 5 8C6.3 8 7.4 7.16 7.82 6H16.19C16.22 6.1 16.26 6.19 16.31 6.29L6.29 16.3C5.9 16.11 5.47 16 5 16C3.35 16 2 17.35 2 19C2 20.65 3.35 22 5 22C6.3 22 7.4 21.16 7.82 20H18.59L16.59 22L18 23.41L22.41 19L18 14.59ZM19 4C19.55 4 20 4.45 20 5C20 5.55 19.55 6 19 6C18.45 6 18 5.55 18 5C18 4.45 18.45 4 19 4ZM5 6C4.45 6 4 5.55 4 5C4 4.45 4.45 4 5 4C5.55 4 6 4.45 6 5C6 5.55 5.55 6 5 6ZM5 20C4.45 20 4 19.55 4 19C4 18.45 4.45 18 5 18C5.55 18 6 18.45 6 19C6 19.55 5.55 20 5 20Z"></path></svg>'},1523:e=>{e.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_252_57732)"><path d="M19 29.2996L20.4 30.6996L22.7 28.3996V33.9996H24.7V28.3996L27 30.6996L28.4 29.2996L23.7 24.5996L19 29.2996Z"></path><path d="M24.7 19.6V14H22.7V19.6L20.4 17.3L19 18.7L23.7 23.4L28.4 18.7L27 17.3L24.7 19.6Z"></path></g><defs><clipPath id="clip0_252_57732"><rect width="9.4" height="20" fill="white" transform="translate(19 14)"></rect></clipPath></defs></svg>'},1390:e=>{e.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_252_57727)"><path d="M19 17.7L20.4 19.1L22.7 16.8V22.4H24.7V16.8L27 19.1L28.4 17.7L23.7 13L19 17.7Z"></path><path d="M24.7 32.0004V26.4004H22.7V32.0004L20.4 29.7004L19 31.1004L23.7 35.8004L28.4 31.1004L27 29.7004L24.7 32.0004Z"></path></g><defs><clipPath id="clip0_252_57727"><rect width="9.4" height="22.8" fill="white" transform="translate(19 13)"></rect></clipPath></defs></svg>'},780:e=>{e.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"><path d="M28 0H4C1.79 0 0 1.79 0 4V28C0 30.21 1.79 32 4 32H28C30.21 32 32 30.21 32 28V4C32 1.79 30.21 0 28 0ZM30 28C30 29.1 29.1 30 28 30H4C2.9 30 2 29.1 2 28V4C2 2.9 2.9 2 4 2H28C29.1 2 30 2.9 30 4V28ZM6 9C6 7.34 7.34 6 9 6C10.66 6 12 7.34 12 9C12 10.66 10.66 12 9 12C7.34 12 6 10.66 6 9ZM19 16L28 28H4L11 19L15 21L19 16Z"></path></svg>'},7466:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M6 1C3.2 1 1 3.2 1 6C1 8.8 3.2 11 6 11C8.8 11 11 8.8 11 6C11 3.2 8.8 1 6 1ZM6 9C4.3 9 3 7.7 3 6C3 4.3 4.3 3 6 3C7.7 3 9 4.3 9 6C9 7.7 7.7 9 6 9ZM8 6C8 7.1 7.1 8 6 8C4.9 8 4 7.1 4 6C4 4.9 4.9 4 6 4C7.1 4 8 4.9 8 6ZM20 18C20 19.1 19.1 20 18 20C16.9 20 16 19.1 16 18C16 16.9 16.9 16 18 16C19.1 16 20 16.9 20 18ZM6 13C3.2 13 1 15.2 1 18C1 20.8 3.2 23 6 23C8.8 23 11 20.8 11 18C11 15.2 8.8 13 6 13ZM6 21C4.3 21 3 19.7 3 18C3 16.3 4.3 15 6 15C7.7 15 9 16.3 9 18C9 19.7 7.7 21 6 21ZM18 11C20.8 11 23 8.8 23 6C23 3.2 20.8 1 18 1C15.2 1 13 3.2 13 6C13 8.8 15.2 11 18 11ZM18 3C19.7 3 21 4.3 21 6C21 7.7 19.7 9 18 9C16.3 9 15 7.7 15 6C15 4.3 16.3 3 18 3ZM18 13C15.2 13 13 15.2 13 18C13 20.8 15.2 23 18 23C20.8 23 23 20.8 23 18C23 15.2 20.8 13 18 13ZM18 21C16.3 21 15 19.7 15 18C15 16.3 16.3 15 18 15C19.7 15 21 16.3 21 18C21 19.7 19.7 21 18 21Z"></path></svg>'},8125:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 4C7 5.7 5.7 7 4 7C2.3 7 1 5.7 1 4C1 2.3 2.3 1 4 1C5.7 1 7 2.3 7 4ZM15 4C15 5.7 13.7 7 12 7C10.3 7 9 5.7 9 4C9 2.3 10.3 1 12 1C13.7 1 15 2.3 15 4ZM13 4C13 3.4 12.6 3 12 3C11.4 3 11 3.4 11 4C11 4.6 11.4 5 12 5C12.6 5 13 4.6 13 4ZM17 4C17 2.3 18.3 1 20 1C21.7 1 23 2.3 23 4C23 5.7 21.7 7 20 7C18.3 7 17 5.7 17 4ZM19 4C19 4.6 19.4 5 20 5C20.6 5 21 4.6 21 4C21 3.4 20.6 3 20 3C19.4 3 19 3.4 19 4ZM7 12C7 13.7 5.7 15 4 15C2.3 15 1 13.7 1 12C1 10.3 2.3 9 4 9C5.7 9 7 10.3 7 12ZM5 12C5 11.4 4.6 11 4 11C3.4 11 3 11.4 3 12C3 12.6 3.4 13 4 13C4.6 13 5 12.6 5 12ZM12 9C10.3 9 9 10.3 9 12C9 13.7 10.3 15 12 15C13.7 15 15 13.7 15 12C15 10.3 13.7 9 12 9ZM20 9C18.3 9 17 10.3 17 12C17 13.7 18.3 15 20 15C21.7 15 23 13.7 23 12C23 10.3 21.7 9 20 9ZM4 17C2.3 17 1 18.3 1 20C1 21.7 2.3 23 4 23C5.7 23 7 21.7 7 20C7 18.3 5.7 17 4 17ZM12 17C10.3 17 9 18.3 9 20C9 21.7 10.3 23 12 23C13.7 23 15 21.7 15 20C15 18.3 13.7 17 12 17ZM23 20C23 21.7 21.7 23 20 23C18.3 23 17 21.7 17 20C17 18.3 18.3 17 20 17C21.7 17 23 18.3 23 20ZM21 20C21 19.4 20.6 19 20 19C19.4 19 19 19.4 19 20C19 20.6 19.4 21 20 21C20.6 21 21 20.6 21 20Z"></path></svg>'},169:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 4C7 5.7 5.7 7 4 7C2.3 7 1 5.7 1 4C1 2.3 2.3 1 4 1C5.7 1 7 2.3 7 4ZM15 4C15 5.7 13.7 7 12 7C10.3 7 9 5.7 9 4C9 2.3 10.3 1 12 1C13.7 1 15 2.3 15 4ZM13 4C13 3.4 12.6 3 12 3C11.4 3 11 3.4 11 4C11 4.6 11.4 5 12 5C12.6 5 13 4.6 13 4ZM17 4C17 2.3 18.3 1 20 1C21.7 1 23 2.3 23 4C23 5.7 21.7 7 20 7C18.3 7 17 5.7 17 4ZM19 4C19 4.6 19.4 5 20 5C20.6 5 21 4.6 21 4C21 3.4 20.6 3 20 3C19.4 3 19 3.4 19 4ZM7 12C7 13.7 5.7 15 4 15C2.3 15 1 13.7 1 12C1 10.3 2.3 9 4 9C5.7 9 7 10.3 7 12ZM5 12C5 11.4 4.6 11 4 11C3.4 11 3 11.4 3 12C3 12.6 3.4 13 4 13C4.6 13 5 12.6 5 12ZM12 9C10.3 9 9 10.3 9 12C9 13.7 10.3 15 12 15C13.7 15 15 13.7 15 12C15 10.3 13.7 9 12 9ZM20 9C18.3 9 17 10.3 17 12C17 13.7 18.3 15 20 15C21.7 15 23 13.7 23 12C23 10.3 21.7 9 20 9ZM5 17H3V19H1V21H3V23H5V21H7V19H5V17Z"></path></svg>'},6544:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 1H4C2.9 1 2 1.9 2 3V9C2 10.1 2.9 11 4 11H20C21.1 11 22 10.1 22 9V3C22 1.9 21.1 1 20 1ZM20 9H4V3H20V9ZM14 7H6V5H14V7ZM20 13H4C2.9 13 2 13.9 2 15V21C2 22.1 2.9 23 4 23H20C21.1 23 22 22.1 22 21V15C22 13.9 21.1 13 20 13ZM20 21H4V15H20V21ZM14 19H6V17H14V19Z"></path></svg>'},5265:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.64648 12.6465L6.34648 13.3465L11.7465 8.04648L6.34648 2.64648L5.64648 3.34648L10.2465 8.04648L5.64648 12.6465Z"></path></svg>'},8273:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 2V4H4V9H2V4C2 2.9 2.9 2 4 2H9ZM20 2H15V4H20V9H22V4C22 2.9 21.1 2 20 2ZM4 20V15H2V20C2 21.1 2.9 22 4 22H9V20H4ZM20 20H15V22H20C21.1 22 22 21.1 22 20V15H20V20Z"></path></svg>'},4520:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 2V4H4V9H2V4C2 3.46957 2.21071 2.96086 2.58579 2.58579C2.96086 2.21071 3.46957 2 4 2H9ZM20 2H15V4H20V9H22V4C22 3.46957 21.7893 2.96086 21.4142 2.58579C21.0391 2.21071 20.5304 2 20 2ZM4 20V15H2V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H9V20H4ZM20 20H15V22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V15H20V20ZM17 13H15V11H13V13H11V15H13V17H15V15H17V13Z"></path></svg>'},2804:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 8H19V1H5V8H4V13H5V13.14C5 14.72 6.28 16 7.86 16C8.2 16 8.41 16.19 8.51 16.3C8.61 16.41 8.76 16.65 8.71 16.98L8.44 18.89C8.29 19.92 8.6 20.97 9.28 21.76C9.96 22.55 10.96 23 12 23C13.04 23 14.04 22.55 14.72 21.76C15.4 20.97 15.71 19.93 15.57 18.89L15.3 16.98C15.25 16.64 15.41 16.41 15.5 16.3C15.59 16.19 15.81 16 16.15 16C17.73 16 19.01 14.72 19.01 13.14V13H20.01V8H20ZM18 11H6V10H18V11ZM7 3H11V5H13V3H14V6H16V3H17V8H7V3ZM17 13.14C17 13.61 16.62 14 16.14 14C15.31 14 14.52 14.36 13.98 14.98C13.44 15.61 13.19 16.44 13.31 17.26L13.58 19.17C13.65 19.64 13.51 20.09 13.2 20.45C12.59 21.15 11.39 21.15 10.78 20.45C10.47 20.09 10.34 19.64 10.4 19.17L10.67 17.26C10.79 16.44 10.54 15.61 10 14.98C9.46 14.35 8.67 13.99 7.84 13.99C7.37 13.99 6.98 13.61 6.98 13.13V12.99H16.98V13.13L17 13.14ZM11 19C11 18.45 11.45 18 12 18C12.55 18 13 18.45 13 19C13 19.55 12.55 20 12 20C11.45 20 11 19.55 11 19Z"></path></g></svg>'},5574:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M6 9.41L4.59 8L8 4.59L9.41 6L6 9.41ZM14.41 6L13 4.59L4.59 13L6 14.41L14.41 6ZM4.59 18L6 19.41L19.41 6L18 4.59L4.59 18ZM9.59 18L11 19.41L19.41 11L18 9.59L9.59 18ZM14.59 18L16 19.41L19.41 16L18 14.59L14.59 18ZM22 4V20C22 21.1 21.1 22 20 22H4C2.9 22 2 21.1 2 20V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.9 22 4ZM20 20V4H4V20H20Z"></path></g></svg>'},1965:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M22 3V21H20V3H22ZM14 21H16V3H14V21ZM8 21H10V3H8V21ZM2 21H4V3H2V21Z"></path></g></svg>'},1144:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M18 14.59L16.59 16L18.59 18H7.82C7.79 17.9 7.75 17.81 7.7 17.71L17.71 7.7C18.1 7.89 18.53 8 19 8C20.65 8 22 6.65 22 5C22 3.35 20.65 2 19 2C17.7 2 16.6 2.84 16.18 4H7.82C7.41 2.84 6.31 2 5 2C3.35 2 2 3.35 2 5C2 6.65 3.35 8 5 8C6.3 8 7.4 7.16 7.82 6H16.19C16.22 6.1 16.26 6.19 16.31 6.29L6.29 16.3C5.9 16.11 5.47 16 5 16C3.35 16 2 17.35 2 19C2 20.65 3.35 22 5 22C6.3 22 7.4 21.16 7.82 20H18.59L16.59 22L18 23.41L22.41 19L18 14.59ZM19 4C19.55 4 20 4.45 20 5C20 5.55 19.55 6 19 6C18.45 6 18 5.55 18 5C18 4.45 18.45 4 19 4ZM5 6C4.45 6 4 5.55 4 5C4 4.45 4.45 4 5 4C5.55 4 6 4.45 6 5C6 5.55 5.55 6 5 6ZM5 20C4.45 20 4 19.55 4 19C4 18.45 4.45 18 5 18C5.55 18 6 18.45 6 19C6 19.55 5.55 20 5 20Z"></path></g></svg>'},386:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M12 2C8.02 2 4 3.37 4 6V18C4 20.63 8.02 22 12 22C15.98 22 20 20.63 20 18V6C20 3.37 15.98 2 12 2ZM12 4C15.72 4 18 5.29 18 6C18 6.71 15.72 8 12 8C8.28 8 6 6.71 6 6C6 5.29 8.28 4 12 4ZM12 20C8.28 20 6 18.71 6 18V16.73C7.54 17.57 9.78 18 12 18C14.22 18 16.46 17.57 18 16.73V18C18 18.71 15.72 20 12 20ZM18 14C18 14.71 15.72 16 12 16C8.28 16 6 14.71 6 14V12.73C7.54 13.57 9.78 14 12 14C14.22 14 16.46 13.57 18 12.73V14ZM18 10C18 10.71 15.72 12 12 12C8.28 12 6 10.71 6 10V8.73C7.54 9.57 9.78 10 12 10C14.22 10 16.46 9.57 18 8.73V10Z"></path></g></svg>'},4300:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M2.59 22H22V2.59L2.59 22ZM20 20H7.41L20 7.41V20ZM13 18L18 13V18H13ZM10 8C11.1 8 12 8.9 12 10C12 11.1 11.1 12 10 12C8.9 12 8 11.1 8 10C8 8.9 8.9 8 10 8ZM2 9.83C2 8.89 2.61 8.09 3.45 7.8C3.56 7.44 3.71 7.09 3.89 6.75C3.75 6.46 3.67 6.13 3.67 5.8C3.67 5.23 3.89 4.69 4.3 4.29C4.94 3.65 5.97 3.5 6.76 3.89C7.1 3.71 7.45 3.57 7.81 3.45C8.1 2.61 8.9 2 9.84 2C10.78 2 11.58 2.61 11.87 3.45C12.23 3.56 12.58 3.71 12.92 3.89C13.71 3.5 14.74 3.65 15.38 4.3C15.78 4.7 16.01 5.24 16.01 5.81C16.01 6.38 15.79 6.92 15.38 7.32L14.67 8.03L13.26 6.61L13.97 5.9C13.97 5.9 14.01 5.83 14.01 5.8C14.01 5.77 14.01 5.74 13.97 5.7C13.9 5.63 13.84 5.63 13.77 5.7L13.1 6.36L12.42 5.91C11.91 5.57 11.36 5.34 10.78 5.22L9.98 5.06V4.13C9.98 3.98 9.7 3.98 9.7 4.13V5.06L8.9 5.22C8.32 5.34 7.76 5.57 7.26 5.91L6.58 6.36L5.92 5.7C5.84 5.63 5.79 5.63 5.72 5.7C5.68 5.74 5.68 5.77 5.68 5.8C5.68 5.83 5.68 5.86 5.72 5.9L6.38 6.57L5.93 7.25C5.59 7.76 5.36 8.31 5.24 8.89L5.08 9.69H4.15C4.07 9.69 4.01 9.75 4.01 9.83C4.01 9.91 4.07 9.97 4.15 9.97H5.08L5.24 10.77C5.36 11.35 5.59 11.91 5.93 12.41L6.38 13.09L5.72 13.75C5.72 13.75 5.68 13.83 5.68 13.85C5.68 13.87 5.68 13.91 5.72 13.95C5.79 14.02 5.85 14.02 5.92 13.95L6.63 13.24L8.05 14.65L7.34 15.36C6.94 15.77 6.4 15.99 5.83 15.99C5.26 15.99 4.72 15.77 4.32 15.36C3.92 14.96 3.69 14.42 3.69 13.85C3.69 13.51 3.77 13.19 3.91 12.9C3.73 12.56 3.59 12.21 3.47 11.85C2.63 11.56 2.02 10.76 2.02 9.82L2 9.83Z"></path></g></svg>'},3236:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM6 7H9V9H6V7ZM12 7H18V9H12V7ZM6 11H9V13H6V11ZM12 11H18V13H12V11ZM6 15H9V17H6V15ZM12 15H18V17H12V15Z"></path></g></svg>'},833:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M21 2H3C1.9 2 1 2.9 1 4V15C1 16.1 1.9 17 3 17H21C22.1 17 23 16.1 23 15V4C23 2.9 22.1 2 21 2ZM4.41 15L9 10.41L12 13.41L14 11.41L17.59 15H4.41ZM20.41 15L14 8.59L12 10.59L9 7.59L3 13.59V4H21V15H20.41ZM19 7.5C19 8.33 18.33 9 17.5 9C16.67 9 16 8.33 16 7.5C16 6.67 16.67 6 17.5 6C18.33 6 19 6.67 19 7.5ZM8 21H16V23H8V21ZM6 18H18V20H6V18Z"></path></g></svg>'},1624:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version = v1"><path id="Vector" d="M17.75 8H15.25L13.35 13.08C12.2029 12.2588 11.2439 11.2027 10.537 9.98187C9.83 8.76107 9.39127 7.40364 9.25 6H14V4H9V2H7V4H2V6H6.91C6.73189 7.75797 6.09115 9.43736 5.05302 10.8672C4.01489 12.2971 2.61643 13.4263 1 14.14C1.32315 14.7296 1.69441 15.2915 2.11 15.82C4.82764 14.5445 6.96846 12.2966 8.11 9.52C9.02641 11.7596 10.5985 13.6698 12.62 15L10 22H12.42L13.79 18.13H19.16L20.56 22H23L17.75 8ZM14.46 16.16L15.73 12.53C16.0406 11.7049 16.2945 10.8596 16.49 10C16.55 10.26 16.67 10.66 16.84 11.21C17.01 11.76 17.14 12.15 17.24 12.41L18.55 16.2L14.46 16.16Z"></path></g></svg>'},5764:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V9C2 10.1 2.9 11 4 11H20C21.1 11 22 10.1 22 9V4C22 2.9 21.1 2 20 2ZM4 9V4H20V9H4ZM11 12H4C2.9 12 2 12.9 2 14V20C2 21.1 2.9 22 4 22H11C12.1 22 13 21.1 13 20V14C13 12.9 12.1 12 11 12ZM4 20V14H11V20H4ZM20 12H16C14.9 12 14 12.9 14 14V20C14 21.1 14.9 22 16 22H20C21.1 22 22 21.1 22 20V14C22 12.9 21.1 12 20 12ZM16 20V14H20V20H16Z"></path></g></svg>'},9551:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM20 4V17.59L15 12.59L13 14.59L10 11.59L4 17.59V4H20ZM19.59 20H4.41L10 14.41L13 17.41L15 15.41L19.59 20ZM14 8C14 6.9 14.9 6 16 6C17.1 6 18 6.9 18 8C18 9.1 17.1 10 16 10C14.9 10 14 9.1 14 8Z"></path></g></svg>'},5e3:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M5 12L10 8V16L5 12ZM14 8V16L19 12L14 8ZM23 12C23 18.07 18.07 23 12 23C5.93 23 1 18.07 1 12C1 5.93 5.93 1 12 1C18.07 1 23 5.93 23 12ZM21 12C21 7.04 16.96 3 12 3C7.04 3 3 7.04 3 12C3 16.96 7.04 21 12 21C16.96 21 21 16.96 21 12Z"></path></g></svg>'},1780:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M19 1H5C3.9 1 3 1.9 3 3V21C3 22.1 3.9 23 5 23H19C20.1 23 21 22.1 21 21V3C21 1.9 20.1 1 19 1ZM5 21V3H19V21H5ZM11 7H7V5H11V7ZM7 8H17V10H7V8ZM7 11H17V13H7V11ZM7 14H17V16H7V14ZM12 17H17V19H12V17Z"></path></g></svg>'},5824:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20.01 14.98H22.01V17.98C22.01 19.08 21.11 19.98 20.01 19.98H12.42L8.71 23.69C8.52 23.88 8.26 23.98 8 23.98C7.87 23.98 7.74 23.96 7.62 23.9C7.25 23.75 7 23.38 7 22.98V19.98H4C2.9 19.98 2 19.08 2 17.98V3.98C2 2.88 2.9 1.98 4 1.98H8V3.98H4.01V17.98H8.01C8.56 17.98 9.01 18.43 9.01 18.98V20.57L11.3 18.28C11.49 18.09 11.74 17.99 12.01 17.99H20.01V14.99V14.98ZM23.01 7.48C23.01 8.39 22.43 9.16 21.62 9.44C21.51 9.77 21.38 10.09 21.22 10.4C21.59 11.17 21.46 12.13 20.82 12.78C20.43 13.17 19.9 13.39 19.35 13.39C19.03 13.39 18.73 13.32 18.45 13.18C18.14 13.34 17.82 13.47 17.49 13.58C17.2 14.39 16.43 14.97 15.53 14.97C14.63 14.97 13.85 14.39 13.57 13.58C13.24 13.47 12.92 13.34 12.61 13.18C11.85 13.55 10.85 13.39 10.23 12.77C9.84 12.38 9.62 11.85 9.62 11.3C9.62 10.98 9.69 10.67 9.83 10.4C9.67 10.09 9.54 9.77 9.43 9.44C8.62 9.15 8.04 8.38 8.04 7.48C8.04 6.58 8.62 5.8 9.43 5.52C9.54 5.19 9.67 4.87 9.83 4.56C9.7 4.28 9.62 3.97 9.62 3.66C9.62 3.1 9.84 2.58 10.23 2.19C10.87 1.55 11.83 1.41 12.61 1.79C12.92 1.63 13.24 1.5 13.57 1.39C13.86 0.58 14.63 0 15.53 0C16.43 0 17.21 0.58 17.49 1.39C17.82 1.5 18.14 1.63 18.45 1.79C19.22 1.42 20.18 1.55 20.83 2.19C21.47 2.83 21.61 3.79 21.24 4.57C21.4 4.88 21.53 5.2 21.64 5.53C22.45 5.82 23.03 6.59 23.03 7.49L23.01 7.48ZM21.01 7.48C21.01 7.48 20.97 7.4 20.93 7.4H20L19.84 6.6C19.73 6.05 19.51 5.53 19.19 5.05L18.74 4.37L19.4 3.71C19.4 3.71 19.43 3.62 19.4 3.59C19.37 3.56 19.32 3.56 19.28 3.59L18.62 4.25L17.94 3.8C17.46 3.48 16.94 3.27 16.39 3.15L15.59 2.99V2.06C15.59 1.97 15.42 1.97 15.42 2.06V2.99L14.62 3.15C14.07 3.26 13.55 3.48 13.07 3.8L12.39 4.25L11.73 3.59C11.73 3.59 11.65 3.56 11.61 3.59V3.71L12.26 4.37L11.81 5.05C11.49 5.53 11.28 6.05 11.16 6.6L11 7.4H10.07C10.07 7.4 9.99 7.44 9.99 7.48C9.99 7.52 10.03 7.56 10.07 7.56H11L11.16 8.36C11.27 8.91 11.49 9.43 11.81 9.91L12.26 10.59L11.61 11.25V11.37H11.73L12.39 10.72L13.07 11.17C13.55 11.49 14.07 11.71 14.62 11.82L15.42 11.98V12.91C15.42 13 15.59 13 15.59 12.91V11.98L16.39 11.82C16.94 11.71 17.46 11.49 17.94 11.17L18.62 10.72L19.28 11.38H19.4C19.4 11.38 19.43 11.3 19.4 11.26L18.74 10.6L19.19 9.92C19.51 9.44 19.72 8.92 19.84 8.37L20 7.57H20.93C20.93 7.57 21.01 7.53 21.01 7.49V7.48ZM15.51 4.98C14.13 4.98 13.01 6.1 13.01 7.48C13.01 8.86 14.13 9.98 15.51 9.98C16.89 9.98 18.01 8.86 18.01 7.48C18.01 6.1 16.89 4.98 15.51 4.98Z"></path></g></svg>'},1557:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M19.26 7.15L20.41 6L19 4.59L17.75 5.84C16.12 4.69 14.14 4.01 12 4.01C9.86 4.01 7.88 4.69 6.25 5.84L5 4.59L3.59 6L4.74 7.15C3.05 8.94 2 11.35 2 14C2 19.51 6.49 24 12 24C17.51 24 22 19.51 22 14C22 11.35 20.96 8.94 19.26 7.15ZM12 22C7.59 22 4 18.41 4 14C4 9.59 7.59 6 12 6C16.41 6 20 9.59 20 14C20 18.41 16.41 22 12 22ZM15 8.58L16.41 9.99L12 14.4L10.59 12.99L15 8.58ZM9.2 3.36L8.83 1.4L9.81 1.21C11.29 0.93 12.7 0.93 14.18 1.21L15.16 1.4L14.79 3.36L13.81 3.17C12.57 2.94 11.42 2.94 10.18 3.17L9.2 3.36Z"></path></g></svg>'},7613:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M21 2V4H3V2H21ZM3 10H21V8H3V10ZM3 16H21V14H3V16ZM3 22H21V20H3V22Z"></path></g></svg>'},6534:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1" clip-path="url(#clip0_22397_60021)"><path id="Vector" d="M20 10.005H22V18.005C22 19.105 21.1 20.005 20 20.005H12.41L8.69999 23.715C8.50999 23.905 8.24999 24.005 7.98999 24.005C7.85999 24.005 7.72999 23.985 7.60999 23.925C7.23999 23.775 6.98999 23.405 6.98999 23.005V20.005H4.98999C3.33999 20.005 1.98999 18.655 1.98999 17.005V5.005C1.99999 3.355 3.34999 2.005 4.99999 2.005H14V4.005H4.99999C4.44999 4.005 3.99999 4.455 3.99999 5.005V17.005C3.99999 17.555 4.44999 18.005 4.99999 18.005H7.99999C8.54999 18.005 8.99999 18.455 8.99999 19.005V20.595L11.29 18.305C11.48 18.115 11.73 18.015 12 18.015H20V10.015V10.005ZM10.1 9.49501L16.79 2.795C18.01 1.575 19.99 1.575 21.2 2.795C22.41 4.015 22.42 5.99501 21.2 7.20501L14.5 13.905L8.60999 15.375L10.08 9.485L10.1 9.49501ZM18.21 4.215L17.42 5.005L19.01 6.59501L19.8 5.80501C20.01 5.59501 20.13 5.31501 20.13 5.01501C20.13 4.71501 20.01 4.435 19.8 4.225C19.38 3.805 18.64 3.805 18.21 4.225V4.215ZM11.37 12.635L13.48 12.105L17.58 8.005L15.99 6.41501L11.89 10.515L11.36 12.625L11.37 12.635Z"></path></g><defs><clipPath id="clip0_22397_60021"><rect width="24" height="24" fill="white"></rect></clipPath></defs></svg>'},1703:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M15.0001 13.59L19.4101 18L18.0001 19.41L13.5901 15L15.0001 13.59ZM15.0001 10.42L13.4101 12.01L12.0001 13.42L6.00009 19.42L4.59009 18.01L10.5901 12.01L9.00009 10.42L5.00009 14.42L0.590088 10L4.59009 6L3.59009 5L5.00009 3.59L6.00009 4.59L10.4101 9L12.0001 10.59L13.5901 9L18.0001 4.59L19.0001 3.59L20.4101 5L19.4101 6L23.4101 10L19.0001 14.41L15.0001 10.41V10.42ZM7.59009 9L6.00009 7.41L3.41009 10L5.00009 11.59L7.59009 9ZM16.4201 9L19.0101 11.59L20.6001 10L18.0101 7.41L16.4201 9Z"></path></g></svg>'},4992:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM11 5H5V11H11V5ZM9 9H7V7H9V9ZM12 12H19V5H12V12ZM14 7H17V10H14V7ZM13 19H19V13H13V19ZM15 15H17V17H15V15ZM5 19H12V12H5V19ZM7 14H10V17H7V14Z"></path></g></svg>'},5891:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20.0001 5H7.42009L14.4201 12L7.42009 19H20.0101V21H2.59009L11.5901 12L2.59009 3H20.0001V5Z"></path></g></svg>'},9324:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M3.34 5.325C3.57 5.785 3.41 6.335 2.99 6.615C2.93 7.115 2.51 7.505 2 7.505C1.45 7.505 1 7.055 1 6.505V6.005C1 5.625 1.21 5.275 1.55 5.115L2 4.895C2.49 4.645 3.09 4.845 3.34 5.345V5.325ZM2 15.415C2.55 15.415 3 14.965 3 14.415V13.535C3 12.985 2.55 12.535 2 12.535C1.45 12.535 1 12.985 1 13.535V14.415C1 14.965 1.45 15.415 2 15.415ZM2 11.455C2.55 11.455 3 11.005 3 10.455V9.575C3 9.025 2.55 8.575 2 8.575C1.45 8.575 1 9.025 1 9.575V10.455C1 11.005 1.45 11.455 2 11.455ZM2.99 17.385C2.93 16.885 2.51 16.495 2 16.495C1.45 16.495 1 16.945 1 17.495V17.995C1 18.375 1.21 18.725 1.55 18.885L2 19.105C2.14 19.175 2.3 19.215 2.45 19.215C2.82 19.215 3.17 19.015 3.35 18.665C3.58 18.205 3.42 17.655 3 17.375L2.99 17.385ZM9.45 20.605L8.72 20.245C8.23 19.995 7.63 20.195 7.38 20.695C7.13 21.185 7.33 21.785 7.83 22.035L8.56 22.395C8.7 22.465 8.86 22.505 9.01 22.505C9.38 22.505 9.73 22.305 9.91 21.955C10.16 21.465 9.96 20.865 9.46 20.615L9.45 20.605ZM6.17 18.965L5.44 18.605C4.95 18.355 4.35 18.555 4.1 19.055C3.85 19.545 4.05 20.145 4.55 20.395L5.28 20.755C5.42 20.825 5.58 20.865 5.73 20.865C6.1 20.865 6.45 20.665 6.63 20.315C6.88 19.825 6.68 19.225 6.18 18.975L6.17 18.965ZM12 21.875C11.51 21.625 10.91 21.825 10.66 22.325C10.41 22.815 10.61 23.415 11.11 23.665L11.56 23.885C11.7 23.955 11.85 23.995 12.01 23.995C12.17 23.995 12.32 23.955 12.46 23.885L12.91 23.665C13.4 23.415 13.6 22.815 13.36 22.325C13.11 21.835 12.51 21.635 12.02 21.875H12ZM18.56 18.595L17.83 18.955C17.34 19.205 17.14 19.805 17.38 20.295C17.56 20.645 17.91 20.845 18.28 20.845C18.43 20.845 18.58 20.815 18.73 20.735L19.46 20.375C19.95 20.125 20.15 19.525 19.91 19.035C19.66 18.545 19.06 18.345 18.57 18.585L18.56 18.595ZM15.28 20.235L14.55 20.595C14.06 20.845 13.86 21.445 14.1 21.935C14.28 22.285 14.63 22.485 15 22.485C15.15 22.485 15.3 22.455 15.45 22.375L16.18 22.015C16.67 21.765 16.87 21.165 16.63 20.675C16.38 20.185 15.78 19.985 15.29 20.225L15.28 20.235ZM22 16.495C21.49 16.495 21.06 16.885 21.01 17.385C20.59 17.655 20.43 18.215 20.66 18.675C20.84 19.025 21.19 19.225 21.56 19.225C21.71 19.225 21.86 19.195 22.01 19.115L22.46 18.895C22.8 18.725 23.01 18.375 23.01 18.005V17.505C23.01 16.955 22.56 16.505 22.01 16.505L22 16.495ZM22 12.535C21.45 12.535 21 12.985 21 13.535V14.415C21 14.965 21.45 15.415 22 15.415C22.55 15.415 23 14.965 23 14.415V13.535C23 12.985 22.55 12.535 22 12.535ZM22 8.575C21.45 8.575 21 9.025 21 9.575V10.455C21 11.005 21.45 11.455 22 11.455C22.55 11.455 23 11.005 23 10.455V9.575C23 9.025 22.55 8.575 22 8.575ZM22.45 5.105L22 4.885C21.51 4.635 20.91 4.835 20.66 5.335C20.43 5.795 20.59 6.345 21.01 6.625C21.07 7.125 21.49 7.515 22 7.515C22.55 7.515 23 7.065 23 6.515V6.015C23 5.635 22.79 5.285 22.45 5.125V5.105ZM14.55 3.385L15.28 3.745C15.42 3.815 15.58 3.855 15.73 3.855C16.1 3.855 16.45 3.655 16.63 3.305C16.88 2.815 16.68 2.215 16.18 1.965L15.45 1.605C14.96 1.355 14.36 1.555 14.11 2.055C13.86 2.555 14.06 3.145 14.56 3.395L14.55 3.385ZM17.83 5.025L18.56 5.385C18.7 5.455 18.86 5.495 19.01 5.495C19.38 5.495 19.73 5.295 19.91 4.945C20.16 4.455 19.96 3.855 19.46 3.605L18.73 3.245C18.24 2.995 17.64 3.195 17.39 3.695C17.14 4.185 17.34 4.785 17.84 5.035L17.83 5.025ZM12.89 0.325L12.44 0.105C12.16 -0.035 11.83 -0.035 11.55 0.105L11.1 0.325C10.61 0.575 10.41 1.175 10.65 1.665C10.9 2.155 11.5 2.355 11.99 2.115C12.13 2.185 12.29 2.225 12.44 2.225C12.81 2.225 13.16 2.025 13.34 1.675C13.59 1.185 13.39 0.585 12.89 0.335V0.325ZM8.28 3.855C8.43 3.855 8.58 3.825 8.73 3.745L9.46 3.385C9.95 3.135 10.15 2.535 9.91 2.045C9.66 1.555 9.06 1.355 8.57 1.595L7.84 1.955C7.35 2.205 7.15 2.805 7.39 3.295C7.57 3.645 7.92 3.845 8.29 3.845L8.28 3.855ZM5 5.495C5.15 5.495 5.3 5.465 5.45 5.385L6.18 5.025C6.67 4.775 6.87 4.175 6.63 3.685C6.38 3.195 5.78 2.995 5.29 3.235L4.56 3.595C4.07 3.845 3.87 4.445 4.11 4.935C4.29 5.285 4.64 5.485 5.01 5.485L5 5.495ZM6 6.655L5.56 6.415C5.07 6.155 4.47 6.335 4.21 6.825C3.95 7.315 4.13 7.915 4.62 8.175L5.06 8.415C5.21 8.495 5.37 8.535 5.53 8.535C5.89 8.535 6.23 8.345 6.41 8.005C6.67 7.515 6.49 6.915 6 6.655ZM7.7 9.835L8.45 10.235C8.6 10.315 8.76 10.355 8.92 10.355C9.28 10.355 9.62 10.165 9.8 9.825C10.06 9.335 9.88 8.735 9.39 8.475L8.64 8.075C8.15 7.815 7.55 7.995 7.29 8.485C7.03 8.975 7.21 9.575 7.7 9.835ZM13.32 10.285C13.06 9.805 12.48 9.625 12 9.855C11.52 9.615 10.93 9.805 10.68 10.285C10.44 10.745 10.6 11.295 11.02 11.585C11.07 12.095 11.48 12.495 12 12.495C12.52 12.495 12.93 12.095 12.98 11.585C13.41 11.305 13.57 10.745 13.32 10.285ZM15.37 8.065L14.61 8.465C14.12 8.725 13.94 9.335 14.2 9.815C14.38 10.155 14.73 10.345 15.08 10.345C15.24 10.345 15.4 10.305 15.55 10.225L16.31 9.825C16.8 9.565 16.98 8.955 16.72 8.475C16.46 7.985 15.85 7.805 15.37 8.065ZM18.46 6.415L18.02 6.655C17.53 6.915 17.35 7.525 17.61 8.005C17.79 8.345 18.14 8.535 18.49 8.535C18.65 8.535 18.81 8.495 18.96 8.415L19.4 8.175C19.89 7.915 20.07 7.305 19.81 6.825C19.55 6.335 18.94 6.155 18.46 6.415ZM12 17.495C11.45 17.495 11 17.945 11 18.495V18.995C11 19.545 11.45 19.995 12 19.995C12.55 19.995 13 19.545 13 18.995V18.495C13 17.945 12.55 17.495 12 17.495ZM13 14.555C13 14.005 12.55 13.555 12 13.555C11.45 13.555 11 14.005 11 14.555V15.435C11 15.985 11.45 16.435 12 16.435C12.55 16.435 13 15.985 13 15.435V14.555Z"></path></g></svg>'},3663:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M12 1C5.93 1 1 5.93 1 12C1 18.07 5.93 23 12 23C18.07 23 23 18.07 23 12C23 5.93 18.07 1 12 1ZM12 21C7.04 21 3 16.96 3 12C3 7.04 7.04 3 12 3C16.96 3 21 7.04 21 12C21 16.96 16.96 21 12 21ZM17.41 8L13.41 12L17.41 16L16 17.41L12 13.41L8 17.41L6.59 16L10.59 12L6.59 8L8 6.59L12 10.59L16 6.59L17.41 8Z"></path></g></svg>'},8807:e=>{e.exports='<svg viewBox="0 0 25 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.5 1C6.42 1 1.5 5.92 1.5 12C1.5 18.08 6.42 23 12.5 23C18.58 23 23.5 18.08 23.5 12C23.5 5.92 18.58 1 12.5 1ZM12.5 21C7.54 21 3.5 16.96 3.5 12C3.5 7.04 7.54 3 12.5 3C17.46 3 21.5 7.04 21.5 12C21.5 16.96 17.46 21 12.5 21ZM17.41 10.25L11.47 6.95C10.85 6.6 10.1 6.61 9.49 6.97C8.87 7.33 8.5 7.98 8.5 8.69V15.29C8.5 16.01 8.87 16.65 9.49 17.01C9.81 17.2 10.15 17.29 10.5 17.29C10.85 17.29 11.17 17.21 11.47 17.04L17.41 13.74C18.04 13.39 18.44 12.72 18.44 11.99C18.44 11.26 18.05 10.59 17.41 10.24V10.25ZM10.5 15.3V8.7L16.44 12L10.5 15.3Z"></path></svg>'},6469:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M10.393 12.6465L5.69297 8.04651L10.393 3.34651L9.69297 2.64651L4.29297 8.04651L9.69297 13.3465L10.393 12.6465Z"></path></svg>'},9435:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C16.4 4 20 7.6 20 12C20 16.4 16.4 20 12 20C7.6 20 4 16.4 4 12C4 7.6 7.6 4 12 4ZM12 2C6.5 2 2 6.5 2 12C2 17.5 6.5 22 12 22C17.5 22 22 17.5 22 12C22 6.5 17.5 2 12 2ZM12 10C13.1 10 14 10.9 14 12C14 13.1 13.1 14 12 14C10.9 14 10 13.1 10 12C10 10.9 10.9 10 12 10ZM12 8C9.8 8 8 9.8 8 12C8 14.2 9.8 16 12 16C14.2 16 16 14.2 16 12C16 9.8 14.2 8 12 8Z"></path></svg>'},5677:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 4H2V21H14V16H18V11H22V4ZM12 19H4V16H12V19ZM16 14H4V11H16V14ZM20 9H4V6H20V9Z"></path></svg>'},9502:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0)"><path d="M12 6.8L12.9 9.7L13.3 11.1H14.8H17.8L15.4 12.9L14.2 13.8L14.6 15.2L15.5 18.1L13.1 16.3L12 15.3L10.8 16.2L8.4 18L9.3 15.1L9.7 13.7L8.5 12.8L6.1 11H9.1H10.6L11 9.6L12 6.8ZM12 0.300003L9.2 9H0L7.4 14.4L4.6 23.1L12 17.7L19.4 23.1L16.6 14.4L24 9H14.8L12 0.300003Z"></path></g><defs><clipPath id="clip0"><rect width="24" height="24"></rect></clipPath></defs></svg>'},2893:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 8.00001H19.6L15.6 4.00001L17 2.60001L23.4 9.00001L17 15.4L15.6 14L19.6 10H7C4.8 10 3 11.8 3 14C3 16.2 4.8 18 7 18H8V20H7C3.7 20 1 17.3 1 14C1 10.7 3.7 8.00001 7 8.00001Z"></path></svg>'},8834:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M12 7V9H4V7H12ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},9890:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_1564_16728)"><path d="M2.77 14.1393L6.09 9.03927L0 9.18927L0.06 6.51927L6.15 6.88927L2.96 1.68927L5.29 0.379272L8.02 5.81927L10.96 0.489272L13.23 1.84927L9.91 6.94927L16 6.79927L15.94 9.46927L9.85 9.09927L13.04 14.2993L10.71 15.6093L7.98 10.1693L5.04 15.4993L2.77 14.1393Z"></path></g><defs><clipPath id="clip0_1564_16728"><rect width="16" height="16" fill="white"></rect></clipPath></defs></svg>'},3334:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.01 2.993C11.8 2.993 11.59 3.023 11.37 3.043L12.71 1.703L11.3 0.292999L7.59 4.003L11.3 7.713L12.71 6.303L11.46 5.053C11.64 5.043 11.82 5.013 12 5.013C15.86 5.013 19 8.153 19 12.013C19 15.873 15.86 19.013 12 19.013C8.14 19.013 5 15.873 5 12.013C5 11.463 4.55 11.013 4 11.013C3.45 11.013 3 11.463 3 12.013C3 16.973 7.04 21.013 12 21.013C16.96 21.013 21 16.973 21 12.013C21 7.053 16.97 2.993 12.01 2.993Z"></path></svg>'},3118:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path d="M12 13H4C2.9 13 2 12.1 2 11V5C2 3.9 2.9 3 4 3H12C13.1 3 14 3.9 14 5V11C14 12.1 13.1 13 12 13ZM4 5V11H12V5H4Z"></path></svg>'},1442:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4L2 4V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V4C22 3.46957 21.7893 2.96086 21.4142 2.58579C21.0391 2.21071 20.5304 2 20 2ZM15 4V6H9V4H15ZM8 20V15H16V20H8ZM20 20H18V13H6V20H4V4.83L4.83 4H7V8H17V4H20V20Z"></path></svg>'},4179:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M23 11H19.9C19.4 7.4 16.6 4.5 13 4.1V1H11V4.1C7.4 4.5 4.5 7.4 4.1 11H1V13H4.1C4.6 16.6 7.4 19.5 11 19.9V23H13V19.9C16.6 19.4 19.5 16.6 19.9 13H23V11ZM12 18C8.7 18 6 15.3 6 12C6 8.7 8.7 6 12 6C15.3 6 18 8.7 18 12C18 15.3 15.3 18 12 18Z"></path></svg>'},7874:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9.9 4C9.4 2.3 7.9 1 6 1C3.8 1 2 2.8 2 5C2 7.2 3.8 9 6 9C7.9 9 9.4 7.7 9.9 6H22V4H9.9ZM6 7C4.9 7 4 6.1 4 5C4 3.9 4.9 3 6 3C7.1 3 8 3.9 8 5C8 6.1 7.1 7 6 7ZM9 15C7.1 15 5.6 16.3 5.1 18H2V20H5.1C5.5 21.7 7.1 23 9 23C10.9 23 12.4 21.7 12.9 20H22V18H12.9C12.4 16.3 10.9 15 9 15ZM9 21C7.9 21 7 20.1 7 19C7 17.9 7.9 17 9 17C10.1 17 11 17.9 11 19C11 20.1 10.1 21 9 21ZM18 8C16.1 8 14.6 9.3 14.1 11H2V13H14.1C14.5 14.7 16.1 16 18 16C20.2 16 22 14.2 22 12C22 9.8 20.2 8 18 8ZM18 14C16.9 14 16 13.1 16 12C16 10.9 16.9 10 18 10C19.1 10 20 10.9 20 12C20 13.1 19.1 14 18 14Z"></path></svg>'},6973:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M6.8 2C6.4 0.8 5.3 0 4 0C2.3 0 1 1.3 1 3C1 4.7 2.3 6 4 6C5.3 6 6.4 5.2 6.8 4H15V2H6.8ZM4 4C3.4 4 3 3.6 3 3C3 2.4 3.4 2 4 2C4.6 2 5 2.4 5 3C5 3.6 4.6 4 4 4ZM12 5C10.7 5 9.6 5.8 9.2 7H1V9H9.2C9.6 10.2 10.7 11 12 11C13.7 11 15 9.7 15 8C15 6.3 13.7 5 12 5ZM12 9C11.4 9 11 8.6 11 8C11 7.4 11.4 7 12 7C12.6 7 13 7.4 13 8C13 8.6 12.6 9 12 9ZM6 10C4.7 10 3.6 10.8 3.2 12H1V14H3.2C3.6 15.2 4.7 16 6 16C7.3 16 8.4 15.2 8.8 14H15V12H8.8C8.4 10.8 7.3 10 6 10ZM6 14C5.4 14 5 13.6 5 13C5 12.4 5.4 12 6 12C6.6 12 7 12.4 7 13C7 13.6 6.6 14 6 14Z"></path></svg>'},3728:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M24 17V19H9.1C9.5 18.4 9.9 17.7 10.2 17H24ZM11.9 9.00001C11 13.7 8.6 19.6 5 22.6C3.8 23.6 2 22.6 2 21.1C2 20.4 2.1 19.7 2.2 19H0V17H2.8C4.3 12.9 7.6 9.10001 10.2 7.60001C10.4 6.10001 10.4 4.80001 10.2 3.90001C9.9 3.30001 9.7 3.00001 9.6 3.00001C9.4 3.00001 7.8 2.90001 3.8 8.70001L2.2 7.60001C5.5 2.80001 7.9 0.700007 9.9 1.00001C12 1.20001 12.5 4.60001 12.2 6.90001C14.3 7.00001 14.8 8.20001 14.9 10.3C16.2 9.10001 18.1 7.90001 19.2 9.20001C20.8 8.90001 22.1 10.4 22.9 11.5L21.3 12.7C20.4 11.4 19.8 11.2 19.6 11.2C19.5 11.2 19.5 11.3 19.4 11.4C19 12 18.6 12.8 18 13.7C17.7 14.1 17.2 14.3 16.7 14.1C15.5 13.5 16.5 12.1 16.8 11.2C15.8 12 14.4 13.4 13.9 14.8C13.8 15.5 13.3 16.3 12.5 16.1C11.6 15.9 11.7 14.9 12 14.2C13.3 9.80001 12.5 9.00001 12.5 9.00001C12.5 8.90001 12.2 8.80001 11.9 9.00001ZM9.5 10.4C6.9 12.8 4.1 17.1 4 20.8C6.6 18.5 8.5 14.3 9.5 10.4Z"></path></svg>'},939:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M11 5C12.7 5 14 6.3 14 8C14 9.7 12.7 11 11 11H5C3.3 11 2 9.7 2 8C2 6.3 3.3 5 5 5H11ZM11 3H5C2.2 3 0 5.2 0 8C0 10.8 2.2 13 5 13H11C13.8 13 16 10.8 16 8C16 5.2 13.8 3 11 3ZM11 6C9.9 6 9 6.9 9 8C9 9.1 9.9 10 11 10C12.1 10 13 9.1 13 8C13 6.9 12.1 6 11 6Z"></path></svg>'},2898:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M11 5C12.7 5 14 6.3 14 8C14 9.7 12.7 11 11 11H5C3.3 11 2 9.7 2 8C2 6.3 3.3 5 5 5H11ZM11 3H5C2.2 3 0 5.2 0 8C0 10.8 2.2 13 5 13H11C13.8 13 16 10.8 16 8C16 5.2 13.8 3 11 3ZM5 6C3.9 6 3 6.9 3 8C3 9.1 3.9 10 5 10C6.1 10 7 9.1 7 8C7 6.9 6.1 6 5 6Z"></path></svg>'},3602:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 7V6C22 4.9 21.1 4 20 4H16C14.9 4 14 4.9 14 6V7C14 8.1 14.9 9 16 9H20C21.1 9 22 8.1 22 7ZM20 7H16V6H20V7ZM2 6V7C2 8.1 2.9 9 4 9H11C12.1 9 13 8.1 13 7V6C13 4.9 12.1 4 11 4H4C2.9 4 2 4.9 2 6ZM4 6H11V7H4V6ZM9 12V13C9 14.1 9.9 15 11 15H20C21.1 15 22 14.1 22 13V12C22 10.9 21.1 10 20 10H11C9.9 10 9 10.9 9 12ZM11 12H20V13H11V12ZM2 18V19C2 20.1 2.9 21 4 21H15C16.1 21 17 20.1 17 19V18C17 16.9 16.1 16 15 16H4C2.9 16 2 16.9 2 18ZM4 18H15V19H4V18ZM2 12V13C2 14.1 2.9 15 4 15H6C7.1 15 8 14.1 8 13V12C8 10.9 7.1 10 6 10H4C2.9 10 2 10.9 2 12ZM4 12H6V13H4V12Z"></path></svg>'},1516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 6H4C2.9 6 2 6.9 2 8V16C2 17.1 2.9 18 4 18H20C21.1 18 22 17.1 22 16V8C22 6.9 21.1 6 20 6ZM20 16H4V8H20V16ZM14 13H6V11H14V13Z"></path></svg>'},3076:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M24 21.4201C23.9387 22.1566 23.5894 22.8394 23.0278 23.3202C22.4662 23.8011 21.7376 24.0413 21 23.9888C20.2624 24.0413 19.5338 23.8011 18.9722 23.3202C18.4106 22.8394 18.0613 22.1566 18 21.4201C18 18.8513 21 16.2826 21 14.9932C21 16.2826 24 18.8513 24 21.4201ZM22 12.9942L11 1.99951L8.71 4.2884L10.12 5.70771L11 4.82814L18.17 11.9946L5.64 15.8028L2.83 12.9942L7.71 8.11653L9.29 9.70576C9.38296 9.79944 9.49356 9.8738 9.61542 9.92455C9.73728 9.97529 9.86799 10.0014 10 10.0014C10.132 10.0014 10.2627 9.97529 10.3846 9.92455C10.5064 9.8738 10.617 9.79944 10.71 9.70576C10.8037 9.61284 10.8781 9.5023 10.9289 9.3805C10.9797 9.2587 11.0058 9.12805 11.0058 8.99611C11.0058 8.86416 10.9797 8.73352 10.9289 8.61172C10.8781 8.48992 10.8037 8.37937 10.71 8.28645L3.71 1.28986C3.5217 1.10165 3.2663 0.995911 3 0.995911C2.7337 0.995911 2.4783 1.10165 2.29 1.28986C2.1017 1.47807 1.99591 1.73334 1.99591 1.99951C1.99591 2.26569 2.1017 2.52096 2.29 2.70917L6.29 6.70722L0 12.9942L10 22.9893L18 14.9932L22 12.9942Z"></path></svg>'},3358:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21 4H16V2C16 1.46957 15.7893 0.960859 15.4142 0.585786C15.0391 0.210714 14.5304 0 14 0L10 0C9.46957 0 8.96086 0.210714 8.58579 0.585786C8.21071 0.960859 8 1.46957 8 2V4H3C2.46957 4 1.96086 4.21071 1.58579 4.58579C1.21071 4.96086 1 5.46957 1 6V12H2V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V12H23V6C23 5.46957 22.7893 4.96086 22.4142 4.58579C22.0391 4.21071 21.5304 4 21 4ZM10 2H14V4H10V2ZM20 20H4V12H9V16H15V12H20V20ZM11 14V10H13V14H11ZM21 10H15V8H9V10H3V6H21V10Z"></path></svg>'},80:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3.34 5.325C3.57 5.785 3.41 6.335 2.99 6.615C2.93 7.115 2.51 7.505 2 7.505C1.45 7.505 1 7.055 1 6.505V6.005C1 5.625 1.21 5.275 1.55 5.115L2 4.895C2.49 4.645 3.09 4.845 3.34 5.345V5.325ZM2 15.415C2.55 15.415 3 14.965 3 14.415V13.535C3 12.985 2.55 12.535 2 12.535C1.45 12.535 1 12.985 1 13.535V14.415C1 14.965 1.45 15.415 2 15.415ZM2 11.455C2.55 11.455 3 11.005 3 10.455V9.575C3 9.025 2.55 8.575 2 8.575C1.45 8.575 1 9.025 1 9.575V10.455C1 11.005 1.45 11.455 2 11.455ZM2.99 17.385C2.93 16.885 2.51 16.495 2 16.495C1.45 16.495 1 16.945 1 17.495V17.995C1 18.375 1.21 18.725 1.55 18.885L2 19.105C2.14 19.175 2.3 19.215 2.45 19.215C2.82 19.215 3.17 19.015 3.35 18.665C3.58 18.205 3.42 17.655 3 17.375L2.99 17.385ZM9.45 20.605L8.72 20.245C8.23 19.995 7.63 20.195 7.38 20.695C7.13 21.185 7.33 21.785 7.83 22.035L8.56 22.395C8.7 22.465 8.86 22.505 9.01 22.505C9.38 22.505 9.73 22.305 9.91 21.955C10.16 21.465 9.96 20.865 9.46 20.615L9.45 20.605ZM6.17 18.965L5.44 18.605C4.95 18.355 4.35 18.555 4.1 19.055C3.85 19.545 4.05 20.145 4.55 20.395L5.28 20.755C5.42 20.825 5.58 20.865 5.73 20.865C6.1 20.865 6.45 20.665 6.63 20.315C6.88 19.825 6.68 19.225 6.18 18.975L6.17 18.965ZM12 21.875C11.51 21.625 10.91 21.825 10.66 22.325C10.41 22.815 10.61 23.415 11.11 23.665L11.56 23.885C11.7 23.955 11.85 23.995 12.01 23.995C12.17 23.995 12.32 23.955 12.46 23.885L12.91 23.665C13.4 23.415 13.6 22.815 13.36 22.325C13.11 21.835 12.51 21.635 12.02 21.875H12ZM18.56 18.595L17.83 18.955C17.34 19.205 17.14 19.805 17.38 20.295C17.56 20.645 17.91 20.845 18.28 20.845C18.43 20.845 18.58 20.815 18.73 20.735L19.46 20.375C19.95 20.125 20.15 19.525 19.91 19.035C19.66 18.545 19.06 18.345 18.57 18.585L18.56 18.595ZM15.28 20.235L14.55 20.595C14.06 20.845 13.86 21.445 14.1 21.935C14.28 22.285 14.63 22.485 15 22.485C15.15 22.485 15.3 22.455 15.45 22.375L16.18 22.015C16.67 21.765 16.87 21.165 16.63 20.675C16.38 20.185 15.78 19.985 15.29 20.225L15.28 20.235ZM22 16.495C21.49 16.495 21.06 16.885 21.01 17.385C20.59 17.655 20.43 18.215 20.66 18.675C20.84 19.025 21.19 19.225 21.56 19.225C21.71 19.225 21.86 19.195 22.01 19.115L22.46 18.895C22.8 18.725 23.01 18.375 23.01 18.005V17.505C23.01 16.955 22.56 16.505 22.01 16.505L22 16.495ZM22 12.535C21.45 12.535 21 12.985 21 13.535V14.415C21 14.965 21.45 15.415 22 15.415C22.55 15.415 23 14.965 23 14.415V13.535C23 12.985 22.55 12.535 22 12.535ZM22 8.575C21.45 8.575 21 9.025 21 9.575V10.455C21 11.005 21.45 11.455 22 11.455C22.55 11.455 23 11.005 23 10.455V9.575C23 9.025 22.55 8.575 22 8.575ZM22.45 5.105L22 4.885C21.51 4.635 20.91 4.835 20.66 5.335C20.43 5.795 20.59 6.345 21.01 6.625C21.07 7.125 21.49 7.515 22 7.515C22.55 7.515 23 7.065 23 6.515V6.015C23 5.635 22.79 5.285 22.45 5.125V5.105ZM14.55 3.385L15.28 3.745C15.42 3.815 15.58 3.855 15.73 3.855C16.1 3.855 16.45 3.655 16.63 3.305C16.88 2.815 16.68 2.215 16.18 1.965L15.45 1.605C14.96 1.355 14.36 1.555 14.11 2.055C13.86 2.555 14.06 3.145 14.56 3.395L14.55 3.385ZM17.83 5.025L18.56 5.385C18.7 5.455 18.86 5.495 19.01 5.495C19.38 5.495 19.73 5.295 19.91 4.945C20.16 4.455 19.96 3.855 19.46 3.605L18.73 3.245C18.24 2.995 17.64 3.195 17.39 3.695C17.14 4.185 17.34 4.785 17.84 5.035L17.83 5.025ZM12.89 0.325L12.44 0.105C12.16 -0.035 11.83 -0.035 11.55 0.105L11.1 0.325C10.61 0.575 10.41 1.175 10.65 1.665C10.9 2.155 11.5 2.355 11.99 2.115C12.13 2.185 12.29 2.225 12.44 2.225C12.81 2.225 13.16 2.025 13.34 1.675C13.59 1.185 13.39 0.585 12.89 0.335V0.325ZM8.28 3.855C8.43 3.855 8.58 3.825 8.73 3.745L9.46 3.385C9.95 3.135 10.15 2.535 9.91 2.045C9.66 1.555 9.06 1.355 8.57 1.595L7.84 1.955C7.35 2.205 7.15 2.805 7.39 3.295C7.57 3.645 7.92 3.845 8.29 3.845L8.28 3.855ZM5 5.495C5.15 5.495 5.3 5.465 5.45 5.385L6.18 5.025C6.67 4.775 6.87 4.175 6.63 3.685C6.38 3.195 5.78 2.995 5.29 3.235L4.56 3.595C4.07 3.845 3.87 4.445 4.11 4.935C4.29 5.285 4.64 5.485 5.01 5.485L5 5.495ZM6 6.655L5.56 6.415C5.07 6.155 4.47 6.335 4.21 6.825C3.95 7.315 4.13 7.915 4.62 8.175L5.06 8.415C5.21 8.495 5.37 8.535 5.53 8.535C5.89 8.535 6.23 8.345 6.41 8.005C6.67 7.515 6.49 6.915 6 6.655ZM7.7 9.835L8.45 10.235C8.6 10.315 8.76 10.355 8.92 10.355C9.28 10.355 9.62 10.165 9.8 9.825C10.06 9.335 9.88 8.735 9.39 8.475L8.64 8.075C8.15 7.815 7.55 7.995 7.29 8.485C7.03 8.975 7.21 9.575 7.7 9.835ZM13.32 10.285C13.06 9.805 12.48 9.625 12 9.855C11.52 9.615 10.93 9.805 10.68 10.285C10.44 10.745 10.6 11.295 11.02 11.585C11.07 12.095 11.48 12.495 12 12.495C12.52 12.495 12.93 12.095 12.98 11.585C13.41 11.305 13.57 10.745 13.32 10.285ZM15.37 8.065L14.61 8.465C14.12 8.725 13.94 9.335 14.2 9.815C14.38 10.155 14.73 10.345 15.08 10.345C15.24 10.345 15.4 10.305 15.55 10.225L16.31 9.825C16.8 9.565 16.98 8.955 16.72 8.475C16.46 7.985 15.85 7.805 15.37 8.065ZM18.46 6.415L18.02 6.655C17.53 6.915 17.35 7.525 17.61 8.005C17.79 8.345 18.14 8.535 18.49 8.535C18.65 8.535 18.81 8.495 18.96 8.415L19.4 8.175C19.89 7.915 20.07 7.305 19.81 6.825C19.55 6.335 18.94 6.155 18.46 6.415ZM12 17.495C11.45 17.495 11 17.945 11 18.495V18.995C11 19.545 11.45 19.995 12 19.995C12.55 19.995 13 19.545 13 18.995V18.495C13 17.945 12.55 17.495 12 17.495ZM13 14.555C13 14.005 12.55 13.555 12 13.555C11.45 13.555 11 14.005 11 14.555V15.435C11 15.985 11.45 16.435 12 16.435C12.55 16.435 13 15.985 13 15.435V14.555Z"></path></svg>'},9775:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 8.00001H4.40001L8.40001 4.00001L7.00001 2.60001L0.600006 9.00001L7.00001 15.4L8.40001 14L4.40001 10H17C19.2 10 21 11.8 21 14C21 16.2 19.2 18 17 18H16V20H17C20.3 20 23 17.3 23 14C23 10.7 20.3 8.00001 17 8.00001Z"></path></svg>'},5405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C7.2 4 3 7.2 0.5 12C3 16.8 7.2 20 12 20C16.8 20 20.9 16.8 23.5 12C20.9 7.2 16.7 4 12 4ZM12 18C8.5 18 5.1 15.8 2.8 12C5.1 8.2 8.5 6 12 6C15.5 6 18.9 8.2 21.2 12C18.9 15.8 15.5 18 12 18ZM12 7C9.2 7 7 9.2 7 12C7 14.8 9.2 17 12 17C14.8 17 17 14.8 17 12C17 9.2 14.7 7 12 7ZM12 15C10.3 15 9 13.7 9 12C9 11.7 9 11.5 9.1 11.3L12 12L10.3 9.5C10.8 9.2 11.3 9 12 9C13.7 9 15 10.3 15 12C15 13.7 13.6 15 12 15Z"></path></svg>'},1612:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7.7 16.3C8.1 16.7 8.1 17.3 7.7 17.7L3.7 21.7C3.5 21.9 3.3 22 3 22C2.7 22 2.5 21.9 2.3 21.7C1.9 21.3 1.9 20.7 2.3 20.3L6.3 16.3C6.7 15.9 7.3 15.9 7.7 16.3ZM20.5 10L23 13.7L18.6 14.6L17.7 19L14 16.5L10.3 19L9.4 14.6L5 13.7L7.5 10L5 6.3L9.4 5.4L10.3 1L14 3.5L17.7 1L18.6 5.4L23 6.3L20.5 10ZM18.1 10L18.8 8.9L19.6 7.7L18.1 7.4L16.8 7.1L16.5 5.8L16.2 4.3L15 5.1L14 5.9L12.9 5.2L11.7 4.3L11.4 5.8L11.1 7.1L9.8 7.4L8.3 7.7L9.1 8.9L9.9 10L9.2 11.1L8.4 12.3L9.9 12.6L11.2 12.9L11.5 14.2L11.8 15.7L13 14.9L14.1 14.2L15.2 14.9L16.4 15.7L16.7 14.2L17 12.9L18.3 12.6L19.8 12.3L19 11.1L18.1 10Z"></path></svg>'},7288:(e,t,o)=>{var i={"./add-lg.svg":6504,"./add.svg":618,"./add_16x16.svg":1797,"./add_24x24.svg":6539,"./alert_24x24.svg":356,"./apply.svg":631,"./arrow-down.svg":4321,"./arrow-left.svg":1354,"./arrow-left_16x16.svg":1685,"./arrow-right.svg":3153,"./arrow-right_16x16.svg":3142,"./arrow-up.svg":3422,"./boolean.svg":9331,"./change-question-type_16x16.svg":7140,"./checkbox.svg":2678,"./checked.svg":8020,"./chevron_16x16.svg":5981,"./clear.svg":9380,"./clear_16x16.svg":6907,"./codeeditor-24x24.svg":9054,"./collapse-detail-light_16x16.svg":7678,"./collapse-detail_16x16.svg":6845,"./collapse-panel.svg":9405,"./collapse-v_16x16.svg":4358,"./collapse_16x16.svg":943,"./collapseall-24x24.svg":6398,"./color-picker.svg":8813,"./comment.svg":6124,"./config.svg":2739,"./copy.svg":2622,"./default.svg":6252,"./delete_16x16.svg":2583,"./delete_24x24.svg":405,"./description-hide.svg":4802,"./description.svg":5869,"./device-desktop.svg":4548,"./device-phone.svg":736,"./device-rotate.svg":3441,"./device-tablet.svg":9364,"./download.svg":6813,"./drag-area-indicator.svg":9531,"./drag-area-indicator_24x16.svg":1689,"./drop-down-arrow.svg":2483,"./drop-down-arrow_16x16.svg":3892,"./dropdown.svg":7382,"./duplicate_16x16.svg":2723,"./edit.svg":5669,"./edit_16x16.svg":2290,"./editing-finish.svg":9697,"./embedsurvey-24x24.svg":2485,"./error.svg":7857,"./expand-detail-light_16x16.svg":7789,"./expand-detail_16x16.svg":7374,"./expand-panel.svg":5208,"./expand-v_16x16.svg":2731,"./expand_16x16.svg":6294,"./expandall-24x24.svg":5049,"./export.svg":1403,"./expression.svg":1399,"./fast-entry.svg":9516,"./file.svg":271,"./fix.svg":4706,"./html.svg":3698,"./image.svg":5168,"./imagepicker.svg":9630,"./import.svg":5518,"./invisible-items.svg":4925,"./keyboard-dragging.svg":8516,"./language.svg":6247,"./load.svg":2937,"./logic-24x24.svg":9730,"./logic-collapse.svg":1523,"./logic-expand.svg":1390,"./logo.svg":780,"./matrix.svg":7466,"./matrixdropdown.svg":8125,"./matrixdynamic.svg":169,"./multipletext.svg":6544,"./next_16x16.svg":5265,"./panel.svg":8273,"./paneldynamic.svg":4520,"./pg-v1/pg-appearance-24x24.svg":2804,"./pg-v1/pg-background-24x24.svg":5574,"./pg-v1/pg-columns-24x24.svg":1965,"./pg-v1/pg-conditions-24x24.svg":1144,"./pg-v1/pg-data-24x24.svg":386,"./pg-v1/pg-design-24x24.svg":4300,"./pg-v1/pg-general-24x24.svg":3236,"./pg-v1/pg-header-24x24.svg":833,"./pg-v1/pg-language-24x24.svg":1624,"./pg-v1/pg-layout-24x24.svg":5764,"./pg-v1/pg-logo-24x24.svg":9551,"./pg-v1/pg-navigation-24x24.svg":5e3,"./pg-v1/pg-pages-24x24.svg":1780,"./pg-v1/pg-questiondesign-24x24.svg":5824,"./pg-v1/pg-quiz-24x24.svg":1557,"./pg-v1/pg-rows-24x24.svg":7613,"./pg-v1/pg-specific-24x24.svg":6534,"./pg-v1/pg-thankyyoupage-24x24.svg":1703,"./pg-v1/pg-themes-24x24.svg":4992,"./pg-v1/pg-totals-24x24.svg":5891,"./pg-v1/pg-undefined-24x24.svg":9324,"./pg-v1/pg-validation-24x24.svg":3663,"./preview.svg":8807,"./previous_16x16.svg":6469,"./radiogroup.svg":9435,"./ranking.svg":5677,"./rating.svg":9502,"./redo.svg":2893,"./remove_16x16.svg":8834,"./required.svg":9890,"./reset.svg":3334,"./restore_16x16.svg":3118,"./save.svg":1442,"./select-page.svg":4179,"./settings.svg":7874,"./settings_16x16.svg":6973,"./signaturepad.svg":3728,"./switch-active_16x16.svg":939,"./switch-inactive_16x16.svg":2898,"./tagbox.svg":3602,"./text.svg":1516,"./theme.svg":3076,"./toolbox.svg":3358,"./undefined-24x24.svg":80,"./undo.svg":9775,"./visible.svg":5405,"./wizard.svg":1612};function n(e){var t=r(e);return o(t)}function r(e){if(!o.o(i,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return i[e]}n.keys=function(){return Object.keys(i)},n.resolve=r,e.exports=n,n.id=7288},156:t=>{"use strict";t.exports=e},7238:e=>{"use strict";e.exports=t}},i={};function n(e){var t=i[e];if(void 0!==t)return t.exports;var r=i[e]={exports:{}};return o[e].call(r.exports,r,r.exports,n),r.exports}n.d=(e,t)=>{for(var o in t)n.o(t,o)&&!n.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},n.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),n.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var r={};return(()=>{"use strict";n.r(r),n.d(r,{AceJsonEditorModel:()=>xe,ColorCalculator:()=>H,CreatorAction:()=>Ri,CreatorBase:()=>Qi,CreatorEvent:()=>qi,CreatorPreset:()=>Ir,CreatorPresetBase:()=>Cr,CreatorPresetPropertyGrid:()=>Vr,CreatorPresetPropertyGridDefinition:()=>Er,CreatorPresetTabs:()=>Pr,CreatorPresetToolbox:()=>Tr,CreatorPresetToolboxConfigurator:()=>xr,CreatorPresetToolboxDefinition:()=>wr,CreatorResponsivityManager:()=>Mo,DEFAULT_MONITOR_DPI:()=>Ve,DefaultFonts:()=>Yo,DragDropSurveyElements:()=>Qt,EditorLocalization:()=>U,EmptySurveyCreatorOptions:()=>a,HSBToRGB:()=>j,ImageItemValueWrapperViewModel:()=>hn,ItemValueWrapperViewModel:()=>dn,JsonDuplicateNameError:()=>de,JsonEditorBaseModel:()=>Ce,LogicEvent:()=>Fe,LogoImageViewModel:()=>bn,MatrixCellWrapperEditSurvey:()=>gn,MatrixCellWrapperViewModel:()=>mn,MenuButton:()=>kt,ObjType:()=>Y,ObjectSelector:()=>To,ObjectSelectorItem:()=>xo,ObjectSelectorModel:()=>So,PageAdorner:()=>rn,PageNavigatorViewModel:()=>nn,PagesController:()=>Eo,PredefinedColors:()=>Ko,PredefinedThemes:()=>Wo,PropertyEditorSetupValue:()=>it,PropertyGridCellsEditor:()=>lr,PropertyGridEditor:()=>lt,PropertyGridEditorBackgroundCornerRadius:()=>$n,PropertyGridEditorBindings:()=>Wn,PropertyGridEditorBoolean:()=>ut,PropertyGridEditorCollection:()=>nt,PropertyGridEditorColor:()=>yt,PropertyGridEditorColorWithAlpha:()=>vt,PropertyGridEditorCondition:()=>Ln,PropertyGridEditorDateTime:()=>gt,PropertyGridEditorDropdown:()=>Pt,PropertyGridEditorExpression:()=>Nn,PropertyGridEditorFontSettings:()=>Xn,PropertyGridEditorHtml:()=>Tt,PropertyGridEditorImageSize:()=>wt,PropertyGridEditorMatrix:()=>Dn,PropertyGridEditorMatrixCalculatedValues:()=>Hn,PropertyGridEditorMatrixColumns:()=>Rn,PropertyGridEditorMatrixHtmlConditions:()=>Qn,PropertyGridEditorMatrixItemValues:()=>kn,PropertyGridEditorMatrixLayoutColumns:()=>Bn,PropertyGridEditorMatrixMultipleTypes:()=>Gn,PropertyGridEditorMatrixMutlipleTextItems:()=>Un,PropertyGridEditorMatrixPages:()=>qn,PropertyGridEditorMatrixRateValues:()=>jn,PropertyGridEditorMatrixTriggers:()=>zn,PropertyGridEditorMatrixUrlConditions:()=>Fn,PropertyGridEditorMatrixValidators:()=>Zn,PropertyGridEditorNumber:()=>bt,PropertyGridEditorPage:()=>Vt,PropertyGridEditorQuestion:()=>It,PropertyGridEditorQuestionCarryForward:()=>Ot,PropertyGridEditorQuestionHeader:()=>yr,PropertyGridEditorQuestionMaskSettings:()=>mr,PropertyGridEditorQuestionRestfull:()=>Yn,PropertyGridEditorQuestionSelectBase:()=>At,PropertyGridEditorQuestionValue:()=>Nt,PropertyGridEditorSet:()=>Et,PropertyGridEditorShadowEffects:()=>er,PropertyGridEditorSpinEdit:()=>Ct,PropertyGridEditorString:()=>ht,PropertyGridEditorStringArray:()=>St,PropertyGridEditorStringBase:()=>dt,PropertyGridEditorSwitchToggle:()=>pt,PropertyGridEditorText:()=>xt,PropertyGridEditorUndefinedBoolean:()=>ct,PropertyGridLinkEditor:()=>ft,PropertyGridModel:()=>st,PropertyGridPanelValueEditor:()=>cr,PropertyGridRowValueEditor:()=>pr,PropertyGridTitleActionsCreator:()=>rt,PropertyGridTriggerValueEditor:()=>dr,PropertyGridTriggerValueInLogicEditor:()=>hr,PropertyGridValueEditor:()=>ur,PropertyGridValueEditorBase:()=>sr,PropertyGridViewModel:()=>Po,PropertyJSONGenerator:()=>at,QuestionAdornerViewModel:()=>sn,QuestionColorModel:()=>En,QuestionCommentWithResetModel:()=>On,QuestionConvertMode:()=>e,QuestionConverter:()=>$,QuestionDropdownAdornerViewModel:()=>ln,QuestionEmbeddedSurveyModel:()=>wn,QuestionFileEditorModel:()=>Vn,QuestionImageAdornerViewModel:()=>un,QuestionLinkValueModel:()=>xn,QuestionRatingAdornerViewModel:()=>pn,QuestionSpinEditorModel:()=>Tn,QuestionTextWithResetModel:()=>An,QuestionToolbox:()=>ve,QuestionToolboxCategory:()=>fe,QuestionToolboxItem:()=>ye,RGBToHSB:()=>R,ResetValueAdorner:()=>In,ResizeManager:()=>jo,RowViewModel:()=>an,SearchManager:()=>he,SearchManagerPropertyGrid:()=>me,SearchManagerToolbox:()=>ge,SidebarHeaderModel:()=>ko,SidebarModel:()=>Ro,SidebarPageModel:()=>Do,StringEditorConnector:()=>Go,StringEditorViewModelBase:()=>Zo,StringItemsNavigatorBase:()=>Bo,StylesManager:()=>Fi,SurveyCreatorModel:()=>Hi,SurveyHelper:()=>ee,SurveyJSON5:()=>X,SurveyLogic:()=>Ue,SurveyLogicUI:()=>co,SurveyQuestionEditorDefinition:()=>Ke,SurveyQuestionEditorPropertyDefinition:()=>Ye,SurveyQuestionEditorTabDefinition:()=>Xe,SurveyQuestionProperties:()=>et,SurveyResultsItemModel:()=>fn,SurveyResultsModel:()=>vn,SurveySimulatorModel:()=>Ee,SurveyTextWorker:()=>ce,SurveyTextWorkerError:()=>ie,SurveyTextWorkerJsonError:()=>pe,SurveyTextWorkerParserError:()=>ne,Switcher:()=>Ii,TabControlModel:()=>No,TabDesignerPlugin:()=>_o,TabDesignerViewModel:()=>Io,TabJsonEditorAcePlugin:()=>Te,TabJsonEditorBasePlugin:()=>we,TabJsonEditorTextareaPlugin:()=>Pe,TabLogicPlugin:()=>ho,TabTestPlugin:()=>Ne,TabTranslationPlugin:()=>eo,TabbedMenuContainer:()=>ji,TabbedMenuItem:()=>ki,TestSurveyTabViewModel:()=>Oe,TextareaJsonEditorModel:()=>Se,ThemeModelEditorDefinition:()=>Ni,ThemeTabPlugin:()=>Li,ThemeTabViewModel:()=>zo,Themes:()=>Jo,ToolbarActionContainer:()=>Bi,ToolboxToolViewModel:()=>on,Transaction:()=>mo,Translation:()=>Wt,TranslationEditor:()=>Yt,TranslationForEditor:()=>Kt,TranslationGroup:()=>Jt,TranslationItem:()=>zt,TranslationItemBase:()=>Gt,TranslationItemString:()=>Zt,UndoRedoAction:()=>fo,UndoRedoArrayAction:()=>yo,UndoRedoManager:()=>go,UndoRedoPlugin:()=>bo,Version:()=>br,assign:()=>q,assignDefaultV2Classes:()=>P,backgroundCornerRadiusFromCssVariable:()=>ai,backgroundCornerRadiusToCssVariable:()=>ri,calculateDragOverLocation:()=>Bt,calculateIsEdge:()=>jt,calculateIsSide:()=>Rt,capitalize:()=>V,clearNewLines:()=>w,convertRgbaToString:()=>M,copyCssClasses:()=>S,copyObject:()=>T,createBoxShadow:()=>ui,createBoxShadowReset:()=>pi,createColor:()=>xi,createExportCSVAction:()=>$t,createImportCSVAction:()=>Xt,defaultPropertyGridDefinition:()=>We,defaultStrings:()=>z,editableStringRendererName:()=>Zi,editorLocalization:()=>G,enStrings:()=>t,findParentNode:()=>g,focusFirstControl:()=>m,fontsettingsFromCssVariable:()=>oi,fontsettingsToCssVariable:()=>ti,getAcceptedTypesByContentMode:()=>O,getElementWrapperComponentData:()=>Wi,getElementWrapperComponentName:()=>zi,getFirstNonTextElement:()=>f,getItemValueWrapperComponentData:()=>Yi,getItemValueWrapperComponentName:()=>Ki,getLocString:()=>Z,getNextItemText:()=>d,getNextItemValue:()=>c,getNextValue:()=>h,getNodesFromKoComponentInfo:()=>y,getQuestionContentWrapperComponentName:()=>Ji,getQuestionFromObj:()=>N,ignoreUndoRedo:()=>wo,imageMimeTypes:()=>A,ingectAlpha:()=>_,initLogicOperator:()=>Qe,initialSettingsAllowShowEmptyTitleInDesignMode:()=>Vo,initializeDesignTimeSurveyModel:()=>Ui,isPanelDynamic:()=>qt,isPropertyVisible:()=>b,isStringEditable:()=>Xi,isTextInput:()=>$i,localization:()=>G,logicCss:()=>to,notShortCircuitAnd:()=>I,parseBoxShadow:()=>ci,parseColor:()=>k,parseRgbaFromString:()=>D,propertyExists:()=>v,propertyGridCss:()=>ze,registerAdorner:()=>en,removeAdorners:()=>tn,roundTo2Decimals:()=>l,saveToFileHandler:()=>Q,scrollElementIntoView:()=>L,select:()=>x,setSurveyJSONForPropertyGrid:()=>ot,settings:()=>i,simulatorDevices:()=>Ie,svgBundle:()=>{},themeModelPropertyGridDefinition:()=>Oi,toggleHovered:()=>C,translationCss:()=>Lt,trimBoxShadowValue:()=>di,trimEmptyFields:()=>B,undoRedoTransaction:()=>Co,updateBackgroundCornerRadiusJSON:()=>ni,updateFontSettingsJSON:()=>ei,updateShadowEffectsJSON:()=>li,updatecoloralphaJSON:()=>Ci,wrapTextByCurlyBraces:()=>E});var e,t={survey:{edit:"Edit",externalHelpLink:"Watch and learn how to create surveys",externalHelpLinkUrl:"https://www.youtube.com/channel/UCH2ru9okIcooNZfpIbyq4qQ?view_as=subscriber",dropQuestion:"Please drop a question here from the Toolbox.",addLogicItem:"Create a rule to customize the flow of the survey.",copy:"Copy",duplicate:"Duplicate",addToToolbox:"Add to toolbox",deletePanel:"Delete Panel",deleteQuestion:"Delete Question",convertTo:"Convert to",drag:"Drag element",license:"To use our library, a <a href='https://surveyjs.io/licensing'>developer license</a> is required. If you have an active license, <a href='https://surveyjs.io/remove-alert-banner'>set up your license key</a> and ensure you're using the latest version."},tabs:{preview:"Preview",theme:"Themes",translation:"Translations",designer:"Designer",editor:"JSON Editor",logic:"Logic"},qt:{default:"Default",checkbox:"Checkboxes",comment:"Long Text",imagepicker:"Image Picker",ranking:"Ranking",image:"Image",dropdown:"Dropdown",tagbox:"Multi-Select Dropdown",file:"File Upload",html:"HTML",matrix:"Single-Select Matrix",matrixdropdown:"Multi-Select Matrix",matrixdynamic:"Dynamic Matrix",multipletext:"Multiple Textboxes",panel:"Panel",paneldynamic:"Dynamic Panel",radiogroup:"Radio Button Group",rating:"Rating Scale",text:"Single-Line Input",boolean:"Yes/No (Boolean)",expression:"Expression (read-only)",signaturepad:"Signature",buttongroup:"Button Group"},toolboxCategories:{general:"General",choice:"Choice Questions",text:"Text Input Questions",containers:"Containers",matrix:"Matrix Questions",misc:"Misc"},ed:{defaultLocale:"Default ({0})",survey:"Survey",settings:"Settings",settingsTooltip:"Open settings",surveySettings:"Survey Settings",surveySettingsTooltip:"Survey settings",themeSettings:"Theme Settings",themeSettingsTooltip:"Theme settings",showPanel:"Show Panel",hidePanel:"Hide Panel",prevSelected:"Select previous",nextSelected:"Select next",prevFocus:"Focus previous",nextFocus:"Focus next",surveyTypeName:"Survey",pageTypeName:"Page",panelTypeName:"Panel",questionTypeName:"Question",columnTypeName:"Column",addNewPage:"Add New Page",moveRight:"Scroll to the Right",moveLeft:"Scroll to the Left",deletePage:"Delete Page",editPage:"Edit Page",edit:"Edit",newPageName:"page",newQuestionName:"question",newPanelName:"panel",newTextItemName:"text",defaultV2Theme:"Default",modernTheme:"Modern",defaultTheme:"Default (legacy)",testSurveyAgain:"Preview Survey Again",testSurveyWidth:"Survey width: ",navigateToMsg:"You had to navigate to",saveSurvey:"Save Survey",saveSurveyTooltip:"Save Survey",saveTheme:"Save Theme",saveThemeTooltip:"Save Theme",jsonHideErrors:"Hide errors",jsonShowErrors:"Show errors",undo:"Undo",redo:"Redo",undoTooltip:"Undo last change",redoTooltip:"Redo the change",expandAllTooltip:"Expand All",collapseAllTooltip:"Collapse All",showMoreChoices:"Show more",showLessChoices:"Show less",copy:"Copy",cut:"Cut",paste:"Paste",copyTooltip:"Copy selection to clipboard",cutTooltip:"Cut selection to clipboard",pasteTooltip:"Paste from clipboard",options:"Options",generateValidJSON:"Generate Valid JSON",generateReadableJSON:"Generate Readable JSON",toolbox:"Toolbox","property-grid":"Properties",toolboxFilteredTextPlaceholder:"Type to search...",toolboxNoResultsFound:"No results found",propertyGridFilteredTextPlaceholder:"Type to search...",propertyGridNoResultsFound:"No results found",propertyGridPlaceholderTitle:"Start configuring your form",propertyGridPlaceholderDescription:"Click any category icon to explore survey settings. Additional settings will become available once you add a survey element to the design surface.",correctJSON:"Please correct JSON.",surveyResults:"Survey Results ",surveyResultsTable:"As Table",surveyResultsJson:"As JSON",resultsTitle:"Question Title",resultsName:"Question Name",resultsValue:"Answer Value",resultsDisplayValue:"Display Value",modified:"Modified",saving:"Saving",saved:"Saved",propertyEditorError:"Error",saveError:"Error! Editor content is not saved.",translationPropertyGridTitle:"Language Settings",themePropertyGridTitle:"Theme Settings",translationLanguages:"Languages",translationDeleteLanguage:"Are you certain you wish to delete all strings for this language?",translationAddLanguage:"Select language to translate",translationShowAllStrings:"All Strings",translationShowUsedStringsOnly:"Used Strings Only",translationShowAllPages:"All Pages",translationNoStrings:"No strings to translate. Please change the filter.",translationExportToSCVButton:"Export to CSV",translationImportFromSCVButton:"Import from CSV",translateUsigAI:"Auto-translate All",translateUsigAIFrom:"Translate from: ",translationDialogTitle:"Untranslated strings",translationMergeLocaleWithDefault:"Merge {0} with default locale",translationPlaceHolder:"Translation...",translationSource:"Source: ",translationTarget:"Target: ",translationYouTubeNotSupported:"YouTube links are not supported.",themeExportButton:"Export",themeImportButton:"Import",surveyJsonExportButton:"Export",surveyJsonImportButton:"Import",surveyJsonCopyButton:"Copy to clipboard",themeResetButton:"Reset theme settings to default",themeResetConfirmation:"Do you really want to reset the theme? All your customizations will be lost.",themeResetConfirmationOk:"Yes, reset the theme",bold:"Bold",italic:"Italic",underline:"Underline",addNewQuestion:"Add Question",selectPage:"Select page...",carryForwardChoicesCopied:"Choices are copied from",choicesLoadedFromWebText:"Choices are loaded from a web service.",choicesLoadedFromWebLinkText:"Go to settings",choicesLoadedFromWebPreviewTitle:"Preview of loaded choice options",htmlPlaceHolder:"HTML content will be here.",panelPlaceHolder:"Drop a question from the toolbox here.",surveyPlaceHolder:"The survey is empty. Drag an element from the toolbox or click the button below.",pagePlaceHolder:"The page is empty. Drag an element from the toolbox or click the button below.",imagePlaceHolder:"Drag and drop an image here or click the button below and choose an image to upload",surveyPlaceHolderMobile:'Click the "Add Question" button below to start creating your form.',surveyPlaceholderTitle:"Your form is empty",surveyPlaceholderTitleMobile:"Your form is empty",surveyPlaceholderDescription:"Drag an element from the toolbox or click the button below.",surveyPlaceholderDescriptionMobile:"Drag an element from the toolbox or click the button below.",previewPlaceholderTitle:"No preview",previewPlaceholderTitleMobile:"No preview",previewPlaceholderDescription:"The survey doesn't contain any visible elements.",previewPlaceholderDescriptionMobile:"The survey doesn't contain any visible elements.",translationsPlaceholderTitle:"No strings to translate",translationsPlaceholderTitleMobile:"No strings to translate",translationsPlaceholderDescription:"Add elements to your form or change the strings filter in the toolbar.",translationsPlaceholderDescriptionMobile:"Add elements to your form or change the strings filter in the toolbar.",pagePlaceHolderMobile:'Click the "Add Question" button below to add a new element to the page.',panelPlaceHolderMobile:'Click the "Add Question" button below to add a new element to the panel.',imagePlaceHolderMobile:"Click the button below and choose an image to upload",imageChooseImage:"Choose Image",addNewTypeQuestion:"Add {0}",chooseLogoPlaceholder:"[LOGO]",choices_Item:"Item ",selectFile:"Select a file",removeFile:"Remove the file",lg:{addNewItem:"Add New Rule",empty_tab:"Create a rule to customize the flow of the survey.",logicPlaceholderTitle:"No logical rules",logicPlaceholderTitleMobile:"No logical rules",logicPlaceholderDescription:"Create a rule to customize the flow of the survey.",logicPlaceholderDescriptionMobile:"Create a rule to customize the flow of the survey.",page_visibilityName:"Show/hide page",page_enableName:"Enable/disable page",page_requireName:"Make page required",panel_visibilityName:"Show/hide panel",panel_enableName:"Enable/disable panel",panel_requireName:"Make panel required",question_visibilityName:"Show/hide question",question_enableName:"Enable/disable question",question_requireName:"Make question required",question_resetValueName:"Reset question value",question_setValueName:"Set question value",column_visibilityName:"Show/hide column",column_enableName:"Enable/disable column",column_requireName:"Make column required",column_resetValueName:"Reset column value",column_setValueName:"Set column value",trigger_completeName:"Complete survey",trigger_setvalueName:"Set answer",trigger_copyvalueName:"Copy answer",trigger_skipName:"Skip to question",trigger_runExpressionName:"Run expression",completedHtmlOnConditionName:'Set "Thank You" page markup',page_visibilityDescription:"Make the page visible when the logical expression evaluates to true. Otherwise, keep the page invisible.",panel_visibilityDescription:"Make the page visible when the logical expression evaluates to true. Otherwise, keep the panel invisible.",panel_enableDescription:"Make the panel and all elements inside it enabled when the logical expression evaluates to true. Otherwise, keep them disabled.",question_visibilityDescription:"Make the question visible when the logical expression evaluates to true. Otherwise, keep the question invisible.",question_enableDescription:"Make the question enabled when the logical expression evaluates to true. Otherwise, keep the question disabled.",question_requireDescription:"Question becomes required when the logical expression evaluates to true.",trigger_completeDescription:'When the logical expression evaluates to true, the survey ends, and the respondent sees the "Thank you" page.',trigger_setvalueDescription:"When question values used in the logical expression are changed, and the expression evaluates to true, the specified value is assigned to the selected question.",trigger_copyvalueDescription:"When question values used in the logical expression are changed, and the expression evaluates to true, the value of the selected question is copied to another question.",trigger_skipDescription:"When the logical expression evaluates to true, the survey focuses/jumps to the selected question.",trigger_runExpressionDescription:"When the logical expression evaluates to true, the survey evaluates another expression. Optionally, the result of the latter expression can be assigned as a value to the selected question",completedHtmlOnConditionDescription:'If the logical expression evaluates to true, the "Thank You" page displays the specified content.',itemExpressionText:"When expression: '{0}' returns true",itemEmptyExpressionText:"New rule",page_visibilityText:"make page {0} visible",panel_visibilityText:"make panel {0} visible",panel_enableText:"make panel {0} enable",question_visibilityText:"make question {0} visible",question_enableText:"make question {0} enable",question_requireText:"make question {0} required",question_resetValueText:"reset value for question: {0}",question_setValueText:"assign value: {1} to question: {0}",column_visibilityText:"make column {0} of question {1} visible",column_enableText:"make column {0} of question {1} enable",column_requireText:"make column {0} of question {1} required",column_resetValueText:"reset cell value for column: {0}",column_setValueText:"assign cell value: {1} to column: {0}",setValueExpressionPlaceholder:"An expression whose result will be assigned to the target question.",trigger_completeText:"survey becomes completed",trigger_setvalueText:"set into question: {0} value {1}",trigger_setvalueEmptyText:"clear question value: {0}",trigger_copyvalueText:"copy into question: {0} value from question {1}",trigger_skipText:"survey skip to the question {0}",trigger_runExpressionText1:"run expression: '{0}'",trigger_runExpressionText2:" and set its result into question: {0}",completedHtmlOnConditionText:'show custom text for the "Thank You" page.',showAllQuestions:"All Questions",showAllActionTypes:"All Action Types",conditions:"Condition(s)",actions:"Action(s)",expressionEditorTitle:"Define condition(s)",actionsEditorTitle:"Define action(s)",deleteAction:"Delete Action",addNewAction:"Add Action",selectedActionCaption:"Select action...",expressionInvalid:"The logic expression is empty or invalid. Please correct it.",noActionError:"Please add at least one action.",actionInvalid:"Please fix issues in your action(s).",uncompletedRule_title:"Logical rules are incomplete",uncompletedRule_text:"You have not completed some of the logical rules. If you leave the tab now, the changes will be lost. Do you still want to leave the tab without completing the changes?",uncompletedRule_apply:"Yes",uncompletedRule_cancel:"No, I want to complete the rules"}},pe:{panel:{name:"Panel name",title:"Panel title",description:"Panel description",visibleIf:"Make the panel visible if",requiredIf:"Make the panel required if",questionsOrder:"Question order within the panel",page:"Move the panel to page",startWithNewLine:"Display the panel on a new line",state:"Panel collapse state",width:"Inline panel width",minWidth:"Minimum panel width",maxWidth:"Maximum panel width",showNumber:"Number panels"},paneldynamic:{name:"Panel name",title:"Panel title",description:"Panel description",visibleIf:"Make the panel visible if",requiredIf:"Make the panel required if",page:"Move the panel to page",startWithNewLine:"Display the panel on a new line",state:"Panel collapse state",width:"Inline panel width",minWidth:"Minimum panel width",maxWidth:"Maximum panel width",confirmDelete:"Confirm panel deletion",templateDescription:"Panel description pattern",templateTitle:"Panel title pattern",noEntriesText:"Empty panel text",templateTabTitle:"Tab title pattern",tabTitlePlaceholder:"Tab title placeholder",templateVisibleIf:"Make an individual panel visible if",hideNumber:"Hide the panel number",titleLocation:"Panel title alignment",descriptionLocation:"Panel description alignment",templateTitleLocation:"Question title alignment",templateErrorLocation:"Error message alignment",newPanelPosition:"New panel location",showRangeInProgress:"Show the progress bar",showProgressBar:"Show the progress bar",progressBarLocation:"Progress bar alignment",keyName:"Prevent duplicate responses in the following question"},question:{name:"Question name",title:"Question title",description:"Question description",visibleIf:"Make the question visible if",requiredIf:"Make the question required if",page:"Move the question to page",state:"Question box collapse state",hideNumber:"Hide the question number",titleLocation:"Question title alignment",descriptionLocation:"Question description alignment",errorLocation:"Error message alignment",indent:"Increase the inner indent",width:"Inline question width",minWidth:"Minimum question width",maxWidth:"Maximum question width",textUpdateMode:"Update input field value"},signaturepad:{signatureWidth:"Signature area width",signatureHeight:"Signature area height",signatureAutoScaleEnabled:"Auto-scale the signature area",showPlaceholder:"Show a placeholder within signature area",placeholder:"Placeholder text",placeholderReadOnly:"Placeholder text in read-only or preview mode",allowClear:"Show the Clear button within signature area",penMinWidth:"Minimum stroke width",penMaxWidth:"Maximum stroke width",penColor:"Stroke color"},comment:{rows:"Input field height (in lines)"},showQuestionNumbers:"Question numbering",questionStartIndex:"Question indexing type",expression:{name:"Expression name",title:"Expression title",description:"Expression description",expression:"Expression"},trigger:{expression:"Expression"},calculatedvalue:{expression:"Expression"},survey:{title:"Survey title",description:"Survey description"},page:{name:"Page name",title:"Page title",description:"Page description",visibleIf:"Make the page visible if",requiredIf:"Make the page required if",timeLimit:"Time limit to complete the page",questionsOrder:"Question order on the page"},matrixdropdowncolumn:{name:"Column name",title:"Column title",isUnique:"Prevent duplicate responses",width:"Column width",minWidth:"Minimum column width",rows:"Input field height (in lines)",visibleIf:"Make the column visible if",requiredIf:"Make the column required if",showInMultipleColumns:"Each option in a separate column"},multipletextitem:{name:"Name",title:"Title"},masksettings:{saveMaskedValue:"Save masked value in survey results"},patternmask:{pattern:"Value pattern"},datetimemask:{min:"Minimum value",max:"Maximum value"},numericmask:{allowNegativeValues:"Allow negative values",thousandsSeparator:"Thousands separator",decimalSeparator:"Decimal separator",precision:"Value precision",min:"Minimum value",max:"Maximum value"},currencymask:{prefix:"Currency prefix",suffix:"Currency suffix"},imageHeight:"Display area height",imageWidth:"Display area width",valueName:"Join identifier",rateDescriptionLocation:"Label alignment",size:"Input field width (in characters)",cellErrorLocation:"Cell error message alignment",enabled:"Enabled",disabled:"Disabled",inherit:"Inherit",apply:"Apply",ok:"OK",save:"Save",clear:"Clear",saveTooltip:"Save",cancel:"Cancel",set:"Set",reset:"Reset",change:"Change",refresh:"Refresh",close:"Close",delete:"Delete",add:"Add",addNew:"Add New",addItem:"Click to add an item...",removeItem:"Click to remove the item...",dragItem:"Drag the item",addOther:"Other",addSelectAll:"Select All",addNone:"None",removeAll:"Remove All",edit:"Edit",back:"Return without saving",backTooltip:"Return without saving",saveAndBack:"Save and return",saveAndBackTooltip:"Save and return",doneEditing:"Done",editChoices:"Edit Choices",showChoices:"Show Choices",move:"Move",empty:"<empty>",emptyValue:"Value is empty",fastEntry:"Manual Entry",fastEntryNonUniqueError:"Value '{0}' is not unique",fastEntryChoicesCountError:"Please limit the number of items from {0} to {1}",fastEntryChoicesMinCountError:"Please enter at least {0} items",fastEntryPlaceholder:"Enter the list of choice options and their IDs in the following format:\n\nid|option\n\nA choice option ID is not visible to respondents and can be used in conditional rules.",formEntry:"Form Entry",testService:"Test the service",itemSelectorEmpty:"Please select the element",conditionActionEmpty:"Please select the action",conditionSelectQuestion:"Select a question...",conditionSelectPage:"Select a page...",conditionSelectPanel:"Select a panel...",conditionValueQuestionTitle:"Please enter/select the value",aceEditorHelp:"Press ctrl+space to get expression completion hint",aceEditorRowTitle:"Current row",aceEditorPanelTitle:"Current panel",showMore:"For more details please check the documentation",assistantTitle:"Available questions",cellsEmptyRowsColumns:"There is should be at least one column or row",showPreviewBeforeComplete:"Review before submit",overridingPropertyPrefix:"Enabled by a condition",resetToDefaultCaption:"Reset",propertyIsEmpty:"Please enter a value",propertyIsNoUnique:"Please enter a unique value",propertyNameIsNotUnique:"Please enter a unique name",propertyNameIsIncorrect:'Do not use reserved words: "item", "choice", "panel", "row".',listIsEmpty:"You don't have any items yet","listIsEmpty@choices":"You don't have any choices yet","listIsEmpty@columns":"You don't have any columns yet","listIsEmpty@rows":"You don't have any rows yet","listIsEmpty@validators":"You don't have any validation rules yet","listIsEmpty@calculatedValues":"You don't have any custom variables yet","listIsEmpty@triggers":"You don't have any triggers yet","listIsEmpty@navigateToUrlOnCondition":"You don't have any links yet","addNew@choices":"Add new choice","addNew@columns":"Add new column","addNew@rows":"Add new row","addNew@validators":"Add new rule","addNew@calculatedValues":"Add new variable","addNew@triggers":"Add new trigger","addNew@navigateToUrlOnCondition":"Add new URL",expressionIsEmpty:"Expression is empty",value:"Value",text:"Text",rowid:"Row ID",imageLink:"Image or video file URL",columnEdit:"Edit column: {0}",itemEdit:"Edit item: {0}",url:"URL",path:"Path to data",choicesbyurl:{url:"Web service URL",valueName:"Get value to store from the following property"},titleName:"Get value to display from the following property",imageLinkName:"Get file URLs from the following property",allowEmptyResponse:"Accept empty response",titlePlaceholder:"Title",surveyTitlePlaceholder:"Survey Title",pageTitlePlaceholder:"Page {num}",descriptionPlaceholder:"Description",surveyDescriptionPlaceholder:"Description",pageDescriptionPlaceholder:"Description",textWrapEnabled:"Wrap choices",showOtherItem:'Enable the "Other" option',otherText:'Rename the "Other" option',showNoneItem:'Enable the "None" option',showRefuseItem:'Enable the "Refuse to Answer" option',showDontKnowItem:'Enable the "Don\'t Know" option',noneText:'Rename the "None" option',showSelectAllItem:'Enable the "Select All" option',selectAllText:'Rename the "Select All" option',choicesMin:"Minimum value for auto-generated items",choicesMax:"Maximum value for auto-generated items",choicesStep:"Step value for auto-generated items",name:"Name",title:"Title",cellType:"Cell input type",colCount:"Column count",choicesOrder:"Choice order",visible:"Visible",isRequired:"Required",markRequired:"Mark as required",removeRequiredMark:"Remove the required mark",isAllRowRequired:"Require an answer in each row",eachRowUnique:"Prevent duplicate responses in rows",requiredErrorText:"Error message for required questions",startWithNewLine:"Display the question on a new line",rows:"Rows",cols:"Columns",placeholder:"Placeholder text within input field",showPreview:"Show preview area",storeDataAsText:"Store file content in JSON result as text",maxSize:"Maximum file size (in bytes)",rowCount:"Row count",columnLayout:"Columns layout",addRowLocation:'"Add Row" button alignment',transposeData:"Transpose rows to columns",addRowText:'"Add Row" button text',removeRowText:'"Remove Row" button text',rateMin:"Minimum rating value",rateMax:"Maximum rating value",rateStep:"Step value",minRateDescription:"Minimum value label",maxRateDescription:"Maximum value label",inputType:"Input type",optionsCaption:"Option placeholder",defaultValue:"Default Answer",cellsDefaultRow:"Default texts",surveyEditorTitle:"Edit survey settings",qEditorTitle:"Edit: {0}",maxLength:"Maximum character limit",buildExpression:"Build",editExpression:"Edit",and:"and",or:"or",remove:"Remove",addCondition:"Add Condition",emptyLogicPopupMessage:"Select a question to start configuring conditions.",if:"If",then:"then",setToName:"Target question",fromName:"Question to copy answer from",gotoName:"Question to skip to",ruleIsNotSet:"Rule is incorrect",includeIntoResult:"Add to the survey results",showTitle:"Make the title and description visible",expandCollapseTitle:"Expand/collapse title",locale:"Select a survey language",simulator:"Select device type",landscapeOrientation:"Switch to landscape orientation",portraitOrientation:"Switch to portrait orientation",mode:"Survey display mode",clearInvisibleValues:"Clear hidden question values",cookieName:"Limit to one response",sendResultOnPageNext:"Auto-save survey progress on page change",storeOthersAsComment:'Save the "Other" option value as a separate property',showPageTitles:"Show page titles",showPageNumbers:"Show page numbers",pagePrevText:'"Previous Page" button text',pageNextText:'"Next Page" button text',completeText:'"Complete Survey" button text',previewText:'"Review Answers" button text',editText:'"Edit Answer" button text',startSurveyText:'"Start Survey" button text',showNavigationButtons:"Show/hide navigation buttons",showPrevButton:'Show the "Previous Page" button',firstPageIsStarted:"First page is a start page",showCompletedPage:'Show the "Thank You" page',goNextPageAutomatic:"Auto-advance to the next page",allowCompleteSurveyAutomatic:"Complete the survey automatically",showProgressBar:"Progress bar alignment",questionTitleLocation:"Question title alignment",questionTitleWidth:"Question title width",requiredText:"Required symbol(s)",questionTitleTemplate:"Question title template, default is: '{no}. {require} {title}'",questionErrorLocation:"Error message alignment",focusFirstQuestionAutomatic:"Focus first question on a new page",questionsOrder:"Question order",timeLimit:"Time limit to complete the survey",timeLimitPerPage:"Time limit to complete one page",showTimer:"Use a timer",timerLocation:"Timer alignment",timerInfoMode:"Timer mode",renderMode:"Panel display mode",allowAddPanel:"Enable panel addition",allowRemovePanel:"Enable panel removal",panelAddText:'"Add Panel" button text',panelRemoveText:'"Remove Panel" button text',isSinglePage:"Show all elements on one page",html:"HTML markup",setValue:"Answer",dataFormat:"Storage format",allowAddRows:"Enable row addition",allowRemoveRows:"Enable row removal",allowRowsDragAndDrop:"Enable row reordering",responsiveImageSizeHelp:"Does not apply if you specify the exact display area width or height.",minImageWidth:"Minimum display area width",maxImageWidth:"Maximum display area width",minImageHeight:"Minimum display area height",maxImageHeight:"Maximum display area height",minValue:"Minimum value",maxValue:"Maximum value",caseInsensitive:"Case insensitive",minLength:"Minimum length (in characters)",allowDigits:"Allow digits",minCount:"Minimum count",maxCount:"Maximum count",regex:"Regular expression",surveyvalidator:{text:"Error message",expression:"Validation expression"},totalText:"Total row header",totalType:"Aggregation method",totalExpression:"Total value expression",totalDisplayStyle:"Total value display format",totalCurrency:"Currency",totalFormat:"Formatted string",logo:"Survey logo",questionsOnPageMode:"Survey layout",maxTextLength:"Restrict answer length",maxOthersLength:"Restrict comment length",commentAreaRows:"Comment area height (in lines)",autoGrowComment:"Auto-expand text areas",allowResizeComment:"Allow users to resize text areas",textUpdateMode:"Update input field values",maskType:"Input mask type",focusOnFirstError:"Set focus on the first invalid answer",checkErrorsMode:"Run validation",validateVisitedEmptyFields:"Validate empty fields on lost focus",navigateToUrl:"Redirect to an external link after submission",navigateToUrlOnCondition:"Dynamic external link",completedBeforeHtml:"Markup to show if the user already filled out this survey",completedHtml:'"Thank You" page markup',completedHtmlOnCondition:'Dynamic "Thank You" page markup',loadingHtml:"Markup to show while survey model is loading",commentText:"Comment area text",autocomplete:"Autocomplete type",labelTrue:'Label for "True"',labelFalse:'Label for "False"',allowClear:"Show the Clear button",searchMode:"Search Mode",displayStyle:"Display format",format:"Formatted string",maximumFractionDigits:"Maximum fractional digits",minimumFractionDigits:"Minimum fractional digits",useGrouping:"Display grouping separators",allowMultiple:"Enable multiple file upload",allowImagesPreview:"Preview uploaded images",acceptedTypes:"Accepted file types",waitForUpload:"Wait for upload to complete",needConfirmRemoveFile:"Confirm file deletion",detailPanelMode:"Row expansion alignment",minRowCount:"Minimum row count",maxRowCount:"Maximum row count",confirmDelete:"Confirm row deletion",confirmDeleteText:"Confirmation message",panelCount:"Initial panel count",minPanelCount:"Minimum panel count",maxPanelCount:"Maximum panel count",panelsState:"Inner panel collapse state",panelPrevText:'"Previous Panel" button text',panelNextText:'"Next Panel" button text',panelRemoveButtonLocation:'"Remove Panel" button alignment',hideIfRowsEmpty:"Hide the question if it has no rows",hideColumnsIfEmpty:"Hide columns if there are no rows",rateValues:"Custom rating values",rateCount:"Rating count",autoGenerate:"Rating configuration",hideIfChoicesEmpty:"Hide the question if it has no choices",minWidth:"Minimum width",maxWidth:"Maximum width",width:"Width",showHeader:"Show column headers",horizontalScroll:"Show horizontal scrollbar",columnMinWidth:"Minimum column width",rowTitleWidth:"Row header width",valueTrue:'Value to store when "True" is selected',valueFalse:'Value to store when "False" is selected',minErrorText:'"Value is below minimum" error message',maxErrorText:'"Value exceeds maximum" error message',otherErrorText:'"Empty comment" error message',keyDuplicationError:"Error message for duplicate responses",minSelectedChoices:"Minimum choices to select",maxSelectedChoices:"Maximum choices to select",showClearButton:"Show the Clear button",logoWidth:"Logo width",logoHeight:"Logo height",readOnly:"Read-only",enableIf:"Disable the read-only mode if",emptyRowsText:'"No rows" message',separateSpecialChoices:"Separate special choices",choicesFromQuestion:"Copy choices from the following question",choicesFromQuestionMode:"Which choice options to copy",progressBarShowPageTitles:"Display page titles in progress bar",progressBarShowPageNumbers:"Display page numbers in progress bar",showCommentArea:"Add a comment box",commentPlaceholder:"Placeholder text for the comment box",displayRateDescriptionsAsExtremeItems:"Show the labels as extreme values",rowsOrder:"Row order",columnsLayout:"Column layout",columnColCount:"Nested column count",correctAnswer:"Correct Answer",defaultPanelValue:"Default Values",cells:"Cell Texts",fileInputPlaceholder:"Select a file or paste a file link...",keyName:"Prevent duplicate responses in the following column",itemvalue:{visibleIf:"Make the option visible if",enableIf:"Make the option selectable if"},"itemvalue@rows":{visibleIf:"Make the row visible if",enableIf:"Make the row editable if"},imageitemvalue:{text:"Alt text"},logoPosition:"Logo alignment",addLogo:"Add logo...",changeLogo:"Change logo...",logoPositions:{none:"Remove logo",left:"Left",right:"Right",top:"On the top",bottom:"In the bottom"},tabs:{panel:{layout:"Panel Layout"},general:"General",fileOptions:"Options",html:"HTML Editor",columns:"Columns",rows:"Rows",choices:"Choice Options",items:"Items",visibleIf:"Visible If",enableIf:"Editable If",requiredIf:"Required If",rateValues:"Rating Values",choicesByUrl:"Choices from a Web Service",matrixChoices:"Default Choices",multipleTextItems:"Text Inputs",numbering:"Numbering",validators:"Validators",navigation:"Navigation",question:"Question Settings",pages:"Pages",timer:"Quiz Mode",calculatedValues:"Calculated Values",triggers:"Triggers",templateTitle:"Title template",totals:"Totals",logic:"Conditions",mask:"Input Mask Settings",layout:{panel:"Panel Layout",question:"Layout",base:"Layout"},data:"Data",validation:"Validation",cells:"Individual Cell Texts",showOnCompleted:'"Thank You" Page',logo:"Logo in the Survey Header",slider:"Slider",expression:"Expression",questionSettings:"Question Settings",header:"Header",background:"Background",appearance:"Appearance",others:"Others"},editProperty:"Edit property '{0}'",items:"Items",choicesVisibleIf:"Make choices visible if",choicesEnableIf:"Make choices selectable if",columnsEnableIf:"Make columns visible if",rowsEnableIf:"Make rows visible if",innerIndent:"Increase the inner indent",defaultValueFromLastRow:"Use answers from the last row as default",defaultValueFromLastPanel:"Use answers from the last panel as default",enterNewValue:"Please enter a value.",noquestions:"There are no questions in the survey.",createtrigger:"Please create a trigger",titleKeyboardAdornerTip:"Press enter button to edit",keyboardAdornerTip:"Press enter button to edit item, press delete button to delete item, press alt plus arrow up or arrow down to move item",triggerOn:"On ",triggerMakePagesVisible:"Make pages visible",triggerMakeQuestionsVisible:"Make elements visible",triggerCompleteText:"Complete the survey if successful.",triggerNotSet:"The trigger is not set",triggerRunIf:"Run if",triggerSetToName:"Change value of: ",triggerFromName:"Copy value from: ",triggerRunExpression:"Run this Expression",triggerSetValue:"to: ",triggerGotoName:"Go to the question",triggerIsVariable:"Do not put the variable into the survey result.",triggerRunExpressionEmpty:"Please enter a valid expression",emptyExpressionPlaceHolder:"Type expression here...",noFile:"No file chosen",clearIfInvisible:"Clear hidden question values",valuePropertyName:"Store values in the following property",searchEnabled:"Enable search-as-you-type",hideSelectedItems:"Hide selected items",closeOnSelect:"Collapse the dropdown upon selection",verticalAlign:"Vertical alignment within cells",alternateRows:"Alternate row colors",columnsVisibleIf:"Make columns visible if",rowsVisibleIf:"Make rows visible if",otherPlaceholder:"Placeholder text for the comment box",filePlaceholder:"Placeholder text for Local file",photoPlaceholder:"Placeholder text for Camera",fileOrPhotoPlaceholder:"Placeholder text for Local file or Camera",rateType:"Rating icon",url_placeholder:"Ex.: https://api.example.com/books",path_placeholder:"Ex.: categories.fiction",questionStartIndex_placeholder:"Ex.: a)",width_placeholder:"Ex.: 6in",minWidth_placeholder:"Ex.: 600px",maxWidth_placeholder:"Ex.: 50%",imageHeight_placeholder:"auto",imageWidth_placeholder:"auto",theme:{themeName:"Theme",isPanelless:"Question appearance",editorPanel:"Background and corner radius",questionPanel:"Background and corner radius",primaryColor:"Accent color",panelBackgroundTransparency:"Panel and question box opacity",questionBackgroundTransparency:"Input element opacity",fontSize:"Survey font size",scale:"Survey scale factor",cornerRadius:"Corner radius",advancedMode:"Advanced mode",pageTitle:"Title font",pageDescription:"Description font",questionTitle:"Title font",questionDescription:"Description font",editorFont:"Font",backgroundOpacity:"Opacity","--sjs-font-family":"Survey font family","--sjs-general-backcolor-dim":"Background color","--sjs-primary-backcolor":"Accent background colors","--sjs-primary-forecolor":"Accent foreground colors","--sjs-special-red":"Error message colors","--sjs-shadow-small":"Shadow effects","--sjs-shadow-inner":"Shadow effects","--sjs-border-default":"Colors"},"header@header":{headerView:"View",logoPosition:"Logo alignment",surveyTitle:"Survey title font",surveyDescription:"Survey description font",headerTitle:"Survey title font",headerDescription:"Survey description font",inheritWidthFrom:"Content area width",textAreaWidth:"Text width",backgroundColorSwitch:"Background color",backgroundImage:"Background image",backgroundImageOpacity:"Opacity",overlapEnabled:"Overlap",logoPositionX:"Logo alignment",titlePositionX:"Survey title alignment",descriptionPositionX:"Survey description alignment"}},pv:{true:"true",false:"false",file:"Local file",camera:"Camera","file-camera":"Local file or Camera",inherit:"Inherit",show:"Visible",hide:"Hidden",default:"Inherit",initial:"Initial",random:"Random",collapsed:"Collapsed",expanded:"Expanded",none:"None",asc:"Ascending",desc:"Descending",indeterminate:"Indeterminate",selected:"Selected",unselected:"Unselected",decimal:"decimal",currency:"currency",percent:"percent",firstExpanded:"First panel is expanded",off:"Hide question numbers",list:"List",carousel:"Carousel",tab:"Tabs",progressTop:"Panel navigator + Progress bar at the top",progressBottom:"Panel navigator + Progress bar at the bottom",progressTopBottom:"Panel navigator + Progress bar at the top and bottom",horizontal:"Horizontal",vertical:"Vertical",top:"Top",bottom:"Bottom",topBottom:"Top and bottom",both:"Both",left:"Left",right:"Right",center:"Center",leftRight:"Left and right",middle:"Middle",color:"color",date:"date",datetime:"datetime","datetime-local":"datetime-local",email:"email",month:"month",number:"number",password:"password",range:"range",tel:"tel",text:"text",time:"time",url:"url",week:"week",hidden:"Hidden",edit:"Editable",display:"Read-only",contain:"Contain",cover:"Cover",fill:"Fill",next:"Next",last:"Last",onComplete:"Upon survey completion",onHidden:"When question gets hidden",onHiddenContainer:"When question or its panel/page gets hidden",clearInvisibleValues:{none:"Never"},clearIfInvisible:{none:"Never"},inputType:{color:"Color",date:"Date","datetime-local":"Date and Time",email:"Email",month:"Month",number:"Number",password:"Password",range:"Range",tel:"Phone Number",text:"Text",time:"Time",url:"URL",week:"Week"},maskType:{none:"None",pattern:"Pattern",numeric:"Numeric",datetime:"Date and Time",currency:"Currency"},inputTextAlignment:{auto:"Auto",left:"Left",right:"Right"},all:"All",page:"Page",survey:"Survey",onNextPage:"When switching to the next page",onValueChanged:"After an answer is changed",onValueChanging:"Before an answer is changed",questionsOnPageMode:{standard:"Original structure",singlePage:"Show all questions on one page",questionPerPage:"Show single question per page"},noPreview:"No preview",showAllQuestions:"Show all questions",showAnsweredQuestions:"Show answered questions only",pages:"Completed pages",questions:"Answered questions",requiredQuestions:"Answered required questions",correctQuestions:"Valid answers",buttons:"Completed pages (button UI)",underInput:"Under the input field",underTitle:"Under the question title",onBlur:"On lost focus",onTyping:"While typing",underRow:"Under the row",underRowSingle:"Under the row, display one row expansion only",auto:"Auto",showNavigationButtons:{none:"Hidden"},timerInfoMode:{combined:"Both"},addRowLocation:{default:"Based on matrix layout"},panelsState:{default:"Locked",collapsed:"Collapse all",expanded:"Expand all",firstExpanded:"First expanded"},widthMode:{static:"Static",responsive:"Responsive"},contentMode:{image:"Image",video:"Video",youtube:"YouTube"},displayMode:{buttons:"Buttons",dropdown:"Dropdown"},rateColorMode:{default:"Default",scale:"Scale"},scaleColorMode:{monochrome:"Monochrome",colored:"Colored"},autoGenerate:{true:"Auto-generate",false:"Manual"},rateType:{labels:"Labels",stars:"Stars",smileys:"Smileys"},state:{default:"Locked"},showQuestionNumbers:{default:"Auto-numbering",on:"Auto-numbering",onPage:"Reset on each page",onpanel:"Reset on each panel",onPanel:"Reset on each panel",onSurvey:"Continue across the survey",off:"No numbering"},descriptionLocation:{underTitle:"Under the question title",underInput:"Under the input field"},selectToRankAreasLayout:{horizontal:"Next to choices",vertical:"Above choices"},displayStyle:{decimal:"Decimal",currency:"Currency",percent:"Percentage",date:"Date"},totalDisplayStyle:{decimal:"Decimal",currency:"Currency",percent:"Percentage",date:"Date"},rowsOrder:{initial:"Original"},questionsOrder:{initial:"Original"},showProgressBar:{off:"Hidden",topbottom:"Top and bottom",aboveheader:"Above the header",belowheader:"Below the header"},progressBarLocation:{top:"Top",bottom:"Bottom",topBottom:"Top and bottom"},sum:"Sum",count:"Count",min:"Min",max:"Max",avg:"Avg",searchMode:{contains:"Contains",startsWith:"Starts with"},backgroundImageFit:{auto:"Auto",cover:"Cover",contain:"Contain",fill:"Stretch",tile:"Tile"},backgroundImageAttachment:{fixed:"Fixed",scroll:"Scroll"},headerView:{basic:"Basic",advanced:"Advanced"},inheritWidthFrom:{survey:"Same as survey",container:"Same as container"},backgroundColorSwitch:{none:"None",accentColor:"Accent color",custom:"Custom"},colorPalette:{light:"Light",dark:"Dark"},isPanelless:{false:"Default",true:"Without Panels"},progressBarInheritWidthFrom:{survey:"Same as survey",container:"Same as container"}},op:{empty:"Empty",notempty:"Not empty",equal:"Equals",notequal:"Does not equal",contains:"Contains",notcontains:"Does not contain",anyof:"Any of",allof:"All of",greater:"Greater than",less:"Less than",greaterorequal:"Greater than or equal to",lessorequal:"Less than or equal to",and:"and",or:"or"},ew:{angular:"Use Angular version",jquery:"Use jQuery version",knockout:"Use Knockout version",react:"Use React version",vue:"Use Vue version",bootstrap:"For bootstrap framework",modern:"Modern theme",default:"Default theme",orange:"Orange theme",darkblue:"Darkblue theme",darkrose:"Darkrose theme",stone:"Stone theme",winter:"Winter theme",winterstone:"Winter-Stone theme",showOnPage:"Show survey on a page",showInWindow:"Show survey in a window",loadFromServer:"Load Survey JSON from server",titleScript:"Scripts and styles",titleHtml:"HTML",titleJavaScript:"JavaScript"},ts:{selectPage:"Select the page to test it",showInvisibleElements:"Show invisible elements",hideInvisibleElements:"Hide invisible elements"},validators:{answercountvalidator:"Answer count",emailvalidator:"Email",expressionvalidator:"Expression",numericvalidator:"Number",regexvalidator:"Regex",textvalidator:"Text"},triggers:{completetrigger:"Complete survey",setvaluetrigger:"Set answer",copyvaluetrigger:"Copy answer",skiptrigger:"Skip to question",runexpressiontrigger:"Run expression",visibletrigger:"change visibility (deprecated)"},peplaceholder:{patternmask:{pattern:"Ex.: +1(999)-999-99-99"},datetimemask:{pattern:"Ex.: mm/dd/yyyy HH:MM:ss"},currencymask:{prefix:"Ex.: $",suffix:"Ex.: USD"},panelbase:{questionTitleWidth:"Ex.: 200px"},panellayoutcolumn:{effectiveWidth:"Ex.: 30%",questionTitleWidth:"Ex.: 200px"}},pehelp:{panel:{name:"A panel ID that is not visible to respondents.",description:"Type a panel subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines panel visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the panel.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",questionTitleLocation:'Applies to all questions within this panel. When set to "Hidden", it also hides question descriptions. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default). ',questionTitleWidth:"Sets consistent width for question titles when they are aligned to the left of their question boxes. Accepts CSS values (px, %, in, pt, etc.).",questionErrorLocation:'Sets the location of an error message in relation to all questions within the panel. The "Inherit" option applies the page-level (if set) or survey-level setting.',questionsOrder:'Keeps the original order of questions or randomizes them. The "Inherit" option applies the page-level (if set) or survey-level setting.',page:"Repositions the panel to the end of a selected page.",innerIndent:"Adds space or margin between the panel content and the left border of the panel box.",startWithNewLine:"Unselect to display the panel in one line with the previous question or panel. The setting doesn't apply if the panel is the first element in your form.",state:'Choose from: "Expanded" - the panel is displayed in full and can be collapsed; "Collapsed" - the panel displays only the title and description and can be expanded; "Locked" - the panel is displayed in full and cannot be collapsed.',width:"Sets the width of the panel in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.)."},paneldynamic:{name:"A panel ID that is not visible to respondents.",description:"Type a panel subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines panel visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the panel.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",templateTitleLocation:'Applies to all questions within this panel. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',templateErrorLocation:'Sets the location of an error message in relation to a question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',errorLocation:'Sets the location of an error message in relation to all questions within the panel. The "Inherit" option applies the page-level (if set) or survey-level setting.',page:"Repositions the panel to the end of a selected page.",innerIndent:"Adds space or margin between the panel content and the left border of the panel box.",startWithNewLine:"Unselect to display the panel in one line with the previous question or panel. The setting doesn't apply if the panel is the first element in your form.",state:'Choose from: "Expanded" - the panel is displayed in full and can be collapsed; "Collapsed" - the panel displays only the title and description and can be expanded; "Locked" - the panel is displayed in full and cannot be collapsed.',width:"Sets the width of the panel in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.).",templateTitle:"Type in a template for dynamic panel titles. Use {panelIndex} for the panel's general position and {visiblePanelIndex} for its order among visible panels. Insert these placeholders into the pattern to add automatic numbering.",templateTabTitle:"Type in a template for tab titles. Use {panelIndex} for a panel's general position and {visiblePanelIndex} for its order among visible panels. Insert these placeholders into the pattern to add automatic numbering.",tabTitlePlaceholder:"A fallback text for tab titles that applies when the tab title pattern doesn't produce a meaningful value.",templateVisibleIf:"This setting allows you to control the visibility of individual panels within the dynamic panel. Use the `{panel}` placeholder to reference the current panel in your expression.",titleLocation:'This setting is automatically inherited by all questions within this panel. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',descriptionLocation:'The "Inherit" option applies the page-level (if set) or survey-level setting ("Under the panel title" by default).',newPanelPosition:'Defines the position of a newly added panel. By default, new panels are added to the end. Select "Next" to insert a new panel after the current one.',defaultValueFromLastPanel:"Duplicates answers from the last panel and assigns them to the next added dynamic panel.",keyName:"Reference a question name to require a user to provide a unique response for this question in each panel."},defaultValueExpression:"This setting allows you to assign a default answer value based on an expression. The expression can include basic calculations - `{q1_id} + {q2_id}`, Boolean expressions, such as `{age} > 60`, and functions: `iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc. The value determined by this expression serves as the initial default value that can be overridden by a respondent's manual input.",resetValueIf:'Use the magic wand icon to set a conditional rule that determines when a respondent\'s input is reset to the value based on the "Default value expression" or "Set value expression" or to the "Default answer" value (if either is set).',setValueIf:'Use the magic wand icon to set a conditional rule that determines when to run the "Set value expression" and dynamically assign the resulting value as a response.',setValueExpression:'Specify an expression that defines the value to be set when the conditions in the "Set value if" rule are met. The expression can include basic calculations - `{q1_id} + {q2_id}`, Boolean expressions, such as `{age} > 60`, and functions: `iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc. The value determined by this expression can be overridden by a respondent\'s manual input.',question:{name:"A question ID that is not visible to respondents.",description:"Type a question subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines question visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the question.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey advancing or submission unless the question received an answer.",startWithNewLine:"Unselect to display the question in one line with the previous question or panel. The setting doesn't apply if the question is the first element in your form.",page:"Repositions the question to the end of a selected page.",state:'Choose from: "Expanded" - the question box is displayed in full and can be collapsed; "Collapsed" - the question box displays only the title and description and can be expanded; "Locked" - the question box is displayed in full and cannot be collapsed.',titleLocation:'Overrides title alignment rules defined on a panel, page, or survey level. When set to "Hidden", it also hides question descriptions. The "Inherit" option applies any higher-level settings (if set) or survey-level setting ("Top" by default).',descriptionLocation:'The "Inherit" option applies the survey-level setting ("Under the question title" by default).',errorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the survey-level setting ("Top" by default).',indent:"Adds space or margin between the question content and the left border of the question box.",width:"Sets the width of the question in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.).",surveyvalidator:{expression:"Use the magic wand icon to set a validation rule for the question."},textUpdateMode:'Choose from: "On lost focus" - the value is updated when the input field loses focus; "While typing" - the value is updated in real-time, as users are typing. The "Inherit" option applies the survey-level setting ("On lost focus" by default).',url:"You can use any web service as a data source for multiple-choice questions. To populate choice values, enter the URL of the service providing the data.",searchMode:"A comparison operation used to filter the drop-down list.",textWrapEnabled:"Long texts in choice options will automatically generate line breaks to fit within the drop-down menu. Unselect if you want the texts to clip."},signaturepad:{signatureWidth:"Sets the width of the displayed signature area and the resulting image.",signatureHeight:"Sets the height of the displayed signature area and the resulting image.",signatureAutoScaleEnabled:"Select if you want the signature area to fill all available space within the question box while maintaining the default 3:2 aspect ratio. When custom width and height values are set, the setting will keep the aspect ratio of these dimensions."},file:{imageHeight:"Adjusts the height of the image in the survey results.",imageWidth:"Adjusts the width of the image in the survey results.",allowImagesPreview:"Displays thumbnail previews for uploaded files when possible. Unselect if you want to show file icons instead."},image:{contentMode:'The "Auto" option automatically determines the suitable mode for display - Image, Video, or YouTube - based on the source URL provided.'},imagepicker:{imageHeight:"Overrides the minimum and maximum height values.",imageWidth:"Overrides the minimum and maximum width values.",choices:'"Value" serves as an item ID used in conditional rules; "Text" is displayed to respondents.',contentMode:'Choose between "Image" and "Video" to set the content mode of the media selector. If "Image" is selected, ensure that all options provided are image files in the following formats: JPEG, GIF, PNG, APNG, SVG, BMP, ICO. Similarly, if "Video" is selected, ensure that all options are direct links to video files in the following formats: MP4, MOV, WMV, FLV, AVI, MKV. Please note that YouTube links are not supported for video options.'},text:{size:'This setting only resizes the input field and doesn\'t affect the width of the question box. To limit the accepted input length, go to "Validation" → "Maximum character limit".'},comment:{rows:"Sets the number of displayed lines in the input field. If the input takes up more lines, the scroll bar will appear."},survey:{mode:'Choose between: "Editable" - enables respondents to fill out your survey; "Read-only" - disables form editing.'},matrixdropdowncolumn:{name:"A column ID that is not visible to respondents.",isUnique:"When enabled for a column, a respondent is required to provide a unique response for each question within this column.",rows:"Sets the number of displayed lines in the input field. If the input takes up more lines, the scroll bar will appear.",visibleIf:"Use the magic wand icon to set a conditional rule that determines column visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the column.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",showInMultipleColumns:"When selected, creates an individual column for each choice option.",colCount:'Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line. When set to -1, the actual value is inherited from the "Nested column count" property of the parent matrix.'},caseInsensitive:"Select if uppercase and lowercase letters in the regular expression must be treated as equivalent.",widthMode:'Choose from: "Static" - sets a fixed width; "Responsive" - makes the survey occupy the full width of the screen; "Auto" - applies either of the two depending on the question types used.',cookieName:"Assign a unique cookie value for your survey. The cookie will be set in a respondent's browser upon survey completion to prevent repetitive survey submissions.",logo:"Paste an image link (no size limits) or click the folder icon to browse a file from your computer (up to 64KB).",logoWidth:"Sets a logo width in CSS units (px, %, in, pt, etc.).",logoHeight:"Sets a logo height in CSS units (px, %, in, pt, etc.).",logoFit:'Choose from: "None" - image maintains its original size; "Contain" - image is resized to fit while maintaining its aspect ratio; "Cover" - image fills the entire box while maintaining its aspect ratio; "Fill" - image is stretched to fill the box without maintaining its aspect ratio.',goNextPageAutomatic:"Select if you want the survey to advance to the next page automatically after a respondent answers all questions on the current page.",allowCompleteSurveyAutomatic:"Select if you want the survey to complete automatically after a respondent answers all questions.",showNavigationButtons:"Sets the visibility and location of navigation buttons on a page.",showProgressBar:'Sets the visibility and location of a progress bar. The "Auto" value displays the progress bar above or below the survey header.',showPreviewBeforeComplete:"Enable the preview page with all or answered questions only.",questionTitleLocation:"Applies to all questions within the survey. This setting can be overridden by title alignment rules at lower levels: panel, page, or question. A lower-level setting will override those on a higher level.",requiredText:"A symbol or a sequence of symbols indicating that an answer is required.",questionStartIndex:"Enter a number or letter with which you want to start numbering.",questionErrorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box.',focusFirstQuestionAutomatic:"Select if you want the first input field on each page ready for text entry.",questionsOrder:"Keeps the original order of questions or randomizes them. The effect of this setting is only visible in the Preview tab.",maxTextLength:"For text entry questions only.",maxOthersLength:"For question comments only.",commentAreaRows:"Sets the number of displayed lines in text areas for question comments. In the input takes up more lines, the scroll bar appears.",autoGrowComment:"Select if you want question comments and Long Text questions to auto-grow in height based on the entered text length.",allowResizeComment:"For question comments and Long Text questions only.",calculatedValues:"Custom variables serve as intermediate or auxiliary variables used in form calculations. They take respondent inputs as source values. Each custom variable has a unique name and an expression it's based on.",includeIntoResult:"Select if you wish the calculated value of the expression to be saved along with survey results.",triggers:'A trigger is an event or condition that is based on an expression. Once the expression is evaluated to "true", a trigger sets off an action. Such an action can optionally have a target question it affects.',clearInvisibleValues:"Choose whether or not to clear values for questions hidden by conditional logic and when to do it.",textUpdateMode:'Choose from: "On lost focus" - the value is updated when the input field loses focus; "While typing" - the value is updated in real-time, as users are typing.',columns:"The left value serves as a column ID used in conditional rules, the right value is displayed to respondents.",rows:"The left value serves as a row ID used in conditional rules, the right value is displayed to respondents.",columnMinWidth:"Accepts CSS values (px, %, in, pt, etc.).",rowTitleWidth:"Accepts CSS values (px, %, in, pt, etc.).",totalText:'Visible only if at least one column displays total values set with "Aggregation method" or "Total value expression".',cellErrorLocation:'Sets the location of an error message in relation to a cell with invalid input. The "Inherit" option applies the setting from the "Error message alignment" property.',keyDuplicationError:'When the "Prevent duplicate responses" property is enabled, a respondent attempting to submit a duplicate entry will receive the following error message.',totalExpression:"Allows you to calculate total values based on an expression. The expression can include basic calculations (`{q1_id} + {q2_id}`), Boolean expressions (`{age} > 60`) and functions ('iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc.).",confirmDelete:"Triggers a prompt asking to confirm the row deletion.",defaultValueFromLastRow:"Duplicates answers from the last row and assigns them to the next added dynamic row.",keyName:"Reference a column ID to require a user to provide a unique response for each question within the specified column.",description:"Type a subtitle.",locale:"Choose a language to begin creating your survey. To add a translation, switch to a new language and translate the original text here or in the Translations tab.",detailPanelMode:'Sets the location of a details section in relation to a row. Choose from: "None" - no expansion is added; "Under the row" - a row expansion is placed under each row of the matrix; "Under the row, display one row expansion only" - an expansion is displayed under a single row only, the remaining row expansions are collapsed.',imageFit:'Choose from: "None" - image maintains its original size; "Contain" - image is resized to fit while maintaining its aspect ratio; "Cover" - image fills the entire box while maintaining its aspect ratio; "Fill" - image is stretched to fill the box without maintaining its aspect ratio.',autoGrow:'The "Inherit" option applies a survey-level setting ("Disabled" by default).',allowResize:'The "Inherit" option applies a survey-level setting ("Enabled" by default).',timeLimit:'A time interval in seconds after which the survey auto-advances to the "Thank You" page. When set to 0, counts the time spent on the survey.',timeLimitPerPage:'A time interval in seconds after which the survey auto-advances to the next page. Hides the "Previous" navigation button. When set to 0, counts the time spent on the current page.',validateVisitedEmptyFields:"Enable this option to trigger validation when a user focuses on an empty input field and then leaves it without making any changes.",page:{timeLimit:'A time interval in seconds after which the survey auto-advances to the next page. Hides the "Previous" navigation button. When set to 0, counts the time spent on the current page.',visibleIf:"Use the magic wand icon to set a conditional rule that determines page visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the page.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",questionTitleLocation:'Applies to all questions within this page. When set to "Hidden", it also hides question descriptions. If you want to override this setting, define title alignment rules for individual questions or panels. The "Inherit" option applies the survey-level setting ("Top" by default).',questionTitleWidth:"Sets consistent width for question titles when they are aligned to the left of their question boxes. Accepts CSS values (px, %, in, pt, etc.).",questionErrorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the survey-level setting ("Top" by default).',questionsOrder:'Keeps the original order of questions or randomizes them. The "Inherit" option applies the survey-level setting ("Original" by default). The effect of this setting is only visible in the Preview tab.',navigationButtonsVisibility:'Sets the visibility of navigation buttons on the page. The "Inherit" option applies the survey-level setting, which defaults to "Visible".'},timerLocation:"Sets the location of a timer on a page.",panelsState:'Choose from: "Locked" - users cannot expand or collapse panels; "Collapse all" - all panels start in a collapsed state; "Expand all" - all panels start in an expanded state; "First expanded" - only the first panel is initially expanded. Applies if "Panel display mode" is set to "List" and the "Panel title pattern" property is specified.',imageLinkName:"Enter a shared property name within the array of objects that contains the image or video file URLs you want to display in the choice list.",choices:"The left value serves as an item ID used in conditional rules, the right value is displayed to respondents.",title:"Type a user-friendly title to display.",waitForUpload:"Ensures that users won't complete the survey until files are uploaded.",minWidth:"Accepts CSS values (px, %, in, pt, etc.).",maxWidth:"Accepts CSS values (px, %, in, pt, etc.).",width:"Accepts CSS values (px, %, in, pt, etc.).",valueName:"A join identifier is a custom key that you can assign to several questions to link them together and sync their values. These values will be merged into a single array or object and stored in survey results using the key as the property name.",useDisplayValuesInDynamicTexts:"In single- and multiple-selection question types, each choice option has an ID and display value. When selected, this setting shows a display value instead of an ID value in HTML questions and dynamic titles and descriptions of survey elements.",clearIfInvisible:'Choose whether or not to clear question values hidden by conditional logic and when to do it. The "Inherit" option applies the survey-level setting ("Upon survey completion" by default).',choicesFromQuestionMode:'Choose from: "All" - copies all choice options from the selected question; "Selected" - dynamically copies only selected choice options; "Unselected" - dynamically copies only unselected choice options. The "None" and "Other" options are copied by default if enabled in the source question.',showOtherItem:"When selected, users can include additional input in a separate comment box.",separateSpecialChoices:'Displays each special choice option ("None", "Other", "Select All") on a new line, even when using a multiple-column layout.',path:"Specify the location within the service dataset where the target array of objects is located. Leave empty if the URL already points to the array.",choicesbyurl:{valueName:"Enter a uniform property name within the array of objects whose value will be stored as a response in survey results."},titleName:"Enter a uniform property name within the array of objects that contains the values you want to display in the choice list.",allowEmptyResponse:"Select to allow the service to return an empty response or array.",choicesVisibleIf:"Use the magic wand icon to set a conditional rule that determines the visibility of all choice options.",rateValues:"The left value serves as an item ID used in conditional rules, the right value is displayed to respondents.",rating:{displayMode:'"Auto" selects between the "Buttons" and "Dropdown" modes based on the available width. When the width is insufficient to display buttons, the question displays a dropdown.'},valuePropertyName:"Allows you to connect questions that produce results in different formats. When such questions are linked together using a join identifier, this shared property stores selected question values.",searchEnabled:"Select if you want to update the drop-down menu contents to match the search query that a user is typing in the input field.",valueTrue:"A value to save in survey results when respondents give a positive answer.",valueFalse:"A value to save in survey results when respondents give a negative answer.",showPreview:"It's not recommended that you disable this option as it overrides the Preview image and makes it hard for a user to understand whether the files have been uploaded.",needConfirmRemoveFile:"Triggers a prompt asking to confirm the file deletion.",selectToRankEnabled:"Enable to rank only selected choices. Users will drag selected items from the choice list to order them within the ranking area.",dataList:"Enter a list of choices that will be suggested to the respondent during input.",itemSize:"The setting only resizes the input fields and doesn't affect the width of the question box.",itemTitleWidth:"Sets consistent width for all item labels in pixels",inputTextAlignment:'Select how to align input value within the field. The default setting "Auto" aligns the input value to the right if currency or numeric masking is applied and to the left if not.',altText:"Serves as a substitute when the image cannot be displayed on a user's device and for accessibility purposes.",rateColorMode:'Defines the color of the selected emoji when the Rating icon type is set to "Smileys". Choose between: "Default" - the selected emoji appears in default survey color; "Scale" - the selected emoji inherits color from the rating scale.',expression:{name:"An expression ID that is not visible to respondents.",description:"Type an expression subtitle.",expression:"An expression can include basic calculations (`{q1_id} + {q2_id}`), conditions (`{age} > 60`), and functions ('iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc.)."},storeOthersAsComment:'Select to store the "Other" option value as a separate property in survey results.',format:"Use {0} as a placeholder for the actual value.",acceptedTypes:"Refer to the [accept](https://www.w3schools.com/tags/att_input_accept.asp) attribute description for more information.",columnColCount:'Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line. Applies only to columns with "Cell input type" set to Radio Button Group or Checkboxes.',autocomplete:"Select the data type that the user's browser can retrieve. This data is sourced either from past values entered by the user or from pre-configured values if any have been saved by the user for autocompletion.",filePlaceholder:'Applies when "File source type" is "Local file" or when camera is unavailable',photoPlaceholder:'Applies when "File source type" is "Camera".',fileOrPhotoPlaceholder:'Applies when "File source type" is "Local file or camera".',colCount:"Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line.",masksettings:{saveMaskedValue:"Select if you want to store the question value with an applied mask in survey results."},patternmask:{pattern:"The pattern can contain string literals and the following placeholders: `9` - for a digit; `a` - for an upper- or lower-case letter; `#` - for a digit or an upper- or lower-case letter. Use backslash `\\` to escape a character."},datetimemask:{pattern:"The pattern can contain separator characters and the following placeholders:<br>`m` - Month number.<br>`mm` - Month number, with leading zero for single-digit values.<br>`d` - Day of the month.<br>`dd` - Day of the month, with leading zero for single-digit values.<br>`yy` - The last two digits of the year.<br>`yyyy` - Four-digit year.<br>`H` - Hours in 24-hour format.<br>`HH` - Hours in 24-hour format, with leading zero for single-digit values.<br>`h` - Hours in 12-hour format.<br>`hh` - Hours in 12-hour format, with leading zero for single-digit values.<br>`MM` - Minutes.<br>`ss` - Seconds.<br>`TT` - 12-hour clock period in upper case (AM/PM).<br>`tt` - 12-hour clock period in lower case (am/pm)."},numericmask:{decimalSeparator:"A symbol used to separate the fractional part from the integer part of a displayed number.",thousandsSeparator:"A symbol used to separate the digits of a large number into groups of three.",precision:"Limits how many digits to retain after the decimal point for a displayed number."},currencymask:{prefix:"One or several symbols to be displayed before the value.",suffix:"One or several symbols to be displayed after the value."},theme:{isPanelless:"This setting applies only to questions outside of a panel.",primaryColor:"Sets a supplementary color that highlights key survey elements.",panelBackgroundTransparency:"Adjusts the transparency of panels and question boxes relative to the survey background.",questionBackgroundTransparency:"Adjusts the transparency of input elements relative to the survey background.",cornerRadius:"Sets the corner radius for all rectangular elements. Enable the Advanced Mode if you want to set individual corner radius values for input elements or panels and question boxes.","--sjs-general-backcolor-dim":"Sets the main background color of the survey."},header:{inheritWidthFrom:'The "Same as container" option auto-adjusts the header content area width to fit into the HTML element the survey is placed in.',textAreaWidth:"The width of the header area that contains the survey title and description, measured in pixels.",overlapEnabled:"When enabled, the top of the survey overlays the bottom of the header.",mobileHeight:"When set to 0, the height is calculated automatically to accommodate the header's content."},panellayoutcolumn:{effectiveWidth:"Accepts values %.",questionTitleWidth:"Accepts values px."},progressBarInheritWidthFrom:'The "Same as container" option auto-adjusts the progress bar area width to fit into the HTML element the survey is placed in.'},p:{title:{name:"title",title:"Leave it empty, if it is the same as 'Name'"},multiSelect:"Allow multiple selection",showLabel:"Show image and video captions",swapOrder:"Swap the order of Yes and No",value:"Value",tabAlign:"Tab alignment",sourceType:"File source type",fitToContainer:"Fit to container",setValueExpression:"Set value expression",description:"Description",logoFit:"Logo fit",pages:"Pages",questions:"Questions",triggers:"Triggers",calculatedValues:"Custom variables",surveyId:"Survey id",surveyPostId:"Survey post id",surveyShowDataSaving:"Survey show data saving",questionDescriptionLocation:"Question description alignment",progressBarType:"Progress bar type",showTOC:"Show table of contents (TOC)",tocLocation:"TOC alignment",questionTitlePattern:"Question title pattern",widthMode:"Survey width mode",showBrandInfo:"Show brand info",useDisplayValuesInDynamicTexts:"Use display values in dynamic texts",visibleIf:"Visible if",defaultValueExpression:"Default value expression",requiredIf:"Required if",resetValueIf:"Reset value if",setValueIf:"Set value if",validators:"Validation rules",bindings:"Bindings",renderAs:"Render as",attachOriginalItems:"Attach original items",choices:"Choices",choicesByUrl:"Choices by url",currency:"Currency",cellHint:"Cell hint",totalMaximumFractionDigits:"Total maximum fraction digits",totalMinimumFractionDigits:"Total minimum fraction digits",columns:"Columns",detailElements:"Detail elements",allowAdaptiveActions:"Allow adaptive actions",defaultRowValue:"Default row value",detailPanelShowOnAdding:"Detail panel show on adding",choicesLazyLoadEnabled:"Choices lazy load enabled",choicesLazyLoadPageSize:"Choices lazy load page size",inputFieldComponent:"Input field component",itemComponent:"Item component",min:"Min",max:"Max",minValueExpression:"Min value expression",maxValueExpression:"Max value expression",step:"Step",dataList:"Items for auto-suggest",itemSize:"Input field width (in characters)",itemTitleWidth:"Item label width (in px)",inputTextAlignment:"Input value alignment",elements:"Elements",content:"Content",navigationButtonsVisibility:"Show/hide navigation buttons",navigationTitle:"Navigation title",navigationDescription:"Navigation description",longTap:"Long tap",autoGrow:"Expand input field dynamically",allowResize:"Enable resize handle",acceptCarriageReturn:"Accept carriage return",displayMode:"Display mode",rateType:"Rate type",label:"Label",contentMode:"Content mode",imageFit:"Image and thumbnail fit",altText:"Alt text",height:"Height",mobileHeight:"Height on smartphones",penColor:"Pen color",backgroundColor:"Background color",templateElements:"Template elements",operator:"Operator",isVariable:"Is variable",runExpression:"Run expression",showCaption:"Show caption",iconName:"Icon name",iconSize:"Icon size",precision:"Precision",matrixDragHandleArea:"Matrix drag handle area",backgroundImage:"Background image",backgroundImageFit:"Background image fit",backgroundImageAttachment:"Background image attachment",backgroundOpacity:"Background opacity",selectToRankEnabled:"Allow selective ranking",selectToRankAreasLayout:"Ranking area alignment",selectToRankEmptyRankedAreaText:"Text to show if all options are selected",selectToRankEmptyUnrankedAreaText:"Placeholder text for the ranking area",allowCameraAccess:"Allow camera access",scaleColorMode:"Rating icon color mode",rateColorMode:"Smileys color scheme",copyDisplayValue:"Copy display value",effectiveColSpan:"Column span",progressBarInheritWidthFrom:"Progress bar area width"},theme:{advancedMode:"Advanced mode",pageTitle:"Page",questionTitle:"Question box",editorPanel:"Input element",lines:"Lines",primaryDefaultColor:"Default",primaryDarkColor:"Hover",primaryLightColor:"Selected",backgroundDimColor:"Background color",cornerRadius:"Corner radius",backcolor:"Default background",hovercolor:"Hover background",borderDecoration:"Border decoration",fontColor:"Font color",backgroundColor:"Background color",primaryForecolor:"Default color",primaryForecolorLight:"Disabled color",font:"Font",borderDefault:"Darker",borderLight:"Lighter",fontFamily:"Font family",fontWeightRegular:"Regular",fontWeightHeavy:"Heavy",fontWeightSemiBold:"Semi-bold",fontWeightBold:"Bold",color:"Color",placeholderColor:"Placeholder color",size:"Size",opacity:"Opacity",boxShadowX:"X",boxShadowY:"Y",boxShadowAddRule:"Add Shadow Effect",boxShadowBlur:"Blur",boxShadowSpread:"Spread",boxShadowDrop:"Drop",boxShadowInner:"Inner",names:{default:"Default",sharp:"Sharp",borderless:"Borderless",flat:"Flat",plain:"Plain",doubleborder:"Double Border",layered:"Layered",solid:"Solid",threedimensional:"3D",contrast:"Contrast"},colors:{teal:"Teal",blue:"Blue",purple:"Purple",orchid:"Orchid",tulip:"Tulip",brown:"Brown",green:"Green"}}},o=n(156);!function(e){e[e.AllTypes=0]="AllTypes",e[e.CompatibleTypes=1]="CompatibleTypes"}(e||(e={}));var i={translation:{sortByName:!1,exportPrefix:"",maximumSelectedLocales:7,exportFileName:"survey_translation.csv"},themeEditor:{exportFileName:"survey_theme.json",defaultFontFamily:"Open Sans"},operators:{empty:[],notempty:[],equal:["!file"],notequal:["!file"],contains:["checkbox","text","comment"],notcontains:["checkbox","text","comment"],anyof:["selectbase"],allof:["checkbox"],greater:["!checkbox","!imagepicker","!boolean","!file"],less:["!checkbox","!imagepicker","!boolean","!file"],greaterorequal:["!checkbox","!imagepicker","!boolean","!file"],lessorequal:["!checkbox","!imagepicker","!boolean","!file"]},defaultNewSurveyJSON:{},designer:{defaultAddQuestionType:"text",showAddQuestionButton:!0},logic:{questionSortOrder:"asc",get defaultOperator(){return i.logic.defaultOperators.default},set defaultOperator(e){i.logic.defaultOperators.default=e},defaultOperators:{default:"equal",checkbox:"allof",tagbox:"allof"},visibleActions:[],logicItemTitleMaxChars:50,openBracket:"{",closeBracket:"}",updateExpressionsOnChanging:{questionName:!0,columnName:!0,choiceValue:!0},updateExpressionsOnDeleting:{question:!0}},questionConvertMode:e.AllTypes,propertyGrid:{useButtonGroup:!0,maxCharsInButtonGroup:25,showNavigationButtons:!1,enableSearch:!0,maximumColumnsCount:0,minimumChoicesCount:0,maximumChoicesCount:0,maximumRowsCount:0,maximumRateValues:0,generalTabName:"general",defaultExpandedTabName:"general",allowExpandMultipleCategories:!1},toolbox:{defaultJSON:{dropdown:{choices:["Item 1","Item 2","Item 3"]},tagbox:{choices:["Item 1","Item 2","Item 3"]},checkbox:{choices:["Item 1","Item 2","Item 3"]},radiogroup:{choices:["Item 1","Item 2","Item 3"]},ranking:{choices:["Item 1","Item 2","Item 3"]},imagepicker:{imageFit:"cover",choices:[{value:"Image 1",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/lion.jpg"},{value:"Image 2",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/giraffe.jpg"},{value:"Image 3",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/panda.jpg"},{value:"Image 4",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/camel.jpg"}]},image:{imageFit:"cover",imageHeight:"auto",imageWidth:"100%"}}},notifications:{lifetime:2e3},autoSave:{delay:500},dragDrop:{restrictDragQuestionBetweenPages:!1,allowDragToTheSameLine:!0},layout:{showTabs:!0,showToolbar:!0,allowCollapseSidebar:!0},jsonEditor:{indentation:2,exportFileName:"survey.json"}},a=function(){function e(){this.isMobileView=!1,this.allowEditExpressionsInTextEditor=!0,this.maximumColumnsCount=i.propertyGrid.maximumColumnsCount,this.minimumChoicesCount=i.propertyGrid.minimumChoicesCount,this.maximumChoicesCount=i.propertyGrid.maximumChoicesCount,this.maximumRowsCount=i.propertyGrid.maximumRowsCount,this.maximumRateValues=i.propertyGrid.maximumRateValues,this.machineTranslationValue=!1,this.inplaceEditForValues=!1,this.maxNestedPanels=-1,this.translationLocalesOrder=[]}return e.prototype.getProcessedTranslationItemText=function(e,t,o,i){return o},e.prototype.getObjectDisplayName=function(e,t,o,i){return i},e.prototype.onCanShowPropertyCallback=function(e,t,o,i,n){return!0},e.prototype.getElementAddornerCssCallback=function(e,t){return t},e.prototype.onPropertyGridSurveyCreatedCallback=function(e,t){},e.prototype.onPropertyEditorCreatedCallback=function(e,t,o){},e.prototype.onPropertyEditorUpdateTitleActionsCallback=function(e,t,o,i){},e.prototype.onPropertyGridShowModalCallback=function(e,t,o,i,n){},e.prototype.onIsPropertyReadOnlyCallback=function(e,t,o,i,n){return o},e.prototype.onCanDeleteItemCallback=function(e,t,o){return o},e.prototype.onCollectionItemDeletingCallback=function(e,t,o,i){return!0},e.prototype.onCollectionItemAllowingCallback=function(e,t,o,i,n){},e.prototype.onItemValueAddedCallback=function(e,t,o,i){},e.prototype.onFastEntryCallback=function(e,t){return e},e.prototype.onMatrixDropdownColumnAddedCallback=function(e,t,o){},e.prototype.onSetPropertyEditorOptionsCallback=function(e,t,o){},e.prototype.onGetErrorTextOnValidationCallback=function(e,t,o){return null},e.prototype.onValueChangingCallback=function(e){},e.prototype.onGetElementEditorTitleCallback=function(e,t){return t},e.prototype.startUndoRedoTransaction=function(){},e.prototype.stopUndoRedoTransaction=function(){},e.prototype.createSurvey=function(e,t,i,n,r){var a=new o.SurveyModel(e);return n&&n(a),a},e.prototype.onConditionQuestionsGetListCallback=function(e,t,o,i,n){return"asc"},e.prototype.onConditionGetTitleCallback=function(e,t){return t},e.prototype.isConditionOperatorEnabled=function(e,t,o,i){return i},e.prototype.onLogicGetTitleCallback=function(e,t,o,i){return o},e.prototype.getTranslationExportedText=function(e,t,o,i,n){return n},e.prototype.uploadFiles=function(e,t,o){},e.prototype.getHasMachineTranslation=function(){return this.machineTranslationValue},e.prototype.doMachineTranslation=function(e,t,o,i){},e.prototype.chooseFiles=function(e,t,o){},e}();function s(e){if(!e)return"";for(var t="",o=e.length-1;o>=0;o--){if(e[o]>="0"&&e[o]<="9")t=e[o]+t;else if(t)return t;if(10==t.length)break}return t}function l(e){return Math.round(100*e)/100}o.StylesManager.applyTheme("defaultV2");var u={true:"false",True:"False",TRUE:"FALSE",false:"true",False:"True",FALSE:"TRUE",yes:"no",Yes:"No",YES:"NO",no:"yes",No:"Yes",NO:"YES"};function p(e,t){t=t.toString();for(var o=0;o<e.length;o++)if(e[o]&&e[o].toString()===t)return!0;return!1}function c(e,t){return h(e,t.map((function(e){return e.value})))}function d(e){var t=e.length;if(0===t)return"";if(!e[t-1].text||e[t-1].text===e[t-1].value)return"";var o=[];e.forEach((function(e){e.hasText&&o.push(e.text)})),e.map((function(e){return e.text}));var i=h("",o);return i?i.toString():""}function h(e,t){if(t.length>0)var o=function(e){return u[e]?u[e]:null}(t[t.length-1]);if(o&&t.indexOf(o)<0)return o;for(var i,n="",r=-1,a=t.length-1;a>=0;a--)if(t[a]){var l=t[a].toString();if(n=s(l)){r=l.lastIndexOf(n),i=t[a];break}}if(r>-1){var c,d=parseInt(n),h=i===d;do{if(h)c=++d;else{for(var g=(d++).toString();n.length>g.length;)g="0"+g;c=l.substring(0,r)+g+l.substring(r+n.length)}}while(p(t,c));return c}return e||(e=t[t.length-1]),e+1}function g(e,t){for(var o=t;o&&!o.classList.contains(e);)o=o.parentElement;return o}function m(e){for(var t=0;t<e.length;t++)if("function"==typeof e[t].getElementsByClassName){var o=e[t].getElementsByClassName("svd-focusable");if(0===o.length&&-1!==e[t].className.indexOf("svd-focusable")&&(o=[e[t]]),o.length>0){var i=o[0];if("a"!==i.tagName.toLowerCase()){i.focus({preventScroll:!0});break}}}}function f(e){if(e&&e.length){for(var t=0;t<e.length;t++)if("#text"!=e[t].nodeName&&"#comment"!=e[t].nodeName)return e[t];return null}}function y(e){var t=e.element,o=[];if(8!==t.nodeType)return t.childNodes;for(;t=t.nextSibling;)3!==t.nodeType&&o.push(t);return o}function v(e,t){var i=!0;return e&&"function"==typeof e.getType&&(i=!!o.Serializer.findProperty(e.getType(),t)),i}function b(e,t){var i=!0;if(e&&"function"==typeof e.getType){var n=o.Serializer.findProperty(e.getType(),t);i=!n||n.visible}return i}function C(e,t,o){void 0===o&&(o=0);var i="__svc_question_processed",n="svc-hovered",r="svc-hovered-ready";function a(e,o){void 0===o&&(o=null);var i=(t.className||"").split(" ");o&&-1==i.indexOf(o)||-1==i.indexOf(e)&&(t.className+=" "+e)}e[i]||"mouseover"!==e.type?(t.className=(t.className||"").replace(" svc-hovered-ready",""),t.className=(t.className||"").replace(" svc-hovered","")):(o?(a(r),setTimeout((function(){a(n,r)}),o)):a(n),e[i]=!0)}function w(e){return e.replace(new RegExp("(\\r\\n|\\n|\\r)","gm"),"")}function x(e){var t,o;window&&(window.getSelection&&document.createRange?(o=window.getSelection(),(t=document.createRange()).selectNodeContents(e),o.removeAllRanges(),o.addRange(t)):document.selection&&document.body.createTextRange&&((t=document.body.createTextRange()).moveToElementText(e),t.select()))}function T(e,t){for(var o in t){var i=t[o];"object"==typeof i&&T(i={},t[o]),e[o]=i}}function S(e,t){t&&("string"==typeof t||t instanceof String?e.root=t:T(e,t))}function P(e,t){S(e,o.defaultV2Css.question),S(e,o.defaultV2Css[t]),e.hasErrorTop="",e.hasErrorBottom=""}function E(e){return i.logic.openBracket+e+i.logic.closeBracket}function V(e){return e?e=(e=e.replace(/[\s]+/g," ")).replace(/([\s]|^)(\S)/g,(function(e,t,o){return t+o.toUpperCase()})):e}function I(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.every((function(e){return!0===e}))}var A="image/png, image/gif, image/jpeg, image/apng, image/avif, image/svg+xml, image/webp";function O(e){return["auto","image"].indexOf(e)>-1?A:"video"==e?"video/*":""}function N(e){return e instanceof o.MatrixDropdownColumn?e.templateQuestion:e}function L(e){if(e&&void 0!==o.settings.environment.root){var t=o.settings.environment.root.getElementById(e);t&&t.scrollIntoView({behavior:"smooth",block:"center",inline:"start"})}}function _(e,t){if(e&&void 0!==t){var o=parseInt(e.slice(1,3),16),i=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16);return"rgba(".concat(o,", ").concat(i,", ").concat(n,", ").concat(t,")")}}function M(e,t){return"rgba(".concat(e[0],", ").concat(e[1],", ").concat(e[2],", ").concat(t,")")}function D(e){void 0===e&&(e="");var t=e.match(/\((.*)\)/);return t?t[1].split(",").map((function(e){return parseFloat(e)})):[]}function k(e){void 0===e&&(e="");var t=D(e);if(0!==t.length){var o=1;return 4==t.length&&(o=t.pop()),{color:t.reduce((function(e,t){var o=t.toString(16);return e+(1==o.length?"0"+o:o)}),"#"),opacity:l(100*o)}}return{color:e,opacity:100}}function j(e,t,o){t/=100,o/=100;var i=function(t){return(t+e/60)%6},n=function(e){return o*(1-t*Math.max(0,Math.min(i(e),4-i(e),1)))};return[Math.round(255*n(5)),Math.round(255*n(3)),Math.round(255*n(1))]}function R(e,t,o){e/=255,t/=255,o/=255;var i=Math.max(e,t,o),n=i-Math.min(e,t,o),r=0===n?0:n&&i===e?(t-o)/n:i===t?2+(o-e)/n:4+(e-t)/n;return[60*(r<0?r+6:r),i&&n/i*100,100*i]}function B(e){Object.keys(e).forEach((function(t){void 0!==e[t]&&null!==e[t]||delete e[t]}))}function q(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var o=(e||[]).filter((function(e){return!!e}));if(!(o.length<=1)){if(2==o.length)return Object.keys(o[1]).forEach((function(e){return o[0][e]=o[1][e]})),void B(e[0]);for(var i=1;i<o.length;i++)q(o[0],o[i])}}var H=function(){function e(){this.colorSettings={baseColorAlpha:1,darkColorAlpha:1,lightColorAlpha:1,deltaDarkColor:0,deltaLightColor:0,newColorLight:"",newColorDark:""}}return e.prototype.initialize=function(e,t,o){var i=D(e),n=D(o),r=D(t);this.colorSettings.baseColorAlpha=i[3],this.colorSettings.darkColorAlpha=n[3],this.colorSettings.lightColorAlpha=r[3];var a=R(i[0],i[1],i[2]),s=R(n[0],n[1],n[2]),l=R(r[0],r[1],r[2]);this.colorSettings.deltaDarkColor=a[2]-s[2],this.colorSettings.deltaLightColor=a[2]-l[2]},e.prototype.calculateColors=function(e){var t=D(e);0===t.length&&(t=D(_(e,1)));var o=R(t[0],t[1],t[2]),i=j(o[0],o[1],o[2]-this.colorSettings.deltaDarkColor),n=j(o[0],o[1],o[2]-this.colorSettings.deltaLightColor);this.colorSettings.newColorLight=M(n,this.colorSettings.lightColorAlpha),this.colorSettings.newColorDark=M(i,this.colorSettings.darkColorAlpha)},e}();function Q(e,t){if(window)if(window.navigator.msSaveOrOpenBlob)window.navigator.msSaveBlob(t,e);else{var o=window.document.createElement("a");o.href=window.URL.createObjectURL(t),o.download=e,document.body.appendChild(o),o.click(),document.body.removeChild(o)}}var F={"tabs.preview":"ed.testSurvey","tabs.theme":"ed.themeSurvey","tabs.translation":"ed.translation","tabs.designer":"ed.designer","tabs.editor":"ed.jsonEditor","tabs.logic":"ed.logic"},U=function(){function e(){this.defaultLocaleValue="en",this.currentLocaleValue="",this.camelCaseBreaking=!0,this.locales={},this.peByClass={},this.peHelpByClass={},this.pePlaceholderByClass={}}return e.prototype.reset=function(){this.peByClass={},this.peHelpByClass={},this.pePlaceholderByClass={}},Object.defineProperty(e.prototype,"defaultLocale",{get:function(){return this.defaultLocaleValue},set:function(e){e||(e="en"),e!==this.defaultLocale&&(this.defaultLocaleValue=e,this.reset())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentLocale",{get:function(){return this.currentLocaleValue},set:function(e){e||(e=""),e!==this.currentLocale&&(this.currentLocaleValue=e,this.reset())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"presetStrings",{get:function(){return this.presetStringsValues},set:function(e){this.presetStringsValues=e,this.reset()},enumerable:!1,configurable:!0}),e.prototype.getString=function(e,t){void 0===t&&(t=null);var o=this.getOldKeysString(e,t);if(o)return o;var i=e.split(".");return this.getStringByPath(i,t)},e.prototype.getStringByPath=function(e,t){void 0===t&&(t=null),t||(t=this.currentLocale);var o=this.getLocale(t),i=this.getDefaultStrings(),n=[];if(o&&n.push(o),t&&t.indexOf("-")>-1){var r=this.getLocale(t.substring(0,t.indexOf("-")));r&&n.push(r)}0!==n.length&&n[n.length-1]===i||n.push(i);var a=this.getPresetLocale(t);a&&n.unshift(a);for(var s=0;s<n.length;s++){var l=this.getStringByLocale(e,n[s]);if(l||""===l)return l}return e[e.length-1]},e.prototype.hasString=function(e,t){return void 0===t&&(t=null),void 0!==this.getStringByLocale(e.split("."),this.getLocale(t))},e.prototype.getStringByLocale=function(e,t){for(var o=t,i=0;i<e.length;i++){if("string"==typeof o)return;if(!(o=o[e[i]])&&""!==o)return}return o},e.prototype.getLocaleName=function(e,t,i){void 0===t&&(t=null),t||(t=o.surveyLocalization.defaultLocale);var n=o.surveyLocalization.getLocaleName(e||t,i);return n===e?n:(n=V(n),e||(n=G.getString("ed.defaultLocale").format(n)),n||e)},e.prototype.getPropertyName=function(e,t){void 0===t&&(t=null);var o=this.getProperty(e,t),i=o.name;return i?this.stringsDiff(i,e)?i:this.getAutoPropertyName(i,t):o},e.prototype.getPropertyTitle=function(e){var t=this.getProperty(e);return t.title?t.title:""},e.prototype.getPropertyNameInEditor=function(e,t,o){void 0===o&&(o=null);var i=this.getPropertyInfoInEditorByType(e,t,this.peByClass,"pe");return i||(i=this.getStringByPath(["pe",t])),this.stringsDiff(i,t)?i:this.getPropertyName(t,o)},e.prototype.getPropertyHelpInEditor=function(e,t,o){void 0===o&&(o=void 0);var i=this.getPropertyHelpInEditorCore(e,t,this.peHelpByClass,"pehelp");if(i)return i;var n=this.getLocale();return o&&n&&n.pe?n.pe[o+"Help"]:void 0},e.prototype.getPropertyPlaceholder=function(e,t){var o=this.getPropertyHelpInEditorCore(e,t,this.pePlaceholderByClass,"peplaceholder");if(o)return" "===o?null:o;var i=this.getLocale();return i&&i.peplaceholder&&(o=i.peplaceholder[t]),o||(i&&i.pe?i.pe[t+"_placeholder"]:void 0)},e.prototype.getPropertyHelpInEditorCore=function(e,t,o,i){var n=this.getPropertyInfoInEditorByType(e,t,o,i);if(n)return" "===n?null:n;for(var r=this.getLocalesWithPreset(),a=0;a<r.length;a++){var s=r[a];if(s[i]&&s[i][t])return s[i][t]}},e.prototype.getPropertyInfoInEditorByType=function(e,t,o,i){if(e)for(var n=this.getLocalesWithPreset(),r=0;r<n.length;r++){var a=this.getPropertyInfoInEditorByTypeCore(e,t,o,i,n[r]);if(a)return a}},e.prototype.getPropertyInfoInEditorByTypeCore=function(e,t,o,i,n){var r=o[e];for(void 0===r&&(r=this.getObjInEditorByTypeCore(e,o,i,n));r;){var a=r.props[t];if(a&&"function"!=typeof a)return r.props[t];r=r.parent}},e.prototype.getObjInEditorByTypeCore=function(e,t,i,n){if(e){t[e];var r=n?n[i]:void 0;if(r){var a=e.indexOf("@");if(a>-1){var s=this.getObjInEditorByTypeCore(e.substring(0,a),t,i,n);if(!r[e])return t[e]=s,s;var l={props:r[e],parent:s};return t[e]=l,l}for(var u=[],p=o.Serializer.findClass(e),c=void 0;p;){var d=p.name;if(c=t[e])break;if(u.push(d),r[d]){c={props:r[d],parent:this.getObjInEditorByTypeCore(p.parentName,t,i,n)};break}if(!p.parentName)break;p=o.Serializer.findClass(p.parentName)}for(var h=0;h<u.length;h++)t[u[h]]=c;return c}}},e.prototype.getProperty=function(e,t){void 0===t&&(t=null);var o=this.getStringByPath(["p",e]);if(this.stringsDiff(o,e))return o;var i=(e+"").indexOf("_");return i<-1?this.getAutoPropertyName(o,t):(e=(e+"").substring(i+1),o=this.getStringByPath(["p",e]),this.stringsDiff(o,e)?o:this.getAutoPropertyName(o,t))},e.prototype.convertToCamelCase=function(e,t){if(void 0===t&&(t=!1),!e)return e;if((e=e.trim()).indexOf(" ")>-1)return e;for(var o=!1,i=0;i<e.length;i++)if(e[i]!==e[i].toUpperCase()){o=!0;break}if(!o)return e;var n=e[0].toUpperCase(),r=!1,a=function(t){return!(t>=e.length)&&e[t].toUpperCase()===e[t]};for(i=1;i<e.length;i++)!r&&a(i)&&(n+=" "),n+=r||a(i+1)?e[i]:e[i].toLowerCase(),r=a(i);return t&&(n=n.toLowerCase()),n},e.prototype.getAutoPropertyName=function(e,t){return void 0===t&&(t=null),t||(e&&this.camelCaseBreaking?this.convertToCamelCase(e):e)},e.prototype.getPropertyValueInEditor=function(e,t){var o=this.getLocale();if(o&&o.pv&&o.pv[e]){var i=o.pv[e][t];if(i)return i}return this.getPropertyValue(t)},e.prototype.getPropertyValue=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"pv",t)},e.prototype.getValidatorName=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"validators",t)},e.prototype.getTriggerName=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"triggers",t)},e.prototype.getLocale=function(e){e||(e=this.currentLocale);var t=e?this.locales[e]:this.getDefaultStrings();return t||(t=this.getDefaultStrings()),t},e.prototype.getPresetLocale=function(e){if(this.presetStrings){var t=e||this.currentLocale||this.defaultLocale;return this.presetStrings[t]}},e.prototype.getLocalesWithPreset=function(e){var t=[],o=this.getPresetLocale(e);o&&t.push(o);var i=this.getLocale(e);return i&&t.push(i),t},e.prototype.getValueInternal=function(e,t,o){return void 0===o&&(o=null),!e||e.indexOf&&e.indexOf(".")>-1?"":(e=e.toString(),this.getString(t+"."+e,o)||(this.camelCaseBreaking?this.convertToCamelCase(e,!1):e))},e.prototype.getLocales=function(){var e=[];for(var t in e.push(""),this.locales)e.push(t);return e},e.prototype.getDefaultStrings=function(){var e=this.defaultLocale;if(e&&"en"!==e){var t=this.getLocale(e);if(t)return t}return z},e.prototype.stringsDiff=function(e,t){return"function"!=typeof e&&"function"!=typeof t&&e!==t},e.prototype.getOldKeysString=function(e,t){void 0===t&&(t=null);var o=F[e];if(o){var i=o.split("."),n=this.getStringByPath(i,t);return n!==i[i.length-1]?n:void 0}},e}(),G=new U;function Z(e,t){return void 0===t&&(t=null),G.getString(e,t)}o.surveyLocalization.onGetExternalString=function(e,t){var o=G.getString(e,t);return o!==e?o:""};var z=t,J=function(e,t,o,i){var n,r=arguments.length,a=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,o):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,o,i);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(r<3?n(a):r>3?n(t,o,a):n(t,o))||a);return r>3&&a&&Object.defineProperty(t,o,a),a},W=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var n in t=arguments[o])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e};function K(e,t){for(var o in t)t.hasOwnProperty(o)&&(e[o]=t[o]);function i(){this.constructor=e}e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var Y,X=function(){function e(e){void 0===e&&(e=0),this.parseType=e}return e.prototype.parse=function(e,t,o,i){var n;return void 0===t&&(t=null),void 0===o&&(o=0),void 0===i&&(i=-1),this.text=String(e),this.at=o,this.endAt=i,this.ch=" ",n=this.value(),this.white(),this.ch&&this.error("Syntax error"),"function"==typeof t?function e(o,i){var n,r,a=o[i];if(a&&"object"==typeof a)for(n in a)Object.prototype.hasOwnProperty.call(a,n)&&(void 0!==(r=e(a,n))?a[n]=r:delete a[n]);return t.call(o,i,a)}({"":n},""):n},e.prototype.error=function(e){var t=new SyntaxError;throw t.message=e,t.at=this.at,t},e.prototype.next=function(e){return void 0===e&&(e=null),e&&e!==this.ch&&this.error("Expected '"+e+"' instead of '"+this.ch+"'"),this.ch=this.chartAt(),this.at+=1,this.ch},e.prototype.peek=function(){return this.chartAt()},e.prototype.chartAt=function(){return this.endAt>-1&&this.at>=this.endAt?"":this.text.charAt(this.at)},e.prototype.identifier=function(){var e=this.ch;for("_"!==this.ch&&"$"!==this.ch&&(this.ch<"a"||this.ch>"z")&&(this.ch<"A"||this.ch>"Z")&&this.error("Bad identifier");this.next()&&("_"===this.ch||"$"===this.ch||this.ch>="a"&&this.ch<="z"||this.ch>="A"&&this.ch<="Z"||this.ch>="0"&&this.ch<="9");)e+=this.ch;return e},e.prototype.number=function(){var e,t="",o="",i=10;if("-"!==this.ch&&"+"!==this.ch||(t=this.ch,this.next(this.ch)),"I"===this.ch)return("number"!=typeof(e=this.word())||isNaN(e))&&this.error("Unexpected word for number"),"-"===t?-e:e;if("N"===this.ch)return e=this.word(),isNaN(e)||this.error("expected word to be NaN"),e;switch("0"===this.ch&&(o+=this.ch,this.next(),"x"===this.ch||"X"===this.ch?(o+=this.ch,this.next(),i=16):this.ch>="0"&&this.ch<="9"&&this.error("Octal literal")),i){case 10:for(;this.ch>="0"&&this.ch<="9";)o+=this.ch,this.next();if("."===this.ch)for(o+=".";this.next()&&this.ch>="0"&&this.ch<="9";)o+=this.ch;if("e"===this.ch||"E"===this.ch)for(o+=this.ch,this.next(),"-"!==this.ch&&"+"!==this.ch||(o+=this.ch,this.next());this.ch>="0"&&this.ch<="9";)o+=this.ch,this.next();break;case 16:for(;this.ch>="0"&&this.ch<="9"||this.ch>="A"&&this.ch<="F"||this.ch>="a"&&this.ch<="f";)o+=this.ch,this.next()}if(e="-"===t?-o:+o,isFinite(e))return e;this.error("Bad number")},e.prototype.string=function(){var t,o,i,n,r="";if('"'===this.ch||"'"===this.ch)for(i=this.ch;this.next();){if(this.ch===i)return this.next(),r;if("\\"===this.ch)if(this.next(),"u"===this.ch){for(n=0,o=0;o<4&&(t=parseInt(this.next(),16),isFinite(t));o+=1)n=16*n+t;r+=String.fromCharCode(n)}else if("\r"===this.ch)"\n"===this.peek()&&this.next();else{if("string"!=typeof e.escapee[this.ch])break;r+=e.escapee[this.ch]}else{if("\n"===this.ch)break;r+=this.ch}}this.error("Bad string")},e.prototype.inlineComment=function(){"/"!==this.ch&&this.error("Not an inline comment");do{if(this.next(),"\n"===this.ch||"\r"===this.ch)return void this.next()}while(this.ch)},e.prototype.blockComment=function(){"*"!==this.ch&&this.error("Not a block comment");do{for(this.next();"*"===this.ch;)if(this.next("*"),"/"===this.ch)return void this.next("/")}while(this.ch);this.error("Unterminated block comment")},e.prototype.comment=function(){"/"!==this.ch&&this.error("Not a comment"),this.next("/"),"/"===this.ch?this.inlineComment():"*"===this.ch?this.blockComment():this.error("Unrecognized comment")},e.prototype.white=function(){for(;this.ch;)if("/"===this.ch)this.comment();else{if(!(e.ws.indexOf(this.ch)>=0))return;this.next()}},e.prototype.word=function(){switch(this.ch){case"t":return this.next("t"),this.next("r"),this.next("u"),this.next("e"),!0;case"f":return this.next("f"),this.next("a"),this.next("l"),this.next("s"),this.next("e"),!1;case"n":return this.next("n"),this.next("u"),this.next("l"),this.next("l"),null;case"I":return this.next("I"),this.next("n"),this.next("f"),this.next("i"),this.next("n"),this.next("i"),this.next("t"),this.next("y"),1/0;case"N":return this.next("N"),this.next("a"),this.next("N"),NaN}this.error("Unexpected '"+this.ch+"'")},e.prototype.array=function(){var e=[];if("["===this.ch)for(this.next("["),this.white();this.ch;){if("]"===this.ch)return this.next("]"),e;if(","===this.ch?this.error("Missing array element"):e.push(this.value()),this.white(),","!==this.ch)return this.next("]"),e;this.next(","),this.white()}this.error("Bad array")},e.prototype.object=function(){var t,o,i=!0,n={};if(this.parseType>0&&(n[e.positionName]={start:this.at-1}),"{"===this.ch)for(this.next("{"),this.white(),o=this.at-1;this.ch;){if("}"===this.ch)return this.parseType>0&&(n[e.positionName].end=o),this.next("}"),n;if(t='"'===this.ch||"'"===this.ch?this.string():this.identifier(),this.white(),this.parseType>1&&(n[e.positionName][t]={start:o,valueStart:this.at}),this.next(":"),n[t]=this.value(),this.parseType>1&&(o=this.at-1,n[e.positionName][t].valueEnd=o,n[e.positionName][t].end=o),this.white(),","!==this.ch)return this.parseType>1&&(n[e.positionName][t].valueEnd--,n[e.positionName][t].end--),this.parseType>0&&(n[e.positionName].end=this.at-1),this.next("}"),n;this.parseType>1&&(n[e.positionName][t].valueEnd--,i||n[e.positionName][t].end--),this.next(","),this.white(),i=!1}this.error("Bad object")},e.prototype.value=function(){switch(this.white(),this.ch){case"{":return this.object();case"[":return this.array();case'"':case"'":return this.string();case"-":case"+":case".":return this.number();default:return this.ch>="0"&&this.ch<="9"?this.number():this.word()}},e.prototype.stringify=function(e,t,o){if(void 0===t&&(t=null),void 0===o&&(o=null),t&&"function"!=typeof t&&!this.isArray(t))throw new Error("Replacer must be a function or an array");this.replacer=t,this.indentStr=this.getIndent(o),this.objStack=[];var i={"":e};return void 0===e?this.getReplacedValueOrUndefined(i,"",!0):this.internalStringify(i,"",!0)},e.prototype.getIndent=function(e){if(e){if("string"==typeof e)return e;if("number"==typeof e&&e>=0)return this.makeIndent(" ",e,!0)}return""},e.prototype.getReplacedValueOrUndefined=function(e,t,o){var i=e[t];return i&&i.toJSON&&"function"==typeof i.toJSON&&(i=i.toJSON()),"function"==typeof this.replacer?this.replacer.call(e,t,i):this.replacer?o||this.isArray(e)||this.replacer.indexOf(t)>=0?i:void 0:i},e.prototype.isWordChar=function(e){return e>="a"&&e<="z"||e>="A"&&e<="Z"||e>="0"&&e<="9"||"_"===e||"$"===e},e.prototype.isWordStart=function(e){return e>="a"&&e<="z"||e>="A"&&e<="Z"||"_"===e||"$"===e},e.prototype.isWord=function(e){if("string"!=typeof e)return!1;if(!this.isWordStart(e[0]))return!1;for(var t=1,o=e.length;t<o;){if(!this.isWordChar(e[t]))return!1;t++}return!0},e.prototype.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},e.prototype.isDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)},e.prototype.isNaN=function(e){return"number"==typeof e&&e!=e},e.prototype.checkForCircular=function(e){for(var t=0;t<this.objStack.length;t++)if(this.objStack[t]===e)throw new TypeError("Converting circular structure to JSON")},e.prototype.makeIndent=function(e,t,o){if(void 0===o&&(o=!1),!e)return"";e.length>10&&(e=e.substring(0,10));for(var i=o?"":"\n",n=0;n<t;n++)i+=e;return i},e.prototype.escapeString=function(t){return e.escapable.lastIndex=0,e.escapable.test(t)?'"'+t.replace(e.escapable,(function(t){var o=e.meta[t];return"string"==typeof o?o:"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)}))+'"':'"'+t+'"'},e.prototype.internalStringify=function(e,t,o){var i,n,r=this.getReplacedValueOrUndefined(e,t,o);switch(r&&!this.isDate(r)&&(r=r.valueOf()),typeof r){case"boolean":return r.toString();case"number":return isNaN(r)||!isFinite(r)?"null":r.toString();case"string":return this.escapeString(r.toString());case"object":if(null===r)return"null";if(this.isArray(r)){this.checkForCircular(r),i="[",this.objStack.push(r);for(var a=0;a<r.length;a++)n=this.internalStringify(r,a,!1),i+=this.makeIndent(this.indentStr,this.objStack.length),i+=null==n?"null":n,a<r.length-1?i+=",":this.indentStr&&(i+="\n");this.objStack.pop(),i+=this.makeIndent(this.indentStr,this.objStack.length,!0)+"]"}else{this.checkForCircular(r),i="{";var s=!1;for(var l in this.objStack.push(r),r)if(r.hasOwnProperty(l)){var u=this.internalStringify(r,l,!1);o=!1,null!=u&&(i+=this.makeIndent(this.indentStr,this.objStack.length),s=!0,i+=(this.isWord(l)?l:this.escapeString(l))+":"+(this.indentStr?" ":"")+u+",")}this.objStack.pop(),i=s?i.substring(0,i.length-1)+this.makeIndent(this.indentStr,this.objStack.length)+"}":"{}"}return i;default:return}},e.positionName="pos",e.escapee={"'":"'",'"':'"',"\\":"\\","/":"/","\n":"",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},e.ws=[" ","\t","\r","\n","\v","\f"," ","\ufeff"],e.cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,e.escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,e.meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},e}(),$=function(){function t(){}return Object.defineProperty(t,"convertInfo",{get:function(){return t.convertInfoValue||(t.convertInfoValue={},t.createDefaultQuestionConverterItems()),t.convertInfoValue},enumerable:!1,configurable:!0}),t.createDefaultQuestionConverterItems=function(){for(var e=o.Serializer.getChildrenClasses("selectbase",!0),i=0;i<e.length;i++)for(var n=0;n<e.length;n++)i!=n&&t.addConvertInfo(e[i].name,e[n].name);t.addConvertInfo("text","comment"),t.addConvertInfo("comment","text")},t.addConvertInfo=function(e,o){t.convertInfo[e]||(t.convertInfo[e]=[]),t.convertInfo[e].push(o)},t.getConvertableClasses=function(e){var o=t.convertInfo[e];return Array.isArray(o)&&o.indexOf(e)<0&&o.unshift(e),o},t.getConvertToClasses=function(n,r,a){void 0===r&&(r=null),void 0===a&&(a=!1);var s=i.questionConvertMode==e.AllTypes?function(e,t){void 0===t&&(t=!1);for(var i=o.Serializer.getChildrenClasses("question",!0),n=[],r=0;r<i.length;r++)(t||i[r].name!==e)&&n.push(i[r].name);(t||"panel"!==e)&&n.push("panel");var a=o.CustomWidgetCollection.Instance.widgets;for(r=0;r<a.length;r++)(t||a[r].name!==e)&&n.push(a[r].name);return n}(n,a):t.getConvertableClasses(n);if(!s)return[];if(Array.isArray(r)&&r.length>0){var l=[];s.forEach((function(e){return l.push(e)})),s=r.filter((function(e){return l.indexOf(e)>=0}))}return s||[]},t.getObjJSON=function(e,t){var i=e.toJSON();if(t)for(var n in t)i[n]&&o.Helpers.isTwoValueEquals(i[n],t[n])&&delete i[n];return i},t.convertObject=function(e,i,n,r,a){if(void 0===r&&(r=null),void 0===a&&(a=null),!e||!e.parent||i==e.getType()&&!r)return null;var s=r?void 0:o.QuestionFactory.Instance.createQuestion(i,e.name);s||(s=o.Serializer.createClass(i,{})),s.name=e.name;var l=r,u=l?o.Helpers.createCopy(l):s.toJSON(),p=n||{};for(var c in p)u[c]=p[c];if(a)for(var c in a)u[c]=a[c];t.updateJSON(u,i,e.getType()),s.fromJSON(u),t.removeValidators(s);var d=e.parent,h=d.elements.indexOf(e);d.isConverting=!0;var g=h+1<d.elements.length&&!1===d.elements[h+1].startWithNewLine;return d.removeElement(e),d.addElement(s,h),g&&(d.elements[h+1].startWithNewLine=!1),delete d.isConverting,s.onSurveyLoad(),s},t.updateJSON=function(e,o,i){t.updateJSONForRating(e,o),t.updateJSONForMatrices(e,o,i),t.updateJSONForPanels(e,o,i),t.updateJSONForBarrating(e,o)},t.updateJSONForMatrices=function(e,i,n){if(o.Serializer.isDescendantOf(i,"matrix")&&o.Serializer.isDescendantOf(n,"matrixdropdownbase")&&e.columns){var r=0;e.columns=e.columns.map((function(e){var t=e.name?e.name:"string"==typeof e?e:"col"+r++;return e.title?{value:t,text:e.title}:t}))}o.Serializer.isDescendantOf(i,"matrixdropdownbase")&&o.Serializer.isDescendantOf(n,"matrix")&&e.columns&&(e.columns=e.columns.map((function(e){return{name:t.getColumnName(e.name||e.value||e),title:e.text}})))},t.getColumnName=function(e){return o.Helpers.isNumber(e)?"col"+e:e},t.updateJSONForRating=function(e,t){"rating"===t&&e.choices&&(e.rateValues=e.choices),e.rateValues&&!o.Serializer.isDescendantOf(t,"matrixdropdownbase")&&(e.choices=e.rateValues)},t.updateJSONForBarrating=function(e,t){"barrating"===t&&(e.choices=[1,2,3,4,5])},t.updateJSONForPanels=function(e,t,i){o.Serializer.isDescendantOf(t,"paneldynamic")&&o.Serializer.isDescendantOf(i,"panel")&&e.elements&&(e.templateElements=e.elements,delete e.elements),o.Serializer.isDescendantOf(t,"panel")&&o.Serializer.isDescendantOf(i,"paneldynamic")&&e.templateElements&&(e.elements=e.templateElements,delete e.templateElements)},t.removeValidators=function(e){var t=e.validators;if(Array.isArray(t)&&0!==t.length)for(var o=e.getSupportedValidators(),i=t.length-1;i>=0;i--){var n=t[i].getType().replace("validator","");o.indexOf(n)<0&&t.splice(i,1)}},t}();!function(e){e.Unknown="unknown",e.Survey="survey",e.Page="page",e.Panel="panel",e.Question="question",e.Column="column"}(Y||(Y={}));var ee=function(){function e(){}return e.getNewElementName=function(e){var t=e.getSurvey();return t?e.isPage?this.getNewPageName(t.pages):e.isPanel?this.getNewPanelName(t.getAllPanels()):this.getNewQuestionName(t.getAllQuestions(!1,!1,!0)):e.name},e.getNewPageName=function(t){return e.getNewName(t,G.getString("ed.newPageName"))},e.isPageNameAutoGenerated=function(t){return e.isNameAutoGenerated(t,G.getString("ed.newPageName"))},e.isPagePropertiesAreModified=function(t){if(!e.isPageNameAutoGenerated(t.name))return!0;var o=t.toJSON();for(var i in delete o.name,delete o.elements,o)return!0;return!1},e.getNewQuestionName=function(t){return e.getNewName(t,G.getString("ed.newQuestionName"))},e.getNewPanelName=function(t){return e.getNewName(t,G.getString("ed.newPanelName"))},e.generateNewName=function(e){for(var t=e.length;t>0&&e[t-1]>="0"&&e[t-1]<="9";)t--;var o=e.substring(0,t),i=0;return t<e.length&&(i=parseInt(e.substring(t))),o+ ++i},e.getNewName=function(e,t){for(var o={},i=0;i<e.length;i++)o[e[i].name]=!0;for(var n=1;o[t+n.toString()];)n++;return t+n.toString()},e.isNameAutoGenerated=function(e,t){if(!e||e.length<t.length)return!1;var i=e.substring(t.length);return o.Helpers.isNumber(i)},e.getObjectType=function(e){return e&&e.getType?e.isPage?Y.Page:e.isPanel?Y.Panel:"survey"==e.getType()?Y.Survey:"matrixdropdowncolumn"==e.getType()?Y.Column:e.isQuestion?Y.Question:Y.Unknown:Y.Unknown},e.getObjectTypeStr=function(t){var o=e.getObjectType(t);return o===Y.Survey?"survey":o===Y.Page?"page":o===Y.Panel?"panel":o===Y.Question?"question":o===Y.Column?"column":"unknown"},e.getObjectName=function(t,o){return void 0===o&&(o=!1),e.getObjectType(t)===Y.Survey?G.getString("ed.surveyTypeName"):o&&t.title?t.title:o&&t.text?t.text:t.name?t.name:""},e.getElements=function(e,t){return void 0===t&&(t=!1),e?e.getElementsInDesign?e.getElementsInDesign(t):e.elements?e.elements:[]:[]},e.addElements=function(t,o,i){for(var n=0;n<t.length;n++)t[n].isPanel===o&&i.push(t[n]),e.addElements(e.getElements(t[n]),o,i)},e.getAllElements=function(t,o){for(var i=[],n=0;n<t.pages.length;n++)e.addElements(t.pages[n].elements,o,i);return i},e.isPropertyVisible=function(e,t,o,i,n,r){if(void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),void 0===r&&(r=null),!t||!t.visible)return!1;if(i&&t.showMode&&i!==t.showMode)return!1;if(t.isVisible&&e.getLayoutType&&!t.isVisible(e.getLayoutType(),null))return!1;var a=o?function(e,t){return o.onCanShowPropertyCallback(e,t,i,n,r)}:null;return!(a&&!a(e,t))},e.isNeedScrollIntoView=function(t,o){if(void 0===o&&(o=!1),t&&t.scrollIntoView){var i=t.getBoundingClientRect(),n=e.getScrollableDiv(t);if(n){var r=n.clientHeight;if(i.top<n.offsetTop)return"top";var a=r+n.offsetTop;return i.bottom>a&&(i.height<r||o)?"bottom":void 0}}},e.scrollIntoViewIfNeeded=function(t,o,i){void 0===i&&(i=!1);var n=e.isNeedScrollIntoView(t,i);if(n){var r="top"===n;t.scrollIntoView(o?o(r):r)}},e.getScrollableDiv=function(e){for(;e;){if(e.id&&e.id.indexOf("scrollableDiv")>-1)return e;if(!e.offsetParent)return null;e=e.offsetParent}return null},e.moveItemInArray=function(t,o,i){if(!t||t.length<2)return!1;if(i<0||i>=t.length)return!1;var n=t.indexOf(o);if(n<0||n==i)return!1;for(var r=0;r<t.length;r++)e.disableSelectingObj(t[r]);for(t.splice(n,1),t.splice(i,0,o),r=0;r<t.length;r++)e.enableSelectingObj(t[r]);return!0},e.applyItemValueArray=function(e,t){if(t&&0!=t.length){if(e.length>t.length&&e.splice(t.length,e.length-t.length),e.length<t.length){for(var o=[],i=e.length;i<t.length;i++)o.push(t[i]);e.splice.apply(e,[e.length,0].concat(o))}for(i=0;i<e.length;i++)e[i].value!=t[i].value&&(e[i].value=t[i].value),e[i].text=t[i].hasText?t[i].text:""}else e.splice(0,e.length)},e.disableSelectingObj=function(e){e.disableSelecting=!0},e.enableSelectingObj=function(e){delete e.disableSelecting},e.canSelectObj=function(e){return!e||!0!==e.disableSelecting},e.warnNonSupported=function(t,o){var i=E(t)+" is not supported in V2.";o&&(i+=" Use the '"+o+"' property instead"),e.warnText(i)},e.warnText=function(e){console.warn(e)},e.deleteConditionProperties=function(e){delete e.visible,delete e.visibleIf,delete e.readOnly,delete e.enableIf,delete e.valueName,delete e.choicesVisibleIf,delete e.choicesEnableIf,delete e.width,delete e.minWidth,delete e.maxWidth},e.deleteRandomProperties=function(e){["choicesOrder","rowsOrder"].forEach((function(t){"random"===e[t]&&delete e[t]}))},e.updateQuestionJson=function(t){t.storeOthersAsComment=!1,delete t.valuePropertyName,e.deleteConditionProperties(t),e.deleteRandomProperties(t),e.deleteConditionPropertiesFromArray(t.choices),e.deleteConditionPropertiesFromArray(t.rows),e.deleteConditionPropertiesFromArray(t.columns),e.deleteConditionPropertiesFromArray(t.rates)},e.deleteConditionPropertiesFromArray=function(t){Array.isArray(t)&&t.forEach((function(t){e.deleteConditionProperties(t)}))},e.convertMatrixRowsToText=function(e){return e.filter((function(e){return!e.cells[0].hasError})).map((function(e){return e.cells.map((function(e){return e.value||""})).join(o.ItemValue.Separator).replace(/\|$/,"")})).join("\n")},e.convertItemValuesToText=function(e){var t="";return e.forEach((function(e){t&&(t+="\n"),t+=e.value,e.pureText&&(t+=o.ItemValue.Separator+e.pureText)})),t},e.convertTextToItemValues=function(e,t,i){var n=[];if(!e)return n;for(var r=e.split("\n"),a=0;a<r.length;a++)if(r[a]){var s=r[a].split(o.ItemValue.Separator),l=o.Serializer.createClass(i);t.forEach((function(e,t){l[e.name]=s[t]})),n.push(l)}return n},e.sortItems=function(e,t){void 0===t&&(t="text");var o=function(e,t){for(var o="";t<e.length&&e[t]>="0"&&e[t]<="9";)o+=e[t],t++;return parseFloat(o)};e.sort((function(e,i){for(var n=e[t]?e[t]:"",r=i[t]?i[t]:"",a=0;a<n.length&&a<r.length&&n[a]===r[a];)a++;if(a<n.length&&a<r.length){for(;a>0&&n[a-1]>="0"&&n[a-1]<="9";)a--;var s=o(n,a),l=o(r,a);if(s<l)return-1;if(s>l)return 1}return n.localeCompare(r)}))},e.getQuestionContextIndexInfo=function(e,t){void 0===t&&(t="");for(var o=["row","panel"],i=0;i<o.length;i++){var n=t+o[i]+".",r=e.indexOf(n);if(r>-1)return{index:r,name:n}}},e.isSupportCellEditor=function(e){for(var t=["selectbase","boolean","rating"],i=0;i<t.length;i++)if(o.Serializer.isDescendantOf(e,t[i]))return!0;return!1},e.getElementDeepLength=function(e){for(var t=0;e;)e.isPanel&&t++,e=e.parent;return t},e}(),te=function(e){function t(t){var o=e.call(this)||this;return o.setDesignMode(!0),o.fromJSON(t),o}return K(t,e),t}(o.SurveyModel),oe=function(){function e(){}return e.prototype.getCorrectAt=function(e,t,o){return t},Object.defineProperty(e.prototype,"isFixable",{get:function(){return!1},enumerable:!1,configurable:!0}),e.prototype.fixError=function(e,t,o){return e},e}(),ie=function(){function e(e,t){this.at=e,this.text=t,this.rowAt=-1,this.columnAt=-1}return Object.defineProperty(e.prototype,"isFixable",{get:function(){return this.fixer.isFixable},enumerable:!1,configurable:!0}),e.prototype.fixError=function(e){return e},Object.defineProperty(e.prototype,"fixer",{get:function(){return this.fixerValue||(this.fixerValue=this.createFixer()),this.fixerValue},enumerable:!1,configurable:!0}),e.prototype.createFixer=function(){return new oe},e}(),ne=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getErrorType=function(){return"parseerror"},t}(ie),re=function(e){function t(t,o){var i=e.call(this)||this;return i.element=t,i.jsonObj=o,i}return K(t,e),t.prototype.getNewIndex=function(e,t,o,i){var n=e.indexOf(t,o);return n>-1&&(i<0||n<i)?n:-1},t.prototype.fixError=function(e,t,o){var i=e.substring(t,o+1),n=JSON.parse(i);return this.updatedJsonObjOnFix(n),this.replaceJson(e,t,o,n)},t.prototype.updatedJsonObjOnFix=function(e){},t.prototype.replaceJson=function(e,t,o,n){var r=JSON.stringify(n,null,i.jsonEditor.indentation);return r=this.addLeftIndentIntoContent(e,r,t-1),e.substring(0,t)+r+e.substring(o+1)},t.prototype.addLeftIndentIntoContent=function(e,t,o){if(o<=0)return t;for(var i="";o>0&&(" "===e[o]||"\t"===e[o]);)i+=e[o],o--;if(!i)return t;for(var n=t.split("\n"),r=1;r<n.length;r++)n[r]=i+n[r];return n.join("\n")},t}(oe),ae=function(e){function t(t,o,i){var n=e.call(this,t,o)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),t.prototype.getCorrectAt=function(e,t,o){return this.propertyName?this.getNewIndex(e,this.propertyName,t,o):t},t}(re),se=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.updatedJsonObjOnFix=function(e){var t=e[this.propertyName];t&&!Array.isArray(t)&&(e[this.propertyName]=[t])},t}(ae),le=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getCorrectAt=function(e,t,o){var i=this.getNewIndex(e,"name:",t,o);return i>t?i:this.getNewIndex(e,'"name":',t,o)},t.prototype.updatedJsonObjOnFix=function(e){e.name=ee.getNewElementName(this.element)},t}(re),ue=function(e){function t(t,o,i){var n=e.call(this,t,o)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return"name"===this.propertyName},enumerable:!1,configurable:!0}),t.prototype.updatedJsonObjOnFix=function(e){var t=this.element.name;t||(t=ee.getNewElementName(this.element)),e.name=t},t}(re),pe=function(e){function t(t){var o=e.call(this,t.at,t.getFullDescription())||this;return o.elementStart=t.at,o.elementEnd=t.end,o.element=t.element,o.errorType=t.type,o.propertyName=t.propertyName,o.jsonObj=t.jsonObj,o}return K(t,e),t.prototype.createFixer=function(){return"unknownproperty"===this.errorType?new ae(this.element,this.jsonObj,this.propertyName):"arrayproperty"===this.errorType?new se(this.element,this.jsonObj,this.propertyName):"duplicatename"===this.errorType?new le(this.element,this.jsonObj):"requiredproperty"===this.errorType?new ue(this.element,this.jsonObj,this.propertyName):e.prototype.createFixer.call(this)},t.prototype.getErrorType=function(){return this.errorType},Object.defineProperty(t.prototype,"isFixable",{get:function(){return this.fixer.isFixable&&this.elementStart>-1&&this.elementEnd>this.elementStart},enumerable:!1,configurable:!0}),t.prototype.correctAt=function(e){var t=this.fixer.getCorrectAt(e,this.at,this.elementEnd);t>-1&&(this.at=t)},t.prototype.fixError=function(e){return this.fixer.fixError(e,this.elementStart,this.elementEnd)},t}(ie),ce=function(){function e(e){this.text=e,this.text&&""!=this.text.trim()||(this.text="{}"),this.errors=[],this.process()}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isJsonCorrect",{get:function(){return!!this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isJsonHasErrors",{get:function(){return this.errors.length>0||!this.isJsonCorrect},enumerable:!1,configurable:!0}),e.prototype.process=function(){var e=this;try{this.jsonValue=new X(1).parse(this.text)}catch(i){this.errors.push(new ne(i.at,i.message))}if(null!=this.jsonValue){this.updateJsonPositions(this.jsonValue),this.surveyValue=new te(this.jsonValue);var t=this.surveyValue.jsonErrors;if(Array.isArray(t))for(var o=0;o<t.length;o++){var i=new pe(t[o]);i.correctAt(this.text),this.errors.push(i)}this.getDuplicatedNamesErrors().forEach((function(t){return e.errors.push(t)}))}this.setErrorsPositionByChartAt()},e.prototype.updateJsonPositions=function(e){for(var t in e.pos.self=e,e){var o=e[t];o&&o.pos&&(e.pos[t]=o.pos,this.updateJsonPositions(o))}},e.prototype.setErrorsPositionByChartAt=function(){if(0!==this.errors.length){this.errors.sort((function(e,t){return e.at>t.at?1:e.at<t.at?-1:0}));for(var e={row:0,column:0},t=0,o=0;o<this.errors.length;o++){var i=this.errors[o].at;e=this.getPostionByChartAt(e,t,i);var n=this.errors[o];i==n.at&&(n.columnAt=e.column,n.rowAt=e.row),t=i}}},e.prototype.getPostionByChartAt=function(t,o,i){for(var n={row:t.row,column:t.column},r=o;r<i;)this.text.charAt(r)==e.newLineChar?(n.row++,n.column=0):n.column++,r++;return n},e.prototype.getDuplicatedNamesErrors=function(){var e=this,t=[];return this.getDuplicatedElements().forEach((function(o){var i=new pe(e.createDuplicatedError(o));i.correctAt(e.text),i&&t.push(i)})),t},e.prototype.getDuplicatedElements=function(){var e=this,t=[],o={};return this.survey.pages.forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),ee.getAllElements(this.survey,!0).forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),ee.getAllElements(this.survey,!1).forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),t},e.prototype.checkDuplicatedElement=function(e,t,o){var i=e.name;t[i]?o.push(e):t[i]=!0},e.prototype.createDuplicatedError=function(e){var t=e.pos;if(t){var i=new o.JsonError("duplicatename","The name: '"+e.name+"' is duplicated.");return i.at=t.start,i.end=t.end,i.element=e,i}},e.newLineChar="\n",e}(),de=function(e){function t(t){var o=e.call(this,"duplicatename","The name: '"+t.name+"' is duplicated.")||this;return o.element=t,o}return K(t,e),t}(o.JsonError),he=function(e){function t(){var t=e.call(this)||this;return t.searchActionBar=new o.ActionContainer,t.initActionBar(),t}return K(t,e),t.prototype.getSearchActions=function(){var e=this;return[new o.Action({id:"svd-grid-search-close",iconName:"icon-clear_16x16",component:"sv-action-bar-item",title:Z("ed.clear"),showTitle:!1,iconSize:16,disableTabStop:!0,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return!!e.filterString})),action:function(){e.clearFilterString()}})]},t.prototype.initActionBar=function(){this.searchActionBar.setItems(this.getSearchActions())},t.prototype.clearFilterString=function(){this.filterString=""},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"filterString"===t&&this.setFiterString(i,o)},t.prototype.dispose=function(){this.searchActionBar.dispose(),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"filterString",void 0),J([(0,o.property)()],t.prototype,"isVisible",void 0),J([(0,o.property)()],t.prototype,"matchCounterText",void 0),t}(o.Base),ge=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.filterStringPlaceholder=Z("ed.toolboxFilteredTextPlaceholder"),t}return K(t,e),t.prototype.setFiterString=function(e,t){!!t!=!!e&&this.toolbox.lockScrollBar(!!e),this.toolbox.items.forEach((function(t){return t.visible=t.hasText(e)})),this.toolbox.showPlaceholder=!this.toolbox.items.filter((function(e){return e.visible})).length,this.toolbox.categories.forEach((function(t){t.forceExpand=!!e,t.empty=0==t.items.filter((function(e){return e.visible})).length}))},t.prototype.clearFilterString=function(){this.filterString="",this.toolbox.containerElement.querySelector("input").focus()},J([(0,o.property)()],t.prototype,"toolbox",void 0),t}(he),me=function(e){function t(){var t=e.call(this)||this;return t.highlightedEditorClass=" spg-editor--highlighted",t.filterStringPlaceholder=Z("ed.propertyGridFilteredTextPlaceholder"),t.propertyGridNoResultsFound=Z("ed.propertyGridNoResultsFound"),t.initActionBar(),t}return K(t,e),t.prototype.expandAllParents=function(e){e&&(e.page&&e.survey&&(e.survey.currentPage=e.page),e.isCollapsed&&e.expand(!1),this.expandAllParents(e.parent),this.expandAllParents(e.parentQuestion))},t.prototype.switchHighlightedEditor=function(e){var t=this;this.currentMatchIndex=e;var o=this.currentMatch;this.currentMatch=this.allMatches[e],null==o||o.updateElementCss(),this.currentMatch&&o!==this.currentMatch&&(this.currentMatch.updateElementCss(),this.expandAllParents(this.currentMatch),setTimeout((function(){L(t.currentMatch.id)}),10)),this.updatedMatchCounterText(e)},t.prototype.updatedMatchCounterText=function(e){var t=this.allMatches.length;if(1===t)this.matchCounterText="";else if(this.currentMatch){var o=e+1;this.matchCounterText=[o,t].join("/")}else this.matchCounterText=this.filterString?this.propertyGridNoResultsFound:""},t.prototype.navigateToEditor=function(e){e<0&&(e=this.allMatches.length-1),e>=this.allMatches.length&&(e=0),this.switchHighlightedEditor(e)},t.prototype.getAllMatches=function(e){var t=o.settings.comparator.normalizeTextCallback,i=t(e,"search");return i=i.toLocaleLowerCase().trim(),this.survey.getAllQuestions().filter((function(e){return e.isVisible})).filter((function(e){var o=e.name+"|"+e.title+"|"+e.description;return o&&(o=(o=t(o,"search")).toLocaleLowerCase().trim()),-1!==o.indexOf(i)}))},t.prototype.setFiterString=function(e,t){if(e)if(this.allMatches=this.getAllMatches(e),0!==this.allMatches.length){var o=this.allMatches.indexOf(this.currentMatch);this.switchHighlightedEditor(-1===o?0:o)}else this.reset();else this.reset()},t.prototype.reset=function(){this.allMatches=[],this.currentMatchIndex=-1;var e=this.currentMatch;this.currentMatch=void 0,null==e||e.updateElementCss(),this.updatedMatchCounterText(-1)},t.prototype.getSearchActions=function(){var t=this,i=e.prototype.getSearchActions.call(this);return i.unshift(new o.Action({id:"svd-grid-search-next",iconName:"icon-next_16x16",component:"sv-action-bar-item",title:Z("ed.nextFocus"),showTitle:!1,iconSize:16,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return t.allMatches.length>1})),action:function(){t.allMatches.length>0&&t.navigateToEditor(t.currentMatchIndex+1)}})),i.unshift(new o.Action({id:"svd-grid-search-prev",iconName:"icon-previous_16x16",component:"sv-action-bar-item",title:Z("ed.prevFocus"),showTitle:!1,iconSize:16,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return t.allMatches.length>1})),action:function(){t.allMatches.length>0&&t.navigateToEditor(t.currentMatchIndex-1)}})),i},t.prototype.setSurvey=function(e){if(this.clearFilterString(),this.survey=e,this.survey){var t=this;this.survey.onUpdateQuestionCssClasses.add((function(e,o){var i=o.cssClasses;o.question===t.currentMatch&&(i.mainRoot+=t.highlightedEditorClass)}))}},J([(0,o.property)()],t.prototype,"survey",void 0),J([(0,o.property)()],t.prototype,"isVisible",void 0),J([(0,o.property)({defaultValue:[]})],t.prototype,"allMatches",void 0),t}(he),fe=function(e){function t(t){var o=e.call(this)||this;return o.toolbox=t,o}return K(t,e),Object.defineProperty(t.prototype,"collapsed",{get:function(){return!this.forceExpand&&this.collapsedValue},set:function(e){this.collapsedValue=e},enumerable:!1,configurable:!0}),t.prototype.toggleState=function(){this.toolbox&&this.toolbox.toggleCategoryState(this.name)},J([(0,o.property)()],t.prototype,"name",void 0),J([(0,o.property)()],t.prototype,"title",void 0),J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"collapsedValue",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"forceExpand",void 0),J([(0,o.property)()],t.prototype,"empty",void 0),t}(o.Base),ye=function(e){function t(t){var i=e.call(this,t)||this;i.item=t,i.id||(i.id=i.name);var n=i.css;return i.css=new o.ComputedUpdater((function(){var e;return(new o.CssClassBuilder).append("svc-toolbox__tool").append("svc-toolbox__tool--action").append(n).append("svc-toolbox__tool--pressed",i.isPressed).append("svc-toolbox__tool--has-icon",!!i.iconName).append("svc-toolbox__tool--has-subitems",!!((null===(e=i.items)||void 0===e?void 0:e.length)>0)).append("svc-toolbox__tool--disabled",!1===i.enabled).append("sv-action--hidden",!i.isVisible).toString()})),i}return K(t,e),t.getItemClassNames=function(e){return(new o.CssClassBuilder).append("svc-toolbox__item").append("svc-toolbox__item--has-icon",!!e).append("svc-toolbox__item--"+e,!!e).toString()},Object.defineProperty(t.prototype,"title",{get:function(){return this.getTitle()},set:function(e){this.setTitle(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enabled",{get:function(){return this.getEnabled()},set:function(e){this.setEnabled(e)},enumerable:!1,configurable:!0}),t.prototype.toJSON=function(){return this.item},Object.defineProperty(t.prototype,"typeName",{get:function(){return this.json&&this.json.type?this.json.type:this.name},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPanel",{get:function(){var e=this.typeName;return!!e&&o.Serializer.isDescendantOf(e,"panelbase")},enumerable:!1,configurable:!0}),t.prototype.getArea=function(e){return e.closest("#scrollableDiv-designer")},t.prototype.hasText=function(e){if(e){var t=e.toLowerCase();return this.title.toLowerCase().indexOf(t)>=0||this.name.toLowerCase().indexOf(t)>=0}},t.prototype.getSubitemByName=function(e){var t;return null===(t=this.items)||void 0===t?void 0:t.filter((function(t){return t.id===e}))[0]},t.prototype.addSubitems=function(e){!e||e.length<1||(this.setSubItems({items:e}),this.component=ve.defaultItemGroupComponent)},t.prototype.clearSubitems=function(){this.hasSubItems&&(this.items=[],this.component="",this.popupModel.dispose())},t.prototype.addSubitem=function(e,i){if(void 0===i&&(i=-1),e){var n=new t(e);n.iconName="",n.className||(n.className=t.getItemClassNames(n.iconName)),n.className=(new o.CssClassBuilder).append(n.className).append("svc-toolbox__item-subtype").toString();var r=(this.items||[]).slice();-1===i?r.push(n):r.splice(i,0,n),this.addSubitems(r)}},t.prototype.removeSubitem=function(e){if(this.hasSubItems&&e){var t=(null==e?void 0:e.id)||e;if(t){var o=this.getSubitemByName(t),i=(this.items||[]).slice(),n=i.indexOf(o);n>-1&&i.splice(n,1),0==i.length?this.clearSubitems():this.addSubitems(i)}}},Object.defineProperty(t.prototype,"subitemsButtonIcon",{get:function(){return"icon-next_16x16"},enumerable:!1,configurable:!0}),t}(o.Action),ve=function(e){function t(t,i,n){void 0===t&&(t=null),void 0===i&&(i=null),void 0===n&&(n=!1);var r=e.call(this)||this;return r.supportedQuestions=t,r.creator=i,r._orderedQuestions=["radiogroup","rating","checkbox","dropdown","tagbox","boolean","file","imagepicker","ranking","text","comment","multipletext","panel","paneldynamic","matrix","matrixdropdown","matrixdynamic","html","expression","image","signaturepad"],r.copiedItemMaxCount=3,r.allowExpandMultipleCategoriesValue=!1,r.keepAllCategoriesExpandedValue=!1,r.toolboxNoResultsFound=Z("ed.toolboxNoResultsFound"),r.categoriesTitles={},r.searchManager=new ge,r.searchManager.isVisible=r.searchEnabled,r.searchManager.toolbox=r,r.searchItem=new o.Action({id:"searchItem-id",css:"svc-toolbox__tool svc-toolbox__search-button",innerCss:"sv-dots__item",iconName:"icon-search",component:"sv-action-bar-item",tooltip:o.surveyLocalization.getString("search"),action:function(){document.querySelector(".svc-toolbox__panel input").focus(),r.isFocused=!0}}),r.updateResponsiveness(r.isCompact,r.overflowBehavior),r.createDefaultItems(t,n),r.initDotsItem(),r}return K(t,e),Object.defineProperty(t.prototype,"itemSelector",{get:function(){return".svc-toolbox__category>.svc-toolbox__tool--action"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerSelector",{get:function(){return".svc-toolbox__scroller"},enumerable:!1,configurable:!0}),t.getQuestionDefaultSettings=function(e){if(i.toolbox&&i.toolbox.defaultJSON)return i.toolbox.defaultJSON[e]},t.getSubTypePropertyName=function(e){var t="";return"text"===e&&(t="inputType"),"rating"===e&&(t="rateType"),t},Object.defineProperty(t.prototype,"orderedQuestions",{get:function(){return this._orderedQuestions},set:function(e){this._orderedQuestions=e,this.reorderItems()},enumerable:!1,configurable:!0}),t.prototype.updateResponsiveness=function(e,t){if("scroll"==t&&this.creator&&!this.creator.isTouch||this.creator&&"sidebar"===this.creator.toolboxLocation)return this.isResponsivenessDisabled=!0,void(this.updateCallback&&this.updateCallback(!0));this.hasCategories&&this.showCategoryTitles?e?(this.isResponsivenessDisabled=!1,this.raiseUpdate(!0)):(this.isResponsivenessDisabled=!0,this.setActionsMode("large")):(this.isResponsivenessDisabled=!1,this.raiseUpdate(!0))},t.prototype.lockScrollBar=function(e){this._containerElementValue&&(this.isScrollLocked=e&&this._containerElementValue.scrollHeight>this._containerElementValue.clientHeight)},t.prototype.initDotsItem=function(){var e=this,t=this.dotsItem.css;this.dotsItem.css=new o.ComputedUpdater((function(){return(new o.CssClassBuilder).append("svc-toolbox__tool").append(t).append("sv-action--hidden",!e.dotsItem.isVisible).toString()})),this.dotsItem.popupModel.horizontalPosition="right",this.dotsItem.popupModel.verticalPosition="top",this.dragOrClickHelper=new o.DragOrClickHelper((function(t,o,i){var n,r=e.creator.getJSONForNewElement(i.json);e.dotsItem.popupModel.hide(),null===(n=e.creator)||void 0===n||n.onDragDropItemStart(),e.dragDropHelper.startDragToolboxItem(t,r,i)})),this.hiddenItemsListModel.onPointerDown=function(t,o){e.creator.readOnly||e.dragOrClickHelper.onPointerDown(t,o)},this.dotsItem.popupModel.cssClass="svc-toolbox-popup"},t.prototype.getDefaultQuestionCategories=function(){var e=this,o={};return Object.keys(t.defaultCategories).forEach((function(i){t.defaultCategories[i].forEach((function(t){e.supportedQuestions&&-1==e.supportedQuestions.indexOf(t)||(o[t]=i)}))})),o},t.prototype.getCategoryTitle=function(e){return this.categoriesTitles[e]?this.categoriesTitles[e]:Z("toolboxCategories."+e)},t.prototype.onActiveCategoryChanged=function(e){for(var t=this.categories,o=0;o<t.length;o++){var i=t[o];i.collapsed=i.name!==e}},Object.defineProperty(t.prototype,"isCompactRendered",{get:function(){return this.isCompact&&!this.isFocused},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSearch",{get:function(){return this.searchEnabled&&this.items.length>t.MINELEMENTCOUNT},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showInSingleCategory",{get:function(){return this.isCompactRendered||1==this.categories.length||!this.showCategoryTitles},enumerable:!1,configurable:!0}),t.prototype.setRootElement=function(e){this._containerElementValue=null==e?void 0:e.querySelector(this.containerSelector)},Object.defineProperty(t.prototype,"containerElement",{get:function(){return this._containerElementValue},enumerable:!1,configurable:!0}),t.prototype.focusOut=function(e){e.relatedTarget===e.currentTarget||e.currentTarget.contains(e.relatedTarget)||(this.isFocused=!1,this.searchManager.filterString="")},Object.defineProperty(t.prototype,"classNames",{get:function(){return(new o.CssClassBuilder).append("svc-toolbox").append("svc-toolbox--searchable",this.searchEnabled).append("svc-toolbox--filtering",!!this.searchManager.filterString).append("svc-toolbox--compact",this.isCompactRendered).append("svc-toolbox--scroll-locked",this.isScrollLocked).append("svc-toolbox--flyout",this.isCompact&&this.isFocused).append("svc-toolbox--scrollable","scroll"==this.overflowBehavior).toString()},enumerable:!1,configurable:!0}),t.prototype.setLocation=function(e){"sidebar"===e?this.visibleActions.forEach((function(e){return e.mode="small"})):this.dotsItem.popupModel.horizontalPosition="right"==this.creator.toolboxLocation?"left":"right",this.updateResponsiveness(this.isCompact,this.overflowBehavior)},Object.defineProperty(t.prototype,"jsonText",{get:function(){return JSON.stringify(this.actions)},set:function(e){this.actions=(e?JSON.parse(e):[]).map((function(e){return new ye(e)})),this.onItemsChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copiedJsonText",{get:function(){return JSON.stringify(this.copiedItems)},set:function(e){var t=e?JSON.parse(e):[];this.clearCopiedItems();for(var o=0;o<t.length;o++)t[o].isCopied=!0,this.addItem(t[o])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"items",{get:function(){return this.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemNames",{get:function(){for(var e=[],t=0;t<this.items.length;t++)e.push(this.items[t].typeName);return e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copiedItems",{get:function(){for(var e=[],t=0;t<this.actions.length;t++)this.actions[t].isCopied&&e.push(this.actions[t]);return e},enumerable:!1,configurable:!0}),t.prototype.addItems=function(e,t){void 0===t&&(t=!1),t&&this.clearItems();for(var o=0;o<e.length;o++)this.actions.push(this.getOrCreateToolboxItem(e[o]));this.onItemsChanged()},t.prototype.addCopiedItem=function(e,o){void 0===o&&(o=null),o||(o={});var i=o.name?o.name:e.name,n=o.title?o.title:i,r=o.tooltip?o.tooltip:n,a=o.iconName?o.iconName:t.defaultIconName,s={id:i,name:i,title:n,tooltip:r,className:ye.getItemClassNames(a),isCopied:!1!==o.isCopied,iconName:a,json:o.json?o.json:this.getQuestionJSON(e),category:o.category?o.category:""};if(!this.replaceItem(s)){var l=this.copiedItems;this.copiedItemMaxCount>0&&l.length==this.copiedItemMaxCount&&this.removeItem(l[this.copiedItemMaxCount-1].name),this.addItem(s)}},t.prototype.getOrCreateToolboxItem=function(e){if(e instanceof ye)return e;e.iconName=e.iconName?e.iconName:t.defaultIconName;var o=new ye(e),i=this.createSubTypes(o);return i&&o.addSubitems(i),o},t.prototype.createSubTypes=function(e){var i=null,n=t.getSubTypePropertyName(e.id);if(n&&(i=o.Serializer.findProperty(e.id,n)),i&&i.visible)return i.choices.map((function(o){var i=W({},e.json);i[n]=o;var r=e.id!=o?o:e.id+"-default";return new ye({id:r,name:r,title:G.getPropertyValueInEditor(n,o),className:ye.getItemClassNames()+" svc-toolbox__item-subtype",json:i,iconName:null,category:null,isCopied:!1,component:t.defaultItemComponent})}))},t.prototype.addItem=function(e,t){this.correctItem(e);var o=this.getOrCreateToolboxItem(e);void 0===t?this.actions.push(o):this.actions.splice(t,0,o),this.onItemsChanged()},t.prototype.correctItem=function(e){e.title||(e.title=e.name),e.tooltip||(e.tooltip=e.title)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t.prototype.replaceItem=function(e){this.correctItem(e);var t=this.indexOf(e.name);if(!(t<0))return this.actions[t]=this.getOrCreateToolboxItem(e),this.onItemsChanged(),!0},t.prototype.removeItem=function(e){var t=this.indexOf(e);return!(t<0||(this.actions.splice(t,1),this.onItemsChanged(),0))},t.prototype.clearItems=function(){this.actions=[],this.onItemsChanged()},t.prototype.clearCopiedItems=function(){for(var e=this.copiedItems,t=0;t<e.length;t++)this.removeItem(e[t].name)},t.prototype.getItemByName=function(e){if(!e)return null;var t=this.indexOf(e);return t>-1?this.actions[t]:null},Object.defineProperty(t.prototype,"allowExpandMultipleCategories",{get:function(){return this.allowExpandMultipleCategoriesValue},set:function(e){this.allowExpandMultipleCategoriesValue=e,this.updateCategoriesState()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keepAllCategoriesExpanded",{get:function(){return this.keepAllCategoriesExpandedValue||!this.showCategoryTitlesValue},set:function(e){this.keepAllCategoriesExpandedValue=e,this.canCollapseCategories=!this.keepAllCategoriesExpanded,this.updateCategoriesState()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showCategoryTitles",{get:function(){return this.showCategoryTitlesValue},set:function(e){this.showCategoryTitlesValue=e,this.updateCategoriesState()},enumerable:!1,configurable:!0}),t.prototype.updateTitles=function(){var e=this;this.actions.forEach((function(t){e.updateActionTitle(t),e.updateActionTitle(t.innerItem)})),Array.isArray(this.categories)&&this.categories.forEach((function(t){t.title=e.getCategoryTitle(t.name)}))},t.prototype.updateActionTitle=function(e){var t=G.getString("qt."+e.id);t&&t!==e.id&&(e.title=t,e.tooltip=t)},t.prototype.updateCategoriesState=function(){this.allowExpandMultipleCategories||this.keepAllCategoriesExpanded?(this.activeCategory="",this.keepAllCategoriesExpandedValue&&this.expandAllCategories()):this.categories.length>0&&(this.activeCategory=this.categories[0].name)},t.prototype.changeCategory=function(e,t){this.changeCategories([{name:e,category:t}])},t.prototype.changeCategories=function(e){for(var t=0;t<e.length;t++){var o=e[t],i=this.getItemByName(o.name);i&&(i.category=o.category)}this.onItemsChanged()},t.prototype.defineCategories=function(e,t){var o=this;if(void 0===t&&(t=!1),Array.isArray(e)){var i=this.getDefaultItems(this.supportedQuestions,!1,!0,!0),n={};i.forEach((function(e){e.visible=!1,n[e.id]=e})),Array.isArray(this.presetDefaultItems)&&this.presetDefaultItems.forEach((function(e){var t=n[e.name];if(t)for(var o in e)t[o]=e[o];else if(e.json){var r=new ye(e);n[r.id]=r,i.push(r)}})),this.categoriesTitles={};var r=new Array;e.forEach((function(e){e.category&&e.title&&(o.categoriesTitles[e.category]=e.title),Array.isArray(e.items)&&e.items.forEach((function(t){var o=void 0,i=void 0;"string"==typeof t?o=t:(o=t.name,i=t.title);var a=n[o];a&&(a.category=e.category,a.visible=!0,i&&(a.title=i),r.push(a))}))})),t&&i.forEach((function(e){e.visible||(e.visible=!0,e.category="misc",r.push(e))})),this.setItems(r),this.onItemsChanged(!1)}},t.prototype.removeCategories=function(){var e=o.ElementFactory.Instance.getAllToolboxTypes();this.changeCategories(e.map((function(e){return{name:e,category:null}}))),this.onItemsChanged()},t.prototype.toggleCategoryState=function(e){if(!this.keepAllCategoriesExpanded)if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!t.collapsed)}else this.activeCategory=e},t.prototype.expandCategory=function(e){if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!1)}else this.canCollapseCategories&&(this.activeCategory=e)},t.prototype.collapseCategory=function(e){if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!0)}},t.prototype.expandAllCategories=function(){this.expandCollapseAllCategories(!1)},t.prototype.collapseAllCategories=function(){this.expandCollapseAllCategories(!0)},t.prototype.expandCollapseAllCategories=function(e){for(var t=this.categories,o=0;o<t.length;o++)t[o].collapsed=e},t.prototype.getCategoryByName=function(e){for(var t=this.categories,o=0;o<t.length;o++){var i=t[o];if(i.name===e)return i}return null},t.prototype.onItemsChanged=function(e){var t=this;void 0===e&&(e=!0);for(var o=new Array,i={},n=this.activeCategory,r=function(e){var r=a.actions[e];if(r.innerItem.action=function(){t.creator.clickToolboxItem(r.json)},!1===r.visible)return"continue";var s=r.category?r.category:"general";if(!i[s]){var l=a.createCategory();l.name=s,l.title=a.getCategoryTitle(s),l.collapsed=s!==n&&!a.keepAllCategoriesExpanded,i[s]=l,o.push(l)}i[s].items.push(r)},a=this,s=0;s<this.actions.length;s++)r(s);if(this.categories=o,this.keepAllCategoriesExpanded||(this.allowExpandMultipleCategories?o.length>0&&(o[0].collapsed=!1):n&&i[n]?this.activeCategory=n:this.activeCategory=o.length>0?o[0].name:""),e){var l=[];this.categories.forEach((function(e){l=l.concat(e.items)})),this.actions=l}this.hasCategories=o.length>1,this.updateItemSeparators(),this.updateResponsiveness(this.isCompact,this.overflowBehavior)},t.prototype.createCategory=function(){return new fe(this)},t.prototype.indexOf=function(e){for(var t=0;t<this.actions.length;t++)if(this.actions[t].name==e)return t;return-1},t.prototype.updateItemSeparators=function(){(this.hasCategories?this.categories:[{items:this.actions}]).forEach((function(e,t){(e.items||[]).forEach((function(e,o){e.needSeparator=0!==t&&0==o,e.innerItem&&(e.innerItem.needSeparator=e.needSeparator)}))}))},t.prototype.reorderItems=function(){var e=this;this.actions.sort((function(t,o){var i=e._orderedQuestions.indexOf(t.name);-1===i&&(i=Number.MAX_VALUE);var n=e._orderedQuestions.indexOf(o.name);return-1===n&&(n=Number.MAX_VALUE),i-n})),this.onItemsChanged()},t.prototype.createDefaultItems=function(e,t){var o=this;e=e||this.supportedQuestions,this.clearItems(),this.getDefaultItems(e,t,!0,!0).forEach((function(e){return o.addToolBoxItem(e,o.actions)})),this.onItemsChanged()},t.prototype.getDefaultItems=function(e,t,o,i){var n=this.getDefaultQuestionItems(e,t);return o&&(n=n.concat(this.getRegisterCustomWidgets())),i&&(n=n.concat(this.getRegisterComponentQuestions())),n},t.prototype.getDefaultQuestionItems=function(e,t){for(var i=[],n=this.getQuestionTypes(e),r=t?this.getDefaultQuestionCategories():{},a=0;a<n.length;a++){var s=n[a],l=o.ElementFactory.Instance.createElement(s,"q1");l||(l=o.Serializer.createClass(s));var u=this.getQuestionJSON(l);delete u.name;var p=G.getString("qt."+s),c="icon-"+s,d={id:s,name:s,iconName:c,title:p,tooltip:p,className:ye.getItemClassNames(c),json:u,isCopied:!1,category:r[s]||""};i.push(this.getOrCreateToolboxItem(d))}return i},t.prototype.getRegisterComponentQuestions=function(){var e=this,t=[];return o.ComponentCollection.Instance.items.forEach((function(o){var i=e.createToolboxItemFromJSON(o.json);i&&t.push(i)})),t},t.prototype.getRegisterCustomWidgets=function(){var e=this,t=[];return o.CustomWidgetCollection.Instance.widgets.forEach((function(o){if(o.canShowInToolbox){var i=e.createToolboxItemFromJSON(o.widgetJson);i&&t.push(i)}})),t},t.prototype.addToolBoxItem=function(e,t){if(e){var o=this.getActionByIdFromArray(e.id,t);if(o)t.splice(t.indexOf(o),1,e);else{var i=Array.isArray(this.supportedQuestions)?this.supportedQuestions.indexOf(e.id):-1;i>-1?t.splice(i,0,e):t.push(e)}}},t.prototype.getActionByIdFromArray=function(e,t){for(var o=0;o<t.length;o++)if(t[o].id===e)return t[o]},t.prototype.createToolboxItemFromJSON=function(e){if(!1!==e.showInToolbox&&!0!==e.internal&&e.name){var i=e.iconName?e.iconName:t.defaultIconName,n=G.getString("qt."+e.name);n&&n!=e.name||(n=this.getTitleFromJsonTitle(e.title,e.name)),n||(n=e.name);var r=e.defaultJSON?JSON.parse(JSON.stringify(e.defaultJSON)):{};r.type||(r.type=e.name),delete r.name;var a=e.category?e.category:"",s=new o.Action({id:e.name,name:e.name,iconName:i,title:n,tooltip:n,className:ye.getItemClassNames(i),json:r,isCopied:!1,category:a});return this.getOrCreateToolboxItem(s)}},t.prototype.getTitleFromJsonTitle=function(e,t){if(!e)return e;if("string"==typeof e)return e;if("object"!=typeof e)return e;for(var o in e){var i=G.locales[o];e[o]&&i&&i.qt&&(i.qt[t]=e[o])}return G.getString("qt."+t)},t.prototype.getQuestionJSON=function(e){var i=(new o.JsonObject).toJsonObject(e);i.type=e.getType();var n=t.getQuestionDefaultSettings(i.type);if(n)for(var r in n)i[r]=n[r];return i},t.prototype.isHiddenCustomWidget=function(e){var t=o.CustomWidgetCollection.Instance.getCustomWidgetByName(e);return!!t&&!t.showInToolbox},t.prototype.getQuestionTypes=function(e){var t=o.ElementFactory.Instance.getAllToolboxTypes();e&&0!=e.length||(e=t);for(var i=[],n=0;n<this.orderedQuestions.length;n++){var r=this.orderedQuestions[n];e.indexOf(r)>-1&&t.indexOf(r)>-1&&i.push(r)}for(n=0;n<e.length;n++){var a=e[n];i.indexOf(a)<0&&t.indexOf(a)>-1&&!this.isHiddenCustomWidget(a)&&i.push(a)}return i},t.prototype.hideAllInnerPopups=function(){this.actions.forEach((function(e){e.hidePopup()}))},t.prototype.onScroll=function(e,t){this.hideAllInnerPopups()},t.MINELEMENTCOUNT=10,t.defaultIconName="icon-default",t.defaultItemComponent="svc-toolbox-item",t.defaultItemGroupComponent="svc-toolbox-item-group",t.defaultCategories={choice:["radiogroup","rating","checkbox","dropdown","tagbox","boolean","file","imagepicker","ranking"],text:["text","comment","multipletext"],containers:["panel","paneldynamic"],matrix:["matrix","matrixdropdown","matrixdynamic"],misc:["html","expression","image","signaturepad"]},J([(0,o.property)({defaultValue:!1})],t.prototype,"showCategoryTitlesValue",void 0),J([(0,o.propertyArray)()],t.prototype,"categories",void 0),J([(0,o.property)({defaultValue:"",onSet:function(e,t){t.onActiveCategoryChanged(e)}})],t.prototype,"activeCategory",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"hasCategories",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"canCollapseCategories",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.updateResponsiveness(e,t.overflowBehavior)}})],t.prototype,"isCompact",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isFocused",void 0),J([(0,o.property)({defaultValue:"scroll",onSet:function(e,t){t.updateResponsiveness(t.isCompact,e)}})],t.prototype,"overflowBehavior",void 0),J([(0,o.property)()],t.prototype,"forceCompact",void 0),J([(0,o.property)({defaultValue:!0,onSet:function(e,t){t.searchManager.isVisible=e}})],t.prototype,"searchEnabled",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showSubitems",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isScrollLocked",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),t}(o.AdaptiveActionContainer),be=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.items=[],o}return K(t,e),Object.defineProperty(t.prototype,"hasPrev",{get:function(){return this.currentIndex>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasNext",{get:function(){var e=this.currentIndex;return e>-1&&e<this.items.length-1},enumerable:!1,configurable:!0}),t.prototype.hasInHistory=function(e){return this.getIndex(e)>-1},t.prototype.prev=function(){this.selectElement(this.currentIndex-1)},t.prototype.next=function(){this.selectElement(this.currentIndex+1)},t.prototype.reset=function(){this.items=[],this.creator.selectedElement&&this.onObjSelected(this.creator.selectedElement)},t.prototype.selectFromAction=function(e,t){var o=this.currentIndex;o>-1&&o<this.items.length&&(this.items[o].propertyName=t),this.creator.selectElement(e)},t.prototype.onObjSelected=function(e){if(!this.isChangingInternally){var t=this.currentIndex;t>-1&&this.items.splice(t,1),this.items.push({obj:e})}},Object.defineProperty(t.prototype,"currentIndex",{get:function(){return this.getIndex(this.creator.selectedElement)},enumerable:!1,configurable:!0}),t.prototype.getIndex=function(e){if(!e)return-1;this.updateItems();for(var t=0;t<this.items.length;t++)if(this.items[t].obj==e)return t;return-1},t.prototype.selectElement=function(e){if(!(e<0||e>=this.items.length)){this.isChangingInternally=!0;var t=this.items[e];this.creator.selectElement(t.obj,t.propertyName),this.isChangingInternally=!1}},t.prototype.updateItems=function(){for(var e=this.items.length-1;e>=0;e--){var t=this.items[e].obj;!t||!t.isDisposed&&t.inSurvey||this.items.splice(e,1)}},t}(o.Base),Ce=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.isJSONChanged=!1,o.isProcessingImmediately=!1,o.jsonEditorChangedTimeoutId=-1,o}return K(t,e),Object.defineProperty(t.prototype,"text",{get:function(){return this.getText()},set:function(e){this.setText(e)},enumerable:!1,configurable:!0}),t.prototype.onEditorActivated=function(){},t.prototype.onPluginActivate=function(){this.text=this.creator.text,this.onEditorActivated(),this.isJSONChanged=!1},t.prototype.onTextChanged=function(){if(-1!==this.jsonEditorChangedTimeoutId&&clearTimeout(this.jsonEditorChangedTimeoutId),this.isProcessingImmediately)this.jsonEditorChangedTimeoutId=-1;else{var e=this;window&&(this.jsonEditorChangedTimeoutId=window.setTimeout((function(){e.jsonEditorChangedTimeoutId=-1,e.processErrors(e.text)}),t.updateTextTimeout))}},Object.defineProperty(t.prototype,"errorList",{get:function(){var e=this;return this.errorListValue||(this.errorListValue=new o.ListModel({items:[],onSelectionChanged:function(t){var o=t.data.error;o&&e.gotoError(o.at,o.rowAt,o.columnAt)},allowSelection:!1,searchEnabled:!1}),this.errorListValue.cssClasses={item:"svc-json-errors__item",itemBody:"svc-json-error",itemsContainer:"svc-json-errors"},this.errorListValue.hasVerticalScroller=!0),this.errorListValue},enumerable:!1,configurable:!0}),t.prototype.setErrors=function(e){var t=e.length>0;if(t){var o=[];this.createErrorActions(e).forEach((function(e){return o.push(e)})),this.errorList.setItems(o)}this.hasErrors=t},t.prototype.gotoError=function(e,t,o){},t.prototype.createErrorActions=function(e){var t=this,i=[],n=1;return e.forEach((function(e){var r=e.rowAt>-1?"Line: "+(e.rowAt+1)+". ":"",a=e.text;a.length>153&&(a=a.substring(0,150)+"..."),a=r+a,e.at,i.push(new o.Action({id:"error_"+n++,component:"json-error-item",title:a,tooltip:e.text,iconName:"icon-error",iconSize:16,data:{error:e,showFixButton:e.isFixable,fixError:function(){t.text=e.fixError(t.text)},fixButtonIcon:"icon-fix",fixButtonTitle:"Fix error"}}))})),i},t.prototype.processErrors=function(e){var t=new ce(e);this.setErrors(t.errors)},Object.defineProperty(t.prototype,"readOnly",{get:function(){return this.creator.readOnly},enumerable:!1,configurable:!0}),t.updateTextTimeout=1e3,J([(0,o.property)()],t.prototype,"hasErrors",void 0),t}(o.Base),we=function(){function e(e){this.creator=e,this.saveToFileHandler=Q,this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.exportToFile=function(e){if(this.model){var t=new Blob([this.model.text],{type:"application/json"});this.saveToFileHandler(e,t)}},e.prototype.importFromFile=function(e,t){var o=this,i=new FileReader;i.onload=function(e){var n=i.result;o.model&&(o.model.text=n,o.model.isJSONChanged=!0),t&&t(n)},i.readAsText(e)},e.prototype.copyToClipboard=function(){this.model&&navigator.clipboard.writeText(this.model.text)},e.prototype.createActions=function(){var e=this,t=[];return this.importAction=new o.Action({id:"svc-json-import",iconName:"icon-load",locTitleName:"ed.surveyJsonImportButton",locTooltipName:"ed.surveyJsonImportButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",needSeparator:!0,action:function(){document&&(e.inputFileElement||(e.inputFileElement=document.createElement("input"),e.inputFileElement.type="file",e.inputFileElement.style.display="none",e.inputFileElement.onchange=function(){e.inputFileElement.files.length<1||(e.importFromFile(e.inputFileElement.files[0]),e.inputFileElement.value="")}),e.inputFileElement.click())}}),t.push(this.importAction),this.exportAction=new o.Action({id:"svc-json-export",iconName:"icon-download",locTitleName:"ed.surveyJsonExportButton",locTooltipName:"ed.surveyJsonExportButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",action:function(){e.exportToFile(i.jsonEditor.exportFileName)}}),t.push(this.exportAction),this.copyAction=new o.Action({id:"svc-json-copy",iconName:"icon-copy",locTitleName:"ed.surveyJsonCopyButton",locTooltipName:"ed.surveyJsonCopyButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",action:function(){e.copyToClipboard()}}),t.push(this.copyAction),t},e.prototype.activate=function(){this.model=this.createModel(this.creator)},e.prototype.deactivate=function(){if(this.model){if(!new ce(this.model.text).isJsonCorrect)return!1;!this.model.readOnly&&this.model.isJSONChanged&&(this.creator.selectedElement=void 0,this.creator.text=this.model.text,this.creator.selectedElement=this.creator.survey,this.creator.setModified({type:"JSON_EDITOR"})),this.model.dispose(),this.model=void 0}return!0},e.prototype.defaultAllowingDeactivate=function(){if(!this.model)return!0;var e=new ce(this.model.text);return e.isJsonCorrect?!e.isJsonHasErrors:void 0},e}();n(1497);var xe=function(e){function t(t){var o=e.call(this,t)||this;return o.aceCanUndo=!1,o.aceCanRedo=!1,o}return K(t,e),t.prototype.getText=function(){return this.aceEditor?this.aceEditor.getValue():""},t.prototype.setText=function(e){this.isProcessingImmediately=!0,this.aceEditor.setValue(e),this.aceEditor.renderer.updateFull(!0),this.aceEditor.getSession().getUndoManager().reset(),this.processErrors(e),this.isProcessingImmediately=!1},t.prototype.init=function(e){var o,i;this.aceEditor=e;var n=null===(i=null===(o=window.ace)||void 0===o?void 0:o.define)||void 0===i?void 0:i.modules;if(n&&n["ace/ext/searchbox"]||this.aceEditor.commands.removeCommand("find"),this.aceEditor.setReadOnly(this.readOnly),t.aceBasePath)try{window.ace.config.set("basePath",t.aceBasePath),this.aceEditor.session.setMode("ace/mode/json")}catch(e){}var r=this;this.aceEditor.setShowPrintMargin(!1),this.aceEditor.getSession().on("change",(function(){r.onTextChanged()})),this.aceEditor.getSession().setUseWorker(!0),ce.newLineChar=this.aceEditor.session.doc.getNewLineCharacter(),this.onPluginActivate()},t.prototype.updateUndoRedoState=function(){var e=this.aceEditor.getSession().getUndoManager();this.aceCanUndo=e.hasUndo(),this.aceCanRedo=e.hasRedo(),!0===this.aceEditor.isFocused()&&(this.isJSONChanged=!e.isClean())},t.prototype.onTextChanged=function(){this.updateUndoRedoState(),e.prototype.onTextChanged.call(this)},t.prototype.createAnnotations=function(e){for(var t=[],o=0;o<e.length;o++){var i=e[o],n={row:i.rowAt,column:i.columnAt,text:i.text,type:"error"};t.push(n)}return t},t.prototype.setErrors=function(t){var o=this;e.prototype.setErrors.call(this,t),this.aceEditor.getSession().setAnnotations(this.createAnnotations(t)),setTimeout((function(){return o.aceEditor.resize()}))},t.prototype.gotoError=function(e,t,o){this.aceEditor.focus(),this.aceEditor.renderer.scrollCursorIntoView({row:t+1,column:o+1},.5),this.aceEditor.gotoLine(t+1,o+1)},t.prototype.onEditorActivated=function(){this.aceEditor.getSession().getUndoManager().markClean(),this.updateUndoRedoState(),this.aceEditor.focus()},t.aceBasePath="",J([(0,o.property)()],t.prototype,"aceCanUndo",void 0),J([(0,o.property)()],t.prototype,"aceCanRedo",void 0),t}(Ce),Te=function(e){function t(t){var o=e.call(this,t)||this;return t.addPluginTab("editor",o,void 0,"svc-tab-json-editor-ace"),o}return K(t,e),t.prototype.createModel=function(e){return new xe(e)},t.hasAceEditor=function(){return"undefined"!=typeof window&&void 0!==window.ace},t}(we);n(8380);var Se=function(e){function t(t){var o=e.call(this,t)||this;return o.ariaLabel=Z("tabs.editor"),o.onPluginActivate(),o}return K(t,e),t.prototype.checkKey=function(e,t){if("Tab"===t.key){t.preventDefault();var o=t.target,i=o.selectionStart,n=o.selectionEnd;o.value=o.value.substring(0,i)+"\t"+o.value.substring(n),o.selectionStart=o.selectionEnd=i+1,t.stopPropagation()}return!0},t.prototype.getText=function(){return this._text},t.prototype.setText=function(e){this.isProcessingImmediately=!0,this._text=e,this.processErrors(e),this.isProcessingImmediately=!1},t.prototype.gotoError=function(e,t,o){if(this.textElement){var i=this.textElement;i.selectionStart=e,i.selectionEnd=e,i.focus()}},Object.defineProperty(t.prototype,"errorButtonText",{get:function(){return this.canShowErrors?Z("ed.jsonHideErrors"):Z("ed.jsonShowErrors")},enumerable:!1,configurable:!0}),t.prototype.toggleErrors=function(){this.canShowErrors=!this.canShowErrors},Object.defineProperty(t.prototype,"userFriendlyErrors",{get:function(){if(0===this._errors.length)return[];for(var e=[],t=0;t<this._errors.length-1;t++)e[t]=this._errors[t].text,e[t]+="\n\n";return e[this._errors.length-1]=this._errors[this._errors.length-1].text,e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"errors",{get:function(){return this._errors},enumerable:!1,configurable:!0}),t.prototype.onTextChanged=function(){this.isJSONChanged=!0,e.prototype.onTextChanged.call(this)},t.prototype.setErrors=function(t){this._errors=t,e.prototype.setErrors.call(this,t)},J([(0,o.property)({defaultValue:"",onSet:function(e,t){return t.onTextChanged()}})],t.prototype,"_text",void 0),J([(0,o.propertyArray)()],t.prototype,"_errors",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"canShowErrors",void 0),t}(Ce),Pe=function(e){function t(t){var o=e.call(this,t)||this;return t.addPluginTab("editor",o,void 0,"svc-tab-json-editor-textarea"),o}return K(t,e),t.prototype.createModel=function(e){return new Se(e)},t}(we);n(8538);var Ee=function(e){function t(t){var o=e.call(this)||this;return o.surveyProvider=t,o.activateZoom=function(){document.addEventListener("keydown",o.listenTryToZoom),document.addEventListener("wheel",o.listenTryToZoomWithWheel,{passive:!1})},o.deactivateZoom=function(){document.removeEventListener("keydown",o.listenTryToZoom),document.removeEventListener("wheel",o.listenTryToZoomWithWheel)},o.listenTryToZoomWithWheel=function(e){return o.tryToZoomWithWheel(e,e)},o.listenTryToZoom=function(e){return o.tryToZoom(e,e)},o}return K(t,e),t.prototype.surveyChanged=function(){var e=this,t=this;this.survey.onOpenDropdownMenu.add((function(o,i){if(!e.surveyProvider.isTouch){var n=Ie[t.activeDevice];i.menuType="desktop"===n.deviceType?"dropdown":"tablet"==n.deviceType?"popup":"overlay"}}))},Object.defineProperty(t.prototype,"zoomScale",{get:function(){return this.currZoomScale},enumerable:!1,configurable:!0}),t.prototype.tryToZoomWithWheel=function(e,t){var o=t.deltaY;return(t.ctrlKey||t.metaKey)&&(o<0?this.zoomSimulator("up",t):this.zoomSimulator("down",t)),!0},t.prototype.tryToZoom=function(e,t){return(t.ctrlKey||t.metaKey)&&(107!=t.keyCode&&187!=t.keyCode||this.zoomSimulator("up",t),109!=t.keyCode&&189!=t.keyCode||this.zoomSimulator("down",t),48!=t.keyCode&&96!=t.keyCode||this.zoomSimulator("zero",t)),!0},t.prototype.changeZoomScale=function(e){var t="up"===e?1.01:"down"===e?1/1.01:1;this.currZoomScale="zero"===e?1:this.currZoomScale*t},t.prototype.zoomSimulator=function(e,t){t.preventDefault(),this.changeZoomScale(e);var o=document.getElementById("svd-simulator-wrapper");o&&(o.style.transform="scale("+this.currZoomScale+")"),t.stopPropagation()},t.prototype.resetZoomParameters=function(){this.currZoomScale=1;var e=document.getElementById("svd-simulator-wrapper");e&&(e.style.transform="")},Object.defineProperty(t.prototype,"activeDevice",{get:function(){return this.device},set:function(e){this.device=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"landscapeOrientation",{get:function(){return this.landscape},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasFrame",{get:function(){var e=Ie[this.activeDevice];return this.simulatorEnabled&&"desktop"!==e.deviceType},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"simulatorFrame",{get:function(){if(this.hasFrame){var e=Ie[this.activeDevice],t=(this.landscapeOrientation?e.height:e.width)/e.cssPixelRatio,o=(this.landscapeOrientation?e.width:e.height)/e.cssPixelRatio,i=(this.landscapeOrientation?e.height:e.width)/e.cssPixelRatio,n=(this.landscapeOrientation?e.width:e.height)/e.cssPixelRatio,r=1*i+2*(this.landscapeOrientation?64:16),a=1*n+2*(this.landscapeOrientation?16:64);return{scale:(this.simulatorScaleEnabled,1),frameWidth:r,frameHeight:a,landscapedFrameWidth:this.landscapeOrientation?a:r,landscapedFrameHeight:this.landscapeOrientation?r:a,deviceWidth:t,deviceHeight:o,cssClass:e.cssClass+(this.landscapeOrientation?" svd-simulator-frame-landscape":"")}}},enumerable:!1,configurable:!0}),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svd-simulator-main").append("svd-simulator-main--frame",this.hasFrame).append("svd-simulator-main--desktop","desktop"===this.device).append("svd-simulator-main--running",this.isRunning).toString()},J([(0,o.property)({defaultValue:!0})],t.prototype,"landscape",void 0),J([(0,o.property)({onSet:function(e,t){t.surveyChanged()}})],t.prototype,"survey",void 0),J([(0,o.property)({defaultValue:"desktop"})],t.prototype,"device",void 0),J([(0,o.property)({defaultValue:"l"})],t.prototype,"orientation",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"considerDPI",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isRunning",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"simulatorEnabled",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"simulatorScaleEnabled",void 0),t}(o.Base),Ve=96*("undefined"!=typeof window?window.devicePixelRatio:1),Ie={desktop:{deviceType:"desktop",title:"Desktop"},iPhoneSE:{cssPixelRatio:2,ppi:326,width:750,height:1334,deviceType:"phone",title:"iPhone SE",cssClass:"svd-simulator-iphonexmax"},iPhone15:{cssPixelRatio:3,ppi:460,width:1179,height:2556,deviceType:"phone",title:"iPhone 15",cssClass:"svd-simulator-iphonexmax"},iPhone15Plus:{cssPixelRatio:3,ppi:460,width:1290,height:2796,deviceType:"phone",title:"iPhone 15 Plus",cssClass:"svd-simulator-iphonexmax"},iPadMini:{cssPixelRatio:2.5,ppi:326,width:1536,height:2048,deviceType:"tablet",title:"iPad Mini",cssClass:"svd-simulator-ipadmini"},iPad:{cssPixelRatio:2,ppi:264,width:1640,height:2360,deviceType:"tablet",title:"iPad Air",cssClass:"svd-simulator-ipad"},androidPhone:{cssPixelRatio:3,ppi:411,width:1080,height:2048,deviceType:"phone",title:"Android Phone",cssClass:"svd-simulator-androidphone"},androidTablet:{cssPixelRatio:1.5,ppi:149,width:800,height:1280,deviceType:"tablet",title:"Android Tablet",cssClass:"svd-simulator-androidtablet"},msSurface:{cssPixelRatio:1,ppi:148,width:768,height:1366,deviceType:"tablet",title:"MS Surface",cssClass:"svd-simulator-mssurface"},genericPhone:{cssPixelRatio:1,deviceType:"phone",title:"",cssClass:"svd-simulator-genphone"}},Ae=function(e){function t(t,i){void 0===i&&(i=o.defaultV2Css);var n=e.call(this)||this;return n.surveyProvider=t,n.startThemeClasses=i,n.enableInvisiblePages=!0,n.pages=new o.ActionContainer,n.simulator=new Ee(t),n}return K(t,e),Object.defineProperty(t.prototype,"activeLanguage",{get:function(){return this.getPropertyValue("activeLanguage",this.survey.locale||o.surveyLocalization.defaultLocale)},set:function(e){e!==this.activeLanguage&&(this.setPropertyValue("activeLanguage",e),this.survey.locale=e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"survey",{get:function(){return this.simulator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pageActions",{get:function(){return this.pages.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPageToolbarVisible",{get:function(){return this.pages.visibleActions.length>0&&!this.surveyProvider.isMobileView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMobileView",{get:function(){return this.surveyProvider.isMobileView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showResults",{get:function(){return this.getShowResults()},enumerable:!1,configurable:!0}),t.prototype.updateSimulatorSurvey=function(e,t){var o=this,i=this.surveyProvider.createSurvey(e||{},this.getTabName(),this,(function(e){e.applyTheme(o.surveyProvider.theme),e.setCss(t,!1),e.fitToContainer=!0,e.addLayoutElement({id:"complete-customization",container:"completePage",component:"svc-complete-page",data:o})})),n=!!this.simulator.survey;this.simulator.survey=i,this.onSurveyCreatedCallback&&this.onSurveyCreatedCallback(this.survey),this.survey.onComplete.add((function(e){o.isRunning=!1})),this.survey.onNavigateToUrl&&this.survey.onNavigateToUrl.add((function(e,t){var i=t.url;if(t.url="",i&&t.allow){var n=Z("ed.navigateToMsg")+" '"+i+"'.";o.surveyProvider?o.surveyProvider.notify(n):alert(n)}})),this.survey.onStarted.add((function(e){o.setActivePageItem(o.simulator.survey.activePage,!0)})),this.survey.onCurrentPageChanged.add((function(e,t){o.activePage=t.newCurrentPage,o.setActivePageItem(t.oldCurrentPage,!1),o.setActivePageItem(t.newCurrentPage,!0)})),this.survey.onPageVisibleChanged.add((function(e,t){o.updatePageItem(t.page),o.updatePrevNextPageActionState()})),n&&this.show()},t.prototype.setJSON=function(e,t){this.json=e,null!=e&&e.cookieName&&delete e.cookieName,this.updateSimulatorSurvey(e,t)},t.prototype.initialize=function(e,t){this.setJSON(e,this.startThemeClasses),this.updatePageList(),void 0!==t.showPagesInTestSurveyTab&&(this.showPagesInTestSurveyTab=t.showPagesInTestSurveyTab),this.buildActions()},t.prototype.updatePageItem=function(e){var t=this.getPageItemByPage(e);t&&(t.enabled=this.enableInvisiblePages&&this.showInvisibleElements||e.isVisible)},t.prototype.getCurrentPageItem=function(){return this.pageListItems[this.survey.pages.indexOf(this.survey.activePage)]},t.prototype.getSelectPageTitle=function(){return this.activePage&&this.getPageTitle(this.activePage,"preview-tab:selected-page","survey-tester-selected")||Z("ts.selectPage")},t.prototype.getPageTitle=function(e,o,i){void 0===o&&(o="preview-tab:page-list"),void 0===i&&(i="survey-tester");var n=e.title.replace(t.tagRegex,""),r=this.surveyProvider.getObjectDisplayName(e,o,i,n);if(r===e.name&&0===r.indexOf("page")){var a=this.survey.pages.indexOf(e);return G.getString("ed.pageTypeName")+" "+(a+1)}return r},t.prototype.updatePageList=function(){for(var e=[],t=0;t<this.survey.pages.length;t++){var o=this.survey.pages[t],i={id:o.name,data:o,title:this.getPageTitle(o),enabled:this.enableInvisiblePages&&this.showInvisibleElements||o.isVisible,visible:!0};o.isVisible||(i.css="svc-page-invisible",i.markerIconName="icon-invisible-items",i.markerIconSize=24),e.push(i)}this.pageListItems=e},t.prototype.getTabName=function(){return""},t.prototype.getShowResults=function(){return!1},t.prototype.show=function(){this.showInvisibleElements=!1,this.activePage=this.survey.activePage,this.survey.locale=this.activeLanguage,this.isRunning=!0},t.prototype.testAgain=function(){this.setJSON(this.json,this.simulator.survey.css),this.updatePageList(),this.show()},t.prototype.buildActions=function(){var e=this,t=[],i=function(t){var o=e.survey.currentPageNo,i=o+(t?1:-1);"starting"===e.survey.state&&t&&(i=0);var n=e.showInvisibleElements?e.survey.pages[i]:e.survey.visiblePages[i];!t&&0===o&&e.survey.firstPageIsStarted&&e.survey.pages.length>0&&(n=e.survey.pages[0]);var r=e.survey.pages.indexOf(n);e.activePage=e.survey.pages[r],e.selectPageAction.data.selectedItem=e.pageListItems[r]};this.prevPageAction&&(this.prevPageAction.visible=new o.ComputedUpdater((function(){var t="running"===e.survey.state,o=e.getTabName()===e.surveyProvider.activeTab;return I(e.isRunning,o,e.pageListItems.length>1)&&t})),this.prevPageAction.iconName=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?"icon-arrow-left":"icon-arrow-left_16x16"})),this.prevPageAction.iconSize=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?24:16})),this.prevPageAction.action=function(){return i(!1)},t.push(this.prevPageAction)),this.selectPageAction=(0,o.createDropdownActionModel)({id:"pageSelector",css:"svc-page-selector",title:this.getSelectPageTitle(),visible:this.isRunning&&this.pageListItems.length>1&&this.showPagesInTestSurveyTab},{items:this.pageListItems,allowSelection:!0,selectedItem:this.getCurrentPageItem(),onSelectionChanged:function(t){e.activePage=t.data;for(var o=0;o<e.survey.pages.length&&e.survey.pages[o]!==e.activePage;o++)e.survey.pages[o].passed=!0},cssClass:"svc-creator-popup",verticalPosition:"top",horizontalPosition:"center"}),t.push(this.selectPageAction),this.selectPageAction.visible=new o.ComputedUpdater((function(){return"running"===e.survey.state})),this.nextPageAction&&(this.nextPageAction.visible=new o.ComputedUpdater((function(){var t="running"===e.survey.state,o=e.getTabName()===e.surveyProvider.activeTab;return I(e.isRunning,o,e.pageListItems.length>1)&&t})),this.nextPageAction.iconName=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?"icon-arrow-right":"icon-arrow-right_16x16"})),this.nextPageAction.iconSize=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?24:16})),this.nextPageAction.action=function(){return i(!0)},t.push(this.nextPageAction)),this.pages.actions=t,this.pages.containerCss="sv-action-bar--pages",this.updatePrevNextPageActionState()},t.prototype.setActivePageItem=function(e,t){var o=this.getPageItemByPage(e);o&&(o.active=t)},t.prototype.getPageItemByPage=function(e){var t=this.selectPageAction.popupModel.contentComponentData.model;if(t&&Array.isArray(t.actions)){for(var o=t.actions,i=0;i<o.length;i++)if(o[i].data===e)return o[i];return null}},t.prototype.updateResultsTemplate=function(e){this.simulator.survey.setCss(e,!1),this.simulator.survey.render()},t.prototype.setTheme=function(e,t){var i=t.filter((function(t){return t.name===e})),n=o.defaultV2Css;i.length>0&&(n=i[0].theme),this.isRunning?this.updateSimulatorSurvey(this.json,n):this.updateResultsTemplate(n)},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.pages.hasActions&&("activePage"===t&&(this.updatePrevNextPageActionState(),this.selectPageAction.title=this.getSelectPageTitle()),"isRunning"!==t&&"pageListItems"!==t&&"showPagesInTestSurveyTab"!==t||(this.selectPageAction.popupModel.contentComponentData.model.items=this.pageListItems,this.selectPageAction.popupModel.contentComponentData.model.selectedItem=this.getCurrentPageItem(),this.selectPageAction.visible=this.isRunning&&this.pageListItems.length>1&&this.showPagesInTestSurveyTab))},t.prototype.updatePrevNextPageActionState=function(){if(this.prevPageAction&&this.survey){var e=this.survey.firstPageIsStarted&&"starting"!==this.survey.state||!this.survey.firstPageIsStarted&&!this.survey.isFirstPage;this.prevPageAction.enabled=e;var t=this.survey&&this.survey.visiblePages.indexOf(this.activePage)!==this.survey.visiblePages.length-1;this.nextPageAction.enabled=t}},Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.isMobileView?Z("ed.previewPlaceholderTitleMobile"):Z("ed.previewPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.isMobileView?Z("ed.previewPlaceholderDescriptionMobile"):Z("ed.previewPlaceholderDescription")},enumerable:!1,configurable:!0}),t.prototype.onScroll=function(){return this.survey.onScroll(),!0},t.prototype.dispose=function(){this.selectPageAction&&this.selectPageAction.dispose(),this.simulator.dispose(),e.prototype.dispose.call(this)},t.tagRegex=/(<([^>]+)>)/gi,J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.simulator.survey.showInvisibleElements=e}})],t.prototype,"showInvisibleElements",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showPagesInTestSurveyTab",void 0),J([(0,o.property)({defaultValue:!0,onSet:function(e,t){t.simulator&&(t.simulator.isRunning=e)}})],t.prototype,"isRunning",void 0),J([(0,o.propertyArray)()],t.prototype,"pageListItems",void 0),J([(0,o.property)({onSet:function(e,t){if(e){var o=t.simulator.survey;o.firstPageIsStarted&&(e===o.pages[0]?o.clear(!1,!0):"starting"==o.state&&o.setPropertyValue("isStartedState",!1)),"starting"!==o.state&&(o.currentPage=e)}t.updatePrevNextPageActionState()}})],t.prototype,"activePage",void 0),t}(o.Base);n(5625);var Oe=function(e){function t(t,o){return e.call(this,t,o)||this}return K(t,e),t.prototype.getTabName=function(){return"test"},t.prototype.getShowResults=function(){return this.surveyProvider.previewShowResults&&!this.isRunning&&!this.isMobileView},t}(Ae),Ne=function(){function e(e){this.creator=e,this.simulatorTheme=o.surveyCss[o.defaultV2ThemeName],e.addPluginTab("test",this),this.setPreviewTheme(this.creator.themeForPreview),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.setDevice=function(e){this.model.simulator.device=e,this.model.simulator.resetZoomParameters();var t=Ie[this.model.simulator.device].deviceType;this.orientationSelectorAction.enabled="desktop"!=t,this.deviceSelectorAction.iconName="icon-device-"+t,this.deviceSelectorAction.title=Z("pe.simulator")},e.prototype.setDefaultLanguageOption=function(e){var t=this,o=!0===e||"all"===e||"auto"===e&&this.model.survey.getUsedLocales().length>1;this.languageSelectorAction.visible=o;var i=[];o&&(i=this.getLanguages("all"!==e?this.model.survey.getUsedLocales():null)),this.languageSelectorAction.popupModel.contentComponentData.model.setItems(i),this.languageSelectorAction.data.selectedItem=i.filter((function(e){return e.id===t.model.activeLanguage}))[0]},e.prototype.getLanguages=function(e){void 0===e&&(e=null);for(var t=[],i=e&&e.length>1?e:o.surveyLocalization.getLocales(),n=0;n<i.length;n++){var r=i[n];t.push({id:r,title:G.getLocaleName(r)})}return t},e.prototype.updateActions=function(){this.languageSelectorAction.title=G.getLocaleName(this.model.activeLanguage),this.languageSelectorAction.visible=!0,this.creator.showSimulatorInTestSurveyTab&&(this.setDevice(this.model.simulator.device),this.deviceSelectorAction.data.selectedItem={id:this.model.simulator.device},this.orientationSelectorAction.title=Z("pe.portraitOrientation")),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction.css=this.model.showInvisibleElements?"sv-action-bar-item--active":"",this.invisibleToggleAction.visible=this.model.isRunning),null!=this.creator.showDefaultLanguageInTestSurveyTab&&this.setDefaultLanguageOption(this.creator.showDefaultLanguageInTestSurveyTab)},e.prototype.setPreviewTheme=function(e){this.simulatorTheme=o.surveyCss[e]||o.surveyCss[o.defaultV2ThemeName]},e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){return"test"===e.creator.activeTab}))},e.prototype.activate=function(){this.model=new Oe(this.creator,this.simulatorTheme),this.model.simulator.landscape="portrait"!=this.creator.previewOrientation,this.update()},e.prototype.update=function(){var e=this;if(this.model){var t={showPagesInTestSurveyTab:this.creator.showPagesInTestSurveyTab};this.model.testAgainAction=this.testAgainAction,this.model.prevPageAction=this.prevPageAction,this.model.nextPageAction=this.nextPageAction,this.model.initialize(this.creator.JSON,t),this.updateActions(),this.model.show(),this.model.onPropertyChanged.add((function(t,o){"isRunning"===o.name&&(e.invisibleToggleAction&&(e.invisibleToggleAction.visible=e.model.isRunning),e.testAgainAction.visible=!e.model.isRunning)}))}},e.prototype.deactivate=function(){return this.model&&(this.simulatorTheme=this.model.simulator.survey.css,this.model.onSurveyCreatedCallback=void 0,this.model.dispose(),this.model=void 0),this.languageSelectorAction.visible=!1,this.testAgainAction.visible=!1,this.invisibleToggleAction&&(this.invisibleToggleAction.visible=!1),!0},e.prototype.getAvailableThemes=function(e){for(var t=[],i=0;i<e.length;i++){var n=e[i],r=new o.Action({id:n.name+"_themeSwitcher",locTitleName:this.getThemeLocName(n.name)});r.value=n.name,t.push(r)}return t},e.prototype.getThemeLocName=function(e){return"ed."+e+"Theme"},e.prototype.createActions=function(){var e=this,t=[];if(this.testAgainAction=new o.Action({id:"testSurveyAgain",visible:!1,locTitleName:"ed.testSurveyAgain",action:function(){e.model.testAgain()}}),this.creator.showSimulatorInTestSurveyTab){var i=Object.keys(Ie).filter((function(e){return!!Ie[e].title})).map((function(e){var t;return{id:e,title:Ie[e].title,visibleIndex:null!==(t=Ie[e].visibleIndex)&&void 0!==t?t:Number.MAX_VALUE}}));this.deviceSelectorAction=(0,o.createDropdownActionModel)({id:"deviceSelector",iconName:"icon-device-desktop",mode:"small",visible:new o.ComputedUpdater((function(){return I("test"===e.creator.activeTab,e.creator.showSimulatorInTestSurveyTab,!e.creator.isTouch)}))},{items:i,allowSelection:!0,onSelectionChanged:function(t){e.setDevice(t.id)},horizontalPosition:"center",cssClass:"svc-creator-popup",onHide:function(){e.deviceSelectorAction.enabled=!0},onShow:function(){e.deviceSelectorAction.enabled=!1}}),t.push(this.deviceSelectorAction),this.orientationSelectorAction=new o.Action({id:"orientationSelector",iconName:"icon-device-rotate",mode:"small",visible:new o.ComputedUpdater((function(){return I("test"===e.creator.activeTab,e.creator.showSimulatorInTestSurveyTab,!e.creator.isTouch)})),action:function(){e.model.simulator.landscape=!e.model.simulator.landscape,e.orientationSelectorAction.title=Z(e.model.simulator.landscape?"pe.portraitOrientation":"pe.landscapeOrientation")}}),t.push(this.orientationSelectorAction)}this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction=new o.Action({id:"showInvisible",iconName:"icon-invisible-items",mode:"small",needSeparator:new o.ComputedUpdater((function(){return!e.creator.isMobileView})),locTitleName:"ts.showInvisibleElements",visible:!1,action:function(){e.model.showInvisibleElements=!e.model.showInvisibleElements,e.invisibleToggleAction.css=e.model.showInvisibleElements?"sv-action-bar-item--active":"",e.invisibleToggleAction.title=Z(e.model.showInvisibleElements?"ts.hideInvisibleElements":"ts.showInvisibleElements")}}),t.push(this.invisibleToggleAction));var n=o.StylesManager.getIncludedThemeCss(),r=["defaultV2","modern","default"];n=n.sort((function(e,t){return r.indexOf(e.name)>r.indexOf(t.name)?1:-1}));var a,s=this.getAvailableThemes(n);return this.creator.allowChangeThemeInPreview&&s.length>1&&!this.creator.showThemeTab&&(this.changeThemeModel=new o.ListModel(s,(function(t){e.model&&e.model.setTheme(t.value,n),e.changeThemeAction.locTitleName=e.getThemeLocName(t.value),e.changeThemeAction.locStrsChanged(),e.changeThemePopupModel.toggleVisibility()}),!0),this.changeThemeModel.locOwner=this.creator,this.changeThemePopupModel=new o.PopupModel("sv-list",{model:this.changeThemeModel},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"}),this.changeThemeAction=new o.Action({id:"themeSwitcher",iconName:"icon-theme",component:"sv-action-bar-item-dropdown",mode:"large",locTitleName:this.getThemeLocName((a=n.filter((function(t){return t.theme.root===e.simulatorTheme.root})),a.length>0?a[0].name:"defaultV2")),needSeparator:!0,visible:new o.ComputedUpdater((function(){return I(e.creator.showSimulatorInTestSurveyTab,"test"===e.creator.activeTab)})),action:function(){e.changeThemePopupModel.toggleVisibility()},popupModel:this.changeThemePopupModel}),t.push(this.changeThemeAction)),this.languageSelectorAction=(0,o.createDropdownActionModel)({id:"languageSelector",iconName:"icon-language",visible:!1,mode:new o.ComputedUpdater((function(){return e.creator.isMobileView?"small":"large"}))},{items:[],allowSelection:!0,onSelectionChanged:function(t){e.model.activeLanguage=t.id,e.languageSelectorAction.title=G.getLocaleName(t.id)},horizontalPosition:"center",cssClass:"svc-creator-popup",onHide:function(){e.languageSelectorAction.enabled=!0},onShow:function(){e.languageSelectorAction.enabled=!1}}),t.push(this.languageSelectorAction),this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",action:function(){e.creator.makeNewViewActive("designer")},visible:this.createVisibleUpdater(),locTitleName:"ed.designer",showTitle:!1}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",active:!0,visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1,action:function(){}}),this.prevPageAction=new o.Action({id:"prevPage",iconName:"icon-arrow-left_16x16",needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),visible:!1}),this.nextPageAction=new o.Action({id:"nextPage",iconName:"icon-arrow-right_16x16",visible:!1}),t},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.prevPageAction),this.creator.footerToolbar.actions.push(this.nextPageAction),this.invisibleToggleAction&&this.creator.footerToolbar.actions.push(this.invisibleToggleAction)},e}(),Le=function(){function e(e,t){void 0===t&&(t=null),this.survey=e,this.options=t}return e.prototype.toDisplayText=function(e){if(!this.survey)return e;this.showTitles=!!this.options&&1==this.options.showTitlesInExpressions;var t=(new o.ConditionsParser).parseExpression(e);if(!t)return e;if(t.getType)return this.toDisplayTextCore(t);if(!this.showTitles)return e;var i=[];return t.setVariables(i),this.replaceVariables(e,i)},e.prototype.toExpression=function(e){return this.toDisplayTextCore(e)},e.prototype.toDisplayTextCore=function(e){this.currentQuestion=null;var t=this,o=!0,i=function(e){var n=o;return o=!1,t.showTitles&&"variable"==e.getType()?t.getQuestionText(e):t.showTitles&&"const"==e.getType()?t.getDisplayText(e):"binary"==e.getType()?(t.proceedBinary(e),t.getDisplayBinary(e,n,i)):"unary"==e.getType()?t.getDisplayUnary(e,i):void 0};return e.toString(i)},e.prototype.getQuestionText=function(e){var t=this.getQuestionByName(e.variable);return t&&t.title?E(t.title):e.variable},e.prototype.getDisplayText=function(e){if(this.currentQuestion){var t=this.currentQuestion.getDisplayValue(!0,e.correctValue);return t?new o.Const(t).toString():void 0}},e.prototype.getDisplayOperand=function(e,t){return e?e.toString(t):""},e.prototype.getDisplayOperator=function(t){return e.operatorText[t]||G.getString("op."+t)},e.prototype.getDisplayBinary=function(e,t,o){return(t?"":"(")+this.getDisplayOperand(e.leftOperand,o)+" "+this.getDisplayOperator(e.operator)+" "+this.getDisplayOperand(e.rightOperand,o)+(t?"":")")},e.prototype.getDisplayUnary=function(e,t){var o=e.expression.toString(t),i=this.getDisplayOperator(e.operator);return"empty"==e.operator||"notempty"==e.operator?o+" "+i:i+" "+o},e.prototype.proceedBinary=function(e){e.isArithmetic||e.isConjunction?this.currentQuestion=null:(this.currentQuestion=this.getQuestionFromOperands(e.leftOperand,e.rightOperand),this.currentQuestion||(this.currentQuestion=this.getQuestionFromOperands(e.rightOperand,e.leftOperand)))},e.prototype.getQuestionFromOperands=function(e,t){if(!e||!t)return null;if("variable"!=e.getType())return null;var o=t.getType();return"const"!=o&&"function"!=o&&"array"!=o?null:this.getQuestionByName(e.variable)},e.prototype.replaceVariables=function(e,t){for(var o=0;o<t.length;o++)e=this.replaceVariable(e,t[o]);return e},e.prototype.replaceVariable=function(e,t){var o=this.getQuestionByName(t);return o&&o.title?e.replace(E(t),E(o.title)):e},e.prototype.getQuestionByName=function(e){return this.survey?this.survey.getQuestionByValueName(e):null},e.operatorText={less:"<",lessorequal:"<=",greater:">",greaterorequal:">=",equal:"==",notequal:"!=",plus:"+",minus:"-",mul:"*",div:"/",power:"^",mod:"%",negate:"!"},e}(),_e=function(){function e(){}return e.prototype.remove=function(e,t){var i=(new o.ConditionsParser).parseExpression(e);if(!i)return e;if(this.wasRemoved=!1,i.getType){var n=this.processOperand(i,t);return this.wasRemoved?n?n.toString():"":e}return e},e.prototype.processOperand=function(e,t){return e?"variable"==e.getType()?this.processVariable(e,t):"unary"==e.getType()?this.processUnary(e,t):"binary"==e.getType()?this.proceedBinary(e,t):e:null},e.prototype.processVariable=function(e,t){return e.variable!==t?e:(this.wasRemoved=!0,null)},e.prototype.processUnary=function(e,t){return this.processOperand(e.expression,t)?e:(this.wasRemoved=!0,null)},e.prototype.proceedBinary=function(e,t){var i=this.processOperand(e.leftOperand,t),n=this.processOperand(e.rightOperand,t);if(i&&n)return i!==e.leftOperand||n!==e.rightOperand?new o.BinaryOperand(e.operator,i,n,e.isArithmetic):e;if(!i&&!n)return null;var r=i||n;return"binary"==r.getType()?r:null},e}(),Me=function(){function e(e){this.constChanges=[],this.operand=(new o.ConditionsParser).parseExpression(e)}return e.prototype.update=function(e,t,o){this.updateOperand(this.operand,e.toLocaleLowerCase(),t,o)},Object.defineProperty(e.prototype,"isModified",{get:function(){return this.constChanges.length>0},enumerable:!1,configurable:!0}),e.prototype.toString=function(){var e=this,t=!0,o=function(i){var n=t;return t=!1,"const"===i.getType()?e.constToString(i):"binary"===i.getType()?e.binaryToString(i,n,o):void 0};return this.operand.toString(o)},e.prototype.constToString=function(e){for(var t=0;t<this.constChanges.length;t++)if(this.constChanges[t].op===e)return this.constChanges[t].val;return e.toString()},e.prototype.binaryToString=function(e,t,o){return(t?"":"(")+this.operandToString(e.leftOperand,o)+" "+this.operatorToString(e.operator)+" "+this.operandToString(e.rightOperand,o)+(t?"":")")},e.prototype.operandToString=function(e,t){return e?e.toString(t):""},e.prototype.operatorToString=function(t){return e.operatorText[t]||t},e.prototype.updateOperand=function(e,t,o,i){if("binary"==e.getType()){var n=e;n.isConjunction?(this.updateOperand(n.leftOperand,t,o,i),this.updateOperand(n.rightOperand,t,o,i)):this.hasVarName(n.leftOperand,t)?this.updateOperandConst(n.rightOperand,o,i):this.hasVarName(n.rightOperand,t)&&this.updateOperandConst(n.leftOperand,o,i)}},e.prototype.hasVarName=function(e,t){if(e&&"variable"===e.getType())return e.variable.toLowerCase()===t},e.prototype.updateOperandConst=function(e,t,i){var n=this;if("array"===e.getType()){var r=e;Array.isArray(r.values)&&r.values.forEach((function(e){return n.updateOperandConst(e,t,i)}))}if("const"===e.getType()){var a=e;o.Helpers.isTwoValueEquals(a.correctValue,t)&&(i=this.getCorrectNewValue(a,i),this.constChanges.push({op:e,val:i}))}},e.prototype.getCorrectNewValue=function(e,t){var i=e.toString();return!i||o.Helpers.isTwoValueEquals(e.correctValue,i)||'"'!==i[0]&&"'"!==i[0]?t:i[0]+t+i[0]},e.operatorText={less:"<",lessorequal:"<=",greater:">",greaterorequal:">=",equal:"=",notequal:"!=",plus:"+",minus:"-",mul:"*",div:"/",power:"^",mod:"%",negate:"!"},e}();function De(e,t,o,i){var n=new Me(e);return n.update(t,o,i),n.isModified?n.toString():e}function ke(e){return G.getString("ed.lg."+e)}var je=function(){function e(e,t,o){void 0===o&&(o=null),this.logicType=e,this.survey=t,this.options=o,this.mergeWithBaseClass()}return e.expressionToDisplayText=function(e,t,o){return new Le(e,t).toDisplayText(o)},e.prototype.mergeWithBaseClass=function(){if(this.logicType.baseClass){var e=Re.baseTypes[this.logicType.baseClass];if(e)for(var t in e)this.logicType[t]||(this.logicType[t]=e[t])}},Object.defineProperty(e.prototype,"name",{get:function(){return this.logicType.name},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"baseClass",{get:function(){return this.logicType.baseClass},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"propertyName",{get:function(){return this.logicType.propertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasVisibleElements",{get:function(){return!0!==this.logicType.isInvisible},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dynamicPropertyName",{get:function(){return this.logicType.dynamicPropertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dependedOnPropertyName",{get:function(){return this.logicType.dependedOnPropertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{get:function(){return!!this.showInUI&&(!this.logicType.showIf||this.logicType.showIf(this.survey))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showTitlesInExpression",{get:function(){return!!this.options&&this.options.showTitlesInExpressions},enumerable:!1,configurable:!0}),e.prototype.createNewObj=function(e){var t=o.Serializer.createClass(this.baseClass);return e&&t.fromJSON(e.toJSON()),t.survey=this.survey,t.setOwner&&t.setOwner(this.survey),(t instanceof o.ItemValue||t instanceof o.SurveyTrigger)&&(t.isGhost=!0),t},e.prototype.cloneElement=function(e){return this.isTrigger?this.createNewObj(e):e},e.prototype.areElementsEqual=function(e,t){return e===t||!(!this.isTrigger||e.getType()!==t.getType())&&o.Helpers.isTwoValueEquals(e.toJSON(),t.toJSON())},e.prototype.saveNewElement=function(e){var t=this.logicType.getCollection?this.logicType.getCollection(this.survey):null;!t&&this.isTrigger&&(t=this.survey.triggers),t&&t.indexOf(e)<0&&t.push(e)},Object.defineProperty(e.prototype,"showInUI",{get:function(){return!1!==this.logicType.showInUI},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isUniqueItem",{get:function(){return!0===this.logicType.isUniqueItem},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"questionNames",{get:function(){return this.logicType.questionNames},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"displayName",{get:function(){return ke(this.name+"Name")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"description",{get:function(){return ke(this.name+"Description")},enumerable:!1,configurable:!0}),e.prototype.getParentElement=function(e){return this.logicType.getParentElement?this.logicType.getParentElement(e):null},Object.defineProperty(e.prototype,"hasSelectorChoices",{get:function(){return!!this.logicType.getSelectorChoices},enumerable:!1,configurable:!0}),e.prototype.getSelectorChoices=function(e,t){return this.hasSelectorChoices?this.logicType.getSelectorChoices(e,t):null},e.prototype.getDisplayText=function(e){var t=ke(this.name+"Text");if(this.logicType.getDisplayText)return this.logicType.getDisplayText(e,t,this);this.logicType.getElementName&&(e=this.getElementByName(this.logicType.getElementName(e)));var o=this.getElementDisplayName(e);if(o){var i=this.getParentElement(e),n=this.getElementDisplayName(i);return t.format(o,n)}return t},e.prototype.getElementDisplayName=function(e){if(!e)return"";var t="";return this.showTitlesInExpression&&(t=e.title),t||(t=e.name||""),E(t)},e.prototype.getElementByName=function(e){return this.survey?this.survey.getQuestionByName(e)||this.survey.getPageByName(e):null},e.prototype.formatElName=function(e){var t=this.getElementByName(e);return this.getElementDisplayName(t)},e.prototype.formatExpression=function(t){return e.expressionToDisplayText(this.survey,this.options,t)},e.prototype.supportContext=function(e){return!!this.logicType.supportContext&&this.logicType.supportContext(e)},Object.defineProperty(e.prototype,"isTrigger",{get:function(){return!!this.baseClass&&this.baseClass.indexOf("trigger")>-1},enumerable:!1,configurable:!0}),e}(),Re=function(){function e(){}return e.baseTypes={panel:{showIf:function(e){return e.getAllPanels().length>0},getSelectorChoices:function(e,t){return e.getAllPanels()}},question:{showIf:function(e){return e.getAllQuestions().length>0},supportContext:function(e){return Array.isArray(e.templateElements)||Array.isArray(e.detailElements)&&e.detailElements.length>0},getParentElement:function(e){return e?e.parentQuestion:null},getSelectorChoices:function(e,t){for(var i=new Array,n=e.getAllQuestions(),r=function(e){i.push(e),e.isPanel&&e.elements.forEach((function(e){return r(e)}))},a=0;a<n.length;a++){var s=n[a];t||i.push(s),s instanceof o.QuestionPanelDynamicModel&&(!t||t===s)&&s.templateElements.forEach((function(e){return r(e)})),s instanceof o.QuestionMatrixDropdownModelBase&&(!t||t===s)&&s.detailElements.forEach((function(e){return r(e)}))}return i}},matrixdropdowncolumn:{showIf:function(e){return function(e){for(var t=e.getAllQuestions(),i=0;i<t.length;i++){var n=t[i];if(n instanceof o.QuestionMatrixDropdownModelBase&&n.columns.length>0)return!0}return!1}(e)},supportContext:function(e){return Array.isArray(e.columns)},getParentElement:function(e){return e?e.colOwner:null},getSelectorChoices:function(e,t){for(var i=[],n=e.getAllQuestions(),r=0;r<n.length;r++){var a=n[r];if(a instanceof o.QuestionMatrixDropdownModelBase&&(!t||t===a))for(var s=a.columns,l=0;l<s.length;l++)i.push(s[l])}return i}}},e.types=[{name:"page_visibility",baseClass:"page",propertyName:"visibleIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"page_enable",baseClass:"page",propertyName:"enableIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"page_require",baseClass:"page",propertyName:"requiredIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"panel_visibility",baseClass:"panel",propertyName:"visibleIf"},{name:"panel_enable",baseClass:"panel",propertyName:"enableIf"},{name:"panel_require",baseClass:"panel",propertyName:"requiredIf"},{name:"question_visibility",baseClass:"question",propertyName:"visibleIf"},{name:"question_enable",baseClass:"question",propertyName:"enableIf"},{name:"question_require",baseClass:"question",propertyName:"requiredIf"},{name:"question_resetValue",baseClass:"question",propertyName:"resetValueIf"},{name:"question_setValue",baseClass:"question",propertyName:"setValueIf",getDisplayText:function(e,t,o){return Be(e,t,o)}},{name:"question_setValueExpression",baseClass:"question",propertyName:"setValueExpression",showInUI:!1},{name:"column_visibility",baseClass:"matrixdropdowncolumn",propertyName:"visibleIf"},{name:"column_enable",baseClass:"matrixdropdowncolumn",propertyName:"enableIf"},{name:"column_require",baseClass:"matrixdropdowncolumn",propertyName:"requiredIf"},{name:"column_resetValue",baseClass:"matrixdropdowncolumn",propertyName:"resetValueIf"},{name:"column_setValue",baseClass:"matrixdropdowncolumn",propertyName:"setValueIf",getDisplayText:function(e,t,o){return Be(e,t,o)}},{name:"column_setValueExpression",baseClass:"matrixdropdowncolumn",propertyName:"setValueExpression",showInUI:!1},{name:"expression_expression",baseClass:"expression",propertyName:"expression",showInUI:!1},{name:"matrixdropdowncolumn_totalExpression",baseClass:"matrixdropdowncolumn",propertyName:"totalExpression",showInUI:!1},{name:"trigger_complete",baseClass:"completetrigger",propertyName:"expression",isUniqueItem:!0,isInvisible:!0},{name:"trigger_setvalue",baseClass:"setvaluetrigger",propertyName:"expression",dynamicPropertyName:"setValue",dependedOnPropertyName:"setToName",questionNames:["setToName"],getDisplayText:function(e,t,i){return o.Helpers.isValueEmpty(e.setValue)&&(t=ke("trigger_setvalueEmptyText")),t.format(i.formatElName(e.setToName),e.setValue)}},{name:"trigger_copyvalue",baseClass:"copyvaluetrigger",propertyName:"expression",questionNames:["setToName","fromName"],getDisplayText:function(e,t,o){return t.format(o.formatElName(e.setToName),o.formatElName(e.fromName))}},{name:"trigger_skip",baseClass:"skiptrigger",propertyName:"expression",questionNames:["gotoName"],isUniqueItem:!0,getElementName:function(e){return e.gotoName}},{name:"trigger_runExpression",baseClass:"runexpressiontrigger",propertyName:"expression",questionNames:["setToName"],getDisplayText:function(e,t,o){var i=ke("trigger_runExpressionText1");return i=i.format(o.formatExpression(e.runExpression)),e.setToName&&(i+=ke("trigger_runExpressionText2").format(o.formatElName(e.setToName))),i}},{name:"completedHtmlOnCondition",baseClass:"htmlconditionitem",propertyName:"expression",isUniqueItem:!0,getCollection:function(e){return e.completedHtmlOnCondition}},{name:"trigger_runExpression_Expression",baseClass:"runexpressiontrigger",propertyName:"runExpression",showInUI:!1},{name:"question_expressionValidator",baseClass:"expressionvalidator",propertyName:"expression",showInUI:!1},{name:"matrix_rowsVisibleIf",baseClass:"matrix",propertyName:"rowsVisibleIf",showInUI:!1},{name:"matrix_columnsVisibleIf",baseClass:"matrix",propertyName:"columnsVisibleIf",showInUI:!1},{name:"matrixdropdown_rowsVisibleIf",baseClass:"matrixdropdown",propertyName:"rowsVisibleIf",showInUI:!1},{name:"select_choicesVisibleIf",baseClass:"selectbase",propertyName:"choicesVisibleIf",showInUI:!1},{name:"select_choicesEnableIf",baseClass:"selectbase",propertyName:"choicesEnableIf",showInUI:!1},{name:"itemvalue_visibleIf",baseClass:"itemvalue",propertyName:"visibleIf",showInUI:!1},{name:"itemvalue_enableIf",baseClass:"itemvalue",propertyName:"enableIf",showInUI:!1},{name:"calculatedValue",baseClass:"calculatedvalue",propertyName:"expression",showInUI:!1}],e}();function Be(e,t,o){var i=o.formatElName(e.name),n=e.setValueExpression;return n?t.format(i,n):ke("trigger_setvalueEmptyText").format(i)}var qe=function(){function e(e,t,o){this.surveyValue=o,this.logicTypeValue=e,this.elementValue=t}return Object.defineProperty(e.prototype,"logicType",{get:function(){return this.logicTypeValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"element",{get:function(){return this.elementValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.element&&this.logicType?this.logicType.getParentElement(this.element):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),e.prototype.apply=function(e,t){if(void 0===t&&(t=!1),this.element&&this.logicType&&(this.element[this.logicType.propertyName]=e,!e&&o.Serializer.isDescendantOf(this.element.getType(),"surveytrigger"))){var i=this.survey.triggers.indexOf(this.element);i>-1&&this.survey.triggers.splice(i,1)}},e.prototype.renameQuestion=function(e,t){if(this.element)for(var o=this.questionNames,i=0;i<o.length;i++){var n=this.element[o[i]];n&&n.toLowerCase()==e.toLowerCase()&&(this.element[o[i]]=t)}},e.prototype.clone=function(){var t=this.logicType.cloneElement(this.element);return new e(this.logicType,t,this.survey)},e.prototype.equals=function(e){return this.logicType===e.logicType&&this.logicType.areElementsEqual(this.element,e.element)},Object.defineProperty(e.prototype,"name",{get:function(){return this.logicType?this.logicType.displayName:""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"logicTypeName",{get:function(){return this.logicType?this.logicType.name:void 0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"logicTypeDescription",{get:function(){return this.logicType?this.logicType.description:""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this.logicType?this.logicType.getDisplayText(this.element):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deleteActionText",{get:function(){return ke("deleteAction")},enumerable:!1,configurable:!0}),e.prototype.getLocString=function(e){return G.getString(e)},e.prototype.isSuitableByQuestionName=function(e){var t=this.elementName===e||0===this.elementName.indexOf(e+".");return t||(t=this.questionNamesValues.filter((function(t){return t===e||0===t.indexOf(e+".")})).length>0),t},e.prototype.isSuitableByLogicType=function(e){return!this.logicTypeName||e===this.logicTypeName},e.prototype.addQuestionNames=function(e){var t=this.elementOwnerName;this.elementName&&-1===e.indexOf(t)&&e.push(t),this.questionNamesValues.forEach((function(t){t&&-1===e.indexOf(t)&&e.push(t)}))},Object.defineProperty(e.prototype,"questionNames",{get:function(){return this.logicType&&this.logicType.questionNames?this.logicType.questionNames:[]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"elementName",{get:function(){if(!this.element)return"";var e="",t=this.getOwnerElement();return t&&t!==this.element&&(e=t.name+"."),e+this.element.name||""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"elementOwnerName",{get:function(){var e=this.getOwnerElement();return e&&e.name||""},enumerable:!1,configurable:!0}),e.prototype.getOwnerElement=function(){return this.element?this.parentElement||this.element:null},Object.defineProperty(e.prototype,"questionNamesValues",{get:function(){var e=this;return this.questionNames.map((function(t){return e.element[t]}))},enumerable:!1,configurable:!0}),e}(),He=function(){function e(t,o){void 0===o&&(o=""),this.owner=t,this.expression=o,this.idValue=++e.counter,this.isNew=!1,this.isModified=!1,this.actionsValue=[],this.removedActions=[]}return Object.defineProperty(e.prototype,"actions",{get:function(){return this.actionsValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this.idValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"name",{get:function(){return"logicItem"+this.id},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.owner.survey},enumerable:!1,configurable:!0}),e.prototype.getVisibleLogicTypes=function(){return this.owner.getVisibleLogicTypes()},Object.defineProperty(e.prototype,"expressionText",{get:function(){return this.getExpressionAsDisplayText()||G.getString("ed.lg.itemEmptyExpressionText")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"actionsText",{get:function(){return this.actions.map((function(e){return e.text})).join(", ")},enumerable:!1,configurable:!0}),e.prototype.getDisplayText=function(){var e=this.getExpressionAsDisplayText(),t="";return this.actions.forEach((function(e){t+=", "+e.text})),e&&t?(this.ifText+" "+e+t).replace(new RegExp("({|})","gm"),"'"):G.getString("ed.lg.itemEmptyExpressionText")},e.prototype.edit=function(){this.owner&&this.owner.editItem(this)},e.prototype.remove=function(){this.owner&&this.owner.removeItem(this)},Object.defineProperty(e.prototype,"isReadOnly",{get:function(){return!!this.owner&&this.owner.readOnly},enumerable:!1,configurable:!0}),e.prototype.addNewAction=function(e){this.actions.push(e)},e.prototype.removeAction=function(e){this.replaceActionCore(null,e)},e.prototype.replaceAction=function(e,t){t?this.replaceActionCore(e,t):this.addNewAction(e)},e.prototype.clone=function(){for(var t=new e(this.owner,this.expression),o=0;o<this.actions.length;o++)t.addNewAction(this.actions[o].clone());return t},e.prototype.equals=function(e){if(this.expression!==e.expression)return!1;if(this.actions.length!==e.actions.length)return!1;for(var t=0;t<this.actions.length;t++)if(!this.actions[t].equals(e.actions[t]))return!1;return!0},e.prototype.replaceActionCore=function(e,t){this.removedActions.push(t);var o=this.actions.indexOf(t);o>-1&&(e?this.actions.splice(o,1,e):this.actions.splice(o,1))},e.prototype.apply=function(e){e?this.removeSameActions():this.removeActions();for(var t=0;t<this.removedActions.length;t++)this.removedActions[t].apply("");this.removedActions=[],this.applyExpression(e,!1)},e.prototype.renameQuestion=function(e,t){var o=this;if(e&&t&&e!==t){["","panel.","row."].forEach((function(n){return o.renameQuestionInExpression(n+e,n+t,[i.logic.closeBracket,".","["])}));for(var n=this.actions,r=0;r<n.length;r++)n[r].renameQuestion(e,t)}},e.prototype.renameColumn=function(e,t,n){if(this.canUpdateExpressionByQuestion(e)){this.actions[0].parentElement===e&&this.renameQuestionInExpression("row."+n,"row."+t.name,[i.logic.closeBracket]);var r=e.rows;if(Array.isArray(r)&&this.isQuestionInExpression(e))for(var a=this.getItemValueQuestionName(e)+".",s=0;s<r.length;s++)if(!o.Helpers.isValueEmpty(r[s].value)){var l=r[s].value.toString()+".";this.renameQuestionInExpression(a+l+n,a+l+t.name,[i.logic.closeBracket])}}},e.prototype.renameItemValue=function(e,t,i){if(this.canUpdateExpressionByQuestion(e)&&(!e.parentQuestion||(Array.isArray(e.parentQuestion.rows)&&this.renameDropdownColumnItemValue(e,t,i),this.actions[0].parentElement===e.parentQuestion))&&this.isQuestionInExpression(e)){var n=this.getItemValueQuestionName(e).toLocaleLowerCase(),r=e.rows,a=this.expression;if(Array.isArray(r))for(var s=0;s<r.length;s++)o.Helpers.isValueEmpty(r[s].value)||(a=De(a,n+"."+r[s].value.toString(),i,t.value));else a=De(a,n,i,t.value);a!=this.expression&&this.applyExpression(a,!0)}},e.prototype.renameDropdownColumnItemValue=function(e,t,n){var r=e.parentQuestion;if(this.isQuestionInExpression(r)){var a="."+e.getValueName();if(this.isStrContainsInExpression(a+i.logic.closeBracket)){for(var s=r.getValueName()+".",l=r.rows,u=this.expression,p=0;p<l.length;p++)o.Helpers.isValueEmpty(l[p].value)||(u=De(u,s+l[p].value.toString()+a,n,t.value));u!=this.expression&&this.applyExpression(u,!0)}}},e.prototype.renameRowValue=function(e,t,o){if(this.canUpdateExpressionByQuestion(e)&&this.isQuestionInExpression(e)){var n=this.getItemValueQuestionName(e);this.renameQuestionInExpression(n+"."+o.toString(),n+"."+t.value.toString(),[i.logic.closeBracket,"."])}},e.prototype.canUpdateExpressionByQuestion=function(e){return!!this.expression&&!!e.name&&this.actions.length>0},e.prototype.isQuestionInExpression=function(e){return this.isStrContainsInExpression(this.getItemValueQuestionName(e).toLocaleLowerCase())},e.prototype.isStrContainsInExpression=function(e){return!!e&&this.expression.toLocaleLowerCase().indexOf(e.toLocaleLowerCase())>-1},e.prototype.getItemValueQuestionName=function(e){var t=e.getValueName();if(e.parentQuestion){if(e.parentQuestion.isDescendantOf("paneldynamic"))return"panel."+t;if(e.parentQuestion.isDescendantOf("matrixdropdownbase"))return"row."+t}return t},e.prototype.removeQuestion=function(e){this.removeQuestionInExpression(e)},e.prototype.getQuestionNames=function(){var e=[];return this.getQuestionNamesFromExpression(e),this.getQuestionNamesFromActions(e),e},e.prototype.getActionTypes=function(){return this.actions.map((function(e){return e.logicTypeName}))},e.prototype.getContext=function(){var e=this.expression;if(!e)return null;if(!ee.getQuestionContextIndexInfo(e,"{"))return null;for(var t=0;t<this.actions.length;t++){var o=this.actions[t].parentElement;if(o)return o}return null},e.prototype.getQuestionNamesFromExpression=function(e){new o.ConditionRunner(this.expression).getVariables().forEach((function(t){-1===e.indexOf(t)&&e.push(t)}))},e.prototype.getQuestionNamesFromActions=function(e){this.actions.forEach((function(t){return t.addQuestionNames(e)}))},e.prototype.getExpressionAsDisplayText=function(){return this.owner?this.owner.getExpressionAsDisplayText(this.expression):this.expression},Object.defineProperty(e.prototype,"editText",{get:function(){return G.getString("pe.edit")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deleteText",{get:function(){return G.getString("pe.delete")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ifText",{get:function(){return G.getString("pe.if")},enumerable:!1,configurable:!0}),e.prototype.isSuitable=function(e,t){return void 0===t&&(t=""),!e&&!t||(e?t?(this.isSuitableInExpression(e)||this.isSuitableByNameInActions(e))&&this.isSuitableByLogicTypeInActions(t):this.isSuitableInExpression(e)||this.isSuitableByNameInActions(e):this.isSuitableByLogicTypeInActions(t))},e.prototype.isSuitableInExpression=function(e){return-1!==this.expression.indexOf(E(e))||-1!==this.expression.indexOf("'"+e+".")},e.prototype.isSuitableByNameInActions=function(e){return this.actions.some((function(t){return t.isSuitableByQuestionName(e)}))},e.prototype.isSuitableByLogicTypeInActions=function(e){return this.actions.some((function(t){return t.isSuitableByLogicType(e)}))},e.prototype.renameQuestionInExpression=function(e,t,o){var n=this;if(this.expression&&(e=e.toLowerCase(),this.isStrContainsInExpression(e))){var r=i.logic.openBracket;e=r+e,t=r+t;var a=this.expression;o.forEach((function(o){a=n.renameQuestionInExpressionCore(a,a.toLocaleLowerCase(),e+o,t+o)})),a!=this.expression&&this.applyExpression(a,!0)}},e.prototype.renameQuestionInExpressionCore=function(e,t,o,i){for(var n=t.lastIndexOf(o,t.length);n>-1;)e=e.substring(0,n)+i+e.substring(n+o.length),n=(t=t.substring(0,n)).lastIndexOf(o,n);return e},e.prototype.removeQuestionInExpression=function(e){if(this.expression){var t=(new _e).remove(this.expression,e);t!=this.expression&&this.applyExpression(t,!0)}},e.prototype.applyExpression=function(e,t){this.expression=e;for(var o=this.actions,i=0;i<o.length;i++)o[i].apply(e,t)},e.prototype.removeActions=function(){for(var e=this.actions,t=e.length-1;t>=0;t--)this.removeAction(e[t])},e.prototype.removeSameActions=function(){for(var e=this.actions,t=e.length-1;t>=0;t--)for(var o=t-1;o>=0;o--)if(e[t].equals(e[o])){this.removeAction(e[t]);break}},e.counter=0,e}();function Qe(e){e.popupModel.isFocusedContent=!0,e.popupModel.setWidthByTarget=!1,e.popupModel.positionMode="flex",e.popupModel.showPointer=!0,e.dropdownListModel.listModel.searchEnabled=e.searchEnabled}n(5377);var Fe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.EventBase),Ue=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this)||this;return i.survey=t,i.options=o,i.invisibleItems=[],i.onLogicItemSaved=new Fe,i.onLogicItemValidation=new Fe,i.onLogicItemRemoving=new Fe,i.onLogicItemRemoved=new Fe,i.options||(i.options=new a),i.readOnly=i.optionsReadOnly,i.update(),i}return K(t,e),Object.defineProperty(t,"visibleActions",{get:function(){return i.logic.visibleActions},set:function(e){i.logic.visibleActions=e},enumerable:!1,configurable:!0}),Object.defineProperty(t,"types",{get:function(){return Re.types},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.onEndEditing(),this.survey=void 0},Object.defineProperty(t.prototype,"editableItem",{get:function(){return this.editableItemValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"mode",{get:function(){return this.modeValue},set:function(e){if(this.modeValue!==e){var t=this.mode;this.modeValue=e,this.errorText="","view"!=e||"edit"!=t&&"new"!=t||this.onEndEditing()}},enumerable:!1,configurable:!0}),t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.getTypeByName=function(e){for(var t=0;t<this.logicTypes.length;t++)if(this.logicTypes[t].name==e)return this.logicTypes[t];return null},t.prototype.update=function(e,t){void 0===e&&(e=null),void 0===t&&(t=null),e&&(this.survey=e),t&&(this.options=t),this.logicTypes=this.createLogicTypes(),this.updateVisibleItems(),this.invisibleItems=this.buildItems(!1),this.readOnly=this.optionsReadOnly,this.mode="view"},t.prototype.updateVisibleItems=function(){this.items=this.buildItems(!0),this.editableItemValue=null},Object.defineProperty(t.prototype,"optionsReadOnly",{get:function(){return!!this.options&&this.options.readOnly},enumerable:!1,configurable:!0}),t.prototype.saveEditableItem=function(){if(!this.editableItem||this.hasError())return!1;this.options&&this.options.startUndoRedoTransaction(),this.onEditableItemApply();var e=this.items.indexOf(this.editableItem)<0;e&&this.items.push(this.editableItem);var t=!e||this.editableItem.isNew;return this.editableItem.isNew=!1,this.onItemChanged(this.editableItem,t?"new":"modify"),this.options&&this.options.stopUndoRedoTransaction(),this.onLogicItemSaved.fire(this,{item:this.editableItem}),!0},t.prototype.saveEditableItemAndBack=function(){var e=this.saveEditableItem();return e&&(this.mode="view"),e},t.prototype.onEditableItemApply=function(){},t.prototype.onItemChanged=function(e,t){this.onChangedCallback&&this.onChangedCallback(e,t)},t.prototype.renameQuestion=function(e,t){this.items.forEach((function(o){return o.renameQuestion(e,t)})),this.invisibleItems.forEach((function(o){return o.renameQuestion(e,t)}))},t.prototype.renameItemValue=function(e,t){var o=this.getItemValueQuestion(e,t);o&&(this.items.forEach((function(i){return i.renameItemValue(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameItemValue(o,e,t)})))},t.prototype.renameRowValue=function(e,t){var o=this.getItemValueQuestion(e,t);o&&(this.items.forEach((function(i){return i.renameRowValue(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameRowValue(o,e,t)})))},t.prototype.renameColumn=function(e,t){var o=e.colOwner;o&&o.isQuestion&&(this.items.forEach((function(i){return i.renameColumn(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameColumn(o,e,t)})))},t.prototype.getItemValueQuestion=function(e,t){if(!e.locOwner||o.Helpers.isValueEmpty(t)||o.Helpers.isValueEmpty(e.value))return null;var i=e.locOwner;return i.isQuestion?i:null},t.prototype.removeQuestion=function(e){this.removeQuestionCore(e,this.items),this.removeQuestionCore(e,this.invisibleItems)},t.prototype.hasError=function(){if(!this.editableItem)return!1;if(this.hasErrorInUI())return!0;var e=new o.ExpressionRunner(this.getExpressionText()),t={item:this.editableItem,error:"",usedNamesInExpression:e.getVariables(),actions:this.getEditingActions()};this.onLogicItemValidation.fire(this,t),this.errorText=t.error;var i=this.survey.creator;return this.errorText&&i&&i.notify(this.errorText,"error"),!!this.errorText},t.prototype.getUsedQuestions=function(){var e=this,t={};this.items.forEach((function(o){o.getQuestionNames().forEach((function(o){var i=e.survey.getQuestionByName(o);i&&!t[o]&&(t[o]=i)}))}));var o=[];return Object.keys(t).forEach((function(e){t[e]&&o.push(t[e])})),o},t.prototype.getUsedActionTypes=function(){var e=this,t={};this.items.forEach((function(o){o.getActionTypes().forEach((function(o){t[o]||(t[o]=e.logicTypes.filter((function(e){return e.name==o}))[0])}))}));var o=[];return Object.keys(t).forEach((function(e){t[e]&&o.push(t[e])})),o},t.prototype.hasErrorInUI=function(){return!1},t.prototype.getExpressionText=function(){return""},t.prototype.getEditingActions=function(){return[]},t.prototype.onReadOnlyChanged=function(){},t.prototype.removeQuestionCore=function(e,t){for(var o=0;o<t.length;o++)t[o].removeQuestion(e)},t.prototype.addNew=function(){this.options&&this.options.startUndoRedoTransaction();var e=new He(this);e.isNew=!0,this.items.push(e),this.editItemCore(e),this.options&&this.options.stopUndoRedoTransaction()},t.prototype.editItem=function(e){this.options&&this.options.startUndoRedoTransaction(),this.editItemCore(e),this.options&&this.options.stopUndoRedoTransaction()},t.prototype.editItemCore=function(e){this.editableItemValue=e,this.onStartEditing(),this.mode=e.isNew?"new":"edit"},t.prototype.onStartEditing=function(){},t.prototype.onEndEditing=function(){this.editableItemValue=null},t.prototype.canRemoveItem=function(e){var t={item:e,allowRemove:!0};return this.onLogicItemRemoving.fire(this,t),t.allowRemove},t.prototype.removeItem=function(e,t){if(void 0===t&&(t=!0),!t||this.canRemoveItem(e)){this.options&&this.options.startUndoRedoTransaction(),e.apply("");var o=this.items.indexOf(e);o>-1&&this.items.splice(o,1),this.onItemChanged(e,"delete"),this.options&&this.options.stopUndoRedoTransaction(),this.onLogicItemRemoved.fire(this,{item:e})}},t.prototype.addAction=function(e,t){void 0===t&&(t=null);var o=this.createNewAction(e,t);return this.editableItem.addNewAction(o),o},t.prototype.addNewAction=function(){return this.addAction(null,null)},t.prototype.createNewAction=function(e,t){return new qe(e,t,this.survey)},t.prototype.getVisibleLogicTypes=function(){for(var e=[],t=this.logicTypes,o=0;o<t.length;o++)t[o].visible&&e.push(t[o]);return e},t.prototype.removeAction=function(e){this.editableItem&&(this.editableItem.removeAction(e),0==this.editableItem.actions.length&&this.addNewAction())},t.prototype.getExpressionAsDisplayText=function(e){return je.expressionToDisplayText(this.survey,this.options,e)},t.prototype.buildItems=function(e){for(var t=[],o={},i=this.getAllElements(),n=0;n<i.length;n++)this.buildItemsByElement(i[n],t,o,e);return t},t.prototype.getAllElements=function(){var e=[];return this.AddElements(this.survey.pages,e),this.AddElements(Re.baseTypes.question.getSelectorChoices(this.survey,null),e),this.AddElements(this.survey.getAllPanels(),e),this.AddElements(this.survey.triggers,e),this.AddElements(this.survey.completedHtmlOnCondition,e),this.AddElements(this.survey.calculatedValues,e),this.AddElements(Re.baseTypes.matrixdropdowncolumn.getSelectorChoices(this.survey,null),e),this.AddElements(this.getValidators(),e),this.AddElements(this.getItemValues(),e),e},t.prototype.getValidators=function(){for(var e=[],t=this.survey.getAllQuestions(),o=0;o<t.length;o++)this.AddElements(t[o].validators,e);return e},t.prototype.getItemValues=function(){for(var e=[],t=this.survey.getAllQuestions(),i=0;i<t.length;i++){var n=t[i],r=n.choices;if(r){var a=o.Serializer.findProperty(n.getType(),"choices");a&&"itemvalue[]"===a.type&&this.AddElements(r,e)}}return e},t.prototype.AddElements=function(e,t){for(var o=0;o<e.length;o++)t.push(e[o])},t.prototype.buildItemsByElement=function(e,t,i,n){for(var r=this.getElementAllTypes(e),a=0;a<this.logicTypes.length;a++){var s=this.logicTypes[a];if(s.showInUI===n){var l=e[s.propertyName];if(r.indexOf(s.baseClass)>-1&&!o.Helpers.isValueEmpty(l)){var u=this.getLogicItemHashKey(l,e),p=i[u];p||(p=new He(this,l),i[u]=p,t.push(p));var c=this.createNewAction(s,e);p.addNewAction(c)}}}},t.prototype.getLogicItemHashKey=function(e,t){var o=this.getParentQuestion(t);return(o?"@"+o.name:"")+e.replace(" ","").toLowerCase()},t.prototype.getParentQuestion=function(e){return e.parentQuestion||(e.isDescendantOf("matrixdropdowncolumn")?e.colOwner:null)},t.prototype.getElementAllTypes=function(e){var t=[],i=e.getType();for(t.push(i);i&&"base"!=i;){var n=o.Serializer.findClass(i);if(!n)break;(i=n.parentName)&&t.push(i)}return t},t.prototype.createLogicTypes=function(){for(var e=[],o=t.visibleActions,i=0;i<t.types.length;i++)o.length>0&&o.indexOf(t.types[i].name)<0||e.push(new je(t.types[i],this.survey,this.options));return e},J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.propertyArray)()],t.prototype,"logicTypes",void 0),J([(0,o.property)()],t.prototype,"errorText",void 0),J([(0,o.property)({onSet:function(e,t){t.onReadOnlyChanged()}})],t.prototype,"readOnly",void 0),J([(0,o.property)()],t.prototype,"placeholderHtml",void 0),t}(o.Base),Ge=n(4809),Ze=function(){function e(e){this.objValue=e,this.editableObjValue=this.createEditableObj()}return e.isCopyObject=function(e){return!!e&&e.isCopy},e.getSurvey=function(t){if(t instanceof o.SurveyModel||t&&t.getType&&"survey"==t.getType())return e.getOriginalSurvey(t);if(t instanceof o.MatrixDropdownColumn&&t.colOwner)return t.colOwner.survey;if(t){if(t.survey)return e.getOriginalSurvey(t.survey);if(t.owner)return e.getSurvey(t.owner);if(t.errorOwner)return e.getSurvey(t.errorOwner);if(t.locOwner)return e.getSurvey(t.locOwner)}var i=e.getOriginalObject(t);return i&&i!==t?e.getSurvey(i):null},e.getOriginalObject=function(e){return e&&e.originalObj?e.originalObj:e},e.getOriginalSurvey=function(t){return e.getOriginalObject(t)},Object.defineProperty(e.prototype,"obj",{get:function(){return this.objValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"editableObj",{get:function(){return this.editableObjValue},enumerable:!1,configurable:!0}),e.prototype.isPropertyChanged=function(e){return"pages"!=e&&!o.Helpers.isTwoValueEquals(this.obj[e],this.editableObj[e])},e.prototype.apply=function(e){this.isPropertyChanged(e)&&(this.obj[e]=this.editableObj[e])},e.prototype.reset=function(){this.assignProperties(this.editableObj)},e.prototype.applyAll=function(e){void 0===e&&(e=[]);for(var t=this.getProperties(e),o=0;o<t.length;o++)this.apply(t[o])},e.prototype.getProperties=function(e){var t=[],o=this.getObjJson(this.editableObj),i=this.getObjJson(this.obj);for(var n in o)e.indexOf(n)>-1||t.push(n);for(var n in i)e.indexOf(n)>-1||t.indexOf(n)>-1||t.push(n);return t},e.prototype.createEditableObj=function(){var e=this.obj.getType(),t=o.Serializer.createClass(e);return null==t&&"survey"==e&&(t=new o.SurveyModel),this.assignProperties(t),"matrixdropdowncolumn"==e&&(t.colOwner=this.obj.colOwner),"survey"!=e&&(t.setSurveyImpl?t.setSurveyImpl(this.obj.survey):this.obj.survey&&!t.survey&&(t.survey=this.obj.survey)),this.obj.parent&&(t.parent=this.obj.parent),t.isCopy=!0,t.originalObj=this.obj,t},e.prototype.assignProperties=function(e){(new o.JsonObject).toObject(this.getObjJson(),e)},e.prototype.getObjJson=function(e){void 0===e&&(e=null),e||(e=this.obj);var t=new o.JsonObject;return t.lightSerializing=!0,t.toJsonObject(e)},e}(),ze={root:"spg-root-modern",container:"spg-container-modern",header:"spg-title spg-container-modern__title",body:"spg-body",bodyEmpty:"spg-body spg-body--empty",footer:"spg-footer spg-body__footer spg-clearfix",title:"",description:"",logo:"spg-logo",logoImage:"spg-logo__image",headerText:"spg-header__text",navigationButton:"",completedPage:"spg-completedpage",navigation:{complete:"spg-btn spg-footer__complete-btn",prev:"spg-btn spg-footer__prev-btn",next:"spg-btn spg-footer__next-btn",start:"spg-btn spg-footer__start-btn",preview:"spg-btn spg-footer__preview-btn",edit:"spg-btn spg-footer__edit-btn"},panel:{expandableAnimating:"",title:"spg-title spg-panel__title",contentEnter:"spg-panel__content--enter",contentLeave:"spg-panel__content--leave",titleExpandable:"spg-panel__title--expandable",titleExpanded:"spg-panel__title--expanded",titleCollapsed:"spg-panel__title--collapsed",titleOnError:"spg-panel__title--error",description:"spg-description spg-panel__description",container:"spg-panel spg-row__panel",content:"spg-panel__content",icon:"spg-panel__icon",iconExpanded:"spg-panel__icon--expanded",footer:"spg-panel__footer",requiredText:"spg-panel__required-text"},paneldynamic:{mainRoot:"spg-question spg-row__question",root:"spg-paneldynamic",navigation:"spg-paneldynamic__navigation",title:"spg-title spg-question__title",button:"spg-action-button spg-action-button--text",buttonRemove:"spg-action-button--danger",buttonAdd:"spg-paneldynamic__add-btn",panelsContainer:"",panelWrapper:"spg-paneldynamic__panel-wrapper",panelWrapperList:"",progressTop:"spg-paneldynamic__progress spg-paneldynamic__progress--top",progressBottom:"spg-paneldynamic__progress spg-paneldynamic__progress--bottom",buttonPrev:"spg-paneldynamic__prev-btn",buttonNext:"spg-paneldynamic__next-btn",progressContainer:"spg-paneldynamic__progress-container",progress:"spg-progress",progressBar:"spg-progress__bar",progressText:"spg-paneldynamic__progress-text",panelFooter:"spg-panel__footer",separator:"spg-paneldynamic__separator"},progress:"spg-progress spg-body__progress",progressBar:"spg-progress__bar",progressText:"spg-progress__text",progressTextInBar:"spg-hidden",page:{root:"spg-page spg-body__page",title:"spg-title spg-page__title",description:"spg-description spg-page__description"},pageTitle:"spg-title spg-page__title",pageDescription:"spg-description spg-page__description",row:"spg-row spg-clearfix",rowEnter:"spg-row--enter",rowLeave:"spg-row--leave",rowDelayedEnter:"spg-row--delayed-fade-in",rowMultiple:"spg-row--multiple",question:{mainRoot:"spg-question spg-row__question",flowRoot:"spg-question spg-row__question spg-row__question--flow",asCell:"spg-table__cell",header:"spg-question__header",headerLeft:"spg-question__header--location--left",headerTop:"spg-question__header--location--top",headerBottom:"spg-question__header--location--bottom",content:"spg-question__content",contentLeft:"spg-question__content--left",titleLeftRoot:"spg-question--location--left",titleOnAnswer:"spg-question__title--answer",titleOnError:"spg-question__title--error",title:"spg-title spg-question__title",requiredText:"spg-question__required-text",number:"spg-question__num",description:"spg-description spg-question__description",descriptionUnderInput:"spg-description spg-question__description",comment:"spg-comment",required:"spg-question--required",titleRequired:"spg-question__title--required",indent:0,footer:"spg-question__footer",formGroup:"spg-question__form-group",hasError:"",disabled:"spg-question--disabled"},image:{root:"spg-image",image:"sv_image_image"},error:{root:"spg-question__erbox",icon:"spg-question__erbox-icon",item:"",locationTop:"spg-question__erbox--location--top",locationBottom:"spg-question__erbox--location--bottom"},checkbox:{root:"spg-selectbase",item:"spg-item spg-checkbox spg-selectbase__item",itemSelectAll:"spg-checkbox--selectall",itemNone:"spg-checkbox--none",itemDisabled:"spg-item--disabled spg-checkbox--disabled",itemChecked:"spg-checkbox--checked",itemHover:"spg-checkbox--allowhover",itemInline:"spg-selectbase__item--inline",label:"spg-selectbase__label",itemSvgIconId:"#icon-v2check",labelChecked:"",itemControl:"spg-checkbox__control",itemDecorator:"spg-checkbox__svg",controlLabel:"spg-checkbox__caption",materialDecorator:"spg-checkbox__rectangle",other:"spg-comment spg-question__other",column:"spg-selectbase__column"},radiogroup:{root:"spg-selectbase",item:"spg-item spg-radio spg-selectbase__item",itemInline:"spg-selectbase__item--inline",label:"spg-selectbase__label",labelChecked:"",itemDisabled:"spg-item--disabled spg-radio--disabled",itemChecked:"spg-radio--checked",itemHover:"spg-radio--allowhover",itemControl:"spg-visuallyhidden spg-item__control",itemDecorator:"spg-item__svg spg-radio__svg",controlLabel:"spg-item__control-label",materialDecorator:"spg-item__decorator spg-radio__decorator",other:"spg-comment spg-question__other",clearButton:"spg-btn spg-selectbase__clear-btn",column:"spg-selectbase__column"},boolean:{mainRoot:"spg-question spg-row__question spg-question--boolean",rootCheckbox:"spg-selectbase",checkboxItem:"spg-checkbox",checkboxItemChecked:"spg-checkbox--checked",checkboxitemIndeterminate:"spg-checkbox--indeterminate",checkboxItemDisabled:"spg-checkbox--disabled",svgIconId:"#icon-v2check",checkboxLabel:"spg-selectbase__label",controlCheckbox:"spg-checkbox__control",checkboxControlLabel:"spg-checkbox__caption",checkboxItemDecorator:"spg-checkbox__svg",checkboxMaterialDecorator:"spg-checkbox__rectangle"},text:{root:"spg-input spg-text",small:"spg-row__question--small",content:"spg-question__content spg-text__content",remainingCharacterCounter:"spg-remaining-character-counter",onError:"spg-input--error"},multipletext:{root:"spg-multipletext",item:"spg-multipletext__item",itemTitle:"spg-multipletext__item-title",content:"spg-multipletext__content spg-text__content",row:"spg-multipletext__row",cell:"spg-multipletext__cell"},dropdown:{root:"",popup:"spg-dropdown-popup svc-creator-popup",small:"spg-row__question--small sd-row__question--small",control:"spg-input spg-dropdown sd-input sd-dropdown",filterStringInput:"sd-dropdown__filter-string-input spg-dropdown__filter-string-input",other:"spg-comment spg-question__other",onError:"spg-input--error",selectWrapper:"sv-dropdown_select-wrapper spg-dropdown_select-wrapper",chevronButton:"sd-dropdown_chevron-button spg-dropdown_chevron-button",chevronButtonSvg:"sd-dropdown_chevron-button-svg",chevronButtonIconId:"icon-chevron"},imagepicker:{root:"spg-imagepicker",item:"spg-imagepicker__item",itemInline:"spg-imagepicker__item--inline",itemChecked:"spg-imagepicker__item--checked",itemDisabled:"spg-imagepicker__item--disabled",itemHover:"spg-imagepicker__item--allowhover",label:"spg-imagepicker__label",itemControl:"spg-imagepicker__control",image:"spg-imagepicker__image",itemText:"spg-imagepicker__text",clearButton:"spg-btn",other:"spg-comment spg-question__other"},matrix:{tableWrapper:"spg-matrix spg-table-wrapper",root:"spg-table",rowError:"spg-matrix__row--error",cell:"spg-table__cell spg-matrix__cell",headerCell:"spg-table__cell spg-table__cell--header",label:"spg-item spg-radio spg-matrix__label",itemValue:"spg-visuallyhidden spg-item__control spg-radio__control",itemChecked:"spg-radio--checked",itemDisabled:"spg-item--disabled spg-radio--disabled",itemHover:"spg-radio--allowhover",materialDecorator:"spg-item__decorator spg-radio__decorator",itemDecorator:"spg-item__svg spg-radio__svg",cellText:"spg-matrix__text",cellTextSelected:"spg-matrix__text--checked",cellTextDisabled:"spg-matrix__text--disabled"},matrixdropdown:{tableWrapper:"spg-table-wrapper",root:"spg-table",cell:"spg-table__cell",headerCell:"spg-table__cell spg-table__cell--header",emptyCell:"spg-table__cell--empty",rowEnter:"spg-table__row--enter",rowLeave:"spg-table__row--leave"},matrixdynamic:{tableWrapper:"spg-table-wrapper",root:"spg-table spg-matrixdynamic",content:"spg-matrixdynamic__content spg-text__content",cell:"spg-table__cell",headerCell:"spg-table__cell spg-table__cell--header",button:"spg-btn",detailRow:"spg-table__row spg-table__row--detail",detailButton:"spg-table__cell--detail-button",detailButtonExpanded:"spg-table__cell--detail-button--expanded",detailIcon:"spg-detail-panel__icon",detailIconExpanded:"spg-detail-panel__icon--expanded",detailPanelCell:"spg-table__cell--detail-panel",actionsCell:"spg-table__cell spg-table__cell--actions",buttonAdd:"spg-matrixdynamic__add-btn spg-action-button spg-action-button--large",buttonRemove:"spg-matrixdynamic__remove-btn",iconAdd:"",iconRemove:"",dragElementDecorator:"spg-drag-element__svg",iconDragElement:"#icon-drag-area-indicator",iconDrag:"spg-matrixdynamic__drag-element",footer:"",dragDropGhostPositionTop:"spg-matrixdynamic__drag-drop-ghost-position-top",dragDropGhostPositionBottom:"spg-matrixdynamic__drag-drop-ghost-position-bottom",emptyRowsSection:"spg-matrixdynamic__placeholder",emptyRowsText:"spg-matrixdynamic__placeholder-text",cellQuestionWrapper:"spg-table__question-wrapper",emptyCell:"spg-table__cell--empty",rowEnter:"spg-table__row--enter",rowLeave:"spg-table__row--leave"},rating:{root:"spg-rating",item:"spg-rating__item",selected:"spg-rating__item--selected",minText:"spg-rating__min-text",itemText:"spg-rating__item-text",maxText:"spg-rating__max-text",disabled:"spg-rating--disabled"},comment:{root:"spg-input spg-comment",content:"spg-question__content spg-comment__content",remainingCharacterCounter:"spg-remaining-character-counter",small:"spg-row__question--small",onError:"spg-input--error"},expression:"",file:{root:"spg-file",other:"spg-comment spg-question__other",placeholderInput:"spg-visuallyhidden",preview:"spg-file__preview",fileSign:"spg-hidden",fileSignBottom:"spg-file__sign",fileDecorator:"spg-file__decorator",fileInput:"spg-visuallyhidden",noFileChosen:"spg-description spg-file__no-file-chosen",chooseFile:"spg-btn spg-file__choose-btn",disabled:"spg-file__choose-btn--disabled",removeButton:"spg-hidden",removeButtonBottom:"spg-btn spg-file__clean-btn",removeFile:"spg-hidden",removeFileSvg:"spg-file__remove-svg",wrapper:"spg-file__wrapper"},signaturepad:{root:"spg-signaturepad sjs_sp_container",small:"spg-row__question--small",controls:"sjs_sp_controls",clearButton:"sjs_sp_clear"},propertygrid_bindings:{content:"spg-question__content spg-question__nopadding spg-question-group"},propertygrid_restfull:{content:"spg-question__content spg-question__nopadding spg-restfull"},propertygrid_masksettings:{content:"spg-question__content spg-question__nopadding spg-masksettings"},propertygrid_header:{mainRoot:"spg-header",content:"spg-question__content spg-question__nopadding"},coloralpha:{content:"spg-question__content spg-question__nopadding spg-question__content-coloralpha"},font:{content:"spg-question__content spg-question__nopadding spg-question-composite__content"},backgroundcornerradius:{content:"spg-question__content spg-question__nopadding spg-question-composite__content"},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"sv_window",body:"sv_window_content",header:{root:"sv_window_title",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}},actionBar:{root:"spg-action-bar",item:"spg-action-button",itemPressed:"spg-action-button--pressed",itemAsIcon:"spg-action-button--icon",itemIcon:"spg-action-button__icon",itemTitle:"spg-action-button__title"},spinedit:{root:"spg-input spg-spin-editor spg-input-container",control:"spg-spin-editor__input spg-input-container__input",buttonsContainer:"spg-input-container__buttons-container",arrowButton:"spg-input__edit-button",increaseButtonIcon:"icon-arrow-up",decreaseButtonIcon:"icon-arrow-down"},color:{root:"spg-input spg-color-editor spg-input-container",swatch:"spg-color-editor__color-swatch",swatchDefault:"spg-color-editor__color-swatch--default",swatchDisabled:"spg-color-editor__color-swatch--disabled",colorInput:"spg-color-editor__color-input",control:"spg-color-editor__input spg-input-container__input",colorDropdown:"spg-input__edit-button",colorDropdownIcon:"icon-drop-down-arrow",colorItem:"spg-color-editor__color-item",swatchIcon:"icon-color-picker"},textwithreset:{root:"spg-input spg-input-container",rootMultiline:"spg-input-container--multiline",control:"spg-input-container__input",controlMultiline:"spg-input-container__input spg-comment",resetButton:"spg-input__edit-button",resetButtonIcon:"icon-reset",content:"spg-question__content spg-text__content",remainingCharacterCounter:"spg-remaining-character-counter",onError:"spg-input--error"},fileedit:{root:"spg-input spg-input-container spg-file-edit",control:"spg-input-container__input",buttonsContainer:"spg-input-container__buttons-container",chooseButtonIcon:"icon-file",clearButtonIcon:"icon-clear",fileInput:"sd-visuallyhidden",clearButton:"spg-input__edit-button",chooseButton:"spg-input__edit-button spg-file-edit__choose-button",chooseButtonDisabled:"spg-input__edit-button--disabled"},linkvalue:{content:"spg-link"}},Je={question:{properties:["name","title","description","visible","readOnly","isRequired","showCommentArea","commentText","commentPlaceholder",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"bindings",tab:"logic"},{name:"defaultValueExpression",tab:"logic"},{name:"resetValueIf",tab:"logic"},{name:"setValueIf",tab:"logic"},{name:"setValueExpression",tab:"logic"},{name:"page",tab:"layout"},{name:"startWithNewLine",tab:"layout"},{name:"hideNumber",tab:"layout"},{name:"state",tab:"layout"},{name:"titleLocation",tab:"layout"},{name:"descriptionLocation",tab:"layout"},{name:"errorLocation",tab:"layout"},{name:"indent",tab:"layout"},{name:"width",tab:"layout"},{name:"minWidth",tab:"layout"},{name:"maxWidth",tab:"layout"},{name:"effectiveColSpan",tab:"layout"},{name:"valueName",tab:"data"},{name:"defaultValue",tab:"data"},{name:"correctAnswer",tab:"data"},{name:"useDisplayValuesInDynamicTexts",tab:"data"},{name:"clearIfInvisible",tab:"data"},{name:"validators",tab:"validation"},{name:"requiredErrorText",tab:"validation"}],tabs:[{name:"layout",index:100},{name:"logic",index:200},{name:"data",index:300},{name:"validation",index:400}]},comment:{properties:[{name:"rows",tab:"layout"},{name:"cols",tab:"layout"},"placeholder",{name:"maxLength",tab:"validation"},{name:"textUpdateMode",tab:"data"},{name:"autoGrow",tab:"layout"},{name:"allowResize",tab:"layout"}]},file:{properties:["sourceType","visible","readOnly","isRequired","showCommentArea","allowMultiple",{name:"showPreview"},"allowImagesPreview","waitForUpload","needConfirmRemoveFile",{name:"storeDataAsText"},"allowCameraAccess","acceptedTypes","maxSize","imageHeight","imageWidth","filePlaceholder","photoPlaceholder","fileOrPhotoPlaceholder"]},signaturepad:{properties:["dataFormat","signatureWidth","signatureHeight","signatureAutoScaleEnabled","showPlaceholder","placeholder","placeholderReadOnly","allowClear","backgroundImage","backgroundColor","penMinWidth","penMaxWidth","penColor","waitForUpload",{name:"storeDataAsText"}]},html:{properties:["html"]},matrixdropdownbase:{properties:["cellType","optionsCaption","detailPanelMode","detailPanelShowOnAdding",{name:"showHeader",tab:"layout"},{name:"showColumnHeader",tab:"layout"},{name:"verticalAlign",tab:"layout"},{name:"alternateRows",tab:"layout"},{name:"columnsVisibleIf",tab:"logic"},{name:"rowsVisibleIf",tab:"logic"},{name:"columnLayout",tab:"layout"},{name:"transposeData",tab:"layout"},{name:"horizontalScroll",tab:"layout"},{name:"columnColCount",tab:"layout"},{name:"columnMinWidth",tab:"layout"},{name:"cellErrorLocation",tab:"layout"},{name:"detailErrorLocation",tab:"layout"}],tabs:[{name:"columns",index:10},{name:"rows",index:11},{name:"choices",index:12}]},matrixdynamic:{properties:["allowAddRows","allowRemoveRows","allowRowsDragAndDrop","rowCount","minRowCount","maxRowCount","addRowLocation","addRowText","removeRowText","confirmDelete","confirmDeleteText","placeholder",{name:"hideColumnsIfEmpty",tab:"columns"},{name:"emptyRowsText",tab:"columns"},{name:"defaultRowValue",tab:"data"},{name:"defaultValueFromLastRow",tab:"data"},{name:"keyName",tab:"validation"},{name:"keyDuplicationError",tab:"validation"}]},matrixdropdown:{properties:["totalText","placeholder",{name:"hideIfRowsEmpty",tab:"rows"},{name:"rowTitleWidth",tab:"layout"},{name:"keyDuplicationError",tab:"validation"}]},matrix:{properties:[{name:"isAllRowRequired",tab:"validation"},{name:"eachRowUnique",tab:"validation"},{name:"showHeader",tab:"layout"},{name:"showColumnHeader",tab:"layout"},{name:"verticalAlign",tab:"layout"},{name:"alternateRows",tab:"layout"},{name:"rowsOrder",tab:"rows"},{name:"hideIfRowsEmpty",tab:"rows"},{name:"columnsVisibleIf",tab:"logic"},{name:"rowsVisibleIf",tab:"logic"},{name:"columnMinWidth",tab:"layout"},{name:"rowTitleWidth",tab:"layout"}],tabs:[{name:"columns",index:10},{name:"rows",index:11},{name:"cells",index:500}]},multipletext:{properties:[{name:"colCount",tab:"layout"},{name:"itemSize",tab:"layout"},{name:"itemErrorLocation",tab:"layout"}],tabs:[{name:"items",index:10}]},rating:{properties:[{name:"displayMode",tab:"rateValues"},{name:"rateCount",tab:"rateValues"},{name:"rateMin",tab:"rateValues"},{name:"rateMax",tab:"rateValues"},{name:"rateStep",tab:"rateValues"},{name:"minRateDescription",tab:"rateValues"},{name:"maxRateDescription",tab:"rateValues"},{name:"rateDescriptionLocation",tab:"rateValues"},{name:"displayRateDescriptionsAsExtremeItems",tab:"rateValues"}],tabs:[{name:"rateValues",index:10}]},selectbase:{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"layout"},{name:"textWrapEnabled",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"hideIfChoicesEmpty",tab:"logic"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"},{name:"otherErrorText",tab:"validation"},{name:"separateSpecialChoices",tab:"choices"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},checkbox:{properties:[{name:"showSelectAllItem",tab:"choices"},{name:"selectAllText",tab:"choices"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"},{name:"separateSpecialChoices",tab:"choices"}]},ranking:{properties:[{name:"selectToRankEnabled"},{name:"selectToRankAreasLayout"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"}]},radiogroup:{properties:[{name:"showClearButton",tab:"choices"},{name:"separateSpecialChoices",tab:"choices"}]},dropdown:{properties:["placeholder","autocomplete",{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"searchMode",tab:"choices"}]},tagbox:{properties:["closeOnSelect","placeholder",{name:"searchEnabled",tab:"choices"},{name:"searchMode",tab:"choices"},{name:"hideSelectedItems",tab:"choices"},{name:"allowClear",tab:"choices"}]},imagepicker:{properties:["contentMode","imageFit","isResponsive","minImageWidth","maxImageWidth","minImageHeight","maxImageHeight","imageHeight","imageWidth","multiSelect","showLabel"]},image:{properties:["imageLink","contentMode","imageFit","imageHeight","imageWidth","text"]},"itemvalue[]@choices":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},"itemvalue[]@rows":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},"itemvalue[]@columns":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},text:{properties:["inputType","min","max","step","placeholder","autocomplete","dataList",{name:"minValueExpression",tab:"logic"},{name:"maxValueExpression",tab:"logic"},{name:"size",tab:"layout"},{name:"inputTextAlignment",tab:"layout"},{name:"maxLength",tab:"validation"},{name:"minErrorText",tab:"validation"},{name:"maxErrorText",tab:"validation"},{name:"textUpdateMode",tab:"data"},{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"mask",index:250}]},boolean:{properties:["label","labelTrue","labelFalse","showTitle",{name:"valueTrue",tab:"data"},{name:"valueFalse",tab:"data"}]},expression:{properties:["expression","displayStyle","currency","format","maximumFractionDigits","minimumFractionDigits","useGrouping"]},panellayoutcolumn:{properties:["effectiveWidth","questionTitleWidth"]},matrixdropdowncolumn:{properties:["name","title"]},"matrixdropdowncolumn@default":{properties:["name","title","cellType","visible","readOnly","isRequired","isUnique","showInMultipleColumns","width","minWidth",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"defaultValueExpression",tab:"logic"},{name:"resetValueIf",tab:"logic"},{name:"setValueIf",tab:"logic"},{name:"setValueExpression",tab:"logic"},{name:"totalType",tab:"totals"},{name:"totalDisplayStyle",tab:"totals"},{name:"totalCurrency",tab:"totals"},{name:"totalFormat",tab:"totals"},{name:"totalExpression",tab:"totals"},{name:"validators",tab:"validation"},{name:"requiredErrorText",tab:"validation"}],tabs:[{name:"general",index:5},{name:"logic",index:20},{name:"totals",index:40},{name:"validation",index:60}]},"matrixdropdowncolumn@checkbox":{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"choices"},{name:"showSelectAllItem",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"},{name:"selectAllText",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@radiogroup":{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@dropdown":{properties:["placeholder",{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"optionsCaption",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@tagbox":{properties:["placeholder",{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"optionsCaption",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@text":{properties:["inputType","min","max","step","placeholder","dataList","maxLength",{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"mask",index:20},{name:"validators",index:25}]},"matrixdropdowncolumn@comment":{properties:["rows","placeholder","maxLength"],tabs:[{name:"validators",index:25}]},"matrixdropdowncolumn@boolean":{properties:[{name:"labelTrue",tab:"data"},{name:"labelFalse",tab:"data"},{name:"valueTrue",tab:"data"},{name:"valueFalse",tab:"data"},{name:"defaultValue",tab:"data"}],tabs:[{name:"data",index:25}]},"matrixdropdowncolumn@expression":{properties:["expression","displayStyle","currency"]},"matrixdropdowncolumn@rating":{properties:[{name:"displayMode",tab:"rateValues"},{name:"rateType",tab:"rateValues"},{name:"rateCount",tab:"rateValues"},{name:"rateColorMode",tab:"rateValues"},{name:"scaleColorMode",tab:"rateValues"},{name:"autoGenerate",tab:"rateValues"},{name:"rateMin",tab:"rateValues"},{name:"rateMax",tab:"rateValues"},{name:"rateStep",tab:"rateValues"},{name:"rateValues",tab:"rateValues"},{name:"minRateDescription",tab:"rateValues"},{name:"maxRateDescription",tab:"rateValues"},{name:"rateDescriptionLocation",tab:"rateValues"},{name:"displayRateDescriptionsAsExtremeItems",tab:"rateValues"}],tabs:[{name:"rateValues",index:5}]},multipletextitem:{properties:["name","title","inputType","isRequired","size","placeholder","inputTextAlignment",{name:"maxLength",tab:"validation"},{name:"requiredErrorText",tab:"validation"},{name:"validators",tab:"validation"},{name:"defaultValueExpression",tab:"logic"},{name:"minValueExpression",tab:"logic"},{name:"maxValueExpression",tab:"logic"},{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"logic",index:200},{name:"mask",index:250},{name:"validation",index:300}]},"multipletext@items":{properties:["name","title"]},calculatedvalue:{properties:["name","expression","includeIntoResult"]},"calculatedvalue@items":{properties:["name","expression"]},paneldynamic:{properties:["renderMode","displayMode","templateTabTitle","tabTitlePlaceholder","tabAlign","panelCount","minPanelCount","maxPanelCount","panelsState",{name:"allowAddPanel"},{name:"allowRemovePanel"},"panelAddText","panelRemoveText","templateTitle","templateDescription","noEntriesText","confirmDelete","confirmDeleteText","panelPrevText","panelNextText","showQuestionNumbers","showRangeInProgress","showProgressBar","progressBarLocation",{name:"defaultPanelValue",tab:"data"},{name:"defaultValueFromLastPanel",tab:"data"},{name:"templateTitleLocation",tab:"questionSettings"},{name:"templateErrorLocation",tab:"questionSettings"},{name:"panelRemoveButtonLocation",tab:"layout"},{name:"keyName",tab:"validation"},{name:"keyDuplicationError",tab:"validation"}]},panelbase:{properties:["name","title","description","visible","readOnly",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"questionTitleLocation",tab:"questionSettings"},{name:"questionTitleWidth",tab:"questionSettings"},{name:"questionErrorLocation",tab:"questionSettings"},{name:"layoutColumns",tab:"questionSettings"}],tabs:[{name:"questionSettings",index:100},{name:"logic",index:200},{name:"data",index:300},{name:"validation",index:400}]},panel:{properties:["isRequired",{name:"questionsOrder",tab:"questionSettings"},{name:"innerIndent",tab:"questionSettings"},{name:"requiredErrorText",tab:"validation"},{name:"page",tab:"layout"},{name:"startWithNewLine",tab:"layout"},{name:"state",tab:"layout"},{name:"width",tab:"layout"},{name:"minWidth",tab:"layout"},{name:"maxWidth",tab:"layout"},{name:"effectiveColSpan",tab:"layout"},{name:"showNumber",tab:"numbering"},{name:"showQuestionNumbers",tab:"numbering"},{name:"questionStartIndex",tab:"numbering"}],tabs:[{name:"layout",index:150},{name:"numbering",index:350}]},page:{properties:["navigationTitle","navigationDescription","timeLimit","maxTimeToFinish",{name:"questionsOrder",tab:"questionSettings"},{name:"navigationButtonsVisibility",tab:"navigation"}],tabs:[{name:"navigation",index:350}]},survey:{properties:["title","description","showTitle","locale","mode","cookieName","widthMode","width","fitToContainer",{name:"questionsOnPageMode",tab:"navigation"},{name:"firstPageIsStarted",tab:"navigation"},{name:"goNextPageAutomatic",tab:"navigation"},{name:"allowCompleteSurveyAutomatic",tab:"navigation"},{name:"showNavigationButtons",tab:"navigation"},{name:"showPrevButton",tab:"navigation"},{name:"showProgressBar",tab:"navigation"},{name:"progressBarType",tab:"navigation"},{name:"progressBarShowPageTitles",tab:"navigation"},{name:"progressBarShowPageNumbers",tab:"navigation"},{name:"showTOC",tab:"navigation"},{name:"tocLocation",tab:"navigation"},{name:"showPreviewBeforeComplete",tab:"navigation"},{name:"previewText",tab:"navigation"},{name:"editText",tab:"navigation"},{name:"startSurveyText",tab:"navigation"},{name:"pagePrevText",tab:"navigation"},{name:"pageNextText",tab:"navigation"},{name:"completeText",tab:"navigation"},{name:"questionsOrder",tab:"question"},{name:"questionTitleLocation",tab:"question"},{name:"questionDescriptionLocation",tab:"question"},{name:"showQuestionNumbers",tab:"question"},{name:"questionTitlePattern",tab:"question"},{name:"requiredText",tab:"question"},{name:"questionStartIndex",tab:"question"},{name:"questionErrorLocation",tab:"question"},{name:"focusFirstQuestionAutomatic",tab:"question"},{name:"maxTextLength",tab:"question"},{name:"maxOthersLength",tab:"question"},{name:"commentAreaRows",tab:"question"},{name:"autoGrowComment",tab:"question"},{name:"allowResizeComment",tab:"question"},{name:"gridLayoutEnabled",tab:"question"},{name:"showPageTitles",tab:"pages"},{name:"showPageNumbers",tab:"pages"},{name:"calculatedValues",tab:"logic"},{name:"triggers",tab:"logic"},{name:"clearInvisibleValues",tab:"data"},{name:"textUpdateMode",tab:"data"},{name:"sendResultOnPageNext",tab:"data"},{name:"storeOthersAsComment",tab:"data"},{name:"focusOnFirstError",tab:"validation"},{name:"checkErrorsMode",tab:"validation"},{name:"validateVisitedEmptyFields",tab:"validation"},{name:"navigateToUrl",tab:"showOnCompleted"},{name:"navigateToUrlOnCondition",tab:"showOnCompleted"},{name:"showCompletedPage",tab:"showOnCompleted"},{name:"completedHtml",tab:"showOnCompleted"},{name:"completedHtmlOnCondition",tab:"showOnCompleted"},{name:"loadingHtml",tab:"showOnCompleted"},{name:"completedBeforeHtml",tab:"showOnCompleted"},{name:"showTimer",tab:"timer"},{name:"timerLocation",tab:"timer"},{name:"timeLimit",tab:"timer"},{name:"timeLimitPerPage",tab:"timer"},{name:"timerInfoMode",tab:"timer"},{name:"maxTimeToFinish",tab:"timer"},{name:"maxTimeToFinishPage",tab:"timer"},{name:"showTimerPanel",tab:"timer"},{name:"showTimerPanelMode",tab:"timer"},{name:"logo",tab:"logo"},{name:"logoPosition",tab:"logo"},{name:"logoWidth",tab:"logo"},{name:"logoHeight",tab:"logo"},{name:"logoFit",tab:"logo"}],tabs:[{name:"logo",index:50},{name:"navigation",index:100},{name:"question",index:200},{name:"pages",index:250},{name:"logic",index:300},{name:"data",index:400},{name:"validation",index:500},{name:"showOnCompleted",index:600},{name:"timer",index:700}]},"page@survey":{properties:["name","title"]},choicesByUrl:{properties:["url","path","valueName","titleName","allowEmptyResponse"]},"patternmask@maskSettings":{properties:["pattern","saveMaskedValue"]},"datetimemask@maskSettings":{properties:["pattern","min","max","saveMaskedValue"]},"numericmask@maskSettings":{properties:["min","max","precision","decimalSeparator","thousandsSeparator","allowNegativeValues","saveMaskedValue"]},"currencymask@maskSettings":{properties:["prefix","suffix","min","max","precision","decimalSeparator","thousandsSeparator","allowNegativeValues","saveMaskedValue"]},patternmask:{properties:["pattern"]},datetimemask:{properties:["pattern"]},currencymask:{properties:["prefix","suffix"]}},We={autoGenerateProperties:!0,classes:Je},Ke=function(){function e(){}return e.definition=Je,e}(),Ye=function(){function e(){}return Object.defineProperty(e.prototype,"name",{get:function(){return this.property?this.property.name:""},enumerable:!1,configurable:!0}),e}(),Xe=function(){this.visible=!0,this.index=0,this.properties=[]},$e="others",et=function(){function e(e,t,i,n,r,a,s){void 0===t&&(t=null),void 0===i&&(i=null),void 0===n&&(n=null),void 0===r&&(r=null),void 0===a&&(a=null),void 0===s&&(s=null),this.obj=e,this.options=t,this.parentObj=r,this.parentProperty=a,this.propertyGridDefinition=s,this.tabs=[],this.unusedProperties=[],this.propertyGridDefinition||(this.propertyGridDefinition=We),this.showModeValue=n,this.properties=o.Serializer.getPropertiesByObj(this.obj),this.fillPropertiesHash(),this.buildTabs(i)}return e.prototype.getAllVisiblePropertiesNames=function(e){var t=[];return this.tabs.forEach((function(e){e.properties.forEach((function(e){return t.push(e.name)}))})),e&&this.unusedProperties.forEach((function(e){return t.push(e.name)})),t},e.prototype.getIsPropertyVisible=function(e){return ee.isPropertyVisible(this.obj,e,this.options,this.showMode,this.parentObj,this.parentProperty)},e.prototype.getDynamicClassName=function(){return this.obj&&this.obj.isQuestion&&this.obj.getDynamicType?this.obj.getDynamicType():""},e.prototype.getProperty=function(e){var t=this.propertiesHash[e];return t&&t.visible?t.property:null},e.prototype.getPropertyAsCategory=function(e){var t=this.getProperty(e);return!t||t.category&&t.category!==e?null:t},Object.defineProperty(e.prototype,"showMode",{get:function(){return this.showModeValue?this.showModeValue:"form"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEmpty",{get:function(){for(var e=0;e<this.tabs.length;e++)if(this.tabs[e].visible&&this.tabs[e].properties.length>0)return!1;return!0},enumerable:!1,configurable:!0}),e.prototype.getClassDefintion=function(e){if(this.propertyGridDefinition&&this.propertyGridDefinition.classes)return this.propertyGridDefinition.classes[e]},e.prototype.fillPropertiesHash=function(){this.propertiesHash={};for(var e=0;e<this.properties.length;e++){var t=this.properties[e];this.propertiesHash[t.name]={property:t,visible:this.getIsPropertyVisible(t)}}},e.prototype.isJSONPropertyVisible=function(e){var t=this.propertiesHash[e.name];return!!t&&t.visible},e.prototype.getTabByName=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].name==e)return this.tabs[t];return null},e.prototype.getTabs=function(){return this.tabs},e.prototype.getProperties=function(e){for(var t=[],o=0;o<e.properties.length;o++)t.push(e.properties[o].property);return t},e.prototype.buildTabs=function(e){!e&&this.obj&&(e=this.obj.getType());for(var t=this.getAllDefinitionsByClass(e),o=[],i=t.length-1;i>=0;i--){for(var n=t[i],r=n.tabs?n.tabs.length-1:-1;r>=0;r--){var a=n.tabs[r];o.indexOf(a.name)>-1?this.setTabProperties(a):this.addPropertyIntoTab(a,!0)&&o.push(a.name)}for(r=n.properties?n.properties.length-1:-1;r>=0;r--){var s=n.properties[r].name||n.properties[r];-1===o.indexOf(s)&&(o.push(s),this.addPropertyIntoTab(n.properties[r]))}}for(i=this.tabs.length-1;i>=0;i--)this.movePropertiesToNextProperties(this.tabs[i].properties),this.tabs[i].visible?this.sortProperties(this.tabs[i].properties):this.tabs.splice(i,1);this.tabs.sort((function(e,t){return e.index<t.index?-1:e.index>t.index?1:0})),this.setParentTabs(),this.tabs.forEach((function(e){var t;null===(t=e.tabs)||void 0===t||t.sort((function(e,t){return e.index-t.index}))}))},e.prototype.setParentTabs=function(){for(var e=this.tabs.length-1;e>=0;e--){var t=this.tabs[e];if(t.parentName){var o=this.getTabByName(t.parentName);o&&(t.parent=o,Array.isArray(o.tabs)||(o.tabs=[]),o.tabs.push(t),this.tabs.splice(e,1))}}},e.prototype.addPropertyIntoTab=function(e,t){void 0===t&&(t=!1),t&&this.setTabProperties(e);var o="string"==typeof e,n=o?e:e.name,r=this.propertiesHash[n];if(!r||t&&!this.getPropertyAsCategory(n))return!1;if(!o&&!1===e.visible)return!1;if(!r.visible&&(o||!o&&!0!==e.visible))return!1;var a=t?e.name:i.propertyGrid.generalTabName;t||o||!e.tab||(a=e.tab);var s=new Ye;return s.property=r.property,s.category=!o&&e.category?e.category:"",s.title=!o&&e.title?e.title:"",t||void 0===e.index||(s.definedIndex=e.index),s.onSameLine=this.isPropertyOnSameLine(r.property.nextToProperty),s.createdFromTabName=t,this.getTabOrCreate(a).properties.unshift(s),!0},e.prototype.setTabProperties=function(e){var t=this.getTabOrCreate(e.name);e.index>0&&(t.index=e.index),t.parentName=e.parent,!1===e.visible&&(t.visible=!1),e.title&&(t.title=e.title)},e.prototype.movePropertiesToNextProperties=function(e){for(var t=[].concat(e),o=0;o<t.length;o++){var i=this.getNextToNameProperty(t[o].property),n=this.getTabByPropertyName(i);if(n){var r=this.getPropertyByNameInTab(n,i),a=n.properties.indexOf(r);n.properties.splice(a+1,0,t[o]),e.splice(e.indexOf(t[o]),1)}}},e.prototype.getTabByPropertyName=function(e){if(!e)return null;this.isPropertyOnSameLine(e)&&(e=e.substring(1));for(var t=0;t<this.tabs.length;t++)if(this.getPropertyByNameInTab(this.tabs[t],e))return this.tabs[t];return null},e.prototype.getNextToNameProperty=function(e){return e.nextToProperty?this.isPropertyOnSameLine(e.nextToProperty)?e.nextToProperty.substring(1):e.nextToProperty:""},e.prototype.isPropertyOnSameLine=function(e){return!!e&&"*"===e[0]},e.prototype.getPropertyByNameInTab=function(e,t){for(var o=e.properties,i=0;i<o.length;i++)if(o[i].name==t)return o[i];return null},e.prototype.getTabOrCreate=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].name==e)return this.tabs[t];var o=new Xe;return o.name=e,e==i.propertyGrid.generalTabName&&(o.index=-1),this.tabs.unshift(o),o},e.prototype.setUsedProperties=function(e,t){for(var o=0;o<e.length;o++){var i=e[o].properties;if(Array.isArray(i))for(var n=0;n<i.length;n++)t[i[n].name?i[n].name:i[n]]=!0}},e.prototype.getAllDefinitionsByClass=function(e){var t=this,i=[],n={};if(e.indexOf("@")>-1&&this.getClassDefintion(e)){for(var r=e.substring(0,e.indexOf("@")+1),a=e.substring(r.length),s=[],l=o.Serializer.findClass(a);l&&"question"!==l.name;)s.unshift(r+l.name),l=l.parentName?o.Serializer.findClass(l.parentName):void 0;return s.indexOf(e)<0&&s.unshift(e),s.indexOf(r+"default")<0&&s.unshift(r+"default"),s.forEach((function(e){var o=t.getClassDefintion(e);o&&i.push(o)})),this.setUsedProperties(i,n),this.isColumnObj&&this.getAllDefinitionsByClassCore(this.obj.templateQuestion.getType(),n,i,void 0,!0),this.addNonTabProperties(i,n,!0),i}var u=!1,p=this.getDynamicClassName();return p&&(u=this.getAllDefinitionsByClassCore(p,n,i,e)),this.getAllDefinitionsByClassCore(e,n,i,void 0)&&u||this.addNonTabProperties(i,n),i},e.prototype.getAllDefinitionsByClassCore=function(e,t,i,n,r){for(var a=!1,s=e;s&&(!n||!o.Serializer.isDescendantOf(n,s));){var l=o.Serializer.findClass(s);if(!l)break;a=this.getAllDefinitionsByClassSingleCore(l.name,t,i,r),s=l.parentName}return a},e.prototype.getAllDefinitionsByClassSingleCore=function(e,t,o,n){var r=this.getClassDefintion(e),a=!1;if(!r)return a;var s=void 0;if(r.properties)for(var l=0;l<r.properties.length;){var u=r.properties[l],p="string"==typeof u?u:u.name,c=i.propertyGrid.generalTabName;"string"!=typeof u&&u.tab&&(c=u.tab);var d=this.propertiesHash[p]?this.propertiesHash[p].property:null;if(!n||(null==d?void 0:d.availableInMatrixColumn)){var h=this.getJsonPropertyCategory(d);h&&h!==c?r.properties.splice(l,1):t[p]=!0,n&&(s||(s={properties:[],tabs:[]}),s.properties.push(u))}l++}if(n)return s&&o.unshift(s),a;if(r.tabs)for(var g=0;g<r.tabs.length;g++)c=r.tabs[g].name,a=a||c===$e,this.getPropertyAsCategory(c)&&(t[c]=!0);return o.unshift(r),a},e.prototype.getJsonPropertyCategory=function(e){return e&&e.category?e.category:null},Object.defineProperty(e.prototype,"isColumnObj",{get:function(){return"matrixdropdowncolumn"===this.obj.getType()},enumerable:!1,configurable:!0}),e.prototype.getUnusedProperties=function(e,t){void 0===t&&(t=!1);for(var o=[],i=this.isColumnObj,n=0;n<this.properties.length;n++){var r=this.properties[n];this.isJSONPropertyVisible(r)&&!e[r.name]&&(!t||"form"===r.showMode||i&&r.availableInMatrixColumn)&&o.push(r)}return o},e.prototype.addNonTabProperties=function(e,t,o){void 0===o&&(o=!1);var n=this.getUnusedProperties(t,o);if(this.propertyGridDefinition.autoGenerateProperties){for(var r={properties:[],tabs:[]},a=[],s=0;s<n.length;s++){var l=n[s],u=this.getJsonPropertyCategory(l)||(0==e.length||this.parentObj&&"form"===this.showMode?i.propertyGrid.generalTabName:$e);if(a.indexOf(u)<0&&u!=i.propertyGrid.generalTabName&&(a.push(u),r.tabs.push({name:u,index:u===$e?1e3:10*a.length})),l.categoryIndex>-1&&a.indexOf(u)>-1)for(var p=0;p<r.tabs.length;p++)r.tabs[p].name==u&&(r.tabs[p].index=l.categoryIndex);r.properties.push({name:l.name,tab:u})}r.properties.length>0&&e.push(r)}else this.unusedProperties=n},e.prototype.sortProperties=function(e){if(Array.isArray(e)){var t=0;e.forEach((function(e){e.index=void 0!==e.definedIndex?e.definedIndex:t,t++})),e.sort((function(e,t){return e.index===t.index?0:e.index<t.index?-1:1})),this.insertProperteisWithVisibleIndex(e)}},e.prototype.insertProperteisWithVisibleIndex=function(e){for(var t=[].concat(e),o=0;o<t.length;o++){var i=t[o].property.visibleIndex;if(t[o].createdFromTabName&&i<0&&(i=0),!(i<0||void 0!==t[o].definedIndex)){var n=e.indexOf(t[o]);n>-1&&e.splice(n,1),i<e.length?e.splice(i,0,t[o]):e.push(t[o])}}},e}(),tt=function(){function e(){}return e.prototype.parse=function(t){e.boldRegEx||(e.boldRegEx=/\*{2}(.*?)\*{2}/gm,e.italicRegEx=/\_(.*?)\_/gm,e.codeRegEx=/\`(.*?)\`/gm,e.linkRegEx=/\[(.+)\]\(([^ ]+?)( "(.+)")?\)/);var o=function(e,t,o,n){if(!t)return e;var r=e.indexOf(t);if(i(e,r))return e;var a=t.substring(n.length,t.length),s="<span class='"+o+"'>"+(a=a.substring(0,a.length-n.length))+"</span>";return e.replace(t,s)},i=function(e,t){for(var o=!1,i=t-1;i>0;i--){if(" "===e[i]||"\n"===e[i])return!1;if("]"===e[i]&&o)return!0;o="("===e[i]}return!1};return t=this.replace(e.boldRegEx,t,"spg-bold","**",o),t=this.replace(e.italicRegEx,t,"spg-italic","_",o),t=this.replace(e.codeRegEx,t,"spg-code","`",o),t=this.replace(e.linkRegEx,t,"spg-link","",(function(e,t,o,i){if(!t)return e;var n=t.indexOf("](");if(n<0)return e;var r=t.substring(1,n),a="<a class='"+o+"' target='_blank' href='"+t.substring(n+2,t.length-1)+"'>"+r+"</a>";return e.replace(t,a)})),this.addLineBreaks(t)},e.prototype.replace=function(e,t,o,i,n){var r=t.match(e);if(!Array.isArray(r)||0==r.length)return t;for(var a=0;a<r.length;a++)t=n(t,r[a],o,i);return t},e.prototype.addLineBreaks=function(e){return e.indexOf("\n")<0?e:e.split("\n").join("<br/>")},e}();function ot(e,t,o){void 0===t&&(t=!0),void 0===o&&(o=!0),e.showNavigationButtons="none",e.showPageTitles=!1,e.focusFirstQuestionAutomatic=!1,e.showQuestionNumbers="off",o&&(e.questionTitleLocation="left"),e.showProgressBar="off",t&&(e.textUpdateMode="onTyping"),e.requiredText=""}o.FunctionFactory.Instance.register("propertyVisibleIf",(function(e){if(!this.question)return!1;var t=this.question.obj,i=this.question.property;return!(!t||!i)&&!!o.Serializer.hasOriginalProperty(t,i.name)&&i.isVisible("",t)})),o.FunctionFactory.Instance.register("propertyEnableIf",(function(e){var t=this.question.property,o=this.question.obj;return!!(this.question&&o&&t)&&!this.question.obj[t.overridingProperty]&&t.isEnable(o)}));var it=function(){function e(e,t){void 0===e&&(e=null),void 0===t&&(t=!0),this.options=e,this.options||(this.options=new a),t&&this.setupSurvey()}return e.prototype.setupSurvey=function(){this.editSurveyValue=this.createSurvey()},Object.defineProperty(e.prototype,"editSurvey",{get:function(){return this.editSurveyValue},enumerable:!1,configurable:!0}),e.prototype.hasErrors=function(){return this.editSurvey.hasErrors(!0,!0)},e.prototype.createSurvey=function(){var e=this.getSurveyJSON();return ot(e,!1,!1),this.options.createSurvey(e,this.getSurveyCreationReason(),this)},e.prototype.dispose=function(){this.editSurvey&&this.editSurvey.dispose()},e}(),nt={editors:new Array,fitHash:{},clearHash:function(){this.fitHash={}},register:function(e){this.editors.push(e)},getEditor:function(e,t){if(!e)return null;if(t)for(var o=this.editors.length-1;o>=0;o--){var i=this.editors[o];if(i.fit(e,t))return i}var n=this.fitHash[e.id];return n||(this.isEditorFit(e)||this.isEditorFit(e,!0))},isEditorFit:function(e,t){void 0===t&&(t=!1);for(var o=this.editors.length-1;o>=0;o--){var i=this.editors[o];if(!t&&i.fit(e)||t&&i.isDefault&&i.isDefault())return this.fitHash[e.id]=i,i}return null},getJSON:function(e,t,o,i,n){var r=this.getEditor(t,i);return r?r.getJSON(e,t,o,n):null},onCreated:function(e,t,o,i,n){var r=this.getEditor(o);r&&r.onCreated&&r.onCreated(e,t,o,i,n)},onSetup:function(e,t,o,i){var n=this.getEditor(o);n&&n.onSetup&&n.onSetup(e,t,o,i)},validateValue:function(e,t,o,i){var n=this.getEditor(o);return n&&n.validateValue?n.validateValue(e,t,o,i):""},onAfterRenderQuestion:function(e,t,o){var i=this.getEditor(t);i&&i.onAfterRenderQuestion&&i.onAfterRenderQuestion(e,t,o)},onMatrixCellCreated:function(e,t,o){var i=this.getEditor(t);i&&i.onMatrixCellCreated&&i.onMatrixCellCreated(o.question.obj,o)},onMatrixCellValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onMatrixCellValueChanged&&i.onMatrixCellValueChanged(e,o);var n=o.row;if(n){for(var r=n.questions,a=0;a<r.length;a++)if(r[a].errors.length>0)return;var s=n.getQuestionByName(o.columnName);s&&n.runCondition({},{question:s})}},onMatrixAllowRemoveRow:function(e,t,o){var i=this.getEditor(t);return!i||!i.onMatrixAllowRemoveRow||i.onMatrixAllowRemoveRow(e,o)},onGetMatrixRowAction:function(e,t,o,i){var n=this.getEditor(t);n&&n.onGetMatrixRowAction&&n.onGetMatrixRowAction(e,o,i)},onUpdateQuestionCssClasses:function(e,t,o){var i=this.getEditor(t);i&&i.onUpdateQuestionCssClasses&&i.onUpdateQuestionCssClasses(e,o)},onGetQuestionTitleActions:function(e,t,o,i){var n=this.getEditor(t);n&&n.onGetQuestionTitleActions&&n.onGetQuestionTitleActions(e,o,i)},onValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onValueChanged&&i.onValueChanged(e,t,o)},onValueChanging:function(e,t,o,i){var n=this.getEditor(t);n&&n.onValueChanging&&n.onValueChanging(e,t,o,i)},onMasterValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onMasterValueChanged&&i.onMasterValueChanged(e,t,o)}},rt=function(){function e(e,t){this.obj=e,this.options=t}return e.prototype.onGetQuestionTitleActions=function(e){var t=e.question,o=t.property,i=nt.getEditor(o);if(i){var n=[],r=!t.isReadOnly;!!i.clearPropertyValue&&(!i.canClearPropertyValue||i.canClearPropertyValue(this.obj,o,t,this.options))&&n.push(this.createClearValueAction(i,o,t,r)),!1!==t.allowBatchEdit&&i.createPropertyEditorSetup&&(i.isPropertyEditorSetupEnabled&&(r=i.isPropertyEditorSetupEnabled(this.obj,o,e.question,this.options)),n.push(this.createEditorSetupAction(i,o,t,r)));var a=this.createPropertyHelpAction(t);a&&(n.unshift(a),t.getTitleToolbar().containerCss+=" spg-title-toolobar--single-help-action",a.iconSize=16),n.length>0&&(e.titleActions=n)}},e.prototype.createClearValueAction=function(e,t,i,n){var r=this;return{id:"property-grid-clear",title:Z("pe.clear"),showTitle:!1,iconName:"icon-clear",innerCss:"spg-action-button--danger",enabled:n,visible:new o.ComputedUpdater((function(){var e=i.obj[t.name];return Array.isArray(e)?e.length>0:!!e})),action:function(){e.clearPropertyValue(i.obj,t,i,r.options)}}},e.prototype.showModalPropertyEditor=function(e,t,o){return e.showModalPropertyEditor(e,t,o,this.options)},e.prototype.createEditorSetupAction=function(e,t,o,i){var n=this;return{id:"property-grid-setup",iconName:t.isArray?"icon-fast-entry":"icon-wizard",enabled:i,title:Z("pe.edit"),showTitle:!1,action:function(){return n.showModalPropertyEditor(e,t,o)}}},e.prototype.createPropertyHelpAction=function(e){var t=this;if(!e.description)return null;var i=new o.Action({title:"",tooltip:e.description,id:"property-grid-help",iconName:this.getHelpActionIconName(e),css:"spg-help-action",showTitle:!1,action:function(){e.descriptionLocation="hidden"!=e.descriptionLocation?"hidden":"underTitle",i.iconName=t.getHelpActionIconName(e)}}),n=i.doMouseDown;return i.doMouseDown=function(e){n.call(i);var t=e.originalEvent?e.originalEvent:e;t.preventDefault(),t.stopPropagation()},i},e.prototype.getHelpActionIconName=function(e){return"hidden"!=e.descriptionLocation?"icon-description-hide":"icon-description"},e}(),at=function(){function e(e,t,o,i,n){void 0===t&&(t=null),void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),this.obj=e,this.options=t,this.parentObj=o,this.parentProperty=i,this.propertyGridDefinition=n}return e.isPropertyReadOnly=function(e,t,o,i,n){var r=e.readOnly;return t&&o&&(r=t.onIsPropertyReadOnlyCallback(o,e,r,i,n)),r},e.getClassNameProperty=function(e){if(e&&e.getClassNameProperty)return e.getClassNameProperty()},e.prototype.toJSON=function(e,t){return void 0===e&&(e=!1),void 0===t&&(t=void 0),this.createJSON(e,t)},e.prototype.createColumnsJSON=function(e,t){for(var i=[],n=(e?o.Serializer.createClass(e):this.obj)||this.obj,r=0;r<t.length;r++){var a=this.getColumnPropertyJSON(n,t[r]);a&&i.push(a)}return i},e.prototype.setupObjPanel=function(e,t,o){void 0===t&&(t=!1),void 0===o&&(o=void 0),e.fromJSON(this.toJSON(t,o)),this.onQuestionsCreated(e)},e.prototype.setupPages=function(e){var t=this,o=this.convertPanelsToPages(this.toJSON(!1)),i=e.toJSON();Object.keys(o).forEach((function(e){return i[e]=o[e]})),e.fromJSON(i),e.pages.forEach((function(e){return t.onQuestionsCreated(e)}))},e.prototype.convertPanelsToPages=function(e){var t=e.elements;if(Array.isArray(t))return t.forEach((function(e){delete e.type})),e.pages=t,delete e.elements,e},e.prototype.onQuestionsCreated=function(e){for(var t=o.Serializer.getPropertiesByObj(this.obj),i={},n=0;n<t.length;n++)i[t[n].name]=t[n];var r=e.questions;for(n=0;n<r.length;n++){var a=r[n],s=i[a.name];a.property=s,a.obj=this.obj,a.creatorOptions=this.options;var l=this.getVisibilityOnEvent(s);if(a.readOnly=a.readOnly||this.isPropertyReadOnly(s),a.visible=a.visible&&l,s.visibleIf&&l&&(a.visibleIf="propertyVisibleIf() = true"),a.visible&&(s.overridingProperty||s.enableIf)&&(a.readOnly||(a.enableIf="propertyEnableIf() = true"),s.overridingProperty)){a.onUpdateCssClassesCallback=function(e){e.questionWrapper="spg-boolean-wrapper--overriding"};var u=this.createOverridingQuestion(e,a,s.overridingProperty);u&&a.parent.addElement(u,a.parent.elements.indexOf(a)+1)}a.descriptionLocation="hidden";var p=G.getPropertyHelpInEditor(this.obj.getType(),s.name,s.type);p&&(a.description=p),nt.onCreated(this.obj,a,s,this.options,this.propertyGridDefinition),this.options.onPropertyEditorCreatedCallback(this.obj,s,a)}},e.prototype.getVisibilityOnEvent=function(e,t){return void 0===t&&(t=""),this.options.onCanShowPropertyCallback(this.obj,e,t,this.parentObj,this.parentProperty)},e.prototype.isPropertyReadOnly=function(t){return e.isPropertyReadOnly(t,this.options,this.obj,this.parentObj,this.parentProperty)},e.prototype.createOverridingQuestion=function(e,t,i){var n=o.Serializer.createClass("linkvalue");if(!n)return null;n.name=t.name+"_overridingProperty",n.startWithNewLine=!1,n.property=t.property,n.obj=t.obj,n.visibleIf="propertyEnableIf() = false";var r=e.getQuestionByName(i);return!r&&e.survey&&(r=e.survey.getQuestionByName(i)),n.linkValueText=G.getString("pe.overridingPropertyPrefix"),n.titleLocation="hidden",n.onUpdateCssClassesCallback=function(e){e.questionWrapper="spg-link-wrapper--overriding"},r&&(n.linkClickCallback=function(){r.focus(!1,!0)}),n},e.prototype.getClasPropName=function(){if(this.parentObj&&this.parentProperty)return this.parentProperty.name;var t=e.getClassNameProperty(this.obj);return t&&this.obj[t]?this.obj[t]:void 0},e.prototype.createJSON=function(e,t){void 0===t&&(t=void 0);var o=void 0,n=this.getClasPropName();n&&("itemvalue"===(o=this.obj.getType())&&(o+="[]"),o+="@"+n);for(var r=new et(this.obj,null,o,void 0,this.parentObj,this.parentProperty,this.propertyGridDefinition).getTabs(),a={},s=0;s<r.length;s++)!1!==r[s].visible&&(a[r[s].name]=this.createPanelProps(r[s],t));var l={elements:[]};for(var u in a)if(u==i.propertyGrid.generalTabName&&e){var p=a[u].elements;for(s=0;s<p.length;s++)l.elements.push(p[s])}else l.elements.push(a[u]);return l},e.prototype.createPanelProps=function(e,t,o){var i=this;void 0===o&&(o=!1);for(var n=this.createPanelJSON(e.name,e.title,o),r=0;r<e.properties.length;r++){var a=e.properties[r],s=this.createQuestionJSON(this.obj,a.property,a.title,!1,t);a.onSameLine&&(s.startWithNewLine=!1,this.updateQuestionJSONOnSameLine(s),n.elements.length>0&&this.updateQuestionJSONOnSameLine(n.elements[n.elements.length-1])),s&&n.elements.push(s)}return Array.isArray(e.tabs)&&e.tabs.forEach((function(e){var o=i.createPanelProps(e,t,!0);o.title===e.name&&delete o.title,o&&n.elements.push(o)})),n},e.prototype.updateQuestionJSONOnSameLine=function(e){e.titleLocation="left",e.minWidth="50px"},e.prototype.createPanelJSON=function(e,t,o){var i={type:"panel",name:e,title:this.getPanelTitle(e,t),elements:[]};return o||(i.state="collapsed"),i},e.prototype.createQuestionJSON=function(e,t,o,i,n){if(void 0===i&&(i=!1),!this.isPropertyVisible(t,i?"list":"")&&i)return null;var r=nt.getJSON(e,t,this.options,n,this.propertyGridDefinition);if(!r)return null;r.name=t.name,r.title=this.getQuestionTitle(t,e.getType(),o),this.isQuestionTitleHidden(t)&&(r.titleLocation="hidden"),r.visible=t.visible,r.isReadOnly=t.readOnly,r.isRequired=t.isRequired,r.requiredErrorText=G.getString("pe.propertyIsEmpty"),["page","panelbase"].indexOf(t.className)&&"name"===r.name&&(r.isRequired=!0,r.requiredErrorText=G.getString("pe.propertyIsEmpty"));var a=G.getPropertyPlaceholder(e.getType(),t.name);return a&&(r.placeholder=a),r},e.prototype.getColumnPropertyJSON=function(e,t){if(!e)return null;var i=o.Serializer.findProperty(e.getType(),t);if(!i)return null;var n=this.createQuestionJSON(e,i,"",!0,void 0);return n?(i.isUnique&&(n.isUnique=i.isUnique),n.type&&(n.cellType=n.type,delete n.type),"buttongroup"===n.cellType&&(n.cellType="dropdown"),"fileedit"===n.cellType&&(n.cellType="text"),i.visibleIf&&(n.visibleIf="propertyVisibleIf() = true"),n.isReadOnly&&(n.readOnly=n.isReadOnly,delete n.isReadOnly),n):null},e.prototype.isPropertyVisible=function(e,t){return!(!e.visible||t&&e.showMode&&t!=e.showMode)},e.prototype.getPanelTitle=function(e,t){if(t)return t;var i=G.getString("pe.tabs."+e);if("object"==typeof i)for(var n in i)if(o.Serializer.isDescendantOf(this.obj.getType(),n))return i[n];return i},e.prototype.getQuestionTitle=function(e,t,i){if(e.displayName)return e.displayName;if(i&&i!==e.name)return i;var n=t;return this.parentProperty&&(n+="@"+this.parentProperty.name),"matrixdropdowncolumn"===this.obj.getType()&&"question"!==this.obj.getDynamicType()&&(o.Serializer.findProperty(this.obj.getType(),e.name)||(n=this.obj.getDynamicType())),G.getPropertyNameInEditor(n,e.name)},e.prototype.isQuestionTitleHidden=function(e){return""===e.displayName},e}(),st=function(){function e(e,t,o){void 0===e&&(e=null),void 0===t&&(t=new a),void 0===o&&(o=null),this.showOneCategoryInPropertyGrid=!1,this.surveyInstanceCreatedArea="property-grid",this.isCellCreating=!1,this.options=t,this.propertyGridDefinition=o,this.options.enableLinkFileEditor&&nt.register(new ft),this.obj=e}return e.prototype.refresh=function(){this.setObj(this.objValue)},Object.defineProperty(e.prototype,"obj",{get:function(){return this.objValue},set:function(e){this.objValue!==e&&this.setObj(e)},enumerable:!1,configurable:!0}),e.prototype.setPropertyGridDefinition=function(e){this.propertyGridDefinition!==e&&(this.propertyGridDefinition=e,this.obj&&this.updateCurrentSurveyWithNewDefinition())},e.prototype.selectProperty=function(e,t){if(void 0===t&&(t=!0),this.survey){var o=this.survey.getQuestionByName(e);if(o){for(var i=this.survey.getAllPanels(),n=0;n<i.length;n++){var r=i[n];r===o.parent?(r.blockAnimations(),r.expand(),r.releaseAnimations()):r.collapse()}t?o.focus():this.showOneCategoryInPropertyGrid&&(this.survey.currentPage=o.page)}}},e.prototype.setObjFromAction=function(e,t){this.changedFromActionCallback?this.changedFromActionCallback(e,t):this.setObj(e)},e.prototype.setObj=function(e){var t=this;this.objValue=e,this.classNameProperty=this.obj?at.getClassNameProperty(this.obj):"",this.classNameValue=this.classNameProperty?this.obj[this.classNameProperty]:void 0,this.titleActionsCreator=this.obj?new rt(this.obj,this.options):void 0;var o=this.getSurveyJSON();this.options.readOnly&&(o.mode="display"),this.surveyValue&&(this.surveyValue.onValidateQuestion.clear(),this.surveyValue.onValueChanging.clear(),this.surveyValue.onValueChanged.clear(),this.surveyValue.onMatrixCellValueChanging.clear(),this.surveyValue.onMatrixCellValidate.clear(),this.surveyValue.onMatrixCellValueChanged.clear(),this.surveyValue.editingObj=void 0,this.surveyValue.data={},this.surveyValue.dispose()),this.surveyValue=this.createSurvey(o,(function(e){t.onCreateSurvey(e)})),this.obj&&(this.survey.onValueChanged.add((function(e,o){t.onValueChanged(o)})),this.survey.onValueChanging.add((function(e,o){t.onValueChanging(o)})),this.survey.onValidateQuestion.add((function(e,o){t.onValidateQuestion(o)})),this.survey.onGetQuestionTitleActions.add((function(e,o){t.titleActionsCreator.onGetQuestionTitleActions(o),t.onGetQuestionTitleActions(o,t.options);var i=o.question;t.options.onPropertyEditorUpdateTitleActionsCallback(t.obj,i.property,i,o.titleActions)})),this.survey.onGetPanelTitleActions.add((function(e,t){t.titleActions.splice(0,t.titleActions.length)})),this.survey.onMatrixCellCreated.add((function(e,o){t.onMatrixCellCreated(o)})),this.survey.onMatrixCellValueChanging.add((function(e,o){t.onMatrixCellValueChanging(o)})),this.survey.onMatrixCellValidate.add((function(e,o){t.onMatrixCellValidate(o)})),this.survey.onMatrixCellValueChanged.add((function(e,o){t.onMatrixCellValueChanged(o)})),this.survey.onMatrixAllowRemoveRow.add((function(e,o){o.allow=t.getMatrixAllowRemoveRow(o.question,o.row)})),this.survey.onMatrixRowRemoving.add((function(e,o){o.allow=t.getMatrixOnRowRemoving(o.question,o.row)})),this.survey.onMatrixRowAdded.add((function(e,o){t.onMatrixRowAdded(o)})),this.survey.onGetMatrixRowActions.add((function(e,o){t.onGetMatrixRowAction(o)})),this.survey.onUpdateQuestionCssClasses.add((function(e,o){t.onUpdateQuestionCssClasses(o)})),this.survey.onElementContentVisibilityChanged.add((function(e,o){if(!i.propertyGrid.allowExpandMultipleCategories){var n=o.element;n&&n.isPanel&&n.isExpanded&&t.collapseOtherPanels(n)}})),this.survey.onAfterRenderQuestion.add((function(e,o){t.onAfterRenderQuestion(o)})),this.survey.onTextMarkdown.add((function(e,t){var o;"description"===t.name&&(t.html=(o=t.text,(new tt).parse(o)))})),this.survey.editingObj=this.obj,this.objValueChangedCallback&&this.objValueChangedCallback(),this.updateDependedPropertiesEditors(),this.showOneCategoryInPropertyGrid?this.survey.onCurrentPageChanged.add((function(e,o){if(t.currentlySelectedPage!==o.newCurrentPage){var i=o.newCurrentPage.getFirstQuestionToFocus(!1,!0);t.currentlySelectedPage=o.newCurrentPage,t.currentlySelectedProperty=i?i.name:""}})):this.survey.onFocusInPanel.add((function(e,o){if(t.currentlySelectedPanel!==o.panel){var i=o.panel.getFirstQuestionToFocus(!1,!0);t.currentlySelectedProperty=i?i.name:"",t.currentlySelectedPanel=o.panel}})),this.survey.onFocusInQuestion.add((function(e,o){t.currentlySelectedProperty=o.question.name,t.currentlySelectedPanel=o.question.parent})),this.survey.onUploadFiles.add((function(e,o){var i="survey"==o.question.obj.getType()?void 0:"imageitemvalue"==o.question.obj.getType()?o.question.obj.locOwner:o.question.obj,n="imageitemvalue"==o.question.obj.getType()?o.question.obj:void 0;t.options.uploadFiles(o.files,i,(function(e,t){return o.callback(e,[{content:t,file:o.files[0]}])}),{element:o.question.obj,item:n,elementType:o.question.obj.getType(),propertyName:o.name})})),this.survey.getAllQuestions().map((function(e){return e.allowRootStyle=!1})),this.survey.onQuestionCreated.add((function(e,t){t.question.allowRootStyle=!1})),this.options.onPropertyGridSurveyCreatedCallback(this.obj,this.survey))},e.prototype.onCreateSurvey=function(e){var t=this;e.questionErrorLocation="bottom",e.getCss().list={};var o=W({},ze);if(o.root+=this.showOneCategoryInPropertyGrid?" spg-root--one-category":"",e.css=o,this.obj){var i=new at(this.obj,this.options,null,null,this.propertyGridDefinition);if(this.showOneCategoryInPropertyGrid)e.css.page.root+=" spg-panel__content",i.setupPages(e);else{var n=e.createNewPage("p1");i.setupObjPanel(n,!1),e.addPage(n)}e.getAllQuestions().forEach((function(e){nt.onSetup(t.obj,e,e.property,t.options)})),e.enterKeyAction="loseFocus",e.checkErrorsMode="onValueChanging",e.questionErrorComponent="svc-question-error",0===e.pages.length&&e.addNewPage("p1")}},e.prototype.updateCurrentSurveyWithNewDefinition=function(){var e=new o.SurveyModel(this.getSurveyJSON());this.onCreateSurvey(e),this.updateElementsInPanel(this.survey.pages[0],e.pages[0])},e.prototype.updateElementsInPanel=function(e,t){for(var o=e.elements.length-1;o>=0;o--){var i=e.elements[o];(r=t.getElementByName(i.name))&&i.isPanel===r.isPanel?i.isPanel&&r.isPanel&&this.updateElementsInPanel(i,r):e.removeElement(i)}var n=new Array;for(o=0;o<t.elements.length;o++){var r=t.elements[o],a=o+n.length;if(!(a<e.elements.length&&e.elements[a].name===r.name)){var s=e.getElementByName(r.name);s?(e.removeElement(s),e.addElement(s,a)):n.push({element:r,index:o})}}for(o=0;o<n.length;o++)e.addElement(n[o].element,n[o].index)},Object.defineProperty(e.prototype,"options",{get:function(){return this.optionsValue},set:function(e){this.optionsValue=e||new a},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),e.prototype.validate=function(){if(this.survey)return!this.survey.hasErrors(!0,!0)},e.prototype.collapseCategory=function(e){var t=this.survey.getPanelByName(e);t&&t.collapse()},e.prototype.expandCategory=function(e){var t=this.survey.getPanelByName(e);t&&t.expand()},e.prototype.collapseAllCategories=function(){this.collapseAllCategoriesExcept(null)},e.prototype.expandAllCategories=function(){this.survey.getAllPanels().forEach((function(e){e.parent.isPanel||e.expand()}))},e.prototype.collapseOtherPanels=function(e){this.collapseAllCategoriesExcept(e)},e.prototype.collapseAllCategoriesExcept=function(e){this.survey.getAllPanels().forEach((function(t){t===e||t.parent.isPanel||t.collapse()}))},e.prototype.createSurvey=function(e,t){return this.options.createSurvey(e,this.surveyInstanceCreatedArea,this,t)},e.prototype.getSurveyJSON=function(){var e={autoGrowComment:!0,allowResizeComment:!1};return ot(e,!0,!1),e},e.prototype.validateQuestionValue=function(e,t,i,n){if(t.isRequired&&(o.Helpers.isValueEmpty(n)||t.valueChangingEmpty))return this.getErrorTextOnValidate(G.getString("pe.propertyIsEmpty"),i.name,e,n);if(this.isPropNameInValid(e,i,n)||t.nameHasError)return this.getErrorTextOnValidate(G.getString("pe.propertyNameIsIncorrect"),i.name,e,n);var r=nt.validateValue(e,t,i,n);return this.getErrorTextOnValidate(r,i.name,e,n)},e.prototype.getErrorTextOnValidate=function(e,t,o,i){return this.options.onGetErrorTextOnValidationCallback(t,o,i)||e},e.prototype.onValidateQuestion=function(e){var t=e.question;t&&t.property&&(e.error=this.validateQuestionValue(this.obj,t,t.property,e.value))},e.prototype.onValueChanging=function(e){var t=e.question;if(t&&t.property&&(Array.isArray(e.value)||!o.Helpers.isTwoValueEquals(e.value,e.oldValue,!1,!1,!1))){nt.onValueChanging(this.obj,t.property,t,e);var i={obj:this.obj,propertyName:t.property.name,value:e.oldValue,newValue:e.value,doValidation:!1};if(this.options.onValueChangingCallback(i),e.value=i.newValue,t.property.isRequired){var n=o.Helpers.isValueEmpty(e.value);t.valueChangingEmpty=n}var r=this.isPropNameInValid(this.obj,t.property,e.value);t.nameHasError=r}},e.prototype.isPropNameInValid=function(e,t,o){return!(!e.isQuestion||"name"!==t.name||!o)&&(o=o.toLowerCase(),["item","choice","row","panel"].indexOf(o)>-1)},e.prototype.onValueChanged=function(e){var t=this,o=e.question;if(o&&o.property&&(o.valueChangingEmpty=!1,o.nameHasError=!1,this.changeDependedProperties(o,(function(e){return t.survey.getQuestionByName(e)}),(function(e){return t.survey.getValue(e)})),nt.onValueChanged(this.obj,o.property,o),this.classNameProperty&&e.name===this.classNameProperty&&this.classNameValue!==e.value&&(this.setObj(this.obj),this.survey))){var i=this.survey.getQuestionByName(e.name);i&&i.focus()}},e.prototype.changeDependedProperties=function(e,t,i){var n=e.property;if(n){var r=n.getDependedProperties();if(r)for(var a=0;a<r.length;a++){var s=r[a],l=t(s);if(l){this.updateDependedPropertiesEditor(l);var u=i(s);o.Helpers.isTwoValueEquals(l.value,u,!1,!1,!1)||(l.value=u),nt.onMasterValueChanged(e.obj,l.property,l)}}}},e.prototype.updateDependedPropertiesEditor=function(e){var t=e.obj;if(t){var o=e.property;o&&o.onPropertyEditorUpdate&&o.onPropertyEditorUpdate(t,e)}},e.prototype.updateDependedPropertiesEditors=function(){for(var e=this.survey.getAllQuestions(),t=0;t<e.length;t++)this.updateDependedPropertiesEditor(e[t])},e.prototype.onAfterRenderQuestion=function(e){nt.onAfterRenderQuestion(this.obj,e.question.property,e)},e.prototype.onMatrixCellCreated=function(e){this.isCellCreating=!0,nt.onMatrixCellCreated(this.obj,e.question.property,e),this.isCellCreating=!1;var t=e.row.editingObj;if(t){var i=o.Serializer.findProperty(t.getType(),e.columnName);if(i){var n=this.getMatrixAllowEditRow(e.question,e.row);e.cellQuestion.readOnly=!n||at.isPropertyReadOnly(i,this.options,t,this.obj,e.question.property)}}},e.prototype.onMatrixCellValueChanging=function(e){if(!this.isCellCreating){var t={obj:e.row.editingObj,propertyName:e.columnName,value:e.oldValue,newValue:e.value,doValidation:!1};this.options.onValueChangingCallback(t),e.value=t.newValue}},e.prototype.onMatrixCellValidate=function(e){if(!this.isCellCreating){var t=e.row.getQuestionByColumnName(e.columnName);t&&t.property&&(e.error=this.validateQuestionValue(e.row.editingObj,t,t.property,e.value))}},e.prototype.onGetMatrixRowAction=function(e){var t=this;nt.onGetMatrixRowAction(this.obj,e.question.property,e,(function(o){t.setObjFromAction(o,e.question.name)}))},e.prototype.onUpdateQuestionCssClasses=function(e){nt.onUpdateQuestionCssClasses(this.obj,e.question.property,e)},e.prototype.onGetQuestionTitleActions=function(e,t){nt.onGetQuestionTitleActions(this.obj,e.question.property,e,t)},e.prototype.onMatrixCellValueChanged=function(e){if(!this.isCellCreating){var t=e.row.getQuestionByName(e.columnName);t&&this.changeDependedProperties(t,(function(t){return e.row.getQuestionByName(t)}),(function(t){return e.row.getValue(t)})),nt.onMatrixCellValueChanged(this.obj,e.question.property,e)}},e.prototype.getMatrixAllowRemoveRow=function(e,t){return void 0===t.allowDeleteRow&&this.calculateMatrixAllowOperations(e,t),t.allowDeleteRow},e.prototype.getMatrixOnRowRemoving=function(e,t){return this.options.onCollectionItemDeletingCallback(this.obj,e.property,e.value,t.editingObj)},e.prototype.getMatrixAllowEditRow=function(e,t){return!e.readOnly&&(void 0===t.allowEditRow&&this.calculateMatrixAllowOperations(e,t),t.allowEditRow)},e.prototype.calculateMatrixAllowOperations=function(e,t){var o={allowDelete:this.onMatrixAllowRemoveRow(e,t),allowEdit:!0,allowAdd:void 0};this.options.onCollectionItemAllowingCallback(this.obj,e.property,e.value,t.editingObj,o),t.allowDeleteRow=o.allowDelete,t.allowEditRow=o.allowEdit},e.prototype.onMatrixAllowRemoveRow=function(e,t){var o=nt.onMatrixAllowRemoveRow(this.obj,e.property,t);return this.options.onCanDeleteItemCallback(this.obj,t.editingObj,o)},e.prototype.onMatrixRowAdded=function(e){var t=e.row.editingObj;o.Serializer.isDescendantOf(t.getType(),"itemvalue")&&this.options.onItemValueAddedCallback(this.obj,e.question.property.name,e.row.editingObj,e.question.value),o.Serializer.isDescendantOf(t.getType(),"matrixdropdowncolumn")&&this.options.onMatrixDropdownColumnAddedCallback(this.obj,e.row.editingObj,e.question.value)},e}(),lt=function(){function e(){}return e.prototype.showModalPropertyEditor=function(e,t,i,n,r){var a=this,s=i.obj,l=e.createPropertyEditorSetup(s,t,i,n);if(!l)return null;if("condition"!==t.type&&(l.editSurvey.css=o.defaultV2Css),i.isReadOnly&&(l.editSurvey.mode="display"),!o.settings.showDialog)return l;var u=o.surveyLocalization.currentLocale,p=G.currentLocale;o.surveyLocalization.currentLocale=p;var c=o.settings.showDialog({componentName:"survey",data:{survey:l.editSurvey,model:l.editSurvey},onApply:function(){return a.onModalPropertyEditorClosed(e,t,i,n,"apply"),r&&r("apply"),l.apply()},onCancel:function(){a.onModalPropertyEditorClosed(e,t,i,n,"cancel"),r&&r("cancel")},cssClass:"sv-property-editor svc-creator-popup",title:i.title,displayMode:n.isMobileView?"overlay":"popup"},n.rootElement);if(i.isReadOnly){var d=c.footerToolbar.getActionById("apply");d&&(d.visible=!1)}return c.locale=p,o.surveyLocalization.currentLocale=u,this.onModalPropertyEditorShown(e,t,i,n),n.onPropertyGridShowModalCallback(s,t,i,l,c),l},e.prototype.onModalPropertyEditorShown=function(e,t,o,i){},e.prototype.onModalPropertyEditorClosed=function(e,t,o,i,n){},e.prototype.isSupportGrouping=function(){return!1},e.prototype.hasPreviousElementForGrouping=function(e){if(!e||!e.parent)return!1;var t=e.parent.elements.indexOf(e);if(!(t<1)){var o=e.parent.elements[t-1],i=e.parent.elements[t-2];return o.getType()===e.getType()||t>1&&!o.startWithNewLine&&i.property===o.property&&i.getType()===e.getType()}},e.prototype.onUpdateQuestionCssClasses=function(e,t){this.isSupportGrouping()&&this.hasPreviousElementForGrouping(t.question)&&(t.cssClasses.mainRoot+=" spg-row-narrow__question")},e}(),ut=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"boolean"==e.type||"switch"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"boolean",default:!1,renderAs:"checkbox",titleLocation:"hidden"},n=t.getChoices(e,(function(e){}));if(Array.isArray(n)&&n.length>=2){for(var r=[],a=0;a<2;a++){var s=n[a].value||n[a];r.push({value:s,text:G.getPropertyValueInEditor(t.name,s)})}var l=(t.getDefaultValue(e)||r[0].value)===n[1].value?1:0,u=0===l?1:0;i.valueTrue=r[l].value,i.valueFalse=r[u].value,i.labelTrue=r[l].text,i.labelFalse=r[u].text}return i},t.prototype.isSupportGrouping=function(){return!0},t}(lt),pt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"switchToggle"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"boolean",default:!1},n=t.getChoices(e,(function(e){}));if(Array.isArray(n)&&n.length>=2){for(var r=[],a=0;a<2;a++){var s=n[a].value||n[a];r.push({value:s,text:G.getPropertyValueInEditor(t.name,s)})}var l=(t.getDefaultValue(e)||r[0].value)===n[1].value?1:0,u=0===l?1:0;i.valueTrue=r[l].value,i.valueFalse=r[u].value,i.labelTrue=r[l].text,i.labelFalse=r[u].text}return i},t}(lt),ct=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"boolean"==e.type&&!!e.defaultValueFunc&&void 0===e.defaultValueFunc(null)},t.prototype.getJSON=function(e,t,o){return{type:"buttongroup",choices:[{value:"auto",text:G.getString("pe.inherit")},{value:"false",text:G.getString("pe.disabled")},{value:"true",text:G.getString("pe.enabled")}],showOptionsCaption:!1}},t.prototype.onCreated=function(e,t,o,i,n){t.valueFromDataCallback=function(e){return void 0===e?"auto":e.toString()},t.valueToDataCallback=function(e){return"auto"===e?void 0:"true"===e}},t.prototype.onSetup=function(e,t,o,i){var n=e.getPropertyValue(o.name);t.value=void 0===n?"auto":"true"===n},t}(lt),dt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.updateMaxLength=function(e,t){return e.maxLength>0&&(t.maxLength=e.maxLength),t},t.prototype.updateType=function(e,t,o){return!o.maxLength&&t.hasDefaultPropertyValue(e.name)&&(o.type="".concat(o.type,"withreset"),o.renderAs=o.type),o},t.prototype.onCreated=function(e,t,i,n){if(t instanceof o.QuestionTextBase&&(t.onKeyDownPreprocess=function(e){(e.ctrlKey||e.metaKey)&&-1!==[89,90].indexOf(e.keyCode)&&(t.isInputTextUpdate?(n.findSuitableShortcuts(e).forEach((function(e){e.execute(n.selectedElement)})),e.preventDefault()):e.target.value==t.value&&n.findSuitableShortcuts(e).forEach((function(e){e.execute(n.selectedElement)})))}),"title"===i.name&&(t.allowSpaceAsAnswer=!0),"textwithreset"==t.getType()||"commentwithreset"==t.getType()){t.resetValueAdorner.resetValueCallback=function(){e.resetPropertyValue(i.name)},t.resetValueAdorner.caption=G.getString("pe.resetToDefaultCaption");var r=function(){return!i.isDefaultValue(i.getValue(e))};t.resetValueAdorner.allowResetValue=r(),e.registerFunctionOnPropertyValueChanged(i.name,(function(){t.resetValueAdorner.allowResetValue=r()}))}},t}(lt),ht=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string"==e.type},t.prototype.isDefault=function(){return!0},t.prototype.getJSON=function(e,t,o){var i=this.updateType(t,e,this.updateMaxLength(t,{type:"text"}));return t.isRequired&&(i.textUpdateMode="onBlur"),t.dataList&&(i.dataList=t.dataList),i},t.prototype.validateValue=function(e,t,o,i){return mt(e,o,i)},t}(dt),gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"datetime"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"text",inputType:"date"}},t}(lt);function mt(e,t,i){if("imageitemvalue"===e.getType()&&"imageLink"===t.name&&o.Helpers.isUrlYoutubeVideo(i))return G.getString("ed.translationYouTubeNotSupported")}var ft=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"url"===e.type||"file"===e.type},t.prototype.getJSON=function(e,t,o){return{type:"fileedit",storeDataAsText:!1,placeholder:G.getString("pe.fileInputPlaceholder")}},t.prototype.onCreated=function(e,t,o,i){if(["image","imageitemvalue"].indexOf(e.getType())>-1){var n="imageitemvalue"==e.getType()?e.locOwner:e;n&&(n.registerFunctionOnPropertyValueChanged("contentMode",(function(e){t.acceptedTypes=O(e)})),t.acceptedTypes=O(n.contentMode))}else t.acceptedTypes=O("image");t.onChooseFilesCallback=function(o,n){i.chooseFiles(o,n,{element:e,elementType:e.getType(),propertyName:t.name})}},t.prototype.validateValue=function(e,t,o,i){return mt(e,o,i)},t}(lt),yt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"color"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"color",allowEmptyValue:!0}},t}(lt),vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"coloralpha"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"coloralpha",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt),bt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"number"==e.type||"responsiveImageSize"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"text",inputType:"number",textUpdateMode:"onBlur"};return void 0!==t.minValue&&(i.min=t.minValue),void 0!==t.maxValue&&(i.max=t.maxValue),i},t.prototype.onValueChanging=function(e,t,o,i){i.value||0===i.value||(void 0!==t.defaultValue?i.value=t.defaultValue:t.isRequired||""!==i.value?i.value=void 0!==t.minValue&&t.minValue>0?t.minValue:0:i.value=void 0)},t}(lt),Ct=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"spinedit"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"spinedit",descriptionLocation:"hidden"}},t}(lt),wt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string"==e.type&&("imageHeight"==e.name||"imageWidth"==e.name)},t.prototype.isDefault=function(){return!1},t.prototype.onCreated=function(t,i,n,r){e.prototype.onCreated.call(this,t,i,n,r),i.valueFromDataCallback=function(e){var i,n,r,a;return i=t.imageHeight,n=t.imageWidth,r=o.Serializer.findProperty(t.getType(),"imageHeight"),a=o.Serializer.findProperty(t.getType(),"imageWidth"),(r||a)&&r.isDefaultValue(i)&&a.isDefaultValue(n)?void 0:e}},t}(ht),xt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"text"===e.type},t.prototype.getJSON=function(e,t,o){return this.updateType(t,e,this.updateMaxLength(t,{type:"comment",rows:2}))},t}(dt),Tt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"html"===e.type},t.prototype.getJSON=function(e,t,o){return this.updateMaxLength(t,{type:"comment",allowResize:!0,autoGrow:!1})},t}(dt),St=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string[]"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",rows:2}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return Array.isArray(e)?e.join("\n"):""},t.valueToDataCallback=function(e){return e?Array.isArray(e)&&!e.split?e:e.split("\n"):[]}},t}(lt),Pt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"boolean"!==e.type&&(this.isLocaleProp(e)||e.hasChoices)},t.prototype.getJSON=function(e,t,o){var i=this.getChoices(e,t),n={type:this.renderAsButtonGroup(t,i)?"buttongroup":"dropdown",choices:i,showOptionsCaption:!1};return this.updateObjBasedOnEmptyValueItem(t,i,n),n},t.prototype.getChoices=function(e,t){return t.getChoices(e,(function(e){}))},t.prototype.updateObjBasedOnEmptyValueItem=function(e,t,o){var i=this.getEmptyJsonItemValue(e,t);i&&(o.showOptionsCaption=!0,o.allowClear=!0,i.text&&(o.optionsCaption=i.text))},Object.defineProperty(t.prototype,"canRenderAsButtonGroup",{get:function(){return i.propertyGrid.useButtonGroup},enumerable:!1,configurable:!0}),t.prototype.renderAsButtonGroup=function(e,t){if("dropdown"===e.type)return!1;if("buttongroup"===e.type)return!0;if(this.isLocaleProp(e))return!1;if(!this.canRenderAsButtonGroup||!t||0==t.length||t.length>4)return!1;for(var o=0,n=0;n<t.length;n++){var r=this.getLocalizedText(e,t[n].value?t[n].value:t[n]);o+=r?r.length:0}return o<i.propertyGrid.maxCharsInButtonGroup},t.prototype.onCreated=function(e,t,o){this.setChoices(e,t,o),t.displayValueCallback=function(e){return e||t.optionsCaption}},t.prototype.onMasterValueChanged=function(e,t,i){this.setChoices(e,i,t),i.isEmpty()||o.ItemValue.getItemByValue(i.choices,i.value)||i.clearValue()},t.prototype.setChoicesCore=function(e,t,o){o&&Array.isArray(o)&&0!=o.length&&(this.updateObjBasedOnEmptyValueItem(t,o,e),e.choices=this.choicesFromPropChoices(t,o))},t.prototype.isLocaleProp=function(e){return"locale"===e.name},t.prototype.getLocalizedText=function(e,t){var o;return this.isLocaleProp(e)&&(o=G.getLocaleName(t))||"cellType"===e.name&&(o=G.getString("qt."+t))?o:null===t?null:G.getPropertyValueInEditor(e.name,t)},t.prototype.choicesFromPropChoices=function(e,t){for(var i=[],n=0;n<t.length;n++){var r=this.getJsonItem(e,t[n]);o.Helpers.isValueEmpty(r.value)||i.push(r)}return i},t.prototype.getJsonItem=function(e,t){var o={value:void 0!==t.value?t.value:t},i=t.text?t.text:"";return i||(i=this.getLocalizedText(e,o.value)),i&&i!=o.value&&(o.text=i),o},t.prototype.setChoices=function(e,t,o){var i=this,n=o.getChoices(e,(function(e){i.setChoicesCore(t,o,e)}));this.setChoicesCore(t,o,n)},t.prototype.getEmptyJsonItemValue=function(e,t){if(!t)return null;for(var i=0;i<t.length;i++){var n=t[i],r=void 0!==n.value?n.value:n;if(o.Helpers.isValueEmpty(r))return this.getJsonItem(e,n)}return null},t}(lt),Et=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"set"==e.type||"multiplevalues"==e.type},t.prototype.getJSON=function(t,i,n){var r=e.prototype.getJSON.call(this,t,i,n),a=!!o.Serializer.findClass("tagbox");return r.type=a?"tagbox":"checkbox",r.hasSelectAll=!a,r},t}(Pt),Vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.hasChoices&&"page"==e.name},Object.defineProperty(t.prototype,"canRenderAsButtonGroup",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.onCreated=function(t,o,i){e.prototype.onCreated.call(this,t,o,i),o.valueFromDataCallback=function(e){return e?e.name:""},o.valueToDataCallback=function(e){if(e&&t&&t.getSurvey())return t.getSurvey().getPageByName(e)}},t}(Pt),It=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question"==e.type||"questionlist"===e.type},t.prototype.getJSON=function(e,t,o){var i={type:"dropdown",optionsCaption:G.getString("pe.conditionSelectQuestion"),choices:this.getChoices(e,t,o)};return"question"==t.type&&(i.allowClear=!1),i},t.prototype.getChoices=function(e,t,o){var n=this,r=Ze.getSurvey(e);if(!r)return[];var a=this.getQuestions(r,e);a||(a=[]);var s=!!o&&o.showTitlesInExpressions,l=a.map((function(e){var t=s?e.locTitle.renderedHtml:e.name;return o&&(t=o.getObjectDisplayName(e,"property-grid:property-editor","property-editor",t)),{value:n.getItemValue(e),text:t}}));return"asc"===i.logic.questionSortOrder&&ee.sortItems(l),l},t.prototype.getQuestions=function(e,t){return e.getAllQuestions()},t.prototype.getItemValue=function(e){return e.name},t}(lt),At=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question_selectbase"==e.type},t.prototype.isQuestionFit=function(e){return o.Serializer.isDescendantOf(e.getType(),"selectbase")},t.prototype.getQuestions=function(t,o){for(var i=e.prototype.getQuestions.call(this,t,o),n=[],r=0;r<i.length;r++){var a=i[r];a!==o&&this.isQuestionFit(a)&&n.push(a)}return n},t}(It),Ot=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question_carryforward"==e.type},t.prototype.isQuestionFit=function(t){return t.isValueArray||e.prototype.isQuestionFit.call(this,t)},t}(At),Nt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"questionvalue"===e.type||"questionlist-savevaluename"===e.type},t.prototype.getItemValue=function(e){return e.getValueName()},t.prototype.getQuestions=function(t,i){return e.prototype.getQuestions.call(this,t,i).filter((function(e){return!o.Serializer.isDescendantOf(e.getType(),"nonvalue")}))},t}(It);nt.register(new ut),nt.register(new ht),nt.register(new bt),nt.register(new Ct),nt.register(new xt),nt.register(new Tt),nt.register(new Pt),nt.register(new Et),nt.register(new Vt),nt.register(new St),nt.register(new It),nt.register(new Nt),nt.register(new At),nt.register(new Ot),nt.register(new wt),nt.register(new yt),nt.register(new vt),nt.register(new gt),nt.register(new ct),nt.register(new pt),o.QuestionFactory.Instance.registerQuestion("buttongroup",(function(e){return new o.QuestionButtonGroupModel(e)}),!1);var Lt={root:"st-root-modern",container:"st-container-modern",header:"st-title st-container-modern__title",body:"st-body",bodyEmpty:"st-body st-body--empty",footer:"st-footer st-body__footer st-clearfix",title:"",description:"",logo:"st-logo",logoImage:"st-logo__image",headerText:"st-header__text",navigationButton:"",bodyNavigationButton:"st-navigation-btn",completedPage:"st-completedpage",navigation:{complete:"st-btn st-footer__complete-btn",prev:"st-btn st-footer__prev-btn",next:"st-btn st-footer__next-btn",start:"st-btn st-footer__start-btn",preview:"st-btn st-footer__preview-btn",edit:"st-btn st-footer__edit-btn"},panel:{title:"st-title st-panel__title",titleExpandable:"st-panel__title--expandable",titleOnExpand:"st-panel__title--expanded",titleOnError:"st-panel__title--error",description:"st-description st-panel__description",container:"st-element st-panel st-row__panel",content:"st-panel__content",icon:"st-panel__icon",iconExpanded:"st-panel__icon--expanded",footer:"st-panel__footer",requiredText:"st-panel__required-text"},paneldynamic:{root:"st-paneldynamic",navigation:"st-paneldynamic__navigation",title:"st-title st-question__title",button:"st-btn",buttonRemove:"st-paneldynamic__remove-btn",buttonAdd:"st-paneldynamic__add-btn",progressTop:"st-paneldynamic__progress st-paneldynamic__progress--top",progressBottom:"st-paneldynamic__progress st-paneldynamic__progress--bottom",buttonPrev:"st-paneldynamic__prev-btn",buttonNext:"st-paneldynamic__next-btn",progressContainer:"st-paneldynamic__progress-container",progress:"st-progress",progressBar:"st-progress__bar",progressText:"st-paneldynamic__progress-text",separator:"st-paneldynamic__separator",panelWrapper:"st-paneldynamic__panel-wrapper",panelWrapperInRow:"st-paneldynamic__panel-wrapper--in-row"},progress:"st-progress st-body__progress",progressBar:"st-progress__bar",progressText:"st-progress__text",progressTextInBar:"st-hidden",page:{root:"st-page st-body__page",title:"st-title st-page__title",description:"st-description st-page__description"},pageTitle:"st-title st-page__title",pageDescription:"st-description st-page__description",row:"st-row st-clearfix",question:{mainRoot:"st-element st-question st-row__question",flowRoot:"st-element st-question st-row__question st-row__question--flow",asCell:"st-table__cell",header:"st-question__header",headerLeft:"st-question__header--location--left",headerTop:"st-question__header--location--top",headerBottom:"st-question__header--location--bottom",content:"st-question__content",contentLeft:"st-question__content--left",titleLeftRoot:"",titleOnAnswer:"st-question__title--answer",titleOnError:"st-question__title--error",title:"st-title st-question__title",requiredText:"st-question__required-text",number:"st-question__num",description:"st-description st-question__description",descriptionUnderInput:"st-description st-question__description",comment:"st-comment",required:"st-question--required",titleRequired:"st-question__title--required",indent:20,footer:"st-question__footer",formGroup:"st-question__form-group",hasError:"",disabled:"st-question--disabled"},image:{root:"st-image",image:"sv_image_image"},error:{root:"st-question__erbox",icon:"",item:"",locationTop:"st-question__erbox--location--top",locationBottom:"st-question__erbox--location--bottom"},checkbox:{root:"st-selectbase",item:"st-item st-checkbox st-selectbase__item",itemSelectAll:"st-checkbox--selectall",itemNone:"st-checkbox--none",itemDisabled:"st-item--disabled st-checkbox--disabled",itemChecked:"st-item--checked st-checkbox--checked",itemHover:"st-item--allowhover st-checkbox--allowhover",itemInline:"st-selectbase__item--inline",label:"st-selectbase__label",labelChecked:"",itemControl:"st-visuallyhidden st-item__control st-checkbox__control",itemDecorator:"st-item__svg st-checkbox__svg",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-checkbox__decorator",other:"st-comment st-question__other",column:"st-selectbase__column"},radiogroup:{root:"st-selectbase",item:"st-item st-radio st-selectbase__item",itemInline:"st-selectbase__item--inline",label:"st-selectbase__label",labelChecked:"",itemDisabled:"st-item--disabled st-radio--disabled",itemChecked:"st-item--checked st-radio--checked",itemHover:"st-item--allowhover st-radio--allowhover",itemControl:"st-visuallyhidden st-item__control st-radio__control",itemDecorator:"st-item__svg st-radio__svg",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-radio__decorator",other:"st-comment st-question__other",clearButton:"st-btn st-selectbase__clear-btn",column:"st-selectbase__column"},boolean:{mainRoot:"st-question st-row__question st-question--boolean",root:"",item:"st-boolean",control:"st-boolean__control st-visuallyhidden",itemChecked:"st-boolean--checked",itemIndeterminate:"st-boolean--indeterminate",itemDisabled:"st-boolean--disabled",label:"st-boolean__label",switch:"st-boolean__switch",disabledLabel:"st-checkbox__label--disabled",itemDecorator:"st-checkbox__hidden",materialDecorator:"st-checkbox__rectangle",sliderText:"",slider:"st-boolean__thumb"},text:{root:"st-input st-text",small:"st-row__question--small",controlDisabled:"st-input--disabled",onError:"st-input--error"},multipletext:{root:"st-multipletext",item:"st-multipletext__item",itemTitle:"st-multipletext__item-title",row:"st-multipletext__row",cell:"st-multipletext__cell"},dropdown:{root:"st-selectbase",popup:"st-dropdown-popup svc-creator-popup",small:"st-row__question--small",control:"st-input st-dropdown",other:"st-comment st-question__other",onError:"st-input--error",label:"st-selectbase__label",item:"st-item st-radio st-selectbase__item",itemDisabled:"st-item--disabled st-radio--disabled",itemChecked:"st-item--checked st-radio--checked",itemHover:"st-item--allowhover st-radio--allowhover",itemControl:"st-visuallyhidden st-item__control st-radio__control",itemDecorator:"st-item__svg st-radio__svg",controlDisabled:"st-input--disabled",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-radio__decorator"},imagepicker:{root:"st-imagepicker",item:"st-imagepicker__item",itemInline:"st-imagepicker__item--inline",itemChecked:"st-imagepicker__item--checked",itemDisabled:"st-imagepicker__item--disabled",itemHover:"st-imagepicker__item--allowhover",label:"st-imagepicker__label",itemControl:"st-imagepicker__control",image:"st-imagepicker__image",itemText:"st-imagepicker__text",clearButton:"st-btn",other:"st-comment st-question__other"},matrix:{mainRoot:"st-question st-row__question st-scrollable",tableWrapper:"st-matrix",root:"st-table",noHeader:"st-table--no-header",rowError:"st-matrix__row--error",cell:"st-table__cell st-matrix__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text",label:"st-item st-radio st-matrix__label",itemValue:"st-visuallyhidden st-item__control st-radio__control",itemChecked:"st-radio--checked",itemDisabled:"st-item--disabled st-radio--disabled",itemHover:"st-radio--allowhover",materialDecorator:"st-item__decorator st-radio__decorator",itemDecorator:"st-item__svg st-radio__svg",cellText:"st-matrix__text",cellTextSelected:"st-matrix__text--checked",cellTextDisabled:"st-matrix__text--disabled"},matrixdropdown:{mainRoot:"st-question st-row__question st-scrollable",root:"st-table",noHeader:"st-table--no-header",cell:"st-table__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text"},matrixdynamic:{mainRoot:"st-question st-row__question st-scrollable",root:"st-table st-matrixdynamic",noHeader:"st-table--no-header",cell:"st-table__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text",button:"st-btn",detailRow:"st-table__row st-table__row--detail",detailButton:"st-table__cell--detail-button",detailButtonExpanded:"st-table__cell--detail-button--expanded",detailIcon:"st-detail-panel__icon",detailIconExpanded:"st-detail-panel__icon--expanded",detailPanelCell:"st-table__cell--detail-panel",actionsCell:"st-table__cell st-table__cell--actions",buttonAdd:"st-matrixdynamic__add-btn",buttonRemove:"st-matrixdynamic__remove-btn",iconAdd:"",iconRemove:""},rating:{root:"st-rating",item:"st-rating__item",itemHover:"st-rating__item--allowhover",selected:"st-rating__item--selected",minText:"st-rating__item-text st-rating__min-text",itemText:"st-rating__item-text",maxText:"st-rating__item-text st-rating__max-text",itemDisabled:"st-rating__item--disabled"},comment:{root:"st-comment",small:"st-row__question--small"},expression:"",file:{root:"st-file",other:"st-comment st-question__other",placeholderInput:"st-visuallyhidden",preview:"st-file__preview",fileSign:"st-hidden",fileSignBottom:"st-file__sign",fileDecorator:"st-file__decorator",fileInput:"st-visuallyhidden",noFileChosen:"st-description st-file__no-file-chosen",chooseFile:"st-btn st-file__choose-btn",disabled:"st-file__choose-btn--disabled",removeButton:"st-hidden",removeButtonBottom:"st-btn st-file__clean-btn",removeFile:"st-hidden",removeFileSvg:"st-file__remove-svg",wrapper:"st-file__wrapper"},signaturepad:{root:"st-signaturepad sjs_sp_container",small:"st-row__question--small",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",clearButton:"sjs_sp_clear"},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"sv_window",body:"sv_window_content",header:{root:"sv_window_title",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}}};function _t(e,t){if(!Array.isArray(e))return null;for(var o=0;o<e.length;o++)if(e[o].id===t)return e[o];return null}function Mt(e,t,o){var i=_t(t,"remove-row");i&&(i.component="sv-action-bar-item",i.iconName="icon-delete",i.innerCss="spg-action-button spg-action-button--danger",i.title=e.removeRowText,i.showTitle=!1,i.visibleIndex=10,i.action=function(){e.removeRowUI(o)})}function Dt(e){e.forEach((function(e){e.innerCss="".concat(e.innerCss||""," spg-action-button--muted")}))}var kt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),Object.defineProperty(t.prototype,"buttonClassName",{get:function(){return(new o.CssClassBuilder).append("svc-menu-action__button").append("svc-menu-action__button--with-subtitle","text-description-vertical"===this.contentType).append("svc-menu-action__button--pressed",this.pressed).append("svc-menu-action__button--selected",!!this.active).toString()},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:"icon"})],t.prototype,"contentType",void 0),t}(o.Action);function jt(e,t){var o=e.getBoundingClientRect();return t-o.top<=Qt.edgeHeight||o.bottom-t<=Qt.edgeHeight}function Rt(e,t){var o=e.getBoundingClientRect();return t-o.left<=Qt.edgeHeight||o.right-t<=Qt.edgeHeight}function Bt(e,t,i,n){void 0===n&&(n=null);var r=i.height/i.width,a=e-i.x,s=t-i.y;return"top-bottom"==n?s>=i.height/2?o.DragTypeOverMeEnum.Bottom:o.DragTypeOverMeEnum.Top:"left-right"==n?a>=i.width/2?o.DragTypeOverMeEnum.Right:o.DragTypeOverMeEnum.Left:s>=r*a?s>=-r*a+i.height?o.DragTypeOverMeEnum.Bottom:o.DragTypeOverMeEnum.Left:s>=-r*a+i.height?o.DragTypeOverMeEnum.Right:o.DragTypeOverMeEnum.Top}function qt(e){return e instanceof o.QuestionPanelDynamicModel}var Ht,Qt=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.insideContainer=null,t.prevIsEdge=null,t.dragOverIndicatorElement=null,t.isDraggedElementSelected=!1,t.doBanDropHere=function(){t.removeDragOverMarker(t.dragOverIndicatorElement),t.removeDragOverMarker(t.dropTarget)},t.doDrop=function(){var e;if(t.dropTarget){var i=t.parentElement,n=t.draggedElement,r=t.draggedElement;if(n.isPage&&n instanceof o.PageModel){var a=n.survey;return a.pages.splice(a.pages.indexOf(n),1),a.pages.splice(a.pages.indexOf(t.dropTarget)+(t.dragOverLocation===o.DragTypeOverMeEnum.Top?0:1),0,n),n}var s=r.parent||r.page;s&&(i.survey.startMovingQuestion(),s.removeElement(r));var l=(null===(e=t.dragOverIndicatorElement)||void 0===e?void 0:e.isPanel)?t.dragOverIndicatorElement:t.dropTarget;if(qt(l)&&t.insideContainer&&(l=l.template),!(l.isPage&&l.elements.length>0)||t.insideContainer){if((l.isPanel||l.isPage)&&t.insideContainer)l.insertElement(r);else{var u=l.parent||l.page;u&&u.insertElement(r,l,function(){switch(t.dragOverLocation){case 4:return"top";case 5:return"right";case 6:default:return"bottom";case 7:return"left"}}())}return i.survey.stopMovingQuestion(),n}}},t}return K(t,e),Object.defineProperty(t.prototype,"draggedElementType",{get:function(){return this.draggedElement&&this.draggedElement.isPage?"survey-page":"survey-element"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"maxNestedPanels",{get:function(){return this.onGetMaxNestedPanels?this.onGetMaxNestedPanels():-1},enumerable:!1,configurable:!0}),t.prototype.startDragToolboxItem=function(e,t,o){var i=this.createElementFromJson(t);i.toolboxItemTitle=o.title,i.toolboxItemIconName=o.iconName,this.startDrag(e,i)},t.prototype.startDragSurveyElement=function(e,t,o){this.isDraggedElementSelected=o,this.startDrag(e,t)},t.prototype.getShortcutText=function(t){return t.toolboxItemTitle||e.prototype.getShortcutText.call(this,t)},t.prototype.createDraggedElementShortcut=function(e,t,o){var i=document.createElement("div"),n=document.createElement("span");return n.className="svc-dragged-element-shortcut__text",n.innerText=e,this.draggedElement.toolboxItemIconName&&i.appendChild(this.createDraggedElementIcon()),i.appendChild(n),i.className=this.getDraggedElementClass(),i},t.prototype.createDraggedElementIcon=function(){var e=document.createElement("span");e.className="svc-dragged-element-shortcut__icon";var t=this.draggedElement.toolboxItemIconName,o='<svg class="sv-svg-icon" role="img" style="width: 24px; height: 24px;"><use xlink:href="#'.concat(t,'"></use></svg>');return e.innerHTML=o,e},t.prototype.getDraggedElementClass=function(){var e="svc-dragged-element-shortcut";return this.draggedElement.toolboxItemIconName&&(e+=" svc-dragged-element-shortcut--has-icon"),this.isDraggedElementSelected&&(e+=" svc-dragged-element-shortcut--selected"),e},t.prototype.createElementFromJson=function(e){var t=this.createNewElement(e);return t.setSurveyImpl?t.setSurveyImpl(this.survey):t.setData(this.survey),t.renderWidth="100%",t},t.prototype.createNewElement=function(e){var t=o.Serializer.createClass(e.type);return(new o.JsonObject).toObject(e,t),t},t.prototype.findDropTargetNodeByDragOverNode=function(e){if(e.closest(".svc-row--ghost")){var t="[data-sv-drop-target-survey-element='sv-drag-drop-ghost-survey-element-name']",o=e.closest(t)||e.querySelector(t);if(o)return o}return e.closest(this.dropTargetDataAttributeName)},t.prototype.getDropTargetByDataAttributeValue=function(e,o,i){var n=this.dragOverIndicatorElement;if(!e){var r=o.parentElement.closest(this.dropTargetDataAttributeName);e=this.getDataAttributeValueByNode(r)}if(!e)throw new Error("Can't find drop target survey element name");if(e===t.ghostSurveyElementName)return this.prevDropTarget;if("newGhostPage"===e)return t.newGhostPage;var a,s,l=this.survey.getPageByName(e);if(l)return l;if(this.survey.pages.forEach((function(t){var o=t.getElementByName(e);o&&(a=o,s=o)})),"matrixdropdown"!==a.getType()&&"matrixdynamic"!==a.getType()||"none"===a.detailPanelMode||!this.insideContainer||(a=a.detailPanel),!a.page){var u=o.parentElement.closest("[data-sv-drop-target-page]");e=u.dataset.svDropTargetPage;var p=this.survey.getPageByName(e);a.__page=p}return this.dragOverIndicatorElement=s,this.dragOverIndicatorElement!=n&&this.removeDragOverMarker(n),a},t.prototype.isDropTargetValid=function(e,i,n){if(void 0===n&&(n=o.DragTypeOverMeEnum.Top),!e)return!1;if(e===this.draggedElement)return!1;if("paneldynamic"===this.draggedElement.getType()&&e===this.draggedElement.template)return!1;if(this.maxNestedPanels>=0&&this.draggedElement.isPanel){var r=ee.getElementDeepLength(e);if(n!==o.DragTypeOverMeEnum.InsideEmptyPanel&&e.isPanel&&r--,this.maxNestedPanels<r)return!1}return!t.restrictDragQuestionBetweenPages||!this.shouldRestricDragQuestionBetweenPages(e)},t.prototype.shouldRestricDragQuestionBetweenPages=function(e){var t=this.draggedElement.page,o=e.isPage?e:e.page;return t&&t!==o},t.prototype.findDeepestDropTargetChild=function(e){for(var t=this.dropTargetDataAttributeName,o=e;e;)o=e,e=e.querySelector(t);return o},t.prototype.isAllowDragOver=function(e,t){if(!this.survey||this.survey.onDragDropAllow.isEmpty)return!0;var i={allow:!0,parent:this.parentElement,source:this.draggedElement,toElement:e,draggedElement:this.draggedElement,fromElement:this.draggedElement.parent,target:e,insertAfter:void 0,insertBefore:void 0,allowDropNextToAnother:!0};return t!==o.DragTypeOverMeEnum.Bottom&&t!==o.DragTypeOverMeEnum.Right||(i.insertAfter=e),t!==o.DragTypeOverMeEnum.Top&&t!==o.DragTypeOverMeEnum.Left||(i.insertBefore=e),this.survey.onDragDropAllow.fire(this.survey,i),i.allowDropNextToAnother||(t===o.DragTypeOverMeEnum.Left&&(this.dragOverLocation=o.DragTypeOverMeEnum.Top),t===o.DragTypeOverMeEnum.Right&&(this.dragOverLocation=o.DragTypeOverMeEnum.Bottom)),i.allow},t.prototype.dragOverCore=function(e,t){var i=this.dragOverIndicatorElement,n=this.dropTarget;if(this.isSameElement(e))this.allowDropHere=!1;else if(this.dropTarget=e,this.dragOverLocation=t,this.parentElement=this.dropTarget.isPage?this.dropTarget:this.dropTarget.page||this.dropTarget.__page,this.isAllowDragOver(e,t)){if(t==o.DragTypeOverMeEnum.InsideEmptyPanel)this.dragOverIndicatorElement=this.dropTarget,this.dragOverIndicatorElement.dragTypeOverMe=o.DragTypeOverMeEnum.InsideEmptyPanel;else{var r=this.parentElement.dragDropFindRow(this.dropTarget);r&&r.elements.length>1&&(this.dragOverLocation===o.DragTypeOverMeEnum.Top||this.dragOverLocation===o.DragTypeOverMeEnum.Bottom)?(r.dragTypeOverMe=this.dragOverLocation,this.dragOverIndicatorElement=r):(this.dropTarget.dragTypeOverMe=this.dragOverLocation,this.dragOverIndicatorElement=this.dropTarget)}this.dragOverIndicatorElement!=i&&this.removeDragOverMarker(i),this.dropTarget!=n&&this.removeDragOverMarker(n)}else this.allowDropHere=!1},t.prototype.isSameElement=function(e){for(;e;){if(e===this.draggedElement)return!0;e=e.parent}return!1},t.prototype.dragOver=function(e){var t=this.findDropTargetNodeFromPoint(e.clientX,e.clientY);if(t){var n=this.insideContainer;this.insideContainer=!jt(t,e.clientY)&&!Rt(t,e.clientX);var r=this.getDropTargetByNode(t,e);!!n!=!!this.insideContainer&&(r.dragTypeOverMe=null);var a=t.getBoundingClientRect(),s=!i.dragDrop.allowDragToTheSameLine||this.draggedElement&&this.draggedElement.isPage?"top-bottom":null,l=Bt(e.clientX,e.clientY,a,s);r&&((r.isPanel||r.isPage)&&0===r.elements.length||qt(r)&&0==r.template.elements.length)&&(r.isPage||this.insideContainer)&&(l=o.DragTypeOverMeEnum.InsideEmptyPanel);var u={survey:this.survey,draggedSurveyElement:this.draggedElement,dragOverSurveyElement:r,clientX:e.clientX,clientY:e.clientY,dragOverRect:a,insideContainer:this.insideContainer,dragOverLocation:l};this.onDragOverLocationCalculating&&(this.onDragOverLocationCalculating(u),l=u.dragOverLocation,this.insideContainer=u.insideContainer),this.isDropTargetValid(r,t,l)?(this.allowDropHere=!0,this.dragOverCore(r,l)):this.banDropHere()}else this.banDropHere()},t.prototype.onStartDrag=function(){this.draggedElement.isDragMe=!0},t.prototype.moveElementInPanel=function(e,t,o,i){var n=t.parent.elements.indexOf(t);i>n&&i--,t===o&&n===i||(e.removeElement(t),e.addElement(o,i))},t.prototype.removeDragOverMarker=function(e){e&&(e.dragTypeOverMe=null)},t.prototype.clear=function(){this.insideContainer=null,this.removeDragOverMarker(this.prevDropTarget),this.removeDragOverMarker(this.dropTarget),this.removeDragOverMarker(this.dragOverIndicatorElement),this.draggedElement&&(this.draggedElement.isDragMe=!1),e.prototype.clear.call(this)},t.prototype.getTargetParent=function(e){var t=e.isPage||e.isPanel?e:e.parent;return"paneldynamic"===e.getType()&&(t=e.templateValue),t},t.prototype.getTargetRow=function(e){var t;return this.getTargetParent(e).rows.forEach((function(o){-1!==o.elements.indexOf(e)&&(t=o)})),t},t.newGhostPage=null,t.restrictDragQuestionBetweenPages=!1,t.edgeHeight=30,t.nestedPanelDepth=-1,t.ghostSurveyElementName="sv-drag-drop-ghost-survey-element-name",t}(o.DragDropCore),Ft=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.needToShrink=function(e,t){return"start"==e.innerItem.location&&t||"start"!=e.innerItem.location},t.prototype.setModeForActions=function(e,t){var o=this;void 0===t&&(t=[]),this.visibleActions.forEach((function(i){-1==t.indexOf(i.id)?o.needToShrink(i,e)?i.mode=i.canShrink?"small":"removed":i.mode="large":i.mode="removed"}))},t.prototype.calcItemSize=function(e,t,o){return void 0===o&&(o=[]),-1!=o.indexOf(e.id)?0:this.needToShrink(e,t)?e.canShrink?e.minDimension:0:e.maxDimension},t.prototype.fit=function(e,t){var o=this;if(!(e<=0)){this.dotsItem.visible=!1;var i=this.visibleActions;e>=i.reduce((function(e,t){return e+t.maxDimension}),0)?i.forEach((function(e){return e.mode="large"})):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!1)}),0)?this.setModeForActions(!1):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!1,["convertInputType"])}),0)?this.setModeForActions(!1,["convertInputType"]):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!0)}),0)?this.setModeForActions(!0):(this.visibleActions.forEach((function(e){"convertTo"!=e.id?"convertInputType"!=e.id?e.mode="popup":e.mode="removed":e.mode="small"})),this.dotsItem.visible=!0,this.hiddenItemsListModel.setItems(i.filter((function(e){return"popup"==e.mode})).map((function(e){return e.innerItem}))))}},t}(o.AdaptiveActionContainer),Ut=function(e){function t(t,i){var n=e.call(this)||this;return n.creator=t,n.animationCollapsed=new o.AnimationBoolean(n.getExpandCollapseAnimationOptions(),(function(e){n._renderedCollapsed=!e}),(function(){return!n.renderedCollapsed})),n.draggedIn=!1,n.selectedPropPageFunc=function(e,t){"isSelectedInDesigner"===t.name&&n.onElementSelectedChanged(t.newValue)},n.sidebarFlyoutModeChangedFunc=function(e,t){"flyoutMode"===t.name&&n.updateActionsProperties()},n.expandCollapseAction=n.getExpandCollapseAction(),n.createActionContainers(),n.attachToUI(i),n}return K(t,e),Object.defineProperty(t.prototype,"dragInsideCollapsedContainer",{get:function(){return this.collapsed&&this.creator.dragDropSurveyElements.insideContainer},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){return null},t.prototype.getInnerAnimatedElements=function(){return[]},t.prototype.getCollapsingCssClassName=function(){return"svc-question--leave"},t.prototype.getExpandingCssClassName=function(){return"svc-question--enter"},Object.defineProperty(t.prototype,"hoverDelay",{get:function(){return this.creator.pageHoverDelay},enumerable:!1,configurable:!0}),t.prototype.hover=function(e,t){var o=this,i="__svc_question_processed";e[i]||"mouseover"!==e.type?(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0,this.isHovered=!1):(this.hoverTimeout||(this.hoverTimeout=setTimeout((function(){o.isHovered=!0,o.hoverTimeout=void 0}),this.hoverDelay)),e[i]=!0)},t.prototype.getExpandCollapseAnimationOptions=function(){var e=this,t=function(t,i){(0,o.prepareElementForVerticalAnimation)(t);var n=e.getInnerAnimatedElements();n.forEach((function(e){(0,o.prepareElementForVerticalAnimation)(e)})),n.forEach((function(e){e.classList.add(i)}))},i=function(t,i){e.expandCollapseAnimationRunning=!1,(0,o.cleanHtmlElementAfterAnimation)(t);var n=e.getInnerAnimatedElements();n.forEach((function(e){(0,o.cleanHtmlElementAfterAnimation)(e)})),n.forEach((function(e){e.classList.remove(i)}))};return{getRerenderEvent:function(){return e.onElementRerendered},getEnterOptions:function(){var o=e.getExpandingCssClassName();return{cssClass:o,onBeforeRunAnimation:function(e){t(e,o)},onAfterRunAnimation:function(e){i(e,o)}}},getLeaveOptions:function(){var o=e.getCollapsingCssClassName();return{cssClass:o,onBeforeRunAnimation:function(e){t(e,o)},onAfterRunAnimation:function(e){i(e,o)}}},getAnimatedElement:function(){return e.getAnimatedElement()},isAnimationEnabled:function(){return e.animationAllowed}}},Object.defineProperty(t.prototype,"renderedCollapsed",{get:function(){return!!this._renderedCollapsed},set:function(e){this.animationAllowed&&e!==this.renderedCollapsed&&(this.expandCollapseAnimationRunning=!0),this.animationCollapsed.sync(!e)},enumerable:!1,configurable:!0}),t.prototype.createActionContainers=function(){this.actionContainer=this.createActionContainer()},t.prototype.createActionContainer=function(){var e=new Ft;return e.dotsItem.iconSize=16,e.dotsItem.popupModel.horizontalPosition="center",e},Object.defineProperty(t.prototype,"canExpandOnDrag",{get:function(){return this.surveyElement.isPanel||this.surveyElement.isPage||qt(this.surveyElement)},enumerable:!1,configurable:!0}),t.prototype.dragIn=function(){var e=this;this.draggedIn||this.canExpandOnDrag&&this.collapsed&&(this.draggedIn=!0,this.dragCollapsedTimer=setTimeout((function(){e.expandWithDragIn()}),this.creator.expandOnDragTimeOut))},t.prototype.expandWithDragIn=function(){this.collapsed=!1,this.dragCollapsedTimer=void 0},t.prototype.dragOut=function(){this.draggedIn&&(clearTimeout(this.dragCollapsedTimer),this.draggedIn=!1)},t.prototype.dblclick=function(e){this.allowExpandCollapse&&(this.collapsed=!this.collapsed),e.stopPropagation()},t.GetAdorner=function(e){return e.getPropertyValue(t.AdornerValueName)},t.RestoreStateFor=function(e){var o=t.GetAdorner(e);o&&o.restoreState()},t.prototype.restoreState=function(){var e;if(this.surveyElement){var t=null===(e=this.creator.designerStateManager)||void 0===e?void 0:e.getElementState(this.surveyElement);this.collapsed=t.collapsed}},t.prototype.detachElement=function(e){e&&(e.getPropertyValue(t.AdornerValueName)===this&&e.setPropertyValue(t.AdornerValueName,null),e.onPropertyChanged.remove(this.selectedPropPageFunc),this.updateActionsContainer(e,!0))},t.prototype.attachElement=function(e){var o,i;e&&(null===(i=null===(o=this.creator)||void 0===o?void 0:o.designerStateManager)||void 0===i||i.initForElement(e),e.onPropertyChanged.add(this.selectedPropPageFunc),this.restoreState(),this.updateActionsContainer(e),this.updateActionsProperties(),e.setPropertyValue(t.AdornerValueName,this))},t.prototype.setSurveyElement=function(e){this.detachElement(this.surveyElement),this.surveyElement=e,this.attachElement(this.surveyElement)},t.prototype.checkActionProperties=function(){this.creator.isElementSelected(this.surveyElement)&&this.updateActionsProperties()},t.prototype.attachToUI=function(e,t){t&&(this.rootElement=t),this.surveyElement!=e&&(this.setSurveyElement(e),this.creator.sidebar.onPropertyChanged.add(this.sidebarFlyoutModeChangedFunc),this.creator.expandCollapseManager.add(this))},t.prototype.detachFromUI=function(){this.rootElement=void 0,this.detachElement(this.surveyElement),this.surveyElement=void 0,this.creator.sidebar.onPropertyChanged.remove(this.sidebarFlyoutModeChangedFunc),this.creator.expandCollapseManager.remove(this)},t.prototype.dispose=function(){this.detachFromUI(),this.actionContainer.isDisposed||this.actionContainer.dispose(),e.prototype.dispose.call(this)},t.prototype.onElementSelectedChanged=function(e){e&&this.updateActionsProperties()},t.prototype.getExpandCollapseAction=function(){var e=this;return{id:"collapse",css:"sv-action-bar-item--secondary sv-action-bar-item--collapse",iconName:new o.ComputedUpdater((function(){return e.collapsed?"icon-restore_16x16":"icon-collapse-detail-light_16x16"})),iconSize:16,action:function(){e.collapsed=!e.collapsed}}},t.prototype.updateActionsContainer=function(e,t){if(void 0===t&&(t=!1),t)this.actionContainer.actions.forEach((function(e){return e.dispose&&e.dispose()}));else{var o=[];this.buildActions(o),this.creator.onElementMenuItemsChanged(e,o),this.actionContainer.setItems(o)}},t.prototype.updateActionsProperties=function(){this.isDisposed||this.updateElementAllowOptions(this.creator.getElementAllowOperations(this.surveyElement),this.isOperationsAllow())},t.prototype.getAllowDragging=function(e){return e.allowDragging},t.prototype.getAllowExpandCollapse=function(e){return"never"!=this.creator.expandCollapseButtonVisibility&&(null==e.allowExpandCollapse||!!e.allowExpandCollapse)},t.prototype.updateElementAllowOptions=function(e,t){if(this.allowDragging=t&&this.getAllowDragging(e),this.allowExpandCollapse=this.getAllowExpandCollapse(e),this.allowEditOption=null==e.allowEdit||!!e.allowEdit,this.updateActionVisibility("delete",t&&e.allowDelete),this.updateActionVisibility("duplicate",t&&e.allowCopy),this.updateActionVisibility("collapse",this.allowExpandCollapse),void 0===e.allowShowSettings){var o=void 0!==e.allowEdit?t&&e.allowEdit:this.creator.sidebar.flyoutMode;this.updateActionVisibility("settings",o)}else this.updateActionVisibility("settings",e.allowShowSettings);this.setShowAddQuestionButton(!1!==e.allowEdit)},t.prototype.isOperationsAllow=function(){return!this.creator.readOnly},t.prototype.updateActionVisibility=function(e,t){var o=this.getActionById(e);o&&o.visible!=t&&(o.visible=t)},t.prototype.getActionById=function(e){return this.actionContainer.getActionById(e)},t.prototype.buildActions=function(e){var t=this;e.push(new o.Action({id:"duplicate",iconName:"icon-duplicate_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("survey.duplicate"),visibleIndex:10,iconSize:16,action:function(){return t.duplicate()},onFocus:function(e,o){return t.disableActionFocusing(e,o)}})),e.push(new o.Action({id:"settings",iconName:"icon-settings_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("ed.settings"),locTooltipName:"ed.settingsTooltip",visibleIndex:20,iconSize:16,action:function(){t.creator.setShowSidebar(!0,!0),t.creator.isMobileView||t.creator.sidebar.executeOnExpand((function(){t.creator.propertyGrid.getAllQuestions()[0].focus()}))}})),e.push(new o.Action({id:"delete",iconName:"icon-delete_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("pe.delete"),visibleIndex:30,iconSize:16,action:function(){t.delete()},onFocus:function(e,o){return t.disableActionFocusing(e,o)}}))},t.prototype.disableActionFocusing=function(e,t){this.isDisableSelecting=e},t.prototype.canSelectElement=function(){var e=!this.isDisableSelecting;return this.isDisableSelecting=!1,e},Object.defineProperty(t.prototype,"allowEdit",{get:function(){return!!this.creator&&!this.creator.readOnly&&this.allowEditOption},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showAddQuestionButton",{get:function(){return this.getPropertyValue("showAddQuestionButton")},enumerable:!1,configurable:!0}),t.prototype.setShowAddQuestionButton=function(e){this.setPropertyValue("showAddQuestionButton",e&&this.allowEdit&&!!this.creator&&this.creator.showAddQuestionButton)},t.prototype.duplicate=function(){},t.prototype.delete=function(){this.creator.deleteElement(this.surveyElement)},t.prototype.getCss=function(){return(new o.CssClassBuilder).append("svc-hovered svc-hovered-ready",this.isHovered).toString()},t.AdornerValueName="__sjs_creator_adorner",J([(0,o.property)({defaultValue:!0})],t.prototype,"allowDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"expandCollapseAnimationRunning",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowExpandCollapse",void 0),J([(0,o.property)({onSet:function(e,t){t.renderedCollapsed=e,t.creator.designerStateManager&&!t.creator.designerStateManager.isSuspended&&t.surveyElement&&(t.creator.designerStateManager.getElementState(t.surveyElement).collapsed=e),setTimeout((function(){t.creator.survey.pages.forEach((function(e){return e.ensureRowsVisibility()})),t.creator.survey.getAllPanels().forEach((function(e){return e.ensureRowsVisibility()}))}),50)}})],t.prototype,"collapsed",void 0),J([(0,o.property)()],t.prototype,"_renderedCollapsed",void 0),J([(0,o.property)()],t.prototype,"isAnimationRunningCollapsed",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isHovered",void 0),t}(o.Base);n(1868),o.FunctionFactory.Instance.register("localeEnableIf",(function(e){if(Ht||!this.question||!this.row)return!1;var t=this.question.parentQuestion;if(!t)return!1;Ht=!0;var o=t.visibleRows.indexOf(this.row);if(Ht=!1,o<=0)return!1;var n=t.value;if(!Array.isArray(n))return!0;var r=n[o];if(!r||r.isSelected)return!0;for(var a=0,s=1;s<n.length;s++)n[s].isSelected&&a++;return a<i.translation.maximumSelectedLocales}));var Gt=function(e){function t(t,o){var i=e.call(this)||this;return i.name=t,i.translation=o,i}return K(t,e),Object.defineProperty(t.prototype,"isGroup",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.fillLocales=function(e){},t.prototype.mergeLocaleWithDefault=function(e){},t.prototype.makeObservable=function(){this.fireOnObjCreating()},t.prototype.deleteLocaleStrings=function(e){},t.prototype.applyEditLocale=function(e){},t.prototype.fireOnObjCreating=function(e){void 0===e&&(e=null),this.translation&&(e||(e=this),this.translation.fireOnObjCreating(e))},t}(o.Base),Zt=function(e){function t(t,o){var i=e.call(this)||this;return i.locString=t,i.locale=o,i.text=i.locString.getLocaleText(i.locale),i}return K(t,e),t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.isReadOnly||"text"!==t||this.locString.setLocaleText(this.locale,i)},t.prototype.getType=function(){return"translationitemstring"},J([(0,o.property)()],t.prototype,"text",void 0),J([(0,o.property)()],t.prototype,"placeholder",void 0),t}(o.Base),zt=function(e){function t(t,o,i,n,r,a){void 0===i&&(i=""),void 0===a&&(a=null);var s=e.call(this,t,n)||this;s.name=t,s.locString=o,s.defaultValue=i,s.context=r,s.property=a,s.translation&&(s.readOnly=s.translation.readOnly),s.hashValues={};var l=s;return s.afterRender=function(e,t){l.translation&&l.translation.translateItemAfterRender(l,e,t.locale)},s.fireOnObjCreating(),s}return K(t,e),Object.defineProperty(t.prototype,"maxLength",{get:function(){return this.property?this.property.maxLength:-1},enumerable:!1,configurable:!0}),t.prototype.makeObservable=function(){for(var t in e.prototype.makeObservable.call(this),this.hashValues)this.fireOnObjCreating(this.hashValues[t])},t.prototype.getType=function(){return"translationitem"},Object.defineProperty(t.prototype,"text",{get:function(){return this.customText?this.customText:this.localizableName},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localizableName",{get:function(){var e=this.context&&this.context.getType&&this.context.getType();return G.getPropertyNameInEditor(e,this.name)},enumerable:!1,configurable:!0}),t.prototype.getLocText=function(e){return this.locString.getLocaleText(e)},t.prototype.setLocText=function(e,t){this.locString.setLocaleText(e,t),this.translation.tranlationChangedCallback&&this.translation.tranlationChangedCallback(e,this.name,t,this.context)},t.prototype.applyEditLocale=function(e){var t=this.values(e);t&&t.text&&this.setLocText(e,t.text)},t.prototype.values=function(e){var t;if(!this.hashValues[e]){var o=new Zt(this.locString,e);o.isReadOnly=!!(null===(t=this.translation)||void 0===t?void 0:t.getEditLocale()),e||(o.placeholder=this.defaultValue),this.hashValues[e]=o,this.fireOnObjCreating(o)}return this.hashValues[e]},t.prototype.fillLocales=function(e){for(var t=this.getKeys(),i=0;i<t.length;i++){var n=t[i];n&&e.indexOf(n)<0&&n!==o.LocalizableString.defaultLocale&&e.push(n)}},t.prototype.toJSON=function(){var e=this,t=this.locString.getJson(),o=Object.keys(this.hashValues);return o.length>0&&o.forEach((function(o){var i=e.hashValues[o].text;i&&(t||(t={}),"string"==typeof t&&(t={default:t}),t[o]=i)})),(t=this.correctJSON(t))&&"string"!=typeof t?t:{default:t}},t.prototype.correctJSON=function(e){if(!e||"string"==typeof e)return e;if(Array.isArray(e))return e.join("\n");for(var t in e)Array.isArray(e[t])&&(e[t]=e[t].join("\n"));return e},t.prototype.getKeys=function(){return this.locString.getLocales()},t.prototype.mergeLocaleWithDefault=function(e){var t=this.locString.getLocaleText(e);t&&(this.locString.setLocaleText("",t),this.locString.setLocaleText(e,null))},t.prototype.deleteLocaleStrings=function(e){this.setLocText(e,void 0)},t.prototype.getDefaultLocaleText=function(e){void 0===e&&(e=!1);var t=this.locString.getLocaleText("");return t||(t=this.getPlaceholder("",e)),t},t.prototype.getPlaceholder=function(e,t){void 0===t&&(t=!1);var i=e&&"default"!==e?e:o.surveyLocalization.defaultLocale,n=t?"":G.getString("ed.translationPlaceHolder",i);return this.context instanceof o.SurveyModel?o.surveyLocalization.getString(this.name,e)||n:this.context instanceof o.PageModel||"title"!==this.name?"choices"===this.context.ownerPropertyName&&"itemvalue"===this.context.getType()&&(this.getPlaceholderText(e)||this.getItemValuePlaceholderText())||n:this.getPlaceholderText(e)||this.context.name},t.prototype.getTextForExport=function(e){return this.locString.getLocaleText(e)||(e.indexOf("-")<0?"":this.getPlaceholderText(e))},t.prototype.getPlaceholderText=function(e){if(!e||"default"===e)return"";var t=this.getRootDialect(e);return this.locString.getLocaleText(t)},t.prototype.getRootDialect=function(e){var t=e.indexOf("-");return t<0||(e=e.substring(0,t))===o.surveyLocalization.defaultLocale?"":e},t.prototype.getItemValuePlaceholderText=function(){var e=this.context.value;return o.Helpers.isValueEmpty(e)?"":e.toString()},J([(0,o.property)({defaultValue:!1})],t.prototype,"readOnly",void 0),t}(Gt),Jt=function(e){function t(t,o,i,n,r){void 0===i&&(i=null),void 0===n&&(n=""),void 0===r&&(r=!1);var a=e.call(this,t,i)||this;return a.name=t,a.obj=o,a.text=n,a.hasIndent=r,a.isRootValue=!1,a.removeLocale=function(e){a.translation&&a.translation.removeLocale(e)},a.text||(a.text=t),a.reset(),a.fireOnObjCreating(),a}return K(t,e),t.prototype.getType=function(){return"translationgroup"},Object.defineProperty(t.prototype,"items",{get:function(){return this.itemValues},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locItems",{get:function(){return this.itemValues.filter((function(e){return e instanceof zt}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allLocItems",{get:function(){var e=new Array;return this.fillLocItems(e),e},enumerable:!1,configurable:!0}),t.prototype.fillLocItems=function(e){this.itemValues.forEach((function(t){t.isGroup?t.fillLocItems(e):e.push(t)}))},Object.defineProperty(t.prototype,"isRoot",{get:function(){return this.isRootValue},enumerable:!1,configurable:!0}),t.prototype.setAsRoot=function(){this.isRootValue=!0},t.prototype.setParent=function(e){this.parentValue=e},Object.defineProperty(t.prototype,"parent",{get:function(){return this.parentValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fullName",{get:function(){var e=this.obj.name===this.name||this.isRoot?"_props":"",t=this.name+e;if(this.isRoot||!this.parent)return t;var o=this.parent.getNameForChild();return(o?o+"_":"")+t},enumerable:!1,configurable:!0}),t.prototype.getNameForChild=function(){return this.isRoot?"":this.isFinalNameObj?this.name:this.fullName},Object.defineProperty(t.prototype,"isFinalNameObj",{get:function(){return this.obj.isQuestion||this.obj.isPage||this.obj.isPanel},enumerable:!1,configurable:!0}),t.prototype.getItemByName=function(e){for(var t=0;t<this.itemValues.length;t++)if(this.itemValues[t].name==e)return this.itemValues[t];return null},Object.defineProperty(t.prototype,"groups",{get:function(){return this.itemValues.filter((function(e){return e instanceof t}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isGroup",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locales",{get:function(){return this.translation?this.translation.locales:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeLocaleText",{get:function(){return G.getString("pe.remove")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localeCount",{get:function(){return Array.isArray(this.locales)?this.locales.length:0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locWidth",{get:function(){var e=this.localeCount;return e<2?"100%":Math.floor(100/e).toString()+"%"},enumerable:!1,configurable:!0}),t.prototype.getLocaleName=function(e){return this.translation?this.translation.getLocaleName(e):G.getLocaleName(e)},t.prototype.reset=function(){this.itemValues=[],this.fillItems()},t.prototype.fillLocales=function(e){for(var t=0;t<this.items.length;t++)this.items[t].fillLocales(e)},t.prototype.makeObservable=function(){e.prototype.makeObservable.call(this);for(var t=0;t<this.items.length;t++)this.items[t].makeObservable()},Object.defineProperty(t.prototype,"showAllStrings",{get:function(){return!this.translation||this.translation.showAllStrings},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasItems",{get:function(){if(this.locItems.length>0)return!0;for(var e=this.groups,t=0;t<e.length;t++)if(e[t].hasItems)return!0;return!1},enumerable:!1,configurable:!0}),t.prototype.mergeLocaleWithDefault=function(e){this.itemValues.forEach((function(t){return t.mergeLocaleWithDefault(e)}))},t.prototype.deleteLocaleStrings=function(e){this.items.forEach((function(t){return t.deleteLocaleStrings(e)}))},t.prototype.applyEditLocale=function(e){this.items.forEach((function(t){return t.applyEditLocale(e)}))},t.prototype.fillItems=function(){if(this.isItemValueArray(this.obj))this.createItemValuesLocale();else if(this.obj&&this.obj.getType){for(var e=this.getLocalizedProperties(this.obj),o=0;o<e.length;o++){var i=e[o],n=this.createTranslationItem(this.obj,e[o]);n&&this.itemValues.push(n)}for(e=this.getArrayProperties(this.obj),o=0;o<e.length;o++){i=e[o];var r=this.obj[i.name];this.isItemValueArray(r)?this.canShowProperty(i,Array.isArray(r)&&r.length>0)&&this.addNewGroup(new t(i.name,r,this.translation,G.getPropertyName(i.name),!0)):this.createGroups(r,i)}this.createMatrixCellsGroup(),this.sortItems()}},t.prototype.createMatrixCellsGroup=function(){var e=this;o.Serializer.getPropertiesByObj(this.obj).forEach((function(t){"cells"===t.type&&e.canShowProperty(t,!0)&&e.createMatrixCellsGroupCore(t)}))},t.prototype.createMatrixCellsGroupCore=function(e){var i=this,n=this.obj[e.name];if(!n.isEmpty){var r=this.obj,a=new t(e.name,n,this.translation,G.getPropertyName(e.name)),s=[{value:o.settings.matrix.defaultRowName,text:G.getString("qt.default")}];r.rows.forEach((function(e){return s.push({value:e.value,text:e.text})})),s.forEach((function(e){r.columns.forEach((function(t){var o=n.getCellDisplayLocText(e.value,t);if(o){var r=G.getPropertyName(e.text,"")+", "+G.getPropertyName(t.title),s=new zt(r,o,"",i.translation,o);a.items.push(s)}}))})),this.addNewGroup(a)}},t.prototype.sortItems=function(){i.translation.sortByName&&this.itemValues.sort((function(e,t){return e.name?t.name?e.name.localeCompare(t.name):1:-1}))},t.prototype.getLocalizedProperties=function(e){for(var t=[],i=o.Serializer.getPropertiesByObj(e),n=0;n<i.length;n++){var r=i[n];if(!r.readOnly&&r.visible&&r.isSerializable&&r.isLocalizable){var a=["url","file"].indexOf(r.type)<0;this.canShowProperty(r,!!e[r.name],a)&&t.push(r)}}return t},t.prototype.getArrayProperties=function(e){for(var t=[],i=o.Serializer.getPropertiesByObj(e),n=0;n<i.length;n++){var r=i[n];if(!1!==r.isSerializable){var a=e[r.name];a&&Array.isArray(a)&&a.length>0&&t.push(r)}}return t},t.prototype.canShowProperty=function(e,t,o){void 0===o&&(o=!0);var i=Array.isArray(this.obj)?this.obj.length>0?this.obj[0]:void 0:this.obj;return!!i&&(this.translation?this.translation.canShowProperty(i,e,t,o):o)},t.prototype.createTranslationItem=function(e,t){var o,i=this.getDefaultValue(e,t),n=e[t.serializationProperty];if(!n)return null;if(!this.showAllStrings&&!i&&n.isEmpty)return null;var r=null===(o=this.translation)||void 0===o?void 0:o.getEditLocale();return r&&n.getLocaleText(r)?null:this.canShowProperty(t,n.isEmpty)?new zt(t.name,n,i,this.translation,e,t):null},t.prototype.getDefaultValue=function(e,t){if("title"==t.name&&t.isLocalizable&&t.serializationProperty){var o=e[t.serializationProperty];if(o&&!e.isPage&&!e.isPanel&&(o.onGetTextCallback||o.onRenderedHtmlCallback))return e.name}return""},t.prototype.isItemValueArray=function(e){return!!e&&Array.isArray(e)&&e.length>0&&!!e[0]&&!!e[0].getType&&!!e[0].setData&&!!e[0].setLocText},t.prototype.createGroups=function(e,o){for(var i=0;i<e.length;i++){var n=e[i];if(n&&n.getType){var r=n.name,a=r;if(!r){var s="["+i.toString()+"]";r=o.name+s,a=G.getPropertyName(o.name)+s}this.addNewGroup(new t(r,n,this.translation,a))}}},t.prototype.addNewGroup=function(e){e.setParent(this),e.hasItems&&this.itemValues.push(e)},t.prototype.createItemValuesLocale=function(){for(var e,t=null===(e=this.translation)||void 0===e?void 0:e.getEditLocale(),o=0;o<this.obj.length;o++){var i=this.obj[o],n=this.showAllStrings||!i.locText.isEmpty||isNaN(i.value);if(t&&i.locText.getLocaleText(t)&&(n=!1),n){var r=new zt(i.value,i.locText,i.value,this.translation,i);this.itemValues.push(r),this.addCustomPropertiesForItemValue(this.obj[o],r)}}},t.prototype.addCustomPropertiesForItemValue=function(e,t){for(var o=this.getLocalizedProperties(e),i=0;i<o.length;i++)if("text"!=o[i].name){var n=this.createTranslationItem(e,o[i]);n&&(n.customText=t.text+" ("+n.localizableName+")",n.name=e.value+"."+n.name,this.itemValues.push(n))}},J([(0,o.property)({defaultValue:!0})],t.prototype,"showHeader",void 0),t}(Gt),Wt=function(e){function t(t,o,n){void 0===o&&(o=null),void 0===n&&(n=!0);var r=e.call(this)||this;r.options=o,r.hasUI=n,r.chooseLanguageActions=[],r.options||(r.options=new a);var s=r;return r.exportToCSVFileUI=function(){s.exportToSCVFile(i.translation.exportFileName)},r.importFromCSVFileUI=function(e){e.files.length<1||(s.importFromCSVFile(e.files[0]),e.value="")},r.settingsSurveyValue=r.createSettingsSurvey(),r.surveyValue=t,r.setupToolbarItems(),r.updateChooseLanguageActions(),r}return K(t,e),t.prototype.getProcessedTranslationItemText=function(e,t,o,i){return this.options.getProcessedTranslationItemText(e,t,o,i)},t.prototype.getType=function(){return"translation"},t.prototype.getEditLocale=function(){return this.editLocale},t.prototype.setEditMode=function(e){this.editLocale=e,this.addLocale(e)},Object.defineProperty(t.prototype,"isEditMode",{get:function(){return!!this.editLocale},enumerable:!1,configurable:!0}),t.prototype.applyEditLocale=function(){this.isEditMode&&this.root&&this.root.applyEditLocale(this.editLocale)},t.prototype.makeObservable=function(e){this.onBaseObjCreatingCallback=e,this.fireOnObjCreating(this),this.root.makeObservable()},t.prototype.fireOnObjCreating=function(e){this.onBaseObjCreatingCallback&&this.onBaseObjCreatingCallback(e)},Object.defineProperty(t.prototype,"settingsSurvey",{get:function(){return this.settingsSurveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localesQuestion",{get:function(){return this.settingsSurvey.getQuestionByName("locales")},enumerable:!1,configurable:!0}),t.prototype.deleteLocaleStrings=function(e){this.root||this.reset(),this.root&&(this.root.deleteLocaleStrings(e),this.removeLocale(e),this.reset())},t.prototype.createSettingsSurvey=function(){var e=this,t=this.getSettingsSurveyJSON();ot(t);var i=this.options.createSurvey(t,"translation_settings",this,(function(e){e.css=ze,e.css.root+=" st-properties",e.rootCss+=" st-properties"}));return i.onValueChanged.add((function(t,o){"locales"==o.name&&e.updateLocales()})),i.getQuestionByName("locales").lockedRowCount=1,i.onMatrixRowRemoving.add((function(t,o){e.removingLocale=o.question.value[o.rowIndex].name})),i.onMatrixRowRemoved.add((function(t,o){e.removingLocale&&e.deleteLocaleStrings(e.removingLocale)})),i.onGetQuestionTitleActions.add((function(t,o){o.titleActions=[e.addLanguageAction]})),i.onGetMatrixRowActions.add((function(t,i){if(Mt(i.question,i.actions,i.row),e.options.getHasMachineTranslation()&&_t(i.actions,"remove-row")&&Array.isArray(i.question.value)){var n=i.question,r=n.visibleRows.indexOf(i.row);if(r>=0&&r<n.value.length){var a=n.value[r].name;i.actions.splice(0,0,new o.Action({iconName:"icon-language",locTooltipName:"ed.translateUsigAI",location:"end",action:function(){return e.showTranslationEditor(a)}}))}}Dt(i.actions)})),i},t.prototype.calcIsChooseLanguageEnabled=function(){this.isChooseLanguageEnabled=this.chooseLanguageActions.filter((function(e){return e.visible})).length>0},t.prototype.refreshAddLanguageActionListModel=function(){var e=this.addLanguageAction.data;e&&e.refresh()},t.prototype.updateLocales=function(){var e=[""],t=this.getSelectedLocales();Array.isArray(t)||(t=[]),this.options.translationLocalesOrder=t,t.forEach((function(t){return e.push(t)})),this.locales=e,this.canMergeLocaleWithDefault=this.hasLocale(this.defaultLocale),this.localesQuestion.allowRowsDragAndDrop=e.length>2},t.prototype.getSettingsSurveyJSON=function(){return{elements:[{type:"matrixdynamic",name:"locales",title:G.getString("ed.translationLanguages"),confirmDelete:!0,titleLocation:"top",confirmDeleteText:G.getString("ed.translationDeleteLanguage"),columns:[{name:"isSelected",cellType:"boolean",renderAs:"checkbox",enableIf:"localeEnableIf()"},{name:"displayName",cellType:"expression",expression:"{row.displayName}"}],showHeader:!1,allowAddRows:!1,rowCount:0}]}},t.prototype.getSurveyLocales=function(){for(var e=new Array,t=o.surveyLocalization.supportedLocales,i=Array.isArray(t)&&t.length>0?t:o.surveyLocalization.getLocales(),n={},r=0;r<i.length;r++)this.addLocaleIntoChoices(i[r],e,n);for(i=this.getVisibleLocales(),r=0;r<i.length;r++)this.addLocaleIntoChoices(i[r],e,n);return[e,i]},t.prototype.importFromCSVFileDOM=function(){var e=this;document&&(this.inputFileElement||(this.inputFileElement=document.createElement("input"),this.inputFileElement.type="file",this.inputFileElement.style.display="none",this.inputFileElement.onchange=function(){e.importFromCSVFileUI(e.inputFileElement)}),this.inputFileElement.click())},t.prototype.updateSettingsSurveyLocales=function(){var e=this.getSurveyLocales(),t=(e[0],e[1]),o=[];t||(t=[]);for(var n=0;n<t.length;n++)this.localeInitialVisibleCallback&&!this.localeInitialVisibleCallback(t[n])||o.push(t[n]);var r=i.translation.maximumSelectedLocales;r>0&&o.length>r&&o.splice(r),this.setSelectedLocales(o)},t.prototype.resetStringsSurvey=function(){this.hasUI&&(this.stringsSurvey=this.createStringsSurvey(),this.stringsHeaderSurvey=this.createStringsHeaderSurvey(),this.updateReadOnly())},t.prototype.getSurveyStringsArea=function(){},t.prototype.getSurveyStringsHeaderArea=function(){},t.prototype.onSurveyStringsCreated=function(e){},t.prototype.onSurveyStringsHeaderCreated=function(e){},t.prototype.createStringsSurvey=function(){var e=this,t={autoGrowComment:!0,allowResizeComment:!1};ot(t,!1);var i=this.options.createSurvey(t,"translation_strings",this,(function(t){t.lazyRendering=!0,t.skeletonComponentName="sd-translation-line-skeleton",t.startLoadingFromJson(),t.css=Lt,t.addNewPage("page"),e.addTranslationGroupIntoStringsSurvey(t.pages[0],e.root),t.data=e.getStringsSurveyData(t),t.endLoadingFromJson(),e.onSurveyStringsCreated(t)}),this.getSurveyStringsArea()),n=function(e,t){var i=o.ItemValue.getItemByValue(e.rows,t);return i?i.translationData:null};return i.onMatrixCellCreated.add((function(t,i){if(i.cell.question instanceof o.QuestionCommentModel){var r=i.cell.question,a=n(i.question,i.row.name);e.setPlaceHolder(r,a,i.columnName);var s=!!a&&a.locString.getIsMultiple();r.acceptCarriageReturn=s,a&&(r.maxLength=a.maxLength),s||(r.rows=1)}})),i.onMatrixCellValueChanging.add((function(t,o){var i=n(o.question,o.row.name);i&&(o.value=e.getProcessedTranslationItemText(o.columnName,i.locString,o.value,i.context))})),i.onMatrixCellValueChanged.add((function(t,o){var i=n(o.question,o.row.name);if(i){i.setLocText(o.columnName,o.value);var r=o.columnName;o.row.cells.forEach((function(t){"default"!==r&&0!==t.column.name.indexOf(r+"-")||e.setPlaceHolder(t.question,i,t.column.name)}))}})),i.onUpdatePanelCssClasses.add((function(e,t){t.panel.__translationHasIndent&&(t.cssClasses.panel.content+=" st-panel-indent")})),i.currentPage=i.pages[0],i},t.prototype.setPlaceHolder=function(e,t,o){e.placeholder=t.getPlaceholder(o)},t.prototype.createStringsHeaderSurvey=function(){var e=this,t={};return ot(t,!1),this.options.createSurvey(t,"translation_strings_header",this,(function(t){t.css=Lt;var i=t.addNewPage("page"),n=o.Serializer.createClass("matrixdropdown");n.name="stringsHeader",n.titleLocation="hidden",e.addLocaleColumns(n),i.addQuestion(n,0),t.currentPage=t.pages[0],e.onSurveyStringsHeaderCreated(t)}),this.getSurveyStringsHeaderArea())},t.prototype.addTranslationGroupIntoStringsSurvey=function(e,t){for(var i=0;i<t.items.length;i++)if(!t.items[i].isGroup){var n=t.items[i],r=o.Serializer.createClass("matrixdropdown");r.cellType="comment",r.titleLocation="hidden",r.name=t.fullName+i,r.showHeader=!1,e.addQuestion(r),this.addLocaleColumns(r);var a=new o.ItemValue(n.name,n.text);a.translationData=n,r.rows.push(a)}for(i=0;i<t.items.length;i++)if(t.items[i].isGroup){n=t.items[i];var s=o.Serializer.createClass("panel");s.name=n.name,e.addElement(s),s.title=n.text,n.hasIndent&&(s.__translationHasIndent=!0),this.addTranslationGroupIntoStringsSurvey(s,n)}},t.prototype.addLocaleColumns=function(e){var t=this.getSelectedLocales();e.addColumn("default",this.getLocaleName("")).readOnly=this.isEditMode;for(var o=0;o<t.length;o++)e.addColumn(t[o],this.getLocaleName(t[o]))},t.prototype.getStringsSurveyData=function(e){for(var t={},o=e.getAllQuestions(),i=0;i<o.length;i++)t[o[i].name]=this.getStringsQuestionData(o[i]);return t},t.prototype.updateStringsSurveyData=function(){var e=this.stringsSurvey;e&&(e.data=this.getStringsSurveyData(e))},t.prototype.getStringsQuestionData=function(e){for(var t={},i=0;i<e.rows.length;i++){var n=e.rows[i],r=n.translationData.toJSON();o.Helpers.isValueEmpty(r)||(t[n.value]=r)}return t},t.prototype.updateHeaderStringsSurveyColumns=function(){if(this.stringsHeaderSurvey){var e=this.stringsHeaderSurvey.getQuestionByName("stringsHeader");e.columns=[],this.addLocaleColumns(e)}},t.prototype.updateStringsSurveyColumns=function(){if(this.stringsSurvey)for(var e=this.stringsSurvey.getAllQuestions(),t=0;t<e.length;t++){var o=e[t];o.beginUpdate(),o.columns=[],this.addLocaleColumns(o),o.endUpdate()}},t.prototype.addLocaleIntoChoices=function(e,t,i){e&&!i[e]&&(i[e]=!0,t.push(new o.ItemValue(e,this.getLocaleName(e))))},t.prototype.addLocaleIntoValue=function(e,t){var o=this.getVisibleLocales();if(o.indexOf(e)<0&&(o.push(e),this.setVisibleLocales(o)),t){var n=this.getSelectedLocales();n.indexOf(e)<0&&n.length<i.translation.maximumSelectedLocales&&(n.push(e),this.setSelectedLocales(n))}},t.prototype.isLocaleVisible=function(e,t){return t!==o.surveyLocalization.defaultLocale&&e.indexOf(t)<0},t.prototype.setupToolbarItems=function(){var e=this;this.chooseLanguageActions=this.getSurveyLocales()[0].map((function(t){return new o.Action({id:t.value,title:e.getLocaleName(t.value),data:t})})),this.addLanguageAction=(0,o.createDropdownActionModel)({id:"svc-translation-choose-language",iconName:"icon-add",enabled:new o.ComputedUpdater((function(){return e.isChooseLanguageEnabled&&!e.readOnly}))},{items:this.chooseLanguageActions,allowSelection:!1,cssClass:"svc-creator-popup",onSelectionChanged:function(t){e.addLocale(t.id)}})},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"canMergeLocaleWithDefault"===t&&(this.mergeLocaleWithDefaultText=this.getMergeLocaleWithDefaultText()),"locales"===t&&(this.updateHeaderStringsSurveyColumns(),this.updateStringsSurveyColumns())},t.prototype.getMergeLocaleWithDefaultText=function(){if(!this.canMergeLocaleWithDefault)return"";var e=this.getLocaleName(this.defaultLocale);return G.getString("ed.translationMergeLocaleWithDefault").format(e)},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},set:function(e){this.surveyValue=e,this.setVisibleLocales([]),this.reset()},enumerable:!1,configurable:!0}),t.prototype.reset=function(e){if(void 0===e&&(e=!0),e||!this.root){var t=this.filteredPage?this.filteredPage:this.survey,o=this.filteredPage?t.name:"survey";this.root=new Jt(o,t,this),this.root.setAsRoot(),this.root.reset(),this.resetLocales(),this.isEmpty=!this.root.hasItems,this.updateSettingsSurveyLocales(),this.updateLocales(),this.resetStringsSurvey(),this.updateChooseLanguageActions()}},t.prototype.updateReadOnly=function(){if(this.stringsSurvey){var e=this.readOnly?"display":"edit";this.stringsSurvey.mode=e,this.settingsSurvey.mode=e}},t.prototype.canShowProperty=function(e,t,o,i){void 0===i&&(i=!0);var n=i&&(!o||ee.isPropertyVisible(e,t,this.options));return this.translationStringVisibilityCallback?this.translationStringVisibilityCallback(e,t.name,n):n},Object.defineProperty(t.prototype,"defaultLocale",{get:function(){return o.surveyLocalization.defaultLocale},enumerable:!1,configurable:!0}),t.prototype.getLocaleName=function(e,t){return G.getLocaleName(e,this.defaultLocale,t)},t.prototype.removeLocale=function(e){if(this.hasLocale(e)){var t=this.locales.indexOf(e),o=this.locales;o.splice(t,1),this.locales=o,this.canMergeLocaleWithDefault=this.hasLocale(this.defaultLocale)}},t.prototype.hasLocale=function(e){return this.locales.indexOf(e)>-1},t.prototype.addLocale=function(e){this.hasLocale(e)||this.addLocaleIntoValue(e,!0),this.updateChooseLanguageActions()},t.prototype.updateChooseLanguageActions=function(){var e=this,t=this.chooseLanguageActions,o=this.getVisibleLocales();Array.isArray(t)&&t.forEach((function(t){return t.visible=e.isLocaleVisible(o,t.data.value)})),this.refreshAddLanguageActionListModel(),this.calcIsChooseLanguageEnabled()},t.prototype.resetLocales=function(){var e=[""];this.root.fillLocales(e);var t=this.options.translationLocalesOrder;if(Array.isArray(t)&&t.length>0){var o=function(e,t,o){var i=o.indexOf(e),n=o.indexOf(t);return i<0&&(i=100),n<0&&(n=100),i<n?-1:i>n?1:0};e.sort((function(i,n){var r=o(i,n,t);return 0===r?o(i,n,e):r}))}this.setSelectedAndVisibleLocales(e,this.getSelectedLocales(),!0)},t.prototype.getSelectedLocales=function(){return this.getSelectedLocalesCore(!0)},t.prototype.setSelectedLocales=function(e){this.setSelectedAndVisibleLocales(this.getVisibleLocales(),e,!0)},t.prototype.getVisibleLocales=function(){return this.getSelectedLocalesCore(!1)},t.prototype.setVisibleLocales=function(e){this.setSelectedAndVisibleLocales(e,this.getSelectedLocales(),!1)},t.prototype.getSelectedLocalesCore=function(e){if(!this.localesQuestion)return[];var t=this.localesQuestion.value;if(!Array.isArray(t)||0===t.length)return[];var o=[];return t.forEach((function(t){!t.name||e&&!t.isSelected||o.push(t.name)})),o},t.prototype.setSelectedAndVisibleLocales=function(e,t,o){var i=this;if(this.localesQuestion){Array.isArray(t)||(t=[]);var n=[];o&&t.forEach((function(t){e.indexOf(t)<0&&e.push(t)}));var r=this.defaultLocale;n.push({isSelected:!0,name:"",displayName:this.getLocaleName("")}),this.getEditLocale()?n.push({isSelected:!0,name:this.getEditLocale()}):e.forEach((function(e){e&&n.push({isSelected:e===r||t.indexOf(e)>-1,name:e,displayName:i.getLocaleName(e)})})),this.localesQuestion.value=n}},Object.defineProperty(t.prototype,"noStringsText",{get:function(){return G.getString("ed.translationNoStrings")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.options.isMobileView?Z("ed.translationsPlaceholderTitleMobile"):Z("ed.translationsPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.options.isMobileView?Z("ed.translationsPlaceholderDescriptionMobile"):Z("ed.translationsPlaceholderDescription")},enumerable:!1,configurable:!0}),t.prototype.exportToCSV=function(){this.root||this.reset();var e=[],o=[],n=this.locales;o.push("description ↓ - language →");for(var r=0;r<n.length;r++)o.push(n[r]?n[r]:"default");e.push(o);var a={};for(var s in this.fillItemsHash("",this.root,a),a){var l=[s],u=a[s];for(r=0;r<n.length;r++){var p=n[r],c=u.getTextForExport(p);c=c||0!=r?c:u.defaultValue,c=this.options.getTranslationExportedText(u.context,u.name,u.locString,p,c),l.push(c||0!=r?c:u.defaultValue)}e.push(l)}var d=i.translation.exportPrefix;return d||(d=""),d+(0,Ge.unparse)(e,{quoteChar:'"',escapeChar:'"',delimiter:t.csvDelimiter,header:!0,newline:t.newLineDelimiter,skipEmptyLines:!1,columns:null})},t.prototype.importFromNestedArray=function(e){var o=this,i=e.shift().slice(1);"default"===i[0]&&(i[0]="");var n=new t(this.survey,this.options,!1);n.showAllStrings=!0;var r={};this.fillItemsHash("",n.root,r),e.forEach((function(e){var t=e.shift().trim();if(t){var n=r[t];n&&o.updateItemWithStrings(t,n,e,i)}})),this.reset(),this.importFinishedCallback&&this.importFinishedCallback()},t.prototype.exportToSCVFile=function(e){if(window){var t=this.exportToCSV(),o=new Blob([t],{type:"text/csv"});if(window.navigator.msSaveOrOpenBlob)window.navigator.msSaveBlob(o,e);else{var i=window.document.createElement("a");i.href=window.URL.createObjectURL(o),i.download=e,document.body.appendChild(i),i.click(),document.body.removeChild(i)}}},t.prototype.importFromCSVFile=function(e){var t=this;(0,Ge.parse)(e,{complete:function(e,o){t.importFromNestedArray(e.data)}})},t.prototype.mergeLocaleWithDefault=function(){this.reset(!1),this.hasLocale(this.defaultLocale)&&(this.root.mergeLocaleWithDefault(this.defaultLocale),this.setVisibleLocales([]),this.setSelectedLocales([]),this.reset())},t.prototype.createTranslationEditor=function(e){var t=this,o=new Yt(this.survey,e,this.options);return o.onApply=function(){t.reset()},o},t.prototype.showTranslationEditor=function(e){this.createTranslationEditor(e).showDialog()},t.prototype.translateItemAfterRender=function(e,t,o){if(this.translateItemAfterRenderCallback){if(Array.isArray(t))for(var i=0;i<t.length;i++)if("TEXTAREA"==t[i].tagName){t=t[i];break}this.translateItemAfterRenderCallback(e,t,o)}},t.prototype.updateItemWithStrings=function(e,t,o,i){for(var n=0;n<o.length&&n<i.length;n++){var r=o[n].trim();r&&(this.importItemCallback&&(r=this.importItemCallback(e,i[n],r)),r&&(t.values(i[n]).text=r))}},t.prototype.fillItemsHash=function(e,t,o){var i=this,n=e?e+"."+t.name:t.name;t.locItems.forEach((function(e){o[n+"."+e.name]=e})),t.groups.forEach((function(e){return i.fillItemsHash(n,e,o)}))},t.prototype.dispose=function(){this.isEmpty=!0,this.stringsSurvey&&(this.stringsSurvey.dispose(),this.stringsSurvey=void 0),this.stringsHeaderSurvey&&(this.stringsHeaderSurvey.dispose(),this.stringsHeaderSurvey=void 0),this.settingsSurveyValue&&(this.settingsSurveyValue.dispose(),this.settingsSurveyValue=void 0),this.importFinishedCallback=void 0,this.availableTranlationsChangedCallback=void 0,this.tranlationChangedCallback=void 0,e.prototype.dispose.call(this)},t.csvDelimiter=",",t.newLineDelimiter="\n",J([(0,o.propertyArray)()],t.prototype,"locales",void 0),J([(0,o.property)()],t.prototype,"canMergeLocaleWithDefault",void 0),J([(0,o.property)()],t.prototype,"mergeLocaleWithDefaultText",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.updateReadOnly()}})],t.prototype,"readOnly",void 0),J([(0,o.property)()],t.prototype,"root",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.reset()}})],t.prototype,"showAllStrings",void 0),J([(0,o.property)({onSet:function(e,t){t.reset()}})],t.prototype,"filteredPage",void 0),J([(0,o.property)()],t.prototype,"stringsSurvey",void 0),J([(0,o.property)()],t.prototype,"stringsHeaderSurvey",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isEmpty",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isChooseLanguageEnabled",void 0),t}(o.Base),Kt=function(e){function t(t,o,i){var n=e.call(this,t,o,!0)||this;return n.surveyStringsHeaderCreatedCallback=i,n}return K(t,e),t.prototype.getSurveyStringsArea=function(){return"translation-tab:table-popup-editor"},t.prototype.getSurveyStringsHeaderArea=function(){return"translation-tab:table-header-popup-editor"},t.prototype.onSurveyStringsHeaderCreated=function(e){this.surveyStringsHeaderCreatedCallback(e)},t}(Wt),Yt=function(){function e(e,t,o){var i=this;this.fromLocales=[],this.survey=e,this.options=o,this.locale=t,this.translationValue=new Kt(this.survey,this.options,(function(e){i.setupNavigationButtons(e)})),this.translation.setEditMode(this.locale),this.translation.reset(),this.fillFromLocales(),this.updateFromLocaleAction(),this.updateMatricesColumns()}return Object.defineProperty(e.prototype,"translation",{get:function(){return this.translationValue},enumerable:!1,configurable:!0}),e.prototype.showDialog=function(){var e=this,t=G.getString("ed.translationDialogTitle")+" ("+this.translation.getLocaleName(this.locale)+")";if(0===this.translation.stringsSurvey.getAllQuestions(!0).length){var i=new o.LocalizableString(this.translation.stringsSurvey);i.text=G.getString("ed.translationNoStrings");var n=o.settings.showDialog({componentName:"sv-string-viewer",data:{locStr:i,locString:i,model:i},onApply:function(){return!0},cssClass:"svc-creator-popup",title:t,displayMode:"popup"},this.options.rootElement).footerToolbar.actions;return n.splice(1,n.length-1),void(n[0].title="OK")}o.settings.showDialog({componentName:"svc-tab-translation",data:{model:this.translation},onApply:function(){return e.apply(),!0},onHide:function(){e.dispose()},cssClass:"sv-property-editor st-translation-dialog svc-creator-popup",title:t,displayMode:this.options.isMobileView?"overlay":"popup"},this.options.rootElement).locale=G.currentLocale},e.prototype.doMachineTranslation=function(){var e=this,t=this.fromLocale||this.translation.defaultLocale;t||(t="en");var o=this.createStringsToTranslate(),i=[];o.forEach((function(t){i.push(e.getTextToTranslate(t))})),this.options.doMachineTranslation(t,this.locale,i,(function(t){if(Array.isArray(t)){for(var i=0;i<Math.min(o.length,t.length);i++)o[i].values(e.locale).text=t[i];e.translation.updateStringsSurveyData()}}))},e.prototype.apply=function(){this.translation.applyEditLocale(),this.onApply&&this.onApply()},e.prototype.cancel=function(){this.dispose()},e.prototype.dispose=function(){this.translationValue.dispose()},e.prototype.setFromLocale=function(e){this.fromLocale!==e&&(this.fromLocale=e,this.updateMatricesColumns())},e.prototype.updateMatricesColumns=function(){var e=this;this.translation.stringsHeaderSurvey.getAllQuestions().forEach((function(t){e.updateMatrixColumns(t),e.updateHeaderMatrixColumns(t)}));for(var t=this.translation.stringsSurvey.getAllQuestions(),o=0;o<t.length;o++)this.updateMatrixColumns(t[o])},e.prototype.updateHeaderMatrixColumns=function(e){var t=e.columns;t[0].title=this.translation.getLocaleName(""),t.length>2?(t[1].title=this.getHeaderTitle("translationSource",t[1].name),t[2].title=this.getHeaderTitle("translationTarget",t[2].name)):t[1].title=this.getHeaderTitle("translationTarget",t[1].name)},e.prototype.updateMatrixColumns=function(e){3===e.columns.length&&e.columns.splice(1,1);var t=this.fromLocale;if(t){var i=new o.MatrixDropdownColumn(t,this.translation.getLocaleName(t));i.readOnly=!0,e.columns.splice(1,0,i)}},e.prototype.getHeaderTitle=function(e,t){return G.getString("ed."+e)+this.translation.getLocaleName(t)},e.prototype.fillFromLocales=function(){var e=this;this.fromLocales=[],this.createStringsToTranslate().forEach((function(t){t.fillLocales(e.fromLocales)}))},e.prototype.setupNavigationButtons=function(e){var t=this,i=new Ft;e.navigationBarValue=i,e.findLayoutElement("buttons-navigation").data=i,i.locOwner=e,i.cssClasses=e.css.actionBar,i.containerCss=e.css.footer,e.addNavigationItem(this.createLocaleFromAction());var n="svc-action-bar-item--right sv-action-bar-item--secondary";this.options.getHasMachineTranslation()&&e.addNavigationItem(new o.Action({id:"svc-translation-machine",iconName:"icon-language",css:n,locTitleName:"ed.translateUsigAI",component:"sv-action-bar-item",action:function(){t.doMachineTranslation()}}));var r=Xt((function(){t.translation.importFromCSVFileDOM()}),!1,!0);r.css=n;var a=$t((function(){t.translation.exportToCSVFileUI()}),!0);a.css=n,e.addNavigationItem(r),e.addNavigationItem(a),e.showNavigationButtons="top"},e.prototype.createStringsToTranslate=function(){var e=this,t=new Array;return this.fromLocale,this.translation.root.allLocItems.forEach((function(o){e.getTextToTranslate(o)&&t.push(o)})),t},e.prototype.getTextToTranslate=function(e){var t=this.fromLocale||"",o=e.getLocText(t);return o||t||(o=e.getDefaultLocaleText(!0)),o},e.prototype.createLocaleFromAction=function(){var e=this,t=this.getActionTranslateFromText(""),i=(0,o.createPopupModelWithListModel)({items:[{id:null,title:t}],onSelectionChanged:function(t){var o=t.id||"";e.setFromLocale(o),n.title=e.getActionTranslateFromText(o)},allowSelection:!0},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var o=[{id:null,title:t}];e.fromLocales.forEach((function(t){o.push({id:t,title:e.getActionTranslateFromText(t)})})),n.popupModel.contentComponentData.model.setItems(o)}}),n=new o.Action({id:"svc-translation-fromlocale",component:"svc-translate-from-action",css:"st-translation-machine-from",location:"start",title:t,iconSize:"auto",innerCss:"st-translation-machine-from__btn",data:{additionalTitleCss:"st-translation-machine-from__title",additionalTitle:G.getString("ed.translateUsigAIFrom")},popupModel:i,action:function(){i.toggleVisibility()}});return n},e.prototype.updateFromLocaleAction=function(){var e=this.translation.stringsHeaderSurvey.findLayoutElement("buttons-navigation").data.getActionById("svc-translation-fromlocale");e&&(e.enabled=this.fromLocales.length>0,e.iconName=e.enabled?"icon-chevron_16x16":void 0,e.data.containerCss=(new o.CssClassBuilder).append("st-translation-machine-from__container").append("st-translation-machine-from__container--disabled",!e.enabled).toString())},e.prototype.getActionTranslateFromText=function(e){return e=e||"",this.translation.getLocaleName(e)},e}();function Xt(e,t,i){return void 0===i&&(i=!1),new o.Action({id:"svc-translation-import",iconName:"icon-load",locTitleName:"ed.translationImportFromSCVButton",locTooltipName:"ed.translationImportFromSCVButton",mode:i?"large":"small",component:"sv-action-bar-item",needSeparator:t,action:e})}function $t(e,t){return void 0===t&&(t=!1),new o.Action({id:"svc-translation-export",iconName:"icon-download",locTitleName:"ed.translationExportToSCVButton",locTooltipName:"ed.translationExportToSCVButton",mode:t?"large":"small",component:"sv-action-bar-item",action:e})}var eo=function(){function e(e){this.creator=e,e.addPluginTab("translation",this),this.sidebarTab=this.creator.sidebar.addPage("translation"),this.sidebarTab.caption=G.getString("ed.translationPropertyGridTitle"),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.activate=function(){var e=this;this.model=new Wt(this.creator.survey,this.creator),this.model.settingsSurvey.locale=this.creator.locale,this.model.readOnly=this.creator.readOnly,this.model.translationStringVisibilityCallback=function(t,o,i){var n={obj:t,propertyName:o,visible:i};return!e.creator.onTranslationStringVisibility.isEmpty&&e.creator.onTranslationStringVisibility.fire(e.creator,n),n.visible},this.model.localeInitialVisibleCallback=function(t){var o={locale:t,isSelected:!0};return e.creator.onTranslationLocaleInitiallySelected.fire(e.creator,o),o.isSelected},this.model.importItemCallback=function(t,o,i){var n={locale:o,name:t,text:i};return e.creator.onTranslationImportItem.fire(e.creator,n),n.text},this.model.importFinishedCallback=function(){e.creator.onTranslationImported.fire(e.creator,{})},this.sidebarTab.componentData=this.model.settingsSurvey,this.sidebarTab.componentName="survey-widget",this.creator.sidebar.activePage=this.sidebarTab.id,this.mergeLocaleWithDefaultAction.title=this.createMergeLocaleWithDefaultActionTitleUpdater(),this.mergeLocaleWithDefaultAction.tooltip=this.createMergeLocaleWithDefaultActionTitleUpdater(),this.mergeLocaleWithDefaultAction.visible=this.model.canMergeLocaleWithDefault,this.filterPageAction.visible=this.creator.survey.pageCount>1,this.updateFilterPageAction(!0),this.filterStringsAction.visible=!0,this.updateFilterStrigsAction(!0),this.importCsvAction.visible=!0,this.exportCsvAction.visible=!0,this.filterPageAction.data.setItems([{id:null,title:this.showAllPagesText}].concat(this.creator.survey.pages.map((function(t){return{id:t.name,title:e.getPageDisplayText(t)}}))),!1),this.model.onPropertyChanged.add((function(t,o){"filteredPage"===o.name&&e.updateFilterPageAction(),"showAllStrings"===o.name&&e.updateFilterStrigsAction(),"canMergeLocaleWithDefault"===o.name&&(e.mergeLocaleWithDefaultAction.visible=e.model.canMergeLocaleWithDefault),"mergeLocaleWithDefaultText"===o.name&&(e.mergeLocaleWithDefaultAction.title=e.model.mergeLocaleWithDefaultText,e.mergeLocaleWithDefaultAction.tooltip=e.model.mergeLocaleWithDefaultText)})),this.model.reset()},e.prototype.update=function(){this.model&&(this.model.survey=this.creator.survey,this.model.filteredPage=null,this.updateFilterPageAction(!0))},e.prototype.deactivate=function(){return this.model&&this.model.dispose(),this.model=void 0,this.sidebarTab.visible=!1,this.filterStringsAction.visible=!1,this.filterPageAction.visible=!1,this.mergeLocaleWithDefaultAction.title=void 0,this.mergeLocaleWithDefaultAction.tooltip=void 0,this.mergeLocaleWithDefaultAction.visible=!1,this.importCsvAction.visible=!1,this.exportCsvAction.visible=!1,!0},e.prototype.createMergeLocaleWithDefaultActionTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;return t||(t="en"),G.getString("ed.translationMergeLocaleWithDefault").format(o.surveyLocalization.defaultLocale)}))},Object.defineProperty(e.prototype,"selectLanguageOptionsCaption",{get:function(){return G.getString("ed.translationAddLanguage")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllStringsText",{get:function(){return G.getString("ed.translationShowAllStrings")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showUsedStringsOnlyText",{get:function(){return G.getString("ed.translationShowUsedStringsOnly")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllPagesText",{get:function(){return G.getString("ed.translationShowAllPages")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"exportToCSVText",{get:function(){return G.getString("ed.translationExportToSCVButton")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"importFromCSVText",{get:function(){return G.getString("ed.translationImportFromSCVButton")},enumerable:!1,configurable:!0}),e.prototype.createActions=function(){var e=this,t=[];return this.createFilterPageAction(),t.push(this.filterPageAction),this.createFilterStringsAction(),t.push(this.filterStringsAction),this.mergeLocaleWithDefaultAction=new o.Action({id:"svd-translation-merge_locale_withdefault",visible:!1,component:"sv-action-bar-item",mode:"small",needSeparator:!0,action:function(){e.model.mergeLocaleWithDefault()}}),t.push(this.mergeLocaleWithDefaultAction),this.importCsvAction=Xt((function(){e.model.importFromCSVFileDOM()}),!0),this.importCsvAction.enabled=new o.ComputedUpdater((function(){return!e.creator.readOnly})),this.importCsvAction.visible=!1,t.push(this.importCsvAction),this.exportCsvAction=$t((function(){e.model.exportToCSVFileUI()})),this.exportCsvAction.visible=!1,t.push(this.exportCsvAction),t},e.prototype.createFilterPageAction=function(){var e=this;this.filterPageAction=(0,o.createDropdownActionModel)({id:"svc-translation-filter-page",title:this.getFilterPageActionTitle(),visible:!1,mode:"small"},{items:[{id:null,title:this.showAllPagesText}],allowSelection:!0,onSelectionChanged:function(t){e.model.filteredPage=t.id?e.creator.survey.getPageByName(t.id):null},horizontalPosition:"center",cssClass:"svc-creator-popup"})},e.prototype.createFilterStringsAction=function(){var e=this;this.filterStringsAction=(0,o.createDropdownActionModel)({id:"svc-translation-show-all-strings",title:this.getFilterStringsActionTitle(),visible:!1,mode:"small"},{items:[{id:"show-all-strings",locTitleName:"ed.translationShowAllStrings"},{id:"show-used-strings-only",locTitleName:"ed.translationShowUsedStringsOnly"}],allowSelection:!0,onSelectionChanged:function(t){e.model.showAllStrings="show-all-strings"===t.id},horizontalPosition:"center",cssClass:"svc-creator-popup"})},e.prototype.updateFilterStrigsAction=function(e){void 0===e&&(e=!1);var t=this.getFilterStringsActionTitle();if(this.filterStringsAction.title=t,e){this.filterStringsAction.needSeparator=this.filterPageAction.visible;var o=this.filterStringsAction.data;o.selectedItem=o.actions.filter((function(e){return e.title===t}))[0]}},e.prototype.updateFilterPageAction=function(e){if(void 0===e&&(e=!1),this.filterPageAction.title=this.getFilterPageActionTitle(),e){var t=this.filterPageAction.data,o=this.model.filteredPage?this.model.filteredPage.name:null;t.selectedItem=t.actions.filter((function(e){return e.id===o}))[0]}},e.prototype.getFilterPageActionTitle=function(){return this.model&&this.model.filteredPage&&this.getPageDisplayText(this.model.filteredPage)||this.showAllPagesText},e.prototype.getFilterStringsActionTitle=function(){return this.model&&!this.model.showAllStrings?this.showUsedStringsOnlyText:this.showAllStringsText},e.prototype.getPageDisplayText=function(e){return this.creator.getObjectDisplayName(e,"translation-tab","survey-translation",e.title)},e}(),to={root:"",container:"",header:"",body:"sl-body",bodyEmpty:"",footer:"",title:"",description:"",logo:"",logoImage:"",headerText:"",navigationButton:"",completedPage:"",navigation:{complete:"",prev:"",next:"",start:"",preview:"",edit:""},panel:{enter:"sl-element-wrapper--enter",leave:"sl-element-wrapper--leave",title:"",titleExpandable:"",titleOnExpand:"",titleOnError:"",description:"",container:"sl-panel",content:"",icon:"",iconExpanded:"",footer:"sl-panel__footer",requiredText:"sl-panel__required-text"},paneldynamic:{mainRoot:"",root:"",navigation:"",title:"",button:"",buttonRemove:"",buttonAdd:"svc-logic-operator sl-paneldynamic__add-btn",progressTop:"",progressBottom:"",buttonPrev:"",buttonNext:"",progressContainer:"",progress:"",progressBar:"",progressText:"",separator:"sv-hidden",panelWrapper:"sl-panel-wrapper",content:"sl-paneldynamic__content",panelsContainer:"",panelWrapperList:"sl-panel-wrapper--list",panelWrapperInRow:"sl-panel-wrapper--in-row",panelWrapperEnter:"sl-panel-wrapper--enter",panelWrapperLeave:"sl-panel-wrapper--leave"},progress:"",progressBar:"",progressText:"",progressTextInBar:"",page:{root:"",title:"",description:""},pageTitle:"",pageDescription:"",row:"sl-row",rowEnter:"sl-row--enter",rowLeave:"sl-row--leave",rowDelayedEnter:"sl-row--delayed-enter",rowMultiple:"sl-row--multiple",question:{mainRoot:"sl-question",flowRoot:"",asCell:"",header:"sl-question__header",headerLeft:"sl-question__header--left",headerTop:"",headerBottom:"",content:"",contentLeft:"",titleLeftRoot:"",titleOnAnswer:"",titleOnError:"",enter:"sl-element-wrapper--enter",leave:"sl-element-wrapper--leave",title:"sl-question__title",requiredText:"sl-question__required-text",number:"",description:"",descriptionUnderInput:"",comment:"",required:"",titleRequired:"",indent:0,footer:"",formGroup:"",hasError:"",disabled:""},image:{root:""},error:{root:"",icon:"",item:"",locationTop:"",locationBottom:""},checkbox:{root:"",item:"",itemSelectAll:"",itemNone:"",itemDisabled:"",itemChecked:"",itemHover:"",itemInline:"",label:"",labelChecked:"",itemControl:"",itemDecorator:"",controlLabel:"",materialDecorator:"",other:"",column:""},radiogroup:{root:"",item:"",itemInline:"",label:"",labelChecked:"",itemDisabled:"",itemChecked:"",itemHover:"",itemControl:"",itemDecorator:"",controlLabel:"",materialDecorator:"",other:"",clearButton:"",column:""},boolean:{mainRoot:"",root:"",item:"",control:"",itemChecked:"",itemIndeterminate:"",itemDisabled:"",label:"",switch:"",disabledLabel:"",itemDecorator:"",materialDecorator:"",sliderText:"",slider:""},text:{root:"",small:"",controlDisabled:"",onError:""},multipletext:{root:"",item:"",itemTitle:"",row:"",cell:""},dropdown:{root:"",popup:"svc-creator-popup",small:"",control:"sl-dropdown",selectWrapper:"",other:"",onError:"",label:"",item:"",itemDisabled:"",itemChecked:"",itemHover:"",itemControl:"",itemDecorator:"",controlDisabled:"",controlLabel:"",materialDecorator:"",controlValue:"sl-dropdown__value",chevronButton:"",chevronButtonSvg:"",chevronButtonIconId:""},imagepicker:{root:"",item:"",itemInline:"",itemChecked:"",itemDisabled:"",itemHover:"",label:"",itemControl:"",image:"",itemText:"",clearButton:"",other:""},matrix:{mainRoot:"",tableWrapper:"",root:"",row:"",rowAdditional:"",rowError:"",cell:"",headerCell:"",label:"",itemValue:"",itemChecked:"",itemDisabled:"",itemHover:"",materialDecorator:"",itemDecorator:"",cellText:"",cellTextSelected:"",cellTextDisabled:""},matrixdropdown:{tableWrapper:"",mainRoot:"",root:"",row:"",rowAdditional:"",cell:"",headerCell:""},matrixdynamic:{tableWrapper:"",mainRoot:"sl-question st-row__question st-scrollable",root:"sl-table st-matrixdynamic",noHeader:"",row:"sl-table__row",rowAdditional:"sl-table__row--additional",cell:"sl-table__cell",headerCell:"sl-table__cell st-table__cell--header",button:"sl-btn",detailRow:"sl-table__row sl-table__row--detail st-table__row--detail",rowEnter:"sl-table__row--enter",rowLeave:"sl-table__row--leave",detailButton:"sl-table__cell--detail-button",detailButtonExpanded:"sl-table__cell--detail-button--expanded",detailIcon:"sl-detail-panel__icon",detailIconExpanded:"sl-detail-panel__icon--expanded",detailPanelCell:"sl-table__cell--detail-panel",actionsCell:"sl-table__cell sl-table__cell--actions st-table__cell--actions",buttonAdd:"sl-matrixdynamic__add-btn",buttonRemove:"sl-matrixdynamic__remove-btn",iconAdd:"",iconRemove:""},rating:{root:"",item:"",itemHover:"",selected:"",minText:"",itemText:"",maxText:"",itemDisabled:""},comment:{mainRoot:"",root:"spg-input spg-comment sl-comment",small:""},expression:"",file:{root:"",other:"",placeholderInput:"",preview:"",fileSign:"",fileSignBottom:"",fileDecorator:"",fileInput:"",noFileChosen:"",chooseFile:"",disabled:"",removeButton:"",removeButtonBottom:"",removeFile:"",removeFileSvg:"",wrapper:""},signaturepad:{root:"",small:"",controls:"",placeholder:"",clearButton:""},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"",body:"",header:{root:"",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}},list:{root:"sv-list__container sl-list",itemBody:"sv-list__item-body sd-list__item-body sl-list__item-body"},embeddedsurvey:{mainRoot:"sl-embedded-survey"},actionBar:o.defaultActionBarCss},oo=function(){this.conjunction="and",this.operator=i.logic.defaultOperators.default},io=function(e){function t(t){var o=e.call(this)||this;return o.survey=t,o}return K(t,e),t.prototype.getOperatorText=function(){var e=this.operator;return"equal"==e?"=":"notequal"==e?"<>":"greater"==e?">":"less"==e?"<":"greaterorequal"==e?">=":"lessorequal"==e?"<=":e},t.prototype.getValueText=function(){var e=this.value;if(!e)return e;if(!Array.isArray(e))return this.valToText(e);for(var t="[",o=0;o<e.length;o++)t+=this.valToText(e[o]),o<e.length-1&&(t+=", ");return t+"]"},Object.defineProperty(t.prototype,"isValueRequired",{get:function(){return"empty"!==this.operator&&"notempty"!==this.operator},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isReady",{get:function(){return!(!this.questionName||this.isValueRequired&&o.Helpers.isValueEmpty(this.value))},enumerable:!1,configurable:!0}),t.prototype.toExpression=function(){var e=E(this.getQuestionValueByName())+" "+this.getOperatorText();return this.isValueRequired&&(e+=" "+this.getValueText()),e},t.prototype.getQuestionValueByName=function(){var e=this.survey.getQuestionByName(this.questionName);return e&&e.name!=e.getValueName()&&this.questionName!=e.getValueName()?this.questionName.replace(e.name,e.getValueName()):this.questionName},t.prototype.valToText=function(e){return"true"==e||"false"==e||this.isNumeric(e)?e:"["==e[0]?e.replace(/(?!^)(['])(?!$)/g,"\\$1"):(this.isQuote(e[0])||(e="'"+e),this.isQuote(e[e.length-1])||(e+="'"),e.replace(/(?!^)(['"])(?!$)/g,"\\$1"))},t.prototype.isNumeric=function(e){return!("string"==typeof e&&e.length>1&&"0"===e[0]&&"x"!==e[1]||isNaN(e))},t.prototype.isQuote=function(e){return"'"==e||'"'==e},t}(oo),no=function(){function e(e){void 0===e&&(e=null),this.hasValue=e}return e.prototype.build=function(e){return e&&(t=(new o.ConditionsParser).parseExpression(e))?this.buildEditorItems(t):[];var t},e.prototype.buildEditorItems=function(e){var t=[];return this.buildEditorItemsCore(e,t,"")||(t=[]),t},e.prototype.buildEditorItemsCore=function(e,t,o){if("unary"==e.getType())return this.buildEditorItemsAddUnaryOperand(e,t);if("binary"!==e.getType())return!1;var i=e;return!(i.isArithmetic&&!i.isConjunction)&&(i.isConjunction?this.buildEditorItemsAddConjunction(i,t,o):this.buildEditorItemsAddBinaryOperand(i,t))},e.prototype.buildEditorItemsAddConjunction=function(e,t,o){var i=e.conjunction;if("or"==i&&o&&o!=i)return!1;if(!this.buildEditorItemsCore(e.leftOperand,t,i))return!1;var n=t.length;return!!this.buildEditorItemsCore(e.rightOperand,t,i)&&(t[n].conjunction=e.conjunction,!0)},e.prototype.buildEditorItemsAddBinaryOperand=function(e,t){var o=this.getOperandByType(e,"variable"),i=this.getArrayValueFromOperand(e),n=i?null:this.getOperandByType(e,"const");if(!o||!n&&!i&&this.canShowValueByOperator(e.operator))return!1;if(!this.isVariableInSurvey(o.variable))return!1;var r=new oo;return r.questionName=o.variable,r.operator=e.leftOperand!==o?this.getOppositeOperator(e.operator):e.operator,i&&(r.value=i),n&&(r.value=n.correctValue),t.push(r),!0},e.prototype.isVariableInSurvey=function(e){return!this.hasValue||this.hasValue(e)},e.prototype.getArrayValueFromOperand=function(e){var t=this.getOperandByType(e,"array");if(!t||!t.values)return null;var o=t.values;if(!Array.isArray(o)||0==o.length)return null;for(var i=[],n=0;n<o.length;n++){var r=o[n];if(r){if("const"!=r.getType())return null;i.push(r.correctValue)}}return 0==i.length?null:i},e.prototype.buildEditorItemsAddUnaryOperand=function(e,t){var o=e.operator;if("empty"!==o&&"notempty"!=o)return!1;var i=e.expression;if(null==i||"variable"!=i.getType())return!1;var n=i.variable;if(!this.isVariableInSurvey(n))return!1;var r=new oo;return r.questionName=n,r.operator=o,t.push(r),!0},e.prototype.getOppositeOperator=function(e){return"less"==e?"greater":"greater"==e?"less":"lessorequal"==e?"greaterorequal":"greaterorequal"==e?"lessorequal":e},e.prototype.getOperandByType=function(e,t){return e.rightOperand?e.leftOperand.getType()!==t&&e.rightOperand.getType()!==t||e.leftOperand.getType()==t&&e.rightOperand.getType()==t?null:e.leftOperand.getType()==t?e.leftOperand:e.rightOperand:null},e.prototype.canShowValueByOperator=function(e){return"empty"!=e&&"notempty"!=e},e}();o.FunctionFactory.Instance.register("questionValueVisibleIf",(function(e){return 2===e.length&&!(!e[0]||!e[1])&&"empty"!==e[1]&&"notempty"!==e[1]}));var ro=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n="");var r=e.call(this,i)||this;return r.propertyName=n,r.addConditionQuestionsHash={},r.isModalValue=!0,r.isSettingPanelValues=!1,r.calculatedValueQuestion=null,r.surveyValue=t,r.objectValue=o,r.panelValue=r.editSurvey.getQuestionByName("panel"),r.textEditorValue=r.editSurvey.getQuestionByName("textEditor"),r.options.maxLogicItemsInCondition&&(r.panel.maxPanelCount=r.options.maxLogicItemsInCondition),r.allConditionQuestions=r.createAllConditionQuestions(),r.editSurvey.onValueChanged.add((function(e,t){r.onValueChanged(t)})),r.editSurvey.onDynamicPanelAdded.add((function(e,t){r.onPanelAdded()})),r.editSurvey.onDynamicPanelRemoved.add((function(e,t){0==t.question.panelCount&&t.question.addPanel(),r.panel.panelCount>0&&(r.panel.panels[0].getQuestionByName("questionName").titleLocation="left")})),r.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){r.onPanelValueChanged(t.panel,t.name)})),r.editSurvey.css=to,r.editSurvey.onUpdateQuestionCssClasses.add((function(e,t){r.onUpdateQuestionCssClasses(t)})),r.text=r.object&&r.propertyName?r.object[r.propertyName]:"",r.updatePlaceholderVisibileIf(),r}return K(t,e),t.canParseExpression=function(e){return!e||!!(new o.ConditionsParser).parseExpression(e)},t.canBuildExpression=function(e){return!e||!!t.canParseExpression(e)&&(new no).build(e).length>0},t.isOperatorEnabled=function(e,o){if(!e)return!0;if(!o||0==o.length)return!0;for(var i=[],n=[],r=0;r<o.length;r++){var a=o[r];"!"==a[0]?n.push(a.substring(1)):i.push(a)}return t.isClassContains(e,i,n)},t.isClassContains=function(e,t,i){for(var n=o.Serializer.findClass(e);n;){if(t.indexOf(n.name)>-1)return!0;if(i.indexOf(n.name)>-1)return!1;n=n.parentName?o.Serializer.findClass(n.parentName):null}return 0==t.length},Object.defineProperty(t.prototype,"title",{get:function(){return this.panel.title},set:function(e){this.panel.title=e,this.textEditor.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isModal",{get:function(){return this.isModalValue},set:function(e){e!==this.isModalValue&&(this.isModalValue=e,this.updatePlaceholderVisibileIf())},enumerable:!1,configurable:!0}),t.prototype.updatePlaceholderVisibileIf=function(){if(this.panel){var e="";this.isModal&&!this.options.animationEnabled&&(e="{panel.questionName} empty and {panelIndex} == 0"),this.panel.template.getQuestionByName("placeholder").visibleIf=e}},t.prototype.getSurveyJSON=function(){return{elements:[{type:"paneldynamic",titleLocation:"hidden",name:"panel",panelRemoveButtonLocation:"right",panelAddText:G.getString("pe.addCondition"),minPanelCount:1,maxPanelCount:1,startWithNewLine:!1,templateElements:[{name:"conjunction",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,titleLocation:"hidden",showOptionsCaption:!1,visibleIf:"{panelIndex} > 0",choices:[{value:"and",text:G.getString("pe.and")},{value:"or",text:G.getString("pe.or")}]},{name:"questionName",type:"dropdown",renderAs:"logicoperator",title:G.getString("pe.if"),titleLocation:"left",showOptionsCaption:!1,startWithNewLine:!1,isRequired:!0},{name:"operator",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,titleLocation:"hidden",startWithNewLine:!1,showOptionsCaption:!1,isRequired:!0,enableIf:"{panel.questionName} notempty"},{name:"removeAction",type:"linkvalue",titleLocation:"hidden",showOptionsCaption:!1,visible:!1,startWithNewLine:!1,showValueInLink:!1,allowClear:!1,showClear:!1,iconName:"icon-delete_24x24"},{name:"questionValue",type:"text",visible:!1},{name:"placeholder",type:"html",visible:!1,html:"<div class='svc-logic-placeholder'><span class=\"svc-logic-placeholder__text\">".concat(G.getString("pe.emptyLogicPopupMessage"),"<span></div>")}]},{type:"comment",titleLocation:"hidden",name:"textEditor",textUpdateMode:"onTyping",placeholder:G.getString("pe.emptyExpressionPlaceHolder"),visible:!1}]}},t.prototype.getSurveyCreationReason=function(){return"condition-builder"},Object.defineProperty(t.prototype,"text",{get:function(){return this.getText()},set:function(e){this.isModal||t.canBuildExpression(e)?(this.textEditor.value=e,this.showBuilder(e)):(this.panel.panelCount=0,this.showTextEditor(e))},enumerable:!1,configurable:!0}),t.prototype.isModified=function(e){if(this.textEditor.visible)return e!=this.text;var t=this.getEditorItems(),i=e?(new o.ConditionsParser).parseExpression(e):null;if(!i)return!(1==t.length&&!t[0].questionName);if(!this.isReady)return!0;var n=(new o.ConditionsParser).parseExpression(this.text);return!i.isEqual(n)},Object.defineProperty(t.prototype,"context",{get:function(){return this.contextValue},set:function(e){e!==this.context&&(this.contextValue=e,this.updateNamesOnContextChanged(),this.onContextChanged&&this.onContextChanged(e))},enumerable:!1,configurable:!0}),t.prototype.processText=function(e){this.panel.panelCount=0;var t=(new no).build(e);this.buildPanels(t)},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"object",{get:function(){return this.objectValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.panelValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textEditor",{get:function(){return this.textEditorValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isReady",{get:function(){if(this.textEditor.visible)return t.canParseExpression(this.textEditor.value);for(var e=0;e<this.panel.panels.length;e++)if(!this.createEditorItemFromPanel(this.panel.panels[e]).isReady)return!1;return!0},enumerable:!1,configurable:!0}),t.prototype.isEmpty=function(){return 0===this.panel.panels.length||!(this.panel.panels.length>1)&&!this.createEditorItemFromPanel(this.panel.panels[0]).questionName},t.prototype.hasErrorInUI=function(){var e=this.survey.creator;return!this.isReady&&(this.hasErrors(),this.errorText=ke("expressionInvalid"),e&&e.notify(this.errorText,"error"),!0)},t.prototype.apply=function(){return!this.hasErrorInUI()&&(this.object&&this.propertyName?(this.object[this.propertyName]=this.text,!0):void 0)},t.prototype.setIsFastEntry=function(e){e?this.showTextEditor(this.text):this.panel.visible||this.showBuilder(this.text)},t.prototype.buildPanels=function(e){this.panel.panelCount=e.length;for(var t=0;t<e.length;t++)this.setItemToPanel(e[t],this.panel.panels[t]);0==this.panel.panelCount&&this.panel.addPanel()},t.prototype.setupConditionOperator=function(e,o){var n=this,r=o.getQuestionByName("operator");r.choices=this.getOperators(),r.value=e.operator,r.onOpened.add((function(e,r){var a=o.getQuestionByName("questionName").value,s=n.getQuestionConditionJson(a),l=s?s.type:null,u=n.getConditionQuestion(a);r.choices.forEach((function(e,o){var r=t.isOperatorEnabled(l,i.operators[e.value]);r=n.options.isConditionOperatorEnabled(a,u,e.value,r),e.setIsEnabled(r),e.setIsVisible(r)}))}))},t.prototype.setupConditionQuestionName=function(e,t){var o=t.getQuestionByName("questionName");o.choices=this.getConditionQuestions(),o.titleLocation=0==this.panel.panels.indexOf(t)?"left":"hidden";var i=this.getQuestionNameToPanel(e.questionName);this.getConditionQuestion(i)&&(o.value=i)},t.prototype.setupRemoveQuestion=function(e){var t=e.getQuestionByName("removeAction").parentQuestion,o=e.getQuestionByName("removeAction");o.linkClickCallback=function(){t&&t.removePanelUI(e)},o.linkSetButtonCssClasses="svc-logic-condition-remove svc-icon-remove",o.linkValueText=""},t.prototype.setItemToPanel=function(e,t){this.isSettingPanelValues=!0,t.getQuestionByName("conjunction").value=e.conjunction,this.setupConditionOperator(e,t),this.setupConditionQuestionName(e,t),t.getQuestionByName("questionValue")&&(t.getQuestionByName("questionValue").value=e.value,this.updateSurveyVariable(e)),this.setupRemoveQuestion(t),this.isSettingPanelValues=!1},t.prototype.updateSurveyVariable=function(e){this.editSurvey.setVariable(e.questionName,e.value)},t.prototype.getConditionQuestions=function(){if(!this.context)return this.allConditionQuestions;for(var e=[],t=0;t<this.allConditionQuestions.length;t++){var o=this.allConditionQuestions[t];o.context&&o.context!==this.context||e.push(o)}return e},t.prototype.getText=function(){if(this.textEditor.visible)return this.textEditor.value;for(var e="",t=this.getEditorItems(),o=0;o<t.length&&t[o].isReady;o++)e&&(e+=" "+t[o].conjunction+" "),e+=t[o].toExpression();return e},t.prototype.getEditorItems=function(){for(var e=[],t=0;t<this.panel.panels.length;t++)e.push(this.createEditorItemFromPanel(this.panel.panels[t]));return e},t.prototype.createEditorItemFromPanel=function(e){var t=new io(this.survey);return t.conjunction=e.getQuestionByName("conjunction").value,t.questionName=this.getQuestionNameFromPanel(e.getQuestionByName("questionName").value),t.operator=e.getQuestionByName("operator").value,e.getQuestionByName("questionValue")&&(t.value=e.getQuestionByName("questionValue").value,this.updateSurveyVariable(t)),t},t.prototype.getQuestionNameFromPanel=function(e){if(!this.context||!e)return e;var t=this.context.getValueName()+".";return e.replace(t,"")},t.prototype.getContextIndexInfo=function(e,t){return void 0===t&&(t=""),ee.getQuestionContextIndexInfo(e,t)},t.prototype.getQuestionNameToPanel=function(e){if(!this.context||!e)return e;var t=this.getContextIndexInfo(e);return t&&0===t.index?this.context.getValueName()+"."+e:e},t.prototype.getContextFromPanels=function(){if(this.object)return null;for(var e=0;e<this.panel.panels.length;e++){var t=this.panel.panels[e].getQuestionByName("questionName").value,o=this.getContextByQuestionName(t);if(o)return o}return null},t.prototype.updateNamesOnContextChanged=function(){for(var e=0;e<this.panel.panels.length;e++)this.panel.panels[e].getQuestionByName("questionName").choices=this.getConditionQuestions()},t.prototype.getContextByQuestionName=function(e){if(!e)return null;var t=this.getContextIndexInfo(e,".");return t?(e=e.substring(0,t.index),this.survey.getQuestionByValueName(e)):null},t.prototype.createAllConditionQuestions=function(){if(!this.survey)return[];var e=[],t=this.survey.getAllQuestions(),o=this.getContextObject(),n=i.logic.questionSortOrder;if(t.length>0)for(var r=0;r<t.length;r++)if(o!=(l=t[r])){var a=o||!this.context||this.context===l;l.addConditionObjectsByContext(e,a)}var s=this.survey.getVariableNames();for(this.addSurveyCalculatedValues(s),n=this.options.onConditionQuestionsGetListCallback(this.propertyName,this.object,this,e,s),r=0;r<e.length;r++){e[r].value=e[r].name;var l=e[r].question?e[r].question:e[r];if(!this.options.showTitlesInExpressions){var u=e[r].name,p=l.valueName;p&&0==u.indexOf(p)&&(u=u.replace(p,l.name)),u=u.replace("-unwrapped",""),e[r].text=this.options.getObjectDisplayName(l,"condition-editor","condition",u)}this.addConditionQuestionsHash[e[r].name]=l}return this.addValuesIntoConditionQuestions(s,e),"asc"===n&&ee.sortItems(e),e},t.prototype.getContextObject=function(){if(this.object&&this.object.isDescendantOf("itemvalue")){var e=this.object.locOwner;if(e&&e.getType)return e.locOwner&&e.locOwner.isDescendantOf("matrixdropdowncolumn")?e.locOwner:e}return this.object},t.prototype.addValuesIntoConditionQuestions=function(e,t){for(var o=0;o<e.length;o++){var i=e[o].name?e[o].name:e[o];this.addConditionQuestionsHash[i]=this.getCalculatedValueQuestion(),t.push({value:i,text:i,question:this.getCalculatedValueQuestion()})}},t.prototype.addSurveyCalculatedValues=function(e){this.survey.calculatedValues.forEach((function(t){var o=e.indexOf(t.name.toLowerCase());o>-1&&e.splice(o,1),e.push(t.name)}))},t.prototype.getCalculatedValueQuestion=function(){return this.calculatedValueQuestion||(this.calculatedValueQuestion=o.Serializer.createClass("text"),this.calculatedValueQuestion.name="question"),this.calculatedValueQuestion},t.prototype.getOperators=function(){var e=[],t=i.operators;for(var n in t)e.push(new o.ItemValue(n,G.getString("op."+n)));return e},t.prototype.rebuildQuestionValue=function(e){e.getQuestionByName("questionValue")&&e.getQuestionByName("questionValue").clearValue();var t=e.getQuestionByName("questionName").value,i=this.getQuestionConditionJson(t,e.getQuestionByName("operator").value);i||(i={type:"text"}),i.isRequired=!0,ee.updateQuestionJson(i),i.enableIf="{panel.questionName} notempty and {panel.operator} != 'empty' and {panel.operator} != 'notempty'";var n=o.Serializer.createClass(i.type);delete i.type,(new o.JsonObject).toObject(i,n),n||(n=o.Serializer.createClass("text",i));var r=e.getQuestionByName("questionValue");if(r&&e.removeElement(r),this.canShowQuestionValue(e)){var a=n.title;if(n.name="questionValue",n.visibleIf="questionValueVisibleIf({panel.questionName}, {panel.operator})",n.title=a,n.description="",n.titleLocation="top",n.hasComment=!1,n.showOtherItem){var s=this.getConditionQuestion(t);if(s&&s.getStoreOthersAsComment&&s.getStoreOthersAsComment()){var l=n.otherItem;n.choices.push(new o.ItemValue(l.value,l.title)),l.value="#"+l.value+"#",n.showOtherItem=!1}}e.addElement(n)}},t.prototype.rebuildQuestionValueOnOperandChanging=function(e){var t=this.getQuestionConditionJson(e.getQuestionByName("questionName").value,e.getQuestionByName("operator").value),o=e.getQuestionByName("questionValue");!o||!o.isReadOnly&&o.isVisible||o.clearValue(),!o||t&&t.type==o.getType()||this.rebuildQuestionValue(e)},t.prototype.canShowQuestionValue=function(e){var t=e.getQuestionByName("operator");if(!t)return!1;this.updateOperatorEnables(e);for(var o=t.choices,i=0;i<o.length;i++)if(o[i].isEnabled){var n=o[i].value;if("empty"!==n&&"notempty"!=n)return!0}return!1},t.prototype.getConditionQuestion=function(e){return this.addConditionQuestionsHash[e]},t.prototype.getQuestionConditionJson=function(e,o){var i="",n=this.getConditionQuestion(e);if(!n)return null;o||(o=this.getDefaultOperatorByQuestion(n)),0==e.indexOf(n.getValueName())&&(i=e.substring(n.getValueName().length));var r=this.getContextIndexInfo(e);r&&0==r.index&&(i=e.substring(r.name.length)),i||(i=e),i&&"."==i[0]&&(i=i.substring(1));var a=n&&n.getConditionJson?n.getConditionJson(o,i):null;return a?(a.choicesFromQuestion&&this.updateChoicesFromQuestion(a),"expression"==a.type&&(a.type="text"),"anyof"==o&&(t.isClassContains(a.type,["checkbox"],[])||(a.type="checkbox")),a):null},t.prototype.updateChoicesFromQuestion=function(e){var t=this.getConditionQuestion(e.choicesFromQuestion);if(t){delete e.choicesFromQuestion;var o=t.toJSON();o.choices&&(e.choices=o.choices),o.choicesByUrl&&(e.choicesByUrl=o.choicesByUrl)}},t.prototype.updateOperatorEnables=function(e){var o=e.getQuestionByName("questionName");if(o){var n=this.getQuestionConditionJson(o.value),r=n?n.type:null,a=e.getQuestionByName("operator");if(a){for(var s=a.choices,l=!0,u=a.value,p=0;p<s.length;p++){var c=t.isOperatorEnabled(r,i.operators[s[p].value]);s[p].setIsEnabled(c),s[p].setIsVisible(c),s[p].value==u&&(l=s[p].isEnabled)}l||(a.value=this.getFirstEnabledOperator(s))}}},t.prototype.updateQuestionsWidth=function(e){var t=e.getQuestionByName("questionValue"),o=e.getQuestionByName("conjunction"),i=e.getQuestionByName("questionName"),n=e.getQuestionByName("operator"),r=!!t&&!t.startWithNewLine,a=!o||!o.isVisible;a||(o.minWidth="50px",o.width="15%"),i.minWidth="50px",i.width=a?"40%":"25%",n.minWidth="50px",n.width=r?"25%":"60%",t&&(t.minWidth="50px",t.width=r?"35%":"")},Object.defineProperty(t.prototype,"defaultOperator",{get:function(){return i.logic.defaultOperators.default},enumerable:!1,configurable:!0}),t.prototype.getDefaultOperatorByQuestionName=function(e){return this.getDefaultOperatorByQuestion(this.getConditionQuestion(e))},t.prototype.getDefaultOperatorByQuestion=function(e){if(e){var t=i.logic.defaultOperators;if(t[e.getType()])return t[e.getType()]}return this.defaultOperator},t.prototype.getFirstEnabledOperator=function(e){for(var t=0;t<e.length;t++)if(e[t].isEnabled)return e[t].value;return this.defaultOperator},t.prototype.onPanelAdded=function(){this.setItemToPanel(new oo,this.panel.panels[this.panel.panels.length-1])},t.prototype.onPanelValueChanged=function(e,t){"questionName"==t&&(this.context=this.getContextFromPanels(),this.rebuildQuestionValue(e),this.isSettingPanelValues||(e.getQuestionByName("operator").value=this.getDefaultOperatorByQuestionName(e.getQuestionByName("questionName").value))),"operator"==t&&this.rebuildQuestionValueOnOperandChanging(e),this.updateOperatorEnables(e),this.updateQuestionsWidth(e)},t.prototype.onUpdateQuestionCssClasses=function(e){var t=e.cssClasses,o=e.question;t.answered="svc-logic-question--answered","textEditor"===o.name&&(t.root+=" svc-logic-question-text-editor"),"conjunction"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--conjunction "),"questionName"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--question",t.error.root="svc-logic-operator__error",t.onError="svc-logic-operator--error"),"operator"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--operator"),"removeAction"===o.name&&(o.allowRootStyle=!1,t.mainRoot+=" svc-logic-condition-remove-question"),("questionValue"===o.name||o.isContentElement)&&(P(t,o.getType()),t.mainRoot+=" svc-logic-question-value sd-element--with-frame",t.error.root="svc-logic-operator__error"),"panel"===o.name&&(t.root+=" svc-logic-paneldynamic",t.buttonAdd+=" svc-logic-operator--operator",t.iconRemove="svc-icon-remove",t.buttonRemove="svc-logic-paneldynamic__button svc-logic-paneldynamic__remove-btn",t.buttonRemoveRight="svc-logic-paneldynamic__remove-btn--right",t.buttonRemoveText="svc-logic-paneldynamic__button-remove-text")},t.prototype.onValueChanged=function(e){if("panel"===e.question.name&&e.value.length>0){var t=this.options.maxLogicItemsInCondition>0?this.options.maxLogicItemsInCondition:100;e.question.maxPanelCount=1!==e.value.length||e.value[0].questionName?t:1,this.panel.panels.forEach((function(t){t.getQuestionByName("removeAction").visible=1!==e.value.length}))}this.setTitle()},t.prototype.setTitle=function(){var e=this.isReady?this.text:"";this.title=this.options.onConditionGetTitleCallback(e,e||G.getString("pe.ruleIsNotSet"))},t.prototype.showTextEditor=function(e){this.panel.visible=!1,this.textEditor.value=e,this.textEditor.visible=!0},t.prototype.showBuilder=function(e){(this.isModal||this.getCanShowBuilder(e))&&(this.textEditor.visible=!1,this.processText(e),this.panel.visible=!0)},t.prototype.getCanShowBuilder=function(e){return t.canBuildExpression(e)},t}(it),ao=function(){function e(e,t,o){this.panel=e,this.initialLogicAction=t,this.logicType=o}return e.createActionModel=function(e,t,o,i){return o&&o.hasSelectorChoices?o.name.indexOf("_setValue")>-1?new lo(e,t,o,i):new so(e,t,o,i):new uo(e,t,o)},e.prototype.updateCurrentLogicAction=function(e){return!1},e.prototype.afterUpdateInitialLogicAction=function(){},e.prototype.resetElements=function(){},e.prototype.getSelectedElement=function(){return null},e.prototype.updateInitialLogicAction=function(){this.initialLogicAction=this.currentLogicAction,this.afterUpdateInitialLogicAction&&this.afterUpdateInitialLogicAction()},e.prototype.setInitialElementValue=function(e,t,o){o&&0!==e.choices.filter((function(e){return e.value===o})).length?e.value=o:e.value=t&&t.logicType==this.logicType?t.elementName:void 0},e}(),so=function(e){function t(t,o,i,n){var r=e.call(this,t,o,i)||this;return r.selectorElementsHash=n,r}return K(t,e),t.prototype.getSelectorOptionsText=function(e){var t=e.baseClass,o="page"==t?"pe.conditionSelectPage":"panel"==t?"pe.conditionSelectPanel":"pe.conditionSelectQuestion";return G.getString(o)},t.prototype.getElementBySelectorName=function(e){var t=e.getQuestionByName("elementSelector").value;return t?this.selectorElementsHash[t]:null},t.prototype.updateCurrentLogicAction=function(e){var t=this.getElementBySelectorName(this.panel);return(!this.initialLogicAction||this.initialLogicAction.logicType!=this.logicType||!!t&&this.initialLogicAction.element!=t)&&(this.currentLogicAction=new qe(this.logicType,t,e),!0)},t.prototype.resetElements=function(){this.panel.getQuestionByName("elementSelector").visible=!1},t.prototype.updatePanelElements=function(e,t){var o=this.panel.getQuestionByName("elementSelector");o.visible=!0,o.choices=t,o.allowClear=!1,o.optionsCaption=this.getSelectorOptionsText(this.logicType),this.setInitialElementValue(o,this.initialLogicAction,e)},t.prototype.getSelectedElement=function(){return this.panel.getQuestionByName("elementSelector").value},t}(ao),lo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.updatePanelElements=function(t,o){e.prototype.updatePanelElements.call(this,t,o),this.getValueIfQuestion().placeholder=G.getString("ed.lg.setValueExpressionPlaceholder"),this.getValueIfPanel().visible=!0,this.setValueExpressionValue()},t.prototype.afterUpdateInitialLogicAction=function(){var e=this.getElementBySelectorName(this.panel);e&&(e.setValueExpression=this.panel.getQuestionByName("setValueExpression").value)},t.prototype.setValueExpressionValue=function(){var e=this.getElementBySelectorName(this.panel);e&&(this.getValueIfQuestion().value=e.setValueExpression)},t.prototype.getValueIfPanel=function(){return this.panel.getElementByName("setValueIfPanel")},t.prototype.getValueIfQuestion=function(){return this.panel.getQuestionByName("setValueExpression")},t.prototype.resetElements=function(){e.prototype.resetElements.call(this),this.getValueIfPanel().visible=!1,this.getValueIfQuestion().clearValue()},t}(so),uo=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.isTrigger=!0,n}return K(t,e),t.prototype.recreateQuestion=function(e,t,i,n){var r=i?e.getQuestionByName(i):null;if(r){var a=e.getElementByName("triggerEditorPanel"),s=o.Serializer.createClass("panel");new at(t,n).setupObjPanel(s,!0,"logic");var l=s.getQuestionByName(i);if(l){var u=a.elements.indexOf(r);a.blockAnimations(),a.addElement(l,u),r.delete(),a.releaseAnimations()}"setValue"===l.name&&this.updateSetValueQuestion(l),this.updateVisibilityPanel(a),s.dispose()}},t.prototype.updateSetValueQuestion=function(e){var t=e.obj,o=t.getSurvey();if(o||(o=t.owner),t.setToName&&o){var i=o.getQuestionByValueName(t.setToName);e.title=i.title,e.titleLocation="top"}},t.prototype.updateRunExpressionQuestion=function(e){e.titleLocation="hidden",e.placeholder=G.getString("pe.emptyExpressionPlaceHolder")},t.prototype.createElementPanelObj=function(){var e=this.initialLogicAction,t=e&&e.logicType==this.logicType?e.element:null,o=this.logicType.createNewObj(t);return this.setPanelObj(o),o},t.prototype.getQuestions=function(){var e=this,t=this.panel.getElementByName("triggerQuestionsPanel");return 0!==t.elements.length&&this.logicType.questionNames?t.elements.filter((function(t){return-1!==e.logicType.questionNames.indexOf(t.name)})):null},t.prototype.resetPanel=function(e){var t=this.panel.getElementByName(e);t.questions.forEach((function(e){e.clearValue()})),t.elements.splice(0,t.elements.length),t.visible=!1},t.prototype.updateVisibilityPanel=function(e){e.elements.length>0?e.visible=e.elements.filter((function(e){return e.visible})).length>0:e.visible=!1},t.prototype.onPanelQuestionValueChanged=function(e,t){var i=this;if(this.panelObj){var n=o.Serializer.findProperty(this.panelObj.getType(),t),r=null==n?void 0:n.getDependedProperties();Array.isArray(r)&&r.length>0&&r.forEach((function(t){var n=e.getQuestionByName(t),r=o.Serializer.findProperty(i.panelObj.getType(),t);n&&r&&nt.onMasterValueChanged(i.panelObj,r,n)}))}},t.prototype.updatePanelQuestionsValue=function(e){var t=this;e.onSurveyLoad(),e.questions.forEach((function(e){o.Helpers.isValueEmpty(t.panelObj[e.getValueName()])||(e.value=t.panelObj[e.getValueName()])}))},t.prototype.afterUpdateInitialLogicAction=function(){this.setPanelObj(this.initialLogicAction.element),this.panelObj&&this.logicType.saveNewElement(this.panelObj)},t.prototype.updateCurrentLogicAction=function(e){if(this.initialLogicAction&&this.initialLogicAction.logicType==this.logicType){for(var t=this.initialLogicAction.element,o=this.panelObj.toJSON(),i=Object.keys(o),n=Object.keys(t.toJSON()),r=[],a=0;a<n.length;a++){var s=n[a];i.indexOf(s)<0&&r.push(s)}for(t.fromJSON(o),this.currentLogicAction=this.initialLogicAction,a=0;a<r.length;a++)t[r[a]]=void 0;return!1}return this.currentLogicAction=new qe(this.logicType,this.panelObj,e),!0},t.prototype.updatePanel=function(e,t,o,i){this.panelObj&&(this.panelObj[e]=t,this.logicType&&this.logicType.dependedOnPropertyName===e&&this.recreateQuestion(this.panel,this.panelObj,this.logicType.dynamicPropertyName,o),this.panel.runCondition(i.getAllValues(),{survey:i}))},t.prototype.setPanelObj=function(e){var t=this,o=this.panelObj;o&&(o.onPropertyValueChangedCallback=void 0),this.panelObj=e,e&&(e.onPropertyValueChangedCallback=function(e,i,n,r,a){if(t.panel&&!t.panel.isDisposed){var s=t.panel.getQuestionByName(e);s&&(s.value=n)}else o.onPropertyValueChangedCallback=void 0})},t.prototype.resetElements=function(){this.setPanelObj(null),this.resetPanel("triggerQuestionsPanel"),this.resetPanel("triggerEditorPanel")},t.prototype.updatePanelElements=function(e,t){var o=this,i=this.panel.getElementByName("triggerEditorPanel"),n=this.panel.getElementByName("triggerQuestionsPanel"),r=this.createElementPanelObj();new at(r,t).setupObjPanel(i,!0,"logic"),i.title="";var a=i.getQuestionByName("runExpression");a&&this.updateRunExpressionQuestion(a),this.logicType.questionNames&&i.elements.filter((function(e){return-1!==o.logicType.questionNames.indexOf(e.name)})).forEach((function(e){var t=e;"dropdown"===t.getType()&&(t.allowClear=!1,t.renderAs="logicoperator"),n.addQuestion(t)})),i.getElementByName(this.logicType.propertyName).visible=!1,this.updateVisibilityPanel(n),this.updatePanelQuestionsValue(n),this.updateVisibilityPanel(i),this.updatePanelQuestionsValue(i);var s=this.getQuestions();s&&e&&s.forEach((function(t){o.setInitialElementValue(t,o.initialLogicAction,e),e=null}))},t.prototype.getSelectedElement=function(){var e=this.getQuestions();if(e){var t=e[0];return!!t&&t.value}},t}(ao);o.FunctionFactory.Instance.register("logicTypeVisibleIf",(function(e){if(!this.question||!this.question.parentQuestion||1!=e.length)return!0;var t=this.question.parentQuestion.panels;if(t.length<2)return!0;for(var o=0;o<t.length;o++){var i=t[o].getQuestionByName("logicTypeName");if(i!=this.question&&i.value==e[0])return!1}return!0}));var po=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,o)||this;return i.options=o,i.initialSelectedElements={},i.isModifiedValue=!1,i.selectorElementsHash={},i.options||(i.options=new a),i.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){"logicTypeName"==t.name&&i.onLogicTypeChanged(t.panel);var o=i.getActionModelByPanel(t.panel);o.isTrigger&&o.updatePanel(t.name,t.value,i.options,i.editSurvey)})),i.editSurvey.onDynamicPanelRemoved.add((function(e,t){if(!i.isBuildingPanels){var o=i.getActionModelByPanel(t.panel);o&&o.initialLogicAction&&i.editableItem.removeAction(o.initialLogicAction),0==i.panel.panelCount&&i.panel.addPanel(),i.panel.panelCount>0&&(i.panels[0].getQuestionByName("logicTypeName").title=G.getString("pe.then"))}})),i.editSurvey.onDynamicPanelAdded.add((function(e,t){if(!i.isBuildingPanels){var o=i.panels[i.panel.panelCount-1];i.onPanelAdded(o,null)}})),i.editSurvey.css=to,i.editSurvey.onUpdateQuestionCssClasses.add((function(e,t){i.onUpdateQuestionCssClasses(t)})),i.editSurvey.onUpdatePanelCssClasses.add((function(e,t){i.onUpdatePanelCssClasses(t)})),i.editSurvey.onQuestionAdded.add((function(e,t){i.onQuestionAdded(t)})),i.editSurvey.onGetQuestionTitleActions.add((function(e,t){i.onGetQuestionTitleActions(t)})),i.editSurvey.onValueChanged.add((function(e,t){i.onValueChanged(t)})),i.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){var o,n=t.panel.getQuestionByName(t.name);if(n&&"triggerEditorPanel"===(null===(o=n.parent)||void 0===o?void 0:o.name)){var r=i.getActionModelByPanel(t.panel);r&&r.onPanelQuestionValueChanged(n.parent,t.name)}})),i.setEditableItem(t),i}return K(t,e),Object.defineProperty(t.prototype,"editableItem",{get:function(){return this.editableItemValue},enumerable:!1,configurable:!0}),t.prototype.setEditableItem=function(e){this.editableItemValue=e,this.buildInitialSelectedElements(),this.buildPanels(),this.resetModified()},Object.defineProperty(t.prototype,"survey",{get:function(){return this.editableItem.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isModified",{get:function(){return this.isModifiedValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.editSurvey.getQuestionByName("panel")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panels",{get:function(){return this.panel.panels},enumerable:!1,configurable:!0}),t.prototype.getActionModelByPanel=function(e){return e.actionModel},t.prototype.setActionModelByPanel=function(e,t){e.actionModel=t},Object.defineProperty(t.prototype,"context",{get:function(){return this.contextValue},set:function(e){e!==this.context&&(this.contextValue=e,this.updatePanelsOnContextChanged())},enumerable:!1,configurable:!0}),t.prototype.getLogicTypeByPanel=function(e){return this.getLogicTypeByName(e.getQuestionByName("logicTypeName").value)},t.prototype.getSurveyJSON=function(){return{clearInvisibleValues:"onHidden",elements:[{type:"paneldynamic",name:"panel",title:ke("actionsEditorTitle"),titleLocation:"hidden",panelAddText:ke("addNewAction"),panelRemoveButtonLocation:"right",panelCount:0,minPanelCount:1,maxPanelCount:1,templateElements:[{name:"logicTypeName",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,allowClear:!1,title:G.getString("pe.then"),titleLocation:"left",isRequired:!0,optionsCaption:ke("selectedActionCaption"),requiredErrorText:this.getLocString("pe.conditionActionEmpty")},{name:"logicTypeDescription",type:"html",startWithNewLine:!1,visible:!1},{name:"elementSelector",type:"dropdown",renderAs:"logicoperator",allowClear:!1,titleLocation:"hidden",isRequired:!0,startWithNewLine:!1,visible:!1},{name:"triggerQuestionsPanel",type:"panel",startWithNewLine:!1,visible:!1},{name:"removeAction",type:"linkvalue",titleLocation:"hidden",showOptionsCaption:!1,visible:!1,startWithNewLine:!1,showValueInLink:!1,allowClear:!1,showClear:!1,iconName:"icon-delete_24x24"},{name:"triggerEditorPanel",type:"panel",visible:!1},{name:"setValueIfPanel",visible:!1,type:"panel",elements:[{name:"setValueExpression",type:"comment",titleLocation:"hidden"}]}]}]}},t.prototype.getSurveyCreationReason=function(){return"logic-item-editor"},t.prototype.resetModified=function(){this.isModifiedValue=!1},t.prototype.isEmpty=function(){return 0===this.panels.length||!(this.panels.length>1)&&!this.getActionModelByPanel(this.panels[0])},t.prototype.apply=function(){if(this.editSurvey.hasErrors())return!1;for(var e=0;e<this.panels.length;e++)this.applyPanel(this.panels[e]);return this.resetModified(),!0},t.prototype.getEditingActions=function(){var e=this;return this.panels.map((function(t){var o=e.getActionModelByPanel(t);return o.updateCurrentLogicAction(e.survey),o.currentLogicAction||o.initialLogicAction})).filter((function(e){return!!e}))},t.prototype.onUpdateQuestionCssClasses=function(e){var t,i=e.cssClasses,n=e.question;i.answered="svc-logic-question--answered","logicTypeName"===n.name&&(n.allowRootStyle=!1,i.control+=" svc-logic-operator svc-logic-operator--action",i.error.root="svc-logic-operator__error",i.onError="svc-logic-operator--error");var r=["elementSelector","setToName","fromName","gotoName"];r.indexOf(n.name)>-1&&(n.allowRootStyle=!1,"setToName"!==n.name&&"fromName"!==n.name||(n.titleLocation="left",n.startWithNewLine=!1),i.control+=" svc-logic-operator svc-logic-operator--question",i.error.root="svc-logic-operator__error",i.onError="svc-logic-operator--error"),(n.isContentElement||this.isSetValueInternalQuestion(n))&&(P(i,n.getType()),i.mainRoot+=" svc-logic-question-value sd-element--with-frame");var a=null===(t=n.parent)||void 0===t?void 0:t.name;if(r.indexOf(n.name)<0&&("triggerEditorPanel"===a||"setValueIfPanel"===a)){var s=n.getType();P(i,s),!o.defaultV2Css[s]&&ze[s]&&(S(i,ze.question),S(i,ze[s]));var l=n.parent.elements.filter((function(e){return r.indexOf(e.name)<0&&"expression"!==e.name}));("runExpression"!==n.name&&"comment"!==s||Array.isArray(l)&&l.length>1)&&(i.mainRoot+=" svc-logic-question-value sd-element--with-frame")}"removeAction"===n.name&&(n.allowRootStyle=!1,i.mainRoot+=" svc-logic-condition-remove-question"),"panel"===n.name&&(i.root+=" svc-logic-paneldynamic",i.buttonAdd+=" svc-logic-operator--action ",i.iconRemove="svc-icon-remove",i.buttonRemove="svc-logic-paneldynamic__button svc-logic-paneldynamic__remove-btn",i.buttonRemoveRight="svc-logic-paneldynamic__remove-btn--right",i.buttonRemoveText="svc-logic-paneldynamic__button-remove-text")},t.prototype.isSetValueInternalQuestion=function(e){if(this.isSetValueInternalQuestionCore(e))return!0;if(this.isSetValueInternalQuestionCore(e.parentQuestion))return!0;var t=e.parent;return t&&this.isSetValueInternalQuestionCore(t.parentQuestion)},t.prototype.isSetValueInternalQuestionCore=function(e){return"setValue"===(null==e?void 0:e.name)},t.prototype.onUpdatePanelCssClasses=function(e){var t=e.panel,o=e.cssClasses,i=t.name;"triggerEditorPanel"!==i&&"setValueIfPanel"!==i||(o.panel.container+=" svc-logic_trigger-editor"),"triggerQuestionsPanel"===i&&(t.allowRootStyle=!1,o.panel.container+=" svc-logic_trigger-questions"),this.isSetValueInternalQuestionCore(t.parentQuestion)&&P(o,t.getType())},t.prototype.onValueChanged=function(e){this.isModifiedValue=!0,e.question.maxPanelCount=1!==e.value.length||e.value[0].logicTypeName?100:1,this.panels.forEach((function(t){t.getQuestionByName("removeAction").visible=1!==e.value.length}))},t.prototype.onQuestionAdded=function(e){"setToName"!==e.question.name&&"fromName"!==e.question.name||(e.question.titleLocation="left",e.question.startWithNewLine=!1)},t.prototype.onGetQuestionTitleActions=function(e){"setValue"===e.question.name&&(e.titleActions=[])},t.prototype.applyPanel=function(e){var t=this.getActionModelByPanel(e);t.updateCurrentLogicAction(this.survey)&&(this.editableItem.replaceAction(t.currentLogicAction,t.initialLogicAction),t.updateInitialLogicAction())},t.prototype.buildInitialSelectedElements=function(){if(this.initialSelectedElements={},this.editableItem)for(var e=0;e<this.editableItem.actions.length;e++){var t=this.editableItem.actions[e];if(this.isElementSelectorVisible(t.logicType)){var o=t.logicTypeName;this.initialSelectedElements[o]||(this.initialSelectedElements[o]=[]),this.initialSelectedElements[o].push(t.element)}}},t.prototype.buildPanels=function(){if(this.panel.panelCount=0,this.editableItem){this.logicTypeChoices=this.getLogicTypeChoices();for(var e=0;e<this.editableItem.actions.length;e++)this.onPanelAdded(this.panel.addPanel(),this.editableItem.actions[e]);0==this.panel.panelCount&&this.onPanelAdded(this.panel.addPanel(),null)}},t.prototype.onPanelAdded=function(e,t){var o=e.getQuestionByName("logicTypeName");if(o.title=this.panel.panelCount>1?G.getString("pe.and"):G.getString("pe.then"),o.choices=this.logicTypeChoices,o.allowClear=!1,t){var i=ao.createActionModel(e,t,this.getLogicTypeByName(t.logicTypeName),this.selectorElementsHash);this.setActionModelByPanel(e,i),o.value=t.logicTypeName}var n=e.getQuestionByName("removeAction"),r=n.parentQuestion;return n.linkClickCallback=function(){r&&r.removePanelUI(e)},n.linkSetButtonCssClasses="svc-logic-condition-remove svc-icon-remove",n.linkValueText="",e},t.prototype.updatePanelsOnContextChanged=function(){if(this.logicTypeChoices=this.getLogicTypeChoices(),this.context)for(var e=this.panels.length-1;e>=0;e--){var t=this.panels[e];this.isPanelSupportContext(t)||(0===e&&1===this.panels.length?t.getQuestionByName("logicTypeName").clearValue():this.panel.removePanel(e))}for(e=0;e<this.panels.length;e++)this.updateSelectorOnContextChanged(this.panels[e])},t.prototype.isPanelSupportContext=function(e){var t=this.getLogicTypeByPanel(e);return!!t&&t.supportContext(this.context)},t.prototype.updateSelectorOnContextChanged=function(e){var t=e.getQuestionByName("logicTypeName");t.choices=this.logicTypeChoices,t.allowClear=!1;var o=this.getLogicTypeByPanel(e);if(this.isElementSelectorVisible(o)){var i=e.getQuestionByName("elementSelector");i.choices=this.getSelectorChoices(o),i.allowClear=!1}},t.prototype.getLogicTypeChoices=function(){for(var e=[],t=this.editableItem.getVisibleLogicTypes(),i=0;i<t.length;i++){var n=t[i];if(!this.context||n.supportContext(this.context)){var r=new o.ItemValue(n.name,n.displayName);n.isUniqueItem&&(r.visibleIf="logicTypeVisibleIf({item})"),e.push(r)}}return e},t.prototype.onLogicTypeChanged=function(e){var t=this.getLogicTypeByPanel(e);e.getQuestionByName("logicTypeDescription").html=t?t.description:"";var o,i=this.getActionModelByPanel(e);if(i&&(o=i.getSelectedElement(),i.resetElements()),t){var n=ao.createActionModel(e,i?i.initialLogicAction:null,t,this.selectorElementsHash);this.setActionModelByPanel(e,n),n.isTrigger?n.updatePanelElements(o,this.options):n.updatePanelElements(o,this.getSelectorChoices(n.logicType))}},t.prototype.getLogicTypeByName=function(e){if(!e)return null;for(var t=this.editableItem.getVisibleLogicTypes(),o=0;o<t.length;o++)if(t[o].name==e)return t[o];return null},t.prototype.isElementSelectorVisible=function(e){return!!e&&e.hasSelectorChoices},t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.getElementText=function(e,t){var o="";return t&&(o=e.locTitle.renderedHtml),o||(o=e.name),e.isQuestion&&(o=this.options.getObjectDisplayName(e,"logic-tab:question-selector","condition",o)),o},t.prototype.getSelectorChoices=function(e){if(!e.hasSelectorChoices)return[];for(var t=e.getSelectorChoices(this.survey,this.context),n=[],r=this.options.showTitlesInExpressions,a=0;a<t.length;a++){var s="",l="",u=t[a],p=e.getParentElement(u);p&&(s=p.name+".",l=this.getElementText(p,r)+".");var c=this.getElementText(u,r),d=s+u.name,h=new o.ItemValue(d,l+c);this.selectorElementsHash[d]=u,u[e.propertyName]&&!this.isElementInInitialSelection(e.name,u)&&(h.enableIf="1=2",h.visibleIf="1=2"),n.push(h)}return"asc"===i.logic.questionSortOrder&&ee.sortItems(n),n},t.prototype.isElementInInitialSelection=function(e,t){return!!this.initialSelectedElements[e]&&this.initialSelectedElements[e].indexOf(t)>-1},t}(it);n(790);var co=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,t,o)||this;return i.survey=t,i.options=o,i.itemUIHash={},i.options||(i.options=new a),i.setupToolbarItems(),i.update(),i}return K(t,e),t.prototype.update=function(t,o){var i=this;void 0===t&&(t=null),void 0===o&&(o=null),e.prototype.update.call(this,t,o);var n=this.options.createSurvey(this.getLogicItemSurveyJSON(),"logic-items",this,(function(e){e.css=to}));this.itemsSurveyValue=n,this.itemsSurvey.onMatrixRowRemoving.add((function(e,t){var o=i.visibleItems[t.rowIndex];t.allow=i.canRemoveItem(o)})),this.itemsSurvey.onMatrixRowRemoved.add((function(e,t){var o=i.visibleItems[t.rowIndex],n=o===i.editableItem;i.removeItem(o,!1),n&&(i.mode="view",i.updateNewActionState()),i.expressionEditorCanShowBuilder=!!i.editableItem})),this.itemsSurvey.onGetMatrixRowActions.add((function(e,t){!function(e,t,o){var i=_t(t,"show-detail");if(i){i.component="sv-action-bar-item",i.iconName="icon-logic-expand",i.innerCss="sl-table__action-button sl-table__detail-button",i.iconSize=48,i.showTitle=!1,i.action=function(){o.showHideDetailPanelClick()};var n=function(){i.iconName=o.isDetailPanelShowing?"icon-logic-collapse":"icon-logic-expand"};e.registerFunctionOnPropertyValueChanged("isRowShowing"+o.id,n),n()}}(t.question,t.actions,t.row),function(e,t,o){Mt(e,t,o);var i=_t(t,"remove-row");i&&(i.css="sl-table__action-button sl-table__remove-button")}(t.question,t.actions,t.row)})),this.updateItemsSurveyData(),this.onReadOnlyChanged()},t.prototype.dispose=function(){for(var t in e.prototype.dispose.call(this),this.itemUIHash){var o=this.itemUIHash[t];o.expressionEditor.dispose(),o.itemEditor.dispose()}this.itemUIHash={}},t.prototype.addNewUI=function(){0!=this.items.length&&this.items[this.items.length-1].isNew||(this.matrixItems.lockResetRenderedTable=!0,this.addNew(),this.matrixItems.lockResetRenderedTable=!1);var e=this.matrixItems.visibleRows;e[e.length-1].showDetailPanel()},t.prototype.toggleExpressionEditorIsFastEntry=function(){this.expressionEditorIsFastEntry=!this.expressionEditorIsFastEntry,this.expressionEditor&&this.expressionEditor.setIsFastEntry(this.expressionEditorIsFastEntry)},t.prototype.updateEditableItemIsModifiedState=function(){this.editableItem&&(this.editableItem.isModified=!!this.itemEditor&&!!this.expressionEditor&&(this.itemEditor.isModified||this.expressionEditor.isModified(this.editableItem.expression)))},t.prototype.getUnsavedItems=function(){for(var e=[],t=0;t<this.visibleItems.length;t++){var o=this.visibleItems[t],i=this.findLogicItemUI(o);i&&(o.isNew?i.expressionEditor.isEmpty()&&i.itemEditor.isEmpty()||e.push(o):o.isModified&&e.push(o))}return e},t.prototype.getErroredItem=function(e){for(var t=0;t<e.length;t++){var o=e[t];if(this.isErroredItem(o))return o}return null},t.prototype.isErroredItem=function(e){var t=this.findLogicItemUI(e);return!!t&&(t.expressionEditor.hasErrors()||t.itemEditor.hasErrors())},t.prototype.showErroredItem=function(e){var t=this.visibleItems.indexOf(e),o=this.matrixItems.visibleRows,i=t>-1&&t<o.length?o[t]:null;i&&(o.forEach((function(e){return e.hideDetailPanel()})),this.mode="view",i.showDetailPanel(),this.hasErrorInUI())},t.prototype.saveItem=function(e){this.isErroredItem(e)||(this.options&&this.options.startUndoRedoTransaction(),this.doItemApply(e),this.options&&this.options.stopUndoRedoTransaction())},t.prototype.tryLeaveUI=function(e){var t=this;this.updateEditableItemIsModifiedState();var o=this.getUnsavedItems();if(0===o.length)return e&&e(!0),!0;var i=this.getErroredItem(o),n=function(){o.forEach((function(e){return t.saveItem(e)})),e&&e(!0)};if(!i)return n(),!0;var r=function(){t.showErroredItem(i),e&&e(!1)};return this.confirmLeavingOnError(n,r)?void 0:(r(),!1)},t.prototype.confirmLeavingOnError=function(e,t){if(!o.settings.showDialog)return!1;var i=new o.LocalizableString(void 0);i.text=this.getLocString("ed.lg.uncompletedRule_text");var n=o.settings.showDialog({componentName:"sv-string-viewer",data:{locStr:i,locString:i,model:i},onApply:function(){return e(),!0},onCancel:function(){return t(),!0},cssClass:"svc-creator-popup",title:this.getLocString("ed.lg.uncompletedRule_title"),displayMode:"popup"},this.options.rootElement),r=n.footerToolbar,a=r.getActionById("apply");return r.getActionById("cancel").title=this.getLocString("ed.lg.uncompletedRule_cancel"),a.title=this.getLocString("ed.lg.uncompletedRule_apply"),a.innerCss+=" svc-logic-tab__leave-apply-button",n.width="800px",!0},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"items"===t&&this.updateItemsSurveyData()},t.prototype.onReadOnlyChanged=function(){var e=this;this.itemsSurvey&&(this.itemsSurvey.mode=this.readOnly?"display":"edit",Object.keys(this.itemUIHash||{}).forEach((function(t){e.updateEditModeLogicItem(e.itemUIHash[t])})))},Object.defineProperty(t.prototype,"expressionEditor",{get:function(){return this.expressionEditorValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemEditor",{get:function(){return this.itemEditorValue},enumerable:!1,configurable:!0}),t.prototype.getExpressionEditor=function(e){return this.getLogicItemUI(e).expressionEditor},t.prototype.getLogicItemEditor=function(e){return this.getLogicItemUI(e).itemEditor},t.prototype.updateEditModeLogicItem=function(e){e&&(e.expressionEditor.editSurvey.mode=this.readOnly?"display":"edit",e.itemEditor.editSurvey.mode=this.readOnly?"display":"edit")},t.prototype.getLogicItemUI=function(e){var t=this.findLogicItemUI(e);if(!t){var o=e.getContext();t={expressionEditor:this.createExpressionPropertyEditor(),itemEditor:new po(e,this.options)},this.updateEditModeLogicItem(t),t.expressionEditor.context=o,t.itemEditor.context=o,t.expressionEditor.text=e.expression,t.expressionEditor.onContextChanged=function(e){t.itemEditor.context=e},this.itemUIHash[e.id]=t}return t},t.prototype.findLogicItemUI=function(e){return this.itemUIHash[e.id]},Object.defineProperty(t.prototype,"expressionSurvey",{get:function(){return this.expressionEditor.editSurvey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemEditorSurvey",{get:function(){return this.itemEditor.editSurvey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemsSurvey",{get:function(){return this.itemsSurveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasItems",{get:function(){return this.items.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"matrixItems",{get:function(){return this.itemsSurvey.getQuestionByName("items")},enumerable:!1,configurable:!0}),t.prototype.onStartEditing=function(){e.prototype.onStartEditing.call(this),this.expressionEditorValue=this.getExpressionEditor(this.editableItem),this.itemEditorValue=this.getLogicItemEditor(this.editableItem),this.expressionEditorIsFastEntry=!1,this.expressionEditor.setIsFastEntry(this.expressionEditorIsFastEntry),this.expressionEditorCanShowBuilder=ro.canBuildExpression(this.expressionEditor.text)},t.prototype.onEndEditing=function(){this.updateEditableItemIsModifiedState(),e.prototype.onEndEditing.call(this),this.expressionEditorValue=null,this.itemEditorValue=null},t.prototype.onEditableItemApply=function(){this.doItemApply(this.editableItem),this.editableItem.isSuitable(this.questionFilter,this.actionTypeFilter)?this.updateItemsSurveyData():(this.questionFilter="",this.actionTypeFilter="")},t.prototype.doItemApply=function(e){var t=this.findLogicItemUI(e);t&&(t.expressionEditor.apply(),t.itemEditor.apply(),e.apply(t.expressionEditor.text),e.actions.length!=t.itemEditor.panels.length&&t.itemEditor.setEditableItem(e),t.itemEditor.resetModified(),e.isNew=!1)},t.prototype.hasErrorInUI=function(){var e=this.survey.creator;return this.expressionEditor.hasErrorInUI()?(this.errorText=this.expressionEditor.errorText,!0):!!this.itemEditor.hasErrors()&&(this.errorText=ke("actionInvalid"),e&&e.notify(this.errorText,"error"),!0)},t.prototype.getExpressionText=function(){return this.expressionEditor.text},t.prototype.getEditingActions=function(){return this.itemEditor.getEditingActions()},t.prototype.getLogicItemSurveyJSON=function(){var e=this.survey.creator,t=e&&e.useTableViewInLogicTab?this.getTwoColumnsLayout():this.getOneColumnLayout();return ot(t),t},t.prototype.getTwoColumnsLayout=function(){return{elements:[{type:"matrixdynamic",name:"items",titleLocation:"hidden",detailPanelMode:"underRowSingle",allowAddRows:!1,allowAdaptiveActions:!1,rowCount:0,columns:[{cellType:"linkvalue",name:"conditions",title:this.getLocString("ed.lg.conditions")},{cellType:"linkvalue",name:"actions",title:this.getLocString("ed.lg.actions")}]}]}},t.prototype.getOneColumnLayout=function(){return{elements:[{type:"matrixdynamic",name:"items",titleLocation:"hidden",showColumnHeader:!1,detailPanelMode:"underRowSingle",allowAddRows:!1,allowAdaptiveActions:!1,rowCount:0,showHeader:!1,columns:[{cellType:"linkvalue",name:"rules",showTooltip:!0,width:"100%"}]}]}},t.prototype.createExpressionPropertyEditor=function(){var e=this,t=new ro(this.survey,null,this.options);return t.isModal=!1,t.editSurvey.onValueChanged.add((function(t,o){"textEditor"===o.name&&(e.expressionEditorCanShowBuilder=ro.canBuildExpression(o.value))})),t},t.prototype.getVisibleItems=function(){var e=this;return this.items.filter((function(t){return t.isNew||t.isSuitable(e.questionFilter,e.actionTypeFilter)}))},t.prototype.getDataFromItem=function(e){var t=this.survey.creator;return t&&t.useTableViewInLogicTab?{conditions:e.expressionText,actions:e.actionsText}:{rules:this.getLogicItemDisplayText(e)}},t.prototype.getLogicItemDisplayText=function(e){var t=e.getDisplayText();return this.options?this.options.onLogicGetTitleCallback(e.expression,e.expressionText,t,e):t},t.prototype.updateItemsSurveyData=function(){var e=this;if(this.itemsSurvey){var t=[];this.visibleItems=this.getVisibleItems(),this.visibleItems.forEach((function(o){t.push(e.getDataFromItem(o))})),this.matrixItems.onHasDetailPanelCallback=function(e){return!0},this.matrixItems.onCreateDetailPanelCallback=function(t,o){t.onDetailPanelShowingChanged=function(){if(e.expressionEditorCanShowBuilder=t.isDetailPanelShowing,t.isDetailPanelShowing){if("view"===e.mode){var i=e.visibleItems[t.rowIndex-1];e.editItem(i)}var n=o.getQuestionByName("conditions"),r=o.getQuestionByName("actions");n.embeddedSurvey=e.expressionEditor.editSurvey,r.embeddedSurvey=e.itemEditorValue.editSurvey,e.updateRowIsAdditionalClasses(t.rowIndex-1,!1)}else e.mode="view",e.updateRenderedRows();e.updateNewActionState()},o.addNewQuestion("embeddedsurvey","conditions"),o.addNewQuestion("embeddedsurvey","actions"),o.footerActions.push({id:"saveDetailPanel",innerCss:"sl-panel__done-button",title:e.getLocString("pe.doneEditing"),action:function(){e.saveEditableItem()&&t.hideDetailPanel(!0)}})},this.matrixItems.onCellCreatedCallback=function(e){e.cell.question.linkClickCallback=function(){e.row.isDetailPanelShowing?e.row.hideDetailPanel():e.row.showDetailPanel()},e.cell.question.showClear=!1,e.cell.question.allowClear=!1},this.matrixItems.value=t,this.updateRenderedRows()}},t.prototype.updateRenderedRows=function(){var e=this;this.visibleItems.forEach((function(t,o){e.updateRowIsAdditionalClasses(o,e.visibleItems[o].isModified||e.visibleItems[o].isNew)}))},t.prototype.updateRowIsAdditionalClasses=function(e,t){this.matrixItems.renderedTable&&(this.matrixItems.renderedTable.rows.filter((function(e){return e.visible}))[e].isAdditionalClasses=t)},t.prototype.updateNewActionState=function(){this.addNewButton.enabled="new"!==this.mode},t.prototype.setupToolbarItems=function(){var e=this;this.addNewButton=new o.Action({id:"svd-logic-addNew",title:this.addNewText,tooltip:this.addNewText,component:"sv-action-bar-item",enabled:!0,action:function(){e.addNewUI()}})},Object.defineProperty(t.prototype,"addNewText",{get:function(){return ke("addNewItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"emptyTabPlaceholder",{get:function(){return ke("empty_tab")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.options.isMobileView?ke("logicPlaceholderTitleMobile"):ke("logicPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.options.isMobileView?ke("logicPlaceholderDescriptionMobile"):ke("logicPlaceholderDescription")},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"itemsSurveyValue",void 0),J([(0,o.property)()],t.prototype,"expressionEditorIsFastEntry",void 0),J([(0,o.property)()],t.prototype,"expressionEditorCanShowBuilder",void 0),J([(0,o.property)({onSet:function(e,t){t.updateItemsSurveyData()}})],t.prototype,"questionFilter",void 0),J([(0,o.property)({onSet:function(e,t){t.updateItemsSurveyData()}})],t.prototype,"actionTypeFilter",void 0),t}(Ue),ho=function(){function e(e){this.creator=e,e.addPluginTab("logic",this),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.activate=function(){var e=this;this.model=new co(this.creator.survey,this.creator),this.filterQuestionAction.title=this.createFilterQuestionTitleUpdater(),this.filterQuestionAction.visible=!0,this.filterActionTypeAction.title=this.createFilterTypeTitleUpdater(),this.filterActionTypeAction.visible=!0,this.fastEntryAction&&(this.fastEntryAction.visible=!0,this.fastEntryAction.active=this.model.expressionEditorIsFastEntry,this.fastEntryAction.enabled=!1),this.model.onPropertyChanged.add((function(t,o){e.fastEntryAction&&"expressionEditorIsFastEntry"===o.name&&(e.fastEntryAction.active=e.model.expressionEditorIsFastEntry),e.fastEntryAction&&"expressionEditorCanShowBuilder"===o.name&&(e.fastEntryAction.enabled=e.model.expressionEditorCanShowBuilder)}))},e.prototype.createFilterTypeTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;t||(t="en");var o=e.model.actionTypeFilter,i=e.showAllActionTypesText;return o?e.model.getTypeByName(o).displayName:i}))},e.prototype.createFilterQuestionTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;t||(t="en");var o=e.model.questionFilter,i=e.showAllQuestionsText;return o||i}))},e.prototype.update=function(){this.model&&this.model.update(this.creator.survey)},e.prototype.canDeactivateAsync=function(e){var t=this;this.model?this.model.tryLeaveUI((function(o){o?e():t.creator.notify(G.getString("ed.lg.expressionInvalid"),"error")})):e()},e.prototype.deactivate=function(){return this.disposeObjs(),!0},e.prototype.dispose=function(){this.disposeObjs()},e.prototype.disposeObjs=function(){this.filterActionTypeAction.title=void 0,this.filterQuestionAction.title=void 0,this.model&&(this.model.dispose(),this.model=void 0),this.filterQuestionAction.visible=!1,this.filterActionTypeAction.visible=!1,this.fastEntryAction&&(this.fastEntryAction.visible=!1)},e.prototype.createActions=function(){var e=this,t=[];return this.filterQuestionAction=(0,o.createDropdownActionModelAdvanced)({id:"svc-logic-filter-question",visible:!1},{items:[{id:null,title:this.showAllQuestionsText}],onSelectionChanged:function(t){e.model.questionFilter=t.id?t.id:""},allowSelection:!0,locOwner:this.creator},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var t=e.model.getUsedQuestions().map((function(t){return{id:t.name,title:e.creator.getObjectDisplayName(t,"logic-tab:question-filter","condition",t.name)}}));ee.sortItems(t,"title"),e.filterQuestionAction.popupModel.contentComponentData.model.setItems([{id:null,title:e.showAllQuestionsText}].concat(t))}}),t.push(this.filterQuestionAction),this.filterActionTypeAction=(0,o.createDropdownActionModelAdvanced)({id:"svc-logic-filter-actiontype",visible:!1},{items:[{id:null,title:this.showAllActionTypesText}],onSelectionChanged:function(t){e.model.actionTypeFilter=t.id?t.id:""},allowSelection:!0,locOwner:this.creator},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var t=e.model.getUsedActionTypes().map((function(e){return{id:e.name,title:e.displayName}}));ee.sortItems(t,"title"),e.filterActionTypeAction.popupModel.contentComponentData.model.setItems([{id:null,title:e.showAllActionTypesText}].concat(t))}}),t.push(this.filterActionTypeAction),this.creator.allowEditExpressionsInTextEditor&&(this.fastEntryAction=new o.Action({id:"svc-logic-fast-entry",iconName:"icon-fast-entry",locTitleName:"pe.fastEntry",visible:!1,component:"sv-action-bar-item",action:function(){e.model.toggleExpressionEditorIsFastEntry()}}),t.push(this.fastEntryAction)),t},Object.defineProperty(e.prototype,"showAllQuestionsText",{get:function(){return ke("showAllQuestions")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllActionTypesText",{get:function(){return ke("showAllActionTypes")},enumerable:!1,configurable:!0}),e}(),go=function(){function e(){this._ignoreChanges=!1,this._isExecuting=!1,this._preparingTransaction=null,this._transactions=[],this._currentTransactionIndex=-1,this.transactionCounter=0}return e.prototype.onPropertyValueChanged=function(e,t,o,i,n){if(!Ze.isCopyObject(i)&&!this.isIgnoring&&!0!==i.ignoreUndoRedo){var r=this._preparingTransaction,a=n?new yo(e,i,n):new fo(e,t,o,i);if(!r)return(r=new mo(e)).addAction(a),void this._addTransaction(r);r.addAction(a)}},e.prototype.isCorrectProperty=function(e,t){var i=o.Serializer.getOriginalProperty(e,t);return!!i&&i.isSerializable},e.prototype.tryMergeTransaction=function(e,t,o){if("name"===t)return!1;var i=this._getCurrentTransaction();return!(!i||0==i.actions.length)&&i.actions[i.actions.length-1].tryMerge(e,t,o)},e.prototype.isCopyObject=function(e){},e.prototype._cutOffTail=function(){this._currentTransactionIndex+1!==this._transactions.length&&(this._transactions.length=this._currentTransactionIndex+1)},Object.defineProperty(e.prototype,"isIgnoring",{get:function(){return this._ignoreChanges||this._isExecuting},enumerable:!1,configurable:!0}),e.prototype._addTransaction=function(e){e.isEmpty()||(this._cutOffTail(),this._transactions[this._currentTransactionIndex]!==e&&(this._transactions.push(e),this._currentTransactionIndex++),this.canUndoRedoCallback())},e.prototype._getCurrentTransaction=function(){var e=this._currentTransactionIndex;return this._transactions[e]},e.prototype._getNextTransaction=function(){var e=this._currentTransactionIndex;return this._transactions[e+1]},e.prototype.notifyChangesFinished=function(e,t){void 0===t&&(t=!1),e.actions.length>0&&this.changesFinishedCallback&&this.changesFinishedCallback(e.actions,t)},e.prototype.canUndoRedoCallback=function(){},e.prototype.startTransaction=function(e){this.isIgnoring||(this.transactionCounter++,this._preparingTransaction||(this._preparingTransaction=new mo(e)))},e.prototype.stopTransaction=function(){this.isIgnoring||(this.transactionCounter>0&&this.transactionCounter--,!this._preparingTransaction||this.transactionCounter>0||(this._addTransaction(this._preparingTransaction),0===this.transactionCounter&&this.notifyChangesFinished(this._preparingTransaction),this._preparingTransaction=null))},e.prototype.setUndoCallbackForTransaction=function(e){this._preparingTransaction&&(this._preparingTransaction.undoCallback=e)},Object.defineProperty(e.prototype,"isProcessingUndoRedo",{get:function(){return!0===this._isExecuting},enumerable:!1,configurable:!0}),e.prototype.canUndo=function(){return!!this._getCurrentTransaction()},e.prototype.undo=function(){var e=this._getCurrentTransaction();this.canUndo()&&(this._isExecuting=!0,e.rollback(),this._isExecuting=!1,this._currentTransactionIndex--,this.canUndoRedoCallback(),this.notifyChangesFinished(e,!0))},e.prototype.canRedo=function(){return!!this._getNextTransaction()},e.prototype.redo=function(){var e=this._getNextTransaction();this.canRedo()&&(this._isExecuting=!0,e.apply(),this._isExecuting=!1,this._currentTransactionIndex++,this.canUndoRedoCallback(),this.notifyChangesFinished(e))},e.prototype.suspend=function(){this._ignoreChanges=!0},e.prototype.resume=function(){this._ignoreChanges=!1},e}(),mo=function(){function e(e){this._name=e,this._actions=[],this.undoCallback=function(){}}return e.prototype.apply=function(){for(var e=this._actions,t=0;t<e.length;t++)e[t].apply()},e.prototype.rollback=function(){for(var e=this._actions,t=e.length-1;t>=0;t--)e[t].rollback();this.undoCallback()},e.prototype.addAction=function(e){this._actions.push(e)},e.prototype.isEmpty=function(){return 0===this._actions.length},Object.defineProperty(e.prototype,"actions",{get:function(){return this._actions},enumerable:!1,configurable:!0}),e}(),fo=function(){function e(e,t,o,i){this._propertyName=e,this._oldValue=t,this._newValue=o,this._sender=i,this.tickCount=(new Date).getTime()}return e.prototype.apply=function(){this._sender[this._propertyName]=this._newValue},e.prototype.rollback=function(){this._sender[this._propertyName]=this._oldValue},e.prototype.getChanges=function(e){return void 0===e&&(e=!1),{object:this._sender,propertyName:this._propertyName,oldValue:e?this._newValue:this._oldValue,newValue:e?this._oldValue:this._newValue}},e.prototype.getDeletedElement=function(e){},e.prototype.getInsertedElement=function(e){},e.prototype.getIndex=function(){return-1},e.prototype.tryMerge=function(t,i,n){if(t!==this._sender||i!==this._propertyName||n==this._oldValue)return!1;var r=o.Serializer.getOriginalProperty(t,i);return!(!r||"string"!==r.type&&"text"!==r.type||(new Date).getTime()-this.tickCount>e.maximumMergeTime||(this._newValue=n,0))},e.maximumMergeTime=1e3,e}(),yo=function(){function e(e,t,o){this._propertyName=e,this._sender=t,this._index=0,this._itemsToAdd=[],this._deletedItems=[],this.survey=t.getSurvey(),this._index=o.index,this._itemsToAdd=o.itemsToAdd,this._deletedItems=o.deletedItems}return e.prototype.apply=function(){this.rollback()},e.prototype.rollback=function(){if(this._sender=this.getSenderElement(),this._sender){var e=this._sender[this._propertyName],t=this._index,o=this._itemsToAdd.length,i=this.getItemsToAdd();this._deletedItems=e.splice.apply(e,[t,o].concat(i)),this._itemsToAdd=[].concat(i)}},e.prototype.getChanges=function(){return{object:this._sender,propertyName:this._propertyName,oldValue:this._deletedItems,newValue:this._itemsToAdd}},e.prototype.getDeletedElement=function(e){return this.getMovedElement(this._deletedItems,this._itemsToAdd,e)},e.prototype.getInsertedElement=function(e){return this.getMovedElement(this._itemsToAdd,this._deletedItems,e)},e.prototype.getIndex=function(){return this._index},e.prototype.getMovedElement=function(e,t,o){var i=o?t:e;if(Array.isArray(i)&&1===i.length)return i[0]},e.prototype.tryMerge=function(e,t,o){return!1},e.prototype.getSenderElement=function(){if(!this._sender.isDisposed||!this.survey)return this._sender;var e=this._sender.name;return!0===this._sender.isPage?0===this.survey.pages.length?this.survey.addNewPage():this.survey.getPageByName(e):!0===this._sender.isPanel?this.survey.getPanelByName(e):!0===this._sender.isQuestion?this.survey.getQuestionByName(e):this._sender},e.prototype.getItemsToAdd=function(){for(var e=[],t=0;t<this._deletedItems.length;t++){var i=this._deletedItems[t];if(i.isDisposed&&i.getType){var n=i.toJSON();(i=o.Serializer.createClass(i.getType())).fromJSON(n)}e.push(i)}return e},e}(),vo=function(e){function t(t){var i=e.call(this)||this;return i.creator=t,i.undoRedoManager=void 0,i.onBeforeUndo=new o.EventBase,i.onBeforeRedo=new o.EventBase,i.updateSurvey(),i}return K(t,e),t.prototype.onSurveyPropertyValueChangedCallback=function(e,t,o,i,n){this.undoRedoManager&&this.undoRedoManager.isCorrectProperty(i,e)&&(this.undoRedoManager.tryMergeTransaction(i,e,o)?this.creator.notifySurveyPropertyChanged({name:e,target:i,oldValue:t,newValue:o}):(this.undoRedoManager.startTransaction(e+" changed"),this.undoRedoManager.onPropertyValueChanged(e,t,o,i,n),this.creator.updateElementsOnLocaleChanged(i,e),this.creator.updateConditionsOnNameChanged(i,e,t),this.undoRedoManager.stopTransaction()))},t.prototype.updateSurvey=function(){var e=this,t=this.creator.survey;t&&(t.onPropertyValueChangedCallback=function(t,o,i,n,r){e.onSurveyPropertyValueChangedCallback(t,o,i,n,r)}),this.undoRedoManager=new go,this.undoRedoManager.changesFinishedCallback=function(t,o){if(!e.notifySurveyMoveItem(t,o))for(var i=t.length-1;i>=0;i--){var n=t[i];if(n){var r=n.getChanges(o);e.creator.notifySurveyPropertyChanged({name:r.propertyName,target:r.object,oldValue:r.oldValue,newValue:r.newValue})}}},this.undoRedoManager.canUndoRedoCallback=function(){e.updateUndeRedoActions()}},t.prototype.notifySurveyMoveItem=function(e,t){e.length;var o=e[0],i=e[1];if(!o||!i)return!1;var n=o.getChanges(t),r=i.getChanges(t);if(n.object!==r.object||n.propertyName!==r.propertyName)return!1;var a=o.getDeletedElement(t),s=o.getInsertedElement(t),l=i.getDeletedElement(t),u=i.getInsertedElement(t);if(a===s||a!==u&&s!==l)return!1;var p=a?o.getIndex():i.getIndex(),c=s?o.getIndex():i.getIndex();return this.creator.notifySurveyItemMoved({arrayName:n.propertyName,parent:n.object,element:a||s,indexFrom:t?c:p,indexTo:t?p:c}),!0},t.prototype.selectElementAfterUndo=function(){this.selectElementAfterUndoCore(this.creator.selectedElement)},t.prototype.selectElementAfterUndoCore=function(e){!e||e.isDisposed||!e.getSurvey()||this.creator.isObjQuestion(e)&&!e.parent?this.creator.selectElement(this.creator.survey):this.creator.selectElement(e)},t.prototype.undo=function(){if(this.undoRedoManager){this.undoRedoManager.suspend();var e={canUndo:this.undoRedoManager.canUndo()};this.onBeforeUndo.fire(this.creator,e),this.creator.onBeforeUndo.fire(this.creator,e),e.canUndo&&(this.undoRedoManager.undo(),this.selectElementAfterUndo()),this.undoRedoManager.resume()}},t.prototype.redo=function(){if(this.undoRedoManager){var e={canRedo:this.undoRedoManager.canRedo()};this.onBeforeRedo.fire(this.creator,e),this.creator.onBeforeRedo.fire(this.creator,e),e.canRedo&&(this.undoRedoManager.redo(),this.selectElementAfterUndo())}},t.prototype.startTransaction=function(e){void 0===e&&(e=""),this.undoRedoManager&&this.undoRedoManager.startTransaction(e)},t.prototype.stopTransaction=function(){this.undoRedoManager&&this.undoRedoManager.stopTransaction()},t.prototype.createActions=function(){var e=this,t=[];return this.undoAction=new o.Action({id:"action-undo",iconName:"icon-undo",locTitleName:"ed.undo",showTitle:!1,visible:new o.ComputedUpdater((function(){return"designer"===e.creator.activeTab})),needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),action:function(){return e.undo()}}),this.redoAction=new o.Action({id:"action-redo",iconName:"icon-redo",locTitleName:"ed.redo",showTitle:!1,visible:new o.ComputedUpdater((function(){return"designer"===e.creator.activeTab})),action:function(){return e.redo()}}),t.push(this.undoAction),t.push(this.redoAction),this.updateUndeRedoActions(),t},t.prototype.updateUndeRedoActions=function(){this.undoAction.enabled=this.undoRedoManager.canUndo(),this.redoAction.enabled=this.undoRedoManager.canRedo()},J([(0,o.property)()],t.prototype,"undoRedoManager",void 0),t}(o.Base),bo=function(){function e(e){var t=this;this.creator=e,this.model=void 0,this.model=new vo(e),this.model.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),e.registerShortcut("undo",{affectedTab:"designer",hotKey:{ctrlKey:!0,keyCode:90},macOsHotkey:{keyCode:90},execute:function(){return t.model.undo()}}),e.registerShortcut("redo",{affectedTab:"designer",hotKey:{ctrlKey:!0,keyCode:89},macOsHotkey:{keyCode:89},execute:function(){return t.model.redo()}})}return e.prototype.activate=function(){},e.prototype.deactivate=function(){return!0},e.prototype.update=function(){},e.prototype.addFooterActions=function(){this.model.undoAction&&this.creator.footerToolbar.actions.splice(2,0,this.model.undoAction),this.model.redoAction&&this.creator.footerToolbar.actions.splice(3,0,this.model.redoAction)},e}();function Co(e,t){return void 0===t&&(t="undoRedoManager"),function(o,i,n){var r=n.value;return n.value=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=this[t];try{return a&&a.startTransaction(e||i),r.apply(this,o)}finally{a&&a.stopTransaction()}},n}}function wo(e){return void 0===e&&(e="undoRedoManager"),function(t,o,i){var n=i.value;return i.value=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];var i=this[e];try{return i&&i.suspend(),n.apply(this,t)}finally{i&&i.resume()}},i}}var xo=function(e){function t(t,o,i,n){var r=e.call(this,{id:"sv_item_selector_"+t.toString(),title:i})||this;return r.data=o,r.level=n,r}return K(t,e),t.prototype.hasText=function(e){return!e||(this.textInLow||(this.textInLow=this.title.toLocaleLowerCase()),this.textInLow.indexOf(e)>-1)},t}(o.Action),To=function(){function e(e,t,o){void 0===o&&(o=void 0),this.creator=e,this.getObjectDisplayName=o,this.surveyValue=t,this.rebuild()}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"items",{get:function(){return this.itemsValue},enumerable:!1,configurable:!0}),e.prototype.getItemByObj=function(e){for(var t=this.items,o=0;o<t.length;o++)if(t[o].data===e)return t[o];return null},e.prototype.filterByText=function(e){this.filteredTextInLow=e?e.toLocaleLowerCase():"",this.updateItemsVisibility()},e.prototype.rebuild=function(){var e=[];this.deepestLevel=0;var t=this.createItem(this.survey,null);e.push(t);for(var o=0;o<this.survey.pages.length;o++){var i=this.survey.pages[o],n=t;if(!this.creator||"single"!==this.creator.pageEditMode){var r=this.createItem(i,t);e.push(r),n=r}this.buildElements(e,this.getElements(i),n)}this.itemsValue=e},e.prototype.updateItemsVisibility=function(){for(var e=this.deepestLevel;e>=0;e--)this.updateItemsLevelVisibility(e)},e.prototype.updateItemsLevelVisibility=function(e){for(var t=0;t<this.items.length;t++){var o=this.items[t];o.level===e&&(o.visible=this.hasVisibleChildren(t)||o.hasText(this.filteredTextInLow))}},e.prototype.hasVisibleChildren=function(e){for(var t=this.items[e].level,o=e+1;o<this.items.length;o++){if(this.items[o].level<=t)return!1;if(this.items[o].visible)return!0}return!1},e.prototype.getElements=function(e){return ee.getElements(e)},e.prototype.buildElements=function(e,t,o){for(var i=0;i<t.length;i++){var n=t[i],r=this.createItem(n,o);e.push(r),this.buildElements(e,this.getElements(n),r)}},e.prototype.createItem=function(t,o){var i=new xo(e.uniqueId++,t,this.getText(t),null!=o?o.level+1:0);return i.level>this.deepestLevel&&(this.deepestLevel=i.level),i},e.prototype.getText=function(e){return this.getObjectDisplayName?this.getObjectDisplayName(e,"property-grid-header:element-list","property-grid",void 0):ee.getObjectName(e,!1)},e.uniqueId=0,e}(),So=function(e){function t(t,o){void 0===o&&(o=void 0);var i=e.call(this)||this;return i.creator=t,i.getObjectDisplayName=o,i}return K(t,e),Object.defineProperty(t.prototype,"list",{get:function(){return this.listModelValue},enumerable:!1,configurable:!0}),t.prototype.show=function(e,t,i){var n=this;this.selector=new To(this.creator,e,this.getObjectDisplayName);var r=this.selector.getItemByObj(t);this.listModelValue?(this.listModelValue.setItems(this.selector.items),this.listModelValue.selectedItem=r):(this.listModelValue=new o.ListModel({items:this.selector.items,onSelectionChanged:function(e){i(e.data)},allowSelection:!0,selectedItem:r}),this.listModelValue.setOnFilterStringChangedCallback((function(e){n.selector.filterByText(e)}))),this.isVisible=!0},t.prototype.refresh=function(){this.listModelValue.refresh()},J([(0,o.property)()],t.prototype,"isVisible",void 0),t}(o.Base),Po=function(e){function t(t,o){var n=e.call(this)||this;return n.propertyGridModel=t,n.creator=o,n.searchManager=new me,n.searchEnabled=i.propertyGrid.enableSearch,n.selectedElementName=n.getTitle(),n.propertyGridModel.objValueChangedCallback=function(){n.onSurveyChanged()},n.propertyGridModel.changedFromActionCallback=function(e,t){n.selectionController&&n.selectionController.selectFromAction(e,t)},n.initActions(),n.creator.onPropertyChanged.add((function(e,t){"sidebarLocation"===t.name&&(n.selectorPopupModel.horizontalPosition="right"==n.creator.sidebarLocation?"left":"right")})),n.onSurveyChanged(),n}return K(t,e),t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.nextSelectionAction&&"hasNext"===t&&(this.nextSelectionAction.enabled=this.hasNext),this.prevSelectionAction&&"hasPrev"===t&&(this.prevSelectionAction.enabled=this.hasPrev)},Object.defineProperty(t.prototype,"selectionController",{get:function(){return this.creator.selectionHistoryController},enumerable:!1,configurable:!0}),t.prototype.onSurveyChanged=function(){var e=this;this.survey=this.propertyGridModel.survey,this.searchManager.setSurvey(this.survey),this.survey&&this.survey.onValueChanged.add((function(t,o){"name"!=o.name&&"title"!=o.name||e.updateTitle()})),this.updateTitle(),this.selectionController&&(this.hasPrev=this.selectionController.hasPrev,this.hasNext=this.selectionController.hasNext)},t.prototype.updateTitle=function(){var e=this.getTitle();this.selectedElementName=e,this.objectSelectionAction.title=this.selectedElementName},t.prototype.getTitle=function(){var e=this.getSelectedObj();if(!e)return"";var t=ee.getObjectName(e,this.propertyGridModel.options.showObjectTitles);return this.propertyGridModel.options.getObjectDisplayName(e,"property-grid-header:selected-element","property-grid-title",t)},t.prototype.getSelectedObj=function(){return this.propertyGridModel.obj},t.prototype.initActions=function(){var e=this;i.propertyGrid.showNavigationButtons&&(this.prevSelectionAction=new o.Action({id:"svd-grid-history-prev",iconName:"icon-arrow-left",component:"sv-action-bar-item",title:Z("ed.prevSelected"),showTitle:!1,enabled:this.hasPrev,action:function(){e.selectionController.prev()}}),this.nextSelectionAction=new o.Action({id:"svd-grid-history-next",iconName:"icon-arrow-right",component:"sv-action-bar-item",title:Z("ed.nextSelected"),showTitle:!1,enabled:this.hasNext,action:function(){e.selectionController.next()}})),this.createObjectSwitcherAction()},t.prototype.createObjectSwitcherAction=function(){var e=this,t=new So(this.creator,(function(t,o,i,n){return e.propertyGridModel.options.getObjectDisplayName(t,o,i,n)}));this.selectorPopupModel=new o.PopupModel("svc-object-selector",{model:t},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"}),this.selectorPopupModel.cssClass+=" svc-object-selector",this.selectorPopupModel.displayMode=this.creator.isTouch?"overlay":"popup",this.selectorPopupModel.registerPropertyChangedHandlers(["isVisible"],(function(){e.selectorPopupModel.isVisible?e.objectSelectionAction.pressed=!0:e.objectSelectionAction.pressed=!1})),this.objectSelectionAction=new kt({id:"svd-grid-object-selector",title:this.selectedElementName,css:"sv-action--object-selector sv-action-bar-item--secondary",component:"sv-action-bar-item-dropdown",disableHide:!0,pressed:!1,action:function(){t.show(e.selectionController.creator.survey,e.propertyGridModel.obj,(function(t){e.selectionController.selectFromAction(t,"name"),e.selectorPopupModel.hide()})),e.selectorPopupModel.show(),t.list.scrollToSelectedItem()},popupModel:this.selectorPopupModel}),this.objectSelectionAction.contentType="text-description-vertical"},t.prototype.dispose=function(){this.searchManager.dispose(),this.nextSelectionAction.dispose(),this.prevSelectionAction.dispose(),this.objectSelectionAction.dispose(),this.selectorPopupModel.dispose(),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"hasPrev",void 0),J([(0,o.property)()],t.prototype,"hasNext",void 0),J([(0,o.property)()],t.prototype,"survey",void 0),J([(0,o.property)()],t.prototype,"selectedElementName",void 0),J([(0,o.property)({onSet:function(e,t){t.searchManager.isVisible=e}})],t.prototype,"searchEnabled",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),t}(o.Base),Eo=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.onPagesChanged=o.addEvent(),o.onCurrentPageChanged=o.addEvent(),o.currentPageChangedFunc=function(e,t){o.page2Display=o.survey.currentPage,o.onCurrentPageChanged.fire(o,{})},o.onSurveyChanged(),o}return K(t,e),Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pages",{get:function(){return this.survey.pages},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPage",{get:function(){return this.survey.currentPage},set:function(e){this.survey.currentPage=e,this.page2Display=e},enumerable:!1,configurable:!0}),t.prototype.selectPage=function(e){this.currentPage=e,this.creator.selectElement(e)},t.prototype.getDisplayName=function(e){return e?this.creator.getObjectDisplayName(e,"page-selector"):""},t.prototype.raisePagesChanged=function(){this.page2Display=this.survey.currentPage,this.onPagesChanged.fire(this,{})},t.prototype.onSurveyChanged=function(){this.removeFunctions(),this.surveyValue=this.creator.survey,this.surveyValue&&(this.raisePagesChanged(),this.page2Display=this.survey.currentPage,this.surveyValue.onCurrentPageChanged.add(this.currentPageChangedFunc))},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.removeFunctions()},t.prototype.removeFunctions=function(){this.surveyValue&&!this.surveyValue.isDisposed&&this.surveyValue.onCurrentPageChanged.remove(this.currentPageChangedFunc)},J([(0,o.property)()],t.prototype,"page2Display",void 0),t}(o.Base);n(5876);var Vo=o.settings.allowShowEmptyTitleInDesignMode,Io=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.pagesControllerValue=new Eo(t),o.initToolbar(),o.initSurvey(),o}return K(t,e),Object.defineProperty(t.prototype,"displayPageDropTarget",{get:function(){return this.pagesController.page2Display===this.newPage?"newGhostPage":this.pagesController.page2Display.name},enumerable:!1,configurable:!0}),t.prototype.createNewPage=function(){var e=this;if(!this.creator.canAddPage())return null;var t=this.survey.createNewPage("");t.ignoreUndoRedo=!0,this.creator.setNewNames(t),t.onFirstRendering(),t.updateCustomWidgets(),t.setWasShown(!0),t.setSurveyImpl(this.survey),t.updateElementCss();var o=function(i,n){"elements"===n.name&&t.elements.length>0&&e.creator.addPage(t,!0,(function(){return t.onPropertyChanged.remove(o),t.showTitle=!0,t.showDescription=!0,delete t.ignoreUndoRedo,!(e.survey.pages.indexOf(t)>-1)}))};return t.num=this.survey.pages.length+1,t.onPropertyChanged.add(o),Qt.newGhostPage=t,t},Object.defineProperty(t.prototype,"canShowNewPage",{get:function(){return!(!this.survey||"single"===this.creator.pageEditMode||!this.creator.allowModifyPages)},enumerable:!1,configurable:!0}),t.prototype.isModifiedPage=function(e){return Object.keys(e.toJSON()).filter((function(e){return"name"!==e})).length>0},t.prototype.initToolbar=function(){var e=this;this.actionContainer=new o.ActionContainer;var t=function(t){e.creator.onSurfaceToolbarActionExecuted.fire(e.creator,{action:t})};this.actionContainer.cssClasses={root:"sv-action-bar",defaultSizeMode:"",smallSizeMode:"",item:"svc-page-navigator__selector",itemWithTitle:"",itemAsIcon:"",itemActive:"",itemPressed:"",itemIcon:"svc-page-navigator__navigator-icon",itemTitleWithIcon:""},this.actionContainer.setItems([{id:"collapseAll",locTooltipName:"ed.collapseAllTooltip",iconName:"icon-collapseall-24x24",action:t},{id:"expandAll",locTooltipName:"ed.expandAllTooltip",iconName:"icon-expandall-24x24",action:t}])},Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pagesController",{get:function(){return this.pagesControllerValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isToolboxVisible",{get:function(){return this.creator.showToolbox&&("right"===this.creator.toolboxLocation||"left"===this.creator.toolboxLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceHolderMobile"):Z("ed.surveyPlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceholderTitleMobile"):Z("ed.surveyPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceholderDescriptionMobile"):Z("ed.surveyPlaceholderDescription")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasToolbar",{get:function(){return"never"!=this.creator.expandCollapseButtonVisibility},enumerable:!1,configurable:!0}),t.prototype.onDesignerSurveyPropertyChanged=function(e,t){if(e&&!this.isUpdatingNewPage){if(this.isUpdatingNewPage=!0,"elements"===t&&e.isDescendantOf("page")){var o=!1;0===e.elements.length&&(o=this.checkLastPageToDelete()),this.checkNewPage(o)}"pages"===t&&e.isDescendantOf("survey")&&this.checkNewPage(!0),this.isUpdatingNewPage=!1}},t.prototype.calculateDesignerCss=function(){return this.survey.css.container+" "+this.survey.css.container+"--"+this.survey.calculatedWidthMode},t.prototype.initSurvey=function(){var e=this;this.survey&&(this.showNewPage=!1,this.newPage=void 0,this.checkNewPage(!1),this.cssUpdater&&this.cssUpdater.dispose(),this.cssUpdater=new o.ComputedUpdater((function(){return e.calculateDesignerCss()})),this.designerCss=this.cssUpdater,this.pagesController.onSurveyChanged())},t.prototype.checkNewPage=function(e){var t=0===this.survey.getAllQuestions().length&&0===this.survey.pageCount;if(this.showPlaceholder=t,this.pageCount=this.survey.pageCount,this.showPlaceholder||this.canShowNewPage){var o=this.survey.pages;(!this.newPage||o.length>0&&this.newPage===o[o.length-1])&&(this.newPage=this.createNewPage(),this.showNewPage=!!this.newPage),this.newPage&&(this.newPage.showTitle=!t,this.newPage.showDescription=!t)}else this.showNewPage=!1,this.newPage=void 0;e&&(this.newPage&&(this.newPage.num=this.survey.pages.length+1,this.newPage.startLoadingFromJson(),this.newPage.name=ee.getNewPageName(this.survey.pages),this.newPage.endLoadingFromJson()),this.pagesController.raisePagesChanged())},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.cssUpdater&&this.cssUpdater.dispose()},t.prototype.checkLastPageToDelete=function(){if(0===this.survey.pageCount||this.survey.isQuestionDragging)return!1;var e=this.survey.pages[this.survey.pageCount-1];return!(e.elements.length>0||e.isConverting||ee.isPagePropertiesAreModified(e)||(e.delete(),0===this.survey.pageCount&&this.creator.selectElement(this.survey),0))},t.prototype.clickDesigner=function(){this.creator.selectedElement=this.creator.survey},t.prototype.getRootCss=function(){var e=this.survey.css.root;return(this.creator.showPageNavigator&&this.survey.pageCount>1||"bypage"===this.creator.pageEditMode||this.hasToolbar)&&(e+=" svc-tab-designer--with-page-navigator"),this.showPlaceholder&&(e+=" svc-tab-designer--with-place-holder"),e+" svc-tab-designer--"+this.creator.pageEditMode+"-mode"},J([(0,o.property)()],t.prototype,"newPage",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showNewPage",void 0),J([(0,o.property)()],t.prototype,"pageCount",void 0),J([(0,o.property)()],t.prototype,"designerCss",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),t}(o.Base),Ao=function(){this.collapsed=!1},Oo=function(){function e(){var e=this;this.elementState={},this.pageState={},this.onQuestionAddedHandler=function(t,o){e.createElementState(o.question,e.isSuspended)},this.onPageAddedHandler=function(t,o){e.createElementState(o.page,e.isSuspended)},this.onPanelAddedHandler=function(t,o){e.createElementState(o.panel,e.isSuspended)},this._suspendCounter=0}return e.prototype.getStateMapForElement=function(e){return e&&e.isPage?this.pageState:this.elementState},e.prototype.initForSurvey=function(e){e.onQuestionAdded.add(this.onQuestionAddedHandler),e.onPageAdded.add(this.onPageAddedHandler),e.onPanelAdded.add(this.onPanelAddedHandler)},e.prototype.initForElement=function(e){if(e){var t=this.getStateMapForElement(e);e.registerFunctionOnPropertyValueChanged("name",(function(o){delete t[e.name],t[o]=new Ao}),"designerStateManager")}},e.prototype.getElementState=function(e){return this.createElementState(e,!0)},e.prototype.createElementState=function(e,t){var o=this.getStateMapForElement(e),i=e.name;if(t){var n=o[i];if(n)return n}var r=new Ao;return o[i]=r,this.onInitElementStateCallback&&this.onInitElementStateCallback(e,r),r},e.prototype.suspend=function(){this._suspendCounter++},e.prototype.release=function(){this._suspendCounter--},Object.defineProperty(e.prototype,"isSuspended",{get:function(){return this._suspendCounter>0},enumerable:!1,configurable:!0}),e}(),No=function(e){function t(t){var i=e.call(this)||this;return i.sidePanel=t,i.topToolbar=new o.ActionContainer,i.bottomToolbar=new o.ActionContainer,i.createToggleAction(),i.updateExpandCollapseAction(),i.sidePanel.registerFunctionOnPropertyValueChanged("_visible",(function(){i.updateExpandCollapseAction()})),i}return K(t,e),t.prototype.updateExpandCollapseAction=function(){this.expandCollapseAction.iconName=this.sidePanel.visible?"icon-collapse-panel":"icon-expand-panel",this.expandCollapseAction.css=this.sidePanel.visible?"svd-grid-hide":"svd-grid-expand",this.expandCollapseAction.locTitleName=this.sidePanel.visible?"ed.hidePanel":"ed.showPanel"},t.prototype.createToggleAction=function(){var e=this;this.expandCollapseAction=new kt({id:"svd-grid-hide",showTitle:!1,visible:!0,pressed:!1,action:function(){e.sidePanel.visible?e.sidePanel.collapseSidebar():e.sidePanel.expandSidebar()}})},Object.defineProperty(t.prototype,"sideBarClassName",{get:function(){return(new o.CssClassBuilder).append("svc-sidebar-tabs").append("svc-sidebar-tabs--collapsed",!this.sidePanel.renderedIsVisible).toString()},enumerable:!1,configurable:!0}),t}(o.Base),Lo={appearance:"icon-pg-v1/pg-appearance-24x24",background:"icon-pg-v1/pg-background-24x24",columns:"icon-pg-v1/pg-columns-24x24",logic:"icon-pg-v1/pg-conditions-24x24",data:"icon-pg-v1/pg-data-24x24",design:"icon-pg-v1/pg-design-24x24",general:"icon-pg-v1/pg-general-24x24",header:"icon-pg-v1/pg-header-24x24",language:"icon-pg-v1/pg-language-24x24",layout:"icon-pg-v1/pg-layout-24x24",logo:"icon-pg-v1/pg-logo-24x24",navigation:"icon-pg-v1/pg-navigation-24x24",pages:"icon-pg-v1/pg-pages-24x24",question:"icon-pg-v1/pg-questiondesign-24x24",timer:"icon-pg-v1/pg-quiz-24x24",rows:"icon-pg-v1/pg-rows-24x24",specific:"icon-pg-v1/pg-specific-24x24",showOnCompleted:"icon-pg-v1/pg-thankyyoupage-24x24",themes:"icon-pg-v1/pg-themes-24x24",totals:"icon-pg-v1/pg-totals-24x24",validation:"icon-pg-v1/pg-validation-24x24",undefined:"icon-pg-v1/pg-undefined-24x24"},_o=function(){function e(e){var t=this;this.creator=e,this._showOneCategoryInPropertyGrid=!1,e.addPluginTab("designer",this),this.tabControlModel=new No(this.creator.sidebar),this.propertyGrid=new st(e.survey,e,e.getPropertyGridDefinition()),this.propertyGridViewModel=new Po(this.propertyGrid,e),this.propertyGridTab=this.creator.sidebar.addPage("propertyGrid","svc-property-grid",this.propertyGridViewModel,(function(){var e=[];return t.propertyGridViewModel.prevSelectionAction&&(t.propertyGridViewModel.prevSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.prevSelectionAction)),t.propertyGridViewModel.nextSelectionAction&&(t.propertyGridViewModel.nextSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.nextSelectionAction)),t.propertyGridViewModel.objectSelectionAction&&(t.propertyGridViewModel.objectSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.objectSelectionAction)),e})),e.onSelectedElementChanged.add((function(e,o){t.showOneCategoryInPropertyGrid&&"designer"===t.creator.activeTab&&(t.setPropertyGridIsActivePage(),t.updateTabControlActions())})),this.toolboxTab=this.creator.sidebar.addPage("toolbox","svc-toolbox",e),this.propertyGridPlaceholderPage=this.creator.sidebar.addPage("propertyGridPlaceholder","svc-property-grid-placeholder",this.propertyGridViewModel),this.propertyGridPlaceholderPage.caption="Survey Settings",this.designerStateManager=new Oo,this.designerStateManager.initForSurvey(this.creator.survey),this.creator.onSurveyInstanceCreated.add((function(e,o){"designer"==o.reason&&t.designerStateManager.initForSurvey(o.survey)})),this.creator.onPropertyChanged.add((function(e,o){"toolboxLocation"===o.name&&(t.toolboxTab.visible&&"sidebar"!==o.newVal&&(t.propertyGridTab.visible=!0),t.toolboxTab.visible="sidebar"===o.newVal)})),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),e.registerShortcut("delete",{affectedTab:"designer",hotKey:{keyCode:46},macOsHotkey:{keyCode:46},execute:function(){return t.creator.deleteCurrentElement()}})}return Object.defineProperty(e.prototype,"isSurveySelected",{get:function(){return this.creator.isElementSelected(this.creator.survey)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSettingsActive",{get:function(){return this.creator.showSidebar&&this.isSurveySelected},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activePageIsPropertyGrid",{get:function(){return this.creator.sidebar.activePage===this.propertyGridTab.id},enumerable:!1,configurable:!0}),e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.sidebar.activePage;return"designer"===e.creator.activeTab&&t!==e.propertyGridPlaceholderPage.id}))},e.prototype.updateTabControl=function(){this.showOneCategoryInPropertyGrid?(this.updateTabControlActions(),this.creator.sidebar.sideAreaComponentName="svc-tab-control",this.creator.sidebar.sideAreaComponentData=this.tabControlModel):(this.creator.sidebar.sideAreaComponentName="",this.creator.sidebar.sideAreaComponentData=void 0)},e.prototype.updateHeaderComponent=function(){this.showOneCategoryInPropertyGrid&&this.activePageIsPropertyGrid?(this.creator.sidebar.header.componentName="svc-side-bar-property-grid-header",this.creator.sidebar.header.componentData=this.propertyGridViewModel.objectSelectionAction):this.showOneCategoryInPropertyGrid&&this.creator.sidebar.activePage===this.propertyGridPlaceholderPage.id?(this.creator.sidebar.header.componentName="svc-side-bar-header",this.creator.sidebar.header.componentData=this.creator.sidebar.header):(this.creator.sidebar.header.componentName="",this.creator.sidebar.header.componentData=void 0)},e.prototype.updateActivePage=function(){this.showOneCategoryInPropertyGrid?(this.creator.sidebar.activePage=this.creator.survey.pageCount?this.propertyGridTab.id:this.propertyGridPlaceholderPage.id,this.updateHeaderComponent()):this.setPropertyGridIsActivePage()},e.prototype.setPropertyGridIsActivePage=function(){this.creator.sidebar.activePage=this.propertyGridTab.id,this.updateHeaderComponent()},Object.defineProperty(e.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid!==e&&(this._showOneCategoryInPropertyGrid=e,this.creator.sidebar.hideSideBarVisibilityControlActions=e,this.propertyGrid.showOneCategoryInPropertyGrid=e,this.propertyGrid.setObj(this.creator.selectedElement),"designer"===this.creator.activeTab&&(this.updateActivePage(),this.updateTabControl()))},enumerable:!1,configurable:!0}),e.prototype.updateTabControlActions=function(){var e,t=this;if(this.showOneCategoryInPropertyGrid){var o=this.propertyGrid.survey.pages.map((function(e){var i=new kt({id:e.name,tooltip:e.title,iconName:Lo[e.name]||Lo[void 0],active:t.activePageIsPropertyGrid&&e.name===t.propertyGrid.survey.currentPage.name,pressed:!1,action:function(){t.creator.sidebar.expandSidebar(),t.setPropertyGridIsActivePage(),t.propertyGrid.survey.currentPage=e,t.propertyGridViewModel.objectSelectionAction.tooltip=e.title,o.forEach((function(e){return e.active=!1})),i.active=!0}});return i}));this.tabControlModel.topToolbar.setItems(o),this.propertyGrid.survey.onCurrentPageChanged.add((function(e,i){o.forEach((function(e){e.active=e.id===i.newCurrentPage.name})),t.propertyGridViewModel.objectSelectionAction.tooltip=i.newCurrentPage.title})),this.propertyGridViewModel.objectSelectionAction.tooltip=null===(e=this.propertyGrid.survey.currentPage)||void 0===e?void 0:e.title}},e.prototype.activate=function(){this.model=new Io(this.creator),this.creator.sidebar.hideSideBarVisibilityControlActions=this.showOneCategoryInPropertyGrid,this.updateActivePage(),this.updateTabControl(),this.creator.focusElement(void 0,!0)},e.prototype.deactivate=function(){return this.model&&this.model.dispose(),this.model=void 0,this.propertyGridTab.visible=!1,this.propertyGridPlaceholderPage.visible=!1,this.toolboxTab.visible=!1,this.creator.sidebar.hideSideBarVisibilityControlActions=!1,this.creator.sidebar.sideAreaComponentName=void 0,this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.reset(),!0},e.prototype.onDesignerSurveyPropertyChanged=function(e,t){this.model&&this.model.onDesignerSurveyPropertyChanged(e,t)},e.prototype.update=function(){this.model&&(this.updateActivePage(),this.model.initSurvey())},e.prototype.createActions=function(){var e=this,t=[],i=new o.Action({id:"svd-toolbox",iconName:"icon-toolbox",needSeparator:!0,action:function(){e.creator.showSidebar||e.creator.setShowSidebar(!0,!0),e.creator.sidebar.activePage="toolbox"},active:new o.ComputedUpdater((function(){return"toolbox"===e.creator.sidebar.activePage})),visible:new o.ComputedUpdater((function(){return I("designer"===e.creator.activeTab,e.creator.showToolbox,"sidebar"===e.creator.toolboxLocation)})),title:"Toolbox",showTitle:!1});return this.surveySettingsAction=new o.Action({id:"svd-settings",iconName:"icon-settings",needSeparator:new o.ComputedUpdater((function(){return I("sidebar"!==e.creator.toolboxLocation,!e.creator.isMobileView)})),action:function(){e.selectSurvey(),e.creator.isMobileView||e.creator.sidebar.executeOnExpand((function(){e.creator.propertyGrid.getAllQuestions()[0].focus()}))},active:this.isSettingsActive,pressed:this.isSettingsActive,visible:this.createVisibleUpdater(),locTitleName:"ed.surveySettings",locTooltipName:"ed.surveySettingsTooltip",showTitle:!1}),this.saveSurveyAction=new o.Action({id:"svd-save",iconName:"icon-save",action:function(){return e.creator.saveSurveyActionHandler()},active:!1,enabled:!1,visible:new o.ComputedUpdater((function(){return I("designer"===e.creator.activeTab,e.creator.showSaveButton)})),locTitleName:"ed.saveSurvey",locTooltipName:"ed.saveSurveyTooltip",showTitle:!1}),this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",visible:this.createVisibleUpdater(),active:!0,locTitleName:"ed.designer",showTitle:!1,action:function(){}}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",action:function(){e.creator.makeNewViewActive(e.creator.showThemeTab?"theme":"test")},visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1}),t.push(this.saveSurveyAction),t.push(i),t.push(this.surveySettingsAction),this.creator.onSelectedElementChanged.add((function(t,o){e.surveySettingsAction.active=e.isSettingsActive,e.surveySettingsAction.pressed=e.isSettingsActive})),this.creator.onShowSidebarVisibilityChanged.add((function(t,o){e.surveySettingsAction.active=e.isSettingsActive,e.surveySettingsAction.pressed=e.isSettingsActive})),t},e.prototype.selectSurvey=function(){this.creator.showSidebar||this.creator.setShowSidebar(!0,!0),this.creator.selectElement(this.creator.survey),this.setPropertyGridIsActivePage()},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.surveySettingsAction)},e}();n(9118);var Mo=function(){function e(e,t){var o=this;this.container=e,this.creator=t,this.resizeObserver=void 0,"undefined"!=typeof ResizeObserver&&(this.resizeObserver=new ResizeObserver((function(e){return o.process()})),this.resizeObserver.observe(this.findCorrectParent(this.container)),this.process(!0),"xs"!=this.currentWidth&&"s"!=this.currentWidth&&"m"!==this.currentWidth||this.creator.setShowSidebar(!1))}return e.prototype.getScreenWidth=function(){var t,o=this;return Object.keys(e.screenSizeBreakpoints).forEach((function(i){var n=e.screenSizeBreakpoints[i];!t&&o.container&&n&&o.container.offsetWidth>=n&&(t=i)})),t||"xs"},e.prototype.initMobileView=function(){this.creator.showTabs=!1,this.creator.showToolbar=!1,this.creator.isMobileView=!0},e.prototype.resetMobileView=function(){this.creator.showTabs=void 0,this.creator.showToolbar=void 0,this.creator.isMobileView=void 0},e.prototype.procesShowToolbox=function(e){this.creator.allowShowToolbox=e},e.prototype.procesShowPageNavigator=function(e){this.creator.allowShowPageNavigator="bypage"===this.creator.pageEditMode||e},e.prototype.findCorrectParent=function(e){return(null===window||void 0===window?void 0:window.getComputedStyle)&&"inline"===window.getComputedStyle(e.parentElement).display?this.findCorrectParent(e.parentElement):e.parentElement},e.prototype._process=function(e,t,o){this.creator.updateToolboxIsCompact(e),this.procesShowToolbox(t),this.procesShowPageNavigator(t),this.creator.sidebar.visible&&!o&&(this.creator.sidebar.collapsedManually=!1),this.creator.sidebar.visible&&!this.creator.sidebar.expandedManually&&o&&"right"!=this.creator.toolboxLocation&&this.creator.sidebar.collapseSidebar(),this.creator.sidebar.visible||this.creator.sidebar.collapsedManually||o||"right"==this.creator.toolboxLocation||this.creator.sidebar.expandSidebar(),this.creator.sidebar.flyoutMode=o},e.prototype.process=function(e){void 0===e&&(e=!1),e&&this.creator.sidebar.blockAnimations(),this.currentWidth=this.getScreenWidth(),"xl"===this.currentWidth||"xxl"===this.currentWidth?this._process(!1,!0,!1):"l"===this.currentWidth?this._process(!0,!0,!1):"m"===this.currentWidth?this._process(!0,!0,!0):this._process(!0,!1,!0),"xs"==this.currentWidth?this.initMobileView():this.resetMobileView(),e&&this.creator.sidebar.releaseAnimations()},e.prototype.dispose=function(){this.creator.allowShowToolbox=!0,this.creator.allowShowPageNavigator=!0,this.resizeObserver&&this.resizeObserver.disconnect()},e.screenSizeBreakpoints={xxl:1800,xl:1500,l:1200,m:900,s:600},e}(),Do=function(e){function t(t,o,i,n){var r=e.call(this)||this;return r.id=t,r.sidePanel=o,i&&(r.componentName=i),n&&(r.componentData=n),r}return K(t,e),J([(0,o.property)()],t.prototype,"caption",void 0),J([(0,o.property)({onSet:function(e,t){t.sidePanel.updateHasVisiblePages()}})],t.prototype,"visible",void 0),J([(0,o.property)()],t.prototype,"componentData",void 0),J([(0,o.property)()],t.prototype,"componentName",void 0),t}(o.Base),ko=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.toolbar=new o.AdaptiveActionContainer,t}return K(t,e),Object.defineProperty(t.prototype,"component",{get:function(){return this.componentName||"svc-side-bar-default-header"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"componentModel",{get:function(){return this.componentData||this},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.title="",this.subTitle="",this.componentName="",this.componentData=void 0},J([(0,o.property)()],t.prototype,"title",void 0),J([(0,o.property)()],t.prototype,"subTitle",void 0),J([(0,o.property)()],t.prototype,"componentData",void 0),J([(0,o.property)()],t.prototype,"componentName",void 0),t}(o.Base),jo=function(){function e(e,t){var o=this;this.container=e,this.events={mousedown:{touch:"touchend",mouse:"mousedown",pointer:"pointerdown"},mouseup:{touch:"touchstart",mouse:"mouseup",pointer:"pointerup"},mousemove:{touch:"touchmove",mouse:"mousemove",pointer:"pointermove"}},this.onMouseDownListener=function(e){window&&(e.preventDefault(),o.originalWidth=o.getStyleValue(o.container,"width"),o.originalMouseX=e.pageX,o.currentResizer=e.target,window.addEventListener(o.getMouseEvent("mousemove"),o.resize),window.addEventListener(o.getMouseEvent("mouseup"),o.stopResize))},this.resize=function(e){var t=o.originalWidth,i=e.pageX-o.originalMouseX;o.currentResizer==o.westResizer?t-=i:t+=i,t>o.maxWidth?t=o.maxWidth:t<o.minWidth&&(t=o.minWidth),o.container.style.width=t+"px"},this.stopResize=function(e){window&&(window.removeEventListener(o.getMouseEvent("mousemove"),o.resize),window.removeEventListener(o.getMouseEvent("mouseup"),o.stopResize))},this.init(e),this.setHandles(t)}return e.prototype.setHandles=function(e){var t=!1,o=!1,i=e.split(",");i.forEach((function(e){return e.trim()})),((i=i.filter((function(e){return!!e})))||[]).forEach((function(e){"w"==e&&(t=!0),"e"==e&&(o=!0)})),this.westResizer.style.display=t?"block":"none",this.eastResizer.style.display=o?"block":"none"},e.prototype.getStyleValue=function(e,t){return window?parseFloat(window.getComputedStyle(e).getPropertyValue(t).replace("px","")):0},e.prototype.isEventSupported=function(e){var t=document.createElement("div"),o=(e="on"+e)in t;return o||(t.setAttribute(e,"return;"),o="function"==typeof t[e]),t=null,o},e.prototype.getEventPrefix=function(){return void 0===this.mouseDevice&&(this.isEventSupported("pointerdown")?this.mouseDevice="pointer":this.isEventSupported("touchstart")?this.mouseDevice="touch":this.isEventSupported("mousedown")&&(this.mouseDevice="mouse")),this.mouseDevice},e.prototype.getMouseEvent=function(e){return this.events[e][this.getEventPrefix()]},e.prototype.init=function(e){this.westResizer=this.createrResizerElement("svc-resizer svc-resizer-west"),this.eastResizer=this.createrResizerElement("svc-resizer svc-resizer-east"),this.minWidth=this.getStyleValue(e,"min-width"),this.maxWidth=this.getStyleValue(e,"max-width"),e.insertBefore(this.westResizer,e.children[0]),e.appendChild(this.eastResizer)},e.prototype.createrResizerElement=function(e){var t=document.createElement("div");return t.className=e,t.addEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),t},e.prototype.dispose=function(){this.eastResizer.removeEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),this.eastResizer.remove(),this.eastResizer=void 0,this.westResizer.removeEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),this.westResizer.remove(),this.westResizer=void 0},e}(),Ro=function(e){function t(t){var i=e.call(this)||this;return i.creator=t,i.header=new ko,i.allowFlyoutMode=!0,i.visibilityAnimation=new o.AnimationBoolean(i.getAnimationOptions(),(function(e){i.renderedIsVisible=e,i.allowFlyoutMode=!0}),(function(){return i.renderedIsVisible})),i.sidebarLocationChangedHandler=function(e,t){"sidebarLocation"===t.name&&i.resizeManager&&i.resizeManager.setHandles(i.getCurrentHandles())},i.onSidebarVisibilityChanged=function(e,t){i.isDisposed||(i.visible=t.show)},i.creator.onShowSidebarVisibilityChanged.add(i.onSidebarVisibilityChanged),i.creator.onPropertyChanged.add(i.sidebarLocationChangedHandler),i.visible=i.creator.showSidebar,i.createActions(),i}return K(t,e),Object.defineProperty(t.prototype,"rootCss",{get:function(){return(new o.CssClassBuilder).append("svc-side-bar").append("svc-side-bar--flyout",this.flyoutPanelMode).append("svc-side-bar--mobile",this.creator.isMobileView).append("svc-side-bar--side-area",!!this.sideAreaComponentName).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderRoot",{get:function(){return this.hasVisiblePages&&(!this.creator.isMobileView||this.renderedIsVisible)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderContainer",{get:function(){return this.renderedIsVisible},enumerable:!1,configurable:!0}),t.prototype.getAnimationOptions=function(){var e=this,t=function(e){e.querySelectorAll(".svc-side-bar__container-wrapper,.svc-side-bar__wrapper").forEach((function(e){e.style.setProperty("--animation-width",e.offsetWidth+"px")}))};return{getAnimatedElement:function(){return e.rootElement},isAnimationEnabled:function(){return e.animationAllowed},getRerenderEvent:function(){return e.onElementRerendered},getLeaveOptions:function(){return{onBeforeRunAnimation:t,cssClass:"svc-side-bar--leave"}},getEnterOptions:function(){return{onBeforeRunAnimation:t,cssClass:"svc-side-bar--enter",onAfterRunAnimation:function(){return e.afterExpand()}}}}},t.prototype.afterExpand=function(){this.onExpandCallback&&this.onExpandCallback(),this.onExpandCallback=void 0},t.prototype.executeOnExpand=function(e){this.renderedIsVisible&&e(),this.onExpandCallback=e},Object.defineProperty(t.prototype,"visible",{get:function(){return this._visible},set:function(e){!this._visible||e||this.flyoutMode||(this.allowFlyoutMode=!1),this._visible!==e&&(this._visible=e,this.animationAllowed||this.afterExpand(),this.visibilityAnimation.sync(e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"flyoutPanelMode",{get:function(){return this.flyoutMode&&this.allowFlyoutMode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"closeText",{get:function(){return Z("pe.close")},enumerable:!1,configurable:!0}),t.prototype.getPageById=function(e){return this.pages.filter((function(t){return t.id===e}))[0]},t.prototype.createActions=function(){var e=this;this._collapseAction=new o.Action({id:"svd-grid-hide",iconName:"icon-collapse-panel",css:"svd-grid-hide",locTitleName:"ed.hidePanel",showTitle:!1,visible:new o.ComputedUpdater((function(){return I(!I(!e.creator.allowCollapseSidebar,!e.flyoutMode),e.visible,!e.hideSideBarVisibilityControlActions)})),action:function(){e.collapseSidebar(),e.flyoutMode?e.creator.focusElement(e.creator.selectedElement,!0):(e.collapsedManually=!0,e.expandedManually=!1)}}),this.header.toolbar.actions.push(this._collapseAction),this.creator.allowCollapseSidebar&&(this._expandAction=new o.Action({id:"svd-grid-expand",iconName:"icon-expand-panel",css:"svd-grid-expand",needSeparator:!0,action:function(){e.expandSidebar(),e.flyoutMode||(e.collapsedManually=!1,e.expandedManually=e.flyoutMode)},locTitleName:"ed.showPanel",visible:new o.ComputedUpdater((function(){return I(e.hasVisiblePages,!e.visible,!e.hideSideBarVisibilityControlActions)})),showTitle:!1}))},t.prototype.getCurrentHandles=function(){return"right"==this.creator.sidebarLocation?"w":"e"},t.prototype.getActivePage=function(){return this._activePage},t.prototype.setActivePage=function(e){this.pages.forEach((function(e){return e.visible=!1})),this._activePage=e,this._activePage&&(this.header.title=this._activePage.caption,this._activePage.visible=!0)},t.prototype.getExpandAction=function(){return this._expandAction},t.prototype.collapseSidebar=function(){this.creator.setShowSidebar(!1)},t.prototype.expandSidebar=function(){this.creator.setShowSidebar(!0)},t.prototype.addPage=function(e,t,o,i){var n=this,r=new Do(e,this,t,o);return this.pages.push(r),i&&(i()||[]).forEach((function(e){return n.header.toolbar.actions.push(e)})),r},t.prototype.updateHasVisiblePages=function(){this.hasVisiblePages=(this.pages||[]).filter((function(e){return e.visible})).length>0},t.prototype.dispose=function(){this.creator&&!this.isDisposed&&(this.creator.onShowSidebarVisibilityChanged.remove(this.onSidebarVisibilityChanged),this.creator.onPropertyChanged.remove(this.sidebarLocationChangedHandler),this.sidebarLocationChangedHandler=void 0),this.resetResizeManager(),e.prototype.dispose.call(this)},t.prototype.initResizeManager=function(e){var t;this.resizeManager=new jo(e,this.getCurrentHandles()),this.rootElement=null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement.parentElement},t.prototype.resetResizeManager=function(){this.resizeManager&&(this.resizeManager.dispose(),this.resizeManager=void 0),this.rootElement=void 0},J([(0,o.propertyArray)()],t.prototype,"pages",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"_visible",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"renderedIsVisible",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"collapsedManually",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"expandedManually",void 0),J([(0,o.property)()],t.prototype,"hasVisiblePages",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"flyoutMode",void 0),J([(0,o.property)({onSet:function(e,t){t.setActivePage(t.pages.filter((function(t){return t.id===e}))[0])}})],t.prototype,"activePage",void 0),J([(0,o.property)()],t.prototype,"hideSideBarVisibilityControlActions",void 0),J([(0,o.property)()],t.prototype,"sideAreaComponentName",void 0),J([(0,o.property)()],t.prototype,"sideAreaComponentData",void 0),J([(0,o.property)({})],t.prototype,"allowFlyoutMode",void 0),t}(o.Base),Bo=function(){function e(e){this.question=e}return e.createItemsNavigator=function(e){return e instanceof o.QuestionImagePickerModel?null:e instanceof o.QuestionMultipleTextModel?new Ho(e):e instanceof o.QuestionMatrixDropdownModel?new Fo(e):e instanceof o.QuestionMatrixDynamicModel?new Uo(e):e instanceof o.QuestionMatrixModel?new Qo(e):e instanceof o.QuestionSelectBase?new qo(e):null},e.prototype.addNewItems=function(e,t,i,n){var r=this,a=t.slice();a.splice(i,1),n.forEach((function(t,n){var s,l;a.splice(i+n,0,(s=t,l=e.inplaceEditForValues?s:c(e.getChoicesItemBaseTitle(),a),r.question.createItemValue?r.question.createItemValue(l,s):new o.ItemValue(l,s)))})),this.question[this.getItemsPropertyName(t)]=a},e.prototype.setEventsForItem=function(e,t,o){var i=this,n=Go.get(this.getItemLocString(t,o));n.allowLineBreaksOnEdit=!0,n.onEditComplete.clear(),n.onEditComplete.add((function(){var n=t.indexOf(o);n>=0&&n<t.length-1&&Go.get(i.getItemLocString(t,t[n+1])).activateEditor(),n==t.length-1&&(i.addNewItem(e,t),Go.get(i.getItemLocString(t,t[t.length-1])).setAutoFocus(),Go.get(i.getItemLocString(t,t[t.length-1])).activateEditor())})),n.onBackspaceEmptyString.clear(),n.onBackspaceEmptyString.add((function(){var e=t.indexOf(o),n=null;if(-1!==e){if(0==e&&t.length>=2&&(n=t[1]),e>0&&(n=t[e-1]),n){var r=Go.get(i.getItemLocString(t,n));r.setAutoFocus(),r.activateEditor()}t.splice(e,1)}})),n.onTextChanging.clear(),n.onTextChanging.add((function(n,r){var a=r.value.split(/\r?\n/).map((function(e){return(e||"").trim()})).filter((function(e){return!!e}));if(!(a.length<=1)){r.cancel=!0;var s=t.indexOf(o);i.addNewItems(e,t,s,a);var l=s+a.length;l>=t.length&&(l=t.length-1),Go.get(i.getItemLocString(t,t[l])).setAutoFocus(),Go.get(i.getItemLocString(t,t[l])).activateEditor()}}))},e.setQuestion=function(t){var o=t.element,i=e.createItemsNavigator(o);if(i){var n=t.creator,r=Go.get(o.locTitle),a=i.getItemSets(),s=a[0];r.hasEditCompleteHandler||(r.onEditComplete.add((function(){s.length&&Go.get(i.getItemLocString(s,s[0])).activateEditor()})),r.hasEditCompleteHandler=!0),a.forEach((function(e){e.forEach((function(t){i.setEventsForItem(n,e,t)}));var t=i.getItemsPropertyName(e);o.onPropertyChanged.add((function(o,r){r.name==t&&e.forEach((function(t){i.setEventsForItem(n,e,t)}))}))}))}return!!i},e}(),qo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locText},t.prototype.getItemSets=function(){return[this.question.choices]},t.prototype.addNewItem=function(e,t,o){if(void 0===o&&(o=null),!(e.maximumChoicesCount&&t.length>=e.maximumChoicesCount)){var i=e.createNewItemValue(this.question);o&&(i.value=o)}},t.prototype.getItemsPropertyName=function(e){return"choices"},t}(Bo),Ho=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locTitle},t.prototype.getItemSets=function(){return[this.question.items]},t.prototype.addNewItem=function(e,t,o){void 0===o&&(o=null),this.question.addItem(o||h("text",t.map((function(e){return e.name}))))},t.prototype.getItemsPropertyName=function(e){return"items"},t.prototype.addNewItems=function(e,t,i,n){var r=t.slice(0,i).concat(n.map((function(e){return new o.MultipleTextItemModel(e)}))).concat(t.slice(i+1));this.question[this.getItemsPropertyName(t)]=r},t}(Bo),Qo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locText},t.prototype.getItemSets=function(){return[this.question.columns,this.question.rows]},t.prototype.addNewItem=function(e,t,i){var n,r;if(void 0===i&&(i=null),t==this.question.columns){if(e.maximumColumnsCount&&t.length>=e.maximumColumnsCount)return;n="Column ",r="columns"}if(t==this.question.rows){if(e.maximumRowsCount&&t.length>=e.maximumRowsCount)return;n="Row ",r="rows"}var a=new o.ItemValue(h(n,t.map((function(e){return e.value}))));t.push(i||a),e.onItemValueAddedCallback(this.question,r,a,t)},t.prototype.getItemsPropertyName=function(e){return e==this.question.columns?"columns":e==this.question.rows?"rows":void 0},t}(Bo),Fo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return e==this.question.columns?t.locTitle:t.locText},t.prototype.addNewItem=function(t,i,n){if(void 0===n&&(n=null),i==this.question.columns){if(t.maximumColumnsCount&&i.length>=t.maximumColumnsCount)return;var r=new o.MatrixDropdownColumn(n||h("Column ",i.map((function(e){return e.value}))));this.question.columns.push(r),t.onMatrixDropdownColumnAddedCallback(this.question,r,this.question.columns)}i==this.question.rows&&e.prototype.addNewItem.call(this,t,i,n)},t.prototype.addNewItems=function(t,i,n,r){if(i==this.question.columns){var a=i.slice(0,n).concat(r.map((function(e){return new o.MatrixDropdownColumn(e)}))).concat(i.slice(n+1));this.question[this.getItemsPropertyName(i)]=a}else e.prototype.addNewItems.call(this,t,i,n,r)},t}(Qo),Uo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemSets=function(){return[this.question.columns]},t}(Fo),Go=function(){function e(e){this.locString=e,this.hasEditCompleteHandler=!1,this.allowLineBreaksOnEdit=!1,this.onDoActivate=new o.EventBase,this.onTextChanging=new o.EventBase,this.onEditComplete=new o.EventBase,this.onBackspaceEmptyString=new o.EventBase}return e.get=function(t){return t._stringEditorConnector||(t._stringEditorConnector=new e(t)),t._stringEditorConnector},e.prototype.setAutoFocus=function(){this.focusOnEditor=!0},e.prototype.activateEditor=function(){this.onDoActivate.fire(this.locString,{})},e}(),Zo=function(e){function t(t,i){var n=e.call(this)||this;return n.locString=t,n.creator=i,n.blurredByEscape=!1,n.focusedProgram=!1,n.characterCounter=new o.CharacterCounter,n.activate=function(){var e=n.getEditorElement();return!(!e||null==e.offsetParent||(e.focus({preventScroll:!0}),x(e),0))},n.justFocused=!1,n.locString=t,n.checkMarkdownToTextConversion(n.locString.owner,n.locString.name),n}return K(t,e),t.prototype.afterRender=function(){this.connector.focusOnEditor&&this.activate()&&(this.connector.focusOnEditor=!1)},t.prototype.detachFromUI=function(){var e;null===(e=this.connector)||void 0===e||e.onDoActivate.remove(this.activate),this.getEditorElement=void 0,this.blurEditor=void 0},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.detachFromUI()},t.prototype.setLocString=function(e){var t;null===(t=this.connector)||void 0===t||t.onDoActivate.remove(this.activate),this.locString=e,this.connector=Go.get(e),this.connector.onDoActivate.add(this.activate)},t.prototype.checkConstraints=function(e){!this.compostionInProgress&&this.maxLength>0&&e.keyCode>=32&&(e.target.innerText||"").length>=this.maxLength&&e.preventDefault(),13!=e.keyCode||this.locString.allowLineBreaks||e.preventDefault(),(e.ctrlKey||e.metaKey)&&-1!==[89,90,66,73].indexOf(e.keyCode)&&(e.stopImmediatePropagation(),e.preventDefault())},t.prototype.onClick=function(e){e.stopPropagation()},t.prototype.onFocus=function(e){this.focusedProgram||(this.valueBeforeEdit=this.locString.hasHtml?e.target.innerHTML:e.target.innerText,this.focusedProgram=!1),this.maxLength>0&&this.characterCounter.updateRemainingCharacterCounter(this.valueBeforeEdit,this.maxLength),this.creator&&(this.creator.selectFromStringEditor=!0),this.locString.hasHtml&&this.editAsText&&(e.target.innerText=e.target.textContent=this.locString.calculatedText),e.target.parentElement.click(),e.target.spellcheck=!0,e.target.setAttribute("tabindex",-1),this.focused=!0,this.justFocused=!0},t.prototype.checkMarkdownToTextConversion=function(e,t){if(this.creator){var o={element:e,text:null,name:t,html:""};this.creator.onHtmlToMarkdown.fire(this.creator,o),this.editAsText=null===o.text}},t.prototype.onCompositionStart=function(e){this.compostionInProgress=!0},t.prototype.onInput=function(e){var t;if(this.maxLength>0){var o=e.target.innerText||"";this.characterCounter.updateRemainingCharacterCounter(o,this.maxLength)}if(this.editAsText&&!this.compostionInProgress){var i={value:null===(t=e.target)||void 0===t?void 0:t.innerText,cancel:null};if(this.connector&&this.connector.onTextChanging.fire(this,i),i.cancel)return;this.maxLength>=0&&e.target.innerText.length>this.maxLength&&(e.target.innerText=e.target.innerText.substring(0,this.maxLength))}},t.prototype.onCompositionEnd=function(e){this.compostionInProgress=!1,this.onInput(e)},t.prototype.onBlur=function(e){var t;if(e.target.removeAttribute("tabindex"),this.blurredByEscape)return this.blurredByEscape=!1,this.locString.hasHtml?e.target.innerHTML=this.valueBeforeEdit:e.target.innerText=this.valueBeforeEdit,this.errorText=null,this.focused=!1,void(null===window||void 0===window||window.getSelection().removeAllRanges());var o=this.getClearedText(e.target);if(this.errorText=this.getErrorTextOnChanged(o),this.locString.text==o||!this.locString.text&&o==this.locString.calculatedText)this.locString.hasHtml?e.target.innerHTML=this.locString.renderedHtml:e.target.innerText=this.locString.renderedHtml,this.locString.strChanged();else{if(this.errorText)return null===(t=this.creator)||void 0===t||t.notify(this.errorText,"error"),this.focusedProgram=!0,e.target.innerText=o,void e.target.focus();this.setValueIntoLocStr(o,null==e?void 0:e.target)}this.focused=!1,null===window||void 0===window||window.getSelection().removeAllRanges()},t.prototype.getClearedText=function(e){var t=e.innerHTML,o=e.innerText;if(!this.creator)return this.locString.hasHtml?t:o;var i,n=null;if(!this.editAsText){var r={element:this.locString.owner,text:null,name:this.locString.name,html:t};this.creator.onHtmlToMarkdown.fire(this.creator,r),n=r.text}if(n)i=n;else{var a=this.locString.hasHtml&&!this.editAsText?t:o;this.locString.allowLineBreaks||(a=w(a)),i=a}var s={obj:this.locString.owner,propertyName:this.locString.name,value:this.locString.text,newValue:i,doValidation:!1};return this.creator.onValueChangingCallback(s),s.newValue},t.prototype.getErrorTextOnChanged=function(e){if(!this.creator)return"";var t=this.locString.owner,o=this.creator.onGetErrorTextOnValidationCallback(this.locString.name,t,e);if(o||e)return o;var i=t.getPropertyByName&&t.getPropertyByName(this.locString.name);return i&&i.isRequired?G.getString("pe.propertyIsEmpty"):""},Object.defineProperty(t.prototype,"isInplaceForEditValues",{get:function(){return!!this.creator&&this.creator.inplaceEditForValues&&this.locString.owner instanceof o.ItemValue&&this.creator.inplaceEditForValues&&-1===["noneText","otherText","selectAllText"].indexOf(this.locString.name)},enumerable:!1,configurable:!0}),t.prototype.setValueIntoLocStr=function(e,t){if(this.isInplaceForEditValues){var i=this.locString.owner;if(i.value!==e){if(i.locOwner&&i.ownerPropertyName){var n=i.locOwner[i.ownerPropertyName];Array.isArray(n)&&o.ItemValue.getItemByValue(n,e)&&(e=c(e,n),t&&(t.innerText=e))}i.value=e}}else{var r=this.locString.storeDefaultText;this.locString.storeDefaultText=!1,this.locString.text=e,this.locString.storeDefaultText=r}},t.prototype.done=function(e){e.stopImmediatePropagation(),e.preventDefault()},t.prototype.onPaste=function(e){var t;if(this.editAsText){e.preventDefault();var o=e.clipboardData.getData("text/plain");this.locString.allowLineBreaks||(null===(t=this.connector)||void 0===t?void 0:t.allowLineBreaksOnEdit)||(o=w(o));var i=window.getSelection();if(!i.rangeCount)return;i.deleteFromDocument(),i.getRangeAt(0).insertNode(document.createTextNode(o)),i.collapseToEnd(),e.target.dispatchEvent(new Event("input",{bubbles:!0}))}},t.prototype.onKeyDown=function(e){return 13!==e.keyCode||e.shiftKey||(this.blurEditor(),e.ctrlKey||e.metaKey||this.connector.onEditComplete.fire(this,{}),this.done(e)),27===e.keyCode&&(this.blurredByEscape=!0,this.blurEditor(),this.done(e)),8!==e.keyCode||e.target.innerText||(this.done(e),this.connector.onBackspaceEmptyString.fire(this,{})),this.checkConstraints(e),!0},t.prototype.onKeyUp=function(e){return 9===e.keyCode&&e.target===document.activeElement&&x(e.target),!0},t.prototype.onMouseUp=function(e){return!this.justFocused||(this.justFocused=!1,!!window&&((window.getSelection().focusNode&&window.getSelection().focusNode.parentElement!==e.target||0==window.getSelection().toString().length)&&x(e.target),!1))},t.prototype.findProperty=function(){if(this.locString.owner.getType){var e=this.locString.owner.getType();if(this.locString.name)return o.Serializer.findProperty(e,this.locString.name)}},Object.defineProperty(t.prototype,"maxLength",{get:function(){var e=this.findProperty();return!e||e.maxLength<=0?-1:e.maxLength},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){var e=this;if(this.placeholderValue)return this.placeholderValue;var t=this.findProperty();if(!t||!t.placeholder)return"";var i=G.getString(t.placeholder);if(i){var n=/\{([^}]+)\}/g;this.placeholderValue=new o.ComputedUpdater((function(){for(var t=i,o=n.exec(t);null!=o;)t=t.replace(n,(function(t){return""+(e.locString.owner&&e.locString.owner[o[1]])})),o=n.exec(t);return t}))}return this.placeholderValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"contentEditable",{get:function(){return!this.creator||this.creator.isCanModifyProperty(this.locString.owner,this.locString.name)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showCharacterCounter",{get:function(){return-1!==this.maxLength},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"getCharacterCounterClass",{get:function(){return"svc-remaining-character-counter"},enumerable:!1,configurable:!0}),t.prototype.className=function(e){return(new o.CssClassBuilder).append("svc-string-editor").append("svc-string-editor--hidden",""==e&&""==this.placeholder).append("svc-string-editor--readonly",!this.contentEditable).append("svc-string-editor--error",!!this.errorText).append("svc-string-editor--multiline",!!this.locString.allowLineBreaks).toString()},J([(0,o.property)()],t.prototype,"errorText",void 0),J([(0,o.property)()],t.prototype,"focused",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"editAsText",void 0),J([(0,o.property)()],t.prototype,"placeholderValue",void 0),t}(o.Base);n(4340);var zo=function(e){function t(t,o){return e.call(this,t,o)||this}return K(t,e),Object.defineProperty(t.prototype,"currentTheme",{get:function(){return this.surveyProvider.theme},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentThemeCssVariables",{get:function(){return this.currentTheme.cssVariables||{}},enumerable:!1,configurable:!0}),t.prototype.getTabName=function(){return"theme"},t}(Ae),Jo={},Wo=["default","sharp","borderless","flat","plain","doubleborder","layered","solid","threedimensional","contrast"],Ko={light:{teal:"rgba(11, 128, 128, 1)",blue:"rgba(39, 114, 203, 1)",purple:"rgba(122, 70, 187, 1)",orchid:"rgba(178, 61, 153, 1)",tulip:"rgba(191, 76, 97, 1)",brown:"rgba(177, 94, 47, 1)",green:"rgba(11, 134, 75, 1)"},dark:{teal:"rgba(22, 198, 187, 1)",blue:"rgba(109, 183, 252, 1)",purple:"rgba(173, 144, 255, 1)",orchid:"rgba(232, 113, 220, 1)",tulip:"rgba(245, 131, 151, 1)",brown:"rgba(252, 187, 89, 1)",green:"rgba(140, 204, 90, 1)"}},Yo=["Open Sans","Arial, sans-serif","Brush Script MT, cursive","Courier New, monospace","Garamond, serif","Georgia, serif","Tahoma, sans-serif","Times New Roman, serif","Trebuchet MS, sans-serif","Verdana, sans-serif"];function Xo(){return[{type:"dropdown",name:"family",title:Z("theme.fontFamily"),titleLocation:"left",descriptionLocation:"hidden",choices:[].concat(Yo),allowClear:!1},{type:"buttongroup",name:"weight",titleLocation:"hidden",descriptionLocation:"hidden",choices:[{value:"400",text:Z("theme.fontWeightRegular")},{value:"600",text:Z("theme.fontWeightSemiBold")},{value:"700",text:Z("theme.fontWeightBold")},{value:"800",text:Z("theme.fontWeightHeavy")}]},{type:"coloralpha",name:"color",colorTitle:Z("theme.color"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"coloralpha",name:"placeholdercolor",colorTitle:Z("theme.placeholderColor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"spinedit",name:"size",title:Z("theme.size"),titleLocation:"left",descriptionLocation:"hidden",unit:"px",min:0}]}function $o(e,t,o){var i=e.contentPanel.questions[2];"allowEmptyColorValue"==t&&(i.allowEmptyValue=o)}function ei(){o.ComponentCollection.Instance.getCustomQuestionByName("font").json.elementsJSON=Xo()}function ti(e,t,o){void 0===e&&(e={}),Object.keys(e).forEach((function(i){var n="--sjs-font-".concat(t.name.toLocaleLowerCase(),"-").concat(i);t.defaultValue&&e[i]===t.defaultValue[i]?o[n]=void 0:o[n]=e[i]+("size"===i?"px":"")}))}function oi(e,t,o,i){if(e){e.defaultValue||(e.defaultValue={}),q(e.defaultValue,{color:t[o],placeholdercolor:i?t[i]:void 0}),e.defaultValue.size||(e.defaultValue.size=parseFloat(t["--sjs-font-size"]));var n=W({},e.defaultValue);return Object.keys(t).filter((function(t){return-1!==t.indexOf(e.name.toLocaleLowerCase())})).forEach((function(e){var o=e.split("-").pop();"size"===o&&void 0!==t[e]?n[o]=parseFloat(t[e].toString()):n[o]=t[e]})),n}}function ii(){return[{type:"coloralpha",name:"backcolor",colorTitle:Z("theme.backcolor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"coloralpha",name:"hovercolor",colorTitle:Z("theme.hovercolor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"spinedit",name:"cornerRadius",title:Z("theme.cornerRadius"),titleLocation:"left",descriptionLocation:"hidden",unit:"px",min:0}]}function ni(){o.ComponentCollection.Instance.getCustomQuestionByName("backgroundcornerradius").json.elementsJSON=ii()}function ri(e,t,o){void 0===e&&(e={}),Object.keys(e).forEach((function(i){var n="--sjs-".concat(t.name.toLocaleLowerCase(),"-").concat(i);t.defaultValue&&e[i]===t.defaultValue[i]?o[n]=void 0:o[n]=e[i]+("cornerRadius"===i?"px":"")}))}function ai(e,t,o,i,n){if(void 0===n&&(n=4),e){e.defaultValue||(e.defaultValue={}),q(e.defaultValue,{backcolor:t[o],hovercolor:t[i],cornerRadius:n});var r=W({},e.defaultValue);return Object.keys(t).filter((function(t){return-1!==t.indexOf(e.name.toLocaleLowerCase())})).forEach((function(e){var o=e.split("-").pop();"cornerRadius"===o&&void 0!==t[e]?r[o]=parseFloat(t[e].toString()):r[o]=t[e]})),r}}function si(){return{type:"paneldynamic",minPanelCount:1,panelAddText:Z("theme.boxShadowAddRule"),templateElements:[{type:"spinedit",name:"x",unit:"px",title:Z("theme.boxShadowX"),titleLocation:"left"},{type:"spinedit",name:"y",unit:"px",startWithNewLine:!1,title:Z("theme.boxShadowY"),titleLocation:"left"},{type:"spinedit",name:"blur",unit:"px",title:Z("theme.boxShadowBlur"),min:0,titleLocation:"left"},{type:"spinedit",name:"spread",unit:"px",min:0,startWithNewLine:!1,title:Z("theme.boxShadowSpread"),titleLocation:"left"},{type:"coloralpha",name:"color",titleLocation:"hidden"},{type:"buttongroup",name:"isInset",titleLocation:"hidden",choices:[{text:Z("theme.boxShadowDrop"),value:!1},{text:Z("theme.boxShadowInner"),value:!0}]}]}}function li(){o.ComponentCollection.Instance.getCustomQuestionByName("shadoweffects").json.questionJSON=si()}function ui(e){if(Array.isArray(e)){var t=!1;if(e.forEach((function(e){for(var o in e)t=!0})),t)return e.map((function(e){var t,o,i,n,r;return"".concat(1==e.isInset?"inset ":"").concat(null!==(t=e.x)&&void 0!==t?t:0,"px ").concat(null!==(o=e.y)&&void 0!==o?o:0,"px ").concat(null!==(i=e.blur)&&void 0!==i?i:0,"px ").concat(null!==(n=e.spread)&&void 0!==n?n:0,"px ").concat(null!==(r=e.color)&&void 0!==r?r:"#000000")})).join(",")}}function pi(e){var t=ci(e);return t.forEach((function(e){e.x=0,e.y=0,e.blur=0,e.spread=0})),ui(t)}function ci(e){return void 0===e&&(e=""),e.split(/,(?![^(]*\))/).map((function(e){var t=e.match(/#[a-zA-Z0-9]+|rgba?\(.*?\)/),o=e.indexOf("inset")>-1,i={};o&&(e=e.replace("inset","")),t&&(i.color=t[0]);var n=e.replace(/\s+/g," ").replace(/^\s|\s$/g,"").split(" ");return i.x=parseInt(n[0])||0,i.y=parseInt(n[1])||0,i.blur=parseInt(n[2])||0,i.spread=parseInt(n[3])||0,i.isInset=o,i}))}function di(e){return e?e.replace(/\)\,\s/g,"),"):e}o.ComponentCollection.Instance.getCustomQuestionByName("font")||o.ComponentCollection.Instance.add({name:"font",showInToolbox:!1,internal:!0,elementsJSON:Xo(),onInit:function(){o.Serializer.addProperties("font",[{name:"allowEmptyColorValue:boolean",default:!1,visible:!1}])},onLoaded:function(e){$o(e,"allowEmptyColorValue",e.allowEmptyColorValue)},onPropertyChanged:function(e,t,o){$o(e,t,o)},onCreated:function(e){e.contentPanel.getQuestionByName("color").visible="surveyTitle"!==e.name&&"surveyDescription"!==e.name,e.contentPanel.getQuestionByName("placeholdercolor").visible="editorFont"===e.name,e.contentPanel.getQuestionByName("family").choices=[].concat(Yo)},valueToQuestion:function(e){return JSON.parse(JSON.stringify(e))},onValueChanged:function(e,t,o){}}),o.ComponentCollection.Instance.getCustomQuestionByName("backgroundcornerradius")||o.ComponentCollection.Instance.add({name:"backgroundcornerradius",showInToolbox:!1,internal:!0,elementsJSON:ii(),onInit:function(){},onCreated:function(e){},valueToQuestion:function(e){return JSON.parse(JSON.stringify(e))},onValueChanged:function(e,t,o){}}),o.ComponentCollection.Instance.getCustomQuestionByName("shadoweffects")||o.ComponentCollection.Instance.add({name:"shadoweffects",showInToolbox:!1,internal:!0,questionJSON:si(),onCreated:function(e){e.valueFromDataCallback=function(e){return void 0===e?[{}]:"string"==typeof e?ci(e):e},e.valueToDataCallback=function(e){return e?"string"==typeof e?e:ui(Array.isArray(e)?e:[e]):""},e.contentQuestion.panels.forEach((function(e){return e.questions.forEach((function(e){return e.allowRootStyle=!1}))}))}});var hi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner},t.prototype.fromJSON=function(t,o){e.prototype.fromJSON.call(this,t,o),t.backgroundImageOpacity&&(this.backgroundImageOpacity=100*t.backgroundImageOpacity)},t.prototype.setCssVariables=function(e){e&&(this.surveyTitle=oi(this.getPropertyByName("surveyTitle"),e),this.surveyDescription=oi(this.getPropertyByName("surveyDescription"),e),this.headerTitle=oi(this.getPropertyByName("headerTitle"),e),this.headerDescription=oi(this.getPropertyByName("headerDescription"),e));var t=e["--sjs-header-backcolor"];t&&(this.backgroundColorSwitch=this.getBackgroundColorSwitchByValue(t),this.backgroundColor="custom"===this.backgroundColorSwitch?t:void 0)},t.prototype.toJSON=function(t){var o=this,i=e.prototype.toJSON.call(this,t);delete i.type,delete i.logoPosition,delete i.headerView,100!==this.backgroundImageOpacity&&(i.backgroundImageOpacity=this.backgroundImageOpacity/100);var n={};return Object.keys(i).forEach((function(e){if("object"==typeof i[e]){var t=o.getPropertyByName(e);"font"===t.type&&(ti(i[e],t,n),delete i[e])}})),this.setHeaderBackgroundColorCssVariable(n),i.cssVariables=n,delete i.backgroundColorSwitch,delete i.backgroundColor,i},t.prototype.saveToThemeJSON=function(e,t){var o=this.toJSON(t);q(e.cssVariables,o.cssVariables),delete o.cssVariables,Object.keys(o).length>0&&(e.header=o),e.headerView=this.headerView},t.prototype.setHeaderBackgroundColorCssVariable=function(e){var t;"none"===this.backgroundColorSwitch?e["--sjs-header-backcolor"]="transparent":"custom"===this.backgroundColorSwitch?e["--sjs-header-backcolor"]=null!==(t=this.backgroundColor)&&void 0!==t?t:"transparent":e["--sjs-header-backcolor"]=void 0},t.prototype.getBackgroundColorSwitchByValue=function(e){return e?"transparent"===e?"none":"custom":"accentColor"},t.prototype.getType=function(){return"header"},t}(o.Base);function gi(){return{family:i.themeEditor.defaultFontFamily,weight:"700",size:32}}function mi(e){var t={family:i.themeEditor.defaultFontFamily,weight:"400",size:16};return e&&(t.weight="600"),t}function fi(e,t){return{type:"buttongroup",name:e,visibleIf:function(e){return"advanced"===e.headerView},choices:[{value:"left"},{value:"center"},{value:"right"}],default:t}}function yi(e,t){return{type:"buttongroup",name:e,displayName:"",visibleIf:function(e){return"advanced"===e.headerView},choices:[{value:"top"},{value:"middle"},{value:"bottom"}],default:t}}o.Serializer.addClass("header",[{type:"buttongroup",name:"headerView",default:"basic",choices:[{value:"basic"},{value:"advanced"}]},{type:"buttongroup",name:"logoPosition",visibleIf:function(e){return"basic"===e.headerView},default:"left",choices:[{value:"left"},{value:"right"}]},{type:"spinedit",name:"height",visibleIf:function(e){return"advanced"===e.headerView},default:256,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"spinedit",name:"mobileHeight",visibleIf:function(e){return"advanced"===e.headerView},default:0,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"buttongroup",name:"inheritWidthFrom",visibleIf:function(e){return"advanced"===e.headerView},default:"container",choices:[{value:"survey"},{value:"container"}]},{type:"spinedit",name:"textAreaWidth",visibleIf:function(e){return"advanced"===e.headerView},default:512,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"buttongroup",name:"backgroundColorSwitch",visibleIf:function(e){return"advanced"===e.headerView},isSerializable:!1,default:"accentColor",choices:[{value:"none"},{value:"accentColor"},{value:"custom"}]},{type:"color",name:"backgroundColor",displayName:"",visibleIf:function(e){return"advanced"===e.headerView},isSerializable:!1,onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyValue=!0,t.enableIf="{composite.backgroundColorSwitch} = 'custom'")}},{name:"backgroundImage:file",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.storeDataAsText=!1,t.acceptedTypes="image/*")}},{type:"buttongroup",name:"backgroundImageFit",displayName:"",choices:[{value:"cover"},{value:"fill"},{value:"contain"},{value:"tile"}],default:"cover",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.enableIf="{composite.backgroundImage} notempty")}},{type:"spinedit",name:"backgroundImageOpacity",visibleIf:function(e){return"advanced"===e.headerView},default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5,t.titleLocation="left",t.enableIf="{composite.backgroundImage} notempty")}},{type:"boolean",name:"overlapEnabled",displayName:"",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.renderAs="checkbox")}},fi("logoPositionX","right"),yi("logoPositionY","top"),fi("titlePositionX","left"),yi("titlePositionY","bottom"),fi("descriptionPositionX","left"),yi("descriptionPositionY","bottom")]),o.Serializer.addProperties("header",[{type:"font",name:"surveyTitle",visibleIf:function(e){return"basic"===e.headerView},default:gi()},{type:"font",name:"surveyDescription",visibleIf:function(e){return"basic"===e.headerView},default:mi()},{type:"font",name:"headerTitle",default:gi(),visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyColorValue=!0)}},{type:"font",name:"headerDescription",default:mi(!0),visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyColorValue=!0)}}]);var vi=n(7238);function bi(){return[{name:"color",type:"color",titleLocation:"hidden"},{name:"opacity",startWithNewLine:!1,type:"spinedit",title:Z("theme.opacity"),min:0,max:100,defaultValue:100,unit:"%",titleLocation:"left"}]}function Ci(){o.ComponentCollection.Instance.getCustomQuestionByName("coloralpha").json.elementsJSON=bi()}function wi(e,t,o){var i=e.contentPanel.questions[0];i&&("colorTitleLocation"==t&&(i.titleLocation=o),"colorTitle"==t&&(i.title=o),"choices"==t&&(i.choices=o),"allowEmptyValue"==t&&(i.allowEmptyValue=o))}function xi(e){return _(e.color,e.opacity/100)}function Ti(e){var t=(e.themeName||Vi.DefaultTheme.themeName||"default")+"-"+(e.colorPalette||"light");return!0===e.isPanelless&&(t+="-panelless"),t}function Si(e,t,o,i){var n=Jo[i];if(n)return n;for(var r=Object.keys(Jo).filter((function(t){return 0===t.indexOf(e+"-")})),a=0,s=r;a<s.length;a++){var l=s[a];0===l.indexOf(e+"-"+t)&&(i=e+"-"+t),0===l.indexOf(e+"-"+t+(o?"-panelless":""))&&(i=e+"-"+t+(o?"-panelless":""))}if(n=Jo[r[0]])return n;var u=Ti({themeName:Vi.DefaultTheme.themeName,colorPalette:t||"light",isPanelless:o});return Jo[u]||Vi.DefaultTheme}function Pi(e,t){void 0===t&&(t={});var o={};return Object.keys(e).forEach((function(i){"object"==typeof e[i]?o[i]=Pi(e[i],t[i]):void 0!==e[i]&&e[i]!=t[i]&&(o[i]=e[i])})),o}function Ei(e,t){if(!t){var i=Ti(e);t=Si(e.themeName,e.colorPalette,e.isPanelless,i)}var n=Pi(e,t);return Object.keys(n).forEach((function(e){-1!==e.toLowerCase().indexOf("background")&&(""!==n[e]&&n[e]!==o.Serializer.findProperty("survey",e).defaultValue||delete n[e])})),n.themeName=t.themeName||Vi.DefaultTheme.themeName||"default",n.colorPalette=t.colorPalette||"light",n.isPanelless=!!t.isPanelless,n}o.ComponentCollection.Instance.getCustomQuestionByName("coloralpha")||o.ComponentCollection.Instance.add({name:"coloralpha",showInToolbox:!1,internal:!0,elementsJSON:bi(),onInit:function(){o.Serializer.addProperties("coloralpha",[{name:"choices:itemvalue[]",visible:!1},{name:"colorTitleLocation:string",default:"hidden",visible:!1},{name:"allowEmptyValue:boolean",default:!1,visible:!1},{name:"colorTitle:string",visible:!1}])},onLoaded:function(e){wi(e,"colorTitle",e.colorTitle),wi(e,"colorTitleLocation",e.colorTitleLocation),wi(e,"choices",e.choices),wi(e,"allowEmptyValue",e.allowEmptyValue)},onPropertyChanged:function(e,t,o){wi(e,t,o)},valueToQuestion:function(e){return e?xi(e):""},valueFromQuestion:function(e){return"string"==typeof e||void 0===e?k(e):e},onCreated:function(e){e.contentPanel.questions.forEach((function(e){return e.allowRootStyle=!1}))}}),Object.keys(vi||{}).forEach((function(e){var t=vi[e],o={},i={};q(o,t.cssVariables),q(i,t,{cssVariables:o});var n=Ti(t);Jo[n]=i}));var Vi=function(e){function t(){var i=e.call(this)||this;return i.themeCssVariablesChanges={},i.colorCalculator=new H,i._defaultSessionTheme=t.DefaultTheme,i.onThemeSelected=new o.EventBase,i.onThemePropertyChanged=new o.EventBase,i.onAllowModifyTheme=new o.EventBase,i.blockThemeChangedNotifications=0,li(),ei(),Ci(),ni(),i.setNewHeaderProperty(),i.onPropertyValueChangedCallback=function(e,t,o,n,r){i.onThemePropertyValueChangedCallback(e,t,o,n,r)},i}return K(t,e),t.prototype.getFullThemeName=function(e){return"light"===this.colorPalette?e||this.themeName:(e||this.themeName)+"-"+this.colorPalette},Object.defineProperty(t.prototype,"defaultSessionTheme",{get:function(){return this._defaultSessionTheme},set:function(e){this._defaultSessionTheme=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssVariables",{get:function(){return this.toJSON().cssVariables||{}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"themeCssCustomizations",{get:function(){var e={};return q(e,this.themeCssVariablesChanges),e},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"theme"},t.prototype.setNewHeaderProperty=function(){var e=new hi;e.owner=this,this.setPropertyValue("header",e)},t.prototype.hasVariations=function(e){var t,o,i=Object.keys(Jo),n=this.themeName+"-light",r=this.themeName+"-dark";this.isPanelless&&(n+="-panelless",r+="-panelless"),o=-1!==i.indexOf(n)&&-1!==i.indexOf(r);var a=this.themeName+"-"+this.colorPalette,s=a+"-panelless";return t=-1!==i.indexOf(a)&&-1!==i.indexOf(s),e?o:t},t.prototype.initializeColorCalculator=function(e){e["--sjs-primary-backcolor"]&&e["--sjs-primary-backcolor-light"]&&e["--sjs-primary-backcolor-dark"]&&this.colorCalculator.initialize(e["--sjs-primary-backcolor"],e["--sjs-primary-backcolor-light"],e["--sjs-primary-backcolor-dark"])},t.prototype.updatePropertiesDependentOnPrimaryColor=function(e){this.colorCalculator.calculateColors(e),this.setPropertyValue("--sjs-primary-backcolor-light",this.colorCalculator.colorSettings.newColorLight),this.setPropertyValue("--sjs-primary-backcolor-dark",this.colorCalculator.colorSettings.newColorDark),this.setThemeCssVariablesChanges("--sjs-primary-backcolor-light",this.colorCalculator.colorSettings.newColorLight),this.setThemeCssVariablesChanges("--sjs-primary-backcolor-dark",this.colorCalculator.colorSettings.newColorDark)},t.prototype.cssVariablePropertiesChanged=function(e,t,o){var i=!0;if("primaryColor"===e)this.setPropertyValue("--sjs-primary-backcolor",t),this.setThemeCssVariablesChanges("--sjs-primary-backcolor",t),this.updatePropertiesDependentOnPrimaryColor(t);else if("--sjs-primary-backcolor"===e)this.primaryColor=t,this.updatePropertiesDependentOnPrimaryColor(t);else if("--sjs-shadow-inner"===e||"--sjs-shadow-small"===e){var n=pi(t);this.setPropertyValue(e+"-reset",n),this.setThemeCssVariablesChanges(e+"-reset",n)}else if("scale"==e)this.setThemeCssVariablesChanges("--sjs-base-unit",8*t/100+"px");else if("fontSize"==e)this.setThemeCssVariablesChanges("--sjs-font-size",16*t/100+"px");else if("cornerRadius"==e)this.setThemeCssVariablesChanges("--sjs-corner-radius",t+"px");else if("questionBackgroundTransparency"===e||"editorPanel"===e){var r=k(this.getPropertyValue("--sjs-general-backcolor-dim-light")).color,a=this.getPropertyValue("questionBackgroundTransparency");this.setThemeCssVariablesChanges("--sjs-editor-background",_(r,a/100))}else if("panelBackgroundTransparency"===e||"questionPanel"===e){r=k(this.getPropertyValue("--sjs-general-backcolor")).color;var s=this.getPropertyValue("panelBackgroundTransparency");this.setThemeCssVariablesChanges("--sjs-question-background",_(r,s/100))}else i=!1;var l=!0;return"font"===o.type?(ti(t,o,this.themeCssVariablesChanges),this.onThemePropertyChanged.fire(this,{name:e,value:t})):"backgroundcornerradius"===o.type?(ri(t,o,this.themeCssVariablesChanges),this.onThemePropertyChanged.fire(this,{name:e,value:t})):l=!1,i||l},t.prototype.setThemeCssVariablesChanges=function(e,t){this.themeCssVariablesChanges[e]!==t&&(this.themeCssVariablesChanges[e]=t,this.onThemePropertyChanged.fire(this,{name:e,value:t}))},t.prototype.initialize=function(e,o){void 0===e&&(e={}),this._defaultSessionTheme=t.DefaultTheme,this.backgroundImage="backgroundImage"in e?e.backgroundImage:null==o?void 0:o.backgroundImage,this.backgroundImageFit=void 0!==e.backgroundImageFit?e.backgroundImageFit:null==o?void 0:o.backgroundImageFit,this.backgroundImageAttachment=void 0!==e.backgroundImageAttachment?e.backgroundImageAttachment:null==o?void 0:o.backgroundImageAttachment,this.backgroundOpacity=100*((void 0!==e.backgroundOpacity?e.backgroundOpacity:null==o?void 0:o.backgroundOpacity)||1),this.loadTheme(e),this.header.logoPosition=null==o?void 0:o.logoPosition,this.undoRedoManager=new go},Object.defineProperty(t.prototype,"header",{get:function(){return this.getPropertyValue("header")},set:function(e){e&&(this.setNewHeaderProperty(),this.header.fromJSON(e.toJSON()))},enumerable:!1,configurable:!0}),t.prototype.loadTheme=function(e){this.blockThemeChangedNotifications+=1;try{var o=Ti(e),i=Si(e.themeName,e.colorPalette,e.isPanelless,o),n=Ei(e,i);this.themeName=n.themeName,this.colorPalette=n.colorPalette,this.isPanelless=n.isPanelless,this.backgroundImage=e.backgroundImage||this.backgroundImage,this.backgroundImageFit=e.backgroundImageFit||this.backgroundImageFit,this.backgroundImageAttachment=e.backgroundImageAttachment||this.backgroundImageAttachment;var r={};q(r,t.DefaultTheme.cssVariables||{},i.cssVariables||{}),q(r,e.cssVariables||{},this.themeCssVariablesChanges);var a={backgroundImage:this.backgroundImage||i.backgroundImage||"",backgroundImageFit:this.backgroundImageFit||i.backgroundImageFit,backgroundImageAttachment:this.backgroundImageAttachment||i.backgroundImageAttachment,backgroundOpacity:this.backgroundOpacity/100||i.backgroundOpacity},s={};Object.keys(s).length>0&&(a.header=s),q(a,e,{cssVariables:r,themeName:this.themeName,colorPalette:this.colorPalette,isPanelless:this.isPanelless}),this.initializeColorCalculator(a.cssVariables),this.fromJSON(a)}finally{this.blockThemeChangedNotifications-=1}},t.prototype.resetTheme=function(){this.setTheme({themeName:this.defaultSessionTheme.themeName,isPanelless:this.defaultSessionTheme.isPanelless,colorPalette:this.defaultSessionTheme.colorPalette})},t.prototype.setTheme=function(e){var t=this,o=this.themeCssVariablesChanges["--sjs-header-backcolor"];this.themeCssVariablesChanges={},void 0!==o&&(this.themeCssVariablesChanges["--sjs-header-backcolor"]=o);try{this.blockThemeChangedNotifications+=1,this.iteratePropertiesHash((function(e,o){t.setPropertyValue(o,void 0)})),this.setNewHeaderProperty()}finally{this.blockThemeChangedNotifications-=1}this.loadTheme(e),this.onThemeSelected.fire(this,{theme:this.toJSON()})},t.prototype.selectTheme=function(e,t,o){void 0===t&&(t="light"),void 0===o&&(o="panels"),this.themeName=e,this.colorPalette=t,this.isPanelless="lightweight"===o;var i=this.findSuitableTheme(e);this.setTheme(i)},t.prototype.generalPropertiesChanged=function(e,t){var o;return-1!==["themeName","isPanelless","colorPalette"].indexOf(e)&&("themeName"===e&&this.loadTheme(this.findSuitableTheme(t)||((o={})[e]=t,o.isPanelless=this.isPanelless,o.colorPalette=this.colorPalette,o)),"isPanelless"===e&&this.loadTheme({themeName:this.themeName,isPanelless:t,colorPalette:this.colorPalette}),"colorPalette"===e&&this.loadTheme({themeName:this.themeName,isPanelless:this.isPanelless,colorPalette:t}),this.onThemeSelected.fire(this,{theme:this.toJSON()}),!0)},t.prototype.onThemePropertyValueChangedCallback=function(e,t,o,i,n){var r=this;if(this.undoRedoManager&&(0==this.blockThemeChangedNotifications&&this.undoRedoManager.startTransaction(e+" changed"),this.undoRedoManager.onPropertyValueChanged(e,t,o,i,n)),!(this.blockThemeChangedNotifications>0)){var a=!1;if(this!==i){var s=i.toJSON();s.cssVariables&&Object.keys(s.cssVariables).forEach((function(e){return r.setThemeCssVariablesChanges(e,s.cssVariables[e])})),this.onThemePropertyChanged.fire(this,{name:e,value:o}),a=!0}if(0===e.indexOf("--")&&(this.setThemeCssVariablesChanges(e,o),a=!0),this.generalPropertiesChanged(e,o))this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction();else{if(this.blockThemeChangedNotifications+=1,this===i&&-1!==["backgroundImage","backgroundImageFit","backgroundImageAttachment","backgroundOpacity"].indexOf(e))return this[e]=o,this.onThemePropertyChanged.fire(this,{name:e,value:o}),this.blockThemeChangedNotifications-=1,void(this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction());this.cssVariablePropertiesChanged(e,o,i.getPropertyByName(e))&&(a=!0),a||this.onThemePropertyChanged.fire(this,{name:e,value:o}),this.blockThemeChangedNotifications-=1,this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction()}}},t.prototype.findSuitableTheme=function(e){var t=Ti({themeName:e,colorPalette:this.colorPalette,isPanelless:this.isPanelless});return Si(e,this.colorPalette,this.isPanelless,t)},t.prototype.fromJSON=function(t,i){var n=this;if(t){var r={};q(r,t),delete r.header,delete r.cssVariables,e.prototype.fromJSON.call(this,r,i);var a={};q(a,t.header),t.headerView&&(a.headerView=t.headerView),this.header.fromJSON(a||{}),t.cssVariables&&(this.primaryColor=t.cssVariables["--sjs-primary-backcolor"],e.prototype.fromJSON.call(this,t.cssVariables,i),this.header.setCssVariables(t.cssVariables),this.scale=this["--sjs-base-unit"]?l(100*parseFloat(this["--sjs-base-unit"])/8):void 0,this.fontSize=this["--sjs-font-size"]?l(100*parseFloat(this["--sjs-font-size"])/16):void 0,this.cornerRadius=this["--sjs-corner-radius"]?l(parseFloat(this["--sjs-corner-radius"])):void 0,t.backgroundOpacity&&(this.backgroundOpacity=100*t.backgroundOpacity),this.questionPanel=ai(this.getPropertyByName("questionPanel"),t.cssVariables,"--sjs-general-backcolor","--sjs-general-backcolor-dark",this.cornerRadius),this.editorPanel=ai(this.getPropertyByName("editorPanel"),t.cssVariables,"--sjs-general-backcolor-dim-light","--sjs-general-backcolor-dim-dark",this.cornerRadius),o.Serializer.getProperties("theme").forEach((function(e){"font"===e.type&&(n[e.name]=oi(e,t.cssVariables))})),this.pageTitle=oi(this.getPropertyByName("pageTitle"),t.cssVariables,"--sjs-general-dim-forecolor"),this.pageDescription=oi(this.getPropertyByName("pageDescription"),t.cssVariables,"--sjs-general-dim-forecolor-light"),this.questionTitle=oi(this.getPropertyByName("questionTitle"),t.cssVariables,"--sjs-general-forecolor"),this.questionDescription=oi(this.getPropertyByName("questionDescription"),t.cssVariables,"--sjs-general-forecolor-light"),this.editorFont=oi(this.getPropertyByName("editorFont"),t.cssVariables,"--sjs-general-forecolor","--sjs-general-forecolor-light"))}},t.prototype.toJSON=function(t){var o=this;void 0!==this.scale&&(this["--sjs-base-unit"]=8*this.scale/100+"px"),void 0!==this.fontSize&&(this["--sjs-font-size"]=16*this.fontSize/100+"px"),void 0!==this.cornerRadius&&(this["--sjs-corner-radius"]=this.cornerRadius+"px");var i=e.prototype.toJSON.call(this,t);i.backgroundImage=this.backgroundImage||"",i.backgroundOpacity=this.backgroundOpacity/100,i.backgroundImageAttachment=this.backgroundImageAttachment,i.backgroundImageFit=this.backgroundImageFit;var n={};return Object.keys(i).forEach((function(e){if(0==e.indexOf("--"))n[e]=i[e],delete i[e];else if("object"==typeof i[e]){var t=o.getPropertyByName(e);"font"===t.type&&(ti(i[e],t,n),delete i[e]),"backgroundcornerradius"===t.type&&(ri(i[e],t,n),delete i[e])}})),i.cssVariables=n,this.header.saveToThemeJSON(i,t),i},t.DefaultTheme=Jo["default-light"]||{},J([(0,o.property)()],t.prototype,"backgroundImage",void 0),J([(0,o.property)()],t.prototype,"backgroundImageFit",void 0),J([(0,o.property)()],t.prototype,"backgroundImageAttachment",void 0),J([(0,o.property)()],t.prototype,"backgroundOpacity",void 0),J([(0,o.property)()],t.prototype,"themeName",void 0),J([(0,o.property)()],t.prototype,"colorPalette",void 0),J([(0,o.property)()],t.prototype,"isPanelless",void 0),J([(0,o.property)()],t.prototype,"groupAppearanceAdvancedMode",void 0),J([(0,o.property)({onSet:function(e,t){var o=_(k(t.questionPanel.backcolor).color,e/100);if(t.questionPanel.backcolor!==o){var i=W({},t.questionPanel);i.backcolor=o,t.questionPanel=i}}})],t.prototype,"panelBackgroundTransparency",void 0),J([(0,o.property)({onSet:function(e,t){var o=_(k(t.editorPanel.backcolor).color,e/100);if(t.editorPanel.backcolor!==o){var i=W({},t.editorPanel);i.backcolor=o,t.editorPanel=i}}})],t.prototype,"questionBackgroundTransparency",void 0),J([(0,o.property)()],t.prototype,"scale",void 0),J([(0,o.property)()],t.prototype,"cornerRadius",void 0),J([(0,o.property)()],t.prototype,"fontSize",void 0),J([(0,o.property)({onSet:function(e,t){var o=k(e.backcolor).opacity;t.panelBackgroundTransparency!==o&&(t.panelBackgroundTransparency=o)}})],t.prototype,"questionPanel",void 0),J([(0,o.property)({onSet:function(e,t){var o=k(e.backcolor).opacity;t.questionBackgroundTransparency!==o&&(t.questionBackgroundTransparency=o)}})],t.prototype,"editorPanel",void 0),t}(o.Base);o.Serializer.addClass("theme",[{type:"dropdown",name:"themeName",choices:Wo.map((function(e){return{value:e,text:Z("theme.names."+e)}})),category:"general"},{type:"buttongroup",name:"colorPalette",displayName:"",choices:[{value:"light"},{value:"dark"}],category:"general",enableIf:function(e){return!e||e.hasVariations(!0)}},{type:"buttongroup",name:"isPanelless",choices:[{value:!1},{value:!0}],category:"general",enableIf:function(e){return!e||e.hasVariations(!1)}},{type:"spinedit",isSerializable:!1,name:"scale",onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"cornerRadius",onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{name:"advancedMode",type:"switchToggle",isSerializable:!1,default:!1,onPropertyEditorUpdate:function(e,t){t&&(t.titleLocation="hidden",t.renderAs="switch")}},{type:"spinedit",isSerializable:!1,name:"fontSize",onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"panelBackgroundTransparency",default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"questionBackgroundTransparency",default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5)}},{type:"backgroundcornerradius",name:"editorPanel"},{type:"backgroundcornerradius",name:"questionPanel"}],(function(e){return new Vi})),o.Serializer.addProperties("theme",[{name:"backgroundImage:file",onPropertyEditorUpdate:function(e,t){t&&(t.storeDataAsText=!1,t.acceptedTypes="image/*")}},{name:"backgroundImageFit",displayName:"",enableIf:function(e){return!!e.backgroundImage},choices:[{value:"auto"},{value:"contain"},{value:"cover"}],default:"cover"},{name:"backgroundImageAttachment",displayName:"",enableIf:function(e){return!!e.backgroundImage},choices:[{value:"fixed"},{value:"scroll"}],default:"scroll"},{type:"spinedit",isSerializable:!1,name:"backgroundOpacity",enableIf:function(e){return!!e.backgroundImage},default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5,t.titleLocation="left")}},{type:"header",name:"header",isSerializable:!1,onPropertyEditorUpdate:function(e,t){if(t){var o=t.contentPanel.elements,i=function(e){"panel"===e.getType()&&e.elements.forEach((function(e){i(e)}));var t=e.obj;if(t){var o=e.property;o&&o.onPropertyEditorUpdate&&o.onPropertyEditorUpdate(t,e)}};o.forEach((function(e){i(e)}))}}},{type:"color",isSerializable:!1,name:"primaryColor"},{type:"dropdown",name:"--sjs-font-family",default:i.themeEditor.defaultFontFamily,choices:[].concat(Yo),onPropertyEditorUpdate:function(e,t){t&&(t.allowClear=!1,t.choices=[].concat(Yo))}},{name:"--sjs-font-size",visible:!1,default:"16px"},{name:"--sjs-corner-radius",visible:!1},{name:"--sjs-base-unit",visible:!1},{name:"--sjs-corner-radius",visible:!1},{type:"font",name:"pageTitle",default:{family:i.themeEditor.defaultFontFamily,weight:"700",size:24}},{type:"font",name:"pageDescription",default:{family:i.themeEditor.defaultFontFamily,weight:"700",size:24}},{type:"shadoweffects",name:"--sjs-shadow-small",onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-small",di(t))}},{type:"font",name:"questionTitle",default:{family:i.themeEditor.defaultFontFamily,weight:"600",size:16}},{type:"font",name:"questionDescription",default:{family:i.themeEditor.defaultFontFamily,weight:"400",size:16}},{type:"shadoweffects",name:"--sjs-shadow-inner",onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-inner",di(t))}},{type:"font",name:"editorFont",default:{family:i.themeEditor.defaultFontFamily,weight:"400",size:16}},{type:"coloralpha",name:"--sjs-border-default",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.borderDefault"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-border-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.borderLight"),t.colorTitleLocation="left")}},{name:"--sjs-general-backcolor",visible:!1},{name:"--sjs-general-backcolor-dark",visible:!1},{name:"--sjs-general-backcolor-dim-light",visible:!1},{name:"--sjs-general-backcolor-dim-dark",visible:!1},{name:"--sjs-general-forecolor",visible:!1},{name:"--sjs-general-forecolor-light",visible:!1},{name:"--sjs-general-dim-forecolor",visible:!1},{name:"--sjs-general-dim-forecolor-light",visible:!1},{name:"--sjs-secondary-backcolor",visible:!1},{name:"--sjs-secondary-backcolor-light",visible:!1},{name:"--sjs-secondary-backcolor-semi-light",visible:!1},{name:"--sjs-secondary-forecolor",visible:!1},{name:"--sjs-secondary-forecolor-light",visible:!1},{name:"--sjs-shadow-small-reset",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-small-reset",di(t))}},{name:"--sjs-shadow-medium",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-medium",di(t))}},{name:"--sjs-shadow-large",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-large",di(t))}},{name:"--sjs-shadow-inner-reset",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-inner-reset",di(t))}},{name:"--sjs-border-light",visible:!1},{name:"--sjs-border-default",visible:!1},{name:"--sjs-border-inside",visible:!1},{name:"--sjs-special-red-forecolor",visible:!1},{name:"--sjs-special-green",visible:!1},{name:"--sjs-special-green-light",visible:!1},{name:"--sjs-special-green-forecolor",visible:!1},{name:"--sjs-special-blue",visible:!1},{name:"--sjs-special-blue-light",visible:!1},{name:"--sjs-special-blue-forecolor",visible:!1},{name:"--sjs-special-yellow",visible:!1},{name:"--sjs-special-yellow-light",visible:!1},{name:"--sjs-special-yellow-forecolor",visible:!1},{name:"--sjs-article-font-xx-large-textDecoration",visible:!1},{name:"--sjs-article-font-xx-large-fontWeight",visible:!1},{name:"--sjs-article-font-xx-large-fontStyle",visible:!1},{name:"--sjs-article-font-xx-large-fontStretch",visible:!1},{name:"--sjs-article-font-xx-large-letterSpacing",visible:!1},{name:"--sjs-article-font-xx-large-lineHeight",visible:!1},{name:"--sjs-article-font-xx-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-xx-large-textCase",visible:!1},{name:"--sjs-article-font-x-large-textDecoration",visible:!1},{name:"--sjs-article-font-x-large-fontWeight",visible:!1},{name:"--sjs-article-font-x-large-fontStyle",visible:!1},{name:"--sjs-article-font-x-large-fontStretch",visible:!1},{name:"--sjs-article-font-x-large-letterSpacing",visible:!1},{name:"--sjs-article-font-x-large-lineHeight",visible:!1},{name:"--sjs-article-font-x-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-x-large-textCase",visible:!1},{name:"--sjs-article-font-large-textDecoration",visible:!1},{name:"--sjs-article-font-large-fontWeight",visible:!1},{name:"--sjs-article-font-large-fontStyle",visible:!1},{name:"--sjs-article-font-large-fontStretch",visible:!1},{name:"--sjs-article-font-large-letterSpacing",visible:!1},{name:"--sjs-article-font-large-lineHeight",visible:!1},{name:"--sjs-article-font-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-large-textCase",visible:!1},{name:"--sjs-article-font-medium-textDecoration",visible:!1},{name:"--sjs-article-font-medium-fontWeight",visible:!1},{name:"--sjs-article-font-medium-fontStyle",visible:!1},{name:"--sjs-article-font-medium-fontStretch",visible:!1},{name:"--sjs-article-font-medium-letterSpacing",visible:!1},{name:"--sjs-article-font-medium-lineHeight",visible:!1},{name:"--sjs-article-font-medium-paragraphIndent",visible:!1},{name:"--sjs-article-font-medium-textCase",visible:!1},{name:"--sjs-article-font-default-textDecoration",visible:!1},{name:"--sjs-article-font-default-fontWeight",visible:!1},{name:"--sjs-article-font-default-fontStyle",visible:!1},{name:"--sjs-article-font-default-fontStretch",visible:!1},{name:"--sjs-article-font-default-letterSpacing",visible:!1},{name:"--sjs-article-font-default-lineHeight",visible:!1},{name:"--sjs-article-font-default-paragraphIndent",visible:!1},{name:"--sjs-article-font-default-textCase",visible:!1},{type:"color",name:"--sjs-general-backcolor-dim"},{type:"coloralpha",name:"--sjs-primary-backcolor",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryDefaultColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-backcolor-dark",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryDarkColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-backcolor-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryLightColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-forecolor",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryForecolor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-forecolor-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryForecolorLight"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-special-red",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.fontColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-special-red-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.backgroundColor"),t.colorTitleLocation="left")}}]),n(3071);var Ii=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getSwitcherIconCss=function(){return(new o.CssClassBuilder).append("svc-switcher__icon").append("svc-switcher__icon--checked",this.checked).toString()},t.prototype.getActionBarItemCss=function(){return"svc-switcher "+e.prototype.getActionBarItemCss.call(this)},J([(0,o.property)()],t.prototype,"checked",void 0),t}(o.Action),Ai={theme:{properties:[{name:"header",tab:"header"},{name:"--sjs-general-backcolor-dim",tab:"background"},{name:"backgroundImage",tab:"background"},{name:"backgroundImageFit",tab:"background"},{name:"backgroundImageAttachment",tab:"background"},{name:"backgroundOpacity",tab:"background"},{name:"primaryColor",tab:"appearancecolor"},{name:"panelBackgroundTransparency",tab:"appearancecolor"},{name:"questionBackgroundTransparency",tab:"appearancecolor"},{name:"--sjs-primary-backcolor",tab:"appearanceprimarycolor"},{name:"--sjs-primary-backcolor-dark",tab:"appearanceprimarycolor"},{name:"--sjs-primary-backcolor-light",tab:"appearanceprimarycolor"},{name:"--sjs-primary-forecolor",tab:"appearanceprimarycolor"},{name:"--sjs-primary-forecolor-light",tab:"appearanceprimarycolor"},{name:"--sjs-special-red",tab:"appearanceprimarycolor"},{name:"--sjs-special-red-light",tab:"appearanceprimarycolor"},{name:"--sjs-font-family",tab:"appearancefont"},{name:"fontSize",tab:"appearancefont"},{name:"scale",tab:"appearanceother"},{name:"cornerRadius",tab:"appearanceother"},{name:"advancedMode",tab:"appearanceadvancedmode"},{name:"pageTitle",tab:"appearancepage"},{name:"pageDescription",tab:"appearancepage"},{name:"questionPanel",tab:"appearancequestion"},{name:"--sjs-shadow-small",tab:"appearancequestion"},{name:"questionTitle",tab:"appearancequestion"},{name:"questionDescription",tab:"appearancequestion"},{name:"editorPanel",tab:"appearanceinput"},{name:"--sjs-shadow-inner",tab:"appearanceinput"},{name:"editorFont",tab:"appearanceinput"},{name:"--sjs-border-default",tab:"appearancelines"},{name:"--sjs-border-light",tab:"appearancelines"}],tabs:[{name:"header",index:100},{name:"background",index:200},{name:"appearance",index:300},{name:"appearancecolor",parent:"appearance",index:100},{name:"appearancefont",parent:"appearance",index:200},{name:"appearanceother",parent:"appearance",index:300},{name:"appearanceadvancedmode",parent:"appearance",index:350},{name:"appearanceprimarycolor",parent:"appearance",index:400},{name:"appearancepage",parent:"appearance",index:500},{name:"appearancequestion",parent:"appearance",index:600},{name:"appearanceinput",parent:"appearance",index:700},{name:"appearancelines",parent:"appearance",index:800}]},"header@header":{properties:[{name:"headerView"},{name:"logoPosition"},{name:"surveyTitle"},{name:"surveyDescription"},{name:"height",tab:"layout"},{name:"mobileHeight",tab:"layout"},{name:"inheritWidthFrom",tab:"layout"},{name:"textAreaWidth",tab:"layout"},{name:"backgroundColorSwitch",tab:"background"},{name:"backgroundColor",tab:"background"},{name:"backgroundImage",tab:"background"},{name:"backgroundImageFit",tab:"background"},{name:"backgroundImageOpacity",tab:"background"},{name:"overlapEnabled",tab:"background"},{name:"headerTitle",tab:"header"},{name:"headerDescription",tab:"header"},{name:"logoPositionX",tab:"positions"},{name:"logoPositionY",tab:"positions"},{name:"titlePositionX",tab:"positions"},{name:"titlePositionY",tab:"positions"},{name:"descriptionPositionX",tab:"positions"},{name:"descriptionPositionY",tab:"positions"}],tabs:[{name:"settings"},{name:"layout",parent:"settings",index:100},{name:"background",parent:"settings",index:200},{name:"header",parent:"settings",index:300},{name:"positions",parent:"settings",index:400}]}},Oi={autoGenerateProperties:!0,classes:Ai},Ni=function(){function e(){}return e.definition=Ai,e}(),Li=function(){function e(e){var t=this;this.creator=e,this.allowModifyTheme=!0,this.simulatorCssClasses=o.surveyCss[o.defaultV2ThemeName],this._availableThemes=[].concat(Wo),this._showOneCategoryInPropertyGrid=!1,this._advancedModeValue=!1,this.creatorPropertyChanged=function(e,o){"isMobileView"===o.name&&t.updateVisibilityOfPropertyGridGroups()},this.saveToFileHandler=Q,this.autoSaveTimerId=null,this.onThemeSelected=new o.EventBase,this.onThemePropertyChanged=new o.EventBase,this.onAllowModifyTheme=new o.EventBase,e.addPluginTab("theme",this),this.simulatorCssClasses=o.surveyCss[o.defaultV2ThemeName],this.tabControlModel=new No(this.creator.sidebar),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),this.propertyGrid=new st(void 0,e,Oi),this.propertyGrid.surveyInstanceCreatedArea="theme-tab:property-grid";var i=new Po(this.propertyGrid,e);this.propertyGridTab=this.creator.sidebar.addPage("theme","svc-property-grid",i),this.propertyGridTab.caption=G.getString("ed.themePropertyGridTitle"),this.themeModel=new Vi,e.registerShortcut("undo_theme",{name:"undo",affectedTab:"theme",hotKey:{ctrlKey:!0,keyCode:90},macOsHotkey:{keyCode:90},execute:function(){return t.undo()}}),e.registerShortcut("redo_theme",{name:"redo",affectedTab:"theme",hotKey:{ctrlKey:!0,keyCode:89},macOsHotkey:{keyCode:89},execute:function(){return t.redo()}}),e.onPropertyChanged.add(this.creatorPropertyChanged)}return Object.defineProperty(e.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid!==e&&(this._showOneCategoryInPropertyGrid=e,this.creator.sidebar.hideSideBarVisibilityControlActions=e,this.updateAdvancedModeQuestion(),this.propertyGrid.showOneCategoryInPropertyGrid=e,this.propertyGrid.setObj(this.creator.selectedElement),"theme"===this.creator.activeTab&&this.updateTabControl())},enumerable:!1,configurable:!0}),e.prototype.updateAdvancedModeQuestion=function(){var e=this.propertyGrid.survey.getQuestionByName("advancedMode");e&&(e.visible=this.showOneCategoryInPropertyGrid,e.value=this._advancedModeValue)},e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){return"theme"===e.creator.activeTab}))},e.prototype.createAppearanceAdvancedModeAction=function(){var e=this,t=new Ii({id:"advancedMode",component:"svc-switcher",ariaRole:"checkbox",css:"sv-theme-group_title-action",title:Z("theme.advancedMode"),visible:!this.creator.isMobileView,action:function(){t.checked=!t.checked,e.propertyGrid.survey.getQuestionByName("advancedMode")&&(e.propertyGrid.survey.getQuestionByName("advancedMode").value=t.checked)}});t.checked=this._advancedModeValue,this.advancedModeSwitcher=t},e.prototype.addSubGroupTitle=function(e,t){if(!e.getQuestionByName(t)){var i=o.Serializer.createClass("html");i.fromJSON({name:t,visibleIf:"{advancedMode} = true",html:"<div class='spg-theme-group-caption'>".concat(Z(t),"</div>")}),e.addElement(i)}},e.prototype.updateSubGroups=function(e){var t=this;["appearancelines","appearanceinput","appearancequestion","appearancepage","appearanceprimarycolor"].forEach((function(e){return t.setVisibleIf(e,!0)})),["appearancecolor","appearancefont","appearanceother"].forEach((function(e){return t.setVisibleIf(e,!1)})),this.addSubGroupTitle(e.getPanelByName("appearanceprimarycolor"),"theme.pageTitle"),this.addSubGroupTitle(e.getPanelByName("appearancepage"),"theme.questionTitle"),this.addSubGroupTitle(e.getPanelByName("appearancequestion"),"theme.editorPanel"),this.addSubGroupTitle(e.getPanelByName("appearanceinput"),"theme.lines")},e.prototype.updatePropertyGridEditorsAvailability=function(){var e=this.model.survey,t=this.propertyGrid.survey.pages[0],o=null==t?void 0:t.getElementByName("header");if(o&&o.elements.length>0){var i=o.elements[0].contentPanel;this.setCoverPropertiesFromSurvey(i,e)}var n=this.propertyGrid.survey.getQuestionByName("pageTitle"),r=e.isSinglePage?e.pages[0].elements:e.pages;n&&(n.readOnly=!r.some((function(e){return!!e.title})));var a=this.propertyGrid.survey.getQuestionByName("pageDescription");a&&(a.readOnly=!r.some((function(e){return!!e.description})))},e.prototype.getPredefinedColorsItemValues=function(){var e=this;return Object.keys(Ko[this.themeModel.colorPalette]).map((function(t){return new o.ItemValue(Ko[e.themeModel.colorPalette][t],Z("theme.colors."+t))}))},e.prototype.updatePropertyGridColorEditorWithPredefinedColors=function(){var e=this,t=this.propertyGrid.survey.pages[0],o=null==t?void 0:t.getElementByName("header");if(o&&o.elements.length>0){var i=o.elements[0].contentPanel.getQuestionByName("backgroundColor");i&&(i.choices=this.getPredefinedColorsItemValues())}this.propertyGrid.survey.getAllQuestions().forEach((function(t){-1!==["color","coloralpha"].indexOf(t.getType())&&(t.choices=e.getPredefinedColorsItemValues())}))},e.prototype._setPGEditorPropertyValue=function(e,t,o){e&&(e[t]=o)},e.prototype.setCoverPropertiesFromSurvey=function(e,t){if(this._setPGEditorPropertyValue(e.getQuestionByName("headerView"),"value",t.headerView),this._setPGEditorPropertyValue(e.getQuestionByName("logoPosition"),"value",t.logoPosition),this._setPGEditorPropertyValue(e.getQuestionByName("surveyTitle"),"readOnly",!t.hasTitle),this._setPGEditorPropertyValue(e.getQuestionByName("surveyDescription"),"readOnly",!t.hasDescription),this._setPGEditorPropertyValue(e.getQuestionByName("headerTitle"),"readOnly",!t.hasTitle),this._setPGEditorPropertyValue(e.getQuestionByName("headerDescription"),"readOnly",!t.hasDescription),this._setPGEditorPropertyValue(e.getQuestionByName("logoPositionX"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("logoPositionY"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("logoPosition"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("titlePositionX"),"readOnly",!t.title),this._setPGEditorPropertyValue(e.getQuestionByName("titlePositionY"),"readOnly",!t.title),this._setPGEditorPropertyValue(e.getQuestionByName("descriptionPositionX"),"readOnly",!t.description),this._setPGEditorPropertyValue(e.getQuestionByName("descriptionPositionY"),"readOnly",!t.description),t.showTOC){var o=e.getQuestionByName("inheritWidthFrom");this._setPGEditorPropertyValue(o,"value","container"),this._setPGEditorPropertyValue(o,"visible",!1)}},e.prototype.updateVisibilityOfPropertyGridGroups=function(){var e=this.propertyGrid.survey.pages[0],t=null==e?void 0:e.getElementByName("header");t&&(t.visible=!this.creator.isMobileView),this.advancedModeSwitcher&&(this.advancedModeSwitcher.visible=!this.creator.isMobileView)},e.prototype.setVisibleIf=function(e,t){var o=this.propertyGrid.survey.getPanelByName(e);o&&(o.visibleIf="{advancedMode} = ".concat(t))},e.prototype.updateTabControl=function(){this.showOneCategoryInPropertyGrid?(this.updateTabControlActions(),this.creator.sidebar.sideAreaComponentName="svc-tab-control",this.creator.sidebar.sideAreaComponentData=this.tabControlModel,this.creator.sidebar.header.componentName="svc-side-bar-header",this.creator.sidebar.header.componentData=this.creator.sidebar.header):(this.creator.sidebar.sideAreaComponentName="",this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.componentName="",this.creator.sidebar.header.componentData=void 0)},e.prototype.activate=function(){var e=this;this.model=new zo(this.creator,this.simulatorCssClasses),this.themeModel.initialize(this.creator.theme,this.creator.survey),this.creator.sidebar.hideSideBarVisibilityControlActions=this.showOneCategoryInPropertyGrid,this.update(),this.propertyGrid.survey.onOpenFileChooser.clear(),this.propertyGrid.obj=this.themeModel,this.propertyGrid.survey.mode="edit",this.propertyGrid.survey.getAllQuestions().forEach((function(e){return e.readOnly=!1})),this.onAvailableThemesChanged(this.availableThemes),this.updateAllowModifyTheme(),this.updateAdvancedModeQuestion();var t=JSON.parse(JSON.stringify(ze));t.root+=" spg-theme-builder-root",this.showOneCategoryInPropertyGrid&&(t.root+=" spg-root--one-category",t.page.root+=" spg-panel__content"),this.propertyGrid.survey.css=t,this.updateSubGroups(this.propertyGrid.survey),this.propertyGrid.survey.onGetPanelTitleActions.add((function(t,o){o.panel&&"appearance"==o.panel.name&&(e.createAppearanceAdvancedModeAction(),o.titleActions.push(e.advancedModeSwitcher))})),this.propertyGrid.survey.onOpenFileChooser.add((function(t,o){var i,n,r={};if(q(r,o.context,{element:e.themeModel,elementType:"theme"}),o.element){var a=o.element;r.propertyName=a.name,"settings"===(null===(n=null===(i=null==a?void 0:a.parent)||void 0===i?void 0:i.parent)||void 0===n?void 0:n.name)&&(r.elementType="header",r.element=r.element.header)}e.creator.chooseFiles(o.input,o.callback,r)})),this.propertyGrid.survey.onUpdatePanelCssClasses.add((function(t,o){var i,n,r;if(o.panel.hasParent){var a=null!==(i=o.panel.parent)&&void 0!==i?i:o.panel.parentQuestion;!a||a.hasParent&&"settings"!==a.name&&"settings"!==(null===(n=a.parentQuestion)||void 0===n?void 0:n.name)?(o.cssClasses.panel.container="spg-panel-group",o.cssClasses.panel.content="spg-panel-group__content"):(o.cssClasses.panel.container="spg-nested-panel",o.cssClasses.panel.content="spg-nested-panel__content")}else e.showOneCategoryInPropertyGrid&&(null===(r=o.panel.parent)||void 0===r?void 0:r.isPage)&&(o.cssClasses.panel.container="spg-panel-by-page",o.cssClasses.panel.content="spg-panel-by-page__content","appearanceother"===o.panel.name&&(o.cssClasses.panel.container+=" spg-panel--hidden-border"),"appearanceadvancedmode"===o.panel.name&&(o.cssClasses.panel.container+=" spg-panel--hidden-border spg-panel--padding"))})),this.updatePropertyGridEditorsAvailability(),this.updateVisibilityOfPropertyGridGroups(),this.updatePropertyGridColorEditorWithPredefinedColors(),this.creator.sidebar.activePage=this.propertyGridTab.id,this.propertyGridTab.visible=!0,this.updateTabControl(),this.creator.expandCategoryIfNeeded()},e.prototype.updateTabControlActions=function(){var e=this;if(this.showOneCategoryInPropertyGrid){var t=this.propertyGrid.survey.pages.map((function(o){var i=new kt({id:o.name,tooltip:o.title,iconName:Lo[o.name]||Lo[void 0],active:o.name===e.propertyGrid.survey.currentPage.name,pressed:!1,action:function(){e.creator.sidebar.expandSidebar(),e.propertyGrid.survey.currentPage=o,e.creator.sidebar.header.subTitle=o.title,t.forEach((function(e){return e.active=!1})),i.active=!0}});return i}));this.tabControlModel.topToolbar.setItems(t),this.creator.sidebar.header.subTitle=this.propertyGrid.survey.currentPage.title}},e.prototype.update=function(){var e=this;if(this.model){this.model.simulator.landscape="portrait"!=this.creator.previewOrientation,this.model.testAgainAction=this.testAgainAction,this.model.prevPageAction=this.prevPageAction,this.model.nextPageAction=this.nextPageAction;var t={showPagesInTestSurveyTab:this.creator.showPagesInTestSurveyTab};this.model.initialize(this.creator.JSON,t),this.updateSimulatorTheme(),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction.css=this.model.showInvisibleElements?"sv-action-bar-item--active":"",this.invisibleToggleAction.visible=this.model.isRunning),this.updateUndeRedoActions(),this.themeModel.undoRedoManager.canUndoRedoCallback=function(){e.updateUndeRedoActions()},this.model.show(),this.model.onPropertyChanged.add((function(t,o){"isRunning"===o.name&&(e.invisibleToggleAction&&(e.invisibleToggleAction.visible=e.model.isRunning),e.testAgainAction.visible=!e.model.isRunning)})),this.themeModel.onThemeSelected.add((function(t,o){e.syncTheme(o.theme),e.resetTheme.enabled=Ti(t.defaultSessionTheme)!==Ti(o.theme),e.saveThemeAction.enabled=!0,e.onThemeSelected.fire(e,o),e.creator.isAutoSave&&e.processAutoSave(),e.propertyGrid.survey.editingObj=void 0,e.propertyGrid.survey.editingObj=t,e.updateAllowModifyTheme(),e.updatePropertyGridColorEditorWithPredefinedColors()})),this.themeModel.onThemePropertyChanged.add((function(t,o){e.syncTheme(),"--sjs-base-unit"==o.name&&e.model.survey.triggerResponsiveness(!0),"logoPosition"==o.name&&(e.creator.survey.logoPosition=o.value,e.model.survey.logoPosition=o.value),e.resetTheme.enabled=!0,e.saveThemeAction.enabled=!0,e.onThemePropertyChanged.fire(e,o),e.creator.isAutoSave&&e.processAutoSave()})),this.themeModel.onAllowModifyTheme.add((function(t,o){e.onAllowModifyTheme.fire(e,o)})),this.resetTheme.enabled=Ti(this.themeModel.defaultSessionTheme)!==Ti(this.creator.theme)||this.isModified,this.updateTabControl()}},e.prototype.updateAllowModifyTheme=function(){var e=this,t={theme:this.themeModel,allow:!this.creator.readOnly};this.onAllowModifyTheme.fire(this,t),this.propertyGrid.survey.getAllQuestions().forEach((function(o){-1===["themeName","colorPalette","isPanelless"].indexOf(o.name)&&(o.readOnly=e.creator.onIsPropertyReadOnlyCallback(e.themeModel,e.themeModel.getPropertyByName(o.name),!t.allow,void 0,void 0,!1))}))},e.prototype.deactivate=function(){var e;return this.model&&(this.simulatorCssClasses=this.model.survey.css,this.model.onPropertyChanged.clear(),this.themeModel.onThemeSelected.clear(),this.themeModel.onThemePropertyChanged.clear(),this.themeModel.onAllowModifyTheme.clear(),this.model.onSurveyCreatedCallback=void 0,this.model.dispose(),this.model=void 0,this.creator.sidebar.hideSideBarVisibilityControlActions=!1),this._advancedModeValue=!!(null===(e=this.propertyGrid.survey.getQuestionByName("advancedMode"))||void 0===e?void 0:e.value),this.creator.sidebar.sideAreaComponentName=void 0,this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.reset(),this.propertyGridTab.visible=!1,this.testAgainAction.visible=!1,this.invisibleToggleAction&&(this.invisibleToggleAction.visible=!1),!0},e.prototype.exportToFile=function(e){var t=JSON.parse(JSON.stringify(this.themeModel.toJSON())),o=JSON.stringify(t,null,4),i=new Blob([o],{type:"application/json"});this.saveToFileHandler(e,i)},e.prototype.importFromFile=function(e,t){var o=this,i=new FileReader;i.onload=function(e){var n=JSON.parse(i.result);o.themeModel&&o.themeModel.setTheme(n),t&&t(n)},i.readAsText(e)},e.prototype.createActions=function(){var e=this,t=[];return this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",action:function(){e.creator.makeNewViewActive("designer")},visible:this.createVisibleUpdater(),locTitleName:"ed.designer",showTitle:!1}),this.prevPageAction=new o.Action({id:"prevPage",iconName:"icon-arrow-left_16x16",needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),visible:!1}),this.nextPageAction=new o.Action({id:"nextPage",iconName:"icon-arrow-right_16x16",visible:!1}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",active:!0,visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1,action:function(){}}),this.testAgainAction=new o.Action({id:"testSurveyAgain",visible:!1,locTitleName:"ed.testSurveyAgain",action:function(){e.model.testAgain()}}),this.undoAction=new o.Action({id:"action-undo-theme",iconName:"icon-undo",locTitleName:"ed.undo",showTitle:!1,visible:this.createVisibleUpdater(),action:function(){return e.undo()}}),this.redoAction=new o.Action({id:"action-redo-theme",iconName:"icon-redo",locTitleName:"ed.redo",showTitle:!1,visible:this.createVisibleUpdater(),action:function(){return e.redo()}}),t.push(this.undoAction),t.push(this.redoAction),this.saveThemeAction=new o.Action({id:"svd-save-theme",iconName:"icon-save",action:function(){e.creator.saveThemeActionHandler(),e.saveThemeAction.enabled=!1},active:!1,enabled:!1,visible:new o.ComputedUpdater((function(){return I("theme"===e.creator.activeTab,e.creator.showSaveButton)})),locTitleName:"ed.saveTheme",locTooltipName:"ed.saveThemeTooltip",showTitle:!1}),t.push(this.saveThemeAction),this.resetTheme=new o.Action({id:"svc-reset-theme",iconName:"icon-reset",locTitleName:"ed.themeResetButton",locTooltipName:"ed.themeResetButton",mode:"small",visible:this.createVisibleUpdater(),action:function(){o.settings.confirmActionAsync(Z("ed.themeResetConfirmation"),(function(t){t&&e.themeModel.resetTheme()}),Z("ed.themeResetConfirmationOk"),G.currentLocale)}}),t.push(this.resetTheme),this.themeSettingsAction=new o.Action({id:"svc-theme-settings",iconName:"icon-theme",action:function(){e.creator.showSidebar||e.creator.setShowSidebar(!0,!0)},visible:this.createVisibleUpdater(),active:new o.ComputedUpdater((function(){return e.creator.showSidebar})),pressed:new o.ComputedUpdater((function(){return e.creator.showSidebar})),locTitleName:"ed.themeSettings",locTooltipName:"ed.themeSettingsTooltip",showTitle:!1}),t.push(this.themeSettingsAction),this.importAction=new o.Action({id:"svc-theme-import",iconName:"icon-load",locTitleName:"ed.themeImportButton",locTooltipName:"ed.themeImportButton",visible:this.createVisibleUpdater(),mode:"small",component:"sv-action-bar-item",needSeparator:!0,action:function(){document&&(e.inputFileElement||(e.inputFileElement=document.createElement("input"),e.inputFileElement.type="file",e.inputFileElement.style.display="none",e.inputFileElement.onchange=function(){e.inputFileElement.files.length<1||(e.importFromFile(e.inputFileElement.files[0]),e.inputFileElement.value="")}),e.inputFileElement.click())}}),t.push(this.importAction),this.exportAction=new o.Action({id:"svc-theme-export",iconName:"icon-download",locTitleName:"ed.themeExportButton",locTooltipName:"ed.themeExportButton",visible:this.createVisibleUpdater(),mode:"small",component:"sv-action-bar-item",action:function(){e.exportToFile(i.themeEditor.exportFileName)}}),t.push(this.exportAction),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction=new o.Action({id:"showInvisible",iconName:"icon-invisible-items",mode:"small",locTitleName:"ts.showInvisibleElements",visible:!1,action:function(){e.model.showInvisibleElements=!e.model.showInvisibleElements,e.invisibleToggleAction.css=e.model.showInvisibleElements?"sv-action-bar-item--active":"",e.invisibleToggleAction.title=Z(e.model.showInvisibleElements?"ts.hideInvisibleElements":"ts.showInvisibleElements")}})),t},e.prototype.undo=function(){var e=this.model&&this.themeModel.undoRedoManager;e&&(e.suspend(),e.canUndo()&&e.undo(),e.resume())},e.prototype.redo=function(){var e=this.model&&this.themeModel.undoRedoManager;e&&(e.suspend(),e.canRedo()&&e.redo(),e.resume())},e.prototype.updateUndeRedoActions=function(){var e=this.themeModel.undoRedoManager;this.undoAction.enabled=e.canUndo(),this.redoAction.enabled=e.canRedo()},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.prevPageAction),this.creator.footerToolbar.actions.push(this.nextPageAction),this.invisibleToggleAction&&this.creator.footerToolbar.actions.push(this.invisibleToggleAction),this.creator.footerToolbar.actions.push(this.themeSettingsAction)},e.prototype.syncTheme=function(e){var t=e||this.themeModel.toJSON();this.creator.theme=t,this.updateSimulatorTheme(t)},e.prototype.updateSimulatorTheme=function(e){this.model.survey&&this.model.survey.applyTheme(e||this.themeModel.toJSON())},Object.defineProperty(e.prototype,"saveThemeFunc",{get:function(){return this._saveThemeFuncValue},set:function(e){this._saveThemeFuncValue=e},enumerable:!1,configurable:!0}),e.prototype.processAutoSave=function(){var e=this,t=this.saveThemeFunc;!t&&this.creator.saveThemeFunc&&(t=function(){return e.creator.saveTheme()}),t&&(this.creator.autoSaveDelay<=0?t():(this.autoSaveTimerId&&clearTimeout(this.autoSaveTimerId),this.autoSaveTimerId=setTimeout((function(){clearTimeout(e.autoSaveTimerId),e.autoSaveTimerId=null,t&&t()}),this.creator.autoSaveDelay)))},Object.defineProperty(e.prototype,"availableThemes",{get:function(){return[].concat(this._availableThemes)},set:function(e){this._availableThemes=e||[],this.onAvailableThemesChanged(e),this.updateAllowModifyTheme()},enumerable:!1,configurable:!0}),e.prototype.onAvailableThemesChanged=function(e){var t=this.propertyGrid.survey.getQuestionByName("themeName");t&&(t.choices=e.map((function(e){return{value:e,text:Z("theme.names."+e)}})),-1===e.indexOf(t.value)&&this.themeModel.setTheme(this.themeModel.defaultSessionTheme)),this.propertyGrid.survey.runExpressions()},e.prototype.addTheme=function(e,t){void 0===t&&(t=!1);var o=Ti(e);return Jo[o]=e,-1===this._availableThemes.indexOf(e.themeName)?t?(this.availableThemes=[e.themeName].concat(this.availableThemes),Vi.DefaultTheme=e):this.availableThemes=this.availableThemes.concat([e.themeName]):this.availableThemes=this.availableThemes,o},e.prototype.removeTheme=function(e,t){void 0===t&&(t=!1);var o="string"==typeof e?Jo[e]:e,i="string"==typeof e?e:Ti(o);if(o){delete Jo[i],Vi.DefaultTheme===o&&(Vi.DefaultTheme=Jo["default-light"]||Jo[Object.keys(Jo)[0]],this.themeModel.defaultSessionTheme=Vi.DefaultTheme);var n=Object.keys(Jo).filter((function(e){return 0===e.indexOf(o.themeName+"-")}));if(t&&n.length>0&&n.forEach((function(e){return delete Jo[e]})),t||0===n.length){var r=this._availableThemes.indexOf(o.themeName);if(-1!==r){var a=this.availableThemes;a.splice(r,1),this.availableThemes=a}}}},e.prototype.getCurrentTheme=function(e){return void 0===e&&(e=!1),e?this.getThemeChanges():this.creator.theme},e.prototype.getThemeChanges=function(){return Ei(this.creator.theme)},Object.defineProperty(e.prototype,"isModified",{get:function(){var e=this.getThemeChanges(),t=Object.keys(e.cssVariables).length>0,o=Object.keys(e).some((function(e){return-1!==e.toLowerCase().indexOf("background")})),i=!!e.header&&0===Object.keys(e.header).length;return t||o||i},enumerable:!1,configurable:!0}),e.DefaultTheme=Jo["default-light"],e}(),_i=function(){function e(e){var t=this;this.adorners=[],e.onSurfaceToolbarActionExecuted.add((function(e,o){var i="collapseAll"==o.action.id,n="expandAll"==o.action.id;(i||n)&&t.updateCollapsed(i)}))}return e.prototype.updateCollapsed=function(e){for(var t=this.adorners.length-1;t>=0;t--)this.adorners[t].allowExpandCollapse&&(this.adorners[t].collapsed=e)},e.prototype.add=function(e){this.adorners.push(e)},e.prototype.remove=function(e){this.adorners.splice(this.adorners.indexOf(e),1)},e}();const Mi={cssVariables:{"--sjs-primary-backcolor":"var(--sjs-primary-background-500)","--sjs-primary-backcolor-light":"var(--sjs-primary-background-10)","--sjs-primary-backcolor-dark":"var(--sjs-primary-background-400)","--sjs-primary-forecolor":"var(--sjs-primary-foreground-100)","--sjs-primary-forecolor-light":"var(--sjs-primary-foreground-25)","--sjs-secondary-backcolor":"var(--sjs-secondary-background-500)","--sjs-secondary-backcolor-light":"var(--sjs-secondary-background-10)","--sjs-secondary-backcolor-semi-light":"var(--sjs-secondary-background-25)","--sjs-secondary-forecolor":"var(--sjs-secondary-foreground-100)","--sjs-secondary-forecolor-light":"var(--sjs-secondary-forecolor-25)","--sjs-general-backcolor":"var(--sjs-layer-1-background-500)","--sjs-general-backcolor-dark":"var(--sjs-layer-1-background-400)","--sjs-general-forecolor":"var(--sjs-layer-1-foreground-100)","--sjs-general-forecolor-light":"var(--sjs-layer-1-foreground-50)","--sjs-general-backcolor-dim":"var(--sjs-layer-3-background-500)","--sjs-general-dim-forecolor":"var(--sjs-layer-3-foreground-100)","--sjs-general-dim-forecolor-light":"var(--sjs-layer-3-foreground-50)","--sjs-general-backcolor-dim-light":"var(--sjs-layer-2-background-500)","--sjs-general-backcolor-dim-dark":"var(--sjs-layer-2-background-400)","--sjs-border-default":"var(--sjs-border-25)","--sjs-border-light":"var(--sjs-border-10)","--sjs-border-inside":"var(--sjs-border-25)","--sjs-special-red":"var(--sjs-semantic-red-background-500)","--sjs-special-red-light":"var(--sjs-semantic-red-background-10)","--sjs-special-red-forecolor":"var(--sjs-semantic-red-foreground-100)","--sjs-special-green":"var(--sjs-semantic-green-background-500)","--sjs-special-green-light":"var(--sjs-semantic-green-background-10)","--sjs-special-green-forecolor":"var(--sjs-semantic-green-foreground-100)","--sjs-special-blue":"var(--sjs-semantic-blue-background-500)","--sjs-special-blue-light":"var(--sjs-semantic-blue-background-10)","--sjs-special-blue-forecolor":"var(--sjs-semantic-blue-foreground-100)","--sjs-special-yellow":"var(--sjs-semantic-yellow-background-500)","--sjs-special-yellow-light":"var(--sjs-semantic-yellow-background-10)","--sjs-special-yellow-forecolor":"var(--sjs-semantic-yellow-foreground-100)","--sjs-special-white":"var(--sjs-semantic-white-background-500)","--sjs-general-haze-background":"var(--sjs-special-haze)","--sjs-shadow-large-offset-x":"var(--lbr-shadow-large-offset-x)","--sjs-shadow-large-offset-y":"var(--lbr-shadow-large-offset-y)","--sjs-shadow-large-blur":"var(--lbr-shadow-large-blur)","--sjs-shadow-large-spread":"var(--lbr-shadow-large-spread)","--sjs-shadow-large-color":"var(--lbr-shadow-large-color)","--sjs-shadow-medium-offset-x":"var(--lbr-shadow-medium-offset-x)","--sjs-shadow-medium-offset-y":"var(--lbr-shadow-medium-offset-y)","--sjs-shadow-medium-blur":"var(--lbr-shadow-medium-blur)","--sjs-shadow-medium-spread":"var(--lbr-shadow-medium-spread)","--sjs-shadow-medium-color":"var(--lbr-shadow-medium-color)","--sjs-shadow-small-offset-x":"var(--lbr-shadow-small-offset-x)","--sjs-shadow-small-offset-y":"var(--lbr-shadow-small-offset-y)","--sjs-shadow-small-blur":"var(--lbr-shadow-small-blur)","--sjs-shadow-small-spread":"var(--lbr-shadow-small-spread)","--sjs-shadow-small-color":"var(--lbr-shadow-small-color)","--sjs-shadow-inner-offset-x":"var(--lbr-shadow-inner-offset-x)","--sjs-shadow-inner-offset-y":"var(--lbr-shadow-inner-offset-y)","--sjs-shadow-inner-blur":"var(--lbr-shadow-inner-blur)","--sjs-shadow-inner-spread":"var(--lbr-shadow-inner-spread)","--sjs-shadow-inner-color":"var(--lbr-shadow-inner-color)"}};var Di={designer:"icon-config",theme:"icon-theme",editor:"icon-codeeditor-24x24",translation:"icon-language",preview:"icon-preview",logic:"icon-logic-24x24",customembeded:"icon-embedsurvey-24x24",default:"icon-undefined-24x24"},ki=function(e){function t(t){return e.call(this,t)||this}return K(t,e),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-tabbed-menu-item").append("svc-tabbed-menu-item--selected",this.active).append("svc-tabbed-menu-item--disabled",void 0!==this.enabled&&!this.enabled).append("svc-tabbed-menu-item--icon",this.hasIcon).toString()},t.prototype.getTitleCss=function(){return(new o.CssClassBuilder).append("svc-text svc-tabbed-menu-item__text svc-text--normal").append("svc-text--bold",this.active).toString()},t.prototype.getIconCss=function(){return(new o.CssClassBuilder).append("svc-tabbed-menu-item__icon").toString()},Object.defineProperty(t.prototype,"hasTitle",{get:function(){return!this.hasIcon},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasIcon",{get:function(){return!this.disableShrink&&this.iconName&&"small"==this.mode},enumerable:!1,configurable:!0}),t}(o.Action),ji=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.dotsItem.popupModel.horizontalPosition="center",o.minVisibleItemsCount=1,o}return K(t,e),t.prototype.addTab=function(e,t,o,i,n){var r=this,a="test"===e?"preview":e,s=o?0==o.indexOf("ed.")?o:"":"tabs."+a,l=new ki({id:e,locTitleName:s,title:o,componentContent:i||"svc-tab-"+e,data:t,iconName:Di[a]||Di.default,action:function(){r.creator.makeNewViewActive(e)},active:this.creator.viewType===e,disableHide:this.creator.viewType===e});l.disableShrink="menu"==this.creator.tabResponsivenessMode,void 0!==n&&n>=0&&n<this.actions.length?this.actions.splice(n,0,l):this.actions.push(l)},t.prototype.updateResponsivenessMode=function(){var e=this;this.actions.forEach((function(t){t.disableShrink="menu"==e.creator.tabResponsivenessMode})),this.raiseUpdate(!0)},t}(o.AdaptiveActionContainer);n(264),n(8445),n(6190);var Ri=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.Action),Bi=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o}return K(t,e),t.prototype.getRenderedActions=function(){var e=this.actions,t=this.creator.sidebar.getExpandAction(),o=e.indexOf(t);return-1!==o&&(e.splice(o,1),e.push(t)),e},t}(o.ActionContainer),qi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.EventBase),Hi=function(e){function t(t,n){var r=e.call(this)||this;r.options=t,r.startEditTitleOnQuestionAddedValue=!0,r.isRTLValue=!1,r.alwaySaveTextInPropertyEditorsValue=!1,r.pageEditModeValue="standard",r.newQuestions=[],r.newPanels=[],r.plugins={},r.onElementDeleting=r.addCreatorEvent(),r.onGetPropertyReadOnly=r.addCreatorEvent(),r.onSurveyInstanceCreated=r.addCreatorEvent(),r.onGetObjectDisplayName=r.addCreatorEvent(),r.onHtmlToMarkdown=r.addCreatorEvent(),r.onElementAllowOperations=r.addCreatorEvent(),r.onDefineElementMenuItems=r.addCreatorEvent(),r.onShowingProperty=r.addCreatorEvent(),r.onCanShowProperty=r.onShowingProperty,r.onPropertyGridSurveyCreated=r.addCreatorEvent(),r.onPropertyEditorCreated=r.addCreatorEvent(),r.onPropertyEditorUpdateTitleActions=r.addCreatorEvent(),r.onPropertyGridShowModal=r.addCreatorEvent(),r.onCanDeleteItem=r.addCreatorEvent(),r.onCollectionItemDeleting=r.addCreatorEvent(),r.onCollectionItemAllowOperations=r.addCreatorEvent(),r.onItemValueAdded=r.addCreatorEvent(),r.onFastEntryFinished=r.addCreatorEvent(),r.onMatrixColumnAdded=r.addCreatorEvent(),r.onSetPropertyEditorOptions=r.addCreatorEvent(),r.onConfigureTablePropertyEditor=r.addCreatorEvent(),r.onGenerateNewName=r.addCreatorEvent(),r.onPropertyValidationCustomError=r.addCreatorEvent(),r.onPropertyValueChanging=r.addCreatorEvent(),r.onSurveyPropertyValueChanged=r.addCreatorEvent(),r.onConditionQuestionsGetList=r.addCreatorEvent(),r.onConditionGetTitle=r.addCreatorEvent(),r.onGetConditionOperator=r.addCreatorEvent(),r.onLogicItemDisplayText=r.addCreatorEvent(),r.onModified=r.addCreatorEvent(),r.onQuestionAdded=r.addCreatorEvent(),r.onPanelAdded=r.addCreatorEvent(),r.onPageAdded=r.addCreatorEvent(),r.onQuestionConverting=r.addCreatorEvent(),r.onGetPageActions=r.addCreatorEvent(),r.onDesignerSurveyCreated=r.addCreatorEvent(),r.onPreviewSurveyCreated=r.addCreatorEvent(),r.onTestSurveyCreated=r.onPreviewSurveyCreated,r.onNotify=r.addCreatorEvent(),r.onSelectedElementChanging=r.addCreatorEvent(),r.onSelectedElementChanged=r.addCreatorEvent(),r.onOpenFileChooser=r.addCreatorEvent(),r.onUploadFile=r.addCreatorEvent(),r.onTranslationStringVisibility=r.addCreatorEvent(),r.onTranslationLocaleInitiallySelected=r.addCreatorEvent(),r.onTranslationImportItem=r.addCreatorEvent(),r.onTranslationImported=r.addCreatorEvent(),r.onTranslationExportItem=r.addCreatorEvent(),r.onMachineTranslate=r.addCreatorEvent(),r.onTranslationItemChanging=r.addCreatorEvent(),r.onDragDropAllow=r.addCreatorEvent(),r.onDragOverLocationCalculating=r.addCreatorEvent(),r.onCreateCustomMessagePanel=r.addCreatorEvent(),r.maxLogicItemsInCondition=-1,r.showObjectTitles=!1,r.maxVisibleChoices=10,r.showTitlesInExpressions=!1,r.allowEditExpressionsInTextEditor=!0,r.maximumColumnsCount=i.propertyGrid.maximumColumnsCount,r.maximumChoicesCount=i.propertyGrid.maximumChoicesCount,r.minimumChoicesCount=i.propertyGrid.minimumChoicesCount,r.maximumRowsCount=i.propertyGrid.maximumRowsCount,r.maximumRateValues=i.propertyGrid.maximumRateValues,r.maxNestedPanels=-1,r.showPagesInTestSurveyTab=!0,r.showSimulatorInTestSurveyTab=!0,r.themeForPreview="defaultV2",r.hasPendingThemeChanges=!1,r._theme={cssVariables:{}},r._allowModifyPages=!0,r.showDefaultLanguageInTestSurveyTab="auto",r.showInvisibleElementsInTestSurveyTab=!0,r.allowChangeThemeInPreview=!0,r._tabResponsivenessMode="menu",r.showErrorOnFailedSave=!0,r.onActiveTabChanging=r.addCreatorEvent(),r.onActiveTabChanged=r.addCreatorEvent(),r.showSidebarValue=!0,r.onShowSidebarVisibilityChanged=r.addCreatorEvent(),r.onShowPropertyGridVisiblityChanged=r.addCreatorEvent(),r.onBeforeUndo=r.addCreatorEvent(),r.onBeforeRedo=r.addCreatorEvent(),r.onPageAdding=r.addCreatorEvent(),r.onDragStart=r.addCreatorEvent(),r.onBeforeDrop=r.onDragStart,r.onDragEnd=r.addCreatorEvent(),r.onAfterDrop=r.onDragEnd,r.animationEnabled=!1,r.onStateChanged=r.addCreatorEvent(),r.onSurfaceToolbarActionExecuted=r.addCreatorEvent(),r.expandCollapseManager=new _i(r),r.notifier=new o.Notifier({root:"svc-notifier",rootWithButtons:"",info:"svc-notifier--info",error:"svc-notifier--error",success:"svc-notifier--success",button:"",shown:"svc-notifier--shown"}),r.addNewQuestionLast=!0,r.onKeyDownHandler=function(e){r.findSuitableShortcuts(e).forEach((function(t){(e.keyCode<48||89==e.keyCode||90==e.keyCode)&&$i(e.target)||t.execute(r.selectedElement)}))},r.shortcuts={},r.hiddenProperties={},r.translationLocalesOrder=[],r.autoSaveDelay=i.autoSave.delay,r.autoSaveTimerId=null,r.saveNo=0,r._syncSaveActions=function(e,t){var o=r._findAction("svd-save"),i=r._findAction("svd-save-theme");o&&i&&(e===r?i.enabled=o.enabled:o.enabled=i.enabled)},r.showTabsDefault=i.layout.showTabs,r.showToolbarDefault=i.layout.showToolbar,r.expandOnDragTimeOut=1e3,r.allowDragPages=!1,r.collapsePagesOnDrag=!1,(n||"string"==typeof r.options||r.options instanceof String)&&(r.options=n||{},ee.warnText("Creator constructor has one parameter, as creator options, in V2.")),r.previewOrientation=t.previewOrientation,r.toolbarValue=new Bi(r),r.toolbarValue.locOwner=r,r.tabbedMenu=new ji(r),r.tabbedMenu.locOwner=r,r.selectionHistoryControllerValue=new be(r),r.sidebar=new Ro(r),r.setOptions(r.options),r.patchMetadata(),r.initSurveyWithJSON(void 0,!1),r.toolbox=new ve(r.options&&r.options.questionTypes?r.options.questionTypes:null,r,!0),r.updateToolboxIsCompact(),r.initTabs(),r.initDragDrop(),r.syncSaveButtons=void 0!==r.options.saveSurveyAndTheme?r.options.saveSurveyAndTheme:r.options.syncSaveButtons,r.isTouch=o.IsTouch;var a=r.sidebar.getExpandAction();return a&&r.toolbar.actions.push(a),r}return K(t,e),t.prototype.getMarkdownHtml=function(e,t){return null},t.prototype.getRenderer=function(e){return null},t.prototype.getRendererContext=function(e){return e},t.prototype.getProcessedText=function(e){return e},t.prototype.getLocale=function(){return this.locale},Object.defineProperty(t.prototype,"showPreviewTab",{get:function(){return this.showTestSurveyTab},set:function(e){this.showTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid=e;var t=this.getPlugin("designer");t&&(t.showOneCategoryInPropertyGrid=e);var o=this.getPlugin("theme");o&&(o.showOneCategoryInPropertyGrid=e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowEditSurveyTitle",{get:function(){return this.getPropertyValue("allowEditSurveyTitle",!0)},set:function(e){this.setPropertyVisibility("survey",e,"title","description","logo","logoFit","showTitle","logoWidth","logoHeight"),this.setPropertyValue("allowEditSurveyTitle",e),this.designerPropertyGrid&&this.designerPropertyGrid.refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSurveyTitle",{get:function(){return this.allowEditSurveyTitle},set:function(e){this.allowEditSurveyTitle=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"haveCommercialLicense",{get:function(){return!!o.hasLicense&&(0,o.hasLicense)(1)},set:function(e){console.warn("As of v1.9.101, the haveCommercialLicense property is not supported. To activate your license, use the setLicenseKey(key) method as shown on the following page: https://surveyjs.io/remove-alert-banner")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"licenseText",{get:function(){return this.getLocString("survey.license")},enumerable:!1,configurable:!0}),t.prototype.slk=function(e){(0,o.slk)(e)},Object.defineProperty(t.prototype,"startEditTitleOnQuestionAdded",{get:function(){return!this.isMobileView&&!this.toolbox.searchManager.filterString&&this.startEditTitleOnQuestionAddedValue},set:function(e){this.startEditTitleOnQuestionAddedValue=e},enumerable:!1,configurable:!0}),t.prototype.changePageModifications=function(e){void 0===e&&(e=!1),this.setPropertyVisibility("survey",e,"pages"),this.setPropertyVisibility("question",e,"page"),this.setPropertyVisibility("panel",e,"page"),this.showJSONEditorTab=!0===this.options.showJSONEditorTab},Object.defineProperty(t.prototype,"pageEditMode",{get:function(){return this.pageEditModeValue},set:function(e){this.pageEditModeValue=e;var t="single"!==this.pageEditModeValue;this.changePageModifications(t),o.settings.allowShowEmptyTitleInDesignMode=t,o.settings.allowShowEmptyDescriptionInDesignMode=t,"bypage"===this.pageEditModeValue&&(this.showPageNavigator=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolbarItems",{get:function(){return this.toolbarValue.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolbar",{get:function(){return this.toolbarValue},enumerable:!1,configurable:!0}),t.prototype._findAction=function(e){return this.toolbarItems.filter((function(t){return t.id===e}))[0]},Object.defineProperty(t.prototype,"showingViewName",{get:function(){return this.activeTab},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isDesignerShowing",{get:function(){return"designer"===this.activeTab},enumerable:!1,configurable:!0}),t.prototype.showDesigner=function(){this.activeTab="designer"},Object.defineProperty(t.prototype,"isTestSurveyShowing",{get:function(){return this.isPreviewShowing},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPreviewShowing",{get:function(){return"test"===this.activeTab},enumerable:!1,configurable:!0}),t.prototype.showTestSurvey=function(){this.showPreview()},t.prototype.showPreview=function(){this.activeTab="test"},t.prototype.addPluginTab=function(e,t,o,i,n){this.tabbedMenu.addTab(e,t,o,i,n),this.addPlugin(e,t)},t.prototype.addPlugin=function(e,t){this.plugins[e]=t},t.prototype.removePlugin=function(e){var t=this.getPlugin(e);if(t){var o=this.getTabIndex(e);o>-1&&this.tabs.splice(o,1),delete this.plugins[e],t.dispose&&t.dispose()}},t.prototype.getTabIndex=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].id===e)return t;return-1},t.prototype.getPlugin=function(e){return this.plugins[e]},Object.defineProperty(t.prototype,"showPagesInPreviewTab",{get:function(){return this.showPagesInTestSurveyTab},set:function(e){this.showPagesInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSimulatorInPreviewTab",{get:function(){return this.showSimulatorInTestSurveyTab},set:function(e){this.showSimulatorInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"themeEditor",{get:function(){return this.getPlugin("theme")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"saveThemeFunc",{get:function(){return this.saveThemeFuncValue},set:function(e){this.saveThemeFuncValue=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"theme",{get:function(){return this._theme},set:function(e){this._theme=e,this.hasPendingThemeChanges=!0,"theme"!==this.activeTab&&this.updatePlugin(this.activeTab)},enumerable:!1,configurable:!0}),t.prototype._doSaveThemeCore=function(e){var t=this;this.setState("saving"),this.saveThemeFunc&&(this.saveNo++,this.saveThemeFunc(this.saveNo,(function(o,i){t.saveNo===o&&(i?(t.setState("saved"),t.hasPendingThemeChanges=!1):(t.setState("modified"),t.showErrorOnFailedSave&&t.notify(t.getLocString("ed.saveError"),"error")),e&&e())})))},t.prototype.saveTheme=function(){this._doSaveThemeCore()},t.prototype.saveThemeActionHandler=function(){this.syncSaveButtons?this.save():this.saveTheme()},Object.defineProperty(t.prototype,"allowModifyPages",{get:function(){return this._allowModifyPages},set:function(e){this._allowModifyPages=e,this.changePageModifications(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showDefaultLanguageInPreviewTab",{get:function(){return this.showDefaultLanguageInTestSurveyTab},set:function(e){this.showDefaultLanguageInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showInvisibleElementsInPreviewTab",{get:function(){return this.showInvisibleElementsInTestSurveyTab},set:function(e){this.showInvisibleElementsInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabResponsivenessMode",{get:function(){return this._tabResponsivenessMode},set:function(e){this._tabResponsivenessMode=e,this.tabbedMenu.updateResponsivenessMode()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabs",{get:function(){return this.tabbedMenu.actions},set:function(e){this.tabbedMenu.actions=e},enumerable:!1,configurable:!0}),t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.onSetReadOnly=function(e){},Object.defineProperty(t.prototype,"locale",{get:function(){return this.getPropertyValue("locale",G.currentLocale)},set:function(e){G.currentLocale!==e&&(G.currentLocale=e,this.setPropertyValue("locale",e),this.updateLocalizedStrings())},enumerable:!1,configurable:!0}),t.prototype.updateLocalizedStrings=function(){this.toolbox.updateTitles(),this.refreshPlugin();var e=this.selectedElement;e&&(this.selectElement(null),this.selectElement(e)),this.locStrsChanged()},t.prototype.locStrsChanged=function(){e.prototype.locStrsChanged.call(this),this.tabbedMenu.locStrsChanged(),this.toolbar.locStrsChanged()},t.prototype.refreshPlugin=function(){var e=this.currentPlugin;if(e){e.deactivate&&e.deactivate();var t=this.viewType;this.viewType="",e.activate(),this.viewType=t}},Object.defineProperty(t.prototype,"readOnly",{get:function(){return this.getPropertyValue("readOnly",!1)},set:function(e){var t=this.text;this.setPropertyValue("readOnly",e),this.onSetReadOnly(e),this.text=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRTL",{get:function(){return this.isRTLValue},set:function(e){this.isRTLValue=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activeTab",{get:function(){return this.viewType},set:function(e){this.makeNewViewActive(e)},enumerable:!1,configurable:!0}),t.prototype.makeNewViewActive=function(e){var t=this;if(e==this.viewType)return!1;var o=this.currentPlugin;if(!o||!o.canDeactivateAsync)return this.switchViewType(e);o.canDeactivateAsync((function(){t.switchViewType(e)}))},t.prototype.switchViewType=function(e){var t,o,i=!0;if((null===(t=this.currentPlugin)||void 0===t?void 0:t.defaultAllowingDeactivate)&&void 0===(i=this.currentPlugin.defaultAllowingDeactivate()))return!1;var n={tabName:e,allow:i,model:null===(o=this.currentPlugin)||void 0===o?void 0:o.model};if(this.onActiveTabChanging.fire(this,n),n.allow){if(!this.canSwitchViewType())return!1;var r=this.activatePlugin(e);return this.viewType=e,this.onActiveTabChanged.fire(this,{tabName:e,plugin:r,model:r?r.model:void 0}),!0}},t.prototype.canSwitchViewType=function(){var e=this.currentPlugin;return!e||!e.deactivate||e.deactivate()},t.prototype.activatePlugin=function(e){var t=this.getPlugin(e);return t&&t.activate(),t},Object.defineProperty(t.prototype,"currentPlugin",{get:function(){return this.getPlugin(this.activeTab)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolboxCategories",{get:function(){return this.toolbox.categories},enumerable:!1,configurable:!0}),t.prototype.addCreatorEvent=function(){return this.addEvent()},t.prototype.updateToolboxIsCompact=function(e){if(this.toolbox){var t=null!=e&&null!=e;void 0!==this.toolbox.forceCompact?this.toolbox.isCompact=this.toolbox.forceCompact:"right"==this.toolboxLocation?this.toolbox.isCompact=this.showSidebar||t&&e:t&&this.toolbox.isCompact!==e&&(this.toolbox.isCompact=e)}},Object.defineProperty(t.prototype,"showToolbox",{get:function(){return this.showToolboxValue&&this.allowShowToolbox},set:function(e){!0!==e&&!1!==e&&ee.warnText("showToolbox is a boolean property now."),"none"===e||!1===e||"top"===e?this.showToolboxValue=!1:(!0===e||(this.toolboxLocation=e),this.showToolboxValue=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSidebar",{get:function(){return this.showSidebarValue},set:function(e){!0===e||!1===e?this.showSidebar!==e&&(this.setShowSidebar(e,!0),this.onShowPropertyGridVisiblityChanged.isEmpty||(ee.warnNonSupported("onShowPropertyGridVisiblityChanged","onShowSidebarVisibilityChanged"),this.onShowPropertyGridVisiblityChanged.fire(this,{show:e}))):ee.warnText("showSidebar is a boolean property now.")},enumerable:!1,configurable:!0}),t.prototype.setShowSidebar=function(e,t){void 0===t&&(t=!1),this.showSidebarValue=e,t&&(e?this.sidebar.expandedManually=!0:this.sidebar.collapsedManually=!0),this.updateToolboxIsCompact(),this.onShowSidebarVisibilityChanged.fire(this,{show:e})},Object.defineProperty(t.prototype,"showPropertyGrid",{get:function(){return ee.warnNonSupported("showPropertyGrid","showSidebar"),this.showSidebar},set:function(e){ee.warnNonSupported("showPropertyGrid","showSidebar"),!0===e||!1===e?this.showSidebar=e:ee.warnText("showSidebar is a boolean property.")},enumerable:!1,configurable:!0}),t.prototype.rightContainerActiveItem=function(e){ee.warnNonSupported("rightContainerActiveItem")},t.prototype.leftContainerActiveItem=function(e){ee.warnNonSupported("leftContainerActiveItem")},Object.defineProperty(t.prototype,"undoRedoManager",{get:function(){var e=this.getPlugin("undoredo");return e&&e.model.undoRedoManager},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"undoRedoController",{get:function(){var e=this.getPlugin("undoredo");return e&&e.model},enumerable:!1,configurable:!0}),t.prototype.startUndoRedoTransaction=function(e){void 0===e&&(e=""),this.undoRedoController&&this.undoRedoController.startTransaction(e)},t.prototype.stopUndoRedoTransaction=function(){this.undoRedoController&&this.undoRedoController.stopTransaction()},Object.defineProperty(t.prototype,"isProcessingUndoRedo",{get:function(){return this.undoRedoManager&&this.undoRedoManager.isProcessingUndoRedo},enumerable:!1,configurable:!0}),t.prototype.undo=function(){this.undoRedoController&&this.undoRedoController.undo()},t.prototype.redo=function(){this.undoRedoController&&this.undoRedoController.redo()},Object.defineProperty(t.prototype,"selectionHistoryController",{get:function(){return this.selectionHistoryControllerValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPage",{get:function(){return this.survey.currentPage},set:function(e){this.survey.currentPage=e},enumerable:!1,configurable:!0}),t.prototype.canAddPage=function(e){var t={page:e,allow:!0};return this.onPageAdding.fire(this,t),t.allow},t.prototype.addPage=function(e,t,o){if(void 0===t&&(t=!0),!this.canAddPage(e))return null;if(void 0===o||o()){var i=e;return i?this.survey.addPage(i):i=this.addNewPageIntoSurvey(),t&&this.selectElement(i),i}},t.prototype.addNewPageIntoSurvey=function(){var e=ee.getNewPageName(this.survey.pages);return this.survey.addNewPage(e)},t.prototype.initTabs=function(){this.initPlugins(),this.initFooterToolbar()},t.prototype.getTabsInfo=function(){var e=this;return{designer:function(){return new _o(e)},preview:function(){return new Ne(e)},theme:function(){return new Li(e)},logic:function(){return new ho(e)},editor:function(){return Te.hasAceEditor()?new Te(e):new Pe(e)},translation:function(){return new eo(e)}}},t.prototype.getAvailableTabNames=function(){var e=[],t=this.getTabsInfo();for(var o in t)e.push(o);return e},t.prototype.getTabNames=function(){var e=this.getAvailableTabNames(),t=[];return this.tabs.forEach((function(o){var i="test"===o.id?"preview":o.id;e.indexOf(i)>-1&&t.push(i)})),t},t.prototype.setTabs=function(e){var t=this;if(Array.isArray(e)){for(var o=this.getTabsInfo(),i=e.length-1;i>=0;i--)o[e[i]]||e.splice(i,1);if(0!==e.length){for(i=this.tabs.length-1;i>=0;i--){var n=this.tabs[i].id,r="test"===n?"preview":n;e.indexOf(r)<0&&this.removePlugin(n)}for(e.forEach((function(e){var i="preview"===e?"test":e;o[e]&&t.getTabIndex(i)<0&&o[e]()})),i=0;i<e.length;i++){var a=this.getTabIndex(e[i]);if(a>-1&&a!==i){var s=this.tabs[a];this.tabs.splice(a,1),this.tabs.splice(i,0,s)}}this.tabs.length>0&&this.makeNewViewActive(this.tabs[0].id)}}},t.prototype.initPlugins=function(){this.addPlugin("undoredo",new bo(this));var e=[];this.showDesignerTab&&e.push("designer"),this.showPreviewTab&&e.push("preview"),this.showThemeTab&&e.push("theme"),this.showLogicTab&&e.push("logic"),this.showJSONEditorTab&&e.push("editor"),this.showTranslationTab&&e.push("translation"),this.setTabs(e)},t.prototype.initFooterToolbar=function(){var e=this;this.footerToolbar||(this.footerToolbar=new o.ActionContainer,["designer","undoredo","test","theme"].forEach((function(t){var o=e.getPlugin(t);o&&o.addFooterActions&&o.addFooterActions()})))},t.prototype.getOptions=function(){return this.options||{}},t.prototype.setOptions=function(e){e||(e={});var t={showTestSurveyTab:"showPreviewTab",showDefaultLanguageInTestSurveyTab:"showDefaultLanguageInPreviewTab",showInvisibleElementsInPreviewTab:"showInvisibleElementsInTestSurveyTab"};for(var o in t)if(void 0!==e[o]){var i=t[o];void 0===e[i]&&(e[i]=e[o],delete e[o])}for(var o in this.options=e,e)this[o]=e[o]},t.prototype.setPropertyPlaceHolder=function(e,t,i){var n=o.Serializer.findProperty(e,t);n&&(n.placeholder=i)},t.prototype.setPropertyVisibility=function(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];if(Array.isArray(i))for(var r=0;r<i.length;r++){var a=o.Serializer.findProperty(e,i[r]);a&&(t?delete this.hiddenProperties[a.id]:this.hiddenProperties[a.id]=!0)}},t.prototype.patchMetadata=function(){this.setPropertyPlaceHolder("survey","title","pe.surveyTitlePlaceholder"),this.setPropertyPlaceHolder("survey","description","pe.surveyDescriptionPlaceholder"),this.setPropertyVisibility("survey",!1,"logoPosition"),"single"!==this.pageEditMode&&(this.setPropertyPlaceHolder("page","title","pe.pageTitlePlaceholder"),this.setPropertyPlaceHolder("page","description","pe.pageDescriptionPlaceholder"))},t.prototype.isCanModifyProperty=function(e,t){var i,n,r=o.Serializer.findProperty(e.getType(),t);if(e instanceof o.ItemValue){i=e.locOwner,n=o.Serializer.findProperty(i.getType(),e.ownerPropertyName||t);var a=!0;if(i instanceof o.QuestionSelectBase&&(a=i.isItemInList(e)),!1===this.getElementAllowOperations(i).allowEdit)return!1;var s={allowDelete:!0,allowEdit:a,allowAdd:!0};if(this.onCollectionItemAllowingCallback(i,r,i.getPropertyValue(null==n?void 0:n.name),e,s),!1===s.allowEdit)return!1;if(this.onIsPropertyReadOnlyCallback(i,n,null==n?void 0:n.readOnly,null,null))return!1}return!(e instanceof o.SurveyElement&&!1===this.getElementAllowOperations(e).allowEdit)&&(!r||!this.onIsPropertyReadOnlyCallback(e,r,r.readOnly,i,n))},t.prototype.onIsPropertyReadOnlyCallback=function(e,t,o,i,n,r){if(!t)return!1;void 0===r&&(r=this.readOnly);var a=r||o;if(this.onGetPropertyReadOnly.isEmpty)return a;var s={obj:e,property:t,readOnly:a,propertyName:t.name,parentObj:i,parentProperty:n};return this.onGetPropertyReadOnly.fire(this,s),s.readOnly},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),t.prototype.addCollectionItemsJson=function(e,t){var i=new o.SurveyModel(e);this.updateAddingSurvey(i),this.addSurveyPages(i,t)},t.prototype.updateAddingSurvey=function(e){this.updateAddingPages(e),this.updateAddingPanels(e),this.updateAddingQuestions(e),this.updateAddingCalculatedValules(e),this.updateAddingArrays(e)},t.prototype.updateAddingPages=function(e){this.updateAddingElements(e,e.pages,this.survey.pages,(function(e,t){e.name=ee.getNewPageName(t)}))},t.prototype.updateAddingExistingElements=function(){return[].concat(this.survey.getAllQuestions(!1,!0)).concat(this.survey.getAllPanels())},t.prototype.updateAddingPanels=function(e){this.updateAddingElements(e,e.getAllPanels(),this.updateAddingExistingElements(),(function(e,t){e.name=ee.getNewPanelName(t)}))},t.prototype.updateAddingQuestions=function(e){var t=new Ue(e,this);this.updateAddingElements(e,e.getAllQuestions(!1,!0),this.updateAddingExistingElements(),(function(e,o){var i=e.name;e.name=ee.getNewQuestionName(o),t.renameQuestion(i,e.name)}))},t.prototype.updateAddingCalculatedValules=function(e){var t=new Ue(e,this);this.updateAddingElements(e,e.calculatedValues,this.survey.calculatedValues,(function(e,o){var i=e.name;e.name=ee.getNewName(o,"var"),t.renameQuestion(i,e.name)}))},t.prototype.updateAddingArrays=function(e){var t=this;e.triggers.forEach((function(e){return t.survey.triggers.push(e)})),e.completedHtmlOnCondition.forEach((function(e){return t.survey.completedHtmlOnCondition.push(e)})),e.calculatedValues.forEach((function(e){return t.survey.calculatedValues.push(e)}))},t.prototype.updateAddingElements=function(e,t,o,i){var n=[],r={};o.forEach((function(e){e.name&&(r[e.name]=e)})),t.forEach((function(e){e.name&&r[e.name]&&n.push(e)}));var a=o.concat(t);n.forEach((function(e){i(e,a)}))},t.prototype.addSurveyPages=function(e,t){(void 0===t||t>=this.survey.pages.length)&&(t=-1);for(var o=0;o<e.pages.length;o++)t<0?this.survey.pages.push(e.pages[o]):this.survey.pages.splice(t+o,0,e.pages[o])},t.prototype.initSurveyWithJSON=function(e,t){var i=this;e||(e={logoPosition:"right"}),this.existingPages={};var n=this.createSurvey({},"designer",void 0,(function(t){t.skeletonHeight=188,t.css=o.defaultV2Css,t.setIsMobile(!!i.isMobileView),t.setDesignMode(!0),t.lazyRendering=!0,t.setJsonObject(e),t.isEmpty&&t.setJsonObject(i.getDefaultSurveyJson())}));n.pages.forEach((function(e){i.existingPages[e.id]=!0})),n.onQuestionAdded.add((function(e,t){i.doOnQuestionAdded(t.question,t.parentPanel)})),n.onPanelAdded.add((function(e,t){i.doOnPanelAdded(t.panel,t.parentPanel)})),n.onPageAdded.add((function(e,t){i.existingPages[t.page.id]||(i.existingPages[t.page.id]=!0,i.doOnPageAdded(t.page))})),n.onDragDropAllow.add((function(e,t){t.survey=e,i.onDragDropAllow.fire(i,t)})),this.setSurvey(n),this.updatePlugin(this.activeTab),"designer"!==this.activeTab&&this.updatePlugin("designer"),this.undoRedoController&&this.undoRedoController.updateSurvey()},t.prototype.updatePlugin=function(e){var t=this.getPlugin(this.activeTab);t&&t.update&&t.update()},t.prototype.initDragDrop=function(){this.initDragDropSurveyElements(),this.initDragDropChoices()},t.prototype.initDragDropSurveyElements=function(){var e=this;Qt.restrictDragQuestionBetweenPages=i.dragDrop.restrictDragQuestionBetweenPages,this.dragDropSurveyElements=new Qt(null,this),this.dragDropSurveyElements.onGetMaxNestedPanels=function(){return e.maxNestedPanels},this.dragDropSurveyElements.onDragOverLocationCalculating=function(t){e.onDragOverLocationCalculating.fire(e,t)};var t=!1;this.dragDropSurveyElements.onDragStart.add((function(o,i){t=!o.draggedElement.parent&&!o.draggedElement.isPage,e.onDragStart.fire(e,i),e.startUndoRedoTransaction("drag drop")})),this.dragDropSurveyElements.onDragEnd.add((function(o,i){e.stopUndoRedoTransaction();var n=t&&e.startEditTitleOnQuestionAdded;i.draggedElement&&(e.selectElement(i.draggedElement,void 0,!0,n),e.onDragEnd.fire(e,i),i.fromElement||i.draggedElement.isPage||e.setModified({type:"ADDED_FROM_TOOLBOX",question:i.draggedElement}))})),this.dragDropSurveyElements.onDragClear.add((function(o,i){var n;t=!1,e.stopUndoRedoTransaction(),e.collapsePagesOnDrag&&(null===(n=e.designerStateManager)||void 0===n||n.release(),e.restorePagesState())}))},Object.defineProperty(t.prototype,"designerStateManager",{get:function(){return this.getPlugin("designer").designerStateManager},enumerable:!1,configurable:!0}),t.prototype.collapseAllPages=function(){this.survey.pages.forEach((function(e){var t=Ut.GetAdorner(e);t&&(t.collapsed=!0)}))},t.prototype.restorePagesState=function(){var e=this;setTimeout((function(){e.survey.pages.forEach((function(e){Ut.RestoreStateFor(e)}))}),10)},t.prototype.initDragDropChoices=function(){var e=this;this.dragDropChoices=new o.DragDropChoices(null,this),this.dragDropChoices.onDragStart.add((function(t,o){e.startUndoRedoTransaction("drag drop")})),this.dragDropChoices.onDragEnd.add((function(t,o){e.stopUndoRedoTransaction(),e.selectElement(o.draggedElement,void 0,!1)})),this.dragDropChoices.onShortcutCreated=function(t){Object.keys(e.designTabSurveyThemeVariables).forEach((function(o){t.style.setProperty(o,e.designTabSurveyThemeVariables[o])}))}},t.prototype.updateElementsOnLocaleChanged=function(e,t){if("survey"===e.getType()&&"locale"===t)for(var o=this.survey.pages,i=0;i<o.length;i++)o[i].locStrsChanged()},t.prototype.updateConditionsOnNameChanged=function(e,t,o){if(this.isObjQuestion(e)){if("name"!==t||e.valueName||this.updateLogicOnQuestionNameChanged(o,e.name),"valueName"===t){var i=o||e.name,n=e.valueName?e.valueName:e.name;this.updateLogicOnQuestionNameChanged(i,n)}"name"===t&&e.isDescendantOf("selectbase")&&this.updateChoicesFromQuestionOnColumnNameChanged(o,e.name)}"name"===t&&e.isDescendantOf("matrixdropdowncolumn")&&this.updateLogicOnColumnNameChanged(e,o,e.name)},t.prototype.getSurveyLogicForUpdate=function(){return this.surveyLogicForUpdate&&this.surveyLogicForUpdate.survey!==this.survey&&(this.surveyLogicForUpdate=void 0),this.surveyLogicForUpdate||(this.surveyLogicForUpdate=this.createSurveyLogicForUpdate()),this.surveyLogicForUpdate},t.prototype.clearSurveyLogicForUpdate=function(e,t,o){!this.surveyLogicRenaming&&this.surveyLogicForUpdate&&e&&t&&this.needClearSurveyLogicForUpdate(e,t,o)&&(this.surveyLogicForUpdate=void 0)},t.prototype.needClearSurveyLogicForUpdate=function(e,t,i){if(Array.isArray(i))return!0;var n=o.Serializer.findProperty(e.getType(),t);return!!n&&["expression","condition","questionvalue","question"].indexOf(n.type)>-1},t.prototype.updateSurveyLogicValues=function(e,t,i){e&&t&&!o.Helpers.isValueEmpty(i)&&"value"===t&&e.isDescendantOf("itemvalue")&&this.updateSurveyLogicItemValue(e,i)},t.prototype.updateSurveyLogicItemValue=function(e,t){if(e.locOwner&&i.logic.updateExpressionsOnChanging.choiceValue&&!(["choices","rateValues","columns","rows"].indexOf(e.ownerPropertyName)<0)){this.surveyLogicRenaming=!0;var o=this.getSurveyLogicForUpdate();"rows"===e.ownerPropertyName?o.renameRowValue(e,t):o.renameItemValue(e,t),this.surveyLogicRenaming=!1}},t.prototype.createSurveyLogicForUpdate=function(){return new Ue(this.survey,this)},t.prototype.updateLogicOnQuestionNameChanged=function(e,t){e!==t&&i.logic.updateExpressionsOnChanging.questionName&&(this.surveyLogicRenaming=!0,this.getSurveyLogicForUpdate().renameQuestion(e,t),this.surveyLogicRenaming=!1)},t.prototype.updateLogicOnColumnNameChanged=function(e,t,o){t&&t!==o&&i.logic.updateExpressionsOnChanging.columnName&&(this.surveyLogicRenaming=!0,this.getSurveyLogicForUpdate().renameColumn(e,t),this.surveyLogicRenaming=!1)},t.prototype.updateChoicesFromQuestionOnColumnNameChanged=function(e,t){this.getAllQuestions().forEach((function(o){o.choicesFromQuestion===e&&(o.choicesFromQuestion=t)}))},t.prototype.isObjQuestion=function(e){return this.isObjThisType(e,"question")},t.prototype.isObjPage=function(e){return this.isObjThisType(e,"page")},t.prototype.isObjThisType=function(e,t){for(var i=o.Serializer.findClass(e.getType());i&&i.parentName;){if(i.name===t)return!0;i=o.Serializer.findClass(i.parentName)}return!!i&&i.name===t},t.prototype.onDragDropItemStart=function(){this.addNewElementReason="DROPPED_FROM_TOOLBOX"},t.prototype.doOnQuestionAdded=function(e,t){e.name=this.generateUniqueName(e,e.name);var o={question:e,page:this.getPageByElement(e),reason:this.addNewElementReason};this.addNewElementReason=void 0,this.onQuestionAdded.fire(this,o)},t.prototype.doOnPanelAdded=function(e,t){var o={panel:e,page:this.getPageByElement(e),reason:this.addNewElementReason};this.onPanelAdded.fire(this,o),this.addNewElementReason=void 0},t.prototype.doOnPageAdded=function(e){var t={page:e};this.onPageAdded.fire(this,t),this.setModified({type:"PAGE_ADDED",newValue:t.page})},t.prototype.getPageByElement=function(e){return this.survey.getPageByElement(e)},t.prototype.getDefaultSurveyJson=function(){var e=i.defaultNewSurveyJSON;return e.pages&&e.pages.length>0&&e.pages[0].name&&(e.pages[0].name=G.getString("ed.newPageName")+"1"),e},t.prototype.setSurvey=function(e){this.surveyValue&&this.surveyValue.dispose(),this.surveyValue=e,this.selectElement(e),this.selectionHistoryController.reset()},t.prototype.getSurveyTextFromDesigner=function(){if(!this.survey)return"";var e=this.survey.toJSON();e=this.singlePageJSON(e),this.moveElementsToTheEnd(e);var t=i.jsonEditor.indentation;return this.generateValidJSON?JSON.stringify(e,null,t):(new X).stringify(e,null,t)},t.prototype.moveElementsToTheEnd=function(e){var t=this;if(e)if(Array.isArray(e))e.forEach((function(e){return t.moveElementsToTheEnd(e)}));else if("object"==typeof e){if(e.elements){var o=e.elements;delete e.elements,e.elements=o}Object.keys(e).forEach((function(o){return t.moveElementsToTheEnd(e[o])}))}},t.prototype.setTextValue=function(e){this.setSurveyJSONTextCallback&&this.setSurveyJSONTextCallback(e)},t.prototype.changeText=function(e,t){if(void 0===t&&(t=!1),this.setTextValue(e),e){var o=new ce(e);o.isJsonCorrect||o.survey?this.initSurveyWithJSON(o.survey.toJSON(),t):this.viewType="editor"}else this.initSurveyWithJSON(void 0,t)},Object.defineProperty(t.prototype,"text",{get:function(){return this.getSurveyJSONTextCallback?this.getSurveyJSONTextCallback().text:this.getSurveyTextFromDesigner()},set:function(e){this.changeText(e,!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"designTabSurveyThemeVariables",{get:function(){return Mi.cssVariables},enumerable:!1,configurable:!0}),t.prototype.getSurveyJSON=function(){if("editor"!=this.viewType)return(new o.JsonObject).toJsonObject(this.survey);var e=this.text,t=new ce(e);return t.isJsonCorrect?(new o.JsonObject).toJsonObject(t.survey):null},t.prototype.getObjectDisplayName=function(e,t,o,i){void 0===o&&(o=void 0),void 0===i&&(i=void 0),i||(i=ee.getObjectName(e,this.showObjectTitles));var n={obj:e,displayName:i,area:t,reason:o};return this.onGetObjectDisplayName.fire(this,n),n.displayName},t.prototype.createSurvey=function(e,t,o,i,n){var r,a=this.createSurveyCore(e,t);return"designer"!==t&&"test"!==t&&"theme"!==t&&(a.fitToContainer=!1,a.applyTheme(Mi),a.gridLayoutEnabled=!1),"designer"!==t&&"modal-question-editor"!==t||Ui(a,this),a.needRenderIcons=!1,"designer"!=t&&"test"!=t&&"theme"!==t&&(a.locale=G.currentLocale,e.clearInvisibleValues||(a.clearInvisibleValues="onComplete")),i&&i(a),n=n||this.getSurveyInstanceCreatedArea(t),this.onSurveyInstanceCreated.fire(this,{survey:a,reason:t,area:n,model:o||(null===(r=this.currentPlugin)||void 0===r?void 0:r.model),obj:"property-grid"===n&&o?o.obj:void 0}),"designer"===t&&this.onDesignerSurveyCreated.fire(this,{survey:a}),"test"!==t&&"theme"!==t||this.onPreviewSurveyCreated.fire(this,{survey:a}),a},t.prototype.getSurveyInstanceCreatedArea=function(e){return{designer:"designer-tab",test:"preview-tab","default-value":"default-value-popup-editor","condition-builder":"logic-rule:condition-editor","logic-item-editor":"logic-rule:action-editor","logic-items":"logic-tab:condition-list",theme:"theme-tab",translation_settings:"translation-tab:language-list",translation_strings:"translation-tab:table",translation_strings_header:"translation-tab:table-header","cells-editor":"matrix-cell-values-popup-editor","fast-entry":"table-values-popup-editor","modal-question-editor":"matrix-cell-question-popup-editor"}[e]||e},t.prototype.createSurveyCore=function(e,t){return void 0===e&&(e={}),new o.SurveyModel(e)},Object.defineProperty(t.prototype,"state",{get:function(){return this._stateValue?this._stateValue:""},enumerable:!1,configurable:!0}),t.prototype.setState=function(e){this._stateValue=e,this.onStateChanged.fire(this,{val:e}),e&&(this.notify(this.getLocString("ed."+e)),this._updateSaveActions())},t.prototype.setModified=function(e){void 0===e&&(e=null),this.setState("modified"),this.onModified.fire(this,e),this.isAutoSave&&this.doAutoSave()},t.prototype.notifySurveyPropertyChanged=function(e){this.clearSurveyLogicForUpdate(e.target,e.name,e.newValue),this.updateSurveyLogicValues(e.target,e.name,e.oldValue);var t=this.currentPlugin;t&&t.onDesignerSurveyPropertyChanged&&t.onDesignerSurveyPropertyChanged(e.target,e.name),this.onSurveyPropertyValueChanged.isEmpty||(e.propertyName=e.name,e.obj=e.target,e.value=e.newValue,this.onSurveyPropertyValueChanged.fire(this,e)),e.type="PROPERTY_CHANGED",this.setModified(e)},t.prototype.notifySurveyItemMoved=function(e){e.type="ELEMENT_REORDERED",this.setModified(e)},t.prototype.notify=function(e,t){void 0===t&&(t="info"),this.onNotify.isEmpty?this.notifier.notify(e,t):this.onNotify.fire(this,{message:e,type:t})},t.prototype.convertQuestion=function(e,t,o){void 0===o&&(o=null);var i=$.getObjJSON(e,this.getDefaultElementJSON(e.getType())),n={sourceQuestion:e,targetType:t,json:i};this.onQuestionConverting.fire(this,n);var r=$.convertObject(e,t,n.json,this.getDefaultElementJSON(t),o);return this.setModified({type:"QUESTION_CONVERTED",className:t,oldValue:e,newValue:r}),r},t.prototype.getDefaultElementJSON=function(e){var t;if(!this.toolbox)return null;var i=null===(t=this.toolbox.getItemByName(e))||void 0===t?void 0:t.json;return i?o.Helpers.createCopy(i):null},t.prototype.singlePageJSON=function(e){if("single"===this.pageEditMode){var t=e.pages;Array.isArray(t)&&t.length>0&&(void 0!==t[0].elements&&(e.elements=t[0].elements),delete e.pages)}return e},Object.defineProperty(t.prototype,"JSON",{get:function(){var e=this.survey.toJSON();return this.singlePageJSON(e)},set:function(e){"editor"==this.viewType?this.setTextValue(JSON.stringify(e)):this.initSurveyWithJSON(e,!0)},enumerable:!1,configurable:!0}),t.prototype.loadSurvey=function(e){var t=this;(new o.dxSurveyService).loadSurvey(e,(function(e,o,i){e&&o&&(t.JSON=o)}))},t.prototype.doClickQuestionCore=function(e,t,o,i){void 0===t&&(t="ADDED_FROM_TOOLBOX"),void 0===o&&(o=-1),void 0===i&&(i=null),0==this.survey.pageCount&&this.addNewPageIntoSurvey();var n=this.currentPage;"bypage"===this.pageEditMode&&(n=this.getPlugin("designer").model.pagesController.page2Display);var r=this.getSelectedSurveyElement();if(r&&r.parent&&r.page==n&&r!==i){if(!i)for(;r.parent&&r.parent.isPanel;)r=r.parentQuestion?r.parentQuestion:r.parent;n=r.parent,o<0&&(this.addNewQuestionLast&&"ADDED_FROM_PAGEBUTTON"===t?o=n.elements.length:(o=n.elements.indexOf(r))>-1&&o++)}i&&(n=i),this.addNewElementReason=t;var a=this.findRowByElement(r,n);e.setVisibleIndex(-1),a&&this.isRowMultiline(a)?this.addElemenMultiline(n,e,o,a):n.addElement(e,o),this.addNewElementReason="",this.setModified({type:t,question:e})},t.prototype.isRowMultiline=function(e){return e.elements.length>1},t.prototype.findRowByElement=function(e,t){return e?e.isPage?e.rows[e.rows.length-1]:t.rows.find((function(t){return-1!==t.elements.indexOf(e)})):null},t.prototype.addElemenMultiline=function(e,t,o,i){var n=i.elements.length,r=i.elements[n-1];r.startWithNewLine=!0,e.addElement(t,o),r.startWithNewLine=!1},t.prototype.setNewNames=function(e){this.newQuestions=[],this.newPanels=[],this.newQuestionChangedNames={},this.setNewNamesCore(e),this.updateNewElementExpressions(e)},t.prototype.updateNewElementExpressions=function(e){var t=this.createSurvey({},"updateNewElementExpressions",void 0,(function(t){t.setDesignMode(!0),e.isPage?t.addPage(e):(t.addNewPage("p1"),t.pages[0].addElement(e))})),o=new Ue(t);for(var i in this.newQuestionChangedNames)o.renameQuestion(i,this.newQuestionChangedNames[i])},t.prototype.getAllQuestions=function(e){return void 0===e&&(e=!0),this.getAllElements(!1,e)},t.prototype.getAllPanels=function(e){return void 0===e&&(e=!0),this.getAllElements(!0,e)},t.prototype.getAllElements=function(e,t){var o=ee.getAllElements(this.survey,e);return t&&(ee.addElements(this.newPanels,e,o),ee.addElements(this.newQuestions,e,o)),o},t.prototype.getNewName=function(e,t){return"page"==e?ee.getNewPageName(this.survey.pages):t?this.getNewPanelName():this.getNewQuestionName()},t.prototype.getNewQuestionName=function(){return ee.getNewQuestionName(this.getAllQuestions())},t.prototype.getNewPanelName=function(){return ee.getNewPanelName(this.getAllPanels())},t.prototype.setNewNamesCore=function(e){var t=this,o=e.getType(),i=this.getNewName(o,e.isPanel);if(i!=e.name&&(this.newQuestionChangedNames[e.name]=i,e.name=i),e.isPanel||e.isPage)e.isPanel&&this.newPanels.push(e),e.elements.forEach((function(e){return t.setNewNamesCore(e)}));else{this.newQuestions.push(e);var n=Array.isArray(e.templateElements)?e.templateElements:Array.isArray(e.detailElements)?e.detailElements:void 0;n&&n.forEach((function(e){return t.setNewNamesCore(e)}))}},t.prototype.createNewElement=function(e){var t=o.Serializer.createClass(e.type);(new o.JsonObject).toObject(e,t);var i=!0;return e.name&&(i=t.isPage?!!this.survey.getPageByName(t.name):t.isPanel?!!this.survey.getPanelByName(t.name):!!this.survey.getQuestionByName(t.name)),i&&this.setNewNames(t),t},t.prototype.copyElement=function(e){var t=(new o.JsonObject).toJsonObject(e);return t.type=e.getType(),this.createNewElement(t)},t.prototype.fastCopyQuestion=function(e,t){var o=this.copyElement(e),i=e.parent?e.parent.elements.indexOf(e)+1:-1;if(i>-1){var n=e.parent.elements;i<n.length&&!1===n[i].startWithNewLine&&(o.startWithNewLine=!1)}return this.doClickQuestionCore(o,"ELEMENT_COPIED",i,e.parent),t&&this.selectElement(o),o},Object.defineProperty(t.prototype,"selectedElement",{get:function(){return this.selectedElementValue},set:function(e){this.selectElement(e)},enumerable:!1,configurable:!0}),t.prototype.refreshDesigner=function(){"designer"===this.activeTab&&this.changeText(this.text)},t.prototype.deleteCurrentObject=function(){this.deleteCurrentElement()},t.prototype.deleteCurrentElement=function(){this.deleteObject(this.selectedElement)},t.prototype.deleteElement=function(e){this.deleteObject(e)},t.prototype.copyPage=function(e){var t=this,o=this.copyElement(e),i=this.survey.pages.indexOf(e);i>-1?this.survey.pages.splice(i+1,0,o):this.survey.pages.push(o),o.questions.forEach((function(e){t.addNewElementReason="ELEMENT_COPIED",t.doOnQuestionAdded(e,e.parent)}));var n=o.getPanels();return Array.isArray(n)&&n.forEach((function(e){return t.doOnPanelAdded(e,e.parent)})),this.addNewElementReason="",o},t.prototype.deleteObjectCore=function(e){if(e.isPage){var t=this.getNextPage(e);this.survey.removePage(e),this.selectElement(t||this.survey)}else{if(1===this.survey.pageCount){var o=this.survey.pages[0];if(1===o.elements.length&&e===o.elements[0]&&!ee.isPagePropertiesAreModified(o))return void this.deleteObjectCore(o)}this.deletePanelOrQuestion(e)}this.setModified({type:"OBJECT_DELETED",target:e}),this.updateConditionsOnRemove(e)},t.prototype.getNextPage=function(e){var t=this.survey.pages.indexOf(e);return t<0||1==this.survey.pages.length?null:(t==this.survey.pages.length-1?t--:t++,t<0||t>this.survey.pages.length-1?null:this.survey.pages[t])},t.prototype.deleteObject=function(e){this.checkOnElementDeleting(e)&&this.deleteObjectCore(e)},t.prototype.updateConditionsOnRemove=function(e){if(i.logic.updateExpressionsOnDeleting.question){if(ee.getObjectType(e)==Y.Question)t=[e];else var t=e.questions;if(t)for(var o=new Ue(this.survey,this),n=0;n<t.length;n++)o.removeQuestion(t[n].getValueName())}},t.prototype.checkOnElementDeleting=function(e){var t={element:e,elementType:ee.getObjectType(e),allowing:!0};return this.onElementDeleting.fire(this,t),t.allowing},t.prototype.isElementSelected=function(e){return!(!e||e.isDisposed)&&e.getPropertyValue("isSelectedInDesigner")},t.prototype.selectElement=function(e,t,o,i){if(void 0===o&&(o=!0),void 0===i&&(i=!1),!e||!e.isDisposed&&e.getSurvey()&&(!e.isQuestion&&!e.isPanel||e.parent)){var n=this.selectedElement;n!==e&&(this.selectedElementValue=this.onSelectingElement(e),n!==this.selectedElementValue&&(n&&!n.isDisposed&&n.setPropertyValue("isSelectedInDesigner",!1),this.selectedElementValue&&this.selectedElementValue.setPropertyValue("isSelectedInDesigner",!0))),(n!==e||t)&&this.selectionChanged(this.selectedElement,t,!!o);var r=this.getSelectedSurveyElement();n!==e&&document&&r&&this.focusElement(e,o,r,t,i)}},t.prototype.focusElement=function(e,t,o,i,n){var r=this;void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),o||(o=this.getSelectedSurveyElement()),o&&(clearInterval(this.currentFocusInterval),clearTimeout(this.currentFocusTimeout),this.currentFocusTimeout=setTimeout((function(){r.currentFocusInterval=setInterval((function(){var a,s,l=document.getElementById(o.id);if(o&&(t||n&&(!o.hasTitle||o.isPanel))){if(!l||r.rootElement.getAnimations({subtree:!0}).filter((function(e){return e.effect.getComputedTiming().activeDuration!==1/0&&(e.pending||"finished"!==e.playState)}))[0])return;if(clearInterval(r.currentFocusInterval),l){if(ee.isNeedScrollIntoView(null!==(a=l.parentElement)&&void 0!==a?a:l,!0)){var u=r.getPageByElement(o),p={block:"start",behavior:r.animationEnabled?"smooth":void 0};u?r.survey.scrollElementToTop(o,void 0,u,o.id,!0,p,r.rootElement):ee.scrollIntoViewIfNeeded(null!==(s=l.parentElement)&&void 0!==s?s:l,(function(){return p}),!0)}if(!i&&l.parentElement){var c="string"==typeof t?l.parentElement.querySelector(t):l.parentElement;c&&c.focus({preventScroll:!0})}}}else clearInterval(r.currentFocusInterval);n&&e&&Go.get(e.locTitle).activateEditor()}),1)}),100))},t.prototype.getSelectedSurveyElement=function(){var e=this.selectedElement;return e&&"survey"!=e.getType()&&e.isInteractiveDesignElement&&e.id?e:null},t.prototype.onSelectingElement=function(e){var t={newSelectedElement:e};return this.onSelectedElementChanging.fire(this,t),t.newSelectedElement},Object.defineProperty(t.prototype,"designerPropertyGrid",{get:function(){var e=this.sidebar.getPageById(this.sidebar.activePage);return e&&e.componentData?e.componentData.propertyGridModel:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"propertyGrid",{get:function(){return this.designerPropertyGrid.survey},enumerable:!1,configurable:!0}),t.prototype.collapsePropertyGridCategory=function(e){this.designerPropertyGrid&&this.designerPropertyGrid.collapseCategory(e)},t.prototype.expandPropertyGridCategory=function(e){this.designerPropertyGrid&&this.designerPropertyGrid.expandCategory(e)},t.prototype.collapseAllPropertyGridCategories=function(){this.designerPropertyGrid&&this.designerPropertyGrid.collapseAllCategories()},t.prototype.expandAllPropertyGridCategories=function(){this.designerPropertyGrid&&this.designerPropertyGrid.expandAllCategories()},t.prototype.collapseAllPropertyTabs=function(){this.collapseAllPropertyGridCategories()},t.prototype.expandAllPropertyTabs=function(){this.expandAllPropertyGridCategories()},t.prototype.expandPropertyTab=function(e){this.expandPropertyGridCategory(e)},t.prototype.collapsePropertyTab=function(e){this.collapsePropertyGridCategory(e)},t.prototype.validateSelectedElement=function(){var e=!0;return this.selectedElement?(this.designerPropertyGrid&&(e=this.designerPropertyGrid.validate()),e):e},t.prototype.deleteLocaleStrings=function(e){new Wt(this.survey).deleteLocaleStrings(e)},t.prototype.getPropertyGridDefinition=function(){return this.propertyGridDefinition},t.prototype.setPropertyGridDefinition=function(e){this.propertyGridDefinition=e,this.designerPropertyGrid&&this.designerPropertyGrid.setPropertyGridDefinition(e)},t.prototype.getPropertyGridExpandedCategory=function(){if(this.designerPropertyGrid){for(var e=this.designerPropertyGrid.survey.getAllPanels(),t=0;t<e.length;t++)if(e[t].isExpanded)return e[t].name;return""}},t.prototype.expandCategoryIfNeeded=function(){var e=i.propertyGrid.defaultExpandedTabName;if(e&&!this.getPropertyGridExpandedCategory()&&!this.survey.isEmpty){var t=this.designerPropertyGrid.survey.getPanelByName(e);t&&(t.blockAnimations(),t.expand(),t.releaseAnimations())}},t.prototype.selectionChanged=function(e,t,o){var i=this;void 0===o&&(o=!0),this.survey.currentPage=this.getCurrentPageByElement(e),this.selectionHistoryController.onObjSelected(e),this.designerPropertyGrid&&(this.designerPropertyGrid.obj=e,t||(t=this.designerPropertyGrid.currentlySelectedProperty),t&&this.sidebar.executeOnExpand((function(){i.designerPropertyGrid.selectProperty(t,o||!i.selectFromStringEditor)})),this.expandCategoryIfNeeded(),this.selectFromStringEditor=!1);var n={newSelectedElement:e};this.onSelectedElementChanged.fire(this,n)},t.prototype.getCurrentPageByElement=function(e){if(e)return e.isPage?e:e.page?e.page:e.parentQuestion?this.getCurrentPageByElement(e.parentQuestion):void 0},t.prototype.clickToolboxItem=function(e,t,o){void 0===t&&(t=null),void 0===o&&(o="ADDED_FROM_TOOLBOX"),this.readOnly||(void 0===e.getType&&(e=this.createNewElement(e)),this.survey.lazyRendering=!1,this.doClickQuestionCore(e,o,-1,t),this.selectElement(e,null,!this.toolbox.searchManager.filterString,this.startEditTitleOnQuestionAdded))},t.prototype.getJSONForNewElement=function(e){var t=this.createNewElement(e);return(e=t.toJSON()).type=t.getType(),e},t.prototype.chooseFiles=function(e,t,i){this.onOpenFileChooser.isEmpty?(0,o.chooseFiles)(e,t):this.onOpenFileChooser.fire(this,{input:e,element:i&&i.element||this.survey,elementType:i&&i.elementType,item:i&&i.item,propertyName:i&&i.propertyName,callback:t,context:i})},t.prototype.uploadFiles=function(e,t,o,i){if(this.onUploadFile.isEmpty){var n=new FileReader;n.onload=function(e){o("success",n.result)},n.readAsDataURL(e[0])}else this.onUploadFile.fire(this,{question:t,files:e||[],callback:o,element:i&&i.element||this.survey,elementType:i&&i.elementType,propertyName:i&&i.propertyName,context:i})},Object.defineProperty(t.prototype,"rootElement",{get:function(){return this._rootElementValue},enumerable:!1,configurable:!0}),t.prototype.setRootElement=function(e){this._rootElementValue=e,this.initKeyboardShortcuts(e),this.initResponsivityManager(e)},t.prototype.unsubscribeRootElement=function(){this.removeKeyboardShortcuts(this._rootElementValue),this.resetResponsivityManager()},t.prototype.initKeyboardShortcuts=function(e){e&&e.addEventListener("keydown",this.onKeyDownHandler)},t.prototype.removeKeyboardShortcuts=function(e){e&&e.removeEventListener("keydown",this.onKeyDownHandler)},t.prototype.findSuitableShortcuts=function(e){var t=this,o=[];return Object.keys(this.shortcuts||{}).map((function(e){return t.shortcuts[e]})).filter((function(e){return!e.affectedTab||e.affectedTab===t.activeTab})).forEach((function(t){var i=e.metaKey?t.macOsHotkey:t.hotKey;i&&!!i.ctrlKey==!!e.ctrlKey&&!!i.shiftKey==!!e.shiftKey&&i.keyCode===e.keyCode&&o.push(t)})),o},t.prototype.registerShortcut=function(e,t){this.shortcuts[e]=t},t.prototype.unRegisterShortcut=function(e){delete this.shortcuts[e]},t.prototype.deletePanelOrQuestion=function(e){var t=this,o=e===this.selectedElement,i=e.parent,n=i.elements,r=n.indexOf(e);r==n.length-1&&r--,e.questions&&e.questions.forEach((function(e){return t.updateConditionsOnRemove(e)})),e.delete(!1),!i.isPage||"single"!==this.pageEditMode&&0!==n.length||(i=this.survey),o&&this.selectElement(r>-1?n[r]:i)},t.prototype.onCanShowObjectProperty=function(e,t,o,i,n){if(this.hiddenProperties[t.id])return!1;var r={obj:e,property:t,canShow:!0,showMode:o,parentObj:i,parentProperty:n};return this.onCanShowProperty.fire(this,r),r.canShow},t.prototype.canDeleteItem=function(e,t,o){var i={obj:e,item:t,canDelete:o};return this.onCanDeleteItem.fire(this,i),i.canDelete},t.prototype.getErrorOnPropertyChanging=function(e,t,o){return"name"!==t||ee.getObjectType(e)===Y.Unknown?null:(ee.getObjectType(e)===Y.Column?e.colOwner&&!this.isNameUniqueInArray(e.colOwner.columns,e,o):this.generateUniqueName(e,o)!==o)?this.getLocString("pe.propertyNameIsNotUnique"):null},t.prototype.generateUniqueName=function(e,t){var o={element:e,name:t,isDone:!0},i=[];do{if(this.generateUniqueNameCore(o),!o.isDone&&i.indexOf(o.name)>-1){o.name=this.checkForUniqueName(e,o.name);break}i.push(o.name)}while(!o.isDone);return o.name},t.prototype.generateUniqueNameCore=function(e){e.name=this.checkForUniqueName(e.element,e.name);var t={element:e.element,name:e.name};this.onGenerateNewName.fire(this,t),e.name!==t.name&&(e.name=t.name,e.name=this.checkForUniqueName(e.element,e.name),e.isDone=e.name===t.name)},t.prototype.checkForUniqueName=function(e,t){for(;!this.isNameUnique(e,t,!1);)t=ee.generateNewName(t);return t},t.prototype.isNameUnique=function(e,t,o){return void 0===o&&(o=!0),!!this.isNameUniqueInArray(this.survey.pages,e,t)&&!!this.isNameUniqueInArray(this.getAllPanels(o),e,t)&&this.isNameUniqueInArray(this.getAllQuestions(o),e,t)},t.prototype.isNameUniqueInArray=function(e,t,o){if(!Array.isArray(e))return!0;o=o.toLowerCase();for(var i=0;i<e.length;i++)if(e[i]!=t&&e[i].name.toLowerCase()==o)return!1;return!0},t.prototype.doPropertyGridChanged=function(){},Object.defineProperty(t.prototype,"alwaySaveTextInPropertyEditors",{get:function(){return this.alwaySaveTextInPropertyEditorsValue},set:function(e){this.alwaySaveTextInPropertyEditorsValue=e},enumerable:!1,configurable:!0}),t.prototype.getElementAddornerCssCallback=function(e,t){return t},t.prototype.onCanShowPropertyCallback=function(e,t,o,i,n){return void 0===o&&(o=null),this.onCanShowObjectProperty(e,t,o,i,n)},t.prototype.onPropertyGridSurveyCreatedCallback=function(e,t){var o={obj:e,survey:t};this.onPropertyGridSurveyCreated.fire(this,o)},t.prototype.onPropertyEditorCreatedCallback=function(e,t,o){var i={obj:e,property:t,editor:o};this.onPropertyEditorCreated.fire(this,i)},t.prototype.onPropertyEditorUpdateTitleActionsCallback=function(e,t,o,i){var n={obj:e,property:t,editor:o,titleActions:i};this.onPropertyEditorUpdateTitleActions.fire(this,n)},t.prototype.onPropertyGridShowModalCallback=function(e,t,o,i,n){var r={obj:e,property:t,editor:o,popupEditor:i,popupModel:n};this.onPropertyGridShowModal.fire(this,r)},t.prototype.onCanDeleteItemCallback=function(e,t,o){if(t&&t.isPage){if("bypage"===this.pageEditMode)return t!==this.survey.currentPage;if("single"===this.pageEditMode)return!1}return this.canDeleteItem(e,t,o)},t.prototype.onCollectionItemDeletingCallback=function(e,t,o,i){if((null==i?void 0:i.isPage)&&!this.checkOnElementDeleting(i))return!1;if(this.onCollectionItemDeleting.isEmpty)return!0;var n={obj:e,property:t,propertyName:t.name,collection:o,item:i,allowDelete:!0};return this.onCollectionItemDeleting.fire(this,n),n.allowDelete},t.prototype.onCollectionItemAllowingCallback=function(e,t,o,i,n){if(!this.onCollectionItemAllowOperations.isEmpty){var r={obj:e,property:t,propertyName:t&&t.name,collection:o,item:i,allowEdit:n.allowEdit,allowDelete:n.allowDelete,allowAdd:n.allowAdd};this.onCollectionItemAllowOperations.fire(this,r),n.allowEdit=r.allowEdit,n.allowDelete=r.allowDelete,n.allowAdd=r.allowAdd}},t.prototype.onItemValueAddedCallback=function(e,t,o,i){var n={obj:e,propertyName:t,newItem:o,itemValues:i};this.onItemValueAdded.fire(this,n)},t.prototype.onFastEntryCallback=function(e,t){var o={items:e,lines:t};return this.onFastEntryFinished.fire(this,o),o.items},t.prototype.onMatrixDropdownColumnAddedCallback=function(e,t,o){var i={newColumn:t,matrix:e,columns:o};this.onMatrixColumnAdded.fire(this,i)},t.prototype.onSetPropertyEditorOptionsCallback=function(e,t,o){var i={propertyName:e,obj:t,editorOptions:o,allowAddRemoveItems:o.allowAddRemoveItems,allowRemoveAllItems:o.allowRemoveAllItems,allowBatchEdit:o.allowBatchEdit},n=["allowAddRemoveItems","allowRemoveAllItems","allowBatchEdit"];n.forEach((function(e){return i[e]=o[e]})),this.onSetPropertyEditorOptions.fire(this,i),this.onConfigureTablePropertyEditor.fire(this,i),n.forEach((function(e){return o[e]=o[e]&&i[e]}))},t.prototype.onGetErrorTextOnValidationCallback=function(e,t,o){var i=this.getErrorOnPropertyChanging(t,e,o);if(i)return i;var n={propertyName:e,obj:t,value:o,error:""};return this.onPropertyValidationCustomError.fire(this,n),n.error},t.prototype.onValueChangingCallback=function(e){this.onPropertyValueChanging.fire(this,e)},t.prototype.onGetElementEditorTitleCallback=function(e,t){return t},t.prototype.onConditionQuestionsGetListCallback=function(e,t,o,n,r){if(this.onConditionQuestionsGetList.isEmpty)return i.logic.questionSortOrder;var a={propertyName:e,obj:t,editor:o,sortOrder:"asc",list:n,variables:r};if(this.onConditionQuestionsGetList.fire(this,a),a.list!==n){n.splice(0,n.length);for(var s=0;s<a.list.length;s++)n.push(a.list[s])}return a.sortOrder},t.prototype.onConditionGetTitleCallback=function(e,t){var o={expression:e,title:t};return this.onConditionGetTitle.fire(this,o),o.title},t.prototype.isConditionOperatorEnabled=function(e,t,o,i){if(this.onGetConditionOperator.isEmpty)return i;var n={questionName:e,question:t,questionType:t?t.getType():"",operator:o,show:i};return this.onGetConditionOperator.fire(this,n),n.show},t.prototype.onLogicGetTitleCallback=function(e,t,o,i){if(this.onLogicItemDisplayText.isEmpty)return o;var n={expression:e,expressionText:t,text:o,logicItem:i};return this.onLogicItemDisplayText.fire(this,n),n.text},t.prototype.getProcessedTranslationItemText=function(e,t,o,i){if(this.onTranslationItemChanging.isEmpty)return o;var n={locale:e,obj:i,locString:t,newText:o};return this.onTranslationItemChanging.fire(this,n),n.newText},t.prototype.getTranslationExportedText=function(e,t,o,i,n){if(this.onTranslationExportItem.isEmpty)return n;var r={obj:e,name:t,locString:o,locale:i,text:n};return this.onTranslationExportItem.fire(this,r),r.text},t.prototype.getHasMachineTranslation=function(){return!this.onMachineTranslate.isEmpty},t.prototype.doMachineTranslation=function(e,t,o,i){this.getHasMachineTranslation()?this.onMachineTranslate.fire(this,{fromLocale:e,toLocale:t,strings:o,callback:i}):i(void 0)},t.prototype.doAutoSave=function(){var e=this,t=function(){return e.doSave()};if(this.autoSaveDelay<=0)t();else{this.autoSaveTimerId&&clearTimeout(this.autoSaveTimerId);var o=this;this.autoSaveTimerId=setTimeout((function(){clearTimeout(o.autoSaveTimerId),o.autoSaveTimerId=null,t()}),this.autoSaveDelay)}},t.prototype._doSaveCore=function(e){var t=this;this.setState("saving"),this.saveSurveyFunc&&(this.saveNo++,this.saveSurveyFunc(this.saveNo,(function(o,i){t.saveNo===o&&(i?t.setState("saved"):(t.setState("modified"),t.showErrorOnFailedSave&&t.notify(t.getLocString("ed.saveError"),"error")),e&&e())})))},t.prototype.saveSurvey=function(){this._doSaveCore()},t.prototype.doSave=function(){this._doSaveCore()},t.prototype.saveSurveyActionHandler=function(){this.syncSaveButtons?this.save():this.saveSurvey()},t.prototype._updateSaveActions=function(){var e=this._findAction("svd-save");if(e&&(e.enabled="modified"===this.state,e.active="modified"===this.state),this.syncSaveButtons){var t=this._findAction("svd-save-theme");t&&(t.enabled=this.hasPendingThemeChanges,t.active=this.hasPendingThemeChanges)}},t.prototype.save=function(){var e=this,t=function(){e.hasPendingThemeChanges&&e._doSaveThemeCore((function(){e._updateSaveActions()}))};"modified"===this.state?this._doSaveCore((function(){t()})):t()},Object.defineProperty(t.prototype,"saveSurveyFunc",{get:function(){return this.saveSurveyFuncValue},set:function(e){this.saveSurveyFuncValue=e,this.showSaveButton=null!=e&&!this.isAutoSave},enumerable:!1,configurable:!0}),t.prototype.convertCurrentQuestion=function(e,t){void 0===t&&(t=null);var o=this.selectedElement;if(o&&(o.getType()!==e||t)){var i=ee.getObjectType(o);i!==Y.Question&&i!==Y.Panel||(this.addNewElementReason="ELEMENT_CONVERTED",o=this.convertQuestion(o,e,t),this.selectElement(o,null,"#convertTo button"))}},t.prototype.getAddNewQuestionText=function(e){if(void 0===e&&(e=null),e||(e=this.currentAddQuestionType),e){var t=this.getLocString("ed.addNewTypeQuestion"),o=this.toolbox.items.filter((function(t){return t.name==e}));if(Array.isArray(o)&&o.length>0&&t&&t.format)return t.format(o[0].title)}return this.getLocString("ed.addNewQuestion")},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return this.getAddNewQuestionText()},enumerable:!1,configurable:!0}),t.prototype.getAvailableToolboxItems=function(e,t){void 0===t&&(t=!0);var o=[].concat(this.toolbox.items);if(!e||this.maxNestedPanels<0)return o;if(!t&&e.isPanel)return o;if(this.maxNestedPanels<ee.getElementDeepLength(e))for(var i=o.length-1;i>=0;i--)o[i].isPanel&&o.splice(i,1);return o},t.prototype.getQuestionTypeSelectorModel=function(e,t){var i=this,n=t&&t.isPanel?t:null,r=function(t,o){i.currentAddQuestionType=t,i.addNewQuestionInPage(e,n,t,o),s.popupModel.hide()},a=function(){return i.getAvailableToolboxItems(t).map((function(e){return i.createIActionBarItemByClass(e,e.needSeparator,r)}))},s=(0,o.createDropdownActionModel)({iconName:"icon-more",title:this.getLocString("ed.addNewQuestion")},{items:a(),onShow:function(){s.popupModel.contentComponentData.model.setItems(a())},allowSelection:!1,cssClass:"svc-creator-popup",verticalPosition:"bottom",horizontalPosition:"center",displayMode:this.isTouch?"overlay":"popup"});return s},t.prototype.getUpdatedPageAdornerFooterActions=function(e,t){var o={page:e.page,addNewQuestion:function(t){e.addNewQuestion(e,void 0,t)},actions:t};return this.onGetPageActions.fire(this,o),o.actions},t.prototype.addNewQuestionInPage=function(e,t,o,n){void 0===t&&(t=null),void 0===o&&(o=null),void 0===n&&(n=null),o||(o=this.currentAddQuestionType),o||(o=i.designer.defaultAddQuestionType),e(o);var r=n;if(!r){var a=this.toolbox.getItemByName(o);r=a&&a.json?a.json:{type:o}}var s=this.createNewElement(r);this.clickToolboxItem(s,t,"ADDED_FROM_PAGEBUTTON")},t.prototype.createIActionBarItemByClass=function(e,t,i){var n=new o.Action({title:e.title,id:e.name,iconName:e.iconName,visible:e.visible,enabled:e.enabled,needSeparator:t});if(n.action=function(){i(e.typeName,e.json)},e.items&&e.items.length>0&&this.toolbox.showSubitems){var r=e.items.map((function(t){return new o.Action({id:t.id,title:t.title,action:function(){n.hidePopup(),i(e.typeName,t.json)}})}));n.setSubItems({items:r})}return n},t.prototype.onElementMenuItemsChanged=function(e,t){this.onDefineElementMenuItems.fire(this,{obj:e,items:t})},t.prototype.getElementAllowOperations=function(e){var t={obj:e,element:e,allowDelete:!0,allowCopy:!0,allowDragging:!0,allowChangeType:!0,allowChangeInputType:!0,allowChangeRequired:!0,allowShowSettings:void 0,allowEdit:void 0,allowExpandCollapse:void 0};return this.onElementAllowOperations.fire(this,t),t},t.prototype.getChoicesItemBaseTitle=function(){return this.getLocString("ed.choices_Item")||o.surveyLocalization.getString("choices_Item")},t.prototype.getNextItemValue=function(e){return c(this.getChoicesItemBaseTitle(),e.choices)},t.prototype.createNewItemValue=function(e,t,o){void 0===t&&(t=!0);var i=this.getNextItemValue(e),n=e.createItemValue(i);if(n.text=d(e.choices),e.choices.push(n),o&&o(n),t){var r=n.ownerPropertyName?n.ownerPropertyName:"choices";this.onItemValueAddedCallback(e,r,n,e.choices)}return n},t.prototype.onPropertyValueChanged=function(t,o,i){var n=this;e.prototype.onPropertyValueChanged.call(this,t,o,i),"viewType"===t&&this.tabs.forEach((function(e){var t=n.viewType===e.id;e.active=t,e.disableHide=t}))},t.prototype.initResponsivityManager=function(e){this.responsivityManager=new Mo(e,this)},t.prototype.resetResponsivityManager=function(){this.responsivityManager&&(this.responsivityManager.dispose(),this.responsivityManager=void 0)},Object.defineProperty(t.prototype,"showPageNavigator",{get:function(){return this.showPageNavigatorValue&&this.allowShowPageNavigator},set:function(e){this.showPageNavigatorValue=e},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){var t=this;this.isCreatorDisposed=!0,this.tabs=[],Object.keys(this.plugins).forEach((function(e){var o=t.plugins[e];"function"==typeof o.deactivate&&o.deactivate(),"function"==typeof o.dispose&&o.dispose()})),e.prototype.dispose.call(this)},t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-creator").append("svc-creator--mobile",this.isMobileView).append("svc-creator--touch",this.isTouch).append("svc-creator--disable-animations",!this.animationEnabled).toString()},J([(0,o.property)({defaultValue:!0})],t.prototype,"showDesignerTab",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showJSONEditorTab",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showTestSurveyTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showThemeTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showTranslationTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showLogicTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"useTableViewInLogicTab",void 0),J([(0,o.property)({defaultValue:200})],t.prototype,"pageHoverDelay",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"inplaceEditForValues",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"previewShowResults",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isAutoSave",void 0),J([(0,o.property)()],t.prototype,"showOptions",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showSearch",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"generateValidJSON",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),J([(0,o.property)({defaultValue:"landscape"})],t.prototype,"previewOrientation",void 0),J([(0,o.property)()],t.prototype,"surveyValue",void 0),J([(0,o.property)()],t.prototype,"viewType",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowShowToolbox",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showToolboxValue",void 0),J([(0,o.property)()],t.prototype,"showSidebarValue",void 0),J([Co()],t.prototype,"addPage",null),J([wo()],t.prototype,"doOnQuestionAdded",null),J([wo()],t.prototype,"doOnPanelAdded",null),J([wo()],t.prototype,"doOnPageAdded",null),J([Co()],t.prototype,"deleteObject",null),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){var o=t.getPlugin("theme");o&&(e?(t.onModified.add(t._syncSaveActions),o.onThemePropertyChanged.add(t._syncSaveActions),o.onThemeSelected.add(t._syncSaveActions)):(t.onModified.remove(t._syncSaveActions),o.onThemePropertyChanged.remove(t._syncSaveActions),o.onThemeSelected.remove(t._syncSaveActions)))}})],t.prototype,"syncSaveButtons",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showSaveButton",void 0),J([Co()],t.prototype,"convertCurrentQuestion",null),J([Co()],t.prototype,"addNewQuestionInPage",null),J([(0,o.property)({defaultValue:!1})],t.prototype,"showHeaderInEmptySurvey",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowShowPageNavigator",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showPageNavigatorValue",void 0),J([(0,o.property)({getDefaultValue:function(e){return e.showTabsDefault}})],t.prototype,"showTabs",void 0),J([(0,o.property)({getDefaultValue:function(e){return e.showToolbarDefault}})],t.prototype,"showToolbar",void 0),J([(0,o.property)({getDefaultValue:function(){return i.layout.allowCollapseSidebar}})],t.prototype,"allowCollapseSidebar",void 0),J([(0,o.property)({getDefaultValue:function(){return i.designer.showAddQuestionButton}})],t.prototype,"showAddQuestionButton",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.survey.setIsMobile(!!e)}})],t.prototype,"isMobileView",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isTouch",void 0),J([(0,o.property)({defaultValue:"left",onSet:function(e,t){t.toolbox&&(t.toolbox.setLocation(e),t.updateToolboxIsCompact())}})],t.prototype,"toolboxLocation",void 0),J([(0,o.property)({defaultValue:"right"})],t.prototype,"sidebarLocation",void 0),J([(0,o.property)({defaultValue:"never"})],t.prototype,"expandCollapseButtonVisibility",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){if(!e)throw new Error("Creator is disposed")}})],t.prototype,"isCreatorDisposed",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"enableLinkFileEditor",void 0),t}(o.Base),Qi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(Hi),Fi=function(){function e(){}return Object.defineProperty(e,"currentTheme",{get:function(){ee.warnNonSupported("StylesManager")},set:function(e){ee.warnNonSupported("StylesManager")},enumerable:!1,configurable:!0}),e.applyTheme=function(e){ee.warnNonSupported("StylesManager")},e}();function Ui(e,t){e.creator=t,e.isPopupEditorContent=!1,e.onElementWrapperComponentName.add((function(t,o){var i=o.componentName;"component"===o.wrapperName&&(o.componentName=zi(o.element,o.reason,e.isPopupEditorContent)),"content-component"===o.wrapperName&&(o.componentName=Ji(o.element)),"row"===o.wrapperName&&(o.componentName="svc-row"),"itemvalue"===o.wrapperName&&(o.componentName=Ki(o.item,o.element)),o.componentName=o.componentName||i})),e.onElementWrapperComponentData.add((function(e,o){var i=o.data;"component"===o.wrapperName&&(o.data=Wi(o.element,o.reason,t)),"row"===o.wrapperName&&(o.data={creator:t,row:o.element}),"itemvalue"===o.wrapperName&&(o.data=Yi(o.item,o.element,t)),o.data=o.data||i})),e.getRendererForString=function(e,o){if(!t.readOnly&&Xi(e))return Zi},e.getRendererContextForString=function(e,o){return!t.readOnly&&Xi(e,o.name)?{creator:t,element:e,locStr:o}:o}}function Gi(e){for(var t=e;t;){if(t.isContentElement)return!0;t=t.parentQuestion}return!1}var Zi="svc-string-editor";function zi(e,t,i){if("logo-image"===t)return"svc-logo-image";if("cell"===t||"column-header"===t||"row-header"===t){if(Gi(function(e){return e?e.row?e.row.data:e.column?e.column.colOwner:null:null}(e)))return;return"svc-matrix-cell"}if(!Gi(e)){if(e instanceof o.Question){var n=e.isDescendantOf("dropdown")||e.isDescendantOf("tagbox");return i?n?"svc-cell-dropdown-question":"svc-cell-question":e.customWidget?"svc-widget-question":n?"svc-dropdown-question":e.isDescendantOf("image")?"svc-image-question":"svc-question"}if(e instanceof o.PanelModel)return"svc-panel"}}function Ji(e){if(e.isDescendantOf("rating")&&!Gi(e))return"svc-rating-question-content"}function Wi(e,t,i){return"logo-image"===t?i:"cell"===t||"column-header"===t||"row-header"===t?{creator:i,element:e,question:e.question,row:e.row,column:e.column}:zi(e,t,!1)?e instanceof o.Question||e instanceof o.PanelModel?i:null:void 0}function Ki(e,t){return Gi(t)?o.SurveyModel.TemplateRendererComponentName:t.isDescendantOf("imagepicker")?"svc-image-item-value":"svc-item-value"}function Yi(e,t,o){return t.isContentElement?e:{creator:o,question:t,item:e}}function Xi(e,t){return!(e.parentQuestion instanceof o.QuestionMatrixDropdownModelBase&&(e.data||Gi(e.parentQuestion)))&&(!Gi(e)||e.isEditableTemplateElement)}function $i(e){if(!e.tagName)return!1;var t=e.tagName.toLowerCase();return-1!==["input","textarea"].indexOf(t)||-1!==["span","div"].indexOf(t)&&e.isContentEditable}function en(e,t){ee.warnNonSupported("registerAdorner","This functionality is no longer supported.")}function tn(e){void 0===e&&(e=void 0),ee.warnNonSupported("removeAdorners","This functionality is no longer supported.")}var on=function(e){function t(t,i,n){var r=e.call(this)||this;if(r.item=t,r.creator=i,r.model=n,r.click=function(e){r.allowAdd&&(r.creator.clickToolboxItem(r.item.json),r.hidePopup())},r.onPointerUp=function(e){r.hidePopup(),r.toolboxItem.isPressed=!1,document.removeEventListener("pointerup",r.onPointerUp)},r.startDragToolboxItem=function(e,t){var o=r.creator.getJSONForNewElement(r.item.json);return r.dragDropHelper.startDragToolboxItem(e,o,r.item),!0},r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragToolboxItem),!r.isDotsItem()){var a=t.popupModel;if(a){var s=(new o.CssClassBuilder).append(a.cssClass).append("svc-toolbox-subtypes").toString();a.cssClass=s,a.isFocusedContainer=!1,a.contentComponentName="svc-toolbox-list",a.contentComponentData.creator=i,a.isFocusedContent=!1}}return r}return K(t,e),Object.defineProperty(t.prototype,"toolboxItem",{get:function(){return this.item},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemComponent",{get:function(){return this.creator&&!this.creator.toolbox.showSubitems&&this.toolboxItem.hasSubItems?ve.defaultItemComponent:this.item.component||ve.defaultItemComponent},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowAdd",{get:function(){return!this.creator.readOnly},enumerable:!1,configurable:!0}),t.prototype.onMouseOver=function(e,t){this.model.mouseOverHandler(e)},t.prototype.onMouseOverTool=function(e,t){var o;(null===(o=e.popupModel)||void 0===o?void 0:o.isVisible)&&this.onMouseOver(e,t)},t.prototype.onMouseLeave=function(e,t){e.hidePopupDelayed(this.creator.toolbox.subItemsHideDelay)},t.prototype.onPointerDown=function(e){var t;if(e.stopPropagation(),this.allowAdd){if(this.isDotsItem())return!0;this.dragOrClickHelper.onPointerDown(e),this.toolboxItem.isPressed=!0,document.addEventListener("pointerup",this.onPointerUp),null===(t=this.creator)||void 0===t||t.onDragDropItemStart()}},t.prototype.isDotsItem=function(){return 0===this.item.id.indexOf("dotsItem-id")},t.prototype.hidePopup=function(){this.toolboxItem.hidePopup(),this.toolboxItem.isHovered=!1},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t}(o.Base);n(9671),n(7205);var nn=function(e){function t(t,i){var n=e.call(this)||this;return n.pagesController=t,n.pageEditMode=i,n.pagesChangedFunc=function(e,t){n.buildItems()},n.currentPagesChangedFunc=function(e,t){n.currentPage=n.pagesController.currentPage},n.pcPropertyChangedHandler=function(e,t){"toolboxLocation"===t.name&&("sidebar"==n.pagesController.creator.toolboxLocation?n.popupModel.horizontalPosition="right":n.popupModel.horizontalPosition=n.pagesController.creator.toolboxLocation)},n.togglePageSelector=function(e){return n.popupModel.toggleVisibility()},n.icon="icon-select-page",n.pagesController.onPagesChanged.add(n.pagesChangedFunc),n.pagesController.onCurrentPageChanged.add(n.currentPagesChangedFunc),n.pageListModel=new o.ListModel({items:[],onSelectionChanged:function(e){n.pagesController.selectPage(e.data),n.popupModel.hide()},allowSelection:!0}),n.popupModel=new o.PopupModel("sv-list",{model:n.pageListModel},{cssClass:"svc-creator-popup"}),n.pagesController&&(n.popupModel.horizontalPosition=n.pagesController.creator.toolboxLocation),n.popupModel.onShow=function(){n.pageListModel.selectedItem=n.getActionBarByPage(n.pagesController.currentPage),n.isPopupOpened=!0},n.popupModel.onHide=function(){n.isPopupOpened=!1},n.pagesController.creator.onPropertyChanged&&n.pagesController.creator.onPropertyChanged.add(n.pcPropertyChangedHandler),n.buildItems(),n}return K(t,e),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.stopItemsContainerHeightObserver(),this.pagesController.onPagesChanged.remove(this.pagesChangedFunc),this.pagesController.onCurrentPageChanged.remove(this.currentPagesChangedFunc),this.pagesController.creator.onPropertyChanged&&(this.pagesController.creator.onPropertyChanged.remove(this.pcPropertyChangedHandler),this.pcPropertyChangedHandler=void 0),this.pageListModel&&this.pageListModel.dispose(),this.popupModel&&this.popupModel.dispose(),this._scrollableContainer=void 0,this._itemsContainer=void 0},t.prototype.getActionBarByPage=function(e){for(var t=0;t<this.items.length;t++)if(this.items[t].data===e)return this.items[t];return null},t.prototype.setItems=function(e){this.items=e,this.pageListModel.setItems(e),this.updateVisibility()},t.prototype.buildItems=function(){this.currentPage=this.pagesController.currentPage||this.pagesController.pages[0];for(var e=[],t=this.pagesController.pages,o=0;o<t.length;o++)e.push(this.createActionBarItem(t[o]));if("bypage"===this.pagesController.creator.pageEditMode){var i=this.pagesController.creator.getPlugin("designer").model.newPage;i&&e.push(this.createActionBarItem(i))}this.setItems(e)},t.prototype.patchContainerOffset=function(e){for(;e;){if(-1!==e.className.indexOf("svc-tab-designer--with-page-navigator"))return void(e.offsetParent.scrollTop=0);e=e.parentElement}},t.prototype.createActionBarItem=function(e){var t=this,i={id:e.id,title:new o.ComputedUpdater((function(){var o=e.name,i=e.title;return t.pagesController?t.pagesController.getDisplayName(e):i||o}))};return i.active=new o.ComputedUpdater((function(){return e===t.currentPage})),i.action=function(o){t.scrollToPage(e)},i.data=e,this.createActionBarCore(i)},Object.defineProperty(t.prototype,"isByPageMode",{get:function(){return"bypage"===this.pagesController.creator.pageEditMode},enumerable:!1,configurable:!0}),t.prototype.scrollToPage=function(e){var t=this;if("bypage"===this.pageEditMode)return this.pagesController.currentPage=e,this.currentPage=e,void this.pagesController.creator.selectElement(this.pagesController.currentPage);var o=document.getElementById(e.id);if(o){var i=this.pagesController.pages.indexOf(e)===this.pagesController.pages.length-1;this._scrollableContainer?(this._scrollableContainer.scrollTo(this._scrollableContainer.scrollLeft,o.offsetTop-20),this.patchContainerOffset(o),i&&setTimeout((function(){t._scrollableContainer.scrollTo(t._scrollableContainer.scrollLeft,o.offsetTop-20),t.patchContainerOffset(o)}),50)):(o.scrollIntoView({block:"start"}),this.patchContainerOffset(o),i&&setTimeout((function(){o.scrollIntoView({block:"start"}),t.patchContainerOffset(o)}),50))}},t.prototype.createActionBarCore=function(e){return new o.Action(e)},Object.defineProperty(t.prototype,"pageSelectorCaption",{get:function(){return Z("ed.selectPage")},enumerable:!1,configurable:!0}),t.prototype.onContainerScroll=function(e){var t=e.scrollTop,o=e.clientHeight,i=t+o,n=[],r=void 0,a=0;return this.pagesController.pages.forEach((function(e){var o=document.getElementById(e.id);if(o){var s=o.offsetTop,l=s+o.clientHeight;if(!(s<i||l>t))return;var u=s-t,p=i-l,c=o.clientHeight;u<0&&(c+=u),p<0&&(c+=p),(c/=o.clientHeight)>0&&(n.push({page:e,visiblePart:c}),c>a&&(a=c,r=e))}})),this.currentPage=r,n},t.prototype.stopItemsContainerHeightObserver=function(){this._itemsContainer=void 0,this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=void 0),this.isDisposed||(this.visibleItemsStartIndex=0,this.visibleItemsCount=Number.MAX_VALUE)},t.prototype.setScrollableContainer=function(e){this._scrollableContainer=e},t.prototype.setItemsContainer=function(e){var t=this;this.stopItemsContainerHeightObserver(),this._itemsContainer=e,this._resizeObserver=new ResizeObserver((function(e,o){return t.updateVisibleItems(e[0].contentBoxSize[0].blockSize)})),this._resizeObserver.observe(e)},t.prototype.updateVisibleItems=function(e){if(this.updateVisibility(),!this.isByPageMode){var o=e-t.PAGE_NAVIGATION_MENU_ITEM_HEIGHT;this.visibleItemsCount=Math.floor(o/t.PAGE_NAVIGATION_ITEM_HEIGHT);var i=this.pagesController.pages.indexOf(this.currentPage),n=0;i>=this.visibleItemsCount&&(n=this.items.length-i-1<this.visibleItemsCount/2?this.items.length-this.visibleItemsCount:i-Math.floor(this.visibleItemsCount/2)),this.visibleItemsStartIndex=n}},t.prototype._updateVisibility=function(){this.hasScrolling=!this._scrollableContainer||this._scrollableContainer.scrollHeight>this._scrollableContainer.clientHeight,this.visible=this.items.length>1&&(this.hasScrolling||this.isByPageMode),this.isByPageMode&&(this.visibleItemsStartIndex=0,this.visibleItemsCount=this.items.length)},t.prototype.updateVisibility=function(){var e=this;setTimeout((function(){e._updateVisibility()}),10)},Object.defineProperty(t.prototype,"visibleItems",{get:function(){return this.items.length<=this.visibleItemsCount?this.items:this.items.slice(this.visibleItemsStartIndex,this.visibleItemsStartIndex+this.visibleItemsCount)},enumerable:!1,configurable:!0}),t.PAGE_NAVIGATION_MENU_ITEM_HEIGHT=44,t.PAGE_NAVIGATION_ITEM_HEIGHT=36,J([(0,o.property)({defaultValue:!0})],t.prototype,"hasScrolling",void 0),J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"visible",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isPopupOpened",void 0),J([(0,o.property)({onSet:function(e,t){var o=t.pagesController.pages.indexOf(e);if(!(o>=t.visibleItemsStartIndex&&o<t.visibleItemsStartIndex+t.visibleItemsCount)){var i=t.visibleItemsStartIndex;if(o<t.visibleItemsStartIndex&&(i=o),o>=t.visibleItemsStartIndex+t.visibleItemsCount&&(i=o-t.visibleItemsCount+1),t.visibleItemsStartIndex!==i)if(t.visible&&t._itemsContainer){var n=t._itemsContainer.querySelectorAll(".svc-page-navigator__selector + div")[0];if(n){var r="svc-page-navigator__items--"+(t.visibleItemsStartIndex<i?"up":"down");n.className=r,setTimeout((function(){n.className="",t.visibleItemsStartIndex=i}),250)}}else t.visibleItemsStartIndex=i}}})],t.prototype,"currentPage",void 0),J([(0,o.property)({defaultValue:0})],t.prototype,"visibleItemsStartIndex",void 0),J([(0,o.property)({defaultValue:Number.MAX_VALUE})],t.prototype,"visibleItemsCount",void 0),t}(o.Base);n(4767);var rn=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.addGhostPage=function(e){void 0===e&&(e=!0);var t=r.page;r.isGhost&&r.creator.addPage(t,e,(function(){return t.unRegisterFunctionOnPropertiesValueChanged(["title","description"],"add_ghost"),t.name=ee.getNewPageName(r.creator.survey.pages),!0}))&&(r.creator.survey.currentPage=t),e&&r.creator.selectElement(t)},r.addNewQuestion=function(e,t,o){r.creator.addNewQuestionInPage((function(e){r.addGhostPage(!1),r.creator.survey.currentPage=r.page}),null,o||r.currentAddQuestionType||i.designer.defaultAddQuestionType)},r.startDragSurveyElement=function(e){var t,o=r.surveyElement,i=r.creator.selectedElement===o;return r.dragDropHelper.startDragSurveyElement(e,o,i),r.creator.collapsePagesOnDrag&&(null===(t=r.creator.designerStateManager)||void 0===t||t.suspend(),r.creator.collapseAllPages()),!0},r.questionTypeSelectorModel=r.creator.getQuestionTypeSelectorModel((function(e){r.currentAddQuestionType=e,r.addGhostPage(!1),r.creator.survey.currentPage=r.page})),r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragSurveyElement),r}return K(t,e),t.prototype.updateDragTypeOverMe=function(){var e;this.isDisposed||(this.dragTypeOverMe=null===(e=this.page)||void 0===e?void 0:e.dragTypeOverMe)},t.prototype.updateIsDragMe=function(){var e;this.isDisposed||(this.isDragMe=null===(e=this.page)||void 0===e?void 0:e.isDragMe)},t.prototype.updateShowPlaceholder=function(e){this.showPlaceholder=!this.isGhost&&0===(e||this.page.elements).length},t.prototype.updateActionVisibility=function(t,o){e.prototype.updateActionVisibility.call(this,t,!this.isGhost&&o)},t.prototype.updateActionsContainer=function(t,o){e.prototype.updateActionsContainer.call(this,t,o),"never"!=this.creator.expandCollapseButtonVisibility&&this.actionContainer.addAction(this.expandCollapseAction)},Object.defineProperty(t.prototype,"dragInsideCollapsedContainer",{get:function(){return this.collapsed},enumerable:!1,configurable:!0}),t.prototype.getAllowExpandCollapse=function(t){return!this.isGhost&&e.prototype.getAllowExpandCollapse.call(this,t)},t.prototype.attachElement=function(t){var o=this;e.prototype.attachElement.call(this,t),this.dragTypeOverMe=null,t&&(t.surveyChangedCallback=function(){o.isPageLive=!!t.survey},this.calcIsGhostPage(t)&&(this.updateActionsProperties(),t.registerFunctionOnPropertiesValueChanged(["title","description"],(function(){o.addGhostPage(),o.updateShowPlaceholder()}),"add_ghost"),this.patchPageForDragDrop(t,this.addGhostPage)),t.registerFunctionOnPropertiesValueChanged(["dragTypeOverMe"],(function(){o.updateDragTypeOverMe()})),t.registerFunctionOnPropertiesValueChanged(["isDragMe"],(function(){o.updateIsDragMe()})),t.registerFunctionOnPropertiesValueChanged(["elements"],(function(e){o.updateShowPlaceholder(e)})),this.updateShowPlaceholder(),t.onFirstRendering(),t.updateCustomWidgets(),t.setWasShown(!0),this.checkActionProperties(),this.dragTypeOverMe=t.dragTypeOverMe,this.isDragMe=t.isDragMe)},t.prototype.detachElement=function(t){t&&(t.unRegisterFunctionOnPropertiesValueChanged(["dragTypeOverMe","isDragMe"]),t.unRegisterFunctionOnPropertiesValueChanged(["title","description"],"add_ghost"),t.surveyChangedCallback=void 0),e.prototype.detachElement.call(this,t),this.isDisposed||(this.dragTypeOverMe=null)},t.prototype.onElementSelectedChanged=function(t){e.prototype.onElementSelectedChanged.call(this,t),this.isSelected=t,t&&"bypage"===this.creator.pageEditMode&&this.setSurveyElement(this.creator.selectedElement),t&&this.onPageSelected()},t.prototype.patchPageForDragDrop=function(e,t){e._isGhost=!0,e._addGhostPageViewModel=function(){delete e._isGhost,delete e._addGhostPageViewModel,t()}},t.prototype.dispose=function(){this.detachElement(this.page),e.prototype.dispose.call(this)},t.prototype.calcIsGhostPage=function(e){return this.creator.survey.pages.indexOf(e)<0},Object.defineProperty(t.prototype,"isGhost",{get:function(){return this.calcIsGhostPage(this.page)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.pagePlaceHolderMobile"):Z("ed.pagePlaceHolder")},enumerable:!1,configurable:!0}),t.prototype.isOperationsAllow=function(){return e.prototype.isOperationsAllow.call(this)&&!this.isGhost&&"single"!==this.creator.pageEditMode&&this.creator.allowModifyPages},t.prototype.getPage=function(){return this.surveyElement},Object.defineProperty(t.prototype,"page",{get:function(){return this.getPage()},enumerable:!1,configurable:!0}),t.prototype.createActionContainer=function(){var e=new o.ActionContainer;return e.sizeMode="small",e},t.prototype.getExpandCollapseAction=function(){var t=e.prototype.getExpandCollapseAction.call(this);return t.needSeparator=!0,t},t.prototype.select=function(e,t){e.isGhost||("single"!==e.creator.pageEditMode?(e.creator.selectElement(e.page,void 0,!1),this.onPageSelected()):e.creator.selectElement(e.creator.survey,void 0,!1)),t.stopPropagation(),t.cancelBubble=!0},Object.defineProperty(t.prototype,"css",{get:function(){var t=e.prototype.getCss.call(this);return this.dragDropHelper.draggedElement&&this.dragDropHelper.draggedElement.isPage?(this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(t+=" svc-question__content--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(t+=" svc-question__content--drag-over-bottom")):(this.dragTypeOverMe&&this.showPlaceholder?t="svc-question__content--drag-over-inside":this.dragTypeOverMe&&0===this.page.elements.length&&this.creator.survey.pages.length>0&&(t="svc-page--drag-over-empty",this.creator&&!this.creator.showAddQuestionButton&&(t+=" svc-page--drag-over-empty-no-add-button")),this.dragTypeOverMe&&this.collapsed?(this.dragIn(),t+=" svc-page__content--collapsed-drag-over-inside"):this.dragOut()),this.allowExpandCollapse&&(t+=" svc-page__content--collapse-"+this.creator.expandCollapseButtonVisibility,this.renderedCollapsed&&(t+=" svc-page__content--collapsed"),this.expandCollapseAnimationRunning&&(t+=" svc-page__content--animation-running")),this.isDragMe&&(t+=" svc-page__content--dragged"),this.isGhost?t+" svc-page__content--new":(this.creator.isElementSelected(this.page)&&(t+=" svc-page__content--selected"),t.trim())},enumerable:!1,configurable:!0}),t.prototype.hoverStopper=function(e,t){e.__svc_question_processed=!0},t.prototype.duplicate=function(){var e=this.creator.copyPage(this.page);this.creator.selectElement(e)},t.prototype.delete=function(){this.creator.deleteElement(this.page)},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return!this.currentAddQuestionType&&this.creator?this.creator.getLocString("ed.addNewQuestion"):this.creator?this.creator.getAddNewQuestionText(this.currentAddQuestionType):""},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"footerActionsBar",{get:function(){var e=this;if(!this._footerActionsBar){this._footerActionsBar=new o.ActionContainer,this._footerActionsBar.containerCss="svc-page__footer",this._footerActionsBar.cssClasses={item:"svc-btn",itemTitle:"svc-text svc-text--normal svc-text--bold"};var t=[{css:"svc-add-new-question-action",visible:new o.ComputedUpdater((function(){return e.showAddQuestionButton})),component:"svc-add-new-question-btn",data:this}];t=this.creator.getUpdatedPageAdornerFooterActions(this,t),this.footerActionsBar.setItems(t)}return this._footerActionsBar},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){var e,t=this.surveyElement.cssClasses.page;return(null==t?void 0:t.description)?null===(e=this.rootElement)||void 0===e?void 0:e.querySelector(":scope ".concat((0,o.classesToSelector)(t.description))):null},t.prototype.getInnerAnimatedElements=function(){var e;return this.surveyElement.cssClasses.pageRow?[].slice.call(null===(e=this.rootElement)||void 0===e?void 0:e.querySelectorAll(":scope .svc-page__footer, :scope ".concat((0,o.classesToSelector)(this.surveyElement.cssRoot)," > .svc-row"))):null},t.prototype.onPageSelected=function(){this.rootElement&&ee.scrollIntoViewIfNeeded(this.rootElement)},t.prototype.getAllowDragging=function(t){return this.creator.allowDragPages&&e.prototype.getAllowDragging.call(this,t)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){this.dragOrClickHelper.onPointerDown(e)},Object.defineProperty(t.prototype,"dropTargetName",{get:function(){return!this.isGhost&&this.page?this.page.name:null},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!1})],t.prototype,"isSelected",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isPageLive",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),J([(0,o.property)({defaultValue:null})],t.prototype,"dragTypeOverMe",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragMe",void 0),t}(Ut);n(4880);var an=function(e){function t(t,o,i){var n=e.call(this)||this;return n.creator=t,n.row=o,n.templateData=i,n.dragTypeOverMe=n.row.dragTypeOverMe,n.row.onPropertyChanged.add((function(e,t){"dragTypeOverMe"==t.name&&(n.dragTypeOverMe=t.newValue)})),n}return K(t,e),Object.defineProperty(t.prototype,"cssClasses",{get:function(){var e="svc-row";return 1===this.row.elements.length&&"sv-drag-drop-ghost-survey-element-name"===this.row.elements[0].name&&(e+=" svc-row--ghost"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(e+=" svc-row--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(e+=" svc-row--drag-over-bottom"),e},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"dragTypeOverMe",void 0),t}(o.Base);n(3844);var sn=function(e){function t(t,n,r){var a=e.call(this,t,n)||this;return a.templateData=r,a.startDragSurveyElement=function(e){var t=a.surveyElement,o=a.creator.selectedElement===t;return a.dragDropHelper.startDragSurveyElement(e,t,o),!0},a.addNewQuestion=function(){a.creator.addNewQuestionInPage((function(e){}),a.surveyElement instanceof o.PanelModelBase?a.surveyElement:null,a.currentAddQuestionType||i.designer.defaultAddQuestionType)},a.questionTypeSelectorModel=a.creator.getQuestionTypeSelectorModel((function(e){a.currentAddQuestionType=e}),a.surveyElement),n.isQuestion&&n.setCanShowOptionItemCallback&&n.setCanShowOptionItemCallback((function(e){return!t.readOnly&&(e!==a.surveyElement.newItem||t.maximumChoicesCount<1||n.choices.length<t.maximumChoicesCount)})),a.checkActionProperties(),a.dragOrClickHelper=new o.DragOrClickHelper(a.startDragSurveyElement),Bo.setQuestion(a),a}return K(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),t.prototype.canSelectElement=function(){return e.prototype.canSelectElement.call(this)&&this.surveyElement.isInteractiveDesignElement},t.prototype.select=function(e,t){if(e.canSelectElement()){var o=e.creator,i=e.surveyElement,n=null===document||void 0===document?void 0:document.activeElement;return o.selectedElement!==i&&n&&n.blur&&"input"===n.tagName.toLocaleLowerCase()&&n.blur(),t.stopPropagation(),t.cancelBubble=!0,o.selectElement(i,void 0,!1),!0}},t.prototype.rootCss=function(){var t=this.surveyElement.isQuestion&&!this.surveyElement.startWithNewLine;return(new o.CssClassBuilder).append(e.prototype.getCss.call(this)).append("svc-question__adorner").append("svc-question__adorner--selected",!!this.creator.isElementSelected(this.surveyElement)).append("svc-question__adorner--collapsed",this.renderedCollapsed).append("svc-question__adorner--start-with-new-line",t).append("svc-question__adorner--collapse-"+this.creator.expandCollapseButtonVisibility,!0).toString()},t.prototype.css=function(){if(!this.surveyElement.isInteractiveDesignElement)return"";var e="svc-question__content";return e+="function"==typeof this.surveyElement.getType?" svc-question__content--"+this.surveyElement.getType():"",this.creator.isElementSelected(this.surveyElement)&&(e+=" svc-question__content--selected"),this.isEmptyElement&&(e+=" svc-question__content--empty"),this.isEmptyTemplate&&(e+=" svc-question__content--empty-template"),this.renderedCollapsed&&(e+=" svc-question__content--collapsed"),this.surveyElement.hasTitle&&(this.surveyElement.isPanel||"hidden"!==this.surveyElement.getTitleLocation())||(e+=" svc-question__content--title-hidden"),this.surveyElement.hasTitleOnBottom&&(e+=" svc-question__content--title-bottom"),this.isDragMe&&(e+=" svc-question__content--dragged"),this.dragTypeOverMe&&this.canExpandOnDrag&&this.dragInsideCollapsedContainer?(this.dragIn(),e+=" svc-question__content--collapsed-drag-over-inside"):this.dragOut(),this.dragTypeOverMe===o.DragTypeOverMeEnum.InsideEmptyPanel&&(e+=" svc-question__content--drag-over-inside"),this.dragInsideCollapsedContainer||(this.dragTypeOverMe===o.DragTypeOverMeEnum.Left&&(e+=" svc-question__content--drag-over-left"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Right&&(e+=" svc-question__content--drag-over-right"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(e+=" svc-question__content--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(e+=" svc-question__content--drag-over-bottom"),this.creator&&(e=this.creator.getElementAddornerCssCallback(this.surveyElement,e))),e},Object.defineProperty(t.prototype,"isTitleLeft",{get:function(){return!this.surveyElement.isPanel&&"left"===this.surveyElement.getTitleLocation()},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){var e,t,i=(this.surveyElement.isPanel?this.surveyElement.cssClasses.panel:this.surveyElement.cssClasses).content;return this.surveyElement.isDescendantOf("rating")&&(i="svc-rating-question-content"),this.isTitleLeft?null===(e=this.rootElement)||void 0===e?void 0:e.querySelector(":scope ".concat((0,o.classesToSelector)(this.surveyElement.getRootCss()))):i?null===(t=this.rootElement)||void 0===t?void 0:t.querySelector(":scope ".concat((0,o.classesToSelector)(i))):null},t.prototype.getInnerAnimatedElements=function(){var e,t=this.surveyElement.isPanel?this.surveyElement.getContainerCss():this.surveyElement.getRootCss(),i=this.surveyElement.cssDescription,n=[":scope > .svc-question__content > *:not(.svc-question__drag-area):not(".concat((0,o.classesToSelector)(t),")")];!this.isTitleLeft&&i&&n.push(":scope ".concat((0,o.classesToSelector)(i)));var r=[].slice.call(null===(e=this.rootElement)||void 0===e?void 0:e.querySelectorAll(n.join(",")));return r.push(this.rootElement),r},t.prototype.expandWithDragIn=function(){e.prototype.expandWithDragIn.call(this),this.element.dragTypeOverMe=null,this.creator.dragDropSurveyElements.dropTarget=null},Object.defineProperty(t.prototype,"isDragMe",{get:function(){return this.surveyElement.isDragMe},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragTypeOverMe",{get:function(){return this.element.dragTypeOverMe},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isBannerShowing",{get:function(){return this.isUsingCarryForward||this.isUsingRestfull||this.isMessagePanelVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isUsingCarryForward",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.isUsingCarryForward},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isUsingRestfull",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.isUsingRestful},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMessagePanelVisible",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.getPropertyValue("isMessagePanelVisible")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssCollapsedHiddenHeader",{get:function(){return this.element.cssHeader+" svc-element__header--hidden"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssCollapsedHiddenTitle",{get:function(){return this.element.cssTitle+" svc-element__title--hidden"},enumerable:!1,configurable:!0}),t.prototype.createBannerParams=function(){return this.createCarryForwardParams()||this.createUsingRestfulParams()||this.createCustomMessagePanel()},t.prototype.createCarryForwardParams=function(){var e,t=this;if(!this.isUsingCarryForward)return null;var o=null===(e=this.element)||void 0===e?void 0:e.choicesFromQuestion;if(!o)return null;var i=this.creator.survey.getQuestionByName(o);return i?{actionText:i.name,text:this.creator.getLocString("ed.carryForwardChoicesCopied"),onClick:function(){t.creator.selectElement(i)}}:null},t.prototype.createUsingRestfulParams=function(){var e=this;return this.isUsingRestfull?{actionText:this.creator.getLocString("ed.choicesLoadedFromWebLinkText"),text:this.creator.getLocString("ed.choicesLoadedFromWebText"),onClick:function(){e.creator.selectElement(e.element,"choicesByUrl")}}:null},t.prototype.createCustomMessagePanel=function(){if(!this.isMessagePanelVisible)return null;var e={question:this.element,actionText:"",messageText:"",onClick:function(){}};return this.creator&&this.creator.onCreateCustomMessagePanel.fire(this.creator,e),e.text=e.messageText,e},t.prototype.detachFromUI=function(){this.surveyElement.unRegisterFunctionOnPropertyValueChanged("isRequired","isRequiredAdorner"),this.surveyElement.unRegisterFunctionOnPropertyValueChanged("inputType","inputTypeAdorner"),this.surveyElement.setCanShowOptionItemCallback&&this.surveyElement.setCanShowOptionItemCallback(void 0)},Object.defineProperty(t.prototype,"isDraggable",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hoverDelay",{get:function(){return this.creator.animationEnabled?this.creator.pageHoverDelay:0},enumerable:!1,configurable:!0}),t.prototype.hover=function(t,o){this.surveyElement.isInteractiveDesignElement&&e.prototype.hover.call(this,t,o)},t.prototype.createActionContainers=function(){e.prototype.createActionContainers.call(this),this.actionContainer.sizeMode="small",this.topActionContainer=new o.ActionContainer,this.topActionContainer.sizeMode="small",this.topActionContainer.setItems([this.expandCollapseAction])},t.prototype.getActionById=function(t){var o=e.prototype.getActionById.call(this,t);return o||(o=this.topActionContainer.getActionById(t)),o},t.prototype.updateActionsProperties=function(){if(!this.isDisposed){e.prototype.updateActionsProperties.call(this);for(var t=this.actionContainer.visibleActions,o=!1,i=t.length-1;i>=0;i--)"convertTo"===t[i].id&&(o=!0),t[i].innerItem.location||(t[i].innerItem.location=o?"start":"end")}},t.prototype.updateElementAllowOptions=function(t,o){e.prototype.updateElementAllowOptions.call(this,t,o),this.updateActionVisibility("convertTo",o&&t.allowChangeType),this.updateActionVisibilityByProp("isrequired","isRequired",o&&t.allowChangeRequired),this.updateActionVisibilityByProp("convertInputType","inputType",t.allowChangeInputType),this.updateActionVisibilityByProp("convertInputType","rateDisplayMode",t.allowChangeInputType)},t.prototype.updateActionVisibilityByProp=function(e,t,i){var n=o.Serializer.findProperty(this.surveyElement.getType(),t);if(n){var r=this.creator.onIsPropertyReadOnlyCallback(this.surveyElement,n,n.readOnly,null,null);this.updateActionVisibility(e,i&&!r)}},Object.defineProperty(t.prototype,"isEmptyElement",{get:function(){if(this.surveyElement instanceof o.QuestionHtmlModel)return!this.surveyElement.html;if(this.surveyElement instanceof o.PanelModelBase){var e=this.surveyElement;return!e.rows||e.rows.length<=0||0===e.elements.length}return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmptyTemplate",{get:function(){return this.surveyElement instanceof o.QuestionPanelDynamicModel&&0==this.surveyElement.templateElements.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showHiddenTitle",{get:function(){return(!this.element.hasTitle||this.isTitleLeft)&&this.element.isInteractiveDesignElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.surveyElement instanceof o.QuestionHtmlModel?Z("ed.htmlPlaceHolder"):this.creator.isMobileView?Z("ed.panelPlaceHolderMobile"):Z("ed.panelPlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRequired",{get:function(){return this.surveyElement.isRequired},set:function(e){this.surveyElement.isRequired=e},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){this.dragOrClickHelper.onPointerDown(e)},t.prototype.getConvertToTypes=function(){var e=this,t=this.creator.getAvailableToolboxItems(this.element,!1),o=[];t.forEach((function(e){-1==o.indexOf(e.typeName)&&o.push(e.typeName)}));var i=$.getConvertToClasses(this.currentType,o,!0),n=[];return i.forEach((function(t){var o=e.creator.toolbox.items.filter((function(e){return e.name==t}));if(Array.isArray(o)&&o.length>0){var i=o[0];n.push(i)}})),n},t.prototype.buildDefaultJsonMap=function(e){var t={};function o(e){var o,i=(null===(o=e.json)||void 0===o?void 0:o.type)||e.id;if(e.json){var n=e.json;t[i]||(t[i]=[]),t[i].push(n)}}return e.forEach((function(e){o(e),(e.items||[]).forEach((function(e){o(e)}))})),t},t.prototype.convertQuestion=function(e,t,o){var i=this,n=(null==t?void 0:t.type)||e,r={};(o[n]||[]).forEach((function(e){if(i.jsonIsCorresponded(e)){r=W({},t);var o=i.element.toJSON(),a=i.cleanDefaultsFromJson(n,e);Object.keys(e).forEach((function(e){"type"==e||r[e]||(r[e]=void 0)})),Object.keys(t||{}).forEach((function(e){"type"!=e&&o[e]&&!a[e]&&(r[e]=void 0)}))}})),this.creator.convertCurrentQuestion(n,r)},t.prototype.getConvertToTypesActions=function(){var e=this,t=this.getConvertToTypes(),o=this.buildDefaultJsonMap(t),i=[],n=null;return t.forEach((function(t){var r=n&&t.category!=n.category,a=e.creator.createIActionBarItemByClass(t,r,(function(t,i){e.convertQuestion(t,i,o)}));n=t,i.push(a)})),i},Object.defineProperty(t.prototype,"currentType",{get:function(){return this.surveyElement.getType()},enumerable:!1,configurable:!0}),t.prototype.createConvertToAction=function(){var e=this,t=this.getConvertToTypesActions(),i=t.length>0,n=this.getSelectedItem(t,this.currentType),r={id:"convertTo",enabled:i,visibleIndex:0,title:n?n.title:G.getString("qt."+this.currentType),iconName:"icon-chevron_16x16"},a=this.createDropdownModel({actionData:r,items:t,updateListModel:function(t){e.updateQuestionTypeOrSubtypeListModel(t,!1)}});return a.iconName=new o.ComputedUpdater((function(){var t;return"small"===a.mode?null===(t=e.creator.toolbox.getItemByName(e.element.getType()))||void 0===t?void 0:t.iconName:"icon-chevron_16x16"})),a.iconSize=new o.ComputedUpdater((function(){return"small"===a.mode?24:16})),a.disableHide=!0,a},t.prototype.jsonsAreCompatible=function(e,t){var i=this,n=!0;return Object.keys(t).forEach((function(r){var a=void 0===e[r]?i.element.getDefaultPropertyValue(r):e[r];"type"==r||o.Helpers.isTwoValueEquals(t[r],a)||(n=!1)})),n},t.prototype.jsonIsCorresponded=function(e){return this.jsonsAreCompatible(this.element.toJSON(),e)},t.prototype.toolboxItemIsCorresponded=function(e,t){var o=this.element.getType(),i=e.json;if(e.id==o||e.json.type==o)return!t||this.jsonIsCorresponded(i)},t.prototype.cleanDefaultsFromJson=function(e,t){var i=o.QuestionFactory.Instance.createQuestion(e,"question");if(!i)return t;i.fromJSON(t);var n=i.toJSON();return n.type=e,delete n.name,n},t.prototype.updateQuestionTypeOrSubtypeListModel=function(e,t){var o,i,n,r=this,a=this.getConvertToTypes(),s=this.buildDefaultJsonMap(a),l=[],u=void 0,p=void 0;if(a.forEach((function(e){var t,o=i&&e.category!=i.category,a=r.creator.createIActionBarItemByClass(e,o,(function(e,t){r.convertQuestion(e,t,s)}));if(r.toolboxItemIsCorresponded(e,!!n)&&(n=a,p=e.items),(null===(t=e.items)||void 0===t?void 0:t.length)>0&&r.creator.toolbox.showSubitems){var c=[],d=void 0,h=!1;if(e.items.forEach((function(t){var o=r.creator.createIActionBarItemByClass(t,!1,(function(e,t){r.convertQuestion(e,t,s)}));r.toolboxItemIsCorresponded(t,!!n)&&(d=t),r.jsonsAreCompatible(e.json,t.json)&&(h=!0),c.push(o)})),!h&&c.length>0){var g=r.creator.createIActionBarItemByClass(e,!1,(function(e,t){r.convertQuestion(e,t,s)}));g.id=a.id+"-default",g.iconName=void 0,g.markerIconName=void 0,g.items=[],g.component=void 0,c.unshift(g),n!=a||d||(d=g)}a.setSubItems({items:c}),d&&(n=a,u=d,p=c)}i=e,l.push(a)})),t){if(p)return e.setItems(p),e.selectedItem=u,!!p}else{var c=null===(o=null==n?void 0:n.popupModel)||void 0===o?void 0:o.contentComponentData.model;c&&(c.selectedItem=u),e.setItems(l),e.selectedItem=n}},t.prototype.createConvertInputType=function(){var e=this,t=new o.ListModel([]);if(this.updateQuestionTypeOrSubtypeListModel(t,!0),0==t.actions.length)return null;var i=this.createDropdownModel({actionData:{id:"convertInputType",visibleIndex:1,title:"SUBTYPE",disableShrink:!0,iconName:"icon-chevron_16x16"},items:[],updateListModel:function(t){e.updateQuestionTypeOrSubtypeListModel(t,!0)}});return this.surveyElement.registerFunctionOnPropertiesValueChanged(["inputType","rateType"],(function(){var t=i.popupModel.contentComponentData.model;e.updateQuestionTypeOrSubtypeListModel(t,!0),i.title=t.selectedItem.title}),"inputTypeAdorner"),i.removePriority=1,i},t.prototype.getSelectedItem=function(e,t){var o=e.filter((function(e){return e.id===t}));return o.length>0?o[0]:void 0},t.prototype.createDropdownModel=function(e){var t=(0,o.createDropdownActionModel)({id:e.actionData.id,css:"sv-action--convertTo sv-action-bar-item--secondary",iconName:e.actionData.iconName,iconSize:16,title:e.actionData.title,enabled:e.actionData.enabled,visibleIndex:e.actionData.visibleIndex,disableShrink:e.actionData.disableShrink,location:"start",action:function(e){}},{items:e.items,allowSelection:!0,horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var o=t.popupModel.contentComponentData.model;e.updateListModel(o)}}),i=t.popupModel.contentComponentData.model;return e.updateListModel(i),i.selectedItem&&(t.title=i.selectedItem.title),t.popupModel.displayMode=this.creator.isTouch?"overlay":"popup",t.data.locOwner=this.creator,t},t.prototype.createRequiredAction=function(){var e=this;this.surveyElement.isRequired;var t=new o.Action({id:"isrequired",ariaChecked:new o.ComputedUpdater((function(){return e.isRequired})),ariaRole:"checkbox",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("pe.isRequired"),visibleIndex:20,iconName:"icon-required",iconSize:16,action:function(){e.creator.isCanModifyProperty(e.surveyElement,"isRequired")&&(e.isRequired=e.getUpdatedPropertyValue("isRequired",!e.isRequired))}});return t.innerCss=new o.ComputedUpdater((function(){return(new o.CssClassBuilder).append("svc-required-action").append("svc-required-action--active",e.isRequired).toString()})),t.innerItem.title=new o.ComputedUpdater((function(){return e.isRequired?e.creator.getLocString("pe.removeRequiredMark"):e.creator.getLocString("pe.markRequired")})),t},t.prototype.getUpdatedPropertyValue=function(e,t){var o={obj:this.element,propertyName:e,value:this.element[e],newValue:t,doValidation:!1};return this.creator.onValueChangingCallback(o),o.newValue},t.prototype.buildActions=function(t){e.prototype.buildActions.call(this,t);var o=this.surveyElement;t.push(this.createConvertToAction());var i=this.createConvertInputType();i&&t.push(i),t[t.length-1].css+=" sv-action--convertTo-last",void 0!==o.isRequired&&v(o,"isRequired")&&b(o,"isRequired")&&t.push(this.createRequiredAction())},t.prototype.duplicate=function(){var e=this;setTimeout((function(){e.creator.fastCopyQuestion(e.surveyElement,!0)}),1)},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return!this.currentAddQuestionType&&this.creator?this.creator.getLocString("ed.addNewQuestion"):this.creator?this.creator.getAddNewQuestionText(this.currentAddQuestionType):""},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),t}(Ut);n(422);var ln=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.switchCollapse=function(){n.isCollapsed=!n.isCollapsed},n.surveyElement.registerFunctionOnPropertyValueChanged("isSelectedInDesigner",(function(){n.leftFocus()}),"dropdownCollapseChecker"),n.visibleCount=t.maxVisibleChoices,n.isCollapsed=n.isCollapsed&&n.needToCollapse,n}return K(t,e),Object.defineProperty(t.prototype,"question",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemComponent",{get:function(){return this.surveyElement.isDescendantOf("dropdown")?"survey-radiogroup-item":"survey-checkbox-item"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"needToCollapse",{get:function(){return this.visibleCount>0&&this.question.visibleChoices.length>this.visibleCount},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isCollapseView",{get:function(){return this.isCollapsed},enumerable:!1,configurable:!0}),t.prototype.leftFocus=function(){this.creator.isElementSelected(this.surveyElement)||this.isCollapsed||(this.isCollapsed=this.needToCollapse)},t.prototype.getChoiceCss=function(){return(new o.CssClassBuilder).append("svc-question__dropdown-choice").append("svc-question__dropdown-choice--collapsed",this.isCollapsed&&this.needToCollapse).toString()},t.prototype.getRenderedItems=function(){return this.isCollapsed?this.question.renderedChoices.slice(0,this.visibleCount):this.question.renderedChoices},t.prototype.getButtonText=function(){return this.isCollapsed?G.getString("ed.showMoreChoices"):G.getString("ed.showLessChoices")},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.surveyElement.unRegisterFunctionOnPropertyValueChanged("isSelectedInDesigner","dropdownCollapseChecker")},J([(0,o.property)({defaultValue:!0})],t.prototype,"isCollapsed",void 0),J([(0,o.property)({defaultValue:-1})],t.prototype,"visibleCount",void 0),t}(sn);n(3140);var un=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.imageLinkValueChangedHandler=function(){n.isEmptyImageLink=!n.question.imageLink,n.filePresentationModel.value=null,n.filePresentationModel.visible=!n.question.imageLink},n.isEmptyImageLink=!n.question.imageLink,n.surveyElement.registerFunctionOnPropertyValueChanged("imageLink",n.imageLinkValueChangedHandler,"imageLinkValueChanged"),n.surveyElement.locImageLink.onStringChanged.add(n.imageLinkValueChangedHandler),n.initFilePresentationModel(),n}return K(t,e),t.prototype.initFilePresentationModel=function(){var e=this;this.filePresentationModel=o.Serializer.createClass("file",{name:this.question.name});var t=new o.SurveyModel;this.filePresentationModel.setSurveyImpl(t),this.filePresentationModel.forceIsInputReadOnly=!this.creator.isCanModifyProperty(this.question,"imageLink"),this.filePresentationModel.filePlaceholder=this.placeholderText,this.filePresentationModel.chooseButtonCaption=this.chooseImageText,this.filePresentationModel.acceptedTypes="image/*",this.filePresentationModel.storeDataAsText=!1,this.filePresentationModel.cssClasses.chooseFileIconId="icon-choosefile",t.onOpenFileChooser.add((function(t,o){e.creator.chooseFiles(o.input,o.callback,o.context)})),t.onUploadFiles.add((function(t,o){o.files[0]&&e.creator.uploadFiles(o.files,e.question,(function(t,i){e.question.imageLink=i,o.callback(t,[{content:i,file:o.files[0]}])}),{element:e.question,elementType:e.question.getType(),propertyName:"imageLink"})}))},t.prototype.chooseFile=function(e){var t=e.rootElement.getElementsByClassName("svc-choose-file-input")[0],o={element:e.question,elementType:e.question.getType(),propertyName:"imageLink"};e.creator.chooseFiles(t,(function(t){e.isUploading=!0,e.creator.uploadFiles(t,e.surveyElement,(function(t,o){e.surveyElement.imageLink=o,e.isUploading=!1}),o)}),o)},Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return O(this.surveyElement.contentMode)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmptyElement",{get:function(){return this.isEmptyImageLink},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"question",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.imagePlaceHolderMobile"):Z("ed.imagePlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"chooseImageText",{get:function(){return Z("ed.imageChooseImage")},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){if(this.isEmptyImageLink){var t=this.filePresentationModel.cssClasses;if(t.root)return this.surveyElement.getWrapperElement().querySelector(":scope ".concat((0,o.classesToSelector)(t.root)))}return e.prototype.getAnimatedElement.call(this)},t.prototype.css=function(){return(new o.CssClassBuilder).append(e.prototype.css.call(this)).append("svc-question__content--loading",this.isUploading).toString()},t.prototype.dispose=function(){this.surveyElement.unRegisterFunctionOnPropertyValueChanged("imageLink","imageLinkValueChanged"),this.surveyElement.locImageLink.onStringChanged.remove(this.imageLinkValueChangedHandler),e.prototype.dispose.call(this)},J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isEmptyImageLink",void 0),t}(sn);n(3926);var pn=function(e){function t(t,o,i){var n=e.call(this)||this;return n.creator=t,n.surveyElement=o,n.templateData=i,n}return K(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return N(this.surveyElement)},enumerable:!1,configurable:!0}),t.useRateValues=function(e){var t=e.contentQuestion?e.contentQuestion:e;return!!t.useRateValues&&t.useRateValues()},t.prototype.addItem=function(e){if(e.allowAdd&&e.enableAdd)if(t.useRateValues(e.element)){var i,n=e.element.rateValues.map((function(e){return e.value}));i=h(e.creator.getChoicesItemBaseTitle(),n);var r=new o.ItemValue(i);r.locOwner={getLocale:function(){return e.element.getLocale?e.element.getLocale():""},getMarkdownHtml:function(e){return e},getProcessedText:function(e){return e}},e.element.rateValues=e.element.rateValues.concat([r]);var a=e.element.rateValues;e.creator.onItemValueAddedCallback(e.element,"rateValues",a[a.length-1],a)}else e.element.rateMax+=e.element.rateStep},t.prototype.removeItem=function(e){if(e.allowRemove&&e.enableRemove){var i=o.Serializer.findProperty(e.element.getType(),"rateValues"),n=e.element.rateValues&&e.element.rateValues.length-1,r=e.element.rateValues&&e.element.rateValues[n]||null;if(e.creator.onCollectionItemDeletingCallback(e.element,i,e.element.rateValues,r)){var a=e.element;t.useRateValues(e.element)||n!==a.rateValues.length-1?(t.useRateValues(e.element)||(a.rateValues=a.rateValues),a.rateValues.splice(n,1)):a.rateMax-=a.rateStep}}},t.allowAddForElement=function(e,i){return(i<1||i>o.settings.ratingMaximumRateValueCount)&&!t.useRateValues(e)&&(i=o.settings.ratingMaximumRateValueCount),"smileys"==e.rateDisplayMode&&(i<1||i>10)&&(i=10),i<1||e.rateCount<i},Object.defineProperty(t.prototype,"allowAdd",{get:function(){return this.canAddOrRemove()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enableAdd",{get:function(){return this.allowAdd&&t.allowAddForElement(this.element,this.creator.maximumRateValues)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-item-value-controls__button").append("svc-item-value-controls__button--disabled",!this.enableAdd).append("svc-item-value-controls__add").toString()},enumerable:!1,configurable:!0}),t.allowRemoveForElement=function(e){return e.rateCount>2},t.prototype.canAddOrRemove=function(){return this.creator.isCanModifyProperty(this.element,"rateValues")&&this.creator.isCanModifyProperty(this.element,"rateCount")&&(!this.element.autoGenerate||this.creator.isCanModifyProperty(this.element,"rateMax"))},Object.defineProperty(t.prototype,"allowRemove",{get:function(){return this.canAddOrRemove()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enableRemove",{get:function(){return this.allowRemove&&t.allowRemoveForElement(this.element)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-item-value-controls__button").append("svc-item-value-controls__button--disabled",!this.enableRemove).append("svc-item-value-controls__remove").toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasTopLabel",{get:function(){return("top"==this.element.rateDescriptionLocation||"topBottom"==this.element.rateDescriptionLocation)&&!!this.element.minRateDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"controlsClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-rating-question-controls").append("svc-item-value-controls").append("svc-rating-question-controls--labels-top",this.hasTopLabel).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addTooltip",{get:function(){return Z("pe.addItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeTooltip",{get:function(){return Z("pe.removeItem")},enumerable:!1,configurable:!0}),t}(o.Base);n(6195);var cn={noneItem:"showNoneItem",otherItem:"showOtherItem",selectAllItem:"showSelectAllItem",refuseItem:"showRefuseItem",dontKnowItem:"showDontKnowItem"},dn=function(e){function t(t,i,n){var r=e.call(this)||this;for(var a in r.creator=t,r.question=i,r.item=n,r.canTouchItems=!0,r.focusCameFromDown=!1,r.startDragItemValue=function(e,t){r.dragDropHelper.startDrag(e,r.item,r.question,t)},r.handleDragDropGhostPositionChanged=function(){r.ghostPosition=r.getGhostPosition(r.item),r.isDragDropGhost=r.item===r.dragDropHelper.draggedElement,r.item===r.dragDropHelper.prevDropTarget?(r.isDragDropMoveDown=r.item.isDragDropMoveDown,r.isDragDropMoveUp=r.item.isDragDropMoveUp):(r.isDragDropMoveDown=!1,r.isDragDropMoveUp=!1)},r.updateIsNew(i,n),cn)r.registerOnPropertyChanged(a,cn[a]);return r.isNew&&(i.renderedChoicesChangedCallback=function(){r.updateNewItemValue()},r.updateNewItemValue()),r.dragDropHelper.onGhostPositionChanged.add(r.handleDragDropGhostPositionChanged),r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragItemValue),r.allowItemOperations={allowDelete:void 0,allowEdit:void 0,allowAdd:void 0},r.collectionProperty=o.Serializer.findProperty(i.getType(),r.collectionPropertyName),r.creator.onCollectionItemAllowingCallback(i.ownerObj||i,r.collectionProperty,i.visibleChoices,r.item,r.allowItemOperations),void 0===r.allowItemOperations.allowDelete&&(r.allowItemOperations.allowDelete=!0),void 0===r.allowItemOperations.allowAdd&&(r.allowItemOperations.allowAdd=!0),r.allowItemOperations.allowAdd||r.updateIsNewVisibility(),r.creator.isCanModifyProperty(i,"choices")||(r.canTouchItems=!1),r}return K(t,e),Object.defineProperty(t.prototype,"canBeDragged",{get:function(){return!this.isNew&&this.question.choices.indexOf(this.item)>-1},enumerable:!1,configurable:!0}),t.prototype.isBanStartDrag=function(e){return!this.isDraggable||"true"===e.target.getAttribute("contenteditable")||!this.canBeDragged},t.prototype.updateNewItemValue=function(){this.creator&&this.question&&this.question.newItem&&(this.question.newItem.value=this.creator.getNextItemValue(this.question),this.question.newItem.text=d(this.question.choices))},t.prototype.registerOnPropertyChanged=function(e,t){var o=this;if(this.question[e]===this.item){var i=this.question,n=this.item;i.registerFunctionOnPropertyValueChanged(t,(function(){o.updateIsNew(i,n)}))}},Object.defineProperty(t.prototype,"collectionPropertyName",{get:function(){return this.item.ownerPropertyName?this.item.ownerPropertyName:"choices"},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){return!!this.isBanStartDrag(e)||(this.dragOrClickHelper.onPointerDown(e),!1)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropChoices},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.dragDropHelper.onGhostPositionChanged.remove(this.handleDragDropGhostPositionChanged)},t.prototype.getGhostPosition=function(e){return this.dragDropHelper.dropTarget!==e?null:this.dragDropHelper.isBottom?"bottom":"top"},Object.defineProperty(t.prototype,"isDraggable",{get:function(){return this.isDraggableItem(this.item)},enumerable:!1,configurable:!0}),t.prototype.isDraggableItem=function(e){return!(this.creator.readOnly||!this.canTouchItems)&&-1!==this.question.choices.indexOf(e)},t.prototype.getSpecificProp=function(e){for(var t in cn)if(e.question[t]===e.item)return cn[t]},t.prototype.add=function(e){var t=this.getSpecificProp(e);t?e.question[t]=!0:(this.addNewItem(e.item,e.question,e.creator),this.updateIsNew(e.question,e.item))},t.prototype.addNewItem=function(e,t,o){e.value="newitem";var i=o.createNewItemValue(t);this.updateNewItemValue(),Go.get(i.locText).setAutoFocus()},t.prototype.remove=function(e){var t=this.getSpecificProp(e);if(t)e.question[t]=!1;else{var o=e.question.choices,i=o.indexOf(e.item);if(this.creator.onCollectionItemDeletingCallback(e.question,this.collectionProperty,o,e.item)){var n=this.findNextElementIndexToRemove(i);e.question.choices.splice(i,1),this.focusNextElementToRemove(n),this.updateIsNew(e.question,e.item)}}},t.prototype.onFocusOut=function(e){this.question._lastActiveItemValueIndex=this.question.choices.indexOf(this.item)},t.prototype.findNextElementIndexToRemove=function(e){var t=0;return this.question.choices.length>0&&((t=e<this.question._lastActiveItemValueIndex?e-1:e)<0&&(t=0),t>=this.question.choices.length-2&&(t=this.question.choices.length-2)),t},t.prototype.focusNextElementToRemove=function(e){var t=this;setTimeout((function(){var o;null===(o=document.getElementById(t.question.id).querySelectorAll(".svc-item-value-controls__remove")[e])||void 0===o||o.focus()}),100)},t.prototype.updateIsNew=function(e,t){this.isNew=!e.isItemInList(t)&&!this.isAutoGeneratedItem(t),this.updateIsNewVisibility()},t.prototype.updateIsNewVisibility=function(){var e;this.isNew&&this.item.setIsVisible(!(!1===(null===(e=this.allowItemOperations)||void 0===e?void 0:e.allowAdd)))},Object.defineProperty(t.prototype,"allowRemove",{get:function(){var e=this.creator.minimumChoicesCount;if(e>0&&e>=this.question.choices.length)return!1;var t=!this.question.isItemInList(this.item),o=this.isAutoGeneratedItem(this.item);return!this.creator.readOnly&&this.canTouchItems&&this.allowItemOperations.allowDelete&&!t&&!o},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tooltip",{get:function(){return Z(this.isNew?"pe.addItem":"pe.removeItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragTooltip",{get:function(){return Z("pe.dragItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowAdd",{get:function(){var e=!this.question.isItemInList(this.item),t=this.isAutoGeneratedItem(this.item);return!this.creator.readOnly&&this.canTouchItems&&this.allowItemOperations.allowAdd&&e&&!t},enumerable:!1,configurable:!0}),t.prototype.select=function(e,t){e.question.inMatrixMode||(e.creator.selectElement(e.question,"choices",!1),t&&t.stopPropagation())},t.prototype.isAutoGeneratedItem=function(e){var t=e.value;if(!o.Helpers.isNumber(t))return!1;var i=this.question.choicesMin,n=this.question.choicesMax;return!(!o.Helpers.isNumber(i)||!o.Helpers.isNumber(n)||i===n&&0===i)&&t>=i&&t<=n},J([(0,o.property)({defaultValue:!1})],t.prototype,"isNew",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropGhost",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropMoveDown",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropMoveUp",void 0),J([(0,o.property)({defaultValue:null})],t.prototype,"ghostPosition",void 0),t}(o.Base);n(1383);var hn=function(e){function t(t,o,i,n,r){var a=e.call(this,t,o,i)||this;return a.question=o,a.item=i,a.templateData=n,a.itemsRoot=r,a.isChoosingNewFile=!1,a.onDragOver=function(e){a.isFileDragging=!0,e.dataTransfer.dropEffect="copy",e.preventDefault()},a.onDrop=function(e){a.isFileDragging=!1,e.preventDefault();var t=e.dataTransfer;if(t&&t.files&&!(t.files.length<1)){for(var o=[],i=0;i<t.files.length;i++)o.push(t.files[i]);a.uploadFiles(o)}},a.onDragLeave=function(e){a.isFileDragging=!1},a}return K(t,e),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-image-item-value-wrapper").append("svc-image-item-value").append("svc-image-item-value--new",this.isNew||this.isUploading).append("svc-image-item-value-wrapper--ghost",this.isDragDropGhost).append("svc-image-item-value--file-dragging",this.isFileDragging).append("svc-image-item-value--single",this.getIsNewItemSingle()).toString()},t.prototype.getIsNewItemSingle=function(){return this.isNew&&0===this.question.choices.length},Object.defineProperty(t.prototype,"canRenderControls",{get:function(){return this.getIsNewItemSingle()||!this.question.renderedImageWidth||this.question.renderedImageWidth>150},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectFileTitle",{get:function(){return this.creator.getLocString("ed.selectFile")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeFileTitle",{get:function(){return this.creator.getLocString("ed.removeFile")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addFileTitle",{get:function(){return this.creator.getLocString("ed.selectFile")},enumerable:!1,configurable:!0}),t.prototype.chooseFile=function(e){var t=e.itemsRoot.getElementsByClassName("svc-choose-file-input")[0],o={element:e.question,item:e.item,elementType:e.question.getType(),propertyName:"imageLink"};e.creator.chooseFiles(t,(function(t){e.isUploading=!0,e.creator.uploadFiles(t,e.question,(function(t,o){"success"===t&&(e.item.imageLink=o),e.isUploading=!1}),o)}),o)},t.prototype.uploadFiles=function(e){var t=this;this.isUploading=!0;var o={element:this.question,item:void 0,elementType:this.question.getType(),propertyName:"imageLink"};this.creator.uploadFiles(e,this.question,(function(e,o){"success"===e&&t.creator.createNewItemValue(t.question,t.isChoosingNewFile,(function(e){e.imageLink=o})),t.isChoosingNewFile=!1,t.isUploading=!1}),o)},t.prototype.chooseNewFile=function(e){var t=this,o=e.itemsRoot.getElementsByClassName("svc-choose-file-input")[0];e.creator.chooseFiles(o,(function(o){t.isChoosingNewFile=!0,e.uploadFiles(o)}),{element:e.question,item:e.item,elementType:e.question.getType(),propertyName:"imageLink"})},Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return O(this.question.contentMode)},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this.itemsRoot=void 0,e.prototype.dispose.call(this)},J([(0,o.property)({defaultValue:!1})],t.prototype,"isFileDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),t}(dn);n(3952);var gn=function(){function e(e,t,i,n){this.cellQuestion=t,this.column=i,this.creator=e;var r=t.toJSON();r.type=t.getType(),this.surveyValue=e.createSurvey({questions:[r]},"modal-question-editor",n,(function(e){e.css=o.defaultV2Css,e.setDesignMode(!0),e.isPopupEditorContent=!0,e.showQuestionNumbers="none",e.questionTitleLocation="hidden"})),this.question.setSurveyImpl(this.survey),this.question.inMatrixMode=!0,this.question.ownerObj=this.column}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"question",{get:function(){return this.survey.getAllQuestions()[0]},enumerable:!1,configurable:!0}),e.prototype.apply=function(){var e=this.cellQuestion.parentQuestion,t=e.getColumnByName(this.cellQuestion.name),i=t.toJSON(),n=i.cellType,r=this.question.toJSON(),a=this.question.getType();if(n&&(r.cellType=n),!o.Helpers.isTwoValueEquals(r,i)){for(var s in i)!o.Serializer.findProperty(a,s)||void 0!==r[s]||!0!==i[s]&&!1!==i[s]||(r[s]=!i[s]);for(var s in r)o.Helpers.isTwoValueEquals(r[s],i[s])||(t[s]=r[s]);e.onColumnCellTypeChanged(t),this.creator.setModified({type:"MATRIX_CELL_EDITOR",column:t})}},e}(),mn=function(e){function t(t,o,i,n,r){var a=e.call(this)||this;return a.creator=t,a.templateData=o,a.question=i,a.row=n,a.column=r,a.onSelectionChanged=function(e,t){a.context&&a.context.getPropertyValue?a.isSelected=a.creator.isElementSelected(a.context):a.isSelected=!1},t.onSelectedElementChanged.add(a.onSelectionChanged),a}return K(t,e),t.prototype.editQuestion=function(e,t){var i=new gn(e.creator,e.question,e.column,this);i.question.cellOwner=e;var n=o.surveyLocalization.currentLocale,r=G.currentLocale;o.surveyLocalization.currentLocale=r,o.settings.showDialog({componentName:"svc-question-editor-content",data:{survey:i.survey,creator:this.creator},onApply:function(){return i.apply(),!0},cssClass:"svc-matrix-cell__popup svc-creator-popup",title:e.question.name,displayMode:this.creator.isMobileView?"overlay":"popup"},e.creator.rootElement).locale=r,o.surveyLocalization.currentLocale=n,t.stopPropagation(),e.creator.selectElement(e.column)},Object.defineProperty(t.prototype,"context",{get:function(){return this.row||this.column||this.templateData},enumerable:!1,configurable:!0}),t.prototype.selectContext=function(e,t){if(e.row)return e.creator.selectElement(e.row.data,"rows",!1),void t.stopPropagation();"function"==typeof e.context.getType&&("itemvalue"===e.context.getType()?e.creator.selectElement(e.context.locOwner,e.context.ownerPropertyName,!1):e.creator.selectElement(e.context),t.stopPropagation())},Object.defineProperty(t.prototype,"isSupportCellEditor",{get:function(){return!(!this.question||!this.question.getType)&&ee.isSupportCellEditor(this.question.getType())},enumerable:!1,configurable:!0}),t.prototype.hover=function(e,t){!this.row&&this.context&&this.context.getPropertyValue&&this.context.getType&&"itemvalue"!==this.context.getType()&&C(e,t)},t.prototype.dispose=function(){this.creator.onSelectedElementChanged.remove(this.onSelectionChanged),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"isSelected",void 0),t}(o.Base);n(9414);var fn=function(e){function t(t,o,i){var n=e.call(this)||this;return n.survey=t,n._data=o,n._lvl=i,n.toggle=function(){n.collapsed=!n.collapsed},n.markerWidth=16,n.question=t.getQuestionByName(n.name),n.items=yn(t,o.data,i+1),n.lvl=i,n}return K(t,e),Object.defineProperty(t.prototype,"data",{get:function(){return this.items},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNode",{get:function(){return this._data.isNode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this._data.name},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"title",{get:function(){return this._data.title},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this._data.value},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"displayValue",{get:function(){return this._data.displayValue},enumerable:!1,configurable:!0}),t.prototype.getString=function(e){return this._data.getString(e)},Object.defineProperty(t.prototype,"markerMargin",{get:function(){return(1.5+this.lvl)*this.markerWidth+"px"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textMargin",{get:function(){return(2.75+this.lvl)*this.markerWidth+"px"},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!0})],t.prototype,"collapsed",void 0),J([(0,o.property)({defaultValue:0})],t.prototype,"lvl",void 0),J([(0,o.property)()],t.prototype,"items",void 0),t}(o.Base);function yn(e,t,o){return void 0===t&&(t=[]),t.filter((function(e){return!!e})).map((function(t){return new fn(e,t,o)}))}var vn=function(e){function t(t){var o=e.call(this)||this;o.survey=t,o.selectTableClick=function(){o.resultViewType="table"},o.selectJsonClick=function(){o.resultViewType="text"},o.resultText=JSON.stringify(t.data,null,4);var i=t.getPlainData({includeEmpty:!1,includeValues:!0});return o.resultData=yn(t,i,0),o}return K(t,e),t.prototype.getLocString=function(e){return G.getString(e)},Object.defineProperty(t.prototype,"surveyResultsText",{get:function(){return this.getLocString("ed.surveyResults")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"surveyResultsTableText",{get:function(){return this.getLocString("ed.surveyResultsTable")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"surveyResultsJsonText",{get:function(){return this.getLocString("ed.surveyResultsJson")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsTitle",{get:function(){return this.getLocString("ed.resultsTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsName",{get:function(){return this.getLocString("ed.resultsName")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsValue",{get:function(){return this.getLocString("ed.resultsValue")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsDisplayValue",{get:function(){return this.getLocString("ed.resultsDisplayValue")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isTableSelected",{get:function(){return"table"===this.resultViewType},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isJsonSelected",{get:function(){return"text"===this.resultViewType},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:"table"})],t.prototype,"resultViewType",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"resultText",void 0),J([(0,o.propertyArray)()],t.prototype,"resultData",void 0),t}(o.Base);n(9281);var bn=function(e){function t(t,o){var i=e.call(this)||this;return i.creator=t,i.root=o,i}return K(t,e),Object.defineProperty(t.prototype,"allowEdit",{get:function(){var e=this.creator.survey,t=o.Serializer.findProperty(e.getType(),"logo");return!(this.creator.readOnly||t.overridingProperty&&e[t.overridingProperty])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerCss",{get:function(){return(new o.CssClassBuilder).append("svc-logo-image-container").append("svc-logo-image-container--editable",this.allowEdit).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),t.prototype.uploadFile=function(e,t,o){e.isUploading=!0,e.creator.uploadFiles(o,void 0,(function(o,i){e.creator.survey.logo=i,t.value="",e.isUploading=!1}),{element:e.creator.survey,elementType:"survey",propertyName:"logo"})},t.prototype.chooseFile=function(e){if(this.allowEdit){var t=e.root.getElementsByClassName("svc-choose-file-input")[0];0===t.files.length?e.creator.chooseFiles(t,(function(o){e.uploadFile(e,t,o)}),{element:this.survey,elementType:this.survey.getType(),propertyName:"logo"}):e.uploadFile(e,t,[t.files[0]])}},t.prototype.remove=function(e){e.creator.survey.logo=""},Object.defineProperty(t.prototype,"chooseLogoPlaceholder",{get:function(){return this.creator.getLocString("ed.chooseLogoPlaceholder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return O("image")},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),t}(o.Base),Cn="embeddedsurvey",wn=function(e){function t(t){var o=e.call(this,t)||this;return o.onEmbeddedSurveyValueChanged=function(){},o}return K(t,e),Object.defineProperty(t.prototype,"embeddedSurvey",{get:function(){return this.getPropertyValue("embeddedSurvey")},set:function(e){e!==this.embeddedSurvey&&(this.setPropertyValue("embeddedSurvey",e),this.onEmbeddedSurveyValueChanged())},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return Cn},t}(o.QuestionNonValue);o.Serializer.addClass(Cn,[],(function(){return new wn("")}),"nonvalue"),o.QuestionFactory.Instance.registerQuestion(Cn,(function(e){return new wn(e)}),!1),n(2996);var xn=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,t)||this,n=o&&!o.showValueInLink&&G.getString("pe.set")+" "+o.title||null;return i.linkValueText=n||G.getString("pe.emptyValue"),i}return K(t,e),t.prototype.onPropertyValueChanged=function(t,i,n){e.prototype.onPropertyValueChanged.call(this,t,i,n),"value"===t&&(this.updateLinkValueText(),this.allowClear&&(this.showClear=!o.Helpers.isValueEmpty(n)),this.updateIsClickable())},t.prototype.onReadOnlyChanged=function(){this.updateIsClickable(),e.prototype.onReadOnlyChanged.call(this)},t.prototype.updateIsClickable=function(){this.setPropertyValue("isClickable",!this.isReadOnly||!!this.isClickableCallback&&this.isClickableCallback())},Object.defineProperty(t.prototype,"ariaRole",{get:function(){return"button"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tooltip",{get:function(){return this.showTooltip?this.linkValueText:void 0},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"linkvalue"},t.prototype.doLinkClick=function(){this.linkClickCallback&&this.linkClickCallback()},t.prototype.doClearClick=function(){this.clearClickCallback&&this.clearClickCallback()},t.prototype.updateLinkValueText=function(){var e;e=this.showValueInLink?this.isEmpty()?G.getString("pe.emptyValue"):this.getObjDisplayValue():G.getString(this.isEmpty()?"pe.set":"pe.change")+" "+this.title,this.linkValueText=e},t.prototype.stringifyValue=function(e){return"string"!=typeof e?JSON.stringify(e):e},t.prototype.getObjDisplayValue=function(){var e=this.obj;if(!e||!e.getDisplayValue)return this.stringifyValue(this.value);var t=e.getDisplayValue(!0,this.value);return"string"!=typeof t?JSON.stringify(t):t},J([(0,o.property)({defaultValue:"svc-link-value-button svc-question-link__set-button"})],t.prototype,"linkSetButtonCssClasses",void 0),J([(0,o.property)({defaultValue:"svc-question-link__clear-button"})],t.prototype,"linkClearButtonCssClasses",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isSelected",void 0),J([(0,o.property)()],t.prototype,"linkValueText",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showClear",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowClear",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showValueInLink",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showTooltip",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isClickable",void 0),J([(0,o.property)()],t.prototype,"iconName",void 0),t}(o.Question);o.Serializer.addClass("linkvalue",["showValueInLink",{name:"showTooltip: boolean",default:!1,visible:!1},"iconName"],(function(e){return new xn("",e)}),"nonvalue"),o.QuestionFactory.Instance.registerQuestion("linkvalue",(function(e){return new xn(e)}),!1);var Tn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._showUnitsInEditor=!0,t.onUpButtonMouseDown=function(){t.increase(),t.increaseTimer=setTimeout(t.onUpButtonMouseDown,200)},t.onDownButtonMouseDown=function(){t.decrease(),t.decreaseTimer=setTimeout(t.onDownButtonMouseDown,200)},t.onButtonMouseLeave=function(){t.onButtonMouseUp()},t.onButtonMouseUp=function(){clearTimeout(t.decreaseTimer),clearTimeout(t.increaseTimer)},t.onKeyDown=function(e){switch(e.key){case"ArrowUp":t.increase(),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":t.decrease(),e.stopPropagation(),e.preventDefault()}t.onTextKeyDownHandler(e)},t.onInputKeyDown=function(e){"ArrowUp"!=e.key&&"ArrowDown"!=e.key||t.updateValueOnEvent(e)},t.onFocus=function(e){"INPUT"==e.target.tagName&&queueMicrotask((function(){var o=e.target,i=o.selectionStart,n=o.selectionEnd,r=o.selectionDirection;t._showUnitsInEditor=!1,queueMicrotask((function(){Math.abs(n-i)>0?o.setSelectionRange(0,t.renderedValue.length,r):o.setSelectionRange(t.renderedValue.length,t.renderedValue.length)}))}))},t.onBlur=function(e){t._showUnitsInEditor=!0,"INPUT"==e.target.tagName&&t.updateValueOnEvent(e)},t}return K(t,e),t.prototype.parseValue=function(e){return{value:parseFloat(e.toString()),unit:e.toString().replace(/[^A-Za-z]/g,"")}},t.prototype.changeValue=function(e){var t=this.parseValue(this.renderedValue),o=Number(this.renderedStep||1),i=t.value;e?i+=o:i-=o,this.value=i},Object.defineProperty(t.prototype,"showUnitsInEditor",{get:function(){return!!this.unit&&this._showUnitsInEditor},enumerable:!1,configurable:!0}),t.prototype.correctValue=function(e){if(null==e||null==e)return e;var t=Number(this.renderedMax),o=Number(this.renderedMin);return e="string"==typeof e?parseFloat(e):e,isNaN(e)?e=isNaN(o)?0:o:e>t?e=t:e<o&&(e=o),Math.round(1e3*e)/1e3},t.prototype.setNewValue=function(t){e.prototype.setNewValue.call(this,this.correctValue(t))},Object.defineProperty(t.prototype,"renderedValue",{get:function(){var e,t,o=(null!==(t=null!==(e=this.value)&&void 0!==e?e:this.renderedMin)&&void 0!==t?t:0).toString();return this.showUnitsInEditor&&(o+=this.unit),o},enumerable:!1,configurable:!0}),t.prototype.increase=function(){this.changeValue(!0)},t.prototype.decrease=function(){this.changeValue(!1)},t.prototype.onBeforeInput=function(e){var t=0==e.target.selectionStart?/[\d.-]/:/[\d.]/;e.data&&!t.test(e.data)&&e.preventDefault()},t.prototype.getType=function(){return"spinedit"},Object.defineProperty(t.prototype,"isInputTextUpdate",{get:function(){return!1},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"unit",void 0),J([(0,o.property)()],t.prototype,"_showUnitsInEditor",void 0),t}(o.QuestionTextModel);o.Serializer.addClass("spinedit",["unit"],(function(){return new Tn("")}),"text"),o.QuestionFactory.Instance.registerQuestion("spinedit",(function(e){return new Tn(e)}),!1);var Sn="#000000",Pn="#FFFFFF",En=function(e){function t(t){var o=e.call(this,t)||this;return o.allowEmptyValue=!1,o.createItemValues("choices"),o.registerFunctionOnPropertyValueChanged("choices",(function(){o.updateChoices()})),o}return K(t,e),t.prototype.getCorrectedValue=function(e){if(null==e||null==e||this.allowEmptyValue&&!e)return e;if((e=k(null!=e?e:"").color).indexOf("#")<0&&(e="#"+e),4===(e=(e.match(/#([0-9a-fA-F]){1,6}/)||[Sn])[0]).length){for(var t=e.slice(0,1),o=1;o<4;o++)t+=e[o]+e[o];e=t}if(e.length<7){var i=e.length;for(o=0;o<7-i;o++)e+="0"}return e},t.prototype.isNewValueEqualsToValue=function(t){return!(!e.prototype.isNewValueEqualsToValue.call(this,t)&&!this.isTwoValueEquals(t,this.value,!0,!0))},t.prototype.setNewValue=function(t){this.resetRenderedValue(),e.prototype.setNewValue.call(this,this.getCorrectedValue(t)),this.updateRenderedValue()},t.prototype.onBeforeInput=function(e){e.data&&!/[\d\w(),#]/.test(e.data)&&e.preventDefault()},t.prototype.onColorInputChange=function(e){this.value=e.target.value},t.prototype.getType=function(){return"color"},t.prototype.resetRenderedValue=function(){this._renderedValue=void 0},t.prototype.updateRenderedValue=function(){if(this.value){var e=k(this.value||"");this._renderedValue=e.color}else this.allowEmptyValue?this._renderedValue="":this._renderedValue=Sn},Object.defineProperty(t.prototype,"renderedValue",{get:function(){return this._renderedValue||""===this._renderedValue||this.updateRenderedValue(),this._renderedValue.toUpperCase()},enumerable:!1,configurable:!0}),t.prototype.getSwatchCss=function(){return(new o.CssClassBuilder).append(this.cssClasses.swatch).append(this.cssClasses.swatchDefault,!this.renderedValue).append(this.cssClasses.swatchDisabled,this.isInputReadOnly).toString()},t.prototype.getSwatchStyle=function(){return{backgroundColor:this.renderedValue||Pn}},Object.defineProperty(t.prototype,"renderedColorValue",{get:function(){return this.renderedValue||Pn},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isInputTextUpdate",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.onSurveyValueChanged=function(t){e.prototype.onSurveyValueChanged.call(this,t),this.updateRenderedValue()},Object.defineProperty(t.prototype,"dropdownAction",{get:function(){return this._dropdownAction||(this._dropdownAction=this.createDropdownAction()),this._dropdownAction},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"choices",{get:function(){return this.getPropertyValue("choices")},set:function(e){this.setPropertyValue("choices",e)},enumerable:!1,configurable:!0}),t.prototype.onTextKeyDownHandler=function(t){var o=this.dropdownAction.popupModel;"ArrowDown"===t.key&&this.dropdownAction.action(),o.isVisible||e.prototype.onTextKeyDownHandler.call(this,t)},Object.defineProperty(t.prototype,"showDropdownAction",{get:function(){return!this.isValueEmpty(this.choices)},enumerable:!1,configurable:!0}),t.prototype.createDropdownAction=function(){var e=this,t=(0,o.createDropdownActionModelAdvanced)({enabled:new o.ComputedUpdater((function(){return!e.isInputReadOnly}))},{onSelectionChanged:function(t){e.value=t.value},items:this.choices},{showPointer:!1,verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"});t.disableTabStop=!0;var i=t.popupModel,n=i.contentComponentData.model;return i.displayMode=o.IsTouch?"overlay":"popup",i.setWidthByTarget=!0,i.positionMode="fixed",n.isItemSelected=function(t){return t.value==e.value},t},t.prototype.calcCssClasses=function(t){var o=e.prototype.calcCssClasses.call(this,t),i=this.dropdownAction;i.cssClasses={item:o.colorDropdown},i.iconName=o.colorDropdownIcon;var n=i.popupModel.contentComponentData.model;return n.cssClasses={},n.cssClasses={itemBody:n.cssClasses.itemBody+" "+o.colorItem},o},t.prototype.updateChoices=function(){this.dropdownAction.popupModel.contentComponentData.model.setItems(this.choices)},Object.defineProperty(t.prototype,"itemComponent",{get:function(){return"color-item"},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"allowEmptyValue",void 0),J([(0,o.property)()],t.prototype,"_renderedValue",void 0),t}(o.QuestionTextModel);o.Serializer.addClass("color",[{name:"allowEmptyValue:boolean",default:!1},"choices:itemvalue[]"],(function(){return new En("")}),"text"),o.QuestionFactory.Instance.registerQuestion("color",(function(e){return new En(e)}),!1);var Vn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._renderedValue="",t.notEmptyValuePlaceholder="",t.onKeyDown=function(e){"INPUT"===e.target.tagName&&t.onTextKeyDownHandler(e)},t.onFileInputChange=function(e){if(!t.onChooseFilesCallback)return t.doChange(e),!0},t}return K(t,e),t.prototype.onChangeQuestionValue=function(e){},t.prototype.setNewValue=function(t){"object"==typeof t&&(this.stateChanged(this.isEmpty()?"empty":"loaded"),this.isLoadingFromJson||this.loadPreview(t),this.loadedFilesValue=t,t=this.previewValue[0].content),this.updateRenderedValue(t),e.prototype.setNewValue.call(this,t)},t.prototype.loadPreview=function(t){"string"!=typeof t&&e.prototype.loadPreview.call(this,t)},Object.defineProperty(t.prototype,"allowMultiple",{get:function(){return!1},set:function(e){},enumerable:!1,configurable:!0}),t.prototype.clear=function(e,t){var o=this;if(void 0===t&&(t=!0),this.survey){var i=function(){t&&(o.value=void 0),o.errors=[],e&&e()};this.loadedFilesValue?(this.containsMultiplyFiles=!1,this.survey.clearFiles(this.loadedFilesValue,this.name,this.previewValue,null,(function(e,t){"success"===e&&i()}))):i()}},Object.defineProperty(t.prototype,"renderedPlaceholder",{get:function(){return this.notEmptyValuePlaceholder||this.placeholder},enumerable:!1,configurable:!0}),t.prototype.updateRenderedValue=function(e){var t=e?e.match(/^data:((?:\w+\/(?:(?!;).)+)?)((?:;[\w\W]*?[^;])*),/):null;t?(this.notEmptyValuePlaceholder=t[0]+"...",this._renderedValue=""):(this.notEmptyValuePlaceholder="",this._renderedValue=e)},Object.defineProperty(t.prototype,"renderedValue",{get:function(){return this._renderedValue},enumerable:!1,configurable:!0}),t.prototype.updateValueFromInputEvent=function(e){var t=e.target.value;this.notEmptyValuePlaceholder&&!t||o.Helpers.isTwoValueEquals(t,this.value)||(this.clear(void 0,!1),this.loadedFilesValue=void 0,this.value=e.target.value)},t.prototype.onSurveyValueChanged=function(t){e.prototype.onSurveyValueChanged.call(this,t),this.updateRenderedValue(t)},t.prototype.onInputChange=function(e){e.target!==document.activeElement&&this.updateValueFromInputEvent(e)},t.prototype.onInputBlur=function(e){this.updateValueFromInputEvent(e)},t.prototype.getType=function(){return"fileedit"},t.prototype.getIsClearButtonDisabled=function(){return!this.value||this.isInputReadOnly},t.prototype.getChooseButtonCss=function(){return(new o.CssClassBuilder).append(this.cssClasses.chooseButton).append(this.cssClasses.chooseButtonDisabled,this.isInputReadOnly).toString()},t.prototype.chooseFiles=function(e){var t=this;if(this.isInputReadOnly||!this.onChooseFilesCallback)return!0;e.preventDefault(),e.stopPropagation();var o=this.rootElement.querySelectorAll("input[type='file']")[0];this.onChooseFilesCallback(o,(function(e){t.loadFiles(e)}))},J([(0,o.property)()],t.prototype,"_renderedValue",void 0),J([(0,o.property)()],t.prototype,"notEmptyValuePlaceholder",void 0),J([(0,o.property)()],t.prototype,"placeholder",void 0),t}(o.QuestionFileModel);o.Serializer.addClass("fileedit",["placeholder:string"],(function(){return new Vn("")}),"file"),o.QuestionFactory.Instance.registerQuestion("fileedit",(function(e){return new Vn(e)}),!1);var In=function(e){function t(t){var o=e.call(this)||this;return o.question=t,o}return K(t,e),t.prototype.resetValue=function(){this.resetValueCallback&&this.resetValueCallback()},Object.defineProperty(t.prototype,"isDisabled",{get:function(){return this.question.isInputReadOnly||!this.allowResetValue},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"allowResetValue",void 0),t}(o.Base),An=function(e){function t(t){var o=e.call(this,t)||this;return o.resetValueAdorner=o.createResetValueAdorner(),o}return K(t,e),t.prototype.createResetValueAdorner=function(){return new In(this)},t.prototype.getType=function(){return"textwithreset"},t.prototype.getRootClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.root).append(this.cssClasses.onError,this.errors.length>0).toString()},t.prototype.getControlClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.control).toString()},Object.defineProperty(t.prototype,"wrappedQuestionTemplate",{get:function(){return"text"},enumerable:!1,configurable:!0}),t}(o.QuestionTextModel);o.Serializer.addClass("textwithreset",[],(function(){return new An("")}),"text"),o.QuestionFactory.Instance.registerQuestion("textwithreset",(function(e){return new An(e)}),!1);var On=function(e){function t(t){var o=e.call(this,t)||this;return o.resetValueAdorner=o.createResetValueAdorner(),o}return K(t,e),t.prototype.createResetValueAdorner=function(){return new In(this)},t.prototype.getType=function(){return"commentwithreset"},t.prototype.getCssType=function(){return"textwithreset"},t.prototype.getRootClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.root).append(this.cssClasses.rootMultiline).append(this.cssClasses.onError,this.errors.length>0).toString()},t.prototype.getControlClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.control).append(this.cssClasses.controlMultiline).toString()},Object.defineProperty(t.prototype,"wrappedQuestionTemplate",{get:function(){return"comment"},enumerable:!1,configurable:!0}),t}(o.QuestionCommentModel);o.Serializer.addClass("commentwithreset",[{name:"allowResize:boolean",default:!1}],(function(){return new On("")}),"comment"),o.QuestionFactory.Instance.registerQuestion("commentwithreset",(function(e){return new On(e)}),!1);var Nn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"expression"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",showOptionsCaption:!1,rows:2}},t.prototype.clearPropertyValue=function(e,t,o,i){o.clearValue()},t}(lt),Ln=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"condition"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",showOptionsCaption:!1,rows:2}},t.prototype.canClearPropertyValue=function(e,t,o,i){return!1!==i.allowEditExpressionsInTextEditor},t.prototype.onSetup=function(e,t,o,i){!1===i.allowEditExpressionsInTextEditor&&(t.onKeyDownPreprocess=function(e){!e.ctrlKey&&["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Home","End"].indexOf(e.key)<0&&e.preventDefault()})},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new ro(e.getSurvey(),e,i,t.name)},t}(Nn);nt.register(new Nn),nt.register(new Ln);var _n=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i="item"),void 0===n&&(n=[]);var r=e.call(this,o)||this;return r.choices=t,r.className=i,r.names=n,r.commentValue=r.editSurvey.getQuestionByName("question"),r.setComment(),r.editSurvey.getQuestionByName("question").placeholder=G.getString("pe.fastEntryPlaceholder"),r.editSurvey.onValidateQuestion.add((function(e,t){var o=r.options.minimumChoicesCount;if(o>0)o>(i=r.getChoicesCount())&&(t.error=G.getString("pe.fastEntryChoicesMinCountError").format(o));else{var i,n=r.options.maximumChoicesCount;if(n>0)n<(i=r.getChoicesCount())&&(t.error=G.getString("pe.fastEntryChoicesCountError").format(i,n));else if(r.isValueUnique){var a=r.getFirstUniqueValue();a&&(t.error=G.getString("pe.fastEntryNonUniqueError").format(a))}}})),r}return K(t,e),t.prototype.calcBeforeApplyItemsArray=function(e,t,o){if(t&&0!=t.length){if(e.length>t.length&&e.splice(t.length,e.length-t.length),e.length<t.length){for(var i=[],n=e.length;n<t.length;n++)i.push(t[n]);e.splice.apply(e,[e.length,0].concat(i))}}else e.splice(0,e.length)},t.prototype.applyItemValueArray=function(e,t,o){void 0===o&&(o=[]),this.calcBeforeApplyItemsArray(e,t,o);for(var i=0;i<e.length;i++)o.forEach((function(o){e[i][o]=t[i][o]}))},t.prototype.getSurveyJSON=function(){return{elements:[{type:"comment",name:"question",titleLocation:"hidden",rows:12}]}},t.prototype.getSurveyCreationReason=function(){return"fast-entry"},t.prototype.apply=function(){return!this.comment.isEmpty()&&this.applyCore()},t.prototype.applyCore=function(){if(this.editSurvey.hasErrors(!0))return!1;var e=(this.comment.value||"").split("\n")||[],t=this.convertTextToItemValues(e);return t=this.options.onFastEntryCallback(t,e),this.applyItemValueArray(this.choices,t,this.names),!0},t.prototype.convertTextToItemValues=function(e){for(var t=[],i=0;i<e.length;i++)if(e[i]){var n=e[i].split(o.ItemValue.Separator),r=o.Serializer.createClass(this.className);this.names.forEach((function(e,t){r[e]=n[t]})),t.push(r)}return t},Object.defineProperty(t.prototype,"comment",{get:function(){return this.commentValue},enumerable:!1,configurable:!0}),t.prototype.getChoicesCount=function(){for(var e=this.comment.value.split("\n"),t=0,o=0;o<e.length;o++)e[o]&&t++;return t},Object.defineProperty(t.prototype,"isValueUnique",{get:function(){return!0===o.Serializer.findProperty("itemvalue","value").isUnique},enumerable:!1,configurable:!0}),t.prototype.getFirstUniqueValue=function(){for(var e=this.comment.value.split("\n"),t={},i=0;i<e.length;i++){var n=e[i];if(n){var r=n.split(o.ItemValue.Separator)[0];if(t[r])return r;t[r]=!0}}},t.prototype.setComment=function(){var e=this.convertItemValuesToText();this.comment.value=e},t.prototype.collectNames=function(e,t,i){var n="";return this.names.forEach((function(r){if("itemvalues"===t){if("value"==r)return;var a="text"==r?e.pureText:e[r]}else a=e[r];if(a){for(var s=0;s<i;s++)n+=o.ItemValue.Separator;n+=a,i=1}else i++})),n},t.prototype.convertItemValuesToText=function(){var e=this,t="";return this.choices.forEach((function(o){t&&(t+="\n"),t+=e.collectNames(o,"",0)})),t},t}(it),Mn=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i="itemvalue"),void 0===n&&(n=["value","text"]);var r=e.call(this,t,o,i,n)||this;return r.choices=t,r.className=i,r.names=n,r}return K(t,e),t.prototype.apply=function(){return this.applyCore()},t.prototype.applyItemValueArray=function(e,t,o){void 0===o&&(o=[]),this.calcBeforeApplyItemsArray(e,t,o);for(var i=0;i<e.length;i++)e[i].value!=t[i].value&&(e[i].value=t[i].value),e[i].text=t[i].hasText?t[i].text:"",o.forEach((function(o){"value"!=o&&"text"!=o&&(e[i][o]=t[i][o])}))},t.prototype.convertItemValuesToText=function(){var e=this,t="";return this.choices.forEach((function(o){t&&(t+="\n"),t+=o.value,t+=e.collectNames(o,"itemvalues",1)})),t},t}(_n);o.Serializer.addProperty("itemvalue",{name:"icon",isSerializable:!1,readOnly:!0,visibleIndex:0,visibleIf:function(e){return e&&"rateValues"===e.ownerPropertyName&&e.locOwner instanceof o.QuestionRatingModel&&"smileys"==e.locOwner.rateType}});var Dn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.getNewColumnName=function(e,t,o){var i=[];if(Array.isArray(e))for(var n=0;n<e.length;n++)i.push(e[n][t]);return h(o,i)},t.prototype.onCreated=function(e,t,o,i,n){var r=this;t.onGetValueForNewRowCallBack=function(e){return r.createNewItem(e,o)},this.setupMatrixQuestion(e,t,o,n)},t.prototype.onSetup=function(e,t,o,i){var n=t;n.allowRowsDragAndDrop&&n.dragDropMatrixRows&&(n.dragDropMatrixRows.onDragStart.add((function(){i.startUndoRedoTransaction()})),n.dragDropMatrixRows.onDragEnd.add((function(){i.stopUndoRedoTransaction()})))},t.prototype.initializePlaceholder=function(e,t,i){var n="function"==typeof e.getType&&e.getType();"text"===t.getType()&&n&&("text"===i&&"itemvalue"===n&&(t.placeholder=new o.ComputedUpdater((function(){return e.value?e.value.toString():e.text}))),"title"!==i||"matrixdropdowncolumn"!==n&&"multipletextitem"!==n||(t.placeholder=new o.ComputedUpdater((function(){return e.name?e.name:e.title}))))},t.prototype.onMatrixCellCreated=function(e,t){var i=t.row.editingObj;if(i){var n=t.cellQuestion;n.obj=i,this.initializePlaceholder(i,n,t.columnName),n.property=o.Serializer.findProperty(i.getType(),t.columnName)}},t.prototype.onGetMatrixRowAction=function(e,t,o){var i=this,n=t.question,r=t.row,a=t.actions;this.getEditItemAsStandAlone()&&a.push({id:"svd-grid-edit-column",iconName:"icon-edit",title:G.getString("pe.edit"),visibleIndex:0,showTitle:!1,location:"end",action:function(){var e=t.row.editingObj;o(e)}});var s=a.filter((function(e){return"show-detail"===e.id}))[0];Mt(n,a,r),s&&(s.component="sv-action-bar-item",s.iconName=this.getShowDetailActionIconName(r),s.showTitle=!1,s.location="end",s.ariaExpanded=r.isDetailPanelShowing,s.action=function(){r.showHideDetailPanelClick(),s.iconName=r.isDetailPanelShowing?"icon-editing-finish":"icon-edit"},s.visibleIndex=0,s.visible=this.hasPropertiesInDetail,r.onDetailPanelShowingChanged=function(){s.iconName=i.getShowDetailActionIconName(r),s.ariaExpanded=r.isDetailPanelShowing}),Dt(a)},t.prototype.getShowDetailActionIconName=function(e){return e.isDetailPanelShowing?"icon-editing-finish":"icon-edit"},t.prototype.addItem=function(e,t,o){o.addRow()},t.prototype.onGetQuestionTitleActions=function(e,t,i){var n=this,r=t.question;t.titleActions.push({id:"add-item",iconName:"icon-add",title:r.addRowText,showTitle:!1,action:function(){return n.addItem(i,e,r)},enabled:new o.ComputedUpdater((function(){return r.canAddRow}))})},t.prototype.createNewItem=function(e,i){e.visibleRows.forEach((function(e){return e.hideDetailPanel()}));var n=this.getBaseValue(i),r=this.getKeyValue();n||(n="item");var a=null;n&&r&&(a=t.getNewColumnName(e.value,r,n));var s=e.obj,l=o.Serializer.createClass(this.getDefaultClassName(s,i),{});a&&(l[r]=a),this.getObjTypeName()&&(l[this.getObjTypeName()]=l.getType());var u=s[i.name];return o.Serializer.isDescendantOf(l.getType(),"itemvalue")&&(l.text=d(u)),u.push(l),u!=e.value&&(e.value=u),l},t.prototype.getDefaultClassName=function(e,t){return t.className},t.prototype.getBaseValue=function(e){return e.getBaseValue()},t.prototype.getKeyValue=function(){return""},t.prototype.getColumnNames=function(e,t,o,i){var n=this.getPropertiesNames(e,t,o,i);return n&&n.length>0?n:this.getDefaultListProperties(t)},t.prototype.getColumnClassName=function(e,t){return t.className},t.prototype.getPropertiesNames=function(e,t,o,i){for(var n=[],r=this.getDefinedListProperties(e,t,o,i),a=0;a<r.length;a++)n.push(r[a].name);return 0==n.length&&(n=this.getDefaulColumnNames()),n},t.prototype.getDefinedListProperties=function(e,t,i,n){if(!t.className)return[];var r=o.Serializer.createClass(t.className);if(!r)return[];var a=new et(r,i,this.getColumnClassName(e,t),"list",e,t,n);return 0==a.getTabs().length?[]:a.getTabs()[0].properties},t.prototype.getDefaultListProperties=function(e){var t=[];if(e&&e.className)for(var i=o.Serializer.getProperties(e.className),n=0;n<i.length;n++)this.isPropertyShownInList(i[n])&&t.push(i[n].name);return t.length>0?t:this.getDefaulColumnNames()},t.prototype.getDefaulColumnNames=function(){return[]},t.prototype.isPropertyShownInList=function(e){return e.visible&&"form"!==e.showMode},t.prototype.getObjTypeName=function(){return""},t.prototype.hasDetailPanel=function(){return!this.getEditItemAsStandAlone()},t.prototype.setupMatrixQuestion=function(e,t,o,i){var n=this;this.hasPropertiesInDetail=this.hasDetailPanel()&&this.calcHasPropertiesInDetail(t,o,i),t.onHasDetailPanelCallback=function(e){return!1!==e.allowEditRow&&n.hasPropertiesInDetail},t.onCreateDetailPanelRenderedRowCallback=function(e){e.cells=[e.cells[1]],e.cells[0].colSpans+=2};var r=t;if(t.onCreateDetailPanelCallback=function(e,t){new at(e.editingObj,r.creatorOptions,r.obj,r.property,i).setupObjPanel(t,!0)},t.allowRowsDragAndDrop=this.getAllowRowDragDrop(o)&&!t.isReadOnly,r.creatorOptions&&this.setupUsingOptions(e,t,r.creatorOptions,o),o.uniquePropertyName){var a=t.getColumnByName(o.uniquePropertyName);a&&(a.isUnique=!0)}},t.prototype.getAllowRowDragDrop=function(e){return!1},t.prototype.calcHasPropertiesInDetail=function(e,t,i){if(!t.className)return!0;var n=o.Serializer.createClass(t.className);if(!n)return!0;var r=new o.PanelModel("");return new at(n,e.creatorOptions,e.obj,t,i).setupObjPanel(r,!0),r.elements.length>0},t.prototype.getJSON=function(e,t,o,i){return this.getMatrixJSON(e,t,this.getColumnNames(e,t,o,i),o,i)},t.prototype.getMatrixJSON=function(e,t,o,i,n){var r=t.className;r||(r=t.baseClassName);var a=this.getColumnsJSON(e,t,o,i,n),s={type:"matrixdynamic",detailPanelMode:"underRow",cellType:"text",rowCount:0,keyName:this.getKeyName(t),columns:a,showHeader:a.length>1,hideColumnsIfEmpty:!0,addRowText:this.getAddRowText(t),keyDuplicationError:G.getString("pe.propertyIsNoUnique"),emptyRowsText:this.getEmptyRowsText(t)};this.getShowDetailPanelOnAdding()&&(s.detailPanelShowOnAdding=!0);var l=this.getMinimumRowCount(e,t,i),u=this.getMaximumRowCount(e,t,i);return l>0&&(s.minRowCount=l),u>0&&(s.maxRowCount=u),s},t.prototype.getEmptyRowsText=function(e){var t="pe.listIsEmpty",o=t+"@"+e.name;return G.hasString(o)&&(t=o),G.getString(t)},t.prototype.getMinimumRowCount=function(e,t,o){return-1},t.prototype.getMaximumRowCount=function(e,t,o){return-1},t.prototype.filterPropertyNames=function(e,t){return e},t.prototype.getClassNameByProp=function(e){return e.className?e.className:e.baseClassName},t.prototype.getKeyName=function(e){var t=this.getClassNameByProp(e);if(!t)return"";for(var i=o.Serializer.getProperties(t),n=0;n<i.length;n++)if(i[n].isUnique)return i[n].name;return""},t.prototype.getColumnsJSON=function(e,t,o,i,n){for(var r=new at(e,i,void 0,void 0,n).createColumnsJSON(this.getClassNameByProp(t),this.filterPropertyNames(o,i)),a=0;a<r.length;a++)"comment"==r[a].cellType&&(r[a].cellType="text");return r},t.prototype.getEditItemAsStandAlone=function(){return!1},t.prototype.getShowDetailPanelOnAdding=function(){return!1},t.prototype.getAddRowText=function(e){var t="pe.addNew@"+e.name;return G.hasString(t)?G.getString(t):G.getString("pe.addNew")},t.prototype.setupUsingOptions=function(e,t,o,i){var n={allowAddRemoveItems:!0,allowRemoveAllItems:!0,showTextView:!0,allowBatchEdit:!0};o.onSetPropertyEditorOptionsCallback(i.name,e,n),n.allowAddRemoveItems||(t.allowAddRows=!1,t.allowRemoveRows=!1),t.allowRemoveAllItems=n.allowRemoveAllItems,t.showTextView=n.showTextView,t.allowBatchEdit=n.allowBatchEdit},t}(lt),kn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.isArray&&o.Serializer.isDescendantOf(e.className,"itemvalue")&&"rateValues"!=e.name},t.prototype.excludeTextPropertyName=function(e,t){return(null==t?void 0:t.inplaceEditForValues)?e.filter((function(e){return"text"!==e})):e},t.prototype.filterPropertyNames=function(e,t){return this.excludeTextPropertyName(e,t).filter((function(e){return"icon"!=e}))},t.prototype.isPropertyEditorSetupEnabled=function(e,t,o,i){if(!1===o.showTextView)return!1;var n=o.getColumnByName("value"),r=o.value;return!!n&&n.isVisible&&!n.readOnly&&!this.hasMultipleLanguage(r)&&!this.hasVisibleIfOrEnableIf(r)},t.prototype.getAllowRowDragDrop=function(e){return!0},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=o.columns.filter((function(e){return!e.readOnly})).map((function(e){return e.name}));return new Mn(e[t.name],i,t.className,n)},t.prototype.canClearPropertyValue=function(e,t,o,i){return!1!==o.allowRemoveAllItems},t.prototype.clearPropertyValue=function(e,t,o,i){var n=e[t.name];Array.isArray(n)&&n.splice(0,n.length)},t.prototype.getColumnClassName=function(e,t){return e.getType()+"@"+t.name},t.prototype.getDefaulColumnNames=function(){return["value","text"]},t.prototype.getKeyValue=function(){return"value"},t.prototype.getMatrixJSON=function(t,o,i,n,r){var a=e.prototype.getMatrixJSON.call(this,t,o,i,n,r);return"rateValues"===o.name&&"icon"==a.columns[0].name&&(a.showHeader=a.columns>3),a},t.prototype.getMinimumRowCount=function(t,o,i){return"choices"===o.name?i.minimumChoicesCount:e.prototype.getMaximumRowCount.call(this,t,o,i)},t.prototype.getMaximumRowCount=function(t,o,i){return"choices"===o.name?i.maximumChoicesCount:"rows"===o.name?i.maximumRowsCount:"columns"===o.name?i.maximumColumnsCount:"rateValues"===o.name?i.maximumRateValues:e.prototype.getMaximumRowCount.call(this,t,o,i)},t.prototype.hasMultipleLanguage=function(e){if(!e||!Array.isArray(e))return!1;for(var t=0;t<e.length;t++)if(e[t].locText.hasNonDefaultText())return!0;return!1},t.prototype.hasVisibleIfOrEnableIf=function(e){if(!e||!Array.isArray(e))return!1;for(var t=0;t<e.length;t++)if(e[t].visibleIf||e[t].enableIf)return!0;return!1},t.prototype.onMatrixCellCreated=function(t,i){function n(e,t){e.html='<div class="spg-smiley-icon"><svg><use xlink:href="#icon-'+t+'"></use></svg></div>'}e.prototype.onMatrixCellCreated.call(this,t,i),t instanceof o.QuestionRatingModel&&"icon"==i.columnName&&(n(i.cellQuestion,i.cellQuestion.value),i.cellQuestion.onPropertyChanged.add((function(e,t){"value"==t.name&&n(e,t.newValue)})))},t.prototype.onMatrixCellValueChanged=function(e,t){e instanceof o.QuestionRatingModel&&"icon"==t.columnName&&(t.cellQuestion.html=t.cellQuestion.value)},t}(Dn),jn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.isArray&&o.Serializer.isDescendantOf(e.className,"itemvalue")&&"rateValues"==e.name},t.prototype.updateAllowAddRemove=function(e,t){e.allowRemoveRows=pn.allowRemoveForElement(t),e.allowAddRows=pn.allowAddForElement(t,e.maxRowCount)},t.prototype.onCreated=function(t,o,i,n,r){var a=this;e.prototype.onCreated.call(this,t,o,i,n,r);var s=o,l=N(t);this.updateAllowAddRemove(s,l),t.onPropertyChanged.add((function(e,t){"rateCount"!=t.name&&"rateDisplayMode"!=t.name||a.updateAllowAddRemove(s,l)}))},t.prototype.onGetQuestionTitleActions=function(t,o,i){var n=o.titleActions.filter((function(e){return"property-grid-clear"==e.id}))[0];n&&(n.visible=!1),e.prototype.onGetQuestionTitleActions.call(this,t,o,i)},t.prototype.filterPropertyNames=function(e,t){return this.excludeTextPropertyName(e,t)},t}(kn),Rn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"matrixdropdowncolumns"==e.type},t.prototype.getEditItemAsStandAlone=function(){return!0},t.prototype.getDefaulColumnNames=function(){return["name","title"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"column"},t.prototype.getMaximumRowCount=function(e,t,o){return o.maximumColumnsCount},t.prototype.getAllowRowDragDrop=function(e){return!0},t}(Dn),Bn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"panellayoutcolumns"==e.type},t.prototype.getDefaulColumnNames=function(){return["width","questionTitleWidth"]},t.prototype.onMatrixCellCreated=function(t,o){e.prototype.onMatrixCellCreated.call(this,t,o),o.cellQuestion.textUpdateMode="onTyping"},t.prototype.onCreated=function(t,o,i,n,r){e.prototype.onCreated.call(this,t,o,i,n,r);var a=o;a.allowRemoveRows=!1,a.allowAddRows=!1},t}(Dn),qn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"surveypages"==e.type},t.prototype.addItem=function(e,t,o){e.addPage(void 0,!1)},t.prototype.getColumnClassName=function(e,t){return"page@"+e.getType()},t.prototype.getDefaulColumnNames=function(){return["name","title"]},t.prototype.hasDetailPanel=function(){return!1},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"page"},t.prototype.getAllowRowDragDrop=function(e){return!0},t}(Dn),Hn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"calculatedvalues"==e.type},t.prototype.getColumnClassName=function(e,t){return"calculatedvalue@items"},t.prototype.getDefaulColumnNames=function(){return["name"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"var"},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t.prototype.setupMatrixQuestion=function(t,o,i,n){e.prototype.setupMatrixQuestion.call(this,t,o,i,n),o.isUniqueCaseSensitive=!1},t}(Dn),Qn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"htmlconditions"==e.type},t.prototype.getDefaulColumnNames=function(){return["html"]},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Dn),Fn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"urlconditions"==e.type},t.prototype.getDefaulColumnNames=function(){return["url"]},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Dn),Un=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"textitem[]"==e.type},t.prototype.getEditItemAsStandAlone=function(){return!0},t.prototype.getColumnClassName=function(e,t){return"multipletext@items"},t.prototype.getDefaulColumnNames=function(){return["name"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"item"},t.prototype.getAllowRowDragDrop=function(){return!0},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=[];return o.columns.forEach((function(e){n.push(e.name)})),new _n(e[t.name],i,t.className,n)},t.prototype.onMatrixCellCreated=function(t,i){e.prototype.onMatrixCellCreated.call(this,t,i);var n=i.cellQuestion;if(i.row.editingObj){var r=i.row.editingObj.editor;r&&n.property&&r.registerFunctionOnPropertyValueChanged(n.property.name,(function(){n.value=o.Serializer.getObjPropertyValue(r,n.property.name)}))}},t}(Dn),Gn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getColumnsJSON=function(t,o,i,n,r){var a=e.prototype.getColumnsJSON.call(this,t,o,i,n,r);return this.getObjTypeName()&&a.unshift({name:this.getObjTypeName(),cellType:"dropdown"}),a},t.prototype.onMatrixCellCreated=function(t,o){if(e.prototype.onMatrixCellCreated.call(this,t,o),o.row.editingObj){var i=o.cellQuestion;o.columnName===this.getObjTypeName()&&(i.showOptionsCaption=!1,i.choices=this.getChoices(t),i.value=o.row.editingObj.getType())}},t.prototype.onMatrixCellValueChanged=function(e,t){if(t.columnName===this.getObjTypeName()){var i=t.question.visibleRows.indexOf(t.row);if(!(i<0)){var n=t.row.isDetailPanelShowing,r=t.row.editingObj.toJSON();delete r.type;var a=o.Serializer.createClass(t.value);a.fromJSON(r),a[this.getObjTypeName()]=a.getType(),t.row.hideDetailPanel(!0),t.question.value.splice(i,1,a),t.row.value=a,n&&t.row.showDetailPanel()}}},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Dn),Zn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"validators"==e.type},t.prototype.getObjTypeName=function(){return"validatorType"},t.prototype.getDefaultClassName=function(e,t){var o="expression",i=e;if(i.getSupportedValidators){var n=i.getSupportedValidators();n.length>0&&n.indexOf(o)<0&&(o=n[0])}return o+"validator"},t.prototype.getChoices=function(e){for(var t=this.getSupportedValidators(e),o=[],i=0;i<t.length;i++){var n=t[i]+"validator";o.push({value:n,text:G.getValidatorName(n)})}return o},t.prototype.getSupportedValidators=function(e){return e?e.getSupportedValidators?e.getSupportedValidators():e.getOriginalObj?this.getSupportedValidators(e.getOriginalObj()):[]:[]},t}(Gn),zn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getAvailableTriggers=function(){return o.Serializer.getChildrenClasses("surveytrigger",!0).filter((function(e){return"visibletrigger"!==e.name}))},t.prototype.fit=function(e){return"triggers"==e.type},t.prototype.getObjTypeName=function(){return"triggerType"},t.prototype.getDefaultClassName=function(e,t){var o=this.getAvailableTriggers().map((function(e){return e.name}));return o.length?-1!==o.indexOf("runexpressiontrigger")?"runexpressiontrigger":o[0]:t.name},t.prototype.getAllowRowDragDrop=function(e){return!0},t.prototype.getChoices=function(e){return this.getAvailableTriggers().map((function(e){return{value:e.name,text:G.getTriggerName(e.name)}}))},t}(Gn);nt.register(new kn),nt.register(new jn),nt.register(new Rn),nt.register(new qn),nt.register(new Hn),nt.register(new Qn),nt.register(new Fn),nt.register(new Un),nt.register(new Zn),nt.register(new zn),nt.register({fit:function(e){return"icon"===e.name&&"itemvalue"===e.classInfo.name},getJSON:function(e){return{type:"html"}}}),nt.register(new Bn);var Jn={name:"propertygrid_bindings",showInToolbox:!1,internal:!0,createElements:function(){}};o.ComponentCollection.Instance.getCustomQuestionByName(Jn.name)||o.ComponentCollection.Instance.add(Jn);var Wn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"bindings"==e.type},t.prototype.getJSON=function(){return{type:"propertygrid_bindings"}},t.prototype.onCreated=function(e,t,o,i){t.contentPanel.fromJSON({elements:this.getQuestions(e,i)}),t.valueFromDataCallback=function(t){if(!t&&e.bindings.getNames().length>0){for(var o={},i=0,n=e.bindings.getNames();i<n.length;i++){var r=n[i];o[r]=e.bindings.getValueNameByPropertyName(r)}return o}return t}},t.prototype.getQuestions=function(e,t){for(var o=[],i=0,n=e.bindings.getNames();i<n.length;i++){var r=n[i];o.push(this.getBindingJSON(r,e,t))}return o},t.prototype.getBindingJSON=function(e,t,i){var n=new o.JsonObjectProperty(null,"value");n.type="questionvalue";var r=nt.getJSON(t,n,i);return r.titleLocation="left",r.descriptionLocation="hidden",r.minWidth="0px",r.name=e,r.title=G.getPropertyName(e),r},t}(lt);nt.register(new Wn);var Kn={name:"propertygrid_restfull",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(Kn.name)||o.ComponentCollection.Instance.add(Kn);var Yn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"restfull"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_restfull",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i,n){var r=t.contentPanel,a=e[o.name];new at(a,i,e,o,n).setupObjPanel(r,!0);var s=r.addNewQuestion("dropdown","test");s.title=G.getString("ed.choicesLoadedFromWebPreviewTitle"),s.choices=[],this.updateTestQuestion(s,a)},t.prototype.onValueChanged=function(e,t,o){if("choicesByUrl"===t.name){var i=o.contentPanel.getQuestionByName("test");this.updateTestQuestion(i,e[t.name])}},t.prototype.updateTestQuestion=function(e,t){t&&(e.visible=!!t.url,e.choicesByUrl.setData(t))},t}(It);nt.register(new Yn);var Xn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"font"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"font",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt);nt.register(new Xn);var $n=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"backgroundcornerradius"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"backgroundcornerradius",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt);nt.register(new $n);var er=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"shadoweffects"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"shadoweffects",descriptionLocation:"hidden"}},t}(lt);nt.register(new er);var tr=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,o)||this;return i.matrix=t,i.editMatrixValue=i.editSurvey.getQuestionByName("question"),i.buildColumns(),i.buildRows(),i.editMatrix.value=i.matrix.cells.getJson(),i}return K(t,e),t.prototype.getSurveyJSON=function(){return{elements:[{type:"matrixdropdown",name:"question",cellType:"comment"}]}},t.prototype.getSurveyCreationReason=function(){return"cells-editor"},Object.defineProperty(t.prototype,"editMatrix",{get:function(){return this.editMatrixValue},enumerable:!1,configurable:!0}),t.prototype.apply=function(){return this.matrix.cells.setJson(this.editMatrix.value),!0},t.prototype.buildColumns=function(){for(var e=this.matrix.columns,t=0;t<e.length;t++)this.editMatrix.addColumn(""+e[t].value,e[t].text)},t.prototype.buildRows=function(){this.editMatrix.rows.push(new o.ItemValue("default",G.getString("pe.cellsDefaultRow")));for(var e=this.matrix.rows,t=0;t<e.length;t++)this.editMatrix.rows.push(new o.ItemValue(e[t].value,e[t].text))},t}(it),or=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,i,!1)||this;return n.editQuestion=t,n.propertyName=o,n.setupSurvey(),n.question.value=n.getQuestionValue(),n}return K(t,e),Object.defineProperty(t.prototype,"question",{get:function(){return this.editSurvey.getQuestionByName("question")},enumerable:!1,configurable:!0}),t.prototype.getSurveyJSON=function(){return{elements:[this.getQuestionJSON()]}},t.prototype.getQuestionJSON=function(){var e=this.editQuestion.toJSON();return e.name="question",e.title=e.title||this.editQuestion.name,e.type=this.editQuestion.getType(),"expression"==e.type&&(e.type="text"),e.cellType&&"matrixdropdowncolumn"==e.type&&(e.type=e.cellType,delete e.cellType),ee.updateQuestionJson(e),e},t.prototype.getQuestionValue=function(){return this.editQuestion[this.propertyName]},t.prototype.getEditValue=function(){return this.question.value},t.prototype.getSurveyCreationReason=function(){return"default-value"},t.prototype.apply=function(){return this.editQuestion[this.propertyName]=this.getEditValue(),!0},t}(it),ir=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionValue=function(){var t=e.prototype.getQuestionValue.call(this);return t?(Array.isArray(t)||(t=[t]),t):t},t.prototype.getEditValue=function(){var t=e.prototype.getEditValue.call(this);return t&&Array.isArray(t)?0==t.length?null:t[0]:t},t}(or),nr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionJSON=function(){var t=e.prototype.getQuestionJSON.call(this);return t.type="matrixdynamic",t.rowCount=1,t.minRowCount=1,t.maxRowCount=1,t.columnsLocation="vertical",delete t.defaultValue,t},t}(ir),rr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionJSON=function(){var t=e.prototype.getQuestionJSON.call(this);return t.panelCount=1,t.minPanelCount=1,t.maxPanelCount=1,t},t}(ir),ar=function(e){function t(t,o,i,n){void 0===n&&(n=null);var r=e.call(this,t,i,n)||this;return r.editQuestion=t,r.editObj=o,r.propertyName=i,r.question.value=r.getQuestionValue(),r}return K(t,e),t.prototype.getQuestionValue=function(){return this.editObj?this.editObj[this.propertyName]:null},t.prototype.apply=function(){return this.editObj[this.propertyName]=this.question.value,!0},t}(or),sr=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onCreated=function(e,o,i,n){var r=o;r.isClickableCallback=function(){return!r.isReadOnly||!t.isValueEmpty(r.value)},r.linkClickCallback=function(){t.showModalPropertyEditor(t,i,o,n,(function(){return r.isSelected=!1})),r.isSelected=!0},r.clearClickCallback=function(){t.clearPropertyValue(o.obj,i,o,null)}},t}return K(t,e),t.prototype.getJSON=function(e,t,o){return{type:"linkvalue",showValueInLink:!1,titleLocation:"hidden"}},t.prototype.clearPropertyValue=function(e,t,o,i){e[t.name]=void 0},t.prototype.isValueEmpty=function(e){return o.Helpers.isValueEmpty(e)},t.prototype.isSupportGrouping=function(){return!0},t}(lt),lr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"cells"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new tr(e,i)},t.prototype.clearPropertyValue=function(e,t,o,i){e.cells.setJson(null)},t.prototype.isValueEmpty=function(e){return!e||o.Helpers.isValueEmpty(e.values)},t}(sr),ur=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"value"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new or(e,t.name,i)},t}(sr),pr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"rowvalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new nr(e,t.name,i)},t}(sr),cr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"panelvalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new rr(e,t.name,i)},t}(sr),dr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"triggervalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=o.obj,r=this.getSetToNameQuestion(n);return new ar(r,n,t.name,i)},t.prototype.getSetToNameQuestion=function(e){var t=e.getSurvey();return t||(t=e.owner),e.setToName&&t?t.getQuestionByValueName(e.setToName):null},t}(sr),hr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"logic"===t&&"triggervalue"==e.type},t.prototype.getJSON=function(e,t,o){var i=this.getSetToNameQuestion(e);if(!i)return{type:"linkvalue"};var n=i.toJSON();return n.type=i.getType(),ee.updateQuestionJson(n),n},t}(dr);nt.register(new lr),nt.register(new ur),nt.register(new pr),nt.register(new cr),nt.register(new dr),nt.register(new hr);var gr={name:"propertygrid_masksettings",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(gr.name)||o.ComponentCollection.Instance.add(gr);var mr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"masksettings"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_masksettings",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i){var n=e[o.name];this._propertyGrid=new at(n,i,e,o),this._prevMaskType="";var r=t.contentPanel;this._previewQuestion=r.addNewQuestion("html","preview"),this.updatePanel(e,t,o)},t.prototype.onValueChanged=function(e,t,o){"maskSettings"===t.name&&this.updatePanel(e,o,t)},t.prototype.updatePanel=function(e,t,o){var i=t.contentPanel,n=e[o.name];this._prevMaskType!==e.maskType&&(this._propertyGrid.obj=n,this._propertyGrid.setupObjPanel(i,!0),this._prevMaskType=e.maskType),"datetimemask"==n.getType()&&this.updateDateTimeMinMaxInputType(n,i),this.updatePreviewQuestion(n,i)},t.prototype.updateDateTimeMinMaxInputType=function(e,t){var o="datetime-local";e.hasDatePart||(o="time"),e.hasTimePart||(o="date"),t.getQuestionByName("min").inputType=o,t.getQuestionByName("max").inputType=o},t.prototype.updatePreviewQuestion=function(e,t){this._previewQuestion.visible="masksettings"===e.getType(),t.getElementByName(this._previewQuestion.name)||t.addElement(this._previewQuestion)},t}(lt);nt.register(new mr);var fr={name:"propertygrid_header",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(fr.name)||o.ComponentCollection.Instance.add(fr);var yr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"header"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_header",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i,n){var r,a=t.contentPanel,s=e[o.name];new at(s,i,e,o,Oi).setupObjPanel(a,!0);for(var l=a.elements,u=0;u<l.length;u++)"settings"==l[u].name&&(r=l[u]);r.state=void 0,r.title="",r.elements.forEach((function(e){e.title="",e.state=void 0}))},t}(lt);nt.register(new yr);var vr=n(7288);o.SvgRegistry.registerIconsFromFolder(vr);var br,Cr=function(){function e(){this.onApplied=new o.EventBase,this.children=[],this.setupPresets()}return e.prototype.setJson=function(e){var t=this;!e&&this.applyEmptyJson()&&(e={}),this.json=e,this.children.forEach((function(e){return e.setJson(t.json&&e.getPath()?t.json[e.getPath()]:t.json)}))},e.prototype.apply=function(e){this.json&&(e&&(this.applyCore(e),this.children.forEach((function(t){return t.apply(e)}))),this.onApplied.fire(this,{}))},e.prototype.applyEmptyJson=function(){return!1},e.prototype.applyCore=function(e){},e.prototype.createPresets=function(){return[]},e.prototype.setupPresets=function(){this.addPresets(this.createPresets())},e.prototype.addPreset=function(e){this.children.push(e)},e.prototype.addPresets=function(e){var t=this;e.forEach((function(e){return t.addPreset(e)}))},e}(),wr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"definition"},t.prototype.applyCore=function(t){e.prototype.applyCore.call(this,t),this.applyDefinition(t,this.json)},t.prototype.applyDefinition=function(e,t){var o=e.toolbox;o.presetDefaultItems=this.getPresetDefaultItems(t),Array.isArray(t)&&t.forEach((function(e){var t=o.getActionById(e.name);t&&["iconName","title","tooltip","json"].forEach((function(o){e[o]&&(t[o]=e[o])}))}))},t.prototype.getPresetDefaultItems=function(e){if(Array.isArray(e)){var t=JSON.parse(JSON.stringify(e)),o=new Array;return t.forEach((function(e){"object"==typeof e&&e.name&&o.push(e)})),o}},t}(Cr),xr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return""},t.prototype.applyCore=function(t){this.json&&(e.prototype.applyCore.call(this,t),t.toolbox.showCategoryTitles=this.json.showCategoryTitles,this.applyItems(t,this.json.items),this.applyCategories(t,this.json.categories))},t.prototype.applyItems=function(e,t){Array.isArray(t)&&(e.toolbox.hasCategories=!1,e.toolbox.defineCategories([{category:"general",items:t}]))},t.prototype.applyCategories=function(e,t){Array.isArray(t)&&(e.toolbox.hasCategories=!0,e.toolbox.defineCategories(t))},t}(Cr),Tr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"toolbox"},t.prototype.createPresets=function(){return[new wr,new xr]},t}(Cr),Sr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"languages"},t.prototype.applyEmptyJson=function(){return!0},t.prototype.applyCore=function(t){var i,n,r;e.prototype.applyCore.call(this,t);var a=(null===(i=this.json)||void 0===i?void 0:i.creator)||"",s=(null===(n=this.json)||void 0===n?void 0:n.surveyLocales)||[],l=null===(r=this.json)||void 0===r?void 0:r.useEnglishNames;t.locale=a,o.surveyLocalization.supportedLocales=s,o.surveyLocalization.showNamesInEnglish=!0===l},t}(Cr),Pr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"tabs"},t.prototype.applyCore=function(t){e.prototype.applyCore.call(this,t);var o=this.json.items||[],i=this.json.activeTab||(o.length>0?o[0]:"");if(o.length>0&&o.indexOf(i)<0&&(i=o[0]),i&&t.activeTab!==i){var n=t.getPlugin(t.activeTab);(null==n?void 0:n.deactivate)&&n.deactivate()}this.applyTabs(t,o),i&&(t.activeTab="preview"===i?"test":i)},t.prototype.applyTabs=function(e,t){Array.isArray(t)&&e.setTabs(t)},t}(Cr),Er=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"definition"},t.prototype.applyCore=function(e){e.setPropertyGridDefinition(this.json)},t}(Cr),Vr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"propertyGrid"},t.prototype.createPresets=function(){return[new Er]},t}(Cr),Ir=function(e){function t(t){var o=e.call(this)||this;return o.setJson(t),o}return K(t,e),t.prototype.getPath=function(){return""},t.prototype.getJson=function(){return this.json},t.prototype.apply=function(t){e.prototype.apply.call(this,t),this.applyLocalization(),t&&t.updateLocalizedStrings()},t.prototype.applyLocalization=function(){var e,t=null===(e=this.json)||void 0===e?void 0:e.localization;G.presetStrings=t?JSON.parse(JSON.stringify(t)):void 0},t.prototype.createPresets=function(){return[new Sr,new Pr,new Tr,new Vr]},t}(Cr);br="".concat("1.12.6"),n(5175),n(7167),n(9845),n(6681),n(5187),n(9336),n(422),n(9991),n(4607),n(7231),n(326),n(1119),n(7671),n(3193),o.settings.supportCreatorV2=!0,(0,o.checkLibraryVersion)("".concat("1.12.6"),"survey-creator-core")})(),r})()));
|
|
2
|
+
!function(e,t){"object"==typeof exports&&"object"==typeof module?module.exports=t(require("survey-core"),require("survey-creator-core/themes"),require("survey-core/themes")):"function"==typeof define&&define.amd?define("survey-creator-core",["survey-core","survey-creator-core/themes","survey-core/themes"],t):"object"==typeof exports?exports["survey-creator-core"]=t(require("survey-core"),require("survey-creator-core/themes"),require("survey-core/themes")):e.SurveyCreatorCore=t(e.Survey,e.SurveyCreatorTheme,e.SurveyTheme)}(this,((e,t,o)=>(()=>{var i={264:(e,t,o)=>{"use strict";o.r(t)},9281:(e,t,o)=>{"use strict";o.r(t)},1383:(e,t,o)=>{"use strict";o.r(t)},6195:(e,t,o)=>{"use strict";o.r(t)},2996:(e,t,o)=>{"use strict";o.r(t)},3952:(e,t,o)=>{"use strict";o.r(t)},7205:(e,t,o)=>{"use strict";o.r(t)},9671:(e,t,o)=>{"use strict";o.r(t)},4767:(e,t,o)=>{"use strict";o.r(t)},7167:(e,t,o)=>{"use strict";o.r(t)},9845:(e,t,o)=>{"use strict";o.r(t)},422:(e,t,o)=>{"use strict";o.r(t)},3140:(e,t,o)=>{"use strict";o.r(t)},3926:(e,t,o)=>{"use strict";o.r(t)},3844:(e,t,o)=>{"use strict";o.r(t)},9414:(e,t,o)=>{"use strict";o.r(t)},4880:(e,t,o)=>{"use strict";o.r(t)},4607:(e,t,o)=>{"use strict";o.r(t)},7231:(e,t,o)=>{"use strict";o.r(t)},8538:(e,t,o)=>{"use strict";o.r(t)},8445:(e,t,o)=>{"use strict";o.r(t)},3071:(e,t,o)=>{"use strict";o.r(t)},6681:(e,t,o)=>{"use strict";o.r(t)},5187:(e,t,o)=>{"use strict";o.r(t)},5876:(e,t,o)=>{"use strict";o.r(t)},1497:(e,t,o)=>{"use strict";o.r(t)},8380:(e,t,o)=>{"use strict";o.r(t)},790:(e,t,o)=>{"use strict";o.r(t)},5377:(e,t,o)=>{"use strict";o.r(t)},5625:(e,t,o)=>{"use strict";o.r(t)},4340:(e,t,o)=>{"use strict";o.r(t)},1868:(e,t,o)=>{"use strict";o.r(t)},4163:(e,t,o)=>{"use strict";o.r(t)},9336:(e,t,o)=>{"use strict";o.r(t)},9991:(e,t,o)=>{"use strict";o.r(t)},6190:(e,t,o)=>{"use strict";o.r(t)},3193:(e,t,o)=>{"use strict";o.r(t)},326:(e,t,o)=>{"use strict";o.r(t)},9118:(e,t,o)=>{"use strict";o.r(t)},5175:(e,t,o)=>{"use strict";o.r(t)},1119:(e,t,o)=>{"use strict";o.r(t)},7671:(e,t,o)=>{"use strict";o.r(t)},4809:function(e,t){var o,i;o=function e(){"use strict";var t="undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==t?t:{},o=!t.document&&!!t.postMessage,i=t.IS_PAPA_WORKER||!1,n={},r=0,a={parse:function(o,i){var s=(i=i||{}).dynamicTyping||!1;if(w(s)&&(i.dynamicTypingFunction=s,s={}),i.dynamicTyping=s,i.transform=!!w(i.transform)&&i.transform,i.worker&&a.WORKERS_SUPPORTED){var l=function(){if(!a.WORKERS_SUPPORTED)return!1;var o,i,s=(o=t.URL||t.webkitURL||null,i=e.toString(),a.BLOB_URL||(a.BLOB_URL=o.createObjectURL(new Blob(["var global = (function() { if (typeof self !== 'undefined') { return self; } if (typeof window !== 'undefined') { return window; } if (typeof global !== 'undefined') { return global; } return {}; })(); global.IS_PAPA_WORKER=true; ","(",i,")();"],{type:"text/javascript"})))),l=new t.Worker(s);return l.onmessage=f,l.id=r++,n[l.id]=l}();return l.userStep=i.step,l.userChunk=i.chunk,l.userComplete=i.complete,l.userError=i.error,i.step=w(i.step),i.chunk=w(i.chunk),i.complete=w(i.complete),i.error=w(i.error),delete i.worker,void l.postMessage({input:o,config:i,workerId:l.id})}var h=null;return a.NODE_STREAM_INPUT,"string"==typeof o?(o=function(e){return 65279===e.charCodeAt(0)?e.slice(1):e}(o),h=i.download?new u(i):new c(i)):!0===o.readable&&w(o.read)&&w(o.on)?h=new d(i):(t.File&&o instanceof File||o instanceof Object)&&(h=new p(i)),h.stream(o)},unparse:function(e,t){var o=!1,i=!0,n=",",r="\r\n",s='"',l=s+s,u=!1,p=null,c=!1;!function(){if("object"==typeof t){if("string"!=typeof t.delimiter||a.BAD_DELIMITERS.filter((function(e){return-1!==t.delimiter.indexOf(e)})).length||(n=t.delimiter),("boolean"==typeof t.quotes||"function"==typeof t.quotes||Array.isArray(t.quotes))&&(o=t.quotes),"boolean"!=typeof t.skipEmptyLines&&"string"!=typeof t.skipEmptyLines||(u=t.skipEmptyLines),"string"==typeof t.newline&&(r=t.newline),"string"==typeof t.quoteChar&&(s=t.quoteChar),"boolean"==typeof t.header&&(i=t.header),Array.isArray(t.columns)){if(0===t.columns.length)throw new Error("Option columns is empty");p=t.columns}void 0!==t.escapeChar&&(l=t.escapeChar+s),("boolean"==typeof t.escapeFormulae||t.escapeFormulae instanceof RegExp)&&(c=t.escapeFormulae instanceof RegExp?t.escapeFormulae:/^[=+\-@\t\r].*$/)}}();var d=new RegExp(g(s),"g");if("string"==typeof e&&(e=JSON.parse(e)),Array.isArray(e)){if(!e.length||Array.isArray(e[0]))return h(null,e,u);if("object"==typeof e[0])return h(p||Object.keys(e[0]),e,u)}else if("object"==typeof e)return"string"==typeof e.data&&(e.data=JSON.parse(e.data)),Array.isArray(e.data)&&(e.fields||(e.fields=e.meta&&e.meta.fields||p),e.fields||(e.fields=Array.isArray(e.data[0])?e.fields:"object"==typeof e.data[0]?Object.keys(e.data[0]):[]),Array.isArray(e.data[0])||"object"==typeof e.data[0]||(e.data=[e.data])),h(e.fields||[],e.data||[],u);throw new Error("Unable to serialize unrecognized input");function h(e,t,o){var a="";"string"==typeof e&&(e=JSON.parse(e)),"string"==typeof t&&(t=JSON.parse(t));var s=Array.isArray(e)&&0<e.length,l=!Array.isArray(t[0]);if(s&&i){for(var u=0;u<e.length;u++)0<u&&(a+=n),a+=m(e[u],u);0<t.length&&(a+=r)}for(var p=0;p<t.length;p++){var c=s?e.length:t[p].length,d=!1,h=s?0===Object.keys(t[p]).length:0===t[p].length;if(o&&!s&&(d="greedy"===o?""===t[p].join("").trim():1===t[p].length&&0===t[p][0].length),"greedy"===o&&s){for(var g=[],f=0;f<c;f++){var y=l?e[f]:f;g.push(t[p][y])}d=""===g.join("").trim()}if(!d){for(var v=0;v<c;v++){0<v&&!h&&(a+=n);var b=s&&l?e[v]:v;a+=m(t[p][b],v)}p<t.length-1&&(!o||0<c&&!h)&&(a+=r)}}return a}function m(e,t){if(null==e)return"";if(e.constructor===Date)return JSON.stringify(e).slice(1,25);var i=!1;c&&"string"==typeof e&&c.test(e)&&(e="'"+e,i=!0);var r=e.toString().replace(d,l);return(i=i||!0===o||"function"==typeof o&&o(e,t)||Array.isArray(o)&&o[t]||function(e,t){for(var o=0;o<t.length;o++)if(-1<e.indexOf(t[o]))return!0;return!1}(r,a.BAD_DELIMITERS)||-1<r.indexOf(n)||" "===r.charAt(0)||" "===r.charAt(r.length-1))?s+r+s:r}}};if(a.RECORD_SEP=String.fromCharCode(30),a.UNIT_SEP=String.fromCharCode(31),a.BYTE_ORDER_MARK="\ufeff",a.BAD_DELIMITERS=["\r","\n",'"',a.BYTE_ORDER_MARK],a.WORKERS_SUPPORTED=!o&&!!t.Worker,a.NODE_STREAM_INPUT=1,a.LocalChunkSize=10485760,a.RemoteChunkSize=5242880,a.DefaultDelimiter=",",a.Parser=m,a.ParserHandle=h,a.NetworkStreamer=u,a.FileStreamer=p,a.StringStreamer=c,a.ReadableStreamStreamer=d,t.jQuery){var s=t.jQuery;s.fn.parse=function(e){var o=e.config||{},i=[];return this.each((function(e){if("INPUT"!==s(this).prop("tagName").toUpperCase()||"file"!==s(this).attr("type").toLowerCase()||!t.FileReader||!this.files||0===this.files.length)return!0;for(var n=0;n<this.files.length;n++)i.push({file:this.files[n],inputElem:this,instanceConfig:s.extend({},o)})})),n(),this;function n(){if(0!==i.length){var t,o,n,l=i[0];if(w(e.before)){var u=e.before(l.file,l.inputElem);if("object"==typeof u){if("abort"===u.action)return t=l.file,o=l.inputElem,n=u.reason,void(w(e.error)&&e.error({name:"AbortError"},t,o,n));if("skip"===u.action)return void r();"object"==typeof u.config&&(l.instanceConfig=s.extend(l.instanceConfig,u.config))}else if("skip"===u)return void r()}var p=l.instanceConfig.complete;l.instanceConfig.complete=function(e){w(p)&&p(e,l.file,l.inputElem),r()},a.parse(l.file,l.instanceConfig)}else w(e.complete)&&e.complete()}function r(){i.splice(0,1),n()}}}function l(e){this._handle=null,this._finished=!1,this._completed=!1,this._halted=!1,this._input=null,this._baseIndex=0,this._partialLine="",this._rowCount=0,this._start=0,this._nextChunk=null,this.isFirstChunk=!0,this._completeResults={data:[],errors:[],meta:{}},function(e){var t=b(e);t.chunkSize=parseInt(t.chunkSize),e.step||e.chunk||(t.chunkSize=null),this._handle=new h(t),(this._handle.streamer=this)._config=t}.call(this,e),this.parseChunk=function(e,o){if(this.isFirstChunk&&w(this._config.beforeFirstChunk)){var n=this._config.beforeFirstChunk(e);void 0!==n&&(e=n)}this.isFirstChunk=!1,this._halted=!1;var r=this._partialLine+e;this._partialLine="";var s=this._handle.parse(r,this._baseIndex,!this._finished);if(!this._handle.paused()&&!this._handle.aborted()){var l=s.meta.cursor;this._finished||(this._partialLine=r.substring(l-this._baseIndex),this._baseIndex=l),s&&s.data&&(this._rowCount+=s.data.length);var u=this._finished||this._config.preview&&this._rowCount>=this._config.preview;if(i)t.postMessage({results:s,workerId:a.WORKER_ID,finished:u});else if(w(this._config.chunk)&&!o){if(this._config.chunk(s,this._handle),this._handle.paused()||this._handle.aborted())return void(this._halted=!0);s=void 0,this._completeResults=void 0}return this._config.step||this._config.chunk||(this._completeResults.data=this._completeResults.data.concat(s.data),this._completeResults.errors=this._completeResults.errors.concat(s.errors),this._completeResults.meta=s.meta),this._completed||!u||!w(this._config.complete)||s&&s.meta.aborted||(this._config.complete(this._completeResults,this._input),this._completed=!0),u||s&&s.meta.paused||this._nextChunk(),s}this._halted=!0},this._sendError=function(e){w(this._config.error)?this._config.error(e):i&&this._config.error&&t.postMessage({workerId:a.WORKER_ID,error:e,finished:!1})}}function u(e){var t;(e=e||{}).chunkSize||(e.chunkSize=a.RemoteChunkSize),l.call(this,e),this._nextChunk=o?function(){this._readChunk(),this._chunkLoaded()}:function(){this._readChunk()},this.stream=function(e){this._input=e,this._nextChunk()},this._readChunk=function(){if(this._finished)this._chunkLoaded();else{if(t=new XMLHttpRequest,this._config.withCredentials&&(t.withCredentials=this._config.withCredentials),o||(t.onload=C(this._chunkLoaded,this),t.onerror=C(this._chunkError,this)),t.open(this._config.downloadRequestBody?"POST":"GET",this._input,!o),this._config.downloadRequestHeaders){var e=this._config.downloadRequestHeaders;for(var i in e)t.setRequestHeader(i,e[i])}if(this._config.chunkSize){var n=this._start+this._config.chunkSize-1;t.setRequestHeader("Range","bytes="+this._start+"-"+n)}try{t.send(this._config.downloadRequestBody)}catch(e){this._chunkError(e.message)}o&&0===t.status&&this._chunkError()}},this._chunkLoaded=function(){4===t.readyState&&(t.status<200||400<=t.status?this._chunkError():(this._start+=this._config.chunkSize?this._config.chunkSize:t.responseText.length,this._finished=!this._config.chunkSize||this._start>=function(e){var t=e.getResponseHeader("Content-Range");return null===t?-1:parseInt(t.substring(t.lastIndexOf("/")+1))}(t),this.parseChunk(t.responseText)))},this._chunkError=function(e){var o=t.statusText||e;this._sendError(new Error(o))}}function p(e){var t,o;(e=e||{}).chunkSize||(e.chunkSize=a.LocalChunkSize),l.call(this,e);var i="undefined"!=typeof FileReader;this.stream=function(e){this._input=e,o=e.slice||e.webkitSlice||e.mozSlice,i?((t=new FileReader).onload=C(this._chunkLoaded,this),t.onerror=C(this._chunkError,this)):t=new FileReaderSync,this._nextChunk()},this._nextChunk=function(){this._finished||this._config.preview&&!(this._rowCount<this._config.preview)||this._readChunk()},this._readChunk=function(){var e=this._input;if(this._config.chunkSize){var n=Math.min(this._start+this._config.chunkSize,this._input.size);e=o.call(e,this._start,n)}var r=t.readAsText(e,this._config.encoding);i||this._chunkLoaded({target:{result:r}})},this._chunkLoaded=function(e){this._start+=this._config.chunkSize,this._finished=!this._config.chunkSize||this._start>=this._input.size,this.parseChunk(e.target.result)},this._chunkError=function(){this._sendError(t.error)}}function c(e){var t;l.call(this,e=e||{}),this.stream=function(e){return t=e,this._nextChunk()},this._nextChunk=function(){if(!this._finished){var e,o=this._config.chunkSize;return o?(e=t.substring(0,o),t=t.substring(o)):(e=t,t=""),this._finished=!t,this.parseChunk(e)}}}function d(e){l.call(this,e=e||{});var t=[],o=!0,i=!1;this.pause=function(){l.prototype.pause.apply(this,arguments),this._input.pause()},this.resume=function(){l.prototype.resume.apply(this,arguments),this._input.resume()},this.stream=function(e){this._input=e,this._input.on("data",this._streamData),this._input.on("end",this._streamEnd),this._input.on("error",this._streamError)},this._checkIsFinished=function(){i&&1===t.length&&(this._finished=!0)},this._nextChunk=function(){this._checkIsFinished(),t.length?this.parseChunk(t.shift()):o=!0},this._streamData=C((function(e){try{t.push("string"==typeof e?e:e.toString(this._config.encoding)),o&&(o=!1,this._checkIsFinished(),this.parseChunk(t.shift()))}catch(e){this._streamError(e)}}),this),this._streamError=C((function(e){this._streamCleanUp(),this._sendError(e)}),this),this._streamEnd=C((function(){this._streamCleanUp(),i=!0,this._streamData("")}),this),this._streamCleanUp=C((function(){this._input.removeListener("data",this._streamData),this._input.removeListener("end",this._streamEnd),this._input.removeListener("error",this._streamError)}),this)}function h(e){var t,o,i,n=Math.pow(2,53),r=-n,s=/^\s*-?(\d+\.?|\.\d+|\d+\.\d+)([eE][-+]?\d+)?\s*$/,l=/^((\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d\.\d+([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z))|(\d{4}-[01]\d-[0-3]\dT[0-2]\d:[0-5]\d([+-][0-2]\d:[0-5]\d|Z)))$/,u=this,p=0,c=0,d=!1,h=!1,f=[],y={data:[],errors:[],meta:{}};if(w(e.step)){var v=e.step;e.step=function(t){if(y=t,T())x();else{if(x(),0===y.data.length)return;p+=t.data.length,e.preview&&p>e.preview?o.abort():(y.data=y.data[0],v(y,u))}}}function C(t){return"greedy"===e.skipEmptyLines?""===t.join("").trim():1===t.length&&0===t[0].length}function x(){return y&&i&&(P("Delimiter","UndetectableDelimiter","Unable to auto-detect delimiting character; defaulted to '"+a.DefaultDelimiter+"'"),i=!1),e.skipEmptyLines&&(y.data=y.data.filter((function(e){return!C(e)}))),T()&&function(){if(y)if(Array.isArray(y.data[0])){for(var t=0;T()&&t<y.data.length;t++)y.data[t].forEach(o);y.data.splice(0,1)}else y.data.forEach(o);function o(t,o){w(e.transformHeader)&&(t=e.transformHeader(t,o)),f.push(t)}}(),function(){if(!y||!e.header&&!e.dynamicTyping&&!e.transform)return y;function t(t,o){var i,n=e.header?{}:[];for(i=0;i<t.length;i++){var r=i,a=t[i];e.header&&(r=i>=f.length?"__parsed_extra":f[i]),e.transform&&(a=e.transform(a,r)),a=S(r,a),"__parsed_extra"===r?(n[r]=n[r]||[],n[r].push(a)):n[r]=a}return e.header&&(i>f.length?P("FieldMismatch","TooManyFields","Too many fields: expected "+f.length+" fields but parsed "+i,c+o):i<f.length&&P("FieldMismatch","TooFewFields","Too few fields: expected "+f.length+" fields but parsed "+i,c+o)),n}var o=1;return!y.data.length||Array.isArray(y.data[0])?(y.data=y.data.map(t),o=y.data.length):y.data=t(y.data,0),e.header&&y.meta&&(y.meta.fields=f),c+=o,y}()}function T(){return e.header&&0===f.length}function S(t,o){return i=t,e.dynamicTypingFunction&&void 0===e.dynamicTyping[i]&&(e.dynamicTyping[i]=e.dynamicTypingFunction(i)),!0===(e.dynamicTyping[i]||e.dynamicTyping)?"true"===o||"TRUE"===o||"false"!==o&&"FALSE"!==o&&(function(e){if(s.test(e)){var t=parseFloat(e);if(r<t&&t<n)return!0}return!1}(o)?parseFloat(o):l.test(o)?new Date(o):""===o?null:o):o;var i}function P(e,t,o,i){var n={type:e,code:t,message:o};void 0!==i&&(n.row=i),y.errors.push(n)}this.parse=function(n,r,s){var l=e.quoteChar||'"';if(e.newline||(e.newline=function(e,t){e=e.substring(0,1048576);var o=new RegExp(g(t)+"([^]*?)"+g(t),"gm"),i=(e=e.replace(o,"")).split("\r"),n=e.split("\n"),r=1<n.length&&n[0].length<i[0].length;if(1===i.length||r)return"\n";for(var a=0,s=0;s<i.length;s++)"\n"===i[s][0]&&a++;return a>=i.length/2?"\r\n":"\r"}(n,l)),i=!1,e.delimiter)w(e.delimiter)&&(e.delimiter=e.delimiter(n),y.meta.delimiter=e.delimiter);else{var u=function(t,o,i,n,r){var s,l,u,p;r=r||[",","\t","|",";",a.RECORD_SEP,a.UNIT_SEP];for(var c=0;c<r.length;c++){var d=r[c],h=0,g=0,f=0;u=void 0;for(var y=new m({comments:n,delimiter:d,newline:o,preview:10}).parse(t),v=0;v<y.data.length;v++)if(i&&C(y.data[v]))f++;else{var b=y.data[v].length;g+=b,void 0!==u?0<b&&(h+=Math.abs(b-u),u=b):u=b}0<y.data.length&&(g/=y.data.length-f),(void 0===l||h<=l)&&(void 0===p||p<g)&&1.99<g&&(l=h,s=d,p=g)}return{successful:!!(e.delimiter=s),bestDelimiter:s}}(n,e.newline,e.skipEmptyLines,e.comments,e.delimitersToGuess);u.successful?e.delimiter=u.bestDelimiter:(i=!0,e.delimiter=a.DefaultDelimiter),y.meta.delimiter=e.delimiter}var p=b(e);return e.preview&&e.header&&p.preview++,t=n,o=new m(p),y=o.parse(t,r,s),x(),d?{meta:{paused:!0}}:y||{meta:{paused:!1}}},this.paused=function(){return d},this.pause=function(){d=!0,o.abort(),t=w(e.chunk)?"":t.substring(o.getCharIndex())},this.resume=function(){u.streamer._halted?(d=!1,u.streamer.parseChunk(t,!0)):setTimeout(u.resume,3)},this.aborted=function(){return h},this.abort=function(){h=!0,o.abort(),y.meta.aborted=!0,w(e.complete)&&e.complete(y),t=""}}function g(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function m(e){var t,o=(e=e||{}).delimiter,i=e.newline,n=e.comments,r=e.step,s=e.preview,l=e.fastMode,u=t=void 0===e.quoteChar||null===e.quoteChar?'"':e.quoteChar;if(void 0!==e.escapeChar&&(u=e.escapeChar),("string"!=typeof o||-1<a.BAD_DELIMITERS.indexOf(o))&&(o=","),n===o)throw new Error("Comment character same as delimiter");!0===n?n="#":("string"!=typeof n||-1<a.BAD_DELIMITERS.indexOf(n))&&(n=!1),"\n"!==i&&"\r"!==i&&"\r\n"!==i&&(i="\n");var p=0,c=!1;this.parse=function(a,d,h){if("string"!=typeof a)throw new Error("Input must be a string");var m=a.length,f=o.length,y=i.length,v=n.length,b=w(r),C=[],x=[],T=[],S=p=0;if(!a)return Z();if(e.header&&!d){var P=a.split(i)[0].split(o),E=[],V={},I=!1;for(var O in P){var A=P[O];w(e.transformHeader)&&(A=e.transformHeader(A,O));var N=A,L=V[A]||0;for(0<L&&(I=!0,N=A+"_"+L),V[A]=L+1;E.includes(N);)N=N+"_"+L;E.push(N)}if(I){var _=a.split(i);_[0]=E.join(o),a=_.join(i)}}if(l||!1!==l&&-1===a.indexOf(t)){for(var M=a.split(i),D=0;D<M.length;D++){if(T=M[D],p+=T.length,D!==M.length-1)p+=i.length;else if(h)return Z();if(!n||T.substring(0,v)!==n){if(b){if(C=[],F(T.split(o)),z(),c)return Z()}else F(T.split(o));if(s&&s<=D)return C=C.slice(0,s),Z(!0)}}return Z()}for(var k=a.indexOf(o,p),j=a.indexOf(i,p),R=new RegExp(g(u)+g(t),"g"),B=a.indexOf(t,p);;)if(a[p]!==t)if(n&&0===T.length&&a.substring(p,p+v)===n){if(-1===j)return Z();p=j+y,j=a.indexOf(i,p),k=a.indexOf(o,p)}else if(-1!==k&&(k<j||-1===j))T.push(a.substring(p,k)),p=k+f,k=a.indexOf(o,p);else{if(-1===j)break;if(T.push(a.substring(p,j)),G(j+y),b&&(z(),c))return Z();if(s&&C.length>=s)return Z(!0)}else for(B=p,p++;;){if(-1===(B=a.indexOf(t,B+1)))return h||x.push({type:"Quotes",code:"MissingQuotes",message:"Quoted field unterminated",row:C.length,index:p}),U();if(B===m-1)return U(a.substring(p,B).replace(R,t));if(t!==u||a[B+1]!==u){if(t===u||0===B||a[B-1]!==u){-1!==k&&k<B+1&&(k=a.indexOf(o,B+1)),-1!==j&&j<B+1&&(j=a.indexOf(i,B+1));var q=Q(-1===j?k:Math.min(k,j));if(a.substr(B+1+q,f)===o){T.push(a.substring(p,B).replace(R,t)),a[p=B+1+q+f]!==t&&(B=a.indexOf(t,p)),k=a.indexOf(o,p),j=a.indexOf(i,p);break}var H=Q(j);if(a.substring(B+1+H,B+1+H+y)===i){if(T.push(a.substring(p,B).replace(R,t)),G(B+1+H+y),k=a.indexOf(o,p),B=a.indexOf(t,p),b&&(z(),c))return Z();if(s&&C.length>=s)return Z(!0);break}x.push({type:"Quotes",code:"InvalidQuotes",message:"Trailing quote on quoted field is malformed",row:C.length,index:p}),B++}}else B++}return U();function F(e){C.push(e),S=p}function Q(e){var t=0;if(-1!==e){var o=a.substring(B+1,e);o&&""===o.trim()&&(t=o.length)}return t}function U(e){return h||(void 0===e&&(e=a.substring(p)),T.push(e),p=m,F(T),b&&z()),Z()}function G(e){p=e,F(T),T=[],j=a.indexOf(i,p)}function Z(e){return{data:C,errors:x,meta:{delimiter:o,linebreak:i,aborted:c,truncated:!!e,cursor:S+(d||0)}}}function z(){r(Z()),C=[],x=[]}},this.abort=function(){c=!0},this.getCharIndex=function(){return p}}function f(e){var t=e.data,o=n[t.workerId],i=!1;if(t.error)o.userError(t.error,t.file);else if(t.results&&t.results.data){var r={abort:function(){i=!0,y(t.workerId,{data:[],errors:[],meta:{aborted:!0}})},pause:v,resume:v};if(w(o.userStep)){for(var a=0;a<t.results.data.length&&(o.userStep({data:t.results.data[a],errors:t.results.errors,meta:t.results.meta},r),!i);a++);delete t.results}else w(o.userChunk)&&(o.userChunk(t.results,r,t.file),delete t.results)}t.finished&&!i&&y(t.workerId,t.results)}function y(e,t){var o=n[e];w(o.userComplete)&&o.userComplete(t),o.terminate(),delete n[e]}function v(){throw new Error("Not implemented.")}function b(e){if("object"!=typeof e||null===e)return e;var t=Array.isArray(e)?[]:{};for(var o in e)t[o]=b(e[o]);return t}function C(e,t){return function(){e.apply(t,arguments)}}function w(e){return"function"==typeof e}return i&&(t.onmessage=function(e){var o=e.data;if(void 0===a.WORKER_ID&&o&&(a.WORKER_ID=o.workerId),"string"==typeof o.input)t.postMessage({workerId:a.WORKER_ID,results:a.parse(o.input,o.config),finished:!0});else if(t.File&&o.input instanceof File||o.input instanceof Object){var i=a.parse(o.input,o.config);i&&t.postMessage({workerId:a.WORKER_ID,results:i,finished:!0})}}),(u.prototype=Object.create(l.prototype)).constructor=u,(p.prototype=Object.create(l.prototype)).constructor=p,(c.prototype=Object.create(c.prototype)).constructor=c,(d.prototype=Object.create(l.prototype)).constructor=d,a},void 0===(i=o.apply(t,[]))||(e.exports=i)},6504:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 11H17V13H13V17H11V13H7V11H11V7H13V11ZM24 12C24 18.6 18.6 24 12 24C5.4 24 0 18.6 0 12C0 5.4 5.4 0 12 0C18.6 0 24 5.4 24 12ZM22 12C22 6.5 17.5 2 12 2C6.5 2 2 6.5 2 12C2 17.5 6.5 22 12 22C17.5 22 22 17.5 22 12Z"></path></svg>'},618:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 11H17V13H13V17H11V13H7V11H11V7H13V11ZM23 12C23 18.1 18.1 23 12 23C5.9 23 1 18.1 1 12C1 5.9 5.9 1 12 1C18.1 1 23 5.9 23 12ZM21 12C21 7 17 3 12 3C7 3 3 7 3 12C3 17 7 21 12 21C17 21 21 17 21 12Z"></path></svg>'},1797:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M9 7H12V9H9V12H7V9H4V7H7V4H9V7ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},6539:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M9 7H12V9H9V12H7V9H4V7H7V4H9V7ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},356:e=>{e.exports='<svg viewBox="0 0 24 20" xmlns="http://www.w3.org/2000/svg"><path d="M23.0336 15.4803L14.5736 1.45346C13.9936 0.487805 12.9936 0 12.0036 0C11.0136 0 10.0136 0.487805 9.43364 1.45346L0.973642 15.4803C-0.226358 17.4714 1.21364 20 3.54364 20H20.4536C22.7836 20 24.2236 17.4714 23.0236 15.4803H23.0336ZM21.3336 17.5112C21.2436 17.6605 20.9936 18.0189 20.4636 18.0189H3.54364C3.01364 18.0189 2.76364 17.6705 2.67364 17.5112C2.58364 17.3519 2.41364 16.9537 2.68364 16.5057L11.1436 2.47885C11.4036 2.04082 11.8336 1.99104 12.0036 1.99104C12.1736 1.99104 12.5936 2.04082 12.8636 2.47885L21.3136 16.5057C21.5836 16.9537 21.4136 17.3519 21.3236 17.5112H21.3336ZM13.0036 7.05824V12.0358C13.0036 12.5834 12.5536 13.0314 12.0036 13.0314C11.4536 13.0314 11.0036 12.5834 11.0036 12.0358V7.05824C11.0036 6.5107 11.4536 6.06272 12.0036 6.06272C12.5536 6.06272 13.0036 6.5107 13.0036 7.05824ZM13.0036 15.0224C13.0036 15.5699 12.5536 16.0179 12.0036 16.0179C11.4536 16.0179 11.0036 15.5699 11.0036 15.0224C11.0036 14.4749 11.4536 14.0269 12.0036 14.0269C12.5536 14.0269 13.0036 14.4749 13.0036 15.0224Z"></path></svg>'},631:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 1C5.9 1 1 5.9 1 12C1 18.1 5.9 23 12 23C18.1 23 23 18.1 23 12C23 5.9 18.1 1 12 1ZM12 21C7 21 3 17 3 12C3 7 7 3 12 3C17 3 21 7 21 12C21 17 17 21 12 21ZM16.3 8L17.7 9.4L10 17.1L6.3 13.4L7.7 12L10 14.3L16.3 8Z"></path></svg>'},4321:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17.01 11.59L13.01 15.59V6H11.01V15.59L7.00998 11.59L5.59998 13L12.01 19.41L18.43 13L17.01 11.59Z"></path></svg>'},1354:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M10.4 2.60001L11.8 4.00001L4.8 11H22V13H4.8L11.8 20L10.4 21.4L1 12L10.4 2.60001Z"></path></svg>'},1685:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 8.99999H4.39998L8.69998 13.3L7.29998 14.7L0.599976 7.99999L7.29998 1.29999L8.69998 2.69999L4.39998 6.99999H15V8.99999V8.99999Z"></path></svg>'},3153:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13.6 2.60001L12.2 4.00001L19.2 11H2V13H19.2L12.2 20L13.6 21.4L23 12L13.6 2.60001Z"></path></svg>'},3142:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M1 6.99999H11.6L7.3 2.69999L8.7 1.29999L15.4 7.99999L8.7 14.7L7.3 13.3L11.6 8.99999H1V6.99999Z"></path></svg>'},3422:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M18.43 11.01L12.01 4.60001L5.59998 11.01L7.00998 12.43L11.01 8.43001V18.01H13.01V8.43001L17.01 12.43L18.43 11.01Z"></path></svg>'},9331:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 11H17C19.8 11 22 8.8 22 6C22 3.2 19.8 1 17 1H7C4.2 1 2 3.2 2 6C2 8.8 4.2 11 7 11ZM7 3H17C18.7 3 20 4.3 20 6C20 7.7 18.7 9 17 9H7C5.3 9 4 7.7 4 6C4 4.3 5.3 3 7 3ZM5 6C5 4.9 5.9 4 7 4C8.1 4 9 4.9 9 6C9 7.1 8.1 8 7 8C5.9 8 5 7.1 5 6ZM19 18C19 19.1 18.1 20 17 20C15.9 20 15 19.1 15 18C15 16.9 15.9 16 17 16C18.1 16 19 16.9 19 18ZM17 13H7C4.2 13 2 15.2 2 18C2 20.8 4.2 23 7 23H17C19.8 23 22 20.8 22 18C22 15.2 19.8 13 17 13ZM17 21H7C5.3 21 4 19.7 4 18C4 16.3 5.3 15 7 15H17C18.7 15 20 16.3 20 18C20 19.7 18.7 21 17 21Z"></path></svg>'},7140:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 2V7H10L12 5C11.1 3.8 9.6 3 8 3C5.2 3 3 5.2 3 8H1C1 4.1 4.1 1 8 1C10.2 1 12.1 2 13.4 3.6L15 2ZM8 13C6.4 13 4.9 12.2 4 11L6 9H1V14L2.6 12.4C3.9 14 5.8 15 8 15C11.9 15 15 11.9 15 8H13C13 10.8 10.8 13 8 13Z"></path></svg>'},2678:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M19 8.90001L21 6.10001V19C21 20.1 20.1 21 19 21H5C3.9 21 3 20.1 3 19V5.00001C3 3.90001 3.9 3.00001 5 3.00001H19C19 3.00001 19 3.00001 19.1 3.00001L20.8 0.600006L22.4 1.80001L11.1 17.5L6.6 13L8 11.6L10.9 14.5L17.7 5.00001H5V19H19V8.90001Z"></path></svg>'},8020:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 20.1L1 12L3.1 9.9L9 15.9L20.9 4L23 6.1L9 20.1Z"></path></svg>'},5981:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M8 11L13 6H3L8 11Z"></path></svg>'},9380:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22.6 8.6L16.4 2.4C16 2 15.5 1.8 15 1.8C14.5 1.8 14 2 13.6 2.4L1.4 14.6C0.600003 15.4 0.600003 16.6 1.4 17.4L6 22H12L22.6 11.4C23.3 10.6 23.3 9.3 22.6 8.6ZM11.1 20H6.8L2.8 16L6.2 12.6L12.4 18.8L11.1 20ZM13.8 17.4L7.6 11.2L15 3.8L21.2 10L13.8 17.4ZM16 20H23V22H14L16 20Z"></path></svg>'},6907:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13.35 3.34999L12.65 2.64999L8.05002 7.24999L3.35002 2.64999L2.65002 3.34999L7.25002 8.04999L2.65002 12.65L3.35002 13.35L8.05002 8.74999L12.65 13.35L13.35 12.65L8.75002 8.04999L13.35 3.34999Z"></path></svg>'},9054:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM9 11C9 11.37 8.89 11.7 8.72 12C8.89 12.3 9 12.63 9 13V14.5C9 14.78 9.22 15 9.5 15H10C10.55 15 11 15.45 11 16C11 16.55 10.55 17 10 17H9.5C8.12 17 7 15.88 7 14.5V13C6.45 13 6 12.55 6 12C6 11.45 6.45 11 7 11V9.5C7 8.12 8.12 7 9.5 7H10C10.55 7 11 7.45 11 8C11 8.55 10.55 9 10 9H9.5C9.22 9 9 9.22 9 9.5V11ZM18 12C18 12.55 17.55 13 17 13V14.5C17 15.88 15.88 17 14.5 17H14C13.45 17 13 16.55 13 16C13 15.45 13.45 15 14 15H14.5C14.78 15 15 14.78 15 14.5V13C15 12.63 15.11 12.3 15.28 12C15.11 11.7 15 11.37 15 11V9.5C15 9.22 14.78 9 14.5 9H14C13.45 9 13 8.55 13 8C13 7.45 13.45 7 14 7H14.5C15.88 7 17 8.12 17 9.5V11C17.55 11 18 11.45 18 12Z"></path></svg>'},7678:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13 7H3V9H13V7Z"></path></svg>'},6845:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M12 9H4V7H12V9ZM16 0V16H0V0H16ZM14 2H2V14H14V2Z"></path></svg>'},9405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 5.6L19.4 12L13 18.4L11.6 17L15.6 13H2V11H15.6L11.6 7L13 5.6ZM20 2V22H22V2H20Z"></path></svg>'},4358:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g id="Collapse V 16x16"><path id="Vector" d="M11.71 12.29C12.1 12.68 12.1 13.31 11.71 13.7C11.51 13.9 11.26 13.99 11 13.99C10.74 13.99 10.49 13.89 10.29 13.7L9.00002 12.41V15C9.00002 15.55 8.55002 16 8.00002 16C7.45002 16 7.00002 15.55 7.00002 15V12.41L5.71002 13.7C5.32002 14.09 4.69002 14.09 4.30002 13.7C3.91002 13.31 3.91002 12.68 4.30002 12.29L7.30002 9.29C7.69002 8.9 8.32002 8.9 8.71002 9.29L11.71 12.29ZM7.29002 6.71C7.49002 6.91 7.74002 7 8.00002 7C8.26002 7 8.51002 6.9 8.71002 6.71L11.71 3.71C12.1 3.32 12.1 2.69 11.71 2.3C11.32 1.91 10.69 1.91 10.3 2.3L9.01002 3.59V1C9.01002 0.45 8.56002 0 8.01002 0C7.46002 0 7.01002 0.45 7.01002 1V3.59L5.72002 2.3C5.33002 1.91 4.70002 1.91 4.31002 2.3C3.92002 2.69 3.90002 3.32 4.29002 3.71L7.29002 6.71Z"></path></g></svg>'},943:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M2 6L3 5L8 10L13 5L14 6L8 12L2 6Z"></path></svg>'},6398:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M12 14.59L16.41 19L15 20.41L13 18.41V23H11V18.41L9 20.41L7.59 19L12 14.59ZM16.41 5L15 3.59L13 5.59V1H11V5.59L9 3.59L7.59 5L12 9.41L16.41 5ZM2 11V13H22V11H2Z"></path></svg>'},8813:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M3.31 15.0002C2.69 15.0002 2.11 14.7602 1.68 14.3202C0.780005 13.4202 0.780005 11.9502 1.68 11.0502L2.45 10.2802C2.45 10.1802 2.44 10.0802 2.44 9.98023C2.44 9.02023 2.81 8.12023 3.49 7.44023L5.6 5.33023C5.37 5.04023 5.25 4.68023 5.25 4.31023C5.25 3.86023 5.42 3.44023 5.74 3.12023C6.06 2.80023 6.48 2.63023 6.92 2.63023C7.29 2.63023 7.65 2.75023 7.94 2.98023L8.88 2.04023C9.56 1.36023 10.46 0.990234 11.41 0.990234C12.36 0.990234 13.27 1.36023 13.95 2.04023C14.63 2.72023 15 3.62023 15 4.58023C15 5.54023 14.63 6.44023 13.95 7.12023L12.94 8.13023C13.04 8.34023 13.09 8.58023 13.09 8.82023C13.09 9.27023 12.92 9.69023 12.6 10.0002C12.28 10.3102 11.86 10.4902 11.42 10.4902C11.18 10.4902 10.94 10.4402 10.73 10.3402L8.56 12.5102C7.88 13.1902 6.98 13.5602 6.03 13.5602C5.93 13.5602 5.83 13.5602 5.73 13.5402L4.97 14.3002C4.53 14.7402 3.95 14.9802 3.34 14.9802L3.31 15.0002Z" fill="black" fill-opacity="0.15"></path><path d="M14.0001 4.57969C14.0001 3.88969 13.7301 3.23969 13.2401 2.74969C12.2301 1.73969 10.5901 1.73969 9.58006 2.74969L7.94006 4.38969L7.39006 3.83969C7.13006 3.57969 6.70006 3.57969 6.44006 3.83969C6.18006 4.09969 6.18006 4.52969 6.44006 4.78969L6.99006 5.33969L4.18006 8.14969C3.69006 8.63969 3.42006 9.28969 3.42006 9.97969C3.42006 10.1997 3.46006 10.4097 3.51006 10.6197L2.38006 11.7497C1.87006 12.2597 1.87006 13.0897 2.38006 13.6097C2.64006 13.8697 2.97006 13.9897 3.31006 13.9897C3.65006 13.9897 3.98006 13.8597 4.24006 13.6097L5.37006 12.4797C5.58006 12.5297 5.79006 12.5697 6.01006 12.5697C6.70006 12.5697 7.35006 12.2997 7.84006 11.8097L10.6501 8.99969L10.9401 9.28969C11.0701 9.41969 11.2401 9.48969 11.4201 9.48969C11.6001 9.48969 11.7701 9.41969 11.9001 9.28969C12.1601 9.02969 12.1601 8.59969 11.9001 8.33969L11.6101 8.04969L13.2501 6.40969C13.7401 5.91969 14.0101 5.26969 14.0101 4.57969H14.0001ZM6.89006 10.8597C6.42006 11.3297 5.61006 11.3297 5.14006 10.8597C4.91006 10.6297 4.78006 10.3197 4.78006 9.98969C4.78006 9.65969 4.91006 9.34969 5.14006 9.11969L7.95006 6.30969L9.70006 8.05969L6.89006 10.8697V10.8597Z"></path></svg>'},6124:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 3H4C2.9 3 2 3.9 2 5V19C2 20.1 2.9 21 4 21H20C21.1 21 22 20.1 22 19V5C22 3.9 21.1 3 20 3ZM20 19H4V5H20V19ZM18 9H6V7H18V9ZM18 13H6V11H18V13ZM12 17H6V15H12V17Z"></path></svg>'},2739:e=>{e.exports='<svg viewBox="0 0 25 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_19827_2206)"><path d="M15.13 2.02C15.74 2.02 16.33 2.11 16.9 2.25L13.63 5.52C12.25 6.9 12.25 9.14 13.63 10.52C14.32 11.21 15.23 11.56 16.13 11.56C17.03 11.56 17.94 11.21 18.63 10.52L21.9 7.25C22.05 7.82 22.13 8.41 22.13 9.02C22.13 12.89 19 16.02 15.13 16.02C13.97 16.02 12.88 15.73 11.92 15.23L6.13 21.02C5.72 21.43 5.17 21.64 4.63 21.64C4.09 21.64 3.54 21.43 3.13 21.02C2.3 20.19 2.3 18.85 3.13 18.02L8.92 12.23C8.42 11.27 8.13 10.18 8.13 9.02C8.13 5.15 11.26 2.02 15.13 2.02ZM15.13 0.02C10.17 0.02 6.13 4.06 6.13 9.02C6.13 9.95 6.28 10.88 6.56 11.76L1.71 16.61C0.93 17.39 0.5 18.42 0.5 19.52C0.5 20.62 0.93 21.66 1.71 22.43C2.49 23.21 3.52 23.64 4.62 23.64C5.72 23.64 6.76 23.21 7.53 22.43L12.38 17.58C13.27 17.86 14.19 18.01 15.12 18.01C20.08 18.01 24.12 13.97 24.12 9.01C24.12 8.26 24.02 7.5 23.82 6.74C23.64 6.05 23.1 5.5 22.41 5.31C22.24 5.26 22.06 5.24 21.89 5.24C21.37 5.24 20.86 5.45 20.48 5.83L17.21 9.1C16.92 9.39 16.53 9.55 16.12 9.55C15.71 9.55 15.32 9.39 15.03 9.1C14.74 8.81 14.58 8.42 14.58 8.01C14.58 7.6 14.74 7.21 15.03 6.92L18.3 3.65C18.81 3.14 19 2.4 18.82 1.71C18.63 1.02 18.09 0.48 17.39 0.3C16.63 0.1 15.87 0 15.12 0L15.13 0.02Z"></path></g><defs><clipPath id="clip0_19827_2206"><rect width="24" height="24" transform="translate(0.5)"></rect></clipPath></defs></svg>'},2622:e=>{e.exports='<svg viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M21 1H9C7.9 1 7 1.9 7 3V7H3C1.9 7 1 7.9 1 9V21C1 22.1 1.9 23 3 23H15C16.1 23 17 22.1 17 21V17H21C22.1 17 23 16.1 23 15V3C23 1.9 22.1 1 21 1ZM15 21H3V9H15V21ZM21 15H17V9C17 7.9 16.1 7 15 7H9V3H21V15Z" fill="black" fill-opacity="0.45"></path></svg>'},6252:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C16.41 4 20 7.14 20 11C19.9901 11.928 19.7826 12.8433 19.3911 13.6847C18.9997 14.5262 18.4334 15.2746 17.73 15.88C17.5103 16.0801 17.338 16.3266 17.2256 16.6017C17.1132 16.8767 17.0634 17.1733 17.08 17.47C16.7752 17.2972 16.4304 17.2076 16.08 17.21C15.8237 17.212 15.5698 17.2594 15.33 17.35C14.2722 17.7789 13.1415 17.9996 12 18C7.59 18 4 14.86 4 11C4 7.14 7.59 4 12 4ZM12 2C6.48 2 2 6 2 11C2 16 6.48 20 12 20C13.4012 19.9996 14.7894 19.7314 16.09 19.21L20 22L19.07 17.36C19.9796 16.5667 20.711 15.5899 21.216 14.4937C21.721 13.3975 21.9882 12.2069 22 11C22 6 17.52 2 12 2Z"></path></svg>'},2583:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M15 2H14H11V1C11 0.4 10.6 0 10 0H7C6.4 0 6 0.4 6 1V2H3H2V4H3V14C3 15.1 3.9 16 5 16H12C13.1 16 14 15.1 14 14V4H15V2ZM7 1H10V2H7V1ZM12 14H5V4H12V14ZM7 13H6V5H7V13ZM9 13H8V5H9V13ZM11 13H10V5H11V13Z"></path></svg>'},405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 4H20H16V2C16 0.9 15.1 0 14 0H10C8.9 0 8 0.9 8 2V4H4H2V6H4V20C4 21.1 4.9 22 6 22H18C19.1 22 20 21.1 20 20V6H22V4ZM10 2H14V4H10V2ZM18 20H6V6H8H16H18V20ZM14 8H16V18H14V8ZM11 8H13V18H11V8ZM8 8H10V18H8V8Z"></path></svg>'},4802:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M2.3 3.7L3.6 5C2 6.9 1 9.3 1 12C1 18.1 5.9 23 12 23C14.7 23 17.1 22 19 20.4L20.3 21.7L21.7 20.3L3.7 2.3L2.3 3.7ZM12 21C7 21 3 17 3 12C3 9.9 3.7 7.9 5 6.4L10.8 12.2C10.7 12.3 10.6 12.4 10.6 12.5C10.5 12.7 10.4 13 10.4 13.3C10.4 13.6 10.5 13.9 10.6 14.1C10.7 14.3 10.8 14.5 10.9 14.8C11 15 11.2 15.1 11.4 15.1C11.5 15.1 11.5 15.1 11.6 15.1H11.7C11.8 15.1 11.9 15.1 12.1 15C12.4 14.9 12.6 14.7 12.6 14.5V14.4V14.1L17.5 19C16.1 20.3 14.1 21 12 21ZM7.8 4.1L6.3 2.6C8 1.6 9.9 1 12 1C18.1 1 23 5.9 23 12C23 14.1 22.4 16 21.4 17.7L19.9 16.2C20.6 15 21 13.5 21 12C21 7 17 3 12 3C10.5 3 9 3.4 7.8 4.1ZM13.5 9.8C13.5 9.7 13.6 9.6 13.6 9.4C13.6 9 13.5 8.6 13.2 8.4C12.8 8 12.4 7.9 12 7.9C11.9 7.9 11.8 7.9 11.6 7.9L10.1 6.4C10.2 6.4 10.2 6.3 10.3 6.3C11.5 5.9 12.7 5.9 13.6 6.1C14.1 6.2 14.5 6.4 14.9 6.6C15.6 7.3 16 8.1 16 9.3C16 10.1 15.7 10.8 15.2 11.4L13.5 9.8ZM11.8 15.9C12.5 15.9 13 16.2 13.3 16.8C13.4 17 13.4 17.2 13.4 17.4C13.4 17.8 13.2 18.2 13 18.5C12.7 18.8 12.3 18.9 11.9 18.9C11.5 18.9 11.1 18.7 10.8 18.5C10.5 18.2 10.4 17.8 10.4 17.4C10.4 17 10.6 16.6 10.8 16.3C11 16 11.4 15.9 11.8 15.9Z"></path></svg>'},5869:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 1C5.9 1 1 5.9 1 12C1 18.1 5.9 23 12 23C18.1 23 23 18.1 23 12C23 5.9 18.1 1 12 1ZM12 21C7 21 3 17 3 12C3 7 7 3 12 3C17 3 21 7 21 12C21 17 17 21 12 21ZM13.3 16.8C13.4 17 13.4 17.2 13.4 17.4C13.4 17.8 13.2 18.2 13 18.5C12.7 18.8 12.3 18.9 11.9 18.9C11.5 18.9 11.1 18.7 10.8 18.5C10.5 18.2 10.4 17.8 10.4 17.4C10.4 17 10.6 16.6 10.8 16.3C11.1 16 11.5 15.8 11.9 15.8C12.5 15.9 13 16.2 13.3 16.8ZM16 9.3C16 10.4 15.5 11.2 14.6 11.9C14.4 12.1 14.1 12.2 13.9 12.4L13.3 12.8C13 13 12.9 13.1 12.9 13.1C12.8 13.2 12.8 13.3 12.8 13.4C12.8 13.6 12.7 13.8 12.7 14.1V14.4V14.5C12.6 14.7 12.4 14.9 12.2 15C12 15.1 11.9 15.1 11.8 15.1H11.7C11.6 15.1 11.6 15.1 11.5 15.1C11.3 15 11.1 14.9 11 14.8C10.9 14.6 10.7 14.4 10.7 14.1C10.6 13.8 10.5 13.6 10.5 13.3C10.5 13 10.6 12.7 10.7 12.5C10.8 12.3 11 12.1 11.2 11.9C11.4 11.7 11.6 11.6 11.8 11.5L12.4 11.2C13 10.9 13.2 10.7 13.3 10.6C13.6 10.3 13.7 9.9 13.7 9.5C13.7 9.1 13.6 8.7 13.3 8.5C12.8 8 12.4 7.9 12 7.9C10.9 7.9 10.6 8.4 10.6 8.8C10.4 9.3 10.4 9.4 10.4 9.4V9.6C10.4 9.7 10.4 9.7 10.4 9.8L10.5 10.2L10.2 10.3C9.6 10.6 9.1 10.6 8.7 10.4C8.6 10.3 8.4 10.1 8.3 10C8.1 9.7 8 9.4 8 9C8 8.6 8.1 8.3 8.2 8C8.3 7.7 8.5 7.5 8.7 7.3C8.9 7.1 9.1 6.9 9.4 6.7C9.7 6.6 10 6.4 10.3 6.3C11.5 5.9 12.7 5.9 13.6 6.1C14.1 6.2 14.5 6.4 14.9 6.6C15.6 7.3 16 8.1 16 9.3Z"></path></svg>'},4548:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 17V2H2V17H10V19C10 19.7956 9.68393 20.5587 9.12132 21.1213C8.55871 21.6839 7.79565 22 7 22H17C16.2044 22 15.4413 21.6839 14.8787 21.1213C14.3161 20.5587 14 19.7956 14 19V17H22ZM4 4H20V15H4V4Z"></path></svg>'},736:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M16 18H8V6H16V18ZM16 2H8C7.46957 2 6.96086 2.21071 6.58579 2.58579C6.21071 2.96086 6 3.46957 6 4V20C6 20.5304 6.21071 21.0391 6.58579 21.4142C6.96086 21.7893 7.46957 22 8 22H16C16.5304 22 17.0391 21.7893 17.4142 21.4142C17.7893 21.0391 18 20.5304 18 20V4C18 3.46957 17.7893 2.96086 17.4142 2.58579C17.0391 2.21071 16.5304 2 16 2Z"></path></svg>'},3441:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M23.41 5.99591L18 11.4059L16.59 9.99591L19.59 6.99591H17C13.5522 6.99591 10.2456 8.36555 7.80761 10.8035C5.36964 13.2415 4 16.5481 4 19.9959V21.9959H2V19.9959C2 16.0177 3.58035 12.2024 6.3934 9.38931C9.20644 6.57626 13.0218 4.99591 17 4.99591H19.59L16.59 1.99591L18 0.585907L23.41 5.99591Z"></path></svg>'},9364:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 18H4V6H20V18ZM21 4H3C2.46957 4 1.96086 4.21071 1.58579 4.58579C1.21071 4.96086 1 5.46957 1 6V18C1 18.5304 1.21071 19.0391 1.58579 19.4142C1.96086 19.7893 2.46957 20 3 20H21C21.5304 20 22.0391 19.7893 22.4142 19.4142C22.7893 19.0391 23 18.5304 23 18V6C23 5.46957 22.7893 4.96086 22.4142 4.58579C22.0391 4.21071 21.5304 4 21 4Z"></path></svg>'},6813:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 18.41L4.59 11L6 9.59L11 14.59V2H13V14.59L18 9.59L19.41 11L12 18.41ZM2 20V22H22V20H2Z"></path></svg>'},9531:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 6C13 4.9 13.9 4 15 4C16.1 4 17 4.9 17 6C17 7.1 16.1 8 15 8C13.9 8 13 7.1 13 6ZM9 4C7.9 4 7 4.9 7 6C7 7.1 7.9 8 9 8C10.1 8 11 7.1 11 6C11 4.9 10.1 4 9 4ZM15 10C13.9 10 13 10.9 13 12C13 13.1 13.9 14 15 14C16.1 14 17 13.1 17 12C17 10.9 16.1 10 15 10ZM9 10C7.9 10 7 10.9 7 12C7 13.1 7.9 14 9 14C10.1 14 11 13.1 11 12C11 10.9 10.1 10 9 10ZM15 16C13.9 16 13 16.9 13 18C13 19.1 13.9 20 15 20C16.1 20 17 19.1 17 18C17 16.9 16.1 16 15 16ZM9 16C7.9 16 7 16.9 7 18C7 19.1 7.9 20 9 20C10.1 20 11 19.1 11 18C11 16.9 10.1 16 9 16Z"></path></svg>'},1689:e=>{e.exports='<svg viewBox="0 0 24 16" xmlns="http://www.w3.org/2000/svg"><path d="M18 9C19.1 9 20 9.9 20 11C20 12.1 19.1 13 18 13C16.9 13 16 12.1 16 11C16 9.9 16.9 9 18 9ZM20 5C20 3.9 19.1 3 18 3C16.9 3 16 3.9 16 5C16 6.1 16.9 7 18 7C19.1 7 20 6.1 20 5ZM14 11C14 9.9 13.1 9 12 9C10.9 9 10 9.9 10 11C10 12.1 10.9 13 12 13C13.1 13 14 12.1 14 11ZM14 5C14 3.9 13.1 3 12 3C10.9 3 10 3.9 10 5C10 6.1 10.9 7 12 7C13.1 7 14 6.1 14 5ZM8 11C8 9.9 7.1 9 6 9C4.9 9 4 9.9 4 11C4 12.1 4.9 13 6 13C7.1 13 8 12.1 8 11ZM8 5C8 3.9 7.1 3 6 3C4.9 3 4 3.9 4 5C4 6.1 4.9 7 6 7C7.1 7 8 6.1 8 5Z"></path></svg>'},2483:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 15L17 10H7L12 15Z"></path></svg>'},3892:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M8 11L13 6H3L8 11Z"></path></svg>'},7382:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V6C2 7.1 2.9 8 4 8V20C4 21.1 4.9 22 6 22H20C21.1 22 22 21.1 22 20V8V6V4C22 2.9 21.1 2 20 2ZM20 20H6V8H20V20ZM4 6V4H20V6H4ZM18 12H8V10H18V12ZM18 16H8V14H18V16Z"></path></svg>'},2723:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_9500_71113)"><path d="M14 0H6C5.46957 0 4.96086 0.210714 4.58579 0.585786C4.21071 0.960859 4 1.46957 4 2V4H2C1.46957 4 0.960859 4.21071 0.585786 4.58579C0.210714 4.96086 0 5.46957 0 6L0 14C0 14.5304 0.210714 15.0391 0.585786 15.4142C0.960859 15.7893 1.46957 16 2 16H10C10.5304 16 11.0391 15.7893 11.4142 15.4142C11.7893 15.0391 12 14.5304 12 14V12H14C14.5304 12 15.0391 11.7893 15.4142 11.4142C15.7893 11.0391 16 10.5304 16 10V2C16 1.46957 15.7893 0.960859 15.4142 0.585786C15.0391 0.210714 14.5304 0 14 0V0ZM10 14H2V6H10V14ZM14 10H12V6C12 5.46957 11.7893 4.96086 11.4142 4.58579C11.0391 4.21071 10.5304 4 10 4H6V2H14V10Z"></path></g><defs><clipPath id="clip0_9500_71113"><rect width="16" height="16"></rect></clipPath></defs></svg>'},5669:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21.9 4.8L19.1 2C18.5 1.5 17.8 1.2 17 1.2C16.2 1.2 15.5 1.5 14.9 2.1L4.6 12.3C2.9 14 2 16.3 2 18.7V21C2 21.6 2.4 22 3 22H5.3C7.7 22 10 21.1 11.7 19.4L21.9 9.1C23.1 7.9 23.1 6 21.9 4.8ZM10.2 17.9C8.9 19.2 7.1 20 5.3 20H4V18.7C4 16.8 4.7 15.1 6.1 13.8L12.3 7.6L16.5 11.8L10.2 17.9ZM20.5 7.7L17.8 10.4L13.6 6.2L16.3 3.5C16.5 3.2 16.8 3.2 17 3.2C17.2 3.2 17.5 3.2 17.7 3.5L20.5 6.3C20.9 6.6 20.9 7.3 20.5 7.7Z"></path></svg>'},2290:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_2693_58208)"><path d="M15.3 2.8L13.2 0.7C12.7 0.2 12.2 0 11.6 0C11 0 10.4 0.2 10 0.7L2 8.6C0.7 9.9 0 11.7 0 13.5V15.3C0 15.7 0.3 16 0.8 16H2.6C4.4 16 6.2 15.3 7.5 14L15.4 6.1C16.2 5.2 16.2 3.7 15.3 2.8ZM6 12.6C5.1 13.5 3.8 14 2.5 14H2V13.5C2 12.2 2.5 10.9 3.4 10L8 5.4L10.6 8L6 12.6ZM13.9 4.7L12 6.6L9.4 4L11.3 2.1C11.4 2 11.5 2 11.6 2C11.7 2 11.7 2 11.8 2.1L13.9 4.2C14 4.3 14 4.5 13.9 4.7Z"></path></g><defs><clipPath id="clip0_2693_58208"><rect width="16" height="16"></rect></clipPath></defs></svg>'},9697:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M2.3 3.7L7.8 9.2L4.6 12.4C2.9 14.1 2 16.4 2 18.8V21.1C2 21.7 2.4 22.1 3 22.1H5.3C7.7 22.1 10 21.2 11.7 19.5L14.9 16.3L20.4 21.8L21.8 20.4L3.8 2.4L2.3 3.7ZM10.2 17.9C8.9 19.2 7.1 20 5.3 20H4V18.7C4 16.8 4.7 15.1 6.1 13.8L9.3 10.6L13.5 14.8L10.2 17.9ZM21.9 9.1L17.2 13.8L15.8 12.4L20.5 7.7C20.9 7.3 20.9 6.7 20.5 6.3L17.7 3.5C17.5 3.2 17.2 3.2 17 3.2C16.8 3.2 16.5 3.2 16.3 3.5L11.6 8.2L10.2 6.8L14.9 2.1C15.5 1.5 16.2 1.2 17 1.2C17.8 1.2 18.5 1.5 19.1 2.1L21.9 4.9C23.1 6 23.1 7.9 21.9 9.1Z"></path></svg>'},2485:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 14.41V23H11V14.41L8.71 16.7L7.3 15.29L12.01 10.58L16.72 15.29L15.31 16.7L13.02 14.41H13ZM20 3H4C2.9 3 2 3.9 2 5V19C2 20.1 2.9 21 4 21H9V19H4V5H20V19H15V21H20C21.1 21 22 20.1 22 19V5C22 3.9 21.1 3 20 3ZM5 6V8H8V6H5ZM19 6H9V8H19V6Z"></path></svg>'},7857:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_19289_560924)"><path d="M8 0C3.58 0 0 3.58 0 8C0 12.42 3.58 16 8 16C12.42 16 16 12.42 16 8C16 3.58 12.42 0 8 0ZM8 14C4.69 14 2 11.31 2 8C2 4.69 4.69 2 8 2C11.31 2 14 4.69 14 8C14 11.31 11.31 14 8 14ZM11.41 6L9.41 8L11.41 10L10 11.41L8 9.41L6 11.41L4.59 10L6.59 8L4.59 6L6 4.59L8 6.59L10 4.59L11.41 6Z"></path></g><defs><clipPath id="clip0_19289_560924"><rect width="16" height="16" fill="transparent"></rect></clipPath></defs></svg>'},7789:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M13 7H9V3H7V7H3V9H7V13H9V9H13V7Z"></path></svg>'},7374:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M7 9H4V7H7V4H9V7H12V9H9V12H7V9ZM16 0V16H0V0H16ZM14 2H2V14H14V2Z"></path></svg>'},5208:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M19.9959 2H14.9959V22H21.9959V2H19.9959ZM19.9959 20H16.9959V4H19.9959V20ZM4.40588 11H12.9959V13H4.40588L8.40588 17L6.99588 18.41L0.585876 12L6.99588 5.59L8.40588 7L4.40588 11Z"></path></svg>'},2731:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g id="Expand V 16x16" clip-path="url(#clip0_2625_3196)"><path id="Vector" d="M4.29006 4.71006C3.90006 4.32006 3.90006 3.69006 4.29006 3.30006L7.29006 0.290059C7.68006 -0.0999414 8.31006 -0.0999414 8.70006 0.290059L11.7001 3.29006C12.0901 3.68006 12.0901 4.31006 11.7001 4.70006C11.5001 4.90006 11.2501 4.99006 10.9901 4.99006C10.7301 4.99006 10.4801 4.89006 10.2801 4.70006L8.99006 3.41006V6.00006C8.99006 6.55006 8.54006 7.00006 7.99006 7.00006C7.44006 7.00006 6.99006 6.55006 6.99006 6.00006V3.41006L5.70006 4.70006C5.31006 5.09006 4.68006 5.09006 4.29006 4.70006V4.71006ZM10.2901 11.2901L9.00006 12.5801V9.99006C9.00006 9.44006 8.55006 8.99006 8.00006 8.99006C7.45006 8.99006 7.00006 9.44006 7.00006 9.99006V12.5801L5.71006 11.2901C5.32006 10.9001 4.69006 10.9001 4.30006 11.2901C3.91006 11.6801 3.91006 12.3101 4.30006 12.7001L7.30006 15.7001C7.50006 15.9001 7.75006 15.9901 8.01006 15.9901C8.27006 15.9901 8.52006 15.8901 8.72006 15.7001L11.7201 12.7001C12.1101 12.3101 12.1101 11.6801 11.7201 11.2901C11.3301 10.9001 10.7001 10.9001 10.3101 11.2901H10.2901Z"></path></g><defs><clipPath id="clip0_2625_3196"><rect width="16" height="16" fill="white"></rect></clipPath></defs></svg>'},6294:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M6 14L5 13L10 8L5 3L6 2L12 8L6 14Z"></path></svg>'},5049:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24"><path d="M9 6.83L7.59 5.42L12 1L16.41 5.41L15 6.82L13 4.82V10.41H11V4.83L9 6.83ZM13 20V14.41H11V20L9 18L7.59 19.41L12 23.82L16.41 19.41L15 18L13 20ZM20 8.41H15V10.41H20V14.41H15V16.41H20C21.1 16.41 22 15.51 22 14.41V10.41C22 9.31 21.1 8.41 20 8.41ZM9 14.41H4V10.41H9V8.41H4C2.9 8.41 2 9.31 2 10.41V14.41C2 15.51 2.9 16.41 4 16.41H9V14.41Z"></path></svg>'},1403:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M6 10.4059L4.59 8.99591L12 1.58591L19.41 8.99591L18 10.4059L13 5.40591V17.9959H11V5.40591L6 10.4059ZM2 19.9959V21.9959H22V19.9959H2Z"></path></svg>'},1399:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 0.5C19.4 0.2 18.7 0 17.8 0C15.9 0 14.3 0.8 13 2.3C11.5 4.1 10.1 7.1 9 11.5H6.2L5.8 13H8.5L8.3 14C8.2 14.4 8.1 14.9 7.9 15.7C7.7 16.4 7.6 17.1 7.5 17.6C6.8 20.6 6.1 21.9 5.6 22.4C5.6 22.1 5.5 21.8 5.2 21.6C4.7 21.3 3.8 21.2 3.3 21.8C3.1 22 3 22.4 3 22.7C3 23.1 3.1 23.4 3.4 23.6C3.7 23.9 4.2 24 4.8 24C5.4 24 6 23.9 6.5 23.6C7.9 23 9 21.7 9.8 19.6C10.2 18.5 10.8 16.7 11.4 14.1L11.7 12.9H15.1L15.5 11.4H12.1C13.1 7.2 14.2 4.2 15.3 2.7C15.6 2.3 15.9 2 16.2 1.8C16.6 1.5 16.8 1.5 17 1.5C17.2 1.5 17.4 1.5 17.7 1.6C17.5 1.9 17.5 2.2 17.5 2.5C17.5 2.9 17.7 3.3 18 3.6C18.7 4.1 19.8 4.1 20.5 3.6C20.8 3.2 21 2.8 21 2.3C21 1.5 20.7 0.9 20 0.5Z"></path></svg>'},9516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M13 5H2V3H13V5ZM10 7H2V9H10V7ZM2 17H10V15H2V17ZM13 11H2V13H13V11ZM23.4 14.9L17 21.3C16 22.4 14.5 23 13 23H11.6C11.3 23 11 22.7 11 22.4V21C11 19.5 11.6 18.1 12.7 17L19.1 10.6C19.4 10.2 19.9 10 20.4 10C20.9 10 21.4 10.2 21.7 10.6L23.4 12.3C24.2 13 24.2 14.2 23.4 14.9ZM21.9 13.6L20.3 12L14 18.3C13.4 19.1 13 20 13 21C14 21 14.9 20.6 15.6 19.9L21.9 13.6Z"></path></svg>'},271:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 9V7C22 5.9 21.1 5 20 5H12L10 3H4C2.9 3 2 3.9 2 5V9V10V21H22L24 9H22ZM4 5H9.2L10.6 6.4L11.2 7H12H20V9H4V5ZM20.3 19H4V11H21.6L20.3 19Z"></path></svg>'},4706:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_506_606)"><path opacity="0.75" d="M8.71 11.29L5.71 8.29C5.32 7.9 4.69 7.9 4.3 8.29C3.91 8.68 3.91 9.31 4.3 9.7L5.59 10.99H1C0.45 10.99 0 11.44 0 11.99C0 12.54 0.45 12.99 1 12.99H5.59L4.3 14.28C3.91 14.67 3.91 15.3 4.3 15.69C4.5 15.89 4.75 15.98 5.01 15.98C5.27 15.98 5.52 15.88 5.72 15.69L8.72 12.69C8.81 12.6 8.89 12.49 8.94 12.36C9.04 12.12 9.04 11.84 8.94 11.6C8.89 11.48 8.82 11.37 8.72 11.27L8.71 11.29Z" fill="black" fill-opacity="0.45"></path><path opacity="0.75" d="M15.71 10.29C15.32 9.89999 14.69 9.89999 14.3 10.29C13.91 10.68 13.91 11.31 14.3 11.7L16.3 13.7C16.5 13.9 16.75 13.99 17.01 13.99C17.27 13.99 17.52 13.89 17.72 13.7L23.72 7.69999C24.11 7.30999 24.11 6.67999 23.72 6.28999C23.33 5.89999 22.7 5.89999 22.31 6.28999L21.05 7.54999C19.99 6.57999 18.57 5.98999 17.02 5.98999C13.71 5.98999 11.02 8.67999 11.02 11.99C11.02 15.3 13.71 17.99 17.02 17.99C20.33 17.99 23.02 15.3 23.02 11.99C23.02 11.5 22.96 11.03 22.85 10.58L20.98 12.45C20.75 14.44 19.07 15.99 17.03 15.99C14.82 15.99 13.03 14.2 13.03 11.99C13.03 9.77999 14.82 7.98999 17.03 7.98999C18.03 7.98999 18.93 8.36999 19.63 8.97999L17.03 11.58L15.74 10.29H15.71Z"></path></g><defs><clipPath id="clip0_506_606"><rect width="24" height="24" fill="white"></rect></clipPath></defs></svg>'},3698:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7.85 6.64999L3.35 11.95L7.85 17.35L6.25 18.65L0.75 11.95L6.25 5.34999L7.85 6.64999ZM17.85 5.34999L16.25 6.64999L20.75 11.95L16.25 17.35L17.75 18.65L23.25 12.05L17.85 5.34999ZM8.15 20.65L10.05 21.25L16.05 3.24999L14.15 2.64999L8.15 20.65Z"></path></svg>'},5168:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM20 20H4V4H20V20ZM7 8C7 6.9 7.9 6 9 6C10.1 6 11 6.9 11 8C11 9.1 10.1 10 9 10C7.9 10 7 9.1 7 8ZM19 19H5L9 14L11 15L14 12L19 19Z"></path></svg>'},9630:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 5H4C2.9 5 2 5.9 2 7V20C2 21.1 2.9 22 4 22H17C18.1 22 19 21.1 19 20V7C19 5.9 18.1 5 17 5ZM17 20H4V7H17V20ZM6 11C6 9.9 6.9 9 8 9C9.1 9 10 9.9 10 11C10 12.1 9.1 13 8 13C6.9 13 6 12.1 6 11ZM16 19H5L16 14V19ZM22 4V17C22 18.1 21.1 19 20 19V17V4H7H5C5 2.9 5.9 2 7 2H20C21.1 2 22 2.9 22 4Z"></path></svg>'},5518:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 18.41L4.59 11L6 9.59L11 14.59V2H13V14.59L18 9.59L19.41 11L12 18.41ZM2 20V22H22V20H2Z"></path></svg>'},4925:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 7.003C12.4641 7.01107 12.9249 7.08171 13.37 7.213L11.54 9.053C10.9155 9.15262 10.3384 9.44704 9.89125 9.89423C9.44406 10.3414 9.14964 10.9185 9.05002 11.543L7.21002 13.373C7.07873 12.9279 7.00809 12.467 7.00002 12.003C7.00002 10.6769 7.5268 9.40515 8.46449 8.46747C9.40217 7.52978 10.6739 7.003 12 7.003ZM5.40002 15.183C4.39516 14.2466 3.52369 13.1766 2.81002 12.003C5.10002 8.223 8.47002 6.003 12 6.003C12.765 6.0082 13.5255 6.11925 14.26 6.333L15.86 4.733C14.6291 4.25486 13.3206 4.0074 12 4.003C7.24002 4.003 3.05002 7.173 0.52002 12.003C1.41557 13.7255 2.59165 15.2868 4.00002 16.623L5.40002 15.183ZM23.48 12.003C21 16.833 16.76 20.003 12 20.003C10.1707 19.9916 8.37315 19.5242 6.77002 18.643L2.71002 22.713L1.29002 21.293L21.29 1.293L22.71 2.713L18.94 6.473C20.8367 7.96509 22.3858 9.8521 23.48 12.003ZM14.7 10.723L10.7 14.723C11.1058 14.9158 11.5508 15.0116 12 15.003C12.7957 15.003 13.5587 14.6869 14.1213 14.1243C14.6839 13.5617 15 12.7986 15 12.003C14.9993 11.559 14.8967 11.1211 14.7 10.723ZM21.19 12.003C20.243 10.4087 18.9887 9.01851 17.5 7.913L16.16 9.263C16.7052 10.073 16.9975 11.0266 17 12.003C17 13.3291 16.4732 14.6009 15.5356 15.5385C14.5979 16.4762 13.3261 17.003 12 17.003C11.0237 17.0005 10.07 16.7081 9.26002 16.163L8.26002 17.163C9.43056 17.7122 10.707 17.9989 12 18.003C15.53 18.003 18.9 15.783 21.19 12.003Z"></path></svg>'},8516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 5L12 0L7 5H11V9H13V5H17Z"></path><path d="M13 19V15H11V19H7L12 24L17 19H13Z"></path></svg>'},6247:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17.75 8H15.25L13.35 13.08C12.2029 12.2588 11.2439 11.2027 10.537 9.98187C9.83 8.76107 9.39127 7.40364 9.25 6H14V4H9V2H7V4H2V6H6.91C6.73189 7.75797 6.09115 9.43736 5.05302 10.8672C4.01489 12.2971 2.61643 13.4263 1 14.14C1.32315 14.7296 1.69441 15.2915 2.11 15.82C4.82764 14.5445 6.96846 12.2966 8.11 9.52C9.02641 11.7596 10.5985 13.6698 12.62 15L10 22H12.42L13.79 18.13H19.16L20.56 22H23L17.75 8ZM14.46 16.16L15.73 12.53C16.0406 11.7049 16.2945 10.8596 16.49 10C16.55 10.26 16.67 10.66 16.84 11.21C17.01 11.76 17.14 12.15 17.24 12.41L18.55 16.2L14.46 16.16Z"></path></svg>'},2937:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21.93 9H21V7C21 6.46957 20.7893 5.96086 20.4142 5.58579C20.0391 5.21071 19.5304 5 19 5H10L8 3H4C3.46957 3 2.96086 3.21071 2.58579 3.58579C2.21071 3.96086 2 4.46957 2 5L2 21H21L23.89 11.63C23.9916 11.3244 24.0179 10.9988 23.9667 10.6809C23.9155 10.363 23.7882 10.0621 23.5958 9.80392C23.4034 9.54571 23.1514 9.33779 22.8614 9.19782C22.5714 9.05786 22.2519 8.99 21.93 9ZM4 5H7.17L8.59 6.41L9.17 7H19V9H6L4 15V5ZM22 11L19.54 19H4.77L7.44 11H22Z"></path></svg>'},9730:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M18 14.59L16.59 16L18.59 18H7.82C7.79 17.9 7.75 17.81 7.7 17.71L17.71 7.7C18.1 7.89 18.53 8 19 8C20.65 8 22 6.65 22 5C22 3.35 20.65 2 19 2C17.7 2 16.6 2.84 16.18 4H7.82C7.41 2.84 6.31 2 5 2C3.35 2 2 3.35 2 5C2 6.65 3.35 8 5 8C6.3 8 7.4 7.16 7.82 6H16.19C16.22 6.1 16.26 6.19 16.31 6.29L6.29 16.3C5.9 16.11 5.47 16 5 16C3.35 16 2 17.35 2 19C2 20.65 3.35 22 5 22C6.3 22 7.4 21.16 7.82 20H18.59L16.59 22L18 23.41L22.41 19L18 14.59ZM19 4C19.55 4 20 4.45 20 5C20 5.55 19.55 6 19 6C18.45 6 18 5.55 18 5C18 4.45 18.45 4 19 4ZM5 6C4.45 6 4 5.55 4 5C4 4.45 4.45 4 5 4C5.55 4 6 4.45 6 5C6 5.55 5.55 6 5 6ZM5 20C4.45 20 4 19.55 4 19C4 18.45 4.45 18 5 18C5.55 18 6 18.45 6 19C6 19.55 5.55 20 5 20Z"></path></svg>'},1523:e=>{e.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_252_57732)"><path d="M19 29.2996L20.4 30.6996L22.7 28.3996V33.9996H24.7V28.3996L27 30.6996L28.4 29.2996L23.7 24.5996L19 29.2996Z"></path><path d="M24.7 19.6V14H22.7V19.6L20.4 17.3L19 18.7L23.7 23.4L28.4 18.7L27 17.3L24.7 19.6Z"></path></g><defs><clipPath id="clip0_252_57732"><rect width="9.4" height="20" fill="white" transform="translate(19 14)"></rect></clipPath></defs></svg>'},1390:e=>{e.exports='<svg viewBox="0 0 48 48" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_252_57727)"><path d="M19 17.7L20.4 19.1L22.7 16.8V22.4H24.7V16.8L27 19.1L28.4 17.7L23.7 13L19 17.7Z"></path><path d="M24.7 32.0004V26.4004H22.7V32.0004L20.4 29.7004L19 31.1004L23.7 35.8004L28.4 31.1004L27 29.7004L24.7 32.0004Z"></path></g><defs><clipPath id="clip0_252_57727"><rect width="9.4" height="22.8" fill="white" transform="translate(19 13)"></rect></clipPath></defs></svg>'},780:e=>{e.exports='<svg viewBox="0 0 32 32" xmlns="http://www.w3.org/2000/svg"><path d="M28 0H4C1.79 0 0 1.79 0 4V28C0 30.21 1.79 32 4 32H28C30.21 32 32 30.21 32 28V4C32 1.79 30.21 0 28 0ZM30 28C30 29.1 29.1 30 28 30H4C2.9 30 2 29.1 2 28V4C2 2.9 2.9 2 4 2H28C29.1 2 30 2.9 30 4V28ZM6 9C6 7.34 7.34 6 9 6C10.66 6 12 7.34 12 9C12 10.66 10.66 12 9 12C7.34 12 6 10.66 6 9ZM19 16L28 28H4L11 19L15 21L19 16Z"></path></svg>'},7466:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M6 1C3.2 1 1 3.2 1 6C1 8.8 3.2 11 6 11C8.8 11 11 8.8 11 6C11 3.2 8.8 1 6 1ZM6 9C4.3 9 3 7.7 3 6C3 4.3 4.3 3 6 3C7.7 3 9 4.3 9 6C9 7.7 7.7 9 6 9ZM8 6C8 7.1 7.1 8 6 8C4.9 8 4 7.1 4 6C4 4.9 4.9 4 6 4C7.1 4 8 4.9 8 6ZM20 18C20 19.1 19.1 20 18 20C16.9 20 16 19.1 16 18C16 16.9 16.9 16 18 16C19.1 16 20 16.9 20 18ZM6 13C3.2 13 1 15.2 1 18C1 20.8 3.2 23 6 23C8.8 23 11 20.8 11 18C11 15.2 8.8 13 6 13ZM6 21C4.3 21 3 19.7 3 18C3 16.3 4.3 15 6 15C7.7 15 9 16.3 9 18C9 19.7 7.7 21 6 21ZM18 11C20.8 11 23 8.8 23 6C23 3.2 20.8 1 18 1C15.2 1 13 3.2 13 6C13 8.8 15.2 11 18 11ZM18 3C19.7 3 21 4.3 21 6C21 7.7 19.7 9 18 9C16.3 9 15 7.7 15 6C15 4.3 16.3 3 18 3ZM18 13C15.2 13 13 15.2 13 18C13 20.8 15.2 23 18 23C20.8 23 23 20.8 23 18C23 15.2 20.8 13 18 13ZM18 21C16.3 21 15 19.7 15 18C15 16.3 16.3 15 18 15C19.7 15 21 16.3 21 18C21 19.7 19.7 21 18 21Z"></path></svg>'},8125:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 4C7 5.7 5.7 7 4 7C2.3 7 1 5.7 1 4C1 2.3 2.3 1 4 1C5.7 1 7 2.3 7 4ZM15 4C15 5.7 13.7 7 12 7C10.3 7 9 5.7 9 4C9 2.3 10.3 1 12 1C13.7 1 15 2.3 15 4ZM13 4C13 3.4 12.6 3 12 3C11.4 3 11 3.4 11 4C11 4.6 11.4 5 12 5C12.6 5 13 4.6 13 4ZM17 4C17 2.3 18.3 1 20 1C21.7 1 23 2.3 23 4C23 5.7 21.7 7 20 7C18.3 7 17 5.7 17 4ZM19 4C19 4.6 19.4 5 20 5C20.6 5 21 4.6 21 4C21 3.4 20.6 3 20 3C19.4 3 19 3.4 19 4ZM7 12C7 13.7 5.7 15 4 15C2.3 15 1 13.7 1 12C1 10.3 2.3 9 4 9C5.7 9 7 10.3 7 12ZM5 12C5 11.4 4.6 11 4 11C3.4 11 3 11.4 3 12C3 12.6 3.4 13 4 13C4.6 13 5 12.6 5 12ZM12 9C10.3 9 9 10.3 9 12C9 13.7 10.3 15 12 15C13.7 15 15 13.7 15 12C15 10.3 13.7 9 12 9ZM20 9C18.3 9 17 10.3 17 12C17 13.7 18.3 15 20 15C21.7 15 23 13.7 23 12C23 10.3 21.7 9 20 9ZM4 17C2.3 17 1 18.3 1 20C1 21.7 2.3 23 4 23C5.7 23 7 21.7 7 20C7 18.3 5.7 17 4 17ZM12 17C10.3 17 9 18.3 9 20C9 21.7 10.3 23 12 23C13.7 23 15 21.7 15 20C15 18.3 13.7 17 12 17ZM23 20C23 21.7 21.7 23 20 23C18.3 23 17 21.7 17 20C17 18.3 18.3 17 20 17C21.7 17 23 18.3 23 20ZM21 20C21 19.4 20.6 19 20 19C19.4 19 19 19.4 19 20C19 20.6 19.4 21 20 21C20.6 21 21 20.6 21 20Z"></path></svg>'},169:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 4C7 5.7 5.7 7 4 7C2.3 7 1 5.7 1 4C1 2.3 2.3 1 4 1C5.7 1 7 2.3 7 4ZM15 4C15 5.7 13.7 7 12 7C10.3 7 9 5.7 9 4C9 2.3 10.3 1 12 1C13.7 1 15 2.3 15 4ZM13 4C13 3.4 12.6 3 12 3C11.4 3 11 3.4 11 4C11 4.6 11.4 5 12 5C12.6 5 13 4.6 13 4ZM17 4C17 2.3 18.3 1 20 1C21.7 1 23 2.3 23 4C23 5.7 21.7 7 20 7C18.3 7 17 5.7 17 4ZM19 4C19 4.6 19.4 5 20 5C20.6 5 21 4.6 21 4C21 3.4 20.6 3 20 3C19.4 3 19 3.4 19 4ZM7 12C7 13.7 5.7 15 4 15C2.3 15 1 13.7 1 12C1 10.3 2.3 9 4 9C5.7 9 7 10.3 7 12ZM5 12C5 11.4 4.6 11 4 11C3.4 11 3 11.4 3 12C3 12.6 3.4 13 4 13C4.6 13 5 12.6 5 12ZM12 9C10.3 9 9 10.3 9 12C9 13.7 10.3 15 12 15C13.7 15 15 13.7 15 12C15 10.3 13.7 9 12 9ZM20 9C18.3 9 17 10.3 17 12C17 13.7 18.3 15 20 15C21.7 15 23 13.7 23 12C23 10.3 21.7 9 20 9ZM5 17H3V19H1V21H3V23H5V21H7V19H5V17Z"></path></svg>'},6544:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 1H4C2.9 1 2 1.9 2 3V9C2 10.1 2.9 11 4 11H20C21.1 11 22 10.1 22 9V3C22 1.9 21.1 1 20 1ZM20 9H4V3H20V9ZM14 7H6V5H14V7ZM20 13H4C2.9 13 2 13.9 2 15V21C2 22.1 2.9 23 4 23H20C21.1 23 22 22.1 22 21V15C22 13.9 21.1 13 20 13ZM20 21H4V15H20V21ZM14 19H6V17H14V19Z"></path></svg>'},5265:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M5.64648 12.6465L6.34648 13.3465L11.7465 8.04648L6.34648 2.64648L5.64648 3.34648L10.2465 8.04648L5.64648 12.6465Z"></path></svg>'},8273:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 2V4H4V9H2V4C2 2.9 2.9 2 4 2H9ZM20 2H15V4H20V9H22V4C22 2.9 21.1 2 20 2ZM4 20V15H2V20C2 21.1 2.9 22 4 22H9V20H4ZM20 20H15V22H20C21.1 22 22 21.1 22 20V15H20V20Z"></path></svg>'},4520:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9 2V4H4V9H2V4C2 3.46957 2.21071 2.96086 2.58579 2.58579C2.96086 2.21071 3.46957 2 4 2H9ZM20 2H15V4H20V9H22V4C22 3.46957 21.7893 2.96086 21.4142 2.58579C21.0391 2.21071 20.5304 2 20 2ZM4 20V15H2V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H9V20H4ZM20 20H15V22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V15H20V20ZM17 13H15V11H13V13H11V15H13V17H15V15H17V13Z"></path></svg>'},2804:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 8H19V1H5V8H4V13H5V13.14C5 14.72 6.28 16 7.86 16C8.2 16 8.41 16.19 8.51 16.3C8.61 16.41 8.76 16.65 8.71 16.98L8.44 18.89C8.29 19.92 8.6 20.97 9.28 21.76C9.96 22.55 10.96 23 12 23C13.04 23 14.04 22.55 14.72 21.76C15.4 20.97 15.71 19.93 15.57 18.89L15.3 16.98C15.25 16.64 15.41 16.41 15.5 16.3C15.59 16.19 15.81 16 16.15 16C17.73 16 19.01 14.72 19.01 13.14V13H20.01V8H20ZM18 11H6V10H18V11ZM7 3H11V5H13V3H14V6H16V3H17V8H7V3ZM17 13.14C17 13.61 16.62 14 16.14 14C15.31 14 14.52 14.36 13.98 14.98C13.44 15.61 13.19 16.44 13.31 17.26L13.58 19.17C13.65 19.64 13.51 20.09 13.2 20.45C12.59 21.15 11.39 21.15 10.78 20.45C10.47 20.09 10.34 19.64 10.4 19.17L10.67 17.26C10.79 16.44 10.54 15.61 10 14.98C9.46 14.35 8.67 13.99 7.84 13.99C7.37 13.99 6.98 13.61 6.98 13.13V12.99H16.98V13.13L17 13.14ZM11 19C11 18.45 11.45 18 12 18C12.55 18 13 18.45 13 19C13 19.55 12.55 20 12 20C11.45 20 11 19.55 11 19Z"></path></g></svg>'},5574:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M6 9.41L4.59 8L8 4.59L9.41 6L6 9.41ZM14.41 6L13 4.59L4.59 13L6 14.41L14.41 6ZM4.59 18L6 19.41L19.41 6L18 4.59L4.59 18ZM9.59 18L11 19.41L19.41 11L18 9.59L9.59 18ZM14.59 18L16 19.41L19.41 16L18 14.59L14.59 18ZM22 4V20C22 21.1 21.1 22 20 22H4C2.9 22 2 21.1 2 20V4C2 2.9 2.9 2 4 2H20C21.1 2 22 2.9 22 4ZM20 20V4H4V20H20Z"></path></g></svg>'},1965:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M22 3V21H20V3H22ZM14 21H16V3H14V21ZM8 21H10V3H8V21ZM2 21H4V3H2V21Z"></path></g></svg>'},1144:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M18 14.59L16.59 16L18.59 18H7.82C7.79 17.9 7.75 17.81 7.7 17.71L17.71 7.7C18.1 7.89 18.53 8 19 8C20.65 8 22 6.65 22 5C22 3.35 20.65 2 19 2C17.7 2 16.6 2.84 16.18 4H7.82C7.41 2.84 6.31 2 5 2C3.35 2 2 3.35 2 5C2 6.65 3.35 8 5 8C6.3 8 7.4 7.16 7.82 6H16.19C16.22 6.1 16.26 6.19 16.31 6.29L6.29 16.3C5.9 16.11 5.47 16 5 16C3.35 16 2 17.35 2 19C2 20.65 3.35 22 5 22C6.3 22 7.4 21.16 7.82 20H18.59L16.59 22L18 23.41L22.41 19L18 14.59ZM19 4C19.55 4 20 4.45 20 5C20 5.55 19.55 6 19 6C18.45 6 18 5.55 18 5C18 4.45 18.45 4 19 4ZM5 6C4.45 6 4 5.55 4 5C4 4.45 4.45 4 5 4C5.55 4 6 4.45 6 5C6 5.55 5.55 6 5 6ZM5 20C4.45 20 4 19.55 4 19C4 18.45 4.45 18 5 18C5.55 18 6 18.45 6 19C6 19.55 5.55 20 5 20Z"></path></g></svg>'},386:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M12 2C8.02 2 4 3.37 4 6V18C4 20.63 8.02 22 12 22C15.98 22 20 20.63 20 18V6C20 3.37 15.98 2 12 2ZM12 4C15.72 4 18 5.29 18 6C18 6.71 15.72 8 12 8C8.28 8 6 6.71 6 6C6 5.29 8.28 4 12 4ZM12 20C8.28 20 6 18.71 6 18V16.73C7.54 17.57 9.78 18 12 18C14.22 18 16.46 17.57 18 16.73V18C18 18.71 15.72 20 12 20ZM18 14C18 14.71 15.72 16 12 16C8.28 16 6 14.71 6 14V12.73C7.54 13.57 9.78 14 12 14C14.22 14 16.46 13.57 18 12.73V14ZM18 10C18 10.71 15.72 12 12 12C8.28 12 6 10.71 6 10V8.73C7.54 9.57 9.78 10 12 10C14.22 10 16.46 9.57 18 8.73V10Z"></path></g></svg>'},4300:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M2.59 22H22V2.59L2.59 22ZM20 20H7.41L20 7.41V20ZM13 18L18 13V18H13ZM10 8C11.1 8 12 8.9 12 10C12 11.1 11.1 12 10 12C8.9 12 8 11.1 8 10C8 8.9 8.9 8 10 8ZM2 9.83C2 8.89 2.61 8.09 3.45 7.8C3.56 7.44 3.71 7.09 3.89 6.75C3.75 6.46 3.67 6.13 3.67 5.8C3.67 5.23 3.89 4.69 4.3 4.29C4.94 3.65 5.97 3.5 6.76 3.89C7.1 3.71 7.45 3.57 7.81 3.45C8.1 2.61 8.9 2 9.84 2C10.78 2 11.58 2.61 11.87 3.45C12.23 3.56 12.58 3.71 12.92 3.89C13.71 3.5 14.74 3.65 15.38 4.3C15.78 4.7 16.01 5.24 16.01 5.81C16.01 6.38 15.79 6.92 15.38 7.32L14.67 8.03L13.26 6.61L13.97 5.9C13.97 5.9 14.01 5.83 14.01 5.8C14.01 5.77 14.01 5.74 13.97 5.7C13.9 5.63 13.84 5.63 13.77 5.7L13.1 6.36L12.42 5.91C11.91 5.57 11.36 5.34 10.78 5.22L9.98 5.06V4.13C9.98 3.98 9.7 3.98 9.7 4.13V5.06L8.9 5.22C8.32 5.34 7.76 5.57 7.26 5.91L6.58 6.36L5.92 5.7C5.84 5.63 5.79 5.63 5.72 5.7C5.68 5.74 5.68 5.77 5.68 5.8C5.68 5.83 5.68 5.86 5.72 5.9L6.38 6.57L5.93 7.25C5.59 7.76 5.36 8.31 5.24 8.89L5.08 9.69H4.15C4.07 9.69 4.01 9.75 4.01 9.83C4.01 9.91 4.07 9.97 4.15 9.97H5.08L5.24 10.77C5.36 11.35 5.59 11.91 5.93 12.41L6.38 13.09L5.72 13.75C5.72 13.75 5.68 13.83 5.68 13.85C5.68 13.87 5.68 13.91 5.72 13.95C5.79 14.02 5.85 14.02 5.92 13.95L6.63 13.24L8.05 14.65L7.34 15.36C6.94 15.77 6.4 15.99 5.83 15.99C5.26 15.99 4.72 15.77 4.32 15.36C3.92 14.96 3.69 14.42 3.69 13.85C3.69 13.51 3.77 13.19 3.91 12.9C3.73 12.56 3.59 12.21 3.47 11.85C2.63 11.56 2.02 10.76 2.02 9.82L2 9.83Z"></path></g></svg>'},3236:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM6 7H9V9H6V7ZM12 7H18V9H12V7ZM6 11H9V13H6V11ZM12 11H18V13H12V11ZM6 15H9V17H6V15ZM12 15H18V17H12V15Z"></path></g></svg>'},833:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M21 2H3C1.9 2 1 2.9 1 4V15C1 16.1 1.9 17 3 17H21C22.1 17 23 16.1 23 15V4C23 2.9 22.1 2 21 2ZM4.41 15L9 10.41L12 13.41L14 11.41L17.59 15H4.41ZM20.41 15L14 8.59L12 10.59L9 7.59L3 13.59V4H21V15H20.41ZM19 7.5C19 8.33 18.33 9 17.5 9C16.67 9 16 8.33 16 7.5C16 6.67 16.67 6 17.5 6C18.33 6 19 6.67 19 7.5ZM8 21H16V23H8V21ZM6 18H18V20H6V18Z"></path></g></svg>'},1624:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version = v1"><path id="Vector" d="M17.75 8H15.25L13.35 13.08C12.2029 12.2588 11.2439 11.2027 10.537 9.98187C9.83 8.76107 9.39127 7.40364 9.25 6H14V4H9V2H7V4H2V6H6.91C6.73189 7.75797 6.09115 9.43736 5.05302 10.8672C4.01489 12.2971 2.61643 13.4263 1 14.14C1.32315 14.7296 1.69441 15.2915 2.11 15.82C4.82764 14.5445 6.96846 12.2966 8.11 9.52C9.02641 11.7596 10.5985 13.6698 12.62 15L10 22H12.42L13.79 18.13H19.16L20.56 22H23L17.75 8ZM14.46 16.16L15.73 12.53C16.0406 11.7049 16.2945 10.8596 16.49 10C16.55 10.26 16.67 10.66 16.84 11.21C17.01 11.76 17.14 12.15 17.24 12.41L18.55 16.2L14.46 16.16Z"></path></g></svg>'},5764:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V9C2 10.1 2.9 11 4 11H20C21.1 11 22 10.1 22 9V4C22 2.9 21.1 2 20 2ZM4 9V4H20V9H4ZM11 12H4C2.9 12 2 12.9 2 14V20C2 21.1 2.9 22 4 22H11C12.1 22 13 21.1 13 20V14C13 12.9 12.1 12 11 12ZM4 20V14H11V20H4ZM20 12H16C14.9 12 14 12.9 14 14V20C14 21.1 14.9 22 16 22H20C21.1 22 22 21.1 22 20V14C22 12.9 21.1 12 20 12ZM16 20V14H20V20H16Z"></path></g></svg>'},9551:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM20 4V17.59L15 12.59L13 14.59L10 11.59L4 17.59V4H20ZM19.59 20H4.41L10 14.41L13 17.41L15 15.41L19.59 20ZM14 8C14 6.9 14.9 6 16 6C17.1 6 18 6.9 18 8C18 9.1 17.1 10 16 10C14.9 10 14 9.1 14 8Z"></path></g></svg>'},5e3:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M5 12L10 8V16L5 12ZM14 8V16L19 12L14 8ZM23 12C23 18.07 18.07 23 12 23C5.93 23 1 18.07 1 12C1 5.93 5.93 1 12 1C18.07 1 23 5.93 23 12ZM21 12C21 7.04 16.96 3 12 3C7.04 3 3 7.04 3 12C3 16.96 7.04 21 12 21C16.96 21 21 16.96 21 12Z"></path></g></svg>'},1780:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M19 1H5C3.9 1 3 1.9 3 3V21C3 22.1 3.9 23 5 23H19C20.1 23 21 22.1 21 21V3C21 1.9 20.1 1 19 1ZM5 21V3H19V21H5ZM11 7H7V5H11V7ZM7 8H17V10H7V8ZM7 11H17V13H7V11ZM7 14H17V16H7V14ZM12 17H17V19H12V17Z"></path></g></svg>'},5824:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20.01 14.98H22.01V17.98C22.01 19.08 21.11 19.98 20.01 19.98H12.42L8.71 23.69C8.52 23.88 8.26 23.98 8 23.98C7.87 23.98 7.74 23.96 7.62 23.9C7.25 23.75 7 23.38 7 22.98V19.98H4C2.9 19.98 2 19.08 2 17.98V3.98C2 2.88 2.9 1.98 4 1.98H8V3.98H4.01V17.98H8.01C8.56 17.98 9.01 18.43 9.01 18.98V20.57L11.3 18.28C11.49 18.09 11.74 17.99 12.01 17.99H20.01V14.99V14.98ZM23.01 7.48C23.01 8.39 22.43 9.16 21.62 9.44C21.51 9.77 21.38 10.09 21.22 10.4C21.59 11.17 21.46 12.13 20.82 12.78C20.43 13.17 19.9 13.39 19.35 13.39C19.03 13.39 18.73 13.32 18.45 13.18C18.14 13.34 17.82 13.47 17.49 13.58C17.2 14.39 16.43 14.97 15.53 14.97C14.63 14.97 13.85 14.39 13.57 13.58C13.24 13.47 12.92 13.34 12.61 13.18C11.85 13.55 10.85 13.39 10.23 12.77C9.84 12.38 9.62 11.85 9.62 11.3C9.62 10.98 9.69 10.67 9.83 10.4C9.67 10.09 9.54 9.77 9.43 9.44C8.62 9.15 8.04 8.38 8.04 7.48C8.04 6.58 8.62 5.8 9.43 5.52C9.54 5.19 9.67 4.87 9.83 4.56C9.7 4.28 9.62 3.97 9.62 3.66C9.62 3.1 9.84 2.58 10.23 2.19C10.87 1.55 11.83 1.41 12.61 1.79C12.92 1.63 13.24 1.5 13.57 1.39C13.86 0.58 14.63 0 15.53 0C16.43 0 17.21 0.58 17.49 1.39C17.82 1.5 18.14 1.63 18.45 1.79C19.22 1.42 20.18 1.55 20.83 2.19C21.47 2.83 21.61 3.79 21.24 4.57C21.4 4.88 21.53 5.2 21.64 5.53C22.45 5.82 23.03 6.59 23.03 7.49L23.01 7.48ZM21.01 7.48C21.01 7.48 20.97 7.4 20.93 7.4H20L19.84 6.6C19.73 6.05 19.51 5.53 19.19 5.05L18.74 4.37L19.4 3.71C19.4 3.71 19.43 3.62 19.4 3.59C19.37 3.56 19.32 3.56 19.28 3.59L18.62 4.25L17.94 3.8C17.46 3.48 16.94 3.27 16.39 3.15L15.59 2.99V2.06C15.59 1.97 15.42 1.97 15.42 2.06V2.99L14.62 3.15C14.07 3.26 13.55 3.48 13.07 3.8L12.39 4.25L11.73 3.59C11.73 3.59 11.65 3.56 11.61 3.59V3.71L12.26 4.37L11.81 5.05C11.49 5.53 11.28 6.05 11.16 6.6L11 7.4H10.07C10.07 7.4 9.99 7.44 9.99 7.48C9.99 7.52 10.03 7.56 10.07 7.56H11L11.16 8.36C11.27 8.91 11.49 9.43 11.81 9.91L12.26 10.59L11.61 11.25V11.37H11.73L12.39 10.72L13.07 11.17C13.55 11.49 14.07 11.71 14.62 11.82L15.42 11.98V12.91C15.42 13 15.59 13 15.59 12.91V11.98L16.39 11.82C16.94 11.71 17.46 11.49 17.94 11.17L18.62 10.72L19.28 11.38H19.4C19.4 11.38 19.43 11.3 19.4 11.26L18.74 10.6L19.19 9.92C19.51 9.44 19.72 8.92 19.84 8.37L20 7.57H20.93C20.93 7.57 21.01 7.53 21.01 7.49V7.48ZM15.51 4.98C14.13 4.98 13.01 6.1 13.01 7.48C13.01 8.86 14.13 9.98 15.51 9.98C16.89 9.98 18.01 8.86 18.01 7.48C18.01 6.1 16.89 4.98 15.51 4.98Z"></path></g></svg>'},1557:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M19.26 7.15L20.41 6L19 4.59L17.75 5.84C16.12 4.69 14.14 4.01 12 4.01C9.86 4.01 7.88 4.69 6.25 5.84L5 4.59L3.59 6L4.74 7.15C3.05 8.94 2 11.35 2 14C2 19.51 6.49 24 12 24C17.51 24 22 19.51 22 14C22 11.35 20.96 8.94 19.26 7.15ZM12 22C7.59 22 4 18.41 4 14C4 9.59 7.59 6 12 6C16.41 6 20 9.59 20 14C20 18.41 16.41 22 12 22ZM15 8.58L16.41 9.99L12 14.4L10.59 12.99L15 8.58ZM9.2 3.36L8.83 1.4L9.81 1.21C11.29 0.93 12.7 0.93 14.18 1.21L15.16 1.4L14.79 3.36L13.81 3.17C12.57 2.94 11.42 2.94 10.18 3.17L9.2 3.36Z"></path></g></svg>'},7613:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M21 2V4H3V2H21ZM3 10H21V8H3V10ZM3 16H21V14H3V16ZM3 22H21V20H3V22Z"></path></g></svg>'},6534:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1" clip-path="url(#clip0_22397_60021)"><path id="Vector" d="M20 10.005H22V18.005C22 19.105 21.1 20.005 20 20.005H12.41L8.69999 23.715C8.50999 23.905 8.24999 24.005 7.98999 24.005C7.85999 24.005 7.72999 23.985 7.60999 23.925C7.23999 23.775 6.98999 23.405 6.98999 23.005V20.005H4.98999C3.33999 20.005 1.98999 18.655 1.98999 17.005V5.005C1.99999 3.355 3.34999 2.005 4.99999 2.005H14V4.005H4.99999C4.44999 4.005 3.99999 4.455 3.99999 5.005V17.005C3.99999 17.555 4.44999 18.005 4.99999 18.005H7.99999C8.54999 18.005 8.99999 18.455 8.99999 19.005V20.595L11.29 18.305C11.48 18.115 11.73 18.015 12 18.015H20V10.015V10.005ZM10.1 9.49501L16.79 2.795C18.01 1.575 19.99 1.575 21.2 2.795C22.41 4.015 22.42 5.99501 21.2 7.20501L14.5 13.905L8.60999 15.375L10.08 9.485L10.1 9.49501ZM18.21 4.215L17.42 5.005L19.01 6.59501L19.8 5.80501C20.01 5.59501 20.13 5.31501 20.13 5.01501C20.13 4.71501 20.01 4.435 19.8 4.225C19.38 3.805 18.64 3.805 18.21 4.225V4.215ZM11.37 12.635L13.48 12.105L17.58 8.005L15.99 6.41501L11.89 10.515L11.36 12.625L11.37 12.635Z"></path></g><defs><clipPath id="clip0_22397_60021"><rect width="24" height="24" fill="white"></rect></clipPath></defs></svg>'},1703:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M15.0001 13.59L19.4101 18L18.0001 19.41L13.5901 15L15.0001 13.59ZM15.0001 10.42L13.4101 12.01L12.0001 13.42L6.00009 19.42L4.59009 18.01L10.5901 12.01L9.00009 10.42L5.00009 14.42L0.590088 10L4.59009 6L3.59009 5L5.00009 3.59L6.00009 4.59L10.4101 9L12.0001 10.59L13.5901 9L18.0001 4.59L19.0001 3.59L20.4101 5L19.4101 6L23.4101 10L19.0001 14.41L15.0001 10.41V10.42ZM7.59009 9L6.00009 7.41L3.41009 10L5.00009 11.59L7.59009 9ZM16.4201 9L19.0101 11.59L20.6001 10L18.0101 7.41L16.4201 9Z"></path></g></svg>'},4992:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20 2H4C2.9 2 2 2.9 2 4V20C2 21.1 2.9 22 4 22H20C21.1 22 22 21.1 22 20V4C22 2.9 21.1 2 20 2ZM4 20V4H20V20H4ZM11 5H5V11H11V5ZM9 9H7V7H9V9ZM12 12H19V5H12V12ZM14 7H17V10H14V7ZM13 19H19V13H13V19ZM15 15H17V17H15V15ZM5 19H12V12H5V19ZM7 14H10V17H7V14Z"></path></g></svg>'},5891:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M20.0001 5H7.42009L14.4201 12L7.42009 19H20.0101V21H2.59009L11.5901 12L2.59009 3H20.0001V5Z"></path></g></svg>'},9324:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M3.34 5.325C3.57 5.785 3.41 6.335 2.99 6.615C2.93 7.115 2.51 7.505 2 7.505C1.45 7.505 1 7.055 1 6.505V6.005C1 5.625 1.21 5.275 1.55 5.115L2 4.895C2.49 4.645 3.09 4.845 3.34 5.345V5.325ZM2 15.415C2.55 15.415 3 14.965 3 14.415V13.535C3 12.985 2.55 12.535 2 12.535C1.45 12.535 1 12.985 1 13.535V14.415C1 14.965 1.45 15.415 2 15.415ZM2 11.455C2.55 11.455 3 11.005 3 10.455V9.575C3 9.025 2.55 8.575 2 8.575C1.45 8.575 1 9.025 1 9.575V10.455C1 11.005 1.45 11.455 2 11.455ZM2.99 17.385C2.93 16.885 2.51 16.495 2 16.495C1.45 16.495 1 16.945 1 17.495V17.995C1 18.375 1.21 18.725 1.55 18.885L2 19.105C2.14 19.175 2.3 19.215 2.45 19.215C2.82 19.215 3.17 19.015 3.35 18.665C3.58 18.205 3.42 17.655 3 17.375L2.99 17.385ZM9.45 20.605L8.72 20.245C8.23 19.995 7.63 20.195 7.38 20.695C7.13 21.185 7.33 21.785 7.83 22.035L8.56 22.395C8.7 22.465 8.86 22.505 9.01 22.505C9.38 22.505 9.73 22.305 9.91 21.955C10.16 21.465 9.96 20.865 9.46 20.615L9.45 20.605ZM6.17 18.965L5.44 18.605C4.95 18.355 4.35 18.555 4.1 19.055C3.85 19.545 4.05 20.145 4.55 20.395L5.28 20.755C5.42 20.825 5.58 20.865 5.73 20.865C6.1 20.865 6.45 20.665 6.63 20.315C6.88 19.825 6.68 19.225 6.18 18.975L6.17 18.965ZM12 21.875C11.51 21.625 10.91 21.825 10.66 22.325C10.41 22.815 10.61 23.415 11.11 23.665L11.56 23.885C11.7 23.955 11.85 23.995 12.01 23.995C12.17 23.995 12.32 23.955 12.46 23.885L12.91 23.665C13.4 23.415 13.6 22.815 13.36 22.325C13.11 21.835 12.51 21.635 12.02 21.875H12ZM18.56 18.595L17.83 18.955C17.34 19.205 17.14 19.805 17.38 20.295C17.56 20.645 17.91 20.845 18.28 20.845C18.43 20.845 18.58 20.815 18.73 20.735L19.46 20.375C19.95 20.125 20.15 19.525 19.91 19.035C19.66 18.545 19.06 18.345 18.57 18.585L18.56 18.595ZM15.28 20.235L14.55 20.595C14.06 20.845 13.86 21.445 14.1 21.935C14.28 22.285 14.63 22.485 15 22.485C15.15 22.485 15.3 22.455 15.45 22.375L16.18 22.015C16.67 21.765 16.87 21.165 16.63 20.675C16.38 20.185 15.78 19.985 15.29 20.225L15.28 20.235ZM22 16.495C21.49 16.495 21.06 16.885 21.01 17.385C20.59 17.655 20.43 18.215 20.66 18.675C20.84 19.025 21.19 19.225 21.56 19.225C21.71 19.225 21.86 19.195 22.01 19.115L22.46 18.895C22.8 18.725 23.01 18.375 23.01 18.005V17.505C23.01 16.955 22.56 16.505 22.01 16.505L22 16.495ZM22 12.535C21.45 12.535 21 12.985 21 13.535V14.415C21 14.965 21.45 15.415 22 15.415C22.55 15.415 23 14.965 23 14.415V13.535C23 12.985 22.55 12.535 22 12.535ZM22 8.575C21.45 8.575 21 9.025 21 9.575V10.455C21 11.005 21.45 11.455 22 11.455C22.55 11.455 23 11.005 23 10.455V9.575C23 9.025 22.55 8.575 22 8.575ZM22.45 5.105L22 4.885C21.51 4.635 20.91 4.835 20.66 5.335C20.43 5.795 20.59 6.345 21.01 6.625C21.07 7.125 21.49 7.515 22 7.515C22.55 7.515 23 7.065 23 6.515V6.015C23 5.635 22.79 5.285 22.45 5.125V5.105ZM14.55 3.385L15.28 3.745C15.42 3.815 15.58 3.855 15.73 3.855C16.1 3.855 16.45 3.655 16.63 3.305C16.88 2.815 16.68 2.215 16.18 1.965L15.45 1.605C14.96 1.355 14.36 1.555 14.11 2.055C13.86 2.555 14.06 3.145 14.56 3.395L14.55 3.385ZM17.83 5.025L18.56 5.385C18.7 5.455 18.86 5.495 19.01 5.495C19.38 5.495 19.73 5.295 19.91 4.945C20.16 4.455 19.96 3.855 19.46 3.605L18.73 3.245C18.24 2.995 17.64 3.195 17.39 3.695C17.14 4.185 17.34 4.785 17.84 5.035L17.83 5.025ZM12.89 0.325L12.44 0.105C12.16 -0.035 11.83 -0.035 11.55 0.105L11.1 0.325C10.61 0.575 10.41 1.175 10.65 1.665C10.9 2.155 11.5 2.355 11.99 2.115C12.13 2.185 12.29 2.225 12.44 2.225C12.81 2.225 13.16 2.025 13.34 1.675C13.59 1.185 13.39 0.585 12.89 0.335V0.325ZM8.28 3.855C8.43 3.855 8.58 3.825 8.73 3.745L9.46 3.385C9.95 3.135 10.15 2.535 9.91 2.045C9.66 1.555 9.06 1.355 8.57 1.595L7.84 1.955C7.35 2.205 7.15 2.805 7.39 3.295C7.57 3.645 7.92 3.845 8.29 3.845L8.28 3.855ZM5 5.495C5.15 5.495 5.3 5.465 5.45 5.385L6.18 5.025C6.67 4.775 6.87 4.175 6.63 3.685C6.38 3.195 5.78 2.995 5.29 3.235L4.56 3.595C4.07 3.845 3.87 4.445 4.11 4.935C4.29 5.285 4.64 5.485 5.01 5.485L5 5.495ZM6 6.655L5.56 6.415C5.07 6.155 4.47 6.335 4.21 6.825C3.95 7.315 4.13 7.915 4.62 8.175L5.06 8.415C5.21 8.495 5.37 8.535 5.53 8.535C5.89 8.535 6.23 8.345 6.41 8.005C6.67 7.515 6.49 6.915 6 6.655ZM7.7 9.835L8.45 10.235C8.6 10.315 8.76 10.355 8.92 10.355C9.28 10.355 9.62 10.165 9.8 9.825C10.06 9.335 9.88 8.735 9.39 8.475L8.64 8.075C8.15 7.815 7.55 7.995 7.29 8.485C7.03 8.975 7.21 9.575 7.7 9.835ZM13.32 10.285C13.06 9.805 12.48 9.625 12 9.855C11.52 9.615 10.93 9.805 10.68 10.285C10.44 10.745 10.6 11.295 11.02 11.585C11.07 12.095 11.48 12.495 12 12.495C12.52 12.495 12.93 12.095 12.98 11.585C13.41 11.305 13.57 10.745 13.32 10.285ZM15.37 8.065L14.61 8.465C14.12 8.725 13.94 9.335 14.2 9.815C14.38 10.155 14.73 10.345 15.08 10.345C15.24 10.345 15.4 10.305 15.55 10.225L16.31 9.825C16.8 9.565 16.98 8.955 16.72 8.475C16.46 7.985 15.85 7.805 15.37 8.065ZM18.46 6.415L18.02 6.655C17.53 6.915 17.35 7.525 17.61 8.005C17.79 8.345 18.14 8.535 18.49 8.535C18.65 8.535 18.81 8.495 18.96 8.415L19.4 8.175C19.89 7.915 20.07 7.305 19.81 6.825C19.55 6.335 18.94 6.155 18.46 6.415ZM12 17.495C11.45 17.495 11 17.945 11 18.495V18.995C11 19.545 11.45 19.995 12 19.995C12.55 19.995 13 19.545 13 18.995V18.495C13 17.945 12.55 17.495 12 17.495ZM13 14.555C13 14.005 12.55 13.555 12 13.555C11.45 13.555 11 14.005 11 14.555V15.435C11 15.985 11.45 16.435 12 16.435C12.55 16.435 13 15.985 13 15.435V14.555Z"></path></g></svg>'},3663:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g id="Version=v1"><path id="Vector" d="M12 1C5.93 1 1 5.93 1 12C1 18.07 5.93 23 12 23C18.07 23 23 18.07 23 12C23 5.93 18.07 1 12 1ZM12 21C7.04 21 3 16.96 3 12C3 7.04 7.04 3 12 3C16.96 3 21 7.04 21 12C21 16.96 16.96 21 12 21ZM17.41 8L13.41 12L17.41 16L16 17.41L12 13.41L8 17.41L6.59 16L10.59 12L6.59 8L8 6.59L12 10.59L16 6.59L17.41 8Z"></path></g></svg>'},8807:e=>{e.exports='<svg viewBox="0 0 25 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.5 1C6.42 1 1.5 5.92 1.5 12C1.5 18.08 6.42 23 12.5 23C18.58 23 23.5 18.08 23.5 12C23.5 5.92 18.58 1 12.5 1ZM12.5 21C7.54 21 3.5 16.96 3.5 12C3.5 7.04 7.54 3 12.5 3C17.46 3 21.5 7.04 21.5 12C21.5 16.96 17.46 21 12.5 21ZM17.41 10.25L11.47 6.95C10.85 6.6 10.1 6.61 9.49 6.97C8.87 7.33 8.5 7.98 8.5 8.69V15.29C8.5 16.01 8.87 16.65 9.49 17.01C9.81 17.2 10.15 17.29 10.5 17.29C10.85 17.29 11.17 17.21 11.47 17.04L17.41 13.74C18.04 13.39 18.44 12.72 18.44 11.99C18.44 11.26 18.05 10.59 17.41 10.24V10.25ZM10.5 15.3V8.7L16.44 12L10.5 15.3Z"></path></svg>'},6469:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M10.393 12.6465L5.69297 8.04651L10.393 3.34651L9.69297 2.64651L4.29297 8.04651L9.69297 13.3465L10.393 12.6465Z"></path></svg>'},9435:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C16.4 4 20 7.6 20 12C20 16.4 16.4 20 12 20C7.6 20 4 16.4 4 12C4 7.6 7.6 4 12 4ZM12 2C6.5 2 2 6.5 2 12C2 17.5 6.5 22 12 22C17.5 22 22 17.5 22 12C22 6.5 17.5 2 12 2ZM12 10C13.1 10 14 10.9 14 12C14 13.1 13.1 14 12 14C10.9 14 10 13.1 10 12C10 10.9 10.9 10 12 10ZM12 8C9.8 8 8 9.8 8 12C8 14.2 9.8 16 12 16C14.2 16 16 14.2 16 12C16 9.8 14.2 8 12 8Z"></path></svg>'},5677:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 4H2V21H14V16H18V11H22V4ZM12 19H4V16H12V19ZM16 14H4V11H16V14ZM20 9H4V6H20V9Z"></path></svg>'},9502:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0)"><path d="M12 6.8L12.9 9.7L13.3 11.1H14.8H17.8L15.4 12.9L14.2 13.8L14.6 15.2L15.5 18.1L13.1 16.3L12 15.3L10.8 16.2L8.4 18L9.3 15.1L9.7 13.7L8.5 12.8L6.1 11H9.1H10.6L11 9.6L12 6.8ZM12 0.300003L9.2 9H0L7.4 14.4L4.6 23.1L12 17.7L19.4 23.1L16.6 14.4L24 9H14.8L12 0.300003Z"></path></g><defs><clipPath id="clip0"><rect width="24" height="24"></rect></clipPath></defs></svg>'},2893:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7 8.00001H19.6L15.6 4.00001L17 2.60001L23.4 9.00001L17 15.4L15.6 14L19.6 10H7C4.8 10 3 11.8 3 14C3 16.2 4.8 18 7 18H8V20H7C3.7 20 1 17.3 1 14C1 10.7 3.7 8.00001 7 8.00001Z"></path></svg>'},8834:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M12 7V9H4V7H12ZM16 8C16 12.4 12.4 16 8 16C3.6 16 0 12.4 0 8C0 3.6 3.6 0 8 0C12.4 0 16 3.6 16 8ZM14 8C14 4.7 11.3 2 8 2C4.7 2 2 4.7 2 8C2 11.3 4.7 14 8 14C11.3 14 14 11.3 14 8Z"></path></svg>'},9890:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><g clip-path="url(#clip0_1564_16728)"><path d="M2.77 14.1393L6.09 9.03927L0 9.18927L0.06 6.51927L6.15 6.88927L2.96 1.68927L5.29 0.379272L8.02 5.81927L10.96 0.489272L13.23 1.84927L9.91 6.94927L16 6.79927L15.94 9.46927L9.85 9.09927L13.04 14.2993L10.71 15.6093L7.98 10.1693L5.04 15.4993L2.77 14.1393Z"></path></g><defs><clipPath id="clip0_1564_16728"><rect width="16" height="16" fill="white"></rect></clipPath></defs></svg>'},3334:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12.01 2.993C11.8 2.993 11.59 3.023 11.37 3.043L12.71 1.703L11.3 0.292999L7.59 4.003L11.3 7.713L12.71 6.303L11.46 5.053C11.64 5.043 11.82 5.013 12 5.013C15.86 5.013 19 8.153 19 12.013C19 15.873 15.86 19.013 12 19.013C8.14 19.013 5 15.873 5 12.013C5 11.463 4.55 11.013 4 11.013C3.45 11.013 3 11.463 3 12.013C3 16.973 7.04 21.013 12 21.013C16.96 21.013 21 16.973 21 12.013C21 7.053 16.97 2.993 12.01 2.993Z"></path></svg>'},3118:e=>{e.exports='<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 16 16"><path d="M12 13H4C2.9 13 2 12.1 2 11V5C2 3.9 2.9 3 4 3H12C13.1 3 14 3.9 14 5V11C14 12.1 13.1 13 12 13ZM4 5V11H12V5H4Z"></path></svg>'},1442:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 2H4L2 4V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V4C22 3.46957 21.7893 2.96086 21.4142 2.58579C21.0391 2.21071 20.5304 2 20 2ZM15 4V6H9V4H15ZM8 20V15H16V20H8ZM20 20H18V13H6V20H4V4.83L4.83 4H7V8H17V4H20V20Z"></path></svg>'},4179:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M23 11H19.9C19.4 7.4 16.6 4.5 13 4.1V1H11V4.1C7.4 4.5 4.5 7.4 4.1 11H1V13H4.1C4.6 16.6 7.4 19.5 11 19.9V23H13V19.9C16.6 19.4 19.5 16.6 19.9 13H23V11ZM12 18C8.7 18 6 15.3 6 12C6 8.7 8.7 6 12 6C15.3 6 18 8.7 18 12C18 15.3 15.3 18 12 18Z"></path></svg>'},7874:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M9.9 4C9.4 2.3 7.9 1 6 1C3.8 1 2 2.8 2 5C2 7.2 3.8 9 6 9C7.9 9 9.4 7.7 9.9 6H22V4H9.9ZM6 7C4.9 7 4 6.1 4 5C4 3.9 4.9 3 6 3C7.1 3 8 3.9 8 5C8 6.1 7.1 7 6 7ZM9 15C7.1 15 5.6 16.3 5.1 18H2V20H5.1C5.5 21.7 7.1 23 9 23C10.9 23 12.4 21.7 12.9 20H22V18H12.9C12.4 16.3 10.9 15 9 15ZM9 21C7.9 21 7 20.1 7 19C7 17.9 7.9 17 9 17C10.1 17 11 17.9 11 19C11 20.1 10.1 21 9 21ZM18 8C16.1 8 14.6 9.3 14.1 11H2V13H14.1C14.5 14.7 16.1 16 18 16C20.2 16 22 14.2 22 12C22 9.8 20.2 8 18 8ZM18 14C16.9 14 16 13.1 16 12C16 10.9 16.9 10 18 10C19.1 10 20 10.9 20 12C20 13.1 19.1 14 18 14Z"></path></svg>'},6973:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M6.8 2C6.4 0.8 5.3 0 4 0C2.3 0 1 1.3 1 3C1 4.7 2.3 6 4 6C5.3 6 6.4 5.2 6.8 4H15V2H6.8ZM4 4C3.4 4 3 3.6 3 3C3 2.4 3.4 2 4 2C4.6 2 5 2.4 5 3C5 3.6 4.6 4 4 4ZM12 5C10.7 5 9.6 5.8 9.2 7H1V9H9.2C9.6 10.2 10.7 11 12 11C13.7 11 15 9.7 15 8C15 6.3 13.7 5 12 5ZM12 9C11.4 9 11 8.6 11 8C11 7.4 11.4 7 12 7C12.6 7 13 7.4 13 8C13 8.6 12.6 9 12 9ZM6 10C4.7 10 3.6 10.8 3.2 12H1V14H3.2C3.6 15.2 4.7 16 6 16C7.3 16 8.4 15.2 8.8 14H15V12H8.8C8.4 10.8 7.3 10 6 10ZM6 14C5.4 14 5 13.6 5 13C5 12.4 5.4 12 6 12C6.6 12 7 12.4 7 13C7 13.6 6.6 14 6 14Z"></path></svg>'},3728:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M24 17V19H9.1C9.5 18.4 9.9 17.7 10.2 17H24ZM11.9 9.00001C11 13.7 8.6 19.6 5 22.6C3.8 23.6 2 22.6 2 21.1C2 20.4 2.1 19.7 2.2 19H0V17H2.8C4.3 12.9 7.6 9.10001 10.2 7.60001C10.4 6.10001 10.4 4.80001 10.2 3.90001C9.9 3.30001 9.7 3.00001 9.6 3.00001C9.4 3.00001 7.8 2.90001 3.8 8.70001L2.2 7.60001C5.5 2.80001 7.9 0.700007 9.9 1.00001C12 1.20001 12.5 4.60001 12.2 6.90001C14.3 7.00001 14.8 8.20001 14.9 10.3C16.2 9.10001 18.1 7.90001 19.2 9.20001C20.8 8.90001 22.1 10.4 22.9 11.5L21.3 12.7C20.4 11.4 19.8 11.2 19.6 11.2C19.5 11.2 19.5 11.3 19.4 11.4C19 12 18.6 12.8 18 13.7C17.7 14.1 17.2 14.3 16.7 14.1C15.5 13.5 16.5 12.1 16.8 11.2C15.8 12 14.4 13.4 13.9 14.8C13.8 15.5 13.3 16.3 12.5 16.1C11.6 15.9 11.7 14.9 12 14.2C13.3 9.80001 12.5 9.00001 12.5 9.00001C12.5 8.90001 12.2 8.80001 11.9 9.00001ZM9.5 10.4C6.9 12.8 4.1 17.1 4 20.8C6.6 18.5 8.5 14.3 9.5 10.4Z"></path></svg>'},939:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M11 5C12.7 5 14 6.3 14 8C14 9.7 12.7 11 11 11H5C3.3 11 2 9.7 2 8C2 6.3 3.3 5 5 5H11ZM11 3H5C2.2 3 0 5.2 0 8C0 10.8 2.2 13 5 13H11C13.8 13 16 10.8 16 8C16 5.2 13.8 3 11 3ZM11 6C9.9 6 9 6.9 9 8C9 9.1 9.9 10 11 10C12.1 10 13 9.1 13 8C13 6.9 12.1 6 11 6Z"></path></svg>'},2898:e=>{e.exports='<svg viewBox="0 0 16 16" xmlns="http://www.w3.org/2000/svg"><path d="M11 5C12.7 5 14 6.3 14 8C14 9.7 12.7 11 11 11H5C3.3 11 2 9.7 2 8C2 6.3 3.3 5 5 5H11ZM11 3H5C2.2 3 0 5.2 0 8C0 10.8 2.2 13 5 13H11C13.8 13 16 10.8 16 8C16 5.2 13.8 3 11 3ZM5 6C3.9 6 3 6.9 3 8C3 9.1 3.9 10 5 10C6.1 10 7 9.1 7 8C7 6.9 6.1 6 5 6Z"></path></svg>'},3602:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M22 7V6C22 4.9 21.1 4 20 4H16C14.9 4 14 4.9 14 6V7C14 8.1 14.9 9 16 9H20C21.1 9 22 8.1 22 7ZM20 7H16V6H20V7ZM2 6V7C2 8.1 2.9 9 4 9H11C12.1 9 13 8.1 13 7V6C13 4.9 12.1 4 11 4H4C2.9 4 2 4.9 2 6ZM4 6H11V7H4V6ZM9 12V13C9 14.1 9.9 15 11 15H20C21.1 15 22 14.1 22 13V12C22 10.9 21.1 10 20 10H11C9.9 10 9 10.9 9 12ZM11 12H20V13H11V12ZM2 18V19C2 20.1 2.9 21 4 21H15C16.1 21 17 20.1 17 19V18C17 16.9 16.1 16 15 16H4C2.9 16 2 16.9 2 18ZM4 18H15V19H4V18ZM2 12V13C2 14.1 2.9 15 4 15H6C7.1 15 8 14.1 8 13V12C8 10.9 7.1 10 6 10H4C2.9 10 2 10.9 2 12ZM4 12H6V13H4V12Z"></path></svg>'},1516:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M20 6H4C2.9 6 2 6.9 2 8V16C2 17.1 2.9 18 4 18H20C21.1 18 22 17.1 22 16V8C22 6.9 21.1 6 20 6ZM20 16H4V8H20V16ZM14 13H6V11H14V13Z"></path></svg>'},3076:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M24 21.4201C23.9387 22.1566 23.5894 22.8394 23.0278 23.3202C22.4662 23.8011 21.7376 24.0413 21 23.9888C20.2624 24.0413 19.5338 23.8011 18.9722 23.3202C18.4106 22.8394 18.0613 22.1566 18 21.4201C18 18.8513 21 16.2826 21 14.9932C21 16.2826 24 18.8513 24 21.4201ZM22 12.9942L11 1.99951L8.71 4.2884L10.12 5.70771L11 4.82814L18.17 11.9946L5.64 15.8028L2.83 12.9942L7.71 8.11653L9.29 9.70576C9.38296 9.79944 9.49356 9.8738 9.61542 9.92455C9.73728 9.97529 9.86799 10.0014 10 10.0014C10.132 10.0014 10.2627 9.97529 10.3846 9.92455C10.5064 9.8738 10.617 9.79944 10.71 9.70576C10.8037 9.61284 10.8781 9.5023 10.9289 9.3805C10.9797 9.2587 11.0058 9.12805 11.0058 8.99611C11.0058 8.86416 10.9797 8.73352 10.9289 8.61172C10.8781 8.48992 10.8037 8.37937 10.71 8.28645L3.71 1.28986C3.5217 1.10165 3.2663 0.995911 3 0.995911C2.7337 0.995911 2.4783 1.10165 2.29 1.28986C2.1017 1.47807 1.99591 1.73334 1.99591 1.99951C1.99591 2.26569 2.1017 2.52096 2.29 2.70917L6.29 6.70722L0 12.9942L10 22.9893L18 14.9932L22 12.9942Z"></path></svg>'},3358:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M21 4H16V2C16 1.46957 15.7893 0.960859 15.4142 0.585786C15.0391 0.210714 14.5304 0 14 0L10 0C9.46957 0 8.96086 0.210714 8.58579 0.585786C8.21071 0.960859 8 1.46957 8 2V4H3C2.46957 4 1.96086 4.21071 1.58579 4.58579C1.21071 4.96086 1 5.46957 1 6V12H2V20C2 20.5304 2.21071 21.0391 2.58579 21.4142C2.96086 21.7893 3.46957 22 4 22H20C20.5304 22 21.0391 21.7893 21.4142 21.4142C21.7893 21.0391 22 20.5304 22 20V12H23V6C23 5.46957 22.7893 4.96086 22.4142 4.58579C22.0391 4.21071 21.5304 4 21 4ZM10 2H14V4H10V2ZM20 20H4V12H9V16H15V12H20V20ZM11 14V10H13V14H11ZM21 10H15V8H9V10H3V6H21V10Z"></path></svg>'},80:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M3.34 5.325C3.57 5.785 3.41 6.335 2.99 6.615C2.93 7.115 2.51 7.505 2 7.505C1.45 7.505 1 7.055 1 6.505V6.005C1 5.625 1.21 5.275 1.55 5.115L2 4.895C2.49 4.645 3.09 4.845 3.34 5.345V5.325ZM2 15.415C2.55 15.415 3 14.965 3 14.415V13.535C3 12.985 2.55 12.535 2 12.535C1.45 12.535 1 12.985 1 13.535V14.415C1 14.965 1.45 15.415 2 15.415ZM2 11.455C2.55 11.455 3 11.005 3 10.455V9.575C3 9.025 2.55 8.575 2 8.575C1.45 8.575 1 9.025 1 9.575V10.455C1 11.005 1.45 11.455 2 11.455ZM2.99 17.385C2.93 16.885 2.51 16.495 2 16.495C1.45 16.495 1 16.945 1 17.495V17.995C1 18.375 1.21 18.725 1.55 18.885L2 19.105C2.14 19.175 2.3 19.215 2.45 19.215C2.82 19.215 3.17 19.015 3.35 18.665C3.58 18.205 3.42 17.655 3 17.375L2.99 17.385ZM9.45 20.605L8.72 20.245C8.23 19.995 7.63 20.195 7.38 20.695C7.13 21.185 7.33 21.785 7.83 22.035L8.56 22.395C8.7 22.465 8.86 22.505 9.01 22.505C9.38 22.505 9.73 22.305 9.91 21.955C10.16 21.465 9.96 20.865 9.46 20.615L9.45 20.605ZM6.17 18.965L5.44 18.605C4.95 18.355 4.35 18.555 4.1 19.055C3.85 19.545 4.05 20.145 4.55 20.395L5.28 20.755C5.42 20.825 5.58 20.865 5.73 20.865C6.1 20.865 6.45 20.665 6.63 20.315C6.88 19.825 6.68 19.225 6.18 18.975L6.17 18.965ZM12 21.875C11.51 21.625 10.91 21.825 10.66 22.325C10.41 22.815 10.61 23.415 11.11 23.665L11.56 23.885C11.7 23.955 11.85 23.995 12.01 23.995C12.17 23.995 12.32 23.955 12.46 23.885L12.91 23.665C13.4 23.415 13.6 22.815 13.36 22.325C13.11 21.835 12.51 21.635 12.02 21.875H12ZM18.56 18.595L17.83 18.955C17.34 19.205 17.14 19.805 17.38 20.295C17.56 20.645 17.91 20.845 18.28 20.845C18.43 20.845 18.58 20.815 18.73 20.735L19.46 20.375C19.95 20.125 20.15 19.525 19.91 19.035C19.66 18.545 19.06 18.345 18.57 18.585L18.56 18.595ZM15.28 20.235L14.55 20.595C14.06 20.845 13.86 21.445 14.1 21.935C14.28 22.285 14.63 22.485 15 22.485C15.15 22.485 15.3 22.455 15.45 22.375L16.18 22.015C16.67 21.765 16.87 21.165 16.63 20.675C16.38 20.185 15.78 19.985 15.29 20.225L15.28 20.235ZM22 16.495C21.49 16.495 21.06 16.885 21.01 17.385C20.59 17.655 20.43 18.215 20.66 18.675C20.84 19.025 21.19 19.225 21.56 19.225C21.71 19.225 21.86 19.195 22.01 19.115L22.46 18.895C22.8 18.725 23.01 18.375 23.01 18.005V17.505C23.01 16.955 22.56 16.505 22.01 16.505L22 16.495ZM22 12.535C21.45 12.535 21 12.985 21 13.535V14.415C21 14.965 21.45 15.415 22 15.415C22.55 15.415 23 14.965 23 14.415V13.535C23 12.985 22.55 12.535 22 12.535ZM22 8.575C21.45 8.575 21 9.025 21 9.575V10.455C21 11.005 21.45 11.455 22 11.455C22.55 11.455 23 11.005 23 10.455V9.575C23 9.025 22.55 8.575 22 8.575ZM22.45 5.105L22 4.885C21.51 4.635 20.91 4.835 20.66 5.335C20.43 5.795 20.59 6.345 21.01 6.625C21.07 7.125 21.49 7.515 22 7.515C22.55 7.515 23 7.065 23 6.515V6.015C23 5.635 22.79 5.285 22.45 5.125V5.105ZM14.55 3.385L15.28 3.745C15.42 3.815 15.58 3.855 15.73 3.855C16.1 3.855 16.45 3.655 16.63 3.305C16.88 2.815 16.68 2.215 16.18 1.965L15.45 1.605C14.96 1.355 14.36 1.555 14.11 2.055C13.86 2.555 14.06 3.145 14.56 3.395L14.55 3.385ZM17.83 5.025L18.56 5.385C18.7 5.455 18.86 5.495 19.01 5.495C19.38 5.495 19.73 5.295 19.91 4.945C20.16 4.455 19.96 3.855 19.46 3.605L18.73 3.245C18.24 2.995 17.64 3.195 17.39 3.695C17.14 4.185 17.34 4.785 17.84 5.035L17.83 5.025ZM12.89 0.325L12.44 0.105C12.16 -0.035 11.83 -0.035 11.55 0.105L11.1 0.325C10.61 0.575 10.41 1.175 10.65 1.665C10.9 2.155 11.5 2.355 11.99 2.115C12.13 2.185 12.29 2.225 12.44 2.225C12.81 2.225 13.16 2.025 13.34 1.675C13.59 1.185 13.39 0.585 12.89 0.335V0.325ZM8.28 3.855C8.43 3.855 8.58 3.825 8.73 3.745L9.46 3.385C9.95 3.135 10.15 2.535 9.91 2.045C9.66 1.555 9.06 1.355 8.57 1.595L7.84 1.955C7.35 2.205 7.15 2.805 7.39 3.295C7.57 3.645 7.92 3.845 8.29 3.845L8.28 3.855ZM5 5.495C5.15 5.495 5.3 5.465 5.45 5.385L6.18 5.025C6.67 4.775 6.87 4.175 6.63 3.685C6.38 3.195 5.78 2.995 5.29 3.235L4.56 3.595C4.07 3.845 3.87 4.445 4.11 4.935C4.29 5.285 4.64 5.485 5.01 5.485L5 5.495ZM6 6.655L5.56 6.415C5.07 6.155 4.47 6.335 4.21 6.825C3.95 7.315 4.13 7.915 4.62 8.175L5.06 8.415C5.21 8.495 5.37 8.535 5.53 8.535C5.89 8.535 6.23 8.345 6.41 8.005C6.67 7.515 6.49 6.915 6 6.655ZM7.7 9.835L8.45 10.235C8.6 10.315 8.76 10.355 8.92 10.355C9.28 10.355 9.62 10.165 9.8 9.825C10.06 9.335 9.88 8.735 9.39 8.475L8.64 8.075C8.15 7.815 7.55 7.995 7.29 8.485C7.03 8.975 7.21 9.575 7.7 9.835ZM13.32 10.285C13.06 9.805 12.48 9.625 12 9.855C11.52 9.615 10.93 9.805 10.68 10.285C10.44 10.745 10.6 11.295 11.02 11.585C11.07 12.095 11.48 12.495 12 12.495C12.52 12.495 12.93 12.095 12.98 11.585C13.41 11.305 13.57 10.745 13.32 10.285ZM15.37 8.065L14.61 8.465C14.12 8.725 13.94 9.335 14.2 9.815C14.38 10.155 14.73 10.345 15.08 10.345C15.24 10.345 15.4 10.305 15.55 10.225L16.31 9.825C16.8 9.565 16.98 8.955 16.72 8.475C16.46 7.985 15.85 7.805 15.37 8.065ZM18.46 6.415L18.02 6.655C17.53 6.915 17.35 7.525 17.61 8.005C17.79 8.345 18.14 8.535 18.49 8.535C18.65 8.535 18.81 8.495 18.96 8.415L19.4 8.175C19.89 7.915 20.07 7.305 19.81 6.825C19.55 6.335 18.94 6.155 18.46 6.415ZM12 17.495C11.45 17.495 11 17.945 11 18.495V18.995C11 19.545 11.45 19.995 12 19.995C12.55 19.995 13 19.545 13 18.995V18.495C13 17.945 12.55 17.495 12 17.495ZM13 14.555C13 14.005 12.55 13.555 12 13.555C11.45 13.555 11 14.005 11 14.555V15.435C11 15.985 11.45 16.435 12 16.435C12.55 16.435 13 15.985 13 15.435V14.555Z"></path></svg>'},9775:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M17 8.00001H4.40001L8.40001 4.00001L7.00001 2.60001L0.600006 9.00001L7.00001 15.4L8.40001 14L4.40001 10H17C19.2 10 21 11.8 21 14C21 16.2 19.2 18 17 18H16V20H17C20.3 20 23 17.3 23 14C23 10.7 20.3 8.00001 17 8.00001Z"></path></svg>'},5405:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M12 4C7.2 4 3 7.2 0.5 12C3 16.8 7.2 20 12 20C16.8 20 20.9 16.8 23.5 12C20.9 7.2 16.7 4 12 4ZM12 18C8.5 18 5.1 15.8 2.8 12C5.1 8.2 8.5 6 12 6C15.5 6 18.9 8.2 21.2 12C18.9 15.8 15.5 18 12 18ZM12 7C9.2 7 7 9.2 7 12C7 14.8 9.2 17 12 17C14.8 17 17 14.8 17 12C17 9.2 14.7 7 12 7ZM12 15C10.3 15 9 13.7 9 12C9 11.7 9 11.5 9.1 11.3L12 12L10.3 9.5C10.8 9.2 11.3 9 12 9C13.7 9 15 10.3 15 12C15 13.7 13.6 15 12 15Z"></path></svg>'},1612:e=>{e.exports='<svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><path d="M7.7 16.3C8.1 16.7 8.1 17.3 7.7 17.7L3.7 21.7C3.5 21.9 3.3 22 3 22C2.7 22 2.5 21.9 2.3 21.7C1.9 21.3 1.9 20.7 2.3 20.3L6.3 16.3C6.7 15.9 7.3 15.9 7.7 16.3ZM20.5 10L23 13.7L18.6 14.6L17.7 19L14 16.5L10.3 19L9.4 14.6L5 13.7L7.5 10L5 6.3L9.4 5.4L10.3 1L14 3.5L17.7 1L18.6 5.4L23 6.3L20.5 10ZM18.1 10L18.8 8.9L19.6 7.7L18.1 7.4L16.8 7.1L16.5 5.8L16.2 4.3L15 5.1L14 5.9L12.9 5.2L11.7 4.3L11.4 5.8L11.1 7.1L9.8 7.4L8.3 7.7L9.1 8.9L9.9 10L9.2 11.1L8.4 12.3L9.9 12.6L11.2 12.9L11.5 14.2L11.8 15.7L13 14.9L14.1 14.2L15.2 14.9L16.4 15.7L16.7 14.2L17 12.9L18.3 12.6L19.8 12.3L19 11.1L18.1 10Z"></path></svg>'},7288:(e,t,o)=>{var i={"./add-lg.svg":6504,"./add.svg":618,"./add_16x16.svg":1797,"./add_24x24.svg":6539,"./alert_24x24.svg":356,"./apply.svg":631,"./arrow-down.svg":4321,"./arrow-left.svg":1354,"./arrow-left_16x16.svg":1685,"./arrow-right.svg":3153,"./arrow-right_16x16.svg":3142,"./arrow-up.svg":3422,"./boolean.svg":9331,"./change-question-type_16x16.svg":7140,"./checkbox.svg":2678,"./checked.svg":8020,"./chevron_16x16.svg":5981,"./clear.svg":9380,"./clear_16x16.svg":6907,"./codeeditor-24x24.svg":9054,"./collapse-detail-light_16x16.svg":7678,"./collapse-detail_16x16.svg":6845,"./collapse-panel.svg":9405,"./collapse-v_16x16.svg":4358,"./collapse_16x16.svg":943,"./collapseall-24x24.svg":6398,"./color-picker.svg":8813,"./comment.svg":6124,"./config.svg":2739,"./copy.svg":2622,"./default.svg":6252,"./delete_16x16.svg":2583,"./delete_24x24.svg":405,"./description-hide.svg":4802,"./description.svg":5869,"./device-desktop.svg":4548,"./device-phone.svg":736,"./device-rotate.svg":3441,"./device-tablet.svg":9364,"./download.svg":6813,"./drag-area-indicator.svg":9531,"./drag-area-indicator_24x16.svg":1689,"./drop-down-arrow.svg":2483,"./drop-down-arrow_16x16.svg":3892,"./dropdown.svg":7382,"./duplicate_16x16.svg":2723,"./edit.svg":5669,"./edit_16x16.svg":2290,"./editing-finish.svg":9697,"./embedsurvey-24x24.svg":2485,"./error.svg":7857,"./expand-detail-light_16x16.svg":7789,"./expand-detail_16x16.svg":7374,"./expand-panel.svg":5208,"./expand-v_16x16.svg":2731,"./expand_16x16.svg":6294,"./expandall-24x24.svg":5049,"./export.svg":1403,"./expression.svg":1399,"./fast-entry.svg":9516,"./file.svg":271,"./fix.svg":4706,"./html.svg":3698,"./image.svg":5168,"./imagepicker.svg":9630,"./import.svg":5518,"./invisible-items.svg":4925,"./keyboard-dragging.svg":8516,"./language.svg":6247,"./load.svg":2937,"./logic-24x24.svg":9730,"./logic-collapse.svg":1523,"./logic-expand.svg":1390,"./logo.svg":780,"./matrix.svg":7466,"./matrixdropdown.svg":8125,"./matrixdynamic.svg":169,"./multipletext.svg":6544,"./next_16x16.svg":5265,"./panel.svg":8273,"./paneldynamic.svg":4520,"./pg-v1/pg-appearance-24x24.svg":2804,"./pg-v1/pg-background-24x24.svg":5574,"./pg-v1/pg-columns-24x24.svg":1965,"./pg-v1/pg-conditions-24x24.svg":1144,"./pg-v1/pg-data-24x24.svg":386,"./pg-v1/pg-design-24x24.svg":4300,"./pg-v1/pg-general-24x24.svg":3236,"./pg-v1/pg-header-24x24.svg":833,"./pg-v1/pg-language-24x24.svg":1624,"./pg-v1/pg-layout-24x24.svg":5764,"./pg-v1/pg-logo-24x24.svg":9551,"./pg-v1/pg-navigation-24x24.svg":5e3,"./pg-v1/pg-pages-24x24.svg":1780,"./pg-v1/pg-questiondesign-24x24.svg":5824,"./pg-v1/pg-quiz-24x24.svg":1557,"./pg-v1/pg-rows-24x24.svg":7613,"./pg-v1/pg-specific-24x24.svg":6534,"./pg-v1/pg-thankyyoupage-24x24.svg":1703,"./pg-v1/pg-themes-24x24.svg":4992,"./pg-v1/pg-totals-24x24.svg":5891,"./pg-v1/pg-undefined-24x24.svg":9324,"./pg-v1/pg-validation-24x24.svg":3663,"./preview.svg":8807,"./previous_16x16.svg":6469,"./radiogroup.svg":9435,"./ranking.svg":5677,"./rating.svg":9502,"./redo.svg":2893,"./remove_16x16.svg":8834,"./required.svg":9890,"./reset.svg":3334,"./restore_16x16.svg":3118,"./save.svg":1442,"./select-page.svg":4179,"./settings.svg":7874,"./settings_16x16.svg":6973,"./signaturepad.svg":3728,"./switch-active_16x16.svg":939,"./switch-inactive_16x16.svg":2898,"./tagbox.svg":3602,"./text.svg":1516,"./theme.svg":3076,"./toolbox.svg":3358,"./undefined-24x24.svg":80,"./undo.svg":9775,"./visible.svg":5405,"./wizard.svg":1612};function n(e){var t=r(e);return o(t)}function r(e){if(!o.o(i,e)){var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}return i[e]}n.keys=function(){return Object.keys(i)},n.resolve=r,e.exports=n,n.id=7288},156:t=>{"use strict";t.exports=e},5271:e=>{"use strict";e.exports=t},7238:e=>{"use strict";e.exports=o}},n={};function r(e){var t=n[e];if(void 0!==t)return t.exports;var o=n[e]={exports:{}};return i[e].call(o.exports,o,o.exports,r),o.exports}r.d=(e,t)=>{for(var o in t)r.o(t,o)&&!r.o(e,o)&&Object.defineProperty(e,o,{enumerable:!0,get:t[o]})},r.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};return(()=>{"use strict";r.r(a),r.d(a,{AceJsonEditorModel:()=>xe,ColorCalculator:()=>H,CreatorAction:()=>Zi,CreatorBase:()=>Ki,CreatorEvent:()=>Ji,CreatorPreset:()=>kr,CreatorPresetBase:()=>Ir,CreatorPresetPropertyGrid:()=>Dr,CreatorPresetPropertyGridDefinition:()=>Mr,CreatorPresetTabs:()=>_r,CreatorPresetToolbox:()=>Nr,CreatorPresetToolboxConfigurator:()=>Ar,CreatorPresetToolboxDefinition:()=>Or,CreatorResponsivityManager:()=>Go,CreatorThemeModel:()=>Bo,DEFAULT_MONITOR_DPI:()=>Ve,DefaultFonts:()=>ri,DragDropSurveyElements:()=>Ft,EditorLocalization:()=>U,EmptySurveyCreatorOptions:()=>n,HSBToRGB:()=>j,ImageItemValueWrapperViewModel:()=>wn,ItemValueWrapperViewModel:()=>Cn,JsonDuplicateNameError:()=>de,JsonEditorBaseModel:()=>Ce,LogicEvent:()=>Qe,LogoImageViewModel:()=>Vn,MatrixCellWrapperEditSurvey:()=>xn,MatrixCellWrapperViewModel:()=>Tn,MenuButton:()=>kt,ObjType:()=>Y,ObjectSelector:()=>To,ObjectSelectorItem:()=>xo,ObjectSelectorModel:()=>So,PageAdorner:()=>hn,PageNavigatorViewModel:()=>dn,PagesController:()=>Eo,PredefinedColors:()=>Fo,PredefinedThemes:()=>Ho,PropertyEditorSetupValue:()=>it,PropertyGridCellsEditor:()=>fr,PropertyGridEditor:()=>lt,PropertyGridEditorBackgroundCornerRadius:()=>sr,PropertyGridEditorBindings:()=>ir,PropertyGridEditorBoolean:()=>ut,PropertyGridEditorCollection:()=>nt,PropertyGridEditorColor:()=>yt,PropertyGridEditorColorWithAlpha:()=>vt,PropertyGridEditorCondition:()=>qn,PropertyGridEditorDateTime:()=>gt,PropertyGridEditorDropdown:()=>Pt,PropertyGridEditorExpression:()=>Bn,PropertyGridEditorFontSettings:()=>ar,PropertyGridEditorHtml:()=>Tt,PropertyGridEditorImageSize:()=>wt,PropertyGridEditorMatrix:()=>Qn,PropertyGridEditorMatrixCalculatedValues:()=>Wn,PropertyGridEditorMatrixColumns:()=>Zn,PropertyGridEditorMatrixHtmlConditions:()=>Kn,PropertyGridEditorMatrixItemValues:()=>Un,PropertyGridEditorMatrixLayoutColumns:()=>zn,PropertyGridEditorMatrixMultipleTypes:()=>$n,PropertyGridEditorMatrixMutlipleTextItems:()=>Xn,PropertyGridEditorMatrixPages:()=>Jn,PropertyGridEditorMatrixRateValues:()=>Gn,PropertyGridEditorMatrixTriggers:()=>tr,PropertyGridEditorMatrixUrlConditions:()=>Yn,PropertyGridEditorMatrixValidators:()=>er,PropertyGridEditorNumber:()=>bt,PropertyGridEditorPage:()=>Vt,PropertyGridEditorQuestion:()=>It,PropertyGridEditorQuestionCarryForward:()=>At,PropertyGridEditorQuestionHeader:()=>Pr,PropertyGridEditorQuestionMaskSettings:()=>Tr,PropertyGridEditorQuestionRestfull:()=>rr,PropertyGridEditorQuestionSelectBase:()=>Ot,PropertyGridEditorQuestionValue:()=>Nt,PropertyGridEditorSet:()=>Et,PropertyGridEditorShadowEffects:()=>lr,PropertyGridEditorSpinEdit:()=>Ct,PropertyGridEditorString:()=>ht,PropertyGridEditorStringArray:()=>St,PropertyGridEditorStringBase:()=>dt,PropertyGridEditorSwitchToggle:()=>pt,PropertyGridEditorText:()=>xt,PropertyGridEditorUndefinedBoolean:()=>ct,PropertyGridLinkEditor:()=>ft,PropertyGridModel:()=>st,PropertyGridPanelValueEditor:()=>br,PropertyGridRowValueEditor:()=>vr,PropertyGridTitleActionsCreator:()=>rt,PropertyGridTriggerValueEditor:()=>Cr,PropertyGridTriggerValueInLogicEditor:()=>wr,PropertyGridValueEditor:()=>yr,PropertyGridValueEditorBase:()=>mr,PropertyGridViewModel:()=>Po,PropertyJSONGenerator:()=>at,QuestionAdornerViewModel:()=>mn,QuestionColorModel:()=>Mn,QuestionCommentWithResetModel:()=>Rn,QuestionConvertMode:()=>e,QuestionConverter:()=>$,QuestionDropdownAdornerViewModel:()=>fn,QuestionEmbeddedSurveyModel:()=>On,QuestionFileEditorModel:()=>Dn,QuestionImageAdornerViewModel:()=>yn,QuestionLinkValueModel:()=>An,QuestionRatingAdornerViewModel:()=>vn,QuestionSpinEditorModel:()=>Nn,QuestionTextWithResetModel:()=>jn,QuestionToolbox:()=>ve,QuestionToolboxCategory:()=>fe,QuestionToolboxItem:()=>ye,RGBToHSB:()=>R,ResetValueAdorner:()=>kn,ResizeManager:()=>Jo,RowViewModel:()=>gn,SearchManager:()=>he,SearchManagerPropertyGrid:()=>me,SearchManagerToolbox:()=>ge,SidebarHeaderModel:()=>zo,SidebarModel:()=>Wo,SidebarPageModel:()=>Zo,StringEditorConnector:()=>oi,StringEditorViewModelBase:()=>ii,StringItemsNavigatorBase:()=>Ko,StylesManager:()=>Yi,SurveyCreatorModel:()=>Wi,SurveyHelper:()=>ee,SurveyJSON5:()=>X,SurveyLogic:()=>Ue,SurveyLogicUI:()=>co,SurveyQuestionEditorDefinition:()=>Ke,SurveyQuestionEditorPropertyDefinition:()=>Ye,SurveyQuestionEditorTabDefinition:()=>Xe,SurveyQuestionProperties:()=>et,SurveyResultsItemModel:()=>Sn,SurveyResultsModel:()=>En,SurveySimulatorModel:()=>Ee,SurveyTextWorker:()=>ce,SurveyTextWorkerError:()=>ie,SurveyTextWorkerJsonError:()=>pe,SurveyTextWorkerParserError:()=>ne,Switcher:()=>ki,TabControlModel:()=>No,TabDesignerPlugin:()=>Uo,TabDesignerViewModel:()=>Io,TabJsonEditorAcePlugin:()=>Te,TabJsonEditorBasePlugin:()=>we,TabJsonEditorTextareaPlugin:()=>Pe,TabLogicPlugin:()=>ho,TabTestPlugin:()=>Ne,TabTranslationPlugin:()=>eo,TabbedMenuContainer:()=>Gi,TabbedMenuItem:()=>Ui,TestSurveyTabViewModel:()=>Ae,TextareaJsonEditorModel:()=>Se,ThemeModelEditorDefinition:()=>Bi,ThemeTabPlugin:()=>qi,ThemeTabViewModel:()=>ni,Themes:()=>qo,ToolbarActionContainer:()=>zi,ToolboxToolViewModel:()=>cn,Transaction:()=>mo,Translation:()=>Wt,TranslationEditor:()=>Yt,TranslationForEditor:()=>Kt,TranslationGroup:()=>Jt,TranslationItem:()=>zt,TranslationItemBase:()=>Gt,TranslationItemString:()=>Zt,UndoRedoAction:()=>fo,UndoRedoArrayAction:()=>yo,UndoRedoManager:()=>go,UndoRedoPlugin:()=>bo,Version:()=>Vr,assign:()=>q,assignDefaultV2Classes:()=>P,backgroundCornerRadiusFromCssVariable:()=>gi,backgroundCornerRadiusToCssVariable:()=>hi,calculateDragOverLocation:()=>Bt,calculateIsEdge:()=>jt,calculateIsSide:()=>Rt,capitalize:()=>V,clearNewLines:()=>w,convertRgbaToString:()=>M,copyCssClasses:()=>S,copyObject:()=>T,createBoxShadow:()=>yi,createBoxShadowReset:()=>vi,createColor:()=>Ai,createExportCSVAction:()=>$t,createImportCSVAction:()=>Xt,creatorThemeModelEditorDefinition:()=>Do,creatorThemeModelPropertyGridDefinition:()=>Mo,defaultPropertyGridDefinition:()=>We,defaultStrings:()=>z,editableStringRendererName:()=>en,editorLocalization:()=>G,enStrings:()=>t,findParentNode:()=>g,focusFirstControl:()=>m,fontsettingsFromCssVariable:()=>pi,fontsettingsToCssVariable:()=>ui,getAcceptedTypesByContentMode:()=>A,getElementWrapperComponentData:()=>nn,getElementWrapperComponentName:()=>tn,getFirstNonTextElement:()=>f,getItemValueWrapperComponentData:()=>an,getItemValueWrapperComponentName:()=>rn,getLocString:()=>Z,getNextItemText:()=>d,getNextItemValue:()=>c,getNextValue:()=>h,getNodesFromKoComponentInfo:()=>y,getPredefinedColorsItemValues:()=>Qo,getQuestionContentWrapperComponentName:()=>on,getQuestionFromObj:()=>N,ignoreUndoRedo:()=>wo,imageMimeTypes:()=>O,ingectAlpha:()=>_,initLogicOperator:()=>Fe,initialSettingsAllowShowEmptyTitleInDesignMode:()=>Vo,initializeDesignTimeSurveyModel:()=>Xi,isPanelDynamic:()=>qt,isPropertyVisible:()=>b,isStringEditable:()=>sn,isTextInput:()=>ln,localization:()=>G,logicCss:()=>to,notShortCircuitAnd:()=>I,parseBoxShadow:()=>bi,parseColor:()=>k,parseRgbaFromString:()=>D,propertyExists:()=>v,propertyGridCss:()=>ze,registerAdorner:()=>un,removeAdorners:()=>pn,roundTo2Decimals:()=>l,saveToFileHandler:()=>F,scrollElementIntoView:()=>L,select:()=>x,setSurveyJSONForPropertyGrid:()=>ot,settings:()=>i,simulatorDevices:()=>Ie,svgBundle:()=>{},themeModelPropertyGridDefinition:()=>Ri,toggleHovered:()=>C,translationCss:()=>Lt,trimBoxShadowValue:()=>Ci,trimEmptyFields:()=>B,undoRedoTransaction:()=>Co,updateBackgroundCornerRadiusJSON:()=>di,updateFontSettingsJSON:()=>li,updateShadowEffectsJSON:()=>fi,updatecoloralphaJSON:()=>Ii,wrapTextByCurlyBraces:()=>E});var e,t={survey:{edit:"Edit",externalHelpLink:"Watch and learn how to create surveys",externalHelpLinkUrl:"https://www.youtube.com/channel/UCH2ru9okIcooNZfpIbyq4qQ?view_as=subscriber",dropQuestion:"Please drop a question here from the Toolbox.",addLogicItem:"Create a rule to customize the flow of the survey.",copy:"Copy",duplicate:"Duplicate",addToToolbox:"Add to toolbox",deletePanel:"Delete Panel",deleteQuestion:"Delete Question",convertTo:"Convert to",drag:"Drag element",license:"To use our library, a <a href='https://surveyjs.io/licensing'>developer license</a> is required. If you have an active license, <a href='https://surveyjs.io/remove-alert-banner'>set up your license key</a> and ensure you're using the latest version."},tabs:{preview:"Preview",theme:"Themes",translation:"Translations",designer:"Designer",editor:"JSON Editor",logic:"Logic"},qt:{default:"Default",checkbox:"Checkboxes",comment:"Long Text",imagepicker:"Image Picker",ranking:"Ranking",image:"Image",dropdown:"Dropdown",tagbox:"Multi-Select Dropdown",file:"File Upload",html:"HTML",matrix:"Single-Select Matrix",matrixdropdown:"Multi-Select Matrix",matrixdynamic:"Dynamic Matrix",multipletext:"Multiple Textboxes",panel:"Panel",paneldynamic:"Dynamic Panel",radiogroup:"Radio Button Group",rating:"Rating Scale",text:"Single-Line Input",boolean:"Yes/No (Boolean)",expression:"Expression (read-only)",signaturepad:"Signature",buttongroup:"Button Group"},toolboxCategories:{general:"General",choice:"Choice Questions",text:"Text Input Questions",containers:"Containers",matrix:"Matrix Questions",misc:"Misc"},ed:{defaultLocale:"Default ({0})",survey:"Survey",settings:"Settings",settingsTooltip:"Open settings",surveySettings:"Survey Settings",surveySettingsTooltip:"Survey settings",themeSettings:"Theme Settings",themeSettingsTooltip:"Theme settings",creatorSettingTitle:"Creator Settings",showPanel:"Show Panel",hidePanel:"Hide Panel",prevSelected:"Select previous",nextSelected:"Select next",prevFocus:"Focus previous",nextFocus:"Focus next",surveyTypeName:"Survey",pageTypeName:"Page",panelTypeName:"Panel",questionTypeName:"Question",columnTypeName:"Column",addNewPage:"Add New Page",moveRight:"Scroll to the Right",moveLeft:"Scroll to the Left",deletePage:"Delete Page",editPage:"Edit Page",edit:"Edit",newPageName:"page",newQuestionName:"question",newPanelName:"panel",newTextItemName:"text",defaultV2Theme:"Default",modernTheme:"Modern",defaultTheme:"Default (legacy)",testSurveyAgain:"Preview Survey Again",testSurveyWidth:"Survey width: ",navigateToMsg:"You had to navigate to",saveSurvey:"Save Survey",saveSurveyTooltip:"Save Survey",saveTheme:"Save Theme",saveThemeTooltip:"Save Theme",jsonHideErrors:"Hide errors",jsonShowErrors:"Show errors",undo:"Undo",redo:"Redo",undoTooltip:"Undo last change",redoTooltip:"Redo the change",expandAllTooltip:"Expand All",collapseAllTooltip:"Collapse All",showMoreChoices:"Show more",showLessChoices:"Show less",copy:"Copy",cut:"Cut",paste:"Paste",copyTooltip:"Copy selection to clipboard",cutTooltip:"Cut selection to clipboard",pasteTooltip:"Paste from clipboard",options:"Options",generateValidJSON:"Generate Valid JSON",generateReadableJSON:"Generate Readable JSON",toolbox:"Toolbox","property-grid":"Properties",toolboxFilteredTextPlaceholder:"Type to search...",toolboxNoResultsFound:"No results found",propertyGridFilteredTextPlaceholder:"Type to search...",propertyGridNoResultsFound:"No results found",propertyGridPlaceholderTitle:"Start configuring your form",propertyGridPlaceholderDescription:"Click any category icon to explore survey settings. Additional settings will become available once you add a survey element to the design surface.",correctJSON:"Please correct JSON.",surveyResults:"Survey Results ",surveyResultsTable:"As Table",surveyResultsJson:"As JSON",resultsTitle:"Question Title",resultsName:"Question Name",resultsValue:"Answer Value",resultsDisplayValue:"Display Value",modified:"Modified",saving:"Saving",saved:"Saved",propertyEditorError:"Error",saveError:"Error! Editor content is not saved.",translationPropertyGridTitle:"Language Settings",themePropertyGridTitle:"Theme Settings",translationLanguages:"Languages",translationDeleteLanguage:"Are you certain you wish to delete all strings for this language?",translationAddLanguage:"Select language to translate",translationShowAllStrings:"All Strings",translationShowUsedStringsOnly:"Used Strings Only",translationShowAllPages:"All Pages",translationNoStrings:"No strings to translate. Please change the filter.",translationExportToSCVButton:"Export to CSV",translationImportFromSCVButton:"Import from CSV",translateUsigAI:"Auto-translate All",translateUsigAIFrom:"Translate from: ",translationDialogTitle:"Untranslated strings",translationMergeLocaleWithDefault:"Merge {0} with default locale",translationPlaceHolder:"Translation...",translationSource:"Source: ",translationTarget:"Target: ",translationYouTubeNotSupported:"YouTube links are not supported.",themeExportButton:"Export",themeImportButton:"Import",surveyJsonExportButton:"Export",surveyJsonImportButton:"Import",surveyJsonCopyButton:"Copy to clipboard",themeResetButton:"Reset theme settings to default",themeResetConfirmation:"Do you really want to reset the theme? All your customizations will be lost.",themeResetConfirmationOk:"Yes, reset the theme",bold:"Bold",italic:"Italic",underline:"Underline",addNewQuestion:"Add Question",selectPage:"Select page...",carryForwardChoicesCopied:"Choices are copied from",choicesLoadedFromWebText:"Choices are loaded from a web service.",choicesLoadedFromWebLinkText:"Go to settings",choicesLoadedFromWebPreviewTitle:"Preview of loaded choice options",htmlPlaceHolder:"HTML content will be here.",panelPlaceHolder:"Drop a question from the toolbox here.",surveyPlaceHolder:"The survey is empty. Drag an element from the toolbox or click the button below.",pagePlaceHolder:"The page is empty. Drag an element from the toolbox or click the button below.",imagePlaceHolder:"Drag and drop an image here or click the button below and choose an image to upload",surveyPlaceHolderMobile:'Click the "Add Question" button below to start creating your form.',surveyPlaceholderTitle:"Your form is empty",surveyPlaceholderTitleMobile:"Your form is empty",surveyPlaceholderDescription:"Drag an element from the toolbox or click the button below.",surveyPlaceholderDescriptionMobile:"Drag an element from the toolbox or click the button below.",previewPlaceholderTitle:"No preview",previewPlaceholderTitleMobile:"No preview",previewPlaceholderDescription:"The survey doesn't contain any visible elements.",previewPlaceholderDescriptionMobile:"The survey doesn't contain any visible elements.",translationsPlaceholderTitle:"No strings to translate",translationsPlaceholderTitleMobile:"No strings to translate",translationsPlaceholderDescription:"Add elements to your form or change the strings filter in the toolbar.",translationsPlaceholderDescriptionMobile:"Add elements to your form or change the strings filter in the toolbar.",pagePlaceHolderMobile:'Click the "Add Question" button below to add a new element to the page.',panelPlaceHolderMobile:'Click the "Add Question" button below to add a new element to the panel.',imagePlaceHolderMobile:"Click the button below and choose an image to upload",imageChooseImage:"Choose Image",addNewTypeQuestion:"Add {0}",chooseLogoPlaceholder:"[LOGO]",choices_Item:"Item ",selectFile:"Select a file",removeFile:"Remove the file",lg:{addNewItem:"Add New Rule",empty_tab:"Create a rule to customize the flow of the survey.",logicPlaceholderTitle:"No logical rules",logicPlaceholderTitleMobile:"No logical rules",logicPlaceholderDescription:"Create a rule to customize the flow of the survey.",logicPlaceholderDescriptionMobile:"Create a rule to customize the flow of the survey.",page_visibilityName:"Show/hide page",page_enableName:"Enable/disable page",page_requireName:"Make page required",panel_visibilityName:"Show/hide panel",panel_enableName:"Enable/disable panel",panel_requireName:"Make panel required",question_visibilityName:"Show/hide question",question_enableName:"Enable/disable question",question_requireName:"Make question required",question_resetValueName:"Reset question value",question_setValueName:"Set question value",column_visibilityName:"Show/hide column",column_enableName:"Enable/disable column",column_requireName:"Make column required",column_resetValueName:"Reset column value",column_setValueName:"Set column value",trigger_completeName:"Complete survey",trigger_setvalueName:"Set answer",trigger_copyvalueName:"Copy answer",trigger_skipName:"Skip to question",trigger_runExpressionName:"Run expression",completedHtmlOnConditionName:'Set "Thank You" page markup',page_visibilityDescription:"Make the page visible when the logical expression evaluates to true. Otherwise, keep the page invisible.",panel_visibilityDescription:"Make the page visible when the logical expression evaluates to true. Otherwise, keep the panel invisible.",panel_enableDescription:"Make the panel and all elements inside it enabled when the logical expression evaluates to true. Otherwise, keep them disabled.",question_visibilityDescription:"Make the question visible when the logical expression evaluates to true. Otherwise, keep the question invisible.",question_enableDescription:"Make the question enabled when the logical expression evaluates to true. Otherwise, keep the question disabled.",question_requireDescription:"Question becomes required when the logical expression evaluates to true.",trigger_completeDescription:'When the logical expression evaluates to true, the survey ends, and the respondent sees the "Thank you" page.',trigger_setvalueDescription:"When question values used in the logical expression are changed, and the expression evaluates to true, the specified value is assigned to the selected question.",trigger_copyvalueDescription:"When question values used in the logical expression are changed, and the expression evaluates to true, the value of the selected question is copied to another question.",trigger_skipDescription:"When the logical expression evaluates to true, the survey focuses/jumps to the selected question.",trigger_runExpressionDescription:"When the logical expression evaluates to true, the survey evaluates another expression. Optionally, the result of the latter expression can be assigned as a value to the selected question",completedHtmlOnConditionDescription:'If the logical expression evaluates to true, the "Thank You" page displays the specified content.',itemExpressionText:"When expression: '{0}' returns true",itemEmptyExpressionText:"New rule",page_visibilityText:"make page {0} visible",panel_visibilityText:"make panel {0} visible",panel_enableText:"make panel {0} enable",question_visibilityText:"make question {0} visible",question_enableText:"make question {0} enable",question_requireText:"make question {0} required",question_resetValueText:"reset value for question: {0}",question_setValueText:"assign value: {1} to question: {0}",column_visibilityText:"make column {0} of question {1} visible",column_enableText:"make column {0} of question {1} enable",column_requireText:"make column {0} of question {1} required",column_resetValueText:"reset cell value for column: {0}",column_setValueText:"assign cell value: {1} to column: {0}",setValueExpressionPlaceholder:"An expression whose result will be assigned to the target question.",trigger_completeText:"survey becomes completed",trigger_setvalueText:"set into question: {0} value {1}",trigger_setvalueEmptyText:"clear question value: {0}",trigger_copyvalueText:"copy into question: {0} value from question {1}",trigger_skipText:"survey skip to the question {0}",trigger_runExpressionText1:"run expression: '{0}'",trigger_runExpressionText2:" and set its result into question: {0}",completedHtmlOnConditionText:'show custom text for the "Thank You" page.',showAllQuestions:"All Questions",showAllActionTypes:"All Action Types",conditions:"Condition(s)",actions:"Action(s)",expressionEditorTitle:"Define condition(s)",actionsEditorTitle:"Define action(s)",deleteAction:"Delete Action",addNewAction:"Add Action",selectedActionCaption:"Select action...",expressionInvalid:"The logic expression is empty or invalid. Please correct it.",noActionError:"Please add at least one action.",actionInvalid:"Please fix issues in your action(s).",uncompletedRule_title:"Logical rules are incomplete",uncompletedRule_text:"You have not completed some of the logical rules. If you leave the tab now, the changes will be lost. Do you still want to leave the tab without completing the changes?",uncompletedRule_apply:"Yes",uncompletedRule_cancel:"No, I want to complete the rules"}},pe:{panel:{name:"Panel name",title:"Panel title",description:"Panel description",visibleIf:"Make the panel visible if",requiredIf:"Make the panel required if",questionsOrder:"Question order within the panel",page:"Move the panel to page",startWithNewLine:"Display the panel on a new line",state:"Panel collapse state",width:"Inline panel width",minWidth:"Minimum panel width",maxWidth:"Maximum panel width",showNumber:"Number panels"},paneldynamic:{name:"Panel name",title:"Panel title",description:"Panel description",visibleIf:"Make the panel visible if",requiredIf:"Make the panel required if",page:"Move the panel to page",startWithNewLine:"Display the panel on a new line",state:"Panel collapse state",width:"Inline panel width",minWidth:"Minimum panel width",maxWidth:"Maximum panel width",confirmDelete:"Confirm panel deletion",templateDescription:"Panel description pattern",templateTitle:"Panel title pattern",noEntriesText:"Empty panel text",templateTabTitle:"Tab title pattern",tabTitlePlaceholder:"Tab title placeholder",templateVisibleIf:"Make an individual panel visible if",hideNumber:"Hide the panel number",titleLocation:"Panel title alignment",descriptionLocation:"Panel description alignment",templateTitleLocation:"Question title alignment",templateErrorLocation:"Error message alignment",newPanelPosition:"New panel location",showRangeInProgress:"Show the progress bar",showProgressBar:"Show the progress bar",progressBarLocation:"Progress bar alignment",keyName:"Prevent duplicate responses in the following question"},question:{name:"Question name",title:"Question title",description:"Question description",visibleIf:"Make the question visible if",requiredIf:"Make the question required if",page:"Move the question to page",state:"Question box collapse state",hideNumber:"Hide the question number",titleLocation:"Question title alignment",descriptionLocation:"Question description alignment",errorLocation:"Error message alignment",indent:"Increase the inner indent",width:"Inline question width",minWidth:"Minimum question width",maxWidth:"Maximum question width",textUpdateMode:"Update input field value"},signaturepad:{signatureWidth:"Signature area width",signatureHeight:"Signature area height",signatureAutoScaleEnabled:"Auto-scale the signature area",showPlaceholder:"Show a placeholder within signature area",placeholder:"Placeholder text",placeholderReadOnly:"Placeholder text in read-only or preview mode",allowClear:"Show the Clear button within signature area",penMinWidth:"Minimum stroke width",penMaxWidth:"Maximum stroke width",penColor:"Stroke color"},comment:{rows:"Input field height (in lines)"},showQuestionNumbers:"Question numbering",questionStartIndex:"Question indexing type",expression:{name:"Expression name",title:"Expression title",description:"Expression description",expression:"Expression"},trigger:{expression:"Expression"},calculatedvalue:{expression:"Expression"},survey:{title:"Survey title",description:"Survey description"},page:{name:"Page name",title:"Page title",description:"Page description",visibleIf:"Make the page visible if",requiredIf:"Make the page required if",timeLimit:"Time limit to complete the page",questionsOrder:"Question order on the page"},matrixdropdowncolumn:{name:"Column name",title:"Column title",isUnique:"Prevent duplicate responses",width:"Column width",minWidth:"Minimum column width",rows:"Input field height (in lines)",visibleIf:"Make the column visible if",requiredIf:"Make the column required if",showInMultipleColumns:"Each option in a separate column"},multipletextitem:{name:"Name",title:"Title"},masksettings:{saveMaskedValue:"Save masked value in survey results"},patternmask:{pattern:"Value pattern"},datetimemask:{min:"Minimum value",max:"Maximum value"},numericmask:{allowNegativeValues:"Allow negative values",thousandsSeparator:"Thousands separator",decimalSeparator:"Decimal separator",precision:"Value precision",min:"Minimum value",max:"Maximum value"},currencymask:{prefix:"Currency prefix",suffix:"Currency suffix"},imageHeight:"Display area height",imageWidth:"Display area width",valueName:"Join identifier",rateDescriptionLocation:"Label alignment",size:"Input field width (in characters)",cellErrorLocation:"Cell error message alignment",enabled:"Enabled",disabled:"Disabled",inherit:"Inherit",apply:"Apply",ok:"OK",save:"Save",clear:"Clear",saveTooltip:"Save",cancel:"Cancel",set:"Set",reset:"Reset",change:"Change",refresh:"Refresh",close:"Close",delete:"Delete",add:"Add",addNew:"Add New",addItem:"Click to add an item...",removeItem:"Click to remove the item...",dragItem:"Drag the item",addOther:"Other",addSelectAll:"Select All",addNone:"None",removeAll:"Remove All",edit:"Edit",back:"Return without saving",backTooltip:"Return without saving",saveAndBack:"Save and return",saveAndBackTooltip:"Save and return",doneEditing:"Done",editChoices:"Edit Choices",showChoices:"Show Choices",move:"Move",empty:"<empty>",emptyValue:"Value is empty",fastEntry:"Manual Entry",fastEntryNonUniqueError:"Value '{0}' is not unique",fastEntryChoicesCountError:"Please limit the number of items from {0} to {1}",fastEntryChoicesMinCountError:"Please enter at least {0} items",fastEntryPlaceholder:"Enter the list of choice options and their IDs in the following format:\n\nid|option\n\nA choice option ID is not visible to respondents and can be used in conditional rules.",formEntry:"Form Entry",testService:"Test the service",itemSelectorEmpty:"Please select the element",conditionActionEmpty:"Please select the action",conditionSelectQuestion:"Select a question...",conditionSelectPage:"Select a page...",conditionSelectPanel:"Select a panel...",conditionValueQuestionTitle:"Please enter/select the value",aceEditorHelp:"Press ctrl+space to get expression completion hint",aceEditorRowTitle:"Current row",aceEditorPanelTitle:"Current panel",showMore:"For more details please check the documentation",assistantTitle:"Available questions",cellsEmptyRowsColumns:"There is should be at least one column or row",showPreviewBeforeComplete:"Review before submit",overridingPropertyPrefix:"Enabled by a condition",resetToDefaultCaption:"Reset",propertyIsEmpty:"Please enter a value",propertyIsNoUnique:"Please enter a unique value",propertyNameIsNotUnique:"Please enter a unique name",propertyNameIsIncorrect:'Do not use reserved words: "item", "choice", "panel", "row".',listIsEmpty:"You don't have any items yet","listIsEmpty@choices":"You don't have any choices yet","listIsEmpty@columns":"You don't have any columns yet","listIsEmpty@rows":"You don't have any rows yet","listIsEmpty@validators":"You don't have any validation rules yet","listIsEmpty@calculatedValues":"You don't have any custom variables yet","listIsEmpty@triggers":"You don't have any triggers yet","listIsEmpty@navigateToUrlOnCondition":"You don't have any links yet","addNew@choices":"Add new choice","addNew@columns":"Add new column","addNew@rows":"Add new row","addNew@validators":"Add new rule","addNew@calculatedValues":"Add new variable","addNew@triggers":"Add new trigger","addNew@navigateToUrlOnCondition":"Add new URL",expressionIsEmpty:"Expression is empty",value:"Value",text:"Text",rowid:"Row ID",imageLink:"Image or video file URL",columnEdit:"Edit column: {0}",itemEdit:"Edit item: {0}",url:"URL",path:"Path to data",choicesbyurl:{url:"Web service URL",valueName:"Get value to store from the following property"},titleName:"Get value to display from the following property",imageLinkName:"Get file URLs from the following property",allowEmptyResponse:"Accept empty response",titlePlaceholder:"Title",surveyTitlePlaceholder:"Survey Title",pageTitlePlaceholder:"Page {num}",descriptionPlaceholder:"Description",surveyDescriptionPlaceholder:"Description",pageDescriptionPlaceholder:"Description",textWrapEnabled:"Wrap choices",showOtherItem:'Enable the "Other" option',otherText:'Rename the "Other" option',showNoneItem:'Enable the "None" option',showRefuseItem:'Enable the "Refuse to Answer" option',showDontKnowItem:'Enable the "Don\'t Know" option',noneText:'Rename the "None" option',showSelectAllItem:'Enable the "Select All" option',selectAllText:'Rename the "Select All" option',choicesMin:"Minimum value for auto-generated items",choicesMax:"Maximum value for auto-generated items",choicesStep:"Step value for auto-generated items",name:"Name",title:"Title",cellType:"Cell input type",colCount:"Column count",choicesOrder:"Choice order",visible:"Visible",isRequired:"Required",markRequired:"Mark as required",removeRequiredMark:"Remove the required mark",isAllRowRequired:"Require an answer in each row",eachRowUnique:"Prevent duplicate responses in rows",requiredErrorText:"Error message for required questions",startWithNewLine:"Display the question on a new line",rows:"Rows",cols:"Columns",placeholder:"Placeholder text within input field",showPreview:"Show preview area",storeDataAsText:"Store file content in JSON result as text",maxSize:"Maximum file size (in bytes)",rowCount:"Row count",columnLayout:"Columns layout",addRowLocation:'"Add Row" button alignment',transposeData:"Transpose rows to columns",addRowText:'"Add Row" button text',removeRowText:'"Remove Row" button text',rateMin:"Minimum rating value",rateMax:"Maximum rating value",rateStep:"Step value",minRateDescription:"Minimum value label",maxRateDescription:"Maximum value label",inputType:"Input type",optionsCaption:"Option placeholder",defaultValue:"Default Answer",cellsDefaultRow:"Default texts",surveyEditorTitle:"Edit survey settings",qEditorTitle:"Edit: {0}",maxLength:"Maximum character limit",buildExpression:"Build",editExpression:"Edit",and:"and",or:"or",remove:"Remove",addCondition:"Add Condition",emptyLogicPopupMessage:"Select a question to start configuring conditions.",if:"If",then:"then",setToName:"Target question",fromName:"Question to copy answer from",gotoName:"Question to skip to",ruleIsNotSet:"Rule is incorrect",includeIntoResult:"Add to the survey results",showTitle:"Make the title and description visible",expandCollapseTitle:"Expand/collapse title",locale:"Select a survey language",simulator:"Select device type",landscapeOrientation:"Switch to landscape orientation",portraitOrientation:"Switch to portrait orientation",mode:"Survey display mode",clearInvisibleValues:"Clear hidden question values",cookieName:"Limit to one response",sendResultOnPageNext:"Auto-save survey progress on page change",storeOthersAsComment:'Save the "Other" option value as a separate property',showPageTitles:"Show page titles",showPageNumbers:"Show page numbers",pagePrevText:'"Previous Page" button text',pageNextText:'"Next Page" button text',completeText:'"Complete Survey" button text',previewText:'"Review Answers" button text',editText:'"Edit Answer" button text',startSurveyText:'"Start Survey" button text',showNavigationButtons:"Show/hide navigation buttons",showPrevButton:'Show the "Previous Page" button',firstPageIsStarted:"First page is a start page",showCompletedPage:'Show the "Thank You" page',goNextPageAutomatic:"Auto-advance to the next page",allowCompleteSurveyAutomatic:"Complete the survey automatically",showProgressBar:"Progress bar alignment",questionTitleLocation:"Question title alignment",questionTitleWidth:"Question title width",requiredText:"Required symbol(s)",questionTitleTemplate:"Question title template, default is: '{no}. {require} {title}'",questionErrorLocation:"Error message alignment",focusFirstQuestionAutomatic:"Focus first question on a new page",questionsOrder:"Question order",timeLimit:"Time limit to complete the survey",timeLimitPerPage:"Time limit to complete one page",showTimer:"Use a timer",timerLocation:"Timer alignment",timerInfoMode:"Timer mode",renderMode:"Panel display mode",allowAddPanel:"Enable panel addition",allowRemovePanel:"Enable panel removal",panelAddText:'"Add Panel" button text',panelRemoveText:'"Remove Panel" button text',isSinglePage:"Show all elements on one page",html:"HTML markup",setValue:"Answer",dataFormat:"Storage format",allowAddRows:"Enable row addition",allowRemoveRows:"Enable row removal",allowRowsDragAndDrop:"Enable row reordering",responsiveImageSizeHelp:"Does not apply if you specify the exact display area width or height.",minImageWidth:"Minimum display area width",maxImageWidth:"Maximum display area width",minImageHeight:"Minimum display area height",maxImageHeight:"Maximum display area height",minValue:"Minimum value",maxValue:"Maximum value",caseInsensitive:"Case insensitive",minLength:"Minimum length (in characters)",allowDigits:"Allow digits",minCount:"Minimum count",maxCount:"Maximum count",regex:"Regular expression",surveyvalidator:{text:"Error message",expression:"Validation expression"},totalText:"Total row header",totalType:"Aggregation method",totalExpression:"Total value expression",totalDisplayStyle:"Total value display format",totalCurrency:"Currency",totalFormat:"Formatted string",logo:"Survey logo",questionsOnPageMode:"Survey layout",maxTextLength:"Restrict answer length",maxOthersLength:"Restrict comment length",commentAreaRows:"Comment area height (in lines)",autoGrowComment:"Auto-expand text areas",allowResizeComment:"Allow users to resize text areas",textUpdateMode:"Update input field values",maskType:"Input mask type",focusOnFirstError:"Set focus on the first invalid answer",checkErrorsMode:"Run validation",validateVisitedEmptyFields:"Validate empty fields on lost focus",navigateToUrl:"Redirect to an external link after submission",navigateToUrlOnCondition:"Dynamic external link",completedBeforeHtml:"Markup to show if the user already filled out this survey",completedHtml:'"Thank You" page markup',completedHtmlOnCondition:'Dynamic "Thank You" page markup',loadingHtml:"Markup to show while survey model is loading",commentText:"Comment area text",autocomplete:"Autocomplete type",labelTrue:'Label for "True"',labelFalse:'Label for "False"',allowClear:"Show the Clear button",searchMode:"Search Mode",displayStyle:"Display format",format:"Formatted string",maximumFractionDigits:"Maximum fractional digits",minimumFractionDigits:"Minimum fractional digits",useGrouping:"Display grouping separators",allowMultiple:"Enable multiple file upload",allowImagesPreview:"Preview uploaded images",acceptedTypes:"Accepted file types",waitForUpload:"Wait for upload to complete",needConfirmRemoveFile:"Confirm file deletion",detailPanelMode:"Row expansion alignment",minRowCount:"Minimum row count",maxRowCount:"Maximum row count",confirmDelete:"Confirm row deletion",confirmDeleteText:"Confirmation message",panelCount:"Initial panel count",minPanelCount:"Minimum panel count",maxPanelCount:"Maximum panel count",panelsState:"Inner panel collapse state",panelPrevText:'"Previous Panel" button text',panelNextText:'"Next Panel" button text',panelRemoveButtonLocation:'"Remove Panel" button alignment',hideIfRowsEmpty:"Hide the question if it has no rows",hideColumnsIfEmpty:"Hide columns if there are no rows",rateValues:"Custom rating values",rateCount:"Rating count",autoGenerate:"Rating configuration",hideIfChoicesEmpty:"Hide the question if it has no choices",minWidth:"Minimum width",maxWidth:"Maximum width",width:"Width",showHeader:"Show column headers",horizontalScroll:"Show horizontal scrollbar",columnMinWidth:"Minimum column width",rowTitleWidth:"Row header width",valueTrue:'Value to store when "True" is selected',valueFalse:'Value to store when "False" is selected',minErrorText:'"Value is below minimum" error message',maxErrorText:'"Value exceeds maximum" error message',otherErrorText:'"Empty comment" error message',keyDuplicationError:"Error message for duplicate responses",minSelectedChoices:"Minimum choices to select",maxSelectedChoices:"Maximum choices to select",showClearButton:"Show the Clear button",logoWidth:"Logo width",logoHeight:"Logo height",readOnly:"Read-only",enableIf:"Disable the read-only mode if",emptyRowsText:'"No rows" message',separateSpecialChoices:"Separate special choices",choicesFromQuestion:"Copy choices from the following question",choicesFromQuestionMode:"Which choice options to copy",progressBarShowPageTitles:"Display page titles in progress bar",progressBarShowPageNumbers:"Display page numbers in progress bar",showCommentArea:"Add a comment box",commentPlaceholder:"Placeholder text for the comment box",displayRateDescriptionsAsExtremeItems:"Show the labels as extreme values",rowsOrder:"Row order",columnsLayout:"Column layout",columnColCount:"Nested column count",correctAnswer:"Correct Answer",defaultPanelValue:"Default Values",cells:"Cell Texts",fileInputPlaceholder:"Select a file or paste a file link...",keyName:"Prevent duplicate responses in the following column",itemvalue:{visibleIf:"Make the option visible if",enableIf:"Make the option selectable if"},"itemvalue@rows":{visibleIf:"Make the row visible if",enableIf:"Make the row editable if"},imageitemvalue:{text:"Alt text"},logoPosition:"Logo alignment",addLogo:"Add logo...",changeLogo:"Change logo...",logoPositions:{none:"Remove logo",left:"Left",right:"Right",top:"On the top",bottom:"In the bottom"},tabs:{panel:{layout:"Panel Layout"},general:"General",fileOptions:"Options",html:"HTML Editor",columns:"Columns",rows:"Rows",choices:"Choice Options",items:"Items",visibleIf:"Visible If",enableIf:"Editable If",requiredIf:"Required If",rateValues:"Rating Values",choicesByUrl:"Choices from a Web Service",matrixChoices:"Default Choices",multipleTextItems:"Text Inputs",numbering:"Numbering",validators:"Validators",navigation:"Navigation",question:"Question Settings",pages:"Pages",timer:"Quiz Mode",calculatedValues:"Calculated Values",triggers:"Triggers",templateTitle:"Title template",totals:"Totals",logic:"Conditions",mask:"Input Mask Settings",layout:{panel:"Panel Layout",question:"Layout",base:"Layout"},data:"Data",validation:"Validation",cells:"Individual Cell Texts",showOnCompleted:'"Thank You" Page',logo:"Logo in the Survey Header",slider:"Slider",expression:"Expression",questionSettings:"Question Settings",header:"Header",background:"Background",appearance:"Appearance",others:"Others"},editProperty:"Edit property '{0}'",items:"Items",choicesVisibleIf:"Make choices visible if",choicesEnableIf:"Make choices selectable if",columnsEnableIf:"Make columns visible if",rowsEnableIf:"Make rows visible if",innerIndent:"Increase the inner indent",defaultValueFromLastRow:"Use answers from the last row as default",defaultValueFromLastPanel:"Use answers from the last panel as default",enterNewValue:"Please enter a value.",noquestions:"There are no questions in the survey.",createtrigger:"Please create a trigger",titleKeyboardAdornerTip:"Press enter button to edit",keyboardAdornerTip:"Press enter button to edit item, press delete button to delete item, press alt plus arrow up or arrow down to move item",triggerOn:"On ",triggerMakePagesVisible:"Make pages visible",triggerMakeQuestionsVisible:"Make elements visible",triggerCompleteText:"Complete the survey if successful.",triggerNotSet:"The trigger is not set",triggerRunIf:"Run if",triggerSetToName:"Change value of: ",triggerFromName:"Copy value from: ",triggerRunExpression:"Run this Expression",triggerSetValue:"to: ",triggerGotoName:"Go to the question",triggerIsVariable:"Do not put the variable into the survey result.",triggerRunExpressionEmpty:"Please enter a valid expression",emptyExpressionPlaceHolder:"Type expression here...",noFile:"No file chosen",clearIfInvisible:"Clear hidden question values",valuePropertyName:"Store values in the following property",searchEnabled:"Enable search-as-you-type",hideSelectedItems:"Hide selected items",closeOnSelect:"Collapse the dropdown upon selection",verticalAlign:"Vertical alignment within cells",alternateRows:"Alternate row colors",columnsVisibleIf:"Make columns visible if",rowsVisibleIf:"Make rows visible if",otherPlaceholder:"Placeholder text for the comment box",filePlaceholder:"Placeholder text for Local file",photoPlaceholder:"Placeholder text for Camera",fileOrPhotoPlaceholder:"Placeholder text for Local file or Camera",rateType:"Rating icon",url_placeholder:"Ex.: https://api.example.com/books",path_placeholder:"Ex.: categories.fiction",questionStartIndex_placeholder:"Ex.: a)",width_placeholder:"Ex.: 6in",minWidth_placeholder:"Ex.: 600px",maxWidth_placeholder:"Ex.: 50%",imageHeight_placeholder:"auto",imageWidth_placeholder:"auto",theme:{themeName:"Theme",isPanelless:"Question appearance",editorPanel:"Background and corner radius",questionPanel:"Background and corner radius",primaryColor:"Accent color",panelBackgroundTransparency:"Panel and question box opacity",questionBackgroundTransparency:"Input element opacity",fontSize:"Survey font size",scale:"Survey scale factor",cornerRadius:"Corner radius",advancedMode:"Advanced mode",pageTitle:"Title font",pageDescription:"Description font",questionTitle:"Title font",questionDescription:"Description font",editorFont:"Font",backgroundOpacity:"Opacity","--sjs-font-family":"Survey font family","--sjs-general-backcolor-dim":"Background color","--sjs-primary-backcolor":"Accent background colors","--sjs-primary-forecolor":"Accent foreground colors","--sjs-special-red":"Error message colors","--sjs-shadow-small":"Shadow effects","--sjs-shadow-inner":"Shadow effects","--sjs-border-default":"Colors"},"header@header":{headerView:"View",logoPosition:"Logo alignment",surveyTitle:"Survey title font",surveyDescription:"Survey description font",headerTitle:"Survey title font",headerDescription:"Survey description font",inheritWidthFrom:"Content area width",textAreaWidth:"Text width",backgroundColorSwitch:"Background color",backgroundImage:"Background image",backgroundImageOpacity:"Opacity",overlapEnabled:"Overlap",logoPositionX:"Logo alignment",titlePositionX:"Survey title alignment",descriptionPositionX:"Survey description alignment"}},pv:{true:"true",false:"false",file:"Local file",camera:"Camera","file-camera":"Local file or Camera",inherit:"Inherit",show:"Visible",hide:"Hidden",default:"Inherit",initial:"Initial",random:"Random",collapsed:"Collapsed",expanded:"Expanded",none:"None",asc:"Ascending",desc:"Descending",indeterminate:"Indeterminate",selected:"Selected",unselected:"Unselected",decimal:"decimal",currency:"currency",percent:"percent",firstExpanded:"First panel is expanded",off:"Hide question numbers",list:"List",carousel:"Carousel",tab:"Tabs",progressTop:"Panel navigator + Progress bar at the top",progressBottom:"Panel navigator + Progress bar at the bottom",progressTopBottom:"Panel navigator + Progress bar at the top and bottom",horizontal:"Horizontal",vertical:"Vertical",top:"Top",bottom:"Bottom",topBottom:"Top and bottom",both:"Both",left:"Left",right:"Right",center:"Center",leftRight:"Left and right",middle:"Middle",color:"color",date:"date",datetime:"datetime","datetime-local":"datetime-local",email:"email",month:"month",number:"number",password:"password",range:"range",tel:"tel",text:"text",time:"time",url:"url",week:"week",hidden:"Hidden",edit:"Editable",display:"Read-only",contain:"Contain",cover:"Cover",fill:"Fill",next:"Next",last:"Last",onComplete:"Upon survey completion",onHidden:"When question gets hidden",onHiddenContainer:"When question or its panel/page gets hidden",clearInvisibleValues:{none:"Never"},clearIfInvisible:{none:"Never"},inputType:{color:"Color",date:"Date","datetime-local":"Date and Time",email:"Email",month:"Month",number:"Number",password:"Password",range:"Range",tel:"Phone Number",text:"Text",time:"Time",url:"URL",week:"Week"},maskType:{none:"None",pattern:"Pattern",numeric:"Numeric",datetime:"Date and Time",currency:"Currency"},inputTextAlignment:{auto:"Auto",left:"Left",right:"Right"},all:"All",page:"Page",survey:"Survey",onNextPage:"When switching to the next page",onValueChanged:"After an answer is changed",onValueChanging:"Before an answer is changed",questionsOnPageMode:{standard:"Original structure",singlePage:"Show all questions on one page",questionPerPage:"Show single question per page"},noPreview:"No preview",showAllQuestions:"Show all questions",showAnsweredQuestions:"Show answered questions only",pages:"Completed pages",questions:"Answered questions",requiredQuestions:"Answered required questions",correctQuestions:"Valid answers",buttons:"Completed pages (button UI)",underInput:"Under the input field",underTitle:"Under the question title",onBlur:"On lost focus",onTyping:"While typing",underRow:"Under the row",underRowSingle:"Under the row, display one row expansion only",auto:"Auto",showNavigationButtons:{none:"Hidden"},timerInfoMode:{combined:"Both"},addRowLocation:{default:"Based on matrix layout"},panelsState:{default:"Locked",collapsed:"Collapse all",expanded:"Expand all",firstExpanded:"First expanded"},widthMode:{static:"Static",responsive:"Responsive"},contentMode:{image:"Image",video:"Video",youtube:"YouTube"},displayMode:{buttons:"Buttons",dropdown:"Dropdown"},rateColorMode:{default:"Default",scale:"Scale"},scaleColorMode:{monochrome:"Monochrome",colored:"Colored"},autoGenerate:{true:"Auto-generate",false:"Manual"},rateType:{labels:"Labels",stars:"Stars",smileys:"Smileys"},state:{default:"Locked"},showQuestionNumbers:{default:"Auto-numbering",on:"Auto-numbering",onPage:"Reset on each page",onpanel:"Reset on each panel",onPanel:"Reset on each panel",onSurvey:"Continue across the survey",off:"No numbering"},descriptionLocation:{underTitle:"Under the question title",underInput:"Under the input field"},selectToRankAreasLayout:{horizontal:"Next to choices",vertical:"Above choices"},displayStyle:{decimal:"Decimal",currency:"Currency",percent:"Percentage",date:"Date"},totalDisplayStyle:{decimal:"Decimal",currency:"Currency",percent:"Percentage",date:"Date"},rowsOrder:{initial:"Original"},questionsOrder:{initial:"Original"},showProgressBar:{off:"Hidden",topbottom:"Top and bottom",aboveheader:"Above the header",belowheader:"Below the header"},progressBarLocation:{top:"Top",bottom:"Bottom",topBottom:"Top and bottom"},sum:"Sum",count:"Count",min:"Min",max:"Max",avg:"Avg",searchMode:{contains:"Contains",startsWith:"Starts with"},backgroundImageFit:{auto:"Auto",cover:"Cover",contain:"Contain",fill:"Stretch",tile:"Tile"},backgroundImageAttachment:{fixed:"Fixed",scroll:"Scroll"},headerView:{basic:"Basic",advanced:"Advanced"},inheritWidthFrom:{survey:"Same as survey",container:"Same as container"},backgroundColorSwitch:{none:"None",accentColor:"Accent color",custom:"Custom"},colorPalette:{light:"Light",dark:"Dark"},isPanelless:{false:"Default",true:"Without Panels"},progressBarInheritWidthFrom:{survey:"Same as survey",container:"Same as container"}},op:{empty:"Empty",notempty:"Not empty",equal:"Equals",notequal:"Does not equal",contains:"Contains",notcontains:"Does not contain",anyof:"Any of",allof:"All of",greater:"Greater than",less:"Less than",greaterorequal:"Greater than or equal to",lessorequal:"Less than or equal to",and:"and",or:"or"},ew:{angular:"Use Angular version",jquery:"Use jQuery version",knockout:"Use Knockout version",react:"Use React version",vue:"Use Vue version",bootstrap:"For bootstrap framework",modern:"Modern theme",default:"Default theme",orange:"Orange theme",darkblue:"Darkblue theme",darkrose:"Darkrose theme",stone:"Stone theme",winter:"Winter theme",winterstone:"Winter-Stone theme",showOnPage:"Show survey on a page",showInWindow:"Show survey in a window",loadFromServer:"Load Survey JSON from server",titleScript:"Scripts and styles",titleHtml:"HTML",titleJavaScript:"JavaScript"},ts:{selectPage:"Select the page to test it",showInvisibleElements:"Show invisible elements",hideInvisibleElements:"Hide invisible elements"},validators:{answercountvalidator:"Answer count",emailvalidator:"Email",expressionvalidator:"Expression",numericvalidator:"Number",regexvalidator:"Regex",textvalidator:"Text"},triggers:{completetrigger:"Complete survey",setvaluetrigger:"Set answer",copyvaluetrigger:"Copy answer",skiptrigger:"Skip to question",runexpressiontrigger:"Run expression",visibletrigger:"change visibility (deprecated)"},peplaceholder:{patternmask:{pattern:"Ex.: +1(999)-999-99-99"},datetimemask:{pattern:"Ex.: mm/dd/yyyy HH:MM:ss"},currencymask:{prefix:"Ex.: $",suffix:"Ex.: USD"},panelbase:{questionTitleWidth:"Ex.: 200px"},panellayoutcolumn:{effectiveWidth:"Ex.: 30%",questionTitleWidth:"Ex.: 200px"}},pehelp:{panel:{name:"A panel ID that is not visible to respondents.",description:"Type a panel subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines panel visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the panel.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",questionTitleLocation:'Applies to all questions within this panel. When set to "Hidden", it also hides question descriptions. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default). ',questionTitleWidth:"Sets consistent width for question titles when they are aligned to the left of their question boxes. Accepts CSS values (px, %, in, pt, etc.).",questionErrorLocation:'Sets the location of an error message in relation to all questions within the panel. The "Inherit" option applies the page-level (if set) or survey-level setting.',questionsOrder:'Keeps the original order of questions or randomizes them. The "Inherit" option applies the page-level (if set) or survey-level setting.',page:"Repositions the panel to the end of a selected page.",innerIndent:"Adds space or margin between the panel content and the left border of the panel box.",startWithNewLine:"Unselect to display the panel in one line with the previous question or panel. The setting doesn't apply if the panel is the first element in your form.",state:'Choose from: "Expanded" - the panel is displayed in full and can be collapsed; "Collapsed" - the panel displays only the title and description and can be expanded; "Locked" - the panel is displayed in full and cannot be collapsed.',width:"Sets the width of the panel in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.)."},paneldynamic:{name:"A panel ID that is not visible to respondents.",description:"Type a panel subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines panel visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the panel.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",templateTitleLocation:'Applies to all questions within this panel. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',templateErrorLocation:'Sets the location of an error message in relation to a question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',errorLocation:'Sets the location of an error message in relation to all questions within the panel. The "Inherit" option applies the page-level (if set) or survey-level setting.',page:"Repositions the panel to the end of a selected page.",innerIndent:"Adds space or margin between the panel content and the left border of the panel box.",startWithNewLine:"Unselect to display the panel in one line with the previous question or panel. The setting doesn't apply if the panel is the first element in your form.",state:'Choose from: "Expanded" - the panel is displayed in full and can be collapsed; "Collapsed" - the panel displays only the title and description and can be expanded; "Locked" - the panel is displayed in full and cannot be collapsed.',width:"Sets the width of the panel in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.).",templateTitle:"Type in a template for dynamic panel titles. Use {panelIndex} for the panel's general position and {visiblePanelIndex} for its order among visible panels. Insert these placeholders into the pattern to add automatic numbering.",templateTabTitle:"Type in a template for tab titles. Use {panelIndex} for a panel's general position and {visiblePanelIndex} for its order among visible panels. Insert these placeholders into the pattern to add automatic numbering.",tabTitlePlaceholder:"A fallback text for tab titles that applies when the tab title pattern doesn't produce a meaningful value.",templateVisibleIf:"This setting allows you to control the visibility of individual panels within the dynamic panel. Use the `{panel}` placeholder to reference the current panel in your expression.",titleLocation:'This setting is automatically inherited by all questions within this panel. If you want to override this setting, define title alignment rules for individual questions. The "Inherit" option applies the page-level (if set) or survey-level setting ("Top" by default).',descriptionLocation:'The "Inherit" option applies the page-level (if set) or survey-level setting ("Under the panel title" by default).',newPanelPosition:'Defines the position of a newly added panel. By default, new panels are added to the end. Select "Next" to insert a new panel after the current one.',defaultValueFromLastPanel:"Duplicates answers from the last panel and assigns them to the next added dynamic panel.",keyName:"Reference a question name to require a user to provide a unique response for this question in each panel."},defaultValueExpression:"This setting allows you to assign a default answer value based on an expression. The expression can include basic calculations - `{q1_id} + {q2_id}`, Boolean expressions, such as `{age} > 60`, and functions: `iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc. The value determined by this expression serves as the initial default value that can be overridden by a respondent's manual input.",resetValueIf:'Use the magic wand icon to set a conditional rule that determines when a respondent\'s input is reset to the value based on the "Default value expression" or "Set value expression" or to the "Default answer" value (if either is set).',setValueIf:'Use the magic wand icon to set a conditional rule that determines when to run the "Set value expression" and dynamically assign the resulting value as a response.',setValueExpression:'Specify an expression that defines the value to be set when the conditions in the "Set value if" rule are met. The expression can include basic calculations - `{q1_id} + {q2_id}`, Boolean expressions, such as `{age} > 60`, and functions: `iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc. The value determined by this expression can be overridden by a respondent\'s manual input.',question:{name:"A question ID that is not visible to respondents.",description:"Type a question subtitle.",visibleIf:"Use the magic wand icon to set a conditional rule that determines question visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the question.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey advancing or submission unless the question received an answer.",startWithNewLine:"Unselect to display the question in one line with the previous question or panel. The setting doesn't apply if the question is the first element in your form.",page:"Repositions the question to the end of a selected page.",state:'Choose from: "Expanded" - the question box is displayed in full and can be collapsed; "Collapsed" - the question box displays only the title and description and can be expanded; "Locked" - the question box is displayed in full and cannot be collapsed.',titleLocation:'Overrides title alignment rules defined on a panel, page, or survey level. When set to "Hidden", it also hides question descriptions. The "Inherit" option applies any higher-level settings (if set) or survey-level setting ("Top" by default).',descriptionLocation:'The "Inherit" option applies the survey-level setting ("Under the question title" by default).',errorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the survey-level setting ("Top" by default).',indent:"Adds space or margin between the question content and the left border of the question box.",width:"Sets the width of the question in proportion to other survey elements in the same line. Accepts CSS values (px, %, in, pt, etc.).",surveyvalidator:{expression:"Use the magic wand icon to set a validation rule for the question."},textUpdateMode:'Choose from: "On lost focus" - the value is updated when the input field loses focus; "While typing" - the value is updated in real-time, as users are typing. The "Inherit" option applies the survey-level setting ("On lost focus" by default).',url:"You can use any web service as a data source for multiple-choice questions. To populate choice values, enter the URL of the service providing the data.",searchMode:"A comparison operation used to filter the drop-down list.",textWrapEnabled:"Long texts in choice options will automatically generate line breaks to fit within the drop-down menu. Unselect if you want the texts to clip."},signaturepad:{signatureWidth:"Sets the width of the displayed signature area and the resulting image.",signatureHeight:"Sets the height of the displayed signature area and the resulting image.",signatureAutoScaleEnabled:"Select if you want the signature area to fill all available space within the question box while maintaining the default 3:2 aspect ratio. When custom width and height values are set, the setting will keep the aspect ratio of these dimensions."},file:{imageHeight:"Adjusts the height of the image in the survey results.",imageWidth:"Adjusts the width of the image in the survey results.",allowImagesPreview:"Displays thumbnail previews for uploaded files when possible. Unselect if you want to show file icons instead."},image:{contentMode:'The "Auto" option automatically determines the suitable mode for display - Image, Video, or YouTube - based on the source URL provided.'},imagepicker:{imageHeight:"Overrides the minimum and maximum height values.",imageWidth:"Overrides the minimum and maximum width values.",choices:'"Value" serves as an item ID used in conditional rules; "Text" is displayed to respondents.',contentMode:'Choose between "Image" and "Video" to set the content mode of the media selector. If "Image" is selected, ensure that all options provided are image files in the following formats: JPEG, GIF, PNG, APNG, SVG, BMP, ICO. Similarly, if "Video" is selected, ensure that all options are direct links to video files in the following formats: MP4, MOV, WMV, FLV, AVI, MKV. Please note that YouTube links are not supported for video options.'},text:{size:'This setting only resizes the input field and doesn\'t affect the width of the question box. To limit the accepted input length, go to "Validation" → "Maximum character limit".'},comment:{rows:"Sets the number of displayed lines in the input field. If the input takes up more lines, the scroll bar will appear."},survey:{mode:'Choose between: "Editable" - enables respondents to fill out your survey; "Read-only" - disables form editing.'},matrixdropdowncolumn:{name:"A column ID that is not visible to respondents.",isUnique:"When enabled for a column, a respondent is required to provide a unique response for each question within this column.",rows:"Sets the number of displayed lines in the input field. If the input takes up more lines, the scroll bar will appear.",visibleIf:"Use the magic wand icon to set a conditional rule that determines column visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the column.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",showInMultipleColumns:"When selected, creates an individual column for each choice option.",colCount:'Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line. When set to -1, the actual value is inherited from the "Nested column count" property of the parent matrix.'},caseInsensitive:"Select if uppercase and lowercase letters in the regular expression must be treated as equivalent.",widthMode:'Choose from: "Static" - sets a fixed width; "Responsive" - makes the survey occupy the full width of the screen; "Auto" - applies either of the two depending on the question types used.',cookieName:"Assign a unique cookie value for your survey. The cookie will be set in a respondent's browser upon survey completion to prevent repetitive survey submissions.",logo:"Paste an image link (no size limits) or click the folder icon to browse a file from your computer (up to 64KB).",logoWidth:"Sets a logo width in CSS units (px, %, in, pt, etc.).",logoHeight:"Sets a logo height in CSS units (px, %, in, pt, etc.).",logoFit:'Choose from: "None" - image maintains its original size; "Contain" - image is resized to fit while maintaining its aspect ratio; "Cover" - image fills the entire box while maintaining its aspect ratio; "Fill" - image is stretched to fill the box without maintaining its aspect ratio.',goNextPageAutomatic:"Select if you want the survey to advance to the next page automatically after a respondent answers all questions on the current page.",allowCompleteSurveyAutomatic:"Select if you want the survey to complete automatically after a respondent answers all questions.",showNavigationButtons:"Sets the visibility and location of navigation buttons on a page.",showProgressBar:'Sets the visibility and location of a progress bar. The "Auto" value displays the progress bar above or below the survey header.',showPreviewBeforeComplete:"Enable the preview page with all or answered questions only.",questionTitleLocation:"Applies to all questions within the survey. This setting can be overridden by title alignment rules at lower levels: panel, page, or question. A lower-level setting will override those on a higher level.",requiredText:"A symbol or a sequence of symbols indicating that an answer is required.",questionStartIndex:"Enter a number or letter with which you want to start numbering.",questionErrorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box.',focusFirstQuestionAutomatic:"Select if you want the first input field on each page ready for text entry.",questionsOrder:"Keeps the original order of questions or randomizes them. The effect of this setting is only visible in the Preview tab.",maxTextLength:"For text entry questions only.",maxOthersLength:"For question comments only.",commentAreaRows:"Sets the number of displayed lines in text areas for question comments. In the input takes up more lines, the scroll bar appears.",autoGrowComment:"Select if you want question comments and Long Text questions to auto-grow in height based on the entered text length.",allowResizeComment:"For question comments and Long Text questions only.",calculatedValues:"Custom variables serve as intermediate or auxiliary variables used in form calculations. They take respondent inputs as source values. Each custom variable has a unique name and an expression it's based on.",includeIntoResult:"Select if you wish the calculated value of the expression to be saved along with survey results.",triggers:'A trigger is an event or condition that is based on an expression. Once the expression is evaluated to "true", a trigger sets off an action. Such an action can optionally have a target question it affects.',clearInvisibleValues:"Choose whether or not to clear values for questions hidden by conditional logic and when to do it.",textUpdateMode:'Choose from: "On lost focus" - the value is updated when the input field loses focus; "While typing" - the value is updated in real-time, as users are typing.',columns:"The left value serves as a column ID used in conditional rules, the right value is displayed to respondents.",rows:"The left value serves as a row ID used in conditional rules, the right value is displayed to respondents.",columnMinWidth:"Accepts CSS values (px, %, in, pt, etc.).",rowTitleWidth:"Accepts CSS values (px, %, in, pt, etc.).",totalText:'Visible only if at least one column displays total values set with "Aggregation method" or "Total value expression".',cellErrorLocation:'Sets the location of an error message in relation to a cell with invalid input. The "Inherit" option applies the setting from the "Error message alignment" property.',keyDuplicationError:'When the "Prevent duplicate responses" property is enabled, a respondent attempting to submit a duplicate entry will receive the following error message.',totalExpression:"Allows you to calculate total values based on an expression. The expression can include basic calculations (`{q1_id} + {q2_id}`), Boolean expressions (`{age} > 60`) and functions ('iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc.).",confirmDelete:"Triggers a prompt asking to confirm the row deletion.",defaultValueFromLastRow:"Duplicates answers from the last row and assigns them to the next added dynamic row.",keyName:"Reference a column ID to require a user to provide a unique response for each question within the specified column.",description:"Type a subtitle.",locale:"Choose a language to begin creating your survey. To add a translation, switch to a new language and translate the original text here or in the Translations tab.",detailPanelMode:'Sets the location of a details section in relation to a row. Choose from: "None" - no expansion is added; "Under the row" - a row expansion is placed under each row of the matrix; "Under the row, display one row expansion only" - an expansion is displayed under a single row only, the remaining row expansions are collapsed.',imageFit:'Choose from: "None" - image maintains its original size; "Contain" - image is resized to fit while maintaining its aspect ratio; "Cover" - image fills the entire box while maintaining its aspect ratio; "Fill" - image is stretched to fill the box without maintaining its aspect ratio.',autoGrow:'The "Inherit" option applies a survey-level setting ("Disabled" by default).',allowResize:'The "Inherit" option applies a survey-level setting ("Enabled" by default).',timeLimit:'A time interval in seconds after which the survey auto-advances to the "Thank You" page. When set to 0, counts the time spent on the survey.',timeLimitPerPage:'A time interval in seconds after which the survey auto-advances to the next page. Hides the "Previous" navigation button. When set to 0, counts the time spent on the current page.',validateVisitedEmptyFields:"Enable this option to trigger validation when a user focuses on an empty input field and then leaves it without making any changes.",page:{timeLimit:'A time interval in seconds after which the survey auto-advances to the next page. Hides the "Previous" navigation button. When set to 0, counts the time spent on the current page.',visibleIf:"Use the magic wand icon to set a conditional rule that determines page visibility.",enableIf:"Use the magic wand icon to set a conditional rule that disables the read-only mode for the page.",requiredIf:"Use the magic wand icon to set a conditional rule that prevents survey submission unless at least one nested question has an answer.",questionTitleLocation:'Applies to all questions within this page. When set to "Hidden", it also hides question descriptions. If you want to override this setting, define title alignment rules for individual questions or panels. The "Inherit" option applies the survey-level setting ("Top" by default).',questionTitleWidth:"Sets consistent width for question titles when they are aligned to the left of their question boxes. Accepts CSS values (px, %, in, pt, etc.).",questionErrorLocation:'Sets the location of an error message in relation to the question with invalid input. Choose between: "Top" - an error text is placed at the top of the question box; "Bottom" - an error text is placed at the bottom of the question box. The "Inherit" option applies the survey-level setting ("Top" by default).',questionsOrder:'Keeps the original order of questions or randomizes them. The "Inherit" option applies the survey-level setting ("Original" by default). The effect of this setting is only visible in the Preview tab.',navigationButtonsVisibility:'Sets the visibility of navigation buttons on the page. The "Inherit" option applies the survey-level setting, which defaults to "Visible".'},timerLocation:"Sets the location of a timer on a page.",panelsState:'Choose from: "Locked" - users cannot expand or collapse panels; "Collapse all" - all panels start in a collapsed state; "Expand all" - all panels start in an expanded state; "First expanded" - only the first panel is initially expanded. Applies if "Panel display mode" is set to "List" and the "Panel title pattern" property is specified.',imageLinkName:"Enter a shared property name within the array of objects that contains the image or video file URLs you want to display in the choice list.",choices:"The left value serves as an item ID used in conditional rules, the right value is displayed to respondents.",title:"Type a user-friendly title to display.",waitForUpload:"Ensures that users won't complete the survey until files are uploaded.",minWidth:"Accepts CSS values (px, %, in, pt, etc.).",maxWidth:"Accepts CSS values (px, %, in, pt, etc.).",width:"Accepts CSS values (px, %, in, pt, etc.).",valueName:"A join identifier is a custom key that you can assign to several questions to link them together and sync their values. These values will be merged into a single array or object and stored in survey results using the key as the property name.",useDisplayValuesInDynamicTexts:"In single- and multiple-selection question types, each choice option has an ID and display value. When selected, this setting shows a display value instead of an ID value in HTML questions and dynamic titles and descriptions of survey elements.",clearIfInvisible:'Choose whether or not to clear question values hidden by conditional logic and when to do it. The "Inherit" option applies the survey-level setting ("Upon survey completion" by default).',choicesFromQuestionMode:'Choose from: "All" - copies all choice options from the selected question; "Selected" - dynamically copies only selected choice options; "Unselected" - dynamically copies only unselected choice options. The "None" and "Other" options are copied by default if enabled in the source question.',showOtherItem:"When selected, users can include additional input in a separate comment box.",separateSpecialChoices:'Displays each special choice option ("None", "Other", "Select All") on a new line, even when using a multiple-column layout.',path:"Specify the location within the service dataset where the target array of objects is located. Leave empty if the URL already points to the array.",choicesbyurl:{valueName:"Enter a uniform property name within the array of objects whose value will be stored as a response in survey results."},titleName:"Enter a uniform property name within the array of objects that contains the values you want to display in the choice list.",allowEmptyResponse:"Select to allow the service to return an empty response or array.",choicesVisibleIf:"Use the magic wand icon to set a conditional rule that determines the visibility of all choice options.",rateValues:"The left value serves as an item ID used in conditional rules, the right value is displayed to respondents.",rating:{displayMode:'"Auto" selects between the "Buttons" and "Dropdown" modes based on the available width. When the width is insufficient to display buttons, the question displays a dropdown.'},valuePropertyName:"Allows you to connect questions that produce results in different formats. When such questions are linked together using a join identifier, this shared property stores selected question values.",searchEnabled:"Select if you want to update the drop-down menu contents to match the search query that a user is typing in the input field.",valueTrue:"A value to save in survey results when respondents give a positive answer.",valueFalse:"A value to save in survey results when respondents give a negative answer.",showPreview:"It's not recommended that you disable this option as it overrides the Preview image and makes it hard for a user to understand whether the files have been uploaded.",needConfirmRemoveFile:"Triggers a prompt asking to confirm the file deletion.",selectToRankEnabled:"Enable to rank only selected choices. Users will drag selected items from the choice list to order them within the ranking area.",dataList:"Enter a list of choices that will be suggested to the respondent during input.",itemSize:"The setting only resizes the input fields and doesn't affect the width of the question box.",itemTitleWidth:"Sets consistent width for all item labels in pixels",inputTextAlignment:'Select how to align input value within the field. The default setting "Auto" aligns the input value to the right if currency or numeric masking is applied and to the left if not.',altText:"Serves as a substitute when the image cannot be displayed on a user's device and for accessibility purposes.",rateColorMode:'Defines the color of the selected emoji when the Rating icon type is set to "Smileys". Choose between: "Default" - the selected emoji appears in default survey color; "Scale" - the selected emoji inherits color from the rating scale.',expression:{name:"An expression ID that is not visible to respondents.",description:"Type an expression subtitle.",expression:"An expression can include basic calculations (`{q1_id} + {q2_id}`), conditions (`{age} > 60`), and functions ('iif()`, `today()`, `age()`, `min()`, `max()`, `avg()`, etc.)."},storeOthersAsComment:'Select to store the "Other" option value as a separate property in survey results.',format:"Use {0} as a placeholder for the actual value.",acceptedTypes:"Refer to the [accept](https://www.w3schools.com/tags/att_input_accept.asp) attribute description for more information.",columnColCount:'Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line. Applies only to columns with "Cell input type" set to Radio Button Group or Checkboxes.',autocomplete:"Select the data type that the user's browser can retrieve. This data is sourced either from past values entered by the user or from pre-configured values if any have been saved by the user for autocompletion.",filePlaceholder:'Applies when "File source type" is "Local file" or when camera is unavailable',photoPlaceholder:'Applies when "File source type" is "Camera".',fileOrPhotoPlaceholder:'Applies when "File source type" is "Local file or camera".',colCount:"Arranges choice options in a multi-column layout. When set to 0, the options are displayed in a single line.",masksettings:{saveMaskedValue:"Select if you want to store the question value with an applied mask in survey results."},patternmask:{pattern:"The pattern can contain string literals and the following placeholders: `9` - for a digit; `a` - for an upper- or lower-case letter; `#` - for a digit or an upper- or lower-case letter. Use backslash `\\` to escape a character."},datetimemask:{pattern:"The pattern can contain separator characters and the following placeholders:<br>`m` - Month number.<br>`mm` - Month number, with leading zero for single-digit values.<br>`d` - Day of the month.<br>`dd` - Day of the month, with leading zero for single-digit values.<br>`yy` - The last two digits of the year.<br>`yyyy` - Four-digit year.<br>`H` - Hours in 24-hour format.<br>`HH` - Hours in 24-hour format, with leading zero for single-digit values.<br>`h` - Hours in 12-hour format.<br>`hh` - Hours in 12-hour format, with leading zero for single-digit values.<br>`MM` - Minutes.<br>`ss` - Seconds.<br>`TT` - 12-hour clock period in upper case (AM/PM).<br>`tt` - 12-hour clock period in lower case (am/pm)."},numericmask:{decimalSeparator:"A symbol used to separate the fractional part from the integer part of a displayed number.",thousandsSeparator:"A symbol used to separate the digits of a large number into groups of three.",precision:"Limits how many digits to retain after the decimal point for a displayed number."},currencymask:{prefix:"One or several symbols to be displayed before the value.",suffix:"One or several symbols to be displayed after the value."},theme:{isPanelless:"This setting applies only to questions outside of a panel.",primaryColor:"Sets a supplementary color that highlights key survey elements.",panelBackgroundTransparency:"Adjusts the transparency of panels and question boxes relative to the survey background.",questionBackgroundTransparency:"Adjusts the transparency of input elements relative to the survey background.",cornerRadius:"Sets the corner radius for all rectangular elements. Enable the Advanced Mode if you want to set individual corner radius values for input elements or panels and question boxes.","--sjs-general-backcolor-dim":"Sets the main background color of the survey."},header:{inheritWidthFrom:'The "Same as container" option auto-adjusts the header content area width to fit into the HTML element the survey is placed in.',textAreaWidth:"The width of the header area that contains the survey title and description, measured in pixels.",overlapEnabled:"When enabled, the top of the survey overlays the bottom of the header.",mobileHeight:"When set to 0, the height is calculated automatically to accommodate the header's content."},panellayoutcolumn:{effectiveWidth:"Accepts values %.",questionTitleWidth:"Accepts values px."},progressBarInheritWidthFrom:'The "Same as container" option auto-adjusts the progress bar area width to fit into the HTML element the survey is placed in.'},p:{title:{name:"title",title:"Leave it empty, if it is the same as 'Name'"},multiSelect:"Allow multiple selection",showLabel:"Show image and video captions",swapOrder:"Swap the order of Yes and No",value:"Value",tabAlign:"Tab alignment",sourceType:"File source type",fitToContainer:"Fit to container",setValueExpression:"Set value expression",description:"Description",logoFit:"Logo fit",pages:"Pages",questions:"Questions",triggers:"Triggers",calculatedValues:"Custom variables",surveyId:"Survey id",surveyPostId:"Survey post id",surveyShowDataSaving:"Survey show data saving",questionDescriptionLocation:"Question description alignment",progressBarType:"Progress bar type",showTOC:"Show table of contents (TOC)",tocLocation:"TOC alignment",questionTitlePattern:"Question title pattern",widthMode:"Survey width mode",showBrandInfo:"Show brand info",useDisplayValuesInDynamicTexts:"Use display values in dynamic texts",visibleIf:"Visible if",defaultValueExpression:"Default value expression",requiredIf:"Required if",resetValueIf:"Reset value if",setValueIf:"Set value if",validators:"Validation rules",bindings:"Bindings",renderAs:"Render as",attachOriginalItems:"Attach original items",choices:"Choices",choicesByUrl:"Choices by url",currency:"Currency",cellHint:"Cell hint",totalMaximumFractionDigits:"Total maximum fraction digits",totalMinimumFractionDigits:"Total minimum fraction digits",columns:"Columns",detailElements:"Detail elements",allowAdaptiveActions:"Allow adaptive actions",defaultRowValue:"Default row value",detailPanelShowOnAdding:"Detail panel show on adding",choicesLazyLoadEnabled:"Choices lazy load enabled",choicesLazyLoadPageSize:"Choices lazy load page size",inputFieldComponent:"Input field component",itemComponent:"Item component",min:"Min",max:"Max",minValueExpression:"Min value expression",maxValueExpression:"Max value expression",step:"Step",dataList:"Items for auto-suggest",itemSize:"Input field width (in characters)",itemTitleWidth:"Item label width (in px)",inputTextAlignment:"Input value alignment",elements:"Elements",content:"Content",navigationButtonsVisibility:"Show/hide navigation buttons",navigationTitle:"Navigation title",navigationDescription:"Navigation description",longTap:"Long tap",autoGrow:"Expand input field dynamically",allowResize:"Enable resize handle",acceptCarriageReturn:"Accept carriage return",displayMode:"Display mode",rateType:"Rate type",label:"Label",contentMode:"Content mode",imageFit:"Image and thumbnail fit",altText:"Alt text",height:"Height",mobileHeight:"Height on smartphones",penColor:"Pen color",backgroundColor:"Background color",templateElements:"Template elements",operator:"Operator",isVariable:"Is variable",runExpression:"Run expression",showCaption:"Show caption",iconName:"Icon name",iconSize:"Icon size",precision:"Precision",matrixDragHandleArea:"Matrix drag handle area",backgroundImage:"Background image",backgroundImageFit:"Background image fit",backgroundImageAttachment:"Background image attachment",backgroundOpacity:"Background opacity",selectToRankEnabled:"Allow selective ranking",selectToRankAreasLayout:"Ranking area alignment",selectToRankEmptyRankedAreaText:"Text to show if all options are selected",selectToRankEmptyUnrankedAreaText:"Placeholder text for the ranking area",allowCameraAccess:"Allow camera access",scaleColorMode:"Rating icon color mode",rateColorMode:"Smileys color scheme",copyDisplayValue:"Copy display value",effectiveColSpan:"Column span",progressBarInheritWidthFrom:"Progress bar area width"},theme:{advancedMode:"Advanced mode",pageTitle:"Page",questionTitle:"Question box",editorPanel:"Input element",lines:"Lines",primaryDefaultColor:"Default",primaryDarkColor:"Hover",primaryLightColor:"Selected",backgroundDimColor:"Background color",cornerRadius:"Corner radius",backcolor:"Default background",hovercolor:"Hover background",borderDecoration:"Border decoration",fontColor:"Font color",backgroundColor:"Background color",primaryForecolor:"Default color",primaryForecolorLight:"Disabled color",font:"Font",borderDefault:"Darker",borderLight:"Lighter",fontFamily:"Font family",fontWeightRegular:"Regular",fontWeightHeavy:"Heavy",fontWeightSemiBold:"Semi-bold",fontWeightBold:"Bold",color:"Color",placeholderColor:"Placeholder color",size:"Size",opacity:"Opacity",boxShadowX:"X",boxShadowY:"Y",boxShadowAddRule:"Add Shadow Effect",boxShadowBlur:"Blur",boxShadowSpread:"Spread",boxShadowDrop:"Drop",boxShadowInner:"Inner",names:{default:"Default",sharp:"Sharp",borderless:"Borderless",flat:"Flat",plain:"Plain",doubleborder:"Double Border",layered:"Layered",solid:"Solid",threedimensional:"3D",contrast:"Contrast"},colors:{teal:"Teal",blue:"Blue",purple:"Purple",orchid:"Orchid",tulip:"Tulip",brown:"Brown",green:"Green"}},creatortheme:{"--sjs-special-background":"Surface background","--sjs-primary-background-500":"Accent colors",surfaceScale:"Surface",userInterfaceBaseUnit:"User interface",fontScale:"Font",names:{sc2020:"Survey Creator 2020","default-light":"Light","default-dark":"Dark","default-contrast":"Contrast"}}},o=r(156);!function(e){e[e.AllTypes=0]="AllTypes",e[e.CompatibleTypes=1]="CompatibleTypes"}(e||(e={}));var i={translation:{sortByName:!1,exportPrefix:"",maximumSelectedLocales:7,exportFileName:"survey_translation.csv"},themeEditor:{exportFileName:"survey_theme.json",defaultFontFamily:"Open Sans"},operators:{empty:[],notempty:[],equal:["!file"],notequal:["!file"],contains:["checkbox","text","comment"],notcontains:["checkbox","text","comment"],anyof:["selectbase"],allof:["checkbox"],greater:["!checkbox","!imagepicker","!boolean","!file"],less:["!checkbox","!imagepicker","!boolean","!file"],greaterorequal:["!checkbox","!imagepicker","!boolean","!file"],lessorequal:["!checkbox","!imagepicker","!boolean","!file"]},defaultNewSurveyJSON:{},designer:{defaultAddQuestionType:"text",showAddQuestionButton:!0},logic:{questionSortOrder:"asc",get defaultOperator(){return i.logic.defaultOperators.default},set defaultOperator(e){i.logic.defaultOperators.default=e},defaultOperators:{default:"equal",checkbox:"allof",tagbox:"allof"},visibleActions:[],logicItemTitleMaxChars:50,openBracket:"{",closeBracket:"}",updateExpressionsOnChanging:{questionName:!0,columnName:!0,choiceValue:!0},updateExpressionsOnDeleting:{question:!0}},questionConvertMode:e.AllTypes,propertyGrid:{useButtonGroup:!0,maxCharsInButtonGroup:25,showNavigationButtons:!1,enableSearch:!0,maximumColumnsCount:0,minimumChoicesCount:0,maximumChoicesCount:0,maximumRowsCount:0,maximumRateValues:0,generalTabName:"general",defaultExpandedTabName:"general",allowExpandMultipleCategories:!1},toolbox:{defaultJSON:{dropdown:{choices:["Item 1","Item 2","Item 3"]},tagbox:{choices:["Item 1","Item 2","Item 3"]},checkbox:{choices:["Item 1","Item 2","Item 3"]},radiogroup:{choices:["Item 1","Item 2","Item 3"]},ranking:{choices:["Item 1","Item 2","Item 3"]},imagepicker:{imageFit:"cover",choices:[{value:"Image 1",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/lion.jpg"},{value:"Image 2",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/giraffe.jpg"},{value:"Image 3",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/panda.jpg"},{value:"Image 4",imageLink:"https://surveyjs.io/Content/Images/examples/image-picker/camel.jpg"}]},image:{imageFit:"cover",imageHeight:"auto",imageWidth:"100%"}}},notifications:{lifetime:2e3},autoSave:{delay:500},dragDrop:{restrictDragQuestionBetweenPages:!1,allowDragToTheSameLine:!0},layout:{showTabs:!0,showToolbar:!0,allowCollapseSidebar:!0},jsonEditor:{indentation:2,exportFileName:"survey.json"}},n=function(){function e(){this.isMobileView=!1,this.allowEditExpressionsInTextEditor=!0,this.maximumColumnsCount=i.propertyGrid.maximumColumnsCount,this.minimumChoicesCount=i.propertyGrid.minimumChoicesCount,this.maximumChoicesCount=i.propertyGrid.maximumChoicesCount,this.maximumRowsCount=i.propertyGrid.maximumRowsCount,this.maximumRateValues=i.propertyGrid.maximumRateValues,this.machineTranslationValue=!1,this.inplaceEditForValues=!1,this.maxNestedPanels=-1,this.translationLocalesOrder=[]}return e.prototype.getProcessedTranslationItemText=function(e,t,o,i){return o},e.prototype.getObjectDisplayName=function(e,t,o,i){return i},e.prototype.onCanShowPropertyCallback=function(e,t,o,i,n){return!0},e.prototype.getElementAddornerCssCallback=function(e,t){return t},e.prototype.onPropertyGridSurveyCreatedCallback=function(e,t){},e.prototype.onPropertyEditorCreatedCallback=function(e,t,o){},e.prototype.onPropertyEditorUpdateTitleActionsCallback=function(e,t,o,i){},e.prototype.onPropertyGridShowModalCallback=function(e,t,o,i,n){},e.prototype.onIsPropertyReadOnlyCallback=function(e,t,o,i,n){return o},e.prototype.onCanDeleteItemCallback=function(e,t,o){return o},e.prototype.onCollectionItemDeletingCallback=function(e,t,o,i){return!0},e.prototype.onCollectionItemAllowingCallback=function(e,t,o,i,n){},e.prototype.onItemValueAddedCallback=function(e,t,o,i){},e.prototype.onFastEntryCallback=function(e,t){return e},e.prototype.onMatrixDropdownColumnAddedCallback=function(e,t,o){},e.prototype.onSetPropertyEditorOptionsCallback=function(e,t,o){},e.prototype.onGetErrorTextOnValidationCallback=function(e,t,o){return null},e.prototype.onValueChangingCallback=function(e){},e.prototype.onGetElementEditorTitleCallback=function(e,t){return t},e.prototype.startUndoRedoTransaction=function(){},e.prototype.stopUndoRedoTransaction=function(){},e.prototype.createSurvey=function(e,t,i,n,r){var a=new o.SurveyModel(e);return n&&n(a),a},e.prototype.onConditionQuestionsGetListCallback=function(e,t,o,i,n){return"asc"},e.prototype.onConditionGetTitleCallback=function(e,t){return t},e.prototype.isConditionOperatorEnabled=function(e,t,o,i){return i},e.prototype.onLogicGetTitleCallback=function(e,t,o,i){return o},e.prototype.getTranslationExportedText=function(e,t,o,i,n){return n},e.prototype.uploadFiles=function(e,t,o){},e.prototype.getHasMachineTranslation=function(){return this.machineTranslationValue},e.prototype.doMachineTranslation=function(e,t,o,i){},e.prototype.chooseFiles=function(e,t,o){},e}();function s(e){if(!e)return"";for(var t="",o=e.length-1;o>=0;o--){if(e[o]>="0"&&e[o]<="9")t=e[o]+t;else if(t)return t;if(10==t.length)break}return t}function l(e){return Math.round(100*e)/100}o.StylesManager.applyTheme("defaultV2");var u={true:"false",True:"False",TRUE:"FALSE",false:"true",False:"True",FALSE:"TRUE",yes:"no",Yes:"No",YES:"NO",no:"yes",No:"Yes",NO:"YES"};function p(e,t){t=t.toString();for(var o=0;o<e.length;o++)if(e[o]&&e[o].toString()===t)return!0;return!1}function c(e,t){return h(e,t.map((function(e){return e.value})))}function d(e){var t=e.length;if(0===t)return"";if(!e[t-1].text||e[t-1].text===e[t-1].value)return"";var o=[];e.forEach((function(e){e.hasText&&o.push(e.text)})),e.map((function(e){return e.text}));var i=h("",o);return i?i.toString():""}function h(e,t){if(t.length>0)var o=function(e){return u[e]?u[e]:null}(t[t.length-1]);if(o&&t.indexOf(o)<0)return o;for(var i,n="",r=-1,a=t.length-1;a>=0;a--)if(t[a]){var l=t[a].toString();if(n=s(l)){r=l.lastIndexOf(n),i=t[a];break}}if(r>-1){var c,d=parseInt(n),h=i===d;do{if(h)c=++d;else{for(var g=(d++).toString();n.length>g.length;)g="0"+g;c=l.substring(0,r)+g+l.substring(r+n.length)}}while(p(t,c));return c}return e||(e=t[t.length-1]),e+1}function g(e,t){for(var o=t;o&&!o.classList.contains(e);)o=o.parentElement;return o}function m(e){for(var t=0;t<e.length;t++)if("function"==typeof e[t].getElementsByClassName){var o=e[t].getElementsByClassName("svd-focusable");if(0===o.length&&-1!==e[t].className.indexOf("svd-focusable")&&(o=[e[t]]),o.length>0){var i=o[0];if("a"!==i.tagName.toLowerCase()){i.focus({preventScroll:!0});break}}}}function f(e){if(e&&e.length){for(var t=0;t<e.length;t++)if("#text"!=e[t].nodeName&&"#comment"!=e[t].nodeName)return e[t];return null}}function y(e){var t=e.element,o=[];if(8!==t.nodeType)return t.childNodes;for(;t=t.nextSibling;)3!==t.nodeType&&o.push(t);return o}function v(e,t){var i=!0;return e&&"function"==typeof e.getType&&(i=!!o.Serializer.findProperty(e.getType(),t)),i}function b(e,t){var i=!0;if(e&&"function"==typeof e.getType){var n=o.Serializer.findProperty(e.getType(),t);i=!n||n.visible}return i}function C(e,t,o){void 0===o&&(o=0);var i="__svc_question_processed",n="svc-hovered",r="svc-hovered-ready";function a(e,o){void 0===o&&(o=null);var i=(t.className||"").split(" ");o&&-1==i.indexOf(o)||-1==i.indexOf(e)&&(t.className+=" "+e)}e[i]||"mouseover"!==e.type?(t.className=(t.className||"").replace(" svc-hovered-ready",""),t.className=(t.className||"").replace(" svc-hovered","")):(o?(a(r),setTimeout((function(){a(n,r)}),o)):a(n),e[i]=!0)}function w(e){return e.replace(new RegExp("(\\r\\n|\\n|\\r)","gm"),"")}function x(e){var t,o;window&&(window.getSelection&&document.createRange?(o=window.getSelection(),(t=document.createRange()).selectNodeContents(e),o.removeAllRanges(),o.addRange(t)):document.selection&&document.body.createTextRange&&((t=document.body.createTextRange()).moveToElementText(e),t.select()))}function T(e,t){for(var o in t){var i=t[o];"object"==typeof i&&T(i={},t[o]),e[o]=i}}function S(e,t){t&&("string"==typeof t||t instanceof String?e.root=t:T(e,t))}function P(e,t){S(e,o.defaultV2Css.question),S(e,o.defaultV2Css[t]),e.hasErrorTop="",e.hasErrorBottom=""}function E(e){return i.logic.openBracket+e+i.logic.closeBracket}function V(e){return e?e=(e=e.replace(/[\s]+/g," ")).replace(/([\s]|^)(\S)/g,(function(e,t,o){return t+o.toUpperCase()})):e}function I(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return e.every((function(e){return!0===e}))}var O="image/png, image/gif, image/jpeg, image/apng, image/avif, image/svg+xml, image/webp";function A(e){return["auto","image"].indexOf(e)>-1?O:"video"==e?"video/*":""}function N(e){return e instanceof o.MatrixDropdownColumn?e.templateQuestion:e}function L(e){if(e&&void 0!==o.settings.environment.root){var t=o.settings.environment.root.getElementById(e);t&&t.scrollIntoView({behavior:"smooth",block:"center",inline:"start"})}}function _(e,t){if(e&&void 0!==t){var o=parseInt(e.slice(1,3),16),i=parseInt(e.slice(3,5),16),n=parseInt(e.slice(5,7),16);return"rgba(".concat(o,", ").concat(i,", ").concat(n,", ").concat(t,")")}}function M(e,t){return"rgba(".concat(e[0],", ").concat(e[1],", ").concat(e[2],", ").concat(t,")")}function D(e){void 0===e&&(e="");var t=e.match(/\((.*)\)/);return t?t[1].split(",").map((function(e){return parseFloat(e)})):[]}function k(e){void 0===e&&(e="");var t=D(e);if(0!==t.length){var o=1;return 4==t.length&&(o=t.pop()),{color:t.reduce((function(e,t){var o=t.toString(16);return e+(1==o.length?"0"+o:o)}),"#"),opacity:l(100*o)}}return{color:e,opacity:100}}function j(e,t,o){t/=100,o/=100;var i=function(t){return(t+e/60)%6},n=function(e){return o*(1-t*Math.max(0,Math.min(i(e),4-i(e),1)))};return[Math.round(255*n(5)),Math.round(255*n(3)),Math.round(255*n(1))]}function R(e,t,o){e/=255,t/=255,o/=255;var i=Math.max(e,t,o),n=i-Math.min(e,t,o),r=0===n?0:n&&i===e?(t-o)/n:i===t?2+(o-e)/n:4+(e-t)/n;return[60*(r<0?r+6:r),i&&n/i*100,100*i]}function B(e){Object.keys(e).forEach((function(t){void 0!==e[t]&&null!==e[t]||delete e[t]}))}function q(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var o=(e||[]).filter((function(e){return!!e}));if(!(o.length<=1)){if(2==o.length)return Object.keys(o[1]).forEach((function(e){return o[0][e]=o[1][e]})),void B(e[0]);for(var i=1;i<o.length;i++)q(o[0],o[i])}}var H=function(){function e(){this.colorSettings={baseColorAlpha:1,darkColorAlpha:1,lightColorAlpha:1,deltaDarkColor:0,deltaLightColor:0,newColorLight:"",newColorDark:""}}return e.prototype.initialize=function(e,t,o){var i=D(e),n=D(o),r=D(t);this.colorSettings.baseColorAlpha=i[3],this.colorSettings.darkColorAlpha=n[3],this.colorSettings.lightColorAlpha=r[3];var a=R(i[0],i[1],i[2]),s=R(n[0],n[1],n[2]),l=R(r[0],r[1],r[2]);this.colorSettings.deltaDarkColor=a[2]-s[2],this.colorSettings.deltaLightColor=a[2]-l[2]},e.prototype.calculateColors=function(e){var t=D(e);0===t.length&&(t=D(_(e,1)));var o=R(t[0],t[1],t[2]),i=j(o[0],o[1],o[2]-this.colorSettings.deltaDarkColor),n=j(o[0],o[1],o[2]-this.colorSettings.deltaLightColor);this.colorSettings.newColorLight=M(n,this.colorSettings.lightColorAlpha),this.colorSettings.newColorDark=M(i,this.colorSettings.darkColorAlpha)},e}();function F(e,t){if(window)if(window.navigator.msSaveOrOpenBlob)window.navigator.msSaveBlob(t,e);else{var o=window.document.createElement("a");o.href=window.URL.createObjectURL(t),o.download=e,document.body.appendChild(o),o.click(),document.body.removeChild(o)}}var Q={"tabs.preview":"ed.testSurvey","tabs.theme":"ed.themeSurvey","tabs.translation":"ed.translation","tabs.designer":"ed.designer","tabs.editor":"ed.jsonEditor","tabs.logic":"ed.logic"},U=function(){function e(){this.defaultLocaleValue="en",this.currentLocaleValue="",this.camelCaseBreaking=!0,this.locales={},this.peByClass={},this.peHelpByClass={},this.pePlaceholderByClass={}}return e.prototype.reset=function(){this.peByClass={},this.peHelpByClass={},this.pePlaceholderByClass={}},Object.defineProperty(e.prototype,"defaultLocale",{get:function(){return this.defaultLocaleValue},set:function(e){e||(e="en"),e!==this.defaultLocale&&(this.defaultLocaleValue=e,this.reset())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"currentLocale",{get:function(){return this.currentLocaleValue},set:function(e){e||(e=""),e!==this.currentLocale&&(this.currentLocaleValue=e,this.reset())},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"presetStrings",{get:function(){return this.presetStringsValues},set:function(e){this.presetStringsValues=e,this.reset()},enumerable:!1,configurable:!0}),e.prototype.getString=function(e,t){void 0===t&&(t=null);var o=this.getOldKeysString(e,t);if(o)return o;var i=e.split(".");return this.getStringByPath(i,t)},e.prototype.getStringByPath=function(e,t){void 0===t&&(t=null),t||(t=this.currentLocale);var o=this.getLocale(t),i=this.getDefaultStrings(),n=[];if(o&&n.push(o),t&&t.indexOf("-")>-1){var r=this.getLocale(t.substring(0,t.indexOf("-")));r&&n.push(r)}0!==n.length&&n[n.length-1]===i||n.push(i);var a=this.getPresetLocale(t);a&&n.unshift(a);for(var s=0;s<n.length;s++){var l=this.getStringByLocale(e,n[s]);if(l||""===l)return l}return e[e.length-1]},e.prototype.hasString=function(e,t){return void 0===t&&(t=null),void 0!==this.getStringByLocale(e.split("."),this.getLocale(t))},e.prototype.getStringByLocale=function(e,t){for(var o=t,i=0;i<e.length;i++){if("string"==typeof o)return;if(!(o=o[e[i]])&&""!==o)return}return o},e.prototype.getLocaleName=function(e,t,i){void 0===t&&(t=null),t||(t=o.surveyLocalization.defaultLocale);var n=o.surveyLocalization.getLocaleName(e||t,i);return n===e?n:(n=V(n),e||(n=G.getString("ed.defaultLocale").format(n)),n||e)},e.prototype.getPropertyName=function(e,t){void 0===t&&(t=null);var o=this.getProperty(e,t),i=o.name;return i?this.stringsDiff(i,e)?i:this.getAutoPropertyName(i,t):o},e.prototype.getPropertyTitle=function(e){var t=this.getProperty(e);return t.title?t.title:""},e.prototype.getPropertyNameInEditor=function(e,t,o){void 0===o&&(o=null);var i=this.getPropertyInfoInEditorByType(e,t,this.peByClass,"pe");return i||(i=this.getStringByPath(["pe",t])),this.stringsDiff(i,t)?i:this.getPropertyName(t,o)},e.prototype.getPropertyHelpInEditor=function(e,t,o){void 0===o&&(o=void 0);var i=this.getPropertyHelpInEditorCore(e,t,this.peHelpByClass,"pehelp");if(i)return i;var n=this.getLocale();return o&&n&&n.pe?n.pe[o+"Help"]:void 0},e.prototype.getPropertyPlaceholder=function(e,t){var o=this.getPropertyHelpInEditorCore(e,t,this.pePlaceholderByClass,"peplaceholder");if(o)return" "===o?null:o;var i=this.getLocale();return i&&i.peplaceholder&&(o=i.peplaceholder[t]),o||(i&&i.pe?i.pe[t+"_placeholder"]:void 0)},e.prototype.getPropertyHelpInEditorCore=function(e,t,o,i){var n=this.getPropertyInfoInEditorByType(e,t,o,i);if(n)return" "===n?null:n;for(var r=this.getLocalesWithPreset(),a=0;a<r.length;a++){var s=r[a];if(s[i]&&s[i][t])return s[i][t]}},e.prototype.getPropertyInfoInEditorByType=function(e,t,o,i){if(e)for(var n=this.getLocalesWithPreset(),r=0;r<n.length;r++){var a=this.getPropertyInfoInEditorByTypeCore(e,t,o,i,n[r]);if(a)return a}},e.prototype.getPropertyInfoInEditorByTypeCore=function(e,t,o,i,n){var r=o[e];for(void 0===r&&(r=this.getObjInEditorByTypeCore(e,o,i,n));r;){var a=r.props[t];if(a&&"function"!=typeof a)return r.props[t];r=r.parent}},e.prototype.getObjInEditorByTypeCore=function(e,t,i,n){if(e){t[e];var r=n?n[i]:void 0;if(r){var a=e.indexOf("@");if(a>-1){var s=this.getObjInEditorByTypeCore(e.substring(0,a),t,i,n);if(!r[e])return t[e]=s,s;var l={props:r[e],parent:s};return t[e]=l,l}for(var u=[],p=o.Serializer.findClass(e),c=void 0;p;){var d=p.name;if(c=t[e])break;if(u.push(d),r[d]){c={props:r[d],parent:this.getObjInEditorByTypeCore(p.parentName,t,i,n)};break}if(!p.parentName)break;p=o.Serializer.findClass(p.parentName)}for(var h=0;h<u.length;h++)t[u[h]]=c;return c}}},e.prototype.getProperty=function(e,t){void 0===t&&(t=null);var o=this.getStringByPath(["p",e]);if(this.stringsDiff(o,e))return o;var i=(e+"").indexOf("_");return i<-1?this.getAutoPropertyName(o,t):(e=(e+"").substring(i+1),o=this.getStringByPath(["p",e]),this.stringsDiff(o,e)?o:this.getAutoPropertyName(o,t))},e.prototype.convertToCamelCase=function(e,t){if(void 0===t&&(t=!1),!e)return e;if((e=e.trim()).indexOf(" ")>-1)return e;for(var o=!1,i=0;i<e.length;i++)if(e[i]!==e[i].toUpperCase()){o=!0;break}if(!o)return e;var n=e[0].toUpperCase(),r=!1,a=function(t){return!(t>=e.length)&&e[t].toUpperCase()===e[t]};for(i=1;i<e.length;i++)!r&&a(i)&&(n+=" "),n+=r||a(i+1)?e[i]:e[i].toLowerCase(),r=a(i);return t&&(n=n.toLowerCase()),n},e.prototype.getAutoPropertyName=function(e,t){return void 0===t&&(t=null),t||(e&&this.camelCaseBreaking?this.convertToCamelCase(e):e)},e.prototype.getPropertyValueInEditor=function(e,t){var o=this.getLocale();if(o&&o.pv&&o.pv[e]){var i=o.pv[e][t];if(i)return i}return this.getPropertyValue(t)},e.prototype.getPropertyValue=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"pv",t)},e.prototype.getValidatorName=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"validators",t)},e.prototype.getTriggerName=function(e,t){return void 0===t&&(t=null),this.getValueInternal(e,"triggers",t)},e.prototype.getLocale=function(e){e||(e=this.currentLocale);var t=e?this.locales[e]:this.getDefaultStrings();return t||(t=this.getDefaultStrings()),t},e.prototype.getPresetLocale=function(e){if(this.presetStrings){var t=e||this.currentLocale||this.defaultLocale;return this.presetStrings[t]}},e.prototype.getLocalesWithPreset=function(e){var t=[],o=this.getPresetLocale(e);o&&t.push(o);var i=this.getLocale(e);return i&&t.push(i),t},e.prototype.getValueInternal=function(e,t,o){return void 0===o&&(o=null),!e||e.indexOf&&e.indexOf(".")>-1?"":(e=e.toString(),this.getString(t+"."+e,o)||(this.camelCaseBreaking?this.convertToCamelCase(e,!1):e))},e.prototype.getLocales=function(){var e=[];for(var t in e.push(""),this.locales)e.push(t);return e},e.prototype.getDefaultStrings=function(){var e=this.defaultLocale;if(e&&"en"!==e){var t=this.getLocale(e);if(t)return t}return z},e.prototype.stringsDiff=function(e,t){return"function"!=typeof e&&"function"!=typeof t&&e!==t},e.prototype.getOldKeysString=function(e,t){void 0===t&&(t=null);var o=Q[e];if(o){var i=o.split("."),n=this.getStringByPath(i,t);return n!==i[i.length-1]?n:void 0}},e}(),G=new U;function Z(e,t){return void 0===t&&(t=null),G.getString(e,t)}o.surveyLocalization.onGetExternalString=function(e,t){var o=G.getString(e,t);return o!==e?o:""};var z=t,J=function(e,t,o,i){var n,r=arguments.length,a=r<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,o):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,o,i);else for(var s=e.length-1;s>=0;s--)(n=e[s])&&(a=(r<3?n(a):r>3?n(t,o,a):n(t,o))||a);return r>3&&a&&Object.defineProperty(t,o,a),a},W=Object.assign||function(e){for(var t,o=1,i=arguments.length;o<i;o++)for(var n in t=arguments[o])Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e};function K(e,t){for(var o in t)t.hasOwnProperty(o)&&(e[o]=t[o]);function i(){this.constructor=e}e.prototype=null===t?Object.create(t):(i.prototype=t.prototype,new i)}var Y,X=function(){function e(e){void 0===e&&(e=0),this.parseType=e}return e.prototype.parse=function(e,t,o,i){var n;return void 0===t&&(t=null),void 0===o&&(o=0),void 0===i&&(i=-1),this.text=String(e),this.at=o,this.endAt=i,this.ch=" ",n=this.value(),this.white(),this.ch&&this.error("Syntax error"),"function"==typeof t?function e(o,i){var n,r,a=o[i];if(a&&"object"==typeof a)for(n in a)Object.prototype.hasOwnProperty.call(a,n)&&(void 0!==(r=e(a,n))?a[n]=r:delete a[n]);return t.call(o,i,a)}({"":n},""):n},e.prototype.error=function(e){var t=new SyntaxError;throw t.message=e,t.at=this.at,t},e.prototype.next=function(e){return void 0===e&&(e=null),e&&e!==this.ch&&this.error("Expected '"+e+"' instead of '"+this.ch+"'"),this.ch=this.chartAt(),this.at+=1,this.ch},e.prototype.peek=function(){return this.chartAt()},e.prototype.chartAt=function(){return this.endAt>-1&&this.at>=this.endAt?"":this.text.charAt(this.at)},e.prototype.identifier=function(){var e=this.ch;for("_"!==this.ch&&"$"!==this.ch&&(this.ch<"a"||this.ch>"z")&&(this.ch<"A"||this.ch>"Z")&&this.error("Bad identifier");this.next()&&("_"===this.ch||"$"===this.ch||this.ch>="a"&&this.ch<="z"||this.ch>="A"&&this.ch<="Z"||this.ch>="0"&&this.ch<="9");)e+=this.ch;return e},e.prototype.number=function(){var e,t="",o="",i=10;if("-"!==this.ch&&"+"!==this.ch||(t=this.ch,this.next(this.ch)),"I"===this.ch)return("number"!=typeof(e=this.word())||isNaN(e))&&this.error("Unexpected word for number"),"-"===t?-e:e;if("N"===this.ch)return e=this.word(),isNaN(e)||this.error("expected word to be NaN"),e;switch("0"===this.ch&&(o+=this.ch,this.next(),"x"===this.ch||"X"===this.ch?(o+=this.ch,this.next(),i=16):this.ch>="0"&&this.ch<="9"&&this.error("Octal literal")),i){case 10:for(;this.ch>="0"&&this.ch<="9";)o+=this.ch,this.next();if("."===this.ch)for(o+=".";this.next()&&this.ch>="0"&&this.ch<="9";)o+=this.ch;if("e"===this.ch||"E"===this.ch)for(o+=this.ch,this.next(),"-"!==this.ch&&"+"!==this.ch||(o+=this.ch,this.next());this.ch>="0"&&this.ch<="9";)o+=this.ch,this.next();break;case 16:for(;this.ch>="0"&&this.ch<="9"||this.ch>="A"&&this.ch<="F"||this.ch>="a"&&this.ch<="f";)o+=this.ch,this.next()}if(e="-"===t?-o:+o,isFinite(e))return e;this.error("Bad number")},e.prototype.string=function(){var t,o,i,n,r="";if('"'===this.ch||"'"===this.ch)for(i=this.ch;this.next();){if(this.ch===i)return this.next(),r;if("\\"===this.ch)if(this.next(),"u"===this.ch){for(n=0,o=0;o<4&&(t=parseInt(this.next(),16),isFinite(t));o+=1)n=16*n+t;r+=String.fromCharCode(n)}else if("\r"===this.ch)"\n"===this.peek()&&this.next();else{if("string"!=typeof e.escapee[this.ch])break;r+=e.escapee[this.ch]}else{if("\n"===this.ch)break;r+=this.ch}}this.error("Bad string")},e.prototype.inlineComment=function(){"/"!==this.ch&&this.error("Not an inline comment");do{if(this.next(),"\n"===this.ch||"\r"===this.ch)return void this.next()}while(this.ch)},e.prototype.blockComment=function(){"*"!==this.ch&&this.error("Not a block comment");do{for(this.next();"*"===this.ch;)if(this.next("*"),"/"===this.ch)return void this.next("/")}while(this.ch);this.error("Unterminated block comment")},e.prototype.comment=function(){"/"!==this.ch&&this.error("Not a comment"),this.next("/"),"/"===this.ch?this.inlineComment():"*"===this.ch?this.blockComment():this.error("Unrecognized comment")},e.prototype.white=function(){for(;this.ch;)if("/"===this.ch)this.comment();else{if(!(e.ws.indexOf(this.ch)>=0))return;this.next()}},e.prototype.word=function(){switch(this.ch){case"t":return this.next("t"),this.next("r"),this.next("u"),this.next("e"),!0;case"f":return this.next("f"),this.next("a"),this.next("l"),this.next("s"),this.next("e"),!1;case"n":return this.next("n"),this.next("u"),this.next("l"),this.next("l"),null;case"I":return this.next("I"),this.next("n"),this.next("f"),this.next("i"),this.next("n"),this.next("i"),this.next("t"),this.next("y"),1/0;case"N":return this.next("N"),this.next("a"),this.next("N"),NaN}this.error("Unexpected '"+this.ch+"'")},e.prototype.array=function(){var e=[];if("["===this.ch)for(this.next("["),this.white();this.ch;){if("]"===this.ch)return this.next("]"),e;if(","===this.ch?this.error("Missing array element"):e.push(this.value()),this.white(),","!==this.ch)return this.next("]"),e;this.next(","),this.white()}this.error("Bad array")},e.prototype.object=function(){var t,o,i=!0,n={};if(this.parseType>0&&(n[e.positionName]={start:this.at-1}),"{"===this.ch)for(this.next("{"),this.white(),o=this.at-1;this.ch;){if("}"===this.ch)return this.parseType>0&&(n[e.positionName].end=o),this.next("}"),n;if(t='"'===this.ch||"'"===this.ch?this.string():this.identifier(),this.white(),this.parseType>1&&(n[e.positionName][t]={start:o,valueStart:this.at}),this.next(":"),n[t]=this.value(),this.parseType>1&&(o=this.at-1,n[e.positionName][t].valueEnd=o,n[e.positionName][t].end=o),this.white(),","!==this.ch)return this.parseType>1&&(n[e.positionName][t].valueEnd--,n[e.positionName][t].end--),this.parseType>0&&(n[e.positionName].end=this.at-1),this.next("}"),n;this.parseType>1&&(n[e.positionName][t].valueEnd--,i||n[e.positionName][t].end--),this.next(","),this.white(),i=!1}this.error("Bad object")},e.prototype.value=function(){switch(this.white(),this.ch){case"{":return this.object();case"[":return this.array();case'"':case"'":return this.string();case"-":case"+":case".":return this.number();default:return this.ch>="0"&&this.ch<="9"?this.number():this.word()}},e.prototype.stringify=function(e,t,o){if(void 0===t&&(t=null),void 0===o&&(o=null),t&&"function"!=typeof t&&!this.isArray(t))throw new Error("Replacer must be a function or an array");this.replacer=t,this.indentStr=this.getIndent(o),this.objStack=[];var i={"":e};return void 0===e?this.getReplacedValueOrUndefined(i,"",!0):this.internalStringify(i,"",!0)},e.prototype.getIndent=function(e){if(e){if("string"==typeof e)return e;if("number"==typeof e&&e>=0)return this.makeIndent(" ",e,!0)}return""},e.prototype.getReplacedValueOrUndefined=function(e,t,o){var i=e[t];return i&&i.toJSON&&"function"==typeof i.toJSON&&(i=i.toJSON()),"function"==typeof this.replacer?this.replacer.call(e,t,i):this.replacer?o||this.isArray(e)||this.replacer.indexOf(t)>=0?i:void 0:i},e.prototype.isWordChar=function(e){return e>="a"&&e<="z"||e>="A"&&e<="Z"||e>="0"&&e<="9"||"_"===e||"$"===e},e.prototype.isWordStart=function(e){return e>="a"&&e<="z"||e>="A"&&e<="Z"||"_"===e||"$"===e},e.prototype.isWord=function(e){if("string"!=typeof e)return!1;if(!this.isWordStart(e[0]))return!1;for(var t=1,o=e.length;t<o;){if(!this.isWordChar(e[t]))return!1;t++}return!0},e.prototype.isArray=function(e){return Array.isArray?Array.isArray(e):"[object Array]"===Object.prototype.toString.call(e)},e.prototype.isDate=function(e){return"[object Date]"===Object.prototype.toString.call(e)},e.prototype.isNaN=function(e){return"number"==typeof e&&e!=e},e.prototype.checkForCircular=function(e){for(var t=0;t<this.objStack.length;t++)if(this.objStack[t]===e)throw new TypeError("Converting circular structure to JSON")},e.prototype.makeIndent=function(e,t,o){if(void 0===o&&(o=!1),!e)return"";e.length>10&&(e=e.substring(0,10));for(var i=o?"":"\n",n=0;n<t;n++)i+=e;return i},e.prototype.escapeString=function(t){return e.escapable.lastIndex=0,e.escapable.test(t)?'"'+t.replace(e.escapable,(function(t){var o=e.meta[t];return"string"==typeof o?o:"\\u"+("0000"+t.charCodeAt(0).toString(16)).slice(-4)}))+'"':'"'+t+'"'},e.prototype.internalStringify=function(e,t,o){var i,n,r=this.getReplacedValueOrUndefined(e,t,o);switch(r&&!this.isDate(r)&&(r=r.valueOf()),typeof r){case"boolean":return r.toString();case"number":return isNaN(r)||!isFinite(r)?"null":r.toString();case"string":return this.escapeString(r.toString());case"object":if(null===r)return"null";if(this.isArray(r)){this.checkForCircular(r),i="[",this.objStack.push(r);for(var a=0;a<r.length;a++)n=this.internalStringify(r,a,!1),i+=this.makeIndent(this.indentStr,this.objStack.length),i+=null==n?"null":n,a<r.length-1?i+=",":this.indentStr&&(i+="\n");this.objStack.pop(),i+=this.makeIndent(this.indentStr,this.objStack.length,!0)+"]"}else{this.checkForCircular(r),i="{";var s=!1;for(var l in this.objStack.push(r),r)if(r.hasOwnProperty(l)){var u=this.internalStringify(r,l,!1);o=!1,null!=u&&(i+=this.makeIndent(this.indentStr,this.objStack.length),s=!0,i+=(this.isWord(l)?l:this.escapeString(l))+":"+(this.indentStr?" ":"")+u+",")}this.objStack.pop(),i=s?i.substring(0,i.length-1)+this.makeIndent(this.indentStr,this.objStack.length)+"}":"{}"}return i;default:return}},e.positionName="pos",e.escapee={"'":"'",'"':'"',"\\":"\\","/":"/","\n":"",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},e.ws=[" ","\t","\r","\n","\v","\f"," ","\ufeff"],e.cx=/[\u0000\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,e.escapable=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,e.meta={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},e}(),$=function(){function t(){}return Object.defineProperty(t,"convertInfo",{get:function(){return t.convertInfoValue||(t.convertInfoValue={},t.createDefaultQuestionConverterItems()),t.convertInfoValue},enumerable:!1,configurable:!0}),t.createDefaultQuestionConverterItems=function(){for(var e=o.Serializer.getChildrenClasses("selectbase",!0),i=0;i<e.length;i++)for(var n=0;n<e.length;n++)i!=n&&t.addConvertInfo(e[i].name,e[n].name);t.addConvertInfo("text","comment"),t.addConvertInfo("comment","text")},t.addConvertInfo=function(e,o){t.convertInfo[e]||(t.convertInfo[e]=[]),t.convertInfo[e].push(o)},t.getConvertableClasses=function(e){var o=t.convertInfo[e];return Array.isArray(o)&&o.indexOf(e)<0&&o.unshift(e),o},t.getConvertToClasses=function(n,r,a){void 0===r&&(r=null),void 0===a&&(a=!1);var s=i.questionConvertMode==e.AllTypes?function(e,t){void 0===t&&(t=!1);for(var i=o.Serializer.getChildrenClasses("question",!0),n=[],r=0;r<i.length;r++)(t||i[r].name!==e)&&n.push(i[r].name);(t||"panel"!==e)&&n.push("panel");var a=o.CustomWidgetCollection.Instance.widgets;for(r=0;r<a.length;r++)(t||a[r].name!==e)&&n.push(a[r].name);return n}(n,a):t.getConvertableClasses(n);if(!s)return[];if(Array.isArray(r)&&r.length>0){var l=[];s.forEach((function(e){return l.push(e)})),s=r.filter((function(e){return l.indexOf(e)>=0}))}return s||[]},t.getObjJSON=function(e,t){var i=e.toJSON();if(t)for(var n in t)i[n]&&o.Helpers.isTwoValueEquals(i[n],t[n])&&delete i[n];return i},t.convertObject=function(e,i,n,r,a){if(void 0===r&&(r=null),void 0===a&&(a=null),!e||!e.parent||i==e.getType()&&!r)return null;var s=r?void 0:o.QuestionFactory.Instance.createQuestion(i,e.name);s||(s=o.Serializer.createClass(i,{})),s.name=e.name;var l=r,u=l?o.Helpers.createCopy(l):s.toJSON(),p=n||{};for(var c in p)u[c]=p[c];if(a)for(var c in a)u[c]=a[c];t.updateJSON(u,i,e.getType()),s.fromJSON(u),t.removeValidators(s);var d=e.parent,h=d.elements.indexOf(e);d.isConverting=!0;var g=h+1<d.elements.length&&!1===d.elements[h+1].startWithNewLine;return d.removeElement(e),d.addElement(s,h),g&&(d.elements[h+1].startWithNewLine=!1),delete d.isConverting,s.onSurveyLoad(),s},t.updateJSON=function(e,o,i){t.updateJSONForRating(e,o),t.updateJSONForMatrices(e,o,i),t.updateJSONForPanels(e,o,i),t.updateJSONForBarrating(e,o)},t.updateJSONForMatrices=function(e,i,n){if(o.Serializer.isDescendantOf(i,"matrix")&&o.Serializer.isDescendantOf(n,"matrixdropdownbase")&&e.columns){var r=0;e.columns=e.columns.map((function(e){var t=e.name?e.name:"string"==typeof e?e:"col"+r++;return e.title?{value:t,text:e.title}:t}))}o.Serializer.isDescendantOf(i,"matrixdropdownbase")&&o.Serializer.isDescendantOf(n,"matrix")&&e.columns&&(e.columns=e.columns.map((function(e){return{name:t.getColumnName(e.name||e.value||e),title:e.text}})))},t.getColumnName=function(e){return o.Helpers.isNumber(e)?"col"+e:e},t.updateJSONForRating=function(e,t){"rating"===t&&e.choices&&(e.rateValues=e.choices),e.rateValues&&!o.Serializer.isDescendantOf(t,"matrixdropdownbase")&&(e.choices=e.rateValues)},t.updateJSONForBarrating=function(e,t){"barrating"===t&&(e.choices=[1,2,3,4,5])},t.updateJSONForPanels=function(e,t,i){o.Serializer.isDescendantOf(t,"paneldynamic")&&o.Serializer.isDescendantOf(i,"panel")&&e.elements&&(e.templateElements=e.elements,delete e.elements),o.Serializer.isDescendantOf(t,"panel")&&o.Serializer.isDescendantOf(i,"paneldynamic")&&e.templateElements&&(e.elements=e.templateElements,delete e.templateElements)},t.removeValidators=function(e){var t=e.validators;if(Array.isArray(t)&&0!==t.length)for(var o=e.getSupportedValidators(),i=t.length-1;i>=0;i--){var n=t[i].getType().replace("validator","");o.indexOf(n)<0&&t.splice(i,1)}},t}();!function(e){e.Unknown="unknown",e.Survey="survey",e.Page="page",e.Panel="panel",e.Question="question",e.Column="column"}(Y||(Y={}));var ee=function(){function e(){}return e.getNewElementName=function(e){var t=e.getSurvey();return t?e.isPage?this.getNewPageName(t.pages):e.isPanel?this.getNewPanelName(t.getAllPanels()):this.getNewQuestionName(t.getAllQuestions(!1,!1,!0)):e.name},e.getNewPageName=function(t){return e.getNewName(t,G.getString("ed.newPageName"))},e.isPageNameAutoGenerated=function(t){return e.isNameAutoGenerated(t,G.getString("ed.newPageName"))},e.isPagePropertiesAreModified=function(t){if(!e.isPageNameAutoGenerated(t.name))return!0;var o=t.toJSON();for(var i in delete o.name,delete o.elements,o)return!0;return!1},e.getNewQuestionName=function(t){return e.getNewName(t,G.getString("ed.newQuestionName"))},e.getNewPanelName=function(t){return e.getNewName(t,G.getString("ed.newPanelName"))},e.generateNewName=function(e){for(var t=e.length;t>0&&e[t-1]>="0"&&e[t-1]<="9";)t--;var o=e.substring(0,t),i=0;return t<e.length&&(i=parseInt(e.substring(t))),o+ ++i},e.getNewName=function(e,t){for(var o={},i=0;i<e.length;i++)o[e[i].name]=!0;for(var n=1;o[t+n.toString()];)n++;return t+n.toString()},e.isNameAutoGenerated=function(e,t){if(!e||e.length<t.length)return!1;var i=e.substring(t.length);return o.Helpers.isNumber(i)},e.getObjectType=function(e){return e&&e.getType?e.isPage?Y.Page:e.isPanel?Y.Panel:"survey"==e.getType()?Y.Survey:"matrixdropdowncolumn"==e.getType()?Y.Column:e.isQuestion?Y.Question:Y.Unknown:Y.Unknown},e.getObjectTypeStr=function(t){var o=e.getObjectType(t);return o===Y.Survey?"survey":o===Y.Page?"page":o===Y.Panel?"panel":o===Y.Question?"question":o===Y.Column?"column":"unknown"},e.getObjectName=function(t,o){return void 0===o&&(o=!1),e.getObjectType(t)===Y.Survey?G.getString("ed.surveyTypeName"):o&&t.title?t.title:o&&t.text?t.text:t.name?t.name:""},e.getElements=function(e,t){return void 0===t&&(t=!1),e?e.getElementsInDesign?e.getElementsInDesign(t):e.elements?e.elements:[]:[]},e.addElements=function(t,o,i){for(var n=0;n<t.length;n++)t[n].isPanel===o&&i.push(t[n]),e.addElements(e.getElements(t[n]),o,i)},e.getAllElements=function(t,o){for(var i=[],n=0;n<t.pages.length;n++)e.addElements(t.pages[n].elements,o,i);return i},e.isPropertyVisible=function(e,t,o,i,n,r){if(void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),void 0===r&&(r=null),!t||!t.visible)return!1;if(i&&t.showMode&&i!==t.showMode)return!1;if(t.isVisible&&e.getLayoutType&&!t.isVisible(e.getLayoutType(),null))return!1;var a=o?function(e,t){return o.onCanShowPropertyCallback(e,t,i,n,r)}:null;return!(a&&!a(e,t))},e.isNeedScrollIntoView=function(t,o){if(void 0===o&&(o=!1),t&&t.scrollIntoView){var i=t.getBoundingClientRect(),n=e.getScrollableDiv(t);if(n){var r=n.clientHeight;if(i.top<n.offsetTop)return"top";var a=r+n.offsetTop;return i.bottom>a&&(i.height<r||o)?"bottom":void 0}}},e.scrollIntoViewIfNeeded=function(t,o,i){void 0===i&&(i=!1);var n=e.isNeedScrollIntoView(t,i);if(n){var r="top"===n;t.scrollIntoView(o?o(r):r)}},e.getScrollableDiv=function(e){for(;e;){if(e.id&&e.id.indexOf("scrollableDiv")>-1)return e;if(!e.offsetParent)return null;e=e.offsetParent}return null},e.moveItemInArray=function(t,o,i){if(!t||t.length<2)return!1;if(i<0||i>=t.length)return!1;var n=t.indexOf(o);if(n<0||n==i)return!1;for(var r=0;r<t.length;r++)e.disableSelectingObj(t[r]);for(t.splice(n,1),t.splice(i,0,o),r=0;r<t.length;r++)e.enableSelectingObj(t[r]);return!0},e.applyItemValueArray=function(e,t){if(t&&0!=t.length){if(e.length>t.length&&e.splice(t.length,e.length-t.length),e.length<t.length){for(var o=[],i=e.length;i<t.length;i++)o.push(t[i]);e.splice.apply(e,[e.length,0].concat(o))}for(i=0;i<e.length;i++)e[i].value!=t[i].value&&(e[i].value=t[i].value),e[i].text=t[i].hasText?t[i].text:""}else e.splice(0,e.length)},e.disableSelectingObj=function(e){e.disableSelecting=!0},e.enableSelectingObj=function(e){delete e.disableSelecting},e.canSelectObj=function(e){return!e||!0!==e.disableSelecting},e.warnNonSupported=function(t,o){var i=E(t)+" is not supported in V2.";o&&(i+=" Use the '"+o+"' property instead"),e.warnText(i)},e.warnText=function(e){console.warn(e)},e.deleteConditionProperties=function(e){delete e.visible,delete e.visibleIf,delete e.readOnly,delete e.enableIf,delete e.valueName,delete e.choicesVisibleIf,delete e.choicesEnableIf,delete e.width,delete e.minWidth,delete e.maxWidth},e.deleteRandomProperties=function(e){["choicesOrder","rowsOrder"].forEach((function(t){"random"===e[t]&&delete e[t]}))},e.updateQuestionJson=function(t){t.storeOthersAsComment=!1,delete t.valuePropertyName,e.deleteConditionProperties(t),e.deleteRandomProperties(t),e.deleteConditionPropertiesFromArray(t.choices),e.deleteConditionPropertiesFromArray(t.rows),e.deleteConditionPropertiesFromArray(t.columns),e.deleteConditionPropertiesFromArray(t.rates)},e.deleteConditionPropertiesFromArray=function(t){Array.isArray(t)&&t.forEach((function(t){e.deleteConditionProperties(t)}))},e.convertMatrixRowsToText=function(e){return e.filter((function(e){return!e.cells[0].hasError})).map((function(e){return e.cells.map((function(e){return e.value||""})).join(o.ItemValue.Separator).replace(/\|$/,"")})).join("\n")},e.convertItemValuesToText=function(e){var t="";return e.forEach((function(e){t&&(t+="\n"),t+=e.value,e.pureText&&(t+=o.ItemValue.Separator+e.pureText)})),t},e.convertTextToItemValues=function(e,t,i){var n=[];if(!e)return n;for(var r=e.split("\n"),a=0;a<r.length;a++)if(r[a]){var s=r[a].split(o.ItemValue.Separator),l=o.Serializer.createClass(i);t.forEach((function(e,t){l[e.name]=s[t]})),n.push(l)}return n},e.sortItems=function(e,t){void 0===t&&(t="text");var o=function(e,t){for(var o="";t<e.length&&e[t]>="0"&&e[t]<="9";)o+=e[t],t++;return parseFloat(o)};e.sort((function(e,i){for(var n=e[t]?e[t]:"",r=i[t]?i[t]:"",a=0;a<n.length&&a<r.length&&n[a]===r[a];)a++;if(a<n.length&&a<r.length){for(;a>0&&n[a-1]>="0"&&n[a-1]<="9";)a--;var s=o(n,a),l=o(r,a);if(s<l)return-1;if(s>l)return 1}return n.localeCompare(r)}))},e.getQuestionContextIndexInfo=function(e,t){void 0===t&&(t="");for(var o=["row","panel"],i=0;i<o.length;i++){var n=t+o[i]+".",r=e.indexOf(n);if(r>-1)return{index:r,name:n}}},e.isSupportCellEditor=function(e){for(var t=["selectbase","boolean","rating"],i=0;i<t.length;i++)if(o.Serializer.isDescendantOf(e,t[i]))return!0;return!1},e.getElementDeepLength=function(e){for(var t=0;e;)e.isPanel&&t++,e=e.parent;return t},e}(),te=function(e){function t(t){var o=e.call(this)||this;return o.setDesignMode(!0),o.fromJSON(t),o}return K(t,e),t}(o.SurveyModel),oe=function(){function e(){}return e.prototype.getCorrectAt=function(e,t,o){return t},Object.defineProperty(e.prototype,"isFixable",{get:function(){return!1},enumerable:!1,configurable:!0}),e.prototype.fixError=function(e,t,o){return e},e}(),ie=function(){function e(e,t){this.at=e,this.text=t,this.rowAt=-1,this.columnAt=-1}return Object.defineProperty(e.prototype,"isFixable",{get:function(){return this.fixer.isFixable},enumerable:!1,configurable:!0}),e.prototype.fixError=function(e){return e},Object.defineProperty(e.prototype,"fixer",{get:function(){return this.fixerValue||(this.fixerValue=this.createFixer()),this.fixerValue},enumerable:!1,configurable:!0}),e.prototype.createFixer=function(){return new oe},e}(),ne=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getErrorType=function(){return"parseerror"},t}(ie),re=function(e){function t(t,o){var i=e.call(this)||this;return i.element=t,i.jsonObj=o,i}return K(t,e),t.prototype.getNewIndex=function(e,t,o,i){var n=e.indexOf(t,o);return n>-1&&(i<0||n<i)?n:-1},t.prototype.fixError=function(e,t,o){var i=e.substring(t,o+1),n=JSON.parse(i);return this.updatedJsonObjOnFix(n),this.replaceJson(e,t,o,n)},t.prototype.updatedJsonObjOnFix=function(e){},t.prototype.replaceJson=function(e,t,o,n){var r=JSON.stringify(n,null,i.jsonEditor.indentation);return r=this.addLeftIndentIntoContent(e,r,t-1),e.substring(0,t)+r+e.substring(o+1)},t.prototype.addLeftIndentIntoContent=function(e,t,o){if(o<=0)return t;for(var i="";o>0&&(" "===e[o]||"\t"===e[o]);)i+=e[o],o--;if(!i)return t;for(var n=t.split("\n"),r=1;r<n.length;r++)n[r]=i+n[r];return n.join("\n")},t}(oe),ae=function(e){function t(t,o,i){var n=e.call(this,t,o)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),t.prototype.getCorrectAt=function(e,t,o){return this.propertyName?this.getNewIndex(e,this.propertyName,t,o):t},t}(re),se=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.updatedJsonObjOnFix=function(e){var t=e[this.propertyName];t&&!Array.isArray(t)&&(e[this.propertyName]=[t])},t}(ae),le=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return!0},enumerable:!1,configurable:!0}),t.prototype.getCorrectAt=function(e,t,o){var i=this.getNewIndex(e,"name:",t,o);return i>t?i:this.getNewIndex(e,'"name":',t,o)},t.prototype.updatedJsonObjOnFix=function(e){e.name=ee.getNewElementName(this.element)},t}(re),ue=function(e){function t(t,o,i){var n=e.call(this,t,o)||this;return n.element=t,n.jsonObj=o,n.propertyName=i,n}return K(t,e),Object.defineProperty(t.prototype,"isFixable",{get:function(){return"name"===this.propertyName},enumerable:!1,configurable:!0}),t.prototype.updatedJsonObjOnFix=function(e){var t=this.element.name;t||(t=ee.getNewElementName(this.element)),e.name=t},t}(re),pe=function(e){function t(t){var o=e.call(this,t.at,t.getFullDescription())||this;return o.elementStart=t.at,o.elementEnd=t.end,o.element=t.element,o.errorType=t.type,o.propertyName=t.propertyName,o.jsonObj=t.jsonObj,o}return K(t,e),t.prototype.createFixer=function(){return"unknownproperty"===this.errorType?new ae(this.element,this.jsonObj,this.propertyName):"arrayproperty"===this.errorType?new se(this.element,this.jsonObj,this.propertyName):"duplicatename"===this.errorType?new le(this.element,this.jsonObj):"requiredproperty"===this.errorType?new ue(this.element,this.jsonObj,this.propertyName):e.prototype.createFixer.call(this)},t.prototype.getErrorType=function(){return this.errorType},Object.defineProperty(t.prototype,"isFixable",{get:function(){return this.fixer.isFixable&&this.elementStart>-1&&this.elementEnd>this.elementStart},enumerable:!1,configurable:!0}),t.prototype.correctAt=function(e){var t=this.fixer.getCorrectAt(e,this.at,this.elementEnd);t>-1&&(this.at=t)},t.prototype.fixError=function(e){return this.fixer.fixError(e,this.elementStart,this.elementEnd)},t}(ie),ce=function(){function e(e){this.text=e,this.text&&""!=this.text.trim()||(this.text="{}"),this.errors=[],this.process()}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isJsonCorrect",{get:function(){return!!this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isJsonHasErrors",{get:function(){return this.errors.length>0||!this.isJsonCorrect},enumerable:!1,configurable:!0}),e.prototype.process=function(){var e=this;try{this.jsonValue=new X(1).parse(this.text)}catch(i){this.errors.push(new ne(i.at,i.message))}if(null!=this.jsonValue){this.updateJsonPositions(this.jsonValue),this.surveyValue=new te(this.jsonValue);var t=this.surveyValue.jsonErrors;if(Array.isArray(t))for(var o=0;o<t.length;o++){var i=new pe(t[o]);i.correctAt(this.text),this.errors.push(i)}this.getDuplicatedNamesErrors().forEach((function(t){return e.errors.push(t)}))}this.setErrorsPositionByChartAt()},e.prototype.updateJsonPositions=function(e){for(var t in e.pos.self=e,e){var o=e[t];o&&o.pos&&(e.pos[t]=o.pos,this.updateJsonPositions(o))}},e.prototype.setErrorsPositionByChartAt=function(){if(0!==this.errors.length){this.errors.sort((function(e,t){return e.at>t.at?1:e.at<t.at?-1:0}));for(var e={row:0,column:0},t=0,o=0;o<this.errors.length;o++){var i=this.errors[o].at;e=this.getPostionByChartAt(e,t,i);var n=this.errors[o];i==n.at&&(n.columnAt=e.column,n.rowAt=e.row),t=i}}},e.prototype.getPostionByChartAt=function(t,o,i){for(var n={row:t.row,column:t.column},r=o;r<i;)this.text.charAt(r)==e.newLineChar?(n.row++,n.column=0):n.column++,r++;return n},e.prototype.getDuplicatedNamesErrors=function(){var e=this,t=[];return this.getDuplicatedElements().forEach((function(o){var i=new pe(e.createDuplicatedError(o));i.correctAt(e.text),i&&t.push(i)})),t},e.prototype.getDuplicatedElements=function(){var e=this,t=[],o={};return this.survey.pages.forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),ee.getAllElements(this.survey,!0).forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),ee.getAllElements(this.survey,!1).forEach((function(i){return e.checkDuplicatedElement(i,o,t)})),t},e.prototype.checkDuplicatedElement=function(e,t,o){var i=e.name;t[i]?o.push(e):t[i]=!0},e.prototype.createDuplicatedError=function(e){var t=e.pos;if(t){var i=new o.JsonError("duplicatename","The name: '"+e.name+"' is duplicated.");return i.at=t.start,i.end=t.end,i.element=e,i}},e.newLineChar="\n",e}(),de=function(e){function t(t){var o=e.call(this,"duplicatename","The name: '"+t.name+"' is duplicated.")||this;return o.element=t,o}return K(t,e),t}(o.JsonError),he=function(e){function t(){var t=e.call(this)||this;return t.searchActionBar=new o.ActionContainer,t.initActionBar(),t}return K(t,e),t.prototype.getSearchActions=function(){var e=this;return[new o.Action({id:"svd-grid-search-close",iconName:"icon-clear_16x16",component:"sv-action-bar-item",title:Z("ed.clear"),showTitle:!1,iconSize:16,disableTabStop:!0,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return!!e.filterString})),action:function(){e.clearFilterString()}})]},t.prototype.initActionBar=function(){this.searchActionBar.setItems(this.getSearchActions())},t.prototype.clearFilterString=function(){this.filterString=""},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"filterString"===t&&this.setFiterString(i,o)},t.prototype.dispose=function(){this.searchActionBar.dispose(),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"filterString",void 0),J([(0,o.property)()],t.prototype,"isVisible",void 0),J([(0,o.property)()],t.prototype,"matchCounterText",void 0),t}(o.Base),ge=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.filterStringPlaceholder=Z("ed.toolboxFilteredTextPlaceholder"),t}return K(t,e),t.prototype.setFiterString=function(e,t){this.toolbox.showSeparators=!e,this.toolbox.items.forEach((function(t){return t.visible=t.hasText(e)})),this.toolbox.showPlaceholder=!this.toolbox.items.filter((function(e){return e.visible})).length,this.toolbox.categories.forEach((function(t){t.forceExpand=!!e,t.empty=0==t.items.filter((function(e){return e.visible})).length}))},t.prototype.clearFilterString=function(){this.filterString="",this.toolbox.rootElement.querySelector("input").focus()},J([(0,o.property)()],t.prototype,"toolbox",void 0),t}(he),me=function(e){function t(){var t=e.call(this)||this;return t.highlightedEditorClass=" spg-editor--highlighted",t.filterStringPlaceholder=Z("ed.propertyGridFilteredTextPlaceholder"),t.propertyGridNoResultsFound=Z("ed.propertyGridNoResultsFound"),t.initActionBar(),t}return K(t,e),t.prototype.expandAllParents=function(e){e&&(e.page&&e.survey&&(e.survey.currentPage=e.page),e.isCollapsed&&e.expand(!1),this.expandAllParents(e.parent),this.expandAllParents(e.parentQuestion))},t.prototype.switchHighlightedEditor=function(e){var t=this;this.currentMatchIndex=e;var o=this.currentMatch;this.currentMatch=this.allMatches[e],null==o||o.updateElementCss(),this.currentMatch&&o!==this.currentMatch&&(this.currentMatch.updateElementCss(),this.expandAllParents(this.currentMatch),setTimeout((function(){L(t.currentMatch.id)}),10)),this.updatedMatchCounterText(e)},t.prototype.updatedMatchCounterText=function(e){var t=this.allMatches.length;if(1===t)this.matchCounterText="";else if(this.currentMatch){var o=e+1;this.matchCounterText=[o,t].join("/")}else this.matchCounterText=this.filterString?this.propertyGridNoResultsFound:""},t.prototype.navigateToEditor=function(e){e<0&&(e=this.allMatches.length-1),e>=this.allMatches.length&&(e=0),this.switchHighlightedEditor(e)},t.prototype.getAllMatches=function(e){var t=o.settings.comparator.normalizeTextCallback,i=t(e,"search");return i=i.toLocaleLowerCase().trim(),this.survey.getAllQuestions().filter((function(e){return e.isVisible})).filter((function(e){var o=e.name+"|"+e.title+"|"+e.description;return o&&(o=(o=t(o,"search")).toLocaleLowerCase().trim()),-1!==o.indexOf(i)}))},t.prototype.setFiterString=function(e,t){if(e)if(this.allMatches=this.getAllMatches(e),0!==this.allMatches.length){var o=this.allMatches.indexOf(this.currentMatch);this.switchHighlightedEditor(-1===o?0:o)}else this.reset();else this.reset()},t.prototype.reset=function(){this.allMatches=[],this.currentMatchIndex=-1;var e=this.currentMatch;this.currentMatch=void 0,null==e||e.updateElementCss(),this.updatedMatchCounterText(-1)},t.prototype.getSearchActions=function(){var t=this,i=e.prototype.getSearchActions.call(this);return i.unshift(new o.Action({id:"svd-grid-search-next",iconName:"icon-next_16x16",component:"sv-action-bar-item",title:Z("ed.nextFocus"),showTitle:!1,iconSize:16,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return t.allMatches.length>1})),action:function(){t.allMatches.length>0&&t.navigateToEditor(t.currentMatchIndex+1)}})),i.unshift(new o.Action({id:"svd-grid-search-prev",iconName:"icon-previous_16x16",component:"sv-action-bar-item",title:Z("ed.prevFocus"),showTitle:!1,iconSize:16,innerCss:"spg-search-editor_bar-item",visible:new o.ComputedUpdater((function(){return t.allMatches.length>1})),action:function(){t.allMatches.length>0&&t.navigateToEditor(t.currentMatchIndex-1)}})),i},t.prototype.setSurvey=function(e){if(this.clearFilterString(),this.survey=e,this.survey){var t=this;this.survey.onUpdateQuestionCssClasses.add((function(e,o){var i=o.cssClasses;o.question===t.currentMatch&&(i.mainRoot+=t.highlightedEditorClass)}))}},J([(0,o.property)()],t.prototype,"survey",void 0),J([(0,o.property)()],t.prototype,"isVisible",void 0),J([(0,o.property)({defaultValue:[]})],t.prototype,"allMatches",void 0),t}(he),fe=function(e){function t(t){var o=e.call(this)||this;return o.toolbox=t,o}return K(t,e),Object.defineProperty(t.prototype,"collapsed",{get:function(){return!this.forceExpand&&this.collapsedValue},set:function(e){this.collapsedValue=e},enumerable:!1,configurable:!0}),t.prototype.toggleState=function(){this.toolbox&&this.toolbox.toggleCategoryState(this.name)},J([(0,o.property)()],t.prototype,"name",void 0),J([(0,o.property)()],t.prototype,"title",void 0),J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"collapsedValue",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"forceExpand",void 0),J([(0,o.property)()],t.prototype,"empty",void 0),t}(o.Base),ye=function(e){function t(t){var i=e.call(this,t)||this;i.item=t,i.id||(i.id=i.name);var n=i.css;return i.css=new o.ComputedUpdater((function(){var e;return(new o.CssClassBuilder).append("svc-toolbox__tool").append("svc-toolbox__tool--action").append(n).append("svc-toolbox__tool--pressed",i.isPressed).append("svc-toolbox__tool--has-icon",!!i.iconName).append("svc-toolbox__tool--has-subitems",!!((null===(e=i.items)||void 0===e?void 0:e.length)>0)).append("svc-toolbox__tool--disabled",!1===i.enabled).append("sv-action--hidden",!i.isVisible).toString()})),i}return K(t,e),t.getItemClassNames=function(e){return(new o.CssClassBuilder).append("svc-toolbox__item").append("svc-toolbox__item--has-icon",!!e).append("svc-toolbox__item--"+e,!!e).toString()},Object.defineProperty(t.prototype,"title",{get:function(){return this.getTitle()},set:function(e){this.setTitle(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enabled",{get:function(){return this.getEnabled()},set:function(e){this.setEnabled(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderedCss",{get:function(){return(new o.CssClassBuilder).append("svc-toolbox__item").append(this.className).append("svc-toolbox__item--has-subitems",this.hasSubItems).toString()},enumerable:!1,configurable:!0}),t.prototype.toJSON=function(){return this.item},Object.defineProperty(t.prototype,"typeName",{get:function(){return this.json&&this.json.type?this.json.type:this.name},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPanel",{get:function(){var e=this.typeName;return!!e&&o.Serializer.isDescendantOf(e,"panelbase")},enumerable:!1,configurable:!0}),t.prototype.getArea=function(e){return e.closest("#scrollableDiv-designer")},t.prototype.hasText=function(e){if(e){var t=e.toLowerCase();return this.title.toLowerCase().indexOf(t)>=0||this.name.toLowerCase().indexOf(t)>=0}},t.prototype.getSubitemByName=function(e){var t;return null===(t=this.items)||void 0===t?void 0:t.filter((function(t){return t.id===e}))[0]},t.prototype.addSubitems=function(e){!e||e.length<1||(this.setSubItems({items:e}),this.component=ve.defaultItemGroupComponent)},t.prototype.clearSubitems=function(){this.hasSubItems&&(this.items=[],this.component="",this.popupModel.dispose())},t.prototype.addSubitem=function(e,i){if(void 0===i&&(i=-1),e){var n=new t(e);n.iconName="",n.className||(n.className=t.getItemClassNames(n.iconName)),n.className=(new o.CssClassBuilder).append(n.className).append("svc-toolbox__item-subtype").toString();var r=(this.items||[]).slice();-1===i?r.push(n):r.splice(i,0,n),this.addSubitems(r)}},t.prototype.removeSubitem=function(e){if(this.hasSubItems&&e){var t=(null==e?void 0:e.id)||e;if(t){var o=this.getSubitemByName(t),i=(this.items||[]).slice(),n=i.indexOf(o);n>-1&&i.splice(n,1),0==i.length?this.clearSubitems():this.addSubitems(i)}}},Object.defineProperty(t.prototype,"subitemsButtonIcon",{get:function(){return"icon-next_16x16"},enumerable:!1,configurable:!0}),t}(o.Action),ve=function(e){function t(t,i,n){void 0===t&&(t=null),void 0===i&&(i=null),void 0===n&&(n=!1);var r=e.call(this)||this;return r.supportedQuestions=t,r.creator=i,r._orderedQuestions=["radiogroup","rating","checkbox","dropdown","tagbox","boolean","file","imagepicker","ranking","text","comment","multipletext","panel","paneldynamic","matrix","matrixdropdown","matrixdynamic","html","expression","image","signaturepad"],r.copiedItemMaxCount=3,r.allowExpandMultipleCategoriesValue=!1,r.keepAllCategoriesExpandedValue=!1,r.toolboxNoResultsFound=Z("ed.toolboxNoResultsFound"),r.categoriesTitles={},r.searchManager=new ge,r.subItemsShowDelay=0,r.searchManager.isVisible=r.searchEnabled,r.searchManager.toolbox=r,r.searchItem=new o.Action({id:"searchItem-id",css:"svc-toolbox__tool svc-toolbox__search-button",innerCss:"sv-dots__item",iconName:"icon-search",component:"sv-action-bar-item",tooltip:o.surveyLocalization.getString("search"),action:function(){r.rootElement.querySelector("input").focus(),r.isFocused=!0}}),r.updateResponsiveness(r.isCompact,r.overflowBehavior),r.createDefaultItems(t,n),r.initDotsItem(),r}return K(t,e),Object.defineProperty(t.prototype,"itemSelector",{get:function(){return".svc-toolbox__category>.svc-toolbox__tool--action"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerSelector",{get:function(){return".svc-toolbox__scroller"},enumerable:!1,configurable:!0}),t.getQuestionDefaultSettings=function(e){if(i.toolbox&&i.toolbox.defaultJSON)return i.toolbox.defaultJSON[e]},t.getSubTypePropertyName=function(e){var t="";return"text"===e&&(t="inputType"),"rating"===e&&(t="rateType"),t},Object.defineProperty(t.prototype,"orderedQuestions",{get:function(){return this._orderedQuestions},set:function(e){this._orderedQuestions=e,this.reorderItems()},enumerable:!1,configurable:!0}),t.prototype.updateResponsiveness=function(e,t){if("scroll"==t&&this.creator&&!this.creator.isTouch||this.creator&&"sidebar"===this.creator.toolboxLocation)return this.isResponsivenessDisabled=!0,void(this.updateCallback&&this.updateCallback(!0));this.hasCategories&&this.showCategoryTitles?e?(this.isResponsivenessDisabled=!1,this.raiseUpdate(!0)):(this.isResponsivenessDisabled=!0,this.setActionsMode("large")):(this.isResponsivenessDisabled=!1,this.raiseUpdate(!0))},t.prototype.initDotsItem=function(){var e=this;this.dotsItem.innerCss="svc-toolbox__item svc-toolbox__item--dots sv-dots__item",this.dotsItem.css=new o.ComputedUpdater((function(){return(new o.CssClassBuilder).append("svc-toolbox__tool svc-toolbox__tool--dots").append("sv-action--hidden",!e.dotsItem.isVisible).toString()})),this.dotsItem.popupModel.horizontalPosition="right",this.dotsItem.popupModel.verticalPosition="top",this.dragOrClickHelper=new o.DragOrClickHelper((function(t,o,i){var n,r=e.creator.getJSONForNewElement(i.json);e.dotsItem.popupModel.hide(),null===(n=e.creator)||void 0===n||n.onDragDropItemStart(),e.dragDropHelper.startDragToolboxItem(t,r,i)})),this.hiddenItemsListModel.onPointerDown=function(t,o){e.creator.readOnly||e.dragOrClickHelper.onPointerDown(t,o)},this.dotsItem.popupModel.cssClass="svc-toolbox-popup"},t.prototype.getDefaultQuestionCategories=function(){var e=this,o={};return Object.keys(t.defaultCategories).forEach((function(i){t.defaultCategories[i].forEach((function(t){e.supportedQuestions&&-1==e.supportedQuestions.indexOf(t)||(o[t]=i)}))})),o},t.prototype.getCategoryTitle=function(e){return this.categoriesTitles[e]?this.categoriesTitles[e]:Z("toolboxCategories."+e)},t.prototype.onActiveCategoryChanged=function(e){for(var t=this.categories,o=0;o<t.length;o++){var i=t[o];i.collapsed=i.name!==e}},Object.defineProperty(t.prototype,"isCompactRendered",{get:function(){return this.isCompact&&!this.isFocused},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSearch",{get:function(){return this.searchEnabled&&this.items.length>t.MINELEMENTCOUNT},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showInSingleCategory",{get:function(){return this.isCompactRendered||1==this.categories.length||!this.showCategoryTitles},enumerable:!1,configurable:!0}),t.prototype.setRootElement=function(e){var t=this;this._rootElementValue=e,this._containerElementValue=null==e?void 0:e.querySelector(this.containerSelector),this._scrollbarElement=null==e?void 0:e.querySelector(".svc-toolbox__scrollbar"),this._scrollbarSizerElement=null==e?void 0:e.querySelector(".svc-toolbox__scrollbar-sizer"),this._containerBodyElement=null==e?void 0:e.querySelector(".svc-toolbox__container"),e&&(this._containerBodyResizeObserver=new ResizeObserver((function(e){for(var o=0,i=e;o<i.length;o++){var n=i[o],r=n.contentBoxSize?n.contentBoxSize[0].blockSize:n.contentRect.width;t._scrollbarSizerElement.style.height=r+"px"}})),this._containerBodyResizeObserver.observe(this._containerBodyElement))},t.prototype.unsubscribeRootElement=function(){this._containerBodyResizeObserver&&(this._containerBodyResizeObserver.disconnect(),this._containerBodyResizeObserver=void 0)},Object.defineProperty(t.prototype,"containerElement",{get:function(){return this._containerElementValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"rootElement",{get:function(){return this._rootElementValue},enumerable:!1,configurable:!0}),t.prototype.focusOut=function(e){e.relatedTarget===e.currentTarget||e.currentTarget.contains(e.relatedTarget)||(this.isFocused=!1,this.searchManager.filterString="")},Object.defineProperty(t.prototype,"classNames",{get:function(){return(new o.CssClassBuilder).append("svc-toolbox").append("svc-toolbox--searchable",this.searchEnabled).append("svc-toolbox--no-separators",!this.showSeparators).append("svc-toolbox--compact",this.isCompactRendered).append("svc-toolbox--flyout",this.isCompact&&this.isFocused).append("svc-toolbox--scrollable","scroll"==this.overflowBehavior).toString()},enumerable:!1,configurable:!0}),t.prototype.setLocation=function(e){"sidebar"===e?this.visibleActions.forEach((function(e){return e.mode="small"})):this.dotsItem.popupModel.horizontalPosition="right"==this.creator.toolboxLocation?"left":"right",this.updateResponsiveness(this.isCompact,this.overflowBehavior)},Object.defineProperty(t.prototype,"jsonText",{get:function(){return JSON.stringify(this.actions)},set:function(e){this.actions=(e?JSON.parse(e):[]).map((function(e){return new ye(e)})),this.onItemsChanged()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copiedJsonText",{get:function(){return JSON.stringify(this.copiedItems)},set:function(e){var t=e?JSON.parse(e):[];this.clearCopiedItems();for(var o=0;o<t.length;o++)t[o].isCopied=!0,this.addItem(t[o])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"items",{get:function(){return this.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemNames",{get:function(){for(var e=[],t=0;t<this.items.length;t++)e.push(this.items[t].typeName);return e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"copiedItems",{get:function(){for(var e=[],t=0;t<this.actions.length;t++)this.actions[t].isCopied&&e.push(this.actions[t]);return e},enumerable:!1,configurable:!0}),t.prototype.addItems=function(e,t){void 0===t&&(t=!1),t&&this.clearItems();for(var o=0;o<e.length;o++)this.actions.push(this.getOrCreateToolboxItem(e[o]));this.onItemsChanged()},t.prototype.addCopiedItem=function(e,o){void 0===o&&(o=null),o||(o={});var i=o.name?o.name:e.name,n=o.title?o.title:i,r=o.tooltip?o.tooltip:n,a=o.iconName?o.iconName:t.defaultIconName,s={id:i,name:i,title:n,tooltip:r,className:ye.getItemClassNames(a),isCopied:!1!==o.isCopied,iconName:a,json:o.json?o.json:this.getQuestionJSON(e),category:o.category?o.category:""};if(!this.replaceItem(s)){var l=this.copiedItems;this.copiedItemMaxCount>0&&l.length==this.copiedItemMaxCount&&this.removeItem(l[this.copiedItemMaxCount-1].name),this.addItem(s)}},t.prototype.getOrCreateToolboxItem=function(e){if(e instanceof ye)return e;e.iconName=e.iconName?e.iconName:t.defaultIconName;var o=new ye(e),i=this.createSubTypes(o);return i&&o.addSubitems(i),o},t.prototype.createSubTypes=function(e){var i=null,n=t.getSubTypePropertyName(e.id);if(n&&(i=o.Serializer.findProperty(e.id,n)),i&&i.visible)return i.choices.map((function(o){var i=W({},e.json);i[n]=o;var r=e.id!=o?o:e.id+"-default";return new ye({id:r,name:r,title:G.getPropertyValueInEditor(n,o),className:ye.getItemClassNames()+" svc-toolbox__item-subtype",json:i,iconName:null,category:null,isCopied:!1,component:t.defaultItemComponent})}))},t.prototype.addItem=function(e,t){this.correctItem(e);var o=this.getOrCreateToolboxItem(e);void 0===t?this.actions.push(o):this.actions.splice(t,0,o),this.onItemsChanged()},t.prototype.correctItem=function(e){e.title||(e.title=e.name),e.tooltip||(e.tooltip=e.title)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t.prototype.replaceItem=function(e){this.correctItem(e);var t=this.indexOf(e.name);if(!(t<0))return this.actions[t]=this.getOrCreateToolboxItem(e),this.onItemsChanged(),!0},t.prototype.removeItem=function(e){var t=this.indexOf(e);return!(t<0||(this.actions.splice(t,1),this.onItemsChanged(),0))},t.prototype.clearItems=function(){this.actions=[],this.onItemsChanged()},t.prototype.clearCopiedItems=function(){for(var e=this.copiedItems,t=0;t<e.length;t++)this.removeItem(e[t].name)},t.prototype.getItemByName=function(e){if(!e)return null;var t=this.indexOf(e);return t>-1?this.actions[t]:null},Object.defineProperty(t.prototype,"allowExpandMultipleCategories",{get:function(){return this.allowExpandMultipleCategoriesValue},set:function(e){this.allowExpandMultipleCategoriesValue=e,this.updateCategoriesState()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"keepAllCategoriesExpanded",{get:function(){return this.keepAllCategoriesExpandedValue||!this.showCategoryTitlesValue},set:function(e){this.keepAllCategoriesExpandedValue=e,this.canCollapseCategories=!this.keepAllCategoriesExpanded,this.updateCategoriesState()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showCategoryTitles",{get:function(){return this.showCategoryTitlesValue},set:function(e){this.showCategoryTitlesValue=e,this.updateCategoriesState()},enumerable:!1,configurable:!0}),t.prototype.updateTitles=function(){var e=this;this.actions.forEach((function(t){e.updateActionTitle(t),e.updateActionTitle(t.innerItem)})),Array.isArray(this.categories)&&this.categories.forEach((function(t){t.title=e.getCategoryTitle(t.name)}))},t.prototype.updateActionTitle=function(e){var t=G.getString("qt."+e.id);t&&t!==e.id&&(e.title=t,e.tooltip=t)},t.prototype.updateCategoriesState=function(){this.allowExpandMultipleCategories||this.keepAllCategoriesExpanded?(this.activeCategory="",this.keepAllCategoriesExpandedValue&&this.expandAllCategories()):this.categories.length>0&&(this.activeCategory=this.categories[0].name)},t.prototype.changeCategory=function(e,t){this.changeCategories([{name:e,category:t}])},t.prototype.changeCategories=function(e){for(var t=0;t<e.length;t++){var o=e[t],i=this.getItemByName(o.name);i&&(i.category=o.category)}this.onItemsChanged()},t.prototype.defineCategories=function(e,t){var o=this;if(void 0===t&&(t=!1),Array.isArray(e)){var i=this.getDefaultItems(this.supportedQuestions,!1,!0,!0),n={};i.forEach((function(e){e.visible=!1,n[e.id]=e})),Array.isArray(this.presetDefaultItems)&&this.presetDefaultItems.forEach((function(e){var t=n[e.name];if(t)for(var o in e)t[o]=e[o];else if(e.json){var r=new ye(e);n[r.id]=r,i.push(r)}})),this.categoriesTitles={};var r=new Array;e.forEach((function(e){e.category&&e.title&&(o.categoriesTitles[e.category]=e.title),Array.isArray(e.items)&&e.items.forEach((function(t){var o=void 0,i=void 0;"string"==typeof t?o=t:(o=t.name,i=t.title);var a=n[o];a&&(a.category=e.category,a.visible=!0,i&&(a.title=i),r.push(a))}))})),t&&i.forEach((function(e){e.visible||(e.visible=!0,e.category="misc",r.push(e))})),this.setItems(r),this.onItemsChanged(!1)}},t.prototype.removeCategories=function(){var e=o.ElementFactory.Instance.getAllToolboxTypes();this.changeCategories(e.map((function(e){return{name:e,category:null}}))),this.onItemsChanged()},t.prototype.toggleCategoryState=function(e){if(!this.keepAllCategoriesExpanded)if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!t.collapsed)}else this.activeCategory=e},t.prototype.expandCategory=function(e){if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!1)}else this.canCollapseCategories&&(this.activeCategory=e)},t.prototype.collapseCategory=function(e){if(this.allowExpandMultipleCategories){var t=this.getCategoryByName(e);t&&(t.collapsed=!0)}},t.prototype.expandAllCategories=function(){this.expandCollapseAllCategories(!1)},t.prototype.collapseAllCategories=function(){this.expandCollapseAllCategories(!0)},t.prototype.expandCollapseAllCategories=function(e){for(var t=this.categories,o=0;o<t.length;o++)t[o].collapsed=e},t.prototype.getCategoryByName=function(e){for(var t=this.categories,o=0;o<t.length;o++){var i=t[o];if(i.name===e)return i}return null},t.prototype.onItemsChanged=function(e){var t=this;void 0===e&&(e=!0);for(var o=new Array,i={},n=this.activeCategory,r=function(e){var r=a.actions[e];if(r.innerItem.action=function(){t.creator.clickToolboxItem(r.json)},!1===r.visible)return"continue";var s=r.category?r.category:"general";if(!i[s]){var l=a.createCategory();l.name=s,l.title=a.getCategoryTitle(s),l.collapsed=s!==n&&!a.keepAllCategoriesExpanded,i[s]=l,o.push(l)}i[s].items.push(r)},a=this,s=0;s<this.actions.length;s++)r(s);if(this.categories=o,this.keepAllCategoriesExpanded||(this.allowExpandMultipleCategories?o.length>0&&(o[0].collapsed=!1):n&&i[n]?this.activeCategory=n:this.activeCategory=o.length>0?o[0].name:""),e){var l=[];this.categories.forEach((function(e){l=l.concat(e.items)})),this.actions=l}this.hasCategories=o.length>1,this.updateItemSeparators(),this.updateResponsiveness(this.isCompact,this.overflowBehavior)},t.prototype.createCategory=function(){return new fe(this)},t.prototype.indexOf=function(e){for(var t=0;t<this.actions.length;t++)if(this.actions[t].name==e)return t;return-1},t.prototype.updateItemSeparators=function(){(this.hasCategories?this.categories:[{items:this.actions}]).forEach((function(e,t){(e.items||[]).forEach((function(e,o){e.needSeparator=0!==t&&0==o,e.innerItem&&(e.innerItem.needSeparator=e.needSeparator)}))}))},t.prototype.reorderItems=function(){var e=this;this.actions.sort((function(t,o){var i=e._orderedQuestions.indexOf(t.name);-1===i&&(i=Number.MAX_VALUE);var n=e._orderedQuestions.indexOf(o.name);return-1===n&&(n=Number.MAX_VALUE),i-n})),this.onItemsChanged()},t.prototype.createDefaultItems=function(e,t){var o=this;e=e||this.supportedQuestions,this.clearItems(),this.getDefaultItems(e,t,!0,!0).forEach((function(e){return o.addToolBoxItem(e,o.actions)})),this.onItemsChanged()},t.prototype.getDefaultItems=function(e,t,o,i){var n=this.getDefaultQuestionItems(e,t);return o&&(n=n.concat(this.getRegisterCustomWidgets())),i&&(n=n.concat(this.getRegisterComponentQuestions())),n},t.prototype.getDefaultQuestionItems=function(e,t){for(var i=[],n=this.getQuestionTypes(e),r=t?this.getDefaultQuestionCategories():{},a=0;a<n.length;a++){var s=n[a],l=o.ElementFactory.Instance.createElement(s,"q1");l||(l=o.Serializer.createClass(s));var u=this.getQuestionJSON(l);delete u.name;var p=G.getString("qt."+s),c="icon-"+s,d={id:s,name:s,iconName:c,title:p,tooltip:p,className:ye.getItemClassNames(c),json:u,isCopied:!1,category:r[s]||""};i.push(this.getOrCreateToolboxItem(d))}return i},t.prototype.getRegisterComponentQuestions=function(){var e=this,t=[];return o.ComponentCollection.Instance.items.forEach((function(o){var i=e.createToolboxItemFromJSON(o.json);i&&t.push(i)})),t},t.prototype.getRegisterCustomWidgets=function(){var e=this,t=[];return o.CustomWidgetCollection.Instance.widgets.forEach((function(o){if(o.canShowInToolbox){var i=e.createToolboxItemFromJSON(o.widgetJson);i&&t.push(i)}})),t},t.prototype.addToolBoxItem=function(e,t){if(e){var o=this.getActionByIdFromArray(e.id,t);if(o)t.splice(t.indexOf(o),1,e);else{var i=Array.isArray(this.supportedQuestions)?this.supportedQuestions.indexOf(e.id):-1;i>-1?t.splice(i,0,e):t.push(e)}}},t.prototype.getActionByIdFromArray=function(e,t){for(var o=0;o<t.length;o++)if(t[o].id===e)return t[o]},t.prototype.createToolboxItemFromJSON=function(e){if(!1!==e.showInToolbox&&!0!==e.internal&&e.name){var i=e.iconName?e.iconName:t.defaultIconName,n=G.getString("qt."+e.name);n&&n!=e.name||(n=this.getTitleFromJsonTitle(e.title,e.name)),n||(n=e.name);var r=e.defaultJSON?JSON.parse(JSON.stringify(e.defaultJSON)):{};r.type||(r.type=e.name),delete r.name;var a=e.category?e.category:"",s=new o.Action({id:e.name,name:e.name,iconName:i,title:n,tooltip:n,className:ye.getItemClassNames(i),json:r,isCopied:!1,category:a});return this.getOrCreateToolboxItem(s)}},t.prototype.getTitleFromJsonTitle=function(e,t){if(!e)return e;if("string"==typeof e)return e;if("object"!=typeof e)return e;for(var o in e){var i=G.locales[o];e[o]&&i&&i.qt&&(i.qt[t]=e[o])}return G.getString("qt."+t)},t.prototype.getQuestionJSON=function(e){var i=(new o.JsonObject).toJsonObject(e);i.type=e.getType();var n=t.getQuestionDefaultSettings(i.type);if(n)for(var r in n)i[r]=n[r];return i},t.prototype.isHiddenCustomWidget=function(e){var t=o.CustomWidgetCollection.Instance.getCustomWidgetByName(e);return!!t&&!t.showInToolbox},t.prototype.getQuestionTypes=function(e){var t=o.ElementFactory.Instance.getAllToolboxTypes();e&&0!=e.length||(e=t);for(var i=[],n=0;n<this.orderedQuestions.length;n++){var r=this.orderedQuestions[n];e.indexOf(r)>-1&&t.indexOf(r)>-1&&i.push(r)}for(n=0;n<e.length;n++){var a=e[n];i.indexOf(a)<0&&t.indexOf(a)>-1&&!this.isHiddenCustomWidget(a)&&i.push(a)}return i},t.prototype.hideAllInnerPopups=function(){this.actions.forEach((function(e){e.hidePopup()}))},t.prototype.onScroll=function(e,t){this.hideAllInnerPopups(),this._scrollbarElement.scrollTop=this._containerElementValue.scrollTop},t.prototype.onScrollbarScroll=function(e){this._containerElementValue.scrollTop=this._scrollbarElement.scrollTop},t.MINELEMENTCOUNT=10,t.defaultIconName="icon-default",t.defaultItemComponent="svc-toolbox-item",t.defaultItemGroupComponent="svc-toolbox-item-group",t.defaultCategories={choice:["radiogroup","rating","checkbox","dropdown","tagbox","boolean","file","imagepicker","ranking"],text:["text","comment","multipletext"],containers:["panel","paneldynamic"],matrix:["matrix","matrixdropdown","matrixdynamic"],misc:["html","expression","image","signaturepad"]},J([(0,o.property)({defaultValue:!1})],t.prototype,"showCategoryTitlesValue",void 0),J([(0,o.propertyArray)()],t.prototype,"categories",void 0),J([(0,o.property)({defaultValue:"",onSet:function(e,t){t.onActiveCategoryChanged(e)}})],t.prototype,"activeCategory",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"hasCategories",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"canCollapseCategories",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.updateResponsiveness(e,t.overflowBehavior)}})],t.prototype,"isCompact",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isFocused",void 0),J([(0,o.property)({defaultValue:"scroll",onSet:function(e,t){t.updateResponsiveness(t.isCompact,e)}})],t.prototype,"overflowBehavior",void 0),J([(0,o.property)()],t.prototype,"forceCompact",void 0),J([(0,o.property)({defaultValue:!0,onSet:function(e,t){t.searchManager.isVisible=e}})],t.prototype,"searchEnabled",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showSubitems",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showSeparators",void 0),t}(o.AdaptiveActionContainer),be=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.items=[],o}return K(t,e),Object.defineProperty(t.prototype,"hasPrev",{get:function(){return this.currentIndex>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasNext",{get:function(){var e=this.currentIndex;return e>-1&&e<this.items.length-1},enumerable:!1,configurable:!0}),t.prototype.hasInHistory=function(e){return this.getIndex(e)>-1},t.prototype.prev=function(){this.selectElement(this.currentIndex-1)},t.prototype.next=function(){this.selectElement(this.currentIndex+1)},t.prototype.reset=function(){this.items=[],this.creator.selectedElement&&this.onObjSelected(this.creator.selectedElement)},t.prototype.selectFromAction=function(e,t){var o=this.currentIndex;o>-1&&o<this.items.length&&(this.items[o].propertyName=t),this.creator.selectElement(e)},t.prototype.onObjSelected=function(e){if(!this.isChangingInternally){var t=this.currentIndex;t>-1&&this.items.splice(t,1),this.items.push({obj:e})}},Object.defineProperty(t.prototype,"currentIndex",{get:function(){return this.getIndex(this.creator.selectedElement)},enumerable:!1,configurable:!0}),t.prototype.getIndex=function(e){if(!e)return-1;this.updateItems();for(var t=0;t<this.items.length;t++)if(this.items[t].obj==e)return t;return-1},t.prototype.selectElement=function(e){if(!(e<0||e>=this.items.length)){this.isChangingInternally=!0;var t=this.items[e];this.creator.selectElement(t.obj,t.propertyName),this.isChangingInternally=!1}},t.prototype.updateItems=function(){for(var e=this.items.length-1;e>=0;e--){var t=this.items[e].obj;!t||!t.isDisposed&&t.inSurvey||this.items.splice(e,1)}},t}(o.Base),Ce=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.isJSONChanged=!1,o.isProcessingImmediately=!1,o.jsonEditorChangedTimeoutId=-1,o}return K(t,e),Object.defineProperty(t.prototype,"text",{get:function(){return this.getText()},set:function(e){this.setText(e)},enumerable:!1,configurable:!0}),t.prototype.onEditorActivated=function(){},t.prototype.onPluginActivate=function(){this.text=this.creator.text,this.onEditorActivated(),this.isJSONChanged=!1},t.prototype.onTextChanged=function(){if(-1!==this.jsonEditorChangedTimeoutId&&clearTimeout(this.jsonEditorChangedTimeoutId),this.isProcessingImmediately)this.jsonEditorChangedTimeoutId=-1;else{var e=this;window&&(this.jsonEditorChangedTimeoutId=window.setTimeout((function(){e.jsonEditorChangedTimeoutId=-1,e.processErrors(e.text)}),t.updateTextTimeout))}},Object.defineProperty(t.prototype,"errorList",{get:function(){var e=this;return this.errorListValue||(this.errorListValue=new o.ListModel({items:[],onSelectionChanged:function(t){var o=t.data.error;o&&e.gotoError(o.at,o.rowAt,o.columnAt)},allowSelection:!1,searchEnabled:!1}),this.errorListValue.cssClasses={item:"svc-json-errors__item",itemBody:"svc-json-error",itemsContainer:"svc-json-errors"},this.errorListValue.hasVerticalScroller=!0),this.errorListValue},enumerable:!1,configurable:!0}),t.prototype.setErrors=function(e){var t=e.length>0;if(t){var o=[];this.createErrorActions(e).forEach((function(e){return o.push(e)})),this.errorList.setItems(o)}this.hasErrors=t},t.prototype.gotoError=function(e,t,o){},t.prototype.createErrorActions=function(e){var t=this,i=[],n=1;return e.forEach((function(e){var r=e.rowAt>-1?"Line: "+(e.rowAt+1)+". ":"",a=e.text;a.length>153&&(a=a.substring(0,150)+"..."),a=r+a,e.at,i.push(new o.Action({id:"error_"+n++,component:"json-error-item",title:a,tooltip:e.text,iconName:"icon-error",iconSize:16,data:{error:e,showFixButton:e.isFixable,fixError:function(){t.text=e.fixError(t.text)},fixButtonIcon:"icon-fix",fixButtonTitle:"Fix error"}}))})),i},t.prototype.processErrors=function(e){var t=new ce(e);this.setErrors(t.errors)},Object.defineProperty(t.prototype,"readOnly",{get:function(){return this.creator.readOnly},enumerable:!1,configurable:!0}),t.updateTextTimeout=1e3,J([(0,o.property)()],t.prototype,"hasErrors",void 0),t}(o.Base),we=function(){function e(e){this.creator=e,this.saveToFileHandler=F,this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.exportToFile=function(e){if(this.model){var t=new Blob([this.model.text],{type:"application/json"});this.saveToFileHandler(e,t)}},e.prototype.importFromFile=function(e,t){var o=this,i=new FileReader;i.onload=function(e){var n=i.result;o.model&&(o.model.text=n,o.model.isJSONChanged=!0),t&&t(n)},i.readAsText(e)},e.prototype.copyToClipboard=function(){this.model&&navigator.clipboard.writeText(this.model.text)},e.prototype.createActions=function(){var e=this,t=[];return this.importAction=new o.Action({id:"svc-json-import",iconName:"icon-load",locTitleName:"ed.surveyJsonImportButton",locTooltipName:"ed.surveyJsonImportButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",needSeparator:!0,action:function(){document&&(e.inputFileElement||(e.inputFileElement=document.createElement("input"),e.inputFileElement.type="file",e.inputFileElement.style.display="none",e.inputFileElement.onchange=function(){e.inputFileElement.files.length<1||(e.importFromFile(e.inputFileElement.files[0]),e.inputFileElement.value="")}),e.inputFileElement.click())}}),t.push(this.importAction),this.exportAction=new o.Action({id:"svc-json-export",iconName:"icon-download",locTitleName:"ed.surveyJsonExportButton",locTooltipName:"ed.surveyJsonExportButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",action:function(){e.exportToFile(i.jsonEditor.exportFileName)}}),t.push(this.exportAction),this.copyAction=new o.Action({id:"svc-json-copy",iconName:"icon-copy",locTitleName:"ed.surveyJsonCopyButton",locTooltipName:"ed.surveyJsonCopyButton",visible:new o.ComputedUpdater((function(){return"editor"===e.creator.activeTab})),mode:"small",component:"sv-action-bar-item",action:function(){e.copyToClipboard()}}),t.push(this.copyAction),t},e.prototype.activate=function(){this.model=this.createModel(this.creator)},e.prototype.deactivate=function(){if(this.model){if(!new ce(this.model.text).isJsonCorrect)return!1;!this.model.readOnly&&this.model.isJSONChanged&&(this.creator.selectedElement=void 0,this.creator.text=this.model.text,this.creator.selectedElement=this.creator.survey,this.creator.setModified({type:"JSON_EDITOR"})),this.model.dispose(),this.model=void 0}return!0},e.prototype.defaultAllowingDeactivate=function(){if(!this.model)return!0;var e=new ce(this.model.text);return e.isJsonCorrect?!e.isJsonHasErrors:void 0},e}();r(1497);var xe=function(e){function t(t){var o=e.call(this,t)||this;return o.aceCanUndo=!1,o.aceCanRedo=!1,o}return K(t,e),t.prototype.getText=function(){return this.aceEditor?this.aceEditor.getValue():""},t.prototype.setText=function(e){this.isProcessingImmediately=!0,this.aceEditor.setValue(e),this.aceEditor.renderer.updateFull(!0),this.aceEditor.getSession().getUndoManager().reset(),this.processErrors(e),this.isProcessingImmediately=!1},t.prototype.init=function(e){var o,i;this.aceEditor=e;var n=null===(i=null===(o=window.ace)||void 0===o?void 0:o.define)||void 0===i?void 0:i.modules;if(n&&n["ace/ext/searchbox"]||this.aceEditor.commands.removeCommand("find"),this.aceEditor.setReadOnly(this.readOnly),t.aceBasePath)try{window.ace.config.set("basePath",t.aceBasePath),this.aceEditor.session.setMode("ace/mode/json")}catch(e){}var r=this;this.aceEditor.setShowPrintMargin(!1),this.aceEditor.getSession().on("change",(function(){r.onTextChanged()})),this.aceEditor.getSession().setUseWorker(!0),ce.newLineChar=this.aceEditor.session.doc.getNewLineCharacter(),this.onPluginActivate()},t.prototype.updateUndoRedoState=function(){var e=this.aceEditor.getSession().getUndoManager();this.aceCanUndo=e.hasUndo(),this.aceCanRedo=e.hasRedo(),!0===this.aceEditor.isFocused()&&(this.isJSONChanged=!e.isClean())},t.prototype.onTextChanged=function(){this.updateUndoRedoState(),e.prototype.onTextChanged.call(this)},t.prototype.createAnnotations=function(e){for(var t=[],o=0;o<e.length;o++){var i=e[o],n={row:i.rowAt,column:i.columnAt,text:i.text,type:"error"};t.push(n)}return t},t.prototype.setErrors=function(t){var o=this;e.prototype.setErrors.call(this,t),this.aceEditor.getSession().setAnnotations(this.createAnnotations(t)),setTimeout((function(){return o.aceEditor.resize()}))},t.prototype.gotoError=function(e,t,o){this.aceEditor.focus(),this.aceEditor.renderer.scrollCursorIntoView({row:t+1,column:o+1},.5),this.aceEditor.gotoLine(t+1,o+1)},t.prototype.onEditorActivated=function(){this.aceEditor.getSession().getUndoManager().markClean(),this.updateUndoRedoState(),this.aceEditor.focus()},t.aceBasePath="",J([(0,o.property)()],t.prototype,"aceCanUndo",void 0),J([(0,o.property)()],t.prototype,"aceCanRedo",void 0),t}(Ce),Te=function(e){function t(t){var o=e.call(this,t)||this;return t.addPluginTab("editor",o,void 0,"svc-tab-json-editor-ace"),o}return K(t,e),t.prototype.createModel=function(e){return new xe(e)},t.hasAceEditor=function(){return"undefined"!=typeof window&&void 0!==window.ace},t}(we);r(8380);var Se=function(e){function t(t){var o=e.call(this,t)||this;return o.ariaLabel=Z("tabs.editor"),o.onPluginActivate(),o}return K(t,e),t.prototype.checkKey=function(e,t){if("Tab"===t.key){t.preventDefault();var o=t.target,i=o.selectionStart,n=o.selectionEnd;o.value=o.value.substring(0,i)+"\t"+o.value.substring(n),o.selectionStart=o.selectionEnd=i+1,t.stopPropagation()}return!0},t.prototype.getText=function(){return this._text},t.prototype.setText=function(e){this.isProcessingImmediately=!0,this._text=e,this.processErrors(e),this.isProcessingImmediately=!1},t.prototype.gotoError=function(e,t,o){if(this.textElement){var i=this.textElement;i.selectionStart=e,i.selectionEnd=e,i.focus()}},Object.defineProperty(t.prototype,"errorButtonText",{get:function(){return this.canShowErrors?Z("ed.jsonHideErrors"):Z("ed.jsonShowErrors")},enumerable:!1,configurable:!0}),t.prototype.toggleErrors=function(){this.canShowErrors=!this.canShowErrors},Object.defineProperty(t.prototype,"userFriendlyErrors",{get:function(){if(0===this._errors.length)return[];for(var e=[],t=0;t<this._errors.length-1;t++)e[t]=this._errors[t].text,e[t]+="\n\n";return e[this._errors.length-1]=this._errors[this._errors.length-1].text,e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"errors",{get:function(){return this._errors},enumerable:!1,configurable:!0}),t.prototype.onTextChanged=function(){this.isJSONChanged=!0,e.prototype.onTextChanged.call(this)},t.prototype.setErrors=function(t){this._errors=t,e.prototype.setErrors.call(this,t)},J([(0,o.property)({defaultValue:"",onSet:function(e,t){return t.onTextChanged()}})],t.prototype,"_text",void 0),J([(0,o.propertyArray)()],t.prototype,"_errors",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"canShowErrors",void 0),t}(Ce),Pe=function(e){function t(t){var o=e.call(this,t)||this;return t.addPluginTab("editor",o,void 0,"svc-tab-json-editor-textarea"),o}return K(t,e),t.prototype.createModel=function(e){return new Se(e)},t}(we);r(8538);var Ee=function(e){function t(t){var o=e.call(this)||this;return o.surveyProvider=t,o.activateZoom=function(){document.addEventListener("keydown",o.listenTryToZoom),document.addEventListener("wheel",o.listenTryToZoomWithWheel,{passive:!1})},o.deactivateZoom=function(){document.removeEventListener("keydown",o.listenTryToZoom),document.removeEventListener("wheel",o.listenTryToZoomWithWheel)},o.listenTryToZoomWithWheel=function(e){return o.tryToZoomWithWheel(e,e)},o.listenTryToZoom=function(e){return o.tryToZoom(e,e)},o}return K(t,e),t.prototype.surveyChanged=function(){var e=this,t=this;this.survey.onOpenDropdownMenu.add((function(o,i){if(!e.surveyProvider.isTouch){var n=Ie[t.activeDevice];i.menuType="desktop"===n.deviceType?"dropdown":"tablet"==n.deviceType?"popup":"overlay"}}))},Object.defineProperty(t.prototype,"zoomScale",{get:function(){return this.currZoomScale},enumerable:!1,configurable:!0}),t.prototype.tryToZoomWithWheel=function(e,t){var o=t.deltaY;return(t.ctrlKey||t.metaKey)&&(o<0?this.zoomSimulator("up",t):this.zoomSimulator("down",t)),!0},t.prototype.tryToZoom=function(e,t){return(t.ctrlKey||t.metaKey)&&(107!=t.keyCode&&187!=t.keyCode||this.zoomSimulator("up",t),109!=t.keyCode&&189!=t.keyCode||this.zoomSimulator("down",t),48!=t.keyCode&&96!=t.keyCode||this.zoomSimulator("zero",t)),!0},t.prototype.changeZoomScale=function(e){var t="up"===e?1.01:"down"===e?1/1.01:1;this.currZoomScale="zero"===e?1:this.currZoomScale*t},t.prototype.zoomSimulator=function(e,t){t.preventDefault(),this.changeZoomScale(e);var o=document.getElementById("svd-simulator-wrapper");o&&(o.style.transform="scale("+this.currZoomScale+")"),t.stopPropagation()},t.prototype.resetZoomParameters=function(){this.currZoomScale=1;var e=document.getElementById("svd-simulator-wrapper");e&&(e.style.transform="")},Object.defineProperty(t.prototype,"activeDevice",{get:function(){return this.device},set:function(e){this.device=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"landscapeOrientation",{get:function(){return this.landscape},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasFrame",{get:function(){var e=Ie[this.activeDevice];return this.simulatorEnabled&&"desktop"!==e.deviceType},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"simulatorFrame",{get:function(){if(this.hasFrame){var e=Ie[this.activeDevice],t=(this.landscapeOrientation?e.height:e.width)/e.cssPixelRatio,o=(this.landscapeOrientation?e.width:e.height)/e.cssPixelRatio,i=(this.landscapeOrientation?e.height:e.width)/e.cssPixelRatio,n=(this.landscapeOrientation?e.width:e.height)/e.cssPixelRatio,r=1*i+2*(this.landscapeOrientation?64:16),a=1*n+2*(this.landscapeOrientation?16:64);return{scale:(this.simulatorScaleEnabled,1),frameWidth:r,frameHeight:a,landscapedFrameWidth:this.landscapeOrientation?a:r,landscapedFrameHeight:this.landscapeOrientation?r:a,deviceWidth:t,deviceHeight:o,cssClass:e.cssClass+(this.landscapeOrientation?" svd-simulator-frame-landscape":"")}}},enumerable:!1,configurable:!0}),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svd-simulator-main").append("svd-simulator-main--frame",this.hasFrame).append("svd-simulator-main--desktop","desktop"===this.device).append("svd-simulator-main--running",this.isRunning).toString()},J([(0,o.property)({defaultValue:!0})],t.prototype,"landscape",void 0),J([(0,o.property)({onSet:function(e,t){t.surveyChanged()}})],t.prototype,"survey",void 0),J([(0,o.property)({defaultValue:"desktop"})],t.prototype,"device",void 0),J([(0,o.property)({defaultValue:"l"})],t.prototype,"orientation",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"considerDPI",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isRunning",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"simulatorEnabled",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"simulatorScaleEnabled",void 0),t}(o.Base),Ve=96*("undefined"!=typeof window?window.devicePixelRatio:1),Ie={desktop:{deviceType:"desktop",title:"Desktop"},iPhoneSE:{cssPixelRatio:2,ppi:326,width:750,height:1334,deviceType:"phone",title:"iPhone SE",cssClass:"svd-simulator-iphonexmax"},iPhone15:{cssPixelRatio:3,ppi:460,width:1179,height:2556,deviceType:"phone",title:"iPhone 15",cssClass:"svd-simulator-iphonexmax"},iPhone15Plus:{cssPixelRatio:3,ppi:460,width:1290,height:2796,deviceType:"phone",title:"iPhone 15 Plus",cssClass:"svd-simulator-iphonexmax"},iPadMini:{cssPixelRatio:2.5,ppi:326,width:1536,height:2048,deviceType:"tablet",title:"iPad Mini",cssClass:"svd-simulator-ipadmini"},iPad:{cssPixelRatio:2,ppi:264,width:1640,height:2360,deviceType:"tablet",title:"iPad Air",cssClass:"svd-simulator-ipad"},androidPhone:{cssPixelRatio:3,ppi:411,width:1080,height:2048,deviceType:"phone",title:"Android Phone",cssClass:"svd-simulator-androidphone"},androidTablet:{cssPixelRatio:1.5,ppi:149,width:800,height:1280,deviceType:"tablet",title:"Android Tablet",cssClass:"svd-simulator-androidtablet"},msSurface:{cssPixelRatio:1,ppi:148,width:768,height:1366,deviceType:"tablet",title:"MS Surface",cssClass:"svd-simulator-mssurface"},genericPhone:{cssPixelRatio:1,deviceType:"phone",title:"",cssClass:"svd-simulator-genphone"}},Oe=function(e){function t(t,i){void 0===i&&(i=o.defaultV2Css);var n=e.call(this)||this;return n.surveyProvider=t,n.startThemeClasses=i,n.enableInvisiblePages=!0,n.pages=new o.ActionContainer,n.simulator=new Ee(t),n}return K(t,e),Object.defineProperty(t.prototype,"activeLanguage",{get:function(){return this.getPropertyValue("activeLanguage",this.survey.locale||o.surveyLocalization.defaultLocale)},set:function(e){e!==this.activeLanguage&&(this.setPropertyValue("activeLanguage",e),this.survey.locale=e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"survey",{get:function(){return this.simulator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pageActions",{get:function(){return this.pages.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPageToolbarVisible",{get:function(){return this.pages.visibleActions.length>0&&!this.surveyProvider.isMobileView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMobileView",{get:function(){return this.surveyProvider.isMobileView},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showResults",{get:function(){return this.getShowResults()},enumerable:!1,configurable:!0}),t.prototype.updateSimulatorSurvey=function(e,t){var o=this,i=this.surveyProvider.createSurvey(e||{},this.getTabName(),this,(function(e){e.applyTheme(o.surveyProvider.theme),e.setCss(t,!1),e.fitToContainer=!0,e.addLayoutElement({id:"complete-customization",container:"completePage",component:"svc-complete-page",data:o})})),n=!!this.simulator.survey;this.simulator.survey=i,this.onSurveyCreatedCallback&&this.onSurveyCreatedCallback(this.survey),this.survey.onComplete.add((function(e){o.isRunning=!1})),this.survey.onNavigateToUrl&&this.survey.onNavigateToUrl.add((function(e,t){var i=t.url;if(t.url="",i&&t.allow){var n=Z("ed.navigateToMsg")+" '"+i+"'.";o.surveyProvider?o.surveyProvider.notify(n):alert(n)}})),this.survey.onStarted.add((function(e){o.setActivePageItem(o.simulator.survey.activePage,!0)})),this.survey.onCurrentPageChanged.add((function(e,t){o.activePage=t.newCurrentPage,o.setActivePageItem(t.oldCurrentPage,!1),o.setActivePageItem(t.newCurrentPage,!0)})),this.survey.onPageVisibleChanged.add((function(e,t){o.updatePageItem(t.page),o.updatePrevNextPageActionState()})),n&&this.show()},t.prototype.setJSON=function(e,t){this.json=e,null!=e&&e.cookieName&&delete e.cookieName,this.updateSimulatorSurvey(e,t)},t.prototype.initialize=function(e,t){this.setJSON(e,this.startThemeClasses),this.updatePageList(),void 0!==t.showPagesInTestSurveyTab&&(this.showPagesInTestSurveyTab=t.showPagesInTestSurveyTab),this.buildActions()},t.prototype.updatePageItem=function(e){var t=this.getPageItemByPage(e);t&&(t.enabled=this.enableInvisiblePages&&this.showInvisibleElements||e.isVisible)},t.prototype.getCurrentPageItem=function(){return this.pageListItems[this.survey.pages.indexOf(this.survey.activePage)]},t.prototype.getSelectPageTitle=function(){return this.activePage&&this.getPageTitle(this.activePage,"preview-tab:selected-page","survey-tester-selected")||Z("ts.selectPage")},t.prototype.getPageTitle=function(e,o,i){void 0===o&&(o="preview-tab:page-list"),void 0===i&&(i="survey-tester");var n=e.title.replace(t.tagRegex,""),r=this.surveyProvider.getObjectDisplayName(e,o,i,n);if(r===e.name&&0===r.indexOf("page")){var a=this.survey.pages.indexOf(e);return G.getString("ed.pageTypeName")+" "+(a+1)}return r},t.prototype.updatePageList=function(){for(var e=[],t=0;t<this.survey.pages.length;t++){var o=this.survey.pages[t],i={id:o.name,data:o,title:this.getPageTitle(o),enabled:this.enableInvisiblePages&&this.showInvisibleElements||o.isVisible,visible:!0};o.isVisible||(i.css="svc-page-invisible",i.markerIconName="icon-invisible-items",i.markerIconSize=24),e.push(i)}this.pageListItems=e},t.prototype.getTabName=function(){return""},t.prototype.getShowResults=function(){return!1},t.prototype.show=function(){this.showInvisibleElements=!1,this.activePage=this.survey.activePage,this.survey.locale=this.activeLanguage,this.isRunning=!0},t.prototype.testAgain=function(){this.setJSON(this.json,this.simulator.survey.css),this.updatePageList(),this.show()},t.prototype.buildActions=function(){var e=this,t=[],i=function(t){var o=e.survey.currentPageNo,i=o+(t?1:-1);"starting"===e.survey.state&&t&&(i=0);var n=e.showInvisibleElements?e.survey.pages[i]:e.survey.visiblePages[i];!t&&0===o&&e.survey.firstPageIsStarted&&e.survey.pages.length>0&&(n=e.survey.pages[0]);var r=e.survey.pages.indexOf(n);e.activePage=e.survey.pages[r],e.selectPageAction.data.selectedItem=e.pageListItems[r]};this.prevPageAction&&(this.prevPageAction.visible=new o.ComputedUpdater((function(){var t="running"===e.survey.state,o=e.getTabName()===e.surveyProvider.activeTab;return I(e.isRunning,o,e.pageListItems.length>1)&&t})),this.prevPageAction.iconName=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?"icon-arrow-left":"icon-arrow-left_16x16"})),this.prevPageAction.iconSize=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?24:16})),this.prevPageAction.action=function(){return i(!1)},t.push(this.prevPageAction)),this.selectPageAction=(0,o.createDropdownActionModel)({id:"pageSelector",css:"svc-page-selector",title:this.getSelectPageTitle(),visible:this.isRunning&&this.pageListItems.length>1&&this.showPagesInTestSurveyTab},{items:this.pageListItems,allowSelection:!0,selectedItem:this.getCurrentPageItem(),onSelectionChanged:function(t){e.activePage=t.data;for(var o=0;o<e.survey.pages.length&&e.survey.pages[o]!==e.activePage;o++)e.survey.pages[o].passed=!0},cssClass:"svc-creator-popup",verticalPosition:"top",horizontalPosition:"center"}),t.push(this.selectPageAction),this.selectPageAction.visible=new o.ComputedUpdater((function(){return"running"===e.survey.state})),this.nextPageAction&&(this.nextPageAction.visible=new o.ComputedUpdater((function(){var t="running"===e.survey.state,o=e.getTabName()===e.surveyProvider.activeTab;return I(e.isRunning,o,e.pageListItems.length>1)&&t})),this.nextPageAction.iconName=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?"icon-arrow-right":"icon-arrow-right_16x16"})),this.nextPageAction.iconSize=new o.ComputedUpdater((function(){return e.surveyProvider.isMobileView?24:16})),this.nextPageAction.action=function(){return i(!0)},t.push(this.nextPageAction)),this.pages.actions=t,this.pages.containerCss="sv-action-bar--pages",this.updatePrevNextPageActionState()},t.prototype.setActivePageItem=function(e,t){var o=this.getPageItemByPage(e);o&&(o.active=t)},t.prototype.getPageItemByPage=function(e){var t=this.selectPageAction.popupModel.contentComponentData.model;if(t&&Array.isArray(t.actions)){for(var o=t.actions,i=0;i<o.length;i++)if(o[i].data===e)return o[i];return null}},t.prototype.updateResultsTemplate=function(e){this.simulator.survey.setCss(e,!1),this.simulator.survey.render()},t.prototype.setTheme=function(e,t){var i=t.filter((function(t){return t.name===e})),n=o.defaultV2Css;i.length>0&&(n=i[0].theme),this.isRunning?this.updateSimulatorSurvey(this.json,n):this.updateResultsTemplate(n)},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.pages.hasActions&&("activePage"===t&&(this.updatePrevNextPageActionState(),this.selectPageAction.title=this.getSelectPageTitle()),"isRunning"!==t&&"pageListItems"!==t&&"showPagesInTestSurveyTab"!==t||(this.selectPageAction.popupModel.contentComponentData.model.items=this.pageListItems,this.selectPageAction.popupModel.contentComponentData.model.selectedItem=this.getCurrentPageItem(),this.selectPageAction.visible=this.isRunning&&this.pageListItems.length>1&&this.showPagesInTestSurveyTab))},t.prototype.updatePrevNextPageActionState=function(){if(this.prevPageAction&&this.survey){var e=this.survey.firstPageIsStarted&&"starting"!==this.survey.state||!this.survey.firstPageIsStarted&&!this.survey.isFirstPage;this.prevPageAction.enabled=e;var t=this.survey&&this.survey.visiblePages.indexOf(this.activePage)!==this.survey.visiblePages.length-1;this.nextPageAction.enabled=t}},Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.isMobileView?Z("ed.previewPlaceholderTitleMobile"):Z("ed.previewPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.isMobileView?Z("ed.previewPlaceholderDescriptionMobile"):Z("ed.previewPlaceholderDescription")},enumerable:!1,configurable:!0}),t.prototype.onScroll=function(){return this.survey.onScroll(),!0},t.prototype.dispose=function(){this.selectPageAction&&this.selectPageAction.dispose(),this.simulator.dispose(),e.prototype.dispose.call(this)},t.tagRegex=/(<([^>]+)>)/gi,J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.simulator.survey.showInvisibleElements=e}})],t.prototype,"showInvisibleElements",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showPagesInTestSurveyTab",void 0),J([(0,o.property)({defaultValue:!0,onSet:function(e,t){t.simulator&&(t.simulator.isRunning=e)}})],t.prototype,"isRunning",void 0),J([(0,o.propertyArray)()],t.prototype,"pageListItems",void 0),J([(0,o.property)({onSet:function(e,t){if(e){var o=t.simulator.survey;o.firstPageIsStarted&&(e===o.pages[0]?o.clear(!1,!0):"starting"==o.state&&o.setPropertyValue("isStartedState",!1)),"starting"!==o.state&&(o.currentPage=e)}t.updatePrevNextPageActionState()}})],t.prototype,"activePage",void 0),t}(o.Base);r(5625);var Ae=function(e){function t(t,o){return e.call(this,t,o)||this}return K(t,e),t.prototype.getTabName=function(){return"test"},t.prototype.getShowResults=function(){return this.surveyProvider.previewShowResults&&!this.isRunning&&!this.isMobileView},t}(Oe),Ne=function(){function e(e){this.creator=e,this.simulatorTheme=o.surveyCss[o.defaultV2ThemeName],e.addPluginTab("test",this),this.setPreviewTheme(this.creator.themeForPreview),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.setDevice=function(e){this.model.simulator.device=e,this.model.simulator.resetZoomParameters();var t=Ie[this.model.simulator.device].deviceType;this.orientationSelectorAction.enabled="desktop"!=t,this.deviceSelectorAction.iconName="icon-device-"+t,this.deviceSelectorAction.title=Z("pe.simulator")},e.prototype.setDefaultLanguageOption=function(e){var t=this,o=!0===e||"all"===e||"auto"===e&&this.model.survey.getUsedLocales().length>1;this.languageSelectorAction.visible=o;var i=[];o&&(i=this.getLanguages("all"!==e?this.model.survey.getUsedLocales():null)),this.languageSelectorAction.popupModel.contentComponentData.model.setItems(i),this.languageSelectorAction.data.selectedItem=i.filter((function(e){return e.id===t.model.activeLanguage}))[0]},e.prototype.getLanguages=function(e){void 0===e&&(e=null);for(var t=[],i=e&&e.length>1?e:o.surveyLocalization.getLocales(),n=0;n<i.length;n++){var r=i[n];t.push({id:r,title:G.getLocaleName(r)})}return t},e.prototype.updateActions=function(){this.languageSelectorAction.title=G.getLocaleName(this.model.activeLanguage),this.languageSelectorAction.visible=!0,this.creator.showSimulatorInTestSurveyTab&&(this.setDevice(this.model.simulator.device),this.deviceSelectorAction.data.selectedItem={id:this.model.simulator.device},this.orientationSelectorAction.title=Z("pe.portraitOrientation")),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction.css=this.model.showInvisibleElements?"sv-action-bar-item--active":"",this.invisibleToggleAction.visible=this.model.isRunning),null!=this.creator.showDefaultLanguageInTestSurveyTab&&this.setDefaultLanguageOption(this.creator.showDefaultLanguageInTestSurveyTab)},e.prototype.setPreviewTheme=function(e){this.simulatorTheme=o.surveyCss[e]||o.surveyCss[o.defaultV2ThemeName]},e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){return"test"===e.creator.activeTab}))},e.prototype.activate=function(){this.model=new Ae(this.creator,this.simulatorTheme),this.model.simulator.landscape="portrait"!=this.creator.previewOrientation,this.update()},e.prototype.update=function(){var e=this;if(this.model){var t={showPagesInTestSurveyTab:this.creator.showPagesInTestSurveyTab};this.model.testAgainAction=this.testAgainAction,this.model.prevPageAction=this.prevPageAction,this.model.nextPageAction=this.nextPageAction,this.model.initialize(this.creator.JSON,t),this.updateActions(),this.model.show(),this.model.onPropertyChanged.add((function(t,o){"isRunning"===o.name&&(e.invisibleToggleAction&&(e.invisibleToggleAction.visible=e.model.isRunning),e.testAgainAction.visible=!e.model.isRunning)}))}},e.prototype.deactivate=function(){return this.model&&(this.simulatorTheme=this.model.simulator.survey.css,this.model.onSurveyCreatedCallback=void 0,this.model.dispose(),this.model=void 0),this.languageSelectorAction.visible=!1,this.testAgainAction.visible=!1,this.invisibleToggleAction&&(this.invisibleToggleAction.visible=!1),!0},e.prototype.getAvailableThemes=function(e){for(var t=[],i=0;i<e.length;i++){var n=e[i],r=new o.Action({id:n.name+"_themeSwitcher",locTitleName:this.getThemeLocName(n.name)});r.value=n.name,t.push(r)}return t},e.prototype.getThemeLocName=function(e){return"ed."+e+"Theme"},e.prototype.createActions=function(){var e=this,t=[];if(this.testAgainAction=new o.Action({id:"testSurveyAgain",visible:!1,locTitleName:"ed.testSurveyAgain",action:function(){e.model.testAgain()}}),this.creator.showSimulatorInTestSurveyTab){var i=Object.keys(Ie).filter((function(e){return!!Ie[e].title})).map((function(e){var t;return{id:e,title:Ie[e].title,visibleIndex:null!==(t=Ie[e].visibleIndex)&&void 0!==t?t:Number.MAX_VALUE}}));this.deviceSelectorAction=(0,o.createDropdownActionModel)({id:"deviceSelector",iconName:"icon-device-desktop",mode:"small",visible:new o.ComputedUpdater((function(){return I("test"===e.creator.activeTab,e.creator.showSimulatorInTestSurveyTab,!e.creator.isTouch)}))},{items:i,allowSelection:!0,onSelectionChanged:function(t){e.setDevice(t.id)},horizontalPosition:"center",cssClass:"svc-creator-popup",onHide:function(){e.deviceSelectorAction.enabled=!0},onShow:function(){e.deviceSelectorAction.enabled=!1}}),t.push(this.deviceSelectorAction),this.orientationSelectorAction=new o.Action({id:"orientationSelector",iconName:"icon-device-rotate",mode:"small",visible:new o.ComputedUpdater((function(){return I("test"===e.creator.activeTab,e.creator.showSimulatorInTestSurveyTab,!e.creator.isTouch)})),action:function(){e.model.simulator.landscape=!e.model.simulator.landscape,e.orientationSelectorAction.title=Z(e.model.simulator.landscape?"pe.portraitOrientation":"pe.landscapeOrientation")}}),t.push(this.orientationSelectorAction)}this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction=new o.Action({id:"showInvisible",iconName:"icon-invisible-items",mode:"small",needSeparator:new o.ComputedUpdater((function(){return!e.creator.isMobileView})),locTitleName:"ts.showInvisibleElements",visible:!1,action:function(){e.model.showInvisibleElements=!e.model.showInvisibleElements,e.invisibleToggleAction.css=e.model.showInvisibleElements?"sv-action-bar-item--active":"",e.invisibleToggleAction.title=Z(e.model.showInvisibleElements?"ts.hideInvisibleElements":"ts.showInvisibleElements")}}),t.push(this.invisibleToggleAction));var n=o.StylesManager.getIncludedThemeCss(),r=["defaultV2","modern","default"];n=n.sort((function(e,t){return r.indexOf(e.name)>r.indexOf(t.name)?1:-1}));var a,s=this.getAvailableThemes(n);return this.creator.allowChangeThemeInPreview&&s.length>1&&!this.creator.showThemeTab&&(this.changeThemeModel=new o.ListModel(s,(function(t){e.model&&e.model.setTheme(t.value,n),e.changeThemeAction.locTitleName=e.getThemeLocName(t.value),e.changeThemeAction.locStrsChanged(),e.changeThemePopupModel.toggleVisibility()}),!0),this.changeThemeModel.locOwner=this.creator,this.changeThemePopupModel=new o.PopupModel("sv-list",{model:this.changeThemeModel},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"}),this.changeThemeAction=new o.Action({id:"themeSwitcher",iconName:"icon-theme",component:"sv-action-bar-item-dropdown",mode:"large",locTitleName:this.getThemeLocName((a=n.filter((function(t){return t.theme.root===e.simulatorTheme.root})),a.length>0?a[0].name:"defaultV2")),needSeparator:!0,visible:new o.ComputedUpdater((function(){return I(e.creator.showSimulatorInTestSurveyTab,"test"===e.creator.activeTab)})),action:function(){e.changeThemePopupModel.toggleVisibility()},popupModel:this.changeThemePopupModel}),t.push(this.changeThemeAction)),this.languageSelectorAction=(0,o.createDropdownActionModel)({id:"languageSelector",iconName:"icon-language",visible:!1,mode:new o.ComputedUpdater((function(){return e.creator.isMobileView?"small":"large"}))},{items:[],allowSelection:!0,onSelectionChanged:function(t){e.model.activeLanguage=t.id,e.languageSelectorAction.title=G.getLocaleName(t.id)},horizontalPosition:"center",cssClass:"svc-creator-popup",onHide:function(){e.languageSelectorAction.enabled=!0},onShow:function(){e.languageSelectorAction.enabled=!1}}),t.push(this.languageSelectorAction),this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",action:function(){e.creator.makeNewViewActive("designer")},visible:this.createVisibleUpdater(),locTitleName:"ed.designer",showTitle:!1}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",active:!0,visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1,action:function(){}}),this.prevPageAction=new o.Action({id:"prevPage",iconName:"icon-arrow-left_16x16",needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),visible:!1}),this.nextPageAction=new o.Action({id:"nextPage",iconName:"icon-arrow-right_16x16",visible:!1}),t},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.prevPageAction),this.creator.footerToolbar.actions.push(this.nextPageAction),this.invisibleToggleAction&&this.creator.footerToolbar.actions.push(this.invisibleToggleAction)},e}(),Le=function(){function e(e,t){void 0===t&&(t=null),this.survey=e,this.options=t}return e.prototype.toDisplayText=function(e){if(!this.survey)return e;this.showTitles=!!this.options&&1==this.options.showTitlesInExpressions;var t=(new o.ConditionsParser).parseExpression(e);if(!t)return e;if(t.getType)return this.toDisplayTextCore(t);if(!this.showTitles)return e;var i=[];return t.setVariables(i),this.replaceVariables(e,i)},e.prototype.toExpression=function(e){return this.toDisplayTextCore(e)},e.prototype.toDisplayTextCore=function(e){this.currentQuestion=null;var t=this,o=!0,i=function(e){var n=o;return o=!1,t.showTitles&&"variable"==e.getType()?t.getQuestionText(e):t.showTitles&&"const"==e.getType()?t.getDisplayText(e):"binary"==e.getType()?(t.proceedBinary(e),t.getDisplayBinary(e,n,i)):"unary"==e.getType()?t.getDisplayUnary(e,i):void 0};return e.toString(i)},e.prototype.getQuestionText=function(e){var t=this.getQuestionByName(e.variable);return t&&t.title?E(t.title):e.variable},e.prototype.getDisplayText=function(e){if(this.currentQuestion){var t=this.currentQuestion.getDisplayValue(!0,e.correctValue);return t?new o.Const(t).toString():void 0}},e.prototype.getDisplayOperand=function(e,t){return e?e.toString(t):""},e.prototype.getDisplayOperator=function(t){return e.operatorText[t]||G.getString("op."+t)},e.prototype.getDisplayBinary=function(e,t,o){return(t?"":"(")+this.getDisplayOperand(e.leftOperand,o)+" "+this.getDisplayOperator(e.operator)+" "+this.getDisplayOperand(e.rightOperand,o)+(t?"":")")},e.prototype.getDisplayUnary=function(e,t){var o=e.expression.toString(t),i=this.getDisplayOperator(e.operator);return"empty"==e.operator||"notempty"==e.operator?o+" "+i:i+" "+o},e.prototype.proceedBinary=function(e){e.isArithmetic||e.isConjunction?this.currentQuestion=null:(this.currentQuestion=this.getQuestionFromOperands(e.leftOperand,e.rightOperand),this.currentQuestion||(this.currentQuestion=this.getQuestionFromOperands(e.rightOperand,e.leftOperand)))},e.prototype.getQuestionFromOperands=function(e,t){if(!e||!t)return null;if("variable"!=e.getType())return null;var o=t.getType();return"const"!=o&&"function"!=o&&"array"!=o?null:this.getQuestionByName(e.variable)},e.prototype.replaceVariables=function(e,t){for(var o=0;o<t.length;o++)e=this.replaceVariable(e,t[o]);return e},e.prototype.replaceVariable=function(e,t){var o=this.getQuestionByName(t);return o&&o.title?e.replace(E(t),E(o.title)):e},e.prototype.getQuestionByName=function(e){return this.survey?this.survey.getQuestionByValueName(e):null},e.operatorText={less:"<",lessorequal:"<=",greater:">",greaterorequal:">=",equal:"==",notequal:"!=",plus:"+",minus:"-",mul:"*",div:"/",power:"^",mod:"%",negate:"!"},e}(),_e=function(){function e(){}return e.prototype.remove=function(e,t){var i=(new o.ConditionsParser).parseExpression(e);if(!i)return e;if(this.wasRemoved=!1,i.getType){var n=this.processOperand(i,t);return this.wasRemoved?n?n.toString():"":e}return e},e.prototype.processOperand=function(e,t){return e?"variable"==e.getType()?this.processVariable(e,t):"unary"==e.getType()?this.processUnary(e,t):"binary"==e.getType()?this.proceedBinary(e,t):e:null},e.prototype.processVariable=function(e,t){return e.variable!==t?e:(this.wasRemoved=!0,null)},e.prototype.processUnary=function(e,t){return this.processOperand(e.expression,t)?e:(this.wasRemoved=!0,null)},e.prototype.proceedBinary=function(e,t){var i=this.processOperand(e.leftOperand,t),n=this.processOperand(e.rightOperand,t);if(i&&n)return i!==e.leftOperand||n!==e.rightOperand?new o.BinaryOperand(e.operator,i,n,e.isArithmetic):e;if(!i&&!n)return null;var r=i||n;return"binary"==r.getType()?r:null},e}(),Me=function(){function e(e){this.constChanges=[],this.operand=(new o.ConditionsParser).parseExpression(e)}return e.prototype.update=function(e,t,o){this.updateOperand(this.operand,e.toLocaleLowerCase(),t,o)},Object.defineProperty(e.prototype,"isModified",{get:function(){return this.constChanges.length>0},enumerable:!1,configurable:!0}),e.prototype.toString=function(){var e=this,t=!0,o=function(i){var n=t;return t=!1,"const"===i.getType()?e.constToString(i):"binary"===i.getType()?e.binaryToString(i,n,o):void 0};return this.operand.toString(o)},e.prototype.constToString=function(e){for(var t=0;t<this.constChanges.length;t++)if(this.constChanges[t].op===e)return this.constChanges[t].val;return e.toString()},e.prototype.binaryToString=function(e,t,o){return(t?"":"(")+this.operandToString(e.leftOperand,o)+" "+this.operatorToString(e.operator)+" "+this.operandToString(e.rightOperand,o)+(t?"":")")},e.prototype.operandToString=function(e,t){return e?e.toString(t):""},e.prototype.operatorToString=function(t){return e.operatorText[t]||t},e.prototype.updateOperand=function(e,t,o,i){if("binary"==e.getType()){var n=e;n.isConjunction?(this.updateOperand(n.leftOperand,t,o,i),this.updateOperand(n.rightOperand,t,o,i)):this.hasVarName(n.leftOperand,t)?this.updateOperandConst(n.rightOperand,o,i):this.hasVarName(n.rightOperand,t)&&this.updateOperandConst(n.leftOperand,o,i)}},e.prototype.hasVarName=function(e,t){if(e&&"variable"===e.getType())return e.variable.toLowerCase()===t},e.prototype.updateOperandConst=function(e,t,i){var n=this;if("array"===e.getType()){var r=e;Array.isArray(r.values)&&r.values.forEach((function(e){return n.updateOperandConst(e,t,i)}))}if("const"===e.getType()){var a=e;o.Helpers.isTwoValueEquals(a.correctValue,t)&&(i=this.getCorrectNewValue(a,i),this.constChanges.push({op:e,val:i}))}},e.prototype.getCorrectNewValue=function(e,t){var i=e.toString();return!i||o.Helpers.isTwoValueEquals(e.correctValue,i)||'"'!==i[0]&&"'"!==i[0]?t:i[0]+t+i[0]},e.operatorText={less:"<",lessorequal:"<=",greater:">",greaterorequal:">=",equal:"=",notequal:"!=",plus:"+",minus:"-",mul:"*",div:"/",power:"^",mod:"%",negate:"!"},e}();function De(e,t,o,i){var n=new Me(e);return n.update(t,o,i),n.isModified?n.toString():e}function ke(e){return G.getString("ed.lg."+e)}var je=function(){function e(e,t,o){void 0===o&&(o=null),this.logicType=e,this.survey=t,this.options=o,this.mergeWithBaseClass()}return e.expressionToDisplayText=function(e,t,o){return new Le(e,t).toDisplayText(o)},e.prototype.mergeWithBaseClass=function(){if(this.logicType.baseClass){var e=Re.baseTypes[this.logicType.baseClass];if(e)for(var t in e)this.logicType[t]||(this.logicType[t]=e[t])}},Object.defineProperty(e.prototype,"name",{get:function(){return this.logicType.name},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"baseClass",{get:function(){return this.logicType.baseClass},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"propertyName",{get:function(){return this.logicType.propertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"hasVisibleElements",{get:function(){return!0!==this.logicType.isInvisible},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dynamicPropertyName",{get:function(){return this.logicType.dynamicPropertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"dependedOnPropertyName",{get:function(){return this.logicType.dependedOnPropertyName},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{get:function(){return!!this.showInUI&&(!this.logicType.showIf||this.logicType.showIf(this.survey))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showTitlesInExpression",{get:function(){return!!this.options&&this.options.showTitlesInExpressions},enumerable:!1,configurable:!0}),e.prototype.createNewObj=function(e){var t=o.Serializer.createClass(this.baseClass);return e&&t.fromJSON(e.toJSON()),t.survey=this.survey,t.setOwner&&t.setOwner(this.survey),(t instanceof o.ItemValue||t instanceof o.SurveyTrigger)&&(t.isGhost=!0),t},e.prototype.cloneElement=function(e){return this.isTrigger?this.createNewObj(e):e},e.prototype.areElementsEqual=function(e,t){return e===t||!(!this.isTrigger||e.getType()!==t.getType())&&o.Helpers.isTwoValueEquals(e.toJSON(),t.toJSON())},e.prototype.saveNewElement=function(e){var t=this.logicType.getCollection?this.logicType.getCollection(this.survey):null;!t&&this.isTrigger&&(t=this.survey.triggers),t&&t.indexOf(e)<0&&t.push(e)},Object.defineProperty(e.prototype,"showInUI",{get:function(){return!1!==this.logicType.showInUI},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isUniqueItem",{get:function(){return!0===this.logicType.isUniqueItem},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"questionNames",{get:function(){return this.logicType.questionNames},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"displayName",{get:function(){return ke(this.name+"Name")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"description",{get:function(){return ke(this.name+"Description")},enumerable:!1,configurable:!0}),e.prototype.getParentElement=function(e){return this.logicType.getParentElement?this.logicType.getParentElement(e):null},Object.defineProperty(e.prototype,"hasSelectorChoices",{get:function(){return!!this.logicType.getSelectorChoices},enumerable:!1,configurable:!0}),e.prototype.getSelectorChoices=function(e,t){return this.hasSelectorChoices?this.logicType.getSelectorChoices(e,t):null},e.prototype.getDisplayText=function(e){var t=ke(this.name+"Text");if(this.logicType.getDisplayText)return this.logicType.getDisplayText(e,t,this);this.logicType.getElementName&&(e=this.getElementByName(this.logicType.getElementName(e)));var o=this.getElementDisplayName(e);if(o){var i=this.getParentElement(e),n=this.getElementDisplayName(i);return t.format(o,n)}return t},e.prototype.getElementDisplayName=function(e){if(!e)return"";var t="";return this.showTitlesInExpression&&(t=e.title),t||(t=e.name||""),E(t)},e.prototype.getElementByName=function(e){return this.survey?this.survey.getQuestionByName(e)||this.survey.getPageByName(e):null},e.prototype.formatElName=function(e){var t=this.getElementByName(e);return this.getElementDisplayName(t)},e.prototype.formatExpression=function(t){return e.expressionToDisplayText(this.survey,this.options,t)},e.prototype.supportContext=function(e){return!!this.logicType.supportContext&&this.logicType.supportContext(e)},Object.defineProperty(e.prototype,"isTrigger",{get:function(){return!!this.baseClass&&this.baseClass.indexOf("trigger")>-1},enumerable:!1,configurable:!0}),e}(),Re=function(){function e(){}return e.baseTypes={panel:{showIf:function(e){return e.getAllPanels().length>0},getSelectorChoices:function(e,t){return e.getAllPanels()}},question:{showIf:function(e){return e.getAllQuestions().length>0},supportContext:function(e){return Array.isArray(e.templateElements)||Array.isArray(e.detailElements)&&e.detailElements.length>0},getParentElement:function(e){return e?e.parentQuestion:null},getSelectorChoices:function(e,t){for(var i=new Array,n=e.getAllQuestions(),r=function(e){i.push(e),e.isPanel&&e.elements.forEach((function(e){return r(e)}))},a=0;a<n.length;a++){var s=n[a];t||i.push(s),s instanceof o.QuestionPanelDynamicModel&&(!t||t===s)&&s.templateElements.forEach((function(e){return r(e)})),s instanceof o.QuestionMatrixDropdownModelBase&&(!t||t===s)&&s.detailElements.forEach((function(e){return r(e)}))}return i}},matrixdropdowncolumn:{showIf:function(e){return function(e){for(var t=e.getAllQuestions(),i=0;i<t.length;i++){var n=t[i];if(n instanceof o.QuestionMatrixDropdownModelBase&&n.columns.length>0)return!0}return!1}(e)},supportContext:function(e){return Array.isArray(e.columns)},getParentElement:function(e){return e?e.colOwner:null},getSelectorChoices:function(e,t){for(var i=[],n=e.getAllQuestions(),r=0;r<n.length;r++){var a=n[r];if(a instanceof o.QuestionMatrixDropdownModelBase&&(!t||t===a))for(var s=a.columns,l=0;l<s.length;l++)i.push(s[l])}return i}}},e.types=[{name:"page_visibility",baseClass:"page",propertyName:"visibleIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"page_enable",baseClass:"page",propertyName:"enableIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"page_require",baseClass:"page",propertyName:"requiredIf",showIf:function(e){return e.pages.length>1},getSelectorChoices:function(e,t){return e.pages}},{name:"panel_visibility",baseClass:"panel",propertyName:"visibleIf"},{name:"panel_enable",baseClass:"panel",propertyName:"enableIf"},{name:"panel_require",baseClass:"panel",propertyName:"requiredIf"},{name:"question_visibility",baseClass:"question",propertyName:"visibleIf"},{name:"question_enable",baseClass:"question",propertyName:"enableIf"},{name:"question_require",baseClass:"question",propertyName:"requiredIf"},{name:"question_resetValue",baseClass:"question",propertyName:"resetValueIf"},{name:"question_setValue",baseClass:"question",propertyName:"setValueIf",getDisplayText:function(e,t,o){return Be(e,t,o)}},{name:"question_setValueExpression",baseClass:"question",propertyName:"setValueExpression",showInUI:!1},{name:"column_visibility",baseClass:"matrixdropdowncolumn",propertyName:"visibleIf"},{name:"column_enable",baseClass:"matrixdropdowncolumn",propertyName:"enableIf"},{name:"column_require",baseClass:"matrixdropdowncolumn",propertyName:"requiredIf"},{name:"column_resetValue",baseClass:"matrixdropdowncolumn",propertyName:"resetValueIf"},{name:"column_setValue",baseClass:"matrixdropdowncolumn",propertyName:"setValueIf",getDisplayText:function(e,t,o){return Be(e,t,o)}},{name:"column_setValueExpression",baseClass:"matrixdropdowncolumn",propertyName:"setValueExpression",showInUI:!1},{name:"expression_expression",baseClass:"expression",propertyName:"expression",showInUI:!1},{name:"matrixdropdowncolumn_totalExpression",baseClass:"matrixdropdowncolumn",propertyName:"totalExpression",showInUI:!1},{name:"trigger_complete",baseClass:"completetrigger",propertyName:"expression",isUniqueItem:!0,isInvisible:!0},{name:"trigger_setvalue",baseClass:"setvaluetrigger",propertyName:"expression",dynamicPropertyName:"setValue",dependedOnPropertyName:"setToName",questionNames:["setToName"],getDisplayText:function(e,t,i){return o.Helpers.isValueEmpty(e.setValue)&&(t=ke("trigger_setvalueEmptyText")),t.format(i.formatElName(e.setToName),e.setValue)}},{name:"trigger_copyvalue",baseClass:"copyvaluetrigger",propertyName:"expression",questionNames:["setToName","fromName"],getDisplayText:function(e,t,o){return t.format(o.formatElName(e.setToName),o.formatElName(e.fromName))}},{name:"trigger_skip",baseClass:"skiptrigger",propertyName:"expression",questionNames:["gotoName"],isUniqueItem:!0,getElementName:function(e){return e.gotoName}},{name:"trigger_runExpression",baseClass:"runexpressiontrigger",propertyName:"expression",questionNames:["setToName"],getDisplayText:function(e,t,o){var i=ke("trigger_runExpressionText1");return i=i.format(o.formatExpression(e.runExpression)),e.setToName&&(i+=ke("trigger_runExpressionText2").format(o.formatElName(e.setToName))),i}},{name:"completedHtmlOnCondition",baseClass:"htmlconditionitem",propertyName:"expression",isUniqueItem:!0,getCollection:function(e){return e.completedHtmlOnCondition}},{name:"trigger_runExpression_Expression",baseClass:"runexpressiontrigger",propertyName:"runExpression",showInUI:!1},{name:"question_expressionValidator",baseClass:"expressionvalidator",propertyName:"expression",showInUI:!1},{name:"matrix_rowsVisibleIf",baseClass:"matrix",propertyName:"rowsVisibleIf",showInUI:!1},{name:"matrix_columnsVisibleIf",baseClass:"matrix",propertyName:"columnsVisibleIf",showInUI:!1},{name:"matrixdropdown_rowsVisibleIf",baseClass:"matrixdropdown",propertyName:"rowsVisibleIf",showInUI:!1},{name:"select_choicesVisibleIf",baseClass:"selectbase",propertyName:"choicesVisibleIf",showInUI:!1},{name:"select_choicesEnableIf",baseClass:"selectbase",propertyName:"choicesEnableIf",showInUI:!1},{name:"itemvalue_visibleIf",baseClass:"itemvalue",propertyName:"visibleIf",showInUI:!1},{name:"itemvalue_enableIf",baseClass:"itemvalue",propertyName:"enableIf",showInUI:!1},{name:"calculatedValue",baseClass:"calculatedvalue",propertyName:"expression",showInUI:!1}],e}();function Be(e,t,o){var i=o.formatElName(e.name),n=e.setValueExpression;return n?t.format(i,n):ke("trigger_setvalueEmptyText").format(i)}var qe=function(){function e(e,t,o){this.surveyValue=o,this.logicTypeValue=e,this.elementValue=t}return Object.defineProperty(e.prototype,"logicType",{get:function(){return this.logicTypeValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"element",{get:function(){return this.elementValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentElement",{get:function(){return this.element&&this.logicType?this.logicType.getParentElement(this.element):null},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),e.prototype.apply=function(e,t){if(void 0===t&&(t=!1),this.element&&this.logicType&&(this.element[this.logicType.propertyName]=e,!e&&o.Serializer.isDescendantOf(this.element.getType(),"surveytrigger"))){var i=this.survey.triggers.indexOf(this.element);i>-1&&this.survey.triggers.splice(i,1)}},e.prototype.renameQuestion=function(e,t){if(this.element)for(var o=this.questionNames,i=0;i<o.length;i++){var n=this.element[o[i]];n&&n.toLowerCase()==e.toLowerCase()&&(this.element[o[i]]=t)}},e.prototype.clone=function(){var t=this.logicType.cloneElement(this.element);return new e(this.logicType,t,this.survey)},e.prototype.equals=function(e){return this.logicType===e.logicType&&this.logicType.areElementsEqual(this.element,e.element)},Object.defineProperty(e.prototype,"name",{get:function(){return this.logicType?this.logicType.displayName:""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"logicTypeName",{get:function(){return this.logicType?this.logicType.name:void 0},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"logicTypeDescription",{get:function(){return this.logicType?this.logicType.description:""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"text",{get:function(){return this.logicType?this.logicType.getDisplayText(this.element):""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deleteActionText",{get:function(){return ke("deleteAction")},enumerable:!1,configurable:!0}),e.prototype.getLocString=function(e){return G.getString(e)},e.prototype.isSuitableByQuestionName=function(e){var t=this.elementName===e||0===this.elementName.indexOf(e+".");return t||(t=this.questionNamesValues.filter((function(t){return t===e||0===t.indexOf(e+".")})).length>0),t},e.prototype.isSuitableByLogicType=function(e){return!this.logicTypeName||e===this.logicTypeName},e.prototype.addQuestionNames=function(e){var t=this.elementOwnerName;this.elementName&&-1===e.indexOf(t)&&e.push(t),this.questionNamesValues.forEach((function(t){t&&-1===e.indexOf(t)&&e.push(t)}))},Object.defineProperty(e.prototype,"questionNames",{get:function(){return this.logicType&&this.logicType.questionNames?this.logicType.questionNames:[]},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"elementName",{get:function(){if(!this.element)return"";var e="",t=this.getOwnerElement();return t&&t!==this.element&&(e=t.name+"."),e+this.element.name||""},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"elementOwnerName",{get:function(){var e=this.getOwnerElement();return e&&e.name||""},enumerable:!1,configurable:!0}),e.prototype.getOwnerElement=function(){return this.element?this.parentElement||this.element:null},Object.defineProperty(e.prototype,"questionNamesValues",{get:function(){var e=this;return this.questionNames.map((function(t){return e.element[t]}))},enumerable:!1,configurable:!0}),e}(),He=function(){function e(t,o){void 0===o&&(o=""),this.owner=t,this.expression=o,this.idValue=++e.counter,this.isNew=!1,this.isModified=!1,this.actionsValue=[],this.removedActions=[]}return Object.defineProperty(e.prototype,"actions",{get:function(){return this.actionsValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"id",{get:function(){return this.idValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"name",{get:function(){return"logicItem"+this.id},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.owner.survey},enumerable:!1,configurable:!0}),e.prototype.getVisibleLogicTypes=function(){return this.owner.getVisibleLogicTypes()},Object.defineProperty(e.prototype,"expressionText",{get:function(){return this.getExpressionAsDisplayText()||G.getString("ed.lg.itemEmptyExpressionText")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"actionsText",{get:function(){return this.actions.map((function(e){return e.text})).join(", ")},enumerable:!1,configurable:!0}),e.prototype.getDisplayText=function(){var e=this.getExpressionAsDisplayText(),t="";return this.actions.forEach((function(e){t+=", "+e.text})),e&&t?(this.ifText+" "+e+t).replace(new RegExp("({|})","gm"),"'"):G.getString("ed.lg.itemEmptyExpressionText")},e.prototype.edit=function(){this.owner&&this.owner.editItem(this)},e.prototype.remove=function(){this.owner&&this.owner.removeItem(this)},Object.defineProperty(e.prototype,"isReadOnly",{get:function(){return!!this.owner&&this.owner.readOnly},enumerable:!1,configurable:!0}),e.prototype.addNewAction=function(e){this.actions.push(e)},e.prototype.removeAction=function(e){this.replaceActionCore(null,e)},e.prototype.replaceAction=function(e,t){t?this.replaceActionCore(e,t):this.addNewAction(e)},e.prototype.clone=function(){for(var t=new e(this.owner,this.expression),o=0;o<this.actions.length;o++)t.addNewAction(this.actions[o].clone());return t},e.prototype.equals=function(e){if(this.expression!==e.expression)return!1;if(this.actions.length!==e.actions.length)return!1;for(var t=0;t<this.actions.length;t++)if(!this.actions[t].equals(e.actions[t]))return!1;return!0},e.prototype.replaceActionCore=function(e,t){this.removedActions.push(t);var o=this.actions.indexOf(t);o>-1&&(e?this.actions.splice(o,1,e):this.actions.splice(o,1))},e.prototype.apply=function(e){e?this.removeSameActions():this.removeActions();for(var t=0;t<this.removedActions.length;t++)this.removedActions[t].apply("");this.removedActions=[],this.applyExpression(e,!1)},e.prototype.renameQuestion=function(e,t){var o=this;if(e&&t&&e!==t){["","panel.","row."].forEach((function(n){return o.renameQuestionInExpression(n+e,n+t,[i.logic.closeBracket,".","["])}));for(var n=this.actions,r=0;r<n.length;r++)n[r].renameQuestion(e,t)}},e.prototype.renameColumn=function(e,t,n){if(this.canUpdateExpressionByQuestion(e)){this.actions[0].parentElement===e&&this.renameQuestionInExpression("row."+n,"row."+t.name,[i.logic.closeBracket]);var r=e.rows;if(Array.isArray(r)&&this.isQuestionInExpression(e))for(var a=this.getItemValueQuestionName(e)+".",s=0;s<r.length;s++)if(!o.Helpers.isValueEmpty(r[s].value)){var l=r[s].value.toString()+".";this.renameQuestionInExpression(a+l+n,a+l+t.name,[i.logic.closeBracket])}}},e.prototype.renameItemValue=function(e,t,i){if(this.canUpdateExpressionByQuestion(e)&&(!e.parentQuestion||(Array.isArray(e.parentQuestion.rows)&&this.renameDropdownColumnItemValue(e,t,i),this.actions[0].parentElement===e.parentQuestion))&&this.isQuestionInExpression(e)){var n=this.getItemValueQuestionName(e).toLocaleLowerCase(),r=e.rows,a=this.expression;if(Array.isArray(r))for(var s=0;s<r.length;s++)o.Helpers.isValueEmpty(r[s].value)||(a=De(a,n+"."+r[s].value.toString(),i,t.value));else a=De(a,n,i,t.value);a!=this.expression&&this.applyExpression(a,!0)}},e.prototype.renameDropdownColumnItemValue=function(e,t,n){var r=e.parentQuestion;if(this.isQuestionInExpression(r)){var a="."+e.getValueName();if(this.isStrContainsInExpression(a+i.logic.closeBracket)){for(var s=r.getValueName()+".",l=r.rows,u=this.expression,p=0;p<l.length;p++)o.Helpers.isValueEmpty(l[p].value)||(u=De(u,s+l[p].value.toString()+a,n,t.value));u!=this.expression&&this.applyExpression(u,!0)}}},e.prototype.renameRowValue=function(e,t,o){if(this.canUpdateExpressionByQuestion(e)&&this.isQuestionInExpression(e)){var n=this.getItemValueQuestionName(e);this.renameQuestionInExpression(n+"."+o.toString(),n+"."+t.value.toString(),[i.logic.closeBracket,"."])}},e.prototype.canUpdateExpressionByQuestion=function(e){return!!this.expression&&!!e.name&&this.actions.length>0},e.prototype.isQuestionInExpression=function(e){return this.isStrContainsInExpression(this.getItemValueQuestionName(e).toLocaleLowerCase())},e.prototype.isStrContainsInExpression=function(e){return!!e&&this.expression.toLocaleLowerCase().indexOf(e.toLocaleLowerCase())>-1},e.prototype.getItemValueQuestionName=function(e){var t=e.getValueName();if(e.parentQuestion){if(e.parentQuestion.isDescendantOf("paneldynamic"))return"panel."+t;if(e.parentQuestion.isDescendantOf("matrixdropdownbase"))return"row."+t}return t},e.prototype.removeQuestion=function(e){this.removeQuestionInExpression(e)},e.prototype.getQuestionNames=function(){var e=[];return this.getQuestionNamesFromExpression(e),this.getQuestionNamesFromActions(e),e},e.prototype.getActionTypes=function(){return this.actions.map((function(e){return e.logicTypeName}))},e.prototype.getContext=function(){var e=this.expression;if(!e)return null;if(!ee.getQuestionContextIndexInfo(e,"{"))return null;for(var t=0;t<this.actions.length;t++){var o=this.actions[t].parentElement;if(o)return o}return null},e.prototype.getQuestionNamesFromExpression=function(e){new o.ConditionRunner(this.expression).getVariables().forEach((function(t){-1===e.indexOf(t)&&e.push(t)}))},e.prototype.getQuestionNamesFromActions=function(e){this.actions.forEach((function(t){return t.addQuestionNames(e)}))},e.prototype.getExpressionAsDisplayText=function(){return this.owner?this.owner.getExpressionAsDisplayText(this.expression):this.expression},Object.defineProperty(e.prototype,"editText",{get:function(){return G.getString("pe.edit")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"deleteText",{get:function(){return G.getString("pe.delete")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"ifText",{get:function(){return G.getString("pe.if")},enumerable:!1,configurable:!0}),e.prototype.isSuitable=function(e,t){return void 0===t&&(t=""),!e&&!t||(e?t?(this.isSuitableInExpression(e)||this.isSuitableByNameInActions(e))&&this.isSuitableByLogicTypeInActions(t):this.isSuitableInExpression(e)||this.isSuitableByNameInActions(e):this.isSuitableByLogicTypeInActions(t))},e.prototype.isSuitableInExpression=function(e){return-1!==this.expression.indexOf(E(e))||-1!==this.expression.indexOf("'"+e+".")},e.prototype.isSuitableByNameInActions=function(e){return this.actions.some((function(t){return t.isSuitableByQuestionName(e)}))},e.prototype.isSuitableByLogicTypeInActions=function(e){return this.actions.some((function(t){return t.isSuitableByLogicType(e)}))},e.prototype.renameQuestionInExpression=function(e,t,o){var n=this;if(this.expression&&(e=e.toLowerCase(),this.isStrContainsInExpression(e))){var r=i.logic.openBracket;e=r+e,t=r+t;var a=this.expression;o.forEach((function(o){a=n.renameQuestionInExpressionCore(a,a.toLocaleLowerCase(),e+o,t+o)})),a!=this.expression&&this.applyExpression(a,!0)}},e.prototype.renameQuestionInExpressionCore=function(e,t,o,i){for(var n=t.lastIndexOf(o,t.length);n>-1;)e=e.substring(0,n)+i+e.substring(n+o.length),n=(t=t.substring(0,n)).lastIndexOf(o,n);return e},e.prototype.removeQuestionInExpression=function(e){if(this.expression){var t=(new _e).remove(this.expression,e);t!=this.expression&&this.applyExpression(t,!0)}},e.prototype.applyExpression=function(e,t){this.expression=e;for(var o=this.actions,i=0;i<o.length;i++)o[i].apply(e,t)},e.prototype.removeActions=function(){for(var e=this.actions,t=e.length-1;t>=0;t--)this.removeAction(e[t])},e.prototype.removeSameActions=function(){for(var e=this.actions,t=e.length-1;t>=0;t--)for(var o=t-1;o>=0;o--)if(e[t].equals(e[o])){this.removeAction(e[t]);break}},e.counter=0,e}();function Fe(e){e.popupModel.isFocusedContent=!0,e.popupModel.setWidthByTarget=!1,e.popupModel.positionMode="flex",e.popupModel.showPointer=!0,e.dropdownListModel.listModel.searchEnabled=e.searchEnabled}r(5377);var Qe=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.EventBase),Ue=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this)||this;return i.survey=t,i.options=o,i.invisibleItems=[],i.onLogicItemSaved=new Qe,i.onLogicItemValidation=new Qe,i.onLogicItemRemoving=new Qe,i.onLogicItemRemoved=new Qe,i.options||(i.options=new n),i.readOnly=i.optionsReadOnly,i.update(),i}return K(t,e),Object.defineProperty(t,"visibleActions",{get:function(){return i.logic.visibleActions},set:function(e){i.logic.visibleActions=e},enumerable:!1,configurable:!0}),Object.defineProperty(t,"types",{get:function(){return Re.types},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.onEndEditing(),this.survey=void 0},Object.defineProperty(t.prototype,"editableItem",{get:function(){return this.editableItemValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"mode",{get:function(){return this.modeValue},set:function(e){if(this.modeValue!==e){var t=this.mode;this.modeValue=e,this.errorText="","view"!=e||"edit"!=t&&"new"!=t||this.onEndEditing()}},enumerable:!1,configurable:!0}),t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.getTypeByName=function(e){for(var t=0;t<this.logicTypes.length;t++)if(this.logicTypes[t].name==e)return this.logicTypes[t];return null},t.prototype.update=function(e,t){void 0===e&&(e=null),void 0===t&&(t=null),e&&(this.survey=e),t&&(this.options=t),this.logicTypes=this.createLogicTypes(),this.updateVisibleItems(),this.invisibleItems=this.buildItems(!1),this.readOnly=this.optionsReadOnly,this.mode="view"},t.prototype.updateVisibleItems=function(){this.items=this.buildItems(!0),this.editableItemValue=null},Object.defineProperty(t.prototype,"optionsReadOnly",{get:function(){return!!this.options&&this.options.readOnly},enumerable:!1,configurable:!0}),t.prototype.saveEditableItem=function(){if(!this.editableItem||this.hasError())return!1;this.options&&this.options.startUndoRedoTransaction(),this.onEditableItemApply();var e=this.items.indexOf(this.editableItem)<0;e&&this.items.push(this.editableItem);var t=!e||this.editableItem.isNew;return this.editableItem.isNew=!1,this.onItemChanged(this.editableItem,t?"new":"modify"),this.options&&this.options.stopUndoRedoTransaction(),this.onLogicItemSaved.fire(this,{item:this.editableItem}),!0},t.prototype.saveEditableItemAndBack=function(){var e=this.saveEditableItem();return e&&(this.mode="view"),e},t.prototype.onEditableItemApply=function(){},t.prototype.onItemChanged=function(e,t){this.onChangedCallback&&this.onChangedCallback(e,t)},t.prototype.renameQuestion=function(e,t){this.items.forEach((function(o){return o.renameQuestion(e,t)})),this.invisibleItems.forEach((function(o){return o.renameQuestion(e,t)}))},t.prototype.renameItemValue=function(e,t){var o=this.getItemValueQuestion(e,t);o&&(this.items.forEach((function(i){return i.renameItemValue(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameItemValue(o,e,t)})))},t.prototype.renameRowValue=function(e,t){var o=this.getItemValueQuestion(e,t);o&&(this.items.forEach((function(i){return i.renameRowValue(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameRowValue(o,e,t)})))},t.prototype.renameColumn=function(e,t){var o=e.colOwner;o&&o.isQuestion&&(this.items.forEach((function(i){return i.renameColumn(o,e,t)})),this.invisibleItems.forEach((function(i){return i.renameColumn(o,e,t)})))},t.prototype.getItemValueQuestion=function(e,t){if(!e.locOwner||o.Helpers.isValueEmpty(t)||o.Helpers.isValueEmpty(e.value))return null;var i=e.locOwner;return i.isQuestion?i:null},t.prototype.removeQuestion=function(e){this.removeQuestionCore(e,this.items),this.removeQuestionCore(e,this.invisibleItems)},t.prototype.hasError=function(){if(!this.editableItem)return!1;if(this.hasErrorInUI())return!0;var e=new o.ExpressionRunner(this.getExpressionText()),t={item:this.editableItem,error:"",usedNamesInExpression:e.getVariables(),actions:this.getEditingActions()};this.onLogicItemValidation.fire(this,t),this.errorText=t.error;var i=this.survey.creator;return this.errorText&&i&&i.notify(this.errorText,"error"),!!this.errorText},t.prototype.getUsedQuestions=function(){var e=this,t={};this.items.forEach((function(o){o.getQuestionNames().forEach((function(o){var i=e.survey.getQuestionByName(o);i&&!t[o]&&(t[o]=i)}))}));var o=[];return Object.keys(t).forEach((function(e){t[e]&&o.push(t[e])})),o},t.prototype.getUsedActionTypes=function(){var e=this,t={};this.items.forEach((function(o){o.getActionTypes().forEach((function(o){t[o]||(t[o]=e.logicTypes.filter((function(e){return e.name==o}))[0])}))}));var o=[];return Object.keys(t).forEach((function(e){t[e]&&o.push(t[e])})),o},t.prototype.hasErrorInUI=function(){return!1},t.prototype.getExpressionText=function(){return""},t.prototype.getEditingActions=function(){return[]},t.prototype.onReadOnlyChanged=function(){},t.prototype.removeQuestionCore=function(e,t){for(var o=0;o<t.length;o++)t[o].removeQuestion(e)},t.prototype.addNew=function(){this.options&&this.options.startUndoRedoTransaction();var e=new He(this);e.isNew=!0,this.items.push(e),this.editItemCore(e),this.options&&this.options.stopUndoRedoTransaction()},t.prototype.editItem=function(e){this.options&&this.options.startUndoRedoTransaction(),this.editItemCore(e),this.options&&this.options.stopUndoRedoTransaction()},t.prototype.editItemCore=function(e){this.editableItemValue=e,this.onStartEditing(),this.mode=e.isNew?"new":"edit"},t.prototype.onStartEditing=function(){},t.prototype.onEndEditing=function(){this.editableItemValue=null},t.prototype.canRemoveItem=function(e){var t={item:e,allowRemove:!0};return this.onLogicItemRemoving.fire(this,t),t.allowRemove},t.prototype.removeItem=function(e,t){if(void 0===t&&(t=!0),!t||this.canRemoveItem(e)){this.options&&this.options.startUndoRedoTransaction(),e.apply("");var o=this.items.indexOf(e);o>-1&&this.items.splice(o,1),this.onItemChanged(e,"delete"),this.options&&this.options.stopUndoRedoTransaction(),this.onLogicItemRemoved.fire(this,{item:e})}},t.prototype.addAction=function(e,t){void 0===t&&(t=null);var o=this.createNewAction(e,t);return this.editableItem.addNewAction(o),o},t.prototype.addNewAction=function(){return this.addAction(null,null)},t.prototype.createNewAction=function(e,t){return new qe(e,t,this.survey)},t.prototype.getVisibleLogicTypes=function(){for(var e=[],t=this.logicTypes,o=0;o<t.length;o++)t[o].visible&&e.push(t[o]);return e},t.prototype.removeAction=function(e){this.editableItem&&(this.editableItem.removeAction(e),0==this.editableItem.actions.length&&this.addNewAction())},t.prototype.getExpressionAsDisplayText=function(e){return je.expressionToDisplayText(this.survey,this.options,e)},t.prototype.buildItems=function(e){for(var t=[],o={},i=this.getAllElements(),n=0;n<i.length;n++)this.buildItemsByElement(i[n],t,o,e);return t},t.prototype.getAllElements=function(){var e=[];return this.AddElements(this.survey.pages,e),this.AddElements(Re.baseTypes.question.getSelectorChoices(this.survey,null),e),this.AddElements(this.survey.getAllPanels(),e),this.AddElements(this.survey.triggers,e),this.AddElements(this.survey.completedHtmlOnCondition,e),this.AddElements(this.survey.calculatedValues,e),this.AddElements(Re.baseTypes.matrixdropdowncolumn.getSelectorChoices(this.survey,null),e),this.AddElements(this.getValidators(),e),this.AddElements(this.getItemValues(),e),e},t.prototype.getValidators=function(){for(var e=[],t=this.survey.getAllQuestions(),o=0;o<t.length;o++)this.AddElements(t[o].validators,e);return e},t.prototype.getItemValues=function(){for(var e=[],t=this.survey.getAllQuestions(),i=0;i<t.length;i++){var n=t[i],r=n.choices;if(r){var a=o.Serializer.findProperty(n.getType(),"choices");a&&"itemvalue[]"===a.type&&this.AddElements(r,e)}}return e},t.prototype.AddElements=function(e,t){for(var o=0;o<e.length;o++)t.push(e[o])},t.prototype.buildItemsByElement=function(e,t,i,n){for(var r=this.getElementAllTypes(e),a=0;a<this.logicTypes.length;a++){var s=this.logicTypes[a];if(s.showInUI===n){var l=e[s.propertyName];if(r.indexOf(s.baseClass)>-1&&!o.Helpers.isValueEmpty(l)){var u=this.getLogicItemHashKey(l,e),p=i[u];p||(p=new He(this,l),i[u]=p,t.push(p));var c=this.createNewAction(s,e);p.addNewAction(c)}}}},t.prototype.getLogicItemHashKey=function(e,t){var o=this.getParentQuestion(t);return(o?"@"+o.name:"")+e.replace(" ","").toLowerCase()},t.prototype.getParentQuestion=function(e){return e.parentQuestion||(e.isDescendantOf("matrixdropdowncolumn")?e.colOwner:null)},t.prototype.getElementAllTypes=function(e){var t=[],i=e.getType();for(t.push(i);i&&"base"!=i;){var n=o.Serializer.findClass(i);if(!n)break;(i=n.parentName)&&t.push(i)}return t},t.prototype.createLogicTypes=function(){for(var e=[],o=t.visibleActions,i=0;i<t.types.length;i++)o.length>0&&o.indexOf(t.types[i].name)<0||e.push(new je(t.types[i],this.survey,this.options));return e},J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.propertyArray)()],t.prototype,"logicTypes",void 0),J([(0,o.property)()],t.prototype,"errorText",void 0),J([(0,o.property)({onSet:function(e,t){t.onReadOnlyChanged()}})],t.prototype,"readOnly",void 0),J([(0,o.property)()],t.prototype,"placeholderHtml",void 0),t}(o.Base),Ge=r(4809),Ze=function(){function e(e){this.objValue=e,this.editableObjValue=this.createEditableObj()}return e.isCopyObject=function(e){return!!e&&e.isCopy},e.getSurvey=function(t){if(t instanceof o.SurveyModel||t&&t.getType&&"survey"==t.getType())return e.getOriginalSurvey(t);if(t instanceof o.MatrixDropdownColumn&&t.colOwner)return t.colOwner.survey;if(t){if(t.survey)return e.getOriginalSurvey(t.survey);if(t.owner)return e.getSurvey(t.owner);if(t.errorOwner)return e.getSurvey(t.errorOwner);if(t.locOwner)return e.getSurvey(t.locOwner)}var i=e.getOriginalObject(t);return i&&i!==t?e.getSurvey(i):null},e.getOriginalObject=function(e){return e&&e.originalObj?e.originalObj:e},e.getOriginalSurvey=function(t){return e.getOriginalObject(t)},Object.defineProperty(e.prototype,"obj",{get:function(){return this.objValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"editableObj",{get:function(){return this.editableObjValue},enumerable:!1,configurable:!0}),e.prototype.isPropertyChanged=function(e){return"pages"!=e&&!o.Helpers.isTwoValueEquals(this.obj[e],this.editableObj[e])},e.prototype.apply=function(e){this.isPropertyChanged(e)&&(this.obj[e]=this.editableObj[e])},e.prototype.reset=function(){this.assignProperties(this.editableObj)},e.prototype.applyAll=function(e){void 0===e&&(e=[]);for(var t=this.getProperties(e),o=0;o<t.length;o++)this.apply(t[o])},e.prototype.getProperties=function(e){var t=[],o=this.getObjJson(this.editableObj),i=this.getObjJson(this.obj);for(var n in o)e.indexOf(n)>-1||t.push(n);for(var n in i)e.indexOf(n)>-1||t.indexOf(n)>-1||t.push(n);return t},e.prototype.createEditableObj=function(){var e=this.obj.getType(),t=o.Serializer.createClass(e);return null==t&&"survey"==e&&(t=new o.SurveyModel),this.assignProperties(t),"matrixdropdowncolumn"==e&&(t.colOwner=this.obj.colOwner),"survey"!=e&&(t.setSurveyImpl?t.setSurveyImpl(this.obj.survey):this.obj.survey&&!t.survey&&(t.survey=this.obj.survey)),this.obj.parent&&(t.parent=this.obj.parent),t.isCopy=!0,t.originalObj=this.obj,t},e.prototype.assignProperties=function(e){(new o.JsonObject).toObject(this.getObjJson(),e)},e.prototype.getObjJson=function(e){void 0===e&&(e=null),e||(e=this.obj);var t=new o.JsonObject;return t.lightSerializing=!0,t.toJsonObject(e)},e}(),ze={root:"spg-root-modern",container:"spg-container-modern",header:"spg-title spg-container-modern__title",body:"spg-body",bodyEmpty:"spg-body spg-body--empty",footer:"spg-footer spg-body__footer spg-clearfix",title:"",description:"",logo:"spg-logo",logoImage:"spg-logo__image",headerText:"spg-header__text",navigationButton:"",completedPage:"spg-completedpage",navigation:{complete:"spg-btn spg-footer__complete-btn",prev:"spg-btn spg-footer__prev-btn",next:"spg-btn spg-footer__next-btn",start:"spg-btn spg-footer__start-btn",preview:"spg-btn spg-footer__preview-btn",edit:"spg-btn spg-footer__edit-btn"},panel:{expandableAnimating:"",title:"spg-title spg-panel__title",contentEnter:"spg-panel__content--enter",contentLeave:"spg-panel__content--leave",titleExpandable:"spg-panel__title--expandable",titleExpanded:"spg-panel__title--expanded",titleCollapsed:"spg-panel__title--collapsed",titleOnError:"spg-panel__title--error",description:"spg-description spg-panel__description",container:"spg-panel spg-row__panel",content:"spg-panel__content",icon:"spg-panel__icon",iconExpanded:"spg-panel__icon--expanded",footer:"spg-panel__footer",requiredText:"spg-panel__required-text"},paneldynamic:{mainRoot:"spg-question spg-row__question",root:"spg-paneldynamic",navigation:"spg-paneldynamic__navigation",title:"spg-title spg-question__title",button:"spg-action-button spg-action-button--text",buttonRemove:"spg-action-button--danger",buttonAdd:"spg-paneldynamic__add-btn",panelsContainer:"",panelWrapper:"spg-paneldynamic__panel-wrapper",panelWrapperList:"",progressTop:"spg-paneldynamic__progress spg-paneldynamic__progress--top",progressBottom:"spg-paneldynamic__progress spg-paneldynamic__progress--bottom",buttonPrev:"spg-paneldynamic__prev-btn",buttonNext:"spg-paneldynamic__next-btn",progressContainer:"spg-paneldynamic__progress-container",progress:"spg-progress",progressBar:"spg-progress__bar",progressText:"spg-paneldynamic__progress-text",panelFooter:"spg-panel__footer",separator:"spg-paneldynamic__separator"},progress:"spg-progress spg-body__progress",progressBar:"spg-progress__bar",progressText:"spg-progress__text",progressTextInBar:"spg-hidden",page:{root:"spg-page spg-body__page",title:"spg-title spg-page__title",description:"spg-description spg-page__description"},pageTitle:"spg-title spg-page__title",pageDescription:"spg-description spg-page__description",row:"spg-row spg-clearfix",rowEnter:"spg-row--enter",rowLeave:"spg-row--leave",rowDelayedEnter:"spg-row--delayed-fade-in",rowMultiple:"spg-row--multiple",question:{mainRoot:"spg-question spg-row__question",flowRoot:"spg-question spg-row__question spg-row__question--flow",asCell:"spg-table__cell",header:"spg-question__header",headerLeft:"spg-question__header--location--left",headerTop:"spg-question__header--location--top",headerBottom:"spg-question__header--location--bottom",content:"spg-question__content",contentLeft:"spg-question__content--left",titleLeftRoot:"spg-question--location--left",titleOnAnswer:"spg-question__title--answer",titleOnError:"spg-question__title--error",title:"spg-title spg-question__title",requiredText:"spg-question__required-text",number:"spg-question__num",description:"spg-description spg-question__description",descriptionUnderInput:"spg-description spg-question__description",comment:"spg-comment",required:"spg-question--required",titleRequired:"spg-question__title--required",indent:0,footer:"spg-question__footer",formGroup:"spg-question__form-group",hasError:"",disabled:"spg-question--disabled"},image:{root:"spg-image",image:"sv_image_image"},error:{root:"spg-question__erbox",icon:"spg-question__erbox-icon",item:"",locationTop:"spg-question__erbox--location--top",locationBottom:"spg-question__erbox--location--bottom"},checkbox:{root:"spg-selectbase",item:"spg-item spg-checkbox spg-selectbase__item",itemSelectAll:"spg-checkbox--selectall",itemNone:"spg-checkbox--none",itemDisabled:"spg-item--disabled spg-checkbox--disabled",itemChecked:"spg-checkbox--checked",itemHover:"spg-checkbox--allowhover",itemInline:"spg-selectbase__item--inline",label:"spg-selectbase__label",itemSvgIconId:"#icon-v2check",labelChecked:"",itemControl:"spg-checkbox__control",itemDecorator:"spg-checkbox__svg",controlLabel:"spg-checkbox__caption",materialDecorator:"spg-checkbox__rectangle",other:"spg-comment spg-question__other",column:"spg-selectbase__column"},radiogroup:{root:"spg-selectbase",item:"spg-item spg-radio spg-selectbase__item",itemInline:"spg-selectbase__item--inline",label:"spg-selectbase__label",labelChecked:"",itemDisabled:"spg-item--disabled spg-radio--disabled",itemChecked:"spg-radio--checked",itemHover:"spg-radio--allowhover",itemControl:"spg-visuallyhidden spg-item__control",itemDecorator:"spg-item__svg spg-radio__svg",controlLabel:"spg-item__control-label",materialDecorator:"spg-item__decorator spg-radio__decorator",other:"spg-comment spg-question__other",clearButton:"spg-btn spg-selectbase__clear-btn",column:"spg-selectbase__column"},boolean:{mainRoot:"spg-question spg-row__question spg-question--boolean",rootCheckbox:"spg-selectbase",checkboxItem:"spg-checkbox",checkboxItemChecked:"spg-checkbox--checked",checkboxitemIndeterminate:"spg-checkbox--indeterminate",checkboxItemDisabled:"spg-checkbox--disabled",svgIconId:"#icon-v2check",checkboxLabel:"spg-selectbase__label",controlCheckbox:"spg-checkbox__control",checkboxControlLabel:"spg-checkbox__caption",checkboxItemDecorator:"spg-checkbox__svg",checkboxMaterialDecorator:"spg-checkbox__rectangle"},text:{root:"spg-input spg-text",small:"spg-row__question--small",content:"spg-question__content spg-text__content",remainingCharacterCounter:"spg-remaining-character-counter",onError:"spg-input--error"},multipletext:{root:"spg-multipletext",item:"spg-multipletext__item",itemTitle:"spg-multipletext__item-title",content:"spg-multipletext__content spg-text__content",row:"spg-multipletext__row",cell:"spg-multipletext__cell"},dropdown:{root:"",popup:"spg-dropdown-popup svc-creator-popup",small:"spg-row__question--small sd-row__question--small",control:"spg-input spg-dropdown sd-input sd-dropdown",filterStringInput:"sd-dropdown__filter-string-input spg-dropdown__filter-string-input",other:"spg-comment spg-question__other",onError:"spg-input--error",selectWrapper:"sv-dropdown_select-wrapper spg-dropdown_select-wrapper",chevronButton:"sd-dropdown_chevron-button spg-dropdown_chevron-button",chevronButtonSvg:"sd-dropdown_chevron-button-svg",chevronButtonIconId:"icon-chevron"},imagepicker:{root:"spg-imagepicker",item:"spg-imagepicker__item",itemInline:"spg-imagepicker__item--inline",itemChecked:"spg-imagepicker__item--checked",itemDisabled:"spg-imagepicker__item--disabled",itemHover:"spg-imagepicker__item--allowhover",label:"spg-imagepicker__label",itemControl:"spg-imagepicker__control",image:"spg-imagepicker__image",itemText:"spg-imagepicker__text",clearButton:"spg-btn",other:"spg-comment spg-question__other"},matrix:{tableWrapper:"spg-matrix spg-table-wrapper",root:"spg-table",rowError:"spg-matrix__row--error",cell:"spg-table__cell spg-matrix__cell",headerCell:"spg-table__cell spg-table__cell--header",label:"spg-item spg-radio spg-matrix__label",itemValue:"spg-visuallyhidden spg-item__control spg-radio__control",itemChecked:"spg-radio--checked",itemDisabled:"spg-item--disabled spg-radio--disabled",itemHover:"spg-radio--allowhover",materialDecorator:"spg-item__decorator spg-radio__decorator",itemDecorator:"spg-item__svg spg-radio__svg",cellText:"spg-matrix__text",cellTextSelected:"spg-matrix__text--checked",cellTextDisabled:"spg-matrix__text--disabled"},matrixdropdown:{tableWrapper:"spg-table-wrapper",root:"spg-table",cell:"spg-table__cell",headerCell:"spg-table__cell spg-table__cell--header",emptyCell:"spg-table__cell--empty",rowEnter:"spg-table__row--enter",rowLeave:"spg-table__row--leave"},matrixdynamic:{tableWrapper:"spg-table-wrapper",root:"spg-table spg-matrixdynamic",content:"spg-matrixdynamic__content spg-text__content",cell:"spg-table__cell",headerCell:"spg-table__cell spg-table__cell--header",button:"spg-btn",detailRow:"spg-table__row spg-table__row--detail",detailButton:"spg-table__cell--detail-button",detailButtonExpanded:"spg-table__cell--detail-button--expanded",detailIcon:"spg-detail-panel__icon",detailIconExpanded:"spg-detail-panel__icon--expanded",detailPanelCell:"spg-table__cell--detail-panel",actionsCell:"spg-table__cell spg-table__cell--actions",buttonAdd:"spg-matrixdynamic__add-btn spg-action-button spg-action-button--large",buttonRemove:"spg-matrixdynamic__remove-btn",iconAdd:"",iconRemove:"",dragElementDecorator:"spg-drag-element__svg",iconDragElement:"#icon-drag-area-indicator",iconDrag:"spg-matrixdynamic__drag-element",footer:"",dragDropGhostPositionTop:"spg-matrixdynamic__drag-drop-ghost-position-top",dragDropGhostPositionBottom:"spg-matrixdynamic__drag-drop-ghost-position-bottom",emptyRowsSection:"spg-matrixdynamic__placeholder",emptyRowsText:"spg-matrixdynamic__placeholder-text",cellQuestionWrapper:"spg-table__question-wrapper",emptyCell:"spg-table__cell--empty",rowEnter:"spg-table__row--enter",rowLeave:"spg-table__row--leave"},rating:{root:"spg-rating",item:"spg-rating__item",selected:"spg-rating__item--selected",minText:"spg-rating__min-text",itemText:"spg-rating__item-text",maxText:"spg-rating__max-text",disabled:"spg-rating--disabled"},comment:{root:"spg-input spg-comment",content:"spg-question__content spg-comment__content",remainingCharacterCounter:"spg-remaining-character-counter",small:"spg-row__question--small",onError:"spg-input--error"},expression:"",file:{root:"spg-file",other:"spg-comment spg-question__other",placeholderInput:"spg-visuallyhidden",preview:"spg-file__preview",fileSign:"spg-hidden",fileSignBottom:"spg-file__sign",fileDecorator:"spg-file__decorator",fileInput:"spg-visuallyhidden",noFileChosen:"spg-description spg-file__no-file-chosen",chooseFile:"spg-btn spg-file__choose-btn",disabled:"spg-file__choose-btn--disabled",removeButton:"spg-hidden",removeButtonBottom:"spg-btn spg-file__clean-btn",removeFile:"spg-hidden",removeFileSvg:"spg-file__remove-svg",wrapper:"spg-file__wrapper"},signaturepad:{root:"spg-signaturepad sjs_sp_container",small:"spg-row__question--small",controls:"sjs_sp_controls",clearButton:"sjs_sp_clear"},propertygrid_bindings:{content:"spg-question__content spg-question__nopadding spg-question-group"},propertygrid_restfull:{content:"spg-question__content spg-question__nopadding spg-restfull"},propertygrid_masksettings:{content:"spg-question__content spg-question__nopadding spg-masksettings"},propertygrid_header:{mainRoot:"spg-header",content:"spg-question__content spg-question__nopadding"},coloralpha:{content:"spg-question__content spg-question__nopadding spg-question__content-coloralpha"},font:{content:"spg-question__content spg-question__nopadding spg-question-composite__content"},backgroundcornerradius:{content:"spg-question__content spg-question__nopadding spg-question-composite__content"},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"sv_window",body:"sv_window_content",header:{root:"sv_window_title",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}},actionBar:{root:"spg-action-bar",item:"spg-action-button",itemPressed:"spg-action-button--pressed",itemAsIcon:"spg-action-button--icon",itemIcon:"spg-action-button__icon",itemTitle:"spg-action-button__title"},spinedit:{root:"spg-input spg-spin-editor spg-input-container",control:"spg-spin-editor__input spg-input-container__input",buttonsContainer:"spg-input-container__buttons-container",arrowButton:"spg-input__edit-button",increaseButtonIcon:"icon-arrow-up",decreaseButtonIcon:"icon-arrow-down"},color:{root:"spg-input spg-color-editor spg-input-container",swatch:"spg-color-editor__color-swatch",swatchDefault:"spg-color-editor__color-swatch--default",swatchDisabled:"spg-color-editor__color-swatch--disabled",colorInput:"spg-color-editor__color-input",control:"spg-color-editor__input spg-input-container__input",colorDropdown:"spg-input__edit-button",colorDropdownIcon:"icon-drop-down-arrow",colorItem:"spg-color-editor__color-item",swatchIcon:"icon-color-picker"},textwithreset:{root:"spg-input spg-input-container",rootMultiline:"spg-input-container--multiline",control:"spg-input-container__input",controlMultiline:"spg-input-container__input spg-comment",resetButton:"spg-input__edit-button",resetButtonIcon:"icon-reset",content:"spg-question__content spg-text__content",remainingCharacterCounter:"spg-remaining-character-counter",onError:"spg-input--error"},fileedit:{root:"spg-input spg-input-container spg-file-edit",control:"spg-input-container__input",buttonsContainer:"spg-input-container__buttons-container",chooseButtonIcon:"icon-file",clearButtonIcon:"icon-clear",fileInput:"sd-visuallyhidden",clearButton:"spg-input__edit-button",chooseButton:"spg-input__edit-button spg-file-edit__choose-button",chooseButtonDisabled:"spg-input__edit-button--disabled"},linkvalue:{content:"spg-link"}},Je={question:{properties:["name","title","description","visible","readOnly","isRequired","showCommentArea","commentText","commentPlaceholder",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"bindings",tab:"logic"},{name:"defaultValueExpression",tab:"logic"},{name:"resetValueIf",tab:"logic"},{name:"setValueIf",tab:"logic"},{name:"setValueExpression",tab:"logic"},{name:"page",tab:"layout"},{name:"startWithNewLine",tab:"layout"},{name:"hideNumber",tab:"layout"},{name:"state",tab:"layout"},{name:"titleLocation",tab:"layout"},{name:"descriptionLocation",tab:"layout"},{name:"errorLocation",tab:"layout"},{name:"indent",tab:"layout"},{name:"width",tab:"layout"},{name:"minWidth",tab:"layout"},{name:"maxWidth",tab:"layout"},{name:"effectiveColSpan",tab:"layout"},{name:"valueName",tab:"data"},{name:"defaultValue",tab:"data"},{name:"correctAnswer",tab:"data"},{name:"useDisplayValuesInDynamicTexts",tab:"data"},{name:"clearIfInvisible",tab:"data"},{name:"validators",tab:"validation"},{name:"requiredErrorText",tab:"validation"}],tabs:[{name:"layout",index:100},{name:"logic",index:200},{name:"data",index:300},{name:"validation",index:400}]},comment:{properties:[{name:"rows",tab:"layout"},{name:"cols",tab:"layout"},"placeholder",{name:"maxLength",tab:"validation"},{name:"textUpdateMode",tab:"data"},{name:"autoGrow",tab:"layout"},{name:"allowResize",tab:"layout"}]},file:{properties:["sourceType","visible","readOnly","isRequired","showCommentArea","allowMultiple",{name:"showPreview"},"allowImagesPreview","waitForUpload","needConfirmRemoveFile",{name:"storeDataAsText"},"allowCameraAccess","acceptedTypes","maxSize","imageHeight","imageWidth","filePlaceholder","photoPlaceholder","fileOrPhotoPlaceholder"]},signaturepad:{properties:["dataFormat","signatureWidth","signatureHeight","signatureAutoScaleEnabled","showPlaceholder","placeholder","placeholderReadOnly","allowClear","backgroundImage","backgroundColor","penMinWidth","penMaxWidth","penColor","waitForUpload",{name:"storeDataAsText"}]},html:{properties:["html"]},matrixdropdownbase:{properties:["cellType","optionsCaption","detailPanelMode","detailPanelShowOnAdding",{name:"showHeader",tab:"layout"},{name:"showColumnHeader",tab:"layout"},{name:"verticalAlign",tab:"layout"},{name:"alternateRows",tab:"layout"},{name:"columnsVisibleIf",tab:"logic"},{name:"rowsVisibleIf",tab:"logic"},{name:"columnLayout",tab:"layout"},{name:"transposeData",tab:"layout"},{name:"horizontalScroll",tab:"layout"},{name:"columnColCount",tab:"layout"},{name:"columnMinWidth",tab:"layout"},{name:"cellErrorLocation",tab:"layout"},{name:"detailErrorLocation",tab:"layout"}],tabs:[{name:"columns",index:10},{name:"rows",index:11},{name:"choices",index:12}]},matrixdynamic:{properties:["allowAddRows","allowRemoveRows","allowRowsDragAndDrop","rowCount","minRowCount","maxRowCount","addRowLocation","addRowText","removeRowText","confirmDelete","confirmDeleteText","placeholder",{name:"hideColumnsIfEmpty",tab:"columns"},{name:"emptyRowsText",tab:"columns"},{name:"defaultRowValue",tab:"data"},{name:"defaultValueFromLastRow",tab:"data"},{name:"keyName",tab:"validation"},{name:"keyDuplicationError",tab:"validation"}]},matrixdropdown:{properties:["totalText","placeholder",{name:"hideIfRowsEmpty",tab:"rows"},{name:"rowTitleWidth",tab:"layout"},{name:"keyDuplicationError",tab:"validation"}]},matrix:{properties:[{name:"isAllRowRequired",tab:"validation"},{name:"eachRowUnique",tab:"validation"},{name:"showHeader",tab:"layout"},{name:"showColumnHeader",tab:"layout"},{name:"verticalAlign",tab:"layout"},{name:"alternateRows",tab:"layout"},{name:"rowsOrder",tab:"rows"},{name:"hideIfRowsEmpty",tab:"rows"},{name:"columnsVisibleIf",tab:"logic"},{name:"rowsVisibleIf",tab:"logic"},{name:"columnMinWidth",tab:"layout"},{name:"rowTitleWidth",tab:"layout"}],tabs:[{name:"columns",index:10},{name:"rows",index:11},{name:"cells",index:500}]},multipletext:{properties:[{name:"colCount",tab:"layout"},{name:"itemSize",tab:"layout"},{name:"itemErrorLocation",tab:"layout"}],tabs:[{name:"items",index:10}]},rating:{properties:[{name:"displayMode",tab:"rateValues"},{name:"rateCount",tab:"rateValues"},{name:"rateMin",tab:"rateValues"},{name:"rateMax",tab:"rateValues"},{name:"rateStep",tab:"rateValues"},{name:"minRateDescription",tab:"rateValues"},{name:"maxRateDescription",tab:"rateValues"},{name:"rateDescriptionLocation",tab:"rateValues"},{name:"displayRateDescriptionsAsExtremeItems",tab:"rateValues"}],tabs:[{name:"rateValues",index:10}]},selectbase:{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"layout"},{name:"textWrapEnabled",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"hideIfChoicesEmpty",tab:"logic"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"},{name:"otherErrorText",tab:"validation"},{name:"separateSpecialChoices",tab:"choices"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},checkbox:{properties:[{name:"showSelectAllItem",tab:"choices"},{name:"selectAllText",tab:"choices"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"},{name:"separateSpecialChoices",tab:"choices"}]},ranking:{properties:[{name:"selectToRankEnabled"},{name:"selectToRankAreasLayout"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"}]},radiogroup:{properties:[{name:"showClearButton",tab:"choices"},{name:"separateSpecialChoices",tab:"choices"}]},dropdown:{properties:["placeholder","autocomplete",{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"searchMode",tab:"choices"}]},tagbox:{properties:["closeOnSelect","placeholder",{name:"searchEnabled",tab:"choices"},{name:"searchMode",tab:"choices"},{name:"hideSelectedItems",tab:"choices"},{name:"allowClear",tab:"choices"}]},imagepicker:{properties:["contentMode","imageFit","isResponsive","minImageWidth","maxImageWidth","minImageHeight","maxImageHeight","imageHeight","imageWidth","multiSelect","showLabel"]},image:{properties:["imageLink","contentMode","imageFit","imageHeight","imageWidth","text"]},"itemvalue[]@choices":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},"itemvalue[]@rows":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},"itemvalue[]@columns":{properties:[{name:"visibleIf"},{name:"enableIf"}],tabs:[{name:"general"}]},text:{properties:["inputType","min","max","step","placeholder","autocomplete","dataList",{name:"minValueExpression",tab:"logic"},{name:"maxValueExpression",tab:"logic"},{name:"size",tab:"layout"},{name:"inputTextAlignment",tab:"layout"},{name:"maxLength",tab:"validation"},{name:"minErrorText",tab:"validation"},{name:"maxErrorText",tab:"validation"},{name:"textUpdateMode",tab:"data"},{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"mask",index:250}]},boolean:{properties:["label","labelTrue","labelFalse","showTitle",{name:"valueTrue",tab:"data"},{name:"valueFalse",tab:"data"}]},expression:{properties:["expression","displayStyle","currency","format","maximumFractionDigits","minimumFractionDigits","useGrouping"]},panellayoutcolumn:{properties:["effectiveWidth","questionTitleWidth"]},matrixdropdowncolumn:{properties:["name","title"]},"matrixdropdowncolumn@default":{properties:["name","title","cellType","visible","readOnly","isRequired","isUnique","showInMultipleColumns","width","minWidth",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"defaultValueExpression",tab:"logic"},{name:"resetValueIf",tab:"logic"},{name:"setValueIf",tab:"logic"},{name:"setValueExpression",tab:"logic"},{name:"totalType",tab:"totals"},{name:"totalDisplayStyle",tab:"totals"},{name:"totalCurrency",tab:"totals"},{name:"totalFormat",tab:"totals"},{name:"totalExpression",tab:"totals"},{name:"validators",tab:"validation"},{name:"requiredErrorText",tab:"validation"}],tabs:[{name:"general",index:5},{name:"logic",index:20},{name:"totals",index:40},{name:"validation",index:60}]},"matrixdropdowncolumn@checkbox":{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"choices"},{name:"showSelectAllItem",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"minSelectedChoices",tab:"choices"},{name:"maxSelectedChoices",tab:"choices"},{name:"selectAllText",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@radiogroup":{properties:[{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"colCount",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@dropdown":{properties:["placeholder",{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"optionsCaption",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@tagbox":{properties:["placeholder",{name:"choicesFromQuestion",tab:"choices"},{name:"choicesFromQuestionMode",tab:"choices"},{name:"choiceValuesFromQuestion",tab:"choices"},{name:"choiceTextsFromQuestion",tab:"choices"},{name:"showOtherItem",tab:"choices"},{name:"otherText",tab:"choices"},{name:"otherPlaceholder",tab:"choices"},{name:"choicesOrder",tab:"choices"},{name:"optionsCaption",tab:"choices"},{name:"showNoneItem",tab:"choices"},{name:"noneText",tab:"choices"},{name:"showRefuseItem",tab:"choices"},{name:"refuseText",tab:"choices"},{name:"showDontKnowItem",tab:"choices"},{name:"dontKnowText",tab:"choices"},{name:"choicesMin",tab:"choices"},{name:"choicesMax",tab:"choices"},{name:"choicesStep",tab:"choices"},{name:"allowClear",tab:"choices"},{name:"choicesVisibleIf",tab:"logic"},{name:"choicesEnableIf",tab:"logic"}],tabs:[{name:"choices",index:10},{name:"choicesByUrl",index:11}]},"matrixdropdowncolumn@text":{properties:["inputType","min","max","step","placeholder","dataList","maxLength",{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"mask",index:20},{name:"validators",index:25}]},"matrixdropdowncolumn@comment":{properties:["rows","placeholder","maxLength"],tabs:[{name:"validators",index:25}]},"matrixdropdowncolumn@boolean":{properties:[{name:"labelTrue",tab:"data"},{name:"labelFalse",tab:"data"},{name:"valueTrue",tab:"data"},{name:"valueFalse",tab:"data"},{name:"defaultValue",tab:"data"}],tabs:[{name:"data",index:25}]},"matrixdropdowncolumn@expression":{properties:["expression","displayStyle","currency"]},"matrixdropdowncolumn@rating":{properties:[{name:"displayMode",tab:"rateValues"},{name:"rateType",tab:"rateValues"},{name:"rateCount",tab:"rateValues"},{name:"rateColorMode",tab:"rateValues"},{name:"scaleColorMode",tab:"rateValues"},{name:"autoGenerate",tab:"rateValues"},{name:"rateMin",tab:"rateValues"},{name:"rateMax",tab:"rateValues"},{name:"rateStep",tab:"rateValues"},{name:"rateValues",tab:"rateValues"},{name:"minRateDescription",tab:"rateValues"},{name:"maxRateDescription",tab:"rateValues"},{name:"rateDescriptionLocation",tab:"rateValues"},{name:"displayRateDescriptionsAsExtremeItems",tab:"rateValues"}],tabs:[{name:"rateValues",index:5}]},multipletextitem:{properties:["name","title","inputType","isRequired","size","placeholder","inputTextAlignment",{name:"maxLength",tab:"validation"},{name:"requiredErrorText",tab:"validation"},{name:"validators",tab:"validation"},{name:"defaultValueExpression",tab:"logic"},{name:"minValueExpression",tab:"logic"},{name:"maxValueExpression",tab:"logic"},{name:"maskType",tab:"mask"},{name:"maskSettings",tab:"mask"}],tabs:[{name:"logic",index:200},{name:"mask",index:250},{name:"validation",index:300}]},"multipletext@items":{properties:["name","title"]},calculatedvalue:{properties:["name","expression","includeIntoResult"]},"calculatedvalue@items":{properties:["name","expression"]},paneldynamic:{properties:["renderMode","displayMode","templateTabTitle","tabTitlePlaceholder","tabAlign","panelCount","minPanelCount","maxPanelCount","panelsState",{name:"allowAddPanel"},{name:"allowRemovePanel"},"panelAddText","panelRemoveText","templateTitle","templateDescription","noEntriesText","confirmDelete","confirmDeleteText","panelPrevText","panelNextText","showQuestionNumbers","showRangeInProgress","showProgressBar","progressBarLocation",{name:"defaultPanelValue",tab:"data"},{name:"defaultValueFromLastPanel",tab:"data"},{name:"templateTitleLocation",tab:"questionSettings"},{name:"templateErrorLocation",tab:"questionSettings"},{name:"panelRemoveButtonLocation",tab:"layout"},{name:"keyName",tab:"validation"},{name:"keyDuplicationError",tab:"validation"}]},panelbase:{properties:["name","title","description","visible","readOnly",{name:"visibleIf",tab:"logic"},{name:"enableIf",tab:"logic"},{name:"requiredIf",tab:"logic"},{name:"questionTitleLocation",tab:"questionSettings"},{name:"questionTitleWidth",tab:"questionSettings"},{name:"questionErrorLocation",tab:"questionSettings"},{name:"layoutColumns",tab:"questionSettings"}],tabs:[{name:"questionSettings",index:100},{name:"logic",index:200},{name:"data",index:300},{name:"validation",index:400}]},panel:{properties:["isRequired",{name:"questionsOrder",tab:"questionSettings"},{name:"innerIndent",tab:"questionSettings"},{name:"requiredErrorText",tab:"validation"},{name:"page",tab:"layout"},{name:"startWithNewLine",tab:"layout"},{name:"state",tab:"layout"},{name:"width",tab:"layout"},{name:"minWidth",tab:"layout"},{name:"maxWidth",tab:"layout"},{name:"effectiveColSpan",tab:"layout"},{name:"showNumber",tab:"numbering"},{name:"showQuestionNumbers",tab:"numbering"},{name:"questionStartIndex",tab:"numbering"}],tabs:[{name:"layout",index:150},{name:"numbering",index:350}]},page:{properties:["navigationTitle","navigationDescription","timeLimit","maxTimeToFinish",{name:"questionsOrder",tab:"questionSettings"},{name:"navigationButtonsVisibility",tab:"navigation"}],tabs:[{name:"navigation",index:350}]},survey:{properties:["title","description","showTitle","locale","mode","cookieName","widthMode","width","fitToContainer",{name:"questionsOnPageMode",tab:"navigation"},{name:"firstPageIsStarted",tab:"navigation"},{name:"goNextPageAutomatic",tab:"navigation"},{name:"allowCompleteSurveyAutomatic",tab:"navigation"},{name:"showNavigationButtons",tab:"navigation"},{name:"showPrevButton",tab:"navigation"},{name:"showProgressBar",tab:"navigation"},{name:"progressBarType",tab:"navigation"},{name:"progressBarShowPageTitles",tab:"navigation"},{name:"progressBarShowPageNumbers",tab:"navigation"},{name:"showTOC",tab:"navigation"},{name:"tocLocation",tab:"navigation"},{name:"showPreviewBeforeComplete",tab:"navigation"},{name:"previewText",tab:"navigation"},{name:"editText",tab:"navigation"},{name:"startSurveyText",tab:"navigation"},{name:"pagePrevText",tab:"navigation"},{name:"pageNextText",tab:"navigation"},{name:"completeText",tab:"navigation"},{name:"questionsOrder",tab:"question"},{name:"questionTitleLocation",tab:"question"},{name:"questionDescriptionLocation",tab:"question"},{name:"showQuestionNumbers",tab:"question"},{name:"questionTitlePattern",tab:"question"},{name:"requiredText",tab:"question"},{name:"questionStartIndex",tab:"question"},{name:"questionErrorLocation",tab:"question"},{name:"focusFirstQuestionAutomatic",tab:"question"},{name:"maxTextLength",tab:"question"},{name:"maxOthersLength",tab:"question"},{name:"commentAreaRows",tab:"question"},{name:"autoGrowComment",tab:"question"},{name:"allowResizeComment",tab:"question"},{name:"gridLayoutEnabled",tab:"question"},{name:"showPageTitles",tab:"pages"},{name:"showPageNumbers",tab:"pages"},{name:"calculatedValues",tab:"logic"},{name:"triggers",tab:"logic"},{name:"clearInvisibleValues",tab:"data"},{name:"textUpdateMode",tab:"data"},{name:"sendResultOnPageNext",tab:"data"},{name:"storeOthersAsComment",tab:"data"},{name:"focusOnFirstError",tab:"validation"},{name:"checkErrorsMode",tab:"validation"},{name:"validateVisitedEmptyFields",tab:"validation"},{name:"navigateToUrl",tab:"showOnCompleted"},{name:"navigateToUrlOnCondition",tab:"showOnCompleted"},{name:"showCompletedPage",tab:"showOnCompleted"},{name:"completedHtml",tab:"showOnCompleted"},{name:"completedHtmlOnCondition",tab:"showOnCompleted"},{name:"loadingHtml",tab:"showOnCompleted"},{name:"completedBeforeHtml",tab:"showOnCompleted"},{name:"showTimer",tab:"timer"},{name:"timerLocation",tab:"timer"},{name:"timeLimit",tab:"timer"},{name:"timeLimitPerPage",tab:"timer"},{name:"timerInfoMode",tab:"timer"},{name:"maxTimeToFinish",tab:"timer"},{name:"maxTimeToFinishPage",tab:"timer"},{name:"showTimerPanel",tab:"timer"},{name:"showTimerPanelMode",tab:"timer"},{name:"logo",tab:"logo"},{name:"logoPosition",tab:"logo"},{name:"logoWidth",tab:"logo"},{name:"logoHeight",tab:"logo"},{name:"logoFit",tab:"logo"}],tabs:[{name:"logo",index:50},{name:"navigation",index:100},{name:"question",index:200},{name:"pages",index:250},{name:"logic",index:300},{name:"data",index:400},{name:"validation",index:500},{name:"showOnCompleted",index:600},{name:"timer",index:700}]},"page@survey":{properties:["name","title"]},choicesByUrl:{properties:["url","path","valueName","titleName","allowEmptyResponse"]},"patternmask@maskSettings":{properties:["pattern","saveMaskedValue"]},"datetimemask@maskSettings":{properties:["pattern","min","max","saveMaskedValue"]},"numericmask@maskSettings":{properties:["min","max","precision","decimalSeparator","thousandsSeparator","allowNegativeValues","saveMaskedValue"]},"currencymask@maskSettings":{properties:["prefix","suffix","min","max","precision","decimalSeparator","thousandsSeparator","allowNegativeValues","saveMaskedValue"]},patternmask:{properties:["pattern"]},datetimemask:{properties:["pattern"]},currencymask:{properties:["prefix","suffix"]}},We={autoGenerateProperties:!0,classes:Je},Ke=function(){function e(){}return e.definition=Je,e}(),Ye=function(){function e(){}return Object.defineProperty(e.prototype,"name",{get:function(){return this.property?this.property.name:""},enumerable:!1,configurable:!0}),e}(),Xe=function(){this.visible=!0,this.index=0,this.properties=[]},$e="others",et=function(){function e(e,t,i,n,r,a,s){void 0===t&&(t=null),void 0===i&&(i=null),void 0===n&&(n=null),void 0===r&&(r=null),void 0===a&&(a=null),void 0===s&&(s=null),this.obj=e,this.options=t,this.parentObj=r,this.parentProperty=a,this.propertyGridDefinition=s,this.tabs=[],this.unusedProperties=[],this.propertyGridDefinition||(this.propertyGridDefinition=We),this.showModeValue=n,this.properties=o.Serializer.getPropertiesByObj(this.obj),this.fillPropertiesHash(),this.buildTabs(i)}return e.prototype.getAllVisiblePropertiesNames=function(e){var t=[];return this.tabs.forEach((function(e){e.properties.forEach((function(e){return t.push(e.name)}))})),e&&this.unusedProperties.forEach((function(e){return t.push(e.name)})),t},e.prototype.getIsPropertyVisible=function(e){return ee.isPropertyVisible(this.obj,e,this.options,this.showMode,this.parentObj,this.parentProperty)},e.prototype.getDynamicClassName=function(){return this.obj&&this.obj.isQuestion&&this.obj.getDynamicType?this.obj.getDynamicType():""},e.prototype.getProperty=function(e){var t=this.propertiesHash[e];return t&&t.visible?t.property:null},e.prototype.getPropertyAsCategory=function(e){var t=this.getProperty(e);return!t||t.category&&t.category!==e?null:t},Object.defineProperty(e.prototype,"showMode",{get:function(){return this.showModeValue?this.showModeValue:"form"},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isEmpty",{get:function(){for(var e=0;e<this.tabs.length;e++)if(this.tabs[e].visible&&this.tabs[e].properties.length>0)return!1;return!0},enumerable:!1,configurable:!0}),e.prototype.getClassDefintion=function(e){if(this.propertyGridDefinition&&this.propertyGridDefinition.classes)return this.propertyGridDefinition.classes[e]},e.prototype.fillPropertiesHash=function(){this.propertiesHash={};for(var e=0;e<this.properties.length;e++){var t=this.properties[e];this.propertiesHash[t.name]={property:t,visible:this.getIsPropertyVisible(t)}}},e.prototype.isJSONPropertyVisible=function(e){var t=this.propertiesHash[e.name];return!!t&&t.visible},e.prototype.getTabByName=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].name==e)return this.tabs[t];return null},e.prototype.getTabs=function(){return this.tabs},e.prototype.getProperties=function(e){for(var t=[],o=0;o<e.properties.length;o++)t.push(e.properties[o].property);return t},e.prototype.buildTabs=function(e){!e&&this.obj&&(e=this.obj.getType());for(var t=this.getAllDefinitionsByClass(e),o=[],i=t.length-1;i>=0;i--){for(var n=t[i],r=n.tabs?n.tabs.length-1:-1;r>=0;r--){var a=n.tabs[r];o.indexOf(a.name)>-1?this.setTabProperties(a):this.addPropertyIntoTab(a,!0)&&o.push(a.name)}for(r=n.properties?n.properties.length-1:-1;r>=0;r--){var s=n.properties[r].name||n.properties[r];-1===o.indexOf(s)&&(o.push(s),this.addPropertyIntoTab(n.properties[r]))}}for(i=this.tabs.length-1;i>=0;i--)this.movePropertiesToNextProperties(this.tabs[i].properties),this.tabs[i].visible?this.sortProperties(this.tabs[i].properties):this.tabs.splice(i,1);this.tabs.sort((function(e,t){return e.index<t.index?-1:e.index>t.index?1:0})),this.setParentTabs(),this.tabs.forEach((function(e){var t;null===(t=e.tabs)||void 0===t||t.sort((function(e,t){return e.index-t.index}))}))},e.prototype.setParentTabs=function(){for(var e=this.tabs.length-1;e>=0;e--){var t=this.tabs[e];if(t.parentName){var o=this.getTabByName(t.parentName);o&&(t.parent=o,Array.isArray(o.tabs)||(o.tabs=[]),o.tabs.push(t),this.tabs.splice(e,1))}}},e.prototype.addPropertyIntoTab=function(e,t){void 0===t&&(t=!1),t&&this.setTabProperties(e);var o="string"==typeof e,n=o?e:e.name,r=this.propertiesHash[n];if(!r||t&&!this.getPropertyAsCategory(n))return!1;if(!o&&!1===e.visible)return!1;if(!r.visible&&(o||!o&&!0!==e.visible))return!1;var a=t?e.name:i.propertyGrid.generalTabName;t||o||!e.tab||(a=e.tab);var s=new Ye;return s.property=r.property,s.category=!o&&e.category?e.category:"",s.title=!o&&e.title?e.title:"",t||void 0===e.index||(s.definedIndex=e.index),s.onSameLine=this.isPropertyOnSameLine(r.property.nextToProperty),s.createdFromTabName=t,this.getTabOrCreate(a).properties.unshift(s),!0},e.prototype.setTabProperties=function(e){var t=this.getTabOrCreate(e.name);e.index>0&&(t.index=e.index),t.parentName=e.parent,!1===e.visible&&(t.visible=!1),e.title&&(t.title=e.title)},e.prototype.movePropertiesToNextProperties=function(e){for(var t=[].concat(e),o=0;o<t.length;o++){var i=this.getNextToNameProperty(t[o].property),n=this.getTabByPropertyName(i);if(n){var r=this.getPropertyByNameInTab(n,i),a=n.properties.indexOf(r);n.properties.splice(a+1,0,t[o]),e.splice(e.indexOf(t[o]),1)}}},e.prototype.getTabByPropertyName=function(e){if(!e)return null;this.isPropertyOnSameLine(e)&&(e=e.substring(1));for(var t=0;t<this.tabs.length;t++)if(this.getPropertyByNameInTab(this.tabs[t],e))return this.tabs[t];return null},e.prototype.getNextToNameProperty=function(e){return e.nextToProperty?this.isPropertyOnSameLine(e.nextToProperty)?e.nextToProperty.substring(1):e.nextToProperty:""},e.prototype.isPropertyOnSameLine=function(e){return!!e&&"*"===e[0]},e.prototype.getPropertyByNameInTab=function(e,t){for(var o=e.properties,i=0;i<o.length;i++)if(o[i].name==t)return o[i];return null},e.prototype.getTabOrCreate=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].name==e)return this.tabs[t];var o=new Xe;return o.name=e,e==i.propertyGrid.generalTabName&&(o.index=-1),this.tabs.unshift(o),o},e.prototype.setUsedProperties=function(e,t){for(var o=0;o<e.length;o++){var i=e[o].properties;if(Array.isArray(i))for(var n=0;n<i.length;n++)t[i[n].name?i[n].name:i[n]]=!0}},e.prototype.getAllDefinitionsByClass=function(e){var t=this,i=[],n={};if(e.indexOf("@")>-1&&this.getClassDefintion(e)){for(var r=e.substring(0,e.indexOf("@")+1),a=e.substring(r.length),s=[],l=o.Serializer.findClass(a);l&&"question"!==l.name;)s.unshift(r+l.name),l=l.parentName?o.Serializer.findClass(l.parentName):void 0;return s.indexOf(e)<0&&s.unshift(e),s.indexOf(r+"default")<0&&s.unshift(r+"default"),s.forEach((function(e){var o=t.getClassDefintion(e);o&&i.push(o)})),this.setUsedProperties(i,n),this.isColumnObj&&this.getAllDefinitionsByClassCore(this.obj.templateQuestion.getType(),n,i,void 0,!0),this.addNonTabProperties(i,n,!0),i}var u=!1,p=this.getDynamicClassName();return p&&(u=this.getAllDefinitionsByClassCore(p,n,i,e)),this.getAllDefinitionsByClassCore(e,n,i,void 0)&&u||this.addNonTabProperties(i,n),i},e.prototype.getAllDefinitionsByClassCore=function(e,t,i,n,r){for(var a=!1,s=e;s&&(!n||!o.Serializer.isDescendantOf(n,s));){var l=o.Serializer.findClass(s);if(!l)break;a=this.getAllDefinitionsByClassSingleCore(l.name,t,i,r),s=l.parentName}return a},e.prototype.getAllDefinitionsByClassSingleCore=function(e,t,o,n){var r=this.getClassDefintion(e),a=!1;if(!r)return a;var s=void 0;if(r.properties)for(var l=0;l<r.properties.length;){var u=r.properties[l],p="string"==typeof u?u:u.name,c=i.propertyGrid.generalTabName;"string"!=typeof u&&u.tab&&(c=u.tab);var d=this.propertiesHash[p]?this.propertiesHash[p].property:null;if(!n||(null==d?void 0:d.availableInMatrixColumn)){var h=this.getJsonPropertyCategory(d);h&&h!==c?r.properties.splice(l,1):t[p]=!0,n&&(s||(s={properties:[],tabs:[]}),s.properties.push(u))}l++}if(n)return s&&o.unshift(s),a;if(r.tabs)for(var g=0;g<r.tabs.length;g++)c=r.tabs[g].name,a=a||c===$e,this.getPropertyAsCategory(c)&&(t[c]=!0);return o.unshift(r),a},e.prototype.getJsonPropertyCategory=function(e){return e&&e.category?e.category:null},Object.defineProperty(e.prototype,"isColumnObj",{get:function(){return"matrixdropdowncolumn"===this.obj.getType()},enumerable:!1,configurable:!0}),e.prototype.getUnusedProperties=function(e,t){void 0===t&&(t=!1);for(var o=[],i=this.isColumnObj,n=0;n<this.properties.length;n++){var r=this.properties[n];this.isJSONPropertyVisible(r)&&!e[r.name]&&(!t||"form"===r.showMode||i&&r.availableInMatrixColumn)&&o.push(r)}return o},e.prototype.addNonTabProperties=function(e,t,o){void 0===o&&(o=!1);var n=this.getUnusedProperties(t,o);if(this.propertyGridDefinition.autoGenerateProperties){for(var r={properties:[],tabs:[]},a=[],s=0;s<n.length;s++){var l=n[s],u=this.getJsonPropertyCategory(l)||(0==e.length||this.parentObj&&"form"===this.showMode?i.propertyGrid.generalTabName:$e);if(a.indexOf(u)<0&&u!=i.propertyGrid.generalTabName&&(a.push(u),r.tabs.push({name:u,index:u===$e?1e3:10*a.length})),l.categoryIndex>-1&&a.indexOf(u)>-1)for(var p=0;p<r.tabs.length;p++)r.tabs[p].name==u&&(r.tabs[p].index=l.categoryIndex);r.properties.push({name:l.name,tab:u})}r.properties.length>0&&e.push(r)}else this.unusedProperties=n},e.prototype.sortProperties=function(e){if(Array.isArray(e)){var t=0;e.forEach((function(e){e.index=void 0!==e.definedIndex?e.definedIndex:t,t++})),e.sort((function(e,t){return e.index===t.index?0:e.index<t.index?-1:1})),this.insertProperteisWithVisibleIndex(e)}},e.prototype.insertProperteisWithVisibleIndex=function(e){for(var t=[].concat(e),o=0;o<t.length;o++){var i=t[o].property.visibleIndex;if(t[o].createdFromTabName&&i<0&&(i=0),!(i<0||void 0!==t[o].definedIndex)){var n=e.indexOf(t[o]);n>-1&&e.splice(n,1),i<e.length?e.splice(i,0,t[o]):e.push(t[o])}}},e}(),tt=function(){function e(){}return e.prototype.parse=function(t){e.boldRegEx||(e.boldRegEx=/\*{2}(.*?)\*{2}/gm,e.italicRegEx=/\_(.*?)\_/gm,e.codeRegEx=/\`(.*?)\`/gm,e.linkRegEx=/\[(.+)\]\(([^ ]+?)( "(.+)")?\)/);var o=function(e,t,o,n){if(!t)return e;var r=e.indexOf(t);if(i(e,r))return e;var a=t.substring(n.length,t.length),s="<span class='"+o+"'>"+(a=a.substring(0,a.length-n.length))+"</span>";return e.replace(t,s)},i=function(e,t){for(var o=!1,i=t-1;i>0;i--){if(" "===e[i]||"\n"===e[i])return!1;if("]"===e[i]&&o)return!0;o="("===e[i]}return!1};return t=this.replace(e.boldRegEx,t,"spg-bold","**",o),t=this.replace(e.italicRegEx,t,"spg-italic","_",o),t=this.replace(e.codeRegEx,t,"spg-code","`",o),t=this.replace(e.linkRegEx,t,"spg-link","",(function(e,t,o,i){if(!t)return e;var n=t.indexOf("](");if(n<0)return e;var r=t.substring(1,n),a="<a class='"+o+"' target='_blank' href='"+t.substring(n+2,t.length-1)+"'>"+r+"</a>";return e.replace(t,a)})),this.addLineBreaks(t)},e.prototype.replace=function(e,t,o,i,n){var r=t.match(e);if(!Array.isArray(r)||0==r.length)return t;for(var a=0;a<r.length;a++)t=n(t,r[a],o,i);return t},e.prototype.addLineBreaks=function(e){return e.indexOf("\n")<0?e:e.split("\n").join("<br/>")},e}();function ot(e,t,o){void 0===t&&(t=!0),void 0===o&&(o=!0),e.showNavigationButtons="none",e.showPageTitles=!1,e.focusFirstQuestionAutomatic=!1,e.showQuestionNumbers="off",o&&(e.questionTitleLocation="left"),e.showProgressBar="off",t&&(e.textUpdateMode="onTyping"),e.requiredText=""}o.FunctionFactory.Instance.register("propertyVisibleIf",(function(e){if(!this.question)return!1;var t=this.question.obj,i=this.question.property;return!(!t||!i)&&!!o.Serializer.hasOriginalProperty(t,i.name)&&i.isVisible("",t)})),o.FunctionFactory.Instance.register("propertyEnableIf",(function(e){var t=this.question.property,o=this.question.obj;return!!(this.question&&o&&t)&&!this.question.obj[t.overridingProperty]&&t.isEnable(o)}));var it=function(){function e(e,t){void 0===e&&(e=null),void 0===t&&(t=!0),this.options=e,this.options||(this.options=new n),t&&this.setupSurvey()}return e.prototype.setupSurvey=function(){this.editSurveyValue=this.createSurvey()},Object.defineProperty(e.prototype,"editSurvey",{get:function(){return this.editSurveyValue},enumerable:!1,configurable:!0}),e.prototype.hasErrors=function(){return this.editSurvey.hasErrors(!0,!0)},e.prototype.createSurvey=function(){var e=this.getSurveyJSON();return ot(e,!1,!1),this.options.createSurvey(e,this.getSurveyCreationReason(),this)},e.prototype.dispose=function(){this.editSurvey&&this.editSurvey.dispose()},e}(),nt={editors:new Array,fitHash:{},clearHash:function(){this.fitHash={}},register:function(e){this.editors.push(e)},getEditor:function(e,t){if(!e)return null;if(t)for(var o=this.editors.length-1;o>=0;o--){var i=this.editors[o];if(i.fit(e,t))return i}var n=this.fitHash[e.id];return n||(this.isEditorFit(e)||this.isEditorFit(e,!0))},isEditorFit:function(e,t){void 0===t&&(t=!1);for(var o=this.editors.length-1;o>=0;o--){var i=this.editors[o];if(!t&&i.fit(e)||t&&i.isDefault&&i.isDefault())return this.fitHash[e.id]=i,i}return null},getJSON:function(e,t,o,i,n){var r=this.getEditor(t,i);return r?r.getJSON(e,t,o,n):null},onCreated:function(e,t,o,i,n){var r=this.getEditor(o);r&&r.onCreated&&r.onCreated(e,t,o,i,n)},onSetup:function(e,t,o,i){var n=this.getEditor(o);n&&n.onSetup&&n.onSetup(e,t,o,i)},validateValue:function(e,t,o,i){var n=this.getEditor(o);return n&&n.validateValue?n.validateValue(e,t,o,i):""},onAfterRenderQuestion:function(e,t,o){var i=this.getEditor(t);i&&i.onAfterRenderQuestion&&i.onAfterRenderQuestion(e,t,o)},onMatrixCellCreated:function(e,t,o){var i=this.getEditor(t);i&&i.onMatrixCellCreated&&i.onMatrixCellCreated(o.question.obj,o)},onMatrixCellValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onMatrixCellValueChanged&&i.onMatrixCellValueChanged(e,o);var n=o.row;if(n){for(var r=n.questions,a=0;a<r.length;a++)if(r[a].errors.length>0)return;var s=n.getQuestionByName(o.columnName);s&&n.runCondition({},{question:s})}},onMatrixAllowRemoveRow:function(e,t,o){var i=this.getEditor(t);return!i||!i.onMatrixAllowRemoveRow||i.onMatrixAllowRemoveRow(e,o)},onGetMatrixRowAction:function(e,t,o,i){var n=this.getEditor(t);n&&n.onGetMatrixRowAction&&n.onGetMatrixRowAction(e,o,i)},onUpdateQuestionCssClasses:function(e,t,o){var i=this.getEditor(t);i&&i.onUpdateQuestionCssClasses&&i.onUpdateQuestionCssClasses(e,o)},onGetQuestionTitleActions:function(e,t,o,i){var n=this.getEditor(t);n&&n.onGetQuestionTitleActions&&n.onGetQuestionTitleActions(e,o,i)},onValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onValueChanged&&i.onValueChanged(e,t,o)},onValueChanging:function(e,t,o,i){var n=this.getEditor(t);n&&n.onValueChanging&&n.onValueChanging(e,t,o,i)},onMasterValueChanged:function(e,t,o){var i=this.getEditor(t);i&&i.onMasterValueChanged&&i.onMasterValueChanged(e,t,o)}},rt=function(){function e(e,t){this.obj=e,this.options=t}return e.prototype.onGetQuestionTitleActions=function(e){var t=e.question,o=t.property,i=nt.getEditor(o);if(i){var n=[],r=!t.isReadOnly;!!i.clearPropertyValue&&(!i.canClearPropertyValue||i.canClearPropertyValue(this.obj,o,t,this.options))&&n.push(this.createClearValueAction(i,o,t,r)),!1!==t.allowBatchEdit&&i.createPropertyEditorSetup&&(i.isPropertyEditorSetupEnabled&&(r=i.isPropertyEditorSetupEnabled(this.obj,o,e.question,this.options)),n.push(this.createEditorSetupAction(i,o,t,r)));var a=this.createPropertyHelpAction(t);a&&(n.unshift(a),t.getTitleToolbar().containerCss+=" spg-title-toolobar--single-help-action",a.iconSize=16),n.length>0&&(e.titleActions=n)}},e.prototype.createClearValueAction=function(e,t,i,n){var r=this;return{id:"property-grid-clear",title:Z("pe.clear"),showTitle:!1,iconName:"icon-clear",innerCss:"spg-action-button--danger",enabled:n,visible:new o.ComputedUpdater((function(){var e=i.obj[t.name];return Array.isArray(e)?e.length>0:!!e})),action:function(){e.clearPropertyValue(i.obj,t,i,r.options)}}},e.prototype.showModalPropertyEditor=function(e,t,o){return e.showModalPropertyEditor(e,t,o,this.options)},e.prototype.createEditorSetupAction=function(e,t,o,i){var n=this;return{id:"property-grid-setup",iconName:t.isArray?"icon-fast-entry":"icon-wizard",enabled:i,title:Z("pe.edit"),showTitle:!1,action:function(){return n.showModalPropertyEditor(e,t,o)}}},e.prototype.createPropertyHelpAction=function(e){var t=this;if(!e.description)return null;var i=new o.Action({title:"",tooltip:e.description,id:"property-grid-help",iconName:this.getHelpActionIconName(e),css:"spg-help-action",showTitle:!1,action:function(){e.descriptionLocation="hidden"!=e.descriptionLocation?"hidden":"underTitle",i.iconName=t.getHelpActionIconName(e)}}),n=i.doMouseDown;return i.doMouseDown=function(e){n.call(i);var t=e.originalEvent?e.originalEvent:e;t.preventDefault(),t.stopPropagation()},i},e.prototype.getHelpActionIconName=function(e){return"hidden"!=e.descriptionLocation?"icon-description-hide":"icon-description"},e}(),at=function(){function e(e,t,o,i,n){void 0===t&&(t=null),void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),this.obj=e,this.options=t,this.parentObj=o,this.parentProperty=i,this.propertyGridDefinition=n}return e.isPropertyReadOnly=function(e,t,o,i,n){var r=e.readOnly;return t&&o&&(r=t.onIsPropertyReadOnlyCallback(o,e,r,i,n)),r},e.getClassNameProperty=function(e){if(e&&e.getClassNameProperty)return e.getClassNameProperty()},e.prototype.toJSON=function(e,t){return void 0===e&&(e=!1),void 0===t&&(t=void 0),this.createJSON(e,t)},e.prototype.createColumnsJSON=function(e,t){for(var i=[],n=(e?o.Serializer.createClass(e):this.obj)||this.obj,r=0;r<t.length;r++){var a=this.getColumnPropertyJSON(n,t[r]);a&&i.push(a)}return i},e.prototype.setupObjPanel=function(e,t,o){void 0===t&&(t=!1),void 0===o&&(o=void 0),e.fromJSON(this.toJSON(t,o)),this.onQuestionsCreated(e)},e.prototype.setupPages=function(e){var t=this,o=this.convertPanelsToPages(this.toJSON(!1)),i=e.toJSON();Object.keys(o).forEach((function(e){return i[e]=o[e]})),e.fromJSON(i),e.pages.forEach((function(e){return t.onQuestionsCreated(e)}))},e.prototype.convertPanelsToPages=function(e){var t=e.elements;if(Array.isArray(t))return t.forEach((function(e){delete e.type})),e.pages=t,delete e.elements,e},e.prototype.onQuestionsCreated=function(e){for(var t=o.Serializer.getPropertiesByObj(this.obj),i={},n=0;n<t.length;n++)i[t[n].name]=t[n];var r=e.questions;for(n=0;n<r.length;n++){var a=r[n],s=i[a.name];a.property=s,a.obj=this.obj,a.creatorOptions=this.options;var l=this.getVisibilityOnEvent(s);if(a.readOnly=a.readOnly||this.isPropertyReadOnly(s),a.visible=a.visible&&l,s.visibleIf&&l&&(a.visibleIf="propertyVisibleIf() = true"),a.visible&&(s.overridingProperty||s.enableIf)&&(a.readOnly||(a.enableIf="propertyEnableIf() = true"),s.overridingProperty)){a.onUpdateCssClassesCallback=function(e){e.questionWrapper="spg-boolean-wrapper--overriding"};var u=this.createOverridingQuestion(e,a,s.overridingProperty);u&&a.parent.addElement(u,a.parent.elements.indexOf(a)+1)}a.descriptionLocation="hidden";var p=G.getPropertyHelpInEditor(this.obj.getType(),s.name,s.type);p&&(a.description=p),nt.onCreated(this.obj,a,s,this.options,this.propertyGridDefinition),this.options.onPropertyEditorCreatedCallback(this.obj,s,a)}},e.prototype.getVisibilityOnEvent=function(e,t){return void 0===t&&(t=""),this.options.onCanShowPropertyCallback(this.obj,e,t,this.parentObj,this.parentProperty)},e.prototype.isPropertyReadOnly=function(t){return e.isPropertyReadOnly(t,this.options,this.obj,this.parentObj,this.parentProperty)},e.prototype.createOverridingQuestion=function(e,t,i){var n=o.Serializer.createClass("linkvalue");if(!n)return null;n.name=t.name+"_overridingProperty",n.startWithNewLine=!1,n.property=t.property,n.obj=t.obj,n.visibleIf="propertyEnableIf() = false";var r=e.getQuestionByName(i);return!r&&e.survey&&(r=e.survey.getQuestionByName(i)),n.linkValueText=G.getString("pe.overridingPropertyPrefix"),n.titleLocation="hidden",n.onUpdateCssClassesCallback=function(e){e.questionWrapper="spg-link-wrapper--overriding"},r&&(n.linkClickCallback=function(){r.focus(!1,!0)}),n},e.prototype.getClasPropName=function(){if(this.parentObj&&this.parentProperty)return this.parentProperty.name;var t=e.getClassNameProperty(this.obj);return t&&this.obj[t]?this.obj[t]:void 0},e.prototype.createJSON=function(e,t){void 0===t&&(t=void 0);var o=void 0,n=this.getClasPropName();n&&("itemvalue"===(o=this.obj.getType())&&(o+="[]"),o+="@"+n);for(var r=new et(this.obj,null,o,void 0,this.parentObj,this.parentProperty,this.propertyGridDefinition).getTabs(),a={},s=0;s<r.length;s++)!1!==r[s].visible&&(a[r[s].name]=this.createPanelProps(r[s],t));var l={elements:[]};for(var u in a)if(u==i.propertyGrid.generalTabName&&e){var p=a[u].elements;for(s=0;s<p.length;s++)l.elements.push(p[s])}else l.elements.push(a[u]);return l},e.prototype.createPanelProps=function(e,t,o){var i=this;void 0===o&&(o=!1);for(var n=this.createPanelJSON(e.name,e.title,o),r=0;r<e.properties.length;r++){var a=e.properties[r],s=this.createQuestionJSON(this.obj,a.property,a.title,!1,t);a.onSameLine&&(s.startWithNewLine=!1,this.updateQuestionJSONOnSameLine(s),n.elements.length>0&&this.updateQuestionJSONOnSameLine(n.elements[n.elements.length-1])),s&&n.elements.push(s)}return Array.isArray(e.tabs)&&e.tabs.forEach((function(e){var o=i.createPanelProps(e,t,!0);o.title===e.name&&delete o.title,o&&n.elements.push(o)})),n},e.prototype.updateQuestionJSONOnSameLine=function(e){e.titleLocation="left",e.minWidth="50px"},e.prototype.createPanelJSON=function(e,t,o){var i={type:"panel",name:e,title:this.getPanelTitle(e,t),elements:[]};return o||(i.state="collapsed"),i},e.prototype.createQuestionJSON=function(e,t,o,i,n){if(void 0===i&&(i=!1),!this.isPropertyVisible(t,i?"list":"")&&i)return null;var r=nt.getJSON(e,t,this.options,n,this.propertyGridDefinition);if(!r)return null;r.name=t.name,r.title=this.getQuestionTitle(t,e.getType(),o),this.isQuestionTitleHidden(t)&&(r.titleLocation="hidden"),r.visible=t.visible,r.isReadOnly=t.readOnly,r.isRequired=t.isRequired,r.requiredErrorText=G.getString("pe.propertyIsEmpty"),["page","panelbase"].indexOf(t.className)&&"name"===r.name&&(r.isRequired=!0,r.requiredErrorText=G.getString("pe.propertyIsEmpty"));var a=G.getPropertyPlaceholder(e.getType(),t.name);return a&&(r.placeholder=a),r},e.prototype.getColumnPropertyJSON=function(e,t){if(!e)return null;var i=o.Serializer.findProperty(e.getType(),t);if(!i)return null;var n=this.createQuestionJSON(e,i,"",!0,void 0);return n?(i.isUnique&&(n.isUnique=i.isUnique),n.type&&(n.cellType=n.type,delete n.type),"buttongroup"===n.cellType&&(n.cellType="dropdown"),"fileedit"===n.cellType&&(n.cellType="text"),i.visibleIf&&(n.visibleIf="propertyVisibleIf() = true"),n.isReadOnly&&(n.readOnly=n.isReadOnly,delete n.isReadOnly),n):null},e.prototype.isPropertyVisible=function(e,t){return!(!e.visible||t&&e.showMode&&t!=e.showMode)},e.prototype.getPanelTitle=function(e,t){if(t)return t;var i=G.getString("pe.tabs."+e);if("object"==typeof i)for(var n in i)if(o.Serializer.isDescendantOf(this.obj.getType(),n))return i[n];return i},e.prototype.getQuestionTitle=function(e,t,i){if(e.displayName)return e.displayName;if(i&&i!==e.name)return i;var n=t;return this.parentProperty&&(n+="@"+this.parentProperty.name),"matrixdropdowncolumn"===this.obj.getType()&&"question"!==this.obj.getDynamicType()&&(o.Serializer.findProperty(this.obj.getType(),e.name)||(n=this.obj.getDynamicType())),G.getPropertyNameInEditor(n,e.name)},e.prototype.isQuestionTitleHidden=function(e){return""===e.displayName},e}(),st=function(){function e(e,t,o){void 0===e&&(e=null),void 0===t&&(t=new n),void 0===o&&(o=null),this.showOneCategoryInPropertyGrid=!1,this.surveyInstanceCreatedArea="property-grid",this.isCellCreating=!1,this.options=t,this.propertyGridDefinition=o,this.options.enableLinkFileEditor&&nt.register(new ft),this.obj=e}return e.prototype.refresh=function(){this.setObj(this.objValue)},Object.defineProperty(e.prototype,"obj",{get:function(){return this.objValue},set:function(e){this.objValue!==e&&this.setObj(e)},enumerable:!1,configurable:!0}),e.prototype.setPropertyGridDefinition=function(e){this.propertyGridDefinition!==e&&(this.propertyGridDefinition=e,this.obj&&this.updateCurrentSurveyWithNewDefinition())},e.prototype.selectProperty=function(e,t){if(void 0===t&&(t=!0),this.survey){var o=this.survey.getQuestionByName(e);if(o){for(var i=this.survey.getAllPanels(),n=0;n<i.length;n++){var r=i[n];r===o.parent?(r.blockAnimations(),r.expand(),r.releaseAnimations()):r.collapse()}t?o.focus():this.showOneCategoryInPropertyGrid&&(this.survey.currentPage=o.page)}}},e.prototype.setObjFromAction=function(e,t){this.changedFromActionCallback?this.changedFromActionCallback(e,t):this.setObj(e)},e.prototype.setObj=function(e){var t=this;this.objValue=e,this.classNameProperty=this.obj?at.getClassNameProperty(this.obj):"",this.classNameValue=this.classNameProperty?this.obj[this.classNameProperty]:void 0,this.titleActionsCreator=this.obj?new rt(this.obj,this.options):void 0;var o=this.getSurveyJSON();this.options.readOnly&&(o.mode="display"),this.surveyValue&&(this.surveyValue.onValidateQuestion.clear(),this.surveyValue.onValueChanging.clear(),this.surveyValue.onValueChanged.clear(),this.surveyValue.onMatrixCellValueChanging.clear(),this.surveyValue.onMatrixCellValidate.clear(),this.surveyValue.onMatrixCellValueChanged.clear(),this.surveyValue.editingObj=void 0,this.surveyValue.data={},this.surveyValue.dispose()),this.surveyValue=this.createSurvey(o,(function(e){t.onCreateSurvey(e)})),this.obj&&(this.survey.onValueChanged.add((function(e,o){t.onValueChanged(o)})),this.survey.onValueChanging.add((function(e,o){t.onValueChanging(o)})),this.survey.onValidateQuestion.add((function(e,o){t.onValidateQuestion(o)})),this.survey.onGetQuestionTitleActions.add((function(e,o){t.titleActionsCreator.onGetQuestionTitleActions(o),t.onGetQuestionTitleActions(o,t.options);var i=o.question;t.options.onPropertyEditorUpdateTitleActionsCallback(t.obj,i.property,i,o.titleActions)})),this.survey.onGetPanelTitleActions.add((function(e,t){t.titleActions.splice(0,t.titleActions.length)})),this.survey.onMatrixCellCreated.add((function(e,o){t.onMatrixCellCreated(o)})),this.survey.onMatrixCellValueChanging.add((function(e,o){t.onMatrixCellValueChanging(o)})),this.survey.onMatrixCellValidate.add((function(e,o){t.onMatrixCellValidate(o)})),this.survey.onMatrixCellValueChanged.add((function(e,o){t.onMatrixCellValueChanged(o)})),this.survey.onMatrixAllowRemoveRow.add((function(e,o){o.allow=t.getMatrixAllowRemoveRow(o.question,o.row)})),this.survey.onMatrixRowRemoving.add((function(e,o){o.allow=t.getMatrixOnRowRemoving(o.question,o.row)})),this.survey.onMatrixRowAdded.add((function(e,o){t.onMatrixRowAdded(o)})),this.survey.onGetMatrixRowActions.add((function(e,o){t.onGetMatrixRowAction(o)})),this.survey.onUpdateQuestionCssClasses.add((function(e,o){t.onUpdateQuestionCssClasses(o)})),this.survey.onElementContentVisibilityChanged.add((function(e,o){if(!i.propertyGrid.allowExpandMultipleCategories){var n=o.element;n&&n.isPanel&&n.isExpanded&&t.collapseOtherPanels(n)}})),this.survey.onAfterRenderQuestion.add((function(e,o){t.onAfterRenderQuestion(o)})),this.survey.onTextMarkdown.add((function(e,t){var o;"description"===t.name&&(t.html=(o=t.text,(new tt).parse(o)))})),this.survey.editingObj=this.obj,this.objValueChangedCallback&&this.objValueChangedCallback(),this.updateDependedPropertiesEditors(),this.showOneCategoryInPropertyGrid?this.survey.onCurrentPageChanged.add((function(e,o){if(t.currentlySelectedPage!==o.newCurrentPage){var i=o.newCurrentPage.getFirstQuestionToFocus(!1,!0);t.currentlySelectedPage=o.newCurrentPage,t.currentlySelectedProperty=i?i.name:""}})):this.survey.onFocusInPanel.add((function(e,o){if(t.currentlySelectedPanel!==o.panel){var i=o.panel.getFirstQuestionToFocus(!1,!0);t.currentlySelectedProperty=i?i.name:"",t.currentlySelectedPanel=o.panel}})),this.survey.onFocusInQuestion.add((function(e,o){t.currentlySelectedProperty=o.question.name,t.currentlySelectedPanel=o.question.parent})),this.survey.onUploadFiles.add((function(e,o){var i="survey"==o.question.obj.getType()?void 0:"imageitemvalue"==o.question.obj.getType()?o.question.obj.locOwner:o.question.obj,n="imageitemvalue"==o.question.obj.getType()?o.question.obj:void 0;t.options.uploadFiles(o.files,i,(function(e,t){return o.callback(e,[{content:t,file:o.files[0]}])}),{element:o.question.obj,item:n,elementType:o.question.obj.getType(),propertyName:o.name})})),this.survey.getAllQuestions().map((function(e){return e.allowRootStyle=!1})),this.survey.onQuestionCreated.add((function(e,t){t.question.allowRootStyle=!1})),this.options.onPropertyGridSurveyCreatedCallback(this.obj,this.survey))},e.prototype.onCreateSurvey=function(e){var t=this;e.questionErrorLocation="bottom",e.getCss().list={};var o=W({},ze);if(o.root+=this.showOneCategoryInPropertyGrid?" spg-root--one-category":"",e.css=o,this.obj){var i=new at(this.obj,this.options,null,null,this.propertyGridDefinition);if(this.showOneCategoryInPropertyGrid)e.css.page.root+=" spg-panel__content",i.setupPages(e);else{var n=e.createNewPage("p1");i.setupObjPanel(n,!1),e.addPage(n)}e.getAllQuestions().forEach((function(e){nt.onSetup(t.obj,e,e.property,t.options)})),e.enterKeyAction="loseFocus",e.checkErrorsMode="onValueChanging",e.questionErrorComponent="svc-question-error",0===e.pages.length&&e.addNewPage("p1")}},e.prototype.updateCurrentSurveyWithNewDefinition=function(){var e=new o.SurveyModel(this.getSurveyJSON());this.onCreateSurvey(e),this.updateElementsInPanel(this.survey.pages[0],e.pages[0])},e.prototype.updateElementsInPanel=function(e,t){for(var o=e.elements.length-1;o>=0;o--){var i=e.elements[o];(r=t.getElementByName(i.name))&&i.isPanel===r.isPanel?i.isPanel&&r.isPanel&&this.updateElementsInPanel(i,r):e.removeElement(i)}var n=new Array;for(o=0;o<t.elements.length;o++){var r=t.elements[o],a=o+n.length;if(!(a<e.elements.length&&e.elements[a].name===r.name)){var s=e.getElementByName(r.name);s?(e.removeElement(s),e.addElement(s,a)):n.push({element:r,index:o})}}for(o=0;o<n.length;o++)e.addElement(n[o].element,n[o].index)},Object.defineProperty(e.prototype,"options",{get:function(){return this.optionsValue},set:function(e){this.optionsValue=e||new n},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),e.prototype.validate=function(){if(this.survey)return!this.survey.hasErrors(!0,!0)},e.prototype.collapseCategory=function(e){var t=this.survey.getPanelByName(e);t&&t.collapse()},e.prototype.expandCategory=function(e){var t=this.survey.getPanelByName(e);t&&t.expand()},e.prototype.collapseAllCategories=function(){this.collapseAllCategoriesExcept(null)},e.prototype.expandAllCategories=function(){this.survey.getAllPanels().forEach((function(e){e.parent.isPanel||e.expand()}))},e.prototype.expandCategoryIfNeeded=function(){var e=i.propertyGrid.defaultExpandedTabName;if(e&&!this.getPropertyGridExpandedCategory()){var t=this.survey.getPanelByName(e);t&&(t.blockAnimations(),t.expand(),t.releaseAnimations())}},e.prototype.getPropertyGridExpandedCategory=function(){for(var e=this.survey.getAllPanels(),t=0;t<e.length;t++)if(e[t].isExpanded)return e[t].name;return""},e.prototype.collapseOtherPanels=function(e){this.collapseAllCategoriesExcept(e)},e.prototype.collapseAllCategoriesExcept=function(e){this.survey.getAllPanels().forEach((function(t){t===e||t.parent.isPanel||t.collapse()}))},e.prototype.createSurvey=function(e,t){return this.options.createSurvey(e,this.surveyInstanceCreatedArea,this,t)},e.prototype.getSurveyJSON=function(){var e={autoGrowComment:!0,allowResizeComment:!1};return ot(e,!0,!1),e},e.prototype.validateQuestionValue=function(e,t,i,n){if(t.isRequired&&(o.Helpers.isValueEmpty(n)||t.valueChangingEmpty))return this.getErrorTextOnValidate(G.getString("pe.propertyIsEmpty"),i.name,e,n);if(this.isPropNameInValid(e,i,n)||t.nameHasError)return this.getErrorTextOnValidate(G.getString("pe.propertyNameIsIncorrect"),i.name,e,n);var r=nt.validateValue(e,t,i,n);return this.getErrorTextOnValidate(r,i.name,e,n)},e.prototype.getErrorTextOnValidate=function(e,t,o,i){return this.options.onGetErrorTextOnValidationCallback(t,o,i)||e},e.prototype.onValidateQuestion=function(e){var t=e.question;t&&t.property&&(e.error=this.validateQuestionValue(this.obj,t,t.property,e.value))},e.prototype.onValueChanging=function(e){var t=e.question;if(t&&t.property&&(Array.isArray(e.value)||!o.Helpers.isTwoValueEquals(e.value,e.oldValue,!1,!1,!1))){nt.onValueChanging(this.obj,t.property,t,e);var i={obj:this.obj,propertyName:t.property.name,value:e.oldValue,newValue:e.value,doValidation:!1};if(this.options.onValueChangingCallback(i),e.value=i.newValue,t.property.isRequired){var n=o.Helpers.isValueEmpty(e.value);t.valueChangingEmpty=n}var r=this.isPropNameInValid(this.obj,t.property,e.value);t.nameHasError=r}},e.prototype.isPropNameInValid=function(e,t,o){return!(!e.isQuestion||"name"!==t.name||!o)&&(o=o.toLowerCase(),["item","choice","row","panel"].indexOf(o)>-1)},e.prototype.onValueChanged=function(e){var t=this,o=e.question;if(o&&o.property&&(o.valueChangingEmpty=!1,o.nameHasError=!1,this.changeDependedProperties(o,(function(e){return t.survey.getQuestionByName(e)}),(function(e){return t.survey.getValue(e)})),nt.onValueChanged(this.obj,o.property,o),this.classNameProperty&&e.name===this.classNameProperty&&this.classNameValue!==e.value&&(this.setObj(this.obj),this.survey))){var i=this.survey.getQuestionByName(e.name);i&&i.focus()}},e.prototype.changeDependedProperties=function(e,t,i){var n=e.property;if(n){var r=n.getDependedProperties();if(r)for(var a=0;a<r.length;a++){var s=r[a],l=t(s);if(l){this.updateDependedPropertiesEditor(l);var u=i(s);o.Helpers.isTwoValueEquals(l.value,u,!1,!1,!1)||(l.value=u),nt.onMasterValueChanged(e.obj,l.property,l)}}}},e.prototype.updateDependedPropertiesEditor=function(e){var t=e.obj;if(t){var o=e.property;o&&o.onPropertyEditorUpdate&&o.onPropertyEditorUpdate(t,e)}},e.prototype.updateDependedPropertiesEditors=function(){for(var e=this.survey.getAllQuestions(),t=0;t<e.length;t++)this.updateDependedPropertiesEditor(e[t])},e.prototype.onAfterRenderQuestion=function(e){nt.onAfterRenderQuestion(this.obj,e.question.property,e)},e.prototype.onMatrixCellCreated=function(e){this.isCellCreating=!0,nt.onMatrixCellCreated(this.obj,e.question.property,e),this.isCellCreating=!1;var t=e.row.editingObj;if(t){var i=o.Serializer.findProperty(t.getType(),e.columnName);if(i){var n=this.getMatrixAllowEditRow(e.question,e.row);e.cellQuestion.readOnly=!n||at.isPropertyReadOnly(i,this.options,t,this.obj,e.question.property)}}},e.prototype.onMatrixCellValueChanging=function(e){if(!this.isCellCreating){var t={obj:e.row.editingObj,propertyName:e.columnName,value:e.oldValue,newValue:e.value,doValidation:!1};this.options.onValueChangingCallback(t),e.value=t.newValue}},e.prototype.onMatrixCellValidate=function(e){if(!this.isCellCreating){var t=e.row.getQuestionByColumnName(e.columnName);t&&t.property&&(e.error=this.validateQuestionValue(e.row.editingObj,t,t.property,e.value))}},e.prototype.onGetMatrixRowAction=function(e){var t=this;nt.onGetMatrixRowAction(this.obj,e.question.property,e,(function(o){t.setObjFromAction(o,e.question.name)}))},e.prototype.onUpdateQuestionCssClasses=function(e){nt.onUpdateQuestionCssClasses(this.obj,e.question.property,e)},e.prototype.onGetQuestionTitleActions=function(e,t){nt.onGetQuestionTitleActions(this.obj,e.question.property,e,t)},e.prototype.onMatrixCellValueChanged=function(e){if(!this.isCellCreating){var t=e.row.getQuestionByName(e.columnName);t&&this.changeDependedProperties(t,(function(t){return e.row.getQuestionByName(t)}),(function(t){return e.row.getValue(t)})),nt.onMatrixCellValueChanged(this.obj,e.question.property,e)}},e.prototype.getMatrixAllowRemoveRow=function(e,t){return void 0===t.allowDeleteRow&&this.calculateMatrixAllowOperations(e,t),t.allowDeleteRow},e.prototype.getMatrixOnRowRemoving=function(e,t){return this.options.onCollectionItemDeletingCallback(this.obj,e.property,e.value,t.editingObj)},e.prototype.getMatrixAllowEditRow=function(e,t){return!e.readOnly&&(void 0===t.allowEditRow&&this.calculateMatrixAllowOperations(e,t),t.allowEditRow)},e.prototype.calculateMatrixAllowOperations=function(e,t){var o={allowDelete:this.onMatrixAllowRemoveRow(e,t),allowEdit:!0,allowAdd:void 0};this.options.onCollectionItemAllowingCallback(this.obj,e.property,e.value,t.editingObj,o),t.allowDeleteRow=o.allowDelete,t.allowEditRow=o.allowEdit},e.prototype.onMatrixAllowRemoveRow=function(e,t){var o=nt.onMatrixAllowRemoveRow(this.obj,e.property,t);return this.options.onCanDeleteItemCallback(this.obj,t.editingObj,o)},e.prototype.onMatrixRowAdded=function(e){var t=e.row.editingObj;o.Serializer.isDescendantOf(t.getType(),"itemvalue")&&this.options.onItemValueAddedCallback(this.obj,e.question.property.name,e.row.editingObj,e.question.value),o.Serializer.isDescendantOf(t.getType(),"matrixdropdowncolumn")&&this.options.onMatrixDropdownColumnAddedCallback(this.obj,e.row.editingObj,e.question.value)},e}(),lt=function(){function e(){}return e.prototype.showModalPropertyEditor=function(e,t,i,n,r){var a=this,s=i.obj,l=e.createPropertyEditorSetup(s,t,i,n);if(!l)return null;if("condition"!==t.type&&(l.editSurvey.css=o.defaultV2Css),i.isReadOnly&&(l.editSurvey.mode="display"),!o.settings.showDialog)return l;var u=o.surveyLocalization.currentLocale,p=G.currentLocale;o.surveyLocalization.currentLocale=p;var c=o.settings.showDialog({componentName:"survey",data:{survey:l.editSurvey,model:l.editSurvey},onApply:function(){return a.onModalPropertyEditorClosed(e,t,i,n,"apply"),r&&r("apply"),l.apply()},onCancel:function(){a.onModalPropertyEditorClosed(e,t,i,n,"cancel"),r&&r("cancel")},cssClass:"sv-property-editor svc-creator-popup",title:i.title,displayMode:n.isMobileView?"overlay":"popup"},n.rootElement);if(i.isReadOnly){var d=c.footerToolbar.getActionById("apply");d&&(d.visible=!1)}return c.locale=p,o.surveyLocalization.currentLocale=u,this.onModalPropertyEditorShown(e,t,i,n),n.onPropertyGridShowModalCallback(s,t,i,l,c),l},e.prototype.onModalPropertyEditorShown=function(e,t,o,i){},e.prototype.onModalPropertyEditorClosed=function(e,t,o,i,n){},e.prototype.isSupportGrouping=function(){return!1},e.prototype.hasPreviousElementForGrouping=function(e){if(!e||!e.parent)return!1;var t=e.parent.elements.indexOf(e);if(!(t<1)){var o=e.parent.elements[t-1],i=e.parent.elements[t-2];return o.getType()===e.getType()||t>1&&!o.startWithNewLine&&i.property===o.property&&i.getType()===e.getType()}},e.prototype.onUpdateQuestionCssClasses=function(e,t){this.isSupportGrouping()&&this.hasPreviousElementForGrouping(t.question)&&(t.cssClasses.mainRoot+=" spg-row-narrow__question")},e}(),ut=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"boolean"==e.type||"switch"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"boolean",default:!1,renderAs:"checkbox",titleLocation:"hidden"},n=t.getChoices(e,(function(e){}));if(Array.isArray(n)&&n.length>=2){for(var r=[],a=0;a<2;a++){var s=n[a].value||n[a];r.push({value:s,text:G.getPropertyValueInEditor(t.name,s)})}var l=(t.getDefaultValue(e)||r[0].value)===n[1].value?1:0,u=0===l?1:0;i.valueTrue=r[l].value,i.valueFalse=r[u].value,i.labelTrue=r[l].text,i.labelFalse=r[u].text}return i},t.prototype.isSupportGrouping=function(){return!0},t}(lt),pt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"switchToggle"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"boolean",default:!1},n=t.getChoices(e,(function(e){}));if(Array.isArray(n)&&n.length>=2){for(var r=[],a=0;a<2;a++){var s=n[a].value||n[a];r.push({value:s,text:G.getPropertyValueInEditor(t.name,s)})}var l=(t.getDefaultValue(e)||r[0].value)===n[1].value?1:0,u=0===l?1:0;i.valueTrue=r[l].value,i.valueFalse=r[u].value,i.labelTrue=r[l].text,i.labelFalse=r[u].text}return i},t}(lt),ct=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"boolean"==e.type&&!!e.defaultValueFunc&&void 0===e.defaultValueFunc(null)},t.prototype.getJSON=function(e,t,o){return{type:"buttongroup",choices:[{value:"auto",text:G.getString("pe.inherit")},{value:"false",text:G.getString("pe.disabled")},{value:"true",text:G.getString("pe.enabled")}],showOptionsCaption:!1}},t.prototype.onCreated=function(e,t,o,i,n){t.valueFromDataCallback=function(e){return void 0===e?"auto":e.toString()},t.valueToDataCallback=function(e){return"auto"===e?void 0:"true"===e}},t.prototype.onSetup=function(e,t,o,i){var n=e.getPropertyValue(o.name);t.value=void 0===n?"auto":"true"===n},t}(lt),dt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.updateMaxLength=function(e,t){return e.maxLength>0&&(t.maxLength=e.maxLength),t},t.prototype.updateType=function(e,t,o){return!o.maxLength&&t.hasDefaultPropertyValue(e.name)&&(o.type="".concat(o.type,"withreset"),o.renderAs=o.type),o},t.prototype.onCreated=function(e,t,i,n){if(t instanceof o.QuestionTextBase&&(t.onKeyDownPreprocess=function(e){(e.ctrlKey||e.metaKey)&&-1!==[89,90].indexOf(e.keyCode)&&(t.isInputTextUpdate?(n.findSuitableShortcuts(e).forEach((function(e){e.execute(n.selectedElement)})),e.preventDefault()):e.target.value==t.value&&n.findSuitableShortcuts(e).forEach((function(e){e.execute(n.selectedElement)})))}),"title"===i.name&&(t.allowSpaceAsAnswer=!0),"textwithreset"==t.getType()||"commentwithreset"==t.getType()){t.resetValueAdorner.resetValueCallback=function(){e.resetPropertyValue(i.name)},t.resetValueAdorner.caption=G.getString("pe.resetToDefaultCaption");var r=function(){return!i.isDefaultValue(i.getValue(e))};t.resetValueAdorner.allowResetValue=r(),e.registerFunctionOnPropertyValueChanged(i.name,(function(){t.resetValueAdorner.allowResetValue=r()}))}},t}(lt),ht=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string"==e.type},t.prototype.isDefault=function(){return!0},t.prototype.getJSON=function(e,t,o){var i=this.updateType(t,e,this.updateMaxLength(t,{type:"text"}));return t.isRequired&&(i.textUpdateMode="onBlur"),t.dataList&&(i.dataList=t.dataList),i},t.prototype.validateValue=function(e,t,o,i){return mt(e,o,i)},t}(dt),gt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"datetime"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"text",inputType:"date"}},t}(lt);function mt(e,t,i){if("imageitemvalue"===e.getType()&&"imageLink"===t.name&&o.Helpers.isUrlYoutubeVideo(i))return G.getString("ed.translationYouTubeNotSupported")}var ft=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"url"===e.type||"file"===e.type},t.prototype.getJSON=function(e,t,o){return{type:"fileedit",storeDataAsText:!1,placeholder:G.getString("pe.fileInputPlaceholder")}},t.prototype.onCreated=function(e,t,o,i){if(["image","imageitemvalue"].indexOf(e.getType())>-1){var n="imageitemvalue"==e.getType()?e.locOwner:e;n&&(n.registerFunctionOnPropertyValueChanged("contentMode",(function(e){t.acceptedTypes=A(e)})),t.acceptedTypes=A(n.contentMode))}else t.acceptedTypes=A("image");t.onChooseFilesCallback=function(o,n){i.chooseFiles(o,n,{element:e,elementType:e.getType(),propertyName:t.name})}},t.prototype.validateValue=function(e,t,o,i){return mt(e,o,i)},t}(lt),yt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"color"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"color",allowEmptyValue:!0}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt),vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"coloralpha"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"coloralpha",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt),bt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"number"==e.type||"responsiveImageSize"==e.type},t.prototype.getJSON=function(e,t,o){var i={type:"text",inputType:"number",textUpdateMode:"onBlur"};return void 0!==t.minValue&&(i.min=t.minValue),void 0!==t.maxValue&&(i.max=t.maxValue),i},t.prototype.onValueChanging=function(e,t,o,i){i.value||0===i.value||(void 0!==t.defaultValue?i.value=t.defaultValue:t.isRequired||""!==i.value?i.value=void 0!==t.minValue&&t.minValue>0?t.minValue:0:i.value=void 0)},t}(lt),Ct=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"spinedit"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"spinedit",descriptionLocation:"hidden"}},t}(lt),wt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string"==e.type&&("imageHeight"==e.name||"imageWidth"==e.name)},t.prototype.isDefault=function(){return!1},t.prototype.onCreated=function(t,i,n,r){e.prototype.onCreated.call(this,t,i,n,r),i.valueFromDataCallback=function(e){var i,n,r,a;return i=t.imageHeight,n=t.imageWidth,r=o.Serializer.findProperty(t.getType(),"imageHeight"),a=o.Serializer.findProperty(t.getType(),"imageWidth"),(r||a)&&r.isDefaultValue(i)&&a.isDefaultValue(n)?void 0:e}},t}(ht),xt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"text"===e.type},t.prototype.getJSON=function(e,t,o){return this.updateType(t,e,this.updateMaxLength(t,{type:"comment",rows:2}))},t}(dt),Tt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"html"===e.type},t.prototype.getJSON=function(e,t,o){return this.updateMaxLength(t,{type:"comment",allowResize:!0,autoGrow:!1})},t}(dt),St=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"string[]"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",rows:2}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return Array.isArray(e)?e.join("\n"):""},t.valueToDataCallback=function(e){return e?Array.isArray(e)&&!e.split?e:e.split("\n"):[]}},t}(lt),Pt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"boolean"!==e.type&&(this.isLocaleProp(e)||e.hasChoices)},t.prototype.getJSON=function(e,t,o){var i=this.getChoices(e,t),n={type:this.renderAsButtonGroup(t,i)?"buttongroup":"dropdown",choices:i,showOptionsCaption:!1};return this.updateObjBasedOnEmptyValueItem(t,i,n),n},t.prototype.getChoices=function(e,t){return t.getChoices(e,(function(e){}))},t.prototype.updateObjBasedOnEmptyValueItem=function(e,t,o){var i=this.getEmptyJsonItemValue(e,t);i&&(o.showOptionsCaption=!0,o.allowClear=!0,i.text&&(o.optionsCaption=i.text))},Object.defineProperty(t.prototype,"canRenderAsButtonGroup",{get:function(){return i.propertyGrid.useButtonGroup},enumerable:!1,configurable:!0}),t.prototype.renderAsButtonGroup=function(e,t){if("dropdown"===e.type)return!1;if("buttongroup"===e.type)return!0;if(this.isLocaleProp(e))return!1;if(!this.canRenderAsButtonGroup||!t||0==t.length||t.length>4)return!1;for(var o=0,n=0;n<t.length;n++){var r=this.getLocalizedText(e,t[n].value?t[n].value:t[n]);o+=r?r.length:0}return o<i.propertyGrid.maxCharsInButtonGroup},t.prototype.onCreated=function(e,t,o){this.setChoices(e,t,o),t.displayValueCallback=function(e){return e||t.optionsCaption}},t.prototype.onMasterValueChanged=function(e,t,i){this.setChoices(e,i,t),i.isEmpty()||o.ItemValue.getItemByValue(i.choices,i.value)||i.clearValue()},t.prototype.setChoicesCore=function(e,t,o){o&&Array.isArray(o)&&0!=o.length&&(this.updateObjBasedOnEmptyValueItem(t,o,e),e.choices=this.choicesFromPropChoices(t,o))},t.prototype.isLocaleProp=function(e){return"locale"===e.name},t.prototype.getLocalizedText=function(e,t){var o;return this.isLocaleProp(e)&&(o=G.getLocaleName(t))||"cellType"===e.name&&(o=G.getString("qt."+t))?o:null===t?null:G.getPropertyValueInEditor(e.name,t)},t.prototype.choicesFromPropChoices=function(e,t){for(var i=[],n=0;n<t.length;n++){var r=this.getJsonItem(e,t[n]);o.Helpers.isValueEmpty(r.value)||i.push(r)}return i},t.prototype.getJsonItem=function(e,t){var o={value:void 0!==t.value?t.value:t},i=t.text?t.text:"";return i||(i=this.getLocalizedText(e,o.value)),i&&i!=o.value&&(o.text=i),o},t.prototype.setChoices=function(e,t,o){var i=this,n=o.getChoices(e,(function(e){i.setChoicesCore(t,o,e)}));this.setChoicesCore(t,o,n)},t.prototype.getEmptyJsonItemValue=function(e,t){if(!t)return null;for(var i=0;i<t.length;i++){var n=t[i],r=void 0!==n.value?n.value:n;if(o.Helpers.isValueEmpty(r))return this.getJsonItem(e,n)}return null},t}(lt),Et=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"set"==e.type||"multiplevalues"==e.type},t.prototype.getJSON=function(t,i,n){var r=e.prototype.getJSON.call(this,t,i,n),a=!!o.Serializer.findClass("tagbox");return r.type=a?"tagbox":"checkbox",r.hasSelectAll=!a,r},t}(Pt),Vt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.hasChoices&&"page"==e.name},Object.defineProperty(t.prototype,"canRenderAsButtonGroup",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.onCreated=function(t,o,i){e.prototype.onCreated.call(this,t,o,i),o.valueFromDataCallback=function(e){return e?e.name:""},o.valueToDataCallback=function(e){if(e&&t&&t.getSurvey())return t.getSurvey().getPageByName(e)}},t}(Pt),It=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question"==e.type||"questionlist"===e.type},t.prototype.getJSON=function(e,t,o){var i={type:"dropdown",optionsCaption:G.getString("pe.conditionSelectQuestion"),choices:this.getChoices(e,t,o)};return"question"==t.type&&(i.allowClear=!1),i},t.prototype.getChoices=function(e,t,o){var n=this,r=Ze.getSurvey(e);if(!r)return[];var a=this.getQuestions(r,e);a||(a=[]);var s=!!o&&o.showTitlesInExpressions,l=a.map((function(e){var t=s?e.locTitle.renderedHtml:e.name;return o&&(t=o.getObjectDisplayName(e,"property-grid:property-editor","property-editor",t)),{value:n.getItemValue(e),text:t}}));return"asc"===i.logic.questionSortOrder&&ee.sortItems(l),l},t.prototype.getQuestions=function(e,t){return e.getAllQuestions()},t.prototype.getItemValue=function(e){return e.name},t}(lt),Ot=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question_selectbase"==e.type},t.prototype.isQuestionFit=function(e){return o.Serializer.isDescendantOf(e.getType(),"selectbase")},t.prototype.getQuestions=function(t,o){for(var i=e.prototype.getQuestions.call(this,t,o),n=[],r=0;r<i.length;r++){var a=i[r];a!==o&&this.isQuestionFit(a)&&n.push(a)}return n},t}(It),At=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"question_carryforward"==e.type},t.prototype.isQuestionFit=function(t){return t.isValueArray||e.prototype.isQuestionFit.call(this,t)},t}(Ot),Nt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"questionvalue"===e.type||"questionlist-savevaluename"===e.type},t.prototype.getItemValue=function(e){return e.getValueName()},t.prototype.getQuestions=function(t,i){return e.prototype.getQuestions.call(this,t,i).filter((function(e){return!o.Serializer.isDescendantOf(e.getType(),"nonvalue")}))},t}(It);nt.register(new ut),nt.register(new ht),nt.register(new bt),nt.register(new Ct),nt.register(new xt),nt.register(new Tt),nt.register(new Pt),nt.register(new Et),nt.register(new Vt),nt.register(new St),nt.register(new It),nt.register(new Nt),nt.register(new Ot),nt.register(new At),nt.register(new wt),nt.register(new yt),nt.register(new vt),nt.register(new gt),nt.register(new ct),nt.register(new pt),o.QuestionFactory.Instance.registerQuestion("buttongroup",(function(e){return new o.QuestionButtonGroupModel(e)}),!1);var Lt={root:"st-root-modern",container:"st-container-modern",header:"st-title st-container-modern__title",body:"st-body",bodyEmpty:"st-body st-body--empty",footer:"st-footer st-body__footer st-clearfix",title:"",description:"",logo:"st-logo",logoImage:"st-logo__image",headerText:"st-header__text",navigationButton:"",bodyNavigationButton:"st-navigation-btn",completedPage:"st-completedpage",navigation:{complete:"st-btn st-footer__complete-btn",prev:"st-btn st-footer__prev-btn",next:"st-btn st-footer__next-btn",start:"st-btn st-footer__start-btn",preview:"st-btn st-footer__preview-btn",edit:"st-btn st-footer__edit-btn"},panel:{title:"st-title st-panel__title",titleExpandable:"st-panel__title--expandable",titleOnExpand:"st-panel__title--expanded",titleOnError:"st-panel__title--error",description:"st-description st-panel__description",container:"st-element st-panel st-row__panel",content:"st-panel__content",icon:"st-panel__icon",iconExpanded:"st-panel__icon--expanded",footer:"st-panel__footer",requiredText:"st-panel__required-text"},paneldynamic:{root:"st-paneldynamic",navigation:"st-paneldynamic__navigation",title:"st-title st-question__title",button:"st-btn",buttonRemove:"st-paneldynamic__remove-btn",buttonAdd:"st-paneldynamic__add-btn",progressTop:"st-paneldynamic__progress st-paneldynamic__progress--top",progressBottom:"st-paneldynamic__progress st-paneldynamic__progress--bottom",buttonPrev:"st-paneldynamic__prev-btn",buttonNext:"st-paneldynamic__next-btn",progressContainer:"st-paneldynamic__progress-container",progress:"st-progress",progressBar:"st-progress__bar",progressText:"st-paneldynamic__progress-text",separator:"st-paneldynamic__separator",panelWrapper:"st-paneldynamic__panel-wrapper",panelWrapperInRow:"st-paneldynamic__panel-wrapper--in-row"},progress:"st-progress st-body__progress",progressBar:"st-progress__bar",progressText:"st-progress__text",progressTextInBar:"st-hidden",page:{root:"st-page st-body__page",title:"st-title st-page__title",description:"st-description st-page__description"},pageTitle:"st-title st-page__title",pageDescription:"st-description st-page__description",row:"st-row st-clearfix",question:{mainRoot:"st-element st-question st-row__question",flowRoot:"st-element st-question st-row__question st-row__question--flow",asCell:"st-table__cell",header:"st-question__header",headerLeft:"st-question__header--location--left",headerTop:"st-question__header--location--top",headerBottom:"st-question__header--location--bottom",content:"st-question__content",contentLeft:"st-question__content--left",titleLeftRoot:"",titleOnAnswer:"st-question__title--answer",titleOnError:"st-question__title--error",title:"st-title st-question__title",requiredText:"st-question__required-text",number:"st-question__num",description:"st-description st-question__description",descriptionUnderInput:"st-description st-question__description",comment:"st-comment",required:"st-question--required",titleRequired:"st-question__title--required",indent:20,footer:"st-question__footer",formGroup:"st-question__form-group",hasError:"",disabled:"st-question--disabled"},image:{root:"st-image",image:"sv_image_image"},error:{root:"st-question__erbox",icon:"",item:"",locationTop:"st-question__erbox--location--top",locationBottom:"st-question__erbox--location--bottom"},checkbox:{root:"st-selectbase",item:"st-item st-checkbox st-selectbase__item",itemSelectAll:"st-checkbox--selectall",itemNone:"st-checkbox--none",itemDisabled:"st-item--disabled st-checkbox--disabled",itemChecked:"st-item--checked st-checkbox--checked",itemHover:"st-item--allowhover st-checkbox--allowhover",itemInline:"st-selectbase__item--inline",label:"st-selectbase__label",labelChecked:"",itemControl:"st-visuallyhidden st-item__control st-checkbox__control",itemDecorator:"st-item__svg st-checkbox__svg",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-checkbox__decorator",other:"st-comment st-question__other",column:"st-selectbase__column"},radiogroup:{root:"st-selectbase",item:"st-item st-radio st-selectbase__item",itemInline:"st-selectbase__item--inline",label:"st-selectbase__label",labelChecked:"",itemDisabled:"st-item--disabled st-radio--disabled",itemChecked:"st-item--checked st-radio--checked",itemHover:"st-item--allowhover st-radio--allowhover",itemControl:"st-visuallyhidden st-item__control st-radio__control",itemDecorator:"st-item__svg st-radio__svg",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-radio__decorator",other:"st-comment st-question__other",clearButton:"st-btn st-selectbase__clear-btn",column:"st-selectbase__column"},boolean:{mainRoot:"st-question st-row__question st-question--boolean",root:"",item:"st-boolean",control:"st-boolean__control st-visuallyhidden",itemChecked:"st-boolean--checked",itemIndeterminate:"st-boolean--indeterminate",itemDisabled:"st-boolean--disabled",label:"st-boolean__label",switch:"st-boolean__switch",disabledLabel:"st-checkbox__label--disabled",itemDecorator:"st-checkbox__hidden",materialDecorator:"st-checkbox__rectangle",sliderText:"",slider:"st-boolean__thumb"},text:{root:"st-input st-text",small:"st-row__question--small",controlDisabled:"st-input--disabled",onError:"st-input--error"},multipletext:{root:"st-multipletext",item:"st-multipletext__item",itemTitle:"st-multipletext__item-title",row:"st-multipletext__row",cell:"st-multipletext__cell"},dropdown:{root:"st-selectbase",popup:"st-dropdown-popup svc-creator-popup",small:"st-row__question--small",control:"st-input st-dropdown",other:"st-comment st-question__other",onError:"st-input--error",label:"st-selectbase__label",item:"st-item st-radio st-selectbase__item",itemDisabled:"st-item--disabled st-radio--disabled",itemChecked:"st-item--checked st-radio--checked",itemHover:"st-item--allowhover st-radio--allowhover",itemControl:"st-visuallyhidden st-item__control st-radio__control",itemDecorator:"st-item__svg st-radio__svg",controlDisabled:"st-input--disabled",controlLabel:"st-item__control-label",materialDecorator:"st-item__decorator st-radio__decorator"},imagepicker:{root:"st-imagepicker",item:"st-imagepicker__item",itemInline:"st-imagepicker__item--inline",itemChecked:"st-imagepicker__item--checked",itemDisabled:"st-imagepicker__item--disabled",itemHover:"st-imagepicker__item--allowhover",label:"st-imagepicker__label",itemControl:"st-imagepicker__control",image:"st-imagepicker__image",itemText:"st-imagepicker__text",clearButton:"st-btn",other:"st-comment st-question__other"},matrix:{mainRoot:"st-question st-row__question st-scrollable",tableWrapper:"st-matrix",root:"st-table",noHeader:"st-table--no-header",rowError:"st-matrix__row--error",cell:"st-table__cell st-matrix__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text",label:"st-item st-radio st-matrix__label",itemValue:"st-visuallyhidden st-item__control st-radio__control",itemChecked:"st-radio--checked",itemDisabled:"st-item--disabled st-radio--disabled",itemHover:"st-radio--allowhover",materialDecorator:"st-item__decorator st-radio__decorator",itemDecorator:"st-item__svg st-radio__svg",cellText:"st-matrix__text",cellTextSelected:"st-matrix__text--checked",cellTextDisabled:"st-matrix__text--disabled"},matrixdropdown:{mainRoot:"st-question st-row__question st-scrollable",root:"st-table",noHeader:"st-table--no-header",cell:"st-table__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text"},matrixdynamic:{mainRoot:"st-question st-row__question st-scrollable",root:"st-table st-matrixdynamic",noHeader:"st-table--no-header",cell:"st-table__cell",headerCell:"st-table__cell st-table__cell--header",rowTextCell:"st-table__cell st-table__cell--row-text",button:"st-btn",detailRow:"st-table__row st-table__row--detail",detailButton:"st-table__cell--detail-button",detailButtonExpanded:"st-table__cell--detail-button--expanded",detailIcon:"st-detail-panel__icon",detailIconExpanded:"st-detail-panel__icon--expanded",detailPanelCell:"st-table__cell--detail-panel",actionsCell:"st-table__cell st-table__cell--actions",buttonAdd:"st-matrixdynamic__add-btn",buttonRemove:"st-matrixdynamic__remove-btn",iconAdd:"",iconRemove:""},rating:{root:"st-rating",item:"st-rating__item",itemHover:"st-rating__item--allowhover",selected:"st-rating__item--selected",minText:"st-rating__item-text st-rating__min-text",itemText:"st-rating__item-text",maxText:"st-rating__item-text st-rating__max-text",itemDisabled:"st-rating__item--disabled"},comment:{root:"st-comment",small:"st-row__question--small"},expression:"",file:{root:"st-file",other:"st-comment st-question__other",placeholderInput:"st-visuallyhidden",preview:"st-file__preview",fileSign:"st-hidden",fileSignBottom:"st-file__sign",fileDecorator:"st-file__decorator",fileInput:"st-visuallyhidden",noFileChosen:"st-description st-file__no-file-chosen",chooseFile:"st-btn st-file__choose-btn",disabled:"st-file__choose-btn--disabled",removeButton:"st-hidden",removeButtonBottom:"st-btn st-file__clean-btn",removeFile:"st-hidden",removeFileSvg:"st-file__remove-svg",wrapper:"st-file__wrapper"},signaturepad:{root:"st-signaturepad sjs_sp_container",small:"st-row__question--small",controls:"sjs_sp_controls",placeholder:"sjs_sp_placeholder",clearButton:"sjs_sp_clear"},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"sv_window",body:"sv_window_content",header:{root:"sv_window_title",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}}};function _t(e,t){if(!Array.isArray(e))return null;for(var o=0;o<e.length;o++)if(e[o].id===t)return e[o];return null}function Mt(e,t,o){var i=_t(t,"remove-row");i&&(i.component="sv-action-bar-item",i.iconName="icon-delete",i.innerCss="spg-action-button spg-action-button--danger",i.title=e.removeRowText,i.showTitle=!1,i.visibleIndex=10,i.action=function(){e.removeRowUI(o)})}function Dt(e){e.forEach((function(e){e.innerCss="".concat(e.innerCss||""," spg-action-button--muted")}))}var kt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),Object.defineProperty(t.prototype,"buttonClassName",{get:function(){return(new o.CssClassBuilder).append("svc-menu-action__button").append("svc-menu-action__button--with-subtitle","text-description-vertical"===this.contentType).append("svc-menu-action__button--pressed",this.pressed).append("svc-menu-action__button--selected",!!this.active).toString()},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:"icon"})],t.prototype,"contentType",void 0),t}(o.Action);function jt(e,t){var o=e.getBoundingClientRect();return t-o.top<=Ft.edgeHeight||o.bottom-t<=Ft.edgeHeight}function Rt(e,t){var o=e.getBoundingClientRect();return t-o.left<=Ft.edgeHeight||o.right-t<=Ft.edgeHeight}function Bt(e,t,i,n){void 0===n&&(n=null);var r=i.height/i.width,a=e-i.x,s=t-i.y;return"top-bottom"==n?s>=i.height/2?o.DragTypeOverMeEnum.Bottom:o.DragTypeOverMeEnum.Top:"left-right"==n?a>=i.width/2?o.DragTypeOverMeEnum.Right:o.DragTypeOverMeEnum.Left:s>=r*a?s>=-r*a+i.height?o.DragTypeOverMeEnum.Bottom:o.DragTypeOverMeEnum.Left:s>=-r*a+i.height?o.DragTypeOverMeEnum.Right:o.DragTypeOverMeEnum.Top}function qt(e){return e instanceof o.QuestionPanelDynamicModel}var Ht,Ft=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.insideContainer=null,t.prevIsEdge=null,t.dragOverIndicatorElement=null,t.isDraggedElementSelected=!1,t.doBanDropHere=function(){t.removeDragOverMarker(t.dragOverIndicatorElement),t.removeDragOverMarker(t.dropTarget)},t.doDrop=function(){var e;if(t.dropTarget){var i=t.parentElement,n=t.draggedElement,r=t.draggedElement;if(n.isPage&&n instanceof o.PageModel){var a=n.survey;return a.pages.splice(a.pages.indexOf(n),1),a.pages.splice(a.pages.indexOf(t.dropTarget)+(t.dragOverLocation===o.DragTypeOverMeEnum.Top?0:1),0,n),n}var s=r.parent||r.page;s&&(i.survey.startMovingQuestion(),s.removeElement(r));var l=(null===(e=t.dragOverIndicatorElement)||void 0===e?void 0:e.isPanel)?t.dragOverIndicatorElement:t.dropTarget;if(qt(l)&&t.insideContainer&&(l=l.template),!(l.isPage&&l.elements.length>0)||t.insideContainer){if((l.isPanel||l.isPage)&&t.insideContainer)l.insertElement(r);else{var u=l.parent||l.page;u&&u.insertElement(r,l,function(){switch(t.dragOverLocation){case 4:return"top";case 5:return"right";case 6:default:return"bottom";case 7:return"left"}}())}return i.survey.stopMovingQuestion(),n}}},t}return K(t,e),Object.defineProperty(t.prototype,"draggedElementType",{get:function(){return this.draggedElement&&this.draggedElement.isPage?"survey-page":"survey-element"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"maxNestedPanels",{get:function(){return this.onGetMaxNestedPanels?this.onGetMaxNestedPanels():-1},enumerable:!1,configurable:!0}),t.prototype.startDragToolboxItem=function(e,t,o){var i=this.createElementFromJson(t);i.toolboxItemTitle=o.title,i.toolboxItemIconName=o.iconName,this.startDrag(e,i)},t.prototype.startDragSurveyElement=function(e,t,o){this.isDraggedElementSelected=o,this.startDrag(e,t)},t.prototype.getShortcutText=function(t){return t.toolboxItemTitle||e.prototype.getShortcutText.call(this,t)},t.prototype.createDraggedElementShortcut=function(e,t,o){var i=document.createElement("div"),n=document.createElement("span");return n.className="svc-dragged-element-shortcut__text",n.innerText=e,this.draggedElement.toolboxItemIconName&&i.appendChild(this.createDraggedElementIcon()),i.appendChild(n),i.className=this.getDraggedElementClass(),i},t.prototype.createDraggedElementIcon=function(){var e=document.createElement("span");e.className="svc-dragged-element-shortcut__icon";var t=this.draggedElement.toolboxItemIconName,o='<svg class="sv-svg-icon" role="img" style="width: 24px; height: 24px;"><use xlink:href="#'.concat(t,'"></use></svg>');return e.innerHTML=o,e},t.prototype.getDraggedElementClass=function(){var e="svc-dragged-element-shortcut";return this.draggedElement.toolboxItemIconName&&(e+=" svc-dragged-element-shortcut--has-icon"),this.isDraggedElementSelected&&(e+=" svc-dragged-element-shortcut--selected"),e},t.prototype.createElementFromJson=function(e){var t=this.createNewElement(e);return t.setSurveyImpl?t.setSurveyImpl(this.survey):t.setData(this.survey),t.renderWidth="100%",t},t.prototype.createNewElement=function(e){var t=o.Serializer.createClass(e.type);return(new o.JsonObject).toObject(e,t),t},t.prototype.findDropTargetNodeByDragOverNode=function(e){if(e.closest(".svc-row--ghost")){var t="[data-sv-drop-target-survey-element='sv-drag-drop-ghost-survey-element-name']",o=e.closest(t)||e.querySelector(t);if(o)return o}return e.closest(this.dropTargetDataAttributeName)},t.prototype.getDropTargetByDataAttributeValue=function(e,o,i){var n=this.dragOverIndicatorElement;if(!e){var r=o.parentElement.closest(this.dropTargetDataAttributeName);e=this.getDataAttributeValueByNode(r)}if(!e)throw new Error("Can't find drop target survey element name");if(e===t.ghostSurveyElementName)return this.prevDropTarget;if("newGhostPage"===e)return t.newGhostPage;var a,s,l=this.survey.getPageByName(e);if(l)return l;if(this.survey.pages.forEach((function(t){var o=t.getElementByName(e);o&&(a=o,s=o)})),"matrixdropdown"!==a.getType()&&"matrixdynamic"!==a.getType()||"none"===a.detailPanelMode||!this.insideContainer||(a=a.detailPanel),!a.page){var u=o.parentElement.closest("[data-sv-drop-target-page]");e=u.dataset.svDropTargetPage;var p=this.survey.getPageByName(e);a.__page=p}return this.dragOverIndicatorElement=s,this.dragOverIndicatorElement!=n&&this.removeDragOverMarker(n),a},t.prototype.isDropTargetValid=function(e,i,n){if(void 0===n&&(n=o.DragTypeOverMeEnum.Top),!e)return!1;if(e===this.draggedElement)return!1;if("paneldynamic"===this.draggedElement.getType()&&e===this.draggedElement.template)return!1;if(this.maxNestedPanels>=0&&this.draggedElement.isPanel){var r=ee.getElementDeepLength(e);if(n!==o.DragTypeOverMeEnum.InsideEmptyPanel&&e.isPanel&&r--,this.maxNestedPanels<r)return!1}return!t.restrictDragQuestionBetweenPages||!this.shouldRestricDragQuestionBetweenPages(e)},t.prototype.shouldRestricDragQuestionBetweenPages=function(e){var t=this.draggedElement.page,o=e.isPage?e:e.page;return t&&t!==o},t.prototype.findDeepestDropTargetChild=function(e){for(var t=this.dropTargetDataAttributeName,o=e;e;)o=e,e=e.querySelector(t);return o},t.prototype.isAllowDragOver=function(e,t){if(!this.survey||this.survey.onDragDropAllow.isEmpty)return!0;var i={allow:!0,parent:this.parentElement,source:this.draggedElement,toElement:e,draggedElement:this.draggedElement,fromElement:this.draggedElement.parent,target:e,insertAfter:void 0,insertBefore:void 0,allowDropNextToAnother:!0};return t!==o.DragTypeOverMeEnum.Bottom&&t!==o.DragTypeOverMeEnum.Right||(i.insertAfter=e),t!==o.DragTypeOverMeEnum.Top&&t!==o.DragTypeOverMeEnum.Left||(i.insertBefore=e),this.survey.onDragDropAllow.fire(this.survey,i),i.allowDropNextToAnother||(t===o.DragTypeOverMeEnum.Left&&(this.dragOverLocation=o.DragTypeOverMeEnum.Top),t===o.DragTypeOverMeEnum.Right&&(this.dragOverLocation=o.DragTypeOverMeEnum.Bottom)),i.allow},t.prototype.dragOverCore=function(e,t){var i=this.dragOverIndicatorElement,n=this.dropTarget;if(this.isSameElement(e))this.allowDropHere=!1;else if(this.dropTarget=e,this.dragOverLocation=t,this.parentElement=this.dropTarget.isPage?this.dropTarget:this.dropTarget.page||this.dropTarget.__page,this.isAllowDragOver(e,t)){if(t==o.DragTypeOverMeEnum.InsideEmptyPanel)this.dragOverIndicatorElement=this.dropTarget,this.dragOverIndicatorElement.dragTypeOverMe=o.DragTypeOverMeEnum.InsideEmptyPanel;else{var r=this.parentElement.dragDropFindRow(this.dropTarget);r&&r.elements.length>1&&(this.dragOverLocation===o.DragTypeOverMeEnum.Top||this.dragOverLocation===o.DragTypeOverMeEnum.Bottom)?(r.dragTypeOverMe=this.dragOverLocation,this.dragOverIndicatorElement=r):(this.dropTarget.dragTypeOverMe=this.dragOverLocation,this.dragOverIndicatorElement=this.dropTarget)}this.dragOverIndicatorElement!=i&&this.removeDragOverMarker(i),this.dropTarget!=n&&this.removeDragOverMarker(n)}else this.allowDropHere=!1},t.prototype.isSameElement=function(e){for(;e;){if(e===this.draggedElement)return!0;e=e.parent}return!1},t.prototype.dragOver=function(e){var t=this.findDropTargetNodeFromPoint(e.clientX,e.clientY);if(t){var n=this.insideContainer;this.insideContainer=!jt(t,e.clientY)&&!Rt(t,e.clientX);var r=this.getDropTargetByNode(t,e);!!n!=!!this.insideContainer&&(r.dragTypeOverMe=null);var a=t.getBoundingClientRect(),s=!i.dragDrop.allowDragToTheSameLine||this.draggedElement&&this.draggedElement.isPage?"top-bottom":null,l=Bt(e.clientX,e.clientY,a,s);r&&((r.isPanel||r.isPage)&&0===r.elements.length||qt(r)&&0==r.template.elements.length)&&(r.isPage||this.insideContainer)&&(l=o.DragTypeOverMeEnum.InsideEmptyPanel);var u={survey:this.survey,draggedSurveyElement:this.draggedElement,dragOverSurveyElement:r,clientX:e.clientX,clientY:e.clientY,dragOverRect:a,insideContainer:this.insideContainer,dragOverLocation:l};this.onDragOverLocationCalculating&&(this.onDragOverLocationCalculating(u),l=u.dragOverLocation,this.insideContainer=u.insideContainer),this.isDropTargetValid(r,t,l)?(this.allowDropHere=!0,this.dragOverCore(r,l)):this.banDropHere()}else this.banDropHere()},t.prototype.onStartDrag=function(){this.draggedElement.isDragMe=!0},t.prototype.moveElementInPanel=function(e,t,o,i){var n=t.parent.elements.indexOf(t);i>n&&i--,t===o&&n===i||(e.removeElement(t),e.addElement(o,i))},t.prototype.removeDragOverMarker=function(e){e&&(e.dragTypeOverMe=null)},t.prototype.clear=function(){this.insideContainer=null,this.removeDragOverMarker(this.prevDropTarget),this.removeDragOverMarker(this.dropTarget),this.removeDragOverMarker(this.dragOverIndicatorElement),this.draggedElement&&(this.draggedElement.isDragMe=!1),e.prototype.clear.call(this)},t.prototype.getTargetParent=function(e){var t=e.isPage||e.isPanel?e:e.parent;return"paneldynamic"===e.getType()&&(t=e.templateValue),t},t.prototype.getTargetRow=function(e){var t;return this.getTargetParent(e).rows.forEach((function(o){-1!==o.elements.indexOf(e)&&(t=o)})),t},t.newGhostPage=null,t.restrictDragQuestionBetweenPages=!1,t.edgeHeight=30,t.nestedPanelDepth=-1,t.ghostSurveyElementName="sv-drag-drop-ghost-survey-element-name",t}(o.DragDropCore),Qt=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.needToShrink=function(e,t){return"start"==e.innerItem.location&&t||"start"!=e.innerItem.location},t.prototype.setModeForActions=function(e,t){var o=this;void 0===t&&(t=[]),this.visibleActions.forEach((function(i){-1==t.indexOf(i.id)?o.needToShrink(i,e)?i.mode=i.canShrink?"small":"removed":i.mode="large":i.mode="removed"}))},t.prototype.calcItemSize=function(e,t,o){return void 0===o&&(o=[]),-1!=o.indexOf(e.id)?0:this.needToShrink(e,t)?e.canShrink?e.minDimension:0:e.maxDimension},t.prototype.fit=function(e,t){var o=this;if(!(e<=0)){this.dotsItem.visible=!1;var i=this.visibleActions;e>=i.reduce((function(e,t){return e+t.maxDimension}),0)?i.forEach((function(e){return e.mode="large"})):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!1)}),0)?this.setModeForActions(!1):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!1,["convertInputType"])}),0)?this.setModeForActions(!1,["convertInputType"]):e>=i.reduce((function(e,t){return e+o.calcItemSize(t,!0)}),0)?this.setModeForActions(!0):(this.visibleActions.forEach((function(e){"convertTo"!=e.id?"convertInputType"!=e.id?e.mode="popup":e.mode="removed":e.mode="small"})),this.dotsItem.visible=!0,this.hiddenItemsListModel.setItems(i.filter((function(e){return"popup"==e.mode})).map((function(e){return e.innerItem}))))}},t}(o.AdaptiveActionContainer),Ut=function(e){function t(t,i){var n=e.call(this)||this;return n.creator=t,n.animationCollapsed=new o.AnimationBoolean(n.getExpandCollapseAnimationOptions(),(function(e){n._renderedCollapsed=!e}),(function(){return!n.renderedCollapsed})),n.draggedIn=!1,n.selectedPropPageFunc=function(e,t){"isSelectedInDesigner"===t.name&&n.onElementSelectedChanged(t.newValue)},n.sidebarFlyoutModeChangedFunc=function(e,t){"flyoutMode"===t.name&&n.updateActionsProperties()},n.expandCollapseAction=n.getExpandCollapseAction(),n.createActionContainers(),n.attachToUI(i),n}return K(t,e),Object.defineProperty(t.prototype,"dragInsideCollapsedContainer",{get:function(){return this.collapsed&&this.creator.dragDropSurveyElements.insideContainer},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){return null},t.prototype.getInnerAnimatedElements=function(){return[]},t.prototype.getCollapsingCssClassName=function(){return"svc-question--leave"},t.prototype.getExpandingCssClassName=function(){return"svc-question--enter"},Object.defineProperty(t.prototype,"hoverDelay",{get:function(){return this.creator.pageHoverDelay},enumerable:!1,configurable:!0}),t.prototype.hover=function(e,t){var o=this,i="__svc_question_processed";e[i]||"mouseover"!==e.type?(clearTimeout(this.hoverTimeout),this.hoverTimeout=void 0,this.isHovered=!1):(this.hoverTimeout||(this.hoverTimeout=setTimeout((function(){o.isHovered=!0,o.hoverTimeout=void 0}),this.hoverDelay)),e[i]=!0)},t.prototype.getExpandCollapseAnimationOptions=function(){var e=this,t=function(t,i){(0,o.prepareElementForVerticalAnimation)(t);var n=e.getInnerAnimatedElements();n.forEach((function(e){(0,o.prepareElementForVerticalAnimation)(e)})),n.forEach((function(e){e.classList.add(i)}))},i=function(t,i){e.expandCollapseAnimationRunning=!1,(0,o.cleanHtmlElementAfterAnimation)(t);var n=e.getInnerAnimatedElements();n.forEach((function(e){(0,o.cleanHtmlElementAfterAnimation)(e)})),n.forEach((function(e){e.classList.remove(i)}))};return{getRerenderEvent:function(){return e.onElementRerendered},getEnterOptions:function(){var o=e.getExpandingCssClassName();return{cssClass:o,onBeforeRunAnimation:function(e){t(e,o)},onAfterRunAnimation:function(e){i(e,o)}}},getLeaveOptions:function(){var o=e.getCollapsingCssClassName();return{cssClass:o,onBeforeRunAnimation:function(e){t(e,o)},onAfterRunAnimation:function(e){i(e,o)}}},getAnimatedElement:function(){return e.getAnimatedElement()},isAnimationEnabled:function(){return e.animationAllowed}}},Object.defineProperty(t.prototype,"renderedCollapsed",{get:function(){return!!this._renderedCollapsed},set:function(e){this.animationAllowed&&e!==this.renderedCollapsed&&(this.expandCollapseAnimationRunning=!0),this.animationCollapsed.sync(!e)},enumerable:!1,configurable:!0}),t.prototype.createActionContainers=function(){this.actionContainer=this.createActionContainer()},t.prototype.createActionContainer=function(){var e=new Qt;return e.dotsItem.iconSize=16,e.dotsItem.popupModel.horizontalPosition="center",e},Object.defineProperty(t.prototype,"canExpandOnDrag",{get:function(){return this.surveyElement.isPanel||this.surveyElement.isPage||qt(this.surveyElement)},enumerable:!1,configurable:!0}),t.prototype.dragIn=function(){var e=this;this.draggedIn||this.canExpandOnDrag&&this.collapsed&&(this.draggedIn=!0,this.dragCollapsedTimer=setTimeout((function(){e.expandWithDragIn()}),this.creator.expandOnDragTimeOut))},t.prototype.expandWithDragIn=function(){this.collapsed=!1,this.dragCollapsedTimer=void 0},t.prototype.dragOut=function(){this.draggedIn&&(clearTimeout(this.dragCollapsedTimer),this.draggedIn=!1)},t.prototype.dblclick=function(e){this.allowExpandCollapse&&(this.collapsed=!this.collapsed),e.stopPropagation()},t.GetAdorner=function(e){return e.getPropertyValue(t.AdornerValueName)},t.RestoreStateFor=function(e){var o=t.GetAdorner(e);o&&o.restoreState()},t.prototype.restoreState=function(){var e;if(this.surveyElement){var t=null===(e=this.creator.designerStateManager)||void 0===e?void 0:e.getElementState(this.surveyElement);this.collapsed=t.collapsed}},t.prototype.detachElement=function(e){e&&(e.getPropertyValue(t.AdornerValueName)!==this||e.isDisposed||e.setPropertyValue(t.AdornerValueName,null),e.onPropertyChanged.remove(this.selectedPropPageFunc),this.cleanActionsContainer())},t.prototype.attachElement=function(e){var o,i;e&&(null===(i=null===(o=this.creator)||void 0===o?void 0:o.designerStateManager)||void 0===i||i.initForElement(e),e.onPropertyChanged.add(this.selectedPropPageFunc),this.restoreState(),this.updateActionsContainer(e),this.updateActionsProperties(),e.setPropertyValue(t.AdornerValueName,this))},t.prototype.setSurveyElement=function(e){this.detachElement(this.surveyElement),this.surveyElement=e,this.attachElement(this.surveyElement)},t.prototype.checkActionProperties=function(){this.creator.isElementSelected(this.surveyElement)&&this.updateActionsProperties()},t.prototype.attachToUI=function(e,t){t&&(this.rootElement=t),this.surveyElement!=e&&(this.setSurveyElement(e),this.creator.sidebar.onPropertyChanged.add(this.sidebarFlyoutModeChangedFunc),this.creator.expandCollapseManager.add(this))},t.prototype.detachFromUI=function(){this.rootElement=void 0,this.detachElement(this.surveyElement),this.surveyElement=void 0,this.creator.sidebar.onPropertyChanged.remove(this.sidebarFlyoutModeChangedFunc),this.creator.expandCollapseManager.remove(this)},t.prototype.dispose=function(){this.detachFromUI(),this.actionContainer.isDisposed||this.actionContainer.dispose(),e.prototype.dispose.call(this)},t.prototype.onElementSelectedChanged=function(e){e&&this.updateActionsProperties()},t.prototype.getExpandCollapseAction=function(){var e=this;return{id:"collapse",css:"sv-action-bar-item--secondary sv-action-bar-item--collapse",iconName:new o.ComputedUpdater((function(){return e.collapsed?"icon-restore_16x16":"icon-collapse-detail-light_16x16"})),iconSize:16,action:function(){e.collapsed=!e.collapsed}}},t.prototype.cleanActionsContainer=function(){var e=this.actionContainer.actions;this.actionContainer.setItems([]),e.forEach((function(e){return e.dispose&&e.dispose()}))},t.prototype.updateActionsContainer=function(e){var t=[];this.buildActions(t),this.creator.onElementMenuItemsChanged(e,t),this.actionContainer.setItems(t)},t.prototype.updateActionsProperties=function(){this.isDisposed||this.updateElementAllowOptions(this.creator.getElementAllowOperations(this.surveyElement),this.isOperationsAllow())},t.prototype.getAllowDragging=function(e){return e.allowDragging},t.prototype.getAllowExpandCollapse=function(e){return"never"!=this.creator.expandCollapseButtonVisibility&&(null==e.allowExpandCollapse||!!e.allowExpandCollapse)},t.prototype.updateElementAllowOptions=function(e,t){if(this.allowDragging=t&&this.getAllowDragging(e),this.allowExpandCollapse=this.getAllowExpandCollapse(e),this.allowEditOption=null==e.allowEdit||!!e.allowEdit,this.updateActionVisibility("delete",t&&e.allowDelete),this.updateActionVisibility("duplicate",t&&e.allowCopy),this.updateActionVisibility("collapse",this.allowExpandCollapse),void 0===e.allowShowSettings){var o=void 0!==e.allowEdit?t&&e.allowEdit:this.creator.sidebar.flyoutMode;this.updateActionVisibility("settings",o)}else this.updateActionVisibility("settings",e.allowShowSettings);this.setShowAddQuestionButton(!1!==e.allowEdit)},t.prototype.isOperationsAllow=function(){return!this.creator.readOnly},t.prototype.updateActionVisibility=function(e,t){var o=this.getActionById(e);o&&o.visible!=t&&(o.visible=t)},t.prototype.getActionById=function(e){return this.actionContainer.getActionById(e)},t.prototype.buildActions=function(e){var t=this;e.push(new o.Action({id:"duplicate",iconName:"icon-duplicate_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("survey.duplicate"),visibleIndex:10,iconSize:16,action:function(){return t.duplicate()},onFocus:function(e,o){return t.disableActionFocusing(e,o)}})),e.push(new o.Action({id:"settings",iconName:"icon-settings_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("ed.settings"),locTooltipName:"ed.settingsTooltip",visibleIndex:20,iconSize:16,action:function(){t.creator.setShowSidebar(!0,!0),t.creator.isMobileView||t.creator.sidebar.executeOnExpand((function(){t.creator.propertyGrid.getAllQuestions()[0].focus()}))}})),e.push(new o.Action({id:"delete",iconName:"icon-delete_16x16",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("pe.delete"),visibleIndex:30,iconSize:16,action:function(){t.delete()},onFocus:function(e,o){return t.disableActionFocusing(e,o)}}))},t.prototype.disableActionFocusing=function(e,t){this.isDisableSelecting=e},t.prototype.canSelectElement=function(){var e=!this.isDisableSelecting;return this.isDisableSelecting=!1,e},Object.defineProperty(t.prototype,"allowEdit",{get:function(){return!!this.creator&&!this.creator.readOnly&&this.allowEditOption},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showAddQuestionButton",{get:function(){return this.getPropertyValue("showAddQuestionButton")},enumerable:!1,configurable:!0}),t.prototype.setShowAddQuestionButton=function(e){this.setPropertyValue("showAddQuestionButton",e&&this.allowEdit&&!!this.creator&&this.creator.showAddQuestionButton)},t.prototype.duplicate=function(){},t.prototype.delete=function(){this.creator.deleteElement(this.surveyElement)},t.prototype.getCss=function(){return(new o.CssClassBuilder).append("svc-hovered svc-hovered-ready",this.isHovered).toString()},t.AdornerValueName="__sjs_creator_adorner",J([(0,o.property)({defaultValue:!0})],t.prototype,"allowDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"expandCollapseAnimationRunning",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowExpandCollapse",void 0),J([(0,o.property)({onSet:function(e,t){t.renderedCollapsed=e,t.creator.designerStateManager&&!t.creator.designerStateManager.isSuspended&&t.surveyElement&&(t.creator.designerStateManager.getElementState(t.surveyElement).collapsed=e),setTimeout((function(){t.creator.survey.pages.forEach((function(e){return e.ensureRowsVisibility()})),t.creator.survey.getAllPanels().forEach((function(e){return e.ensureRowsVisibility()}))}),50)}})],t.prototype,"collapsed",void 0),J([(0,o.property)()],t.prototype,"_renderedCollapsed",void 0),J([(0,o.property)()],t.prototype,"isAnimationRunningCollapsed",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isHovered",void 0),t}(o.Base);r(1868),o.FunctionFactory.Instance.register("localeEnableIf",(function(e){if(Ht||!this.question||!this.row)return!1;var t=this.question.parentQuestion;if(!t)return!1;Ht=!0;var o=t.visibleRows.indexOf(this.row);if(Ht=!1,o<=0)return!1;var n=t.value;if(!Array.isArray(n))return!0;var r=n[o];if(!r||r.isSelected)return!0;for(var a=0,s=1;s<n.length;s++)n[s].isSelected&&a++;return a<i.translation.maximumSelectedLocales}));var Gt=function(e){function t(t,o){var i=e.call(this)||this;return i.name=t,i.translation=o,i}return K(t,e),Object.defineProperty(t.prototype,"isGroup",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.fillLocales=function(e){},t.prototype.mergeLocaleWithDefault=function(e){},t.prototype.makeObservable=function(){this.fireOnObjCreating()},t.prototype.deleteLocaleStrings=function(e){},t.prototype.applyEditLocale=function(e){},t.prototype.fireOnObjCreating=function(e){void 0===e&&(e=null),this.translation&&(e||(e=this),this.translation.fireOnObjCreating(e))},t}(o.Base),Zt=function(e){function t(t,o){var i=e.call(this)||this;return i.locString=t,i.locale=o,i.text=i.locString.getLocaleText(i.locale),i}return K(t,e),t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.isReadOnly||"text"!==t||this.locString.setLocaleText(this.locale,i)},t.prototype.getType=function(){return"translationitemstring"},J([(0,o.property)()],t.prototype,"text",void 0),J([(0,o.property)()],t.prototype,"placeholder",void 0),t}(o.Base),zt=function(e){function t(t,o,i,n,r,a){void 0===i&&(i=""),void 0===a&&(a=null);var s=e.call(this,t,n)||this;s.name=t,s.locString=o,s.defaultValue=i,s.context=r,s.property=a,s.translation&&(s.readOnly=s.translation.readOnly),s.hashValues={};var l=s;return s.afterRender=function(e,t){l.translation&&l.translation.translateItemAfterRender(l,e,t.locale)},s.fireOnObjCreating(),s}return K(t,e),Object.defineProperty(t.prototype,"maxLength",{get:function(){return this.property?this.property.maxLength:-1},enumerable:!1,configurable:!0}),t.prototype.makeObservable=function(){for(var t in e.prototype.makeObservable.call(this),this.hashValues)this.fireOnObjCreating(this.hashValues[t])},t.prototype.getType=function(){return"translationitem"},Object.defineProperty(t.prototype,"text",{get:function(){return this.customText?this.customText:this.localizableName},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localizableName",{get:function(){var e=this.context&&this.context.getType&&this.context.getType();return G.getPropertyNameInEditor(e,this.name)},enumerable:!1,configurable:!0}),t.prototype.getLocText=function(e){return this.locString.getLocaleText(e)},t.prototype.setLocText=function(e,t){this.locString.setLocaleText(e,t),this.translation.tranlationChangedCallback&&this.translation.tranlationChangedCallback(e,this.name,t,this.context)},t.prototype.applyEditLocale=function(e){var t=this.values(e);t&&t.text&&this.setLocText(e,t.text)},t.prototype.values=function(e){var t;if(!this.hashValues[e]){var o=new Zt(this.locString,e);o.isReadOnly=!!(null===(t=this.translation)||void 0===t?void 0:t.getEditLocale()),e||(o.placeholder=this.defaultValue),this.hashValues[e]=o,this.fireOnObjCreating(o)}return this.hashValues[e]},t.prototype.fillLocales=function(e){for(var t=this.getKeys(),i=0;i<t.length;i++){var n=t[i];n&&e.indexOf(n)<0&&n!==o.LocalizableString.defaultLocale&&e.push(n)}},t.prototype.toJSON=function(){var e=this,t=this.locString.getJson(),o=Object.keys(this.hashValues);return o.length>0&&o.forEach((function(o){var i=e.hashValues[o].text;i&&(t||(t={}),"string"==typeof t&&(t={default:t}),t[o]=i)})),(t=this.correctJSON(t))&&"string"!=typeof t?t:{default:t}},t.prototype.correctJSON=function(e){if(!e||"string"==typeof e)return e;if(Array.isArray(e))return e.join("\n");for(var t in e)Array.isArray(e[t])&&(e[t]=e[t].join("\n"));return e},t.prototype.getKeys=function(){return this.locString.getLocales()},t.prototype.mergeLocaleWithDefault=function(e){var t=this.locString.getLocaleText(e);t&&(this.locString.setLocaleText("",t),this.locString.setLocaleText(e,null))},t.prototype.deleteLocaleStrings=function(e){this.setLocText(e,void 0)},t.prototype.getDefaultLocaleText=function(e){void 0===e&&(e=!1);var t=this.locString.getLocaleText("");return t||(t=this.getPlaceholder("",e)),t},t.prototype.getPlaceholder=function(e,t){void 0===t&&(t=!1);var i=e&&"default"!==e?e:o.surveyLocalization.defaultLocale,n=t?"":G.getString("ed.translationPlaceHolder",i);return this.context instanceof o.SurveyModel?o.surveyLocalization.getString(this.name,e)||n:this.context instanceof o.PageModel||"title"!==this.name?"choices"===this.context.ownerPropertyName&&"itemvalue"===this.context.getType()&&(this.getPlaceholderText(e)||this.getItemValuePlaceholderText())||n:this.getPlaceholderText(e)||this.context.name},t.prototype.getTextForExport=function(e){return this.locString.getLocaleText(e)||(e.indexOf("-")<0?"":this.getPlaceholderText(e))},t.prototype.getPlaceholderText=function(e){if(!e||"default"===e)return"";var t=this.getRootDialect(e);return this.locString.getLocaleText(t)},t.prototype.getRootDialect=function(e){var t=e.indexOf("-");return t<0||(e=e.substring(0,t))===o.surveyLocalization.defaultLocale?"":e},t.prototype.getItemValuePlaceholderText=function(){var e=this.context.value;return o.Helpers.isValueEmpty(e)?"":e.toString()},J([(0,o.property)({defaultValue:!1})],t.prototype,"readOnly",void 0),t}(Gt),Jt=function(e){function t(t,o,i,n,r){void 0===i&&(i=null),void 0===n&&(n=""),void 0===r&&(r=!1);var a=e.call(this,t,i)||this;return a.name=t,a.obj=o,a.text=n,a.hasIndent=r,a.isRootValue=!1,a.removeLocale=function(e){a.translation&&a.translation.removeLocale(e)},a.text||(a.text=t),a.reset(),a.fireOnObjCreating(),a}return K(t,e),t.prototype.getType=function(){return"translationgroup"},Object.defineProperty(t.prototype,"items",{get:function(){return this.itemValues},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locItems",{get:function(){return this.itemValues.filter((function(e){return e instanceof zt}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allLocItems",{get:function(){var e=new Array;return this.fillLocItems(e),e},enumerable:!1,configurable:!0}),t.prototype.fillLocItems=function(e){this.itemValues.forEach((function(t){t.isGroup?t.fillLocItems(e):e.push(t)}))},Object.defineProperty(t.prototype,"isRoot",{get:function(){return this.isRootValue},enumerable:!1,configurable:!0}),t.prototype.setAsRoot=function(){this.isRootValue=!0},t.prototype.setParent=function(e){this.parentValue=e},Object.defineProperty(t.prototype,"parent",{get:function(){return this.parentValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"fullName",{get:function(){var e=this.obj.name===this.name||this.isRoot?"_props":"",t=this.name+e;if(this.isRoot||!this.parent)return t;var o=this.parent.getNameForChild();return(o?o+"_":"")+t},enumerable:!1,configurable:!0}),t.prototype.getNameForChild=function(){return this.isRoot?"":this.isFinalNameObj?this.name:this.fullName},Object.defineProperty(t.prototype,"isFinalNameObj",{get:function(){return this.obj.isQuestion||this.obj.isPage||this.obj.isPanel},enumerable:!1,configurable:!0}),t.prototype.getItemByName=function(e){for(var t=0;t<this.itemValues.length;t++)if(this.itemValues[t].name==e)return this.itemValues[t];return null},Object.defineProperty(t.prototype,"groups",{get:function(){return this.itemValues.filter((function(e){return e instanceof t}))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isGroup",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locales",{get:function(){return this.translation?this.translation.locales:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeLocaleText",{get:function(){return G.getString("pe.remove")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localeCount",{get:function(){return Array.isArray(this.locales)?this.locales.length:0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"locWidth",{get:function(){var e=this.localeCount;return e<2?"100%":Math.floor(100/e).toString()+"%"},enumerable:!1,configurable:!0}),t.prototype.getLocaleName=function(e){return this.translation?this.translation.getLocaleName(e):G.getLocaleName(e)},t.prototype.reset=function(){this.itemValues=[],this.fillItems()},t.prototype.fillLocales=function(e){for(var t=0;t<this.items.length;t++)this.items[t].fillLocales(e)},t.prototype.makeObservable=function(){e.prototype.makeObservable.call(this);for(var t=0;t<this.items.length;t++)this.items[t].makeObservable()},Object.defineProperty(t.prototype,"showAllStrings",{get:function(){return!this.translation||this.translation.showAllStrings},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasItems",{get:function(){if(this.locItems.length>0)return!0;for(var e=this.groups,t=0;t<e.length;t++)if(e[t].hasItems)return!0;return!1},enumerable:!1,configurable:!0}),t.prototype.mergeLocaleWithDefault=function(e){this.itemValues.forEach((function(t){return t.mergeLocaleWithDefault(e)}))},t.prototype.deleteLocaleStrings=function(e){this.items.forEach((function(t){return t.deleteLocaleStrings(e)}))},t.prototype.applyEditLocale=function(e){this.items.forEach((function(t){return t.applyEditLocale(e)}))},t.prototype.fillItems=function(){if(this.isItemValueArray(this.obj))this.createItemValuesLocale();else if(this.obj&&this.obj.getType){for(var e=this.getLocalizedProperties(this.obj),o=0;o<e.length;o++){var i=e[o],n=this.createTranslationItem(this.obj,e[o]);n&&this.itemValues.push(n)}for(e=this.getArrayProperties(this.obj),o=0;o<e.length;o++){i=e[o];var r=this.obj[i.name];this.isItemValueArray(r)?this.canShowProperty(i,Array.isArray(r)&&r.length>0)&&this.addNewGroup(new t(i.name,r,this.translation,G.getPropertyName(i.name),!0)):this.createGroups(r,i)}this.createMatrixCellsGroup(),this.sortItems()}},t.prototype.createMatrixCellsGroup=function(){var e=this;o.Serializer.getPropertiesByObj(this.obj).forEach((function(t){"cells"===t.type&&e.canShowProperty(t,!0)&&e.createMatrixCellsGroupCore(t)}))},t.prototype.createMatrixCellsGroupCore=function(e){var i=this,n=this.obj[e.name];if(!n.isEmpty){var r=this.obj,a=new t(e.name,n,this.translation,G.getPropertyName(e.name)),s=[{value:o.settings.matrix.defaultRowName,text:G.getString("qt.default")}];r.rows.forEach((function(e){return s.push({value:e.value,text:e.text})})),s.forEach((function(e){r.columns.forEach((function(t){var o=n.getCellDisplayLocText(e.value,t);if(o){var r=G.getPropertyName(e.text,"")+", "+G.getPropertyName(t.title),s=new zt(r,o,"",i.translation,o);a.items.push(s)}}))})),this.addNewGroup(a)}},t.prototype.sortItems=function(){i.translation.sortByName&&this.itemValues.sort((function(e,t){return e.name?t.name?e.name.localeCompare(t.name):1:-1}))},t.prototype.getLocalizedProperties=function(e){for(var t=[],i=o.Serializer.getPropertiesByObj(e),n=0;n<i.length;n++){var r=i[n];if(!r.readOnly&&r.visible&&r.isSerializable&&r.isLocalizable){var a=["url","file"].indexOf(r.type)<0;this.canShowProperty(r,!!e[r.name],a)&&t.push(r)}}return t},t.prototype.getArrayProperties=function(e){for(var t=[],i=o.Serializer.getPropertiesByObj(e),n=0;n<i.length;n++){var r=i[n];if(!1!==r.isSerializable){var a=e[r.name];a&&Array.isArray(a)&&a.length>0&&t.push(r)}}return t},t.prototype.canShowProperty=function(e,t,o){void 0===o&&(o=!0);var i=Array.isArray(this.obj)?this.obj.length>0?this.obj[0]:void 0:this.obj;return!!i&&(this.translation?this.translation.canShowProperty(i,e,t,o):o)},t.prototype.createTranslationItem=function(e,t){var o,i=this.getDefaultValue(e,t),n=e[t.serializationProperty];if(!n)return null;if(!this.showAllStrings&&!i&&n.isEmpty)return null;var r=null===(o=this.translation)||void 0===o?void 0:o.getEditLocale();return r&&n.getLocaleText(r)?null:this.canShowProperty(t,n.isEmpty)?new zt(t.name,n,i,this.translation,e,t):null},t.prototype.getDefaultValue=function(e,t){if("title"==t.name&&t.isLocalizable&&t.serializationProperty){var o=e[t.serializationProperty];if(o&&!e.isPage&&!e.isPanel&&(o.onGetTextCallback||o.onRenderedHtmlCallback))return e.name}return""},t.prototype.isItemValueArray=function(e){return!!e&&Array.isArray(e)&&e.length>0&&!!e[0]&&!!e[0].getType&&!!e[0].setData&&!!e[0].setLocText},t.prototype.createGroups=function(e,o){for(var i=0;i<e.length;i++){var n=e[i];if(n&&n.getType){var r=n.name,a=r;if(!r){var s="["+i.toString()+"]";r=o.name+s,a=G.getPropertyName(o.name)+s}this.addNewGroup(new t(r,n,this.translation,a))}}},t.prototype.addNewGroup=function(e){e.setParent(this),e.hasItems&&this.itemValues.push(e)},t.prototype.createItemValuesLocale=function(){for(var e,t=null===(e=this.translation)||void 0===e?void 0:e.getEditLocale(),o=0;o<this.obj.length;o++){var i=this.obj[o],n=this.showAllStrings||!i.locText.isEmpty||isNaN(i.value);if(t&&i.locText.getLocaleText(t)&&(n=!1),n){var r=new zt(i.value,i.locText,i.value,this.translation,i);this.itemValues.push(r),this.addCustomPropertiesForItemValue(this.obj[o],r)}}},t.prototype.addCustomPropertiesForItemValue=function(e,t){for(var o=this.getLocalizedProperties(e),i=0;i<o.length;i++)if("text"!=o[i].name){var n=this.createTranslationItem(e,o[i]);n&&(n.customText=t.text+" ("+n.localizableName+")",n.name=e.value+"."+n.name,this.itemValues.push(n))}},J([(0,o.property)({defaultValue:!0})],t.prototype,"showHeader",void 0),t}(Gt),Wt=function(e){function t(t,o,r){void 0===o&&(o=null),void 0===r&&(r=!0);var a=e.call(this)||this;a.options=o,a.hasUI=r,a.chooseLanguageActions=[],a.options||(a.options=new n);var s=a;return a.exportToCSVFileUI=function(){s.exportToSCVFile(i.translation.exportFileName)},a.importFromCSVFileUI=function(e){e.files.length<1||(s.importFromCSVFile(e.files[0]),e.value="")},a.settingsSurveyValue=a.createSettingsSurvey(),a.surveyValue=t,a.setupToolbarItems(),a.updateChooseLanguageActions(),a}return K(t,e),t.prototype.getProcessedTranslationItemText=function(e,t,o,i){return this.options.getProcessedTranslationItemText(e,t,o,i)},t.prototype.getType=function(){return"translation"},t.prototype.getEditLocale=function(){return this.editLocale},t.prototype.setEditMode=function(e){this.editLocale=e,this.addLocale(e)},Object.defineProperty(t.prototype,"isEditMode",{get:function(){return!!this.editLocale},enumerable:!1,configurable:!0}),t.prototype.applyEditLocale=function(){this.isEditMode&&this.root&&this.root.applyEditLocale(this.editLocale)},t.prototype.makeObservable=function(e){this.onBaseObjCreatingCallback=e,this.fireOnObjCreating(this),this.root.makeObservable()},t.prototype.fireOnObjCreating=function(e){this.onBaseObjCreatingCallback&&this.onBaseObjCreatingCallback(e)},Object.defineProperty(t.prototype,"settingsSurvey",{get:function(){return this.settingsSurveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"localesQuestion",{get:function(){return this.settingsSurvey.getQuestionByName("locales")},enumerable:!1,configurable:!0}),t.prototype.deleteLocaleStrings=function(e){this.root||this.reset(),this.root&&(this.root.deleteLocaleStrings(e),this.removeLocale(e),this.reset())},t.prototype.createSettingsSurvey=function(){var e=this,t=this.getSettingsSurveyJSON();ot(t);var i=this.options.createSurvey(t,"translation_settings",this,(function(e){e.css=ze,e.css.root+=" st-properties",e.rootCss+=" st-properties"}));return i.onValueChanged.add((function(t,o){"locales"==o.name&&e.updateLocales()})),i.getQuestionByName("locales").lockedRowCount=1,i.onMatrixRowRemoving.add((function(t,o){e.removingLocale=o.question.value[o.rowIndex].name})),i.onMatrixRowRemoved.add((function(t,o){e.removingLocale&&e.deleteLocaleStrings(e.removingLocale)})),i.onGetQuestionTitleActions.add((function(t,o){o.titleActions=[e.addLanguageAction]})),i.onGetMatrixRowActions.add((function(t,i){if(Mt(i.question,i.actions,i.row),e.options.getHasMachineTranslation()&&_t(i.actions,"remove-row")&&Array.isArray(i.question.value)){var n=i.question,r=n.visibleRows.indexOf(i.row);if(r>=0&&r<n.value.length){var a=n.value[r].name;i.actions.splice(0,0,new o.Action({iconName:"icon-language",locTooltipName:"ed.translateUsigAI",location:"end",action:function(){return e.showTranslationEditor(a)}}))}}Dt(i.actions)})),i},t.prototype.calcIsChooseLanguageEnabled=function(){this.isChooseLanguageEnabled=this.chooseLanguageActions.filter((function(e){return e.visible})).length>0},t.prototype.refreshAddLanguageActionListModel=function(){var e=this.addLanguageAction.data;e&&e.refresh()},t.prototype.updateLocales=function(){var e=[""],t=this.getSelectedLocales();Array.isArray(t)||(t=[]),this.options.translationLocalesOrder=t,t.forEach((function(t){return e.push(t)})),this.locales=e,this.canMergeLocaleWithDefault=this.hasLocale(this.defaultLocale),this.localesQuestion.allowRowsDragAndDrop=e.length>2},t.prototype.getSettingsSurveyJSON=function(){return{elements:[{type:"matrixdynamic",name:"locales",title:G.getString("ed.translationLanguages"),confirmDelete:!0,titleLocation:"top",confirmDeleteText:G.getString("ed.translationDeleteLanguage"),columns:[{name:"isSelected",cellType:"boolean",renderAs:"checkbox",enableIf:"localeEnableIf()"},{name:"displayName",cellType:"expression",expression:"{row.displayName}"}],showHeader:!1,allowAddRows:!1,rowCount:0}]}},t.prototype.getSurveyLocales=function(){for(var e=new Array,t=o.surveyLocalization.supportedLocales,i=Array.isArray(t)&&t.length>0?t:o.surveyLocalization.getLocales(),n={},r=0;r<i.length;r++)this.addLocaleIntoChoices(i[r],e,n);for(i=this.getVisibleLocales(),r=0;r<i.length;r++)this.addLocaleIntoChoices(i[r],e,n);return[e,i]},t.prototype.importFromCSVFileDOM=function(){var e=this;document&&(this.inputFileElement||(this.inputFileElement=document.createElement("input"),this.inputFileElement.type="file",this.inputFileElement.style.display="none",this.inputFileElement.onchange=function(){e.importFromCSVFileUI(e.inputFileElement)}),this.inputFileElement.click())},t.prototype.updateSettingsSurveyLocales=function(){var e=this.getSurveyLocales(),t=(e[0],e[1]),o=[];t||(t=[]);for(var n=0;n<t.length;n++)this.localeInitialVisibleCallback&&!this.localeInitialVisibleCallback(t[n])||o.push(t[n]);var r=i.translation.maximumSelectedLocales;r>0&&o.length>r&&o.splice(r),this.setSelectedLocales(o)},t.prototype.resetStringsSurvey=function(){this.hasUI&&(this.stringsSurvey=this.createStringsSurvey(),this.stringsHeaderSurvey=this.createStringsHeaderSurvey(),this.updateReadOnly())},t.prototype.getSurveyStringsArea=function(){},t.prototype.getSurveyStringsHeaderArea=function(){},t.prototype.onSurveyStringsCreated=function(e){},t.prototype.onSurveyStringsHeaderCreated=function(e){},t.prototype.createStringsSurvey=function(){var e=this,t={autoGrowComment:!0,allowResizeComment:!1};ot(t,!1);var i=this.options.createSurvey(t,"translation_strings",this,(function(t){t.lazyRendering=!0,t.skeletonComponentName="sd-translation-line-skeleton",t.startLoadingFromJson(),t.css=Lt,t.addNewPage("page"),e.addTranslationGroupIntoStringsSurvey(t.pages[0],e.root),t.data=e.getStringsSurveyData(t),t.endLoadingFromJson(),e.onSurveyStringsCreated(t)}),this.getSurveyStringsArea()),n=function(e,t){var i=o.ItemValue.getItemByValue(e.rows,t);return i?i.translationData:null};return i.onMatrixCellCreated.add((function(t,i){if(i.cell.question instanceof o.QuestionCommentModel){var r=i.cell.question,a=n(i.question,i.row.name);e.setPlaceHolder(r,a,i.columnName);var s=!!a&&a.locString.getIsMultiple();r.acceptCarriageReturn=s,a&&(r.maxLength=a.maxLength),s||(r.rows=1)}})),i.onMatrixCellValueChanging.add((function(t,o){var i=n(o.question,o.row.name);i&&(o.value=e.getProcessedTranslationItemText(o.columnName,i.locString,o.value,i.context))})),i.onMatrixCellValueChanged.add((function(t,o){var i=n(o.question,o.row.name);if(i){i.setLocText(o.columnName,o.value);var r=o.columnName;o.row.cells.forEach((function(t){"default"!==r&&0!==t.column.name.indexOf(r+"-")||e.setPlaceHolder(t.question,i,t.column.name)}))}})),i.onUpdatePanelCssClasses.add((function(e,t){t.panel.__translationHasIndent&&(t.cssClasses.panel.content+=" st-panel-indent")})),i.currentPage=i.pages[0],i},t.prototype.setPlaceHolder=function(e,t,o){e.placeholder=t.getPlaceholder(o)},t.prototype.createStringsHeaderSurvey=function(){var e=this,t={};return ot(t,!1),this.options.createSurvey(t,"translation_strings_header",this,(function(t){t.css=Lt;var i=t.addNewPage("page"),n=o.Serializer.createClass("matrixdropdown");n.name="stringsHeader",n.titleLocation="hidden",e.addLocaleColumns(n),i.addQuestion(n,0),t.currentPage=t.pages[0],e.onSurveyStringsHeaderCreated(t)}),this.getSurveyStringsHeaderArea())},t.prototype.addTranslationGroupIntoStringsSurvey=function(e,t){for(var i=0;i<t.items.length;i++)if(!t.items[i].isGroup){var n=t.items[i],r=o.Serializer.createClass("matrixdropdown");r.cellType="comment",r.titleLocation="hidden",r.name=t.fullName+i,r.showHeader=!1,e.addQuestion(r),this.addLocaleColumns(r);var a=new o.ItemValue(n.name,n.text);a.translationData=n,r.rows.push(a)}for(i=0;i<t.items.length;i++)if(t.items[i].isGroup){n=t.items[i];var s=o.Serializer.createClass("panel");s.name=n.name,e.addElement(s),s.title=n.text,n.hasIndent&&(s.__translationHasIndent=!0),this.addTranslationGroupIntoStringsSurvey(s,n)}},t.prototype.addLocaleColumns=function(e){var t=this.getSelectedLocales();e.addColumn("default",this.getLocaleName("")).readOnly=this.isEditMode;for(var o=0;o<t.length;o++)e.addColumn(t[o],this.getLocaleName(t[o]))},t.prototype.getStringsSurveyData=function(e){for(var t={},o=e.getAllQuestions(),i=0;i<o.length;i++)t[o[i].name]=this.getStringsQuestionData(o[i]);return t},t.prototype.updateStringsSurveyData=function(){var e=this.stringsSurvey;e&&(e.data=this.getStringsSurveyData(e))},t.prototype.getStringsQuestionData=function(e){for(var t={},i=0;i<e.rows.length;i++){var n=e.rows[i],r=n.translationData.toJSON();o.Helpers.isValueEmpty(r)||(t[n.value]=r)}return t},t.prototype.updateHeaderStringsSurveyColumns=function(){if(this.stringsHeaderSurvey){var e=this.stringsHeaderSurvey.getQuestionByName("stringsHeader");e.columns=[],this.addLocaleColumns(e)}},t.prototype.updateStringsSurveyColumns=function(){if(this.stringsSurvey)for(var e=this.stringsSurvey.getAllQuestions(),t=0;t<e.length;t++){var o=e[t];o.beginUpdate(),o.columns=[],this.addLocaleColumns(o),o.endUpdate()}},t.prototype.addLocaleIntoChoices=function(e,t,i){e&&!i[e]&&(i[e]=!0,t.push(new o.ItemValue(e,this.getLocaleName(e))))},t.prototype.addLocaleIntoValue=function(e,t){var o=this.getVisibleLocales();if(o.indexOf(e)<0&&(o.push(e),this.setVisibleLocales(o)),t){var n=this.getSelectedLocales();n.indexOf(e)<0&&n.length<i.translation.maximumSelectedLocales&&(n.push(e),this.setSelectedLocales(n))}},t.prototype.isLocaleVisible=function(e,t){return t!==o.surveyLocalization.defaultLocale&&e.indexOf(t)<0},t.prototype.setupToolbarItems=function(){var e=this;this.chooseLanguageActions=this.getSurveyLocales()[0].map((function(t){return new o.Action({id:t.value,title:e.getLocaleName(t.value),data:t})})),this.addLanguageAction=(0,o.createDropdownActionModel)({id:"svc-translation-choose-language",iconName:"icon-add",enabled:new o.ComputedUpdater((function(){return e.isChooseLanguageEnabled&&!e.readOnly}))},{items:this.chooseLanguageActions,allowSelection:!1,cssClass:"svc-creator-popup",onSelectionChanged:function(t){e.addLocale(t.id)}})},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"canMergeLocaleWithDefault"===t&&(this.mergeLocaleWithDefaultText=this.getMergeLocaleWithDefaultText()),"locales"===t&&(this.updateHeaderStringsSurveyColumns(),this.updateStringsSurveyColumns())},t.prototype.getMergeLocaleWithDefaultText=function(){if(!this.canMergeLocaleWithDefault)return"";var e=this.getLocaleName(this.defaultLocale);return G.getString("ed.translationMergeLocaleWithDefault").format(e)},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},set:function(e){this.surveyValue=e,this.setVisibleLocales([]),this.reset()},enumerable:!1,configurable:!0}),t.prototype.reset=function(e){if(void 0===e&&(e=!0),e||!this.root){var t=this.filteredPage?this.filteredPage:this.survey,o=this.filteredPage?t.name:"survey";this.root=new Jt(o,t,this),this.root.setAsRoot(),this.root.reset(),this.resetLocales(),this.isEmpty=!this.root.hasItems,this.updateSettingsSurveyLocales(),this.updateLocales(),this.resetStringsSurvey(),this.updateChooseLanguageActions()}},t.prototype.updateReadOnly=function(){if(this.stringsSurvey){var e=this.readOnly?"display":"edit";this.stringsSurvey.mode=e,this.settingsSurvey.mode=e}},t.prototype.canShowProperty=function(e,t,o,i){void 0===i&&(i=!0);var n=i&&(!o||ee.isPropertyVisible(e,t,this.options));return this.translationStringVisibilityCallback?this.translationStringVisibilityCallback(e,t.name,n):n},Object.defineProperty(t.prototype,"defaultLocale",{get:function(){return o.surveyLocalization.defaultLocale},enumerable:!1,configurable:!0}),t.prototype.getLocaleName=function(e,t){return G.getLocaleName(e,this.defaultLocale,t)},t.prototype.removeLocale=function(e){if(this.hasLocale(e)){var t=this.locales.indexOf(e),o=this.locales;o.splice(t,1),this.locales=o,this.canMergeLocaleWithDefault=this.hasLocale(this.defaultLocale)}},t.prototype.hasLocale=function(e){return this.locales.indexOf(e)>-1},t.prototype.addLocale=function(e){this.hasLocale(e)||this.addLocaleIntoValue(e,!0),this.updateChooseLanguageActions()},t.prototype.updateChooseLanguageActions=function(){var e=this,t=this.chooseLanguageActions,o=this.getVisibleLocales();Array.isArray(t)&&t.forEach((function(t){return t.visible=e.isLocaleVisible(o,t.data.value)})),this.refreshAddLanguageActionListModel(),this.calcIsChooseLanguageEnabled()},t.prototype.resetLocales=function(){var e=[""];this.root.fillLocales(e);var t=this.options.translationLocalesOrder;if(Array.isArray(t)&&t.length>0){var o=function(e,t,o){var i=o.indexOf(e),n=o.indexOf(t);return i<0&&(i=100),n<0&&(n=100),i<n?-1:i>n?1:0};e.sort((function(i,n){var r=o(i,n,t);return 0===r?o(i,n,e):r}))}this.setSelectedAndVisibleLocales(e,this.getSelectedLocales(),!0)},t.prototype.getSelectedLocales=function(){return this.getSelectedLocalesCore(!0)},t.prototype.setSelectedLocales=function(e){this.setSelectedAndVisibleLocales(this.getVisibleLocales(),e,!0)},t.prototype.getVisibleLocales=function(){return this.getSelectedLocalesCore(!1)},t.prototype.setVisibleLocales=function(e){this.setSelectedAndVisibleLocales(e,this.getSelectedLocales(),!1)},t.prototype.getSelectedLocalesCore=function(e){if(!this.localesQuestion)return[];var t=this.localesQuestion.value;if(!Array.isArray(t)||0===t.length)return[];var o=[];return t.forEach((function(t){!t.name||e&&!t.isSelected||o.push(t.name)})),o},t.prototype.setSelectedAndVisibleLocales=function(e,t,o){var i=this;if(this.localesQuestion){Array.isArray(t)||(t=[]);var n=[];o&&t.forEach((function(t){e.indexOf(t)<0&&e.push(t)}));var r=this.defaultLocale;n.push({isSelected:!0,name:"",displayName:this.getLocaleName("")}),this.getEditLocale()?n.push({isSelected:!0,name:this.getEditLocale()}):e.forEach((function(e){e&&n.push({isSelected:e===r||t.indexOf(e)>-1,name:e,displayName:i.getLocaleName(e)})})),this.localesQuestion.value=n}},Object.defineProperty(t.prototype,"noStringsText",{get:function(){return G.getString("ed.translationNoStrings")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.options.isMobileView?Z("ed.translationsPlaceholderTitleMobile"):Z("ed.translationsPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.options.isMobileView?Z("ed.translationsPlaceholderDescriptionMobile"):Z("ed.translationsPlaceholderDescription")},enumerable:!1,configurable:!0}),t.prototype.exportToCSV=function(){this.root||this.reset();var e=[],o=[],n=this.locales;o.push("description ↓ - language →");for(var r=0;r<n.length;r++)o.push(n[r]?n[r]:"default");e.push(o);var a={};for(var s in this.fillItemsHash("",this.root,a),a){var l=[s],u=a[s];for(r=0;r<n.length;r++){var p=n[r],c=u.getTextForExport(p);c=c||0!=r?c:u.defaultValue,c=this.options.getTranslationExportedText(u.context,u.name,u.locString,p,c),l.push(c||0!=r?c:u.defaultValue)}e.push(l)}var d=i.translation.exportPrefix;return d||(d=""),d+(0,Ge.unparse)(e,{quoteChar:'"',escapeChar:'"',delimiter:t.csvDelimiter,header:!0,newline:t.newLineDelimiter,skipEmptyLines:!1,columns:null})},t.prototype.importFromNestedArray=function(e){var o=this,i=e.shift().slice(1);"default"===i[0]&&(i[0]="");var n=new t(this.survey,this.options,!1);n.showAllStrings=!0;var r={};this.fillItemsHash("",n.root,r),e.forEach((function(e){var t=e.shift().trim();if(t){var n=r[t];n&&o.updateItemWithStrings(t,n,e,i)}})),this.reset(),this.importFinishedCallback&&this.importFinishedCallback()},t.prototype.exportToSCVFile=function(e){if(window){var t=this.exportToCSV(),o=new Blob([t],{type:"text/csv"});if(window.navigator.msSaveOrOpenBlob)window.navigator.msSaveBlob(o,e);else{var i=window.document.createElement("a");i.href=window.URL.createObjectURL(o),i.download=e,document.body.appendChild(i),i.click(),document.body.removeChild(i)}}},t.prototype.importFromCSVFile=function(e){var t=this;(0,Ge.parse)(e,{complete:function(e,o){t.importFromNestedArray(e.data)}})},t.prototype.mergeLocaleWithDefault=function(){this.reset(!1),this.hasLocale(this.defaultLocale)&&(this.root.mergeLocaleWithDefault(this.defaultLocale),this.setVisibleLocales([]),this.setSelectedLocales([]),this.reset())},t.prototype.createTranslationEditor=function(e){var t=this,o=new Yt(this.survey,e,this.options);return o.onApply=function(){t.reset()},o},t.prototype.showTranslationEditor=function(e){this.createTranslationEditor(e).showDialog()},t.prototype.translateItemAfterRender=function(e,t,o){if(this.translateItemAfterRenderCallback){if(Array.isArray(t))for(var i=0;i<t.length;i++)if("TEXTAREA"==t[i].tagName){t=t[i];break}this.translateItemAfterRenderCallback(e,t,o)}},t.prototype.updateItemWithStrings=function(e,t,o,i){for(var n=0;n<o.length&&n<i.length;n++){var r=o[n].trim();r&&(this.importItemCallback&&(r=this.importItemCallback(e,i[n],r)),r&&(t.values(i[n]).text=r))}},t.prototype.fillItemsHash=function(e,t,o){var i=this,n=e?e+"."+t.name:t.name;t.locItems.forEach((function(e){o[n+"."+e.name]=e})),t.groups.forEach((function(e){return i.fillItemsHash(n,e,o)}))},t.prototype.dispose=function(){this.isEmpty=!0,this.stringsSurvey&&(this.stringsSurvey.dispose(),this.stringsSurvey=void 0),this.stringsHeaderSurvey&&(this.stringsHeaderSurvey.dispose(),this.stringsHeaderSurvey=void 0),this.settingsSurveyValue&&(this.settingsSurveyValue.dispose(),this.settingsSurveyValue=void 0),this.importFinishedCallback=void 0,this.availableTranlationsChangedCallback=void 0,this.tranlationChangedCallback=void 0,e.prototype.dispose.call(this)},t.csvDelimiter=",",t.newLineDelimiter="\n",J([(0,o.propertyArray)()],t.prototype,"locales",void 0),J([(0,o.property)()],t.prototype,"canMergeLocaleWithDefault",void 0),J([(0,o.property)()],t.prototype,"mergeLocaleWithDefaultText",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.updateReadOnly()}})],t.prototype,"readOnly",void 0),J([(0,o.property)()],t.prototype,"root",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.reset()}})],t.prototype,"showAllStrings",void 0),J([(0,o.property)({onSet:function(e,t){t.reset()}})],t.prototype,"filteredPage",void 0),J([(0,o.property)()],t.prototype,"stringsSurvey",void 0),J([(0,o.property)()],t.prototype,"stringsHeaderSurvey",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isEmpty",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isChooseLanguageEnabled",void 0),t}(o.Base),Kt=function(e){function t(t,o,i){var n=e.call(this,t,o,!0)||this;return n.surveyStringsHeaderCreatedCallback=i,n}return K(t,e),t.prototype.getSurveyStringsArea=function(){return"translation-tab:table-popup-editor"},t.prototype.getSurveyStringsHeaderArea=function(){return"translation-tab:table-header-popup-editor"},t.prototype.onSurveyStringsHeaderCreated=function(e){this.surveyStringsHeaderCreatedCallback(e)},t}(Wt),Yt=function(){function e(e,t,o){var i=this;this.fromLocales=[],this.survey=e,this.options=o,this.locale=t,this.translationValue=new Kt(this.survey,this.options,(function(e){i.setupNavigationButtons(e)})),this.translation.setEditMode(this.locale),this.translation.reset(),this.fillFromLocales(),this.updateFromLocaleAction(),this.updateMatricesColumns()}return Object.defineProperty(e.prototype,"translation",{get:function(){return this.translationValue},enumerable:!1,configurable:!0}),e.prototype.showDialog=function(){var e=this,t=G.getString("ed.translationDialogTitle")+" ("+this.translation.getLocaleName(this.locale)+")";if(0===this.translation.stringsSurvey.getAllQuestions(!0).length){var i=new o.LocalizableString(this.translation.stringsSurvey);i.text=G.getString("ed.translationNoStrings");var n=o.settings.showDialog({componentName:"sv-string-viewer",data:{locStr:i,locString:i,model:i},onApply:function(){return!0},cssClass:"svc-creator-popup",title:t,displayMode:"popup"},this.options.rootElement).footerToolbar.actions;return n.splice(1,n.length-1),void(n[0].title="OK")}o.settings.showDialog({componentName:"svc-tab-translation",data:{model:this.translation},onApply:function(){return e.apply(),!0},onHide:function(){e.dispose()},cssClass:"sv-property-editor st-translation-dialog svc-creator-popup",title:t,displayMode:this.options.isMobileView?"overlay":"popup"},this.options.rootElement).locale=G.currentLocale},e.prototype.doMachineTranslation=function(){var e=this,t=this.fromLocale||this.translation.defaultLocale;t||(t="en");var o=this.createStringsToTranslate(),i=[];o.forEach((function(t){i.push(e.getTextToTranslate(t))})),this.options.doMachineTranslation(t,this.locale,i,(function(t){if(Array.isArray(t)){for(var i=0;i<Math.min(o.length,t.length);i++)o[i].values(e.locale).text=t[i];e.translation.updateStringsSurveyData()}}))},e.prototype.apply=function(){this.translation.applyEditLocale(),this.onApply&&this.onApply()},e.prototype.cancel=function(){this.dispose()},e.prototype.dispose=function(){this.translationValue.dispose()},e.prototype.setFromLocale=function(e){this.fromLocale!==e&&(this.fromLocale=e,this.updateMatricesColumns())},e.prototype.updateMatricesColumns=function(){var e=this;this.translation.stringsHeaderSurvey.getAllQuestions().forEach((function(t){e.updateMatrixColumns(t),e.updateHeaderMatrixColumns(t)}));for(var t=this.translation.stringsSurvey.getAllQuestions(),o=0;o<t.length;o++)this.updateMatrixColumns(t[o])},e.prototype.updateHeaderMatrixColumns=function(e){var t=e.columns;t[0].title=this.translation.getLocaleName(""),t.length>2?(t[1].title=this.getHeaderTitle("translationSource",t[1].name),t[2].title=this.getHeaderTitle("translationTarget",t[2].name)):t[1].title=this.getHeaderTitle("translationTarget",t[1].name)},e.prototype.updateMatrixColumns=function(e){3===e.columns.length&&e.columns.splice(1,1);var t=this.fromLocale;if(t){var i=new o.MatrixDropdownColumn(t,this.translation.getLocaleName(t));i.readOnly=!0,e.columns.splice(1,0,i)}},e.prototype.getHeaderTitle=function(e,t){return G.getString("ed."+e)+this.translation.getLocaleName(t)},e.prototype.fillFromLocales=function(){var e=this;this.fromLocales=[],this.createStringsToTranslate().forEach((function(t){t.fillLocales(e.fromLocales)}))},e.prototype.setupNavigationButtons=function(e){var t=this,i=new Qt;e.navigationBarValue=i,e.findLayoutElement("buttons-navigation").data=i,i.locOwner=e,i.cssClasses=e.css.actionBar,i.containerCss=e.css.footer,e.addNavigationItem(this.createLocaleFromAction());var n="svc-action-bar-item--right sv-action-bar-item--secondary";this.options.getHasMachineTranslation()&&e.addNavigationItem(new o.Action({id:"svc-translation-machine",iconName:"icon-language",css:n,locTitleName:"ed.translateUsigAI",component:"sv-action-bar-item",action:function(){t.doMachineTranslation()}}));var r=Xt((function(){t.translation.importFromCSVFileDOM()}),!1,!0);r.css=n;var a=$t((function(){t.translation.exportToCSVFileUI()}),!0);a.css=n,e.addNavigationItem(r),e.addNavigationItem(a),e.showNavigationButtons="top"},e.prototype.createStringsToTranslate=function(){var e=this,t=new Array;return this.fromLocale,this.translation.root.allLocItems.forEach((function(o){e.getTextToTranslate(o)&&t.push(o)})),t},e.prototype.getTextToTranslate=function(e){var t=this.fromLocale||"",o=e.getLocText(t);return o||t||(o=e.getDefaultLocaleText(!0)),o},e.prototype.createLocaleFromAction=function(){var e=this,t=this.getActionTranslateFromText(""),i=(0,o.createPopupModelWithListModel)({items:[{id:null,title:t}],onSelectionChanged:function(t){var o=t.id||"";e.setFromLocale(o),n.title=e.getActionTranslateFromText(o)},allowSelection:!0},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var o=[{id:null,title:t}];e.fromLocales.forEach((function(t){o.push({id:t,title:e.getActionTranslateFromText(t)})})),n.popupModel.contentComponentData.model.setItems(o)}}),n=new o.Action({id:"svc-translation-fromlocale",component:"svc-translate-from-action",css:"st-translation-machine-from",location:"start",title:t,iconSize:"auto",innerCss:"st-translation-machine-from__btn",data:{additionalTitleCss:"st-translation-machine-from__title",additionalTitle:G.getString("ed.translateUsigAIFrom")},popupModel:i,action:function(){i.toggleVisibility()}});return n},e.prototype.updateFromLocaleAction=function(){var e=this.translation.stringsHeaderSurvey.findLayoutElement("buttons-navigation").data.getActionById("svc-translation-fromlocale");e&&(e.enabled=this.fromLocales.length>0,e.iconName=e.enabled?"icon-chevron_16x16":void 0,e.data.containerCss=(new o.CssClassBuilder).append("st-translation-machine-from__container").append("st-translation-machine-from__container--disabled",!e.enabled).toString())},e.prototype.getActionTranslateFromText=function(e){return e=e||"",this.translation.getLocaleName(e)},e}();function Xt(e,t,i){return void 0===i&&(i=!1),new o.Action({id:"svc-translation-import",iconName:"icon-load",locTitleName:"ed.translationImportFromSCVButton",locTooltipName:"ed.translationImportFromSCVButton",mode:i?"large":"small",component:"sv-action-bar-item",needSeparator:t,action:e})}function $t(e,t){return void 0===t&&(t=!1),new o.Action({id:"svc-translation-export",iconName:"icon-download",locTitleName:"ed.translationExportToSCVButton",locTooltipName:"ed.translationExportToSCVButton",mode:t?"large":"small",component:"sv-action-bar-item",action:e})}var eo=function(){function e(e){this.creator=e,e.addPluginTab("translation",this),this.sidebarTab=this.creator.sidebar.addPage("translation"),this.sidebarTab.caption=G.getString("ed.translationPropertyGridTitle"),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.activate=function(){var e=this;this.model=new Wt(this.creator.survey,this.creator),this.model.settingsSurvey.locale=this.creator.locale,this.model.readOnly=this.creator.readOnly,this.model.translationStringVisibilityCallback=function(t,o,i){var n={obj:t,propertyName:o,visible:i};return!e.creator.onTranslationStringVisibility.isEmpty&&e.creator.onTranslationStringVisibility.fire(e.creator,n),n.visible},this.model.localeInitialVisibleCallback=function(t){var o={locale:t,isSelected:!0};return e.creator.onTranslationLocaleInitiallySelected.fire(e.creator,o),o.isSelected},this.model.importItemCallback=function(t,o,i){var n={locale:o,name:t,text:i};return e.creator.onTranslationImportItem.fire(e.creator,n),n.text},this.model.importFinishedCallback=function(){e.creator.onTranslationImported.fire(e.creator,{})},this.sidebarTab.componentData=this.model.settingsSurvey,this.sidebarTab.componentName="survey-widget",this.creator.sidebar.activePage=this.sidebarTab.id,this.mergeLocaleWithDefaultAction.title=this.createMergeLocaleWithDefaultActionTitleUpdater(),this.mergeLocaleWithDefaultAction.tooltip=this.createMergeLocaleWithDefaultActionTitleUpdater(),this.mergeLocaleWithDefaultAction.visible=this.model.canMergeLocaleWithDefault,this.filterPageAction.visible=this.creator.survey.pageCount>1,this.updateFilterPageAction(!0),this.filterStringsAction.visible=!0,this.updateFilterStrigsAction(!0),this.importCsvAction.visible=!0,this.exportCsvAction.visible=!0,this.filterPageAction.data.setItems([{id:null,title:this.showAllPagesText}].concat(this.creator.survey.pages.map((function(t){return{id:t.name,title:e.getPageDisplayText(t)}}))),!1),this.model.onPropertyChanged.add((function(t,o){"filteredPage"===o.name&&e.updateFilterPageAction(),"showAllStrings"===o.name&&e.updateFilterStrigsAction(),"canMergeLocaleWithDefault"===o.name&&(e.mergeLocaleWithDefaultAction.visible=e.model.canMergeLocaleWithDefault),"mergeLocaleWithDefaultText"===o.name&&(e.mergeLocaleWithDefaultAction.title=e.model.mergeLocaleWithDefaultText,e.mergeLocaleWithDefaultAction.tooltip=e.model.mergeLocaleWithDefaultText)})),this.model.reset()},e.prototype.update=function(){this.model&&(this.model.survey=this.creator.survey,this.model.filteredPage=null,this.updateFilterPageAction(!0))},e.prototype.deactivate=function(){return this.model&&this.model.dispose(),this.model=void 0,this.sidebarTab.visible=!1,this.filterStringsAction.visible=!1,this.filterPageAction.visible=!1,this.mergeLocaleWithDefaultAction.title=void 0,this.mergeLocaleWithDefaultAction.tooltip=void 0,this.mergeLocaleWithDefaultAction.visible=!1,this.importCsvAction.visible=!1,this.exportCsvAction.visible=!1,!0},e.prototype.createMergeLocaleWithDefaultActionTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;return t||(t="en"),G.getString("ed.translationMergeLocaleWithDefault").format(o.surveyLocalization.defaultLocale)}))},Object.defineProperty(e.prototype,"selectLanguageOptionsCaption",{get:function(){return G.getString("ed.translationAddLanguage")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllStringsText",{get:function(){return G.getString("ed.translationShowAllStrings")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showUsedStringsOnlyText",{get:function(){return G.getString("ed.translationShowUsedStringsOnly")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllPagesText",{get:function(){return G.getString("ed.translationShowAllPages")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"exportToCSVText",{get:function(){return G.getString("ed.translationExportToSCVButton")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"importFromCSVText",{get:function(){return G.getString("ed.translationImportFromSCVButton")},enumerable:!1,configurable:!0}),e.prototype.createActions=function(){var e=this,t=[];return this.createFilterPageAction(),t.push(this.filterPageAction),this.createFilterStringsAction(),t.push(this.filterStringsAction),this.mergeLocaleWithDefaultAction=new o.Action({id:"svd-translation-merge_locale_withdefault",visible:!1,component:"sv-action-bar-item",mode:"small",needSeparator:!0,action:function(){e.model.mergeLocaleWithDefault()}}),t.push(this.mergeLocaleWithDefaultAction),this.importCsvAction=Xt((function(){e.model.importFromCSVFileDOM()}),!0),this.importCsvAction.enabled=new o.ComputedUpdater((function(){return!e.creator.readOnly})),this.importCsvAction.visible=!1,t.push(this.importCsvAction),this.exportCsvAction=$t((function(){e.model.exportToCSVFileUI()})),this.exportCsvAction.visible=!1,t.push(this.exportCsvAction),t},e.prototype.createFilterPageAction=function(){var e=this;this.filterPageAction=(0,o.createDropdownActionModel)({id:"svc-translation-filter-page",title:this.getFilterPageActionTitle(),visible:!1,mode:"small"},{items:[{id:null,title:this.showAllPagesText}],allowSelection:!0,onSelectionChanged:function(t){e.model.filteredPage=t.id?e.creator.survey.getPageByName(t.id):null},horizontalPosition:"center",cssClass:"svc-creator-popup"})},e.prototype.createFilterStringsAction=function(){var e=this;this.filterStringsAction=(0,o.createDropdownActionModel)({id:"svc-translation-show-all-strings",title:this.getFilterStringsActionTitle(),visible:!1,mode:"small"},{items:[{id:"show-all-strings",locTitleName:"ed.translationShowAllStrings"},{id:"show-used-strings-only",locTitleName:"ed.translationShowUsedStringsOnly"}],allowSelection:!0,onSelectionChanged:function(t){e.model.showAllStrings="show-all-strings"===t.id},horizontalPosition:"center",cssClass:"svc-creator-popup"})},e.prototype.updateFilterStrigsAction=function(e){void 0===e&&(e=!1);var t=this.getFilterStringsActionTitle();if(this.filterStringsAction.title=t,e){this.filterStringsAction.needSeparator=this.filterPageAction.visible;var o=this.filterStringsAction.data;o.selectedItem=o.actions.filter((function(e){return e.title===t}))[0]}},e.prototype.updateFilterPageAction=function(e){if(void 0===e&&(e=!1),this.filterPageAction.title=this.getFilterPageActionTitle(),e){var t=this.filterPageAction.data,o=this.model.filteredPage?this.model.filteredPage.name:null;t.selectedItem=t.actions.filter((function(e){return e.id===o}))[0]}},e.prototype.getFilterPageActionTitle=function(){return this.model&&this.model.filteredPage&&this.getPageDisplayText(this.model.filteredPage)||this.showAllPagesText},e.prototype.getFilterStringsActionTitle=function(){return this.model&&!this.model.showAllStrings?this.showUsedStringsOnlyText:this.showAllStringsText},e.prototype.getPageDisplayText=function(e){return this.creator.getObjectDisplayName(e,"translation-tab","survey-translation",e.title)},e}(),to={root:"",container:"",header:"",body:"sl-body",bodyEmpty:"",footer:"",title:"",description:"",logo:"",logoImage:"",headerText:"",navigationButton:"",completedPage:"",navigation:{complete:"",prev:"",next:"",start:"",preview:"",edit:""},panel:{enter:"sl-element-wrapper--enter",leave:"sl-element-wrapper--leave",title:"",titleExpandable:"",titleOnExpand:"",titleOnError:"",description:"",container:"sl-panel",content:"",icon:"",iconExpanded:"",footer:"sl-panel__footer",requiredText:"sl-panel__required-text"},paneldynamic:{mainRoot:"",root:"",navigation:"",title:"",button:"",buttonRemove:"",buttonAdd:"svc-logic-operator sl-paneldynamic__add-btn",progressTop:"",progressBottom:"",buttonPrev:"",buttonNext:"",progressContainer:"",progress:"",progressBar:"",progressText:"",separator:"sv-hidden",panelWrapper:"sl-panel-wrapper",content:"sl-paneldynamic__content",panelsContainer:"",panelWrapperList:"sl-panel-wrapper--list",panelWrapperInRow:"sl-panel-wrapper--in-row",panelWrapperEnter:"sl-panel-wrapper--enter",panelWrapperLeave:"sl-panel-wrapper--leave"},progress:"",progressBar:"",progressText:"",progressTextInBar:"",page:{root:"",title:"",description:""},pageTitle:"",pageDescription:"",row:"sl-row",rowEnter:"sl-row--enter",rowLeave:"sl-row--leave",rowDelayedEnter:"sl-row--delayed-enter",rowMultiple:"sl-row--multiple",question:{mainRoot:"sl-question",flowRoot:"",asCell:"",header:"sl-question__header",headerLeft:"sl-question__header--left",headerTop:"",headerBottom:"",content:"",contentLeft:"",titleLeftRoot:"",titleOnAnswer:"",titleOnError:"",enter:"sl-element-wrapper--enter",leave:"sl-element-wrapper--leave",title:"sl-question__title",requiredText:"sl-question__required-text",number:"",description:"",descriptionUnderInput:"",comment:"",required:"",titleRequired:"",indent:0,footer:"",formGroup:"",hasError:"",disabled:""},image:{root:""},error:{root:"",icon:"",item:"",locationTop:"",locationBottom:""},checkbox:{root:"",item:"",itemSelectAll:"",itemNone:"",itemDisabled:"",itemChecked:"",itemHover:"",itemInline:"",label:"",labelChecked:"",itemControl:"",itemDecorator:"",controlLabel:"",materialDecorator:"",other:"",column:""},radiogroup:{root:"",item:"",itemInline:"",label:"",labelChecked:"",itemDisabled:"",itemChecked:"",itemHover:"",itemControl:"",itemDecorator:"",controlLabel:"",materialDecorator:"",other:"",clearButton:"",column:""},boolean:{mainRoot:"",root:"",item:"",control:"",itemChecked:"",itemIndeterminate:"",itemDisabled:"",label:"",switch:"",disabledLabel:"",itemDecorator:"",materialDecorator:"",sliderText:"",slider:""},text:{root:"",small:"",controlDisabled:"",onError:""},multipletext:{root:"",item:"",itemTitle:"",row:"",cell:""},dropdown:{root:"",popup:"svc-creator-popup",small:"",control:"sl-dropdown",selectWrapper:"",other:"",onError:"",label:"",item:"",itemDisabled:"",itemChecked:"",itemHover:"",itemControl:"",itemDecorator:"",controlDisabled:"",controlLabel:"",materialDecorator:"",controlValue:"sl-dropdown__value",chevronButton:"",chevronButtonSvg:"",chevronButtonIconId:""},imagepicker:{root:"",item:"",itemInline:"",itemChecked:"",itemDisabled:"",itemHover:"",label:"",itemControl:"",image:"",itemText:"",clearButton:"",other:""},matrix:{mainRoot:"",tableWrapper:"",root:"",row:"",rowAdditional:"",rowError:"",cell:"",headerCell:"",label:"",itemValue:"",itemChecked:"",itemDisabled:"",itemHover:"",materialDecorator:"",itemDecorator:"",cellText:"",cellTextSelected:"",cellTextDisabled:""},matrixdropdown:{tableWrapper:"",mainRoot:"",root:"",row:"",rowAdditional:"",cell:"",headerCell:""},matrixdynamic:{tableWrapper:"",mainRoot:"sl-question st-row__question st-scrollable",root:"sl-table st-matrixdynamic",noHeader:"",row:"sl-table__row",rowAdditional:"sl-table__row--additional",cell:"sl-table__cell",headerCell:"sl-table__cell st-table__cell--header",button:"sl-btn",detailRow:"sl-table__row sl-table__row--detail st-table__row--detail",rowEnter:"sl-table__row--enter",rowLeave:"sl-table__row--leave",detailButton:"sl-table__cell--detail-button",detailButtonExpanded:"sl-table__cell--detail-button--expanded",detailIcon:"sl-detail-panel__icon",detailIconExpanded:"sl-detail-panel__icon--expanded",detailPanelCell:"sl-table__cell--detail-panel",actionsCell:"sl-table__cell sl-table__cell--actions st-table__cell--actions",buttonAdd:"sl-matrixdynamic__add-btn",buttonRemove:"sl-matrixdynamic__remove-btn",iconAdd:"",iconRemove:""},rating:{root:"",item:"",itemHover:"",selected:"",minText:"",itemText:"",maxText:"",itemDisabled:""},comment:{mainRoot:"",root:"spg-input spg-comment sl-comment",small:""},expression:"",file:{root:"",other:"",placeholderInput:"",preview:"",fileSign:"",fileSignBottom:"",fileDecorator:"",fileInput:"",noFileChosen:"",chooseFile:"",disabled:"",removeButton:"",removeButtonBottom:"",removeFile:"",removeFileSvg:"",wrapper:""},signaturepad:{root:"",small:"",controls:"",placeholder:"",clearButton:""},saveData:{root:"",saving:"",error:"",success:"",saveAgainButton:""},window:{root:"",body:"",header:{root:"",title:"",button:"",buttonExpanded:"",buttonCollapsed:""}},list:{root:"sv-list__container sl-list",itemBody:"sv-list__item-body sd-list__item-body sl-list__item-body"},embeddedsurvey:{mainRoot:"sl-embedded-survey"},actionBar:o.defaultActionBarCss},oo=function(){this.conjunction="and",this.operator=i.logic.defaultOperators.default},io=function(e){function t(t){var o=e.call(this)||this;return o.survey=t,o}return K(t,e),t.prototype.getOperatorText=function(){var e=this.operator;return"equal"==e?"=":"notequal"==e?"<>":"greater"==e?">":"less"==e?"<":"greaterorequal"==e?">=":"lessorequal"==e?"<=":e},t.prototype.getValueText=function(){var e=this.value;if(!e)return e;if(!Array.isArray(e))return this.valToText(e);for(var t="[",o=0;o<e.length;o++)t+=this.valToText(e[o]),o<e.length-1&&(t+=", ");return t+"]"},Object.defineProperty(t.prototype,"isValueRequired",{get:function(){return"empty"!==this.operator&&"notempty"!==this.operator},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isReady",{get:function(){return!(!this.questionName||this.isValueRequired&&o.Helpers.isValueEmpty(this.value))},enumerable:!1,configurable:!0}),t.prototype.toExpression=function(){var e=E(this.getQuestionValueByName())+" "+this.getOperatorText();return this.isValueRequired&&(e+=" "+this.getValueText()),e},t.prototype.getQuestionValueByName=function(){var e=this.survey.getQuestionByName(this.questionName);return e&&e.name!=e.getValueName()&&this.questionName!=e.getValueName()?this.questionName.replace(e.name,e.getValueName()):this.questionName},t.prototype.valToText=function(e){return"true"==e||"false"==e||this.isNumeric(e)?e:"["==e[0]?e.replace(/(?!^)(['])(?!$)/g,"\\$1"):(this.isQuote(e[0])||(e="'"+e),this.isQuote(e[e.length-1])||(e+="'"),e.replace(/(?!^)(['"])(?!$)/g,"\\$1"))},t.prototype.isNumeric=function(e){return!("string"==typeof e&&e.length>1&&"0"===e[0]&&"x"!==e[1]||isNaN(e))},t.prototype.isQuote=function(e){return"'"==e||'"'==e},t}(oo),no=function(){function e(e){void 0===e&&(e=null),this.hasValue=e}return e.prototype.build=function(e){return e&&(t=(new o.ConditionsParser).parseExpression(e))?this.buildEditorItems(t):[];var t},e.prototype.buildEditorItems=function(e){var t=[];return this.buildEditorItemsCore(e,t,"")||(t=[]),t},e.prototype.buildEditorItemsCore=function(e,t,o){if("unary"==e.getType())return this.buildEditorItemsAddUnaryOperand(e,t);if("binary"!==e.getType())return!1;var i=e;return!(i.isArithmetic&&!i.isConjunction)&&(i.isConjunction?this.buildEditorItemsAddConjunction(i,t,o):this.buildEditorItemsAddBinaryOperand(i,t))},e.prototype.buildEditorItemsAddConjunction=function(e,t,o){var i=e.conjunction;if("or"==i&&o&&o!=i)return!1;if(!this.buildEditorItemsCore(e.leftOperand,t,i))return!1;var n=t.length;return!!this.buildEditorItemsCore(e.rightOperand,t,i)&&(t[n].conjunction=e.conjunction,!0)},e.prototype.buildEditorItemsAddBinaryOperand=function(e,t){var o=this.getOperandByType(e,"variable"),i=this.getArrayValueFromOperand(e),n=i?null:this.getOperandByType(e,"const");if(!o||!n&&!i&&this.canShowValueByOperator(e.operator))return!1;if(!this.isVariableInSurvey(o.variable))return!1;var r=new oo;return r.questionName=o.variable,r.operator=e.leftOperand!==o?this.getOppositeOperator(e.operator):e.operator,i&&(r.value=i),n&&(r.value=n.correctValue),t.push(r),!0},e.prototype.isVariableInSurvey=function(e){return!this.hasValue||this.hasValue(e)},e.prototype.getArrayValueFromOperand=function(e){var t=this.getOperandByType(e,"array");if(!t||!t.values)return null;var o=t.values;if(!Array.isArray(o)||0==o.length)return null;for(var i=[],n=0;n<o.length;n++){var r=o[n];if(r){if("const"!=r.getType())return null;i.push(r.correctValue)}}return 0==i.length?null:i},e.prototype.buildEditorItemsAddUnaryOperand=function(e,t){var o=e.operator;if("empty"!==o&&"notempty"!=o)return!1;var i=e.expression;if(null==i||"variable"!=i.getType())return!1;var n=i.variable;if(!this.isVariableInSurvey(n))return!1;var r=new oo;return r.questionName=n,r.operator=o,t.push(r),!0},e.prototype.getOppositeOperator=function(e){return"less"==e?"greater":"greater"==e?"less":"lessorequal"==e?"greaterorequal":"greaterorequal"==e?"lessorequal":e},e.prototype.getOperandByType=function(e,t){return e.rightOperand?e.leftOperand.getType()!==t&&e.rightOperand.getType()!==t||e.leftOperand.getType()==t&&e.rightOperand.getType()==t?null:e.leftOperand.getType()==t?e.leftOperand:e.rightOperand:null},e.prototype.canShowValueByOperator=function(e){return"empty"!=e&&"notempty"!=e},e}();o.FunctionFactory.Instance.register("questionValueVisibleIf",(function(e){return 2===e.length&&!(!e[0]||!e[1])&&"empty"!==e[1]&&"notempty"!==e[1]}));var ro=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n="");var r=e.call(this,i)||this;return r.propertyName=n,r.addConditionQuestionsHash={},r.isModalValue=!0,r.isSettingPanelValues=!1,r.calculatedValueQuestion=null,r.surveyValue=t,r.objectValue=o,r.panelValue=r.editSurvey.getQuestionByName("panel"),r.textEditorValue=r.editSurvey.getQuestionByName("textEditor"),r.options.maxLogicItemsInCondition&&(r.panel.maxPanelCount=r.options.maxLogicItemsInCondition),r.allConditionQuestions=r.createAllConditionQuestions(),r.editSurvey.onValueChanged.add((function(e,t){r.onValueChanged(t)})),r.editSurvey.onDynamicPanelAdded.add((function(e,t){r.onPanelAdded()})),r.editSurvey.onDynamicPanelRemoved.add((function(e,t){0==t.question.panelCount&&t.question.addPanel(),r.panel.panelCount>0&&(r.panel.panels[0].getQuestionByName("questionName").titleLocation="left")})),r.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){r.onPanelValueChanged(t.panel,t.name)})),r.editSurvey.css=to,r.editSurvey.onUpdateQuestionCssClasses.add((function(e,t){r.onUpdateQuestionCssClasses(t)})),r.text=r.object&&r.propertyName?r.object[r.propertyName]:"",r.updatePlaceholderVisibileIf(),r}return K(t,e),t.canParseExpression=function(e){return!e||!!(new o.ConditionsParser).parseExpression(e)},t.canBuildExpression=function(e){return!e||!!t.canParseExpression(e)&&(new no).build(e).length>0},t.isOperatorEnabled=function(e,o){if(!e)return!0;if(!o||0==o.length)return!0;for(var i=[],n=[],r=0;r<o.length;r++){var a=o[r];"!"==a[0]?n.push(a.substring(1)):i.push(a)}return t.isClassContains(e,i,n)},t.isClassContains=function(e,t,i){for(var n=o.Serializer.findClass(e);n;){if(t.indexOf(n.name)>-1)return!0;if(i.indexOf(n.name)>-1)return!1;n=n.parentName?o.Serializer.findClass(n.parentName):null}return 0==t.length},Object.defineProperty(t.prototype,"title",{get:function(){return this.panel.title},set:function(e){this.panel.title=e,this.textEditor.title=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isModal",{get:function(){return this.isModalValue},set:function(e){e!==this.isModalValue&&(this.isModalValue=e,this.updatePlaceholderVisibileIf())},enumerable:!1,configurable:!0}),t.prototype.updatePlaceholderVisibileIf=function(){if(this.panel){var e="";this.isModal&&!this.options.animationEnabled&&(e="{panel.questionName} empty and {panelIndex} == 0"),this.panel.template.getQuestionByName("placeholder").visibleIf=e}},t.prototype.getSurveyJSON=function(){return{elements:[{type:"paneldynamic",titleLocation:"hidden",name:"panel",panelRemoveButtonLocation:"right",panelAddText:G.getString("pe.addCondition"),minPanelCount:1,maxPanelCount:1,startWithNewLine:!1,templateElements:[{name:"conjunction",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,titleLocation:"hidden",showOptionsCaption:!1,visibleIf:"{panelIndex} > 0",choices:[{value:"and",text:G.getString("pe.and")},{value:"or",text:G.getString("pe.or")}]},{name:"questionName",type:"dropdown",renderAs:"logicoperator",title:G.getString("pe.if"),titleLocation:"left",showOptionsCaption:!1,startWithNewLine:!1,isRequired:!0},{name:"operator",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,titleLocation:"hidden",startWithNewLine:!1,showOptionsCaption:!1,isRequired:!0,enableIf:"{panel.questionName} notempty"},{name:"removeAction",type:"linkvalue",titleLocation:"hidden",showOptionsCaption:!1,visible:!1,startWithNewLine:!1,showValueInLink:!1,allowClear:!1,showClear:!1,iconName:"icon-delete_24x24"},{name:"questionValue",type:"text",visible:!1},{name:"placeholder",type:"html",visible:!1,html:"<div class='svc-logic-placeholder'><span class=\"svc-logic-placeholder__text\">".concat(G.getString("pe.emptyLogicPopupMessage"),"<span></div>")}]},{type:"comment",titleLocation:"hidden",name:"textEditor",textUpdateMode:"onTyping",placeholder:G.getString("pe.emptyExpressionPlaceHolder"),visible:!1}]}},t.prototype.getSurveyCreationReason=function(){return"condition-builder"},Object.defineProperty(t.prototype,"text",{get:function(){return this.getText()},set:function(e){this.isModal||t.canBuildExpression(e)?(this.textEditor.value=e,this.showBuilder(e)):(this.panel.panelCount=0,this.showTextEditor(e))},enumerable:!1,configurable:!0}),t.prototype.isModified=function(e){if(this.textEditor.visible)return e!=this.text;var t=this.getEditorItems(),i=e?(new o.ConditionsParser).parseExpression(e):null;if(!i)return!(1==t.length&&!t[0].questionName);if(!this.isReady)return!0;var n=(new o.ConditionsParser).parseExpression(this.text);return!i.isEqual(n)},Object.defineProperty(t.prototype,"context",{get:function(){return this.contextValue},set:function(e){e!==this.context&&(this.contextValue=e,this.updateNamesOnContextChanged(),this.onContextChanged&&this.onContextChanged(e))},enumerable:!1,configurable:!0}),t.prototype.processText=function(e){this.panel.panelCount=0;var t=(new no).build(e);this.buildPanels(t)},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"object",{get:function(){return this.objectValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.panelValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textEditor",{get:function(){return this.textEditorValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isReady",{get:function(){if(this.textEditor.visible)return t.canParseExpression(this.textEditor.value);for(var e=0;e<this.panel.panels.length;e++)if(!this.createEditorItemFromPanel(this.panel.panels[e]).isReady)return!1;return!0},enumerable:!1,configurable:!0}),t.prototype.isEmpty=function(){return 0===this.panel.panels.length||!(this.panel.panels.length>1)&&!this.createEditorItemFromPanel(this.panel.panels[0]).questionName},t.prototype.hasErrorInUI=function(){var e=this.survey.creator;return!this.isReady&&(this.hasErrors(),this.errorText=ke("expressionInvalid"),e&&e.notify(this.errorText,"error"),!0)},t.prototype.apply=function(){return!this.hasErrorInUI()&&(this.object&&this.propertyName?(this.object[this.propertyName]=this.text,!0):void 0)},t.prototype.setIsFastEntry=function(e){e?this.showTextEditor(this.text):this.panel.visible||this.showBuilder(this.text)},t.prototype.buildPanels=function(e){this.panel.panelCount=e.length;for(var t=0;t<e.length;t++)this.setItemToPanel(e[t],this.panel.panels[t]);0==this.panel.panelCount&&this.panel.addPanel()},t.prototype.setupConditionOperator=function(e,o){var n=this,r=o.getQuestionByName("operator");r.choices=this.getOperators(),r.value=e.operator,r.onOpened.add((function(e,r){var a=o.getQuestionByName("questionName").value,s=n.getQuestionConditionJson(a),l=s?s.type:null,u=n.getConditionQuestion(a);r.choices.forEach((function(e,o){var r=t.isOperatorEnabled(l,i.operators[e.value]);r=n.options.isConditionOperatorEnabled(a,u,e.value,r),e.setIsEnabled(r),e.setIsVisible(r)}))}))},t.prototype.setupConditionQuestionName=function(e,t){var o=t.getQuestionByName("questionName");o.choices=this.getConditionQuestions(),o.titleLocation=0==this.panel.panels.indexOf(t)?"left":"hidden";var i=this.getQuestionNameToPanel(e.questionName);this.getConditionQuestion(i)&&(o.value=i)},t.prototype.setupRemoveQuestion=function(e){var t=e.getQuestionByName("removeAction").parentQuestion,o=e.getQuestionByName("removeAction");o.linkClickCallback=function(){t&&t.removePanelUI(e)},o.linkSetButtonCssClasses="svc-logic-condition-remove svc-icon-remove",o.linkValueText=""},t.prototype.setItemToPanel=function(e,t){this.isSettingPanelValues=!0,t.getQuestionByName("conjunction").value=e.conjunction,this.setupConditionOperator(e,t),this.setupConditionQuestionName(e,t),t.getQuestionByName("questionValue")&&(t.getQuestionByName("questionValue").value=e.value,this.updateSurveyVariable(e)),this.setupRemoveQuestion(t),this.isSettingPanelValues=!1},t.prototype.updateSurveyVariable=function(e){this.editSurvey.setVariable(e.questionName,e.value)},t.prototype.getConditionQuestions=function(){if(!this.context)return this.allConditionQuestions;for(var e=[],t=0;t<this.allConditionQuestions.length;t++){var o=this.allConditionQuestions[t];o.context&&o.context!==this.context||e.push(o)}return e},t.prototype.getText=function(){if(this.textEditor.visible)return this.textEditor.value;for(var e="",t=this.getEditorItems(),o=0;o<t.length&&t[o].isReady;o++)e&&(e+=" "+t[o].conjunction+" "),e+=t[o].toExpression();return e},t.prototype.getEditorItems=function(){for(var e=[],t=0;t<this.panel.panels.length;t++)e.push(this.createEditorItemFromPanel(this.panel.panels[t]));return e},t.prototype.createEditorItemFromPanel=function(e){var t=new io(this.survey);return t.conjunction=e.getQuestionByName("conjunction").value,t.questionName=this.getQuestionNameFromPanel(e.getQuestionByName("questionName").value),t.operator=e.getQuestionByName("operator").value,e.getQuestionByName("questionValue")&&(t.value=e.getQuestionByName("questionValue").value,this.updateSurveyVariable(t)),t},t.prototype.getQuestionNameFromPanel=function(e){if(!this.context||!e)return e;var t=this.context.getValueName()+".";return e.replace(t,"")},t.prototype.getContextIndexInfo=function(e,t){return void 0===t&&(t=""),ee.getQuestionContextIndexInfo(e,t)},t.prototype.getQuestionNameToPanel=function(e){if(!this.context||!e)return e;var t=this.getContextIndexInfo(e);return t&&0===t.index?this.context.getValueName()+"."+e:e},t.prototype.getContextFromPanels=function(){if(this.object)return null;for(var e=0;e<this.panel.panels.length;e++){var t=this.panel.panels[e].getQuestionByName("questionName").value,o=this.getContextByQuestionName(t);if(o)return o}return null},t.prototype.updateNamesOnContextChanged=function(){for(var e=0;e<this.panel.panels.length;e++)this.panel.panels[e].getQuestionByName("questionName").choices=this.getConditionQuestions()},t.prototype.getContextByQuestionName=function(e){if(!e)return null;var t=this.getContextIndexInfo(e,".");return t?(e=e.substring(0,t.index),this.survey.getQuestionByValueName(e)):null},t.prototype.createAllConditionQuestions=function(){if(!this.survey)return[];var e=[],t=this.survey.getAllQuestions(),o=this.getContextObject(),n=i.logic.questionSortOrder;if(t.length>0)for(var r=0;r<t.length;r++)if(o!=(l=t[r])){var a=o||!this.context||this.context===l;l.addConditionObjectsByContext(e,a)}var s=this.survey.getVariableNames();for(this.addSurveyCalculatedValues(s),n=this.options.onConditionQuestionsGetListCallback(this.propertyName,this.object,this,e,s),r=0;r<e.length;r++){e[r].value=e[r].name;var l=e[r].question?e[r].question:e[r];if(!this.options.showTitlesInExpressions){var u=e[r].name,p=l.valueName;p&&0==u.indexOf(p)&&(u=u.replace(p,l.name)),u=u.replace("-unwrapped",""),e[r].text=this.options.getObjectDisplayName(l,"condition-editor","condition",u)}this.addConditionQuestionsHash[e[r].name]=l}return this.addValuesIntoConditionQuestions(s,e),"asc"===n&&ee.sortItems(e),e},t.prototype.getContextObject=function(){if(this.object&&this.object.isDescendantOf("itemvalue")){var e=this.object.locOwner;if(e&&e.getType)return e.locOwner&&e.locOwner.isDescendantOf("matrixdropdowncolumn")?e.locOwner:e}return this.object},t.prototype.addValuesIntoConditionQuestions=function(e,t){for(var o=0;o<e.length;o++){var i=e[o].name?e[o].name:e[o];this.addConditionQuestionsHash[i]=this.getCalculatedValueQuestion(),t.push({value:i,text:i,question:this.getCalculatedValueQuestion()})}},t.prototype.addSurveyCalculatedValues=function(e){this.survey.calculatedValues.forEach((function(t){var o=e.indexOf(t.name.toLowerCase());o>-1&&e.splice(o,1),e.push(t.name)}))},t.prototype.getCalculatedValueQuestion=function(){return this.calculatedValueQuestion||(this.calculatedValueQuestion=o.Serializer.createClass("text"),this.calculatedValueQuestion.name="question"),this.calculatedValueQuestion},t.prototype.getOperators=function(){var e=[],t=i.operators;for(var n in t)e.push(new o.ItemValue(n,G.getString("op."+n)));return e},t.prototype.rebuildQuestionValue=function(e){e.getQuestionByName("questionValue")&&e.getQuestionByName("questionValue").clearValue();var t=e.getQuestionByName("questionName").value,i=this.getQuestionConditionJson(t,e.getQuestionByName("operator").value);i||(i={type:"text"}),i.isRequired=!0,ee.updateQuestionJson(i),i.enableIf="{panel.questionName} notempty and {panel.operator} != 'empty' and {panel.operator} != 'notempty'";var n=o.Serializer.createClass(i.type);delete i.type,(new o.JsonObject).toObject(i,n),n||(n=o.Serializer.createClass("text",i));var r=e.getQuestionByName("questionValue");if(r&&e.removeElement(r),this.canShowQuestionValue(e)){var a=n.title;if(n.name="questionValue",n.visibleIf="questionValueVisibleIf({panel.questionName}, {panel.operator})",n.title=a,n.description="",n.titleLocation="top",n.hasComment=!1,n.showOtherItem){var s=this.getConditionQuestion(t);if(s&&s.getStoreOthersAsComment&&s.getStoreOthersAsComment()){var l=n.otherItem;n.choices.push(new o.ItemValue(l.value,l.title)),l.value="#"+l.value+"#",n.showOtherItem=!1}}e.addElement(n)}},t.prototype.rebuildQuestionValueOnOperandChanging=function(e){var t=this.getQuestionConditionJson(e.getQuestionByName("questionName").value,e.getQuestionByName("operator").value),o=e.getQuestionByName("questionValue");!o||!o.isReadOnly&&o.isVisible||o.clearValue(),!o||t&&t.type==o.getType()||this.rebuildQuestionValue(e)},t.prototype.canShowQuestionValue=function(e){var t=e.getQuestionByName("operator");if(!t)return!1;this.updateOperatorEnables(e);for(var o=t.choices,i=0;i<o.length;i++)if(o[i].isEnabled){var n=o[i].value;if("empty"!==n&&"notempty"!=n)return!0}return!1},t.prototype.getConditionQuestion=function(e){return this.addConditionQuestionsHash[e]},t.prototype.getQuestionConditionJson=function(e,o){var i="",n=this.getConditionQuestion(e);if(!n)return null;o||(o=this.getDefaultOperatorByQuestion(n)),0==e.indexOf(n.getValueName())&&(i=e.substring(n.getValueName().length));var r=this.getContextIndexInfo(e);r&&0==r.index&&(i=e.substring(r.name.length)),i||(i=e),i&&"."==i[0]&&(i=i.substring(1));var a=n&&n.getConditionJson?n.getConditionJson(o,i):null;return a?(a.choicesFromQuestion&&this.updateChoicesFromQuestion(a),"expression"==a.type&&(a.type="text"),"anyof"==o&&(t.isClassContains(a.type,["checkbox"],[])||(a.type="checkbox")),a):null},t.prototype.updateChoicesFromQuestion=function(e){var t=this.getConditionQuestion(e.choicesFromQuestion);if(t){delete e.choicesFromQuestion;var o=t.toJSON();o.choices&&(e.choices=o.choices),o.choicesByUrl&&(e.choicesByUrl=o.choicesByUrl)}},t.prototype.updateOperatorEnables=function(e){var o=e.getQuestionByName("questionName");if(o){var n=this.getQuestionConditionJson(o.value),r=n?n.type:null,a=e.getQuestionByName("operator");if(a){for(var s=a.choices,l=!0,u=a.value,p=0;p<s.length;p++){var c=t.isOperatorEnabled(r,i.operators[s[p].value]);s[p].setIsEnabled(c),s[p].setIsVisible(c),s[p].value==u&&(l=s[p].isEnabled)}l||(a.value=this.getFirstEnabledOperator(s))}}},t.prototype.updateQuestionsWidth=function(e){var t=e.getQuestionByName("questionValue"),o=e.getQuestionByName("conjunction"),i=e.getQuestionByName("questionName"),n=e.getQuestionByName("operator"),r=!!t&&!t.startWithNewLine,a=!o||!o.isVisible;a||(o.minWidth="50px",o.width="15%"),i.minWidth="50px",i.width=a?"40%":"25%",n.minWidth="50px",n.width=r?"25%":"60%",t&&(t.minWidth="50px",t.width=r?"35%":"")},Object.defineProperty(t.prototype,"defaultOperator",{get:function(){return i.logic.defaultOperators.default},enumerable:!1,configurable:!0}),t.prototype.getDefaultOperatorByQuestionName=function(e){return this.getDefaultOperatorByQuestion(this.getConditionQuestion(e))},t.prototype.getDefaultOperatorByQuestion=function(e){if(e){var t=i.logic.defaultOperators;if(t[e.getType()])return t[e.getType()]}return this.defaultOperator},t.prototype.getFirstEnabledOperator=function(e){for(var t=0;t<e.length;t++)if(e[t].isEnabled)return e[t].value;return this.defaultOperator},t.prototype.onPanelAdded=function(){this.setItemToPanel(new oo,this.panel.panels[this.panel.panels.length-1])},t.prototype.onPanelValueChanged=function(e,t){"questionName"==t&&(this.context=this.getContextFromPanels(),this.rebuildQuestionValue(e),this.isSettingPanelValues||(e.getQuestionByName("operator").value=this.getDefaultOperatorByQuestionName(e.getQuestionByName("questionName").value))),"operator"==t&&this.rebuildQuestionValueOnOperandChanging(e),this.updateOperatorEnables(e),this.updateQuestionsWidth(e)},t.prototype.onUpdateQuestionCssClasses=function(e){var t=e.cssClasses,o=e.question;t.answered="svc-logic-question--answered","textEditor"===o.name&&(t.root+=" svc-logic-question-text-editor"),"conjunction"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--conjunction "),"questionName"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--question",t.error.root="svc-logic-operator__error",t.onError="svc-logic-operator--error"),"operator"===o.name&&(o.allowRootStyle=!1,t.control+=" svc-logic-operator svc-logic-operator--operator"),"removeAction"===o.name&&(o.allowRootStyle=!1,t.mainRoot+=" svc-logic-condition-remove-question"),("questionValue"===o.name||o.isContentElement)&&(P(t,o.getType()),t.mainRoot+=" svc-logic-question-value sd-element--with-frame",t.error.root="svc-logic-operator__error"),"panel"===o.name&&(t.root+=" svc-logic-paneldynamic",t.buttonAdd+=" svc-logic-operator--operator",t.iconRemove="svc-icon-remove",t.buttonRemove="svc-logic-paneldynamic__button svc-logic-paneldynamic__remove-btn",t.buttonRemoveRight="svc-logic-paneldynamic__remove-btn--right",t.buttonRemoveText="svc-logic-paneldynamic__button-remove-text")},t.prototype.onValueChanged=function(e){if("panel"===e.question.name&&e.value.length>0){var t=this.options.maxLogicItemsInCondition>0?this.options.maxLogicItemsInCondition:100;e.question.maxPanelCount=1!==e.value.length||e.value[0].questionName?t:1,this.panel.panels.forEach((function(t){t.getQuestionByName("removeAction").visible=1!==e.value.length}))}this.setTitle()},t.prototype.setTitle=function(){var e=this.isReady?this.text:"";this.title=this.options.onConditionGetTitleCallback(e,e||G.getString("pe.ruleIsNotSet"))},t.prototype.showTextEditor=function(e){this.panel.visible=!1,this.textEditor.value=e,this.textEditor.visible=!0},t.prototype.showBuilder=function(e){(this.isModal||this.getCanShowBuilder(e))&&(this.textEditor.visible=!1,this.processText(e),this.panel.visible=!0)},t.prototype.getCanShowBuilder=function(e){return t.canBuildExpression(e)},t}(it),ao=function(){function e(e,t,o){this.panel=e,this.initialLogicAction=t,this.logicType=o}return e.createActionModel=function(e,t,o,i){return o&&o.hasSelectorChoices?o.name.indexOf("_setValue")>-1?new lo(e,t,o,i):new so(e,t,o,i):new uo(e,t,o)},e.prototype.updateCurrentLogicAction=function(e){return!1},e.prototype.afterUpdateInitialLogicAction=function(){},e.prototype.resetElements=function(){},e.prototype.getSelectedElement=function(){return null},e.prototype.updateInitialLogicAction=function(){this.initialLogicAction=this.currentLogicAction,this.afterUpdateInitialLogicAction&&this.afterUpdateInitialLogicAction()},e.prototype.setInitialElementValue=function(e,t,o){o&&0!==e.choices.filter((function(e){return e.value===o})).length?e.value=o:e.value=t&&t.logicType==this.logicType?t.elementName:void 0},e}(),so=function(e){function t(t,o,i,n){var r=e.call(this,t,o,i)||this;return r.selectorElementsHash=n,r}return K(t,e),t.prototype.getSelectorOptionsText=function(e){var t=e.baseClass,o="page"==t?"pe.conditionSelectPage":"panel"==t?"pe.conditionSelectPanel":"pe.conditionSelectQuestion";return G.getString(o)},t.prototype.getElementBySelectorName=function(e){var t=e.getQuestionByName("elementSelector").value;return t?this.selectorElementsHash[t]:null},t.prototype.updateCurrentLogicAction=function(e){var t=this.getElementBySelectorName(this.panel);return(!this.initialLogicAction||this.initialLogicAction.logicType!=this.logicType||!!t&&this.initialLogicAction.element!=t)&&(this.currentLogicAction=new qe(this.logicType,t,e),!0)},t.prototype.resetElements=function(){this.panel.getQuestionByName("elementSelector").visible=!1},t.prototype.updatePanelElements=function(e,t){var o=this.panel.getQuestionByName("elementSelector");o.visible=!0,o.choices=t,o.allowClear=!1,o.optionsCaption=this.getSelectorOptionsText(this.logicType),this.setInitialElementValue(o,this.initialLogicAction,e)},t.prototype.getSelectedElement=function(){return this.panel.getQuestionByName("elementSelector").value},t}(ao),lo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.updatePanelElements=function(t,o){e.prototype.updatePanelElements.call(this,t,o),this.getValueIfQuestion().placeholder=G.getString("ed.lg.setValueExpressionPlaceholder"),this.getValueIfPanel().visible=!0,this.setValueExpressionValue()},t.prototype.afterUpdateInitialLogicAction=function(){var e=this.getElementBySelectorName(this.panel);e&&(e.setValueExpression=this.panel.getQuestionByName("setValueExpression").value)},t.prototype.setValueExpressionValue=function(){var e=this.getElementBySelectorName(this.panel);e&&(this.getValueIfQuestion().value=e.setValueExpression)},t.prototype.getValueIfPanel=function(){return this.panel.getElementByName("setValueIfPanel")},t.prototype.getValueIfQuestion=function(){return this.panel.getQuestionByName("setValueExpression")},t.prototype.resetElements=function(){e.prototype.resetElements.call(this),this.getValueIfPanel().visible=!1,this.getValueIfQuestion().clearValue()},t}(so),uo=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.isTrigger=!0,n}return K(t,e),t.prototype.recreateQuestion=function(e,t,i,n){var r=i?e.getQuestionByName(i):null;if(r){var a=e.getElementByName("triggerEditorPanel"),s=o.Serializer.createClass("panel");new at(t,n).setupObjPanel(s,!0,"logic");var l=s.getQuestionByName(i);if(l){var u=a.elements.indexOf(r);a.blockAnimations(),a.addElement(l,u),r.delete(),a.releaseAnimations()}"setValue"===l.name&&this.updateSetValueQuestion(l),this.updateVisibilityPanel(a),s.dispose()}},t.prototype.updateSetValueQuestion=function(e){var t=e.obj,o=t.getSurvey();if(o||(o=t.owner),t.setToName&&o){var i=o.getQuestionByValueName(t.setToName);e.title=i.title,e.titleLocation="top"}},t.prototype.updateRunExpressionQuestion=function(e){e.titleLocation="hidden",e.placeholder=G.getString("pe.emptyExpressionPlaceHolder")},t.prototype.createElementPanelObj=function(){var e=this.initialLogicAction,t=e&&e.logicType==this.logicType?e.element:null,o=this.logicType.createNewObj(t);return this.setPanelObj(o),o},t.prototype.getQuestions=function(){var e=this,t=this.panel.getElementByName("triggerQuestionsPanel");return 0!==t.elements.length&&this.logicType.questionNames?t.elements.filter((function(t){return-1!==e.logicType.questionNames.indexOf(t.name)})):null},t.prototype.resetPanel=function(e){var t=this.panel.getElementByName(e);t.questions.forEach((function(e){e.clearValue()})),t.elements.splice(0,t.elements.length),t.visible=!1},t.prototype.updateVisibilityPanel=function(e){e.elements.length>0?e.visible=e.elements.filter((function(e){return e.visible})).length>0:e.visible=!1},t.prototype.onPanelQuestionValueChanged=function(e,t){var i=this;if(this.panelObj){var n=o.Serializer.findProperty(this.panelObj.getType(),t),r=null==n?void 0:n.getDependedProperties();Array.isArray(r)&&r.length>0&&r.forEach((function(t){var n=e.getQuestionByName(t),r=o.Serializer.findProperty(i.panelObj.getType(),t);n&&r&&nt.onMasterValueChanged(i.panelObj,r,n)}))}},t.prototype.updatePanelQuestionsValue=function(e){var t=this;e.onSurveyLoad(),e.questions.forEach((function(e){o.Helpers.isValueEmpty(t.panelObj[e.getValueName()])||(e.value=t.panelObj[e.getValueName()])}))},t.prototype.afterUpdateInitialLogicAction=function(){this.setPanelObj(this.initialLogicAction.element),this.panelObj&&this.logicType.saveNewElement(this.panelObj)},t.prototype.updateCurrentLogicAction=function(e){if(this.initialLogicAction&&this.initialLogicAction.logicType==this.logicType){for(var t=this.initialLogicAction.element,o=this.panelObj.toJSON(),i=Object.keys(o),n=Object.keys(t.toJSON()),r=[],a=0;a<n.length;a++){var s=n[a];i.indexOf(s)<0&&r.push(s)}for(t.fromJSON(o),this.currentLogicAction=this.initialLogicAction,a=0;a<r.length;a++)t[r[a]]=void 0;return!1}return this.currentLogicAction=new qe(this.logicType,this.panelObj,e),!0},t.prototype.updatePanel=function(e,t,o,i){this.panelObj&&(this.panelObj[e]=t,this.logicType&&this.logicType.dependedOnPropertyName===e&&this.recreateQuestion(this.panel,this.panelObj,this.logicType.dynamicPropertyName,o),this.panel.runCondition(i.getAllValues(),{survey:i}))},t.prototype.setPanelObj=function(e){var t=this,o=this.panelObj;o&&(o.onPropertyValueChangedCallback=void 0),this.panelObj=e,e&&(e.onPropertyValueChangedCallback=function(e,i,n,r,a){if(t.panel&&!t.panel.isDisposed){var s=t.panel.getQuestionByName(e);s&&(s.value=n)}else o.onPropertyValueChangedCallback=void 0})},t.prototype.resetElements=function(){this.setPanelObj(null),this.resetPanel("triggerQuestionsPanel"),this.resetPanel("triggerEditorPanel")},t.prototype.updatePanelElements=function(e,t){var o=this,i=this.panel.getElementByName("triggerEditorPanel"),n=this.panel.getElementByName("triggerQuestionsPanel"),r=this.createElementPanelObj();new at(r,t).setupObjPanel(i,!0,"logic"),i.title="";var a=i.getQuestionByName("runExpression");a&&this.updateRunExpressionQuestion(a),this.logicType.questionNames&&i.elements.filter((function(e){return-1!==o.logicType.questionNames.indexOf(e.name)})).forEach((function(e){var t=e;"dropdown"===t.getType()&&(t.allowClear=!1,t.renderAs="logicoperator"),n.addQuestion(t)})),i.getElementByName(this.logicType.propertyName).visible=!1,this.updateVisibilityPanel(n),this.updatePanelQuestionsValue(n),this.updateVisibilityPanel(i),this.updatePanelQuestionsValue(i);var s=this.getQuestions();s&&e&&s.forEach((function(t){o.setInitialElementValue(t,o.initialLogicAction,e),e=null}))},t.prototype.getSelectedElement=function(){var e=this.getQuestions();if(e){var t=e[0];return!!t&&t.value}},t}(ao);o.FunctionFactory.Instance.register("logicTypeVisibleIf",(function(e){if(!this.question||!this.question.parentQuestion||1!=e.length)return!0;var t=this.question.parentQuestion.panels;if(t.length<2)return!0;for(var o=0;o<t.length;o++){var i=t[o].getQuestionByName("logicTypeName");if(i!=this.question&&i.value==e[0])return!1}return!0}));var po=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,o)||this;return i.options=o,i.initialSelectedElements={},i.isModifiedValue=!1,i.selectorElementsHash={},i.options||(i.options=new n),i.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){"logicTypeName"==t.name&&i.onLogicTypeChanged(t.panel);var o=i.getActionModelByPanel(t.panel);o.isTrigger&&o.updatePanel(t.name,t.value,i.options,i.editSurvey)})),i.editSurvey.onDynamicPanelRemoved.add((function(e,t){if(!i.isBuildingPanels){var o=i.getActionModelByPanel(t.panel);o&&o.initialLogicAction&&i.editableItem.removeAction(o.initialLogicAction),0==i.panel.panelCount&&i.panel.addPanel(),i.panel.panelCount>0&&(i.panels[0].getQuestionByName("logicTypeName").title=G.getString("pe.then"))}})),i.editSurvey.onDynamicPanelAdded.add((function(e,t){if(!i.isBuildingPanels){var o=i.panels[i.panel.panelCount-1];i.onPanelAdded(o,null)}})),i.editSurvey.css=to,i.editSurvey.onUpdateQuestionCssClasses.add((function(e,t){i.onUpdateQuestionCssClasses(t)})),i.editSurvey.onUpdatePanelCssClasses.add((function(e,t){i.onUpdatePanelCssClasses(t)})),i.editSurvey.onQuestionAdded.add((function(e,t){i.onQuestionAdded(t)})),i.editSurvey.onGetQuestionTitleActions.add((function(e,t){i.onGetQuestionTitleActions(t)})),i.editSurvey.onValueChanged.add((function(e,t){i.onValueChanged(t)})),i.editSurvey.onDynamicPanelItemValueChanged.add((function(e,t){var o,n=t.panel.getQuestionByName(t.name);if(n&&"triggerEditorPanel"===(null===(o=n.parent)||void 0===o?void 0:o.name)){var r=i.getActionModelByPanel(t.panel);r&&r.onPanelQuestionValueChanged(n.parent,t.name)}})),i.setEditableItem(t),i}return K(t,e),Object.defineProperty(t.prototype,"editableItem",{get:function(){return this.editableItemValue},enumerable:!1,configurable:!0}),t.prototype.setEditableItem=function(e){this.editableItemValue=e,this.buildInitialSelectedElements(),this.buildPanels(),this.resetModified()},Object.defineProperty(t.prototype,"survey",{get:function(){return this.editableItem.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isModified",{get:function(){return this.isModifiedValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panel",{get:function(){return this.editSurvey.getQuestionByName("panel")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"panels",{get:function(){return this.panel.panels},enumerable:!1,configurable:!0}),t.prototype.getActionModelByPanel=function(e){return e.actionModel},t.prototype.setActionModelByPanel=function(e,t){e.actionModel=t},Object.defineProperty(t.prototype,"context",{get:function(){return this.contextValue},set:function(e){e!==this.context&&(this.contextValue=e,this.updatePanelsOnContextChanged())},enumerable:!1,configurable:!0}),t.prototype.getLogicTypeByPanel=function(e){return this.getLogicTypeByName(e.getQuestionByName("logicTypeName").value)},t.prototype.getSurveyJSON=function(){return{clearInvisibleValues:"onHidden",elements:[{type:"paneldynamic",name:"panel",title:ke("actionsEditorTitle"),titleLocation:"hidden",panelAddText:ke("addNewAction"),panelRemoveButtonLocation:"right",panelCount:0,minPanelCount:1,maxPanelCount:1,templateElements:[{name:"logicTypeName",type:"dropdown",renderAs:"logicoperator",searchEnabled:!1,allowClear:!1,title:G.getString("pe.then"),titleLocation:"left",isRequired:!0,optionsCaption:ke("selectedActionCaption"),requiredErrorText:this.getLocString("pe.conditionActionEmpty")},{name:"logicTypeDescription",type:"html",startWithNewLine:!1,visible:!1},{name:"elementSelector",type:"dropdown",renderAs:"logicoperator",allowClear:!1,titleLocation:"hidden",isRequired:!0,startWithNewLine:!1,visible:!1},{name:"triggerQuestionsPanel",type:"panel",startWithNewLine:!1,visible:!1},{name:"removeAction",type:"linkvalue",titleLocation:"hidden",showOptionsCaption:!1,visible:!1,startWithNewLine:!1,showValueInLink:!1,allowClear:!1,showClear:!1,iconName:"icon-delete_24x24"},{name:"triggerEditorPanel",type:"panel",visible:!1},{name:"setValueIfPanel",visible:!1,type:"panel",elements:[{name:"setValueExpression",type:"comment",titleLocation:"hidden"}]}]}]}},t.prototype.getSurveyCreationReason=function(){return"logic-item-editor"},t.prototype.resetModified=function(){this.isModifiedValue=!1},t.prototype.isEmpty=function(){return 0===this.panels.length||!(this.panels.length>1)&&!this.getActionModelByPanel(this.panels[0])},t.prototype.apply=function(){if(this.editSurvey.hasErrors())return!1;for(var e=0;e<this.panels.length;e++)this.applyPanel(this.panels[e]);return this.resetModified(),!0},t.prototype.getEditingActions=function(){var e=this;return this.panels.map((function(t){var o=e.getActionModelByPanel(t);return o.updateCurrentLogicAction(e.survey),o.currentLogicAction||o.initialLogicAction})).filter((function(e){return!!e}))},t.prototype.onUpdateQuestionCssClasses=function(e){var t,i=e.cssClasses,n=e.question;i.answered="svc-logic-question--answered","logicTypeName"===n.name&&(n.allowRootStyle=!1,i.control+=" svc-logic-operator svc-logic-operator--action",i.error.root="svc-logic-operator__error",i.onError="svc-logic-operator--error");var r=["elementSelector","setToName","fromName","gotoName"];r.indexOf(n.name)>-1&&(n.allowRootStyle=!1,"setToName"!==n.name&&"fromName"!==n.name||(n.titleLocation="left",n.startWithNewLine=!1),i.control+=" svc-logic-operator svc-logic-operator--question",i.error.root="svc-logic-operator__error",i.onError="svc-logic-operator--error"),(n.isContentElement||this.isSetValueInternalQuestion(n))&&(P(i,n.getType()),i.mainRoot+=" svc-logic-question-value sd-element--with-frame");var a=null===(t=n.parent)||void 0===t?void 0:t.name;if(r.indexOf(n.name)<0&&("triggerEditorPanel"===a||"setValueIfPanel"===a)){var s=n.getType();P(i,s),!o.defaultV2Css[s]&&ze[s]&&(S(i,ze.question),S(i,ze[s]));var l=n.parent.elements.filter((function(e){return r.indexOf(e.name)<0&&"expression"!==e.name}));("runExpression"!==n.name&&"comment"!==s||Array.isArray(l)&&l.length>1)&&(i.mainRoot+=" svc-logic-question-value sd-element--with-frame")}"removeAction"===n.name&&(n.allowRootStyle=!1,i.mainRoot+=" svc-logic-condition-remove-question"),"panel"===n.name&&(i.root+=" svc-logic-paneldynamic",i.buttonAdd+=" svc-logic-operator--action ",i.iconRemove="svc-icon-remove",i.buttonRemove="svc-logic-paneldynamic__button svc-logic-paneldynamic__remove-btn",i.buttonRemoveRight="svc-logic-paneldynamic__remove-btn--right",i.buttonRemoveText="svc-logic-paneldynamic__button-remove-text")},t.prototype.isSetValueInternalQuestion=function(e){if(this.isSetValueInternalQuestionCore(e))return!0;if(this.isSetValueInternalQuestionCore(e.parentQuestion))return!0;var t=e.parent;return t&&this.isSetValueInternalQuestionCore(t.parentQuestion)},t.prototype.isSetValueInternalQuestionCore=function(e){return"setValue"===(null==e?void 0:e.name)},t.prototype.onUpdatePanelCssClasses=function(e){var t=e.panel,o=e.cssClasses,i=t.name;"triggerEditorPanel"!==i&&"setValueIfPanel"!==i||(o.panel.container+=" svc-logic_trigger-editor"),"triggerQuestionsPanel"===i&&(t.allowRootStyle=!1,o.panel.container+=" svc-logic_trigger-questions"),this.isSetValueInternalQuestionCore(t.parentQuestion)&&P(o,t.getType())},t.prototype.onValueChanged=function(e){this.isModifiedValue=!0,e.question.maxPanelCount=1!==e.value.length||e.value[0].logicTypeName?100:1,this.panels.forEach((function(t){t.getQuestionByName("removeAction").visible=1!==e.value.length}))},t.prototype.onQuestionAdded=function(e){"setToName"!==e.question.name&&"fromName"!==e.question.name||(e.question.titleLocation="left",e.question.startWithNewLine=!1)},t.prototype.onGetQuestionTitleActions=function(e){"setValue"===e.question.name&&(e.titleActions=[])},t.prototype.applyPanel=function(e){var t=this.getActionModelByPanel(e);t.updateCurrentLogicAction(this.survey)&&(this.editableItem.replaceAction(t.currentLogicAction,t.initialLogicAction),t.updateInitialLogicAction())},t.prototype.buildInitialSelectedElements=function(){if(this.initialSelectedElements={},this.editableItem)for(var e=0;e<this.editableItem.actions.length;e++){var t=this.editableItem.actions[e];if(this.isElementSelectorVisible(t.logicType)){var o=t.logicTypeName;this.initialSelectedElements[o]||(this.initialSelectedElements[o]=[]),this.initialSelectedElements[o].push(t.element)}}},t.prototype.buildPanels=function(){if(this.panel.panelCount=0,this.editableItem){this.logicTypeChoices=this.getLogicTypeChoices();for(var e=0;e<this.editableItem.actions.length;e++)this.onPanelAdded(this.panel.addPanel(),this.editableItem.actions[e]);0==this.panel.panelCount&&this.onPanelAdded(this.panel.addPanel(),null)}},t.prototype.onPanelAdded=function(e,t){var o=e.getQuestionByName("logicTypeName");if(o.title=this.panel.panelCount>1?G.getString("pe.and"):G.getString("pe.then"),o.choices=this.logicTypeChoices,o.allowClear=!1,t){var i=ao.createActionModel(e,t,this.getLogicTypeByName(t.logicTypeName),this.selectorElementsHash);this.setActionModelByPanel(e,i),o.value=t.logicTypeName}var n=e.getQuestionByName("removeAction"),r=n.parentQuestion;return n.linkClickCallback=function(){r&&r.removePanelUI(e)},n.linkSetButtonCssClasses="svc-logic-condition-remove svc-icon-remove",n.linkValueText="",e},t.prototype.updatePanelsOnContextChanged=function(){if(this.logicTypeChoices=this.getLogicTypeChoices(),this.context)for(var e=this.panels.length-1;e>=0;e--){var t=this.panels[e];this.isPanelSupportContext(t)||(0===e&&1===this.panels.length?t.getQuestionByName("logicTypeName").clearValue():this.panel.removePanel(e))}for(e=0;e<this.panels.length;e++)this.updateSelectorOnContextChanged(this.panels[e])},t.prototype.isPanelSupportContext=function(e){var t=this.getLogicTypeByPanel(e);return!!t&&t.supportContext(this.context)},t.prototype.updateSelectorOnContextChanged=function(e){var t=e.getQuestionByName("logicTypeName");t.choices=this.logicTypeChoices,t.allowClear=!1;var o=this.getLogicTypeByPanel(e);if(this.isElementSelectorVisible(o)){var i=e.getQuestionByName("elementSelector");i.choices=this.getSelectorChoices(o),i.allowClear=!1}},t.prototype.getLogicTypeChoices=function(){for(var e=[],t=this.editableItem.getVisibleLogicTypes(),i=0;i<t.length;i++){var n=t[i];if(!this.context||n.supportContext(this.context)){var r=new o.ItemValue(n.name,n.displayName);n.isUniqueItem&&(r.visibleIf="logicTypeVisibleIf({item})"),e.push(r)}}return e},t.prototype.onLogicTypeChanged=function(e){var t=this.getLogicTypeByPanel(e);e.getQuestionByName("logicTypeDescription").html=t?t.description:"";var o,i=this.getActionModelByPanel(e);if(i&&(o=i.getSelectedElement(),i.resetElements()),t){var n=ao.createActionModel(e,i?i.initialLogicAction:null,t,this.selectorElementsHash);this.setActionModelByPanel(e,n),n.isTrigger?n.updatePanelElements(o,this.options):n.updatePanelElements(o,this.getSelectorChoices(n.logicType))}},t.prototype.getLogicTypeByName=function(e){if(!e)return null;for(var t=this.editableItem.getVisibleLogicTypes(),o=0;o<t.length;o++)if(t[o].name==e)return t[o];return null},t.prototype.isElementSelectorVisible=function(e){return!!e&&e.hasSelectorChoices},t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.getElementText=function(e,t){var o="";return t&&(o=e.locTitle.renderedHtml),o||(o=e.name),e.isQuestion&&(o=this.options.getObjectDisplayName(e,"logic-tab:question-selector","condition",o)),o},t.prototype.getSelectorChoices=function(e){if(!e.hasSelectorChoices)return[];for(var t=e.getSelectorChoices(this.survey,this.context),n=[],r=this.options.showTitlesInExpressions,a=0;a<t.length;a++){var s="",l="",u=t[a],p=e.getParentElement(u);p&&(s=p.name+".",l=this.getElementText(p,r)+".");var c=this.getElementText(u,r),d=s+u.name,h=new o.ItemValue(d,l+c);this.selectorElementsHash[d]=u,u[e.propertyName]&&!this.isElementInInitialSelection(e.name,u)&&(h.enableIf="1=2",h.visibleIf="1=2"),n.push(h)}return"asc"===i.logic.questionSortOrder&&ee.sortItems(n),n},t.prototype.isElementInInitialSelection=function(e,t){return!!this.initialSelectedElements[e]&&this.initialSelectedElements[e].indexOf(t)>-1},t}(it);r(790);var co=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,t,o)||this;return i.survey=t,i.options=o,i.itemUIHash={},i.options||(i.options=new n),i.setupToolbarItems(),i.update(),i}return K(t,e),t.prototype.update=function(t,o){var i=this;void 0===t&&(t=null),void 0===o&&(o=null),e.prototype.update.call(this,t,o);var n=this.options.createSurvey(this.getLogicItemSurveyJSON(),"logic-items",this,(function(e){e.css=to}));this.itemsSurveyValue=n,this.itemsSurvey.onMatrixRowRemoving.add((function(e,t){var o=i.visibleItems[t.rowIndex];t.allow=i.canRemoveItem(o)})),this.itemsSurvey.onMatrixRowRemoved.add((function(e,t){var o=i.visibleItems[t.rowIndex],n=o===i.editableItem;i.removeItem(o,!1),n&&(i.mode="view",i.updateNewActionState()),i.expressionEditorCanShowBuilder=!!i.editableItem})),this.itemsSurvey.onGetMatrixRowActions.add((function(e,t){!function(e,t,o){var i=_t(t,"show-detail");if(i){i.component="sv-action-bar-item",i.iconName="icon-logic-expand",i.innerCss="sl-table__action-button sl-table__detail-button",i.iconSize=48,i.showTitle=!1,i.action=function(){o.showHideDetailPanelClick()};var n=function(){i.iconName=o.isDetailPanelShowing?"icon-logic-collapse":"icon-logic-expand"};e.registerFunctionOnPropertyValueChanged("isRowShowing"+o.id,n),n()}}(t.question,t.actions,t.row),function(e,t,o){Mt(e,t,o);var i=_t(t,"remove-row");i&&(i.css="sl-table__action-button sl-table__remove-button")}(t.question,t.actions,t.row)})),this.updateItemsSurveyData(),this.onReadOnlyChanged()},t.prototype.dispose=function(){for(var t in e.prototype.dispose.call(this),this.itemUIHash){var o=this.itemUIHash[t];o.expressionEditor.dispose(),o.itemEditor.dispose()}this.itemUIHash={}},t.prototype.addNewUI=function(){0!=this.items.length&&this.items[this.items.length-1].isNew||(this.matrixItems.lockResetRenderedTable=!0,this.addNew(),this.matrixItems.lockResetRenderedTable=!1);var e=this.matrixItems.visibleRows;e[e.length-1].showDetailPanel()},t.prototype.toggleExpressionEditorIsFastEntry=function(){this.expressionEditorIsFastEntry=!this.expressionEditorIsFastEntry,this.expressionEditor&&this.expressionEditor.setIsFastEntry(this.expressionEditorIsFastEntry)},t.prototype.updateEditableItemIsModifiedState=function(){this.editableItem&&(this.editableItem.isModified=!!this.itemEditor&&!!this.expressionEditor&&(this.itemEditor.isModified||this.expressionEditor.isModified(this.editableItem.expression)))},t.prototype.getUnsavedItems=function(){for(var e=[],t=0;t<this.visibleItems.length;t++){var o=this.visibleItems[t],i=this.findLogicItemUI(o);i&&(o.isNew?i.expressionEditor.isEmpty()&&i.itemEditor.isEmpty()||e.push(o):o.isModified&&e.push(o))}return e},t.prototype.getErroredItem=function(e){for(var t=0;t<e.length;t++){var o=e[t];if(this.isErroredItem(o))return o}return null},t.prototype.isErroredItem=function(e){var t=this.findLogicItemUI(e);return!!t&&(t.expressionEditor.hasErrors()||t.itemEditor.hasErrors())},t.prototype.showErroredItem=function(e){var t=this.visibleItems.indexOf(e),o=this.matrixItems.visibleRows,i=t>-1&&t<o.length?o[t]:null;i&&(o.forEach((function(e){return e.hideDetailPanel()})),this.mode="view",i.showDetailPanel(),this.hasErrorInUI())},t.prototype.saveItem=function(e){this.isErroredItem(e)||(this.options&&this.options.startUndoRedoTransaction(),this.doItemApply(e),this.options&&this.options.stopUndoRedoTransaction())},t.prototype.tryLeaveUI=function(e){var t=this;this.updateEditableItemIsModifiedState();var o=this.getUnsavedItems();if(0===o.length)return e&&e(!0),!0;var i=this.getErroredItem(o),n=function(){o.forEach((function(e){return t.saveItem(e)})),e&&e(!0)};if(!i)return n(),!0;var r=function(){t.showErroredItem(i),e&&e(!1)};return this.confirmLeavingOnError(n,r)?void 0:(r(),!1)},t.prototype.confirmLeavingOnError=function(e,t){if(!o.settings.showDialog)return!1;var i=new o.LocalizableString(void 0);i.text=this.getLocString("ed.lg.uncompletedRule_text");var n=o.settings.showDialog({componentName:"sv-string-viewer",data:{locStr:i,locString:i,model:i},onApply:function(){return e(),!0},onCancel:function(){return t(),!0},cssClass:"svc-creator-popup",title:this.getLocString("ed.lg.uncompletedRule_title"),displayMode:"popup"},this.options.rootElement),r=n.footerToolbar,a=r.getActionById("apply");return r.getActionById("cancel").title=this.getLocString("ed.lg.uncompletedRule_cancel"),a.title=this.getLocString("ed.lg.uncompletedRule_apply"),a.innerCss+=" svc-logic-tab__leave-apply-button",n.width="800px",!0},t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),"items"===t&&this.updateItemsSurveyData()},t.prototype.onReadOnlyChanged=function(){var e=this;this.itemsSurvey&&(this.itemsSurvey.mode=this.readOnly?"display":"edit",Object.keys(this.itemUIHash||{}).forEach((function(t){e.updateEditModeLogicItem(e.itemUIHash[t])})))},Object.defineProperty(t.prototype,"expressionEditor",{get:function(){return this.expressionEditorValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemEditor",{get:function(){return this.itemEditorValue},enumerable:!1,configurable:!0}),t.prototype.getExpressionEditor=function(e){return this.getLogicItemUI(e).expressionEditor},t.prototype.getLogicItemEditor=function(e){return this.getLogicItemUI(e).itemEditor},t.prototype.updateEditModeLogicItem=function(e){e&&(e.expressionEditor.editSurvey.mode=this.readOnly?"display":"edit",e.itemEditor.editSurvey.mode=this.readOnly?"display":"edit")},t.prototype.getLogicItemUI=function(e){var t=this.findLogicItemUI(e);if(!t){var o=e.getContext();t={expressionEditor:this.createExpressionPropertyEditor(),itemEditor:new po(e,this.options)},this.updateEditModeLogicItem(t),t.expressionEditor.context=o,t.itemEditor.context=o,t.expressionEditor.text=e.expression,t.expressionEditor.onContextChanged=function(e){t.itemEditor.context=e},this.itemUIHash[e.id]=t}return t},t.prototype.findLogicItemUI=function(e){return this.itemUIHash[e.id]},Object.defineProperty(t.prototype,"expressionSurvey",{get:function(){return this.expressionEditor.editSurvey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemEditorSurvey",{get:function(){return this.itemEditor.editSurvey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemsSurvey",{get:function(){return this.itemsSurveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasItems",{get:function(){return this.items.length>0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"matrixItems",{get:function(){return this.itemsSurvey.getQuestionByName("items")},enumerable:!1,configurable:!0}),t.prototype.onStartEditing=function(){e.prototype.onStartEditing.call(this),this.expressionEditorValue=this.getExpressionEditor(this.editableItem),this.itemEditorValue=this.getLogicItemEditor(this.editableItem),this.expressionEditorIsFastEntry=!1,this.expressionEditor.setIsFastEntry(this.expressionEditorIsFastEntry),this.expressionEditorCanShowBuilder=ro.canBuildExpression(this.expressionEditor.text)},t.prototype.onEndEditing=function(){this.updateEditableItemIsModifiedState(),e.prototype.onEndEditing.call(this),this.expressionEditorValue=null,this.itemEditorValue=null},t.prototype.onEditableItemApply=function(){this.doItemApply(this.editableItem),this.editableItem.isSuitable(this.questionFilter,this.actionTypeFilter)?this.updateItemsSurveyData():(this.questionFilter="",this.actionTypeFilter="")},t.prototype.doItemApply=function(e){var t=this.findLogicItemUI(e);t&&(t.expressionEditor.apply(),t.itemEditor.apply(),e.apply(t.expressionEditor.text),e.actions.length!=t.itemEditor.panels.length&&t.itemEditor.setEditableItem(e),t.itemEditor.resetModified(),e.isNew=!1)},t.prototype.hasErrorInUI=function(){var e=this.survey.creator;return this.expressionEditor.hasErrorInUI()?(this.errorText=this.expressionEditor.errorText,!0):!!this.itemEditor.hasErrors()&&(this.errorText=ke("actionInvalid"),e&&e.notify(this.errorText,"error"),!0)},t.prototype.getExpressionText=function(){return this.expressionEditor.text},t.prototype.getEditingActions=function(){return this.itemEditor.getEditingActions()},t.prototype.getLogicItemSurveyJSON=function(){var e=this.survey.creator,t=e&&e.useTableViewInLogicTab?this.getTwoColumnsLayout():this.getOneColumnLayout();return ot(t),t},t.prototype.getTwoColumnsLayout=function(){return{elements:[{type:"matrixdynamic",name:"items",titleLocation:"hidden",detailPanelMode:"underRowSingle",allowAddRows:!1,allowAdaptiveActions:!1,rowCount:0,columns:[{cellType:"linkvalue",name:"conditions",title:this.getLocString("ed.lg.conditions")},{cellType:"linkvalue",name:"actions",title:this.getLocString("ed.lg.actions")}]}]}},t.prototype.getOneColumnLayout=function(){return{elements:[{type:"matrixdynamic",name:"items",titleLocation:"hidden",showColumnHeader:!1,detailPanelMode:"underRowSingle",allowAddRows:!1,allowAdaptiveActions:!1,rowCount:0,showHeader:!1,columns:[{cellType:"linkvalue",name:"rules",showTooltip:!0,width:"100%"}]}]}},t.prototype.createExpressionPropertyEditor=function(){var e=this,t=new ro(this.survey,null,this.options);return t.isModal=!1,t.editSurvey.onValueChanged.add((function(t,o){"textEditor"===o.name&&(e.expressionEditorCanShowBuilder=ro.canBuildExpression(o.value))})),t},t.prototype.getVisibleItems=function(){var e=this;return this.items.filter((function(t){return t.isNew||t.isSuitable(e.questionFilter,e.actionTypeFilter)}))},t.prototype.getDataFromItem=function(e){var t=this.survey.creator;return t&&t.useTableViewInLogicTab?{conditions:e.expressionText,actions:e.actionsText}:{rules:this.getLogicItemDisplayText(e)}},t.prototype.getLogicItemDisplayText=function(e){var t=e.getDisplayText();return this.options?this.options.onLogicGetTitleCallback(e.expression,e.expressionText,t,e):t},t.prototype.updateItemsSurveyData=function(){var e=this;if(this.itemsSurvey){var t=[];this.visibleItems=this.getVisibleItems(),this.visibleItems.forEach((function(o){t.push(e.getDataFromItem(o))})),this.matrixItems.onHasDetailPanelCallback=function(e){return!0},this.matrixItems.onCreateDetailPanelCallback=function(t,o){t.onDetailPanelShowingChanged=function(){if(e.expressionEditorCanShowBuilder=t.isDetailPanelShowing,t.isDetailPanelShowing){if("view"===e.mode){var i=e.visibleItems[t.rowIndex-1];e.editItem(i)}var n=o.getQuestionByName("conditions"),r=o.getQuestionByName("actions");n.embeddedSurvey=e.expressionEditor.editSurvey,r.embeddedSurvey=e.itemEditorValue.editSurvey,e.updateRowIsAdditionalClasses(t.rowIndex-1,!1)}else e.mode="view",e.updateRenderedRows();e.updateNewActionState()},o.addNewQuestion("embeddedsurvey","conditions"),o.addNewQuestion("embeddedsurvey","actions"),o.footerActions.push({id:"saveDetailPanel",innerCss:"sl-panel__done-button",title:e.getLocString("pe.doneEditing"),action:function(){e.saveEditableItem()&&t.hideDetailPanel(!0)}})},this.matrixItems.onCellCreatedCallback=function(e){e.cell.question.linkClickCallback=function(){e.row.isDetailPanelShowing?e.row.hideDetailPanel():e.row.showDetailPanel()},e.cell.question.showClear=!1,e.cell.question.allowClear=!1},this.matrixItems.value=t,this.updateRenderedRows()}},t.prototype.updateRenderedRows=function(){var e=this;this.visibleItems.forEach((function(t,o){e.updateRowIsAdditionalClasses(o,e.visibleItems[o].isModified||e.visibleItems[o].isNew)}))},t.prototype.updateRowIsAdditionalClasses=function(e,t){this.matrixItems.renderedTable&&(this.matrixItems.renderedTable.rows.filter((function(e){return e.visible}))[e].isAdditionalClasses=t)},t.prototype.updateNewActionState=function(){this.addNewButton.enabled="new"!==this.mode},t.prototype.setupToolbarItems=function(){var e=this;this.addNewButton=new o.Action({id:"svd-logic-addNew",title:this.addNewText,tooltip:this.addNewText,component:"sv-action-bar-item",enabled:!0,action:function(){e.addNewUI()}})},Object.defineProperty(t.prototype,"addNewText",{get:function(){return ke("addNewItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"emptyTabPlaceholder",{get:function(){return ke("empty_tab")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.options.isMobileView?ke("logicPlaceholderTitleMobile"):ke("logicPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.options.isMobileView?ke("logicPlaceholderDescriptionMobile"):ke("logicPlaceholderDescription")},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"itemsSurveyValue",void 0),J([(0,o.property)()],t.prototype,"expressionEditorIsFastEntry",void 0),J([(0,o.property)()],t.prototype,"expressionEditorCanShowBuilder",void 0),J([(0,o.property)({onSet:function(e,t){t.updateItemsSurveyData()}})],t.prototype,"questionFilter",void 0),J([(0,o.property)({onSet:function(e,t){t.updateItemsSurveyData()}})],t.prototype,"actionTypeFilter",void 0),t}(Ue),ho=function(){function e(e){this.creator=e,e.addPluginTab("logic",this),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)}))}return e.prototype.activate=function(){var e=this;this.model=new co(this.creator.survey,this.creator),this.filterQuestionAction.title=this.createFilterQuestionTitleUpdater(),this.filterQuestionAction.visible=!0,this.filterActionTypeAction.title=this.createFilterTypeTitleUpdater(),this.filterActionTypeAction.visible=!0,this.fastEntryAction&&(this.fastEntryAction.visible=!0,this.fastEntryAction.active=this.model.expressionEditorIsFastEntry,this.fastEntryAction.enabled=!1),this.model.onPropertyChanged.add((function(t,o){e.fastEntryAction&&"expressionEditorIsFastEntry"===o.name&&(e.fastEntryAction.active=e.model.expressionEditorIsFastEntry),e.fastEntryAction&&"expressionEditorCanShowBuilder"===o.name&&(e.fastEntryAction.enabled=e.model.expressionEditorCanShowBuilder)}))},e.prototype.createFilterTypeTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;t||(t="en");var o=e.model.actionTypeFilter,i=e.showAllActionTypesText;return o?e.model.getTypeByName(o).displayName:i}))},e.prototype.createFilterQuestionTitleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.locale;t||(t="en");var o=e.model.questionFilter,i=e.showAllQuestionsText;return o||i}))},e.prototype.update=function(){this.model&&this.model.update(this.creator.survey)},e.prototype.canDeactivateAsync=function(e){var t=this;this.model?this.model.tryLeaveUI((function(o){o?e():t.creator.notify(G.getString("ed.lg.expressionInvalid"),"error")})):e()},e.prototype.deactivate=function(){return this.disposeObjs(),!0},e.prototype.dispose=function(){this.disposeObjs()},e.prototype.disposeObjs=function(){this.filterActionTypeAction.title=void 0,this.filterQuestionAction.title=void 0,this.model&&(this.model.dispose(),this.model=void 0),this.filterQuestionAction.visible=!1,this.filterActionTypeAction.visible=!1,this.fastEntryAction&&(this.fastEntryAction.visible=!1)},e.prototype.createActions=function(){var e=this,t=[];return this.filterQuestionAction=(0,o.createDropdownActionModelAdvanced)({id:"svc-logic-filter-question",visible:!1},{items:[{id:null,title:this.showAllQuestionsText}],onSelectionChanged:function(t){e.model.questionFilter=t.id?t.id:""},allowSelection:!0,locOwner:this.creator},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var t=e.model.getUsedQuestions().map((function(t){return{id:t.name,title:e.creator.getObjectDisplayName(t,"logic-tab:question-filter","condition",t.name)}}));ee.sortItems(t,"title"),e.filterQuestionAction.popupModel.contentComponentData.model.setItems([{id:null,title:e.showAllQuestionsText}].concat(t))}}),t.push(this.filterQuestionAction),this.filterActionTypeAction=(0,o.createDropdownActionModelAdvanced)({id:"svc-logic-filter-actiontype",visible:!1},{items:[{id:null,title:this.showAllActionTypesText}],onSelectionChanged:function(t){e.model.actionTypeFilter=t.id?t.id:""},allowSelection:!0,locOwner:this.creator},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var t=e.model.getUsedActionTypes().map((function(e){return{id:e.name,title:e.displayName}}));ee.sortItems(t,"title"),e.filterActionTypeAction.popupModel.contentComponentData.model.setItems([{id:null,title:e.showAllActionTypesText}].concat(t))}}),t.push(this.filterActionTypeAction),this.creator.allowEditExpressionsInTextEditor&&(this.fastEntryAction=new o.Action({id:"svc-logic-fast-entry",iconName:"icon-fast-entry",locTitleName:"pe.fastEntry",visible:!1,component:"sv-action-bar-item",action:function(){e.model.toggleExpressionEditorIsFastEntry()}}),t.push(this.fastEntryAction)),t},Object.defineProperty(e.prototype,"showAllQuestionsText",{get:function(){return ke("showAllQuestions")},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"showAllActionTypesText",{get:function(){return ke("showAllActionTypes")},enumerable:!1,configurable:!0}),e}(),go=function(){function e(){this._ignoreChanges=!1,this._isExecuting=!1,this._preparingTransaction=null,this._transactions=[],this._currentTransactionIndex=-1,this.transactionCounter=0}return e.prototype.onPropertyValueChanged=function(e,t,o,i,n){if(!Ze.isCopyObject(i)&&!this.isIgnoring&&!0!==i.ignoreUndoRedo){var r=this._preparingTransaction,a=n?new yo(e,i,n):new fo(e,t,o,i);if(!r)return(r=new mo(e)).addAction(a),void this._addTransaction(r);r.addAction(a)}},e.prototype.isCorrectProperty=function(e,t){var i=o.Serializer.getOriginalProperty(e,t);return!!i&&i.isSerializable},e.prototype.tryMergeTransaction=function(e,t,o){if("name"===t)return!1;var i=this._getCurrentTransaction();return!(!i||0==i.actions.length)&&i.actions[i.actions.length-1].tryMerge(e,t,o)},e.prototype.isCopyObject=function(e){},e.prototype._cutOffTail=function(){this._currentTransactionIndex+1!==this._transactions.length&&(this._transactions.length=this._currentTransactionIndex+1)},Object.defineProperty(e.prototype,"isIgnoring",{get:function(){return this._ignoreChanges||this._isExecuting},enumerable:!1,configurable:!0}),e.prototype._addTransaction=function(e){e.isEmpty()||(this._cutOffTail(),this._transactions[this._currentTransactionIndex]!==e&&(this._transactions.push(e),this._currentTransactionIndex++),this.canUndoRedoCallback())},e.prototype._getCurrentTransaction=function(){var e=this._currentTransactionIndex;return this._transactions[e]},e.prototype._getNextTransaction=function(){var e=this._currentTransactionIndex;return this._transactions[e+1]},e.prototype.notifyChangesFinished=function(e,t){void 0===t&&(t=!1),e.actions.length>0&&this.changesFinishedCallback&&this.changesFinishedCallback(e.actions,t)},e.prototype.canUndoRedoCallback=function(){},e.prototype.startTransaction=function(e){this.isIgnoring||(this.transactionCounter++,this._preparingTransaction||(this._preparingTransaction=new mo(e)))},e.prototype.stopTransaction=function(){this.isIgnoring||(this.transactionCounter>0&&this.transactionCounter--,!this._preparingTransaction||this.transactionCounter>0||(this._addTransaction(this._preparingTransaction),0===this.transactionCounter&&this.notifyChangesFinished(this._preparingTransaction),this._preparingTransaction=null))},e.prototype.setUndoCallbackForTransaction=function(e){this._preparingTransaction&&(this._preparingTransaction.undoCallback=e)},Object.defineProperty(e.prototype,"isProcessingUndoRedo",{get:function(){return!0===this._isExecuting},enumerable:!1,configurable:!0}),e.prototype.canUndo=function(){return!!this._getCurrentTransaction()},e.prototype.undo=function(){var e=this._getCurrentTransaction();this.canUndo()&&(this._isExecuting=!0,e.rollback(),this._isExecuting=!1,this._currentTransactionIndex--,this.canUndoRedoCallback(),this.notifyChangesFinished(e,!0))},e.prototype.canRedo=function(){return!!this._getNextTransaction()},e.prototype.redo=function(){var e=this._getNextTransaction();this.canRedo()&&(this._isExecuting=!0,e.apply(),this._isExecuting=!1,this._currentTransactionIndex++,this.canUndoRedoCallback(),this.notifyChangesFinished(e))},e.prototype.suspend=function(){this._ignoreChanges=!0},e.prototype.resume=function(){this._ignoreChanges=!1},e}(),mo=function(){function e(e){this._name=e,this._actions=[],this.undoCallback=function(){}}return e.prototype.apply=function(){for(var e=this._actions,t=0;t<e.length;t++)e[t].apply()},e.prototype.rollback=function(){for(var e=this._actions,t=e.length-1;t>=0;t--)e[t].rollback();this.undoCallback()},e.prototype.addAction=function(e){this._actions.push(e)},e.prototype.isEmpty=function(){return 0===this._actions.length},Object.defineProperty(e.prototype,"actions",{get:function(){return this._actions},enumerable:!1,configurable:!0}),e}(),fo=function(){function e(e,t,o,i){this._propertyName=e,this._oldValue=t,this._newValue=o,this._sender=i,this.tickCount=(new Date).getTime()}return e.prototype.apply=function(){this._sender[this._propertyName]=this._newValue},e.prototype.rollback=function(){this._sender[this._propertyName]=this._oldValue},e.prototype.getChanges=function(e){return void 0===e&&(e=!1),{object:this._sender,propertyName:this._propertyName,oldValue:e?this._newValue:this._oldValue,newValue:e?this._oldValue:this._newValue}},e.prototype.getDeletedElement=function(e){},e.prototype.getInsertedElement=function(e){},e.prototype.getIndex=function(){return-1},e.prototype.tryMerge=function(t,i,n){if(t!==this._sender||i!==this._propertyName||n==this._oldValue)return!1;var r=o.Serializer.getOriginalProperty(t,i);return!(!r||"string"!==r.type&&"text"!==r.type||(new Date).getTime()-this.tickCount>e.maximumMergeTime||(this._newValue=n,0))},e.maximumMergeTime=1e3,e}(),yo=function(){function e(e,t,o){this._propertyName=e,this._sender=t,this._index=0,this._itemsToAdd=[],this._deletedItems=[],this.survey=t.getSurvey(),this._index=o.index,this._itemsToAdd=o.itemsToAdd,this._deletedItems=o.deletedItems}return e.prototype.apply=function(){this.rollback()},e.prototype.rollback=function(){if(this._sender=this.getSenderElement(),this._sender){var e=this._sender[this._propertyName],t=this._index,o=this._itemsToAdd.length,i=this.getItemsToAdd();this._deletedItems=e.splice.apply(e,[t,o].concat(i)),this._itemsToAdd=[].concat(i)}},e.prototype.getChanges=function(){return{object:this._sender,propertyName:this._propertyName,oldValue:this._deletedItems,newValue:this._itemsToAdd}},e.prototype.getDeletedElement=function(e){return this.getMovedElement(this._deletedItems,this._itemsToAdd,e)},e.prototype.getInsertedElement=function(e){return this.getMovedElement(this._itemsToAdd,this._deletedItems,e)},e.prototype.getIndex=function(){return this._index},e.prototype.getMovedElement=function(e,t,o){var i=o?t:e;if(Array.isArray(i)&&1===i.length)return i[0]},e.prototype.tryMerge=function(e,t,o){return!1},e.prototype.getSenderElement=function(){if(!this._sender.isDisposed||!this.survey)return this._sender;var e=this._sender.name;return!0===this._sender.isPage?0===this.survey.pages.length?this.survey.addNewPage():this.survey.getPageByName(e):!0===this._sender.isPanel?this.survey.getPanelByName(e):!0===this._sender.isQuestion?this.survey.getQuestionByName(e):this._sender},e.prototype.getItemsToAdd=function(){for(var e=[],t=0;t<this._deletedItems.length;t++){var i=this._deletedItems[t];if(i.isDisposed&&i.getType){var n=i.toJSON();(i=o.Serializer.createClass(i.getType())).fromJSON(n)}e.push(i)}return e},e}(),vo=function(e){function t(t){var i=e.call(this)||this;return i.creator=t,i.undoRedoManager=void 0,i.onBeforeUndo=new o.EventBase,i.onBeforeRedo=new o.EventBase,i.updateSurvey(),i}return K(t,e),t.prototype.onSurveyPropertyValueChangedCallback=function(e,t,o,i,n){this.undoRedoManager&&this.undoRedoManager.isCorrectProperty(i,e)&&(this.undoRedoManager.tryMergeTransaction(i,e,o)?this.creator.notifySurveyPropertyChanged({name:e,target:i,oldValue:t,newValue:o}):(this.undoRedoManager.startTransaction(e+" changed"),this.undoRedoManager.onPropertyValueChanged(e,t,o,i,n),this.creator.updateElementsOnLocaleChanged(i,e),this.creator.updateConditionsOnNameChanged(i,e,t),this.undoRedoManager.stopTransaction()))},t.prototype.updateSurvey=function(){var e=this,t=this.creator.survey;t&&(t.onPropertyValueChangedCallback=function(t,o,i,n,r){e.onSurveyPropertyValueChangedCallback(t,o,i,n,r)}),this.undoRedoManager=new go,this.undoRedoManager.changesFinishedCallback=function(t,o){if(!e.notifySurveyMoveItem(t,o))for(var i=t.length-1;i>=0;i--){var n=t[i];if(n){var r=n.getChanges(o);e.creator.notifySurveyPropertyChanged({name:r.propertyName,target:r.object,oldValue:r.oldValue,newValue:r.newValue})}}},this.undoRedoManager.canUndoRedoCallback=function(){e.updateUndeRedoActions()}},t.prototype.notifySurveyMoveItem=function(e,t){e.length;var o=e[0],i=e[1];if(!o||!i)return!1;var n=o.getChanges(t),r=i.getChanges(t);if(n.object!==r.object||n.propertyName!==r.propertyName)return!1;var a=o.getDeletedElement(t),s=o.getInsertedElement(t),l=i.getDeletedElement(t),u=i.getInsertedElement(t);if(a===s||a!==u&&s!==l)return!1;var p=a?o.getIndex():i.getIndex(),c=s?o.getIndex():i.getIndex();return this.creator.notifySurveyItemMoved({arrayName:n.propertyName,parent:n.object,element:a||s,indexFrom:t?c:p,indexTo:t?p:c}),!0},t.prototype.selectElementAfterUndo=function(){this.selectElementAfterUndoCore(this.creator.selectedElement)},t.prototype.selectElementAfterUndoCore=function(e){!e||e.isDisposed||!e.getSurvey()||this.creator.isObjQuestion(e)&&!e.parent?this.creator.selectElement(this.creator.survey):this.creator.selectElement(e)},t.prototype.undo=function(){if(this.undoRedoManager){this.undoRedoManager.suspend();var e={canUndo:this.undoRedoManager.canUndo()};this.onBeforeUndo.fire(this.creator,e),this.creator.onBeforeUndo.fire(this.creator,e),e.canUndo&&(this.undoRedoManager.undo(),this.selectElementAfterUndo()),this.undoRedoManager.resume()}},t.prototype.redo=function(){if(this.undoRedoManager){var e={canRedo:this.undoRedoManager.canRedo()};this.onBeforeRedo.fire(this.creator,e),this.creator.onBeforeRedo.fire(this.creator,e),e.canRedo&&(this.undoRedoManager.redo(),this.selectElementAfterUndo())}},t.prototype.startTransaction=function(e){void 0===e&&(e=""),this.undoRedoManager&&this.undoRedoManager.startTransaction(e)},t.prototype.stopTransaction=function(){this.undoRedoManager&&this.undoRedoManager.stopTransaction()},t.prototype.createActions=function(){var e=this,t=[];return this.undoAction=new o.Action({id:"action-undo",iconName:"icon-undo",locTitleName:"ed.undo",showTitle:!1,visible:new o.ComputedUpdater((function(){return"designer"===e.creator.activeTab})),needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),action:function(){return e.undo()}}),this.redoAction=new o.Action({id:"action-redo",iconName:"icon-redo",locTitleName:"ed.redo",showTitle:!1,visible:new o.ComputedUpdater((function(){return"designer"===e.creator.activeTab})),action:function(){return e.redo()}}),t.push(this.undoAction),t.push(this.redoAction),this.updateUndeRedoActions(),t},t.prototype.updateUndeRedoActions=function(){this.undoAction.enabled=this.undoRedoManager.canUndo(),this.redoAction.enabled=this.undoRedoManager.canRedo()},J([(0,o.property)()],t.prototype,"undoRedoManager",void 0),t}(o.Base),bo=function(){function e(e){var t=this;this.creator=e,this.model=void 0,this.model=new vo(e),this.model.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),e.registerShortcut("undo",{affectedTab:"designer",hotKey:{ctrlKey:!0,keyCode:90},macOsHotkey:{keyCode:90},execute:function(){return t.model.undo()}}),e.registerShortcut("redo",{affectedTab:"designer",hotKey:{ctrlKey:!0,keyCode:89},macOsHotkey:{keyCode:89},execute:function(){return t.model.redo()}})}return e.prototype.activate=function(){},e.prototype.deactivate=function(){return!0},e.prototype.update=function(){},e.prototype.addFooterActions=function(){this.model.undoAction&&this.creator.footerToolbar.actions.splice(2,0,this.model.undoAction),this.model.redoAction&&this.creator.footerToolbar.actions.splice(3,0,this.model.redoAction)},e}();function Co(e,t){return void 0===t&&(t="undoRedoManager"),function(o,i,n){var r=n.value;return n.value=function(){for(var o=[],n=0;n<arguments.length;n++)o[n]=arguments[n];var a=this[t];try{return a&&a.startTransaction(e||i),r.apply(this,o)}finally{a&&a.stopTransaction()}},n}}function wo(e){return void 0===e&&(e="undoRedoManager"),function(t,o,i){var n=i.value;return i.value=function(){for(var t=[],o=0;o<arguments.length;o++)t[o]=arguments[o];var i=this[e];try{return i&&i.suspend(),n.apply(this,t)}finally{i&&i.resume()}},i}}var xo=function(e){function t(t,o,i,n){var r=e.call(this,{id:"sv_item_selector_"+t.toString(),title:i})||this;return r.data=o,r.level=n,r}return K(t,e),t.prototype.hasText=function(e){return!e||(this.textInLow||(this.textInLow=this.title.toLocaleLowerCase()),this.textInLow.indexOf(e)>-1)},t}(o.Action),To=function(){function e(e,t,o){void 0===o&&(o=void 0),this.creator=e,this.getObjectDisplayName=o,this.surveyValue=t,this.rebuild()}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"items",{get:function(){return this.itemsValue},enumerable:!1,configurable:!0}),e.prototype.getItemByObj=function(e){for(var t=this.items,o=0;o<t.length;o++)if(t[o].data===e)return t[o];return null},e.prototype.filterByText=function(e){this.filteredTextInLow=e?e.toLocaleLowerCase():"",this.updateItemsVisibility()},e.prototype.rebuild=function(){var e=[];this.deepestLevel=0;var t=this.createItem(this.survey,null);e.push(t);for(var o=0;o<this.survey.pages.length;o++){var i=this.survey.pages[o],n=t;if(!this.creator||"single"!==this.creator.pageEditMode){var r=this.createItem(i,t);e.push(r),n=r}this.buildElements(e,this.getElements(i),n)}this.itemsValue=e},e.prototype.updateItemsVisibility=function(){for(var e=this.deepestLevel;e>=0;e--)this.updateItemsLevelVisibility(e)},e.prototype.updateItemsLevelVisibility=function(e){for(var t=0;t<this.items.length;t++){var o=this.items[t];o.level===e&&(o.visible=this.hasVisibleChildren(t)||o.hasText(this.filteredTextInLow))}},e.prototype.hasVisibleChildren=function(e){for(var t=this.items[e].level,o=e+1;o<this.items.length;o++){if(this.items[o].level<=t)return!1;if(this.items[o].visible)return!0}return!1},e.prototype.getElements=function(e){return ee.getElements(e)},e.prototype.buildElements=function(e,t,o){for(var i=0;i<t.length;i++){var n=t[i],r=this.createItem(n,o);e.push(r),this.buildElements(e,this.getElements(n),r)}},e.prototype.createItem=function(t,o){var i=new xo(e.uniqueId++,t,this.getText(t),null!=o?o.level+1:0);return i.level>this.deepestLevel&&(this.deepestLevel=i.level),i},e.prototype.getText=function(e){return this.getObjectDisplayName?this.getObjectDisplayName(e,"property-grid-header:element-list","property-grid",void 0):ee.getObjectName(e,!1)},e.uniqueId=0,e}(),So=function(e){function t(t,o){void 0===o&&(o=void 0);var i=e.call(this)||this;return i.creator=t,i.getObjectDisplayName=o,i}return K(t,e),Object.defineProperty(t.prototype,"list",{get:function(){return this.listModelValue},enumerable:!1,configurable:!0}),t.prototype.show=function(e,t,i){var n=this;this.selector=new To(this.creator,e,this.getObjectDisplayName);var r=this.selector.getItemByObj(t);this.listModelValue?(this.listModelValue.setItems(this.selector.items),this.listModelValue.selectedItem=r):(this.listModelValue=new o.ListModel({items:this.selector.items,onSelectionChanged:function(e){i(e.data)},allowSelection:!0,selectedItem:r}),this.listModelValue.setOnFilterStringChangedCallback((function(e){n.selector.filterByText(e)}))),this.isVisible=!0},t.prototype.refresh=function(){this.listModelValue.refresh()},J([(0,o.property)()],t.prototype,"isVisible",void 0),t}(o.Base),Po=function(e){function t(t,o){var n=e.call(this)||this;return n.propertyGridModel=t,n.creator=o,n.searchManager=new me,n.searchEnabled=i.propertyGrid.enableSearch,n.selectedElementName=n.getTitle(),n.propertyGridModel.objValueChangedCallback=function(){n.onSurveyChanged()},n.propertyGridModel.changedFromActionCallback=function(e,t){n.selectionController&&n.selectionController.selectFromAction(e,t)},n.initActions(),n.creator.onPropertyChanged.add((function(e,t){"sidebarLocation"===t.name&&(n.selectorPopupModel.horizontalPosition="right"==n.creator.sidebarLocation?"left":"right")})),n.onSurveyChanged(),n}return K(t,e),Object.defineProperty(t.prototype,"rootCss",{get:function(){return(new o.CssClassBuilder).append("spg-container").append("spg-container_search",this.searchEnabled).toString()},enumerable:!1,configurable:!0}),t.prototype.onPropertyValueChanged=function(t,o,i){e.prototype.onPropertyValueChanged.call(this,t,o,i),this.nextSelectionAction&&"hasNext"===t&&(this.nextSelectionAction.enabled=this.hasNext),this.prevSelectionAction&&"hasPrev"===t&&(this.prevSelectionAction.enabled=this.hasPrev)},Object.defineProperty(t.prototype,"selectionController",{get:function(){return this.creator.selectionHistoryController},enumerable:!1,configurable:!0}),t.prototype.onSurveyChanged=function(){var e=this;this.survey=this.propertyGridModel.survey,this.searchManager.setSurvey(this.survey),this.survey&&this.survey.onValueChanged.add((function(t,o){"name"!=o.name&&"title"!=o.name||e.updateTitle()})),this.updateTitle(),this.selectionController&&(this.hasPrev=this.selectionController.hasPrev,this.hasNext=this.selectionController.hasNext)},t.prototype.updateTitle=function(){var e=this.getTitle();this.selectedElementName=e,this.objectSelectionAction.title=this.selectedElementName},t.prototype.getTitle=function(){var e=this.getSelectedObj();if(!e)return"";var t=ee.getObjectName(e,this.propertyGridModel.options.showObjectTitles);return this.propertyGridModel.options.getObjectDisplayName(e,"property-grid-header:selected-element","property-grid-title",t)},t.prototype.getSelectedObj=function(){return this.propertyGridModel.obj},t.prototype.initActions=function(){var e=this;i.propertyGrid.showNavigationButtons&&(this.prevSelectionAction=new o.Action({id:"svd-grid-history-prev",iconName:"icon-arrow-left",component:"sv-action-bar-item",title:Z("ed.prevSelected"),showTitle:!1,enabled:this.hasPrev,action:function(){e.selectionController.prev()}}),this.nextSelectionAction=new o.Action({id:"svd-grid-history-next",iconName:"icon-arrow-right",component:"sv-action-bar-item",title:Z("ed.nextSelected"),showTitle:!1,enabled:this.hasNext,action:function(){e.selectionController.next()}})),this.createObjectSwitcherAction()},t.prototype.createObjectSwitcherAction=function(){var e=this,t=new So(this.creator,(function(t,o,i,n){return e.propertyGridModel.options.getObjectDisplayName(t,o,i,n)}));this.selectorPopupModel=new o.PopupModel("svc-object-selector",{model:t},{verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"}),this.selectorPopupModel.cssClass+=" svc-object-selector",this.selectorPopupModel.displayMode=this.creator.isTouch?"overlay":"popup",this.selectorPopupModel.registerPropertyChangedHandlers(["isVisible"],(function(){e.selectorPopupModel.isVisible?e.objectSelectionAction.pressed=!0:e.objectSelectionAction.pressed=!1})),this.objectSelectionAction=new kt({id:"svd-grid-object-selector",title:this.selectedElementName,css:"sv-action--object-selector sv-action-bar-item--secondary",component:"sv-action-bar-item-dropdown",disableHide:!0,pressed:!1,action:function(){t.show(e.selectionController.creator.survey,e.propertyGridModel.obj,(function(t){e.selectionController.selectFromAction(t,"name"),e.selectorPopupModel.hide()})),e.selectorPopupModel.show(),t.list.scrollToSelectedItem()},popupModel:this.selectorPopupModel}),this.objectSelectionAction.contentType="text-description-vertical"},t.prototype.dispose=function(){this.searchManager.dispose(),this.nextSelectionAction.dispose(),this.prevSelectionAction.dispose(),this.objectSelectionAction.dispose(),this.selectorPopupModel.dispose(),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"hasPrev",void 0),J([(0,o.property)()],t.prototype,"hasNext",void 0),J([(0,o.property)()],t.prototype,"survey",void 0),J([(0,o.property)()],t.prototype,"selectedElementName",void 0),J([(0,o.property)({onSet:function(e,t){t.searchManager.isVisible=e}})],t.prototype,"searchEnabled",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),t}(o.Base),Eo=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.onPagesChanged=o.addEvent(),o.onCurrentPageChanged=o.addEvent(),o.currentPageChangedFunc=function(e,t){o.page2Display=o.survey.currentPage,o.onCurrentPageChanged.fire(o,{})},o.onSurveyChanged(),o}return K(t,e),Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pages",{get:function(){return this.survey.pages},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPage",{get:function(){return this.survey.currentPage},set:function(e){this.survey.currentPage=e,this.page2Display=e},enumerable:!1,configurable:!0}),t.prototype.selectPage=function(e){this.currentPage=e,this.creator.selectElement(e)},t.prototype.getDisplayName=function(e){return e?this.creator.getObjectDisplayName(e,"page-selector"):""},t.prototype.raisePagesChanged=function(){this.page2Display=this.survey.currentPage,this.onPagesChanged.fire(this,{})},t.prototype.onSurveyChanged=function(){this.removeFunctions(),this.surveyValue=this.creator.survey,this.surveyValue&&(this.raisePagesChanged(),this.page2Display=this.survey.currentPage,this.surveyValue.onCurrentPageChanged.add(this.currentPageChangedFunc))},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.removeFunctions()},t.prototype.removeFunctions=function(){this.surveyValue&&!this.surveyValue.isDisposed&&this.surveyValue.onCurrentPageChanged.remove(this.currentPageChangedFunc)},J([(0,o.property)()],t.prototype,"page2Display",void 0),t}(o.Base);r(5876);var Vo=o.settings.allowShowEmptyTitleInDesignMode,Io=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.pagesControllerValue=new Eo(t),o.initToolbar(),o.initSurvey(),o}return K(t,e),Object.defineProperty(t.prototype,"displayPageDropTarget",{get:function(){return this.pagesController.page2Display===this.newPage?"newGhostPage":this.pagesController.page2Display.name},enumerable:!1,configurable:!0}),t.prototype.createNewPage=function(){var e=this;if(!this.creator.canAddPage())return null;var t=this.survey.createNewPage("");t.ignoreUndoRedo=!0,this.creator.setNewNames(t),t.onFirstRendering(),t.updateCustomWidgets(),t.setWasShown(!0),t.setSurveyImpl(this.survey),t.updateElementCss();var o=function(i,n){"elements"===n.name&&t.elements.length>0&&e.creator.addPage(t,!0,(function(){return t.onPropertyChanged.remove(o),t.showTitle=!0,t.showDescription=!0,delete t.ignoreUndoRedo,!(e.survey.pages.indexOf(t)>-1)}))};return t.num=this.survey.pages.length+1,t.onPropertyChanged.add(o),Ft.newGhostPage=t,t},Object.defineProperty(t.prototype,"canShowNewPage",{get:function(){return!(!this.survey||"single"===this.creator.pageEditMode||!this.creator.allowModifyPages)},enumerable:!1,configurable:!0}),t.prototype.isModifiedPage=function(e){return Object.keys(e.toJSON()).filter((function(e){return"name"!==e})).length>0},t.prototype.initToolbar=function(){var e=this;this.actionContainer=new o.ActionContainer;var t=function(t){e.creator.onSurfaceToolbarActionExecuted.fire(e.creator,{action:t})};this.actionContainer.cssClasses={root:"sv-action-bar",defaultSizeMode:"",smallSizeMode:"",item:"svc-page-navigator__selector",itemWithTitle:"",itemAsIcon:"",itemActive:"",itemPressed:"",itemIcon:"svc-page-navigator__navigator-icon",itemTitleWithIcon:""},this.actionContainer.setItems([{id:"collapseAll",locTooltipName:"ed.collapseAllTooltip",iconName:"icon-collapseall-24x24",action:t},{id:"expandAll",locTooltipName:"ed.expandAllTooltip",iconName:"icon-expandall-24x24",action:t}])},Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"pagesController",{get:function(){return this.pagesControllerValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isToolboxVisible",{get:function(){return this.creator.showToolbox&&("right"===this.creator.toolboxLocation||"left"===this.creator.toolboxLocation)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceHolderMobile"):Z("ed.surveyPlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderTitleText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceholderTitleMobile"):Z("ed.surveyPlaceholderTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderDescriptionText",{get:function(){return this.creator.isMobileView?Z("ed.surveyPlaceholderDescriptionMobile"):Z("ed.surveyPlaceholderDescription")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasToolbar",{get:function(){return"never"!=this.creator.expandCollapseButtonVisibility},enumerable:!1,configurable:!0}),t.prototype.onDesignerSurveyPropertyChanged=function(e,t){if(e&&!this.isUpdatingNewPage){if(this.isUpdatingNewPage=!0,"elements"===t&&e.isDescendantOf("page")){var o=!1;0===e.elements.length&&(o=this.checkLastPageToDelete()),this.checkNewPage(o)}"pages"===t&&e.isDescendantOf("survey")&&this.checkNewPage(!0),this.isUpdatingNewPage=!1}},t.prototype.calculateDesignerCss=function(){return this.survey.css.container+" "+this.survey.css.container+"--"+this.survey.calculatedWidthMode},t.prototype.initSurvey=function(){var e=this;this.survey&&(this.showNewPage=!1,this.newPage=void 0,this.checkNewPage(!1),this.cssUpdater&&this.cssUpdater.dispose(),this.cssUpdater=new o.ComputedUpdater((function(){return e.calculateDesignerCss()})),this.designerCss=this.cssUpdater,this.pagesController.onSurveyChanged())},t.prototype.checkNewPage=function(e){var t=0===this.survey.getAllQuestions().length&&0===this.survey.pageCount;if(this.showPlaceholder=t,this.pageCount=this.survey.pageCount,this.showPlaceholder||this.canShowNewPage){var o=this.survey.pages;(!this.newPage||o.length>0&&this.newPage===o[o.length-1])&&(this.newPage=this.createNewPage(),this.showNewPage=!!this.newPage),this.newPage&&(this.newPage.showTitle=!t,this.newPage.showDescription=!t)}else this.showNewPage=!1,this.newPage=void 0;e&&(this.newPage&&(this.newPage.num=this.survey.pages.length+1,this.newPage.startLoadingFromJson(),this.newPage.name=ee.getNewPageName(this.survey.pages),this.newPage.endLoadingFromJson()),this.pagesController.raisePagesChanged())},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.cssUpdater&&this.cssUpdater.dispose()},t.prototype.checkLastPageToDelete=function(){if(0===this.survey.pageCount||this.survey.isQuestionDragging)return!1;var e=this.survey.pages[this.survey.pageCount-1];return!(e.elements.length>0||e.isConverting||ee.isPagePropertiesAreModified(e)||(e.delete(),0===this.survey.pageCount&&this.creator.selectElement(this.survey),0))},t.prototype.clickDesigner=function(){this.creator.selectedElement=this.creator.survey},t.prototype.getRootCss=function(){var e=this.survey.css.root;return(this.creator.showPageNavigator&&this.survey.pageCount>1||"bypage"===this.creator.pageEditMode||this.hasToolbar)&&(e+=" svc-tab-designer--with-page-navigator"),this.showPlaceholder&&(e+=" svc-tab-designer--with-place-holder"),e+" svc-tab-designer--"+this.creator.pageEditMode+"-mode"},J([(0,o.property)()],t.prototype,"newPage",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showNewPage",void 0),J([(0,o.property)()],t.prototype,"pageCount",void 0),J([(0,o.property)()],t.prototype,"designerCss",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),t}(o.Base),Oo=function(){this.collapsed=!1},Ao=function(){function e(){var e=this;this.elementState={},this.pageState={},this.onQuestionAddedHandler=function(t,o){e.createElementState(o.question,e.isSuspended)},this.onPageAddedHandler=function(t,o){e.createElementState(o.page,e.isSuspended)},this.onPanelAddedHandler=function(t,o){e.createElementState(o.panel,e.isSuspended)},this._suspendCounter=0}return e.prototype.getStateMapForElement=function(e){return e&&e.isPage?this.pageState:this.elementState},e.prototype.initForSurvey=function(e){e.onQuestionAdded.add(this.onQuestionAddedHandler),e.onPageAdded.add(this.onPageAddedHandler),e.onPanelAdded.add(this.onPanelAddedHandler)},e.prototype.initForElement=function(e){if(e){var t=this.getStateMapForElement(e);e.registerFunctionOnPropertyValueChanged("name",(function(o){delete t[e.name],t[o]=new Oo}),"designerStateManager")}},e.prototype.getElementState=function(e){return this.createElementState(e,!0)},e.prototype.createElementState=function(e,t){var o=this.getStateMapForElement(e),i=e.name;if(t){var n=o[i];if(n)return n}var r=new Oo;return o[i]=r,this.onInitElementStateCallback&&this.onInitElementStateCallback(e,r),r},e.prototype.suspend=function(){this._suspendCounter++},e.prototype.release=function(){this._suspendCounter--},Object.defineProperty(e.prototype,"isSuspended",{get:function(){return this._suspendCounter>0},enumerable:!1,configurable:!0}),e}(),No=function(e){function t(t){var i=e.call(this)||this;return i.sidePanel=t,i.topToolbar=new o.ActionContainer,i.bottomToolbar=new o.ActionContainer,i.createToggleAction(),i.updateExpandCollapseAction(),i.sidePanel.registerFunctionOnPropertyValueChanged("_visible",(function(){i.updateExpandCollapseAction()})),i}return K(t,e),t.prototype.updateExpandCollapseAction=function(){this.expandCollapseAction.iconName=this.sidePanel.visible?"icon-collapse-panel":"icon-expand-panel",this.expandCollapseAction.css=this.sidePanel.visible?"svd-grid-hide":"svd-grid-expand",this.expandCollapseAction.locTitleName=this.sidePanel.visible?"ed.hidePanel":"ed.showPanel"},t.prototype.createToggleAction=function(){var e=this;this.expandCollapseAction=new kt({id:"svd-grid-hide",showTitle:!1,visible:!0,pressed:!1,action:function(){e.sidePanel.visible?e.sidePanel.collapseSidebar():e.sidePanel.expandSidebar()}})},Object.defineProperty(t.prototype,"sideBarClassName",{get:function(){return(new o.CssClassBuilder).append("svc-sidebar-tabs").append("svc-sidebar-tabs--collapsed",!this.sidePanel.renderedIsVisible).toString()},enumerable:!1,configurable:!0}),t}(o.Base),Lo={appearance:"icon-pg-v1/pg-appearance-24x24",background:"icon-pg-v1/pg-background-24x24",columns:"icon-pg-v1/pg-columns-24x24",logic:"icon-pg-v1/pg-conditions-24x24",data:"icon-pg-v1/pg-data-24x24",design:"icon-pg-v1/pg-design-24x24",general:"icon-pg-v1/pg-general-24x24",header:"icon-pg-v1/pg-header-24x24",language:"icon-pg-v1/pg-language-24x24",layout:"icon-pg-v1/pg-layout-24x24",logo:"icon-pg-v1/pg-logo-24x24",navigation:"icon-pg-v1/pg-navigation-24x24",pages:"icon-pg-v1/pg-pages-24x24",question:"icon-pg-v1/pg-questiondesign-24x24",timer:"icon-pg-v1/pg-quiz-24x24",rows:"icon-pg-v1/pg-rows-24x24",specific:"icon-pg-v1/pg-specific-24x24",showOnCompleted:"icon-pg-v1/pg-thankyyoupage-24x24",themes:"icon-pg-v1/pg-themes-24x24",totals:"icon-pg-v1/pg-totals-24x24",validation:"icon-pg-v1/pg-validation-24x24",undefined:"icon-pg-v1/pg-undefined-24x24"},_o={creatorTheme:{properties:[{name:"themeName",index:1},{name:"--sjs-special-background",index:10},{name:"--sjs-primary-background-500",index:20},{name:"--sjs-secondary-background-500",index:30},{name:"fontScale",index:40},{name:"scale",index:50},{name:"surfaceScale",index:60}]}},Mo={autoGenerateProperties:!0,classes:_o},Do=function(){function e(){}return e.definition=_o,e}(),ko=["sc2020"],jo={sc2020:{themeName:"sc2020",cssVariables:{"--sjs-special-background":"#F3F3F3FF","--sjs-primary-background-500":"#19B394FF","--sjs-primary-background-10":"#19B3941A","--sjs-primary-background-400":"#14A48BFF","--sjs-secondary-background-500":"#FF9814FF","--sjs-secondary-background-25":"#FF981440","--sjs-secondary-background-10":"#FF98141A","--ctr-surface-background-color":"var(--sjs-special-background)"}}},Ro=r(5271);Object.keys(Ro||{}).forEach((function(e){var t=Ro[e];-1===ko.indexOf(t.themeName)&&ko.push(t.themeName),jo[t.themeName]=t}));var Bo=function(e){function t(){var i=e.call(this)||this;return i.initialCssVariables={},i.themeCssVariablesChanges={},i.unitDictionary={"--ctr-font-unit":8,"--ctr-line-height-unit":8,"--ctr-size-unit":8,"--ctr-spacing-unit":8,"--ctr-corner-radius-unit":8,"--ctr-stroke-unit":1,"--ctr-surface-base-unit":8},i.themeName=t.defautlThemeName,i.isLight=!0,i.onThemeSelected=new o.EventBase,i.onThemePropertyChanged=new o.EventBase,i.blockThemeChangedNotifications=0,i.onPropertyValueChangedCallback=function(e,t,o,n,r){i.onThemePropertyValueChangedCallback(e,t,o,n,r)},i}return K(t,e),t.prototype.getType=function(){return"creatortheme"},Object.defineProperty(t.prototype,"cssVariables",{get:function(){return this.toJSON().cssVariables||{}},enumerable:!1,configurable:!0}),t.prototype.setThemeCssVariablesChanges=function(e,t){this.themeCssVariablesChanges[e]!==t&&(this.themeCssVariablesChanges[e]=t,this.onThemePropertyChanged.fire(this,{name:e,value:t}))},t.prototype.onThemePropertyValueChangedCallback=function(e,t,o,i,n){this.blockThemeChangedNotifications>0||("themeName"===e?(this.loadTheme({themeName:o}),this.onThemeSelected.fire(this,{theme:this.toJSON()})):0===e.indexOf("--")?this.setThemeCssVariablesChanges(e,o):"fontScale"!=e&&"scale"!=e&&"surfaceScale"!=e||this.scalePropertiesChanged(e,o))},t.prototype.scalePropertiesChanged=function(e,t){"fontScale"==e?(this.scalingProperties("--ctr-font-unit",t),this.scalingProperties("--ctr-line-height-unit",t)):"scale"==e?(this.scalingProperties("--ctr-size-unit",t),this.scalingProperties("--ctr-spacing-unit",t),this.scalingProperties("--ctr-corner-radius-unit",t)):"surfaceScale"==e&&this.scalingProperties("--ctr-surface-base-unit",t)},t.prototype.scalingProperties=function(e,t){var o=this.unitDictionary[e];this.setThemeCssVariablesChanges(e,t*o/100+"px")},t.prototype.scaleValue=function(e,t){var o=this.unitDictionary[e];this[e]=t*o/100+"px"},t.prototype.scaleCssVariables=function(){void 0!==this.fontScale&&(this.scaleValue("--ctr-font-unit",this.fontScale),this.scaleValue("--ctr-line-height-unit",this.fontScale)),void 0!==this.scale&&(this.scaleValue("--ctr-size-unit",this.scale),this.scaleValue("--ctr-spacing-unit",this.scale),this.scaleValue("--ctr-corner-radius-unit",this.scale)),void 0!==this.surfaceScale&&this.scaleValue("--ctr-surface-base-unit",this.surfaceScale)},t.prototype.getScaleFactor=function(e){return this[e]?l(100*parseFloat(this[e])/this.unitDictionary[e]):void 0},t.prototype.updateScaleProperties=function(){this.blockThemeChangedNotifications+=1;try{this.fontScale=this.getScaleFactor("--ctr-font-unit"),this.scale=this.getScaleFactor("--ctr-size-unit"),this.surfaceScale=this.getScaleFactor("--ctr-surface-base-unit")}finally{this.blockThemeChangedNotifications-=1}},t.prototype.loadTheme=function(e){void 0===e&&(e={}),this.blockThemeChangedNotifications+=1;try{var o=jo[e.themeName]||{};this.themeName=e.themeName||o.themeName||t.defautlThemeName;var i={};q(i,o.cssVariables||{}),q(i,e.cssVariables||{},this.themeCssVariablesChanges);var n={};q(n,o,e,{cssVariables:i,themeName:this.themeName}),this.fromJSON(n)}finally{this.blockThemeChangedNotifications-=1}},t.prototype.fromJSON=function(t,o){if(t){var i={};q(i,t),delete i.cssVariables,e.prototype.fromJSON.call(this,i,o),t.cssVariables&&(e.prototype.fromJSON.call(this,t.cssVariables,o),this.initialCssVariables={},q(this.initialCssVariables,t.cssVariables),this.updateScaleProperties())}},t.prototype.toJSON=function(t){this.scaleCssVariables();var o=e.prototype.toJSON.call(this,t),i={};return q(i,this.initialCssVariables,this.themeCssVariablesChanges),o.cssVariables=i,Object.keys(o).forEach((function(e){0==e.indexOf("--")&&delete o[e]})),0===Object.keys(o.cssVariables).length&&delete o.cssVariables,o},t.defautlThemeName="sc2020",J([(0,o.property)()],t.prototype,"themeName",void 0),J([(0,o.property)()],t.prototype,"scale",void 0),J([(0,o.property)()],t.prototype,"fontScale",void 0),J([(0,o.property)()],t.prototype,"surfaceScale",void 0),J([(0,o.property)()],t.prototype,"isLight",void 0),t}(o.Base);o.Serializer.addClass("creatortheme",[{type:"dropdown",name:"themeName",choices:ko.map((function(e){return{value:e,text:Z("creatortheme.names."+e)}}))}],(function(e){return new Bo})),o.Serializer.addProperties("creatortheme",[{type:"color",name:"--sjs-special-background",default:"#F3F3F3FF",onPropertyEditorUpdate:function(e,t){t&&(t.title=Z("creatortheme.--sjs-special-background"))}},{type:"color",name:"--sjs-primary-background-500",default:"#19B394FF",onPropertyEditorUpdate:function(e,t){t&&(t.title=Z("creatortheme.--sjs-primary-background-500"))}},{type:"color",name:"--sjs-secondary-background-500",default:"#FF9814FF",displayName:""},{name:"--ctr-font-unit",default:"8px",visible:!1},{name:"--ctr-line-height-unit",default:"8px",visible:!1},{type:"spinedit",name:"fontScale",isSerializable:!1,default:100,enableIf:function(e){return!e||e.themeName!==Bo.defautlThemeName},onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5,t.title=Z("creatortheme.fontScale"),t.titleLocation="left",t.descriptionLocation="hidden")}},{name:"--ctr-spacing-unit",default:"8px",visible:!1},{name:"--ctr-size-unit",default:"8px",visible:!1},{name:"--ctr-corner-radius-unit",default:"8px",visible:!1},{type:"spinedit",name:"scale",isSerializable:!1,default:100,enableIf:function(e){return!e||e.themeName!==Bo.defautlThemeName},onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5,t.title=Z("creatortheme.userInterfaceBaseUnit"),t.titleLocation="left",t.descriptionLocation="hidden")}},{name:"--ctr-surface-base-unit",default:"8px",visible:!1},{type:"spinedit",name:"surfaceScale",isSerializable:!1,default:100,enableIf:function(e){return!e||e.themeName!==Bo.defautlThemeName},onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5,t.title=Z("creatortheme.surfaceScale"),t.titleLocation="left",t.descriptionLocation="hidden")}},{name:"isLight:boolean",visible:!1,isSerializable:!1}]);var qo={},Ho=["default","sharp","borderless","flat","plain","doubleborder","layered","solid","threedimensional","contrast"],Fo={light:{teal:"rgba(11, 128, 128, 1)",blue:"rgba(39, 114, 203, 1)",purple:"rgba(122, 70, 187, 1)",orchid:"rgba(178, 61, 153, 1)",tulip:"rgba(191, 76, 97, 1)",brown:"rgba(177, 94, 47, 1)",green:"rgba(11, 134, 75, 1)"},dark:{teal:"rgba(22, 198, 187, 1)",blue:"rgba(109, 183, 252, 1)",purple:"rgba(173, 144, 255, 1)",orchid:"rgba(232, 113, 220, 1)",tulip:"rgba(245, 131, 151, 1)",brown:"rgba(252, 187, 89, 1)",green:"rgba(140, 204, 90, 1)"}};function Qo(e){return void 0===e&&(e="light"),Object.keys(Fo[e]).map((function(t){return new o.ItemValue(Fo[e][t],Z("theme.colors."+t))}))}var Uo=function(){function e(e){var t=this;this.creator=e,this._showOneCategoryInPropertyGrid=!1,e.addPluginTab("designer",this),this.tabControlModel=new No(this.creator.sidebar),this.propertyGrid=new st(e.survey,e,e.getPropertyGridDefinition()),this.propertyGridViewModel=new Po(this.propertyGrid,e),this.propertyGridTab=this.creator.sidebar.addPage("propertyGrid","svc-property-grid",this.propertyGridViewModel,(function(){var e=[];return t.propertyGridViewModel.prevSelectionAction&&(t.propertyGridViewModel.prevSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.prevSelectionAction)),t.propertyGridViewModel.nextSelectionAction&&(t.propertyGridViewModel.nextSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.nextSelectionAction)),t.propertyGridViewModel.objectSelectionAction&&(t.propertyGridViewModel.objectSelectionAction.visible=t.createVisibleUpdater(),e.push(t.propertyGridViewModel.objectSelectionAction)),e})),e.onSelectedElementChanged.add((function(e,o){t.showOneCategoryInPropertyGrid&&"designer"===t.creator.activeTab&&(t.setPropertyGridIsActivePage(),t.updateTabControlActions())})),this.toolboxTab=this.creator.sidebar.addPage("toolbox","svc-toolbox",e),this.propertyGridPlaceholderPage=this.creator.sidebar.addPage("propertyGridPlaceholder","svc-property-grid-placeholder",this.propertyGridViewModel),this.propertyGridPlaceholderPage.caption="Survey Settings",this.creator.showCreatorThemeSettings&&this.createCreatorThemeSettingsPage(e),this.designerStateManager=new Ao,this.designerStateManager.initForSurvey(this.creator.survey),this.creator.onSurveyInstanceCreated.add((function(e,o){"designer"==o.reason&&t.designerStateManager.initForSurvey(o.survey)})),this.creator.onPropertyChanged.add((function(e,o){"toolboxLocation"===o.name&&(t.toolboxTab.visible&&"sidebar"!==o.newVal&&(t.propertyGridTab.visible=!0),t.toolboxTab.visible="sidebar"===o.newVal)})),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),e.registerShortcut("delete",{affectedTab:"designer",hotKey:{keyCode:46},macOsHotkey:{keyCode:46},execute:function(){return t.creator.deleteCurrentElement()}})}return Object.defineProperty(e.prototype,"isSurveySelected",{get:function(){return this.creator.isElementSelected(this.creator.survey)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"isSettingsActive",{get:function(){return this.creator.showSidebar&&this.isSurveySelected},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"activePageIsPropertyGrid",{get:function(){return this.creator.sidebar.activePage===this.propertyGridTab.id},enumerable:!1,configurable:!0}),e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){var t=e.creator.sidebar.activePage;return"designer"===e.creator.activeTab&&t!==e.propertyGridPlaceholderPage.id}))},e.prototype.updateTabControl=function(){this.showOneCategoryInPropertyGrid?(this.updateTabControlActions(),this.creator.sidebar.sideAreaComponentName="svc-tab-control",this.creator.sidebar.sideAreaComponentData=this.tabControlModel):(this.creator.sidebar.sideAreaComponentName="",this.creator.sidebar.sideAreaComponentData=void 0)},e.prototype.updateHeaderComponent=function(){var e=this.creator.sidebar.activePage;this.showOneCategoryInPropertyGrid&&this.activePageIsPropertyGrid?(this.creator.sidebar.header.componentName="svc-side-bar-property-grid-header",this.creator.sidebar.header.componentData=this.propertyGridViewModel.objectSelectionAction):!this.showOneCategoryInPropertyGrid||e!==this.propertyGridPlaceholderPage.id&&e!==this.themePropertyGridTab.id?(this.creator.sidebar.header.componentName="",this.creator.sidebar.header.componentData=void 0):(this.creator.sidebar.header.componentName="svc-side-bar-header",this.creator.sidebar.header.componentData=this.creator.sidebar.header)},e.prototype.updateActivePage=function(){this.showOneCategoryInPropertyGrid?(this.setActivePage(this.creator.survey.pageCount?this.propertyGridTab.id:this.propertyGridPlaceholderPage.id),this.updateHeaderComponent()):this.setPropertyGridIsActivePage()},e.prototype.setPropertyGridIsActivePage=function(){this.setActivePage(this.propertyGridTab.id)},e.prototype.setActivePage=function(e){this.creator.sidebar.activePage=e,this.updateHeaderComponent()},Object.defineProperty(e.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid!==e&&(this._showOneCategoryInPropertyGrid=e,this.creator.sidebar.hideSideBarVisibilityControlActions=e,this.propertyGrid.showOneCategoryInPropertyGrid=e,this.propertyGrid.setObj(this.creator.selectedElement),"designer"===this.creator.activeTab&&(this.updateActivePage(),this.updateTabControl()))},enumerable:!1,configurable:!0}),e.prototype.syncTheme=function(e){var t=e||this.themeModel.toJSON();this.creator.syncTheme(t)},e.prototype.updatePredefinedColorChoices=function(){var e=this;this.themePropertyGrid.survey.getAllQuestions().forEach((function(t){"--sjs-primary-background-500"!==t.name&&"--sjs-secondary-background-500"!==t.name||(t.choices=Qo(!1===e.themeModel.isLight?"dark":"light"))}))},e.prototype.updateThemeSettings=function(){this.creator.showCreatorThemeSettings&&(this.themeModel.loadTheme(this.creator.creatorTheme),this.themePropertyGrid.obj=this.themeModel,this.updatePredefinedColorChoices())},e.prototype.createCreatorThemeSettingsPage=function(e){var t=this;this.themeModel=new Bo,this.themePropertyGrid=new st(void 0,e,Mo),this.themePropertyGrid.showOneCategoryInPropertyGrid=!0,this.themePropertyGrid.surveyInstanceCreatedArea="designer-tab:creator-settings";var o=new Po(this.themePropertyGrid,e);o.searchEnabled=!1,this.themePropertyGridTab=this.creator.sidebar.addPage("creatorTheme","svc-property-grid",o),this.themePropertyGridTab.caption=G.getString("ed.creatorSettingTitle"),this.themePropertyGridTab.deactivateCallback=function(){i.active=!1},this.themeModel.onThemeSelected.add((function(e,o){t.syncTheme(o.theme),t.themePropertyGrid.survey.editingObj=void 0,t.themePropertyGrid.survey.editingObj=e,t.updatePredefinedColorChoices()})),this.themeModel.onThemePropertyChanged.add((function(e,o){t.syncTheme()}));var i=new kt({id:"theme-settings",locTooltipName:"pe.tabs.creatorSettingTitle",iconName:"icon-config",pressed:!1,action:function(){t.creator.sidebar.expandSidebar(),t.setActivePage(t.themePropertyGridTab.id),i.active=!0}});this.tabControlModel.bottomToolbar.setItems([i])},e.prototype.updateTabControlActions=function(){var e,t=this;if(this.showOneCategoryInPropertyGrid){var o=this.propertyGrid.survey.pages.map((function(e){var i=new kt({id:e.name,tooltip:e.title,iconName:Lo[e.name]||Lo[void 0],active:t.activePageIsPropertyGrid&&e.name===t.propertyGrid.survey.currentPage.name,pressed:!1,action:function(){t.creator.sidebar.expandSidebar(),t.setPropertyGridIsActivePage(),t.propertyGrid.survey.currentPage=e,t.propertyGridViewModel.objectSelectionAction.tooltip=e.title,o.forEach((function(e){return e.active=!1})),i.active=!0}});return i}));this.tabControlModel.topToolbar.setItems(o),this.propertyGridTab.deactivateCallback=function(){o.forEach((function(e){return e.active=!1}))},this.propertyGrid.survey.onCurrentPageChanged.add((function(e,i){o.forEach((function(e){e.active=e.id===i.newCurrentPage.name})),t.propertyGridViewModel.objectSelectionAction.tooltip=i.newCurrentPage.title})),this.propertyGridViewModel.objectSelectionAction.tooltip=null===(e=this.propertyGrid.survey.currentPage)||void 0===e?void 0:e.title}},e.prototype.activate=function(){this.model=new Io(this.creator),this.creator.sidebar.hideSideBarVisibilityControlActions=this.showOneCategoryInPropertyGrid,this.updateActivePage(),this.updateTabControl(),this.updateThemeSettings(),this.creator.focusElement(void 0,!0)},e.prototype.deactivate=function(){return this.model&&this.model.dispose(),this.model=void 0,this.propertyGridTab.visible=!1,this.propertyGridPlaceholderPage.visible=!1,this.themePropertyGridTab&&(this.themePropertyGridTab.visible=!1),this.toolboxTab.visible=!1,this.creator.sidebar.hideSideBarVisibilityControlActions=!1,this.creator.sidebar.sideAreaComponentName=void 0,this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.reset(),!0},e.prototype.onDesignerSurveyPropertyChanged=function(e,t){this.model&&this.model.onDesignerSurveyPropertyChanged(e,t)},e.prototype.update=function(){this.model&&(this.updateActivePage(),this.model.initSurvey())},e.prototype.createActions=function(){var e=this,t=[],i=new o.Action({id:"svd-toolbox",iconName:"icon-toolbox",needSeparator:!0,action:function(){e.creator.showSidebar||e.creator.setShowSidebar(!0,!0),e.setActivePage("toolbox")},active:new o.ComputedUpdater((function(){return"toolbox"===e.creator.sidebar.activePage})),visible:new o.ComputedUpdater((function(){return I("designer"===e.creator.activeTab,e.creator.showToolbox,"sidebar"===e.creator.toolboxLocation)})),title:"Toolbox",showTitle:!1});return this.surveySettingsAction=new o.Action({id:"svd-settings",iconName:"icon-settings",needSeparator:new o.ComputedUpdater((function(){return I("sidebar"!==e.creator.toolboxLocation,!e.creator.isMobileView)})),action:function(){e.selectSurvey(),e.creator.isMobileView||e.creator.sidebar.executeOnExpand((function(){e.creator.propertyGrid.getAllQuestions()[0].focus()}))},active:this.isSettingsActive,pressed:this.isSettingsActive,visible:this.createVisibleUpdater(),locTitleName:"ed.surveySettings",locTooltipName:"ed.surveySettingsTooltip",showTitle:!1}),this.saveSurveyAction=new o.Action({id:"svd-save",iconName:"icon-save",action:function(){return e.creator.saveSurveyActionHandler()},active:!1,enabled:!1,visible:new o.ComputedUpdater((function(){return I("designer"===e.creator.activeTab,e.creator.showSaveButton)})),locTitleName:"ed.saveSurvey",locTooltipName:"ed.saveSurveyTooltip",showTitle:!1}),this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",visible:this.createVisibleUpdater(),active:!0,locTitleName:"ed.designer",showTitle:!1,action:function(){}}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",action:function(){e.creator.makeNewViewActive(e.creator.showThemeTab?"theme":"test")},visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1}),t.push(this.saveSurveyAction),t.push(i),t.push(this.surveySettingsAction),this.creator.onSelectedElementChanged.add((function(t,o){e.surveySettingsAction.active=e.isSettingsActive,e.surveySettingsAction.pressed=e.isSettingsActive})),this.creator.onShowSidebarVisibilityChanged.add((function(t,o){e.surveySettingsAction.active=e.isSettingsActive,e.surveySettingsAction.pressed=e.isSettingsActive})),t},e.prototype.selectSurvey=function(){this.creator.showSidebar||this.creator.setShowSidebar(!0,!0),this.creator.selectElement(this.creator.survey),this.setPropertyGridIsActivePage()},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.surveySettingsAction)},e}();r(9118);var Go=function(){function e(e,t){var o=this;this.container=e,this.creator=t,this.resizeObserver=void 0,"undefined"!=typeof ResizeObserver&&(this.resizeObserver=new ResizeObserver((function(e){return o.process()})),this.resizeObserver.observe(this.findCorrectParent(this.container)),this.process(!0),"xs"!=this.currentWidth&&"s"!=this.currentWidth&&"m"!==this.currentWidth||this.creator.setShowSidebar(!1))}return e.prototype.getScreenWidth=function(){var t,o=this;return Object.keys(e.screenSizeBreakpoints).forEach((function(i){var n=e.screenSizeBreakpoints[i];!t&&o.container&&n&&o.container.offsetWidth>=n&&(t=i)})),t||"xs"},e.prototype.initMobileView=function(){this.creator.showTabs=!1,this.creator.showToolbar=!1,this.creator.isMobileView=!0},e.prototype.resetMobileView=function(){this.creator.showTabs=void 0,this.creator.showToolbar=void 0,this.creator.isMobileView=void 0},e.prototype.procesShowToolbox=function(e){this.creator.allowShowToolbox=e},e.prototype.procesShowPageNavigator=function(e){this.creator.allowShowPageNavigator="bypage"===this.creator.pageEditMode||e},e.prototype.findCorrectParent=function(e){return(null===window||void 0===window?void 0:window.getComputedStyle)&&"inline"===window.getComputedStyle(e.parentElement).display?this.findCorrectParent(e.parentElement):e.parentElement},e.prototype._process=function(e,t,o){this.creator.updateToolboxIsCompact(e),this.procesShowToolbox(t),this.procesShowPageNavigator(t),this.creator.sidebar.visible&&!o&&(this.creator.sidebar.collapsedManually=!1),this.creator.sidebar.visible&&!this.creator.sidebar.expandedManually&&o&&"right"!=this.creator.toolboxLocation&&this.creator.sidebar.collapseSidebar(),this.creator.sidebar.visible||this.creator.sidebar.collapsedManually||o||"right"==this.creator.toolboxLocation||this.creator.sidebar.expandSidebar(),this.creator.sidebar.flyoutMode=o},e.prototype.process=function(e){void 0===e&&(e=!1),e&&this.creator.sidebar.blockAnimations(),this.currentWidth=this.getScreenWidth(),"xl"===this.currentWidth||"xxl"===this.currentWidth?this._process(!1,!0,!1):"l"===this.currentWidth?this._process(!0,!0,!1):"m"===this.currentWidth?this._process(!0,!0,!0):this._process(!0,!1,!0),"xs"==this.currentWidth?this.initMobileView():this.resetMobileView(),e&&this.creator.sidebar.releaseAnimations()},e.prototype.dispose=function(){this.creator.allowShowToolbox=!0,this.creator.allowShowPageNavigator=!0,this.resizeObserver&&this.resizeObserver.disconnect()},e.screenSizeBreakpoints={xxl:1800,xl:1500,l:1200,m:900,s:600},e}(),Zo=function(e){function t(t,o,i,n){var r=e.call(this)||this;return r.id=t,r.sidePanel=o,i&&(r.componentName=i),n&&(r.componentData=n),r}return K(t,e),J([(0,o.property)()],t.prototype,"caption",void 0),J([(0,o.property)({onSet:function(e,t){t.sidePanel.updateHasVisiblePages()}})],t.prototype,"visible",void 0),J([(0,o.property)()],t.prototype,"componentData",void 0),J([(0,o.property)()],t.prototype,"componentName",void 0),t}(o.Base),zo=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.toolbar=new o.AdaptiveActionContainer,t}return K(t,e),Object.defineProperty(t.prototype,"component",{get:function(){return this.componentName||"svc-side-bar-default-header"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"componentModel",{get:function(){return this.componentData||this},enumerable:!1,configurable:!0}),t.prototype.reset=function(){this.title="",this.subTitle="",this.componentName="",this.componentData=void 0},J([(0,o.property)()],t.prototype,"title",void 0),J([(0,o.property)()],t.prototype,"subTitle",void 0),J([(0,o.property)()],t.prototype,"componentData",void 0),J([(0,o.property)()],t.prototype,"componentName",void 0),t}(o.Base),Jo=function(){function e(e,t){var o=this;this.container=e,this.events={mousedown:{touch:"touchend",mouse:"mousedown",pointer:"pointerdown"},mouseup:{touch:"touchstart",mouse:"mouseup",pointer:"pointerup"},mousemove:{touch:"touchmove",mouse:"mousemove",pointer:"pointermove"}},this.onMouseDownListener=function(e){window&&(e.preventDefault(),o.originalWidth=o.getStyleValue(o.container,"width"),o.originalMouseX=e.pageX,o.currentResizer=e.target,window.addEventListener(o.getMouseEvent("mousemove"),o.resize),window.addEventListener(o.getMouseEvent("mouseup"),o.stopResize))},this.resize=function(e){var t=o.originalWidth,i=e.pageX-o.originalMouseX;o.currentResizer==o.westResizer?t-=i:t+=i,t>o.maxWidth?t=o.maxWidth:t<o.minWidth&&(t=o.minWidth),o.container.style.width=t+"px"},this.stopResize=function(e){window&&(window.removeEventListener(o.getMouseEvent("mousemove"),o.resize),window.removeEventListener(o.getMouseEvent("mouseup"),o.stopResize))},this.init(e),this.setHandles(t)}return e.prototype.setHandles=function(e){var t=!1,o=!1,i=e.split(",");i.forEach((function(e){return e.trim()})),((i=i.filter((function(e){return!!e})))||[]).forEach((function(e){"w"==e&&(t=!0),"e"==e&&(o=!0)})),this.westResizer.style.display=t?"block":"none",this.eastResizer.style.display=o?"block":"none"},e.prototype.getStyleValue=function(e,t){return window?parseFloat(window.getComputedStyle(e).getPropertyValue(t).replace("px","")):0},e.prototype.isEventSupported=function(e){var t=document.createElement("div"),o=(e="on"+e)in t;return o||(t.setAttribute(e,"return;"),o="function"==typeof t[e]),t=null,o},e.prototype.getEventPrefix=function(){return void 0===this.mouseDevice&&(this.isEventSupported("pointerdown")?this.mouseDevice="pointer":this.isEventSupported("touchstart")?this.mouseDevice="touch":this.isEventSupported("mousedown")&&(this.mouseDevice="mouse")),this.mouseDevice},e.prototype.getMouseEvent=function(e){return this.events[e][this.getEventPrefix()]},e.prototype.init=function(e){this.westResizer=this.createrResizerElement("svc-resizer svc-resizer-west"),this.eastResizer=this.createrResizerElement("svc-resizer svc-resizer-east"),this.minWidth=this.getStyleValue(e,"min-width"),this.maxWidth=this.getStyleValue(e,"max-width"),e.insertBefore(this.westResizer,e.children[0]),e.appendChild(this.eastResizer)},e.prototype.createrResizerElement=function(e){var t=document.createElement("div");return t.className=e,t.addEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),t},e.prototype.dispose=function(){this.eastResizer.removeEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),this.eastResizer.remove(),this.eastResizer=void 0,this.westResizer.removeEventListener(this.getMouseEvent("mousedown"),this.onMouseDownListener),this.westResizer.remove(),this.westResizer=void 0},e}(),Wo=function(e){function t(t){var i=e.call(this)||this;return i.creator=t,i.header=new zo,i.allowFlyoutMode=!0,i.visibilityAnimation=new o.AnimationBoolean(i.getAnimationOptions(),(function(e){i.renderedIsVisible=e,i.allowFlyoutMode=!0}),(function(){return i.renderedIsVisible})),i.sidebarLocationChangedHandler=function(e,t){"sidebarLocation"===t.name&&i.resizeManager&&i.resizeManager.setHandles(i.getCurrentHandles())},i.onSidebarVisibilityChanged=function(e,t){i.isDisposed||(i.visible=t.show)},i.creator.onShowSidebarVisibilityChanged.add(i.onSidebarVisibilityChanged),i.creator.onPropertyChanged.add(i.sidebarLocationChangedHandler),i.visible=i.creator.showSidebar,i.createActions(),i}return K(t,e),Object.defineProperty(t.prototype,"rootCss",{get:function(){return(new o.CssClassBuilder).append("svc-side-bar").append("svc-side-bar--flyout",this.flyoutPanelMode).append("svc-side-bar--mobile",this.creator.isMobileView).append("svc-side-bar--side-area",!!this.sideAreaComponentName).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderRoot",{get:function(){return this.hasVisiblePages&&(!this.creator.isMobileView||this.renderedIsVisible)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"renderContainer",{get:function(){return this.renderedIsVisible},enumerable:!1,configurable:!0}),t.prototype.getAnimationOptions=function(){var e=this,t=function(e){e.querySelectorAll(".svc-side-bar__container-wrapper,.svc-side-bar__wrapper").forEach((function(e){e.style.setProperty("--animation-width",e.offsetWidth+"px")}))};return{getAnimatedElement:function(){return e.rootElement},isAnimationEnabled:function(){return e.animationAllowed},getRerenderEvent:function(){return e.onElementRerendered},getLeaveOptions:function(){return{onBeforeRunAnimation:t,cssClass:"svc-side-bar--leave"}},getEnterOptions:function(){return{onBeforeRunAnimation:t,cssClass:"svc-side-bar--enter",onAfterRunAnimation:function(){return e.afterExpand()}}}}},t.prototype.afterExpand=function(){this.onExpandCallback&&this.onExpandCallback(),this.onExpandCallback=void 0},t.prototype.executeOnExpand=function(e){this.renderedIsVisible&&e(),this.onExpandCallback=e},Object.defineProperty(t.prototype,"visible",{get:function(){return this._visible},set:function(e){!this._visible||e||this.flyoutMode||(this.allowFlyoutMode=!1),this._visible!==e&&(this._visible=e,this.animationAllowed||this.afterExpand(),this.visibilityAnimation.sync(e))},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"flyoutPanelMode",{get:function(){return this.flyoutMode&&this.allowFlyoutMode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"closeText",{get:function(){return Z("pe.close")},enumerable:!1,configurable:!0}),t.prototype.getPageById=function(e){return this.pages.filter((function(t){return t.id===e}))[0]},t.prototype.createActions=function(){var e=this;this._collapseAction=new o.Action({id:"svd-grid-hide",iconName:"icon-collapse-panel",css:"svd-grid-hide",locTitleName:"ed.hidePanel",showTitle:!1,visible:new o.ComputedUpdater((function(){return I(!I(!e.creator.allowCollapseSidebar,!e.flyoutMode),e.visible,!e.hideSideBarVisibilityControlActions)})),action:function(){e.collapseSidebar(),e.flyoutMode?e.creator.focusElement(e.creator.selectedElement,!0):(e.collapsedManually=!0,e.expandedManually=!1)}}),this.header.toolbar.actions.push(this._collapseAction),this.creator.allowCollapseSidebar&&(this._expandAction=new o.Action({id:"svd-grid-expand",iconName:"icon-expand-panel",css:"svd-grid-expand",needSeparator:!0,action:function(){e.expandSidebar(),e.flyoutMode||(e.collapsedManually=!1,e.expandedManually=e.flyoutMode)},locTitleName:"ed.showPanel",visible:new o.ComputedUpdater((function(){return I(e.hasVisiblePages,!e.visible,!e.hideSideBarVisibilityControlActions)})),showTitle:!1}))},t.prototype.getCurrentHandles=function(){return"right"==this.creator.sidebarLocation?"w":"e"},t.prototype.getActivePage=function(){return this._activePage},t.prototype.setActivePage=function(e){this._activePage&&this._activePage.id!==e.id&&this._activePage.deactivateCallback&&this._activePage.deactivateCallback(),this.pages.forEach((function(e){return e.visible=!1})),this._activePage=e,this._activePage&&(this.header.title=this._activePage.caption,this._activePage.visible=!0)},t.prototype.getExpandAction=function(){return this._expandAction},t.prototype.collapseSidebar=function(){this.creator.setShowSidebar(!1)},t.prototype.expandSidebar=function(){this.creator.setShowSidebar(!0)},t.prototype.addPage=function(e,t,o,i){var n=this,r=new Zo(e,this,t,o);return this.pages.push(r),i&&(i()||[]).forEach((function(e){return n.header.toolbar.actions.push(e)})),r},t.prototype.updateHasVisiblePages=function(){this.hasVisiblePages=(this.pages||[]).filter((function(e){return e.visible})).length>0},t.prototype.dispose=function(){this.creator&&!this.isDisposed&&(this.creator.onShowSidebarVisibilityChanged.remove(this.onSidebarVisibilityChanged),this.creator.onPropertyChanged.remove(this.sidebarLocationChangedHandler),this.sidebarLocationChangedHandler=void 0),this.resetResizeManager(),e.prototype.dispose.call(this)},t.prototype.initResizeManager=function(e){var t;this.resizeManager=new Jo(e,this.getCurrentHandles()),this.rootElement=null===(t=null==e?void 0:e.parentElement)||void 0===t?void 0:t.parentElement.parentElement},t.prototype.resetResizeManager=function(){this.resizeManager&&(this.resizeManager.dispose(),this.resizeManager=void 0),this.rootElement=void 0},Object.defineProperty(t.prototype,"toolbar",{get:function(){var e;return null===(e=this.header)||void 0===e?void 0:e.toolbar},enumerable:!1,configurable:!0}),J([(0,o.propertyArray)()],t.prototype,"pages",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"_visible",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"renderedIsVisible",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"collapsedManually",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"expandedManually",void 0),J([(0,o.property)()],t.prototype,"hasVisiblePages",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"flyoutMode",void 0),J([(0,o.property)({onSet:function(e,t){t.setActivePage(t.pages.filter((function(t){return t.id===e}))[0])}})],t.prototype,"activePage",void 0),J([(0,o.property)()],t.prototype,"hideSideBarVisibilityControlActions",void 0),J([(0,o.property)()],t.prototype,"sideAreaComponentName",void 0),J([(0,o.property)()],t.prototype,"sideAreaComponentData",void 0),J([(0,o.property)({})],t.prototype,"allowFlyoutMode",void 0),t}(o.Base),Ko=function(){function e(e){this.question=e}return e.createItemsNavigator=function(e){return e instanceof o.QuestionImagePickerModel?null:e instanceof o.QuestionMultipleTextModel?new Xo(e):e instanceof o.QuestionMatrixDropdownModel?new ei(e):e instanceof o.QuestionMatrixDynamicModel?new ti(e):e instanceof o.QuestionMatrixModel?new $o(e):e instanceof o.QuestionSelectBase?new Yo(e):null},e.prototype.addNewItems=function(e,t,i,n){var r=this,a=t.slice();a.splice(i,1),n.forEach((function(t,n){var s,l;a.splice(i+n,0,(s=t,l=e.inplaceEditForValues?s:c(e.getChoicesItemBaseTitle(),a),r.question.createItemValue?r.question.createItemValue(l,s):new o.ItemValue(l,s)))})),this.question[this.getItemsPropertyName(t)]=a},e.prototype.setEventsForItem=function(e,t,o){var i=this,n=oi.get(this.getItemLocString(t,o));n.allowLineBreaksOnEdit=!0,n.onEditComplete.clear(),n.onEditComplete.add((function(){var n=t.indexOf(o);n>=0&&n<t.length-1&&oi.get(i.getItemLocString(t,t[n+1])).activateEditor(),n==t.length-1&&(i.addNewItem(e,t),oi.get(i.getItemLocString(t,t[t.length-1])).setAutoFocus(),oi.get(i.getItemLocString(t,t[t.length-1])).activateEditor())})),n.onBackspaceEmptyString.clear(),n.onBackspaceEmptyString.add((function(){var e=t.indexOf(o),n=null;if(-1!==e){if(0==e&&t.length>=2&&(n=t[1]),e>0&&(n=t[e-1]),n){var r=oi.get(i.getItemLocString(t,n));r.setAutoFocus(),r.activateEditor()}t.splice(e,1)}})),n.onTextChanging.clear(),n.onTextChanging.add((function(n,r){var a=r.value.split(/\r?\n/).map((function(e){return(e||"").trim()})).filter((function(e){return!!e}));if(!(a.length<=1)){r.cancel=!0;var s=t.indexOf(o);i.addNewItems(e,t,s,a);var l=s+a.length;l>=t.length&&(l=t.length-1),oi.get(i.getItemLocString(t,t[l])).setAutoFocus(),oi.get(i.getItemLocString(t,t[l])).activateEditor()}}))},e.setQuestion=function(t){var o=t.element,i=e.createItemsNavigator(o);if(i){var n=t.creator,r=oi.get(o.locTitle),a=i.getItemSets(),s=a[0];r.hasEditCompleteHandler||(r.onEditComplete.add((function(){s.length&&oi.get(i.getItemLocString(s,s[0])).activateEditor()})),r.hasEditCompleteHandler=!0),a.forEach((function(e){e.forEach((function(t){i.setEventsForItem(n,e,t)}));var t=i.getItemsPropertyName(e);o.onPropertyChanged.add((function(o,r){r.name==t&&e.forEach((function(t){i.setEventsForItem(n,e,t)}))}))}))}return!!i},e}(),Yo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locText},t.prototype.getItemSets=function(){return[this.question.choices]},t.prototype.addNewItem=function(e,t,o){if(void 0===o&&(o=null),!(e.maximumChoicesCount&&t.length>=e.maximumChoicesCount)){var i=e.createNewItemValue(this.question);o&&(i.value=o)}},t.prototype.getItemsPropertyName=function(e){return"choices"},t}(Ko),Xo=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locTitle},t.prototype.getItemSets=function(){return[this.question.items]},t.prototype.addNewItem=function(e,t,o){void 0===o&&(o=null),this.question.addItem(o||h("text",t.map((function(e){return e.name}))))},t.prototype.getItemsPropertyName=function(e){return"items"},t.prototype.addNewItems=function(e,t,i,n){var r=t.slice(0,i).concat(n.map((function(e){return new o.MultipleTextItemModel(e)}))).concat(t.slice(i+1));this.question[this.getItemsPropertyName(t)]=r},t}(Ko),$o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return t.locText},t.prototype.getItemSets=function(){return[this.question.columns,this.question.rows]},t.prototype.addNewItem=function(e,t,i){var n,r;if(void 0===i&&(i=null),t==this.question.columns){if(e.maximumColumnsCount&&t.length>=e.maximumColumnsCount)return;n="Column ",r="columns"}if(t==this.question.rows){if(e.maximumRowsCount&&t.length>=e.maximumRowsCount)return;n="Row ",r="rows"}var a=new o.ItemValue(h(n,t.map((function(e){return e.value}))));t.push(i||a),e.onItemValueAddedCallback(this.question,r,a,t)},t.prototype.getItemsPropertyName=function(e){return e==this.question.columns?"columns":e==this.question.rows?"rows":void 0},t}(Ko),ei=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemLocString=function(e,t){return e==this.question.columns?t.locTitle:t.locText},t.prototype.addNewItem=function(t,i,n){if(void 0===n&&(n=null),i==this.question.columns){if(t.maximumColumnsCount&&i.length>=t.maximumColumnsCount)return;var r=new o.MatrixDropdownColumn(n||h("Column ",i.map((function(e){return e.value}))));this.question.columns.push(r),t.onMatrixDropdownColumnAddedCallback(this.question,r,this.question.columns)}i==this.question.rows&&e.prototype.addNewItem.call(this,t,i,n)},t.prototype.addNewItems=function(t,i,n,r){if(i==this.question.columns){var a=i.slice(0,n).concat(r.map((function(e){return new o.MatrixDropdownColumn(e)}))).concat(i.slice(n+1));this.question[this.getItemsPropertyName(i)]=a}else e.prototype.addNewItems.call(this,t,i,n,r)},t}($o),ti=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getItemSets=function(){return[this.question.columns]},t}(ei),oi=function(){function e(e){this.locString=e,this.hasEditCompleteHandler=!1,this.allowLineBreaksOnEdit=!1,this.onDoActivate=new o.EventBase,this.onTextChanging=new o.EventBase,this.onEditComplete=new o.EventBase,this.onBackspaceEmptyString=new o.EventBase}return e.get=function(t){return t._stringEditorConnector||(t._stringEditorConnector=new e(t)),t._stringEditorConnector},e.prototype.setAutoFocus=function(){this.focusOnEditor=!0},e.prototype.activateEditor=function(){this.onDoActivate.fire(this.locString,{})},e}(),ii=function(e){function t(t,i){var n=e.call(this)||this;return n.locString=t,n.creator=i,n.blurredByEscape=!1,n.focusedProgram=!1,n.characterCounter=new o.CharacterCounter,n.activate=function(){var e=n.getEditorElement();return!(!e||null==e.offsetParent||(e.focus({preventScroll:!0}),x(e),0))},n.justFocused=!1,n.locString=t,n.checkMarkdownToTextConversion(n.locString.owner,n.locString.name),n}return K(t,e),t.prototype.afterRender=function(){this.connector.focusOnEditor&&this.activate()&&(this.connector.focusOnEditor=!1)},t.prototype.detachFromUI=function(){var e;null===(e=this.connector)||void 0===e||e.onDoActivate.remove(this.activate),this.getEditorElement=void 0,this.blurEditor=void 0},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.detachFromUI()},t.prototype.setLocString=function(e){var t;null===(t=this.connector)||void 0===t||t.onDoActivate.remove(this.activate),this.locString=e,this.connector=oi.get(e),this.connector.onDoActivate.add(this.activate)},t.prototype.checkConstraints=function(e){!this.compostionInProgress&&this.maxLength>0&&e.keyCode>=32&&(e.target.innerText||"").length>=this.maxLength&&e.preventDefault(),13!=e.keyCode||this.locString.allowLineBreaks||e.preventDefault(),(e.ctrlKey||e.metaKey)&&-1!==[89,90,66,73].indexOf(e.keyCode)&&(e.stopImmediatePropagation(),e.preventDefault())},t.prototype.onClick=function(e){e.stopPropagation()},t.prototype.onFocus=function(e){this.focusedProgram||(this.valueBeforeEdit=this.locString.hasHtml?e.target.innerHTML:e.target.innerText,this.focusedProgram=!1),this.maxLength>0&&this.characterCounter.updateRemainingCharacterCounter(this.valueBeforeEdit,this.maxLength),this.creator&&(this.creator.selectFromStringEditor=!0),this.locString.hasHtml&&this.editAsText&&(e.target.innerText=e.target.textContent=this.locString.calculatedText),e.target.parentElement.click(),e.target.spellcheck=!0,e.target.setAttribute("tabindex",-1),this.focused=!0,this.justFocused=!0},t.prototype.checkMarkdownToTextConversion=function(e,t){if(this.creator){var o={element:e,text:null,name:t,html:""};this.creator.onHtmlToMarkdown.fire(this.creator,o),this.editAsText=null===o.text}},t.prototype.onCompositionStart=function(e){this.compostionInProgress=!0},t.prototype.onInput=function(e){var t;if(this.maxLength>0){var o=e.target.innerText||"";this.characterCounter.updateRemainingCharacterCounter(o,this.maxLength)}if(this.editAsText&&!this.compostionInProgress){var i={value:null===(t=e.target)||void 0===t?void 0:t.innerText,cancel:null};if(this.connector&&this.connector.onTextChanging.fire(this,i),i.cancel)return;this.maxLength>=0&&e.target.innerText.length>this.maxLength&&(e.target.innerText=e.target.innerText.substring(0,this.maxLength))}},t.prototype.onCompositionEnd=function(e){this.compostionInProgress=!1,this.onInput(e)},t.prototype.onBlur=function(e){var t;if(e.target.removeAttribute("tabindex"),this.blurredByEscape)return this.blurredByEscape=!1,this.locString.hasHtml?e.target.innerHTML=this.valueBeforeEdit:e.target.innerText=this.valueBeforeEdit,this.errorText=null,this.focused=!1,void(null===window||void 0===window||window.getSelection().removeAllRanges());var o=this.getClearedText(e.target);if(this.errorText=this.getErrorTextOnChanged(o),this.locString.text==o||!this.locString.text&&o==this.locString.calculatedText)this.locString.hasHtml?e.target.innerHTML=this.locString.renderedHtml:e.target.innerText=this.locString.renderedHtml,this.locString.strChanged();else{if(this.errorText)return null===(t=this.creator)||void 0===t||t.notify(this.errorText,"error"),this.focusedProgram=!0,e.target.innerText=o,void e.target.focus();this.setValueIntoLocStr(o,null==e?void 0:e.target)}this.focused=!1,null===window||void 0===window||window.getSelection().removeAllRanges()},t.prototype.getClearedText=function(e){var t=e.innerHTML,o=e.innerText;if(!this.creator)return this.locString.hasHtml?t:o;var i,n=null;if(!this.editAsText){var r={element:this.locString.owner,text:null,name:this.locString.name,html:t};this.creator.onHtmlToMarkdown.fire(this.creator,r),n=r.text}if(n)i=n;else{var a=this.locString.hasHtml&&!this.editAsText?t:o;this.locString.allowLineBreaks||(a=w(a)),i=a}var s={obj:this.locString.owner,propertyName:this.locString.name,value:this.locString.text,newValue:i,doValidation:!1};return this.creator.onValueChangingCallback(s),s.newValue},t.prototype.getErrorTextOnChanged=function(e){if(!this.creator)return"";var t=this.locString.owner,o=this.creator.onGetErrorTextOnValidationCallback(this.locString.name,t,e);if(o||e)return o;var i=t.getPropertyByName&&t.getPropertyByName(this.locString.name);return i&&i.isRequired?G.getString("pe.propertyIsEmpty"):""},Object.defineProperty(t.prototype,"isInplaceForEditValues",{get:function(){return!!this.creator&&this.creator.inplaceEditForValues&&this.locString.owner instanceof o.ItemValue&&this.creator.inplaceEditForValues&&-1===["noneText","otherText","selectAllText"].indexOf(this.locString.name)},enumerable:!1,configurable:!0}),t.prototype.setValueIntoLocStr=function(e,t){if(this.isInplaceForEditValues){var i=this.locString.owner;if(i.value!==e){if(i.locOwner&&i.ownerPropertyName){var n=i.locOwner[i.ownerPropertyName];Array.isArray(n)&&o.ItemValue.getItemByValue(n,e)&&(e=c(e,n),t&&(t.innerText=e))}i.value=e}}else{var r=this.locString.storeDefaultText;this.locString.storeDefaultText=!1,this.locString.text=e,this.locString.storeDefaultText=r}},t.prototype.done=function(e){e.stopImmediatePropagation(),e.preventDefault()},t.prototype.onPaste=function(e){var t;if(this.editAsText){e.preventDefault();var o=e.clipboardData.getData("text/plain");this.locString.allowLineBreaks||(null===(t=this.connector)||void 0===t?void 0:t.allowLineBreaksOnEdit)||(o=w(o));var i=window.getSelection();if(!i.rangeCount)return;i.deleteFromDocument(),i.getRangeAt(0).insertNode(document.createTextNode(o)),i.collapseToEnd(),e.target.dispatchEvent(new Event("input",{bubbles:!0}))}},t.prototype.onKeyDown=function(e){return 13!==e.keyCode||e.shiftKey||(this.blurEditor(),e.ctrlKey||e.metaKey||this.connector.onEditComplete.fire(this,{}),this.done(e)),27===e.keyCode&&(this.blurredByEscape=!0,this.blurEditor(),this.done(e)),8!==e.keyCode||e.target.innerText||(this.done(e),this.connector.onBackspaceEmptyString.fire(this,{})),this.checkConstraints(e),!0},t.prototype.onKeyUp=function(e){return 9===e.keyCode&&e.target===document.activeElement&&x(e.target),!0},t.prototype.onMouseUp=function(e){return!this.justFocused||(this.justFocused=!1,!!window&&((window.getSelection().focusNode&&window.getSelection().focusNode.parentElement!==e.target||0==window.getSelection().toString().length)&&x(e.target),!1))},t.prototype.findProperty=function(){if(this.locString.owner.getType){var e=this.locString.owner.getType();if(this.locString.name)return o.Serializer.findProperty(e,this.locString.name)}},Object.defineProperty(t.prototype,"maxLength",{get:function(){var e=this.findProperty();return!e||e.maxLength<=0?-1:e.maxLength},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholder",{get:function(){var e=this;if(this.placeholderValue)return this.placeholderValue;var t=this.findProperty();if(!t||!t.placeholder)return"";var i=G.getString(t.placeholder);if(i){var n=/\{([^}]+)\}/g;this.placeholderValue=new o.ComputedUpdater((function(){for(var t=i,o=n.exec(t);null!=o;)t=t.replace(n,(function(t){return""+(e.locString.owner&&e.locString.owner[o[1]])})),o=n.exec(t);return t}))}return this.placeholderValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"contentEditable",{get:function(){return!this.creator||this.creator.isCanModifyProperty(this.locString.owner,this.locString.name)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showCharacterCounter",{get:function(){return-1!==this.maxLength},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"getCharacterCounterClass",{get:function(){return"svc-remaining-character-counter"},enumerable:!1,configurable:!0}),t.prototype.className=function(e){return(new o.CssClassBuilder).append("svc-string-editor").append("svc-string-editor--hidden",""==e&&""==this.placeholder).append("svc-string-editor--readonly",!this.contentEditable).append("svc-string-editor--error",!!this.errorText).append("svc-string-editor--multiline",!!this.locString.allowLineBreaks).toString()},J([(0,o.property)()],t.prototype,"errorText",void 0),J([(0,o.property)()],t.prototype,"focused",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"editAsText",void 0),J([(0,o.property)()],t.prototype,"placeholderValue",void 0),t}(o.Base);r(4340);var ni=function(e){function t(t,o){return e.call(this,t,o)||this}return K(t,e),Object.defineProperty(t.prototype,"currentTheme",{get:function(){return this.surveyProvider.theme},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentThemeCssVariables",{get:function(){return this.currentTheme.cssVariables||{}},enumerable:!1,configurable:!0}),t.prototype.getTabName=function(){return"theme"},t}(Oe),ri=["Open Sans","Arial, sans-serif","Brush Script MT, cursive","Courier New, monospace","Garamond, serif","Georgia, serif","Tahoma, sans-serif","Times New Roman, serif","Trebuchet MS, sans-serif","Verdana, sans-serif"];function ai(){return[{type:"dropdown",name:"family",title:Z("theme.fontFamily"),titleLocation:"left",descriptionLocation:"hidden",choices:[].concat(ri),allowClear:!1},{type:"buttongroup",name:"weight",titleLocation:"hidden",descriptionLocation:"hidden",choices:[{value:"400",text:Z("theme.fontWeightRegular")},{value:"600",text:Z("theme.fontWeightSemiBold")},{value:"700",text:Z("theme.fontWeightBold")},{value:"800",text:Z("theme.fontWeightHeavy")}]},{type:"coloralpha",name:"color",colorTitle:Z("theme.color"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"coloralpha",name:"placeholdercolor",colorTitle:Z("theme.placeholderColor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"spinedit",name:"size",title:Z("theme.size"),titleLocation:"left",descriptionLocation:"hidden",unit:"px",min:0}]}function si(e,t,o){var i=e.contentPanel.questions[2];"allowEmptyColorValue"==t&&(i.allowEmptyValue=o)}function li(){o.ComponentCollection.Instance.getCustomQuestionByName("font").json.elementsJSON=ai()}function ui(e,t,o){void 0===e&&(e={}),Object.keys(e).forEach((function(i){var n="--sjs-font-".concat(t.name.toLocaleLowerCase(),"-").concat(i);t.defaultValue&&e[i]===t.defaultValue[i]?o[n]=void 0:o[n]=e[i]+("size"===i?"px":"")}))}function pi(e,t,o,i){if(e){e.defaultValue||(e.defaultValue={}),q(e.defaultValue,{color:t[o],placeholdercolor:i?t[i]:void 0}),e.defaultValue.size||(e.defaultValue.size=parseFloat(t["--sjs-font-size"]));var n=W({},e.defaultValue);return Object.keys(t).filter((function(t){return-1!==t.indexOf(e.name.toLocaleLowerCase())})).forEach((function(e){var o=e.split("-").pop();"size"===o&&void 0!==t[e]?n[o]=parseFloat(t[e].toString()):n[o]=t[e]})),n}}function ci(){return[{type:"coloralpha",name:"backcolor",colorTitle:Z("theme.backcolor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"coloralpha",name:"hovercolor",colorTitle:Z("theme.hovercolor"),colorTitleLocation:"left",titleLocation:"hidden",descriptionLocation:"hidden"},{type:"spinedit",name:"cornerRadius",title:Z("theme.cornerRadius"),titleLocation:"left",descriptionLocation:"hidden",unit:"px",min:0}]}function di(){o.ComponentCollection.Instance.getCustomQuestionByName("backgroundcornerradius").json.elementsJSON=ci()}function hi(e,t,o){void 0===e&&(e={}),Object.keys(e).forEach((function(i){var n="--sjs-".concat(t.name.toLocaleLowerCase(),"-").concat(i);t.defaultValue&&e[i]===t.defaultValue[i]?o[n]=void 0:o[n]=e[i]+("cornerRadius"===i?"px":"")}))}function gi(e,t,o,i,n){if(void 0===n&&(n=4),e){e.defaultValue||(e.defaultValue={}),q(e.defaultValue,{backcolor:t[o],hovercolor:t[i],cornerRadius:n});var r=W({},e.defaultValue);return Object.keys(t).filter((function(t){return-1!==t.indexOf(e.name.toLocaleLowerCase())})).forEach((function(e){var o=e.split("-").pop();"cornerRadius"===o&&void 0!==t[e]?r[o]=parseFloat(t[e].toString()):r[o]=t[e]})),r}}function mi(){return{type:"paneldynamic",minPanelCount:1,panelAddText:Z("theme.boxShadowAddRule"),templateElements:[{type:"spinedit",name:"x",unit:"px",title:Z("theme.boxShadowX"),titleLocation:"left"},{type:"spinedit",name:"y",unit:"px",startWithNewLine:!1,title:Z("theme.boxShadowY"),titleLocation:"left"},{type:"spinedit",name:"blur",unit:"px",title:Z("theme.boxShadowBlur"),min:0,titleLocation:"left"},{type:"spinedit",name:"spread",unit:"px",min:0,startWithNewLine:!1,title:Z("theme.boxShadowSpread"),titleLocation:"left"},{type:"coloralpha",name:"color",titleLocation:"hidden"},{type:"buttongroup",name:"isInset",titleLocation:"hidden",choices:[{text:Z("theme.boxShadowDrop"),value:!1},{text:Z("theme.boxShadowInner"),value:!0}]}]}}function fi(){o.ComponentCollection.Instance.getCustomQuestionByName("shadoweffects").json.questionJSON=mi()}function yi(e){if(Array.isArray(e)){var t=!1;if(e.forEach((function(e){for(var o in e)t=!0})),t)return e.map((function(e){var t,o,i,n,r;return"".concat(1==e.isInset?"inset ":"").concat(null!==(t=e.x)&&void 0!==t?t:0,"px ").concat(null!==(o=e.y)&&void 0!==o?o:0,"px ").concat(null!==(i=e.blur)&&void 0!==i?i:0,"px ").concat(null!==(n=e.spread)&&void 0!==n?n:0,"px ").concat(null!==(r=e.color)&&void 0!==r?r:"#000000")})).join(",")}}function vi(e){var t=bi(e);return t.forEach((function(e){e.x=0,e.y=0,e.blur=0,e.spread=0})),yi(t)}function bi(e){return void 0===e&&(e=""),e.split(/,(?![^(]*\))/).map((function(e){var t=e.match(/#[a-zA-Z0-9]+|rgba?\(.*?\)/),o=e.indexOf("inset")>-1,i={};o&&(e=e.replace("inset","")),t&&(i.color=t[0]);var n=e.replace(/\s+/g," ").replace(/^\s|\s$/g,"").split(" ");return i.x=parseInt(n[0])||0,i.y=parseInt(n[1])||0,i.blur=parseInt(n[2])||0,i.spread=parseInt(n[3])||0,i.isInset=o,i}))}function Ci(e){return e?e.replace(/\)\,\s/g,"),"):e}o.ComponentCollection.Instance.getCustomQuestionByName("font")||o.ComponentCollection.Instance.add({name:"font",showInToolbox:!1,internal:!0,elementsJSON:ai(),onInit:function(){o.Serializer.addProperties("font",[{name:"allowEmptyColorValue:boolean",default:!1,visible:!1}])},onLoaded:function(e){si(e,"allowEmptyColorValue",e.allowEmptyColorValue)},onPropertyChanged:function(e,t,o){si(e,t,o)},onCreated:function(e){e.contentPanel.getQuestionByName("color").visible="surveyTitle"!==e.name&&"surveyDescription"!==e.name,e.contentPanel.getQuestionByName("placeholdercolor").visible="editorFont"===e.name,e.contentPanel.getQuestionByName("family").choices=[].concat(ri)},valueToQuestion:function(e){return JSON.parse(JSON.stringify(e))},onValueChanged:function(e,t,o){}}),o.ComponentCollection.Instance.getCustomQuestionByName("backgroundcornerradius")||o.ComponentCollection.Instance.add({name:"backgroundcornerradius",showInToolbox:!1,internal:!0,elementsJSON:ci(),onInit:function(){},onCreated:function(e){},valueToQuestion:function(e){return JSON.parse(JSON.stringify(e))},onValueChanged:function(e,t,o){}}),o.ComponentCollection.Instance.getCustomQuestionByName("shadoweffects")||o.ComponentCollection.Instance.add({name:"shadoweffects",showInToolbox:!1,internal:!0,questionJSON:mi(),onCreated:function(e){e.valueFromDataCallback=function(e){return void 0===e?[{}]:"string"==typeof e?bi(e):e},e.valueToDataCallback=function(e){return e?"string"==typeof e?e:yi(Array.isArray(e)?e:[e]):""},e.contentQuestion.panels.forEach((function(e){return e.questions.forEach((function(e){return e.allowRootStyle=!1}))}))}});var wi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getSurvey=function(e){return void 0===e&&(e=!1),this.owner},t.prototype.fromJSON=function(t,o){e.prototype.fromJSON.call(this,t,o),t.backgroundImageOpacity&&(this.backgroundImageOpacity=100*t.backgroundImageOpacity)},t.prototype.setCssVariables=function(e){e&&(this.surveyTitle=pi(this.getPropertyByName("surveyTitle"),e),this.surveyDescription=pi(this.getPropertyByName("surveyDescription"),e),this.headerTitle=pi(this.getPropertyByName("headerTitle"),e),this.headerDescription=pi(this.getPropertyByName("headerDescription"),e));var t=e["--sjs-header-backcolor"];t&&(this.backgroundColorSwitch=this.getBackgroundColorSwitchByValue(t),this.backgroundColor="custom"===this.backgroundColorSwitch?t:void 0)},t.prototype.toJSON=function(t){var o=this,i=e.prototype.toJSON.call(this,t);delete i.type,delete i.logoPosition,delete i.headerView,100!==this.backgroundImageOpacity&&(i.backgroundImageOpacity=this.backgroundImageOpacity/100);var n={};return Object.keys(i).forEach((function(e){if("object"==typeof i[e]){var t=o.getPropertyByName(e);"font"===t.type&&(ui(i[e],t,n),delete i[e])}})),this.setHeaderBackgroundColorCssVariable(n),i.cssVariables=n,delete i.backgroundColorSwitch,delete i.backgroundColor,i},t.prototype.saveToThemeJSON=function(e,t){var o=this.toJSON(t);q(e.cssVariables,o.cssVariables),delete o.cssVariables,Object.keys(o).length>0&&(e.header=o),e.headerView=this.headerView},t.prototype.setHeaderBackgroundColorCssVariable=function(e){var t;"none"===this.backgroundColorSwitch?e["--sjs-header-backcolor"]="transparent":"custom"===this.backgroundColorSwitch?e["--sjs-header-backcolor"]=null!==(t=this.backgroundColor)&&void 0!==t?t:"transparent":e["--sjs-header-backcolor"]=void 0},t.prototype.getBackgroundColorSwitchByValue=function(e){return e?"transparent"===e?"none":"custom":"accentColor"},t.prototype.getType=function(){return"header"},t}(o.Base);function xi(){return{family:i.themeEditor.defaultFontFamily,weight:"700",size:32}}function Ti(e){var t={family:i.themeEditor.defaultFontFamily,weight:"400",size:16};return e&&(t.weight="600"),t}function Si(e,t){return{type:"buttongroup",name:e,visibleIf:function(e){return"advanced"===e.headerView},choices:[{value:"left"},{value:"center"},{value:"right"}],default:t}}function Pi(e,t){return{type:"buttongroup",name:e,displayName:"",visibleIf:function(e){return"advanced"===e.headerView},choices:[{value:"top"},{value:"middle"},{value:"bottom"}],default:t}}o.Serializer.addClass("header",[{type:"buttongroup",name:"headerView",default:"basic",choices:[{value:"basic"},{value:"advanced"}]},{type:"buttongroup",name:"logoPosition",visibleIf:function(e){return"basic"===e.headerView},default:"left",choices:[{value:"left"},{value:"right"}]},{type:"spinedit",name:"height",visibleIf:function(e){return"advanced"===e.headerView},default:256,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"spinedit",name:"mobileHeight",visibleIf:function(e){return"advanced"===e.headerView},default:0,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"buttongroup",name:"inheritWidthFrom",visibleIf:function(e){return"advanced"===e.headerView},default:"container",choices:[{value:"survey"},{value:"container"}]},{type:"spinedit",name:"textAreaWidth",visibleIf:function(e){return"advanced"===e.headerView},default:512,onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{type:"buttongroup",name:"backgroundColorSwitch",visibleIf:function(e){return"advanced"===e.headerView},isSerializable:!1,default:"accentColor",choices:[{value:"none"},{value:"accentColor"},{value:"custom"}]},{type:"color",name:"backgroundColor",displayName:"",visibleIf:function(e){return"advanced"===e.headerView},isSerializable:!1,onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyValue=!0,t.enableIf="{composite.backgroundColorSwitch} = 'custom'")}},{name:"backgroundImage:file",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.storeDataAsText=!1,t.acceptedTypes="image/*")}},{type:"buttongroup",name:"backgroundImageFit",displayName:"",choices:[{value:"cover"},{value:"fill"},{value:"contain"},{value:"tile"}],default:"cover",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.enableIf="{composite.backgroundImage} notempty")}},{type:"spinedit",name:"backgroundImageOpacity",visibleIf:function(e){return"advanced"===e.headerView},default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5,t.titleLocation="left",t.enableIf="{composite.backgroundImage} notempty")}},{type:"boolean",name:"overlapEnabled",displayName:"",visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.renderAs="checkbox")}},Si("logoPositionX","right"),Pi("logoPositionY","top"),Si("titlePositionX","left"),Pi("titlePositionY","bottom"),Si("descriptionPositionX","left"),Pi("descriptionPositionY","bottom")]),o.Serializer.addProperties("header",[{type:"font",name:"surveyTitle",visibleIf:function(e){return"basic"===e.headerView},default:xi()},{type:"font",name:"surveyDescription",visibleIf:function(e){return"basic"===e.headerView},default:Ti()},{type:"font",name:"headerTitle",default:xi(),visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyColorValue=!0)}},{type:"font",name:"headerDescription",default:Ti(!0),visibleIf:function(e){return"advanced"===e.headerView},onPropertyEditorUpdate:function(e,t){t&&(t.allowEmptyColorValue=!0)}}]);var Ei=r(7238);function Vi(){return[{name:"color",type:"color",titleLocation:"hidden"},{name:"opacity",startWithNewLine:!1,type:"spinedit",title:Z("theme.opacity"),min:0,max:100,defaultValue:100,unit:"%",titleLocation:"left"}]}function Ii(){o.ComponentCollection.Instance.getCustomQuestionByName("coloralpha").json.elementsJSON=Vi()}function Oi(e,t,o){var i=e.contentPanel.questions[0];i&&("colorTitleLocation"==t&&(i.titleLocation=o),"colorTitle"==t&&(i.title=o),"choices"==t&&(i.choices=o),"allowEmptyValue"==t&&(i.allowEmptyValue=o))}function Ai(e){return _(e.color,e.opacity/100)}function Ni(e){var t=(e.themeName||Di.DefaultTheme.themeName||"default")+"-"+(e.colorPalette||"light");return!0===e.isPanelless&&(t+="-panelless"),t}function Li(e,t,o,i){var n=qo[i];if(n)return n;for(var r=Object.keys(qo).filter((function(t){return 0===t.indexOf(e+"-")})),a=0,s=r;a<s.length;a++){var l=s[a];0===l.indexOf(e+"-"+t)&&(i=e+"-"+t),0===l.indexOf(e+"-"+t+(o?"-panelless":""))&&(i=e+"-"+t+(o?"-panelless":""))}if(n=qo[r[0]])return n;var u=Ni({themeName:Di.DefaultTheme.themeName,colorPalette:t||"light",isPanelless:o});return qo[u]||Di.DefaultTheme}function _i(e,t){void 0===t&&(t={});var o={};return Object.keys(e).forEach((function(i){"object"==typeof e[i]?o[i]=_i(e[i],t[i]):void 0!==e[i]&&e[i]!=t[i]&&(o[i]=e[i])})),o}function Mi(e,t){if(!t){var i=Ni(e);t=Li(e.themeName,e.colorPalette,e.isPanelless,i)}var n=_i(e,t);return Object.keys(n).forEach((function(e){-1!==e.toLowerCase().indexOf("background")&&(""!==n[e]&&n[e]!==o.Serializer.findProperty("survey",e).defaultValue||delete n[e])})),n.themeName=t.themeName||Di.DefaultTheme.themeName||"default",n.colorPalette=t.colorPalette||"light",n.isPanelless=!!t.isPanelless,n}o.ComponentCollection.Instance.getCustomQuestionByName("coloralpha")||o.ComponentCollection.Instance.add({name:"coloralpha",showInToolbox:!1,internal:!0,elementsJSON:Vi(),onInit:function(){o.Serializer.addProperties("coloralpha",[{name:"choices:itemvalue[]",visible:!1},{name:"colorTitleLocation:string",default:"hidden",visible:!1},{name:"allowEmptyValue:boolean",default:!1,visible:!1},{name:"colorTitle:string",visible:!1}])},onLoaded:function(e){Oi(e,"colorTitle",e.colorTitle),Oi(e,"colorTitleLocation",e.colorTitleLocation),Oi(e,"choices",e.choices),Oi(e,"allowEmptyValue",e.allowEmptyValue)},onPropertyChanged:function(e,t,o){Oi(e,t,o)},valueToQuestion:function(e){return e?Ai(e):""},valueFromQuestion:function(e){return"string"==typeof e||void 0===e?k(e):e},onCreated:function(e){e.contentPanel.questions.forEach((function(e){return e.allowRootStyle=!1}))}}),Object.keys(Ei||{}).forEach((function(e){var t=Ei[e],o={},i={};q(o,t.cssVariables),q(i,t,{cssVariables:o});var n=Ni(t);qo[n]=i}));var Di=function(e){function t(){var i=e.call(this)||this;return i.themeCssVariablesChanges={},i.colorCalculator=new H,i._defaultSessionTheme=t.DefaultTheme,i.onThemeSelected=new o.EventBase,i.onThemePropertyChanged=new o.EventBase,i.onAllowModifyTheme=new o.EventBase,i.blockThemeChangedNotifications=0,fi(),li(),Ii(),di(),i.setNewHeaderProperty(),i.onPropertyValueChangedCallback=function(e,t,o,n,r){i.onThemePropertyValueChangedCallback(e,t,o,n,r)},i}return K(t,e),t.prototype.getFullThemeName=function(e){return"light"===this.colorPalette?e||this.themeName:(e||this.themeName)+"-"+this.colorPalette},Object.defineProperty(t.prototype,"defaultSessionTheme",{get:function(){return this._defaultSessionTheme},set:function(e){this._defaultSessionTheme=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssVariables",{get:function(){return this.toJSON().cssVariables||{}},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"themeCssCustomizations",{get:function(){var e={};return q(e,this.themeCssVariablesChanges),e},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"theme"},t.prototype.setNewHeaderProperty=function(){var e=new wi;e.owner=this,this.setPropertyValue("header",e)},t.prototype.hasVariations=function(e){var t,o,i=Object.keys(qo),n=this.themeName+"-light",r=this.themeName+"-dark";this.isPanelless&&(n+="-panelless",r+="-panelless"),o=-1!==i.indexOf(n)&&-1!==i.indexOf(r);var a=this.themeName+"-"+this.colorPalette,s=a+"-panelless";return t=-1!==i.indexOf(a)&&-1!==i.indexOf(s),e?o:t},t.prototype.initializeColorCalculator=function(e){e["--sjs-primary-backcolor"]&&e["--sjs-primary-backcolor-light"]&&e["--sjs-primary-backcolor-dark"]&&this.colorCalculator.initialize(e["--sjs-primary-backcolor"],e["--sjs-primary-backcolor-light"],e["--sjs-primary-backcolor-dark"])},t.prototype.updatePropertiesDependentOnPrimaryColor=function(e){this.colorCalculator.calculateColors(e),this.setPropertyValue("--sjs-primary-backcolor-light",this.colorCalculator.colorSettings.newColorLight),this.setPropertyValue("--sjs-primary-backcolor-dark",this.colorCalculator.colorSettings.newColorDark),this.setThemeCssVariablesChanges("--sjs-primary-backcolor-light",this.colorCalculator.colorSettings.newColorLight),this.setThemeCssVariablesChanges("--sjs-primary-backcolor-dark",this.colorCalculator.colorSettings.newColorDark)},t.prototype.cssVariablePropertiesChanged=function(e,t,o){var i=!0;if("primaryColor"===e)this.setPropertyValue("--sjs-primary-backcolor",t),this.setThemeCssVariablesChanges("--sjs-primary-backcolor",t),this.updatePropertiesDependentOnPrimaryColor(t);else if("--sjs-primary-backcolor"===e)this.primaryColor=t,this.updatePropertiesDependentOnPrimaryColor(t);else if("--sjs-shadow-inner"===e||"--sjs-shadow-small"===e){var n=vi(t);this.setPropertyValue(e+"-reset",n),this.setThemeCssVariablesChanges(e+"-reset",n)}else if("scale"==e)this.setThemeCssVariablesChanges("--sjs-base-unit",8*t/100+"px");else if("fontSize"==e)this.setThemeCssVariablesChanges("--sjs-font-size",16*t/100+"px");else if("cornerRadius"==e)this.setThemeCssVariablesChanges("--sjs-corner-radius",t+"px");else if("questionBackgroundTransparency"===e||"editorPanel"===e){var r=k(this.getPropertyValue("--sjs-general-backcolor-dim-light")).color,a=this.getPropertyValue("questionBackgroundTransparency");this.setThemeCssVariablesChanges("--sjs-editor-background",_(r,a/100))}else if("panelBackgroundTransparency"===e||"questionPanel"===e){r=k(this.getPropertyValue("--sjs-general-backcolor")).color;var s=this.getPropertyValue("panelBackgroundTransparency");this.setThemeCssVariablesChanges("--sjs-question-background",_(r,s/100))}else i=!1;var l=!0;return"font"===o.type?(ui(t,o,this.themeCssVariablesChanges),this.onThemePropertyChanged.fire(this,{name:e,value:t})):"backgroundcornerradius"===o.type?(hi(t,o,this.themeCssVariablesChanges),this.onThemePropertyChanged.fire(this,{name:e,value:t})):l=!1,i||l},t.prototype.setThemeCssVariablesChanges=function(e,t){this.themeCssVariablesChanges[e]!==t&&(this.themeCssVariablesChanges[e]=t,this.onThemePropertyChanged.fire(this,{name:e,value:t}))},t.prototype.initialize=function(e,o){void 0===e&&(e={}),this._defaultSessionTheme=t.DefaultTheme,this.backgroundImage="backgroundImage"in e?e.backgroundImage:null==o?void 0:o.backgroundImage,this.backgroundImageFit=void 0!==e.backgroundImageFit?e.backgroundImageFit:null==o?void 0:o.backgroundImageFit,this.backgroundImageAttachment=void 0!==e.backgroundImageAttachment?e.backgroundImageAttachment:null==o?void 0:o.backgroundImageAttachment,this.backgroundOpacity=100*((void 0!==e.backgroundOpacity?e.backgroundOpacity:null==o?void 0:o.backgroundOpacity)||1),this.loadTheme(e),this.header.logoPosition=null==o?void 0:o.logoPosition,this.undoRedoManager=new go},Object.defineProperty(t.prototype,"header",{get:function(){return this.getPropertyValue("header")},set:function(e){e&&(this.setNewHeaderProperty(),this.header.fromJSON(e.toJSON()))},enumerable:!1,configurable:!0}),t.prototype.loadTheme=function(e){this.blockThemeChangedNotifications+=1;try{var o=Ni(e),i=Li(e.themeName,e.colorPalette,e.isPanelless,o),n=Mi(e,i);this.themeName=n.themeName,this.colorPalette=n.colorPalette,this.isPanelless=n.isPanelless,this.backgroundImage=e.backgroundImage||this.backgroundImage,this.backgroundImageFit=e.backgroundImageFit||this.backgroundImageFit,this.backgroundImageAttachment=e.backgroundImageAttachment||this.backgroundImageAttachment;var r={};q(r,t.DefaultTheme.cssVariables||{},i.cssVariables||{}),q(r,e.cssVariables||{},this.themeCssVariablesChanges);var a={backgroundImage:this.backgroundImage||i.backgroundImage||"",backgroundImageFit:this.backgroundImageFit||i.backgroundImageFit,backgroundImageAttachment:this.backgroundImageAttachment||i.backgroundImageAttachment,backgroundOpacity:this.backgroundOpacity/100||i.backgroundOpacity},s={};Object.keys(s).length>0&&(a.header=s),q(a,e,{cssVariables:r,themeName:this.themeName,colorPalette:this.colorPalette,isPanelless:this.isPanelless}),this.initializeColorCalculator(a.cssVariables),this.fromJSON(a)}finally{this.blockThemeChangedNotifications-=1}},t.prototype.resetTheme=function(){this.setTheme({themeName:this.defaultSessionTheme.themeName,isPanelless:this.defaultSessionTheme.isPanelless,colorPalette:this.defaultSessionTheme.colorPalette})},t.prototype.setTheme=function(e){var t=this,o=this.themeCssVariablesChanges["--sjs-header-backcolor"];this.themeCssVariablesChanges={},void 0!==o&&(this.themeCssVariablesChanges["--sjs-header-backcolor"]=o);try{this.blockThemeChangedNotifications+=1,this.iteratePropertiesHash((function(e,o){t.setPropertyValue(o,void 0)})),this.setNewHeaderProperty()}finally{this.blockThemeChangedNotifications-=1}this.loadTheme(e),this.onThemeSelected.fire(this,{theme:this.toJSON()})},t.prototype.selectTheme=function(e,t,o){void 0===t&&(t="light"),void 0===o&&(o="panels"),this.themeName=e,this.colorPalette=t,this.isPanelless="lightweight"===o;var i=this.findSuitableTheme(e);this.setTheme(i)},t.prototype.generalPropertiesChanged=function(e,t){var o;return-1!==["themeName","isPanelless","colorPalette"].indexOf(e)&&("themeName"===e&&this.loadTheme(this.findSuitableTheme(t)||((o={})[e]=t,o.isPanelless=this.isPanelless,o.colorPalette=this.colorPalette,o)),"isPanelless"===e&&this.loadTheme({themeName:this.themeName,isPanelless:t,colorPalette:this.colorPalette}),"colorPalette"===e&&this.loadTheme({themeName:this.themeName,isPanelless:this.isPanelless,colorPalette:t}),this.onThemeSelected.fire(this,{theme:this.toJSON()}),!0)},t.prototype.onThemePropertyValueChangedCallback=function(e,t,o,i,n){var r=this;if(this.undoRedoManager&&(0==this.blockThemeChangedNotifications&&this.undoRedoManager.startTransaction(e+" changed"),this.undoRedoManager.onPropertyValueChanged(e,t,o,i,n)),!(this.blockThemeChangedNotifications>0)){var a=!1;if(this!==i){var s=i.toJSON();s.cssVariables&&Object.keys(s.cssVariables).forEach((function(e){return r.setThemeCssVariablesChanges(e,s.cssVariables[e])})),this.onThemePropertyChanged.fire(this,{name:e,value:o}),a=!0}if(0===e.indexOf("--")&&(this.setThemeCssVariablesChanges(e,o),a=!0),this.generalPropertiesChanged(e,o))this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction();else{if(this.blockThemeChangedNotifications+=1,this===i&&-1!==["backgroundImage","backgroundImageFit","backgroundImageAttachment","backgroundOpacity"].indexOf(e))return this[e]=o,this.onThemePropertyChanged.fire(this,{name:e,value:o}),this.blockThemeChangedNotifications-=1,void(this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction());this.cssVariablePropertiesChanged(e,o,i.getPropertyByName(e))&&(a=!0),a||this.onThemePropertyChanged.fire(this,{name:e,value:o}),this.blockThemeChangedNotifications-=1,this.undoRedoManager&&0==this.blockThemeChangedNotifications&&this.undoRedoManager.stopTransaction()}}},t.prototype.findSuitableTheme=function(e){var t=Ni({themeName:e,colorPalette:this.colorPalette,isPanelless:this.isPanelless});return Li(e,this.colorPalette,this.isPanelless,t)},t.prototype.fromJSON=function(t,i){var n=this;if(t){var r={};q(r,t),delete r.header,delete r.cssVariables,e.prototype.fromJSON.call(this,r,i);var a={};q(a,t.header),t.headerView&&(a.headerView=t.headerView),this.header.fromJSON(a||{}),t.cssVariables&&(this.primaryColor=t.cssVariables["--sjs-primary-backcolor"],e.prototype.fromJSON.call(this,t.cssVariables,i),this.header.setCssVariables(t.cssVariables),this.scale=this["--sjs-base-unit"]?l(100*parseFloat(this["--sjs-base-unit"])/8):void 0,this.fontSize=this["--sjs-font-size"]?l(100*parseFloat(this["--sjs-font-size"])/16):void 0,this.cornerRadius=this["--sjs-corner-radius"]?l(parseFloat(this["--sjs-corner-radius"])):void 0,t.backgroundOpacity&&(this.backgroundOpacity=100*t.backgroundOpacity),this.questionPanel=gi(this.getPropertyByName("questionPanel"),t.cssVariables,"--sjs-general-backcolor","--sjs-general-backcolor-dark",this.cornerRadius),this.editorPanel=gi(this.getPropertyByName("editorPanel"),t.cssVariables,"--sjs-general-backcolor-dim-light","--sjs-general-backcolor-dim-dark",this.cornerRadius),o.Serializer.getProperties("theme").forEach((function(e){"font"===e.type&&(n[e.name]=pi(e,t.cssVariables))})),this.pageTitle=pi(this.getPropertyByName("pageTitle"),t.cssVariables,"--sjs-general-dim-forecolor"),this.pageDescription=pi(this.getPropertyByName("pageDescription"),t.cssVariables,"--sjs-general-dim-forecolor-light"),this.questionTitle=pi(this.getPropertyByName("questionTitle"),t.cssVariables,"--sjs-general-forecolor"),this.questionDescription=pi(this.getPropertyByName("questionDescription"),t.cssVariables,"--sjs-general-forecolor-light"),this.editorFont=pi(this.getPropertyByName("editorFont"),t.cssVariables,"--sjs-general-forecolor","--sjs-general-forecolor-light"))}},t.prototype.toJSON=function(t){var o=this;void 0!==this.scale&&(this["--sjs-base-unit"]=8*this.scale/100+"px"),void 0!==this.fontSize&&(this["--sjs-font-size"]=16*this.fontSize/100+"px"),void 0!==this.cornerRadius&&(this["--sjs-corner-radius"]=this.cornerRadius+"px");var i=e.prototype.toJSON.call(this,t);i.backgroundImage=this.backgroundImage||"",i.backgroundOpacity=this.backgroundOpacity/100,i.backgroundImageAttachment=this.backgroundImageAttachment,i.backgroundImageFit=this.backgroundImageFit;var n={};return Object.keys(i).forEach((function(e){if(0==e.indexOf("--"))n[e]=i[e],delete i[e];else if("object"==typeof i[e]){var t=o.getPropertyByName(e);"font"===t.type&&(ui(i[e],t,n),delete i[e]),"backgroundcornerradius"===t.type&&(hi(i[e],t,n),delete i[e])}})),i.cssVariables=n,this.header.saveToThemeJSON(i,t),i},t.DefaultTheme=qo["default-light"]||{},J([(0,o.property)()],t.prototype,"backgroundImage",void 0),J([(0,o.property)()],t.prototype,"backgroundImageFit",void 0),J([(0,o.property)()],t.prototype,"backgroundImageAttachment",void 0),J([(0,o.property)()],t.prototype,"backgroundOpacity",void 0),J([(0,o.property)()],t.prototype,"themeName",void 0),J([(0,o.property)()],t.prototype,"colorPalette",void 0),J([(0,o.property)()],t.prototype,"isPanelless",void 0),J([(0,o.property)()],t.prototype,"groupAppearanceAdvancedMode",void 0),J([(0,o.property)({onSet:function(e,t){var o=_(k(t.questionPanel.backcolor).color,e/100);if(t.questionPanel.backcolor!==o){var i=W({},t.questionPanel);i.backcolor=o,t.questionPanel=i}}})],t.prototype,"panelBackgroundTransparency",void 0),J([(0,o.property)({onSet:function(e,t){var o=_(k(t.editorPanel.backcolor).color,e/100);if(t.editorPanel.backcolor!==o){var i=W({},t.editorPanel);i.backcolor=o,t.editorPanel=i}}})],t.prototype,"questionBackgroundTransparency",void 0),J([(0,o.property)()],t.prototype,"scale",void 0),J([(0,o.property)()],t.prototype,"cornerRadius",void 0),J([(0,o.property)()],t.prototype,"fontSize",void 0),J([(0,o.property)({onSet:function(e,t){var o=k(e.backcolor).opacity;t.panelBackgroundTransparency!==o&&(t.panelBackgroundTransparency=o)}})],t.prototype,"questionPanel",void 0),J([(0,o.property)({onSet:function(e,t){var o=k(e.backcolor).opacity;t.questionBackgroundTransparency!==o&&(t.questionBackgroundTransparency=o)}})],t.prototype,"editorPanel",void 0),t}(o.Base);o.Serializer.addClass("theme",[{type:"dropdown",name:"themeName",choices:Ho.map((function(e){return{value:e,text:Z("theme.names."+e)}})),category:"general"},{type:"buttongroup",name:"colorPalette",displayName:"",choices:[{value:"light"},{value:"dark"}],category:"general",enableIf:function(e){return!e||e.hasVariations(!0)}},{type:"buttongroup",name:"isPanelless",choices:[{value:!1},{value:!0}],category:"general",enableIf:function(e){return!e||e.hasVariations(!1)}},{type:"spinedit",isSerializable:!1,name:"scale",onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"cornerRadius",onPropertyEditorUpdate:function(e,t){t&&(t.unit="px",t.min=0)}},{name:"advancedMode",type:"switchToggle",isSerializable:!1,default:!1,onPropertyEditorUpdate:function(e,t){t&&(t.titleLocation="hidden",t.renderAs="switch")}},{type:"spinedit",isSerializable:!1,name:"fontSize",onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"panelBackgroundTransparency",default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5)}},{type:"spinedit",isSerializable:!1,name:"questionBackgroundTransparency",default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5)}},{type:"backgroundcornerradius",name:"editorPanel"},{type:"backgroundcornerradius",name:"questionPanel"}],(function(e){return new Di})),o.Serializer.addProperties("theme",[{name:"backgroundImage:file",onPropertyEditorUpdate:function(e,t){t&&(t.storeDataAsText=!1,t.acceptedTypes="image/*")}},{name:"backgroundImageFit",displayName:"",enableIf:function(e){return!!e.backgroundImage},choices:[{value:"auto"},{value:"contain"},{value:"cover"}],default:"cover"},{name:"backgroundImageAttachment",displayName:"",enableIf:function(e){return!!e.backgroundImage},choices:[{value:"fixed"},{value:"scroll"}],default:"scroll"},{type:"spinedit",isSerializable:!1,name:"backgroundOpacity",enableIf:function(e){return!!e.backgroundImage},default:100,onPropertyEditorUpdate:function(e,t){t&&(t.unit="%",t.min=0,t.max=100,t.step=5,t.titleLocation="left")}},{type:"header",name:"header",isSerializable:!1,onPropertyEditorUpdate:function(e,t){if(t){var o=t.contentPanel.elements,i=function(e){"panel"===e.getType()&&e.elements.forEach((function(e){i(e)}));var t=e.obj;if(t){var o=e.property;o&&o.onPropertyEditorUpdate&&o.onPropertyEditorUpdate(t,e)}};o.forEach((function(e){i(e)}))}}},{type:"color",isSerializable:!1,name:"primaryColor"},{type:"dropdown",name:"--sjs-font-family",default:i.themeEditor.defaultFontFamily,choices:[].concat(ri),onPropertyEditorUpdate:function(e,t){t&&(t.allowClear=!1,t.choices=[].concat(ri))}},{name:"--sjs-font-size",visible:!1,default:"16px"},{name:"--sjs-corner-radius",visible:!1},{name:"--sjs-base-unit",visible:!1},{name:"--sjs-corner-radius",visible:!1},{type:"font",name:"pageTitle",default:{family:i.themeEditor.defaultFontFamily,weight:"700",size:24}},{type:"font",name:"pageDescription",default:{family:i.themeEditor.defaultFontFamily,weight:"700",size:24}},{type:"shadoweffects",name:"--sjs-shadow-small",onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-small",Ci(t))}},{type:"font",name:"questionTitle",default:{family:i.themeEditor.defaultFontFamily,weight:"600",size:16}},{type:"font",name:"questionDescription",default:{family:i.themeEditor.defaultFontFamily,weight:"400",size:16}},{type:"shadoweffects",name:"--sjs-shadow-inner",onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-inner",Ci(t))}},{type:"font",name:"editorFont",default:{family:i.themeEditor.defaultFontFamily,weight:"400",size:16}},{type:"coloralpha",name:"--sjs-border-default",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.borderDefault"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-border-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.borderLight"),t.colorTitleLocation="left")}},{name:"--sjs-general-backcolor",visible:!1},{name:"--sjs-general-backcolor-dark",visible:!1},{name:"--sjs-general-backcolor-dim-light",visible:!1},{name:"--sjs-general-backcolor-dim-dark",visible:!1},{name:"--sjs-general-forecolor",visible:!1},{name:"--sjs-general-forecolor-light",visible:!1},{name:"--sjs-general-dim-forecolor",visible:!1},{name:"--sjs-general-dim-forecolor-light",visible:!1},{name:"--sjs-secondary-backcolor",visible:!1},{name:"--sjs-secondary-backcolor-light",visible:!1},{name:"--sjs-secondary-backcolor-semi-light",visible:!1},{name:"--sjs-secondary-forecolor",visible:!1},{name:"--sjs-secondary-forecolor-light",visible:!1},{name:"--sjs-shadow-small-reset",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-small-reset",Ci(t))}},{name:"--sjs-shadow-medium",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-medium",Ci(t))}},{name:"--sjs-shadow-large",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-large",Ci(t))}},{name:"--sjs-shadow-inner-reset",visible:!1,onSetValue:function(e,t){e.setPropertyValue("--sjs-shadow-inner-reset",Ci(t))}},{name:"--sjs-border-light",visible:!1},{name:"--sjs-border-default",visible:!1},{name:"--sjs-border-inside",visible:!1},{name:"--sjs-special-red-forecolor",visible:!1},{name:"--sjs-special-green",visible:!1},{name:"--sjs-special-green-light",visible:!1},{name:"--sjs-special-green-forecolor",visible:!1},{name:"--sjs-special-blue",visible:!1},{name:"--sjs-special-blue-light",visible:!1},{name:"--sjs-special-blue-forecolor",visible:!1},{name:"--sjs-special-yellow",visible:!1},{name:"--sjs-special-yellow-light",visible:!1},{name:"--sjs-special-yellow-forecolor",visible:!1},{name:"--sjs-article-font-xx-large-textDecoration",visible:!1},{name:"--sjs-article-font-xx-large-fontWeight",visible:!1},{name:"--sjs-article-font-xx-large-fontStyle",visible:!1},{name:"--sjs-article-font-xx-large-fontStretch",visible:!1},{name:"--sjs-article-font-xx-large-letterSpacing",visible:!1},{name:"--sjs-article-font-xx-large-lineHeight",visible:!1},{name:"--sjs-article-font-xx-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-xx-large-textCase",visible:!1},{name:"--sjs-article-font-x-large-textDecoration",visible:!1},{name:"--sjs-article-font-x-large-fontWeight",visible:!1},{name:"--sjs-article-font-x-large-fontStyle",visible:!1},{name:"--sjs-article-font-x-large-fontStretch",visible:!1},{name:"--sjs-article-font-x-large-letterSpacing",visible:!1},{name:"--sjs-article-font-x-large-lineHeight",visible:!1},{name:"--sjs-article-font-x-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-x-large-textCase",visible:!1},{name:"--sjs-article-font-large-textDecoration",visible:!1},{name:"--sjs-article-font-large-fontWeight",visible:!1},{name:"--sjs-article-font-large-fontStyle",visible:!1},{name:"--sjs-article-font-large-fontStretch",visible:!1},{name:"--sjs-article-font-large-letterSpacing",visible:!1},{name:"--sjs-article-font-large-lineHeight",visible:!1},{name:"--sjs-article-font-large-paragraphIndent",visible:!1},{name:"--sjs-article-font-large-textCase",visible:!1},{name:"--sjs-article-font-medium-textDecoration",visible:!1},{name:"--sjs-article-font-medium-fontWeight",visible:!1},{name:"--sjs-article-font-medium-fontStyle",visible:!1},{name:"--sjs-article-font-medium-fontStretch",visible:!1},{name:"--sjs-article-font-medium-letterSpacing",visible:!1},{name:"--sjs-article-font-medium-lineHeight",visible:!1},{name:"--sjs-article-font-medium-paragraphIndent",visible:!1},{name:"--sjs-article-font-medium-textCase",visible:!1},{name:"--sjs-article-font-default-textDecoration",visible:!1},{name:"--sjs-article-font-default-fontWeight",visible:!1},{name:"--sjs-article-font-default-fontStyle",visible:!1},{name:"--sjs-article-font-default-fontStretch",visible:!1},{name:"--sjs-article-font-default-letterSpacing",visible:!1},{name:"--sjs-article-font-default-lineHeight",visible:!1},{name:"--sjs-article-font-default-paragraphIndent",visible:!1},{name:"--sjs-article-font-default-textCase",visible:!1},{type:"color",name:"--sjs-general-backcolor-dim"},{type:"coloralpha",name:"--sjs-primary-backcolor",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryDefaultColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-backcolor-dark",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryDarkColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-backcolor-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryLightColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-forecolor",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryForecolor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-primary-forecolor-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.primaryForecolorLight"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-special-red",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.fontColor"),t.colorTitleLocation="left")}},{type:"coloralpha",name:"--sjs-special-red-light",displayName:"",onPropertyEditorUpdate:function(e,t){t&&(t.colorTitle=Z("theme.backgroundColor"),t.colorTitleLocation="left")}}]),r(3071);var ki=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getSwitcherIconCss=function(){return(new o.CssClassBuilder).append("svc-switcher__icon").append("svc-switcher__icon--checked",this.checked).toString()},t.prototype.getActionBarItemCss=function(){return"svc-switcher "+e.prototype.getActionBarItemCss.call(this)},J([(0,o.property)()],t.prototype,"checked",void 0),t}(o.Action),ji={theme:{properties:[{name:"header",tab:"header"},{name:"--sjs-general-backcolor-dim",tab:"background"},{name:"backgroundImage",tab:"background"},{name:"backgroundImageFit",tab:"background"},{name:"backgroundImageAttachment",tab:"background"},{name:"backgroundOpacity",tab:"background"},{name:"primaryColor",tab:"appearancecolor"},{name:"panelBackgroundTransparency",tab:"appearancecolor"},{name:"questionBackgroundTransparency",tab:"appearancecolor"},{name:"--sjs-primary-backcolor",tab:"appearanceprimarycolor"},{name:"--sjs-primary-backcolor-dark",tab:"appearanceprimarycolor"},{name:"--sjs-primary-backcolor-light",tab:"appearanceprimarycolor"},{name:"--sjs-primary-forecolor",tab:"appearanceprimarycolor"},{name:"--sjs-primary-forecolor-light",tab:"appearanceprimarycolor"},{name:"--sjs-special-red",tab:"appearanceprimarycolor"},{name:"--sjs-special-red-light",tab:"appearanceprimarycolor"},{name:"--sjs-font-family",tab:"appearancefont"},{name:"fontSize",tab:"appearancefont"},{name:"scale",tab:"appearanceother"},{name:"cornerRadius",tab:"appearanceother"},{name:"advancedMode",tab:"appearanceadvancedmode"},{name:"pageTitle",tab:"appearancepage"},{name:"pageDescription",tab:"appearancepage"},{name:"questionPanel",tab:"appearancequestion"},{name:"--sjs-shadow-small",tab:"appearancequestion"},{name:"questionTitle",tab:"appearancequestion"},{name:"questionDescription",tab:"appearancequestion"},{name:"editorPanel",tab:"appearanceinput"},{name:"--sjs-shadow-inner",tab:"appearanceinput"},{name:"editorFont",tab:"appearanceinput"},{name:"--sjs-border-default",tab:"appearancelines"},{name:"--sjs-border-light",tab:"appearancelines"}],tabs:[{name:"header",index:100},{name:"background",index:200},{name:"appearance",index:300},{name:"appearancecolor",parent:"appearance",index:100},{name:"appearancefont",parent:"appearance",index:200},{name:"appearanceother",parent:"appearance",index:300},{name:"appearanceadvancedmode",parent:"appearance",index:350},{name:"appearanceprimarycolor",parent:"appearance",index:400},{name:"appearancepage",parent:"appearance",index:500},{name:"appearancequestion",parent:"appearance",index:600},{name:"appearanceinput",parent:"appearance",index:700},{name:"appearancelines",parent:"appearance",index:800}]},"header@header":{properties:[{name:"headerView"},{name:"logoPosition"},{name:"surveyTitle"},{name:"surveyDescription"},{name:"height",tab:"layout"},{name:"mobileHeight",tab:"layout"},{name:"inheritWidthFrom",tab:"layout"},{name:"textAreaWidth",tab:"layout"},{name:"backgroundColorSwitch",tab:"background"},{name:"backgroundColor",tab:"background"},{name:"backgroundImage",tab:"background"},{name:"backgroundImageFit",tab:"background"},{name:"backgroundImageOpacity",tab:"background"},{name:"overlapEnabled",tab:"background"},{name:"headerTitle",tab:"header"},{name:"headerDescription",tab:"header"},{name:"logoPositionX",tab:"positions"},{name:"logoPositionY",tab:"positions"},{name:"titlePositionX",tab:"positions"},{name:"titlePositionY",tab:"positions"},{name:"descriptionPositionX",tab:"positions"},{name:"descriptionPositionY",tab:"positions"}],tabs:[{name:"settings"},{name:"layout",parent:"settings",index:100},{name:"background",parent:"settings",index:200},{name:"header",parent:"settings",index:300},{name:"positions",parent:"settings",index:400}]}},Ri={autoGenerateProperties:!0,classes:ji},Bi=function(){function e(){}return e.definition=ji,e}(),qi=function(){function e(e){var t=this;this.creator=e,this.allowModifyTheme=!0,this.simulatorCssClasses=o.surveyCss[o.defaultV2ThemeName],this._availableThemes=[].concat(Ho),this._showOneCategoryInPropertyGrid=!1,this._advancedModeValue=!1,this.creatorPropertyChanged=function(e,o){"isMobileView"===o.name&&t.updateVisibilityOfPropertyGridGroups()},this.saveToFileHandler=F,this.autoSaveTimerId=null,this.onThemeSelected=new o.EventBase,this.onThemePropertyChanged=new o.EventBase,this.onAllowModifyTheme=new o.EventBase,e.addPluginTab("theme",this),this.simulatorCssClasses=o.surveyCss[o.defaultV2ThemeName],this.tabControlModel=new No(this.creator.sidebar),this.createActions().forEach((function(t){return e.toolbar.actions.push(t)})),this.propertyGrid=new st(void 0,e,Ri),this.propertyGrid.surveyInstanceCreatedArea="theme-tab:property-grid";var i=new Po(this.propertyGrid,e);this.propertyGridTab=this.creator.sidebar.addPage("theme","svc-property-grid",i),this.propertyGridTab.caption=G.getString("ed.themePropertyGridTitle"),this.themeModel=new Di,e.registerShortcut("undo_theme",{name:"undo",affectedTab:"theme",hotKey:{ctrlKey:!0,keyCode:90},macOsHotkey:{keyCode:90},execute:function(){return t.undo()}}),e.registerShortcut("redo_theme",{name:"redo",affectedTab:"theme",hotKey:{ctrlKey:!0,keyCode:89},macOsHotkey:{keyCode:89},execute:function(){return t.redo()}}),e.onPropertyChanged.add(this.creatorPropertyChanged)}return Object.defineProperty(e.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid!==e&&(this._showOneCategoryInPropertyGrid=e,this.creator.sidebar.hideSideBarVisibilityControlActions=e,this.updateAdvancedModeQuestion(),this.propertyGrid.showOneCategoryInPropertyGrid=e,this.propertyGrid.setObj(this.creator.selectedElement),"theme"===this.creator.activeTab&&this.updateTabControl())},enumerable:!1,configurable:!0}),e.prototype.updateAdvancedModeQuestion=function(){var e=this.propertyGrid.survey.getQuestionByName("advancedMode");e&&(e.visible=this.showOneCategoryInPropertyGrid,e.value=this._advancedModeValue)},e.prototype.createVisibleUpdater=function(){var e=this;return new o.ComputedUpdater((function(){return"theme"===e.creator.activeTab}))},e.prototype.createAppearanceAdvancedModeAction=function(){var e=this,t=new ki({id:"advancedMode",component:"svc-switcher",ariaRole:"checkbox",css:"sv-theme-group_title-action",title:Z("theme.advancedMode"),visible:!this.creator.isMobileView,action:function(){t.checked=!t.checked,e.propertyGrid.survey.getQuestionByName("advancedMode")&&(e.propertyGrid.survey.getQuestionByName("advancedMode").value=t.checked)}});t.checked=this._advancedModeValue,this.advancedModeSwitcher=t},e.prototype.addSubGroupTitle=function(e,t){if(!e.getQuestionByName(t)){var i=o.Serializer.createClass("html");i.fromJSON({name:t,visibleIf:"{advancedMode} = true",html:"<div class='spg-theme-group-caption'>".concat(Z(t),"</div>")}),e.addElement(i)}},e.prototype.updateSubGroups=function(e){var t=this;["appearancelines","appearanceinput","appearancequestion","appearancepage","appearanceprimarycolor"].forEach((function(e){return t.setVisibleIf(e,!0)})),["appearancecolor","appearancefont","appearanceother"].forEach((function(e){return t.setVisibleIf(e,!1)})),this.addSubGroupTitle(e.getPanelByName("appearanceprimarycolor"),"theme.pageTitle"),this.addSubGroupTitle(e.getPanelByName("appearancepage"),"theme.questionTitle"),this.addSubGroupTitle(e.getPanelByName("appearancequestion"),"theme.editorPanel"),this.addSubGroupTitle(e.getPanelByName("appearanceinput"),"theme.lines")},e.prototype.updatePropertyGridEditorsAvailability=function(){var e=this.model.survey,t=this.propertyGrid.survey.pages[0],o=null==t?void 0:t.getElementByName("header");if(o&&o.elements.length>0){var i=o.elements[0].contentPanel;this.setCoverPropertiesFromSurvey(i,e)}var n=this.propertyGrid.survey.getQuestionByName("pageTitle"),r=e.isSinglePage?e.pages[0].elements:e.pages;n&&(n.readOnly=!r.some((function(e){return!!e.title})));var a=this.propertyGrid.survey.getQuestionByName("pageDescription");a&&(a.readOnly=!r.some((function(e){return!!e.description})))},e.prototype.updatePropertyGridColorEditorWithPredefinedColors=function(){var e=this,t=this.propertyGrid.survey.pages[0],o=null==t?void 0:t.getElementByName("header");if(o&&o.elements.length>0){var i=o.elements[0].contentPanel.getQuestionByName("backgroundColor");i&&(i.choices=Qo(this.themeModel.colorPalette))}this.propertyGrid.survey.getAllQuestions().forEach((function(t){-1!==["color","coloralpha"].indexOf(t.getType())&&(t.choices=Qo(e.themeModel.colorPalette))}))},e.prototype._setPGEditorPropertyValue=function(e,t,o){e&&(e[t]=o)},e.prototype.setCoverPropertiesFromSurvey=function(e,t){if(this._setPGEditorPropertyValue(e.getQuestionByName("headerView"),"value",t.headerView),this._setPGEditorPropertyValue(e.getQuestionByName("logoPosition"),"value",t.logoPosition),this._setPGEditorPropertyValue(e.getQuestionByName("surveyTitle"),"readOnly",!t.hasTitle),this._setPGEditorPropertyValue(e.getQuestionByName("surveyDescription"),"readOnly",!t.hasDescription),this._setPGEditorPropertyValue(e.getQuestionByName("headerTitle"),"readOnly",!t.hasTitle),this._setPGEditorPropertyValue(e.getQuestionByName("headerDescription"),"readOnly",!t.hasDescription),this._setPGEditorPropertyValue(e.getQuestionByName("logoPositionX"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("logoPositionY"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("logoPosition"),"readOnly",!t.logo),this._setPGEditorPropertyValue(e.getQuestionByName("titlePositionX"),"readOnly",!t.title),this._setPGEditorPropertyValue(e.getQuestionByName("titlePositionY"),"readOnly",!t.title),this._setPGEditorPropertyValue(e.getQuestionByName("descriptionPositionX"),"readOnly",!t.description),this._setPGEditorPropertyValue(e.getQuestionByName("descriptionPositionY"),"readOnly",!t.description),t.showTOC){var o=e.getQuestionByName("inheritWidthFrom");this._setPGEditorPropertyValue(o,"value","container"),this._setPGEditorPropertyValue(o,"visible",!1)}},e.prototype.updateVisibilityOfPropertyGridGroups=function(){var e=this.propertyGrid.survey.pages[0],t=null==e?void 0:e.getElementByName("header");t&&(t.visible=!this.creator.isMobileView),this.advancedModeSwitcher&&(this.advancedModeSwitcher.visible=!this.creator.isMobileView)},e.prototype.setVisibleIf=function(e,t){var o=this.propertyGrid.survey.getPanelByName(e);o&&(o.visibleIf="{advancedMode} = ".concat(t))},e.prototype.updateTabControl=function(){this.showOneCategoryInPropertyGrid?(this.updateTabControlActions(),this.creator.sidebar.sideAreaComponentName="svc-tab-control",this.creator.sidebar.sideAreaComponentData=this.tabControlModel,this.creator.sidebar.header.componentName="svc-side-bar-header",this.creator.sidebar.header.componentData=this.creator.sidebar.header):(this.creator.sidebar.sideAreaComponentName="",this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.componentName="",this.creator.sidebar.header.componentData=void 0)},e.prototype.activate=function(){var e=this;this.model=new ni(this.creator,this.simulatorCssClasses),this.themeModel.initialize(this.creator.theme,this.creator.survey),this.creator.sidebar.hideSideBarVisibilityControlActions=this.showOneCategoryInPropertyGrid,this.update(),this.propertyGrid.survey.onOpenFileChooser.clear(),this.propertyGrid.obj=this.themeModel,this.propertyGrid.survey.mode="edit",this.propertyGrid.survey.getAllQuestions().forEach((function(e){return e.readOnly=!1})),this.onAvailableThemesChanged(this.availableThemes),this.updateAllowModifyTheme(),this.updateAdvancedModeQuestion();var t=JSON.parse(JSON.stringify(ze));t.root+=" spg-theme-builder-root",this.showOneCategoryInPropertyGrid&&(t.root+=" spg-root--one-category",t.page.root+=" spg-panel__content"),this.propertyGrid.survey.css=t,this.updateSubGroups(this.propertyGrid.survey),this.propertyGrid.survey.onGetPanelTitleActions.add((function(t,o){o.panel&&"appearance"==o.panel.name&&(e.createAppearanceAdvancedModeAction(),o.titleActions.push(e.advancedModeSwitcher))})),this.propertyGrid.survey.onOpenFileChooser.add((function(t,o){var i,n,r={};if(q(r,o.context,{element:e.themeModel,elementType:"theme"}),o.element){var a=o.element;r.propertyName=a.name,"settings"===(null===(n=null===(i=null==a?void 0:a.parent)||void 0===i?void 0:i.parent)||void 0===n?void 0:n.name)&&(r.elementType="header",r.element=r.element.header)}e.creator.chooseFiles(o.input,o.callback,r)})),this.propertyGrid.survey.onUpdatePanelCssClasses.add((function(t,o){var i,n,r;if(o.panel.hasParent){var a=null!==(i=o.panel.parent)&&void 0!==i?i:o.panel.parentQuestion;!a||a.hasParent&&"settings"!==a.name&&"settings"!==(null===(n=a.parentQuestion)||void 0===n?void 0:n.name)?(o.cssClasses.panel.container="spg-panel-group",o.cssClasses.panel.content="spg-panel-group__content"):(o.cssClasses.panel.container="spg-nested-panel",o.cssClasses.panel.content="spg-nested-panel__content")}else e.showOneCategoryInPropertyGrid&&(null===(r=o.panel.parent)||void 0===r?void 0:r.isPage)&&(o.cssClasses.panel.container="spg-panel-by-page",o.cssClasses.panel.content="spg-panel-by-page__content","appearanceother"===o.panel.name&&(o.cssClasses.panel.container+=" spg-panel--hidden-border"),"appearanceadvancedmode"===o.panel.name&&(o.cssClasses.panel.container+=" spg-panel--hidden-border spg-panel--padding"))})),this.updatePropertyGridEditorsAvailability(),this.updateVisibilityOfPropertyGridGroups(),this.updatePropertyGridColorEditorWithPredefinedColors(),this.creator.sidebar.activePage=this.propertyGridTab.id,this.propertyGridTab.visible=!0,this.updateTabControl(),this.expandCategoryIfNeeded()},e.prototype.expandCategoryIfNeeded=function(){this.model.survey.isEmpty||this.propertyGrid.expandCategoryIfNeeded()},e.prototype.updateTabControlActions=function(){var e=this;if(this.showOneCategoryInPropertyGrid){var t=this.propertyGrid.survey.pages.map((function(o){var i=new kt({id:o.name,tooltip:o.title,iconName:Lo[o.name]||Lo[void 0],active:o.name===e.propertyGrid.survey.currentPage.name,pressed:!1,action:function(){e.creator.sidebar.expandSidebar(),e.propertyGrid.survey.currentPage=o,e.creator.sidebar.header.subTitle=o.title,t.forEach((function(e){return e.active=!1})),i.active=!0}});return i}));this.tabControlModel.topToolbar.setItems(t),this.creator.sidebar.header.subTitle=this.propertyGrid.survey.currentPage.title}},e.prototype.update=function(){var e=this;if(this.model){this.model.simulator.landscape="portrait"!=this.creator.previewOrientation,this.model.testAgainAction=this.testAgainAction,this.model.prevPageAction=this.prevPageAction,this.model.nextPageAction=this.nextPageAction;var t={showPagesInTestSurveyTab:this.creator.showPagesInTestSurveyTab};this.model.initialize(this.creator.JSON,t),this.updateSimulatorTheme(),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction.css=this.model.showInvisibleElements?"sv-action-bar-item--active":"",this.invisibleToggleAction.visible=this.model.isRunning),this.updateUndeRedoActions(),this.themeModel.undoRedoManager.canUndoRedoCallback=function(){e.updateUndeRedoActions()},this.model.show(),this.model.onPropertyChanged.add((function(t,o){"isRunning"===o.name&&(e.invisibleToggleAction&&(e.invisibleToggleAction.visible=e.model.isRunning),e.testAgainAction.visible=!e.model.isRunning)})),this.themeModel.onThemeSelected.add((function(t,o){e.syncTheme(o.theme),e.resetTheme.enabled=Ni(t.defaultSessionTheme)!==Ni(o.theme),e.saveThemeAction.enabled=!0,e.onThemeSelected.fire(e,o),e.creator.isAutoSave&&e.processAutoSave(),e.propertyGrid.survey.editingObj=void 0,e.propertyGrid.survey.editingObj=t,e.updateAllowModifyTheme(),e.updatePropertyGridColorEditorWithPredefinedColors()})),this.themeModel.onThemePropertyChanged.add((function(t,o){e.syncTheme(),"--sjs-base-unit"==o.name&&e.model.survey.triggerResponsiveness(!0),"logoPosition"==o.name&&(e.creator.survey.logoPosition=o.value,e.model.survey.logoPosition=o.value),e.resetTheme.enabled=!0,e.saveThemeAction.enabled=!0,e.onThemePropertyChanged.fire(e,o),e.creator.isAutoSave&&e.processAutoSave()})),this.themeModel.onAllowModifyTheme.add((function(t,o){e.onAllowModifyTheme.fire(e,o)})),this.resetTheme.enabled=Ni(this.themeModel.defaultSessionTheme)!==Ni(this.creator.theme)||this.isModified,this.updateTabControl()}},e.prototype.updateAllowModifyTheme=function(){var e=this,t={theme:this.themeModel,allow:!this.creator.readOnly};this.onAllowModifyTheme.fire(this,t),this.propertyGrid.survey.getAllQuestions().forEach((function(o){-1===["themeName","colorPalette","isPanelless"].indexOf(o.name)&&(o.readOnly=e.creator.onIsPropertyReadOnlyCallback(e.themeModel,e.themeModel.getPropertyByName(o.name),!t.allow,void 0,void 0,!1))}))},e.prototype.deactivate=function(){var e;return this.model&&(this.simulatorCssClasses=this.model.survey.css,this.model.onPropertyChanged.clear(),this.themeModel.onThemeSelected.clear(),this.themeModel.onThemePropertyChanged.clear(),this.themeModel.onAllowModifyTheme.clear(),this.model.onSurveyCreatedCallback=void 0,this.model.dispose(),this.model=void 0,this.creator.sidebar.hideSideBarVisibilityControlActions=!1),this._advancedModeValue=!!(null===(e=this.propertyGrid.survey.getQuestionByName("advancedMode"))||void 0===e?void 0:e.value),this.creator.sidebar.sideAreaComponentName=void 0,this.creator.sidebar.sideAreaComponentData=void 0,this.creator.sidebar.header.reset(),this.propertyGridTab.visible=!1,this.testAgainAction.visible=!1,this.invisibleToggleAction&&(this.invisibleToggleAction.visible=!1),!0},e.prototype.exportToFile=function(e){var t=JSON.parse(JSON.stringify(this.themeModel.toJSON())),o=JSON.stringify(t,null,4),i=new Blob([o],{type:"application/json"});this.saveToFileHandler(e,i)},e.prototype.importFromFile=function(e,t){var o=this,i=new FileReader;i.onload=function(e){var n=JSON.parse(i.result);o.themeModel&&o.themeModel.setTheme(n),t&&t(n)},i.readAsText(e)},e.prototype.createActions=function(){var e=this,t=[];return this.designerAction=new o.Action({id:"svd-designer",iconName:"icon-config",action:function(){e.creator.makeNewViewActive("designer")},visible:this.createVisibleUpdater(),locTitleName:"ed.designer",showTitle:!1}),this.prevPageAction=new o.Action({id:"prevPage",iconName:"icon-arrow-left_16x16",needSeparator:new o.ComputedUpdater((function(){return e.creator.isMobileView})),visible:!1}),this.nextPageAction=new o.Action({id:"nextPage",iconName:"icon-arrow-right_16x16",visible:!1}),this.previewAction=new o.Action({id:"svd-preview",iconName:"icon-preview",active:!0,visible:this.createVisibleUpdater(),locTitleName:"tabs.preview",showTitle:!1,action:function(){}}),this.testAgainAction=new o.Action({id:"testSurveyAgain",visible:!1,locTitleName:"ed.testSurveyAgain",action:function(){e.model.testAgain()}}),this.undoAction=new o.Action({id:"action-undo-theme",iconName:"icon-undo",locTitleName:"ed.undo",showTitle:!1,visible:this.createVisibleUpdater(),action:function(){return e.undo()}}),this.redoAction=new o.Action({id:"action-redo-theme",iconName:"icon-redo",locTitleName:"ed.redo",showTitle:!1,visible:this.createVisibleUpdater(),action:function(){return e.redo()}}),t.push(this.undoAction),t.push(this.redoAction),this.saveThemeAction=new o.Action({id:"svd-save-theme",iconName:"icon-save",action:function(){e.creator.saveThemeActionHandler(),e.saveThemeAction.enabled=!1},active:!1,enabled:!1,visible:new o.ComputedUpdater((function(){return I("theme"===e.creator.activeTab,e.creator.showSaveButton)})),locTitleName:"ed.saveTheme",locTooltipName:"ed.saveThemeTooltip",showTitle:!1}),t.push(this.saveThemeAction),this.resetTheme=new o.Action({id:"svc-reset-theme",iconName:"icon-reset",locTitleName:"ed.themeResetButton",locTooltipName:"ed.themeResetButton",mode:"small",visible:this.createVisibleUpdater(),action:function(){o.settings.confirmActionAsync(Z("ed.themeResetConfirmation"),(function(t){t&&e.themeModel.resetTheme()}),Z("ed.themeResetConfirmationOk"),G.currentLocale)}}),t.push(this.resetTheme),this.themeSettingsAction=new o.Action({id:"svc-theme-settings",iconName:"icon-theme",action:function(){e.creator.showSidebar||e.creator.setShowSidebar(!0,!0)},visible:this.createVisibleUpdater(),active:new o.ComputedUpdater((function(){return e.creator.showSidebar})),pressed:new o.ComputedUpdater((function(){return e.creator.showSidebar})),locTitleName:"ed.themeSettings",locTooltipName:"ed.themeSettingsTooltip",showTitle:!1}),t.push(this.themeSettingsAction),this.importAction=new o.Action({id:"svc-theme-import",iconName:"icon-load",locTitleName:"ed.themeImportButton",locTooltipName:"ed.themeImportButton",visible:this.createVisibleUpdater(),mode:"small",component:"sv-action-bar-item",needSeparator:!0,action:function(){document&&(e.inputFileElement||(e.inputFileElement=document.createElement("input"),e.inputFileElement.type="file",e.inputFileElement.style.display="none",e.inputFileElement.onchange=function(){e.inputFileElement.files.length<1||(e.importFromFile(e.inputFileElement.files[0]),e.inputFileElement.value="")}),e.inputFileElement.click())}}),t.push(this.importAction),this.exportAction=new o.Action({id:"svc-theme-export",iconName:"icon-download",locTitleName:"ed.themeExportButton",locTooltipName:"ed.themeExportButton",visible:this.createVisibleUpdater(),mode:"small",component:"sv-action-bar-item",action:function(){e.exportToFile(i.themeEditor.exportFileName)}}),t.push(this.exportAction),this.creator.showInvisibleElementsInTestSurveyTab&&(this.invisibleToggleAction=new o.Action({id:"showInvisible",iconName:"icon-invisible-items",mode:"small",locTitleName:"ts.showInvisibleElements",visible:!1,action:function(){e.model.showInvisibleElements=!e.model.showInvisibleElements,e.invisibleToggleAction.css=e.model.showInvisibleElements?"sv-action-bar-item--active":"",e.invisibleToggleAction.title=Z(e.model.showInvisibleElements?"ts.hideInvisibleElements":"ts.showInvisibleElements")}})),t},e.prototype.undo=function(){var e=this.model&&this.themeModel.undoRedoManager;e&&(e.suspend(),e.canUndo()&&e.undo(),e.resume())},e.prototype.redo=function(){var e=this.model&&this.themeModel.undoRedoManager;e&&(e.suspend(),e.canRedo()&&e.redo(),e.resume())},e.prototype.updateUndeRedoActions=function(){var e=this.themeModel.undoRedoManager;this.undoAction.enabled=e.canUndo(),this.redoAction.enabled=e.canRedo()},e.prototype.addFooterActions=function(){this.creator.footerToolbar.actions.push(this.designerAction),this.creator.footerToolbar.actions.push(this.previewAction),this.creator.footerToolbar.actions.push(this.prevPageAction),this.creator.footerToolbar.actions.push(this.nextPageAction),this.invisibleToggleAction&&this.creator.footerToolbar.actions.push(this.invisibleToggleAction),this.creator.footerToolbar.actions.push(this.themeSettingsAction)},e.prototype.syncTheme=function(e){var t=e||this.themeModel.toJSON();this.creator.theme=t,this.updateSimulatorTheme(t)},e.prototype.updateSimulatorTheme=function(e){this.model.survey&&this.model.survey.applyTheme(e||this.themeModel.toJSON())},Object.defineProperty(e.prototype,"saveThemeFunc",{get:function(){return this._saveThemeFuncValue},set:function(e){this._saveThemeFuncValue=e},enumerable:!1,configurable:!0}),e.prototype.processAutoSave=function(){var e=this,t=this.saveThemeFunc;!t&&this.creator.saveThemeFunc&&(t=function(){return e.creator.saveTheme()}),t&&(this.creator.autoSaveDelay<=0?t():(this.autoSaveTimerId&&clearTimeout(this.autoSaveTimerId),this.autoSaveTimerId=setTimeout((function(){clearTimeout(e.autoSaveTimerId),e.autoSaveTimerId=null,t&&t()}),this.creator.autoSaveDelay)))},Object.defineProperty(e.prototype,"availableThemes",{get:function(){return[].concat(this._availableThemes)},set:function(e){this._availableThemes=e||[],this.onAvailableThemesChanged(e),this.updateAllowModifyTheme()},enumerable:!1,configurable:!0}),e.prototype.onAvailableThemesChanged=function(e){var t=this.propertyGrid.survey.getQuestionByName("themeName");t&&(t.choices=e.map((function(e){return{value:e,text:Z("theme.names."+e)}})),-1===e.indexOf(t.value)&&this.themeModel.setTheme(this.themeModel.defaultSessionTheme)),this.propertyGrid.survey.runExpressions()},e.prototype.addTheme=function(e,t){void 0===t&&(t=!1);var o=Ni(e);return qo[o]=e,-1===this._availableThemes.indexOf(e.themeName)?t?(this.availableThemes=[e.themeName].concat(this.availableThemes),Di.DefaultTheme=e):this.availableThemes=this.availableThemes.concat([e.themeName]):this.availableThemes=this.availableThemes,o},e.prototype.removeTheme=function(e,t){void 0===t&&(t=!1);var o="string"==typeof e?qo[e]:e,i="string"==typeof e?e:Ni(o);if(o){delete qo[i],Di.DefaultTheme===o&&(Di.DefaultTheme=qo["default-light"]||qo[Object.keys(qo)[0]],this.themeModel.defaultSessionTheme=Di.DefaultTheme);var n=Object.keys(qo).filter((function(e){return 0===e.indexOf(o.themeName+"-")}));if(t&&n.length>0&&n.forEach((function(e){return delete qo[e]})),t||0===n.length){var r=this._availableThemes.indexOf(o.themeName);if(-1!==r){var a=this.availableThemes;a.splice(r,1),this.availableThemes=a}}}},e.prototype.getCurrentTheme=function(e){return void 0===e&&(e=!1),e?this.getThemeChanges():this.creator.theme},e.prototype.getThemeChanges=function(){return Mi(this.creator.theme)},Object.defineProperty(e.prototype,"isModified",{get:function(){var e=this.getThemeChanges(),t=Object.keys(e.cssVariables).length>0,o=Object.keys(e).some((function(e){return-1!==e.toLowerCase().indexOf("background")})),i=!!e.header&&0===Object.keys(e.header).length;return t||o||i},enumerable:!1,configurable:!0}),e.DefaultTheme=qo["default-light"],e}(),Hi=function(){function e(e){var t=this;this.adorners=[],e.onSurfaceToolbarActionExecuted.add((function(e,o){var i="collapseAll"==o.action.id,n="expandAll"==o.action.id;(i||n)&&t.updateCollapsed(i)}))}return e.prototype.updateCollapsed=function(e){for(var t=this.adorners.length-1;t>=0;t--)this.adorners[t].allowExpandCollapse&&(this.adorners[t].collapsed=e)},e.prototype.add=function(e){this.adorners.push(e)},e.prototype.remove=function(e){this.adorners.splice(this.adorners.indexOf(e),1)},e}();const Fi={cssVariables:{"--sjs-primary-backcolor":"var(--sjs-primary-background-500)","--sjs-primary-backcolor-light":"var(--sjs-primary-background-10)","--sjs-primary-backcolor-dark":"var(--sjs-primary-background-400)","--sjs-primary-forecolor":"var(--sjs-primary-foreground-100)","--sjs-primary-forecolor-light":"var(--sjs-primary-foreground-25)","--sjs-secondary-backcolor":"var(--sjs-secondary-background-500)","--sjs-secondary-backcolor-light":"var(--sjs-secondary-background-10)","--sjs-secondary-backcolor-semi-light":"var(--sjs-secondary-background-25)","--sjs-secondary-forecolor":"var(--sjs-secondary-foreground-100)","--sjs-secondary-forecolor-light":"var(--sjs-secondary-forecolor-25)","--sjs-general-backcolor":"var(--sjs-layer-1-background-500)","--sjs-general-backcolor-dark":"var(--sjs-layer-1-background-400)","--sjs-general-forecolor":"var(--sjs-layer-1-foreground-100)","--sjs-general-forecolor-light":"var(--sjs-layer-1-foreground-50)","--sjs-general-backcolor-dim":"var(--sjs-layer-3-background-500)","--sjs-general-dim-forecolor":"var(--sjs-layer-3-foreground-100)","--sjs-general-dim-forecolor-light":"var(--sjs-layer-3-foreground-50)","--sjs-general-backcolor-dim-light":"var(--sjs-layer-2-background-500)","--sjs-general-backcolor-dim-dark":"var(--sjs-layer-2-background-400)","--sjs-border-default":"var(--sjs-border-25)","--sjs-border-light":"var(--sjs-border-10)","--sjs-border-inside":"var(--sjs-border-25)","--sjs-special-red":"var(--sjs-semantic-red-background-500)","--sjs-special-red-light":"var(--sjs-semantic-red-background-10)","--sjs-special-red-forecolor":"var(--sjs-semantic-red-foreground-100)","--sjs-special-green":"var(--sjs-semantic-green-background-500)","--sjs-special-green-light":"var(--sjs-semantic-green-background-10)","--sjs-special-green-forecolor":"var(--sjs-semantic-green-foreground-100)","--sjs-special-blue":"var(--sjs-semantic-blue-background-500)","--sjs-special-blue-light":"var(--sjs-semantic-blue-background-10)","--sjs-special-blue-forecolor":"var(--sjs-semantic-blue-foreground-100)","--sjs-special-yellow":"var(--sjs-semantic-yellow-background-500)","--sjs-special-yellow-light":"var(--sjs-semantic-yellow-background-10)","--sjs-special-yellow-forecolor":"var(--sjs-semantic-yellow-foreground-100)","--sjs-special-white":"var(--sjs-semantic-white-background-500)","--sjs-general-haze-background":"var(--sjs-special-haze)","--sjs-shadow-large-offset-x":"var(--lbr-shadow-large-offset-x)","--sjs-shadow-large-offset-y":"var(--lbr-shadow-large-offset-y)","--sjs-shadow-large-blur":"var(--lbr-shadow-large-blur)","--sjs-shadow-large-spread":"var(--lbr-shadow-large-spread)","--sjs-shadow-large-color":"var(--lbr-shadow-large-color)","--sjs-shadow-medium-offset-x":"var(--lbr-shadow-medium-offset-x)","--sjs-shadow-medium-offset-y":"var(--lbr-shadow-medium-offset-y)","--sjs-shadow-medium-blur":"var(--lbr-shadow-medium-blur)","--sjs-shadow-medium-spread":"var(--lbr-shadow-medium-spread)","--sjs-shadow-medium-color":"var(--lbr-shadow-medium-color)","--sjs-shadow-small-offset-x":"var(--lbr-shadow-small-offset-x)","--sjs-shadow-small-offset-y":"var(--lbr-shadow-small-offset-y)","--sjs-shadow-small-blur":"var(--lbr-shadow-small-blur)","--sjs-shadow-small-spread":"var(--lbr-shadow-small-spread)","--sjs-shadow-small-color":"var(--lbr-shadow-small-color)","--sjs-shadow-inner-offset-x":"var(--lbr-shadow-inner-offset-x)","--sjs-shadow-inner-offset-y":"var(--lbr-shadow-inner-offset-y)","--sjs-shadow-inner-blur":"var(--lbr-shadow-inner-blur)","--sjs-shadow-inner-spread":"var(--lbr-shadow-inner-spread)","--sjs-shadow-inner-color":"var(--lbr-shadow-inner-color)"}};var Qi={designer:"icon-config",theme:"icon-theme",editor:"icon-codeeditor-24x24",translation:"icon-language",preview:"icon-preview",logic:"icon-logic-24x24",customembeded:"icon-embedsurvey-24x24",default:"icon-undefined-24x24"},Ui=function(e){function t(t){return e.call(this,t)||this}return K(t,e),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-tabbed-menu-item").append("svc-tabbed-menu-item--selected",this.active).append("svc-tabbed-menu-item--disabled",void 0!==this.enabled&&!this.enabled).append("svc-tabbed-menu-item--icon",this.hasIcon).toString()},t.prototype.getTitleCss=function(){return(new o.CssClassBuilder).append("svc-text svc-tabbed-menu-item__text svc-text--normal").append("svc-text--bold",this.active).toString()},t.prototype.getIconCss=function(){return(new o.CssClassBuilder).append("svc-tabbed-menu-item__icon").toString()},Object.defineProperty(t.prototype,"hasTitle",{get:function(){return!this.hasIcon},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasIcon",{get:function(){return!this.disableShrink&&this.iconName&&"small"==this.mode},enumerable:!1,configurable:!0}),t}(o.Action),Gi=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o.dotsItem.popupModel.horizontalPosition="center",o.minVisibleItemsCount=1,o}return K(t,e),t.prototype.addTab=function(e,t,o,i,n){var r=this,a="test"===e?"preview":e,s=o?0==o.indexOf("ed.")?o:"":"tabs."+a,l=new Ui({id:e,locTitleName:s,title:o,componentContent:i||"svc-tab-"+e,data:t,iconName:Qi[a]||Qi.default,action:function(){r.creator.makeNewViewActive(e)},active:this.creator.viewType===e,disableHide:this.creator.viewType===e});l.disableShrink="menu"==this.creator.tabResponsivenessMode,void 0!==n&&n>=0&&n<this.actions.length?this.actions.splice(n,0,l):this.actions.push(l)},t.prototype.updateResponsivenessMode=function(){var e=this;this.actions.forEach((function(t){t.disableShrink="menu"==e.creator.tabResponsivenessMode})),this.raiseUpdate(!0)},t}(o.AdaptiveActionContainer);r(264),r(8445),r(6190);var Zi=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.Action),zi=function(e){function t(t){var o=e.call(this)||this;return o.creator=t,o}return K(t,e),t.prototype.getRenderedActions=function(){var e=this.actions,t=this.creator.sidebar.getExpandAction(),o=e.indexOf(t);return-1!==o&&(e.splice(o,1),e.push(t)),e},t}(o.ActionContainer),Ji=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(o.EventBase),Wi=function(e){function t(t,n){var r=e.call(this)||this;r.options=t,r.startEditTitleOnQuestionAddedValue=!0,r.isRTLValue=!1,r.alwaySaveTextInPropertyEditorsValue=!1,r.pageEditModeValue="standard",r.newQuestions=[],r.newPanels=[],r.plugins={},r.onElementDeleting=r.addCreatorEvent(),r.onGetPropertyReadOnly=r.addCreatorEvent(),r.onSurveyInstanceCreated=r.addCreatorEvent(),r.onGetObjectDisplayName=r.addCreatorEvent(),r.onHtmlToMarkdown=r.addCreatorEvent(),r.onElementAllowOperations=r.addCreatorEvent(),r.onDefineElementMenuItems=r.addCreatorEvent(),r.onShowingProperty=r.addCreatorEvent(),r.onCanShowProperty=r.onShowingProperty,r.onPropertyGridSurveyCreated=r.addCreatorEvent(),r.onPropertyEditorCreated=r.addCreatorEvent(),r.onPropertyEditorUpdateTitleActions=r.addCreatorEvent(),r.onPropertyGridShowModal=r.addCreatorEvent(),r.onCanDeleteItem=r.addCreatorEvent(),r.onCollectionItemDeleting=r.addCreatorEvent(),r.onCollectionItemAllowOperations=r.addCreatorEvent(),r.onItemValueAdded=r.addCreatorEvent(),r.onFastEntryFinished=r.addCreatorEvent(),r.onMatrixColumnAdded=r.addCreatorEvent(),r.onSetPropertyEditorOptions=r.addCreatorEvent(),r.onConfigureTablePropertyEditor=r.addCreatorEvent(),r.onGenerateNewName=r.addCreatorEvent(),r.onPropertyValidationCustomError=r.addCreatorEvent(),r.onPropertyValueChanging=r.addCreatorEvent(),r.onSurveyPropertyValueChanged=r.addCreatorEvent(),r.onConditionQuestionsGetList=r.addCreatorEvent(),r.onConditionGetTitle=r.addCreatorEvent(),r.onGetConditionOperator=r.addCreatorEvent(),r.onLogicItemDisplayText=r.addCreatorEvent(),r.onModified=r.addCreatorEvent(),r.onQuestionAdded=r.addCreatorEvent(),r.onPanelAdded=r.addCreatorEvent(),r.onPageAdded=r.addCreatorEvent(),r.onQuestionConverting=r.addCreatorEvent(),r.onGetPageActions=r.addCreatorEvent(),r.onDesignerSurveyCreated=r.addCreatorEvent(),r.onPreviewSurveyCreated=r.addCreatorEvent(),r.onTestSurveyCreated=r.onPreviewSurveyCreated,r.onNotify=r.addCreatorEvent(),r.onSelectedElementChanging=r.addCreatorEvent(),r.onSelectedElementChanged=r.addCreatorEvent(),r.onOpenFileChooser=r.addCreatorEvent(),r.onUploadFile=r.addCreatorEvent(),r.onTranslationStringVisibility=r.addCreatorEvent(),r.onTranslationLocaleInitiallySelected=r.addCreatorEvent(),r.onTranslationImportItem=r.addCreatorEvent(),r.onTranslationImported=r.addCreatorEvent(),r.onTranslationExportItem=r.addCreatorEvent(),r.onMachineTranslate=r.addCreatorEvent(),r.onTranslationItemChanging=r.addCreatorEvent(),r.onDragDropAllow=r.addCreatorEvent(),r.onDragOverLocationCalculating=r.addCreatorEvent(),r.onCreateCustomMessagePanel=r.addCreatorEvent(),r.maxLogicItemsInCondition=-1,r.showObjectTitles=!1,r.maxVisibleChoices=10,r.showTitlesInExpressions=!1,r.allowEditExpressionsInTextEditor=!0,r.maximumColumnsCount=i.propertyGrid.maximumColumnsCount,r.maximumChoicesCount=i.propertyGrid.maximumChoicesCount,r.minimumChoicesCount=i.propertyGrid.minimumChoicesCount,r.maximumRowsCount=i.propertyGrid.maximumRowsCount,r.maximumRateValues=i.propertyGrid.maximumRateValues,r.maxNestedPanels=-1,r.showPagesInTestSurveyTab=!0,r.showSimulatorInTestSurveyTab=!0,r.themeForPreview="defaultV2",r.hasPendingThemeChanges=!1,r._theme={cssVariables:{}},r._allowModifyPages=!0,r.showDefaultLanguageInTestSurveyTab="auto",r.showInvisibleElementsInTestSurveyTab=!0,r.allowChangeThemeInPreview=!0,r._tabResponsivenessMode="menu",r.showErrorOnFailedSave=!0,r.onActiveTabChanging=r.addCreatorEvent(),r.onActiveTabChanged=r.addCreatorEvent(),r.showSidebarValue=!0,r.onShowSidebarVisibilityChanged=r.addCreatorEvent(),r.onShowPropertyGridVisiblityChanged=r.addCreatorEvent(),r.onBeforeUndo=r.addCreatorEvent(),r.onBeforeRedo=r.addCreatorEvent(),r.onPageAdding=r.addCreatorEvent(),r.onDragStart=r.addCreatorEvent(),r.onBeforeDrop=r.onDragStart,r.onDragEnd=r.addCreatorEvent(),r.onAfterDrop=r.onDragEnd,r.animationEnabled=!1,r.onStateChanged=r.addCreatorEvent(),r.onSurfaceToolbarActionExecuted=r.addCreatorEvent(),r.expandCollapseManager=new Hi(r),r.notifier=new o.Notifier({root:"svc-notifier",rootWithButtons:"",info:"svc-notifier--info",error:"svc-notifier--error",success:"svc-notifier--success",button:"",shown:"svc-notifier--shown"}),r.addNewQuestionLast=!0,r.onKeyDownHandler=function(e){r.findSuitableShortcuts(e).forEach((function(t){(e.keyCode<48||89==e.keyCode||90==e.keyCode)&&ln(e.target)||t.execute(r.selectedElement)}))},r.shortcuts={},r.hiddenProperties={},r.translationLocalesOrder=[],r.autoSaveDelay=i.autoSave.delay,r.autoSaveTimerId=null,r.saveNo=0,r._syncSaveActions=function(e,t){var o=r._findAction("svd-save"),i=r._findAction("svd-save-theme");o&&i&&(e===r?i.enabled=o.enabled:o.enabled=i.enabled)},r.showTabsDefault=i.layout.showTabs,r.showToolbarDefault=i.layout.showToolbar,r.expandOnDragTimeOut=1e3,r.themeVariables={},r.allowDragPages=!1,r.collapsePagesOnDrag=!1,(n||"string"==typeof r.options||r.options instanceof String)&&(r.options=n||{},ee.warnText("Creator constructor has one parameter, as creator options, in V2.")),r.previewOrientation=t.previewOrientation,r.toolbarValue=new zi(r),r.toolbarValue.locOwner=r,r.tabbedMenu=new Gi(r),r.tabbedMenu.locOwner=r,r.selectionHistoryControllerValue=new be(r),r.sidebar=new Wo(r),r.setOptions(r.options),r.patchMetadata(),r.initSurveyWithJSON(void 0,!1),r.toolbox=new ve(r.options&&r.options.questionTypes?r.options.questionTypes:null,r,!0),r.updateToolboxIsCompact(),r.initTabs(),r.initDragDrop(),r.syncSaveButtons=void 0!==r.options.saveSurveyAndTheme?r.options.saveSurveyAndTheme:r.options.syncSaveButtons,r.isTouch=o.IsTouch;var a=r.sidebar.getExpandAction();return a&&r.toolbar.actions.push(a),r}return K(t,e),t.prototype.getMarkdownHtml=function(e,t){return null},t.prototype.getRenderer=function(e){return null},t.prototype.getRendererContext=function(e){return e},t.prototype.getProcessedText=function(e){return e},t.prototype.getLocale=function(){return this.locale},Object.defineProperty(t.prototype,"showPreviewTab",{get:function(){return this.showTestSurveyTab},set:function(e){this.showTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showOneCategoryInPropertyGrid",{get:function(){return this._showOneCategoryInPropertyGrid},set:function(e){this._showOneCategoryInPropertyGrid=e;var t=this.getPlugin("designer");t&&(t.showOneCategoryInPropertyGrid=e);var o=this.getPlugin("theme");o&&(o.showOneCategoryInPropertyGrid=e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowEditSurveyTitle",{get:function(){return this.getPropertyValue("allowEditSurveyTitle",!0)},set:function(e){this.setPropertyVisibility("survey",e,"title","description","logo","logoFit","showTitle","logoWidth","logoHeight"),this.setPropertyValue("allowEditSurveyTitle",e),this.designerPropertyGrid&&this.designerPropertyGrid.refresh()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSurveyTitle",{get:function(){return this.allowEditSurveyTitle},set:function(e){this.allowEditSurveyTitle=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"haveCommercialLicense",{get:function(){return!!o.hasLicense&&(0,o.hasLicense)(1)},set:function(e){console.warn("As of v1.9.101, the haveCommercialLicense property is not supported. To activate your license, use the setLicenseKey(key) method as shown on the following page: https://surveyjs.io/remove-alert-banner")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"licenseText",{get:function(){return this.getLocString("survey.license")},enumerable:!1,configurable:!0}),t.prototype.slk=function(e){(0,o.slk)(e)},Object.defineProperty(t.prototype,"startEditTitleOnQuestionAdded",{get:function(){return!this.isMobileView&&!this.toolbox.searchManager.filterString&&this.startEditTitleOnQuestionAddedValue},set:function(e){this.startEditTitleOnQuestionAddedValue=e},enumerable:!1,configurable:!0}),t.prototype.changePageModifications=function(e){void 0===e&&(e=!1),this.setPropertyVisibility("survey",e,"pages"),this.setPropertyVisibility("question",e,"page"),this.setPropertyVisibility("panel",e,"page"),this.showJSONEditorTab=!0===this.options.showJSONEditorTab},Object.defineProperty(t.prototype,"pageEditMode",{get:function(){return this.pageEditModeValue},set:function(e){this.pageEditModeValue=e;var t="single"!==this.pageEditModeValue;this.changePageModifications(t),o.settings.allowShowEmptyTitleInDesignMode=t,o.settings.allowShowEmptyDescriptionInDesignMode=t,"bypage"===this.pageEditModeValue&&(this.showPageNavigator=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolbarItems",{get:function(){return this.toolbarValue.actions},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolbar",{get:function(){return this.toolbarValue},enumerable:!1,configurable:!0}),t.prototype._findAction=function(e){return this.toolbarItems.filter((function(t){return t.id===e}))[0]},Object.defineProperty(t.prototype,"showingViewName",{get:function(){return this.activeTab},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isDesignerShowing",{get:function(){return"designer"===this.activeTab},enumerable:!1,configurable:!0}),t.prototype.showDesigner=function(){this.activeTab="designer"},Object.defineProperty(t.prototype,"isTestSurveyShowing",{get:function(){return this.isPreviewShowing},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isPreviewShowing",{get:function(){return"test"===this.activeTab},enumerable:!1,configurable:!0}),t.prototype.showTestSurvey=function(){this.showPreview()},t.prototype.showPreview=function(){this.activeTab="test"},t.prototype.addPluginTab=function(e,t,o,i,n){this.tabbedMenu.addTab(e,t,o,i,n),this.addPlugin(e,t)},t.prototype.addPlugin=function(e,t){this.plugins[e]=t},t.prototype.removePlugin=function(e){var t=this.getPlugin(e);if(t){var o=this.getTabIndex(e);o>-1&&this.tabs.splice(o,1),delete this.plugins[e],t.dispose&&t.dispose()}},t.prototype.getTabIndex=function(e){for(var t=0;t<this.tabs.length;t++)if(this.tabs[t].id===e)return t;return-1},t.prototype.getPlugin=function(e){return this.plugins[e]},Object.defineProperty(t.prototype,"showPagesInPreviewTab",{get:function(){return this.showPagesInTestSurveyTab},set:function(e){this.showPagesInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSimulatorInPreviewTab",{get:function(){return this.showSimulatorInTestSurveyTab},set:function(e){this.showSimulatorInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"themeEditor",{get:function(){return this.getPlugin("theme")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"saveThemeFunc",{get:function(){return this.saveThemeFuncValue},set:function(e){this.saveThemeFuncValue=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"theme",{get:function(){return this._theme},set:function(e){this._theme=e,this.hasPendingThemeChanges=!0,"theme"!==this.activeTab&&this.updatePlugin(this.activeTab)},enumerable:!1,configurable:!0}),t.prototype._doSaveThemeCore=function(e){var t=this;this.setState("saving"),this.saveThemeFunc&&(this.saveNo++,this.saveThemeFunc(this.saveNo,(function(o,i){t.saveNo===o&&(i?(t.setState("saved"),t.hasPendingThemeChanges=!1):(t.setState("modified"),t.showErrorOnFailedSave&&t.notify(t.getLocString("ed.saveError"),"error")),e&&e())})))},t.prototype.saveTheme=function(){this._doSaveThemeCore()},t.prototype.saveThemeActionHandler=function(){this.syncSaveButtons?this.save():this.saveTheme()},Object.defineProperty(t.prototype,"allowModifyPages",{get:function(){return this._allowModifyPages},set:function(e){this._allowModifyPages=e,this.changePageModifications(e)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showDefaultLanguageInPreviewTab",{get:function(){return this.showDefaultLanguageInTestSurveyTab},set:function(e){this.showDefaultLanguageInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showInvisibleElementsInPreviewTab",{get:function(){return this.showInvisibleElementsInTestSurveyTab},set:function(e){this.showInvisibleElementsInTestSurveyTab=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabResponsivenessMode",{get:function(){return this._tabResponsivenessMode},set:function(e){this._tabResponsivenessMode=e,this.tabbedMenu.updateResponsivenessMode()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tabs",{get:function(){return this.tabbedMenu.actions},set:function(e){this.tabbedMenu.actions=e},enumerable:!1,configurable:!0}),t.prototype.getLocString=function(e){return G.getString(e)},t.prototype.onSetReadOnly=function(e){},Object.defineProperty(t.prototype,"locale",{get:function(){return this.getPropertyValue("locale",G.currentLocale)},set:function(e){G.currentLocale!==e&&(G.currentLocale=e,this.setPropertyValue("locale",e),this.updateLocalizedStrings())},enumerable:!1,configurable:!0}),t.prototype.updateLocalizedStrings=function(){this.toolbox.updateTitles(),this.refreshPlugin();var e=this.selectedElement;e&&(this.selectElement(null),this.selectElement(e)),this.locStrsChanged()},t.prototype.locStrsChanged=function(){e.prototype.locStrsChanged.call(this),this.tabbedMenu.locStrsChanged(),this.toolbar.locStrsChanged()},t.prototype.refreshPlugin=function(){var e=this.currentPlugin;if(e){e.deactivate&&e.deactivate();var t=this.viewType;this.viewType="",e.activate(),this.viewType=t}},Object.defineProperty(t.prototype,"readOnly",{get:function(){return this.getPropertyValue("readOnly",!1)},set:function(e){var t=this.text;this.setPropertyValue("readOnly",e),this.onSetReadOnly(e),this.text=t},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRTL",{get:function(){return this.isRTLValue},set:function(e){this.isRTLValue=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"activeTab",{get:function(){return this.viewType},set:function(e){this.makeNewViewActive(e)},enumerable:!1,configurable:!0}),t.prototype.makeNewViewActive=function(e){var t=this;if(e==this.viewType)return!1;var o=this.currentPlugin;if(!o||!o.canDeactivateAsync)return this.switchViewType(e);o.canDeactivateAsync((function(){t.switchViewType(e)}))},t.prototype.switchViewType=function(e){var t,o,i=!0;if((null===(t=this.currentPlugin)||void 0===t?void 0:t.defaultAllowingDeactivate)&&void 0===(i=this.currentPlugin.defaultAllowingDeactivate()))return!1;var n={tabName:e,allow:i,model:null===(o=this.currentPlugin)||void 0===o?void 0:o.model};if(this.onActiveTabChanging.fire(this,n),n.allow){if(!this.canSwitchViewType())return!1;var r=this.activatePlugin(e);return this.viewType=e,this.onActiveTabChanged.fire(this,{tabName:e,plugin:r,model:r?r.model:void 0}),!0}},t.prototype.canSwitchViewType=function(){var e=this.currentPlugin;return!e||!e.deactivate||e.deactivate()},t.prototype.activatePlugin=function(e){var t=this.getPlugin(e);return t&&t.activate(),t},Object.defineProperty(t.prototype,"currentPlugin",{get:function(){return this.getPlugin(this.activeTab)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"toolboxCategories",{get:function(){return this.toolbox.categories},enumerable:!1,configurable:!0}),t.prototype.addCreatorEvent=function(){return this.addEvent()},t.prototype.updateToolboxIsCompact=function(e){if(this.toolbox){var t=null!=e&&null!=e;void 0!==this.toolbox.forceCompact?this.toolbox.isCompact=this.toolbox.forceCompact:"right"==this.toolboxLocation?this.toolbox.isCompact=this.showSidebar||t&&e:t&&this.toolbox.isCompact!==e&&(this.toolbox.isCompact=e)}},Object.defineProperty(t.prototype,"showToolbox",{get:function(){return this.showToolboxValue&&this.allowShowToolbox},set:function(e){!0!==e&&!1!==e&&ee.warnText("showToolbox is a boolean property now."),"none"===e||!1===e||"top"===e?this.showToolboxValue=!1:(!0===e||(this.toolboxLocation=e),this.showToolboxValue=!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showSidebar",{get:function(){return this.showSidebarValue},set:function(e){!0===e||!1===e?this.showSidebar!==e&&(this.setShowSidebar(e,!0),this.onShowPropertyGridVisiblityChanged.isEmpty||(ee.warnNonSupported("onShowPropertyGridVisiblityChanged","onShowSidebarVisibilityChanged"),this.onShowPropertyGridVisiblityChanged.fire(this,{show:e}))):ee.warnText("showSidebar is a boolean property now.")},enumerable:!1,configurable:!0}),t.prototype.setShowSidebar=function(e,t){void 0===t&&(t=!1),this.showSidebarValue=e,t&&(e?this.sidebar.expandedManually=!0:this.sidebar.collapsedManually=!0),this.updateToolboxIsCompact(),this.onShowSidebarVisibilityChanged.fire(this,{show:e})},Object.defineProperty(t.prototype,"showPropertyGrid",{get:function(){return ee.warnNonSupported("showPropertyGrid","showSidebar"),this.showSidebar},set:function(e){ee.warnNonSupported("showPropertyGrid","showSidebar"),!0===e||!1===e?this.showSidebar=e:ee.warnText("showSidebar is a boolean property.")},enumerable:!1,configurable:!0}),t.prototype.rightContainerActiveItem=function(e){ee.warnNonSupported("rightContainerActiveItem")},t.prototype.leftContainerActiveItem=function(e){ee.warnNonSupported("leftContainerActiveItem")},Object.defineProperty(t.prototype,"undoRedoManager",{get:function(){var e=this.getPlugin("undoredo");return e&&e.model.undoRedoManager},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"undoRedoController",{get:function(){var e=this.getPlugin("undoredo");return e&&e.model},enumerable:!1,configurable:!0}),t.prototype.startUndoRedoTransaction=function(e){void 0===e&&(e=""),this.undoRedoController&&this.undoRedoController.startTransaction(e)},t.prototype.stopUndoRedoTransaction=function(){this.undoRedoController&&this.undoRedoController.stopTransaction()},Object.defineProperty(t.prototype,"isProcessingUndoRedo",{get:function(){return this.undoRedoManager&&this.undoRedoManager.isProcessingUndoRedo},enumerable:!1,configurable:!0}),t.prototype.undo=function(){this.undoRedoController&&this.undoRedoController.undo()},t.prototype.redo=function(){this.undoRedoController&&this.undoRedoController.redo()},Object.defineProperty(t.prototype,"selectionHistoryController",{get:function(){return this.selectionHistoryControllerValue},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"currentPage",{get:function(){return this.survey.currentPage},set:function(e){this.survey.currentPage=e},enumerable:!1,configurable:!0}),t.prototype.canAddPage=function(e){var t={page:e,allow:!0};return this.onPageAdding.fire(this,t),t.allow},t.prototype.addPage=function(e,t,o){if(void 0===t&&(t=!0),!this.canAddPage(e))return null;if(void 0===o||o()){var i=e;return i?this.survey.addPage(i):i=this.addNewPageIntoSurvey(),t&&this.selectElement(i),i}},t.prototype.addNewPageIntoSurvey=function(){var e=ee.getNewPageName(this.survey.pages);return this.survey.addNewPage(e)},t.prototype.initTabs=function(){this.initPlugins(),this.initFooterToolbar()},t.prototype.getTabsInfo=function(){var e=this;return{designer:function(){return new Uo(e)},preview:function(){return new Ne(e)},theme:function(){return new qi(e)},logic:function(){return new ho(e)},editor:function(){return Te.hasAceEditor()?new Te(e):new Pe(e)},translation:function(){return new eo(e)}}},t.prototype.getAvailableTabNames=function(){var e=[],t=this.getTabsInfo();for(var o in t)e.push(o);return e},t.prototype.getTabNames=function(){var e=this.getAvailableTabNames(),t=[];return this.tabs.forEach((function(o){var i="test"===o.id?"preview":o.id;e.indexOf(i)>-1&&t.push(i)})),t},t.prototype.setTabs=function(e){var t=this;if(Array.isArray(e)){for(var o=this.getTabsInfo(),i=e.length-1;i>=0;i--)o[e[i]]||e.splice(i,1);if(0!==e.length){for(i=this.tabs.length-1;i>=0;i--){var n=this.tabs[i].id,r="test"===n?"preview":n;e.indexOf(r)<0&&this.removePlugin(n)}for(e.forEach((function(e){var i="preview"===e?"test":e;o[e]&&t.getTabIndex(i)<0&&o[e]()})),i=0;i<e.length;i++){var a=this.getTabIndex(e[i]);if(a>-1&&a!==i){var s=this.tabs[a];this.tabs.splice(a,1),this.tabs.splice(i,0,s)}}this.tabs.length>0&&this.makeNewViewActive(this.tabs[0].id)}}},t.prototype.initPlugins=function(){this.addPlugin("undoredo",new bo(this));var e=[];this.showDesignerTab&&e.push("designer"),this.showPreviewTab&&e.push("preview"),this.showThemeTab&&e.push("theme"),this.showLogicTab&&e.push("logic"),this.showJSONEditorTab&&e.push("editor"),this.showTranslationTab&&e.push("translation"),this.setTabs(e)},t.prototype.initFooterToolbar=function(){var e=this;this.footerToolbar||(this.footerToolbar=new o.ActionContainer,["designer","undoredo","test","theme"].forEach((function(t){var o=e.getPlugin(t);o&&o.addFooterActions&&o.addFooterActions()})))},t.prototype.getOptions=function(){return this.options||{}},t.prototype.setOptions=function(e){e||(e={});var t={showTestSurveyTab:"showPreviewTab",showDefaultLanguageInTestSurveyTab:"showDefaultLanguageInPreviewTab",showInvisibleElementsInPreviewTab:"showInvisibleElementsInTestSurveyTab"};for(var o in t)if(void 0!==e[o]){var i=t[o];void 0===e[i]&&(e[i]=e[o],delete e[o])}for(var o in this.options=e,e)this[o]=e[o]},t.prototype.setPropertyPlaceHolder=function(e,t,i){var n=o.Serializer.findProperty(e,t);n&&(n.placeholder=i)},t.prototype.setPropertyVisibility=function(e,t){for(var i=[],n=2;n<arguments.length;n++)i[n-2]=arguments[n];if(Array.isArray(i))for(var r=0;r<i.length;r++){var a=o.Serializer.findProperty(e,i[r]);a&&(t?delete this.hiddenProperties[a.id]:this.hiddenProperties[a.id]=!0)}},t.prototype.patchMetadata=function(){this.setPropertyPlaceHolder("survey","title","pe.surveyTitlePlaceholder"),this.setPropertyPlaceHolder("survey","description","pe.surveyDescriptionPlaceholder"),this.setPropertyVisibility("survey",!1,"logoPosition"),"single"!==this.pageEditMode&&(this.setPropertyPlaceHolder("page","title","pe.pageTitlePlaceholder"),this.setPropertyPlaceHolder("page","description","pe.pageDescriptionPlaceholder"))},t.prototype.isCanModifyProperty=function(e,t){var i,n,r=o.Serializer.findProperty(e.getType(),t);if(e instanceof o.ItemValue){i=e.locOwner,n=o.Serializer.findProperty(i.getType(),e.ownerPropertyName||t);var a=!0;if(i instanceof o.QuestionSelectBase&&(a=i.isItemInList(e)),!1===this.getElementAllowOperations(i).allowEdit)return!1;var s={allowDelete:!0,allowEdit:a,allowAdd:!0};if(this.onCollectionItemAllowingCallback(i,r,i.getPropertyValue(null==n?void 0:n.name),e,s),!1===s.allowEdit)return!1;if(this.onIsPropertyReadOnlyCallback(i,n,null==n?void 0:n.readOnly,null,null))return!1}return!(e instanceof o.SurveyElement&&!1===this.getElementAllowOperations(e).allowEdit)&&(!r||!this.onIsPropertyReadOnlyCallback(e,r,r.readOnly,i,n))},t.prototype.onIsPropertyReadOnlyCallback=function(e,t,o,i,n,r){if(!t)return!1;void 0===r&&(r=this.readOnly);var a=r||o;if(this.onGetPropertyReadOnly.isEmpty)return a;var s={obj:e,property:t,readOnly:a,propertyName:t.name,parentObj:i,parentProperty:n};return this.onGetPropertyReadOnly.fire(this,s),s.readOnly},Object.defineProperty(t.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),t.prototype.addCollectionItemsJson=function(e,t){var i=new o.SurveyModel(e);this.updateAddingSurvey(i),this.addSurveyPages(i,t)},t.prototype.updateAddingSurvey=function(e){this.updateAddingPages(e),this.updateAddingPanels(e),this.updateAddingQuestions(e),this.updateAddingCalculatedValules(e),this.updateAddingArrays(e)},t.prototype.updateAddingPages=function(e){this.updateAddingElements(e,e.pages,this.survey.pages,(function(e,t){e.name=ee.getNewPageName(t)}))},t.prototype.updateAddingExistingElements=function(){return[].concat(this.survey.getAllQuestions(!1,!0)).concat(this.survey.getAllPanels())},t.prototype.updateAddingPanels=function(e){this.updateAddingElements(e,e.getAllPanels(),this.updateAddingExistingElements(),(function(e,t){e.name=ee.getNewPanelName(t)}))},t.prototype.updateAddingQuestions=function(e){var t=new Ue(e,this);this.updateAddingElements(e,e.getAllQuestions(!1,!0),this.updateAddingExistingElements(),(function(e,o){var i=e.name;e.name=ee.getNewQuestionName(o),t.renameQuestion(i,e.name)}))},t.prototype.updateAddingCalculatedValules=function(e){var t=new Ue(e,this);this.updateAddingElements(e,e.calculatedValues,this.survey.calculatedValues,(function(e,o){var i=e.name;e.name=ee.getNewName(o,"var"),t.renameQuestion(i,e.name)}))},t.prototype.updateAddingArrays=function(e){var t=this;e.triggers.forEach((function(e){return t.survey.triggers.push(e)})),e.completedHtmlOnCondition.forEach((function(e){return t.survey.completedHtmlOnCondition.push(e)})),e.calculatedValues.forEach((function(e){return t.survey.calculatedValues.push(e)}))},t.prototype.updateAddingElements=function(e,t,o,i){var n=[],r={};o.forEach((function(e){e.name&&(r[e.name]=e)})),t.forEach((function(e){e.name&&r[e.name]&&n.push(e)}));var a=o.concat(t);n.forEach((function(e){i(e,a)}))},t.prototype.addSurveyPages=function(e,t){(void 0===t||t>=this.survey.pages.length)&&(t=-1);for(var o=0;o<e.pages.length;o++)t<0?this.survey.pages.push(e.pages[o]):this.survey.pages.splice(t+o,0,e.pages[o])},t.prototype.initSurveyWithJSON=function(e,t){var i=this;e||(e={logoPosition:"right"}),this.existingPages={};var n=this.createSurvey({},"designer",void 0,(function(t){t.skeletonHeight=188,t.css=o.defaultV2Css,t.setIsMobile(!!i.isMobileView),t.setDesignMode(!0),t.lazyRendering=!0,t.setJsonObject(e),t.isEmpty&&t.setJsonObject(i.getDefaultSurveyJson())}));n.pages.forEach((function(e){i.existingPages[e.id]=!0})),n.onQuestionAdded.add((function(e,t){i.doOnQuestionAdded(t.question,t.parentPanel)})),n.onPanelAdded.add((function(e,t){i.doOnPanelAdded(t.panel,t.parentPanel)})),n.onPageAdded.add((function(e,t){i.existingPages[t.page.id]||(i.existingPages[t.page.id]=!0,i.doOnPageAdded(t.page))})),n.onDragDropAllow.add((function(e,t){t.survey=e,i.onDragDropAllow.fire(i,t)})),this.setSurvey(n),this.updatePlugin(this.activeTab),"designer"!==this.activeTab&&this.updatePlugin("designer"),this.undoRedoController&&this.undoRedoController.updateSurvey()},t.prototype.updatePlugin=function(e){var t=this.getPlugin(this.activeTab);t&&t.update&&t.update()},t.prototype.initDragDrop=function(){this.initDragDropSurveyElements(),this.initDragDropChoices()},t.prototype.initDragDropSurveyElements=function(){var e=this;Ft.restrictDragQuestionBetweenPages=i.dragDrop.restrictDragQuestionBetweenPages,this.dragDropSurveyElements=new Ft(null,this),this.dragDropSurveyElements.onGetMaxNestedPanels=function(){return e.maxNestedPanels},this.dragDropSurveyElements.onDragOverLocationCalculating=function(t){e.onDragOverLocationCalculating.fire(e,t)};var t=!1;this.dragDropSurveyElements.onDragStart.add((function(o,i){t=!o.draggedElement.parent&&!o.draggedElement.isPage,e.onDragStart.fire(e,i),e.startUndoRedoTransaction("drag drop")})),this.dragDropSurveyElements.onDragEnd.add((function(o,i){e.stopUndoRedoTransaction();var n=t&&e.startEditTitleOnQuestionAdded;i.draggedElement&&(e.selectElement(i.draggedElement,void 0,!0,n),e.onDragEnd.fire(e,i),i.fromElement||i.draggedElement.isPage||e.setModified({type:"ADDED_FROM_TOOLBOX",question:i.draggedElement}))})),this.dragDropSurveyElements.onDragClear.add((function(o,i){var n;t=!1,e.stopUndoRedoTransaction(),e.collapsePagesOnDrag&&(null===(n=e.designerStateManager)||void 0===n||n.release(),e.restorePagesState())}))},Object.defineProperty(t.prototype,"designerStateManager",{get:function(){return this.getPlugin("designer").designerStateManager},enumerable:!1,configurable:!0}),t.prototype.collapseAllPages=function(){this.survey.pages.forEach((function(e){var t=Ut.GetAdorner(e);t&&(t.collapsed=!0)}))},t.prototype.restorePagesState=function(){var e=this;setTimeout((function(){e.survey.pages.forEach((function(e){Ut.RestoreStateFor(e)}))}),10)},t.prototype.initDragDropChoices=function(){var e=this;this.dragDropChoices=new o.DragDropChoices(null,this),this.dragDropChoices.onDragStart.add((function(t,o){e.startUndoRedoTransaction("drag drop")})),this.dragDropChoices.onDragEnd.add((function(t,o){e.stopUndoRedoTransaction(),e.selectElement(o.draggedElement,void 0,!1)})),this.dragDropChoices.onShortcutCreated=function(t){Object.keys(e.designTabSurveyThemeVariables).forEach((function(o){t.style.setProperty(o,e.designTabSurveyThemeVariables[o])}))}},t.prototype.updateElementsOnLocaleChanged=function(e,t){if("survey"===e.getType()&&"locale"===t)for(var o=this.survey.pages,i=0;i<o.length;i++)o[i].locStrsChanged()},t.prototype.updateConditionsOnNameChanged=function(e,t,o){if(this.isObjQuestion(e)){if("name"!==t||e.valueName||this.updateLogicOnQuestionNameChanged(o,e.name),"valueName"===t){var i=o||e.name,n=e.valueName?e.valueName:e.name;this.updateLogicOnQuestionNameChanged(i,n)}"name"===t&&e.isDescendantOf("selectbase")&&this.updateChoicesFromQuestionOnColumnNameChanged(o,e.name)}"name"===t&&e.isDescendantOf("matrixdropdowncolumn")&&this.updateLogicOnColumnNameChanged(e,o,e.name)},t.prototype.getSurveyLogicForUpdate=function(){return this.surveyLogicForUpdate&&this.surveyLogicForUpdate.survey!==this.survey&&(this.surveyLogicForUpdate=void 0),this.surveyLogicForUpdate||(this.surveyLogicForUpdate=this.createSurveyLogicForUpdate()),this.surveyLogicForUpdate},t.prototype.clearSurveyLogicForUpdate=function(e,t,o){!this.surveyLogicRenaming&&this.surveyLogicForUpdate&&e&&t&&this.needClearSurveyLogicForUpdate(e,t,o)&&(this.surveyLogicForUpdate=void 0)},t.prototype.needClearSurveyLogicForUpdate=function(e,t,i){if(Array.isArray(i))return!0;var n=o.Serializer.findProperty(e.getType(),t);return!!n&&["expression","condition","questionvalue","question"].indexOf(n.type)>-1},t.prototype.updateSurveyLogicValues=function(e,t,i){e&&t&&!o.Helpers.isValueEmpty(i)&&"value"===t&&e.isDescendantOf("itemvalue")&&this.updateSurveyLogicItemValue(e,i)},t.prototype.updateSurveyLogicItemValue=function(e,t){if(e.locOwner&&i.logic.updateExpressionsOnChanging.choiceValue&&!(["choices","rateValues","columns","rows"].indexOf(e.ownerPropertyName)<0)){this.surveyLogicRenaming=!0;var o=this.getSurveyLogicForUpdate();"rows"===e.ownerPropertyName?o.renameRowValue(e,t):o.renameItemValue(e,t),this.surveyLogicRenaming=!1}},t.prototype.createSurveyLogicForUpdate=function(){return new Ue(this.survey,this)},t.prototype.updateLogicOnQuestionNameChanged=function(e,t){e!==t&&i.logic.updateExpressionsOnChanging.questionName&&(this.surveyLogicRenaming=!0,this.getSurveyLogicForUpdate().renameQuestion(e,t),this.surveyLogicRenaming=!1)},t.prototype.updateLogicOnColumnNameChanged=function(e,t,o){t&&t!==o&&i.logic.updateExpressionsOnChanging.columnName&&(this.surveyLogicRenaming=!0,this.getSurveyLogicForUpdate().renameColumn(e,t),this.surveyLogicRenaming=!1)},t.prototype.updateChoicesFromQuestionOnColumnNameChanged=function(e,t){this.getAllQuestions().forEach((function(o){o.choicesFromQuestion===e&&(o.choicesFromQuestion=t)}))},t.prototype.isObjQuestion=function(e){return this.isObjThisType(e,"question")},t.prototype.isObjPage=function(e){return this.isObjThisType(e,"page")},t.prototype.isObjThisType=function(e,t){for(var i=o.Serializer.findClass(e.getType());i&&i.parentName;){if(i.name===t)return!0;i=o.Serializer.findClass(i.parentName)}return!!i&&i.name===t},t.prototype.onDragDropItemStart=function(){this.addNewElementReason="DROPPED_FROM_TOOLBOX"},t.prototype.doOnQuestionAdded=function(e,t){e.name=this.generateUniqueName(e,e.name);var o={question:e,page:this.getPageByElement(e),reason:this.addNewElementReason};this.addNewElementReason=void 0,this.onQuestionAdded.fire(this,o)},t.prototype.doOnPanelAdded=function(e,t){var o={panel:e,page:this.getPageByElement(e),reason:this.addNewElementReason};this.onPanelAdded.fire(this,o),this.addNewElementReason=void 0},t.prototype.doOnPageAdded=function(e){var t={page:e};this.onPageAdded.fire(this,t),this.setModified({type:"PAGE_ADDED",newValue:t.page})},t.prototype.getPageByElement=function(e){return this.survey.getPageByElement(e)},t.prototype.getDefaultSurveyJson=function(){var e=i.defaultNewSurveyJSON;return e.pages&&e.pages.length>0&&e.pages[0].name&&(e.pages[0].name=G.getString("ed.newPageName")+"1"),e},t.prototype.setSurvey=function(e){this.surveyValue&&this.surveyValue.dispose(),this.surveyValue=e,this.selectElement(e),this.selectionHistoryController.reset()},t.prototype.getSurveyTextFromDesigner=function(){if(!this.survey)return"";var e=this.survey.toJSON();e=this.singlePageJSON(e),this.moveElementsToTheEnd(e);var t=i.jsonEditor.indentation;return this.generateValidJSON?JSON.stringify(e,null,t):(new X).stringify(e,null,t)},t.prototype.moveElementsToTheEnd=function(e){var t=this;if(e)if(Array.isArray(e))e.forEach((function(e){return t.moveElementsToTheEnd(e)}));else if("object"==typeof e){if(e.elements){var o=e.elements;delete e.elements,e.elements=o}Object.keys(e).forEach((function(o){return t.moveElementsToTheEnd(e[o])}))}},t.prototype.setTextValue=function(e){this.setSurveyJSONTextCallback&&this.setSurveyJSONTextCallback(e)},t.prototype.changeText=function(e,t){if(void 0===t&&(t=!1),this.setTextValue(e),e){var o=new ce(e);o.isJsonCorrect||o.survey?this.initSurveyWithJSON(o.survey.toJSON(),t):this.viewType="editor"}else this.initSurveyWithJSON(void 0,t)},Object.defineProperty(t.prototype,"text",{get:function(){return this.getSurveyJSONTextCallback?this.getSurveyJSONTextCallback().text:this.getSurveyTextFromDesigner()},set:function(e){this.changeText(e,!0)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"designTabSurveyThemeVariables",{get:function(){var e={};return q(e,Fi.cssVariables,{"--sjs-base-unit":"var(--ctr-surface-base-unit)"}),e},enumerable:!1,configurable:!0}),t.prototype.getSurveyJSON=function(){if("editor"!=this.viewType)return(new o.JsonObject).toJsonObject(this.survey);var e=this.text,t=new ce(e);return t.isJsonCorrect?(new o.JsonObject).toJsonObject(t.survey):null},t.prototype.getObjectDisplayName=function(e,t,o,i){void 0===o&&(o=void 0),void 0===i&&(i=void 0),i||(i=ee.getObjectName(e,this.showObjectTitles));var n={obj:e,displayName:i,area:t,reason:o};return this.onGetObjectDisplayName.fire(this,n),n.displayName},t.prototype.createSurvey=function(e,t,o,i,n){var r,a=this.createSurveyCore(e,t);return"designer"!==t&&"test"!==t&&"theme"!==t&&(a.fitToContainer=!1,a.applyTheme(Fi),a.gridLayoutEnabled=!1),"designer"!==t&&"modal-question-editor"!==t||Xi(a,this),a.needRenderIcons=!1,"designer"!=t&&"test"!=t&&"theme"!==t&&(a.locale=G.currentLocale,e.clearInvisibleValues||(a.clearInvisibleValues="onComplete")),i&&i(a),n=n||this.getSurveyInstanceCreatedArea(t),this.onSurveyInstanceCreated.fire(this,{survey:a,reason:t,area:n,model:o||(null===(r=this.currentPlugin)||void 0===r?void 0:r.model),obj:"property-grid"===n&&o?o.obj:void 0}),"designer"===t&&this.onDesignerSurveyCreated.fire(this,{survey:a}),"test"!==t&&"theme"!==t||this.onPreviewSurveyCreated.fire(this,{survey:a}),a},t.prototype.getSurveyInstanceCreatedArea=function(e){return{designer:"designer-tab",test:"preview-tab","default-value":"default-value-popup-editor","condition-builder":"logic-rule:condition-editor","logic-item-editor":"logic-rule:action-editor","logic-items":"logic-tab:condition-list",theme:"theme-tab",translation_settings:"translation-tab:language-list",translation_strings:"translation-tab:table",translation_strings_header:"translation-tab:table-header","cells-editor":"matrix-cell-values-popup-editor","fast-entry":"table-values-popup-editor","modal-question-editor":"matrix-cell-question-popup-editor"}[e]||e},t.prototype.createSurveyCore=function(e,t){return void 0===e&&(e={}),new o.SurveyModel(e)},Object.defineProperty(t.prototype,"state",{get:function(){return this._stateValue?this._stateValue:""},enumerable:!1,configurable:!0}),t.prototype.setState=function(e){this._stateValue=e,this.onStateChanged.fire(this,{val:e}),e&&(this.notify(this.getLocString("ed."+e)),this._updateSaveActions())},t.prototype.setModified=function(e){void 0===e&&(e=null),this.setState("modified"),this.onModified.fire(this,e),this.isAutoSave&&this.doAutoSave()},t.prototype.notifySurveyPropertyChanged=function(e){this.clearSurveyLogicForUpdate(e.target,e.name,e.newValue),this.updateSurveyLogicValues(e.target,e.name,e.oldValue);var t=this.currentPlugin;t&&t.onDesignerSurveyPropertyChanged&&t.onDesignerSurveyPropertyChanged(e.target,e.name),this.onSurveyPropertyValueChanged.isEmpty||(e.propertyName=e.name,e.obj=e.target,e.value=e.newValue,this.onSurveyPropertyValueChanged.fire(this,e)),e.type="PROPERTY_CHANGED",this.setModified(e)},t.prototype.notifySurveyItemMoved=function(e){e.type="ELEMENT_REORDERED",this.setModified(e)},t.prototype.notify=function(e,t){void 0===t&&(t="info"),this.onNotify.isEmpty?this.notifier.notify(e,t):this.onNotify.fire(this,{message:e,type:t})},t.prototype.convertQuestion=function(e,t,o){void 0===o&&(o=null);var i=$.getObjJSON(e,this.getDefaultElementJSON(e.getType())),n={sourceQuestion:e,targetType:t,json:i};this.onQuestionConverting.fire(this,n);var r=$.convertObject(e,t,n.json,this.getDefaultElementJSON(t),o);return this.setModified({type:"QUESTION_CONVERTED",className:t,oldValue:e,newValue:r}),r},t.prototype.getDefaultElementJSON=function(e){var t;if(!this.toolbox)return null;var i=null===(t=this.toolbox.getItemByName(e))||void 0===t?void 0:t.json;return i?o.Helpers.createCopy(i):null},t.prototype.singlePageJSON=function(e){if("single"===this.pageEditMode){var t=e.pages;Array.isArray(t)&&t.length>0&&(void 0!==t[0].elements&&(e.elements=t[0].elements),delete e.pages)}return e},Object.defineProperty(t.prototype,"JSON",{get:function(){var e=this.survey.toJSON();return this.singlePageJSON(e)},set:function(e){"editor"==this.viewType?this.setTextValue(JSON.stringify(e)):this.initSurveyWithJSON(e,!0)},enumerable:!1,configurable:!0}),t.prototype.loadSurvey=function(e){var t=this;(new o.dxSurveyService).loadSurvey(e,(function(e,o,i){e&&o&&(t.JSON=o)}))},t.prototype.doClickQuestionCore=function(e,t,o,i){void 0===t&&(t="ADDED_FROM_TOOLBOX"),void 0===o&&(o=-1),void 0===i&&(i=null),0==this.survey.pageCount&&this.addNewPageIntoSurvey();var n=this.currentPage;"bypage"===this.pageEditMode&&(n=this.getPlugin("designer").model.pagesController.page2Display);var r=this.getSelectedSurveyElement();if(r&&r.parent&&r.page==n&&r!==i){if(!i)for(;r.parent&&r.parent.isPanel;)r=r.parentQuestion?r.parentQuestion:r.parent;n=r.parent,o<0&&(this.addNewQuestionLast&&"ADDED_FROM_PAGEBUTTON"===t?o=n.elements.length:(o=n.elements.indexOf(r))>-1&&o++)}i&&(n=i),this.addNewElementReason=t;var a=this.findRowByElement(r,n);e.setVisibleIndex(-1),a&&this.isRowMultiline(a)?this.addElemenMultiline(n,e,o,a):n.addElement(e,o),this.addNewElementReason="",this.setModified({type:t,question:e})},t.prototype.isRowMultiline=function(e){return e.elements.length>1},t.prototype.findRowByElement=function(e,t){return e?e.isPage?e.rows[e.rows.length-1]:t.rows.find((function(t){return-1!==t.elements.indexOf(e)})):null},t.prototype.addElemenMultiline=function(e,t,o,i){var n=i.elements.length,r=i.elements[n-1];r.startWithNewLine=!0,e.addElement(t,o),r.startWithNewLine=!1},t.prototype.setNewNames=function(e){this.newQuestions=[],this.newPanels=[],this.newQuestionChangedNames={},this.setNewNamesCore(e),this.updateNewElementExpressions(e)},t.prototype.updateNewElementExpressions=function(e){var t=this.createSurvey({},"updateNewElementExpressions",void 0,(function(t){t.setDesignMode(!0),e.isPage?t.addPage(e):(t.addNewPage("p1"),t.pages[0].addElement(e))})),o=new Ue(t);for(var i in this.newQuestionChangedNames)o.renameQuestion(i,this.newQuestionChangedNames[i])},t.prototype.getAllQuestions=function(e){return void 0===e&&(e=!0),this.getAllElements(!1,e)},t.prototype.getAllPanels=function(e){return void 0===e&&(e=!0),this.getAllElements(!0,e)},t.prototype.getAllElements=function(e,t){var o=ee.getAllElements(this.survey,e);return t&&(ee.addElements(this.newPanels,e,o),ee.addElements(this.newQuestions,e,o)),o},t.prototype.getNewName=function(e,t){return"page"==e?ee.getNewPageName(this.survey.pages):t?this.getNewPanelName():this.getNewQuestionName()},t.prototype.getNewQuestionName=function(){return ee.getNewQuestionName(this.getAllQuestions())},t.prototype.getNewPanelName=function(){return ee.getNewPanelName(this.getAllPanels())},t.prototype.setNewNamesCore=function(e){var t=this,o=e.getType(),i=this.getNewName(o,e.isPanel);if(i!=e.name&&(this.newQuestionChangedNames[e.name]=i,e.name=i),e.isPanel||e.isPage)e.isPanel&&this.newPanels.push(e),e.elements.forEach((function(e){return t.setNewNamesCore(e)}));else{this.newQuestions.push(e);var n=Array.isArray(e.templateElements)?e.templateElements:Array.isArray(e.detailElements)?e.detailElements:void 0;n&&n.forEach((function(e){return t.setNewNamesCore(e)}))}},t.prototype.createNewElement=function(e){var t=o.Serializer.createClass(e.type);(new o.JsonObject).toObject(e,t);var i=!0;return e.name&&(i=t.isPage?!!this.survey.getPageByName(t.name):t.isPanel?!!this.survey.getPanelByName(t.name):!!this.survey.getQuestionByName(t.name)),i&&this.setNewNames(t),t},t.prototype.copyElement=function(e){var t=(new o.JsonObject).toJsonObject(e);return t.type=e.getType(),this.createNewElement(t)},t.prototype.fastCopyQuestion=function(e,t){var o=this.copyElement(e),i=e.parent?e.parent.elements.indexOf(e)+1:-1;if(i>-1){var n=e.parent.elements;i<n.length&&!1===n[i].startWithNewLine&&(o.startWithNewLine=!1)}return this.doClickQuestionCore(o,"ELEMENT_COPIED",i,e.parent),t&&this.selectElement(o),o},Object.defineProperty(t.prototype,"selectedElement",{get:function(){return this.selectedElementValue},set:function(e){this.selectElement(e)},enumerable:!1,configurable:!0}),t.prototype.refreshDesigner=function(){"designer"===this.activeTab&&this.changeText(this.text)},t.prototype.deleteCurrentObject=function(){this.deleteCurrentElement()},t.prototype.deleteCurrentElement=function(){this.deleteObject(this.selectedElement)},t.prototype.deleteElement=function(e){this.deleteObject(e)},t.prototype.copyPage=function(e){var t=this,o=this.copyElement(e),i=this.survey.pages.indexOf(e);i>-1?this.survey.pages.splice(i+1,0,o):this.survey.pages.push(o),o.questions.forEach((function(e){t.addNewElementReason="ELEMENT_COPIED",t.doOnQuestionAdded(e,e.parent)}));var n=o.getPanels();return Array.isArray(n)&&n.forEach((function(e){return t.doOnPanelAdded(e,e.parent)})),this.addNewElementReason="",o},t.prototype.deleteObjectCore=function(e){if(e.isPage){var t=this.getNextPage(e);this.survey.removePage(e),this.selectElement(t||this.survey)}else{if(1===this.survey.pageCount){var o=this.survey.pages[0];if(1===o.elements.length&&e===o.elements[0]&&!ee.isPagePropertiesAreModified(o))return void this.deleteObjectCore(o)}this.deletePanelOrQuestion(e)}this.setModified({type:"OBJECT_DELETED",target:e}),this.updateConditionsOnRemove(e)},t.prototype.getNextPage=function(e){var t=this.survey.pages.indexOf(e);return t<0||1==this.survey.pages.length?null:(t==this.survey.pages.length-1?t--:t++,t<0||t>this.survey.pages.length-1?null:this.survey.pages[t])},t.prototype.deleteObject=function(e){this.checkOnElementDeleting(e)&&this.deleteObjectCore(e)},t.prototype.updateConditionsOnRemove=function(e){if(i.logic.updateExpressionsOnDeleting.question){if(ee.getObjectType(e)==Y.Question)t=[e];else var t=e.questions;if(t)for(var o=new Ue(this.survey,this),n=0;n<t.length;n++)o.removeQuestion(t[n].getValueName())}},t.prototype.checkOnElementDeleting=function(e){var t={element:e,elementType:ee.getObjectType(e),allowing:!0};return this.onElementDeleting.fire(this,t),t.allowing},t.prototype.isElementSelected=function(e){return!(!e||e.isDisposed)&&e.getPropertyValue("isSelectedInDesigner")},t.prototype.selectElement=function(e,t,o,i){if(void 0===o&&(o=!0),void 0===i&&(i=!1),!e||!e.isDisposed&&e.getSurvey()&&(!e.isQuestion&&!e.isPanel||e.parent)){var n=this.selectedElement;n!==e&&(this.selectedElementValue=this.onSelectingElement(e),n!==this.selectedElementValue&&(n&&!n.isDisposed&&n.setPropertyValue("isSelectedInDesigner",!1),this.selectedElementValue&&this.selectedElementValue.setPropertyValue("isSelectedInDesigner",!0))),(n!==e||t)&&this.selectionChanged(this.selectedElement,t,!!o);var r=this.getSelectedSurveyElement();n!==e&&document&&r&&this.focusElement(e,o,r,t,i)}},t.prototype.focusElement=function(e,t,o,i,n){var r=this;void 0===o&&(o=null),void 0===i&&(i=null),void 0===n&&(n=null),o||(o=this.getSelectedSurveyElement()),o&&(clearInterval(this.currentFocusInterval),clearTimeout(this.currentFocusTimeout),this.animationEnabled&&this.survey.isLazyRendering&&this.survey.disableLazyRenderingBeforeElement(o),this.currentFocusTimeout=setTimeout((function(){r.currentFocusInterval=setInterval((function(){var a,s,l=document.getElementById(o.id);if(o&&(t||n&&(!o.hasTitle||o.isPanel))){if(!l||r.rootElement.getAnimations({subtree:!0}).filter((function(e){return e.effect.getComputedTiming().activeDuration!==1/0&&(e.pending||"finished"!==e.playState)}))[0])return;if(clearInterval(r.currentFocusInterval),l){if(ee.isNeedScrollIntoView(null!==(a=l.parentElement)&&void 0!==a?a:l,!0)){var u=r.getPageByElement(o),p={block:"start",behavior:r.animationEnabled?"smooth":void 0};u?r.survey.scrollElementToTop(o,void 0,u,o.id,!0,p,r.rootElement):ee.scrollIntoViewIfNeeded(null!==(s=l.parentElement)&&void 0!==s?s:l,(function(){return p}),!0)}if(!i&&l.parentElement){var c="string"==typeof t?l.parentElement.querySelector(t):l.parentElement;c&&c.focus({preventScroll:!0})}}}else clearInterval(r.currentFocusInterval);n&&e&&oi.get(e.locTitle).activateEditor()}),1)}),100))},t.prototype.getSelectedSurveyElement=function(){var e=this.selectedElement;return e&&"survey"!=e.getType()&&e.isInteractiveDesignElement&&e.id?e:null},t.prototype.onSelectingElement=function(e){var t={newSelectedElement:e};return this.onSelectedElementChanging.fire(this,t),t.newSelectedElement},Object.defineProperty(t.prototype,"designerPropertyGrid",{get:function(){var e=this.sidebar.getPageById("propertyGrid");return e&&e.componentData?e.componentData.propertyGridModel:null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"propertyGrid",{get:function(){return this.designerPropertyGrid.survey},enumerable:!1,configurable:!0}),t.prototype.collapsePropertyGridCategory=function(e){this.designerPropertyGrid&&this.designerPropertyGrid.collapseCategory(e)},t.prototype.expandPropertyGridCategory=function(e){this.designerPropertyGrid&&this.designerPropertyGrid.expandCategory(e)},t.prototype.collapseAllPropertyGridCategories=function(){this.designerPropertyGrid&&this.designerPropertyGrid.collapseAllCategories()},t.prototype.expandAllPropertyGridCategories=function(){this.designerPropertyGrid&&this.designerPropertyGrid.expandAllCategories()},t.prototype.collapseAllPropertyTabs=function(){this.collapseAllPropertyGridCategories()},t.prototype.expandAllPropertyTabs=function(){this.expandAllPropertyGridCategories()},t.prototype.expandPropertyTab=function(e){this.expandPropertyGridCategory(e)},t.prototype.collapsePropertyTab=function(e){this.collapsePropertyGridCategory(e)},t.prototype.validateSelectedElement=function(){var e=!0;return this.selectedElement?(this.designerPropertyGrid&&(e=this.designerPropertyGrid.validate()),e):e},t.prototype.deleteLocaleStrings=function(e){new Wt(this.survey).deleteLocaleStrings(e)},t.prototype.getPropertyGridDefinition=function(){return this.propertyGridDefinition},t.prototype.setPropertyGridDefinition=function(e){this.propertyGridDefinition=e,this.designerPropertyGrid&&this.designerPropertyGrid.setPropertyGridDefinition(e)},t.prototype.expandCategoryIfNeeded=function(){this.survey.isEmpty||this.designerPropertyGrid.expandCategoryIfNeeded()},t.prototype.selectionChanged=function(e,t,o){var i=this;void 0===o&&(o=!0),this.survey.currentPage=this.getCurrentPageByElement(e),this.selectionHistoryController.onObjSelected(e),this.designerPropertyGrid&&(this.designerPropertyGrid.obj=e,t||(t=this.designerPropertyGrid.currentlySelectedProperty),t&&this.sidebar.executeOnExpand((function(){i.designerPropertyGrid.selectProperty(t,o||!i.selectFromStringEditor)})),this.expandCategoryIfNeeded(),this.selectFromStringEditor=!1);var n={newSelectedElement:e};this.onSelectedElementChanged.fire(this,n)},t.prototype.getCurrentPageByElement=function(e){if(e)return e.isPage?e:e.page?e.page:e.parentQuestion?this.getCurrentPageByElement(e.parentQuestion):void 0},t.prototype.clickToolboxItem=function(e,t,o){void 0===t&&(t=null),void 0===o&&(o="ADDED_FROM_TOOLBOX"),this.readOnly||(void 0===e.getType&&(e=this.createNewElement(e)),this.survey.lazyRendering=!1,this.doClickQuestionCore(e,o,-1,t),this.selectElement(e,null,!this.toolbox.searchManager.filterString,this.startEditTitleOnQuestionAdded))},t.prototype.getJSONForNewElement=function(e){var t=this.createNewElement(e);return(e=t.toJSON()).type=t.getType(),e},t.prototype.chooseFiles=function(e,t,i){this.onOpenFileChooser.isEmpty?(0,o.chooseFiles)(e,t):this.onOpenFileChooser.fire(this,{input:e,element:i&&i.element||this.survey,elementType:i&&i.elementType,item:i&&i.item,propertyName:i&&i.propertyName,callback:t,context:i})},t.prototype.uploadFiles=function(e,t,o,i){if(this.onUploadFile.isEmpty){var n=new FileReader;n.onload=function(e){o("success",n.result)},n.readAsDataURL(e[0])}else this.onUploadFile.fire(this,{question:t,files:e||[],callback:o,element:i&&i.element||this.survey,elementType:i&&i.elementType,propertyName:i&&i.propertyName,context:i})},Object.defineProperty(t.prototype,"rootElement",{get:function(){return this._rootElementValue},enumerable:!1,configurable:!0}),t.prototype.setRootElement=function(e){this._rootElementValue=e,this.initKeyboardShortcuts(e),this.initResponsivityManager(e)},t.prototype.unsubscribeRootElement=function(){this.removeKeyboardShortcuts(this._rootElementValue),this.resetResponsivityManager()},t.prototype.initKeyboardShortcuts=function(e){e&&e.addEventListener("keydown",this.onKeyDownHandler)},t.prototype.removeKeyboardShortcuts=function(e){e&&e.removeEventListener("keydown",this.onKeyDownHandler)},t.prototype.findSuitableShortcuts=function(e){var t=this,o=[];return Object.keys(this.shortcuts||{}).map((function(e){return t.shortcuts[e]})).filter((function(e){return!e.affectedTab||e.affectedTab===t.activeTab})).forEach((function(t){var i=e.metaKey?t.macOsHotkey:t.hotKey;i&&!!i.ctrlKey==!!e.ctrlKey&&!!i.shiftKey==!!e.shiftKey&&i.keyCode===e.keyCode&&o.push(t)})),o},t.prototype.registerShortcut=function(e,t){this.shortcuts[e]=t},t.prototype.unRegisterShortcut=function(e){delete this.shortcuts[e]},t.prototype.deletePanelOrQuestion=function(e){var t=this,o=e===this.selectedElement,i=e.parent,n=i.elements,r=n.indexOf(e);r==n.length-1&&r--,e.questions&&e.questions.forEach((function(e){return t.updateConditionsOnRemove(e)})),e.delete(!1),!i.isPage||"single"!==this.pageEditMode&&0!==n.length||(i=this.survey),o&&this.selectElement(r>-1?n[r]:i)},t.prototype.onCanShowObjectProperty=function(e,t,o,i,n){if(this.hiddenProperties[t.id])return!1;var r={obj:e,property:t,canShow:!0,showMode:o,parentObj:i,parentProperty:n};return this.onCanShowProperty.fire(this,r),r.canShow},t.prototype.canDeleteItem=function(e,t,o){var i={obj:e,item:t,canDelete:o};return this.onCanDeleteItem.fire(this,i),i.canDelete},t.prototype.getErrorOnPropertyChanging=function(e,t,o){return"name"!==t||ee.getObjectType(e)===Y.Unknown?null:(ee.getObjectType(e)===Y.Column?e.colOwner&&!this.isNameUniqueInArray(e.colOwner.columns,e,o):this.generateUniqueName(e,o)!==o)?this.getLocString("pe.propertyNameIsNotUnique"):null},t.prototype.generateUniqueName=function(e,t){var o={element:e,name:t,isDone:!0},i=[];do{if(this.generateUniqueNameCore(o),!o.isDone&&i.indexOf(o.name)>-1){o.name=this.checkForUniqueName(e,o.name);break}i.push(o.name)}while(!o.isDone);return o.name},t.prototype.generateUniqueNameCore=function(e){e.name=this.checkForUniqueName(e.element,e.name);var t={element:e.element,name:e.name};this.onGenerateNewName.fire(this,t),e.name!==t.name&&(e.name=t.name,e.name=this.checkForUniqueName(e.element,e.name),e.isDone=e.name===t.name)},t.prototype.checkForUniqueName=function(e,t){for(;!this.isNameUnique(e,t,!1);)t=ee.generateNewName(t);return t},t.prototype.isNameUnique=function(e,t,o){return void 0===o&&(o=!0),!!this.isNameUniqueInArray(this.survey.pages,e,t)&&!!this.isNameUniqueInArray(this.getAllPanels(o),e,t)&&this.isNameUniqueInArray(this.getAllQuestions(o),e,t)},t.prototype.isNameUniqueInArray=function(e,t,o){if(!Array.isArray(e))return!0;o=o.toLowerCase();for(var i=0;i<e.length;i++)if(e[i]!=t&&e[i].name.toLowerCase()==o)return!1;return!0},t.prototype.doPropertyGridChanged=function(){},Object.defineProperty(t.prototype,"alwaySaveTextInPropertyEditors",{get:function(){return this.alwaySaveTextInPropertyEditorsValue},set:function(e){this.alwaySaveTextInPropertyEditorsValue=e},enumerable:!1,configurable:!0}),t.prototype.getElementAddornerCssCallback=function(e,t){return t},t.prototype.onCanShowPropertyCallback=function(e,t,o,i,n){return void 0===o&&(o=null),this.onCanShowObjectProperty(e,t,o,i,n)},t.prototype.onPropertyGridSurveyCreatedCallback=function(e,t){var o={obj:e,survey:t};this.onPropertyGridSurveyCreated.fire(this,o)},t.prototype.onPropertyEditorCreatedCallback=function(e,t,o){var i={obj:e,property:t,editor:o};this.onPropertyEditorCreated.fire(this,i)},t.prototype.onPropertyEditorUpdateTitleActionsCallback=function(e,t,o,i){var n={obj:e,property:t,editor:o,titleActions:i};this.onPropertyEditorUpdateTitleActions.fire(this,n)},t.prototype.onPropertyGridShowModalCallback=function(e,t,o,i,n){var r={obj:e,property:t,editor:o,popupEditor:i,popupModel:n};this.onPropertyGridShowModal.fire(this,r)},t.prototype.onCanDeleteItemCallback=function(e,t,o){if(t&&t.isPage){if("bypage"===this.pageEditMode)return t!==this.survey.currentPage;if("single"===this.pageEditMode)return!1}return this.canDeleteItem(e,t,o)},t.prototype.onCollectionItemDeletingCallback=function(e,t,o,i){if((null==i?void 0:i.isPage)&&!this.checkOnElementDeleting(i))return!1;if(this.onCollectionItemDeleting.isEmpty)return!0;var n={obj:e,property:t,propertyName:t.name,collection:o,item:i,allowDelete:!0};return this.onCollectionItemDeleting.fire(this,n),n.allowDelete},t.prototype.onCollectionItemAllowingCallback=function(e,t,o,i,n){if(!this.onCollectionItemAllowOperations.isEmpty){var r={obj:e,property:t,propertyName:t&&t.name,collection:o,item:i,allowEdit:n.allowEdit,allowDelete:n.allowDelete,allowAdd:n.allowAdd};this.onCollectionItemAllowOperations.fire(this,r),n.allowEdit=r.allowEdit,n.allowDelete=r.allowDelete,n.allowAdd=r.allowAdd}},t.prototype.onItemValueAddedCallback=function(e,t,o,i){var n={obj:e,propertyName:t,newItem:o,itemValues:i};this.onItemValueAdded.fire(this,n)},t.prototype.onFastEntryCallback=function(e,t){var o={items:e,lines:t};return this.onFastEntryFinished.fire(this,o),o.items},t.prototype.onMatrixDropdownColumnAddedCallback=function(e,t,o){var i={newColumn:t,matrix:e,columns:o};this.onMatrixColumnAdded.fire(this,i)},t.prototype.onSetPropertyEditorOptionsCallback=function(e,t,o){var i={propertyName:e,obj:t,editorOptions:o,allowAddRemoveItems:o.allowAddRemoveItems,allowRemoveAllItems:o.allowRemoveAllItems,allowBatchEdit:o.allowBatchEdit},n=["allowAddRemoveItems","allowRemoveAllItems","allowBatchEdit"];n.forEach((function(e){return i[e]=o[e]})),this.onSetPropertyEditorOptions.fire(this,i),this.onConfigureTablePropertyEditor.fire(this,i),n.forEach((function(e){return o[e]=o[e]&&i[e]}))},t.prototype.onGetErrorTextOnValidationCallback=function(e,t,o){var i=this.getErrorOnPropertyChanging(t,e,o);if(i)return i;var n={propertyName:e,obj:t,value:o,error:""};return this.onPropertyValidationCustomError.fire(this,n),n.error},t.prototype.onValueChangingCallback=function(e){this.onPropertyValueChanging.fire(this,e)},t.prototype.onGetElementEditorTitleCallback=function(e,t){return t},t.prototype.onConditionQuestionsGetListCallback=function(e,t,o,n,r){if(this.onConditionQuestionsGetList.isEmpty)return i.logic.questionSortOrder;var a={propertyName:e,obj:t,editor:o,sortOrder:"asc",list:n,variables:r};if(this.onConditionQuestionsGetList.fire(this,a),a.list!==n){n.splice(0,n.length);for(var s=0;s<a.list.length;s++)n.push(a.list[s])}return a.sortOrder},t.prototype.onConditionGetTitleCallback=function(e,t){var o={expression:e,title:t};return this.onConditionGetTitle.fire(this,o),o.title},t.prototype.isConditionOperatorEnabled=function(e,t,o,i){if(this.onGetConditionOperator.isEmpty)return i;var n={questionName:e,question:t,questionType:t?t.getType():"",operator:o,show:i};return this.onGetConditionOperator.fire(this,n),n.show},t.prototype.onLogicGetTitleCallback=function(e,t,o,i){if(this.onLogicItemDisplayText.isEmpty)return o;var n={expression:e,expressionText:t,text:o,logicItem:i};return this.onLogicItemDisplayText.fire(this,n),n.text},t.prototype.getProcessedTranslationItemText=function(e,t,o,i){if(this.onTranslationItemChanging.isEmpty)return o;var n={locale:e,obj:i,locString:t,newText:o};return this.onTranslationItemChanging.fire(this,n),n.newText},t.prototype.getTranslationExportedText=function(e,t,o,i,n){if(this.onTranslationExportItem.isEmpty)return n;var r={obj:e,name:t,locString:o,locale:i,text:n};return this.onTranslationExportItem.fire(this,r),r.text},t.prototype.getHasMachineTranslation=function(){return!this.onMachineTranslate.isEmpty},t.prototype.doMachineTranslation=function(e,t,o,i){this.getHasMachineTranslation()?this.onMachineTranslate.fire(this,{fromLocale:e,toLocale:t,strings:o,callback:i}):i(void 0)},t.prototype.doAutoSave=function(){var e=this,t=function(){return e.doSave()};if(this.autoSaveDelay<=0)t();else{this.autoSaveTimerId&&clearTimeout(this.autoSaveTimerId);var o=this;this.autoSaveTimerId=setTimeout((function(){clearTimeout(o.autoSaveTimerId),o.autoSaveTimerId=null,t()}),this.autoSaveDelay)}},t.prototype._doSaveCore=function(e){var t=this;this.setState("saving"),this.saveSurveyFunc&&(this.saveNo++,this.saveSurveyFunc(this.saveNo,(function(o,i){t.saveNo===o&&(i?t.setState("saved"):(t.setState("modified"),t.showErrorOnFailedSave&&t.notify(t.getLocString("ed.saveError"),"error")),e&&e())})))},t.prototype.saveSurvey=function(){this._doSaveCore()},t.prototype.doSave=function(){this._doSaveCore()},t.prototype.saveSurveyActionHandler=function(){this.syncSaveButtons?this.save():this.saveSurvey()},t.prototype._updateSaveActions=function(){var e=this._findAction("svd-save");if(e&&(e.enabled="modified"===this.state,e.active="modified"===this.state),this.syncSaveButtons){var t=this._findAction("svd-save-theme");t&&(t.enabled=this.hasPendingThemeChanges,t.active=this.hasPendingThemeChanges)}},t.prototype.save=function(){var e=this,t=function(){e.hasPendingThemeChanges&&e._doSaveThemeCore((function(){e._updateSaveActions()}))};"modified"===this.state?this._doSaveCore((function(){t()})):t()},Object.defineProperty(t.prototype,"saveSurveyFunc",{get:function(){return this.saveSurveyFuncValue},set:function(e){this.saveSurveyFuncValue=e,this.showSaveButton=null!=e&&!this.isAutoSave},enumerable:!1,configurable:!0}),t.prototype.convertCurrentQuestion=function(e,t){void 0===t&&(t=null);var o=this.selectedElement;if(o&&(o.getType()!==e||t)){var i=ee.getObjectType(o);i!==Y.Question&&i!==Y.Panel||(this.addNewElementReason="ELEMENT_CONVERTED",o=this.convertQuestion(o,e,t),this.selectElement(o,null,"#convertTo button"))}},t.prototype.getAddNewQuestionText=function(e){if(void 0===e&&(e=null),e||(e=this.currentAddQuestionType),e){var t=this.getLocString("ed.addNewTypeQuestion"),o=this.toolbox.items.filter((function(t){return t.name==e}));if(Array.isArray(o)&&o.length>0&&t&&t.format)return t.format(o[0].title)}return this.getLocString("ed.addNewQuestion")},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return this.getAddNewQuestionText()},enumerable:!1,configurable:!0}),t.prototype.getAvailableToolboxItems=function(e,t){void 0===t&&(t=!0);var o=[].concat(this.toolbox.items);if(!e||this.maxNestedPanels<0)return o;if(!t&&e.isPanel)return o;if(this.maxNestedPanels<ee.getElementDeepLength(e))for(var i=o.length-1;i>=0;i--)o[i].isPanel&&o.splice(i,1);return o},t.prototype.getQuestionTypeSelectorModel=function(e,t){var i=this,n=t&&t.isPanel?t:null,r=function(t,o){i.currentAddQuestionType=t,i.addNewQuestionInPage(e,n,t,o),s.popupModel.hide()},a=function(){return i.getAvailableToolboxItems(t).map((function(e){return i.createIActionBarItemByClass(e,e.needSeparator,r)}))},s=(0,o.createDropdownActionModel)({iconName:"icon-more",title:this.getLocString("ed.addNewQuestion")},{items:a(),onShow:function(){s.popupModel.contentComponentData.model.setItems(a())},allowSelection:!1,cssClass:"svc-creator-popup",verticalPosition:"bottom",horizontalPosition:"center",displayMode:this.isTouch?"overlay":"popup"});return s},t.prototype.getUpdatedPageAdornerFooterActions=function(e,t){var o={page:e.page,addNewQuestion:function(t){e.addNewQuestion(e,void 0,t)},actions:t};return this.onGetPageActions.fire(this,o),o.actions},t.prototype.addNewQuestionInPage=function(e,t,o,n){void 0===t&&(t=null),void 0===o&&(o=null),void 0===n&&(n=null),o||(o=this.currentAddQuestionType),o||(o=i.designer.defaultAddQuestionType),e(o);var r=n;if(!r){var a=this.toolbox.getItemByName(o);r=a&&a.json?a.json:{type:o}}var s=this.createNewElement(r);this.clickToolboxItem(s,t,"ADDED_FROM_PAGEBUTTON")},t.prototype.createIActionBarItemByClass=function(e,t,i){var n=new o.Action({title:e.title,id:e.name,iconName:e.iconName,visible:e.visible,enabled:e.enabled,needSeparator:t});if(n.action=function(){i(e.typeName,e.json)},e.items&&e.items.length>0&&this.toolbox.showSubitems){var r=e.items.map((function(t){return new o.Action({id:t.id,title:t.title,action:function(){n.hidePopup(),i(e.typeName,t.json)}})}));n.setSubItems({items:r})}return n},t.prototype.onElementMenuItemsChanged=function(e,t){this.onDefineElementMenuItems.fire(this,{obj:e,items:t})},t.prototype.getElementAllowOperations=function(e){var t={obj:e,element:e,allowDelete:!0,allowCopy:!0,allowDragging:!0,allowChangeType:!0,allowChangeInputType:!0,allowChangeRequired:!0,allowShowSettings:void 0,allowEdit:void 0,allowExpandCollapse:void 0};return this.onElementAllowOperations.fire(this,t),t},t.prototype.getChoicesItemBaseTitle=function(){return this.getLocString("ed.choices_Item")||o.surveyLocalization.getString("choices_Item")},t.prototype.getNextItemValue=function(e){return c(this.getChoicesItemBaseTitle(),e.choices)},t.prototype.createNewItemValue=function(e,t,o){void 0===t&&(t=!0);var i=this.getNextItemValue(e),n=e.createItemValue(i);if(n.text=d(e.choices),e.choices.push(n),o&&o(n),t){var r=n.ownerPropertyName?n.ownerPropertyName:"choices";this.onItemValueAddedCallback(e,r,n,e.choices)}return n},t.prototype.onPropertyValueChanged=function(t,o,i){var n=this;e.prototype.onPropertyValueChanged.call(this,t,o,i),"viewType"===t&&this.tabs.forEach((function(e){var t=n.viewType===e.id;e.active=t,e.disableHide=t}))},t.prototype.initResponsivityManager=function(e){this.responsivityManager=new Go(e,this)},t.prototype.resetResponsivityManager=function(){this.responsivityManager&&(this.responsivityManager.dispose(),this.responsivityManager=void 0)},Object.defineProperty(t.prototype,"showPageNavigator",{get:function(){return this.showPageNavigatorValue&&this.allowShowPageNavigator},set:function(e){this.showPageNavigatorValue=e},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){var t=this;this.isCreatorDisposed=!0,this.tabs=[],Object.keys(this.plugins).forEach((function(e){var o=t.plugins[e];"function"==typeof o.deactivate&&o.deactivate(),"function"==typeof o.dispose&&o.dispose()})),e.prototype.dispose.call(this)},t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-creator").append("svc-creator--mobile",this.isMobileView).append("svc-creator--touch",this.isTouch).append("svc-creator--disable-animations",!this.animationEnabled).toString()},t.prototype.applyTheme=function(e){this.syncTheme(e);var t=this.getPlugin("designer");t&&t.updateThemeSettings()},t.prototype.syncTheme=function(e){if(e){this.creatorTheme=e;var t={};q(t,null==e?void 0:e.cssVariables),this.themeVariables=t}},J([(0,o.property)({defaultValue:!0})],t.prototype,"showDesignerTab",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showJSONEditorTab",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showTestSurveyTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showThemeTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showCreatorThemeSettings",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showTranslationTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showLogicTab",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"useTableViewInLogicTab",void 0),J([(0,o.property)({defaultValue:200})],t.prototype,"pageHoverDelay",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"inplaceEditForValues",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"previewShowResults",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isAutoSave",void 0),J([(0,o.property)()],t.prototype,"showOptions",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showSearch",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"generateValidJSON",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),J([(0,o.property)({defaultValue:"landscape"})],t.prototype,"previewOrientation",void 0),J([(0,o.property)()],t.prototype,"surveyValue",void 0),J([(0,o.property)()],t.prototype,"viewType",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowShowToolbox",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showToolboxValue",void 0),J([(0,o.property)()],t.prototype,"showSidebarValue",void 0),J([Co()],t.prototype,"addPage",null),J([wo()],t.prototype,"doOnQuestionAdded",null),J([wo()],t.prototype,"doOnPanelAdded",null),J([wo()],t.prototype,"doOnPageAdded",null),J([Co()],t.prototype,"deleteObject",null),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){var o=t.getPlugin("theme");o&&(e?(t.onModified.add(t._syncSaveActions),o.onThemePropertyChanged.add(t._syncSaveActions),o.onThemeSelected.add(t._syncSaveActions)):(t.onModified.remove(t._syncSaveActions),o.onThemePropertyChanged.remove(t._syncSaveActions),o.onThemeSelected.remove(t._syncSaveActions)))}})],t.prototype,"syncSaveButtons",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showSaveButton",void 0),J([Co()],t.prototype,"convertCurrentQuestion",null),J([Co()],t.prototype,"addNewQuestionInPage",null),J([(0,o.property)({defaultValue:!1})],t.prototype,"showHeaderInEmptySurvey",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowShowPageNavigator",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showPageNavigatorValue",void 0),J([(0,o.property)({getDefaultValue:function(e){return e.showTabsDefault}})],t.prototype,"showTabs",void 0),J([(0,o.property)({getDefaultValue:function(e){return e.showToolbarDefault}})],t.prototype,"showToolbar",void 0),J([(0,o.property)({getDefaultValue:function(){return i.layout.allowCollapseSidebar}})],t.prototype,"allowCollapseSidebar",void 0),J([(0,o.property)({getDefaultValue:function(){return i.designer.showAddQuestionButton}})],t.prototype,"showAddQuestionButton",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){t.survey.setIsMobile(!!e)}})],t.prototype,"isMobileView",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isTouch",void 0),J([(0,o.property)({defaultValue:"left",onSet:function(e,t){t.toolbox&&(t.toolbox.setLocation(e),t.updateToolboxIsCompact())}})],t.prototype,"toolboxLocation",void 0),J([(0,o.property)({defaultValue:"right"})],t.prototype,"sidebarLocation",void 0),J([(0,o.property)({defaultValue:"never"})],t.prototype,"expandCollapseButtonVisibility",void 0),J([(0,o.property)({defaultValue:!1,onSet:function(e,t){if(!e)throw new Error("Creator is disposed")}})],t.prototype,"isCreatorDisposed",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"enableLinkFileEditor",void 0),J([(0,o.property)({defaultValue:{}})],t.prototype,"themeVariables",void 0),J([(0,o.property)()],t.prototype,"creatorTheme",void 0),t}(o.Base),Ki=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t}(Wi),Yi=function(){function e(){}return Object.defineProperty(e,"currentTheme",{get:function(){ee.warnNonSupported("StylesManager")},set:function(e){ee.warnNonSupported("StylesManager")},enumerable:!1,configurable:!0}),e.applyTheme=function(e){ee.warnNonSupported("StylesManager")},e}();function Xi(e,t){e.creator=t,e.isPopupEditorContent=!1,e.onElementWrapperComponentName.add((function(t,o){var i=o.componentName;"component"===o.wrapperName&&(o.componentName=tn(o.element,o.reason,e.isPopupEditorContent)),"content-component"===o.wrapperName&&(o.componentName=on(o.element)),"row"===o.wrapperName&&(o.componentName="svc-row"),"itemvalue"===o.wrapperName&&(o.componentName=rn(o.item,o.element)),o.componentName=o.componentName||i})),e.onElementWrapperComponentData.add((function(e,o){var i=o.data;"component"===o.wrapperName&&(o.data=nn(o.element,o.reason,t)),"row"===o.wrapperName&&(o.data={creator:t,row:o.element}),"itemvalue"===o.wrapperName&&(o.data=an(o.item,o.element,t)),o.data=o.data||i})),e.getRendererForString=function(e,o){if(!t.readOnly&&sn(e))return en},e.getRendererContextForString=function(e,o){return!t.readOnly&&sn(e,o.name)?{creator:t,element:e,locStr:o}:o}}function $i(e){for(var t=e;t;){if(t.isContentElement)return!0;t=t.parentQuestion}return!1}var en="svc-string-editor";function tn(e,t,i){if("logo-image"===t)return"svc-logo-image";if("cell"===t||"column-header"===t||"row-header"===t){if($i(function(e){return e?e.row?e.row.data:e.column?e.column.colOwner:null:null}(e)))return;return"svc-matrix-cell"}if(!$i(e)){if(e instanceof o.Question){var n=e.isDescendantOf("dropdown")||e.isDescendantOf("tagbox");return i?n?"svc-cell-dropdown-question":"svc-cell-question":e.customWidget?"svc-widget-question":n?"svc-dropdown-question":e.isDescendantOf("image")?"svc-image-question":"svc-question"}if(e instanceof o.PanelModel)return"svc-panel"}}function on(e){if(e.isDescendantOf("rating")&&!$i(e))return"svc-rating-question-content"}function nn(e,t,i){return"logo-image"===t?i:"cell"===t||"column-header"===t||"row-header"===t?{creator:i,element:e,question:e.question,row:e.row,column:e.column}:tn(e,t,!1)?e instanceof o.Question||e instanceof o.PanelModel?i:null:void 0}function rn(e,t){return $i(t)?o.SurveyModel.TemplateRendererComponentName:t.isDescendantOf("imagepicker")?"svc-image-item-value":"svc-item-value"}function an(e,t,o){return t.isContentElement?e:{creator:o,question:t,item:e}}function sn(e,t){return!(e.parentQuestion instanceof o.QuestionMatrixDropdownModelBase&&(e.data||$i(e.parentQuestion)))&&(!$i(e)||e.isEditableTemplateElement)}function ln(e){if(!e.tagName)return!1;var t=e.tagName.toLowerCase();return-1!==["input","textarea"].indexOf(t)||-1!==["span","div"].indexOf(t)&&e.isContentEditable}function un(e,t){ee.warnNonSupported("registerAdorner","This functionality is no longer supported.")}function pn(e){void 0===e&&(e=void 0),ee.warnNonSupported("removeAdorners","This functionality is no longer supported.")}var cn=function(e){function t(t,i,n){var r=e.call(this)||this;if(r.item=t,r.creator=i,r.model=n,r.click=function(e){r.allowAdd&&(r.creator.clickToolboxItem(r.item.json),r.hidePopup())},r.onPointerUp=function(e){r.hidePopup(),r.toolboxItem.isPressed=!1,document.removeEventListener("pointerup",r.onPointerUp)},r.startDragToolboxItem=function(e,t){var o=r.creator.getJSONForNewElement(r.item.json);return r.dragDropHelper.startDragToolboxItem(e,o,r.item),!0},r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragToolboxItem),!r.isDotsItem()){var a=t.popupModel;if(a){var s=(new o.CssClassBuilder).append(a.cssClass).append("svc-toolbox-subtypes").toString();a.cssClass=s,a.isFocusedContainer=!1,a.contentComponentName="svc-toolbox-list",a.contentComponentData.creator=i,a.isFocusedContent=!1}}return r}return K(t,e),Object.defineProperty(t.prototype,"toolboxItem",{get:function(){return this.item},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemComponent",{get:function(){return this.creator&&!this.creator.toolbox.showSubitems&&this.toolboxItem.hasSubItems?ve.defaultItemComponent:this.item.component||ve.defaultItemComponent},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowAdd",{get:function(){return!this.creator.readOnly},enumerable:!1,configurable:!0}),t.prototype.onMouseOver=function(e,t){this.model.mouseOverHandler(e)},t.prototype.onMouseOverTool=function(e,t){var o;(null===(o=e.popupModel)||void 0===o?void 0:o.isVisible)&&this.onMouseOver(e,t)},t.prototype.onMouseLeave=function(e,t){e.hidePopupDelayed(this.creator.toolbox.subItemsHideDelay)},t.prototype.onPointerDown=function(e){var t;if(e.stopPropagation(),this.allowAdd){if(this.isDotsItem())return!0;this.dragOrClickHelper.onPointerDown(e),this.toolboxItem.isPressed=!0,document.addEventListener("pointerup",this.onPointerUp),null===(t=this.creator)||void 0===t||t.onDragDropItemStart()}},t.prototype.isDotsItem=function(){return 0===this.item.id.indexOf("dotsItem-id")},t.prototype.hidePopup=function(){this.toolboxItem.hidePopup(),this.toolboxItem.isHovered=!1},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t}(o.Base);r(9671),r(7205);var dn=function(e){function t(t,i){var n=e.call(this)||this;return n.pagesController=t,n.pageEditMode=i,n.pagesChangedFunc=function(e,t){n.buildItems()},n.currentPagesChangedFunc=function(e,t){n.currentPage=n.pagesController.currentPage},n.pcPropertyChangedHandler=function(e,t){"toolboxLocation"===t.name&&("sidebar"==n.pagesController.creator.toolboxLocation?n.popupModel.horizontalPosition="right":n.popupModel.horizontalPosition=n.pagesController.creator.toolboxLocation)},n.togglePageSelector=function(e){return n.popupModel.toggleVisibility()},n.icon="icon-select-page",n.pagesController.onPagesChanged.add(n.pagesChangedFunc),n.pagesController.onCurrentPageChanged.add(n.currentPagesChangedFunc),n.pageListModel=new o.ListModel({items:[],onSelectionChanged:function(e){n.pagesController.selectPage(e.data),n.popupModel.hide()},allowSelection:!0}),n.popupModel=new o.PopupModel("sv-list",{model:n.pageListModel},{cssClass:"svc-creator-popup"}),n.pagesController&&(n.popupModel.horizontalPosition=n.pagesController.creator.toolboxLocation),n.popupModel.onShow=function(){n.pageListModel.selectedItem=n.getActionBarByPage(n.pagesController.currentPage),n.isPopupOpened=!0},n.popupModel.onHide=function(){n.isPopupOpened=!1},n.pagesController.creator.onPropertyChanged&&n.pagesController.creator.onPropertyChanged.add(n.pcPropertyChangedHandler),n.buildItems(),n}return K(t,e),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.stopItemsContainerHeightObserver(),this.pagesController.onPagesChanged.remove(this.pagesChangedFunc),this.pagesController.onCurrentPageChanged.remove(this.currentPagesChangedFunc),this.pagesController.creator.onPropertyChanged&&(this.pagesController.creator.onPropertyChanged.remove(this.pcPropertyChangedHandler),this.pcPropertyChangedHandler=void 0),this.pageListModel&&this.pageListModel.dispose(),this.popupModel&&this.popupModel.dispose(),this._scrollableContainer=void 0,this._itemsContainer=void 0},t.prototype.getActionBarByPage=function(e){for(var t=0;t<this.items.length;t++)if(this.items[t].data===e)return this.items[t];return null},t.prototype.setItems=function(e){this.items=e,this.pageListModel.setItems(e),this.updateVisibility()},t.prototype.buildItems=function(){this.currentPage=this.pagesController.currentPage||this.pagesController.pages[0];for(var e=[],t=this.pagesController.pages,o=0;o<t.length;o++)e.push(this.createActionBarItem(t[o]));if("bypage"===this.pagesController.creator.pageEditMode){var i=this.pagesController.creator.getPlugin("designer").model.newPage;i&&e.push(this.createActionBarItem(i))}this.setItems(e)},t.prototype.patchContainerOffset=function(e){for(;e;){if(-1!==e.className.indexOf("svc-tab-designer--with-page-navigator"))return void(e.offsetParent.scrollTop=0);e=e.parentElement}},t.prototype.createActionBarItem=function(e){var t=this,i={id:e.id,title:new o.ComputedUpdater((function(){var o=e.name,i=e.title;return t.pagesController?t.pagesController.getDisplayName(e):i||o}))};return i.active=new o.ComputedUpdater((function(){return e===t.currentPage})),i.action=function(o){t.scrollToPage(e)},i.data=e,this.createActionBarCore(i)},Object.defineProperty(t.prototype,"isByPageMode",{get:function(){return"bypage"===this.pagesController.creator.pageEditMode},enumerable:!1,configurable:!0}),t.prototype.scrollToPage=function(e){var t=this;if("bypage"===this.pageEditMode)return this.pagesController.currentPage=e,this.currentPage=e,void this.pagesController.creator.selectElement(this.pagesController.currentPage);var o=document.getElementById(e.id);if(o){var i=this.pagesController.pages.indexOf(e)===this.pagesController.pages.length-1;this._scrollableContainer?(this._scrollableContainer.scrollTo(this._scrollableContainer.scrollLeft,o.offsetTop-20),this.patchContainerOffset(o),i&&setTimeout((function(){t._scrollableContainer.scrollTo(t._scrollableContainer.scrollLeft,o.offsetTop-20),t.patchContainerOffset(o)}),50)):(o.scrollIntoView({block:"start"}),this.patchContainerOffset(o),i&&setTimeout((function(){o.scrollIntoView({block:"start"}),t.patchContainerOffset(o)}),50))}},t.prototype.createActionBarCore=function(e){return new o.Action(e)},Object.defineProperty(t.prototype,"pageSelectorCaption",{get:function(){return Z("ed.selectPage")},enumerable:!1,configurable:!0}),t.prototype.onContainerScroll=function(e){var t=e.scrollTop,o=e.clientHeight,i=t+o,n=[],r=void 0,a=0;return this.pagesController.pages.forEach((function(e){var o=document.getElementById(e.id);if(o){var s=o.offsetTop,l=s+o.clientHeight;if(!(s<i||l>t))return;var u=s-t,p=i-l,c=o.clientHeight;u<0&&(c+=u),p<0&&(c+=p),(c/=o.clientHeight)>0&&(n.push({page:e,visiblePart:c}),c>a&&(a=c,r=e))}})),this.currentPage=r,n},t.prototype.stopItemsContainerHeightObserver=function(){this._itemsContainer=void 0,this._resizeObserver&&(this._resizeObserver.disconnect(),this._resizeObserver=void 0),this.isDisposed||(this.visibleItemsStartIndex=0,this.visibleItemsCount=Number.MAX_VALUE)},t.prototype.setScrollableContainer=function(e){this._scrollableContainer=e},t.prototype.setItemsContainer=function(e){var t=this;this.stopItemsContainerHeightObserver(),this._itemsContainer=e,this._resizeObserver=new ResizeObserver((function(e,o){return t.updateVisibleItems(e[0].contentBoxSize[0].blockSize)})),this._resizeObserver.observe(e)},t.prototype.updateVisibleItems=function(e){if(this.updateVisibility(),!this.isByPageMode){var o=e-t.PAGE_NAVIGATION_MENU_ITEM_HEIGHT;this.visibleItemsCount=Math.floor(o/t.PAGE_NAVIGATION_ITEM_HEIGHT);var i=this.pagesController.pages.indexOf(this.currentPage),n=0;i>=this.visibleItemsCount&&(n=this.items.length-i-1<this.visibleItemsCount/2?this.items.length-this.visibleItemsCount:i-Math.floor(this.visibleItemsCount/2)),this.visibleItemsStartIndex=n}},t.prototype._updateVisibility=function(){this.hasScrolling=!this._scrollableContainer||this._scrollableContainer.scrollHeight>this._scrollableContainer.clientHeight,this.visible=this.items.length>1&&(this.hasScrolling||this.isByPageMode),this.isByPageMode&&(this.visibleItemsStartIndex=0,this.visibleItemsCount=this.items.length)},t.prototype.updateVisibility=function(){var e=this;setTimeout((function(){e._updateVisibility()}),10)},Object.defineProperty(t.prototype,"visibleItems",{get:function(){return this.items.length<=this.visibleItemsCount?this.items:this.items.slice(this.visibleItemsStartIndex,this.visibleItemsStartIndex+this.visibleItemsCount)},enumerable:!1,configurable:!0}),t.PAGE_NAVIGATION_MENU_ITEM_HEIGHT=44,t.PAGE_NAVIGATION_ITEM_HEIGHT=36,J([(0,o.property)({defaultValue:!0})],t.prototype,"hasScrolling",void 0),J([(0,o.propertyArray)()],t.prototype,"items",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"visible",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isPopupOpened",void 0),J([(0,o.property)({onSet:function(e,t){var o=t.pagesController.pages.indexOf(e);if(!(o>=t.visibleItemsStartIndex&&o<t.visibleItemsStartIndex+t.visibleItemsCount)){var i=t.visibleItemsStartIndex;if(o<t.visibleItemsStartIndex&&(i=o),o>=t.visibleItemsStartIndex+t.visibleItemsCount&&(i=o-t.visibleItemsCount+1),t.visibleItemsStartIndex!==i)if(t.visible&&t._itemsContainer){var n=t._itemsContainer.querySelectorAll(".svc-page-navigator__selector + div")[0];if(n){var r="svc-page-navigator__items--"+(t.visibleItemsStartIndex<i?"up":"down");n.className=r,setTimeout((function(){n.className="",t.visibleItemsStartIndex=i}),250)}}else t.visibleItemsStartIndex=i}}})],t.prototype,"currentPage",void 0),J([(0,o.property)({defaultValue:0})],t.prototype,"visibleItemsStartIndex",void 0),J([(0,o.property)({defaultValue:Number.MAX_VALUE})],t.prototype,"visibleItemsCount",void 0),t}(o.Base);r(4767);var hn=function(e){function t(t,n){var r=e.call(this,t,n)||this;return r.addGhostPage=function(e){void 0===e&&(e=!0);var t=r.page;r.isGhost&&r.creator.addPage(t,e,(function(){return t.unRegisterFunctionOnPropertiesValueChanged(["title","description"],"add_ghost"),t.name=ee.getNewPageName(r.creator.survey.pages),!0}))&&(r.creator.survey.currentPage=t),e&&r.creator.selectElement(t)},r.addNewQuestion=function(e,t,o){r.creator.addNewQuestionInPage((function(e){r.addGhostPage(!1),r.creator.survey.currentPage=r.page}),null,o||r.currentAddQuestionType||i.designer.defaultAddQuestionType)},r.startDragSurveyElement=function(e){var t,o=r.surveyElement,i=r.creator.selectedElement===o;return r.dragDropHelper.startDragSurveyElement(e,o,i),r.creator.collapsePagesOnDrag&&(null===(t=r.creator.designerStateManager)||void 0===t||t.suspend(),r.creator.collapseAllPages()),!0},r.questionTypeSelectorModel=r.creator.getQuestionTypeSelectorModel((function(e){r.currentAddQuestionType=e,r.addGhostPage(!1),r.creator.survey.currentPage=r.page})),r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragSurveyElement),r}return K(t,e),t.prototype.updateDragTypeOverMe=function(){var e;this.isDisposed||(this.dragTypeOverMe=null===(e=this.page)||void 0===e?void 0:e.dragTypeOverMe)},t.prototype.updateIsDragMe=function(){var e;this.isDisposed||(this.isDragMe=null===(e=this.page)||void 0===e?void 0:e.isDragMe)},t.prototype.updateShowPlaceholder=function(e){this.showPlaceholder=!this.isGhost&&0===(e||this.page.elements).length},t.prototype.updateActionVisibility=function(t,o){e.prototype.updateActionVisibility.call(this,t,!this.isGhost&&o)},t.prototype.updateActionsContainer=function(t){e.prototype.updateActionsContainer.call(this,t),"never"!=this.creator.expandCollapseButtonVisibility&&this.actionContainer.addAction(this.expandCollapseAction)},Object.defineProperty(t.prototype,"dragInsideCollapsedContainer",{get:function(){return this.collapsed},enumerable:!1,configurable:!0}),t.prototype.getAllowExpandCollapse=function(t){return!this.isGhost&&e.prototype.getAllowExpandCollapse.call(this,t)},t.prototype.attachElement=function(t){var o=this;e.prototype.attachElement.call(this,t),this.dragTypeOverMe=null,t&&(t.surveyChangedCallback=function(){o.isPageLive=!!t.survey},this.calcIsGhostPage(t)&&(this.updateActionsProperties(),t.registerFunctionOnPropertiesValueChanged(["title","description"],(function(){o.addGhostPage(),o.updateShowPlaceholder()}),"add_ghost"),this.patchPageForDragDrop(t,this.addGhostPage)),t.registerFunctionOnPropertiesValueChanged(["dragTypeOverMe"],(function(){o.updateDragTypeOverMe()})),t.registerFunctionOnPropertiesValueChanged(["isDragMe"],(function(){o.updateIsDragMe()})),t.registerFunctionOnPropertiesValueChanged(["elements"],(function(e){o.updateShowPlaceholder(e)})),this.updateShowPlaceholder(),t.onFirstRendering(),t.updateCustomWidgets(),t.setWasShown(!0),this.checkActionProperties(),this.dragTypeOverMe=t.dragTypeOverMe,this.isDragMe=t.isDragMe)},t.prototype.detachElement=function(t){t&&(t.unRegisterFunctionOnPropertiesValueChanged(["dragTypeOverMe","isDragMe"]),t.unRegisterFunctionOnPropertiesValueChanged(["title","description"],"add_ghost"),t.surveyChangedCallback=void 0),e.prototype.detachElement.call(this,t),this.isDisposed||(this.dragTypeOverMe=null)},t.prototype.onElementSelectedChanged=function(t){e.prototype.onElementSelectedChanged.call(this,t),this.isSelected=t,t&&"bypage"===this.creator.pageEditMode&&this.setSurveyElement(this.creator.selectedElement),t&&this.onPageSelected()},t.prototype.patchPageForDragDrop=function(e,t){e._isGhost=!0,e._addGhostPageViewModel=function(){delete e._isGhost,delete e._addGhostPageViewModel,t()}},t.prototype.calcIsGhostPage=function(e){return this.creator.survey.pages.indexOf(e)<0},Object.defineProperty(t.prototype,"isGhost",{get:function(){return this.calcIsGhostPage(this.page)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.pagePlaceHolderMobile"):Z("ed.pagePlaceHolder")},enumerable:!1,configurable:!0}),t.prototype.isOperationsAllow=function(){return e.prototype.isOperationsAllow.call(this)&&!this.isGhost&&"single"!==this.creator.pageEditMode&&this.creator.allowModifyPages},t.prototype.getPage=function(){return this.surveyElement},Object.defineProperty(t.prototype,"page",{get:function(){return this.getPage()},enumerable:!1,configurable:!0}),t.prototype.createActionContainer=function(){var e=new o.ActionContainer;return e.sizeMode="small",e},t.prototype.getExpandCollapseAction=function(){var t=e.prototype.getExpandCollapseAction.call(this);return t.needSeparator=!0,t},t.prototype.select=function(e,t){e.isGhost||("single"!==e.creator.pageEditMode?(e.creator.selectElement(e.page,void 0,!1),this.onPageSelected()):e.creator.selectElement(e.creator.survey,void 0,!1)),t.stopPropagation(),t.cancelBubble=!0},Object.defineProperty(t.prototype,"css",{get:function(){var t=e.prototype.getCss.call(this);return this.dragDropHelper.draggedElement&&this.dragDropHelper.draggedElement.isPage?(this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(t+=" svc-question__content--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(t+=" svc-question__content--drag-over-bottom")):(this.dragTypeOverMe&&this.showPlaceholder?t="svc-question__content--drag-over-inside":this.dragTypeOverMe&&0===this.page.elements.length&&this.creator.survey.pages.length>0&&(t="svc-page--drag-over-empty",this.creator&&!this.creator.showAddQuestionButton&&(t+=" svc-page--drag-over-empty-no-add-button")),this.dragTypeOverMe&&this.collapsed?(this.dragIn(),t+=" svc-page__content--collapsed-drag-over-inside"):this.dragOut()),this.allowExpandCollapse&&(t+=" svc-page__content--collapse-"+this.creator.expandCollapseButtonVisibility,this.renderedCollapsed&&(t+=" svc-page__content--collapsed"),this.expandCollapseAnimationRunning&&(t+=" svc-page__content--animation-running")),this.isDragMe&&(t+=" svc-page__content--dragged"),this.isGhost?t+" svc-page__content--new":(this.creator.isElementSelected(this.page)&&(t+=" svc-page__content--selected"),t.trim())},enumerable:!1,configurable:!0}),t.prototype.hoverStopper=function(e,t){e.__svc_question_processed=!0},t.prototype.duplicate=function(){var e=this.creator.copyPage(this.page);this.creator.selectElement(e)},t.prototype.delete=function(){this.creator.deleteElement(this.page)},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return!this.currentAddQuestionType&&this.creator?this.creator.getLocString("ed.addNewQuestion"):this.creator?this.creator.getAddNewQuestionText(this.currentAddQuestionType):""},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"footerActionsBar",{get:function(){var e=this;if(!this._footerActionsBar){this._footerActionsBar=new o.ActionContainer,this._footerActionsBar.containerCss="svc-page__footer",this._footerActionsBar.cssClasses={item:"svc-btn",itemTitle:"svc-text svc-text--normal svc-text--bold"};var t=[{css:"svc-add-new-question-action",visible:new o.ComputedUpdater((function(){return e.showAddQuestionButton})),component:"svc-add-new-question-btn",data:this}];t=this.creator.getUpdatedPageAdornerFooterActions(this,t),this.footerActionsBar.setItems(t)}return this._footerActionsBar},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){var e,t=this.surveyElement.cssClasses.page;return(null==t?void 0:t.description)?null===(e=this.rootElement)||void 0===e?void 0:e.querySelector(":scope ".concat((0,o.classesToSelector)(t.description))):null},t.prototype.getInnerAnimatedElements=function(){var e;return this.surveyElement.cssClasses.pageRow?[].slice.call(null===(e=this.rootElement)||void 0===e?void 0:e.querySelectorAll(":scope .svc-page__footer, :scope ".concat((0,o.classesToSelector)(this.surveyElement.cssRoot)," > .svc-row"))):null},t.prototype.onPageSelected=function(){this.rootElement&&ee.scrollIntoViewIfNeeded(this.rootElement)},t.prototype.getAllowDragging=function(t){return this.creator.allowDragPages&&e.prototype.getAllowDragging.call(this,t)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){this.dragOrClickHelper.onPointerDown(e)},Object.defineProperty(t.prototype,"dropTargetName",{get:function(){return!this.isGhost&&this.page?this.page.name:null},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!1})],t.prototype,"isSelected",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isPageLive",void 0),J([(0,o.property)()],t.prototype,"showPlaceholder",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),J([(0,o.property)({defaultValue:null})],t.prototype,"dragTypeOverMe",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragMe",void 0),t}(Ut);r(4880);var gn=function(e){function t(t,o,i){var n=e.call(this)||this;return n.creator=t,n.row=o,n.templateData=i,n.dragTypeOverMe=n.row.dragTypeOverMe,n.row.onPropertyChanged.add((function(e,t){"dragTypeOverMe"==t.name&&(n.dragTypeOverMe=t.newValue)})),n}return K(t,e),Object.defineProperty(t.prototype,"cssClasses",{get:function(){var e="svc-row";return 1===this.row.elements.length&&"sv-drag-drop-ghost-survey-element-name"===this.row.elements[0].name&&(e+=" svc-row--ghost"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(e+=" svc-row--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(e+=" svc-row--drag-over-bottom"),e},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"dragTypeOverMe",void 0),t}(o.Base);r(3844);var mn=function(e){function t(t,n,r){var a=e.call(this,t,n)||this;return a.templateData=r,a.startDragSurveyElement=function(e){var t=a.surveyElement,o=a.creator.selectedElement===t;return a.dragDropHelper.startDragSurveyElement(e,t,o),!0},a.addNewQuestion=function(){a.creator.addNewQuestionInPage((function(e){}),a.surveyElement instanceof o.PanelModelBase?a.surveyElement:null,a.currentAddQuestionType||i.designer.defaultAddQuestionType)},a.questionTypeSelectorModel=a.creator.getQuestionTypeSelectorModel((function(e){a.currentAddQuestionType=e}),a.surveyElement),n.isQuestion&&n.setCanShowOptionItemCallback&&n.setCanShowOptionItemCallback((function(e){return!t.readOnly&&(e!==a.surveyElement.newItem||t.maximumChoicesCount<1||n.choices.length<t.maximumChoicesCount)})),a.checkActionProperties(),a.dragOrClickHelper=new o.DragOrClickHelper(a.startDragSurveyElement),Ko.setQuestion(a),a}return K(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),t.prototype.canSelectElement=function(){return e.prototype.canSelectElement.call(this)&&this.surveyElement.isInteractiveDesignElement},t.prototype.select=function(e,t){if(e.canSelectElement()){var o=e.creator,i=e.surveyElement,n=null===document||void 0===document?void 0:document.activeElement;return o.selectedElement!==i&&n&&n.blur&&"input"===n.tagName.toLocaleLowerCase()&&n.blur(),t.stopPropagation(),t.cancelBubble=!0,o.selectElement(i,void 0,!1),!0}},t.prototype.rootCss=function(){var t=this.surveyElement.isQuestion&&!this.surveyElement.startWithNewLine;return(new o.CssClassBuilder).append(e.prototype.getCss.call(this)).append("svc-question__adorner").append("svc-question__adorner--selected",!!this.creator.isElementSelected(this.surveyElement)).append("svc-question__adorner--collapsed",this.renderedCollapsed).append("svc-question__adorner--start-with-new-line",t).append("svc-question__adorner--collapse-"+this.creator.expandCollapseButtonVisibility,!0).toString()},t.prototype.css=function(){if(!this.surveyElement.isInteractiveDesignElement)return"";var e="svc-question__content";return e+="function"==typeof this.surveyElement.getType?" svc-question__content--"+this.surveyElement.getType():"",this.creator.isElementSelected(this.surveyElement)&&(e+=" svc-question__content--selected"),this.isEmptyElement&&(e+=" svc-question__content--empty"),this.isEmptyTemplate&&(e+=" svc-question__content--empty-template"),this.renderedCollapsed&&(e+=" svc-question__content--collapsed"),this.surveyElement.hasTitle&&(this.surveyElement.isPanel||"hidden"!==this.surveyElement.getTitleLocation())||(e+=" svc-question__content--title-hidden"),this.surveyElement.hasTitleOnBottom&&(e+=" svc-question__content--title-bottom"),this.isDragMe&&(e+=" svc-question__content--dragged"),this.dragTypeOverMe&&this.canExpandOnDrag&&this.dragInsideCollapsedContainer?(this.dragIn(),e+=" svc-question__content--collapsed-drag-over-inside"):this.dragOut(),this.dragTypeOverMe===o.DragTypeOverMeEnum.InsideEmptyPanel&&(e+=" svc-question__content--drag-over-inside"),this.dragInsideCollapsedContainer||(this.dragTypeOverMe===o.DragTypeOverMeEnum.Left&&(e+=" svc-question__content--drag-over-left"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Right&&(e+=" svc-question__content--drag-over-right"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Top&&(e+=" svc-question__content--drag-over-top"),this.dragTypeOverMe===o.DragTypeOverMeEnum.Bottom&&(e+=" svc-question__content--drag-over-bottom"),this.creator&&(e=this.creator.getElementAddornerCssCallback(this.surveyElement,e))),e},Object.defineProperty(t.prototype,"isTitleLeft",{get:function(){return!this.surveyElement.isPanel&&"left"===this.surveyElement.getTitleLocation()},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){var e,t,i=(this.surveyElement.isPanel?this.surveyElement.cssClasses.panel:this.surveyElement.cssClasses).content;return this.surveyElement.isDescendantOf("rating")&&(i="svc-rating-question-content"),this.isTitleLeft?null===(e=this.rootElement)||void 0===e?void 0:e.querySelector(":scope ".concat((0,o.classesToSelector)(this.surveyElement.getRootCss()))):i?null===(t=this.rootElement)||void 0===t?void 0:t.querySelector(":scope ".concat((0,o.classesToSelector)(i))):null},t.prototype.getInnerAnimatedElements=function(){var e,t=this.surveyElement.isPanel?this.surveyElement.getContainerCss():this.surveyElement.getRootCss(),i=this.surveyElement.cssDescription,n=[":scope > .svc-question__content > *:not(.svc-question__drag-area):not(".concat((0,o.classesToSelector)(t),")")];!this.isTitleLeft&&i&&n.push(":scope ".concat((0,o.classesToSelector)(i)));var r=[].slice.call(null===(e=this.rootElement)||void 0===e?void 0:e.querySelectorAll(n.join(",")));return r.push(this.rootElement),r},t.prototype.expandWithDragIn=function(){e.prototype.expandWithDragIn.call(this),this.element.dragTypeOverMe=null,this.creator.dragDropSurveyElements.dropTarget=null},Object.defineProperty(t.prototype,"isDragMe",{get:function(){return this.surveyElement.isDragMe},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragTypeOverMe",{get:function(){return this.element.dragTypeOverMe},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isBannerShowing",{get:function(){return this.isUsingCarryForward||this.isUsingRestfull||this.isMessagePanelVisible},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isUsingCarryForward",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.isUsingCarryForward},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isUsingRestfull",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.isUsingRestful},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMessagePanelVisible",{get:function(){var e;return null===(e=this.element)||void 0===e?void 0:e.getPropertyValue("isMessagePanelVisible")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssCollapsedHiddenHeader",{get:function(){return this.element.cssHeader+" svc-element__header--hidden"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"cssCollapsedHiddenTitle",{get:function(){return this.element.cssTitle+" svc-element__title--hidden"},enumerable:!1,configurable:!0}),t.prototype.createBannerParams=function(){return this.createCarryForwardParams()||this.createUsingRestfulParams()||this.createCustomMessagePanel()},t.prototype.createCarryForwardParams=function(){var e,t=this;if(!this.isUsingCarryForward)return null;var o=null===(e=this.element)||void 0===e?void 0:e.choicesFromQuestion;if(!o)return null;var i=this.creator.survey.getQuestionByName(o);return i?{actionText:i.name,text:this.creator.getLocString("ed.carryForwardChoicesCopied"),onClick:function(){t.creator.selectElement(i)}}:null},t.prototype.createUsingRestfulParams=function(){var e=this;return this.isUsingRestfull?{actionText:this.creator.getLocString("ed.choicesLoadedFromWebLinkText"),text:this.creator.getLocString("ed.choicesLoadedFromWebText"),onClick:function(){e.creator.selectElement(e.element,"choicesByUrl")}}:null},t.prototype.createCustomMessagePanel=function(){if(!this.isMessagePanelVisible)return null;var e={question:this.element,actionText:"",messageText:"",onClick:function(){}};return this.creator&&this.creator.onCreateCustomMessagePanel.fire(this.creator,e),e.text=e.messageText,e},t.prototype.detachFromUI=function(){this.surveyElement.unRegisterFunctionOnPropertyValueChanged("isRequired","isRequiredAdorner"),this.surveyElement.unRegisterFunctionOnPropertyValueChanged("inputType","inputTypeAdorner"),this.surveyElement.setCanShowOptionItemCallback&&this.surveyElement.setCanShowOptionItemCallback(void 0)},Object.defineProperty(t.prototype,"isDraggable",{get:function(){return!0},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hoverDelay",{get:function(){return this.creator.animationEnabled?this.creator.pageHoverDelay:0},enumerable:!1,configurable:!0}),t.prototype.hover=function(t,o){this.surveyElement.isInteractiveDesignElement&&e.prototype.hover.call(this,t,o)},t.prototype.createActionContainers=function(){e.prototype.createActionContainers.call(this),this.actionContainer.sizeMode="small",this.topActionContainer=new o.ActionContainer,this.topActionContainer.sizeMode="small",this.topActionContainer.setItems([this.expandCollapseAction])},t.prototype.getActionById=function(t){var o=e.prototype.getActionById.call(this,t);return o||(o=this.topActionContainer.getActionById(t)),o},t.prototype.updateActionsProperties=function(){if(!this.isDisposed){e.prototype.updateActionsProperties.call(this);for(var t=this.actionContainer.visibleActions,o=!1,i=t.length-1;i>=0;i--)"convertTo"===t[i].id&&(o=!0),t[i].innerItem.location||(t[i].innerItem.location=o?"start":"end")}},t.prototype.updateElementAllowOptions=function(t,o){e.prototype.updateElementAllowOptions.call(this,t,o),this.updateActionVisibility("convertTo",o&&t.allowChangeType),this.updateActionVisibilityByProp("isrequired","isRequired",o&&t.allowChangeRequired),this.updateActionVisibilityByProp("convertInputType","inputType",t.allowChangeInputType),this.updateActionVisibilityByProp("convertInputType","rateDisplayMode",t.allowChangeInputType)},t.prototype.updateActionVisibilityByProp=function(e,t,i){var n=o.Serializer.findProperty(this.surveyElement.getType(),t);if(n){var r=this.creator.onIsPropertyReadOnlyCallback(this.surveyElement,n,n.readOnly,null,null);this.updateActionVisibility(e,i&&!r)}},Object.defineProperty(t.prototype,"isEmptyElement",{get:function(){if(this.surveyElement instanceof o.QuestionHtmlModel)return!this.surveyElement.html;if(this.surveyElement instanceof o.PanelModelBase){var e=this.surveyElement;return!e.rows||e.rows.length<=0||0===e.elements.length}return!1},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmptyTemplate",{get:function(){return this.surveyElement instanceof o.QuestionPanelDynamicModel&&0==this.surveyElement.templateElements.length},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"showHiddenTitle",{get:function(){return(!this.element.hasTitle||this.isTitleLeft)&&this.element.isInteractiveDesignElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.surveyElement instanceof o.QuestionHtmlModel?Z("ed.htmlPlaceHolder"):this.creator.isMobileView?Z("ed.panelPlaceHolderMobile"):Z("ed.panelPlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropSurveyElements},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isRequired",{get:function(){return this.surveyElement.isRequired},set:function(e){this.surveyElement.isRequired=e},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){this.dragOrClickHelper.onPointerDown(e)},t.prototype.getConvertToTypes=function(){var e=this,t=this.creator.getAvailableToolboxItems(this.element,!1),o=[];t.forEach((function(e){-1==o.indexOf(e.typeName)&&o.push(e.typeName)}));var i=$.getConvertToClasses(this.currentType,o,!0),n=[];return i.forEach((function(t){var o=e.creator.toolbox.items.filter((function(e){return e.name==t}));if(Array.isArray(o)&&o.length>0){var i=o[0];n.push(i)}})),n},t.prototype.buildDefaultJsonMap=function(e){var t={};function o(e){var o,i=(null===(o=e.json)||void 0===o?void 0:o.type)||e.id;if(e.json){var n=e.json;t[i]||(t[i]=[]),t[i].push(n)}}return e.forEach((function(e){o(e),(e.items||[]).forEach((function(e){o(e)}))})),t},t.prototype.convertQuestion=function(e,t,o){var i=this,n=(null==t?void 0:t.type)||e,r={};(o[n]||[]).forEach((function(e){if(i.jsonIsCorresponded(e)){r=W({},t);var o=i.element.toJSON(),a=i.cleanDefaultsFromJson(n,e);Object.keys(e).forEach((function(e){"type"==e||r[e]||(r[e]=void 0)})),Object.keys(t||{}).forEach((function(e){"type"!=e&&o[e]&&!a[e]&&(r[e]=void 0)}))}})),this.creator.convertCurrentQuestion(n,r)},t.prototype.getConvertToTypesActions=function(){var e=this,t=this.getConvertToTypes(),o=this.buildDefaultJsonMap(t),i=[],n=null;return t.forEach((function(t){var r=n&&t.category!=n.category,a=e.creator.createIActionBarItemByClass(t,r,(function(t,i){e.convertQuestion(t,i,o)}));n=t,i.push(a)})),i},Object.defineProperty(t.prototype,"currentType",{get:function(){return this.surveyElement.getType()},enumerable:!1,configurable:!0}),t.prototype.createConvertToAction=function(){var e=this,t=this.getConvertToTypesActions(),i=t.length>0,n=this.getSelectedItem(t,this.currentType),r={id:"convertTo",enabled:i,visibleIndex:0,title:n?n.title:G.getString("qt."+this.currentType),iconName:"icon-chevron_16x16"},a=this.createDropdownModel({actionData:r,items:t,updateListModel:function(t){e.updateQuestionTypeOrSubtypeListModel(t,!1)}});return a.iconName=new o.ComputedUpdater((function(){var t;return"small"===a.mode?null===(t=e.creator.toolbox.getItemByName(e.element.getType()))||void 0===t?void 0:t.iconName:"icon-chevron_16x16"})),a.iconSize=new o.ComputedUpdater((function(){return"small"===a.mode?24:16})),a.disableHide=!0,a},t.prototype.jsonsAreCompatible=function(e,t){var i=this,n=!0;return Object.keys(t).forEach((function(r){var a=void 0===e[r]?i.element.getDefaultPropertyValue(r):e[r];"type"==r||o.Helpers.isTwoValueEquals(t[r],a)||(n=!1)})),n},t.prototype.jsonIsCorresponded=function(e){return this.jsonsAreCompatible(this.element.toJSON(),e)},t.prototype.toolboxItemIsCorresponded=function(e,t){var o=this.element.getType(),i=e.json;if(e.id==o||e.json.type==o)return!t||this.jsonIsCorresponded(i)},t.prototype.cleanDefaultsFromJson=function(e,t){var i=o.QuestionFactory.Instance.createQuestion(e,"question");if(!i)return t;i.fromJSON(t);var n=i.toJSON();return n.type=e,delete n.name,n},t.prototype.updateQuestionTypeOrSubtypeListModel=function(e,t){var o,i,n,r=this,a=this.getConvertToTypes(),s=this.buildDefaultJsonMap(a),l=[],u=void 0,p=void 0;if(a.forEach((function(e){var t,o=i&&e.category!=i.category,a=r.creator.createIActionBarItemByClass(e,o,(function(e,t){r.convertQuestion(e,t,s)}));if(r.toolboxItemIsCorresponded(e,!!n)&&(n=a,p=e.items),(null===(t=e.items)||void 0===t?void 0:t.length)>0&&r.creator.toolbox.showSubitems){var c=[],d=void 0,h=!1;if(e.items.forEach((function(t){var o=r.creator.createIActionBarItemByClass(t,!1,(function(e,t){r.convertQuestion(e,t,s)}));r.toolboxItemIsCorresponded(t,!!n)&&(d=t),r.jsonsAreCompatible(e.json,t.json)&&(h=!0),c.push(o)})),!h&&c.length>0){var g=r.creator.createIActionBarItemByClass(e,!1,(function(e,t){r.convertQuestion(e,t,s)}));g.id=a.id+"-default",g.iconName=void 0,g.markerIconName=void 0,g.items=[],g.component=void 0,c.unshift(g),n!=a||d||(d=g)}a.setSubItems({items:c}),d&&(n=a,u=d,p=c)}i=e,l.push(a)})),t){if(p)return e.setItems(p),e.selectedItem=u,!!p}else{var c=null===(o=null==n?void 0:n.popupModel)||void 0===o?void 0:o.contentComponentData.model;c&&(c.selectedItem=u),e.setItems(l),e.selectedItem=n}},t.prototype.createConvertInputType=function(){var e=this,t=new o.ListModel([]);if(this.updateQuestionTypeOrSubtypeListModel(t,!0),0==t.actions.length)return null;var i=this.createDropdownModel({actionData:{id:"convertInputType",visibleIndex:1,title:"SUBTYPE",disableShrink:!0,iconName:"icon-chevron_16x16"},items:[],updateListModel:function(t){e.updateQuestionTypeOrSubtypeListModel(t,!0)}});return this.surveyElement.registerFunctionOnPropertiesValueChanged(["inputType","rateType"],(function(){var t=i.popupModel.contentComponentData.model;e.updateQuestionTypeOrSubtypeListModel(t,!0),i.title=t.selectedItem.title}),"inputTypeAdorner"),i.removePriority=1,i},t.prototype.getSelectedItem=function(e,t){var o=e.filter((function(e){return e.id===t}));return o.length>0?o[0]:void 0},t.prototype.createDropdownModel=function(e){var t=(0,o.createDropdownActionModel)({id:e.actionData.id,css:"sv-action--convertTo sv-action-bar-item--secondary",iconName:e.actionData.iconName,iconSize:16,title:e.actionData.title,enabled:e.actionData.enabled,visibleIndex:e.actionData.visibleIndex,disableShrink:e.actionData.disableShrink,location:"start",action:function(e){}},{items:e.items,allowSelection:!0,horizontalPosition:"center",cssClass:"svc-creator-popup",onShow:function(){var o=t.popupModel.contentComponentData.model;e.updateListModel(o)}}),i=t.popupModel.contentComponentData.model;return e.updateListModel(i),i.selectedItem&&(t.title=i.selectedItem.title),t.popupModel.displayMode=this.creator.isTouch?"overlay":"popup",t.data.locOwner=this.creator,t},t.prototype.createRequiredAction=function(){var e=this;this.surveyElement.isRequired;var t=new o.Action({id:"isrequired",ariaChecked:new o.ComputedUpdater((function(){return e.isRequired})),ariaRole:"checkbox",css:"svc-action-bar-item--right sv-action-bar-item--secondary",title:this.creator.getLocString("pe.isRequired"),visibleIndex:20,iconName:"icon-required",iconSize:16,action:function(){e.creator.isCanModifyProperty(e.surveyElement,"isRequired")&&(e.isRequired=e.getUpdatedPropertyValue("isRequired",!e.isRequired))}});return t.innerCss=new o.ComputedUpdater((function(){return(new o.CssClassBuilder).append("svc-required-action").append("svc-required-action--active",e.isRequired).toString()})),t.innerItem.title=new o.ComputedUpdater((function(){return e.isRequired?e.creator.getLocString("pe.removeRequiredMark"):e.creator.getLocString("pe.markRequired")})),t},t.prototype.getUpdatedPropertyValue=function(e,t){var o={obj:this.element,propertyName:e,value:this.element[e],newValue:t,doValidation:!1};return this.creator.onValueChangingCallback(o),o.newValue},t.prototype.buildActions=function(t){e.prototype.buildActions.call(this,t);var o=this.surveyElement;t.push(this.createConvertToAction());var i=this.createConvertInputType();i&&t.push(i),t[t.length-1].css+=" sv-action--convertTo-last",void 0!==o.isRequired&&v(o,"isRequired")&&b(o,"isRequired")&&t.push(this.createRequiredAction())},t.prototype.duplicate=function(){var e=this;setTimeout((function(){e.creator.fastCopyQuestion(e.surveyElement,!0)}),1)},Object.defineProperty(t.prototype,"addNewQuestionText",{get:function(){return!this.currentAddQuestionType&&this.creator?this.creator.getLocString("ed.addNewQuestion"):this.creator?this.creator.getAddNewQuestionText(this.currentAddQuestionType):""},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:""})],t.prototype,"currentAddQuestionType",void 0),t}(Ut);r(422);var fn=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.switchCollapse=function(){n.isCollapsed=!n.isCollapsed},n.surveyElement.registerFunctionOnPropertyValueChanged("isSelectedInDesigner",(function(){n.leftFocus()}),"dropdownCollapseChecker"),n.visibleCount=t.maxVisibleChoices,n.isCollapsed=n.isCollapsed&&n.needToCollapse,n}return K(t,e),Object.defineProperty(t.prototype,"question",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"itemComponent",{get:function(){return this.surveyElement.isDescendantOf("dropdown")?"survey-radiogroup-item":"survey-checkbox-item"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"needToCollapse",{get:function(){return this.visibleCount>0&&this.question.visibleChoices.length>this.visibleCount},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isCollapseView",{get:function(){return this.isCollapsed},enumerable:!1,configurable:!0}),t.prototype.leftFocus=function(){this.creator.isElementSelected(this.surveyElement)||this.isCollapsed||(this.isCollapsed=this.needToCollapse)},t.prototype.getChoiceCss=function(){return(new o.CssClassBuilder).append("svc-question__dropdown-choice").append("svc-question__dropdown-choice--collapsed",this.isCollapsed&&this.needToCollapse).toString()},t.prototype.getRenderedItems=function(){return this.isCollapsed?this.question.renderedChoices.slice(0,this.visibleCount):this.question.renderedChoices},t.prototype.getButtonText=function(){return this.isCollapsed?G.getString("ed.showMoreChoices"):G.getString("ed.showLessChoices")},t.prototype.dispose=function(){e.prototype.dispose.call(this),this.surveyElement.unRegisterFunctionOnPropertyValueChanged("isSelectedInDesigner","dropdownCollapseChecker")},J([(0,o.property)({defaultValue:!0})],t.prototype,"isCollapsed",void 0),J([(0,o.property)({defaultValue:-1})],t.prototype,"visibleCount",void 0),t}(mn);r(3140);var yn=function(e){function t(t,o,i){var n=e.call(this,t,o,i)||this;return n.imageLinkValueChangedHandler=function(){n.isEmptyImageLink=!n.question.imageLink,n.filePresentationModel.value=null,n.filePresentationModel.visible=!n.question.imageLink},n.isEmptyImageLink=!n.question.imageLink,n.surveyElement.registerFunctionOnPropertyValueChanged("imageLink",n.imageLinkValueChangedHandler,"imageLinkValueChanged"),n.surveyElement.locImageLink.onStringChanged.add(n.imageLinkValueChangedHandler),n.initFilePresentationModel(),n}return K(t,e),t.prototype.initFilePresentationModel=function(){var e=this;this.filePresentationModel=o.Serializer.createClass("file",{name:this.question.name});var t=new o.SurveyModel;this.filePresentationModel.setSurveyImpl(t),this.filePresentationModel.forceIsInputReadOnly=!this.creator.isCanModifyProperty(this.question,"imageLink"),this.filePresentationModel.filePlaceholder=this.placeholderText,this.filePresentationModel.chooseButtonCaption=this.chooseImageText,this.filePresentationModel.acceptedTypes="image/*",this.filePresentationModel.storeDataAsText=!1,this.filePresentationModel.cssClasses.chooseFileIconId="icon-choosefile",t.onOpenFileChooser.add((function(t,o){e.creator.chooseFiles(o.input,o.callback,o.context)})),t.onUploadFiles.add((function(t,o){o.files[0]&&e.creator.uploadFiles(o.files,e.question,(function(t,i){e.question.imageLink=i,o.callback(t,[{content:i,file:o.files[0]}])}),{element:e.question,elementType:e.question.getType(),propertyName:"imageLink"})}))},t.prototype.chooseFile=function(e){var t=e.rootElement.getElementsByClassName("svc-choose-file-input")[0],o={element:e.question,elementType:e.question.getType(),propertyName:"imageLink"};e.creator.chooseFiles(t,(function(t){e.isUploading=!0,e.creator.uploadFiles(t,e.surveyElement,(function(t,o){e.surveyElement.imageLink=o,e.isUploading=!1}),o)}),o)},Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return A(this.surveyElement.contentMode)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isEmptyElement",{get:function(){return this.isEmptyImageLink},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"question",{get:function(){return this.surveyElement},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"placeholderText",{get:function(){return this.creator.isMobileView?Z("ed.imagePlaceHolderMobile"):Z("ed.imagePlaceHolder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"chooseImageText",{get:function(){return Z("ed.imageChooseImage")},enumerable:!1,configurable:!0}),t.prototype.getAnimatedElement=function(){if(this.isEmptyImageLink){var t=this.filePresentationModel.cssClasses;if(t.root)return this.surveyElement.getWrapperElement().querySelector(":scope ".concat((0,o.classesToSelector)(t.root)))}return e.prototype.getAnimatedElement.call(this)},t.prototype.css=function(){return(new o.CssClassBuilder).append(e.prototype.css.call(this)).append("svc-question__content--loading",this.isUploading).toString()},t.prototype.dispose=function(){this.surveyElement.unRegisterFunctionOnPropertyValueChanged("imageLink","imageLinkValueChanged"),this.surveyElement.locImageLink.onStringChanged.remove(this.imageLinkValueChangedHandler),e.prototype.dispose.call(this)},J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isEmptyImageLink",void 0),t}(mn);r(3926);var vn=function(e){function t(t,o,i){var n=e.call(this)||this;return n.creator=t,n.surveyElement=o,n.templateData=i,n}return K(t,e),Object.defineProperty(t.prototype,"element",{get:function(){return N(this.surveyElement)},enumerable:!1,configurable:!0}),t.useRateValues=function(e){var t=e.contentQuestion?e.contentQuestion:e;return!!t.useRateValues&&t.useRateValues()},t.prototype.addItem=function(e){if(e.allowAdd&&e.enableAdd)if(t.useRateValues(e.element)){var i,n=e.element.rateValues.map((function(e){return e.value}));i=h(e.creator.getChoicesItemBaseTitle(),n);var r=new o.ItemValue(i);r.locOwner={getLocale:function(){return e.element.getLocale?e.element.getLocale():""},getMarkdownHtml:function(e){return e},getProcessedText:function(e){return e}},e.element.rateValues=e.element.rateValues.concat([r]);var a=e.element.rateValues;e.creator.onItemValueAddedCallback(e.element,"rateValues",a[a.length-1],a)}else e.element.rateMax+=e.element.rateStep},t.prototype.removeItem=function(e){if(e.allowRemove&&e.enableRemove){var i=o.Serializer.findProperty(e.element.getType(),"rateValues"),n=e.element.rateValues&&e.element.rateValues.length-1,r=e.element.rateValues&&e.element.rateValues[n]||null;if(e.creator.onCollectionItemDeletingCallback(e.element,i,e.element.rateValues,r)){var a=e.element;t.useRateValues(e.element)||n!==a.rateValues.length-1?(t.useRateValues(e.element)||(a.rateValues=a.rateValues),a.rateValues.splice(n,1)):a.rateMax-=a.rateStep}}},t.allowAddForElement=function(e,i){return(i<1||i>o.settings.ratingMaximumRateValueCount)&&!t.useRateValues(e)&&(i=o.settings.ratingMaximumRateValueCount),"smileys"==e.rateDisplayMode&&(i<1||i>10)&&(i=10),i<1||e.rateCount<i},Object.defineProperty(t.prototype,"allowAdd",{get:function(){return this.canAddOrRemove()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enableAdd",{get:function(){return this.allowAdd&&t.allowAddForElement(this.element,this.creator.maximumRateValues)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-item-value-controls__button").append("svc-item-value-controls__button--disabled",!this.enableAdd).append("svc-item-value-controls__add").toString()},enumerable:!1,configurable:!0}),t.allowRemoveForElement=function(e){return e.rateCount>2},t.prototype.canAddOrRemove=function(){return this.creator.isCanModifyProperty(this.element,"rateValues")&&this.creator.isCanModifyProperty(this.element,"rateCount")&&(!this.element.autoGenerate||this.creator.isCanModifyProperty(this.element,"rateMax"))},Object.defineProperty(t.prototype,"allowRemove",{get:function(){return this.canAddOrRemove()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"enableRemove",{get:function(){return this.allowRemove&&t.allowRemoveForElement(this.element)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-item-value-controls__button").append("svc-item-value-controls__button--disabled",!this.enableRemove).append("svc-item-value-controls__remove").toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hasTopLabel",{get:function(){return("top"==this.element.rateDescriptionLocation||"topBottom"==this.element.rateDescriptionLocation)&&!!this.element.minRateDescription},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"controlsClassNames",{get:function(){return(new o.CssClassBuilder).append("svc-rating-question-controls").append("svc-item-value-controls").append("svc-rating-question-controls--labels-top",this.hasTopLabel).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addTooltip",{get:function(){return Z("pe.addItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeTooltip",{get:function(){return Z("pe.removeItem")},enumerable:!1,configurable:!0}),t}(o.Base);r(6195);var bn={noneItem:"showNoneItem",otherItem:"showOtherItem",selectAllItem:"showSelectAllItem",refuseItem:"showRefuseItem",dontKnowItem:"showDontKnowItem"},Cn=function(e){function t(t,i,n){var r=e.call(this)||this;for(var a in r.creator=t,r.question=i,r.item=n,r.canTouchItems=!0,r.focusCameFromDown=!1,r.startDragItemValue=function(e,t){r.dragDropHelper.startDrag(e,r.item,r.question,t)},r.handleDragDropGhostPositionChanged=function(){r.ghostPosition=r.getGhostPosition(r.item),r.isDragDropGhost=r.item===r.dragDropHelper.draggedElement,r.item===r.dragDropHelper.prevDropTarget?(r.isDragDropMoveDown=r.item.isDragDropMoveDown,r.isDragDropMoveUp=r.item.isDragDropMoveUp):(r.isDragDropMoveDown=!1,r.isDragDropMoveUp=!1)},r.updateIsNew(i,n),bn)r.registerOnPropertyChanged(a,bn[a]);return r.isNew&&(i.renderedChoicesChangedCallback=function(){r.updateNewItemValue()},r.updateNewItemValue()),r.dragDropHelper.onGhostPositionChanged.add(r.handleDragDropGhostPositionChanged),r.dragOrClickHelper=new o.DragOrClickHelper(r.startDragItemValue),r.allowItemOperations={allowDelete:void 0,allowEdit:void 0,allowAdd:void 0},r.collectionProperty=o.Serializer.findProperty(i.getType(),r.collectionPropertyName),r.creator.onCollectionItemAllowingCallback(i.ownerObj||i,r.collectionProperty,i.visibleChoices,r.item,r.allowItemOperations),void 0===r.allowItemOperations.allowDelete&&(r.allowItemOperations.allowDelete=!0),void 0===r.allowItemOperations.allowAdd&&(r.allowItemOperations.allowAdd=!0),r.allowItemOperations.allowAdd||r.updateIsNewVisibility(),r.creator.isCanModifyProperty(i,"choices")||(r.canTouchItems=!1),r}return K(t,e),Object.defineProperty(t.prototype,"canBeDragged",{get:function(){return!this.isNew&&this.question.choices.indexOf(this.item)>-1},enumerable:!1,configurable:!0}),t.prototype.isBanStartDrag=function(e){return!this.isDraggable||"true"===e.target.getAttribute("contenteditable")||!this.canBeDragged},t.prototype.updateNewItemValue=function(){this.creator&&this.question&&this.question.newItem&&(this.question.newItem.value=this.creator.getNextItemValue(this.question),this.question.newItem.text=d(this.question.choices))},t.prototype.registerOnPropertyChanged=function(e,t){var o=this;if(this.question[e]===this.item){var i=this.question,n=this.item;i.registerFunctionOnPropertyValueChanged(t,(function(){o.updateIsNew(i,n)}))}},Object.defineProperty(t.prototype,"collectionPropertyName",{get:function(){return this.item.ownerPropertyName?this.item.ownerPropertyName:"choices"},enumerable:!1,configurable:!0}),t.prototype.onPointerDown=function(e){return!!this.isBanStartDrag(e)||(this.dragOrClickHelper.onPointerDown(e),!1)},Object.defineProperty(t.prototype,"dragDropHelper",{get:function(){return this.creator.dragDropChoices},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){e.prototype.dispose.call(this),this.dragDropHelper.onGhostPositionChanged.remove(this.handleDragDropGhostPositionChanged)},t.prototype.getGhostPosition=function(e){return this.dragDropHelper.dropTarget!==e?null:this.dragDropHelper.isBottom?"bottom":"top"},Object.defineProperty(t.prototype,"isDraggable",{get:function(){return this.isDraggableItem(this.item)},enumerable:!1,configurable:!0}),t.prototype.isDraggableItem=function(e){return!(this.creator.readOnly||!this.canTouchItems)&&-1!==this.question.choices.indexOf(e)},t.prototype.getSpecificProp=function(e){for(var t in bn)if(e.question[t]===e.item)return bn[t]},t.prototype.add=function(e){var t=this.getSpecificProp(e);t?e.question[t]=!0:(this.addNewItem(e.item,e.question,e.creator),this.updateIsNew(e.question,e.item))},t.prototype.addNewItem=function(e,t,o){e.value="newitem";var i=o.createNewItemValue(t);this.updateNewItemValue(),oi.get(i.locText).setAutoFocus()},t.prototype.remove=function(e){var t=this.getSpecificProp(e);if(t)e.question[t]=!1;else{var o=e.question.choices,i=o.indexOf(e.item);if(this.creator.onCollectionItemDeletingCallback(e.question,this.collectionProperty,o,e.item)){var n=this.findNextElementIndexToRemove(i);e.question.choices.splice(i,1),this.focusNextElementToRemove(n),this.updateIsNew(e.question,e.item)}}},t.prototype.onFocusOut=function(e){this.question._lastActiveItemValueIndex=this.question.choices.indexOf(this.item)},t.prototype.findNextElementIndexToRemove=function(e){var t=0;return this.question.choices.length>0&&((t=e<this.question._lastActiveItemValueIndex?e-1:e)<0&&(t=0),t>=this.question.choices.length-2&&(t=this.question.choices.length-2)),t},t.prototype.focusNextElementToRemove=function(e){var t=this;setTimeout((function(){var o;null===(o=document.getElementById(t.question.id).querySelectorAll(".svc-item-value-controls__remove")[e])||void 0===o||o.focus()}),100)},t.prototype.updateIsNew=function(e,t){this.isNew=!e.isItemInList(t)&&!this.isAutoGeneratedItem(t),this.updateIsNewVisibility()},t.prototype.updateIsNewVisibility=function(){var e;this.isNew&&this.item.setIsVisible(!(!1===(null===(e=this.allowItemOperations)||void 0===e?void 0:e.allowAdd)))},Object.defineProperty(t.prototype,"allowRemove",{get:function(){var e=this.creator.minimumChoicesCount;if(e>0&&e>=this.question.choices.length)return!1;var t=!this.question.isItemInList(this.item),o=this.isAutoGeneratedItem(this.item);return!this.creator.readOnly&&this.canTouchItems&&this.allowItemOperations.allowDelete&&!t&&!o},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tooltip",{get:function(){return Z(this.isNew?"pe.addItem":"pe.removeItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"dragTooltip",{get:function(){return Z("pe.dragItem")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"allowAdd",{get:function(){var e=!this.question.isItemInList(this.item),t=this.isAutoGeneratedItem(this.item);return!this.creator.readOnly&&this.canTouchItems&&this.allowItemOperations.allowAdd&&e&&!t},enumerable:!1,configurable:!0}),t.prototype.select=function(e,t){e.question.inMatrixMode||(e.creator.selectElement(e.question,"choices",!1),t&&t.stopPropagation())},t.prototype.isAutoGeneratedItem=function(e){var t=e.value;if(!o.Helpers.isNumber(t))return!1;var i=this.question.choicesMin,n=this.question.choicesMax;return!(!o.Helpers.isNumber(i)||!o.Helpers.isNumber(n)||i===n&&0===i)&&t>=i&&t<=n},J([(0,o.property)({defaultValue:!1})],t.prototype,"isNew",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropGhost",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropMoveDown",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isDragDropMoveUp",void 0),J([(0,o.property)({defaultValue:null})],t.prototype,"ghostPosition",void 0),t}(o.Base);r(1383);var wn=function(e){function t(t,o,i,n,r){var a=e.call(this,t,o,i)||this;return a.question=o,a.item=i,a.templateData=n,a.itemsRoot=r,a.isChoosingNewFile=!1,a.onDragOver=function(e){a.isFileDragging=!0,e.dataTransfer.dropEffect="copy",e.preventDefault()},a.onDrop=function(e){a.isFileDragging=!1,e.preventDefault();var t=e.dataTransfer;if(t&&t.files&&!(t.files.length<1)){for(var o=[],i=0;i<t.files.length;i++)o.push(t.files[i]);a.uploadFiles(o)}},a.onDragLeave=function(e){a.isFileDragging=!1},a}return K(t,e),t.prototype.getRootCss=function(){return(new o.CssClassBuilder).append("svc-image-item-value-wrapper").append("svc-image-item-value").append("svc-image-item-value--new",this.isNew||this.isUploading).append("svc-image-item-value-wrapper--ghost",this.isDragDropGhost).append("svc-image-item-value--file-dragging",this.isFileDragging).append("svc-image-item-value--single",this.getIsNewItemSingle()).toString()},t.prototype.getIsNewItemSingle=function(){return this.isNew&&0===this.question.choices.length},Object.defineProperty(t.prototype,"canRenderControls",{get:function(){return this.getIsNewItemSingle()||!this.question.renderedImageWidth||this.question.renderedImageWidth>150},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"selectFileTitle",{get:function(){return this.creator.getLocString("ed.selectFile")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"removeFileTitle",{get:function(){return this.creator.getLocString("ed.removeFile")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"addFileTitle",{get:function(){return this.creator.getLocString("ed.selectFile")},enumerable:!1,configurable:!0}),t.prototype.chooseFile=function(e){var t=e.itemsRoot.getElementsByClassName("svc-choose-file-input")[0],o={element:e.question,item:e.item,elementType:e.question.getType(),propertyName:"imageLink"};e.creator.chooseFiles(t,(function(t){e.isUploading=!0,e.creator.uploadFiles(t,e.question,(function(t,o){"success"===t&&(e.item.imageLink=o),e.isUploading=!1}),o)}),o)},t.prototype.uploadFiles=function(e){var t=this;this.isUploading=!0;var o={element:this.question,item:void 0,elementType:this.question.getType(),propertyName:"imageLink"};this.creator.uploadFiles(e,this.question,(function(e,o){"success"===e&&t.creator.createNewItemValue(t.question,t.isChoosingNewFile,(function(e){e.imageLink=o})),t.isChoosingNewFile=!1,t.isUploading=!1}),o)},t.prototype.chooseNewFile=function(e){var t=this,o=e.itemsRoot.getElementsByClassName("svc-choose-file-input")[0];e.creator.chooseFiles(o,(function(o){t.isChoosingNewFile=!0,e.uploadFiles(o)}),{element:e.question,item:e.item,elementType:e.question.getType(),propertyName:"imageLink"})},Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return A(this.question.contentMode)},enumerable:!1,configurable:!0}),t.prototype.dispose=function(){this.itemsRoot=void 0,e.prototype.dispose.call(this)},J([(0,o.property)({defaultValue:!1})],t.prototype,"isFileDragging",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),t}(Cn);r(3952);var xn=function(){function e(e,t,i,n){this.cellQuestion=t,this.column=i,this.creator=e;var r=t.toJSON();r.type=t.getType(),this.surveyValue=e.createSurvey({questions:[r]},"modal-question-editor",n,(function(e){e.css=o.defaultV2Css,e.setDesignMode(!0),e.isPopupEditorContent=!0,e.showQuestionNumbers="none",e.questionTitleLocation="hidden"})),this.question.setSurveyImpl(this.survey),this.question.inMatrixMode=!0,this.question.ownerObj=this.column}return Object.defineProperty(e.prototype,"survey",{get:function(){return this.surveyValue},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"question",{get:function(){return this.survey.getAllQuestions()[0]},enumerable:!1,configurable:!0}),e.prototype.apply=function(){var e=this.cellQuestion.parentQuestion,t=e.getColumnByName(this.cellQuestion.name),i=t.toJSON(),n=i.cellType,r=this.question.toJSON(),a=this.question.getType();if(n&&(r.cellType=n),!o.Helpers.isTwoValueEquals(r,i)){for(var s in i)!o.Serializer.findProperty(a,s)||void 0!==r[s]||!0!==i[s]&&!1!==i[s]||(r[s]=!i[s]);for(var s in r)o.Helpers.isTwoValueEquals(r[s],i[s])||(t[s]=r[s]);e.onColumnCellTypeChanged(t),this.creator.setModified({type:"MATRIX_CELL_EDITOR",column:t})}},e}(),Tn=function(e){function t(t,o,i,n,r){var a=e.call(this)||this;return a.creator=t,a.templateData=o,a.question=i,a.row=n,a.column=r,a.onSelectionChanged=function(e,t){a.context&&a.context.getPropertyValue?a.isSelected=a.creator.isElementSelected(a.context):a.isSelected=!1},t.onSelectedElementChanged.add(a.onSelectionChanged),a}return K(t,e),t.prototype.editQuestion=function(e,t){var i=new xn(e.creator,e.question,e.column,this);i.question.cellOwner=e;var n=o.surveyLocalization.currentLocale,r=G.currentLocale;o.surveyLocalization.currentLocale=r,o.settings.showDialog({componentName:"svc-question-editor-content",data:{survey:i.survey,creator:this.creator},onApply:function(){return i.apply(),!0},cssClass:"svc-matrix-cell__popup svc-creator-popup",title:e.question.name,displayMode:this.creator.isMobileView?"overlay":"popup"},e.creator.rootElement).locale=r,o.surveyLocalization.currentLocale=n,t.stopPropagation(),e.creator.selectElement(e.column)},Object.defineProperty(t.prototype,"context",{get:function(){return this.row||this.column||this.templateData},enumerable:!1,configurable:!0}),t.prototype.selectContext=function(e,t){if(e.row)return e.creator.selectElement(e.row.data,"rows",!1),void t.stopPropagation();"function"==typeof e.context.getType&&("itemvalue"===e.context.getType()?e.creator.selectElement(e.context.locOwner,e.context.ownerPropertyName,!1):e.creator.selectElement(e.context),t.stopPropagation())},Object.defineProperty(t.prototype,"isSupportCellEditor",{get:function(){return!(!this.question||!this.question.getType)&&ee.isSupportCellEditor(this.question.getType())},enumerable:!1,configurable:!0}),t.prototype.hover=function(e,t){!this.row&&this.context&&this.context.getPropertyValue&&this.context.getType&&"itemvalue"!==this.context.getType()&&C(e,t)},t.prototype.dispose=function(){this.creator.onSelectedElementChanged.remove(this.onSelectionChanged),e.prototype.dispose.call(this)},J([(0,o.property)()],t.prototype,"isSelected",void 0),t}(o.Base);r(9414);var Sn=function(e){function t(t,o,i){var n=e.call(this)||this;return n.survey=t,n._data=o,n._lvl=i,n.toggle=function(){n.collapsed=!n.collapsed},n.markerWidth=16,n.question=t.getQuestionByName(n.name),n.items=Pn(t,o.data,i+1),n.lvl=i,n}return K(t,e),Object.defineProperty(t.prototype,"data",{get:function(){return this.items},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isNode",{get:function(){return this._data.isNode},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"name",{get:function(){return this._data.name},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"title",{get:function(){return this._data.title},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"value",{get:function(){return this._data.value},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"displayValue",{get:function(){return this._data.displayValue},enumerable:!1,configurable:!0}),t.prototype.getString=function(e){return this._data.getString(e)},Object.defineProperty(t.prototype,"markerMargin",{get:function(){return(1.5+this.lvl)*this.markerWidth+"px"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"textMargin",{get:function(){return(2.75+this.lvl)*this.markerWidth+"px"},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!0})],t.prototype,"collapsed",void 0),J([(0,o.property)({defaultValue:0})],t.prototype,"lvl",void 0),J([(0,o.property)()],t.prototype,"items",void 0),t}(o.Base);function Pn(e,t,o){return void 0===t&&(t=[]),t.filter((function(e){return!!e})).map((function(t){return new Sn(e,t,o)}))}var En=function(e){function t(t){var o=e.call(this)||this;o.survey=t,o.selectTableClick=function(){o.resultViewType="table"},o.selectJsonClick=function(){o.resultViewType="text"},o.resultText=JSON.stringify(t.data,null,4);var i=t.getPlainData({includeEmpty:!1,includeValues:!0});return o.resultData=Pn(t,i,0),o}return K(t,e),t.prototype.getLocString=function(e){return G.getString(e)},Object.defineProperty(t.prototype,"surveyResultsText",{get:function(){return this.getLocString("ed.surveyResults")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"surveyResultsTableText",{get:function(){return this.getLocString("ed.surveyResultsTable")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"surveyResultsJsonText",{get:function(){return this.getLocString("ed.surveyResultsJson")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsTitle",{get:function(){return this.getLocString("ed.resultsTitle")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsName",{get:function(){return this.getLocString("ed.resultsName")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsValue",{get:function(){return this.getLocString("ed.resultsValue")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"resultsDisplayValue",{get:function(){return this.getLocString("ed.resultsDisplayValue")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isTableSelected",{get:function(){return"table"===this.resultViewType},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isJsonSelected",{get:function(){return"text"===this.resultViewType},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:"table"})],t.prototype,"resultViewType",void 0),J([(0,o.property)({defaultValue:""})],t.prototype,"resultText",void 0),J([(0,o.propertyArray)()],t.prototype,"resultData",void 0),t}(o.Base);r(9281);var Vn=function(e){function t(t,o){var i=e.call(this)||this;return i.creator=t,i.root=o,i}return K(t,e),Object.defineProperty(t.prototype,"allowEdit",{get:function(){var e=this.creator.survey,t=o.Serializer.findProperty(e.getType(),"logo");return!(this.creator.readOnly||t.overridingProperty&&e[t.overridingProperty])},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"containerCss",{get:function(){return(new o.CssClassBuilder).append("svc-logo-image-container").append("svc-logo-image-container--editable",this.allowEdit).toString()},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"survey",{get:function(){return this.creator.survey},enumerable:!1,configurable:!0}),t.prototype.uploadFile=function(e,t,o){e.isUploading=!0,e.creator.uploadFiles(o,void 0,(function(o,i){e.creator.survey.logo=i,t.value="",e.isUploading=!1}),{element:e.creator.survey,elementType:"survey",propertyName:"logo"})},t.prototype.chooseFile=function(e){if(this.allowEdit){var t=e.root.getElementsByClassName("svc-choose-file-input")[0];0===t.files.length?e.creator.chooseFiles(t,(function(o){e.uploadFile(e,t,o)}),{element:this.survey,elementType:this.survey.getType(),propertyName:"logo"}):e.uploadFile(e,t,[t.files[0]])}},t.prototype.remove=function(e){e.creator.survey.logo=""},Object.defineProperty(t.prototype,"chooseLogoPlaceholder",{get:function(){return this.creator.getLocString("ed.chooseLogoPlaceholder")},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"acceptedTypes",{get:function(){return A("image")},enumerable:!1,configurable:!0}),J([(0,o.property)({defaultValue:!1})],t.prototype,"isUploading",void 0),t}(o.Base),In="embeddedsurvey",On=function(e){function t(t){var o=e.call(this,t)||this;return o.onEmbeddedSurveyValueChanged=function(){},o}return K(t,e),Object.defineProperty(t.prototype,"embeddedSurvey",{get:function(){return this.getPropertyValue("embeddedSurvey")},set:function(e){e!==this.embeddedSurvey&&(this.setPropertyValue("embeddedSurvey",e),this.onEmbeddedSurveyValueChanged())},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return In},t}(o.QuestionNonValue);o.Serializer.addClass(In,[],(function(){return new On("")}),"nonvalue"),o.QuestionFactory.Instance.registerQuestion(In,(function(e){return new On(e)}),!1),r(2996);var An=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,t)||this,n=o&&!o.showValueInLink&&G.getString("pe.set")+" "+o.title||null;return i.linkValueText=n||G.getString("pe.emptyValue"),i}return K(t,e),t.prototype.onPropertyValueChanged=function(t,i,n){e.prototype.onPropertyValueChanged.call(this,t,i,n),"value"===t&&(this.updateLinkValueText(),this.allowClear&&(this.showClear=!o.Helpers.isValueEmpty(n)),this.updateIsClickable())},t.prototype.onReadOnlyChanged=function(){this.updateIsClickable(),e.prototype.onReadOnlyChanged.call(this)},t.prototype.updateIsClickable=function(){this.setPropertyValue("isClickable",!this.isReadOnly||!!this.isClickableCallback&&this.isClickableCallback())},Object.defineProperty(t.prototype,"ariaRole",{get:function(){return"button"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"tooltip",{get:function(){return this.showTooltip?this.linkValueText:void 0},enumerable:!1,configurable:!0}),t.prototype.getType=function(){return"linkvalue"},t.prototype.doLinkClick=function(){this.linkClickCallback&&this.linkClickCallback()},t.prototype.doClearClick=function(){this.clearClickCallback&&this.clearClickCallback()},t.prototype.updateLinkValueText=function(){var e;e=this.showValueInLink?this.isEmpty()?G.getString("pe.emptyValue"):this.getObjDisplayValue():G.getString(this.isEmpty()?"pe.set":"pe.change")+" "+this.title,this.linkValueText=e},t.prototype.stringifyValue=function(e){return"string"!=typeof e?JSON.stringify(e):e},t.prototype.getObjDisplayValue=function(){var e=this.obj;if(!e||!e.getDisplayValue)return this.stringifyValue(this.value);var t=e.getDisplayValue(!0,this.value);return"string"!=typeof t?JSON.stringify(t):t},J([(0,o.property)({defaultValue:"svc-link-value-button svc-question-link__set-button"})],t.prototype,"linkSetButtonCssClasses",void 0),J([(0,o.property)({defaultValue:"svc-question-link__clear-button"})],t.prototype,"linkClearButtonCssClasses",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"isSelected",void 0),J([(0,o.property)()],t.prototype,"linkValueText",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showClear",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"allowClear",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"showValueInLink",void 0),J([(0,o.property)({defaultValue:!1})],t.prototype,"showTooltip",void 0),J([(0,o.property)({defaultValue:!0})],t.prototype,"isClickable",void 0),J([(0,o.property)()],t.prototype,"iconName",void 0),t}(o.Question);o.Serializer.addClass("linkvalue",["showValueInLink",{name:"showTooltip: boolean",default:!1,visible:!1},"iconName"],(function(e){return new An("",e)}),"nonvalue"),o.QuestionFactory.Instance.registerQuestion("linkvalue",(function(e){return new An(e)}),!1);var Nn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._showUnitsInEditor=!0,t.onUpButtonMouseDown=function(){t.increase(),t.increaseTimer=setTimeout(t.onUpButtonMouseDown,200)},t.onDownButtonMouseDown=function(){t.decrease(),t.decreaseTimer=setTimeout(t.onDownButtonMouseDown,200)},t.onButtonMouseLeave=function(){t.onButtonMouseUp()},t.onButtonMouseUp=function(){clearTimeout(t.decreaseTimer),clearTimeout(t.increaseTimer)},t.onKeyDown=function(e){switch(e.key){case"ArrowUp":t.increase(),e.stopPropagation(),e.preventDefault();break;case"ArrowDown":t.decrease(),e.stopPropagation(),e.preventDefault()}t.onTextKeyDownHandler(e)},t.onInputKeyDown=function(e){"ArrowUp"!=e.key&&"ArrowDown"!=e.key||t.updateValueOnEvent(e)},t.onFocus=function(e){"INPUT"==e.target.tagName&&queueMicrotask((function(){var o=e.target,i=o.selectionStart,n=o.selectionEnd,r=o.selectionDirection;t._showUnitsInEditor=!1,queueMicrotask((function(){Math.abs(n-i)>0?o.setSelectionRange(0,t.renderedValue.length,r):o.setSelectionRange(t.renderedValue.length,t.renderedValue.length)}))}))},t.onBlur=function(e){t._showUnitsInEditor=!0,"INPUT"==e.target.tagName&&t.updateValueOnEvent(e)},t}return K(t,e),t.prototype.parseValue=function(e){return{value:parseFloat(e.toString()),unit:e.toString().replace(/[^A-Za-z]/g,"")}},t.prototype.changeValue=function(e){var t=this.parseValue(this.renderedValue),o=Number(this.renderedStep||1),i=t.value;e?i+=o:i-=o,this.value=i},Object.defineProperty(t.prototype,"showUnitsInEditor",{get:function(){return!!this.unit&&this._showUnitsInEditor},enumerable:!1,configurable:!0}),t.prototype.correctValue=function(e){if(null==e||null==e)return e;var t=Number(this.renderedMax),o=Number(this.renderedMin);return e="string"==typeof e?parseFloat(e):e,isNaN(e)?e=isNaN(o)?0:o:e>t?e=t:e<o&&(e=o),Math.round(1e3*e)/1e3},t.prototype.setNewValue=function(t){e.prototype.setNewValue.call(this,this.correctValue(t))},Object.defineProperty(t.prototype,"renderedValue",{get:function(){var e,t,o=(null!==(t=null!==(e=this.value)&&void 0!==e?e:this.renderedMin)&&void 0!==t?t:0).toString();return this.showUnitsInEditor&&(o+=this.unit),o},enumerable:!1,configurable:!0}),t.prototype.increase=function(){this.changeValue(!0)},t.prototype.decrease=function(){this.changeValue(!1)},t.prototype.onBeforeInput=function(e){var t=0==e.target.selectionStart?/[\d.-]/:/[\d.]/;e.data&&!t.test(e.data)&&e.preventDefault()},t.prototype.getType=function(){return"spinedit"},Object.defineProperty(t.prototype,"isInputTextUpdate",{get:function(){return!1},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"unit",void 0),J([(0,o.property)()],t.prototype,"_showUnitsInEditor",void 0),t}(o.QuestionTextModel);o.Serializer.addClass("spinedit",["unit"],(function(){return new Nn("")}),"text"),o.QuestionFactory.Instance.registerQuestion("spinedit",(function(e){return new Nn(e)}),!1);var Ln="#000000",_n="#FFFFFF",Mn=function(e){function t(t){var o=e.call(this,t)||this;return o.allowEmptyValue=!1,o.createItemValues("choices"),o.registerFunctionOnPropertyValueChanged("choices",(function(){o.updateChoices()})),o}return K(t,e),t.prototype.getCorrectedValue=function(e){if(null==e||null==e||this.allowEmptyValue&&!e)return e;if((e=k(null!=e?e:"").color).indexOf("#")<0&&(e="#"+e),4===(e=(e.match(/#([0-9a-fA-F]){1,6}/)||[Ln])[0]).length){for(var t=e.slice(0,1),o=1;o<4;o++)t+=e[o]+e[o];e=t}if(e.length<7){var i=e.length;for(o=0;o<7-i;o++)e+="0"}return e},t.prototype.isNewValueEqualsToValue=function(t){return!(!e.prototype.isNewValueEqualsToValue.call(this,t)&&!this.isTwoValueEquals(t,this.value,!0,!0))},t.prototype.setNewValue=function(t){this.resetRenderedValue(),e.prototype.setNewValue.call(this,this.getCorrectedValue(t)),this.updateRenderedValue()},t.prototype.onBeforeInput=function(e){e.data&&!/[\d\w(),#]/.test(e.data)&&e.preventDefault()},t.prototype.onColorInputChange=function(e){this.value=e.target.value},t.prototype.getType=function(){return"color"},t.prototype.resetRenderedValue=function(){this._renderedValue=void 0},t.prototype.updateRenderedValue=function(){if(this.value){var e=k(this.value||"");this._renderedValue=e.color}else this.allowEmptyValue?this._renderedValue="":this._renderedValue=Ln},Object.defineProperty(t.prototype,"renderedValue",{get:function(){return this._renderedValue||""===this._renderedValue||this.updateRenderedValue(),this._renderedValue.toUpperCase()},enumerable:!1,configurable:!0}),t.prototype.getSwatchCss=function(){return(new o.CssClassBuilder).append(this.cssClasses.swatch).append(this.cssClasses.swatchDefault,!this.renderedValue).append(this.cssClasses.swatchDisabled,this.isInputReadOnly).toString()},t.prototype.getSwatchStyle=function(){return{backgroundColor:this.renderedValue||_n}},Object.defineProperty(t.prototype,"renderedColorValue",{get:function(){return this.renderedValue||_n},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isInputTextUpdate",{get:function(){return!1},enumerable:!1,configurable:!0}),t.prototype.onSurveyValueChanged=function(t){e.prototype.onSurveyValueChanged.call(this,t),this.updateRenderedValue()},Object.defineProperty(t.prototype,"dropdownAction",{get:function(){return this._dropdownAction||(this._dropdownAction=this.createDropdownAction()),this._dropdownAction},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"choices",{get:function(){return this.getPropertyValue("choices")},set:function(e){this.setPropertyValue("choices",e)},enumerable:!1,configurable:!0}),t.prototype.onTextKeyDownHandler=function(t){var o=this.dropdownAction.popupModel;"ArrowDown"===t.key&&this.dropdownAction.action(),o.isVisible||e.prototype.onTextKeyDownHandler.call(this,t)},Object.defineProperty(t.prototype,"showDropdownAction",{get:function(){return!this.isValueEmpty(this.choices)},enumerable:!1,configurable:!0}),t.prototype.createDropdownAction=function(){var e=this,t=(0,o.createDropdownActionModelAdvanced)({enabled:new o.ComputedUpdater((function(){return!e.isInputReadOnly}))},{onSelectionChanged:function(t){e.value=t.value},items:this.choices},{showPointer:!1,verticalPosition:"bottom",horizontalPosition:"center",cssClass:"svc-creator-popup"});t.disableTabStop=!0;var i=t.popupModel,n=i.contentComponentData.model;return i.displayMode=o.IsTouch?"overlay":"popup",i.setWidthByTarget=!0,i.positionMode="fixed",n.isItemSelected=function(t){return t.value==e.value},t},t.prototype.calcCssClasses=function(t){var o=e.prototype.calcCssClasses.call(this,t),i=this.dropdownAction;i.cssClasses={item:o.colorDropdown},i.iconName=o.colorDropdownIcon;var n=i.popupModel.contentComponentData.model;return n.cssClasses={},n.cssClasses={itemBody:n.cssClasses.itemBody+" "+o.colorItem},o},t.prototype.updateChoices=function(){this.dropdownAction.popupModel.contentComponentData.model.setItems(this.choices)},Object.defineProperty(t.prototype,"itemComponent",{get:function(){return"color-item"},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"allowEmptyValue",void 0),J([(0,o.property)()],t.prototype,"_renderedValue",void 0),t}(o.QuestionTextModel);o.Serializer.addClass("color",[{name:"allowEmptyValue:boolean",default:!1},"choices:itemvalue[]"],(function(){return new Mn("")}),"text"),o.QuestionFactory.Instance.registerQuestion("color",(function(e){return new Mn(e)}),!1);var Dn=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t._renderedValue="",t.notEmptyValuePlaceholder="",t.onKeyDown=function(e){"INPUT"===e.target.tagName&&t.onTextKeyDownHandler(e)},t.onFileInputChange=function(e){if(!t.onChooseFilesCallback)return t.doChange(e),!0},t}return K(t,e),t.prototype.onChangeQuestionValue=function(e){},t.prototype.setNewValue=function(t){"object"==typeof t&&(this.stateChanged(this.isEmpty()?"empty":"loaded"),this.isLoadingFromJson||this.loadPreview(t),this.loadedFilesValue=t,t=this.previewValue[0].content),this.updateRenderedValue(t),e.prototype.setNewValue.call(this,t)},t.prototype.loadPreview=function(t){"string"!=typeof t&&e.prototype.loadPreview.call(this,t)},Object.defineProperty(t.prototype,"allowMultiple",{get:function(){return!1},set:function(e){},enumerable:!1,configurable:!0}),t.prototype.clear=function(e,t){var o=this;if(void 0===t&&(t=!0),this.survey){var i=function(){t&&(o.value=void 0),o.errors=[],e&&e()};this.loadedFilesValue?(this.containsMultiplyFiles=!1,this.survey.clearFiles(this.loadedFilesValue,this.name,this.previewValue,null,(function(e,t){"success"===e&&i()}))):i()}},Object.defineProperty(t.prototype,"renderedPlaceholder",{get:function(){return this.notEmptyValuePlaceholder||this.placeholder},enumerable:!1,configurable:!0}),t.prototype.updateRenderedValue=function(e){var t=e?e.match(/^data:((?:\w+\/(?:(?!;).)+)?)((?:;[\w\W]*?[^;])*),/):null;t?(this.notEmptyValuePlaceholder=t[0]+"...",this._renderedValue=""):(this.notEmptyValuePlaceholder="",this._renderedValue=e)},Object.defineProperty(t.prototype,"renderedValue",{get:function(){return this._renderedValue},enumerable:!1,configurable:!0}),t.prototype.updateValueFromInputEvent=function(e){var t=e.target.value;this.notEmptyValuePlaceholder&&!t||o.Helpers.isTwoValueEquals(t,this.value)||(this.clear(void 0,!1),this.loadedFilesValue=void 0,this.value=e.target.value)},t.prototype.onSurveyValueChanged=function(t){e.prototype.onSurveyValueChanged.call(this,t),this.updateRenderedValue(t)},t.prototype.onInputChange=function(e){e.target!==document.activeElement&&this.updateValueFromInputEvent(e)},t.prototype.onInputBlur=function(e){this.updateValueFromInputEvent(e)},t.prototype.getType=function(){return"fileedit"},t.prototype.getIsClearButtonDisabled=function(){return!this.value||this.isInputReadOnly},t.prototype.getChooseButtonCss=function(){return(new o.CssClassBuilder).append(this.cssClasses.chooseButton).append(this.cssClasses.chooseButtonDisabled,this.isInputReadOnly).toString()},t.prototype.chooseFiles=function(e){var t=this;if(this.isInputReadOnly||!this.onChooseFilesCallback)return!0;e.preventDefault(),e.stopPropagation();var o=this.rootElement.querySelectorAll("input[type='file']")[0];this.onChooseFilesCallback(o,(function(e){t.loadFiles(e)}))},J([(0,o.property)()],t.prototype,"_renderedValue",void 0),J([(0,o.property)()],t.prototype,"notEmptyValuePlaceholder",void 0),J([(0,o.property)()],t.prototype,"placeholder",void 0),t}(o.QuestionFileModel);o.Serializer.addClass("fileedit",["placeholder:string"],(function(){return new Dn("")}),"file"),o.QuestionFactory.Instance.registerQuestion("fileedit",(function(e){return new Dn(e)}),!1);var kn=function(e){function t(t){var o=e.call(this)||this;return o.question=t,o}return K(t,e),t.prototype.resetValue=function(){this.resetValueCallback&&this.resetValueCallback()},Object.defineProperty(t.prototype,"isDisabled",{get:function(){return this.question.isInputReadOnly||!this.allowResetValue},enumerable:!1,configurable:!0}),J([(0,o.property)()],t.prototype,"allowResetValue",void 0),t}(o.Base),jn=function(e){function t(t){var o=e.call(this,t)||this;return o.resetValueAdorner=o.createResetValueAdorner(),o}return K(t,e),t.prototype.createResetValueAdorner=function(){return new kn(this)},t.prototype.getType=function(){return"textwithreset"},t.prototype.getRootClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.root).append(this.cssClasses.onError,this.errors.length>0).toString()},t.prototype.getControlClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.control).toString()},Object.defineProperty(t.prototype,"wrappedQuestionTemplate",{get:function(){return"text"},enumerable:!1,configurable:!0}),t}(o.QuestionTextModel);o.Serializer.addClass("textwithreset",[],(function(){return new jn("")}),"text"),o.QuestionFactory.Instance.registerQuestion("textwithreset",(function(e){return new jn(e)}),!1);var Rn=function(e){function t(t){var o=e.call(this,t)||this;return o.resetValueAdorner=o.createResetValueAdorner(),o}return K(t,e),t.prototype.createResetValueAdorner=function(){return new kn(this)},t.prototype.getType=function(){return"commentwithreset"},t.prototype.getCssType=function(){return"textwithreset"},t.prototype.getRootClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.root).append(this.cssClasses.rootMultiline).append(this.cssClasses.onError,this.errors.length>0).toString()},t.prototype.getControlClass=function(){return(new o.CssClassBuilder).append(this.cssClasses.control).append(this.cssClasses.controlMultiline).toString()},Object.defineProperty(t.prototype,"wrappedQuestionTemplate",{get:function(){return"comment"},enumerable:!1,configurable:!0}),t}(o.QuestionCommentModel);o.Serializer.addClass("commentwithreset",[{name:"allowResize:boolean",default:!1}],(function(){return new Rn("")}),"comment"),o.QuestionFactory.Instance.registerQuestion("commentwithreset",(function(e){return new Rn(e)}),!1);var Bn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"expression"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",showOptionsCaption:!1,rows:2}},t.prototype.clearPropertyValue=function(e,t,o,i){o.clearValue()},t}(lt),qn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"condition"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"comment",showOptionsCaption:!1,rows:2}},t.prototype.canClearPropertyValue=function(e,t,o,i){return!1!==i.allowEditExpressionsInTextEditor},t.prototype.onSetup=function(e,t,o,i){!1===i.allowEditExpressionsInTextEditor&&(t.onKeyDownPreprocess=function(e){!e.ctrlKey&&["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Home","End"].indexOf(e.key)<0&&e.preventDefault()})},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new ro(e.getSurvey(),e,i,t.name)},t}(Bn);nt.register(new Bn),nt.register(new qn);var Hn=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i="item"),void 0===n&&(n=[]);var r=e.call(this,o)||this;return r.choices=t,r.className=i,r.names=n,r.commentValue=r.editSurvey.getQuestionByName("question"),r.setComment(),r.editSurvey.getQuestionByName("question").placeholder=G.getString("pe.fastEntryPlaceholder"),r.editSurvey.onValidateQuestion.add((function(e,t){var o=r.options.minimumChoicesCount;if(o>0)o>(i=r.getChoicesCount())&&(t.error=G.getString("pe.fastEntryChoicesMinCountError").format(o));else{var i,n=r.options.maximumChoicesCount;if(n>0)n<(i=r.getChoicesCount())&&(t.error=G.getString("pe.fastEntryChoicesCountError").format(i,n));else if(r.isValueUnique){var a=r.getFirstUniqueValue();a&&(t.error=G.getString("pe.fastEntryNonUniqueError").format(a))}}})),r}return K(t,e),t.prototype.calcBeforeApplyItemsArray=function(e,t,o){if(t&&0!=t.length){if(e.length>t.length&&e.splice(t.length,e.length-t.length),e.length<t.length){for(var i=[],n=e.length;n<t.length;n++)i.push(t[n]);e.splice.apply(e,[e.length,0].concat(i))}}else e.splice(0,e.length)},t.prototype.applyItemValueArray=function(e,t,o){void 0===o&&(o=[]),this.calcBeforeApplyItemsArray(e,t,o);for(var i=0;i<e.length;i++)o.forEach((function(o){e[i][o]=t[i][o]}))},t.prototype.getSurveyJSON=function(){return{elements:[{type:"comment",name:"question",titleLocation:"hidden",rows:12}]}},t.prototype.getSurveyCreationReason=function(){return"fast-entry"},t.prototype.apply=function(){return!this.comment.isEmpty()&&this.applyCore()},t.prototype.applyCore=function(){if(this.editSurvey.hasErrors(!0))return!1;var e=(this.comment.value||"").split("\n")||[],t=this.convertTextToItemValues(e);return t=this.options.onFastEntryCallback(t,e),this.applyItemValueArray(this.choices,t,this.names),!0},t.prototype.convertTextToItemValues=function(e){for(var t=[],i=0;i<e.length;i++)if(e[i]){var n=e[i].split(o.ItemValue.Separator),r=o.Serializer.createClass(this.className);this.names.forEach((function(e,t){r[e]=n[t]})),t.push(r)}return t},Object.defineProperty(t.prototype,"comment",{get:function(){return this.commentValue},enumerable:!1,configurable:!0}),t.prototype.getChoicesCount=function(){for(var e=this.comment.value.split("\n"),t=0,o=0;o<e.length;o++)e[o]&&t++;return t},Object.defineProperty(t.prototype,"isValueUnique",{get:function(){return!0===o.Serializer.findProperty("itemvalue","value").isUnique},enumerable:!1,configurable:!0}),t.prototype.getFirstUniqueValue=function(){for(var e=this.comment.value.split("\n"),t={},i=0;i<e.length;i++){var n=e[i];if(n){var r=n.split(o.ItemValue.Separator)[0];if(t[r])return r;t[r]=!0}}},t.prototype.setComment=function(){var e=this.convertItemValuesToText();this.comment.value=e},t.prototype.collectNames=function(e,t,i){var n="";return this.names.forEach((function(r){if("itemvalues"===t){if("value"==r)return;var a="text"==r?e.pureText:e[r]}else a=e[r];if(a){for(var s=0;s<i;s++)n+=o.ItemValue.Separator;n+=a,i=1}else i++})),n},t.prototype.convertItemValuesToText=function(){var e=this,t="";return this.choices.forEach((function(o){t&&(t+="\n"),t+=e.collectNames(o,"",0)})),t},t}(it),Fn=function(e){function t(t,o,i,n){void 0===o&&(o=null),void 0===i&&(i="itemvalue"),void 0===n&&(n=["value","text"]);var r=e.call(this,t,o,i,n)||this;return r.choices=t,r.className=i,r.names=n,r}return K(t,e),t.prototype.apply=function(){return this.applyCore()},t.prototype.applyItemValueArray=function(e,t,o){void 0===o&&(o=[]),this.calcBeforeApplyItemsArray(e,t,o);for(var i=0;i<e.length;i++)e[i].value!=t[i].value&&(e[i].value=t[i].value),e[i].text=t[i].hasText?t[i].text:"",o.forEach((function(o){"value"!=o&&"text"!=o&&(e[i][o]=t[i][o])}))},t.prototype.convertItemValuesToText=function(){var e=this,t="";return this.choices.forEach((function(o){t&&(t+="\n"),t+=o.value,t+=e.collectNames(o,"itemvalues",1)})),t},t}(Hn);o.Serializer.addProperty("itemvalue",{name:"icon",isSerializable:!1,readOnly:!0,visibleIndex:0,visibleIf:function(e){return e&&"rateValues"===e.ownerPropertyName&&e.locOwner instanceof o.QuestionRatingModel&&"smileys"==e.locOwner.rateType}});var Qn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.getNewColumnName=function(e,t,o){var i=[];if(Array.isArray(e))for(var n=0;n<e.length;n++)i.push(e[n][t]);return h(o,i)},t.prototype.onCreated=function(e,t,o,i,n){var r=this;t.onGetValueForNewRowCallBack=function(e){return r.createNewItem(e,o)},this.setupMatrixQuestion(e,t,o,n)},t.prototype.onSetup=function(e,t,o,i){var n=t;n.allowRowsDragAndDrop&&n.dragDropMatrixRows&&(n.dragDropMatrixRows.onDragStart.add((function(){i.startUndoRedoTransaction()})),n.dragDropMatrixRows.onDragEnd.add((function(){i.stopUndoRedoTransaction()})))},t.prototype.initializePlaceholder=function(e,t,i){var n="function"==typeof e.getType&&e.getType();"text"===t.getType()&&n&&("text"===i&&"itemvalue"===n&&(t.placeholder=new o.ComputedUpdater((function(){return e.value?e.value.toString():e.text}))),"title"!==i||"matrixdropdowncolumn"!==n&&"multipletextitem"!==n||(t.placeholder=new o.ComputedUpdater((function(){return e.name?e.name:e.title}))))},t.prototype.onMatrixCellCreated=function(e,t){var i=t.row.editingObj;if(i){var n=t.cellQuestion;n.obj=i,this.initializePlaceholder(i,n,t.columnName),n.property=o.Serializer.findProperty(i.getType(),t.columnName)}},t.prototype.onGetMatrixRowAction=function(e,t,o){var i=this,n=t.question,r=t.row,a=t.actions;this.getEditItemAsStandAlone()&&a.push({id:"svd-grid-edit-column",iconName:"icon-edit",title:G.getString("pe.edit"),visibleIndex:0,showTitle:!1,location:"end",action:function(){var e=t.row.editingObj;o(e)}});var s=a.filter((function(e){return"show-detail"===e.id}))[0];Mt(n,a,r),s&&(s.component="sv-action-bar-item",s.iconName=this.getShowDetailActionIconName(r),s.showTitle=!1,s.location="end",s.ariaExpanded=r.isDetailPanelShowing,s.action=function(){r.showHideDetailPanelClick(),s.iconName=r.isDetailPanelShowing?"icon-editing-finish":"icon-edit"},s.visibleIndex=0,s.visible=this.hasPropertiesInDetail,r.onDetailPanelShowingChanged=function(){s.iconName=i.getShowDetailActionIconName(r),s.ariaExpanded=r.isDetailPanelShowing}),Dt(a)},t.prototype.getShowDetailActionIconName=function(e){return e.isDetailPanelShowing?"icon-editing-finish":"icon-edit"},t.prototype.addItem=function(e,t,o){o.addRow()},t.prototype.onGetQuestionTitleActions=function(e,t,i){var n=this,r=t.question;t.titleActions.push({id:"add-item",iconName:"icon-add",title:r.addRowText,showTitle:!1,action:function(){return n.addItem(i,e,r)},enabled:new o.ComputedUpdater((function(){return r.canAddRow}))})},t.prototype.createNewItem=function(e,i){e.visibleRows.forEach((function(e){return e.hideDetailPanel()}));var n=this.getBaseValue(i),r=this.getKeyValue();n||(n="item");var a=null;n&&r&&(a=t.getNewColumnName(e.value,r,n));var s=e.obj,l=o.Serializer.createClass(this.getDefaultClassName(s,i),{});a&&(l[r]=a),this.getObjTypeName()&&(l[this.getObjTypeName()]=l.getType());var u=s[i.name];return o.Serializer.isDescendantOf(l.getType(),"itemvalue")&&(l.text=d(u)),u.push(l),u!=e.value&&(e.value=u),l},t.prototype.getDefaultClassName=function(e,t){return t.className},t.prototype.getBaseValue=function(e){return e.getBaseValue()},t.prototype.getKeyValue=function(){return""},t.prototype.getColumnNames=function(e,t,o,i){var n=this.getPropertiesNames(e,t,o,i);return n&&n.length>0?n:this.getDefaultListProperties(t)},t.prototype.getColumnClassName=function(e,t){return t.className},t.prototype.getPropertiesNames=function(e,t,o,i){for(var n=[],r=this.getDefinedListProperties(e,t,o,i),a=0;a<r.length;a++)n.push(r[a].name);return 0==n.length&&(n=this.getDefaulColumnNames()),n},t.prototype.getDefinedListProperties=function(e,t,i,n){if(!t.className)return[];var r=o.Serializer.createClass(t.className);if(!r)return[];var a=new et(r,i,this.getColumnClassName(e,t),"list",e,t,n);return 0==a.getTabs().length?[]:a.getTabs()[0].properties},t.prototype.getDefaultListProperties=function(e){var t=[];if(e&&e.className)for(var i=o.Serializer.getProperties(e.className),n=0;n<i.length;n++)this.isPropertyShownInList(i[n])&&t.push(i[n].name);return t.length>0?t:this.getDefaulColumnNames()},t.prototype.getDefaulColumnNames=function(){return[]},t.prototype.isPropertyShownInList=function(e){return e.visible&&"form"!==e.showMode},t.prototype.getObjTypeName=function(){return""},t.prototype.hasDetailPanel=function(){return!this.getEditItemAsStandAlone()},t.prototype.setupMatrixQuestion=function(e,t,o,i){var n=this;this.hasPropertiesInDetail=this.hasDetailPanel()&&this.calcHasPropertiesInDetail(t,o,i),t.onHasDetailPanelCallback=function(e){return!1!==e.allowEditRow&&n.hasPropertiesInDetail},t.onCreateDetailPanelRenderedRowCallback=function(e){e.cells=[e.cells[1]],e.cells[0].colSpans+=2};var r=t;if(t.onCreateDetailPanelCallback=function(e,t){new at(e.editingObj,r.creatorOptions,r.obj,r.property,i).setupObjPanel(t,!0)},t.allowRowsDragAndDrop=this.getAllowRowDragDrop(o)&&!t.isReadOnly,r.creatorOptions&&this.setupUsingOptions(e,t,r.creatorOptions,o),o.uniquePropertyName){var a=t.getColumnByName(o.uniquePropertyName);a&&(a.isUnique=!0)}},t.prototype.getAllowRowDragDrop=function(e){return!1},t.prototype.calcHasPropertiesInDetail=function(e,t,i){if(!t.className)return!0;var n=o.Serializer.createClass(t.className);if(!n)return!0;var r=new o.PanelModel("");return new at(n,e.creatorOptions,e.obj,t,i).setupObjPanel(r,!0),r.elements.length>0},t.prototype.getJSON=function(e,t,o,i){return this.getMatrixJSON(e,t,this.getColumnNames(e,t,o,i),o,i)},t.prototype.getMatrixJSON=function(e,t,o,i,n){var r=t.className;r||(r=t.baseClassName);var a=this.getColumnsJSON(e,t,o,i,n),s={type:"matrixdynamic",detailPanelMode:"underRow",cellType:"text",rowCount:0,keyName:this.getKeyName(t),columns:a,showHeader:a.length>1,hideColumnsIfEmpty:!0,addRowText:this.getAddRowText(t),keyDuplicationError:G.getString("pe.propertyIsNoUnique"),emptyRowsText:this.getEmptyRowsText(t)};this.getShowDetailPanelOnAdding()&&(s.detailPanelShowOnAdding=!0);var l=this.getMinimumRowCount(e,t,i),u=this.getMaximumRowCount(e,t,i);return l>0&&(s.minRowCount=l),u>0&&(s.maxRowCount=u),s},t.prototype.getEmptyRowsText=function(e){var t="pe.listIsEmpty",o=t+"@"+e.name;return G.hasString(o)&&(t=o),G.getString(t)},t.prototype.getMinimumRowCount=function(e,t,o){return-1},t.prototype.getMaximumRowCount=function(e,t,o){return-1},t.prototype.filterPropertyNames=function(e,t){return e},t.prototype.getClassNameByProp=function(e){return e.className?e.className:e.baseClassName},t.prototype.getKeyName=function(e){var t=this.getClassNameByProp(e);if(!t)return"";for(var i=o.Serializer.getProperties(t),n=0;n<i.length;n++)if(i[n].isUnique)return i[n].name;return""},t.prototype.getColumnsJSON=function(e,t,o,i,n){for(var r=new at(e,i,void 0,void 0,n).createColumnsJSON(this.getClassNameByProp(t),this.filterPropertyNames(o,i)),a=0;a<r.length;a++)"comment"==r[a].cellType&&(r[a].cellType="text");return r},t.prototype.getEditItemAsStandAlone=function(){return!1},t.prototype.getShowDetailPanelOnAdding=function(){return!1},t.prototype.getAddRowText=function(e){var t="pe.addNew@"+e.name;return G.hasString(t)?G.getString(t):G.getString("pe.addNew")},t.prototype.setupUsingOptions=function(e,t,o,i){var n={allowAddRemoveItems:!0,allowRemoveAllItems:!0,showTextView:!0,allowBatchEdit:!0};o.onSetPropertyEditorOptionsCallback(i.name,e,n),n.allowAddRemoveItems||(t.allowAddRows=!1,t.allowRemoveRows=!1),t.allowRemoveAllItems=n.allowRemoveAllItems,t.showTextView=n.showTextView,t.allowBatchEdit=n.allowBatchEdit},t}(lt),Un=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.isArray&&o.Serializer.isDescendantOf(e.className,"itemvalue")&&"rateValues"!=e.name},t.prototype.excludeTextPropertyName=function(e,t){return(null==t?void 0:t.inplaceEditForValues)?e.filter((function(e){return"text"!==e})):e},t.prototype.filterPropertyNames=function(e,t){return this.excludeTextPropertyName(e,t).filter((function(e){return"icon"!=e}))},t.prototype.isPropertyEditorSetupEnabled=function(e,t,o,i){if(!1===o.showTextView)return!1;var n=o.getColumnByName("value"),r=o.value;return!!n&&n.isVisible&&!n.readOnly&&!this.hasMultipleLanguage(r)&&!this.hasVisibleIfOrEnableIf(r)},t.prototype.getAllowRowDragDrop=function(e){return!0},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=o.columns.filter((function(e){return!e.readOnly})).map((function(e){return e.name}));return new Fn(e[t.name],i,t.className,n)},t.prototype.canClearPropertyValue=function(e,t,o,i){return!1!==o.allowRemoveAllItems},t.prototype.clearPropertyValue=function(e,t,o,i){var n=e[t.name];Array.isArray(n)&&n.splice(0,n.length)},t.prototype.getColumnClassName=function(e,t){return e.getType()+"@"+t.name},t.prototype.getDefaulColumnNames=function(){return["value","text"]},t.prototype.getKeyValue=function(){return"value"},t.prototype.getMatrixJSON=function(t,o,i,n,r){var a=e.prototype.getMatrixJSON.call(this,t,o,i,n,r);return"rateValues"===o.name&&"icon"==a.columns[0].name&&(a.showHeader=a.columns>3),a},t.prototype.getMinimumRowCount=function(t,o,i){return"choices"===o.name?i.minimumChoicesCount:e.prototype.getMaximumRowCount.call(this,t,o,i)},t.prototype.getMaximumRowCount=function(t,o,i){return"choices"===o.name?i.maximumChoicesCount:"rows"===o.name?i.maximumRowsCount:"columns"===o.name?i.maximumColumnsCount:"rateValues"===o.name?i.maximumRateValues:e.prototype.getMaximumRowCount.call(this,t,o,i)},t.prototype.hasMultipleLanguage=function(e){if(!e||!Array.isArray(e))return!1;for(var t=0;t<e.length;t++)if(e[t].locText.hasNonDefaultText())return!0;return!1},t.prototype.hasVisibleIfOrEnableIf=function(e){if(!e||!Array.isArray(e))return!1;for(var t=0;t<e.length;t++)if(e[t].visibleIf||e[t].enableIf)return!0;return!1},t.prototype.onMatrixCellCreated=function(t,i){function n(e,t){e.html='<div class="spg-smiley-icon"><svg><use xlink:href="#icon-'+t+'"></use></svg></div>'}e.prototype.onMatrixCellCreated.call(this,t,i),t instanceof o.QuestionRatingModel&&"icon"==i.columnName&&(n(i.cellQuestion,i.cellQuestion.value),i.cellQuestion.onPropertyChanged.add((function(e,t){"value"==t.name&&n(e,t.newValue)})))},t.prototype.onMatrixCellValueChanged=function(e,t){e instanceof o.QuestionRatingModel&&"icon"==t.columnName&&(t.cellQuestion.html=t.cellQuestion.value)},t}(Qn),Gn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return e.isArray&&o.Serializer.isDescendantOf(e.className,"itemvalue")&&"rateValues"==e.name},t.prototype.updateAllowAddRemove=function(e,t){e.allowRemoveRows=vn.allowRemoveForElement(t),e.allowAddRows=vn.allowAddForElement(t,e.maxRowCount)},t.prototype.onCreated=function(t,o,i,n,r){var a=this;e.prototype.onCreated.call(this,t,o,i,n,r);var s=o,l=N(t);this.updateAllowAddRemove(s,l),t.onPropertyChanged.add((function(e,t){"rateCount"!=t.name&&"rateDisplayMode"!=t.name||a.updateAllowAddRemove(s,l)}))},t.prototype.onGetQuestionTitleActions=function(t,o,i){var n=o.titleActions.filter((function(e){return"property-grid-clear"==e.id}))[0];n&&(n.visible=!1),e.prototype.onGetQuestionTitleActions.call(this,t,o,i)},t.prototype.filterPropertyNames=function(e,t){return this.excludeTextPropertyName(e,t)},t}(Un),Zn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"matrixdropdowncolumns"==e.type},t.prototype.getEditItemAsStandAlone=function(){return!0},t.prototype.getDefaulColumnNames=function(){return["name","title"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"column"},t.prototype.getMaximumRowCount=function(e,t,o){return o.maximumColumnsCount},t.prototype.getAllowRowDragDrop=function(e){return!0},t}(Qn),zn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"panellayoutcolumns"==e.type},t.prototype.getDefaulColumnNames=function(){return["width","questionTitleWidth"]},t.prototype.onMatrixCellCreated=function(t,o){e.prototype.onMatrixCellCreated.call(this,t,o),o.cellQuestion.textUpdateMode="onTyping"},t.prototype.onCreated=function(t,o,i,n,r){e.prototype.onCreated.call(this,t,o,i,n,r);var a=o;a.allowRemoveRows=!1,a.allowAddRows=!1},t}(Qn),Jn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"surveypages"==e.type},t.prototype.addItem=function(e,t,o){e.addPage(void 0,!1)},t.prototype.getColumnClassName=function(e,t){return"page@"+e.getType()},t.prototype.getDefaulColumnNames=function(){return["name","title"]},t.prototype.hasDetailPanel=function(){return!1},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"page"},t.prototype.getAllowRowDragDrop=function(e){return!0},t}(Qn),Wn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"calculatedvalues"==e.type},t.prototype.getColumnClassName=function(e,t){return"calculatedvalue@items"},t.prototype.getDefaulColumnNames=function(){return["name"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"var"},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t.prototype.setupMatrixQuestion=function(t,o,i,n){e.prototype.setupMatrixQuestion.call(this,t,o,i,n),o.isUniqueCaseSensitive=!1},t}(Qn),Kn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"htmlconditions"==e.type},t.prototype.getDefaulColumnNames=function(){return["html"]},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Qn),Yn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"urlconditions"==e.type},t.prototype.getDefaulColumnNames=function(){return["url"]},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Qn),Xn=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"textitem[]"==e.type},t.prototype.getEditItemAsStandAlone=function(){return!0},t.prototype.getColumnClassName=function(e,t){return"multipletext@items"},t.prototype.getDefaulColumnNames=function(){return["name"]},t.prototype.getKeyValue=function(){return"name"},t.prototype.getBaseValue=function(e){return"item"},t.prototype.getAllowRowDragDrop=function(){return!0},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=[];return o.columns.forEach((function(e){n.push(e.name)})),new Hn(e[t.name],i,t.className,n)},t.prototype.onMatrixCellCreated=function(t,i){e.prototype.onMatrixCellCreated.call(this,t,i);var n=i.cellQuestion;if(i.row.editingObj){var r=i.row.editingObj.editor;r&&n.property&&r.registerFunctionOnPropertyValueChanged(n.property.name,(function(){n.value=o.Serializer.getObjPropertyValue(r,n.property.name)}))}},t}(Qn),$n=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getColumnsJSON=function(t,o,i,n,r){var a=e.prototype.getColumnsJSON.call(this,t,o,i,n,r);return this.getObjTypeName()&&a.unshift({name:this.getObjTypeName(),cellType:"dropdown"}),a},t.prototype.onMatrixCellCreated=function(t,o){if(e.prototype.onMatrixCellCreated.call(this,t,o),o.row.editingObj){var i=o.cellQuestion;o.columnName===this.getObjTypeName()&&(i.showOptionsCaption=!1,i.choices=this.getChoices(t),i.value=o.row.editingObj.getType())}},t.prototype.onMatrixCellValueChanged=function(e,t){if(t.columnName===this.getObjTypeName()){var i=t.question.visibleRows.indexOf(t.row);if(!(i<0)){var n=t.row.isDetailPanelShowing,r=t.row.editingObj.toJSON();delete r.type;var a=o.Serializer.createClass(t.value);a.fromJSON(r),a[this.getObjTypeName()]=a.getType(),t.row.hideDetailPanel(!0),t.question.value.splice(i,1,a),t.row.value=a,n&&t.row.showDetailPanel()}}},t.prototype.getShowDetailPanelOnAdding=function(){return!0},t}(Qn),er=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"validators"==e.type},t.prototype.getObjTypeName=function(){return"validatorType"},t.prototype.getDefaultClassName=function(e,t){var o="expression",i=e;if(i.getSupportedValidators){var n=i.getSupportedValidators();n.length>0&&n.indexOf(o)<0&&(o=n[0])}return o+"validator"},t.prototype.getChoices=function(e){for(var t=this.getSupportedValidators(e),o=[],i=0;i<t.length;i++){var n=t[i]+"validator";o.push({value:n,text:G.getValidatorName(n)})}return o},t.prototype.getSupportedValidators=function(e){return e?e.getSupportedValidators?e.getSupportedValidators():e.getOriginalObj?this.getSupportedValidators(e.getOriginalObj()):[]:[]},t}($n),tr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getAvailableTriggers=function(){return o.Serializer.getChildrenClasses("surveytrigger",!0).filter((function(e){return"visibletrigger"!==e.name}))},t.prototype.fit=function(e){return"triggers"==e.type},t.prototype.getObjTypeName=function(){return"triggerType"},t.prototype.getDefaultClassName=function(e,t){var o=this.getAvailableTriggers().map((function(e){return e.name}));return o.length?-1!==o.indexOf("runexpressiontrigger")?"runexpressiontrigger":o[0]:t.name},t.prototype.getAllowRowDragDrop=function(e){return!0},t.prototype.getChoices=function(e){return this.getAvailableTriggers().map((function(e){return{value:e.name,text:G.getTriggerName(e.name)}}))},t}($n);nt.register(new Un),nt.register(new Gn),nt.register(new Zn),nt.register(new Jn),nt.register(new Wn),nt.register(new Kn),nt.register(new Yn),nt.register(new Xn),nt.register(new er),nt.register(new tr),nt.register({fit:function(e){return"icon"===e.name&&"itemvalue"===e.classInfo.name},getJSON:function(e){return{type:"html"}}}),nt.register(new zn);var or={name:"propertygrid_bindings",showInToolbox:!1,internal:!0,createElements:function(){}};o.ComponentCollection.Instance.getCustomQuestionByName(or.name)||o.ComponentCollection.Instance.add(or);var ir=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"bindings"==e.type},t.prototype.getJSON=function(){return{type:"propertygrid_bindings"}},t.prototype.onCreated=function(e,t,o,i){t.contentPanel.fromJSON({elements:this.getQuestions(e,i)}),t.valueFromDataCallback=function(t){if(!t&&e.bindings.getNames().length>0){for(var o={},i=0,n=e.bindings.getNames();i<n.length;i++){var r=n[i];o[r]=e.bindings.getValueNameByPropertyName(r)}return o}return t}},t.prototype.getQuestions=function(e,t){for(var o=[],i=0,n=e.bindings.getNames();i<n.length;i++){var r=n[i];o.push(this.getBindingJSON(r,e,t))}return o},t.prototype.getBindingJSON=function(e,t,i){var n=new o.JsonObjectProperty(null,"value");n.type="questionvalue";var r=nt.getJSON(t,n,i);return r.titleLocation="left",r.descriptionLocation="hidden",r.minWidth="0px",r.name=e,r.title=G.getPropertyName(e),r},t}(lt);nt.register(new ir);var nr={name:"propertygrid_restfull",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(nr.name)||o.ComponentCollection.Instance.add(nr);var rr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"restfull"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_restfull",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i,n){var r=t.contentPanel,a=e[o.name];new at(a,i,e,o,n).setupObjPanel(r,!0);var s=r.addNewQuestion("dropdown","test");s.title=G.getString("ed.choicesLoadedFromWebPreviewTitle"),s.choices=[],this.updateTestQuestion(s,a)},t.prototype.onValueChanged=function(e,t,o){if("choicesByUrl"===t.name){var i=o.contentPanel.getQuestionByName("test");this.updateTestQuestion(i,e[t.name])}},t.prototype.updateTestQuestion=function(e,t){t&&(e.visible=!!t.url,e.choicesByUrl.setData(t))},t}(It);nt.register(new rr);var ar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"font"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"font",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt);nt.register(new ar);var sr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"backgroundcornerradius"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"backgroundcornerradius",descriptionLocation:"hidden"}},t.prototype.onCreated=function(e,t,o){t.valueFromDataCallback=function(e){return e},t.valueToDataCallback=function(e){return e}},t}(lt);nt.register(new sr);var lr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"shadoweffects"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"shadoweffects",descriptionLocation:"hidden"}},t}(lt);nt.register(new lr);var ur=function(e){function t(t,o){void 0===o&&(o=null);var i=e.call(this,o)||this;return i.matrix=t,i.editMatrixValue=i.editSurvey.getQuestionByName("question"),i.buildColumns(),i.buildRows(),i.editMatrix.value=i.matrix.cells.getJson(),i}return K(t,e),t.prototype.getSurveyJSON=function(){return{elements:[{type:"matrixdropdown",name:"question",cellType:"comment"}]}},t.prototype.getSurveyCreationReason=function(){return"cells-editor"},Object.defineProperty(t.prototype,"editMatrix",{get:function(){return this.editMatrixValue},enumerable:!1,configurable:!0}),t.prototype.apply=function(){return this.matrix.cells.setJson(this.editMatrix.value),!0},t.prototype.buildColumns=function(){for(var e=this.matrix.columns,t=0;t<e.length;t++)this.editMatrix.addColumn(""+e[t].value,e[t].text)},t.prototype.buildRows=function(){this.editMatrix.rows.push(new o.ItemValue("default",G.getString("pe.cellsDefaultRow")));for(var e=this.matrix.rows,t=0;t<e.length;t++)this.editMatrix.rows.push(new o.ItemValue(e[t].value,e[t].text))},t}(it),pr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,i,!1)||this;return n.editQuestion=t,n.propertyName=o,n.setupSurvey(),n.question.value=n.getQuestionValue(),n}return K(t,e),Object.defineProperty(t.prototype,"question",{get:function(){return this.editSurvey.getQuestionByName("question")},enumerable:!1,configurable:!0}),t.prototype.getSurveyJSON=function(){return{elements:[this.getQuestionJSON()]}},t.prototype.getQuestionJSON=function(){var e=this.editQuestion.toJSON();return e.name="question",e.title=e.title||this.editQuestion.name,e.type=this.editQuestion.getType(),"expression"==e.type&&(e.type="text"),e.cellType&&"matrixdropdowncolumn"==e.type&&(e.type=e.cellType,delete e.cellType),ee.updateQuestionJson(e),e},t.prototype.getQuestionValue=function(){return this.editQuestion[this.propertyName]},t.prototype.getEditValue=function(){return this.question.value},t.prototype.getSurveyCreationReason=function(){return"default-value"},t.prototype.apply=function(){return this.editQuestion[this.propertyName]=this.getEditValue(),!0},t}(it),cr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionValue=function(){var t=e.prototype.getQuestionValue.call(this);return t?(Array.isArray(t)||(t=[t]),t):t},t.prototype.getEditValue=function(){var t=e.prototype.getEditValue.call(this);return t&&Array.isArray(t)?0==t.length?null:t[0]:t},t}(pr),dr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionJSON=function(){var t=e.prototype.getQuestionJSON.call(this);return t.type="matrixdynamic",t.rowCount=1,t.minRowCount=1,t.maxRowCount=1,t.columnsLocation="vertical",delete t.defaultValue,t},t}(cr),hr=function(e){function t(t,o,i){void 0===i&&(i=null);var n=e.call(this,t,o,i)||this;return n.editQuestion=t,n.propertyName=o,n}return K(t,e),t.prototype.getQuestionJSON=function(){var t=e.prototype.getQuestionJSON.call(this);return t.panelCount=1,t.minPanelCount=1,t.maxPanelCount=1,t},t}(cr),gr=function(e){function t(t,o,i,n){void 0===n&&(n=null);var r=e.call(this,t,i,n)||this;return r.editQuestion=t,r.editObj=o,r.propertyName=i,r.question.value=r.getQuestionValue(),r}return K(t,e),t.prototype.getQuestionValue=function(){return this.editObj?this.editObj[this.propertyName]:null},t.prototype.apply=function(){return this.editObj[this.propertyName]=this.question.value,!0},t}(pr),mr=function(e){function t(){var t=null!==e&&e.apply(this,arguments)||this;return t.onCreated=function(e,o,i,n){var r=o;r.isClickableCallback=function(){return!r.isReadOnly||!t.isValueEmpty(r.value)},r.linkClickCallback=function(){t.showModalPropertyEditor(t,i,o,n,(function(){return r.isSelected=!1})),r.isSelected=!0},r.clearClickCallback=function(){t.clearPropertyValue(o.obj,i,o,null)}},t}return K(t,e),t.prototype.getJSON=function(e,t,o){return{type:"linkvalue",showValueInLink:!1,titleLocation:"hidden"}},t.prototype.clearPropertyValue=function(e,t,o,i){e[t.name]=void 0},t.prototype.isValueEmpty=function(e){return o.Helpers.isValueEmpty(e)},t.prototype.isSupportGrouping=function(){return!0},t}(lt),fr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"cells"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new ur(e,i)},t.prototype.clearPropertyValue=function(e,t,o,i){e.cells.setJson(null)},t.prototype.isValueEmpty=function(e){return!e||o.Helpers.isValueEmpty(e.values)},t}(mr),yr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"value"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new pr(e,t.name,i)},t}(mr),vr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"rowvalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new dr(e,t.name,i)},t}(mr),br=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"panelvalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){return new hr(e,t.name,i)},t}(mr),Cr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"triggervalue"==e.type},t.prototype.createPropertyEditorSetup=function(e,t,o,i){var n=o.obj,r=this.getSetToNameQuestion(n);return new gr(r,n,t.name,i)},t.prototype.getSetToNameQuestion=function(e){var t=e.getSurvey();return t||(t=e.owner),e.setToName&&t?t.getQuestionByValueName(e.setToName):null},t}(mr),wr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e,t){return"logic"===t&&"triggervalue"==e.type},t.prototype.getJSON=function(e,t,o){var i=this.getSetToNameQuestion(e);if(!i)return{type:"linkvalue"};var n=i.toJSON();return n.type=i.getType(),ee.updateQuestionJson(n),n},t}(Cr);nt.register(new fr),nt.register(new yr),nt.register(new vr),nt.register(new br),nt.register(new Cr),nt.register(new wr);var xr={name:"propertygrid_masksettings",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(xr.name)||o.ComponentCollection.Instance.add(xr);var Tr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"masksettings"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_masksettings",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i){var n=e[o.name];this._propertyGrid=new at(n,i,e,o),this._prevMaskType="";var r=t.contentPanel;this._previewQuestion=r.addNewQuestion("html","preview"),this.updatePanel(e,t,o)},t.prototype.onValueChanged=function(e,t,o){"maskSettings"===t.name&&this.updatePanel(e,o,t)},t.prototype.updatePanel=function(e,t,o){var i=t.contentPanel,n=e[o.name];this._prevMaskType!==e.maskType&&(this._propertyGrid.obj=n,this._propertyGrid.setupObjPanel(i,!0),this._prevMaskType=e.maskType),"datetimemask"==n.getType()&&this.updateDateTimeMinMaxInputType(n,i),this.updatePreviewQuestion(n,i)},t.prototype.updateDateTimeMinMaxInputType=function(e,t){var o="datetime-local";e.hasDatePart||(o="time"),e.hasTimePart||(o="date"),t.getQuestionByName("min").inputType=o,t.getQuestionByName("max").inputType=o},t.prototype.updatePreviewQuestion=function(e,t){this._previewQuestion.visible="masksettings"===e.getType(),t.getElementByName(this._previewQuestion.name)||t.addElement(this._previewQuestion)},t}(lt);nt.register(new Tr);var Sr={name:"propertygrid_header",showInToolbox:!1,internal:!0,createElements:function(e){}};o.ComponentCollection.Instance.getCustomQuestionByName(Sr.name)||o.ComponentCollection.Instance.add(Sr);var Pr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.fit=function(e){return"header"==e.type},t.prototype.getJSON=function(e,t,o){return{type:"propertygrid_header",titleLocation:"hidden"}},t.prototype.onCreated=function(e,t,o,i,n){var r,a=t.contentPanel,s=e[o.name];new at(s,i,e,o,Ri).setupObjPanel(a,!0);for(var l=a.elements,u=0;u<l.length;u++)"settings"==l[u].name&&(r=l[u]);r.state=void 0,r.title="",r.elements.forEach((function(e){e.title="",e.state=void 0}))},t}(lt);nt.register(new Pr);var Er=r(7288);o.SvgRegistry.registerIconsFromFolder(Er);var Vr,Ir=function(){function e(){this.onApplied=new o.EventBase,this.children=[],this.setupPresets()}return e.prototype.setJson=function(e){var t=this;!e&&this.applyEmptyJson()&&(e={}),this.json=e,this.children.forEach((function(e){return e.setJson(t.json&&e.getPath()?t.json[e.getPath()]:t.json)}))},e.prototype.apply=function(e){this.json&&(e&&(this.applyCore(e),this.children.forEach((function(t){return t.apply(e)}))),this.onApplied.fire(this,{}))},e.prototype.applyEmptyJson=function(){return!1},e.prototype.applyCore=function(e){},e.prototype.createPresets=function(){return[]},e.prototype.setupPresets=function(){this.addPresets(this.createPresets())},e.prototype.addPreset=function(e){this.children.push(e)},e.prototype.addPresets=function(e){var t=this;e.forEach((function(e){return t.addPreset(e)}))},e}(),Or=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"definition"},t.prototype.applyCore=function(t){e.prototype.applyCore.call(this,t),this.applyDefinition(t,this.json)},t.prototype.applyDefinition=function(e,t){var o=e.toolbox;o.presetDefaultItems=this.getPresetDefaultItems(t),Array.isArray(t)&&t.forEach((function(e){var t=o.getActionById(e.name);t&&["iconName","title","tooltip","json"].forEach((function(o){e[o]&&(t[o]=e[o])}))}))},t.prototype.getPresetDefaultItems=function(e){if(Array.isArray(e)){var t=JSON.parse(JSON.stringify(e)),o=new Array;return t.forEach((function(e){"object"==typeof e&&e.name&&o.push(e)})),o}},t}(Ir),Ar=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return""},t.prototype.applyCore=function(t){this.json&&(e.prototype.applyCore.call(this,t),t.toolbox.showCategoryTitles=this.json.showCategoryTitles,this.applyItems(t,this.json.items),this.applyCategories(t,this.json.categories))},t.prototype.applyItems=function(e,t){Array.isArray(t)&&(e.toolbox.hasCategories=!1,e.toolbox.defineCategories([{category:"general",items:t}]))},t.prototype.applyCategories=function(e,t){Array.isArray(t)&&(e.toolbox.hasCategories=!0,e.toolbox.defineCategories(t))},t}(Ir),Nr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"toolbox"},t.prototype.createPresets=function(){return[new Or,new Ar]},t}(Ir),Lr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"languages"},t.prototype.applyEmptyJson=function(){return!0},t.prototype.applyCore=function(t){var i,n,r;e.prototype.applyCore.call(this,t);var a=(null===(i=this.json)||void 0===i?void 0:i.creator)||"",s=(null===(n=this.json)||void 0===n?void 0:n.surveyLocales)||[],l=null===(r=this.json)||void 0===r?void 0:r.useEnglishNames;t.locale=a,o.surveyLocalization.supportedLocales=s,o.surveyLocalization.showNamesInEnglish=!0===l},t}(Ir),_r=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"tabs"},t.prototype.applyCore=function(t){e.prototype.applyCore.call(this,t);var o=this.json.items||[],i=this.json.activeTab||(o.length>0?o[0]:"");if(o.length>0&&o.indexOf(i)<0&&(i=o[0]),i&&t.activeTab!==i){var n=t.getPlugin(t.activeTab);(null==n?void 0:n.deactivate)&&n.deactivate()}this.applyTabs(t,o),i&&(t.activeTab="preview"===i?"test":i)},t.prototype.applyTabs=function(e,t){Array.isArray(t)&&e.setTabs(t)},t}(Ir),Mr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"definition"},t.prototype.applyCore=function(e){e.setPropertyGridDefinition(this.json)},t}(Ir),Dr=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return K(t,e),t.prototype.getPath=function(){return"propertyGrid"},t.prototype.createPresets=function(){return[new Mr]},t}(Ir),kr=function(e){function t(t){var o=e.call(this)||this;return o.setJson(t),o}return K(t,e),t.prototype.getPath=function(){return""},t.prototype.getJson=function(){return this.json},t.prototype.apply=function(t){e.prototype.apply.call(this,t),this.applyLocalization(),t&&t.updateLocalizedStrings()},t.prototype.applyLocalization=function(){var e,t=null===(e=this.json)||void 0===e?void 0:e.localization;G.presetStrings=t?JSON.parse(JSON.stringify(t)):void 0},t.prototype.createPresets=function(){return[new Lr,new _r,new Nr,new Dr]},t}(Ir);Vr="".concat("1.12.7"),r(5175),r(7167),r(9845),r(6681),r(5187),r(9336),r(422),r(9991),r(4163),r(4607),r(7231),r(326),r(1119),r(7671),r(3193),o.settings.supportCreatorV2=!0,(0,o.checkLibraryVersion)("".concat("1.12.7"),"survey-creator-core")})(),a})()));
|