@aquera/nile-elements 0.0.18 → 0.0.20
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/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-content-editor/nile-content-editor.css.js +4 -0
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-content-editor/nile-content-editor.css.js.map +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-content-editor/nile-content-editor.d.ts +1 -0
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-content-editor/nile-content-editor.js +25 -10
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-content-editor/nile-content-editor.js.map +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-radio-group/nile-radio-group.js +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-radio-group/nile-radio-group.js.map +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-switcher/nile-switcher.css.js +9 -6
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-switcher/nile-switcher.css.js.map +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-switcher/nile-switcher.d.ts +1 -0
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-switcher/nile-switcher.js +9 -3
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/src/nile-switcher/nile-switcher.js.map +1 -1
- package/.rollup.cache/opt/atlassian/pipelines/agent/build/packages/nile-elements/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/index.iife.js +26 -14
- package/dist/nile-content-editor/nile-content-editor.cjs.js +1 -1
- package/dist/nile-content-editor/nile-content-editor.cjs.js.map +1 -1
- package/dist/nile-content-editor/nile-content-editor.css.cjs.js +1 -1
- package/dist/nile-content-editor/nile-content-editor.css.cjs.js.map +1 -1
- package/dist/nile-content-editor/nile-content-editor.css.esm.js +4 -0
- package/dist/nile-content-editor/nile-content-editor.esm.js +7 -7
- package/dist/nile-radio-group/nile-radio-group.cjs.js +1 -1
- package/dist/nile-radio-group/nile-radio-group.cjs.js.map +1 -1
- package/dist/nile-radio-group/nile-radio-group.esm.js +1 -1
- package/dist/nile-switcher/nile-switcher.cjs.js +1 -1
- package/dist/nile-switcher/nile-switcher.cjs.js.map +1 -1
- package/dist/nile-switcher/nile-switcher.css.cjs.js +1 -1
- package/dist/nile-switcher/nile-switcher.css.cjs.js.map +1 -1
- package/dist/nile-switcher/nile-switcher.css.esm.js +11 -8
- package/dist/nile-switcher/nile-switcher.esm.js +26 -21
- package/dist/src/nile-content-editor/nile-content-editor.css.js +4 -0
- package/dist/src/nile-content-editor/nile-content-editor.css.js.map +1 -1
- package/dist/src/nile-content-editor/nile-content-editor.d.ts +1 -0
- package/dist/src/nile-content-editor/nile-content-editor.js +25 -10
- package/dist/src/nile-content-editor/nile-content-editor.js.map +1 -1
- package/dist/src/nile-radio-group/nile-radio-group.js +1 -1
- package/dist/src/nile-radio-group/nile-radio-group.js.map +1 -1
- package/dist/src/nile-switcher/nile-switcher.css.js +9 -6
- package/dist/src/nile-switcher/nile-switcher.css.js.map +1 -1
- package/dist/src/nile-switcher/nile-switcher.d.ts +1 -0
- package/dist/src/nile-switcher/nile-switcher.js +9 -3
- package/dist/src/nile-switcher/nile-switcher.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +1 -1
- package/src/nile-content-editor/nile-content-editor.css.ts +4 -0
- package/src/nile-content-editor/nile-content-editor.ts +24 -10
- package/src/nile-radio-group/nile-radio-group.ts +1 -1
- package/src/nile-switcher/nile-switcher.css.ts +9 -6
- package/src/nile-switcher/nile-switcher.ts +10 -2
package/dist/index.iife.js
CHANGED
@@ -1926,7 +1926,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
1926
1926
|
${this.hasButtonGroup?v`
|
1927
1927
|
${I}
|
1928
1928
|
`:v`
|
1929
|
-
<div class="${this.labelInline?"form-control--inline-radio":""}"> ${I}</div> `}
|
1929
|
+
<div part="options-base" class="${this.labelInline?"form-control--inline-radio":""}"> ${I}</div> `}
|
1930
1930
|
</div>
|
1931
1931
|
|
1932
1932
|
${D?v`
|
@@ -4703,15 +4703,18 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4703
4703
|
}
|
4704
4704
|
.input-container {
|
4705
4705
|
display: flex;
|
4706
|
+
gap: 0.5rem;
|
4706
4707
|
}
|
4707
4708
|
|
4708
|
-
.
|
4709
|
-
|
4710
|
-
|
4709
|
+
.tooltip-container {
|
4710
|
+
display: flex;
|
4711
|
+
flex-grow: 1;
|
4712
|
+
flex-shrink: 0;
|
4711
4713
|
}
|
4712
|
-
|
4713
|
-
|
4714
|
-
|
4714
|
+
|
4715
|
+
.input-container > :first-child {
|
4716
|
+
flex-grow: 1;
|
4717
|
+
flex-shrink: 0;
|
4715
4718
|
}
|
4716
4719
|
|
4717
4720
|
nile-radio {
|
@@ -4757,18 +4760,23 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4757
4760
|
@change=${M=>{this.handleChange(M,N,I)}}
|
4758
4761
|
>
|
4759
4762
|
${i&&i.map((M=>v`<nile-radio .value="${M}">${M} </nile-radio>`))}
|
4760
|
-
</nile-radio-group>`}renderContentEditor(M,N){const{value:i,options:D,inputType:j,errorMessage:I,type:g,readonly:u}=M;return v`<nile-content-editor
|
4763
|
+
</nile-radio-group>`}renderContentEditor(M,N){const{value:i,options:D,inputType:j,errorMessage:I,type:g,readonly:u,noborder:L}=M;return v`<nile-content-editor
|
4761
4764
|
.value=${i}
|
4762
4765
|
.options=${D}
|
4763
4766
|
.type=${g}
|
4764
4767
|
.readonly=${u}
|
4768
|
+
.noborder=${L}
|
4765
4769
|
.errorMessage=${I}
|
4766
4770
|
@nile-change=${M=>{this.handleChange(M,N,j)}}
|
4767
4771
|
>
|
4768
|
-
</nile-content-editor>`}handleChange(M,N,i){i===fi.CHECKBOX?this.nileSwitchConfig[N].value=M.detail.checked:this.nileSwitchConfig[N].value=M.detail.value,M.stopPropagation(),this.emit("nile-change",{config:this.nileSwitchConfig})}renderIcon(M,N){const i=M.helperText,D=N.helperText,j=this.nileSwitchConfig.toggleSwitch?"stringinput":"header-functions",I=this.nileSwitchConfig.toggleSwitch?i||`switch to ${M.inputType}`:D||`switch to ${N.inputType}`;return v` <nile-tooltip
|
4772
|
+
</nile-content-editor>`}handleChange(M,N,i){i===fi.CHECKBOX?this.nileSwitchConfig[N].value=M.detail.checked:this.nileSwitchConfig[N].value=M.detail.value,M.stopPropagation(),this.emit("nile-change",{config:this.nileSwitchConfig})}renderIcon(M,N){const i=M.helperText,D=N.helperText,j=this.nileSwitchConfig.toggleSwitch?"stringinput":"header-functions",I=this.nileSwitchConfig.toggleSwitch?i||`switch to ${M.inputType}`:D||`switch to ${N.inputType}`;return v` <nile-tooltip
|
4773
|
+
class=${nM({"tooltip-container":!0})}
|
4774
|
+
content=${I}
|
4775
|
+
placement="bottom"
|
4776
|
+
>
|
4769
4777
|
<nile-icon
|
4770
4778
|
size="14"
|
4771
|
-
class=${nM({"pointer-cursor":!0
|
4779
|
+
class=${nM({"pointer-cursor":!0})}
|
4772
4780
|
.name=${j}
|
4773
4781
|
color="#005EA6"
|
4774
4782
|
@click=${this.toggleField}
|
@@ -4864,7 +4872,11 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4864
4872
|
.asterik {
|
4865
4873
|
color: #e5434d;
|
4866
4874
|
}
|
4867
|
-
|
4875
|
+
|
4876
|
+
.no-border {
|
4877
|
+
border: none;
|
4878
|
+
}
|
4879
|
+
`,_i={BACKSPACE:"Backspace",TAB:"Tab",ENTER:"Enter",SHIFT:"ShiftLeft",CTRL:"ControlLeft",ESCAPE:"Escape",SPACE:"Space",PAGE_UP:"PageUp",PAGE_DOWN:"PageDown",END:"End",HOME:"Home",ARROW_LEFT:"ArrowLeft",ARROW_UP:"ArrowUp",ARROW_RIGHT:"ArrowRight",ARROW_DOWN:"ArrowDown",CUT:"KeyX",COPY:"Copy",PASTE:"Paste"};M.NileContentEditor=class extends BM{constructor(){super(...arguments),this.value="",this.showLabel=!0,this.labelText="",this.type="text|text-area",this.required=!0,this.openDropdown=!1,this.tagIdentifier="$",this.filteredValue="",this.helpText="",this.readonly=!1,this.errorMessage="",this.error=!1,this.noborder=!1}connectedCallback(){this.handleOutsideClick=this.handleOutsideClick.bind(this),this.handleClipboardEvent=this.handleClipboardEvent.bind(this),super.connectedCallback(),this.emit("nile-init"),this.addOpenListeners(),this.setInitialValues()}setInitialValues(){this.updateComplete.then((M=>{M&&this.value&&(this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value))}))}addOpenListeners(){this.addEventListener("click",this.handleOutsideClick),this.addEventListener("cut",this.handleClipboardEvent),this.addEventListener("copy",this.handleClipboardEvent),this.addEventListener("paste",this.handleClipboardEvent)}removeOpenListeners(){this.removeEventListener("click",this.handleOutsideClick),this.removeEventListener("cut",this.handleClipboardEvent),this.removeEventListener("copy",this.handleClipboardEvent),this.removeEventListener("paste",this.handleClipboardEvent)}async handleClipboardEvent(M){const N=window?.getSelection()?.toString();switch(M.type){case"cut":case"copy":N&&await navigator.clipboard.writeText(N),document.execCommand(M.type);break;case"paste":M.preventDefault();let i="";i=await navigator.clipboard.readText(),i=i.replace(/<(|\/)(html|body|meta|span)[^>]*?>/gi,"").trim(),document.execCommand("insertText",!1,i)}setTimeout((()=>{this.emitInputChange()}))}toggleDropdown(M){this.openDropdown=M}handleOutsideClick(M){M&&M.target&&this.toggleDropdown(!1)}handleTypeChange(){this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value)}disconnectedCallback(){super.disconnectedCallback(),this.removeOpenListeners(),this.emit("nile-destroy")}handlekeyDown(M){if(M.code!==_i.ENTER||"text"!==this.type){if(![_i.CUT,_i.COPY,_i.PASTE].includes(M.code)||!M.ctrlKey&&!M.metaKey){if(M.code===_i.ARROW_RIGHT&&(this.contentEditor.focus(),document.execCommand("selectAll",!1,void 0),document?.getSelection()?.collapseToEnd()),M.code===_i.ESCAPE)return M.preventDefault(),void this.toggleDropdown(!1);setTimeout((()=>{const M=this.contentEditor.innerText;this.emitInputChange(),M.includes(this.tagIdentifier)?(this.insertNodes(this.contentEditor,this.contentEditor.childNodes),this.filterOptions(),this.toggleDropdown(!0)):this.toggleDropdown(!1)}),10)}}else M.preventDefault()}filterOptions(){this.filteredOptions=this.options,this.filteredValue=this.filteredValue.trim(),this.options.length&&this.filteredValue?this.filteredOptions=this.options.filter((M=>M.includes(this.filteredValue))):this.filteredOptions=this.options}generateValuesFromHTMLTags(M){return M.replace(/<span class="chips(?: chip-error)?" contenteditable="false">(.*?)<\/span>/g,((M,N)=>"{{"+N+"}}"))}generateHTMLTagsWithValues(M){return M.replace(/{{(.*?)}}/g,((M,N)=>this.options.includes(N)?'<span class="chips" contenteditable="false">'+N+"</span>":this.setError(N)))}setError(M){return this.error=!0,'<span class="chips chip-error" contenteditable="false">'+M+"</span>"}emitInputChange(){if(this.contentEditor){let M=this.contentEditor.innerHTML;""!==this.contentEditor.innerText&&(M=this.generateValuesFromHTMLTags(M)),M=M.replace(/ /g," "),M=M.replace("<br>",""),this.emit("nile-change",{value:this.generateValuesFromHTMLTags(M)})}}insertNodes(M,N,i){[...N].forEach(((N,D)=>{if(N.hasChildNodes())i?this.insertNodes(N,N.childNodes,i):this.insertNodes(N,N.childNodes);else if(N.nodeValue?.includes(this.tagIdentifier))return i&&(M.childNodes[D].nodeValue=N.nodeValue?.replace(this.tagIdentifier+this.filteredValue,""),M.childNodes[D].after(i)),void(this.filteredValue=M?.childNodes[D]?.nodeValue?.split(this.tagIdentifier).slice(1).join()||"")}))}handleOptions(M){this.toggleDropdown(!1);let N=document.createElement("span");N.setAttribute("class","chips"),N.setAttribute("contentEditable","false"),N.innerText=M,this.insertNodes(this.contentEditor,this.contentEditor.childNodes,N),this.filteredOptions=this.options,this.filteredValue="",this.emitInputChange()}renderAutoOptions(){return v`<div
|
4868
4880
|
class="${nM({"nile-options-container":!0,"dropdown-position":"text-area"===this.type})}"
|
4869
4881
|
>
|
4870
4882
|
${this.filteredOptions&&this.filteredOptions.map((M=>v` <nile-option
|
@@ -4872,7 +4884,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4872
4884
|
@click="${N=>{this.handleOptions(M)}}"
|
4873
4885
|
>${M}
|
4874
4886
|
</nile-option>`))}
|
4875
|
-
</div>`}render(){const M=!!this.helpText,N=!!this.error,i=!!this.errorMessage,D=!!this.readonly,j=this.type;return v`
|
4887
|
+
</div>`}render(){const M=!!this.helpText,N=!!this.error,i=!!this.errorMessage,D=!!this.readonly,j=!!this.noborder,I=this.type;return v`
|
4876
4888
|
<nile-popup
|
4877
4889
|
.active="${FM(this.openDropdown)}"
|
4878
4890
|
sync="width"
|
@@ -4885,7 +4897,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4885
4897
|
<div
|
4886
4898
|
contenteditable="${!D}"
|
4887
4899
|
spellcheck="false"
|
4888
|
-
class=${nM({"content-editable-input":!0,error:N||i,"read-only":D,"text-area":"text-area"===
|
4900
|
+
class=${nM({"content-editable-input":!0,error:N||i,"read-only":D,"no-border":j,"text-area":"text-area"===I})}
|
4889
4901
|
@keydown=${this.handlekeyDown}
|
4890
4902
|
></div>
|
4891
4903
|
${M?v`
|
@@ -4899,7 +4911,7 @@ const bM=Symbol.for(""),ZM=M=>{if((null==M?void 0:M.r)===bM)return null==M?void
|
|
4899
4911
|
</div>
|
4900
4912
|
${this.filteredOptions&&this.filteredOptions.length?this.renderAutoOptions():null}
|
4901
4913
|
</nile-popup>
|
4902
|
-
`}},M.NileContentEditor.styles=Xi,N([tM()],M.NileContentEditor.prototype,"value",void 0),N([tM()],M.NileContentEditor.prototype,"options",void 0),N([tM()],M.NileContentEditor.prototype,"filteredOptions",void 0),N([tM()],M.NileContentEditor.prototype,"showLabel",void 0),N([tM()],M.NileContentEditor.prototype,"labelText",void 0),N([tM()],M.NileContentEditor.prototype,"type",void 0),N([tM()],M.NileContentEditor.prototype,"required",void 0),N([cM(".content-editable-input")],M.NileContentEditor.prototype,"contentEditor",void 0),N([cM(".nile-options-container")],M.NileContentEditor.prototype,"autoOptions",void 0),N([zM()],M.NileContentEditor.prototype,"openDropdown",void 0),N([tM({attribute:"help-text"})],M.NileContentEditor.prototype,"helpText",void 0),N([tM({attribute:"readonly"})],M.NileContentEditor.prototype,"readonly",void 0),N([tM({attribute:"error-message"})],M.NileContentEditor.prototype,"errorMessage",void 0),N([tM({attribute:"error"})],M.NileContentEditor.prototype,"error",void 0),N([VM("type",{waitUntilFirstUpdate:!0})],M.NileContentEditor.prototype,"handleTypeChange",null),M.NileContentEditor=N([uM("nile-content-editor")],M.NileContentEditor);const $i=u`
|
4914
|
+
`}},M.NileContentEditor.styles=Xi,N([tM()],M.NileContentEditor.prototype,"value",void 0),N([tM()],M.NileContentEditor.prototype,"options",void 0),N([tM()],M.NileContentEditor.prototype,"filteredOptions",void 0),N([tM()],M.NileContentEditor.prototype,"showLabel",void 0),N([tM()],M.NileContentEditor.prototype,"labelText",void 0),N([tM()],M.NileContentEditor.prototype,"type",void 0),N([tM()],M.NileContentEditor.prototype,"required",void 0),N([cM(".content-editable-input")],M.NileContentEditor.prototype,"contentEditor",void 0),N([cM(".nile-options-container")],M.NileContentEditor.prototype,"autoOptions",void 0),N([zM()],M.NileContentEditor.prototype,"openDropdown",void 0),N([tM({attribute:"help-text"})],M.NileContentEditor.prototype,"helpText",void 0),N([tM({attribute:"readonly"})],M.NileContentEditor.prototype,"readonly",void 0),N([tM({attribute:"error-message"})],M.NileContentEditor.prototype,"errorMessage",void 0),N([tM({attribute:"error"})],M.NileContentEditor.prototype,"error",void 0),N([tM({attribute:"noborder"})],M.NileContentEditor.prototype,"noborder",void 0),N([VM(["type"],{waitUntilFirstUpdate:!0})],M.NileContentEditor.prototype,"handleTypeChange",null),M.NileContentEditor=N([uM("nile-content-editor")],M.NileContentEditor);const $i=u`
|
4903
4915
|
:host {
|
4904
4916
|
--width: 31rem;
|
4905
4917
|
--header-spacing: 1.25rem;
|
@@ -1,2 +1,2 @@
|
|
1
|
-
System.register(["tslib","../index-cd83c5c8.cjs.js","lit/decorators.js","./nile-content-editor.css.cjs.js","lit/directives/class-map.js","../internal/nile-element.cjs.js","../internal/watch.cjs.js","../internal/enum.cjs.js","lit/directives/live.js","../property-0f6a51ec.cjs.js","lit"],function(_export,_context){"use strict";var t,i,s,e,o,n,h,r,a,l,d,p,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,c;function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread();}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen);}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter);}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr);}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2;}function _regeneratorRuntime(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */_regeneratorRuntime=function(){return e;};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value;},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function define(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e];}try{define({},"");}catch(t){define=function(t,e,r){return t[e]=r;};}function wrap(t,e,r,n){var i=e&&e.prototype instanceof Generator?e:Generator,a=Object.create(i.prototype),c=new Context(n||[]);return o(a,"_invoke",{value:makeInvokeMethod(t,r,c)}),a;}function tryCatch(t,e,r){try{return{type:"normal",arg:t.call(e,r)};}catch(t){return{type:"throw",arg:t};}}e.wrap=wrap;var h="suspendedStart",l="suspendedYield",f="executing",s="completed",y={};function Generator(){}function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var p={};define(p,a,function(){return this;});var d=Object.getPrototypeOf,v=d&&d(d(values([])));v&&v!==r&&n.call(v,a)&&(p=v);var g=GeneratorFunctionPrototype.prototype=Generator.prototype=Object.create(p);function defineIteratorMethods(t){["next","throw","return"].forEach(function(e){define(t,e,function(t){return this._invoke(e,t);});});}function AsyncIterator(t,e){function invoke(r,o,i,a){var c=tryCatch(t[r],t,o);if("throw"!==c.type){var u=c.arg,h=u.value;return h&&"object"==typeof h&&n.call(h,"__await")?e.resolve(h.__await).then(function(t){invoke("next",t,i,a);},function(t){invoke("throw",t,i,a);}):e.resolve(h).then(function(t){u.value=t,i(u);},function(t){return invoke("throw",t,i,a);});}a(c.arg);}var r;o(this,"_invoke",{value:function(t,n){function callInvokeWithMethodAndArg(){return new e(function(e,r){invoke(t,n,e,r);});}return r=r?r.then(callInvokeWithMethodAndArg,callInvokeWithMethodAndArg):callInvokeWithMethodAndArg();}});}function makeInvokeMethod(e,r,n){var o=h;return function(i,a){if(o===f)throw new Error("Generator is already running");if(o===s){if("throw"===i)throw a;return{value:t,done:!0};}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=maybeInvokeDelegate(c,n);if(u){if(u===y)continue;return u;}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=s,n.arg;n.dispatchException(n.arg);}else"return"===n.method&&n.abrupt("return",n.arg);o=f;var p=tryCatch(e,r,n);if("normal"===p.type){if(o=n.done?s:l,p.arg===y)continue;return{value:p.arg,done:n.done};}"throw"===p.type&&(o=s,n.method="throw",n.arg=p.arg);}};}function maybeInvokeDelegate(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,maybeInvokeDelegate(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var i=tryCatch(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y);}function pushTryEntry(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e);}function resetTryEntry(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e;}function Context(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(pushTryEntry,this),this.reset(!0);}function values(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function next(){for(;++o<e.length;)if(n.call(e,o))return next.value=e[o],next.done=!1,next;return next.value=t,next.done=!0,next;};return i.next=i;}}throw new TypeError(typeof e+" is not iterable");}return GeneratorFunction.prototype=GeneratorFunctionPrototype,o(g,"constructor",{value:GeneratorFunctionPrototype,configurable:!0}),o(GeneratorFunctionPrototype,"constructor",{value:GeneratorFunction,configurable:!0}),GeneratorFunction.displayName=define(GeneratorFunctionPrototype,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===GeneratorFunction||"GeneratorFunction"===(e.displayName||e.name));},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,GeneratorFunctionPrototype):(t.__proto__=GeneratorFunctionPrototype,define(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t;},e.awrap=function(t){return{__await:t};},defineIteratorMethods(AsyncIterator.prototype),define(AsyncIterator.prototype,c,function(){return this;}),e.AsyncIterator=AsyncIterator,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new AsyncIterator(wrap(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then(function(t){return t.done?t.value:a.next();});},defineIteratorMethods(g),define(g,u,"Generator"),define(g,a,function(){return this;}),define(g,"toString",function(){return"[object Generator]";}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function next(){for(;r.length;){var t=r.pop();if(t in e)return next.value=t,next.done=!1,next;}return next.done=!0,next;};},e.values=values,Context.prototype={constructor:Context,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(resetTryEntry),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t);},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval;},dispatchException:function(e){if(this.done)throw e;var r=this;function handle(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o;}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return handle("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}else if(c){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break;}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a);},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y;},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),resetTryEntry(r),y;}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;resetTryEntry(r);}return o;}}throw new Error("illegal catch attempt");},delegateYield:function(e,r,n){return this.delegate={iterator:values(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y;}},e;}function asyncGeneratorStep(gen,resolve,reject,_next,_throw,key,arg){try{var info=gen[key](arg);var value=info.value;}catch(error){reject(error);return;}if(info.done){resolve(value);}else{Promise.resolve(value).then(_next,_throw);}}function _asyncToGenerator(fn){return function(){var self=this,args=arguments;return new Promise(function(resolve,reject){var gen=fn.apply(self,args);function _next(value){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"next",value);}function _throw(err){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"throw",err);}_next(undefined);});};}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor);}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor;}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key);}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.");}return(hint==="string"?String:Number)(input);}function _get(){if(typeof Reflect!=="undefined"&&Reflect.get){_get=Reflect.get.bind();}else{_get=function _get(target,property,receiver){var base=_superPropBase(target,property);if(!base)return;var desc=Object.getOwnPropertyDescriptor(base,property);if(desc.get){return desc.get.call(arguments.length<3?target:receiver);}return desc.value;};}return _get.apply(this,arguments);}function _superPropBase(object,property){while(!Object.prototype.hasOwnProperty.call(object,property)){object=_getPrototypeOf(object);if(object===null)break;}return object;}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function");}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass);}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o;};return _setPrototypeOf(o,p);}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget);}else{result=Super.apply(this,arguments);}return _possibleConstructorReturn(this,result);};}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call;}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined");}return _assertThisInitialized(self);}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn't been initialised - super() hasn't been called");}return self;}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true;}catch(e){return false;}}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o);};return _getPrototypeOf(o);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_index001CjsJs){i=_index001CjsJs.x;},function(_litDecoratorsJs){s=_litDecoratorsJs.query;e=_litDecoratorsJs.state;o=_litDecoratorsJs.customElement;},function(_nileContentEditorCssCjsJs){n=_nileContentEditorCssCjsJs.s;},function(_litDirectivesClassMapJs){h=_litDirectivesClassMapJs.classMap;},function(_internalNileElementCjsJs){r=_internalNileElementCjsJs.N;},function(_internalWatchCjsJs){a=_internalWatchCjsJs.w;},function(_internalEnumCjsJs){l=_internalEnumCjsJs.K;},function(_litDirectivesLiveJs){d=_litDirectivesLiveJs.live;},function(_property002CjsJs){p=_property002CjsJs.n;},function(_lit){}],execute:function(){_export("N",c=/*#__PURE__*/function(_r){_inherits(c,_r);var _super=_createSuper(c);function c(){var _this;_classCallCheck(this,c);_this=_super.apply(this,arguments),_this.value="",_this.showLabel=!0,_this.labelText="",_this.type="text|text-area",_this.required=!0,_this.openDropdown=!1,_this.tagIdentifier="$",_this.filteredValue="",_this.helpText="",_this.readonly=!1,_this.errorMessage="",_this.error=!1;return _this;}_createClass(c,[{key:"connectedCallback",value:function connectedCallback(){this.handleOutsideClick=this.handleOutsideClick.bind(this),this.handleClipboardEvent=this.handleClipboardEvent.bind(this),_get(_getPrototypeOf(c.prototype),"connectedCallback",this).call(this),this.emit("nile-init"),this.addOpenListeners(),this.setInitialValues();}},{key:"setInitialValues",value:function setInitialValues(){var _this2=this;this.updateComplete.then(function(t){t&&_this2.value&&(_this2.contentEditor.innerHTML=_this2.generateHTMLTagsWithValues(_this2.value));});}},{key:"addOpenListeners",value:function addOpenListeners(){window.addEventListener("click",this.handleOutsideClick),window.addEventListener("cut",this.handleClipboardEvent),window.addEventListener("copy",this.handleClipboardEvent),window.addEventListener("paste",this.handleClipboardEvent);}},{key:"removeOpenListeners",value:function removeOpenListeners(){window.removeEventListener("click",this.handleOutsideClick),window.removeEventListener("cut",this.handleClipboardEvent),window.removeEventListener("copy",this.handleClipboardEvent),window.removeEventListener("paste",this.handleClipboardEvent);}},{key:"handleClipboardEvent",value:function(){var _handleClipboardEvent=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(t){var _window,_this3=this;var i,_s;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:i=(_window=window)===null||_window===void 0||(_window=_window.getSelection())===null||_window===void 0?void 0:_window.toString();_context2.t0=t.type;_context2.next=_context2.t0==="cut"?4:_context2.t0==="copy"?4:_context2.t0==="paste"?10:15;break;case 4:_context2.t1=i;if(!_context2.t1){_context2.next=8;break;}_context2.next=8;return navigator.clipboard.writeText(i);case 8:document.execCommand(t.type);return _context2.abrupt("break",15);case 10:t.preventDefault();_context2.next=13;return navigator.clipboard.readText();case 13:_s=_context2.sent;_s=_s.replace(/<(|\/)(html|body|meta|span)[^>]*?>/gi,"").trim(),document.execCommand("insertText",!1,_s);case 15:setTimeout(function(){_this3.emitInputChange();});case 16:case"end":return _context2.stop();}},_callee);}));function handleClipboardEvent(_x){return _handleClipboardEvent.apply(this,arguments);}return handleClipboardEvent;}()},{key:"toggleDropdown",value:function toggleDropdown(t){this.openDropdown=t;}},{key:"handleOutsideClick",value:function handleOutsideClick(t){t&&t.target&&this.toggleDropdown(!1);}},{key:"handleTypeChange",value:function handleTypeChange(){this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value);}},{key:"disconnectedCallback",value:function disconnectedCallback(){_get(_getPrototypeOf(c.prototype),"disconnectedCallback",this).call(this),this.removeOpenListeners(),this.emit("nile-destroy");}},{key:"handlekeyDown",value:function handlekeyDown(t){var _this4=this;if(t.code!==l.ENTER||"text"!==this.type){if(![l.CUT,l.COPY,l.PASTE].includes(t.code)||!t.ctrlKey&&!t.metaKey)return t.code===l.ESCAPE?(t.preventDefault(),void this.toggleDropdown(!1)):void setTimeout(function(){var t=_this4.contentEditor.innerText;_this4.emitInputChange(),t.includes(_this4.tagIdentifier)?(_this4.insertNodes(_this4.contentEditor,_this4.contentEditor.childNodes),_this4.filterOptions(),_this4.toggleDropdown(!0)):_this4.toggleDropdown(!1);},10);}else t.preventDefault();}},{key:"filterOptions",value:function filterOptions(){var _this5=this;this.filteredOptions=this.options,this.options.length&&this.filteredValue?this.filteredOptions=this.options.filter(function(t){return t.includes(_this5.filteredValue);}):this.filteredOptions=this.options;}},{key:"generateValuesFromHTMLTags",value:function generateValuesFromHTMLTags(t){return t.replace(/<span class="chips(?: chip-error)?" contenteditable="false">(.*?)<\/span>/g,function(t,i){return"{{"+i+"}}";});}},{key:"generateHTMLTagsWithValues",value:function generateHTMLTagsWithValues(t){var _this6=this;return t.replace(/{{(.*?)}}/g,function(t,i){return _this6.options.includes(i)?'<span class="chips" contenteditable="false">'+i+"</span>":_this6.setError(i);});}},{key:"setError",value:function setError(t){return this.error=!0,'<span class="chips chip-error" contenteditable="false">'+t+"</span>";}},{key:"emitInputChange",value:function emitInputChange(){if(this.contentEditor){var _t=this.contentEditor.innerHTML;""!==this.contentEditor.innerText&&(_t=this.generateValuesFromHTMLTags(_t)),_t=_t.replace(/ /g," "),_t=_t.replace("<br>",""),this.emit("nile-change",{value:this.generateValuesFromHTMLTags(_t)});}}},{key:"insertNodes",value:function insertNodes(t,i,s){var _this7=this;_toConsumableArray(i).forEach(function(i,e){var _i$nodeValue,_i$nodeValue2,_t$childNodes$e;if(i.hasChildNodes())s?_this7.insertNodes(i,i.childNodes,s):_this7.insertNodes(i,i.childNodes);else if((_i$nodeValue=i.nodeValue)!==null&&_i$nodeValue!==void 0&&_i$nodeValue.includes(_this7.tagIdentifier))return s&&(t.childNodes[e].nodeValue=(_i$nodeValue2=i.nodeValue)===null||_i$nodeValue2===void 0?void 0:_i$nodeValue2.replace(_this7.tagIdentifier+_this7.filteredValue,""),t.childNodes[e].after(s)),void(_this7.filteredValue=(t===null||t===void 0||(_t$childNodes$e=t.childNodes[e])===null||_t$childNodes$e===void 0||(_t$childNodes$e=_t$childNodes$e.nodeValue)===null||_t$childNodes$e===void 0?void 0:_t$childNodes$e.split(_this7.tagIdentifier).slice(1).join())||"");});}},{key:"handleOptions",value:function handleOptions(t){this.toggleDropdown(!1);var i=document.createElement("span");i.setAttribute("class","chips"),i.setAttribute("contentEditable","false"),i.innerText=t,this.insertNodes(this.contentEditor,this.contentEditor.childNodes,i),this.filteredOptions=this.options,this.filteredValue="",this.emitInputChange();}},{key:"renderAutoOptions",value:function renderAutoOptions(){var _this8=this;return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["<div\n class=\"","\"\n >\n ","\n </div>"])),h({"nile-options-container":!0,"dropdown-position":"text-area"===this.type}),this.filteredOptions&&this.filteredOptions.map(function(t){return i(_templateObject2||(_templateObject2=_taggedTemplateLiteral([" <nile-option\n .value=\"","\"\n @click=\"","\"\n >","\n </nile-option>"])),t,function(i){_this8.handleOptions(t);},t);}));}},{key:"render",value:function render(){var t=!!this.helpText,s=!!this.error,e=!!this.errorMessage,o=!!this.readonly,n=this.type;return i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <nile-popup\n .active=\"","\"\n sync=\"width\"\n strategy=\"fixed\"\n placement=\"bottom\"\n class=","\n >\n <div class=\"content-editable-wrapper\" slot=\"anchor\">\n ","\n <div\n contenteditable=\"","\"\n spellcheck=\"false\"\n class=","\n @keydown=","\n ></div>\n ","\n ","\n </div>\n ","\n </nile-popup>\n "])),d(this.openDropdown),h({dropdown:!0,"dropdown--open":!0,popup:!0}),this.showLabel&&this.labelText?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<label class=\"ods-label\">"," </label> ",""])),this.labelText,this.required?i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<span class=\"asterik\">*</span>"]))):""):"",!o,h({"content-editable-input":!0,error:s||e,"read-only":o,"text-area":"text-area"===n}),this.handlekeyDown,t?i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n <nile-form-help-text>","</nile-form-help-text>\n "])),this.helpText):"",e?i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <nile-form-error-message\n >","</nile-form-error-message\n >\n "])),this.errorMessage):"",this.filteredOptions&&this.filteredOptions.length?this.renderAutoOptions():null);}}]);return c;}(r));c.styles=n,t([p()],c.prototype,"value",void 0),t([p()],c.prototype,"options",void 0),t([p()],c.prototype,"filteredOptions",void 0),t([p()],c.prototype,"showLabel",void 0),t([p()],c.prototype,"labelText",void 0),t([p()],c.prototype,"type",void 0),t([p()],c.prototype,"required",void 0),t([s(".content-editable-input")],c.prototype,"contentEditor",void 0),t([s(".nile-options-container")],c.prototype,"autoOptions",void 0),t([e()],c.prototype,"openDropdown",void 0),t([p({attribute:"help-text"})],c.prototype,"helpText",void 0),t([p({attribute:"readonly"})],c.prototype,"readonly",void 0),t([p({attribute:"error-message"})],c.prototype,"errorMessage",void 0),t([p({attribute:"error"})],c.prototype,"error",void 0),t([a("type",{waitUntilFirstUpdate:!0})],c.prototype,"handleTypeChange",null),_export("N",c=t([o("nile-content-editor")],c));}};});
|
1
|
+
System.register(["tslib","../index-cd83c5c8.cjs.js","lit/decorators.js","./nile-content-editor.css.cjs.js","lit/directives/class-map.js","../internal/nile-element.cjs.js","../internal/watch.cjs.js","../internal/enum.cjs.js","lit/directives/live.js","../property-0f6a51ec.cjs.js","lit"],function(_export,_context){"use strict";var t,i,s,e,o,h,n,r,a,l,p,d,_templateObject,_templateObject2,_templateObject3,_templateObject4,_templateObject5,_templateObject6,_templateObject7,c;function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}function _toConsumableArray(arr){return _arrayWithoutHoles(arr)||_iterableToArray(arr)||_unsupportedIterableToArray(arr)||_nonIterableSpread();}function _nonIterableSpread(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");}function _unsupportedIterableToArray(o,minLen){if(!o)return;if(typeof o==="string")return _arrayLikeToArray(o,minLen);var n=Object.prototype.toString.call(o).slice(8,-1);if(n==="Object"&&o.constructor)n=o.constructor.name;if(n==="Map"||n==="Set")return Array.from(o);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return _arrayLikeToArray(o,minLen);}function _iterableToArray(iter){if(typeof Symbol!=="undefined"&&iter[Symbol.iterator]!=null||iter["@@iterator"]!=null)return Array.from(iter);}function _arrayWithoutHoles(arr){if(Array.isArray(arr))return _arrayLikeToArray(arr);}function _arrayLikeToArray(arr,len){if(len==null||len>arr.length)len=arr.length;for(var i=0,arr2=new Array(len);i<len;i++)arr2[i]=arr[i];return arr2;}function _regeneratorRuntime(){"use strict";/*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */_regeneratorRuntime=function(){return e;};var t,e={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(t,e,r){t[e]=r.value;},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",c=i.asyncIterator||"@@asyncIterator",u=i.toStringTag||"@@toStringTag";function define(t,e,r){return Object.defineProperty(t,e,{value:r,enumerable:!0,configurable:!0,writable:!0}),t[e];}try{define({},"");}catch(t){define=function(t,e,r){return t[e]=r;};}function wrap(t,e,r,n){var i=e&&e.prototype instanceof Generator?e:Generator,a=Object.create(i.prototype),c=new Context(n||[]);return o(a,"_invoke",{value:makeInvokeMethod(t,r,c)}),a;}function tryCatch(t,e,r){try{return{type:"normal",arg:t.call(e,r)};}catch(t){return{type:"throw",arg:t};}}e.wrap=wrap;var h="suspendedStart",l="suspendedYield",f="executing",s="completed",y={};function Generator(){}function GeneratorFunction(){}function GeneratorFunctionPrototype(){}var p={};define(p,a,function(){return this;});var d=Object.getPrototypeOf,v=d&&d(d(values([])));v&&v!==r&&n.call(v,a)&&(p=v);var g=GeneratorFunctionPrototype.prototype=Generator.prototype=Object.create(p);function defineIteratorMethods(t){["next","throw","return"].forEach(function(e){define(t,e,function(t){return this._invoke(e,t);});});}function AsyncIterator(t,e){function invoke(r,o,i,a){var c=tryCatch(t[r],t,o);if("throw"!==c.type){var u=c.arg,h=u.value;return h&&"object"==typeof h&&n.call(h,"__await")?e.resolve(h.__await).then(function(t){invoke("next",t,i,a);},function(t){invoke("throw",t,i,a);}):e.resolve(h).then(function(t){u.value=t,i(u);},function(t){return invoke("throw",t,i,a);});}a(c.arg);}var r;o(this,"_invoke",{value:function(t,n){function callInvokeWithMethodAndArg(){return new e(function(e,r){invoke(t,n,e,r);});}return r=r?r.then(callInvokeWithMethodAndArg,callInvokeWithMethodAndArg):callInvokeWithMethodAndArg();}});}function makeInvokeMethod(e,r,n){var o=h;return function(i,a){if(o===f)throw new Error("Generator is already running");if(o===s){if("throw"===i)throw a;return{value:t,done:!0};}for(n.method=i,n.arg=a;;){var c=n.delegate;if(c){var u=maybeInvokeDelegate(c,n);if(u){if(u===y)continue;return u;}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===h)throw o=s,n.arg;n.dispatchException(n.arg);}else"return"===n.method&&n.abrupt("return",n.arg);o=f;var p=tryCatch(e,r,n);if("normal"===p.type){if(o=n.done?s:l,p.arg===y)continue;return{value:p.arg,done:n.done};}"throw"===p.type&&(o=s,n.method="throw",n.arg=p.arg);}};}function maybeInvokeDelegate(e,r){var n=r.method,o=e.iterator[n];if(o===t)return r.delegate=null,"throw"===n&&e.iterator.return&&(r.method="return",r.arg=t,maybeInvokeDelegate(e,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var i=tryCatch(o,e.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[e.resultName]=a.value,r.next=e.nextLoc,"return"!==r.method&&(r.method="next",r.arg=t),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y);}function pushTryEntry(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e);}function resetTryEntry(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e;}function Context(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(pushTryEntry,this),this.reset(!0);}function values(e){if(e||""===e){var r=e[a];if(r)return r.call(e);if("function"==typeof e.next)return e;if(!isNaN(e.length)){var o=-1,i=function next(){for(;++o<e.length;)if(n.call(e,o))return next.value=e[o],next.done=!1,next;return next.value=t,next.done=!0,next;};return i.next=i;}}throw new TypeError(typeof e+" is not iterable");}return GeneratorFunction.prototype=GeneratorFunctionPrototype,o(g,"constructor",{value:GeneratorFunctionPrototype,configurable:!0}),o(GeneratorFunctionPrototype,"constructor",{value:GeneratorFunction,configurable:!0}),GeneratorFunction.displayName=define(GeneratorFunctionPrototype,u,"GeneratorFunction"),e.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===GeneratorFunction||"GeneratorFunction"===(e.displayName||e.name));},e.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,GeneratorFunctionPrototype):(t.__proto__=GeneratorFunctionPrototype,define(t,u,"GeneratorFunction")),t.prototype=Object.create(g),t;},e.awrap=function(t){return{__await:t};},defineIteratorMethods(AsyncIterator.prototype),define(AsyncIterator.prototype,c,function(){return this;}),e.AsyncIterator=AsyncIterator,e.async=function(t,r,n,o,i){void 0===i&&(i=Promise);var a=new AsyncIterator(wrap(t,r,n,o),i);return e.isGeneratorFunction(r)?a:a.next().then(function(t){return t.done?t.value:a.next();});},defineIteratorMethods(g),define(g,u,"Generator"),define(g,a,function(){return this;}),define(g,"toString",function(){return"[object Generator]";}),e.keys=function(t){var e=Object(t),r=[];for(var n in e)r.push(n);return r.reverse(),function next(){for(;r.length;){var t=r.pop();if(t in e)return next.value=t,next.done=!1,next;}return next.done=!0,next;};},e.values=values,Context.prototype={constructor:Context,reset:function(e){if(this.prev=0,this.next=0,this.sent=this._sent=t,this.done=!1,this.delegate=null,this.method="next",this.arg=t,this.tryEntries.forEach(resetTryEntry),!e)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=t);},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval;},dispatchException:function(e){if(this.done)throw e;var r=this;function handle(n,o){return a.type="throw",a.arg=e,r.next=n,o&&(r.method="next",r.arg=t),!!o;}for(var o=this.tryEntries.length-1;o>=0;--o){var i=this.tryEntries[o],a=i.completion;if("root"===i.tryLoc)return handle("end");if(i.tryLoc<=this.prev){var c=n.call(i,"catchLoc"),u=n.call(i,"finallyLoc");if(c&&u){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}else if(c){if(this.prev<i.catchLoc)return handle(i.catchLoc,!0);}else{if(!u)throw new Error("try statement without catch or finally");if(this.prev<i.finallyLoc)return handle(i.finallyLoc);}}}},abrupt:function(t,e){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break;}}i&&("break"===t||"continue"===t)&&i.tryLoc<=e&&e<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=t,a.arg=e,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a);},complete:function(t,e){if("throw"===t.type)throw t.arg;return"break"===t.type||"continue"===t.type?this.next=t.arg:"return"===t.type?(this.rval=this.arg=t.arg,this.method="return",this.next="end"):"normal"===t.type&&e&&(this.next=e),y;},finish:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),resetTryEntry(r),y;}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var o=n.arg;resetTryEntry(r);}return o;}}throw new Error("illegal catch attempt");},delegateYield:function(e,r,n){return this.delegate={iterator:values(e),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=t),y;}},e;}function asyncGeneratorStep(gen,resolve,reject,_next,_throw,key,arg){try{var info=gen[key](arg);var value=info.value;}catch(error){reject(error);return;}if(info.done){resolve(value);}else{Promise.resolve(value).then(_next,_throw);}}function _asyncToGenerator(fn){return function(){var self=this,args=arguments;return new Promise(function(resolve,reject){var gen=fn.apply(self,args);function _next(value){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"next",value);}function _throw(err){asyncGeneratorStep(gen,resolve,reject,_next,_throw,"throw",err);}_next(undefined);});};}function _classCallCheck(instance,Constructor){if(!(instance instanceof Constructor)){throw new TypeError("Cannot call a class as a function");}}function _defineProperties(target,props){for(var i=0;i<props.length;i++){var descriptor=props[i];descriptor.enumerable=descriptor.enumerable||false;descriptor.configurable=true;if("value"in descriptor)descriptor.writable=true;Object.defineProperty(target,_toPropertyKey(descriptor.key),descriptor);}}function _createClass(Constructor,protoProps,staticProps){if(protoProps)_defineProperties(Constructor.prototype,protoProps);if(staticProps)_defineProperties(Constructor,staticProps);Object.defineProperty(Constructor,"prototype",{writable:false});return Constructor;}function _toPropertyKey(arg){var key=_toPrimitive(arg,"string");return typeof key==="symbol"?key:String(key);}function _toPrimitive(input,hint){if(typeof input!=="object"||input===null)return input;var prim=input[Symbol.toPrimitive];if(prim!==undefined){var res=prim.call(input,hint||"default");if(typeof res!=="object")return res;throw new TypeError("@@toPrimitive must return a primitive value.");}return(hint==="string"?String:Number)(input);}function _get(){if(typeof Reflect!=="undefined"&&Reflect.get){_get=Reflect.get.bind();}else{_get=function _get(target,property,receiver){var base=_superPropBase(target,property);if(!base)return;var desc=Object.getOwnPropertyDescriptor(base,property);if(desc.get){return desc.get.call(arguments.length<3?target:receiver);}return desc.value;};}return _get.apply(this,arguments);}function _superPropBase(object,property){while(!Object.prototype.hasOwnProperty.call(object,property)){object=_getPrototypeOf(object);if(object===null)break;}return object;}function _inherits(subClass,superClass){if(typeof superClass!=="function"&&superClass!==null){throw new TypeError("Super expression must either be null or a function");}subClass.prototype=Object.create(superClass&&superClass.prototype,{constructor:{value:subClass,writable:true,configurable:true}});Object.defineProperty(subClass,"prototype",{writable:false});if(superClass)_setPrototypeOf(subClass,superClass);}function _setPrototypeOf(o,p){_setPrototypeOf=Object.setPrototypeOf?Object.setPrototypeOf.bind():function _setPrototypeOf(o,p){o.__proto__=p;return o;};return _setPrototypeOf(o,p);}function _createSuper(Derived){var hasNativeReflectConstruct=_isNativeReflectConstruct();return function _createSuperInternal(){var Super=_getPrototypeOf(Derived),result;if(hasNativeReflectConstruct){var NewTarget=_getPrototypeOf(this).constructor;result=Reflect.construct(Super,arguments,NewTarget);}else{result=Super.apply(this,arguments);}return _possibleConstructorReturn(this,result);};}function _possibleConstructorReturn(self,call){if(call&&(typeof call==="object"||typeof call==="function")){return call;}else if(call!==void 0){throw new TypeError("Derived constructors may only return object or undefined");}return _assertThisInitialized(self);}function _assertThisInitialized(self){if(self===void 0){throw new ReferenceError("this hasn't been initialised - super() hasn't been called");}return self;}function _isNativeReflectConstruct(){if(typeof Reflect==="undefined"||!Reflect.construct)return false;if(Reflect.construct.sham)return false;if(typeof Proxy==="function")return true;try{Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}));return true;}catch(e){return false;}}function _getPrototypeOf(o){_getPrototypeOf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function _getPrototypeOf(o){return o.__proto__||Object.getPrototypeOf(o);};return _getPrototypeOf(o);}return{setters:[function(_tslib){t=_tslib.__decorate;},function(_index001CjsJs){i=_index001CjsJs.x;},function(_litDecoratorsJs){s=_litDecoratorsJs.query;e=_litDecoratorsJs.state;o=_litDecoratorsJs.customElement;},function(_nileContentEditorCssCjsJs){h=_nileContentEditorCssCjsJs.s;},function(_litDirectivesClassMapJs){n=_litDirectivesClassMapJs.classMap;},function(_internalNileElementCjsJs){r=_internalNileElementCjsJs.N;},function(_internalWatchCjsJs){a=_internalWatchCjsJs.w;},function(_internalEnumCjsJs){l=_internalEnumCjsJs.K;},function(_litDirectivesLiveJs){p=_litDirectivesLiveJs.live;},function(_property002CjsJs){d=_property002CjsJs.n;},function(_lit){}],execute:function(){_export("N",c=/*#__PURE__*/function(_r){_inherits(c,_r);var _super=_createSuper(c);function c(){var _this;_classCallCheck(this,c);_this=_super.apply(this,arguments),_this.value="",_this.showLabel=!0,_this.labelText="",_this.type="text|text-area",_this.required=!0,_this.openDropdown=!1,_this.tagIdentifier="$",_this.filteredValue="",_this.helpText="",_this.readonly=!1,_this.errorMessage="",_this.error=!1,_this.noborder=!1;return _this;}_createClass(c,[{key:"connectedCallback",value:function connectedCallback(){this.handleOutsideClick=this.handleOutsideClick.bind(this),this.handleClipboardEvent=this.handleClipboardEvent.bind(this),_get(_getPrototypeOf(c.prototype),"connectedCallback",this).call(this),this.emit("nile-init"),this.addOpenListeners(),this.setInitialValues();}},{key:"setInitialValues",value:function setInitialValues(){var _this2=this;this.updateComplete.then(function(t){t&&_this2.value&&(_this2.contentEditor.innerHTML=_this2.generateHTMLTagsWithValues(_this2.value));});}},{key:"addOpenListeners",value:function addOpenListeners(){this.addEventListener("click",this.handleOutsideClick),this.addEventListener("cut",this.handleClipboardEvent),this.addEventListener("copy",this.handleClipboardEvent),this.addEventListener("paste",this.handleClipboardEvent);}},{key:"removeOpenListeners",value:function removeOpenListeners(){this.removeEventListener("click",this.handleOutsideClick),this.removeEventListener("cut",this.handleClipboardEvent),this.removeEventListener("copy",this.handleClipboardEvent),this.removeEventListener("paste",this.handleClipboardEvent);}},{key:"handleClipboardEvent",value:function(){var _handleClipboardEvent=_asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(t){var _window,_this3=this;var i,_s;return _regeneratorRuntime().wrap(function _callee$(_context2){while(1)switch(_context2.prev=_context2.next){case 0:i=(_window=window)===null||_window===void 0||(_window=_window.getSelection())===null||_window===void 0?void 0:_window.toString();_context2.t0=t.type;_context2.next=_context2.t0==="cut"?4:_context2.t0==="copy"?4:_context2.t0==="paste"?10:17;break;case 4:_context2.t1=i;if(!_context2.t1){_context2.next=8;break;}_context2.next=8;return navigator.clipboard.writeText(i);case 8:document.execCommand(t.type);return _context2.abrupt("break",17);case 10:t.preventDefault();_s="";_context2.next=14;return navigator.clipboard.readText();case 14:_s=_context2.sent;_s=_s.replace(/<(|\/)(html|body|meta|span)[^>]*?>/gi,"").trim();document.execCommand("insertText",!1,_s);case 17:setTimeout(function(){_this3.emitInputChange();});case 18:case"end":return _context2.stop();}},_callee);}));function handleClipboardEvent(_x){return _handleClipboardEvent.apply(this,arguments);}return handleClipboardEvent;}()},{key:"toggleDropdown",value:function toggleDropdown(t){this.openDropdown=t;}},{key:"handleOutsideClick",value:function handleOutsideClick(t){t&&t.target&&this.toggleDropdown(!1);}},{key:"handleTypeChange",value:function handleTypeChange(){this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value);}},{key:"disconnectedCallback",value:function disconnectedCallback(){_get(_getPrototypeOf(c.prototype),"disconnectedCallback",this).call(this),this.removeOpenListeners(),this.emit("nile-destroy");}},{key:"handlekeyDown",value:function handlekeyDown(t){var _this4=this;if(t.code!==l.ENTER||"text"!==this.type){if(![l.CUT,l.COPY,l.PASTE].includes(t.code)||!t.ctrlKey&&!t.metaKey){var _document;if(t.code===l.ARROW_RIGHT&&(this.contentEditor.focus(),document.execCommand("selectAll",!1,void 0),(_document=document)!==null&&_document!==void 0&&(_document=_document.getSelection())!==null&&_document!==void 0&&_document.collapseToEnd()),t.code===l.ESCAPE)return t.preventDefault(),void this.toggleDropdown(!1);setTimeout(function(){var t=_this4.contentEditor.innerText;_this4.emitInputChange(),t.includes(_this4.tagIdentifier)?(_this4.insertNodes(_this4.contentEditor,_this4.contentEditor.childNodes),_this4.filterOptions(),_this4.toggleDropdown(!0)):_this4.toggleDropdown(!1);},10);}}else t.preventDefault();}},{key:"filterOptions",value:function filterOptions(){var _this5=this;this.filteredOptions=this.options,this.filteredValue=this.filteredValue.trim(),this.options.length&&this.filteredValue?this.filteredOptions=this.options.filter(function(t){return t.includes(_this5.filteredValue);}):this.filteredOptions=this.options;}},{key:"generateValuesFromHTMLTags",value:function generateValuesFromHTMLTags(t){return t.replace(/<span class="chips(?: chip-error)?" contenteditable="false">(.*?)<\/span>/g,function(t,i){return"{{"+i+"}}";});}},{key:"generateHTMLTagsWithValues",value:function generateHTMLTagsWithValues(t){var _this6=this;return t.replace(/{{(.*?)}}/g,function(t,i){return _this6.options.includes(i)?'<span class="chips" contenteditable="false">'+i+"</span>":_this6.setError(i);});}},{key:"setError",value:function setError(t){return this.error=!0,'<span class="chips chip-error" contenteditable="false">'+t+"</span>";}},{key:"emitInputChange",value:function emitInputChange(){if(this.contentEditor){var _t=this.contentEditor.innerHTML;""!==this.contentEditor.innerText&&(_t=this.generateValuesFromHTMLTags(_t)),_t=_t.replace(/ /g," "),_t=_t.replace("<br>",""),this.emit("nile-change",{value:this.generateValuesFromHTMLTags(_t)});}}},{key:"insertNodes",value:function insertNodes(t,i,s){var _this7=this;_toConsumableArray(i).forEach(function(i,e){var _i$nodeValue,_i$nodeValue2,_t$childNodes$e;if(i.hasChildNodes())s?_this7.insertNodes(i,i.childNodes,s):_this7.insertNodes(i,i.childNodes);else if((_i$nodeValue=i.nodeValue)!==null&&_i$nodeValue!==void 0&&_i$nodeValue.includes(_this7.tagIdentifier))return s&&(t.childNodes[e].nodeValue=(_i$nodeValue2=i.nodeValue)===null||_i$nodeValue2===void 0?void 0:_i$nodeValue2.replace(_this7.tagIdentifier+_this7.filteredValue,""),t.childNodes[e].after(s)),void(_this7.filteredValue=(t===null||t===void 0||(_t$childNodes$e=t.childNodes[e])===null||_t$childNodes$e===void 0||(_t$childNodes$e=_t$childNodes$e.nodeValue)===null||_t$childNodes$e===void 0?void 0:_t$childNodes$e.split(_this7.tagIdentifier).slice(1).join())||"");});}},{key:"handleOptions",value:function handleOptions(t){this.toggleDropdown(!1);var i=document.createElement("span");i.setAttribute("class","chips"),i.setAttribute("contentEditable","false"),i.innerText=t,this.insertNodes(this.contentEditor,this.contentEditor.childNodes,i),this.filteredOptions=this.options,this.filteredValue="",this.emitInputChange();}},{key:"renderAutoOptions",value:function renderAutoOptions(){var _this8=this;return i(_templateObject||(_templateObject=_taggedTemplateLiteral(["<div\n class=\"","\"\n >\n ","\n </div>"])),n({"nile-options-container":!0,"dropdown-position":"text-area"===this.type}),this.filteredOptions&&this.filteredOptions.map(function(t){return i(_templateObject2||(_templateObject2=_taggedTemplateLiteral([" <nile-option\n .value=\"","\"\n @click=\"","\"\n >","\n </nile-option>"])),t,function(i){_this8.handleOptions(t);},t);}));}},{key:"render",value:function render(){var t=!!this.helpText,s=!!this.error,e=!!this.errorMessage,o=!!this.readonly,h=!!this.noborder,r=this.type;return i(_templateObject3||(_templateObject3=_taggedTemplateLiteral(["\n <nile-popup\n .active=\"","\"\n sync=\"width\"\n strategy=\"fixed\"\n placement=\"bottom\"\n class=","\n >\n <div class=\"content-editable-wrapper\" slot=\"anchor\">\n ","\n <div\n contenteditable=\"","\"\n spellcheck=\"false\"\n class=","\n @keydown=","\n ></div>\n ","\n ","\n </div>\n ","\n </nile-popup>\n "])),p(this.openDropdown),n({dropdown:!0,"dropdown--open":!0,popup:!0}),this.showLabel&&this.labelText?i(_templateObject4||(_templateObject4=_taggedTemplateLiteral(["<label class=\"ods-label\">"," </label> ",""])),this.labelText,this.required?i(_templateObject5||(_templateObject5=_taggedTemplateLiteral(["<span class=\"asterik\">*</span>"]))):""):"",!o,n({"content-editable-input":!0,error:s||e,"read-only":o,"no-border":h,"text-area":"text-area"===r}),this.handlekeyDown,t?i(_templateObject6||(_templateObject6=_taggedTemplateLiteral(["\n <nile-form-help-text>","</nile-form-help-text>\n "])),this.helpText):"",e?i(_templateObject7||(_templateObject7=_taggedTemplateLiteral(["\n <nile-form-error-message\n >","</nile-form-error-message\n >\n "])),this.errorMessage):"",this.filteredOptions&&this.filteredOptions.length?this.renderAutoOptions():null);}}]);return c;}(r));c.styles=h,t([d()],c.prototype,"value",void 0),t([d()],c.prototype,"options",void 0),t([d()],c.prototype,"filteredOptions",void 0),t([d()],c.prototype,"showLabel",void 0),t([d()],c.prototype,"labelText",void 0),t([d()],c.prototype,"type",void 0),t([d()],c.prototype,"required",void 0),t([s(".content-editable-input")],c.prototype,"contentEditor",void 0),t([s(".nile-options-container")],c.prototype,"autoOptions",void 0),t([e()],c.prototype,"openDropdown",void 0),t([d({attribute:"help-text"})],c.prototype,"helpText",void 0),t([d({attribute:"readonly"})],c.prototype,"readonly",void 0),t([d({attribute:"error-message"})],c.prototype,"errorMessage",void 0),t([d({attribute:"error"})],c.prototype,"error",void 0),t([d({attribute:"noborder"})],c.prototype,"noborder",void 0),t([a(["type"],{waitUntilFirstUpdate:!0})],c.prototype,"handleTypeChange",null),_export("N",c=t([o("nile-content-editor")],c));}};});
|
2
2
|
//# sourceMappingURL=nile-content-editor.cjs.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"nile-content-editor.cjs.js","sources":["../../../src/nile-content-editor/nile-content-editor.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, property, TemplateResult } from 'lit-element';\nimport { customElement, query, state } from 'lit/decorators.js';\nimport { styles } from './nile-content-editor.css';\nimport { CSSResultGroup } from 'lit';\nimport { classMap } from 'lit/directives/class-map.js';\nimport NileElement from '../internal/nile-element';\nimport { watch } from '../internal/watch';\nimport { KeyCode } from '../internal/enum';\nimport { live } from 'lit/directives/live.js';\n\n/**\n * Nile icon component.\n *\n * @tag nile-attribute-expression\n *\n */\n@customElement('nile-content-editor')\nexport class NileContentEditor extends NileElement {\n /**\n * @summary Allows you to handle both input and dropdown selection\n\n * @dependency nile-option\n \n * @event nile-change - Emitted when the control's value changes. \n */\n\n @property() value: string = '';\n\n @property() options: Array<any>;\n\n @property() filteredOptions: Array<any>;\n\n @property() showLabel: boolean = true;\n\n @property() labelText = '';\n\n @property() type = 'text|text-area';\n\n @property() required: boolean = true;\n\n @query('.content-editable-input') contentEditor: HTMLInputElement;\n @query('.nile-options-container') autoOptions: HTMLInputElement;\n\n @state() openDropdown = false;\n\n tagIdentifier = '$';\n\n filteredValue = '';\n\n @property({ attribute: 'help-text' }) helpText = '';\n\n @property({ attribute: 'readonly' }) readonly = false;\n\n @property({ attribute: 'error-message' }) errorMessage = '';\n\n @property({ attribute: 'error' }) error = false;\n\n static styles: CSSResultGroup = styles;\n\n connectedCallback() {\n this.handleOutsideClick = this.handleOutsideClick.bind(this);\n this.handleClipboardEvent = this.handleClipboardEvent.bind(this);\n super.connectedCallback();\n this.emit('nile-init');\n this.addOpenListeners();\n this.setInitialValues();\n }\n\n setInitialValues() {\n this.updateComplete.then(res => {\n if (res && !!this.value)\n this.contentEditor.innerHTML = this.generateHTMLTagsWithValues(\n this.value\n );\n });\n }\n\n addOpenListeners() {\n window.addEventListener('click', this.handleOutsideClick);\n window.addEventListener('cut', this.handleClipboardEvent);\n window.addEventListener('copy', this.handleClipboardEvent);\n window.addEventListener('paste', this.handleClipboardEvent);\n }\n\n removeOpenListeners() {\n window.removeEventListener('click', this.handleOutsideClick);\n window.removeEventListener('cut', this.handleClipboardEvent);\n window.removeEventListener('copy', this.handleClipboardEvent);\n window.removeEventListener('paste', this.handleClipboardEvent);\n }\n\n async handleClipboardEvent(event: Event) {\n const selectedText = window?.getSelection()?.toString();\n switch (event.type) {\n case 'cut':\n case 'copy':\n if (!!selectedText) await navigator.clipboard.writeText(selectedText);\n document.execCommand(event.type);\n break;\n case 'paste':\n event.preventDefault();\n let pastedText = await navigator.clipboard.readText();\n pastedText = pastedText\n .replace(/<(|\\/)(html|body|meta|span)[^>]*?>/gi, '')\n .trim();\n document.execCommand('insertText', false, pastedText);\n break;\n default:\n break;\n }\n setTimeout(() => {\n this.emitInputChange();\n });\n }\n\n toggleDropdown(value: boolean) {\n this.openDropdown = value;\n }\n\n handleOutsideClick(event: Event) {\n if (event && event.target) {\n this.toggleDropdown(false);\n }\n }\n\n @watch('type', { waitUntilFirstUpdate: true })\n handleTypeChange() {\n this.contentEditor.innerHTML = this.generateHTMLTagsWithValues(this.value);\n }\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.removeOpenListeners();\n this.emit('nile-destroy');\n }\n\n private handlekeyDown(event: any) {\n if (event.code === KeyCode.ENTER && this.type === 'text') {\n event.preventDefault();\n return;\n }\n if (\n [KeyCode.CUT, KeyCode.COPY, KeyCode.PASTE].includes(event.code) &&\n (event.ctrlKey || event.metaKey)\n ) {\n return;\n }\n if (event.code === KeyCode.ESCAPE) {\n event.preventDefault();\n this.toggleDropdown(false);\n return;\n }\n setTimeout(() => {\n const value = this.contentEditor.innerText;\n this.emitInputChange();\n if (value.includes(this.tagIdentifier)) {\n this.insertNodes(this.contentEditor, this.contentEditor.childNodes);\n this.filterOptions();\n this.toggleDropdown(true);\n } else {\n this.toggleDropdown(false);\n }\n }, 10);\n }\n\n filterOptions() {\n this.filteredOptions = this.options;\n if (!!this.options.length && !!this.filteredValue) {\n this.filteredOptions = this.options.filter(item =>\n item.includes(this.filteredValue)\n );\n } else {\n this.filteredOptions = this.options;\n }\n }\n\n generateValuesFromHTMLTags(string: any): string {\n var pattern =\n /<span class=\"chips(?: chip-error)?\" contenteditable=\"false\">(.*?)<\\/span>/g;\n var result = string.replace(pattern, (match: any, option: any) => {\n return '{{' + option + '}}';\n });\n return result;\n }\n\n generateHTMLTagsWithValues(string: any): string {\n var pattern = /{{(.*?)}}/g;\n var result = string.replace(pattern, (match: any, option: any) => {\n return this.options.includes(option)\n ? '<span class=\"chips\" contenteditable=\"false\">' + option + '</span>'\n : this.setError(option);\n });\n return result;\n }\n\n setError(option: any) {\n this.error = true;\n return (\n '<span class=\"chips chip-error\" contenteditable=\"false\">' +\n option +\n '</span>'\n );\n }\n\n emitInputChange(): void {\n if (this.contentEditor) {\n let fieldValue = this.contentEditor.innerHTML;\n if (this.contentEditor.innerText !== '') {\n fieldValue = this.generateValuesFromHTMLTags(fieldValue);\n }\n fieldValue = fieldValue.replace(/ /g, ' ');\n fieldValue = fieldValue.replace('<br>', '');\n this.emit('nile-change', {\n value: this.generateValuesFromHTMLTags(fieldValue),\n });\n }\n }\n\n insertNodes(parentNode: Node, childNodes: NodeList, autoOptionsTag?: Node) {\n [...childNodes].forEach((node: Node, index: number) => {\n if (node.hasChildNodes()) {\n if (autoOptionsTag) {\n this.insertNodes(node, node.childNodes, autoOptionsTag);\n } else {\n this.insertNodes(node, node.childNodes);\n }\n } else {\n if (node.nodeValue?.includes(this.tagIdentifier)) {\n if (autoOptionsTag) {\n parentNode.childNodes[index].nodeValue = node.nodeValue?.replace(\n this.tagIdentifier + this.filteredValue,\n ''\n );\n parentNode.childNodes[index].after(autoOptionsTag);\n }\n this.filteredValue =\n parentNode?.childNodes[index]?.nodeValue\n ?.split(this.tagIdentifier)\n .slice(1)\n .join() || '';\n return;\n }\n }\n });\n }\n\n handleOptions(option: any): void {\n this.toggleDropdown(false);\n let autoOptionsTag = document.createElement('span');\n autoOptionsTag.setAttribute('class', 'chips');\n autoOptionsTag.setAttribute('contentEditable', 'false');\n autoOptionsTag.innerText = option;\n this.insertNodes(\n this.contentEditor,\n this.contentEditor.childNodes,\n autoOptionsTag\n );\n this.filteredOptions = this.options;\n this.filteredValue = '';\n this.emitInputChange();\n }\n\n public renderAutoOptions(): TemplateResult {\n return html`<div\n class=\"${classMap({\n 'nile-options-container': true,\n 'dropdown-position': this.type === 'text-area',\n })}\"\n >\n ${this.filteredOptions &&\n this.filteredOptions.map((option: any) => {\n return html` <nile-option\n .value=\"${option}\"\n @click=\"${(event: Event) => {\n this.handleOptions(option);\n }}\"\n >${option}\n </nile-option>`;\n })}\n </div>`;\n }\n\n public render(): TemplateResult {\n const hasHelpText = this.helpText ? true : false;\n const hasError = !!this.error;\n const hasErrorMessage = !!this.errorMessage;\n const readonly = !!this.readonly;\n const type = this.type;\n return html`\n <nile-popup\n .active=\"${live(this.openDropdown)}\"\n sync=\"width\"\n strategy=\"fixed\"\n placement=\"bottom\"\n class=${classMap({\n dropdown: true,\n 'dropdown--open': true,\n popup: true,\n })}\n >\n <div class=\"content-editable-wrapper\" slot=\"anchor\">\n ${this.showLabel && this.labelText\n ? html`<label class=\"ods-label\">${this.labelText} </label> ${this\n .required\n ? html`<span class=\"asterik\">*</span>`\n : ''}`\n : ''}\n <div\n contenteditable=\"${!readonly}\"\n spellcheck=\"false\"\n class=${classMap({\n 'content-editable-input': true,\n error: hasError || hasErrorMessage,\n 'read-only': readonly,\n 'text-area': type === 'text-area' ? true : false,\n })}\n @keydown=${this.handlekeyDown}\n ></div>\n ${hasHelpText\n ? html`\n <nile-form-help-text>${this.helpText}</nile-form-help-text>\n `\n : ``}\n ${hasErrorMessage\n ? html`\n <nile-form-error-message\n >${this.errorMessage}</nile-form-error-message\n >\n `\n : ``}\n </div>\n ${this.filteredOptions && !!this.filteredOptions.length\n ? this.renderAutoOptions()\n : null}\n </nile-popup>\n `;\n }\n}\n\nexport default NileContentEditor;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-content-editor': NileContentEditor;\n }\n}\n"],"names":["classMap","NileContentEditor","c","constructor","this","value","showLabel","labelText","type","required","openDropdown","tagIdentifier","filteredValue","helpText","readonly","errorMessage","error","_this","_createClass","key","connectedCallback","handleOutsideClick","bind","handleClipboardEvent","emit","addOpenListeners","setInitialValues","updateComplete","then","res","contentEditor","innerHTML","generateHTMLTagsWithValues","window","addEventListener","removeOpenListeners","removeEventListener","_handleClipboardEvent","_asyncToGenerator","_regeneratorRuntime","mark","_callee","event","selectedText","getSelection","toString","_context2","next","t0","t1","navigator","clipboard","writeText","document","execCommand","preventDefault","readText","pastedText","replace","trim","setTimeout","emitInputChange","stop","_x","apply","arguments","toggleDropdown","target","handleTypeChange","disconnectedCallback","super","handlekeyDown","code","KeyCode","ENTER","CUT","COPY","PASTE","includes","ctrlKey","metaKey","ESCAPE","innerText","insertNodes","childNodes","filterOptions","filteredOptions","options","length","filter","item","generateValuesFromHTMLTags","string","match","option","setError","fieldValue","parentNode","autoOptionsTag","_toConsumableArray","forEach","node","index","_i$nodeValue","_i$nodeValue2","_t$childNodes$e","hasChildNodes","nodeValue","after","split","slice","join","handleOptions","createElement","setAttribute","renderAutoOptions","html","_templateObject","_taggedTemplateLiteral","map","_templateObject2","render","hasHelpText","hasError","hasErrorMessage","_templateObject3","live","dropdown","popup","_templateObject4","_templateObject5","_templateObject6","_templateObject7","NileElement","styles","__decorate","property","prototype","query","state","attribute","watch","waitUntilFirstUpdate","_export","customElement"],"mappings":"uuDA+QeA,oJAAAA,mBAAAA,SAAAA,CAAAA,SAAAA,CAAAA,OAAAA,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OAAA,KA/GU9I,CAAiBsI,CAAAA,CAAAA,CAAA,CAD7BS,CAAAA,CAAc,wBACF/I"}
|
1
|
+
{"version":3,"file":"nile-content-editor.cjs.js","sources":["../../../src/nile-content-editor/nile-content-editor.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { html, property, TemplateResult } from 'lit-element';\nimport { customElement, query, state } from 'lit/decorators.js';\nimport { styles } from './nile-content-editor.css';\nimport { CSSResultGroup } from 'lit';\nimport { classMap } from 'lit/directives/class-map.js';\nimport NileElement from '../internal/nile-element';\nimport { watch } from '../internal/watch';\nimport { KeyCode } from '../internal/enum';\nimport { live } from 'lit/directives/live.js';\n\n/**\n * Nile icon component.\n *\n * @tag nile-attribute-expression\n *\n */\n@customElement('nile-content-editor')\nexport class NileContentEditor extends NileElement {\n /**\n * @summary Allows you to handle both input and dropdown selection\n\n * @dependency nile-option\n \n * @event nile-change - Emitted when the control's value changes. \n */\n\n @property() value: string = '';\n\n @property() options: Array<any>;\n\n @property() filteredOptions: Array<any>;\n\n @property() showLabel: boolean = true;\n\n @property() labelText = '';\n\n @property() type = 'text|text-area';\n\n @property() required: boolean = true;\n\n @query('.content-editable-input') contentEditor: HTMLInputElement;\n @query('.nile-options-container') autoOptions: HTMLInputElement;\n\n @state() openDropdown = false;\n\n tagIdentifier = '$';\n\n filteredValue = '';\n\n @property({ attribute: 'help-text' }) helpText = '';\n\n @property({ attribute: 'readonly' }) readonly = false;\n\n @property({ attribute: 'error-message' }) errorMessage = '';\n\n @property({ attribute: 'error' }) error = false;\n @property({ attribute: 'noborder' }) noborder = false;\n\n static styles: CSSResultGroup = styles;\n\n connectedCallback() {\n this.handleOutsideClick = this.handleOutsideClick.bind(this);\n this.handleClipboardEvent = this.handleClipboardEvent.bind(this);\n super.connectedCallback();\n this.emit('nile-init');\n this.addOpenListeners();\n this.setInitialValues();\n }\n\n setInitialValues() {\n this.updateComplete.then(res => {\n if (res && !!this.value)\n this.contentEditor.innerHTML = this.generateHTMLTagsWithValues(\n this.value\n );\n });\n }\n\n addOpenListeners() {\n this.addEventListener('click', this.handleOutsideClick);\n this.addEventListener('cut', this.handleClipboardEvent);\n this.addEventListener('copy', this.handleClipboardEvent);\n this.addEventListener('paste', this.handleClipboardEvent);\n }\n\n removeOpenListeners() {\n this.removeEventListener('click', this.handleOutsideClick);\n this.removeEventListener('cut', this.handleClipboardEvent);\n this.removeEventListener('copy', this.handleClipboardEvent);\n this.removeEventListener('paste', this.handleClipboardEvent);\n }\n\n async handleClipboardEvent(event: Event) {\n const selectedText = window?.getSelection()?.toString();\n switch (event.type) {\n case 'cut':\n case 'copy':\n if (!!selectedText) await navigator.clipboard.writeText(selectedText);\n document.execCommand(event.type);\n break;\n case 'paste':\n event.preventDefault();\n let pastedText = '';\n pastedText = await navigator.clipboard.readText();\n pastedText = pastedText\n .replace(/<(|\\/)(html|body|meta|span)[^>]*?>/gi, '')\n .trim();\n document.execCommand('insertText', false, pastedText);\n break;\n default:\n break;\n }\n setTimeout(() => {\n this.emitInputChange();\n });\n }\n\n toggleDropdown(value: boolean) {\n this.openDropdown = value;\n }\n\n handleOutsideClick(event: Event) {\n if (event && event.target) {\n this.toggleDropdown(false);\n }\n }\n\n @watch(['type'], { waitUntilFirstUpdate: true })\n handleTypeChange() {\n this.contentEditor.innerHTML = this.generateHTMLTagsWithValues(this.value);\n }\n\n disconnectedCallback(): void {\n super.disconnectedCallback();\n this.removeOpenListeners();\n this.emit('nile-destroy');\n }\n\n private handlekeyDown(event: any) {\n if (event.code === KeyCode.ENTER && this.type === 'text') {\n event.preventDefault();\n return;\n }\n if (\n [KeyCode.CUT, KeyCode.COPY, KeyCode.PASTE].includes(event.code) &&\n (event.ctrlKey || event.metaKey)\n ) {\n return;\n }\n\n if (event.code === KeyCode.ARROW_RIGHT) {\n this.contentEditor.focus();\n // select all the content in the element\n document.execCommand('selectAll', false, undefined);\n // collapse selection to the end\n\n document?.getSelection()?.collapseToEnd();\n }\n if (event.code === KeyCode.ESCAPE) {\n event.preventDefault();\n this.toggleDropdown(false);\n return;\n }\n setTimeout(() => {\n const value = this.contentEditor.innerText;\n this.emitInputChange();\n if (value.includes(this.tagIdentifier)) {\n this.insertNodes(this.contentEditor, this.contentEditor.childNodes);\n this.filterOptions();\n this.toggleDropdown(true);\n } else {\n this.toggleDropdown(false);\n }\n }, 10);\n }\n\n filterOptions() {\n this.filteredOptions = this.options;\n this.filteredValue = this.filteredValue.trim();\n if (!!this.options.length && !!this.filteredValue) {\n this.filteredOptions = this.options.filter(item =>\n item.includes(this.filteredValue)\n );\n } else {\n this.filteredOptions = this.options;\n }\n }\n\n generateValuesFromHTMLTags(string: any): string {\n var pattern =\n /<span class=\"chips(?: chip-error)?\" contenteditable=\"false\">(.*?)<\\/span>/g;\n var result = string.replace(pattern, (match: any, option: any) => {\n return '{{' + option + '}}';\n });\n return result;\n }\n\n generateHTMLTagsWithValues(string: any): string {\n var pattern = /{{(.*?)}}/g;\n var result = string.replace(pattern, (match: any, option: any) => {\n return this.options.includes(option)\n ? '<span class=\"chips\" contenteditable=\"false\">' + option + '</span>'\n : this.setError(option);\n });\n return result;\n }\n\n setError(option: any) {\n this.error = true;\n return (\n '<span class=\"chips chip-error\" contenteditable=\"false\">' +\n option +\n '</span>'\n );\n }\n\n emitInputChange(): void {\n if (this.contentEditor) {\n let fieldValue = this.contentEditor.innerHTML;\n if (this.contentEditor.innerText !== '') {\n fieldValue = this.generateValuesFromHTMLTags(fieldValue);\n }\n fieldValue = fieldValue.replace(/ /g, ' ');\n fieldValue = fieldValue.replace('<br>', '');\n this.emit('nile-change', {\n value: this.generateValuesFromHTMLTags(fieldValue),\n });\n }\n }\n\n insertNodes(parentNode: Node, childNodes: NodeList, autoOptionsTag?: Node) {\n [...childNodes].forEach((node: Node, index: number) => {\n if (node.hasChildNodes()) {\n if (autoOptionsTag) {\n this.insertNodes(node, node.childNodes, autoOptionsTag);\n } else {\n this.insertNodes(node, node.childNodes);\n }\n } else {\n if (node.nodeValue?.includes(this.tagIdentifier)) {\n if (autoOptionsTag) {\n parentNode.childNodes[index].nodeValue = node.nodeValue?.replace(\n this.tagIdentifier + this.filteredValue,\n ''\n );\n parentNode.childNodes[index].after(autoOptionsTag);\n }\n this.filteredValue =\n parentNode?.childNodes[index]?.nodeValue\n ?.split(this.tagIdentifier)\n .slice(1)\n .join() || '';\n return;\n }\n }\n });\n }\n\n handleOptions(option: any): void {\n this.toggleDropdown(false);\n let autoOptionsTag = document.createElement('span');\n autoOptionsTag.setAttribute('class', 'chips');\n autoOptionsTag.setAttribute('contentEditable', 'false');\n autoOptionsTag.innerText = option;\n this.insertNodes(\n this.contentEditor,\n this.contentEditor.childNodes,\n autoOptionsTag\n );\n this.filteredOptions = this.options;\n this.filteredValue = '';\n this.emitInputChange();\n }\n\n public renderAutoOptions(): TemplateResult {\n return html`<div\n class=\"${classMap({\n 'nile-options-container': true,\n 'dropdown-position': this.type === 'text-area',\n })}\"\n >\n ${this.filteredOptions &&\n this.filteredOptions.map((option: any) => {\n return html` <nile-option\n .value=\"${option}\"\n @click=\"${(event: Event) => {\n this.handleOptions(option);\n }}\"\n >${option}\n </nile-option>`;\n })}\n </div>`;\n }\n\n public render(): TemplateResult {\n const hasHelpText = this.helpText ? true : false;\n const hasError = !!this.error;\n const hasErrorMessage = !!this.errorMessage;\n const readonly = !!this.readonly;\n const noborder = !!this.noborder;\n const type = this.type;\n return html`\n <nile-popup\n .active=\"${live(this.openDropdown)}\"\n sync=\"width\"\n strategy=\"fixed\"\n placement=\"bottom\"\n class=${classMap({\n dropdown: true,\n 'dropdown--open': true,\n popup: true,\n })}\n >\n <div class=\"content-editable-wrapper\" slot=\"anchor\">\n ${this.showLabel && this.labelText\n ? html`<label class=\"ods-label\">${this.labelText} </label> ${this\n .required\n ? html`<span class=\"asterik\">*</span>`\n : ''}`\n : ''}\n <div\n contenteditable=\"${!readonly}\"\n spellcheck=\"false\"\n class=${classMap({\n 'content-editable-input': true,\n error: hasError || hasErrorMessage,\n 'read-only': readonly,\n 'no-border': noborder,\n 'text-area': type === 'text-area' ? true : false,\n })}\n @keydown=${this.handlekeyDown}\n ></div>\n ${hasHelpText\n ? html`\n <nile-form-help-text>${this.helpText}</nile-form-help-text>\n `\n : ``}\n ${hasErrorMessage\n ? html`\n <nile-form-error-message\n >${this.errorMessage}</nile-form-error-message\n >\n `\n : ``}\n </div>\n ${this.filteredOptions && !!this.filteredOptions.length\n ? this.renderAutoOptions()\n : null}\n </nile-popup>\n `;\n }\n}\n\nexport default NileContentEditor;\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'nile-content-editor': NileContentEditor;\n }\n}\n"],"names":["classMap","NileContentEditor","c","constructor","this","value","showLabel","labelText","type","required","openDropdown","tagIdentifier","filteredValue","helpText","readonly","errorMessage","error","noborder","_this","_createClass","key","connectedCallback","handleOutsideClick","bind","handleClipboardEvent","super","emit","addOpenListeners","setInitialValues","updateComplete","then","res","contentEditor","innerHTML","generateHTMLTagsWithValues","addEventListener","removeOpenListeners","removeEventListener","_handleClipboardEvent","_asyncToGenerator","_regeneratorRuntime","mark","_callee","event","_window","_this3","i","_s","wrap","_callee$","_context2","prev","next","selectedText","window","getSelection","toString","t0","navigator","clipboard","writeText","document","execCommand","preventDefault","pastedText","readText","replace","trim","setTimeout","emitInputChange","stop","_x","apply","arguments","toggleDropdown","target","handleTypeChange","disconnectedCallback","handlekeyDown","code","KeyCode","ENTER","CUT","COPY","PASTE","includes","ctrlKey","metaKey","_document","ARROW_RIGHT","focus","undefined","collapseToEnd","ESCAPE","innerText","insertNodes","childNodes","filterOptions","filteredOptions","options","length","filter","item","generateValuesFromHTMLTags","string","match","option","setError","fieldValue","parentNode","autoOptionsTag","_toConsumableArray","forEach","node","index","hasChildNodes","_i$nodeValue","nodeValue","after","split","slice","join","handleOptions","createElement","setAttribute","renderAutoOptions","html","_templateObject","_taggedTemplateLiteral","map","_templateObject2","render","hasHelpText","hasError","hasErrorMessage","_templateObject3","live","dropdown","popup","_templateObject4","_templateObject5","_templateObject6","_templateObject7","NileElement","styles","__decorate","property","prototype","query","state","attribute","watch","waitUntilFirstUpdate","customElement"],"mappings":"uuDA2ReA,oJAAAA,mBAAAA,SAAAA,CAAAA,SAAAA,CAAAA,OAAAA,CAAAA,CAAAA,CAAAA,IAAAA,CAAAA,CAAAA,MAAAA,CAAAA,SAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,cAAAA,CAAAA,CAAAA,CAAAA,MAAAA,CAAAA,cAAAA,WAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,EAAAA,CAAAA,CAAAA,CAAAA,EAAAA,CAAAA,CAAAA,KAAAA,GAAAA,CAAAA,oBAAAA,MAAAA,CAAAA,MAAAA,IAAAA,CAAAA,CAAAA,CAAAA,CAAAA,QAAAA,eAAAA,CAAAA,CAAAA,CAAAA,CAAAA,aAAAA,oBAAAA,CAAAA,CAAAA,CAAAA,CAAAA,WAAAA,2BAAAA,OAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,SAAAA,MAAAA,CAAAA,cAAAA,CAAAA,CAAAA,CAAAA,CAAAA,EAAAA,KAAAA,CAAAA,CAAAA,CAAAA,UAAAA,IAAAA,YAAAA,IAAAA,QAAAA,MAAAA,CAAAA,CAAAA,CAAAA,OAAAA,MAAAA,eAAAA,CAAAA,EAAAA,MAAAA,SAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,SAAAA,CAAAA,CAAAA,CAAAA,EAAAA,CAAAA,aAAAA,KAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,EAAAA,CAAAA,CAAAA,SAAAA,YAAAA,SAAAA,CAAAA,CAAAA,CAAAA,SAAAA,CAAAA,CAAAA,CAAAA,MAAAA,CAAAA,MAAAA,CAAAA,CAAAA,CAAAA,SAAAA,EAAAA,CAA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AAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAkJ,SAAA,CAAA,UAAA,CAAA,IAAA,EAEfF,CAAAA,CAAAA,CAAAA,CAAA,CAApCC,CAAS,CAAA,CAAEI,SAAW,CAAA,UAAA,CAAA,CAAA,CAAA,CAA+BrJ,CAAAkJ,CAAAA,SAAAA,CAAA,UAAA,CAAA,IAAA,EAAA,CAAA,CAEZF,EAAA,CAAzCC,CAAAA,CAAS,CAAEI,SAAAA,CAAW,eAAqCrJ,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAkJ,SAAA,CAAA,cAAA,CAAA,IAAA,IAE1BF,CAAA,CAAA,CAAjCC,CAAS,CAAA,CAAEI,SAAW,CAAA,OAAA,CAAA,CAAA,CAAA,CAAyBrJ,CAAAkJ,CAAAA,SAAAA,CAAA,YAAA,EACXF,CAAAA,CAAAA,CAAAA,CAAA,CAApCC,CAAAA,CAAS,CAAEI,SAAAA,CAAW,UAA+BrJ,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAkJ,UAAA,UAAA,CAAA,IAAA,EAAA,CAAA,CAwEtDF,CAAA,CAAA,CADCM,CAAM,CAAA,CAAC,MAAS,CAAA,CAAA,CAAEC,sBAAsB,CAGxCvJ,CAAAA,CAAAA,CAAAA,CAAAA,CAAAA,CAAAkJ,SAAA,CAAA,kBAAA,CAAA,kBAjHUlJ,CAAiBgJ,CAAAA,CAAAA,CAAA,CAD7BQ,CAAAA,CAAc,wBACFxJ"}
|
@@ -1,2 +1,2 @@
|
|
1
|
-
System.register(["../index-cd83c5c8.cjs.js"],function(_export,_context){"use strict";var o,_templateObject,e;function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}return{setters:[function(_index001CjsJs){o=_index001CjsJs.i;}],execute:function(){_export("s",e=o(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n :host {\n width: 100%;\n box-sizing: border-box;\n font-size: 14px;\n }\n\n .content-editable-wrapper {\n position: relative;\n width: 100%;\n box-sizing: border-box;\n }\n\n .dropdown-position {\n position: relative;\n bottom: 20px;\n }\n .content-editable-input {\n box-sizing: border-box;\n width: 100%;\n padding: 9px;\n border: 1px solid #c7ced4;\n border-radius: 4px;\n overflow-x: auto;\n overflow-anchor: none;\n scrollbar-width: none;\n -ms-overflow-style: none;\n cursor: text;\n white-space: nowrap;\n background-color: #ffffff;\n height: 38px;\n }\n .content-editable-input:focus {\n outline: none;\n }\n\n .error {\n border-color: #e5434d;\n }\n\n .read-only {\n cursor: not-allowed;\n }\n\n .chips {\n display: inline;\n background: #e5e9eb;\n color: #000;\n border-radius: 4px;\n padding: 6px;\n height: 24px;\n line-height: 10px;\n margin-left: 3px;\n letter-spacing: 0.2px;\n }\n\n .text-area {\n height: 120px;\n overflow: scroll;\n line-height: 26px;\n }\n\n .text-area .chips {\n padding: 4px 8px;\n }\n\n .chip-error {\n background: #f3a5aa;\n }\n .nile-options-container {\n box-sizing: border-box;\n background-color: #ffffff;\n border: 1px solid #c7ced4;\n overflow: auto;\n max-height: 150px;\n }\n\n label {\n display: inline-block;\n margin-bottom: 6px;\n font-family: 'colfax-medium';\n }\n\n .asterik {\n color: #e5434d;\n }\n"]))));}};});
|
1
|
+
System.register(["../index-cd83c5c8.cjs.js"],function(_export,_context){"use strict";var o,_templateObject,e;function _taggedTemplateLiteral(strings,raw){if(!raw){raw=strings.slice(0);}return Object.freeze(Object.defineProperties(strings,{raw:{value:Object.freeze(raw)}}));}return{setters:[function(_index001CjsJs){o=_index001CjsJs.i;}],execute:function(){_export("s",e=o(_templateObject||(_templateObject=_taggedTemplateLiteral(["\n :host {\n width: 100%;\n box-sizing: border-box;\n font-size: 14px;\n }\n\n .content-editable-wrapper {\n position: relative;\n width: 100%;\n box-sizing: border-box;\n }\n\n .dropdown-position {\n position: relative;\n bottom: 20px;\n }\n .content-editable-input {\n box-sizing: border-box;\n width: 100%;\n padding: 9px;\n border: 1px solid #c7ced4;\n border-radius: 4px;\n overflow-x: auto;\n overflow-anchor: none;\n scrollbar-width: none;\n -ms-overflow-style: none;\n cursor: text;\n white-space: nowrap;\n background-color: #ffffff;\n height: 38px;\n }\n .content-editable-input:focus {\n outline: none;\n }\n\n .error {\n border-color: #e5434d;\n }\n\n .read-only {\n cursor: not-allowed;\n }\n\n .chips {\n display: inline;\n background: #e5e9eb;\n color: #000;\n border-radius: 4px;\n padding: 6px;\n height: 24px;\n line-height: 10px;\n margin-left: 3px;\n letter-spacing: 0.2px;\n }\n\n .text-area {\n height: 120px;\n overflow: scroll;\n line-height: 26px;\n }\n\n .text-area .chips {\n padding: 4px 8px;\n }\n\n .chip-error {\n background: #f3a5aa;\n }\n .nile-options-container {\n box-sizing: border-box;\n background-color: #ffffff;\n border: 1px solid #c7ced4;\n overflow: auto;\n max-height: 150px;\n }\n\n label {\n display: inline-block;\n margin-bottom: 6px;\n font-family: 'colfax-medium';\n }\n\n .asterik {\n color: #e5434d;\n }\n\n .no-border {\n border: none;\n }\n"]))));}};});
|
2
2
|
//# sourceMappingURL=nile-content-editor.css.cjs.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"nile-content-editor.css.cjs.js","sources":["../../../src/nile-content-editor/nile-content-editor.css.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit-element';\n\n/**\n * AttributeExpression CSS\n */\nexport const styles = css`\n :host {\n width: 100%;\n box-sizing: border-box;\n font-size: 14px;\n }\n\n .content-editable-wrapper {\n position: relative;\n width: 100%;\n box-sizing: border-box;\n }\n\n .dropdown-position {\n position: relative;\n bottom: 20px;\n }\n .content-editable-input {\n box-sizing: border-box;\n width: 100%;\n padding: 9px;\n border: 1px solid #c7ced4;\n border-radius: 4px;\n overflow-x: auto;\n overflow-anchor: none;\n scrollbar-width: none;\n -ms-overflow-style: none;\n cursor: text;\n white-space: nowrap;\n background-color: #ffffff;\n height: 38px;\n }\n .content-editable-input:focus {\n outline: none;\n }\n\n .error {\n border-color: #e5434d;\n }\n\n .read-only {\n cursor: not-allowed;\n }\n\n .chips {\n display: inline;\n background: #e5e9eb;\n color: #000;\n border-radius: 4px;\n padding: 6px;\n height: 24px;\n line-height: 10px;\n margin-left: 3px;\n letter-spacing: 0.2px;\n }\n\n .text-area {\n height: 120px;\n overflow: scroll;\n line-height: 26px;\n }\n\n .text-area .chips {\n padding: 4px 8px;\n }\n\n .chip-error {\n background: #f3a5aa;\n }\n .nile-options-container {\n box-sizing: border-box;\n background-color: #ffffff;\n border: 1px solid #c7ced4;\n overflow: auto;\n max-height: 150px;\n }\n\n label {\n display: inline-block;\n margin-bottom: 6px;\n font-family: 'colfax-medium';\n }\n\n .asterik {\n color: #e5434d;\n }\n`;\n\nexport default [styles];\n"],"names":["styles","css","_templateObject","_taggedTemplateLiteral"],"mappings":"gXAYaA,CAAAA,CAASC,CAAG,CAAAC,eAAA,GAAAA,eAAA,CAAAC,sBAAA"}
|
1
|
+
{"version":3,"file":"nile-content-editor.css.cjs.js","sources":["../../../src/nile-content-editor/nile-content-editor.css.ts"],"sourcesContent":["/**\n * Copyright Aquera Inc 2023\n *\n * This source code is licensed under the BSD-3-Clause license found in the\n * LICENSE file in the root directory of this source tree.\n */\n\nimport { css } from 'lit-element';\n\n/**\n * AttributeExpression CSS\n */\nexport const styles = css`\n :host {\n width: 100%;\n box-sizing: border-box;\n font-size: 14px;\n }\n\n .content-editable-wrapper {\n position: relative;\n width: 100%;\n box-sizing: border-box;\n }\n\n .dropdown-position {\n position: relative;\n bottom: 20px;\n }\n .content-editable-input {\n box-sizing: border-box;\n width: 100%;\n padding: 9px;\n border: 1px solid #c7ced4;\n border-radius: 4px;\n overflow-x: auto;\n overflow-anchor: none;\n scrollbar-width: none;\n -ms-overflow-style: none;\n cursor: text;\n white-space: nowrap;\n background-color: #ffffff;\n height: 38px;\n }\n .content-editable-input:focus {\n outline: none;\n }\n\n .error {\n border-color: #e5434d;\n }\n\n .read-only {\n cursor: not-allowed;\n }\n\n .chips {\n display: inline;\n background: #e5e9eb;\n color: #000;\n border-radius: 4px;\n padding: 6px;\n height: 24px;\n line-height: 10px;\n margin-left: 3px;\n letter-spacing: 0.2px;\n }\n\n .text-area {\n height: 120px;\n overflow: scroll;\n line-height: 26px;\n }\n\n .text-area .chips {\n padding: 4px 8px;\n }\n\n .chip-error {\n background: #f3a5aa;\n }\n .nile-options-container {\n box-sizing: border-box;\n background-color: #ffffff;\n border: 1px solid #c7ced4;\n overflow: auto;\n max-height: 150px;\n }\n\n label {\n display: inline-block;\n margin-bottom: 6px;\n font-family: 'colfax-medium';\n }\n\n .asterik {\n color: #e5434d;\n }\n\n .no-border {\n border: none;\n }\n`;\n\nexport default [styles];\n"],"names":["styles","css","_templateObject","_taggedTemplateLiteral"],"mappings":"gXAYaA,CAAAA,CAASC,CAAG,CAAAC,eAAA,GAAAA,eAAA,CAAAC,sBAAA"}
|
@@ -1,25 +1,25 @@
|
|
1
|
-
import{__decorate as t}from"tslib";import{x as i}from"../index-cd2f9c12.esm.js";import{query as s,state as e,customElement as o}from"lit/decorators.js";import{s as
|
2
|
-
class="${
|
1
|
+
import{__decorate as t}from"tslib";import{x as i}from"../index-cd2f9c12.esm.js";import{query as s,state as e,customElement as o}from"lit/decorators.js";import{s as h}from"./nile-content-editor.css.esm.js";import{classMap as n}from"lit/directives/class-map.js";import{N as r}from"../internal/nile-element.esm.js";import{w as a}from"../internal/watch.esm.js";import{K as l}from"../internal/enum.esm.js";import{live as p}from"lit/directives/live.js";import{n as d}from"../property-09139d3c.esm.js";import"lit";let c=class extends r{constructor(){super(...arguments),this.value="",this.showLabel=!0,this.labelText="",this.type="text|text-area",this.required=!0,this.openDropdown=!1,this.tagIdentifier="$",this.filteredValue="",this.helpText="",this.readonly=!1,this.errorMessage="",this.error=!1,this.noborder=!1}connectedCallback(){this.handleOutsideClick=this.handleOutsideClick.bind(this),this.handleClipboardEvent=this.handleClipboardEvent.bind(this),super.connectedCallback(),this.emit("nile-init"),this.addOpenListeners(),this.setInitialValues()}setInitialValues(){this.updateComplete.then((t=>{t&&this.value&&(this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value))}))}addOpenListeners(){this.addEventListener("click",this.handleOutsideClick),this.addEventListener("cut",this.handleClipboardEvent),this.addEventListener("copy",this.handleClipboardEvent),this.addEventListener("paste",this.handleClipboardEvent)}removeOpenListeners(){this.removeEventListener("click",this.handleOutsideClick),this.removeEventListener("cut",this.handleClipboardEvent),this.removeEventListener("copy",this.handleClipboardEvent),this.removeEventListener("paste",this.handleClipboardEvent)}async handleClipboardEvent(t){const i=window?.getSelection()?.toString();switch(t.type){case"cut":case"copy":i&&await navigator.clipboard.writeText(i),document.execCommand(t.type);break;case"paste":t.preventDefault();let s="";s=await navigator.clipboard.readText(),s=s.replace(/<(|\/)(html|body|meta|span)[^>]*?>/gi,"").trim(),document.execCommand("insertText",!1,s)}setTimeout((()=>{this.emitInputChange()}))}toggleDropdown(t){this.openDropdown=t}handleOutsideClick(t){t&&t.target&&this.toggleDropdown(!1)}handleTypeChange(){this.contentEditor.innerHTML=this.generateHTMLTagsWithValues(this.value)}disconnectedCallback(){super.disconnectedCallback(),this.removeOpenListeners(),this.emit("nile-destroy")}handlekeyDown(t){if(t.code!==l.ENTER||"text"!==this.type){if(![l.CUT,l.COPY,l.PASTE].includes(t.code)||!t.ctrlKey&&!t.metaKey){if(t.code===l.ARROW_RIGHT&&(this.contentEditor.focus(),document.execCommand("selectAll",!1,void 0),document?.getSelection()?.collapseToEnd()),t.code===l.ESCAPE)return t.preventDefault(),void this.toggleDropdown(!1);setTimeout((()=>{const t=this.contentEditor.innerText;this.emitInputChange(),t.includes(this.tagIdentifier)?(this.insertNodes(this.contentEditor,this.contentEditor.childNodes),this.filterOptions(),this.toggleDropdown(!0)):this.toggleDropdown(!1)}),10)}}else t.preventDefault()}filterOptions(){this.filteredOptions=this.options,this.filteredValue=this.filteredValue.trim(),this.options.length&&this.filteredValue?this.filteredOptions=this.options.filter((t=>t.includes(this.filteredValue))):this.filteredOptions=this.options}generateValuesFromHTMLTags(t){return t.replace(/<span class="chips(?: chip-error)?" contenteditable="false">(.*?)<\/span>/g,((t,i)=>"{{"+i+"}}"))}generateHTMLTagsWithValues(t){return t.replace(/{{(.*?)}}/g,((t,i)=>this.options.includes(i)?'<span class="chips" contenteditable="false">'+i+"</span>":this.setError(i)))}setError(t){return this.error=!0,'<span class="chips chip-error" contenteditable="false">'+t+"</span>"}emitInputChange(){if(this.contentEditor){let t=this.contentEditor.innerHTML;""!==this.contentEditor.innerText&&(t=this.generateValuesFromHTMLTags(t)),t=t.replace(/ /g," "),t=t.replace("<br>",""),this.emit("nile-change",{value:this.generateValuesFromHTMLTags(t)})}}insertNodes(t,i,s){[...i].forEach(((i,e)=>{if(i.hasChildNodes())s?this.insertNodes(i,i.childNodes,s):this.insertNodes(i,i.childNodes);else if(i.nodeValue?.includes(this.tagIdentifier))return s&&(t.childNodes[e].nodeValue=i.nodeValue?.replace(this.tagIdentifier+this.filteredValue,""),t.childNodes[e].after(s)),void(this.filteredValue=t?.childNodes[e]?.nodeValue?.split(this.tagIdentifier).slice(1).join()||"")}))}handleOptions(t){this.toggleDropdown(!1);let i=document.createElement("span");i.setAttribute("class","chips"),i.setAttribute("contentEditable","false"),i.innerText=t,this.insertNodes(this.contentEditor,this.contentEditor.childNodes,i),this.filteredOptions=this.options,this.filteredValue="",this.emitInputChange()}renderAutoOptions(){return i`<div
|
2
|
+
class="${n({"nile-options-container":!0,"dropdown-position":"text-area"===this.type})}"
|
3
3
|
>
|
4
4
|
${this.filteredOptions&&this.filteredOptions.map((t=>i` <nile-option
|
5
5
|
.value="${t}"
|
6
6
|
@click="${i=>{this.handleOptions(t)}}"
|
7
7
|
>${t}
|
8
8
|
</nile-option>`))}
|
9
|
-
</div>`}render(){const t=!!this.helpText,s=!!this.error,e=!!this.errorMessage,o=!!this.readonly,
|
9
|
+
</div>`}render(){const t=!!this.helpText,s=!!this.error,e=!!this.errorMessage,o=!!this.readonly,h=!!this.noborder,r=this.type;return i`
|
10
10
|
<nile-popup
|
11
|
-
.active="${
|
11
|
+
.active="${p(this.openDropdown)}"
|
12
12
|
sync="width"
|
13
13
|
strategy="fixed"
|
14
14
|
placement="bottom"
|
15
|
-
class=${
|
15
|
+
class=${n({dropdown:!0,"dropdown--open":!0,popup:!0})}
|
16
16
|
>
|
17
17
|
<div class="content-editable-wrapper" slot="anchor">
|
18
18
|
${this.showLabel&&this.labelText?i`<label class="ods-label">${this.labelText} </label> ${this.required?i`<span class="asterik">*</span>`:""}`:""}
|
19
19
|
<div
|
20
20
|
contenteditable="${!o}"
|
21
21
|
spellcheck="false"
|
22
|
-
class=${
|
22
|
+
class=${n({"content-editable-input":!0,error:s||e,"read-only":o,"no-border":h,"text-area":"text-area"===r})}
|
23
23
|
@keydown=${this.handlekeyDown}
|
24
24
|
></div>
|
25
25
|
${t?i`
|
@@ -33,4 +33,4 @@ import{__decorate as t}from"tslib";import{x as i}from"../index-cd2f9c12.esm.js";
|
|
33
33
|
</div>
|
34
34
|
${this.filteredOptions&&this.filteredOptions.length?this.renderAutoOptions():null}
|
35
35
|
</nile-popup>
|
36
|
-
`}};c.styles=
|
36
|
+
`}};c.styles=h,t([d()],c.prototype,"value",void 0),t([d()],c.prototype,"options",void 0),t([d()],c.prototype,"filteredOptions",void 0),t([d()],c.prototype,"showLabel",void 0),t([d()],c.prototype,"labelText",void 0),t([d()],c.prototype,"type",void 0),t([d()],c.prototype,"required",void 0),t([s(".content-editable-input")],c.prototype,"contentEditor",void 0),t([s(".nile-options-container")],c.prototype,"autoOptions",void 0),t([e()],c.prototype,"openDropdown",void 0),t([d({attribute:"help-text"})],c.prototype,"helpText",void 0),t([d({attribute:"readonly"})],c.prototype,"readonly",void 0),t([d({attribute:"error-message"})],c.prototype,"errorMessage",void 0),t([d({attribute:"error"})],c.prototype,"error",void 0),t([d({attribute:"noborder"})],c.prototype,"noborder",void 0),t([a(["type"],{waitUntilFirstUpdate:!0})],c.prototype,"handleTypeChange",null),c=t([o("nile-content-editor")],c);export{c as N};
|