@oslokommune/punkt-elements 16.6.2 → 16.7.1
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/CHANGELOG.md +35 -0
- package/dist/{accordionitem-D7sWqDM_.cjs → accordionitem-D1Agl1bB.cjs} +1 -1
- package/dist/{accordionitem-Cj74XruR.js → accordionitem-ZlaXvjt5.js} +5 -5
- package/dist/{alert-ca_hFi-u.js → alert-BuAXrnKl.js} +6 -6
- package/dist/{alert-C95U_RZ0.cjs → alert-DFkFNTxh.cjs} +1 -1
- package/dist/{async-directive-CKx6pubI.js → async-directive-CMzWMlZ5.js} +1 -1
- package/dist/{async-directive-B158h3ba.cjs → async-directive-DoMuclel.cjs} +1 -1
- package/dist/{backlink-CQoNgoa-.cjs → backlink-EiAXUUZP.cjs} +1 -1
- package/dist/{backlink-C68H4Z3b.js → backlink-V4DAt17e.js} +3 -3
- package/dist/{button-BRovt5nm.js → button-DEyvt1LI.js} +5 -5
- package/dist/{button-BXN_JPaH.cjs → button-DYv5Dg4M.cjs} +1 -1
- package/dist/{calendar-43Y_6FD8.cjs → calendar-HIE9nxcc.cjs} +1 -1
- package/dist/{calendar-B5Xwl8mV.js → calendar-S63oreVW.js} +4 -4
- package/dist/{card-DfHo45CG.cjs → card-CyeH6l1c.cjs} +1 -1
- package/dist/{card-DvgCTN4B.js → card-DDiLfuO4.js} +7 -7
- package/dist/{checkbox-mmn3v9ry.cjs → checkbox-BLlwTABj.cjs} +1 -1
- package/dist/{checkbox-CbIUMIYt.js → checkbox-ejBUa5qQ.js} +4 -4
- package/dist/{class-map-3ADKve8g.js → class-map-CEnykyO_.js} +1 -1
- package/dist/{class-map-Bokp1SoS.cjs → class-map-CsENJXf1.cjs} +1 -1
- package/dist/{combobox-CwW0md6G.js → combobox-BmxSecfE.js} +13 -13
- package/dist/{combobox-TKL44xnV.cjs → combobox-Hb2V-fPX.cjs} +1 -1
- package/dist/{consent-CgS1L1xF.js → consent-iXyx5v6J.js} +3 -3
- package/dist/{consent-CIhFwuFO.cjs → consent-ruWAEVXW.cjs} +1 -1
- package/dist/{datepicker-qRWWzmbo.js → datepicker-CZl7b8Na.js} +12 -12
- package/dist/{datepicker-oN9L0Wnm.cjs → datepicker-D2H7U6MS.cjs} +1 -1
- package/dist/{directive-helpers-B3Vpl3xV.cjs → directive-helpers-BP2WOx60.cjs} +1 -1
- package/dist/{directive-helpers-CyPtA1_i.js → directive-helpers-rm-28gIj.js} +1 -1
- package/dist/{element-CV9utnHJ.js → element-CPpT3rFQ.js} +68 -67
- package/dist/{element-CMTfByxQ.cjs → element-gR_VtSiD.cjs} +6 -6
- package/dist/{element-with-slot-1djk8KXi.js → element-with-slot-Dqk6-TRR.js} +2 -2
- package/dist/{element-with-slot-yT8k1Z37.cjs → element-with-slot-ZX-up7jO.cjs} +1 -1
- package/dist/{heading-D9R5UBcv.js → heading-CKt7cVn7.js} +1 -1
- package/dist/{heading-B0XRE0lq.cjs → heading-Cvz8m1xL.cjs} +1 -1
- package/dist/{helptext-B366oeR9.cjs → helptext-5Mzp65-F.cjs} +1 -1
- package/dist/{helptext-DepcDYFV.js → helptext-jIoWRcCF.js} +5 -5
- package/dist/{icon-D0IQAVwS.js → icon-BlKA8YuW.js} +1 -1
- package/dist/{icon-Dj0oZZSa.cjs → icon-Bqj9oBbl.cjs} +1 -1
- package/dist/{if-defined-rXcLNTzN.js → if-defined-B0krMLad.js} +1 -1
- package/dist/{if-defined-hKKmbsI8.cjs → if-defined-BOW3ODSj.cjs} +1 -1
- package/dist/index.d.ts +92 -0
- package/dist/{input-element-n5U38pZ1.js → input-element-8nLwuQS4.js} +3 -3
- package/dist/{input-element-Xe9FTi2a.cjs → input-element-DdVhUvva.cjs} +1 -1
- package/dist/{input-wrapper-BdFdJU-k.cjs → input-wrapper-B0MkQ0IZ.cjs} +1 -1
- package/dist/{input-wrapper-B__6jW4U.js → input-wrapper-B2JpK016.js} +7 -7
- package/dist/{link-DLjXMpvi.cjs → link-R_lNhViF.cjs} +1 -1
- package/dist/{link-oGYvBLYL.js → link-Z_GizclR.js} +4 -4
- package/dist/{linkcard-BhVIc18n.js → linkcard-BlQvdB1a.js} +4 -4
- package/dist/{linkcard-C20WC6Nw.cjs → linkcard-C7HbSLlX.cjs} +1 -1
- package/dist/{listbox-CS4WQOuf.js → listbox-BQKDZvZn.js} +5 -5
- package/dist/{listbox-OAVh_U7u.cjs → listbox-CGgV9MAe.cjs} +1 -1
- package/dist/{loader-BHt9i5Xp.js → loader-Ci3CHU8k.js} +5 -5
- package/dist/{loader-DxAGCcNF.cjs → loader-e2gs_1xz.cjs} +1 -1
- package/dist/{messagebox-DkspcMQg.js → messagebox-Bf-XMlvW.js} +5 -5
- package/dist/{messagebox-B8LW0PSQ.cjs → messagebox-D67w71VX.cjs} +1 -1
- package/dist/{modal-mWn5pjs8.cjs → modal-CyvEkbfQ.cjs} +1 -1
- package/dist/{modal-D3u6ueP5.js → modal-DzGe1g8Z.js} +6 -6
- package/dist/pkt-accordion.cjs +1 -1
- package/dist/pkt-accordion.js +2 -2
- package/dist/pkt-alert.cjs +1 -1
- package/dist/pkt-alert.js +1 -1
- package/dist/pkt-backlink.cjs +1 -1
- package/dist/pkt-backlink.js +1 -1
- package/dist/pkt-breadcrumbs.cjs +1 -1
- package/dist/pkt-breadcrumbs.js +2 -2
- package/dist/pkt-button.cjs +1 -1
- package/dist/pkt-button.js +1 -1
- package/dist/pkt-calendar.cjs +1 -1
- package/dist/pkt-calendar.js +1 -1
- package/dist/pkt-card.cjs +1 -1
- package/dist/pkt-card.js +1 -1
- package/dist/pkt-checkbox.cjs +1 -1
- package/dist/pkt-checkbox.js +1 -1
- package/dist/pkt-combobox.cjs +1 -1
- package/dist/pkt-combobox.js +1 -1
- package/dist/pkt-consent.cjs +1 -1
- package/dist/pkt-consent.js +1 -1
- package/dist/pkt-datepicker.cjs +1 -1
- package/dist/pkt-datepicker.js +2 -2
- package/dist/pkt-header.cjs +1 -1
- package/dist/pkt-header.js +10 -10
- package/dist/pkt-heading.cjs +1 -1
- package/dist/pkt-heading.js +1 -1
- package/dist/pkt-helptext.cjs +1 -1
- package/dist/pkt-helptext.js +1 -1
- package/dist/pkt-icon.cjs +1 -1
- package/dist/pkt-icon.js +1 -1
- package/dist/pkt-index.cjs +1 -1
- package/dist/pkt-index.js +33 -31
- package/dist/pkt-input-wrapper.cjs +1 -1
- package/dist/pkt-input-wrapper.js +1 -1
- package/dist/pkt-link.cjs +1 -1
- package/dist/pkt-link.js +1 -1
- package/dist/pkt-linkcard.cjs +1 -1
- package/dist/pkt-linkcard.js +1 -1
- package/dist/pkt-listbox.cjs +1 -1
- package/dist/pkt-listbox.js +1 -1
- package/dist/pkt-loader.cjs +1 -1
- package/dist/pkt-loader.js +1 -1
- package/dist/pkt-messagebox.cjs +1 -1
- package/dist/pkt-messagebox.js +1 -1
- package/dist/pkt-modal.cjs +1 -1
- package/dist/pkt-modal.js +1 -1
- package/dist/{pkt-options-controller-DIeKSpWv.cjs → pkt-options-controller-5LXbEzuk.cjs} +1 -1
- package/dist/{pkt-options-controller-W4ITGQy9.js → pkt-options-controller-B5YalfCb.js} +1 -1
- package/dist/pkt-progressbar.cjs +1 -1
- package/dist/pkt-progressbar.js +2 -2
- package/dist/pkt-radiobutton.cjs +1 -1
- package/dist/pkt-radiobutton.js +1 -1
- package/dist/pkt-select.cjs +1 -1
- package/dist/pkt-select.js +1 -1
- package/dist/pkt-tabs.cjs +1 -1
- package/dist/pkt-tabs.js +2 -2
- package/dist/pkt-tag.cjs +1 -1
- package/dist/pkt-tag.js +1 -1
- package/dist/pkt-textarea.cjs +1 -1
- package/dist/pkt-textarea.js +1 -1
- package/dist/pkt-textinput.cjs +1 -1
- package/dist/pkt-textinput.js +1 -1
- package/dist/pkt-timepicker.cjs +191 -0
- package/dist/pkt-timepicker.js +558 -0
- package/dist/{progressbar-CcX-xiPI.js → progressbar-By7e0lEI.js} +5 -5
- package/dist/{progressbar-CC9Qr82_.cjs → progressbar-DsJ2B9Vm.cjs} +1 -1
- package/dist/{radiobutton-RW3h0tJj.js → radiobutton-6frNG9J_.js} +5 -5
- package/dist/{radiobutton-BUDQYAH-.cjs → radiobutton-Bv-BZ1Hw.cjs} +1 -1
- package/dist/{ref-DBGHvw2G.js → ref-Bg_Swj5w.js} +2 -2
- package/dist/{ref-DahIePMT.cjs → ref-CL-Xk9Xm.cjs} +1 -1
- package/dist/{repeat-DnlRNf63.js → repeat-BD8TKgJb.js} +2 -2
- package/dist/{repeat-C-FJ2vfy.cjs → repeat-Cfq8CDlf.cjs} +1 -1
- package/dist/{select-iXKeM3yz.js → select-CXZt1nHS.js} +8 -8
- package/dist/{select-PuEeK4jQ.cjs → select-WFhS4Vfp.cjs} +1 -1
- package/dist/{state-l4hGZdFJ.js → state-C_1EOo3D.js} +1 -1
- package/dist/{state-BNgpvY-A.cjs → state-Dg-53wQ8.cjs} +1 -1
- package/dist/{tabitem-DZSzwag2.js → tabitem-CB8wkKmv.js} +5 -5
- package/dist/{tabitem-Jenus4Qd.cjs → tabitem-DZpspU4Q.cjs} +1 -1
- package/dist/{tag-CIWBLpjv.js → tag-BuCpqaks.js} +6 -6
- package/dist/{tag-DeE1OpmF.cjs → tag-X6xdjR0N.cjs} +1 -1
- package/dist/{textarea-DR9lVDN-.js → textarea-Bzuymclz.js} +10 -10
- package/dist/{textarea-DtiYQWjy.cjs → textarea-DoeHJ7HR.cjs} +1 -1
- package/dist/{textinput-0Bttvt9V.js → textinput-9lHjs4ce.js} +9 -9
- package/dist/{textinput-cKrjvbJW.cjs → textinput-BNsLd26i.cjs} +1 -1
- package/dist/timepicker.d.ts +1 -0
- package/package.json +2 -3
- package/src/components/index.ts +3 -0
- package/src/components/timepicker/index.ts +2 -0
- package/src/components/timepicker/timepicker.test.ts +453 -0
- package/src/components/timepicker/timepicker.ts +794 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const o=require("./element-CMTfByxQ.cjs"),d=require("./if-defined-hKKmbsI8.cjs"),b=require("./ref-DahIePMT.cjs"),V=require("./class-map-Bokp1SoS.cjs"),S=require("./repeat-C-FJ2vfy.cjs"),u=require("./listbox-OAVh_U7u.cjs"),R=require("./element-with-slot-yT8k1Z37.cjs"),v=require("./state-BNgpvY-A.cjs"),w=require("./input-element-Xe9FTi2a.cjs"),C=require("./pkt-options-controller-DIeKSpWv.cjs");require("./input-wrapper-BdFdJU-k.cjs");require("./icon-Dj0oZZSa.cjs");require("./tag-DeE1OpmF.cjs");const F=(a,t,e)=>{switch(a){case",":return e?"addValue":null;case"Enter":return"addValue";case"Tab":case"ArrowDown":return t?null:"focusListbox";case"Escape":return"closeOptions";default:return null}},M=(a,t,e,s,i)=>{if(!a)return{action:"none",value:null};const l=u.findOptionByValue(e,a);return!t.includes(a)&&!l?s?{action:"addUserValue",value:a}:i?{action:"none",value:null}:{action:"removeValue",value:t[0]}:l&&!t.includes(l.value)?{action:"selectOption",value:l.value}:{action:"none",value:null}},U=(a,t,e,s,i)=>a.trim().toLowerCase()?{...u.getSearchInfoMessage(a,t,e,s),shouldRemoveValue:!1,shouldResetInput:!1}:{addValueText:null,userInfoMessage:"",shouldRemoveValue:!i&&!!t[0],shouldResetInput:!0},O=(a,t,e)=>{const s=u.findOptionByValue(t,a);return e==="label"&&(s!=null&&s.label)?s.label:a},m={markOptionSelected(a,t){if(t){for(const e of a)if(e.value===t){e.selected=!0;break}}},markOptionDeselected(a,t){if(t){for(const e of a)if(e.value===t){e.selected=!1;break}}},markAllSelected(a){for(const t of a)t.selected=!0},markAllDeselected(a){for(const t of a)t.selected=!1},removeUserAddedOptions(a){return a.filter(t=>!t.userAdded)}},A={parseOptionsFromSlot(a){const t=[];return a.forEach(e=>{if(!e.textContent&&!e.getAttribute("value"))return;const s={value:e.getAttribute("value")||e.textContent||"",label:e.textContent||e.getAttribute("value")||""};e.getAttribute("data-prefix")&&(s.prefix=e.getAttribute("data-prefix")||void 0),e.getAttribute("tagskincolor")&&(s.tagSkinColor=e.getAttribute("tagskincolor")),e.getAttribute("description")&&(s.description=e.getAttribute("description")||void 0),s.fulltext=u.buildFulltext(s),t.push(s)}),t}},k={syncOptionsWithValues(a,t){const e=[...t];return a.forEach(s=>{s.value&&!s.label&&(s.label=s.value),s.selected&&!e.includes(s.value)&&e.push(s.value),s.fulltext=u.buildFulltext(s),s.selected=s.selected||e.includes(s.value)}),{options:a,newValues:e}},mergeWithUserAdded(a,t){return[...t.filter(i=>(i==null?void 0:i.userAdded)&&i.selected).filter(i=>!(Array.isArray(a)?a:[]).some(l=>l.value===i.value)),...a]}},D={displayValueAs:{default:"label"}},q={props:D};var P=Object.defineProperty,r=(a,t,e,s)=>{for(var i=void 0,l=a.length-1,n;l>=0;l--)(n=a[l])&&(i=n(t,e,i)||i);return i&&P(t,e,i),i};class h extends w.PktInputElement{constructor(){super(),this.value="",this.options=[],this.defaultOptions=[],this.allowUserInput=!1,this.typeahead=!1,this.includeSearch=!1,this.searchPlaceholder="",this.multiple=!1,this.maxlength=null,this.displayValueAs=q.props.displayValueAs.default,this.tagPlacement=null,this.isOpen=!1,this._options=[],this._value=[],this._isOptionsOpen=!1,this._userInfoMessage="",this._addValueText=null,this._maxIsReached=!1,this._search="",this._inputFocus=!1,this._internalValueSync=!1,this._optionsFromSlot=!1,this._lastSlotGeneration=0,this._suppressNextOpen=!1,this.inputRef=b.e(),this.triggerRef=b.e(),this.listboxRef=b.e(),this.optionsController=new C.PktOptionsSlotController(this)}get _hasTextInput(){return this.typeahead||this.allowUserInput}get _selectionDescription(){if(!(!this.multiple||this._value.length===0))return`${this._value.length} valgt`}focusTrigger(){var t,e;this._hasTextInput?(t=this.inputRef.value)==null||t.focus():(e=this.triggerRef.value)==null||e.focus()}parseValue(){return Array.isArray(this.value)?this.multiple?this.value:this.value.length>0?[this.value[0]]:[]:this.value&&this.multiple?this.value.split(","):this.value?[this.value]:[]}updateMaxReached(){this._maxIsReached=u.isMaxSelectionReached(this._value.length,this.maxlength)}syncValueAndDispatch(t){const e=this._value,s=this.multiple?e.join(","):e[0]||"",i=Array.isArray(this.value)?this.value.join(","):String(this.value||"");if(s!==i&&(this._internalValueSync=!0,this.value=s),(t==null?void 0:t.join(","))!==e.join(",")){const l=this.multiple?[...e]:e[0]||"";this.onChange(l)}else e.length===0&&t&&t.length>0&&this.clearInputValue()}onChange(t){this.touched=!0,super.onChange(t)}valueChanged(){}}r([o.n({type:String,reflect:!0})],h.prototype,"value");r([o.n({type:Array})],h.prototype,"options");r([o.n({type:Array,attribute:"default-options"})],h.prototype,"defaultOptions");r([o.n({type:Boolean,attribute:"allow-user-input"})],h.prototype,"allowUserInput");r([o.n({type:Boolean})],h.prototype,"typeahead");r([o.n({type:Boolean,attribute:"include-search"})],h.prototype,"includeSearch");r([o.n({type:String,attribute:"search-placeholder"})],h.prototype,"searchPlaceholder");r([o.n({type:Boolean})],h.prototype,"multiple");r([o.n({type:Number})],h.prototype,"maxlength");r([o.n({type:String,attribute:"display-value-as"})],h.prototype,"displayValueAs");r([o.n({type:String,attribute:"tag-placement"})],h.prototype,"tagPlacement");r([o.n({type:Boolean,attribute:"open"})],h.prototype,"isOpen");r([v.r()],h.prototype,"_options");r([v.r()],h.prototype,"_value");r([v.r()],h.prototype,"_isOptionsOpen");r([v.r()],h.prototype,"_userInfoMessage");r([v.r()],h.prototype,"_addValueText");r([v.r()],h.prototype,"_maxIsReached");r([v.r()],h.prototype,"_search");r([v.r()],h.prototype,"_inputFocus");class B extends h{toggleValue(t){var $,I;if(this.disabled)return;this.touched=!0,this._userInfoMessage="",this._addValueText=null;const e=(($=u.findOptionByValue(this.options,t))==null?void 0:$.value)||null,s=this._value.includes(t||e||""),i=!!e,l=((I=this._options.find(T=>T.value===t))==null?void 0:I.disabled)||!1,n=!(t!=null&&t.trim()),p=!this.multiple,f=this.multiple,_=u.isMaxSelectionReached(this._value.length,this.maxlength);let c=!1,x=!0,g="",y="";l||(!i&&this.allowUserInput&&!n?(this.addNewUserValue(t),g="Ny verdi lagt til",c=f):!i&&!this.allowUserInput?(p&&this._value[0]&&this.removeValue(this._value[0]),x=!1,c=!0,g="Ingen treff i søket"):s?(this.removeValue(e),c=!0,p&&this._hasTextInput&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value="")):n&&p?(this.removeAllSelected(),c=!0):p?(this._value[0]&&this.removeSelected(this._value[0]),this.setSelected(e),c=!1):f&&!_?(this.setSelected(e),c=!0):f&&_?(g="Maks antall valg nådd",x=!1,y=t):(p&&this.removeAllSelected(),g="Ingen gyldig verdi valgt",x=!1,c=!0,y=t),this._isOptionsOpen=c,c||(p&&this._hasTextInput&&(this._suppressNextOpen=!0),window.setTimeout(()=>{this.focusTrigger()},0)),this._userInfoMessage=g,this._search=y||"",this.resetComboboxInput(x),f&&this.updateMaxReached())}setSelected(t){if(!this._value.includes(t)){if(this.multiple&&u.isMaxSelectionReached(this._value.length,this.maxlength)){this._userInfoMessage="Maks antall valg nådd";return}!this.multiple&&this.removeAllSelected(),this._value=t?[...this._value,t]:this._value,m.markOptionSelected(this._options,t),this.resetComboboxInput(!0)}}removeSelected(t){if(!t)return;this._value=this._value.filter(s=>s!==t);const e=u.findOptionByValue(this.options,t);e&&(m.markOptionDeselected(this.options,t),e.userAdded?(this._options=[...this._options.filter(s=>s.value!==t)],this.options=[...this.options.filter(s=>s.value!==t)]):this._options.some(s=>s.value===t)||(this._options=[...this._options,e]))}addAllOptions(){if(this.multiple){if(this.maxlength&&this._options.length>this.maxlength){this._userInfoMessage="For mange valgt";return}this._value=this._options.map(t=>t.value),m.markAllSelected(this._options),this.requestUpdate()}}removeAllSelected(){this._value=[],m.markAllDeselected(this._options),this._options=m.removeUserAddedOptions(this._options),this.requestUpdate()}addValue(){var e;const t=((e=this.inputRef.value)==null?void 0:e.value.trim())||"";if(this._search=t,t&&this._value.includes(t)){this.resetComboboxInput(!0),this._userInfoMessage="Verdien er allerede valgt";return}this.toggleValue(t)}removeValue(t){this._value=this.multiple?this._value.filter(e=>e!==t):[],this.removeSelected(t)}addNewUserValue(t){if(!t||t.trim()==="")return;if(!this.multiple)this._value[0]&&this.removeSelected(this._value[0]),this._value=[t];else if(!u.findOptionByValue(this.options,t)){if(u.isMaxSelectionReached(this._value.length,this.maxlength))return;this._value=[...this._value,t]}const e={value:t,label:t,userAdded:!0,selected:!0};this.options=[e,...this.options],this._options=[e,...this._options],this.resetComboboxInput(!0),this.multiple||(this._isOptionsOpen=!1,this._hasTextInput&&(this._suppressNextOpen=!0),window.setTimeout(()=>{this.focusTrigger()},0)),this.requestUpdate()}resetComboboxInput(t=!0){this._addValueText=null,this.inputRef.value&&this.inputRef.value.type!=="hidden"&&t&&(this._search="",this.multiple?this.inputRef.value.value="":(this.inputRef.value.value=this._value[0]?O(this._value[0],this.options,this.displayValueAs):"",this._userInfoMessage="")),this._options=[...this.options]}removeLastValue(t){if(this._value.length===0)return;t.preventDefault();const e=this._value[this._value.length-1];e&&this.removeSelected(e),this.updateMaxReached()}}class E extends B{handleInput(t){if(t.stopPropagation(),t.stopImmediatePropagation(),this.disabled)return;this.touched=!0;const e=t.target;if(this._search=e.value,this.checkForMatches(),this.typeahead)if(this._search){const{filtered:s,suggestion:i}=u.findTypeaheadMatches(this.options,this._search);this._options=s,t.inputType!=="deleteContentBackward"&&(i!=null&&i.label)&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(e.value=i.label,window.setTimeout(()=>e.setSelectionRange(this._search.length,e.value.length),0),e.selectionDirection="backward")}else this._options=[...this.options]}handleFocus(){if(!this.disabled){if(this._suppressNextOpen){this._suppressNextOpen=!1,this._inputFocus=!0,this.requestUpdate();return}!this.multiple&&this._value[0]&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value=O(this._value[0],this.options,this.displayValueAs)),this._inputFocus=!0,this._search="",this._options=[...this.options],this._isOptionsOpen=!0,this.onFocus(),this.requestUpdate()}}handleFocusOut(t){var i,l;if(this.disabled||!this._isOptionsOpen)return;const e=t.relatedTarget;((i=e==null?void 0:e.closest("pkt-combobox"))==null?void 0:i.id)===this.id||((l=t.target)==null?void 0:l.getAttribute("data-focusfix"))===this.id||e===this.inputRef.value||e===this.triggerRef.value||this.closeAndProcessInput()}closeAndProcessInput(){if(this._inputFocus=!1,this._addValueText=null,this._userInfoMessage="",this._search="",this.inputRef.value&&this.inputRef.value.type!=="hidden"){const t=this.inputRef.value.value;if(this.multiple){if(t!==""){const{action:e,value:s}=M(t,this._value,this.options,this.allowUserInput,this.multiple);switch(e){case"addUserValue":this.addNewUserValue(s);break;case"selectOption":this.setSelected(s);break;case"removeValue":this.removeValue(s);break}}}else if(!t)this._value[0]&&this.removeSelected(this._value[0]);else{const e=u.findOptionByValue(this.options,t);e&&e.value!==this._value[0]?(this._value[0]&&this.removeSelected(this._value[0]),this.setSelected(e.value)):!e&&this.allowUserInput&&(this._value[0]&&this.removeSelected(this._value[0]),this.addNewUserValue(t))}!this.multiple&&this._value[0]?this.inputRef.value.value=O(this._value[0],this.options,this.displayValueAs):this.inputRef.value.value=""}this._isOptionsOpen=!1,this.onBlur()}handleBlur(){this._inputFocus=!1,this.onBlur()}handleInputClick(t){var e,s;if(this.disabled){t.preventDefault(),t.stopImmediatePropagation();return}this._hasTextInput?((e=this.inputRef.value)==null||e.focus(),this.requestUpdate()):(t.stopImmediatePropagation(),t.preventDefault(),this._isOptionsOpen=!this._isOptionsOpen,this._isOptionsOpen&&((s=this.listboxRef.value)==null||s.focusFirstOrSelectedOption()))}handlePlaceholderClick(t){this.disabled||(t.stopPropagation(),this._hasTextInput&&this.inputRef.value?(this.inputRef.value.focus(),this._inputFocus=!0,this.requestUpdate()):(this._isOptionsOpen=!this._isOptionsOpen,this.requestUpdate()))}handleSelectOnlyKeydown(t){var e,s;if(!this.disabled)switch(t.key){case"Enter":case" ":case"ArrowDown":case"ArrowUp":t.preventDefault(),this._isOptionsOpen?this._isOptionsOpen=!1:(this._isOptionsOpen=!0,(e=this.listboxRef.value)==null||e.focusFirstOrSelectedOption());break;case"Escape":this._isOptionsOpen&&(t.preventDefault(),this._isOptionsOpen=!1);break;case"Home":case"End":t.preventDefault(),this._isOptionsOpen||(this._isOptionsOpen=!0),(s=this.listboxRef.value)==null||s.focusFirstOrSelectedOption();break;case"ArrowLeft":this.multiple&&this._value.length>0&&(t.preventDefault(),this.focusTag(this._value.length-1));break;case"Backspace":case"Delete":this.multiple&&this._value.length>0&&(t.preventDefault(),this.removeSelected(this._value[this._value.length-1]));break}}handleOptionToggled(t){this.toggleValue(t.detail)}handleSearch(t){t.stopPropagation(),this._search=t.detail.toLowerCase(),this.checkForMatches()}handleInputKeydown(t){var s,i,l;if(t.key==="Backspace"){const n=!((s=this.inputRef.value)!=null&&s.value);!this._search&&n&&this.multiple&&this._value.length>0&&this.removeLastValue(t);return}if(t.key==="ArrowLeft"&&this.multiple&&this._value.length>0){const n=this.inputRef.value;if(n&&n.selectionStart===0&&!n.value){t.preventDefault(),this.focusTag(this._value.length-1);return}}const e=F(t.key,t.shiftKey,this.multiple);if(e&&!(t.key==="Tab"&&!this._isOptionsOpen)){if(e==="focusListbox"&&t.key==="Tab"&&!((i=this.listboxRef.value)==null?void 0:i.querySelector('[role="option"]:not([data-disabled]), [data-type="new-option"]'))){this.closeAndProcessInput();return}switch(t.preventDefault(),e){case"addValue":this.addValue();break;case"focusListbox":(l=this.listboxRef.value)==null||l.focusFirstOrSelectedOption();break;case"closeOptions":this._isOptionsOpen=!1;break}}}handleTagRemove(t){this.removeSelected(t),this._hasTextInput&&this.inputRef.value&&(this._inputFocus=!0,this.inputRef.value.focus(),this.requestUpdate())}getInsideTags(){return Array.from(this.querySelectorAll(".pkt-combobox__input .pkt-combobox__tag-list pkt-tag"))}focusTag(t){var i;const e=this.getInsideTags();e.forEach((l,n)=>{l.buttonTabindex=n===t?0:-1});const s=(i=e[t])==null?void 0:i.querySelector("button");s==null||s.focus()}resetTagTabindices(){this.getInsideTags().forEach(e=>{e.buttonTabindex=-1})}handleTagKeydown(t,e){t.stopPropagation();const s=()=>{var i;this.resetTagTabindices(),this._hasTextInput&&this.inputRef.value?this.inputRef.value.focus():(i=this.triggerRef.value)==null||i.focus()};switch(t.key){case"ArrowLeft":t.preventDefault(),e>0&&this.focusTag(e-1);break;case"ArrowRight":t.preventDefault(),e<this._value.length-1?this.focusTag(e+1):s();break;case"Backspace":case"Delete":t.preventDefault();{const i=this._value[e],l=e>=this._value.length-1?e-1:e;this.removeSelected(i),l>=0?(this.requestUpdate(),this.updateComplete.then(()=>this.focusTag(l))):s()}break;case"Tab":this.resetTagTabindices();break;case"Escape":t.preventDefault(),s();break}}checkForMatches(){var s;const t=((s=this.inputRef.value)==null?void 0:s.value)||this._search||"",e=U(t,this._value,this.options,this.allowUserInput,this.multiple);if(e.shouldRemoveValue&&this.removeValue(this._value[0]),e.shouldResetInput){this.resetComboboxInput(!1);return}this._addValueText=e.addValueText,this._userInfoMessage=e.userInfoMessage}}var N=Object.getOwnPropertyDescriptor,L=(a,t,e,s)=>{for(var i=s>1?void 0:s?N(t,e):t,l=a.length-1,n;l>=0;l--)(n=a[l])&&(i=n(i)||i);return i};exports.PktCombobox=class extends E{constructor(){super(...arguments),this.handleBodyClick=t=>{this._isOptionsOpen&&!this.contains(t.target)&&this.closeAndProcessInput()}}connectedCallback(){var t,e;if(super.connectedCallback(),document==null||document.body.addEventListener("click",this.handleBodyClick),this._options=[],this.defaultOptions&&this.defaultOptions.length){const s=((t=this.options)==null?void 0:t.filter(i=>i.userAdded))||[];this.options=[...s,...JSON.parse(JSON.stringify(this.defaultOptions))],this._options=Array.isArray(this.options)?[...this.options]:[]}if((e=this.optionsController)!=null&&e.nodes&&this.optionsController.nodes.length){const s=A.parseOptionsFromSlot(this.optionsController.nodes);s.length&&(this.options=[...s],this._options=[...s],this._optionsFromSlot=!0,this._lastSlotGeneration=this.optionsController.generation)}}willUpdate(t){if(this._optionsFromSlot&&this.optionsController){const e=this.optionsController.generation;if(e!==this._lastSlotGeneration){this._lastSlotGeneration=e;const s=A.parseOptionsFromSlot(this.optionsController.nodes),i=this._options.filter(l=>l.userAdded);this.options=[...i,...s]}}super.willUpdate(t)}disconnectedCallback(){super.disconnectedCallback(),document==null||document.body.removeEventListener("click",this.handleBodyClick)}firstUpdated(t){this.defaultValue!==null&&!this.value&&(this.value=this.defaultValue),super.firstUpdated(t)}updated(t){t.has("isOpen")&&(this._isOptionsOpen=this.isOpen);const e=t.has("value"),s=t.has("_value");if(e&&this._internalValueSync)this._internalValueSync=!1,s&&this.syncValueAndDispatch(t.get("_value"));else if(e){const l=[...this._value],n=this.parseValue();n.join(",")!==this._value.join(",")&&(this._value=n),this.updateMaxReached(),this.syncValueAndDispatch(l)}else s&&this.syncValueAndDispatch(t.get("_value"));if(t.has("defaultOptions")&&this.defaultOptions.length){const l=(Array.isArray(this.options)?this.options:[]).filter(n=>n.userAdded)||[];this.options=[...l,...JSON.parse(JSON.stringify(this.defaultOptions))],this._options=Array.isArray(this.options)?[...this.options]:[]}if(t.has("options")){const l=t.get("options")||this._options||[],n=k.mergeWithUserAdded(this.options,l);this._options=n,n.length>this.options.length&&(this.options=n);const p=k.syncOptionsWithValues(this._options,this._value);if(this._options=p.options,p.newValues.length>this._value.length){const f=[...this._value];this._value=p.newValues,this.syncValueAndDispatch(f)}}if(t.has("_search")&&this.dispatchEvent(new CustomEvent("search",{detail:this._search,bubbles:!1})),!this._isOptionsOpen&&!this.multiple&&this._hasTextInput&&this.inputRef.value&&this.inputRef.value.type!=="hidden"){const l=this._value[0]?O(this._value[0],this.options,this.displayValueAs):"";this.inputRef.value.value!==l&&(this.inputRef.value.value=l)}super.updated(t)}formResetCallback(){this.touched=!1;const t=this.defaultValue||(this.multiple,"");this.value=t,this._value=this.parseValue(),this._options=this._options.filter(e=>!e.userAdded).map(e=>({...e,selected:this._value.includes(e.value)})),this.options=this.options.filter(e=>!e.userAdded).map(e=>({...e,selected:this._value.includes(e.value)})),this._search="",this._isOptionsOpen=!1,this._userInfoMessage="",this._addValueText=null,this._inputFocus=!1,this.updateMaxReached(),this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value=""),this.internals.setFormValue(""),this.internals.ariaInvalid="false",this.requestUpdate()}attributeChangedCallback(t,e,s){if(t==="options"){this._options=Array.isArray(this.options)?[...this.options]:[];const i=k.syncOptionsWithValues(this._options,this._value);this._options=i.options,i.newValues.length>this._value.length&&(this._value=i.newValues),this._search=""}super.attributeChangedCallback(t,e,s)}render(){return o.b`
|
|
1
|
+
"use strict";const o=require("./element-gR_VtSiD.cjs"),d=require("./if-defined-BOW3ODSj.cjs"),b=require("./ref-CL-Xk9Xm.cjs"),V=require("./class-map-CsENJXf1.cjs"),S=require("./repeat-Cfq8CDlf.cjs"),u=require("./listbox-CGgV9MAe.cjs"),R=require("./element-with-slot-ZX-up7jO.cjs"),v=require("./state-Dg-53wQ8.cjs"),w=require("./input-element-DdVhUvva.cjs"),C=require("./pkt-options-controller-5LXbEzuk.cjs");require("./input-wrapper-B0MkQ0IZ.cjs");require("./icon-Bqj9oBbl.cjs");require("./tag-X6xdjR0N.cjs");const F=(a,t,e)=>{switch(a){case",":return e?"addValue":null;case"Enter":return"addValue";case"Tab":case"ArrowDown":return t?null:"focusListbox";case"Escape":return"closeOptions";default:return null}},M=(a,t,e,s,i)=>{if(!a)return{action:"none",value:null};const l=u.findOptionByValue(e,a);return!t.includes(a)&&!l?s?{action:"addUserValue",value:a}:i?{action:"none",value:null}:{action:"removeValue",value:t[0]}:l&&!t.includes(l.value)?{action:"selectOption",value:l.value}:{action:"none",value:null}},U=(a,t,e,s,i)=>a.trim().toLowerCase()?{...u.getSearchInfoMessage(a,t,e,s),shouldRemoveValue:!1,shouldResetInput:!1}:{addValueText:null,userInfoMessage:"",shouldRemoveValue:!i&&!!t[0],shouldResetInput:!0},O=(a,t,e)=>{const s=u.findOptionByValue(t,a);return e==="label"&&(s!=null&&s.label)?s.label:a},m={markOptionSelected(a,t){if(t){for(const e of a)if(e.value===t){e.selected=!0;break}}},markOptionDeselected(a,t){if(t){for(const e of a)if(e.value===t){e.selected=!1;break}}},markAllSelected(a){for(const t of a)t.selected=!0},markAllDeselected(a){for(const t of a)t.selected=!1},removeUserAddedOptions(a){return a.filter(t=>!t.userAdded)}},A={parseOptionsFromSlot(a){const t=[];return a.forEach(e=>{if(!e.textContent&&!e.getAttribute("value"))return;const s={value:e.getAttribute("value")||e.textContent||"",label:e.textContent||e.getAttribute("value")||""};e.getAttribute("data-prefix")&&(s.prefix=e.getAttribute("data-prefix")||void 0),e.getAttribute("tagskincolor")&&(s.tagSkinColor=e.getAttribute("tagskincolor")),e.getAttribute("description")&&(s.description=e.getAttribute("description")||void 0),s.fulltext=u.buildFulltext(s),t.push(s)}),t}},k={syncOptionsWithValues(a,t){const e=[...t];return a.forEach(s=>{s.value&&!s.label&&(s.label=s.value),s.selected&&!e.includes(s.value)&&e.push(s.value),s.fulltext=u.buildFulltext(s),s.selected=s.selected||e.includes(s.value)}),{options:a,newValues:e}},mergeWithUserAdded(a,t){return[...t.filter(i=>(i==null?void 0:i.userAdded)&&i.selected).filter(i=>!(Array.isArray(a)?a:[]).some(l=>l.value===i.value)),...a]}},D={displayValueAs:{default:"label"}},q={props:D};var P=Object.defineProperty,r=(a,t,e,s)=>{for(var i=void 0,l=a.length-1,n;l>=0;l--)(n=a[l])&&(i=n(t,e,i)||i);return i&&P(t,e,i),i};class h extends w.PktInputElement{constructor(){super(),this.value="",this.options=[],this.defaultOptions=[],this.allowUserInput=!1,this.typeahead=!1,this.includeSearch=!1,this.searchPlaceholder="",this.multiple=!1,this.maxlength=null,this.displayValueAs=q.props.displayValueAs.default,this.tagPlacement=null,this.isOpen=!1,this._options=[],this._value=[],this._isOptionsOpen=!1,this._userInfoMessage="",this._addValueText=null,this._maxIsReached=!1,this._search="",this._inputFocus=!1,this._internalValueSync=!1,this._optionsFromSlot=!1,this._lastSlotGeneration=0,this._suppressNextOpen=!1,this.inputRef=b.e(),this.triggerRef=b.e(),this.listboxRef=b.e(),this.optionsController=new C.PktOptionsSlotController(this)}get _hasTextInput(){return this.typeahead||this.allowUserInput}get _selectionDescription(){if(!(!this.multiple||this._value.length===0))return`${this._value.length} valgt`}focusTrigger(){var t,e;this._hasTextInput?(t=this.inputRef.value)==null||t.focus():(e=this.triggerRef.value)==null||e.focus()}parseValue(){return Array.isArray(this.value)?this.multiple?this.value:this.value.length>0?[this.value[0]]:[]:this.value&&this.multiple?this.value.split(","):this.value?[this.value]:[]}updateMaxReached(){this._maxIsReached=u.isMaxSelectionReached(this._value.length,this.maxlength)}syncValueAndDispatch(t){const e=this._value,s=this.multiple?e.join(","):e[0]||"",i=Array.isArray(this.value)?this.value.join(","):String(this.value||"");if(s!==i&&(this._internalValueSync=!0,this.value=s),(t==null?void 0:t.join(","))!==e.join(",")){const l=this.multiple?[...e]:e[0]||"";this.onChange(l)}else e.length===0&&t&&t.length>0&&this.clearInputValue()}onChange(t){this.touched=!0,super.onChange(t)}valueChanged(){}}r([o.n({type:String,reflect:!0})],h.prototype,"value");r([o.n({type:Array})],h.prototype,"options");r([o.n({type:Array,attribute:"default-options"})],h.prototype,"defaultOptions");r([o.n({type:Boolean,attribute:"allow-user-input"})],h.prototype,"allowUserInput");r([o.n({type:Boolean})],h.prototype,"typeahead");r([o.n({type:Boolean,attribute:"include-search"})],h.prototype,"includeSearch");r([o.n({type:String,attribute:"search-placeholder"})],h.prototype,"searchPlaceholder");r([o.n({type:Boolean})],h.prototype,"multiple");r([o.n({type:Number})],h.prototype,"maxlength");r([o.n({type:String,attribute:"display-value-as"})],h.prototype,"displayValueAs");r([o.n({type:String,attribute:"tag-placement"})],h.prototype,"tagPlacement");r([o.n({type:Boolean,attribute:"open"})],h.prototype,"isOpen");r([v.r()],h.prototype,"_options");r([v.r()],h.prototype,"_value");r([v.r()],h.prototype,"_isOptionsOpen");r([v.r()],h.prototype,"_userInfoMessage");r([v.r()],h.prototype,"_addValueText");r([v.r()],h.prototype,"_maxIsReached");r([v.r()],h.prototype,"_search");r([v.r()],h.prototype,"_inputFocus");class B extends h{toggleValue(t){var $,I;if(this.disabled)return;this.touched=!0,this._userInfoMessage="",this._addValueText=null;const e=(($=u.findOptionByValue(this.options,t))==null?void 0:$.value)||null,s=this._value.includes(t||e||""),i=!!e,l=((I=this._options.find(T=>T.value===t))==null?void 0:I.disabled)||!1,n=!(t!=null&&t.trim()),p=!this.multiple,f=this.multiple,_=u.isMaxSelectionReached(this._value.length,this.maxlength);let c=!1,x=!0,g="",y="";l||(!i&&this.allowUserInput&&!n?(this.addNewUserValue(t),g="Ny verdi lagt til",c=f):!i&&!this.allowUserInput?(p&&this._value[0]&&this.removeValue(this._value[0]),x=!1,c=!0,g="Ingen treff i søket"):s?(this.removeValue(e),c=!0,p&&this._hasTextInput&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value="")):n&&p?(this.removeAllSelected(),c=!0):p?(this._value[0]&&this.removeSelected(this._value[0]),this.setSelected(e),c=!1):f&&!_?(this.setSelected(e),c=!0):f&&_?(g="Maks antall valg nådd",x=!1,y=t):(p&&this.removeAllSelected(),g="Ingen gyldig verdi valgt",x=!1,c=!0,y=t),this._isOptionsOpen=c,c||(p&&this._hasTextInput&&(this._suppressNextOpen=!0),window.setTimeout(()=>{this.focusTrigger()},0)),this._userInfoMessage=g,this._search=y||"",this.resetComboboxInput(x),f&&this.updateMaxReached())}setSelected(t){if(!this._value.includes(t)){if(this.multiple&&u.isMaxSelectionReached(this._value.length,this.maxlength)){this._userInfoMessage="Maks antall valg nådd";return}!this.multiple&&this.removeAllSelected(),this._value=t?[...this._value,t]:this._value,m.markOptionSelected(this._options,t),this.resetComboboxInput(!0)}}removeSelected(t){if(!t)return;this._value=this._value.filter(s=>s!==t);const e=u.findOptionByValue(this.options,t);e&&(m.markOptionDeselected(this.options,t),e.userAdded?(this._options=[...this._options.filter(s=>s.value!==t)],this.options=[...this.options.filter(s=>s.value!==t)]):this._options.some(s=>s.value===t)||(this._options=[...this._options,e]))}addAllOptions(){if(this.multiple){if(this.maxlength&&this._options.length>this.maxlength){this._userInfoMessage="For mange valgt";return}this._value=this._options.map(t=>t.value),m.markAllSelected(this._options),this.requestUpdate()}}removeAllSelected(){this._value=[],m.markAllDeselected(this._options),this._options=m.removeUserAddedOptions(this._options),this.requestUpdate()}addValue(){var e;const t=((e=this.inputRef.value)==null?void 0:e.value.trim())||"";if(this._search=t,t&&this._value.includes(t)){this.resetComboboxInput(!0),this._userInfoMessage="Verdien er allerede valgt";return}this.toggleValue(t)}removeValue(t){this._value=this.multiple?this._value.filter(e=>e!==t):[],this.removeSelected(t)}addNewUserValue(t){if(!t||t.trim()==="")return;if(!this.multiple)this._value[0]&&this.removeSelected(this._value[0]),this._value=[t];else if(!u.findOptionByValue(this.options,t)){if(u.isMaxSelectionReached(this._value.length,this.maxlength))return;this._value=[...this._value,t]}const e={value:t,label:t,userAdded:!0,selected:!0};this.options=[e,...this.options],this._options=[e,...this._options],this.resetComboboxInput(!0),this.multiple||(this._isOptionsOpen=!1,this._hasTextInput&&(this._suppressNextOpen=!0),window.setTimeout(()=>{this.focusTrigger()},0)),this.requestUpdate()}resetComboboxInput(t=!0){this._addValueText=null,this.inputRef.value&&this.inputRef.value.type!=="hidden"&&t&&(this._search="",this.multiple?this.inputRef.value.value="":(this.inputRef.value.value=this._value[0]?O(this._value[0],this.options,this.displayValueAs):"",this._userInfoMessage="")),this._options=[...this.options]}removeLastValue(t){if(this._value.length===0)return;t.preventDefault();const e=this._value[this._value.length-1];e&&this.removeSelected(e),this.updateMaxReached()}}class E extends B{handleInput(t){if(t.stopPropagation(),t.stopImmediatePropagation(),this.disabled)return;this.touched=!0;const e=t.target;if(this._search=e.value,this.checkForMatches(),this.typeahead)if(this._search){const{filtered:s,suggestion:i}=u.findTypeaheadMatches(this.options,this._search);this._options=s,t.inputType!=="deleteContentBackward"&&(i!=null&&i.label)&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(e.value=i.label,window.setTimeout(()=>e.setSelectionRange(this._search.length,e.value.length),0),e.selectionDirection="backward")}else this._options=[...this.options]}handleFocus(){if(!this.disabled){if(this._suppressNextOpen){this._suppressNextOpen=!1,this._inputFocus=!0,this.requestUpdate();return}!this.multiple&&this._value[0]&&this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value=O(this._value[0],this.options,this.displayValueAs)),this._inputFocus=!0,this._search="",this._options=[...this.options],this._isOptionsOpen=!0,this.onFocus(),this.requestUpdate()}}handleFocusOut(t){var i,l;if(this.disabled||!this._isOptionsOpen)return;const e=t.relatedTarget;((i=e==null?void 0:e.closest("pkt-combobox"))==null?void 0:i.id)===this.id||((l=t.target)==null?void 0:l.getAttribute("data-focusfix"))===this.id||e===this.inputRef.value||e===this.triggerRef.value||this.closeAndProcessInput()}closeAndProcessInput(){if(this._inputFocus=!1,this._addValueText=null,this._userInfoMessage="",this._search="",this.inputRef.value&&this.inputRef.value.type!=="hidden"){const t=this.inputRef.value.value;if(this.multiple){if(t!==""){const{action:e,value:s}=M(t,this._value,this.options,this.allowUserInput,this.multiple);switch(e){case"addUserValue":this.addNewUserValue(s);break;case"selectOption":this.setSelected(s);break;case"removeValue":this.removeValue(s);break}}}else if(!t)this._value[0]&&this.removeSelected(this._value[0]);else{const e=u.findOptionByValue(this.options,t);e&&e.value!==this._value[0]?(this._value[0]&&this.removeSelected(this._value[0]),this.setSelected(e.value)):!e&&this.allowUserInput&&(this._value[0]&&this.removeSelected(this._value[0]),this.addNewUserValue(t))}!this.multiple&&this._value[0]?this.inputRef.value.value=O(this._value[0],this.options,this.displayValueAs):this.inputRef.value.value=""}this._isOptionsOpen=!1,this.onBlur()}handleBlur(){this._inputFocus=!1,this.onBlur()}handleInputClick(t){var e,s;if(this.disabled){t.preventDefault(),t.stopImmediatePropagation();return}this._hasTextInput?((e=this.inputRef.value)==null||e.focus(),this.requestUpdate()):(t.stopImmediatePropagation(),t.preventDefault(),this._isOptionsOpen=!this._isOptionsOpen,this._isOptionsOpen&&((s=this.listboxRef.value)==null||s.focusFirstOrSelectedOption()))}handlePlaceholderClick(t){this.disabled||(t.stopPropagation(),this._hasTextInput&&this.inputRef.value?(this.inputRef.value.focus(),this._inputFocus=!0,this.requestUpdate()):(this._isOptionsOpen=!this._isOptionsOpen,this.requestUpdate()))}handleSelectOnlyKeydown(t){var e,s;if(!this.disabled)switch(t.key){case"Enter":case" ":case"ArrowDown":case"ArrowUp":t.preventDefault(),this._isOptionsOpen?this._isOptionsOpen=!1:(this._isOptionsOpen=!0,(e=this.listboxRef.value)==null||e.focusFirstOrSelectedOption());break;case"Escape":this._isOptionsOpen&&(t.preventDefault(),this._isOptionsOpen=!1);break;case"Home":case"End":t.preventDefault(),this._isOptionsOpen||(this._isOptionsOpen=!0),(s=this.listboxRef.value)==null||s.focusFirstOrSelectedOption();break;case"ArrowLeft":this.multiple&&this._value.length>0&&(t.preventDefault(),this.focusTag(this._value.length-1));break;case"Backspace":case"Delete":this.multiple&&this._value.length>0&&(t.preventDefault(),this.removeSelected(this._value[this._value.length-1]));break}}handleOptionToggled(t){this.toggleValue(t.detail)}handleSearch(t){t.stopPropagation(),this._search=t.detail.toLowerCase(),this.checkForMatches()}handleInputKeydown(t){var s,i,l;if(t.key==="Backspace"){const n=!((s=this.inputRef.value)!=null&&s.value);!this._search&&n&&this.multiple&&this._value.length>0&&this.removeLastValue(t);return}if(t.key==="ArrowLeft"&&this.multiple&&this._value.length>0){const n=this.inputRef.value;if(n&&n.selectionStart===0&&!n.value){t.preventDefault(),this.focusTag(this._value.length-1);return}}const e=F(t.key,t.shiftKey,this.multiple);if(e&&!(t.key==="Tab"&&!this._isOptionsOpen)){if(e==="focusListbox"&&t.key==="Tab"&&!((i=this.listboxRef.value)==null?void 0:i.querySelector('[role="option"]:not([data-disabled]), [data-type="new-option"]'))){this.closeAndProcessInput();return}switch(t.preventDefault(),e){case"addValue":this.addValue();break;case"focusListbox":(l=this.listboxRef.value)==null||l.focusFirstOrSelectedOption();break;case"closeOptions":this._isOptionsOpen=!1;break}}}handleTagRemove(t){this.removeSelected(t),this._hasTextInput&&this.inputRef.value&&(this._inputFocus=!0,this.inputRef.value.focus(),this.requestUpdate())}getInsideTags(){return Array.from(this.querySelectorAll(".pkt-combobox__input .pkt-combobox__tag-list pkt-tag"))}focusTag(t){var i;const e=this.getInsideTags();e.forEach((l,n)=>{l.buttonTabindex=n===t?0:-1});const s=(i=e[t])==null?void 0:i.querySelector("button");s==null||s.focus()}resetTagTabindices(){this.getInsideTags().forEach(e=>{e.buttonTabindex=-1})}handleTagKeydown(t,e){t.stopPropagation();const s=()=>{var i;this.resetTagTabindices(),this._hasTextInput&&this.inputRef.value?this.inputRef.value.focus():(i=this.triggerRef.value)==null||i.focus()};switch(t.key){case"ArrowLeft":t.preventDefault(),e>0&&this.focusTag(e-1);break;case"ArrowRight":t.preventDefault(),e<this._value.length-1?this.focusTag(e+1):s();break;case"Backspace":case"Delete":t.preventDefault();{const i=this._value[e],l=e>=this._value.length-1?e-1:e;this.removeSelected(i),l>=0?(this.requestUpdate(),this.updateComplete.then(()=>this.focusTag(l))):s()}break;case"Tab":this.resetTagTabindices();break;case"Escape":t.preventDefault(),s();break}}checkForMatches(){var s;const t=((s=this.inputRef.value)==null?void 0:s.value)||this._search||"",e=U(t,this._value,this.options,this.allowUserInput,this.multiple);if(e.shouldRemoveValue&&this.removeValue(this._value[0]),e.shouldResetInput){this.resetComboboxInput(!1);return}this._addValueText=e.addValueText,this._userInfoMessage=e.userInfoMessage}}var N=Object.getOwnPropertyDescriptor,L=(a,t,e,s)=>{for(var i=s>1?void 0:s?N(t,e):t,l=a.length-1,n;l>=0;l--)(n=a[l])&&(i=n(i)||i);return i};exports.PktCombobox=class extends E{constructor(){super(...arguments),this.handleBodyClick=t=>{this._isOptionsOpen&&!this.contains(t.target)&&this.closeAndProcessInput()}}connectedCallback(){var t,e;if(super.connectedCallback(),document==null||document.body.addEventListener("click",this.handleBodyClick),this._options=[],this.defaultOptions&&this.defaultOptions.length){const s=((t=this.options)==null?void 0:t.filter(i=>i.userAdded))||[];this.options=[...s,...JSON.parse(JSON.stringify(this.defaultOptions))],this._options=Array.isArray(this.options)?[...this.options]:[]}if((e=this.optionsController)!=null&&e.nodes&&this.optionsController.nodes.length){const s=A.parseOptionsFromSlot(this.optionsController.nodes);s.length&&(this.options=[...s],this._options=[...s],this._optionsFromSlot=!0,this._lastSlotGeneration=this.optionsController.generation)}}willUpdate(t){if(this._optionsFromSlot&&this.optionsController){const e=this.optionsController.generation;if(e!==this._lastSlotGeneration){this._lastSlotGeneration=e;const s=A.parseOptionsFromSlot(this.optionsController.nodes),i=this._options.filter(l=>l.userAdded);this.options=[...i,...s]}}super.willUpdate(t)}disconnectedCallback(){super.disconnectedCallback(),document==null||document.body.removeEventListener("click",this.handleBodyClick)}firstUpdated(t){this.defaultValue!==null&&!this.value&&(this.value=this.defaultValue),super.firstUpdated(t)}updated(t){t.has("isOpen")&&(this._isOptionsOpen=this.isOpen);const e=t.has("value"),s=t.has("_value");if(e&&this._internalValueSync)this._internalValueSync=!1,s&&this.syncValueAndDispatch(t.get("_value"));else if(e){const l=[...this._value],n=this.parseValue();n.join(",")!==this._value.join(",")&&(this._value=n),this.updateMaxReached(),this.syncValueAndDispatch(l)}else s&&this.syncValueAndDispatch(t.get("_value"));if(t.has("defaultOptions")&&this.defaultOptions.length){const l=(Array.isArray(this.options)?this.options:[]).filter(n=>n.userAdded)||[];this.options=[...l,...JSON.parse(JSON.stringify(this.defaultOptions))],this._options=Array.isArray(this.options)?[...this.options]:[]}if(t.has("options")){const l=t.get("options")||this._options||[],n=k.mergeWithUserAdded(this.options,l);this._options=n,n.length>this.options.length&&(this.options=n);const p=k.syncOptionsWithValues(this._options,this._value);if(this._options=p.options,p.newValues.length>this._value.length){const f=[...this._value];this._value=p.newValues,this.syncValueAndDispatch(f)}}if(t.has("_search")&&this.dispatchEvent(new CustomEvent("search",{detail:this._search,bubbles:!1})),!this._isOptionsOpen&&!this.multiple&&this._hasTextInput&&this.inputRef.value&&this.inputRef.value.type!=="hidden"){const l=this._value[0]?O(this._value[0],this.options,this.displayValueAs):"";this.inputRef.value.value!==l&&(this.inputRef.value.value=l)}super.updated(t)}formResetCallback(){this.touched=!1;const t=this.defaultValue||(this.multiple,"");this.value=t,this._value=this.parseValue(),this._options=this._options.filter(e=>!e.userAdded).map(e=>({...e,selected:this._value.includes(e.value)})),this.options=this.options.filter(e=>!e.userAdded).map(e=>({...e,selected:this._value.includes(e.value)})),this._search="",this._isOptionsOpen=!1,this._userInfoMessage="",this._addValueText=null,this._inputFocus=!1,this.updateMaxReached(),this.inputRef.value&&this.inputRef.value.type!=="hidden"&&(this.inputRef.value.value=""),this.internals.setFormValue(""),this.internals.ariaInvalid="false",this.requestUpdate()}attributeChangedCallback(t,e,s){if(t==="options"){this._options=Array.isArray(this.options)?[...this.options]:[];const i=k.syncOptionsWithValues(this._options,this._value);this._options=i.options,i.newValues.length>this._value.length&&(this._value=i.newValues),this._search=""}super.attributeChangedCallback(t,e,s)}render(){return o.b`
|
|
2
2
|
<pkt-input-wrapper
|
|
3
3
|
.label=${this.label}
|
|
4
4
|
.helptext=${this.helptext}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { P as p, b as c, n as a, t as g } from "./element-
|
|
2
|
-
import "./button-
|
|
3
|
-
import "./icon-
|
|
1
|
+
import { P as p, b as c, n as a, t as g } from "./element-CPpT3rFQ.js";
|
|
2
|
+
import "./button-DEyvt1LI.js";
|
|
3
|
+
import "./icon-BlKA8YuW.js";
|
|
4
4
|
const u = {
|
|
5
5
|
i18n: {
|
|
6
6
|
nb: {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const o=require("./element-
|
|
1
|
+
"use strict";const o=require("./element-gR_VtSiD.cjs");require("./button-DYv5Dg4M.cjs");require("./icon-Bqj9oBbl.cjs");const k={i18n:{nb:{contentPresentation:{title:"Oslo kommune bruker informasjonskapsler",description:["For at nettstedet skal fungere og være trygt, bruker Oslo kommune informasjonskapsler. Noen er teknisk nødvendige, mens andre sikrer ulik funksjonalitet.","Godtar du alle informasjonskapsler, tillater du også at vi samler inn data om statistikk og brukeradferd. Da hjelper du oss med å lage et bedre nettsted uten at du trenger å dele noe personlig informasjon med oss."],buttons:{accept:"Godta alle",reject:"Kun nødvendige",settings:"Innstillinger for informasjonskapsler"}},contentSettings:{title:"Innstillinger for informasjonskapsler",description:["Her kan du velge hvilke typer informasjonskapsler du vil tillate. Tillatelsen gjelder i 90 dager. Husk at nødvendige informasjonskapsler ikke kan velges bort.","Du kan når som helst endre innstillingene og finne mer informasjon nederst på nettstedet under «Innstillinger for informasjonskapsler» og «Personvern og informasjonskapsler»."],buttons:{back:"Tilbake",save:"Lagre innstillinger"}}},en:{contentPresentation:{title:"Before you visit Oslo kommune ...",description:["This website uses cookies to make improvements. In this context, we need your consent to measure the traffic on the website in relation to statistics and feedback.","To read more about what we use cookies for, go to our privacy declaration which you will find at the bottom of our websites."],buttons:{accept:"Yes, I accept",reject:"Only necessary",settings:"Go to settings"}},contentSettings:{title:"Her kan du aktivt velge mellom ulike informasjonskapsler",description:["For å lese mer om hva vi bruker informasjonskapsler til gå til vår personvernserklering som du finner på våre nettsider"],buttons:{back:"Back",save:"Save settings"}}}}};var d=Object.defineProperty,p=Object.getOwnPropertyDescriptor,s=(r,e,t,n)=>{for(var i=n>1?void 0:n?p(e,t):e,a=r.length-1,l;a>=0;a--)(l=r[a])&&(i=(n?l(e,t,i):l(i))||i);return n&&i&&d(e,t,i),i};let c=null;function u(){return c||(c=new Promise((r,e)=>{if(document.querySelector("#oslo-consent-script")){r();return}const t=document.createElement("script");t.src="https://cdn.web.oslo.kommune.no/cb/cb-v1.1.0.js",t.id="oslo-consent-script",t.onload=()=>r(),t.onerror=e,document.head.appendChild(t);const n=document.createElement("link");n.href="https://cdn.web.oslo.kommune.no/cb/cb-v1.1.0.css",n.type="text/css",n.rel="stylesheet",n.id="oslo-consent-styles",document.head.appendChild(n)}),c)}exports.PktConsent=class extends o.PktElement{constructor(){super(),this.devMode=!1,this.hotjarId=null,this.googleAnalyticsId=null,this.cookieDomain=null,this.cookieSecure=null,this.cookieExpiryDays=null,this.triggerType="button",this.triggerText=null,this.i18nLanguage="nb"}connectedCallback(){super.connectedCallback(),this.triggerText=this.triggerText||k.i18n[this.i18nLanguage].contentPresentation.buttons.settings}disconnectedCallback(){var e;super.disconnectedCallback(),this._cookieEventHandler&&((e=window.__cookieEvents)==null||e.off("CookieManager.setCookie",this._cookieEventHandler))}returnJsonOrObject(e){let t;try{t=JSON.parse(e)}catch{t=e}return t}emitCookieConsents(e){const n=this.returnJsonOrObject(e.value).items.reduce((i,a)=>(i[a.name]=a.consent,i),{});this.dispatchEvent(new CustomEvent("toggle-consent",{detail:n,bubbles:!0,cancelable:!1}))}async firstUpdated(e){window.cookieBanner_googleAnalyticsId=this.googleAnalyticsId,window.cookieBanner_hotjarId=this.hotjarId,this.cookieDomain&&(window.cookieBanner_cookieDomain=this.cookieDomain),this.cookieSecure&&(window.cookieBanner_cookieSecure=this.cookieSecure),this.cookieExpiryDays&&(window.cookieBanner_cookieExpiryDays=this.cookieExpiryDays),this.devMode&&(window.cookieBanner_devMode=this.devMode),await u(),this.triggerInit()}triggerInit(){window.document.dispatchEvent(new Event("CookieBannerReady",{bubbles:!0,cancelable:!0})),window.cookieBanner.cookieConsent.validateConsentCookie().then(e=>{if(e){const n={value:window.cookieBanner.cookieConsent.getConsentCookie()};window.setTimeout(()=>this.emitCookieConsents(n),0),this._cookieEventHandler&&window.__cookieEvents.off("CookieManager.setCookie",this._cookieEventHandler),this._cookieEventHandler=i=>{this.emitCookieConsents(i)},window.__cookieEvents.on("CookieManager.setCookie",this._cookieEventHandler)}})}openModal(e){var t;e.preventDefault(),(t=window.cookieBanner)!=null&&t.cookieConsent||this.triggerInit(),setTimeout(()=>window.cookieBanner.openCookieModal())}render(){return this.triggerType==="link"?o.b`<a href="#" class="pkt-link" @click=${this.openModal}>${this.triggerText}</a>`:this.triggerType==="footerlink"?o.b`<a href="#" class="pkt-footer__link" @click=${this.openModal}>
|
|
2
2
|
<pkt-icon name="chevron-right" class="pkt-footer__link-icon"></pkt-icon>
|
|
3
3
|
${this.triggerText}
|
|
4
4
|
</a>`:this.triggerType==="icon"?o.b`<pkt-button
|
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { P as L, A as D, b as h, n as r, t as x } from "./element-
|
|
2
|
-
import { r as z } from "./state-
|
|
3
|
-
import { s as H, f as N, a as Q, i as X, n as k, b as j, c as W, v as I, d as Y, p as Z, e as G } from "./calendar-
|
|
4
|
-
import { P as ee } from "./input-element-
|
|
5
|
-
import { e as m, n as v } from "./ref-
|
|
6
|
-
import "./icon-
|
|
7
|
-
import "./input-wrapper-
|
|
8
|
-
import { e as $ } from "./class-map-
|
|
9
|
-
import { c as te } from "./repeat-
|
|
10
|
-
import "./tag-
|
|
1
|
+
import { P as L, A as D, b as h, n as r, t as x } from "./element-CPpT3rFQ.js";
|
|
2
|
+
import { r as z } from "./state-C_1EOo3D.js";
|
|
3
|
+
import { s as H, f as N, a as Q, i as X, n as k, b as j, c as W, v as I, d as Y, p as Z, e as G } from "./calendar-S63oreVW.js";
|
|
4
|
+
import { P as ee } from "./input-element-8nLwuQS4.js";
|
|
5
|
+
import { e as m, n as v } from "./ref-Bg_Swj5w.js";
|
|
6
|
+
import "./icon-BlKA8YuW.js";
|
|
7
|
+
import "./input-wrapper-B2JpK016.js";
|
|
8
|
+
import { e as $ } from "./class-map-CEnykyO_.js";
|
|
9
|
+
import { c as te } from "./repeat-BD8TKgJb.js";
|
|
10
|
+
import "./tag-BuCpqaks.js";
|
|
11
11
|
import { u as se, s as ie } from "./utils-DznhwRXm.js";
|
|
12
|
-
import { o as f } from "./if-defined-
|
|
13
|
-
import { s as ae } from "./element-with-slot-
|
|
12
|
+
import { o as f } from "./if-defined-B0krMLad.js";
|
|
13
|
+
import { s as ae } from "./element-with-slot-Dqk6-TRR.js";
|
|
14
14
|
const J = {
|
|
15
15
|
calendar: { buttonAltText: "Åpne kalender" }
|
|
16
16
|
}, ne = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";const l=require("./element-
|
|
1
|
+
"use strict";const l=require("./element-gR_VtSiD.cjs"),I=require("./state-Dg-53wQ8.cjs"),u=require("./calendar-HIE9nxcc.cjs"),A=require("./input-element-DdVhUvva.cjs"),o=require("./ref-CL-Xk9Xm.cjs");require("./icon-Bqj9oBbl.cjs");require("./input-wrapper-B0MkQ0IZ.cjs");const m=require("./class-map-CsENJXf1.cjs"),M=require("./repeat-Cfq8CDlf.cjs");require("./tag-X6xdjR0N.cjs");const O=require("./utils-byXsEz1u.cjs"),g=require("./if-defined-BOW3ODSj.cjs"),F=require("./element-with-slot-ZX-up7jO.cjs"),B={calendar:{buttonAltText:"Åpne kalender"}},j={calendar:{buttonAltText:"Åpne kalender"},generic:{from:"Fra",to:"Til"}};var q=Object.defineProperty,L=Object.getOwnPropertyDescriptor,k=(s,e,t,a)=>{for(var i=a>1?void 0:a?L(e,t):e,r=s.length-1,n;r>=0;r--)(n=s[r])&&(i=(a?n(e,t,i):n(i))||i);return a&&i&&q(e,t,i),i};exports.PktDateTags=class extends l.PktElement{constructor(){super(...arguments),this.dates=[],this.dateformat="dd.MM.yyyy",this.className="pkt-datepicker__tags",this.idBase=O.uuidish()}render(){return this.classes={"pkt-date-tags":!0,[this.className]:!0},l.b`
|
|
2
2
|
<div class=${m.e(this.classes)} aria-live="polite">
|
|
3
3
|
${Array.isArray(this.dates)&&this.dates[0]?M.c(u.sortDateStrings((this.dates??[]).filter(Boolean)),e=>e,e=>{var t;return l.b` <pkt-tag
|
|
4
4
|
id=${this.idBase+e+"-tag"}
|
|
@@ -3,11 +3,11 @@
|
|
|
3
3
|
* Copyright 2017 Google LLC
|
|
4
4
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5
5
|
*/
|
|
6
|
-
const P = globalThis, V = (r) => r,
|
|
7
|
-
\f\r]`, w = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, W = /-->/g, Z = />/g,
|
|
8
|
-
\f\r"'\`<>=]|("|')|))|$)`, "g"), K = /'/g, G = /"/g, nt = /^(?:script|style|textarea|title)$/i, ut = (r) => (t, ...e) => ({ _$litType$: r, strings: t, values: e }),
|
|
6
|
+
const P = globalThis, V = (r) => r, k = P.trustedTypes, J = k ? k.createPolicy("lit-html", { createHTML: (r) => r }) : void 0, it = "$lit$", f = `lit$${Math.random().toFixed(9).slice(2)}$`, rt = "?" + f, dt = `<${rt}>`, y = document, x = () => y.createComment(""), U = (r) => r === null || typeof r != "object" && typeof r != "function", F = Array.isArray, pt = (r) => F(r) || typeof (r == null ? void 0 : r[Symbol.iterator]) == "function", R = `[
|
|
7
|
+
\f\r]`, w = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, W = /-->/g, Z = />/g, m = RegExp(`>|${R}(?:([^\\s"'>=/]+)(${R}*=${R}*(?:[^
|
|
8
|
+
\f\r"'\`<>=]|("|')|))|$)`, "g"), K = /'/g, G = /"/g, nt = /^(?:script|style|textarea|title)$/i, ut = (r) => (t, ...e) => ({ _$litType$: r, strings: t, values: e }), Ft = ut(1), S = Symbol.for("lit-noChange"), d = Symbol.for("lit-nothing"), Q = /* @__PURE__ */ new WeakMap(), g = y.createTreeWalker(y, 129);
|
|
9
9
|
function ot(r, t) {
|
|
10
|
-
if (!
|
|
10
|
+
if (!F(r) || !r.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
11
11
|
return J !== void 0 ? J.createHTML(t) : t;
|
|
12
12
|
}
|
|
13
13
|
const $t = (r, t) => {
|
|
@@ -16,8 +16,8 @@ const $t = (r, t) => {
|
|
|
16
16
|
for (let a = 0; a < e; a++) {
|
|
17
17
|
const h = r[a];
|
|
18
18
|
let c, p, l = -1, u = 0;
|
|
19
|
-
for (; u < h.length && (o.lastIndex = u, p = o.exec(h), p !== null); ) u = o.lastIndex, o === w ? p[1] === "!--" ? o = W : p[1] !== void 0 ? o = Z : p[2] !== void 0 ? (nt.test(p[2]) && (i = RegExp("</" + p[2], "g")), o =
|
|
20
|
-
const $ = o ===
|
|
19
|
+
for (; u < h.length && (o.lastIndex = u, p = o.exec(h), p !== null); ) u = o.lastIndex, o === w ? p[1] === "!--" ? o = W : p[1] !== void 0 ? o = Z : p[2] !== void 0 ? (nt.test(p[2]) && (i = RegExp("</" + p[2], "g")), o = m) : p[3] !== void 0 && (o = m) : o === m ? p[0] === ">" ? (o = i ?? w, l = -1) : p[1] === void 0 ? l = -2 : (l = o.lastIndex - p[2].length, c = p[1], o = p[3] === void 0 ? m : p[3] === '"' ? G : K) : o === G || o === K ? o = m : o === W || o === Z ? o = w : (o = m, i = void 0);
|
|
20
|
+
const $ = o === m && r[a + 1].startsWith("/>") ? " " : "";
|
|
21
21
|
n += o === w ? h + dt : l >= 0 ? (s.push(c), h.slice(0, l) + it + h.slice(l) + f + $) : h + f + (l === -2 ? a : $);
|
|
22
22
|
}
|
|
23
23
|
return [ot(r, n + (r[e] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), s];
|
|
@@ -28,22 +28,22 @@ let z = class ht {
|
|
|
28
28
|
this.parts = [];
|
|
29
29
|
let n = 0, o = 0;
|
|
30
30
|
const a = t.length - 1, h = this.parts, [c, p] = $t(t, e);
|
|
31
|
-
if (this.el = ht.createElement(c, s),
|
|
31
|
+
if (this.el = ht.createElement(c, s), g.currentNode = this.el.content, e === 2 || e === 3) {
|
|
32
32
|
const l = this.el.content.firstChild;
|
|
33
33
|
l.replaceWith(...l.childNodes);
|
|
34
34
|
}
|
|
35
|
-
for (; (i =
|
|
35
|
+
for (; (i = g.nextNode()) !== null && h.length < a; ) {
|
|
36
36
|
if (i.nodeType === 1) {
|
|
37
37
|
if (i.hasAttributes()) for (const l of i.getAttributeNames()) if (l.endsWith(it)) {
|
|
38
|
-
const u = p[o++], $ = i.getAttribute(l).split(f),
|
|
39
|
-
h.push({ type: 1, index: n, name:
|
|
38
|
+
const u = p[o++], $ = i.getAttribute(l).split(f), O = /([.?@])?(.*)/.exec(u);
|
|
39
|
+
h.push({ type: 1, index: n, name: O[2], strings: $, ctor: O[1] === "." ? _t : O[1] === "?" ? mt : O[1] === "@" ? gt : N }), i.removeAttribute(l);
|
|
40
40
|
} else l.startsWith(f) && (h.push({ type: 6, index: n }), i.removeAttribute(l));
|
|
41
41
|
if (nt.test(i.tagName)) {
|
|
42
42
|
const l = i.textContent.split(f), u = l.length - 1;
|
|
43
43
|
if (u > 0) {
|
|
44
|
-
i.textContent =
|
|
45
|
-
for (let $ = 0; $ < u; $++) i.append(l[$],
|
|
46
|
-
i.append(l[u],
|
|
44
|
+
i.textContent = k ? k.emptyScript : "";
|
|
45
|
+
for (let $ = 0; $ < u; $++) i.append(l[$], x()), g.nextNode(), h.push({ type: 2, index: ++n });
|
|
46
|
+
i.append(l[u], x());
|
|
47
47
|
}
|
|
48
48
|
}
|
|
49
49
|
} else if (i.nodeType === 8) if (i.data === rt) h.push({ type: 2, index: n });
|
|
@@ -59,12 +59,12 @@ let z = class ht {
|
|
|
59
59
|
return s.innerHTML = t, s;
|
|
60
60
|
}
|
|
61
61
|
};
|
|
62
|
-
function
|
|
62
|
+
function E(r, t, e = r, s) {
|
|
63
63
|
var o, a;
|
|
64
|
-
if (t ===
|
|
64
|
+
if (t === S) return t;
|
|
65
65
|
let i = s !== void 0 ? (o = e._$Co) == null ? void 0 : o[s] : e._$Cl;
|
|
66
|
-
const n =
|
|
67
|
-
return (i == null ? void 0 : i.constructor) !== n && ((a = i == null ? void 0 : i._$AO) == null || a.call(i, !1), n === void 0 ? i = void 0 : (i = new n(r), i._$AT(r, e, s)), s !== void 0 ? (e._$Co ?? (e._$Co = []))[s] = i : e._$Cl = i), i !== void 0 && (t =
|
|
66
|
+
const n = U(t) ? void 0 : t._$litDirective$;
|
|
67
|
+
return (i == null ? void 0 : i.constructor) !== n && ((a = i == null ? void 0 : i._$AO) == null || a.call(i, !1), n === void 0 ? i = void 0 : (i = new n(r), i._$AT(r, e, s)), s !== void 0 ? (e._$Co ?? (e._$Co = []))[s] = i : e._$Cl = i), i !== void 0 && (t = E(r, i._$AS(r, t.values), i, s)), t;
|
|
68
68
|
}
|
|
69
69
|
class ft {
|
|
70
70
|
constructor(t, e) {
|
|
@@ -78,16 +78,16 @@ class ft {
|
|
|
78
78
|
}
|
|
79
79
|
u(t) {
|
|
80
80
|
const { el: { content: e }, parts: s } = this._$AD, i = ((t == null ? void 0 : t.creationScope) ?? y).importNode(e, !0);
|
|
81
|
-
|
|
82
|
-
let n =
|
|
81
|
+
g.currentNode = i;
|
|
82
|
+
let n = g.nextNode(), o = 0, a = 0, h = s[0];
|
|
83
83
|
for (; h !== void 0; ) {
|
|
84
84
|
if (o === h.index) {
|
|
85
85
|
let c;
|
|
86
86
|
h.type === 2 ? c = new b(n, n.nextSibling, this, t) : h.type === 1 ? c = new h.ctor(n, h.name, h.strings, this, t) : h.type === 6 && (c = new At(n, this, t)), this._$AV.push(c), h = s[++a];
|
|
87
87
|
}
|
|
88
|
-
o !== (h == null ? void 0 : h.index) && (n =
|
|
88
|
+
o !== (h == null ? void 0 : h.index) && (n = g.nextNode(), o++);
|
|
89
89
|
}
|
|
90
|
-
return
|
|
90
|
+
return g.currentNode = y, i;
|
|
91
91
|
}
|
|
92
92
|
p(t) {
|
|
93
93
|
let e = 0;
|
|
@@ -114,7 +114,7 @@ class b {
|
|
|
114
114
|
return this._$AB;
|
|
115
115
|
}
|
|
116
116
|
_$AI(t, e = this) {
|
|
117
|
-
t =
|
|
117
|
+
t = E(this, t, e), U(t) ? t === d || t == null || t === "" ? (this._$AH !== d && this._$AR(), this._$AH = d) : t !== this._$AH && t !== S && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : pt(t) ? this.k(t) : this._(t);
|
|
118
118
|
}
|
|
119
119
|
O(t) {
|
|
120
120
|
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
@@ -123,7 +123,7 @@ class b {
|
|
|
123
123
|
this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
|
|
124
124
|
}
|
|
125
125
|
_(t) {
|
|
126
|
-
this._$AH !== d &&
|
|
126
|
+
this._$AH !== d && U(this._$AH) ? this._$AA.nextSibling.data = t : this.T(y.createTextNode(t)), this._$AH = t;
|
|
127
127
|
}
|
|
128
128
|
$(t) {
|
|
129
129
|
var n;
|
|
@@ -139,10 +139,10 @@ class b {
|
|
|
139
139
|
return e === void 0 && Q.set(t.strings, e = new z(t)), e;
|
|
140
140
|
}
|
|
141
141
|
k(t) {
|
|
142
|
-
|
|
142
|
+
F(this._$AH) || (this._$AH = [], this._$AR());
|
|
143
143
|
const e = this._$AH;
|
|
144
144
|
let s, i = 0;
|
|
145
|
-
for (const n of t) i === e.length ? e.push(s = new b(this.O(
|
|
145
|
+
for (const n of t) i === e.length ? e.push(s = new b(this.O(x()), this.O(x()), this, this.options)) : s = e[i], s._$AI(n), i++;
|
|
146
146
|
i < e.length && (this._$AR(s && s._$AB.nextSibling, i), e.length = i);
|
|
147
147
|
}
|
|
148
148
|
_$AR(t = this._$AA.nextSibling, e) {
|
|
@@ -170,11 +170,11 @@ class N {
|
|
|
170
170
|
_$AI(t, e = this, s, i) {
|
|
171
171
|
const n = this.strings;
|
|
172
172
|
let o = !1;
|
|
173
|
-
if (n === void 0) t =
|
|
173
|
+
if (n === void 0) t = E(this, t, e, 0), o = !U(t) || t !== this._$AH && t !== S, o && (this._$AH = t);
|
|
174
174
|
else {
|
|
175
175
|
const a = t;
|
|
176
176
|
let h, c;
|
|
177
|
-
for (t = n[0], h = 0; h < n.length - 1; h++) c =
|
|
177
|
+
for (t = n[0], h = 0; h < n.length - 1; h++) c = E(this, a[s + h], e, h), c === S && (c = this._$AH[h]), o || (o = !U(c) || c !== this._$AH[h]), c === d ? t = d : t !== d && (t += (c ?? "") + n[h + 1]), this._$AH[h] = c;
|
|
178
178
|
}
|
|
179
179
|
o && !i && this.j(t);
|
|
180
180
|
}
|
|
@@ -190,7 +190,7 @@ class _t extends N {
|
|
|
190
190
|
this.element[this.name] = t === d ? void 0 : t;
|
|
191
191
|
}
|
|
192
192
|
}
|
|
193
|
-
class
|
|
193
|
+
class mt extends N {
|
|
194
194
|
constructor() {
|
|
195
195
|
super(...arguments), this.type = 4;
|
|
196
196
|
}
|
|
@@ -198,12 +198,12 @@ class gt extends N {
|
|
|
198
198
|
this.element.toggleAttribute(this.name, !!t && t !== d);
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
|
-
class
|
|
201
|
+
class gt extends N {
|
|
202
202
|
constructor(t, e, s, i, n) {
|
|
203
203
|
super(t, e, s, i, n), this.type = 5;
|
|
204
204
|
}
|
|
205
205
|
_$AI(t, e = this) {
|
|
206
|
-
if ((t =
|
|
206
|
+
if ((t = E(this, t, e, 0) ?? d) === S) return;
|
|
207
207
|
const s = this._$AH, i = t === d && s !== d || t.capture !== s.capture || t.once !== s.once || t.passive !== s.passive, n = t !== d && (s === d || i);
|
|
208
208
|
i && this.element.removeEventListener(this.name, this, s), n && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
209
209
|
}
|
|
@@ -220,7 +220,7 @@ class At {
|
|
|
220
220
|
return this._$AM._$AU;
|
|
221
221
|
}
|
|
222
222
|
_$AI(t) {
|
|
223
|
-
|
|
223
|
+
E(this, t);
|
|
224
224
|
}
|
|
225
225
|
}
|
|
226
226
|
const It = { I: b }, D = P.litHtmlPolyfillSupport;
|
|
@@ -230,7 +230,7 @@ const yt = (r, t, e) => {
|
|
|
230
230
|
let i = s._$litPart$;
|
|
231
231
|
if (i === void 0) {
|
|
232
232
|
const n = (e == null ? void 0 : e.renderBefore) ?? null;
|
|
233
|
-
s._$litPart$ = i = new b(t.insertBefore(
|
|
233
|
+
s._$litPart$ = i = new b(t.insertBefore(x(), n), n, void 0, e ?? {});
|
|
234
234
|
}
|
|
235
235
|
return i._$AI(r), i;
|
|
236
236
|
};
|
|
@@ -239,7 +239,7 @@ const yt = (r, t, e) => {
|
|
|
239
239
|
* Copyright 2017 Google LLC
|
|
240
240
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
241
241
|
*/
|
|
242
|
-
const
|
|
242
|
+
const Bt = (r) => (t, e) => {
|
|
243
243
|
e !== void 0 ? e.addInitializer(() => {
|
|
244
244
|
customElements.define(r, t);
|
|
245
245
|
}) : customElements.define(r, t);
|
|
@@ -249,7 +249,7 @@ const Ft = (r) => (t, e) => {
|
|
|
249
249
|
* Copyright 2019 Google LLC
|
|
250
250
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
251
251
|
*/
|
|
252
|
-
const T = globalThis,
|
|
252
|
+
const T = globalThis, I = T.ShadowRoot && (T.ShadyCSS === void 0 || T.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, at = Symbol(), X = /* @__PURE__ */ new WeakMap();
|
|
253
253
|
let vt = class {
|
|
254
254
|
constructor(t, e, s) {
|
|
255
255
|
if (this._$cssResult$ = !0, s !== at) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
@@ -258,7 +258,7 @@ let vt = class {
|
|
|
258
258
|
get styleSheet() {
|
|
259
259
|
let t = this.o;
|
|
260
260
|
const e = this.t;
|
|
261
|
-
if (
|
|
261
|
+
if (I && t === void 0) {
|
|
262
262
|
const s = e !== void 0 && e.length === 1;
|
|
263
263
|
s && (t = X.get(e)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), s && X.set(e, t));
|
|
264
264
|
}
|
|
@@ -268,26 +268,26 @@ let vt = class {
|
|
|
268
268
|
return this.cssText;
|
|
269
269
|
}
|
|
270
270
|
};
|
|
271
|
-
const
|
|
272
|
-
if (
|
|
271
|
+
const St = (r) => new vt(typeof r == "string" ? r : r + "", void 0, at), Et = (r, t) => {
|
|
272
|
+
if (I) r.adoptedStyleSheets = t.map((e) => e instanceof CSSStyleSheet ? e : e.styleSheet);
|
|
273
273
|
else for (const e of t) {
|
|
274
274
|
const s = document.createElement("style"), i = T.litNonce;
|
|
275
275
|
i !== void 0 && s.setAttribute("nonce", i), s.textContent = e.cssText, r.appendChild(s);
|
|
276
276
|
}
|
|
277
|
-
}, Y =
|
|
277
|
+
}, Y = I ? (r) => r : (r) => r instanceof CSSStyleSheet ? ((t) => {
|
|
278
278
|
let e = "";
|
|
279
279
|
for (const s of t.cssRules) e += s.cssText;
|
|
280
|
-
return
|
|
280
|
+
return St(e);
|
|
281
281
|
})(r) : r;
|
|
282
282
|
/**
|
|
283
283
|
* @license
|
|
284
284
|
* Copyright 2017 Google LLC
|
|
285
285
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
286
286
|
*/
|
|
287
|
-
const { is: bt, defineProperty: wt, getOwnPropertyDescriptor: Pt, getOwnPropertyNames: Ct, getOwnPropertySymbols:
|
|
287
|
+
const { is: bt, defineProperty: wt, getOwnPropertyDescriptor: Pt, getOwnPropertyNames: Ct, getOwnPropertySymbols: Mt, getPrototypeOf: xt } = Object, _ = globalThis, tt = _.trustedTypes, Ut = tt ? tt.emptyScript : "", j = _.reactiveElementPolyfillSupport, C = (r, t) => r, H = { toAttribute(r, t) {
|
|
288
288
|
switch (t) {
|
|
289
289
|
case Boolean:
|
|
290
|
-
r = r ?
|
|
290
|
+
r = r ? Ut : null;
|
|
291
291
|
break;
|
|
292
292
|
case Object:
|
|
293
293
|
case Array:
|
|
@@ -312,7 +312,7 @@ const { is: bt, defineProperty: wt, getOwnPropertyDescriptor: Pt, getOwnProperty
|
|
|
312
312
|
}
|
|
313
313
|
}
|
|
314
314
|
return e;
|
|
315
|
-
} }, B = (r, t) => !bt(r, t), et = { attribute: !0, type: String, converter:
|
|
315
|
+
} }, B = (r, t) => !bt(r, t), et = { attribute: !0, type: String, converter: H, reflect: !1, useDefault: !1, hasChanged: B };
|
|
316
316
|
Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), _.litPropertyMetadata ?? (_.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
|
|
317
317
|
class v extends HTMLElement {
|
|
318
318
|
static addInitializer(t) {
|
|
@@ -343,13 +343,13 @@ class v extends HTMLElement {
|
|
|
343
343
|
}
|
|
344
344
|
static _$Ei() {
|
|
345
345
|
if (this.hasOwnProperty(C("elementProperties"))) return;
|
|
346
|
-
const t =
|
|
346
|
+
const t = xt(this);
|
|
347
347
|
t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
|
|
348
348
|
}
|
|
349
349
|
static finalize() {
|
|
350
350
|
if (this.hasOwnProperty(C("finalized"))) return;
|
|
351
351
|
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(C("properties"))) {
|
|
352
|
-
const e = this.properties, s = [...Ct(e), ...
|
|
352
|
+
const e = this.properties, s = [...Ct(e), ...Mt(e)];
|
|
353
353
|
for (const i of s) this.createProperty(i, e[i]);
|
|
354
354
|
}
|
|
355
355
|
const t = this[Symbol.metadata];
|
|
@@ -398,7 +398,7 @@ class v extends HTMLElement {
|
|
|
398
398
|
}
|
|
399
399
|
createRenderRoot() {
|
|
400
400
|
const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
401
|
-
return
|
|
401
|
+
return Et(t, this.constructor.elementStyles), t;
|
|
402
402
|
}
|
|
403
403
|
connectedCallback() {
|
|
404
404
|
var t;
|
|
@@ -423,7 +423,7 @@ class v extends HTMLElement {
|
|
|
423
423
|
var n;
|
|
424
424
|
const s = this.constructor.elementProperties.get(t), i = this.constructor._$Eu(t, s);
|
|
425
425
|
if (i !== void 0 && s.reflect === !0) {
|
|
426
|
-
const o = (((n = s.converter) == null ? void 0 : n.toAttribute) !== void 0 ? s.converter :
|
|
426
|
+
const o = (((n = s.converter) == null ? void 0 : n.toAttribute) !== void 0 ? s.converter : H).toAttribute(e, s.type);
|
|
427
427
|
this._$Em = t, o == null ? this.removeAttribute(i) : this.setAttribute(i, o), this._$Em = null;
|
|
428
428
|
}
|
|
429
429
|
}
|
|
@@ -431,7 +431,7 @@ class v extends HTMLElement {
|
|
|
431
431
|
var n, o;
|
|
432
432
|
const s = this.constructor, i = s._$Eh.get(t);
|
|
433
433
|
if (i !== void 0 && this._$Em !== i) {
|
|
434
|
-
const a = s.getPropertyOptions(i), h = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((n = a.converter) == null ? void 0 : n.fromAttribute) !== void 0 ? a.converter :
|
|
434
|
+
const a = s.getPropertyOptions(i), h = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((n = a.converter) == null ? void 0 : n.fromAttribute) !== void 0 ? a.converter : H;
|
|
435
435
|
this._$Em = i;
|
|
436
436
|
const c = h.fromAttribute(e, a.type);
|
|
437
437
|
this[i] = c ?? ((o = this._$Ej) == null ? void 0 : o.get(i)) ?? c, this._$Em = null;
|
|
@@ -523,7 +523,7 @@ v.elementStyles = [], v.shadowRootOptions = { mode: "open" }, v[C("elementProper
|
|
|
523
523
|
* Copyright 2017 Google LLC
|
|
524
524
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
525
525
|
*/
|
|
526
|
-
const
|
|
526
|
+
const Ot = { attribute: !0, type: String, converter: H, reflect: !1, hasChanged: B }, Tt = (r = Ot, t, e) => {
|
|
527
527
|
const { kind: s, metadata: i } = e;
|
|
528
528
|
let n = globalThis.litPropertyMetadata.get(i);
|
|
529
529
|
if (n === void 0 && globalThis.litPropertyMetadata.set(i, n = /* @__PURE__ */ new Map()), s === "setter" && ((r = Object.create(r)).wrapped = !0), n.set(e.name, r), s === "accessor") {
|
|
@@ -556,7 +556,7 @@ function lt(r) {
|
|
|
556
556
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
557
557
|
*/
|
|
558
558
|
const A = globalThis;
|
|
559
|
-
class
|
|
559
|
+
class M extends v {
|
|
560
560
|
constructor() {
|
|
561
561
|
super(...arguments), this.renderOptions = { host: this }, this._$Do = void 0;
|
|
562
562
|
}
|
|
@@ -578,29 +578,30 @@ class x extends v {
|
|
|
578
578
|
super.disconnectedCallback(), (t = this._$Do) == null || t.setConnected(!1);
|
|
579
579
|
}
|
|
580
580
|
render() {
|
|
581
|
-
return
|
|
581
|
+
return S;
|
|
582
582
|
}
|
|
583
583
|
}
|
|
584
584
|
var st;
|
|
585
|
-
|
|
585
|
+
M._$litElement$ = !0, M.finalized = !0, (st = A.litElementHydrateSupport) == null || st.call(A, { LitElement: M });
|
|
586
586
|
const L = A.litElementPolyfillSupport;
|
|
587
|
-
L == null || L({ LitElement:
|
|
587
|
+
L == null || L({ LitElement: M });
|
|
588
588
|
(A.litElementVersions ?? (A.litElementVersions = [])).push("4.2.2");
|
|
589
|
-
const
|
|
590
|
-
example:
|
|
591
|
-
generic:
|
|
589
|
+
const kt = { hi: "Hei!" }, Ht = { from: "Fra", to: "Til" }, Nt = { buttonAltText: "Åpne kalender", deleteDate: "Fjern dato" }, Rt = { month: "Måned", year: "År", days: ["Mandag", "Tirsdag", "Onsdag", "Torsdag", "Fredag", "Lørdag", "Søndag"], daysShort: ["Man", "Tir", "Ons", "Tor", "Fre", "Lør", "Søn"], months: ["Januar", "Februar", "Mars", "April", "Mai", "Juni", "Juli", "August", "September", "Oktober", "November", "Desember"], monthsShort: ["Jan", "Feb", "Mar", "Apr", "Mai", "Jun", "Jul", "Aug", "Sep", "Okt", "Nov", "Des"], week: "Uke", prevMonth: "Forrige måned", nextMonth: "Neste måned" }, Dt = { hours: "Timer", minutes: "Minutter", openPicker: "Åpne tidspunkt-velger", prevTime: "Forrige tidspunkt", nextTime: "Neste tidspunkt", selectTime: "Velg tidspunkt" }, jt = { search: { placeholder: "Søk…" }, labels: { optional: "Valgfritt", required: "Må fylles ut" }, messages: { required: "Dette feltet er påkrevd", invalid: "Ugyldig verdi", invalidPattern: "Ugyldig format", tooShort: "For kort", tooLong: "For lang", rangeUnderflow: "For lav verdi", rangeOverflow: "For høy verdi", stepMismatch: "Må treffe på steget som er definert i elementet", timeStepMismatch: "Må treffe på et steg, for eksempel 0, {step} minutter", timeStepMismatchHour: "Må treffe på hver hele time", timeStepMismatchHalfHour: "Må treffe på hver hele eller halve time", rangeUnderflowMin: "Verdien må være større enn eller lik {min}.", rangeOverflowMax: "Verdien må være mindre enn eller lik {max}.", dateUnderflow: "For tidlig dato", dateOverflow: "For sen dato" }, helptext: { helptextDropdownButton: "Les mer" }, date: { multiple: "Her kan du velge flere datoer. Trykk komma eller enter når du har skrevet inn en dato." } }, Lt = {
|
|
590
|
+
example: kt,
|
|
591
|
+
generic: Ht,
|
|
592
592
|
calendar: Nt,
|
|
593
593
|
dates: Rt,
|
|
594
|
-
|
|
594
|
+
timepicker: Dt,
|
|
595
|
+
forms: jt
|
|
595
596
|
};
|
|
596
|
-
var
|
|
597
|
+
var zt = Object.defineProperty, ct = (r, t, e, s) => {
|
|
597
598
|
for (var i = void 0, n = r.length - 1, o; n >= 0; n--)
|
|
598
599
|
(o = r[n]) && (i = o(t, e, i) || i);
|
|
599
|
-
return i &&
|
|
600
|
+
return i && zt(t, e, i), i;
|
|
600
601
|
};
|
|
601
|
-
class q extends
|
|
602
|
+
class q extends M {
|
|
602
603
|
constructor() {
|
|
603
|
-
super(...arguments), this.strings =
|
|
604
|
+
super(...arguments), this.strings = Lt, this.role = null;
|
|
604
605
|
}
|
|
605
606
|
/**
|
|
606
607
|
* Add support for Hot Module Reloading in dev mode
|
|
@@ -615,7 +616,7 @@ ct([
|
|
|
615
616
|
ct([
|
|
616
617
|
lt({ type: String })
|
|
617
618
|
], q.prototype, "role");
|
|
618
|
-
class
|
|
619
|
+
class Vt extends q {
|
|
619
620
|
/**
|
|
620
621
|
* Make sure the component renders in light DOM instead of shadow DOM
|
|
621
622
|
*/
|
|
@@ -625,13 +626,13 @@ class qt extends q {
|
|
|
625
626
|
}
|
|
626
627
|
export {
|
|
627
628
|
d as A,
|
|
628
|
-
E,
|
|
629
|
-
|
|
629
|
+
S as E,
|
|
630
|
+
Vt as P,
|
|
630
631
|
q as a,
|
|
631
|
-
|
|
632
|
-
|
|
632
|
+
Ft as b,
|
|
633
|
+
M as i,
|
|
633
634
|
It as j,
|
|
634
635
|
lt as n,
|
|
635
|
-
|
|
636
|
-
|
|
636
|
+
Lt as s,
|
|
637
|
+
Bt as t
|
|
637
638
|
};
|