@oslokommune/punkt-react 12.43.0 → 12.43.2
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/dist/punkt-react.es.js +14 -14
- package/dist/punkt-react.umd.js +1 -1
- package/package.json +5 -5
package/dist/punkt-react.es.js
CHANGED
|
@@ -38123,7 +38123,7 @@ const aH = [
|
|
|
38123
38123
|
{
|
|
38124
38124
|
id: "audioguide",
|
|
38125
38125
|
fn: "audioguide.svg",
|
|
38126
|
-
cat: "
|
|
38126
|
+
cat: "objects"
|
|
38127
38127
|
},
|
|
38128
38128
|
{
|
|
38129
38129
|
id: "baby-bottle",
|
|
@@ -38190,11 +38190,6 @@ const aH = [
|
|
|
38190
38190
|
fn: "bicycle.svg",
|
|
38191
38191
|
cat: "travel"
|
|
38192
38192
|
},
|
|
38193
|
-
{
|
|
38194
|
-
id: "blitz-prohibited",
|
|
38195
|
-
fn: "blitz-prohibited.svg",
|
|
38196
|
-
cat: "objects"
|
|
38197
|
-
},
|
|
38198
38193
|
{
|
|
38199
38194
|
id: "books",
|
|
38200
38195
|
fn: "books.svg",
|
|
@@ -38483,7 +38478,7 @@ const aH = [
|
|
|
38483
38478
|
{
|
|
38484
38479
|
id: "dancing",
|
|
38485
38480
|
fn: "dancing.svg",
|
|
38486
|
-
cat: "
|
|
38481
|
+
cat: "activities"
|
|
38487
38482
|
},
|
|
38488
38483
|
{
|
|
38489
38484
|
id: "data",
|
|
@@ -38735,6 +38730,11 @@ const aH = [
|
|
|
38735
38730
|
fn: "flammable-waste.svg",
|
|
38736
38731
|
cat: "signs"
|
|
38737
38732
|
},
|
|
38733
|
+
{
|
|
38734
|
+
id: "flash-prohibited",
|
|
38735
|
+
fn: "flash-prohibited.svg",
|
|
38736
|
+
cat: "objects"
|
|
38737
|
+
},
|
|
38738
38738
|
{
|
|
38739
38739
|
id: "folder",
|
|
38740
38740
|
fn: "folder.svg",
|
|
@@ -38748,7 +38748,7 @@ const aH = [
|
|
|
38748
38748
|
{
|
|
38749
38749
|
id: "fountain",
|
|
38750
38750
|
fn: "fountain.svg",
|
|
38751
|
-
cat: "
|
|
38751
|
+
cat: "places"
|
|
38752
38752
|
},
|
|
38753
38753
|
{
|
|
38754
38754
|
id: "game-console",
|
|
@@ -38838,7 +38838,7 @@ const aH = [
|
|
|
38838
38838
|
{
|
|
38839
38839
|
id: "helmet",
|
|
38840
38840
|
fn: "helmet.svg",
|
|
38841
|
-
cat: "
|
|
38841
|
+
cat: "objects"
|
|
38842
38842
|
},
|
|
38843
38843
|
{
|
|
38844
38844
|
id: "hiking-trail",
|
|
@@ -38993,7 +38993,7 @@ const aH = [
|
|
|
38993
38993
|
{
|
|
38994
38994
|
id: "megaphone",
|
|
38995
38995
|
fn: "megaphone.svg",
|
|
38996
|
-
cat: "
|
|
38996
|
+
cat: "objects"
|
|
38997
38997
|
},
|
|
38998
38998
|
{
|
|
38999
38999
|
id: "memorial-stone",
|
|
@@ -39143,7 +39143,7 @@ const aH = [
|
|
|
39143
39143
|
{
|
|
39144
39144
|
id: "picnic-table",
|
|
39145
39145
|
fn: "picnic-table.svg",
|
|
39146
|
-
cat: "
|
|
39146
|
+
cat: "objects"
|
|
39147
39147
|
},
|
|
39148
39148
|
{
|
|
39149
39149
|
id: "picture",
|
|
@@ -39273,7 +39273,7 @@ const aH = [
|
|
|
39273
39273
|
{
|
|
39274
39274
|
id: "roadblock",
|
|
39275
39275
|
fn: "roadblock.svg",
|
|
39276
|
-
cat: "
|
|
39276
|
+
cat: "objects"
|
|
39277
39277
|
},
|
|
39278
39278
|
{
|
|
39279
39279
|
id: "ruler",
|
|
@@ -39361,8 +39361,8 @@ const aH = [
|
|
|
39361
39361
|
cat: "objects"
|
|
39362
39362
|
},
|
|
39363
39363
|
{
|
|
39364
|
-
id: "
|
|
39365
|
-
fn: "
|
|
39364
|
+
id: "shopping-bag",
|
|
39365
|
+
fn: "shopping-bag.svg",
|
|
39366
39366
|
cat: "objects"
|
|
39367
39367
|
},
|
|
39368
39368
|
{
|
package/dist/punkt-react.umd.js
CHANGED
|
@@ -1542,5 +1542,5 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
1542
1542
|
* @public
|
|
1543
1543
|
*/var i=function(l){var c=/(?:^|\s)lang(?:uage)?-([\w-]+)(?=\s|$)/i,h=0,m={},D={manual:l.Prism&&l.Prism.manual,disableWorkerMessageHandler:l.Prism&&l.Prism.disableWorkerMessageHandler,util:{encode:function q(W){return W instanceof C?new C(W.type,q(W.content),W.alias):Array.isArray(W)?W.map(q):W.replace(/&/g,"&").replace(/</g,"<").replace(/\u00a0/g," ")},type:function(q){return Object.prototype.toString.call(q).slice(8,-1)},objId:function(q){return q.__id||Object.defineProperty(q,"__id",{value:++h}),q.__id},clone:function q(W,Z){Z=Z||{};var X,ae;switch(D.util.type(W)){case"Object":if(ae=D.util.objId(W),Z[ae])return Z[ae];X={},Z[ae]=X;for(var pe in W)W.hasOwnProperty(pe)&&(X[pe]=q(W[pe],Z));return X;case"Array":return ae=D.util.objId(W),Z[ae]?Z[ae]:(X=[],Z[ae]=X,W.forEach(function(Te,be){X[be]=q(Te,Z)}),X);default:return W}},getLanguage:function(q){for(;q;){var W=c.exec(q.className);if(W)return W[1].toLowerCase();q=q.parentElement}return"none"},setLanguage:function(q,W){q.className=q.className.replace(RegExp(c,"gi"),""),q.classList.add("language-"+W)},currentScript:function(){if(typeof document>"u")return null;if("currentScript"in document)return document.currentScript;try{throw new Error}catch(X){var q=(/at [^(\r\n]*\((.*):[^:]+:[^:]+\)$/i.exec(X.stack)||[])[1];if(q){var W=document.getElementsByTagName("script");for(var Z in W)if(W[Z].src==q)return W[Z]}return null}},isActive:function(q,W,Z){for(var X="no-"+W;q;){var ae=q.classList;if(ae.contains(W))return!0;if(ae.contains(X))return!1;q=q.parentElement}return!!Z}},languages:{plain:m,plaintext:m,text:m,txt:m,extend:function(q,W){var Z=D.util.clone(D.languages[q]);for(var X in W)Z[X]=W[X];return Z},insertBefore:function(q,W,Z,X){X=X||D.languages;var ae=X[q],pe={};for(var Te in ae)if(ae.hasOwnProperty(Te)){if(Te==W)for(var be in Z)Z.hasOwnProperty(be)&&(pe[be]=Z[be]);Z.hasOwnProperty(Te)||(pe[Te]=ae[Te])}var Ge=X[q];return X[q]=pe,D.languages.DFS(D.languages,function(qe,Xe){Xe===Ge&&qe!=q&&(this[qe]=pe)}),pe},DFS:function q(W,Z,X,ae){ae=ae||{};var pe=D.util.objId;for(var Te in W)if(W.hasOwnProperty(Te)){Z.call(W,Te,W[Te],X||Te);var be=W[Te],Ge=D.util.type(be);Ge==="Object"&&!ae[pe(be)]?(ae[pe(be)]=!0,q(be,Z,null,ae)):Ge==="Array"&&!ae[pe(be)]&&(ae[pe(be)]=!0,q(be,Z,Te,ae))}}},plugins:{},highlightAll:function(q,W){D.highlightAllUnder(document,q,W)},highlightAllUnder:function(q,W,Z){var X={callback:Z,container:q,selector:'code[class*="language-"], [class*="language-"] code, code[class*="lang-"], [class*="lang-"] code'};D.hooks.run("before-highlightall",X),X.elements=Array.prototype.slice.apply(X.container.querySelectorAll(X.selector)),D.hooks.run("before-all-elements-highlight",X);for(var ae=0,pe;pe=X.elements[ae++];)D.highlightElement(pe,W===!0,X.callback)},highlightElement:function(q,W,Z){var X=D.util.getLanguage(q),ae=D.languages[X];D.util.setLanguage(q,X);var pe=q.parentElement;pe&&pe.nodeName.toLowerCase()==="pre"&&D.util.setLanguage(pe,X);var Te=q.textContent,be={element:q,language:X,grammar:ae,code:Te};function Ge(Xe){be.highlightedCode=Xe,D.hooks.run("before-insert",be),be.element.innerHTML=be.highlightedCode,D.hooks.run("after-highlight",be),D.hooks.run("complete",be),Z&&Z.call(be.element)}if(D.hooks.run("before-sanity-check",be),pe=be.element.parentElement,pe&&pe.nodeName.toLowerCase()==="pre"&&!pe.hasAttribute("tabindex")&&pe.setAttribute("tabindex","0"),!be.code){D.hooks.run("complete",be),Z&&Z.call(be.element);return}if(D.hooks.run("before-highlight",be),!be.grammar){Ge(D.util.encode(be.code));return}if(W&&l.Worker){var qe=new Worker(D.filename);qe.onmessage=function(Xe){Ge(Xe.data)},qe.postMessage(JSON.stringify({language:be.language,code:be.code,immediateClose:!0}))}else Ge(D.highlight(be.code,be.grammar,be.language))},highlight:function(q,W,Z){var X={code:q,grammar:W,language:Z};if(D.hooks.run("before-tokenize",X),!X.grammar)throw new Error('The language "'+X.language+'" has no grammar.');return X.tokens=D.tokenize(X.code,X.grammar),D.hooks.run("after-tokenize",X),C.stringify(D.util.encode(X.tokens),X.language)},tokenize:function(q,W){var Z=W.rest;if(Z){for(var X in Z)W[X]=Z[X];delete W.rest}var ae=new N;return R(ae,ae.head,q),$(q,ae,W,ae.head,0),j(ae)},hooks:{all:{},add:function(q,W){var Z=D.hooks.all;Z[q]=Z[q]||[],Z[q].push(W)},run:function(q,W){var Z=D.hooks.all[q];if(!(!Z||!Z.length))for(var X=0,ae;ae=Z[X++];)ae(W)}},Token:C};l.Prism=D;function C(q,W,Z,X){this.type=q,this.content=W,this.alias=Z,this.length=(X||"").length|0}C.stringify=function q(W,Z){if(typeof W=="string")return W;if(Array.isArray(W)){var X="";return W.forEach(function(Ge){X+=q(Ge,Z)}),X}var ae={type:W.type,content:q(W.content,Z),tag:"span",classes:["token",W.type],attributes:{},language:Z},pe=W.alias;pe&&(Array.isArray(pe)?Array.prototype.push.apply(ae.classes,pe):ae.classes.push(pe)),D.hooks.run("wrap",ae);var Te="";for(var be in ae.attributes)Te+=" "+be+'="'+(ae.attributes[be]||"").replace(/"/g,""")+'"';return"<"+ae.tag+' class="'+ae.classes.join(" ")+'"'+Te+">"+ae.content+"</"+ae.tag+">"};function T(q,W,Z,X){q.lastIndex=W;var ae=q.exec(Z);if(ae&&X&&ae[1]){var pe=ae[1].length;ae.index+=pe,ae[0]=ae[0].slice(pe)}return ae}function $(q,W,Z,X,ae,pe){for(var Te in Z)if(!(!Z.hasOwnProperty(Te)||!Z[Te])){var be=Z[Te];be=Array.isArray(be)?be:[be];for(var Ge=0;Ge<be.length;++Ge){if(pe&&pe.cause==Te+","+Ge)return;var qe=be[Ge],Xe=qe.inside,nt=!!qe.lookbehind,He=!!qe.greedy,dt=qe.alias;if(He&&!qe.pattern.global){var Me=qe.pattern.toString().match(/[imsuy]*$/)[0];qe.pattern=RegExp(qe.pattern.source,Me+"g")}for(var Oe=qe.pattern||qe,de=X.next,Le=ae;de!==W.tail&&!(pe&&Le>=pe.reach);Le+=de.value.length,de=de.next){var xe=de.value;if(W.length>q.length)return;if(!(xe instanceof C)){var Q=1,he;if(He){if(he=T(Oe,Le,q,nt),!he||he.index>=q.length)break;var ht=he.index,ot=he.index+he[0].length,rt=Le;for(rt+=de.value.length;ht>=rt;)de=de.next,rt+=de.value.length;if(rt-=de.value.length,Le=rt,de.value instanceof C)continue;for(var Dt=de;Dt!==W.tail&&(rt<ot||typeof Dt.value=="string");Dt=Dt.next)Q++,rt+=Dt.value.length;Q--,xe=q.slice(Le,rt),he.index-=Le}else if(he=T(Oe,0,xe,nt),!he)continue;var ht=he.index,bt=he[0],vt=xe.slice(0,ht),Lt=xe.slice(ht+bt.length),fn=Le+xe.length;pe&&fn>pe.reach&&(pe.reach=fn);var en=de.prev;vt&&(en=R(W,en,vt),Le+=vt.length),L(W,en,Q);var Jn=new C(Te,Xe?D.tokenize(bt,Xe):bt,dt,bt);if(de=R(W,en,Jn),Lt&&R(W,de,Lt),Q>1){var Ot={cause:Te+","+Ge,reach:fn};$(q,W,Z,de.prev,Le,Ot),pe&&Ot.reach>pe.reach&&(pe.reach=Ot.reach)}}}}}}function N(){var q={value:null,prev:null,next:null},W={value:null,prev:q,next:null};q.next=W,this.head=q,this.tail=W,this.length=0}function R(q,W,Z){var X=W.next,ae={value:Z,prev:W,next:X};return W.next=ae,X.prev=ae,q.length++,ae}function L(q,W,Z){for(var X=W.next,ae=0;ae<Z&&X!==q.tail;ae++)X=X.next;W.next=X,X.prev=W,q.length-=ae}function j(q){for(var W=[],Z=q.head.next;Z!==q.tail;)W.push(Z.value),Z=Z.next;return W}if(!l.document)return l.addEventListener&&(D.disableWorkerMessageHandler||l.addEventListener("message",function(q){var W=JSON.parse(q.data),Z=W.language,X=W.code,ae=W.immediateClose;l.postMessage(D.highlight(X,D.languages[Z],Z)),ae&&l.close()},!1)),D;var J=D.util.currentScript();J&&(D.filename=J.src,J.hasAttribute("data-manual")&&(D.manual=!0));function G(){D.manual||D.highlightAll()}if(!D.manual){var Se=document.readyState;Se==="loading"||Se==="interactive"&&J&&J.defer?document.addEventListener("DOMContentLoaded",G):window.requestAnimationFrame?window.requestAnimationFrame(G):window.setTimeout(G,16)}return D}(n);r.exports&&(r.exports=i),typeof Sd<"u"&&(Sd.Prism=i)})($E);var a4=$E.exports,i4=S2;S2.displayName="markup",S2.aliases=["html","mathml","svg","xml","ssml","atom","rss"];function S2(r){r.languages.markup={comment:{pattern:/<!--(?:(?!<!--)[\s\S])*?-->/,greedy:!0},prolog:{pattern:/<\?[\s\S]+?\?>/,greedy:!0},doctype:{pattern:/<!DOCTYPE(?:[^>"'[\]]|"[^"]*"|'[^']*')+(?:\[(?:[^<"'\]]|"[^"]*"|'[^']*'|<(?!!--)|<!--(?:[^-]|-(?!->))*-->)*\]\s*)?>/i,greedy:!0,inside:{"internal-subset":{pattern:/(^[^\[]*\[)[\s\S]+(?=\]>$)/,lookbehind:!0,greedy:!0,inside:null},string:{pattern:/"[^"]*"|'[^']*'/,greedy:!0},punctuation:/^<!|>$|[[\]]/,"doctype-tag":/^DOCTYPE/i,name:/[^\s<>'"]+/}},cdata:{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,greedy:!0},tag:{pattern:/<\/?(?!\d)[^\s>\/=$<%]+(?:\s(?:\s*[^\s>\/=]+(?:\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))|(?=[\s/>])))+)?\s*\/?>/,greedy:!0,inside:{tag:{pattern:/^<\/?[^\s>\/]+/,inside:{punctuation:/^<\/?/,namespace:/^[^\s>\/:]+:/}},"special-attr":[],"attr-value":{pattern:/=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+)/,inside:{punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}},punctuation:/\/?>/,"attr-name":{pattern:/[^\s>\/]+/,inside:{namespace:/^[^\s>\/:]+:/}}}},entity:[{pattern:/&[\da-z]{1,8};/i,alias:"named-entity"},/&#x?[\da-f]{1,8};/i]},r.languages.markup.tag.inside["attr-value"].inside.entity=r.languages.markup.entity,r.languages.markup.doctype.inside["internal-subset"].inside=r.languages.markup,r.hooks.add("wrap",function(n){n.type==="entity"&&(n.attributes.title=n.content.value.replace(/&/,"&"))}),Object.defineProperty(r.languages.markup.tag,"addInlined",{value:function(i,l){var c={};c["language-"+l]={pattern:/(^<!\[CDATA\[)[\s\S]+?(?=\]\]>$)/i,lookbehind:!0,inside:r.languages[l]},c.cdata=/^<!\[CDATA\[|\]\]>$/i;var h={"included-cdata":{pattern:/<!\[CDATA\[[\s\S]*?\]\]>/i,inside:c}};h["language-"+l]={pattern:/[\s\S]+/,inside:r.languages[l]};var m={};m[i]={pattern:RegExp(/(<__[^>]*>)(?:<!\[CDATA\[(?:[^\]]|\](?!\]>))*\]\]>|(?!<!\[CDATA\[)[\s\S])*?(?=<\/__>)/.source.replace(/__/g,function(){return i}),"i"),lookbehind:!0,greedy:!0,inside:h},r.languages.insertBefore("markup","cdata",m)}}),Object.defineProperty(r.languages.markup.tag,"addAttribute",{value:function(n,i){r.languages.markup.tag.inside["special-attr"].push({pattern:RegExp(/(^|["'\s])/.source+"(?:"+n+")"+/\s*=\s*(?:"[^"]*"|'[^']*'|[^\s'">=]+(?=[\s>]))/.source,"i"),lookbehind:!0,inside:{"attr-name":/^[^\s=]+/,"attr-value":{pattern:/=[\s\S]+/,inside:{value:{pattern:/(^=\s*(["']|(?!["'])))\S[\s\S]*(?=\2$)/,lookbehind:!0,alias:[i,"language-"+i],inside:r.languages[i]},punctuation:[{pattern:/^=/,alias:"attr-equals"},/"|'/]}}}})}}),r.languages.html=r.languages.markup,r.languages.mathml=r.languages.markup,r.languages.svg=r.languages.markup,r.languages.xml=r.languages.extend("markup",{}),r.languages.ssml=r.languages.xml,r.languages.atom=r.languages.xml,r.languages.rss=r.languages.xml}var o4=C2;C2.displayName="css",C2.aliases=[];function C2(r){(function(n){var i=/(?:"(?:\\(?:\r\n|[\s\S])|[^"\\\r\n])*"|'(?:\\(?:\r\n|[\s\S])|[^'\\\r\n])*')/;n.languages.css={comment:/\/\*[\s\S]*?\*\//,atrule:{pattern:/@[\w-](?:[^;{\s]|\s+(?![\s{]))*(?:;|(?=\s*\{))/,inside:{rule:/^@[\w-]+/,"selector-function-argument":{pattern:/(\bselector\s*\(\s*(?![\s)]))(?:[^()\s]|\s+(?![\s)])|\((?:[^()]|\([^()]*\))*\))+(?=\s*\))/,lookbehind:!0,alias:"selector"},keyword:{pattern:/(^|[^\w-])(?:and|not|only|or)(?![\w-])/,lookbehind:!0}}},url:{pattern:RegExp("\\burl\\((?:"+i.source+"|"+/(?:[^\\\r\n()"']|\\[\s\S])*/.source+")\\)","i"),greedy:!0,inside:{function:/^url/i,punctuation:/^\(|\)$/,string:{pattern:RegExp("^"+i.source+"$"),alias:"url"}}},selector:{pattern:RegExp(`(^|[{}\\s])[^{}\\s](?:[^{};"'\\s]|\\s+(?![\\s{])|`+i.source+")*(?=\\s*\\{)"),lookbehind:!0},string:{pattern:i,greedy:!0},property:{pattern:/(^|[^-\w\xA0-\uFFFF])(?!\s)[-_a-z\xA0-\uFFFF](?:(?!\s)[-\w\xA0-\uFFFF])*(?=\s*:)/i,lookbehind:!0},important:/!important\b/i,function:{pattern:/(^|[^-a-z0-9])[-a-z0-9]+(?=\()/i,lookbehind:!0},punctuation:/[(){};:,]/},n.languages.css.atrule.inside.rest=n.languages.css;var l=n.languages.markup;l&&(l.tag.addInlined("style","css"),l.tag.addAttribute("style","css"))})(r)}var s4=x2;x2.displayName="clike",x2.aliases=[];function x2(r){r.languages.clike={comment:[{pattern:/(^|[^\\])\/\*[\s\S]*?(?:\*\/|$)/,lookbehind:!0,greedy:!0},{pattern:/(^|[^\\:])\/\/.*/,lookbehind:!0,greedy:!0}],string:{pattern:/(["'])(?:\\(?:\r\n|[\s\S])|(?!\1)[^\\\r\n])*\1/,greedy:!0},"class-name":{pattern:/(\b(?:class|extends|implements|instanceof|interface|new|trait)\s+|\bcatch\s+\()[\w.\\]+/i,lookbehind:!0,inside:{punctuation:/[.\\]/}},keyword:/\b(?:break|catch|continue|do|else|finally|for|function|if|in|instanceof|new|null|return|throw|try|while)\b/,boolean:/\b(?:false|true)\b/,function:/\b\w+(?=\()/,number:/\b0x[\da-f]+\b|(?:\b\d+(?:\.\d*)?|\B\.\d+)(?:e[+-]?\d+)?/i,operator:/[<>]=?|[!=]=?=?|--?|\+\+?|&&?|\|\|?|[?*/~^%]/,punctuation:/[{}[\];(),.:]/}}var l4=_2;_2.displayName="javascript",_2.aliases=["js"];function _2(r){r.languages.javascript=r.languages.extend("clike",{"class-name":[r.languages.clike["class-name"],{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$A-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\.(?:constructor|prototype))/,lookbehind:!0}],keyword:[{pattern:/((?:^|\})\s*)catch\b/,lookbehind:!0},{pattern:/(^|[^.]|\.\.\.\s*)\b(?:as|assert(?=\s*\{)|async(?=\s*(?:function\b|\(|[$\w\xA0-\uFFFF]|$))|await|break|case|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally(?=\s*(?:\{|$))|for|from(?=\s*(?:['"]|$))|function|(?:get|set)(?=\s*(?:[#\[$\w\xA0-\uFFFF]|$))|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)\b/,lookbehind:!0}],function:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*(?:\.\s*(?:apply|bind|call)\s*)?\()/,number:{pattern:RegExp(/(^|[^\w$])/.source+"(?:"+(/NaN|Infinity/.source+"|"+/0[bB][01]+(?:_[01]+)*n?/.source+"|"+/0[oO][0-7]+(?:_[0-7]+)*n?/.source+"|"+/0[xX][\dA-Fa-f]+(?:_[\dA-Fa-f]+)*n?/.source+"|"+/\d+(?:_\d+)*n/.source+"|"+/(?:\d+(?:_\d+)*(?:\.(?:\d+(?:_\d+)*)?)?|\.\d+(?:_\d+)*)(?:[Ee][+-]?\d+(?:_\d+)*)?/.source)+")"+/(?![\w$])/.source),lookbehind:!0},operator:/--|\+\+|\*\*=?|=>|&&=?|\|\|=?|[!=]==|<<=?|>>>?=?|[-+*/%&|^!=<>]=?|\.{3}|\?\?=?|\?\.?|[~:]/}),r.languages.javascript["class-name"][0].pattern=/(\b(?:class|extends|implements|instanceof|interface|new)\s+)[\w.\\]+/,r.languages.insertBefore("javascript","keyword",{regex:{pattern:/((?:^|[^$\w\xA0-\uFFFF."'\])\s]|\b(?:return|yield))\s*)\/(?:\[(?:[^\]\\\r\n]|\\.)*\]|\\.|[^/\\\[\r\n])+\/[dgimyus]{0,7}(?=(?:\s|\/\*(?:[^*]|\*(?!\/))*\*\/)*(?:$|[\r\n,.;:})\]]|\/\/))/,lookbehind:!0,greedy:!0,inside:{"regex-source":{pattern:/^(\/)[\s\S]+(?=\/[a-z]*$)/,lookbehind:!0,alias:"language-regex",inside:r.languages.regex},"regex-delimiter":/^\/|\/$/,"regex-flags":/^[a-z]+$/}},"function-variable":{pattern:/#?(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*[=:]\s*(?:async\s*)?(?:\bfunction\b|(?:\((?:[^()]|\([^()]*\))*\)|(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)\s*=>))/,alias:"function"},parameter:[{pattern:/(function(?:\s+(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*)?\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\))/,lookbehind:!0,inside:r.languages.javascript},{pattern:/(^|[^$\w\xA0-\uFFFF])(?!\s)[_$a-z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*=>)/i,lookbehind:!0,inside:r.languages.javascript},{pattern:/(\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*=>)/,lookbehind:!0,inside:r.languages.javascript},{pattern:/((?:\b|\s|^)(?!(?:as|async|await|break|case|catch|class|const|continue|debugger|default|delete|do|else|enum|export|extends|finally|for|from|function|get|if|implements|import|in|instanceof|interface|let|new|null|of|package|private|protected|public|return|set|static|super|switch|this|throw|try|typeof|undefined|var|void|while|with|yield)(?![$\w\xA0-\uFFFF]))(?:(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*\s*)\(\s*|\]\s*\(\s*)(?!\s)(?:[^()\s]|\s+(?![\s)])|\([^()]*\))+(?=\s*\)\s*\{)/,lookbehind:!0,inside:r.languages.javascript}],constant:/\b[A-Z](?:[A-Z_]|\dx?)*\b/}),r.languages.insertBefore("javascript","string",{hashbang:{pattern:/^#!.*/,greedy:!0,alias:"comment"},"template-string":{pattern:/`(?:\\[\s\S]|\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}|(?!\$\{)[^\\`])*`/,greedy:!0,inside:{"template-punctuation":{pattern:/^`|`$/,alias:"string"},interpolation:{pattern:/((?:^|[^\\])(?:\\{2})*)\$\{(?:[^{}]|\{(?:[^{}]|\{[^}]*\})*\})+\}/,lookbehind:!0,inside:{"interpolation-punctuation":{pattern:/^\$\{|\}$/,alias:"punctuation"},rest:r.languages.javascript}},string:/[\s\S]+/}},"string-property":{pattern:/((?:^|[,{])[ \t]*)(["'])(?:\\(?:\r\n|[\s\S])|(?!\2)[^\\\r\n])*\2(?=\s*:)/m,lookbehind:!0,greedy:!0,alias:"property"}}),r.languages.insertBefore("javascript","operator",{"literal-property":{pattern:/((?:^|[,{])[ \t]*)(?!\s)[_$a-zA-Z\xA0-\uFFFF](?:(?!\s)[$\w\xA0-\uFFFF])*(?=\s*:)/m,lookbehind:!0,alias:"property"}}),r.languages.markup&&(r.languages.markup.tag.addInlined("script","javascript"),r.languages.markup.tag.addAttribute(/on(?:abort|blur|change|click|composition(?:end|start|update)|dblclick|error|focus(?:in|out)?|key(?:down|up)|load|mouse(?:down|enter|leave|move|out|over|up)|reset|resize|scroll|select|slotchange|submit|unload|wheel)/.source,"javascript")),r.languages.js=r.languages.javascript}var Qg=typeof globalThis=="object"?globalThis:typeof self=="object"?self:typeof window=="object"?window:typeof Sd=="object"?Sd:{},u4=x4();Qg.Prism={manual:!0,disableWorkerMessageHandler:!0};var c4=Sj,d4=zj,PE=a4,f4=i4,p4=o4,h4=s4,m4=l4;u4();var E2={}.hasOwnProperty;function NE(){}NE.prototype=PE;var ha=new NE,g4=ha;ha.highlight=y4,ha.register=Kg,ha.alias=v4,ha.registered=b4,ha.listLanguages=k4,Kg(f4),Kg(p4),Kg(h4),Kg(m4),ha.util.encode=S4,ha.Token.stringify=w4;function Kg(r){if(typeof r!="function"||!r.displayName)throw new Error("Expected `function` for `grammar`, got `"+r+"`");ha.languages[r.displayName]===void 0&&r(ha)}function v4(r,n){var i=ha.languages,l=r,c,h,m,D;n&&(l={},l[r]=n);for(c in l)for(h=l[c],h=typeof h=="string"?[h]:h,m=h.length,D=-1;++D<m;)i[h[D]]=i[c]}function y4(r,n){var i=PE.highlight,l;if(typeof r!="string")throw new Error("Expected `string` for `value`, got `"+r+"`");if(ha.util.type(n)==="Object")l=n,n=null;else{if(typeof n!="string")throw new Error("Expected `string` for `name`, got `"+n+"`");if(E2.call(ha.languages,n))l=ha.languages[n];else throw new Error("Unknown language: `"+n+"` is not registered")}return i.call(this,r,l,n)}function b4(r){if(typeof r!="string")throw new Error("Expected `string` for `language`, got `"+r+"`");return E2.call(ha.languages,r)}function k4(){var r=ha.languages,n=[],i;for(i in r)E2.call(r,i)&&typeof r[i]=="object"&&n.push(i);return n}function w4(r,n,i){var l;return typeof r=="string"?{type:"text",value:r}:ha.util.type(r)==="Array"?D4(r,n):(l={type:r.type,content:ha.Token.stringify(r.content,n,i),tag:"span",classes:["token",r.type],attributes:{},language:n,parent:i},r.alias&&(l.classes=l.classes.concat(r.alias)),ha.hooks.run("wrap",l),c4(l.tag+"."+l.classes.join("."),C4(l.attributes),l.content))}function D4(r,n){for(var i=[],l=r.length,c=-1,h;++c<l;)h=r[c],h!==""&&h!==null&&h!==void 0&&i.push(h);for(c=-1,l=i.length;++c<l;)h=i[c],i[c]=ha.Token.stringify(h,n,i);return i}function S4(r){return r}function C4(r){var n;for(n in r)r[n]=d4(r[n]);return r}function x4(){var r="Prism"in Qg,n=r?Qg.Prism:void 0;return i;function i(){r?Qg.Prism=n:delete Qg.Prism,r=void 0,n=void 0}}const T2=Iy(g4);var Zg=iI(T2,{});Zg.registerLanguage=function(r,n){return T2.register(n)},Zg.alias=function(r,n){return T2.alias(r,n)};const RE={'code[class*="language-"]':{color:"black",background:"none",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none"},'pre[class*="language-"]':{color:"black",background:"#f5f2f0",textShadow:"0 1px white",fontFamily:"Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace",fontSize:"1em",textAlign:"left",whiteSpace:"pre",wordSpacing:"normal",wordBreak:"normal",wordWrap:"normal",lineHeight:"1.5",MozTabSize:"4",OTabSize:"4",tabSize:"4",WebkitHyphens:"none",MozHyphens:"none",msHyphens:"none",hyphens:"none",padding:"1em",margin:".5em 0",overflow:"auto"},'pre[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::-moz-selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'pre[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"]::selection':{textShadow:"none",background:"#b3d4fc"},'code[class*="language-"] ::selection':{textShadow:"none",background:"#b3d4fc"},':not(pre) > code[class*="language-"]':{background:"#f5f2f0",padding:".1em",borderRadius:".3em",whiteSpace:"normal"},comment:{color:"slategray"},prolog:{color:"slategray"},doctype:{color:"slategray"},cdata:{color:"slategray"},punctuation:{color:"#999"},namespace:{Opacity:".7"},property:{color:"#905"},tag:{color:"#905"},boolean:{color:"#905"},number:{color:"#905"},constant:{color:"#905"},symbol:{color:"#905"},deleted:{color:"#905"},selector:{color:"#690"},"attr-name":{color:"#690"},string:{color:"#690"},char:{color:"#690"},builtin:{color:"#690"},inserted:{color:"#690"},operator:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},entity:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)",cursor:"help"},url:{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".language-css .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},".style .token.string":{color:"#9a6e3a",background:"hsla(0, 0%, 100%, .5)"},atrule:{color:"#07a"},"attr-value":{color:"#07a"},keyword:{color:"#07a"},function:{color:"#DD4A68"},"class-name":{color:"#DD4A68"},regex:{color:"#e90"},important:{color:"#e90",fontWeight:"bold"},variable:{color:"#e90"},bold:{fontWeight:"bold"},italic:{fontStyle:"italic"}};var _4=F2;F2.displayName="jsx",F2.aliases=[];function F2(r){(function(n){var i=n.util.clone(n.languages.javascript),l=/(?:\s|\/\/.*(?!.)|\/\*(?:[^*]|\*(?!\/))\*\/)/.source,c=/(?:\{(?:\{(?:\{[^{}]*\}|[^{}])*\}|[^{}])*\})/.source,h=/(?:\{<S>*\.{3}(?:[^{}]|<BRACES>)*\})/.source;function m(T,$){return T=T.replace(/<S>/g,function(){return l}).replace(/<BRACES>/g,function(){return c}).replace(/<SPREAD>/g,function(){return h}),RegExp(T,$)}h=m(h).source,n.languages.jsx=n.languages.extend("markup",i),n.languages.jsx.tag.pattern=m(/<\/?(?:[\w.:-]+(?:<S>+(?:[\w.:$-]+(?:=(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s{'"/>=]+|<BRACES>))?|<SPREAD>))*<S>*\/?)?>/.source),n.languages.jsx.tag.inside.tag.pattern=/^<\/?[^\s>\/]*/,n.languages.jsx.tag.inside["attr-value"].pattern=/=(?!\{)(?:"(?:\\[\s\S]|[^\\"])*"|'(?:\\[\s\S]|[^\\'])*'|[^\s'">]+)/,n.languages.jsx.tag.inside.tag.inside["class-name"]=/^[A-Z]\w*(?:\.[A-Z]\w*)*$/,n.languages.jsx.tag.inside.comment=i.comment,n.languages.insertBefore("inside","attr-name",{spread:{pattern:m(/<SPREAD>/.source),inside:n.languages.jsx}},n.languages.jsx.tag),n.languages.insertBefore("inside","special-attr",{script:{pattern:m(/=<BRACES>/.source),alias:"language-javascript",inside:{"script-punctuation":{pattern:/^=(?=\{)/,alias:"punctuation"},rest:n.languages.jsx}}},n.languages.jsx.tag);var D=function(T){return T?typeof T=="string"?T:typeof T.content=="string"?T.content:T.content.map(D).join(""):""},C=function(T){for(var $=[],N=0;N<T.length;N++){var R=T[N],L=!1;if(typeof R!="string"&&(R.type==="tag"&&R.content[0]&&R.content[0].type==="tag"?R.content[0].content[0].content==="</"?$.length>0&&$[$.length-1].tagName===D(R.content[0].content[1])&&$.pop():R.content[R.content.length-1].content==="/>"||$.push({tagName:D(R.content[0].content[1]),openedBraces:0}):$.length>0&&R.type==="punctuation"&&R.content==="{"?$[$.length-1].openedBraces++:$.length>0&&$[$.length-1].openedBraces>0&&R.type==="punctuation"&&R.content==="}"?$[$.length-1].openedBraces--:L=!0),(L||typeof R=="string")&&$.length>0&&$[$.length-1].openedBraces===0){var j=D(R);N<T.length-1&&(typeof T[N+1]=="string"||T[N+1].type==="plain-text")&&(j+=D(T[N+1]),T.splice(N+1,1)),N>0&&(typeof T[N-1]=="string"||T[N-1].type==="plain-text")&&(j=D(T[N-1])+j,T.splice(N-1,1),N--),T[N]=new n.Token("plain-text",j,null,j)}R.content&&typeof R.content!="string"&&C(R.content)}};n.hooks.add("after-tokenize",function(T){T.language!=="jsx"&&T.language!=="tsx"||C(T.tokens)})})(r)}const E4=Iy(_4),T4=zr({tagName:"pkt-tag",elementClass:Es,react:$e,displayName:"PktTag",events:{onClose:"close"}}),Yh=$e.forwardRef(({children:r,...n},i)=>O.jsx(T4,{ref:i,...n,children:O.jsx("div",{className:"pkt-contents",children:r})}));Yh.displayName="PktTag";const LE=$e.forwardRef(({arrowNav:r=!0,tabs:n,onTabSelected:i},l)=>{const c=$e.useRef([]);$e.useEffect(()=>{c.current=c.current.slice(0,n.length)},[n]);const h=(D,C)=>{C.action&&C.action(D),i&&i(D)},m=(D,C)=>{var T,$;r&&(C.code==="ArrowLeft"&&D!==0&&((T=c.current[D-1])==null||T.focus()),C.code==="ArrowRight"&&D<n.length-1&&(($=c.current[D+1])==null||$.focus()),(C.code==="ArrowDown"||C.code==="Space")&&h(D,n[D]))};return O.jsx("div",{className:"pkt-tabs",ref:l,children:O.jsx("div",{className:"pkt-tabs__list",role:r?"tablist":"navigation",children:n.map((D,C)=>O.jsx($e.Fragment,{children:D.href?O.jsxs("a",{"aria-selected":!!D.active,role:r?"tab":void 0,href:D.href,"aria-controls":D.controls,className:`pkt-tabs__link ${D.active?"active":""}`,onKeyUp:T=>m(C,T),onClick:()=>h(C,D),tabIndex:D.active||!r?void 0:-1,ref:T=>{c.current[C]=T},children:[D.icon&&O.jsx(or,{name:D.icon,className:"pkt-icon--small"}),D.text,D.tag&&O.jsx(Yh,{skin:D.tag.skin,size:"small",children:D.tag.text})]}):O.jsxs("button",{"aria-selected":!!D.active,role:r?"tab":void 0,type:"button","aria-controls":D.controls,className:`pkt-tabs__button pkt-link-button ${D.active?"active":""}`,onKeyUp:T=>m(C,T),onClick:()=>h(C,D),tabIndex:D.active||!r?void 0:-1,ref:T=>{c.current[C]=T},children:[D.icon&&O.jsx(or,{name:D.icon,className:"pkt-icon--small"}),D.text,D.tag&&O.jsx(Yh,{skin:D.tag.skin,size:"small",children:D.tag.text})]},"b-"+C)},C))})})}),F4=zr({tagName:"pkt-textinput",elementClass:As,react:$e,displayName:"PktTextinput",events:{onChange:"change",onInput:"input",onBlur:"blur",onFocus:"focus",onValueChange:"valueChange",onToggleHelpText:"toggleHelpText"}}),ev=$e.forwardRef(({helptext:r,...n},i)=>O.jsx(F4,{...n,ref:i,children:r&&O.jsx("div",{slot:"helptext",className:"pkt-contents",children:r})}));ev.displayName="PktTextinput";const Pb=({className:r,compact:n=!1,skin:i="basic",responsiveView:l=!0,children:c})=>O.jsx("table",{"data-testid":"pkt-table",className:ml(r,"pkt-table",{"pkt-table--responsive":l,"pkt-table--compact":n,"pkt-table--basic":i==="basic","pkt-table--zebra-blue":i==="zebra-blue"}),role:"table",children:c}),Nb=({className:r,children:n})=>O.jsx("thead",{className:ml(r,"pkt-table__header",{}),role:"rowgroup",children:n}),Rb=({children:r,className:n})=>O.jsx("tbody",{className:ml(n,"pkt-table__body",{}),role:"rowgroup",children:r}),rp=({className:r,children:n})=>O.jsx("tr",{className:ml(r,"pkt-table__row",{}),role:"row",children:n}),gl=({className:r,children:n})=>O.jsx("th",{className:ml(r,"pkt-table__header-cell",{}),role:"columnheader",children:n}),Zo=({children:r,className:n,dataLabel:i})=>O.jsx("td",{className:ml(n,"pkt-table__data-cell",{}),"data-label":i,role:"cell","data-testid":"pkt-table__data-cell",children:r}),A4=({specs:r})=>{const n=l=>Array.isArray(l)?l.join(`
|
|
1544
1544
|
`):l,i=l=>typeof l=="boolean"?l?"true":"false":l;return O.jsxs(O.Fragment,{children:[O.jsx("h2",{children:"Egenskaper"}),O.jsxs(Pb,{compact:!0,children:[O.jsx(Nb,{children:O.jsxs(rp,{children:[O.jsx(gl,{children:"Prop"}),O.jsx(gl,{children:"Navn"}),O.jsx(gl,{children:"Beskrivelse"}),O.jsx(gl,{children:"Type"}),O.jsx(gl,{children:"Standardverdi"})]})}),O.jsx(Rb,{children:Object.entries(r.props||{}).map(([l,c])=>O.jsxs(rp,{children:[O.jsx(Zo,{dataLabel:"Prop",children:O.jsx("pre",{children:l})}),O.jsx(Zo,{dataLabel:"Navn",children:!Array.isArray(c)&&c.name||l}),Array.isArray(c)?O.jsxs(O.Fragment,{children:[O.jsx(Zo,{dataLabel:"Beskrivelse"}),O.jsx(Zo,{dataLabel:"Type",children:O.jsx("pre",{children:c.join(`
|
|
1545
|
-
`)})})]}):O.jsxs(O.Fragment,{children:[O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})}),O.jsx(Zo,{dataLabel:"Type",children:O.jsx("pre",{children:c.type&&n(c.type)})}),O.jsx(Zo,{dataLabel:"Standardverdi",children:O.jsx("pre",{children:i(c.default)})})]})]},l))})]}),r.events&&O.jsxs(O.Fragment,{children:[O.jsx("h2",{children:"Hendelser / handlinger"}),O.jsxs(Pb,{compact:!0,children:[O.jsx(Nb,{children:O.jsxs(rp,{children:[O.jsx(gl,{children:"Event"}),O.jsx(gl,{children:"Beskrivelse"}),O.jsx(gl,{children:"Type"})]})}),O.jsx(Rb,{children:Object.entries(r.events||{}).map(([l,c])=>O.jsxs(rp,{children:[O.jsx(Zo,{dataLabel:"Event",children:O.jsx("pre",{children:l})}),O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})}),O.jsx(Zo,{dataLabel:"Type",children:c.type})]},l))})]})]}),r.slots&&O.jsxs(O.Fragment,{children:[O.jsx("h2",{children:"Innhold"}),O.jsxs(Pb,{compact:!0,children:[O.jsx(Nb,{children:O.jsxs(rp,{children:[O.jsx(gl,{children:"Slot"}),O.jsx(gl,{children:"Beskrivelse"})]})}),O.jsx(Rb,{children:Object.entries(r.slots||{}).map(([l,c])=>O.jsxs(rp,{children:[O.jsx(Zo,{dataLabel:"Slot",children:O.jsx("pre",{children:l})}),O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})})]},l))})]})]})]})},$4=zr({tagName:"pkt-select",elementClass:Nh,react:$e,displayName:"PktSelect",events:{onChange:"change",onInput:"input",onBlur:"blur",onFocus:"focus",onValueChange:"valueChange",onToggleHelpText:"toggleHelpText"}}),Lb=$e.forwardRef(({children:r,helptext:n,...i},l)=>O.jsxs($4,{ref:l,...i,children:[n&&O.jsx("div",{slot:"helptext",className:"pkt-contents",children:n}),r]}));Lb.displayName="PktSelect";const P4=[{id:"24h",fn:"24h.svg",cat:"health"},{id:"access-prohibited",fn:"access-prohibited.svg",cat:"signs"},{id:"accessibility",fn:"accessibility.svg",cat:"signs"},{id:"accessible-water-access",fn:"accessible-water-access.svg",cat:"activities"},{id:"active-person",fn:"active-person.svg",cat:"activities"},{id:"adjust",fn:"adjust.svg",cat:"ui"},{id:"advice",fn:"advice.svg",cat:"social"},{id:"alcohol-prohibited",fn:"alcohol-prohibited.svg",cat:"food"},{id:"alert-circle",fn:"alert-circle.svg",cat:"status"},{id:"alert-error-system",fn:"alert-error-system.svg",cat:"status"},{id:"alert-error",fn:"alert-error.svg",cat:"status"},{id:"alert-information",fn:"alert-information.svg",cat:"status"},{id:"alert-success-system",fn:"alert-success-system.svg",cat:"status"},{id:"alert-success",fn:"alert-success.svg",cat:"status"},{id:"alert-warning",fn:"alert-warning.svg",cat:"status"},{id:"ambulance",fn:"ambulance.svg",cat:"travel"},{id:"apple",fn:"apple.svg",cat:"food"},{id:"archive",fn:"archive.svg",cat:"ui"},{id:"arrow-circle",fn:"arrow-circle.svg",cat:"ui"},{id:"arrow-return",fn:"arrow-return.svg",cat:"navigation"},{id:"arrow",fn:"arrow.svg",cat:"navigation"},{id:"arts-and-culture",fn:"arts-and-culture.svg",cat:"places"},{id:"attachment",fn:"attachment.svg",cat:"ui"},{id:"audioguide",fn:"audioguide.svg",cat:"uncategorized"},{id:"baby-bottle",fn:"baby-bottle.svg",cat:"food"},{id:"baby-changing-room",fn:"baby-changing-room.svg",cat:"activities"},{id:"backpack-prohibited",fn:"backpack-prohibited.svg",cat:"objects"},{id:"backpack",fn:"backpack.svg",cat:"services"},{id:"ball-sports",fn:"ball-sports.svg",cat:"activities"},{id:"balloons",fn:"balloons.svg",cat:"objects"},{id:"bath",fn:"bath.svg",cat:"objects"},{id:"bed",fn:"bed.svg",cat:"objects"},{id:"beehive",fn:"beehive.svg",cat:"objects"},{id:"bicycle-parking",fn:"bicycle-parking.svg",cat:"travel"},{id:"bicycle-prohibited",fn:"bicycle-prohibited.svg",cat:"travel"},{id:"bicycle-service",fn:"bicycle-service.svg",cat:"travel"},{id:"bicycle",fn:"bicycle.svg",cat:"travel"},{id:"blitz-prohibited",fn:"blitz-prohibited.svg",cat:"objects"},{id:"books",fn:"books.svg",cat:"health"},{id:"boys-shower",fn:"boys-shower.svg",cat:"signs"},{id:"boys-toilet",fn:"boys-toilet.svg",cat:"user"},{id:"brain-heart",fn:"brain-heart.svg",cat:"health"},{id:"brain-signal",fn:"brain-signal.svg",cat:"health"},{id:"brain",fn:"brain.svg",cat:"health"},{id:"briefcase",fn:"briefcase.svg",cat:"objects"},{id:"bulb",fn:"bulb.svg",cat:"objects"},{id:"bullseye",fn:"bullseye.svg",cat:"objects"},{id:"bus",fn:"bus.svg",cat:"travel"},{id:"cafe",fn:"cafe.svg",cat:"food"},{id:"calendar",fn:"calendar.svg",cat:"ui"},{id:"camera-surveillance-CCTV",fn:"camera-surveillance-CCTV.svg",cat:"objects"},{id:"camera",fn:"camera.svg",cat:"objects"},{id:"campfire-site",fn:"campfire-site.svg",cat:"health"},{id:"camping",fn:"camping.svg",cat:"places"},{id:"car",fn:"car.svg",cat:"travel"},{id:"character-exclamation-mark",fn:"character-exclamation-mark.svg",cat:"status"},{id:"character-information",fn:"character-information.svg",cat:"status"},{id:"charging-point",fn:"charging-point.svg",cat:"objects"},{id:"check-big",fn:"check-big.svg",cat:"ui"},{id:"check-box-checked",fn:"check-box-checked.svg",cat:"ui"},{id:"check-box-unchecked",fn:"check-box-unchecked.svg",cat:"ui"},{id:"check-circle",fn:"check-circle.svg",cat:"ui"},{id:"check-medium",fn:"check-medium.svg",cat:"ui"},{id:"check",fn:"check.svg",cat:"ui"},{id:"chevron-down",fn:"chevron-down.svg",cat:"navigation"},{id:"chevron-left",fn:"chevron-left.svg",cat:"navigation"},{id:"chevron-right",fn:"chevron-right.svg",cat:"navigation"},{id:"chevron-thin-down",fn:"chevron-thin-down.svg",cat:"navigation"},{id:"chevron-thin-left",fn:"chevron-thin-left.svg",cat:"navigation"},{id:"chevron-thin-right",fn:"chevron-thin-right.svg",cat:"navigation"},{id:"chevron-thin-up",fn:"chevron-thin-up.svg",cat:"navigation"},{id:"chevron-up-and-down",fn:"chevron-up-and-down.svg",cat:"ui"},{id:"chevron-up",fn:"chevron-up.svg",cat:"navigation"},{id:"childrens-toilet",fn:"childrens-toilet.svg",cat:"signs"},{id:"circular-economy",fn:"circular-economy.svg",cat:"ui"},{id:"climbing",fn:"climbing.svg",cat:"activities"},{id:"clock-history",fn:"clock-history.svg",cat:"ui"},{id:"clock",fn:"clock.svg",cat:"ui"},{id:"close",fn:"close.svg",cat:"ui"},{id:"cloud",fn:"cloud.svg",cat:"objects"},{id:"code",fn:"code.svg",cat:"data"},{id:"coffee",fn:"coffee.svg",cat:"food"},{id:"cogwheel",fn:"cogwheel.svg",cat:"ui"},{id:"coin-stacks",fn:"coin-stacks.svg",cat:"health"},{id:"computer",fn:"computer.svg",cat:"objects"},{id:"cookie",fn:"cookie.svg",cat:"ui"},{id:"copy",fn:"copy.svg",cat:"ui"},{id:"crane",fn:"crane.svg",cat:"places"},{id:"crayfish",fn:"crayfish.svg",cat:"objects"},{id:"cross-circle-big",fn:"cross-circle-big.svg",cat:"ui"},{id:"cross-circle-fill-large",fn:"cross-circle-fill-large.svg",cat:"ui"},{id:"cross-circle-fill",fn:"cross-circle-fill.svg",cat:"ui"},{id:"cross-circle",fn:"cross-circle.svg",cat:"ui"},{id:"cross",fn:"cross.svg",cat:"ui"},{id:"cupboard",fn:"cupboard.svg",cat:"objects"},{id:"dancing",fn:"dancing.svg",cat:"uncategorized"},{id:"data",fn:"data.svg",cat:"data"},{id:"deer",fn:"deer.svg",cat:"objects"},{id:"defibrillators",fn:"defibrillators.svg",cat:"signs"},{id:"district",fn:"district.svg",cat:"places"},{id:"diving-prohibited",fn:"diving-prohibited.svg",cat:"activities"},{id:"dock",fn:"dock.svg",cat:"places"},{id:"document-code",fn:"document-code.svg",cat:"ui"},{id:"document-pdf",fn:"document-pdf.svg",cat:"ui"},{id:"document-plain",fn:"document-plain.svg",cat:"ui"},{id:"document-table",fn:"document-table.svg",cat:"ui"},{id:"document-text",fn:"document-text.svg",cat:"ui"},{id:"dog-forbidden",fn:"dog-forbidden.svg",cat:"objects"},{id:"dog-on-a-leash",fn:"dog-on-a-leash.svg",cat:"objects"},{id:"download",fn:"download.svg",cat:"ui"},{id:"drag",fn:"drag.svg",cat:"ui"},{id:"drinking-area-refreshments",fn:"drinking-area-refreshments.svg",cat:"food"},{id:"drone",fn:"drone.svg",cat:"objects"},{id:"drugs-prohibited",fn:"drugs-prohibited.svg",cat:"objects"},{id:"ecg-heart",fn:"ecg-heart.svg",cat:"health"},{id:"edit",fn:"edit.svg",cat:"ui"},{id:"elderly",fn:"elderly.svg",cat:"user"},{id:"electric-car",fn:"electric-car.svg",cat:"travel"},{id:"electric-van",fn:"electric-van.svg",cat:"travel"},{id:"elevator",fn:"elevator.svg",cat:"signs"},{id:"email",fn:"email.svg",cat:"social"},{id:"escalator",fn:"escalator.svg",cat:"signs"},{id:"exclamation-mark-circle",fn:"exclamation-mark-circle.svg",cat:"status"},{id:"exclamation-mark-square",fn:"exclamation-mark-square.svg",cat:"status"},{id:"exit-door",fn:"exit-door.svg",cat:"ui"},{id:"exit",fn:"exit.svg",cat:"navigation"},{id:"expand",fn:"expand.svg",cat:"ui"},{id:"eye",fn:"eye.svg",cat:"ui"},{id:"face-almost-happy",fn:"face-almost-happy.svg",cat:"feedback"},{id:"face-almost-sad",fn:"face-almost-sad.svg",cat:"feedback"},{id:"face-happy",fn:"face-happy.svg",cat:"feedback"},{id:"face-neutral",fn:"face-neutral.svg",cat:"feedback"},{id:"face-sad",fn:"face-sad.svg",cat:"feedback"},{id:"facebook",fn:"facebook.svg",cat:"social"},{id:"factory-fill",fn:"factory-fill.svg",cat:"places"},{id:"feedback",fn:"feedback.svg",cat:"social"},{id:"figma",fn:"figma.svg",cat:"social"},{id:"filming-prohibited",fn:"filming-prohibited.svg",cat:"signs"},{id:"filter",fn:"filter.svg",cat:"ui"},{id:"fire-prohibited",fn:"fire-prohibited.svg",cat:"signs"},{id:"fire-safety",fn:"fire-safety.svg",cat:"health"},{id:"fireworks-prohibited",fn:"fireworks-prohibited.svg",cat:"signs"},{id:"fishing-prohibited",fn:"fishing-prohibited.svg",cat:"signs"},{id:"fixed-bench",fn:"fixed-bench.svg",cat:"objects"},{id:"fixed-grill",fn:"fixed-grill.svg",cat:"objects"},{id:"flammable-waste",fn:"flammable-waste.svg",cat:"signs"},{id:"folder",fn:"folder.svg",cat:"ui"},{id:"food-and-drinks-prohibited",fn:"food-and-drinks-prohibited.svg",cat:"food"},{id:"fountain",fn:"fountain.svg",cat:"uncategorized"},{id:"game-console",fn:"game-console.svg",cat:"objects"},{id:"girls-shower",fn:"girls-shower.svg",cat:"signs"},{id:"girls-toilet",fn:"girls-toilet.svg",cat:"user"},{id:"github",fn:"github.svg",cat:"social"},{id:"graffiti-allowed",fn:"graffiti-allowed.svg",cat:"objects"},{id:"graffiti-prohibited",fn:"graffiti-prohibited.svg",cat:"objects"},{id:"graph",fn:"graph.svg",cat:"data"},{id:"grid",fn:"grid.svg",cat:"ui"},{id:"gym",fn:"gym.svg",cat:"objects"},{id:"handicap-elevator",fn:"handicap-elevator.svg",cat:"signs"},{id:"handicap",fn:"handicap.svg",cat:"user"},{id:"hands-globe",fn:"hands-globe.svg",cat:"health"},{id:"headset",fn:"headset.svg",cat:"objects"},{id:"heart-hand",fn:"heart-hand.svg",cat:"health"},{id:"heart-plus",fn:"heart-plus.svg",cat:"health"},{id:"heart",fn:"heart.svg",cat:"health"},{id:"height-restriction",fn:"height-restriction.svg",cat:"objects"},{id:"helmet",fn:"helmet.svg",cat:"uncategorized"},{id:"hiking-trail",fn:"hiking-trail.svg",cat:"places"},{id:"holding-hands",fn:"holding-hands.svg",cat:"user"},{id:"home",fn:"home.svg",cat:"places"},{id:"horizontal-menu",fn:"horizontal-menu.svg",cat:"ui"},{id:"house-heart",fn:"house-heart.svg",cat:"places"},{id:"ice-skating",fn:"ice-skating.svg",cat:"objects"},{id:"indoor-pool",fn:"indoor-pool.svg",cat:"activities"},{id:"information",fn:"information.svg",cat:"status"},{id:"instagram",fn:"instagram.svg",cat:"social"},{id:"invoice",fn:"invoice.svg",cat:"ui"},{id:"key",fn:"key.svg",cat:"objects"},{id:"ladies-toilet",fn:"ladies-toilet.svg",cat:"user"},{id:"language",fn:"language.svg",cat:"user"},{id:"law-paragraph",fn:"law-paragraph.svg",cat:"user"},{id:"lecture-workplace",fn:"lecture-workplace.svg",cat:"sign"},{id:"lecture",fn:"lecture.svg",cat:"activities"},{id:"life-ring",fn:"life-ring.svg",cat:"objects"},{id:"link",fn:"link.svg",cat:"ui"},{id:"linkedin",fn:"linkedin.svg",cat:"social"},{id:"list",fn:"list.svg",cat:"ui"},{id:"living-room",fn:"living-room.svg",cat:"objects"},{id:"location-pin-filled",fn:"location-pin-filled.svg",cat:"travel"},{id:"location-pin",fn:"location-pin.svg",cat:"travel"},{id:"lock-locked",fn:"lock-locked.svg",cat:"ui"},{id:"lock-unlocked",fn:"lock-unlocked.svg",cat:"ui"},{id:"luggage-prohibited",fn:"luggage-prohibited.svg",cat:"objects"},{id:"magnifying-glass-big",fn:"magnifying-glass-big.svg",cat:"ui"},{id:"magnifying-glass-small",fn:"magnifying-glass-small.svg",cat:"ui"},{id:"map",fn:"map.svg",cat:"travel"},{id:"medicine-cabinet",fn:"medicine-cabinet.svg",cat:"objects"},{id:"megaphone",fn:"megaphone.svg",cat:"uncategorized"},{id:"memorial-stone",fn:"memorial-stone.svg",cat:"objects"},{id:"mens-toilet",fn:"mens-toilet.svg",cat:"user"},{id:"menu",fn:"menu.svg",cat:"navigation"},{id:"message",fn:"message.svg",cat:"social"},{id:"minimize",fn:"minimize.svg",cat:"ui"},{id:"minus-circle-fill",fn:"minus-circle-fill.svg",cat:"ui"},{id:"minus-circle",fn:"minus-circle.svg",cat:"ui"},{id:"minus-sign",fn:"minus-sign.svg",cat:"ui"},{id:"mobile-phone",fn:"mobile-phone.svg",cat:"objects"},{id:"moon",fn:"moon.svg",cat:"objects"},{id:"motorcycle",fn:"motorcycle.svg",cat:"travel"},{id:"museum",fn:"museum.svg",cat:"places"},{id:"music-notes",fn:"music-notes.svg",cat:"objects"},{id:"nature-plant-2",fn:"nature-plant-2.svg",cat:"objects"},{id:"nature-plant",fn:"nature-plant.svg",cat:"objects"},{id:"new-window-small",fn:"new-window-small.svg",cat:"navigation"},{id:"new-window",fn:"new-window.svg",cat:"navigation"},{id:"no-walking",fn:"no-walking.svg",cat:"activities"},{id:"nodejs",fn:"nodejs.svg",cat:"social"},{id:"obstacle",fn:"obstacle.svg",cat:"objects"},{id:"organization",fn:"organization.svg",cat:"places"},{id:"package",fn:"package.svg",cat:"data"},{id:"paint-bucket",fn:"paint-bucket.svg",cat:"objects"},{id:"palette",fn:"palette.svg",cat:"objects"},{id:"paragraph",fn:"paragraph.svg",cat:"ui"},{id:"park",fn:"park.svg",cat:"places"},{id:"parking-meter",fn:"parking-meter.svg",cat:"signs"},{id:"partner-workout",fn:"partner-workout.svg",cat:"activities"},{id:"paste",fn:"paste.svg",cat:"ui"},{id:"picnic-table",fn:"picnic-table.svg",cat:"uncategorized"},{id:"picture",fn:"picture.svg",cat:"objects"},{id:"placeholder-icon",fn:"placeholder-icon.svg",cat:"ui"},{id:"planter-box",fn:"planter-box.svg",cat:"places"},{id:"playground",fn:"playground.svg",cat:"places"},{id:"plus-circle-fill",fn:"plus-circle-fill.svg",cat:"ui"},{id:"plus-circle",fn:"plus-circle.svg",cat:"ui"},{id:"plus-sign",fn:"plus-sign.svg",cat:"ui"},{id:"pregnant",fn:"pregnant.svg",cat:"user"},{id:"pride-heart",fn:"pride-heart.svg",cat:"health"},{id:"print",fn:"print.svg",cat:"objects"},{id:"privacy",fn:"privacy.svg",cat:"user"},{id:"process-back",fn:"process-back.svg",cat:"ui"},{id:"process-forward",fn:"process-forward.svg",cat:"ui"},{id:"process-iteration",fn:"process-iteration.svg",cat:"ui"},{id:"processing",fn:"processing.svg",cat:"ui"},{id:"prohibited",fn:"prohibited.svg",cat:"signs"},{id:"punkt-circle-blue",fn:"punkt-circle-blue.svg",cat:"social"},{id:"qr-code",fn:"qr-code.svg",cat:"ui"},{id:"question",fn:"question.svg",cat:"ui"},{id:"radio-checked",fn:"radio-checked.svg",cat:"ui"},{id:"radio-unchecked",fn:"radio-unchecked.svg",cat:"ui"},{id:"react",fn:"react.svg",cat:"social"},{id:"receipt",fn:"receipt.svg",cat:"ui"},{id:"recycling",fn:"recycling.svg",cat:"health"},{id:"restaurant",fn:"restaurant.svg",cat:"food"},{id:"roadblock",fn:"roadblock.svg",cat:"uncategorized"},{id:"ruler",fn:"ruler.svg",cat:"objects"},{id:"sass",fn:"sass.svg",cat:"social"},{id:"sauna",fn:"sauna.svg",cat:"activities"},{id:"save",fn:"save.svg",cat:"ui"},{id:"scooter-prohibited",fn:"scooter-prohibited.svg",cat:"travel"},{id:"scooter",fn:"scooter.svg",cat:"travel"},{id:"search-icon-round-active",fn:"search-icon-round-active.svg",cat:"uncategorized"},{id:"search-icon-round-disabled",fn:"search-icon-round-disabled.svg",cat:"uncategorized"},{id:"search-icon-round-normal",fn:"search-icon-round-normal.svg",cat:"uncategorized"},{id:"search-icon-square-active",fn:"search-icon-square-active.svg",cat:"uncategorized"},{id:"search-icon-square-disabled",fn:"search-icon-square-disabled.svg",cat:"uncategorized"},{id:"search-icon-square-normal",fn:"search-icon-square-normal.svg",cat:"uncategorized"},{id:"share-outline",fn:"share-outline.svg",cat:"social"},{id:"share",fn:"share.svg",cat:"social"},{id:"shield-fire",fn:"shield-fire.svg",cat:"health"},{id:"shield-law-paragraph",fn:"shield-law-paragraph.svg",cat:"user"},{id:"shoes-prohibited",fn:"shoes-prohibited.svg",cat:"objects"},{id:"shop",fn:"shop.svg",cat:"objects"},{id:"shower",fn:"shower.svg",cat:"objects"},{id:"signature",fn:"signature.svg",cat:"objects"},{id:"skateboarding",fn:"skateboarding.svg",cat:"activities"},{id:"slack",fn:"slack.svg",cat:"social"},{id:"sledding",fn:"sledding.svg",cat:"activities"},{id:"smiley-neutral",fn:"smiley-neutral.svg",cat:"feedback"},{id:"smiley-sad",fn:"smiley-sad.svg",cat:"feedback"},{id:"smiley-smile",fn:"smiley-smile.svg",cat:"feedback"},{id:"smoking-prohibited",fn:"smoking-prohibited.svg",cat:"signs"},{id:"snow",fn:"snow.svg",cat:"objects"},{id:"sort",fn:"sort.svg",cat:"ui"},{id:"sound-off",fn:"sound-off.svg",cat:"status"},{id:"sound-on",fn:"sound-on.svg",cat:"status"},{id:"sparkles",fn:"sparkles.svg",cat:"objects"},{id:"stairs-down",fn:"stairs-down.svg",cat:"signs"},{id:"stairs-up",fn:"stairs-up.svg",cat:"signs"},{id:"stairs",fn:"stairs.svg",cat:"signs"},{id:"street-vendor",fn:"street-vendor.svg",cat:"places"},{id:"stroller-prohibited",fn:"stroller-prohibited.svg",cat:"objects"},{id:"stroller",fn:"stroller.svg",cat:"objects"},{id:"studded-tires",fn:"studded-tires.svg",cat:"objects"},{id:"svg",fn:"svg.svg",cat:"social"},{id:"swimming-area",fn:"swimming-area.svg",cat:"activities"},{id:"swingset",fn:"swingset.svg",cat:"places"},{id:"table",fn:"table.svg",cat:"data"},{id:"tap",fn:"tap.svg",cat:"objects"},{id:"target",fn:"target.svg",cat:"ui"},{id:"thumbs-down",fn:"thumbs-down.svg",cat:"feedback"},{id:"thumbs-up",fn:"thumbs-up.svg",cat:"feedback"},{id:"tickets",fn:"tickets.svg",cat:"objects"},{id:"toilet-unisex",fn:"toilet-unisex.svg",cat:"user"},{id:"toilet",fn:"toilet.svg",cat:"signs"},{id:"tool",fn:"tool.svg",cat:"objects"},{id:"touching-prohibited",fn:"touching-prohibited.svg",cat:"signs"},{id:"trail-gate",fn:"trail-gate.svg",cat:"objects"},{id:"trail",fn:"trail.svg",cat:"sign"},{id:"tram",fn:"tram.svg",cat:"travel"},{id:"trash-can",fn:"trash-can.svg",cat:"ui"},{id:"trash",fn:"trash.svg",cat:"activities"},{id:"twitter",fn:"twitter.svg",cat:"social"},{id:"two-people-dancing",fn:"two-people-dancing.svg",cat:"activities"},{id:"two-people-talking",fn:"two-people-talking.svg",cat:"activities"},{id:"umbrella-prohibited",fn:"umbrella-prohibited.svg",cat:"objects"},{id:"urban-landscape",fn:"urban-landscape.svg",cat:"places"},{id:"urinal",fn:"urinal.svg",cat:"signs"},{id:"user",fn:"user.svg",cat:"user"},{id:"van",fn:"van.svg",cat:"travel"},{id:"vertical-menu",fn:"vertical-menu.svg",cat:"ui"},{id:"viewpoint",fn:"viewpoint.svg",cat:"objects"},{id:"virus",fn:"virus.svg",cat:"objects"},{id:"vue",fn:"vue.svg",cat:"social"},{id:"walking",fn:"walking.svg",cat:"activities"},{id:"wardrobe-boys",fn:"wardrobe-boys.svg",cat:"signs"},{id:"wardrobe-girls",fn:"wardrobe-girls.svg",cat:"signs"},{id:"wardrobe",fn:"wardrobe.svg",cat:"objects"},{id:"waste-container",fn:"waste-container.svg",cat:"objects"},{id:"water-faucet",fn:"water-faucet.svg",cat:"health"},{id:"wheelchair-ramp",fn:"wheelchair-ramp.svg",cat:"activities"},{id:"wheelchair",fn:"wheelchair.svg",cat:"sign"},{id:"wifi",fn:"wifi.svg",cat:"signs"},{id:"wine-bottle",fn:"wine-bottle.svg",cat:"food"},{id:"workplace",fn:"workplace.svg",cat:"social"},{id:"wrench",fn:"wrench.svg",cat:"objects"},{id:"x",fn:"x.svg",cat:"social"}],A2=({propKey:r,spec:n,props:i,handleChange:l})=>{const c={BOOLEAN:"boolean",ICON:"icon",ARRAY:"array",OBJECT:"object",DATE:"ISOdatestring",NUMBER:"number"},h=(T,$)=>{l(r,{...i[r],[T]:$})},m=(T,$,N)=>{const R=[...i[r]];R[T]={...R[T],[$]:N},l(r,R)},D=()=>{const T=[...i[r],{}];l(r,T)},C=T=>{const $=i[r].filter((N,R)=>R!==T);l(r,$)};if(n.type===c.BOOLEAN)return O.jsx(n_,{label:n.name||r,forId:r,helptext:n.description||null,hasFieldset:!0,requiredTag:n.required,children:O.jsx(k0,{id:r,label:r,type:"checkbox",checked:i[r]||!1,onChange:T=>l(r,T.target.checked,n.displayAsFalse),labelPosition:"right",isSwitch:!0})});if(n.type===c.ICON)return O.jsxs(Lb,{label:n.name||r,helptext:n.description||null,id:r,value:i[r]||"",onChange:T=>l(r,T.target.value),requiredTag:n.required,children:[O.jsx("option",{value:""}),P4.map(T=>O.jsx("option",{value:T.id,children:T.id},T.id))]});if(n.type===c.DATE)return O.jsx(w0,{id:r,label:n.name||r,helptext:n.description||null,value:i[r]||"",multiple:n.variant==="multiple",maxlength:999,onChange:T=>l(r,T.target.value),requiredTag:n.required});if(Array.isArray(n)||Array.isArray(n.type)||Array.isArray(n.values)){const T=Array.isArray(n)?n:n.values||n.type;return O.jsxs(Lb,{label:n.name||r,helptext:n.description||null,id:r,value:i[r],onChange:$=>l(r,$.target.value),requiredTag:n.required,children:[O.jsx("option",{value:""}),T.map($=>O.jsx("option",{value:$,children:$},$))]})}return n.type===c.NUMBER?O.jsx(ev,{id:r,label:n.name||r,helptext:n.description||null,type:"number",value:i[r]||"",onChange:T=>l(r,parseFloat(T.currentTarget.value)),requiredTag:n.required}):n.type===c.OBJECT?(i[r]||(i[r]={}),O.jsxs("div",{children:[O.jsx("div",{className:"pkt-inputwrapper__label",children:O.jsx("h2",{children:n.name||r})}),n.description&&O.jsx("p",{children:n.description}),O.jsxs("fieldset",{children:[O.jsx("legend",{children:n.name||r}),Object.entries(n.properties).map(([T,$])=>O.jsx(A2,{propKey:T,props:i[r],spec:$,handleChange:(N,R)=>h(N,R)},T))]})]})):n.type===c.ARRAY&&n.items.type===c.OBJECT?(i[r]||(i[r]=[]),O.jsxs("div",{children:[O.jsx("div",{className:"pkt-inputwrapper__label",children:O.jsx("h2",{children:n.name||r})}),n.description&&O.jsx("p",{children:n.description}),i[r].map((T,$)=>O.jsx("div",{children:O.jsxs("fieldset",{children:[O.jsxs("legend",{children:["Item ",$+1]}),Object.entries(n.items.properties).map(([N,R])=>O.jsx(A2,{propKey:N,props:T,spec:R,handleChange:(L,j)=>m($,L,j)},N)),O.jsx($d,{onClick:()=>C($),children:"Fjern denne"})]})},$)),O.jsx($d,{onClick:D,children:"Legg til ny"})]})):O.jsx(ev,{id:r,label:n.name||r,helptext:n.description||null,type:"text",value:i[r]||"",onChange:T=>l(r,n.type==="number"?parseFloat(T.currentTarget.value):T.currentTarget.value),requiredTag:n.required})};Zg.registerLanguage("jsx",E4);const OE=({specs:r,children:n,fullWidth:i})=>{var He,dt;const l=r.props&&typeof r.props=="object"&&!Array.isArray(r.props)?Object.entries(r.props).reduce((Me,[Oe,de])=>(typeof de=="object"&&!Array.isArray(de)&&de.previewDefault!==void 0&&de.previewDefault!==null?(de.previewDefault==="false"&&(de.previewDefault=!1),de.previewDefault==="true"&&(de.previewDefault=!0),Me[Oe]=de.previewDefault):typeof de=="object"&&!Array.isArray(de)&&de.default!==void 0&&de.default!==null&&(de.default==="false"&&(de.default=!1),de.default==="true"&&(de.default=!0),Me[Oe]=de.default),Me),{}):{},[c,h]=$e.useState(0),[m,D]=$e.useState(l),[C,T]=$e.useState("light"),[$,N]=$e.useState(""),[R,L]=$e.useState(""),[j,J]=$e.useState(""),[G,Se]=$e.useState("Rediger innhold"),[q,W]=$e.useState([{text:"Rediger",icon:"adjust",active:!0},{text:"Kode (React)",icon:"react",active:!1},{text:`Kode (${r.isElement?"Element":"HTML"})`,icon:"code",active:!1},{text:"Egenskaper",icon:"list",active:!1}]),Z=Me=>{Me===1&&pe(),Me===2&&ae(),J(""),W(Oe=>Oe.map((de,Le)=>({...de,active:Le===Me})))},X=$e.useRef(null),ae=async()=>{if(r.isElement&&$e.isValidElement(Xe)){const Me=$e.isValidElement(Xe)?Xe.type.displayName||Xe.type.name:r.name,Oe=Object.entries(m).map(([Le,xe])=>{if(xe&&!be(xe)&&!Ge(xe))return typeof xe=="object"?`${Le}='${JSON.stringify(xe)}'`:`${Le}="${xe}"`}).join(" "),de=await Eb(`<${r.name||Me} ${Oe}>${G}</${r.name||Me}>`,{parser:"html",plugins:[j1]});N(`<!-- Denne koden bør testes grundig før bruk. Spør en Punkt-utvikler om du er usikker. -->
|
|
1545
|
+
`)})})]}):O.jsxs(O.Fragment,{children:[O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})}),O.jsx(Zo,{dataLabel:"Type",children:O.jsx("pre",{children:c.type&&n(c.type)})}),O.jsx(Zo,{dataLabel:"Standardverdi",children:O.jsx("pre",{children:i(c.default)})})]})]},l))})]}),r.events&&O.jsxs(O.Fragment,{children:[O.jsx("h2",{children:"Hendelser / handlinger"}),O.jsxs(Pb,{compact:!0,children:[O.jsx(Nb,{children:O.jsxs(rp,{children:[O.jsx(gl,{children:"Event"}),O.jsx(gl,{children:"Beskrivelse"}),O.jsx(gl,{children:"Type"})]})}),O.jsx(Rb,{children:Object.entries(r.events||{}).map(([l,c])=>O.jsxs(rp,{children:[O.jsx(Zo,{dataLabel:"Event",children:O.jsx("pre",{children:l})}),O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})}),O.jsx(Zo,{dataLabel:"Type",children:c.type})]},l))})]})]}),r.slots&&O.jsxs(O.Fragment,{children:[O.jsx("h2",{children:"Innhold"}),O.jsxs(Pb,{compact:!0,children:[O.jsx(Nb,{children:O.jsxs(rp,{children:[O.jsx(gl,{children:"Slot"}),O.jsx(gl,{children:"Beskrivelse"})]})}),O.jsx(Rb,{children:Object.entries(r.slots||{}).map(([l,c])=>O.jsxs(rp,{children:[O.jsx(Zo,{dataLabel:"Slot",children:O.jsx("pre",{children:l})}),O.jsx(Zo,{dataLabel:"Beskrivelse",children:O.jsx("span",{dangerouslySetInnerHTML:{__html:c.description||""}})})]},l))})]})]})]})},$4=zr({tagName:"pkt-select",elementClass:Nh,react:$e,displayName:"PktSelect",events:{onChange:"change",onInput:"input",onBlur:"blur",onFocus:"focus",onValueChange:"valueChange",onToggleHelpText:"toggleHelpText"}}),Lb=$e.forwardRef(({children:r,helptext:n,...i},l)=>O.jsxs($4,{ref:l,...i,children:[n&&O.jsx("div",{slot:"helptext",className:"pkt-contents",children:n}),r]}));Lb.displayName="PktSelect";const P4=[{id:"24h",fn:"24h.svg",cat:"health"},{id:"access-prohibited",fn:"access-prohibited.svg",cat:"signs"},{id:"accessibility",fn:"accessibility.svg",cat:"signs"},{id:"accessible-water-access",fn:"accessible-water-access.svg",cat:"activities"},{id:"active-person",fn:"active-person.svg",cat:"activities"},{id:"adjust",fn:"adjust.svg",cat:"ui"},{id:"advice",fn:"advice.svg",cat:"social"},{id:"alcohol-prohibited",fn:"alcohol-prohibited.svg",cat:"food"},{id:"alert-circle",fn:"alert-circle.svg",cat:"status"},{id:"alert-error-system",fn:"alert-error-system.svg",cat:"status"},{id:"alert-error",fn:"alert-error.svg",cat:"status"},{id:"alert-information",fn:"alert-information.svg",cat:"status"},{id:"alert-success-system",fn:"alert-success-system.svg",cat:"status"},{id:"alert-success",fn:"alert-success.svg",cat:"status"},{id:"alert-warning",fn:"alert-warning.svg",cat:"status"},{id:"ambulance",fn:"ambulance.svg",cat:"travel"},{id:"apple",fn:"apple.svg",cat:"food"},{id:"archive",fn:"archive.svg",cat:"ui"},{id:"arrow-circle",fn:"arrow-circle.svg",cat:"ui"},{id:"arrow-return",fn:"arrow-return.svg",cat:"navigation"},{id:"arrow",fn:"arrow.svg",cat:"navigation"},{id:"arts-and-culture",fn:"arts-and-culture.svg",cat:"places"},{id:"attachment",fn:"attachment.svg",cat:"ui"},{id:"audioguide",fn:"audioguide.svg",cat:"objects"},{id:"baby-bottle",fn:"baby-bottle.svg",cat:"food"},{id:"baby-changing-room",fn:"baby-changing-room.svg",cat:"activities"},{id:"backpack-prohibited",fn:"backpack-prohibited.svg",cat:"objects"},{id:"backpack",fn:"backpack.svg",cat:"services"},{id:"ball-sports",fn:"ball-sports.svg",cat:"activities"},{id:"balloons",fn:"balloons.svg",cat:"objects"},{id:"bath",fn:"bath.svg",cat:"objects"},{id:"bed",fn:"bed.svg",cat:"objects"},{id:"beehive",fn:"beehive.svg",cat:"objects"},{id:"bicycle-parking",fn:"bicycle-parking.svg",cat:"travel"},{id:"bicycle-prohibited",fn:"bicycle-prohibited.svg",cat:"travel"},{id:"bicycle-service",fn:"bicycle-service.svg",cat:"travel"},{id:"bicycle",fn:"bicycle.svg",cat:"travel"},{id:"books",fn:"books.svg",cat:"health"},{id:"boys-shower",fn:"boys-shower.svg",cat:"signs"},{id:"boys-toilet",fn:"boys-toilet.svg",cat:"user"},{id:"brain-heart",fn:"brain-heart.svg",cat:"health"},{id:"brain-signal",fn:"brain-signal.svg",cat:"health"},{id:"brain",fn:"brain.svg",cat:"health"},{id:"briefcase",fn:"briefcase.svg",cat:"objects"},{id:"bulb",fn:"bulb.svg",cat:"objects"},{id:"bullseye",fn:"bullseye.svg",cat:"objects"},{id:"bus",fn:"bus.svg",cat:"travel"},{id:"cafe",fn:"cafe.svg",cat:"food"},{id:"calendar",fn:"calendar.svg",cat:"ui"},{id:"camera-surveillance-CCTV",fn:"camera-surveillance-CCTV.svg",cat:"objects"},{id:"camera",fn:"camera.svg",cat:"objects"},{id:"campfire-site",fn:"campfire-site.svg",cat:"health"},{id:"camping",fn:"camping.svg",cat:"places"},{id:"car",fn:"car.svg",cat:"travel"},{id:"character-exclamation-mark",fn:"character-exclamation-mark.svg",cat:"status"},{id:"character-information",fn:"character-information.svg",cat:"status"},{id:"charging-point",fn:"charging-point.svg",cat:"objects"},{id:"check-big",fn:"check-big.svg",cat:"ui"},{id:"check-box-checked",fn:"check-box-checked.svg",cat:"ui"},{id:"check-box-unchecked",fn:"check-box-unchecked.svg",cat:"ui"},{id:"check-circle",fn:"check-circle.svg",cat:"ui"},{id:"check-medium",fn:"check-medium.svg",cat:"ui"},{id:"check",fn:"check.svg",cat:"ui"},{id:"chevron-down",fn:"chevron-down.svg",cat:"navigation"},{id:"chevron-left",fn:"chevron-left.svg",cat:"navigation"},{id:"chevron-right",fn:"chevron-right.svg",cat:"navigation"},{id:"chevron-thin-down",fn:"chevron-thin-down.svg",cat:"navigation"},{id:"chevron-thin-left",fn:"chevron-thin-left.svg",cat:"navigation"},{id:"chevron-thin-right",fn:"chevron-thin-right.svg",cat:"navigation"},{id:"chevron-thin-up",fn:"chevron-thin-up.svg",cat:"navigation"},{id:"chevron-up-and-down",fn:"chevron-up-and-down.svg",cat:"ui"},{id:"chevron-up",fn:"chevron-up.svg",cat:"navigation"},{id:"childrens-toilet",fn:"childrens-toilet.svg",cat:"signs"},{id:"circular-economy",fn:"circular-economy.svg",cat:"ui"},{id:"climbing",fn:"climbing.svg",cat:"activities"},{id:"clock-history",fn:"clock-history.svg",cat:"ui"},{id:"clock",fn:"clock.svg",cat:"ui"},{id:"close",fn:"close.svg",cat:"ui"},{id:"cloud",fn:"cloud.svg",cat:"objects"},{id:"code",fn:"code.svg",cat:"data"},{id:"coffee",fn:"coffee.svg",cat:"food"},{id:"cogwheel",fn:"cogwheel.svg",cat:"ui"},{id:"coin-stacks",fn:"coin-stacks.svg",cat:"health"},{id:"computer",fn:"computer.svg",cat:"objects"},{id:"cookie",fn:"cookie.svg",cat:"ui"},{id:"copy",fn:"copy.svg",cat:"ui"},{id:"crane",fn:"crane.svg",cat:"places"},{id:"crayfish",fn:"crayfish.svg",cat:"objects"},{id:"cross-circle-big",fn:"cross-circle-big.svg",cat:"ui"},{id:"cross-circle-fill-large",fn:"cross-circle-fill-large.svg",cat:"ui"},{id:"cross-circle-fill",fn:"cross-circle-fill.svg",cat:"ui"},{id:"cross-circle",fn:"cross-circle.svg",cat:"ui"},{id:"cross",fn:"cross.svg",cat:"ui"},{id:"cupboard",fn:"cupboard.svg",cat:"objects"},{id:"dancing",fn:"dancing.svg",cat:"activities"},{id:"data",fn:"data.svg",cat:"data"},{id:"deer",fn:"deer.svg",cat:"objects"},{id:"defibrillators",fn:"defibrillators.svg",cat:"signs"},{id:"district",fn:"district.svg",cat:"places"},{id:"diving-prohibited",fn:"diving-prohibited.svg",cat:"activities"},{id:"dock",fn:"dock.svg",cat:"places"},{id:"document-code",fn:"document-code.svg",cat:"ui"},{id:"document-pdf",fn:"document-pdf.svg",cat:"ui"},{id:"document-plain",fn:"document-plain.svg",cat:"ui"},{id:"document-table",fn:"document-table.svg",cat:"ui"},{id:"document-text",fn:"document-text.svg",cat:"ui"},{id:"dog-forbidden",fn:"dog-forbidden.svg",cat:"objects"},{id:"dog-on-a-leash",fn:"dog-on-a-leash.svg",cat:"objects"},{id:"download",fn:"download.svg",cat:"ui"},{id:"drag",fn:"drag.svg",cat:"ui"},{id:"drinking-area-refreshments",fn:"drinking-area-refreshments.svg",cat:"food"},{id:"drone",fn:"drone.svg",cat:"objects"},{id:"drugs-prohibited",fn:"drugs-prohibited.svg",cat:"objects"},{id:"ecg-heart",fn:"ecg-heart.svg",cat:"health"},{id:"edit",fn:"edit.svg",cat:"ui"},{id:"elderly",fn:"elderly.svg",cat:"user"},{id:"electric-car",fn:"electric-car.svg",cat:"travel"},{id:"electric-van",fn:"electric-van.svg",cat:"travel"},{id:"elevator",fn:"elevator.svg",cat:"signs"},{id:"email",fn:"email.svg",cat:"social"},{id:"escalator",fn:"escalator.svg",cat:"signs"},{id:"exclamation-mark-circle",fn:"exclamation-mark-circle.svg",cat:"status"},{id:"exclamation-mark-square",fn:"exclamation-mark-square.svg",cat:"status"},{id:"exit-door",fn:"exit-door.svg",cat:"ui"},{id:"exit",fn:"exit.svg",cat:"navigation"},{id:"expand",fn:"expand.svg",cat:"ui"},{id:"eye",fn:"eye.svg",cat:"ui"},{id:"face-almost-happy",fn:"face-almost-happy.svg",cat:"feedback"},{id:"face-almost-sad",fn:"face-almost-sad.svg",cat:"feedback"},{id:"face-happy",fn:"face-happy.svg",cat:"feedback"},{id:"face-neutral",fn:"face-neutral.svg",cat:"feedback"},{id:"face-sad",fn:"face-sad.svg",cat:"feedback"},{id:"facebook",fn:"facebook.svg",cat:"social"},{id:"factory-fill",fn:"factory-fill.svg",cat:"places"},{id:"feedback",fn:"feedback.svg",cat:"social"},{id:"figma",fn:"figma.svg",cat:"social"},{id:"filming-prohibited",fn:"filming-prohibited.svg",cat:"signs"},{id:"filter",fn:"filter.svg",cat:"ui"},{id:"fire-prohibited",fn:"fire-prohibited.svg",cat:"signs"},{id:"fire-safety",fn:"fire-safety.svg",cat:"health"},{id:"fireworks-prohibited",fn:"fireworks-prohibited.svg",cat:"signs"},{id:"fishing-prohibited",fn:"fishing-prohibited.svg",cat:"signs"},{id:"fixed-bench",fn:"fixed-bench.svg",cat:"objects"},{id:"fixed-grill",fn:"fixed-grill.svg",cat:"objects"},{id:"flammable-waste",fn:"flammable-waste.svg",cat:"signs"},{id:"flash-prohibited",fn:"flash-prohibited.svg",cat:"objects"},{id:"folder",fn:"folder.svg",cat:"ui"},{id:"food-and-drinks-prohibited",fn:"food-and-drinks-prohibited.svg",cat:"food"},{id:"fountain",fn:"fountain.svg",cat:"places"},{id:"game-console",fn:"game-console.svg",cat:"objects"},{id:"girls-shower",fn:"girls-shower.svg",cat:"signs"},{id:"girls-toilet",fn:"girls-toilet.svg",cat:"user"},{id:"github",fn:"github.svg",cat:"social"},{id:"graffiti-allowed",fn:"graffiti-allowed.svg",cat:"objects"},{id:"graffiti-prohibited",fn:"graffiti-prohibited.svg",cat:"objects"},{id:"graph",fn:"graph.svg",cat:"data"},{id:"grid",fn:"grid.svg",cat:"ui"},{id:"gym",fn:"gym.svg",cat:"objects"},{id:"handicap-elevator",fn:"handicap-elevator.svg",cat:"signs"},{id:"handicap",fn:"handicap.svg",cat:"user"},{id:"hands-globe",fn:"hands-globe.svg",cat:"health"},{id:"headset",fn:"headset.svg",cat:"objects"},{id:"heart-hand",fn:"heart-hand.svg",cat:"health"},{id:"heart-plus",fn:"heart-plus.svg",cat:"health"},{id:"heart",fn:"heart.svg",cat:"health"},{id:"height-restriction",fn:"height-restriction.svg",cat:"objects"},{id:"helmet",fn:"helmet.svg",cat:"objects"},{id:"hiking-trail",fn:"hiking-trail.svg",cat:"places"},{id:"holding-hands",fn:"holding-hands.svg",cat:"user"},{id:"home",fn:"home.svg",cat:"places"},{id:"horizontal-menu",fn:"horizontal-menu.svg",cat:"ui"},{id:"house-heart",fn:"house-heart.svg",cat:"places"},{id:"ice-skating",fn:"ice-skating.svg",cat:"objects"},{id:"indoor-pool",fn:"indoor-pool.svg",cat:"activities"},{id:"information",fn:"information.svg",cat:"status"},{id:"instagram",fn:"instagram.svg",cat:"social"},{id:"invoice",fn:"invoice.svg",cat:"ui"},{id:"key",fn:"key.svg",cat:"objects"},{id:"ladies-toilet",fn:"ladies-toilet.svg",cat:"user"},{id:"language",fn:"language.svg",cat:"user"},{id:"law-paragraph",fn:"law-paragraph.svg",cat:"user"},{id:"lecture-workplace",fn:"lecture-workplace.svg",cat:"sign"},{id:"lecture",fn:"lecture.svg",cat:"activities"},{id:"life-ring",fn:"life-ring.svg",cat:"objects"},{id:"link",fn:"link.svg",cat:"ui"},{id:"linkedin",fn:"linkedin.svg",cat:"social"},{id:"list",fn:"list.svg",cat:"ui"},{id:"living-room",fn:"living-room.svg",cat:"objects"},{id:"location-pin-filled",fn:"location-pin-filled.svg",cat:"travel"},{id:"location-pin",fn:"location-pin.svg",cat:"travel"},{id:"lock-locked",fn:"lock-locked.svg",cat:"ui"},{id:"lock-unlocked",fn:"lock-unlocked.svg",cat:"ui"},{id:"luggage-prohibited",fn:"luggage-prohibited.svg",cat:"objects"},{id:"magnifying-glass-big",fn:"magnifying-glass-big.svg",cat:"ui"},{id:"magnifying-glass-small",fn:"magnifying-glass-small.svg",cat:"ui"},{id:"map",fn:"map.svg",cat:"travel"},{id:"medicine-cabinet",fn:"medicine-cabinet.svg",cat:"objects"},{id:"megaphone",fn:"megaphone.svg",cat:"objects"},{id:"memorial-stone",fn:"memorial-stone.svg",cat:"objects"},{id:"mens-toilet",fn:"mens-toilet.svg",cat:"user"},{id:"menu",fn:"menu.svg",cat:"navigation"},{id:"message",fn:"message.svg",cat:"social"},{id:"minimize",fn:"minimize.svg",cat:"ui"},{id:"minus-circle-fill",fn:"minus-circle-fill.svg",cat:"ui"},{id:"minus-circle",fn:"minus-circle.svg",cat:"ui"},{id:"minus-sign",fn:"minus-sign.svg",cat:"ui"},{id:"mobile-phone",fn:"mobile-phone.svg",cat:"objects"},{id:"moon",fn:"moon.svg",cat:"objects"},{id:"motorcycle",fn:"motorcycle.svg",cat:"travel"},{id:"museum",fn:"museum.svg",cat:"places"},{id:"music-notes",fn:"music-notes.svg",cat:"objects"},{id:"nature-plant-2",fn:"nature-plant-2.svg",cat:"objects"},{id:"nature-plant",fn:"nature-plant.svg",cat:"objects"},{id:"new-window-small",fn:"new-window-small.svg",cat:"navigation"},{id:"new-window",fn:"new-window.svg",cat:"navigation"},{id:"no-walking",fn:"no-walking.svg",cat:"activities"},{id:"nodejs",fn:"nodejs.svg",cat:"social"},{id:"obstacle",fn:"obstacle.svg",cat:"objects"},{id:"organization",fn:"organization.svg",cat:"places"},{id:"package",fn:"package.svg",cat:"data"},{id:"paint-bucket",fn:"paint-bucket.svg",cat:"objects"},{id:"palette",fn:"palette.svg",cat:"objects"},{id:"paragraph",fn:"paragraph.svg",cat:"ui"},{id:"park",fn:"park.svg",cat:"places"},{id:"parking-meter",fn:"parking-meter.svg",cat:"signs"},{id:"partner-workout",fn:"partner-workout.svg",cat:"activities"},{id:"paste",fn:"paste.svg",cat:"ui"},{id:"picnic-table",fn:"picnic-table.svg",cat:"objects"},{id:"picture",fn:"picture.svg",cat:"objects"},{id:"placeholder-icon",fn:"placeholder-icon.svg",cat:"ui"},{id:"planter-box",fn:"planter-box.svg",cat:"places"},{id:"playground",fn:"playground.svg",cat:"places"},{id:"plus-circle-fill",fn:"plus-circle-fill.svg",cat:"ui"},{id:"plus-circle",fn:"plus-circle.svg",cat:"ui"},{id:"plus-sign",fn:"plus-sign.svg",cat:"ui"},{id:"pregnant",fn:"pregnant.svg",cat:"user"},{id:"pride-heart",fn:"pride-heart.svg",cat:"health"},{id:"print",fn:"print.svg",cat:"objects"},{id:"privacy",fn:"privacy.svg",cat:"user"},{id:"process-back",fn:"process-back.svg",cat:"ui"},{id:"process-forward",fn:"process-forward.svg",cat:"ui"},{id:"process-iteration",fn:"process-iteration.svg",cat:"ui"},{id:"processing",fn:"processing.svg",cat:"ui"},{id:"prohibited",fn:"prohibited.svg",cat:"signs"},{id:"punkt-circle-blue",fn:"punkt-circle-blue.svg",cat:"social"},{id:"qr-code",fn:"qr-code.svg",cat:"ui"},{id:"question",fn:"question.svg",cat:"ui"},{id:"radio-checked",fn:"radio-checked.svg",cat:"ui"},{id:"radio-unchecked",fn:"radio-unchecked.svg",cat:"ui"},{id:"react",fn:"react.svg",cat:"social"},{id:"receipt",fn:"receipt.svg",cat:"ui"},{id:"recycling",fn:"recycling.svg",cat:"health"},{id:"restaurant",fn:"restaurant.svg",cat:"food"},{id:"roadblock",fn:"roadblock.svg",cat:"objects"},{id:"ruler",fn:"ruler.svg",cat:"objects"},{id:"sass",fn:"sass.svg",cat:"social"},{id:"sauna",fn:"sauna.svg",cat:"activities"},{id:"save",fn:"save.svg",cat:"ui"},{id:"scooter-prohibited",fn:"scooter-prohibited.svg",cat:"travel"},{id:"scooter",fn:"scooter.svg",cat:"travel"},{id:"search-icon-round-active",fn:"search-icon-round-active.svg",cat:"uncategorized"},{id:"search-icon-round-disabled",fn:"search-icon-round-disabled.svg",cat:"uncategorized"},{id:"search-icon-round-normal",fn:"search-icon-round-normal.svg",cat:"uncategorized"},{id:"search-icon-square-active",fn:"search-icon-square-active.svg",cat:"uncategorized"},{id:"search-icon-square-disabled",fn:"search-icon-square-disabled.svg",cat:"uncategorized"},{id:"search-icon-square-normal",fn:"search-icon-square-normal.svg",cat:"uncategorized"},{id:"share-outline",fn:"share-outline.svg",cat:"social"},{id:"share",fn:"share.svg",cat:"social"},{id:"shield-fire",fn:"shield-fire.svg",cat:"health"},{id:"shield-law-paragraph",fn:"shield-law-paragraph.svg",cat:"user"},{id:"shoes-prohibited",fn:"shoes-prohibited.svg",cat:"objects"},{id:"shopping-bag",fn:"shopping-bag.svg",cat:"objects"},{id:"shower",fn:"shower.svg",cat:"objects"},{id:"signature",fn:"signature.svg",cat:"objects"},{id:"skateboarding",fn:"skateboarding.svg",cat:"activities"},{id:"slack",fn:"slack.svg",cat:"social"},{id:"sledding",fn:"sledding.svg",cat:"activities"},{id:"smiley-neutral",fn:"smiley-neutral.svg",cat:"feedback"},{id:"smiley-sad",fn:"smiley-sad.svg",cat:"feedback"},{id:"smiley-smile",fn:"smiley-smile.svg",cat:"feedback"},{id:"smoking-prohibited",fn:"smoking-prohibited.svg",cat:"signs"},{id:"snow",fn:"snow.svg",cat:"objects"},{id:"sort",fn:"sort.svg",cat:"ui"},{id:"sound-off",fn:"sound-off.svg",cat:"status"},{id:"sound-on",fn:"sound-on.svg",cat:"status"},{id:"sparkles",fn:"sparkles.svg",cat:"objects"},{id:"stairs-down",fn:"stairs-down.svg",cat:"signs"},{id:"stairs-up",fn:"stairs-up.svg",cat:"signs"},{id:"stairs",fn:"stairs.svg",cat:"signs"},{id:"street-vendor",fn:"street-vendor.svg",cat:"places"},{id:"stroller-prohibited",fn:"stroller-prohibited.svg",cat:"objects"},{id:"stroller",fn:"stroller.svg",cat:"objects"},{id:"studded-tires",fn:"studded-tires.svg",cat:"objects"},{id:"svg",fn:"svg.svg",cat:"social"},{id:"swimming-area",fn:"swimming-area.svg",cat:"activities"},{id:"swingset",fn:"swingset.svg",cat:"places"},{id:"table",fn:"table.svg",cat:"data"},{id:"tap",fn:"tap.svg",cat:"objects"},{id:"target",fn:"target.svg",cat:"ui"},{id:"thumbs-down",fn:"thumbs-down.svg",cat:"feedback"},{id:"thumbs-up",fn:"thumbs-up.svg",cat:"feedback"},{id:"tickets",fn:"tickets.svg",cat:"objects"},{id:"toilet-unisex",fn:"toilet-unisex.svg",cat:"user"},{id:"toilet",fn:"toilet.svg",cat:"signs"},{id:"tool",fn:"tool.svg",cat:"objects"},{id:"touching-prohibited",fn:"touching-prohibited.svg",cat:"signs"},{id:"trail-gate",fn:"trail-gate.svg",cat:"objects"},{id:"trail",fn:"trail.svg",cat:"sign"},{id:"tram",fn:"tram.svg",cat:"travel"},{id:"trash-can",fn:"trash-can.svg",cat:"ui"},{id:"trash",fn:"trash.svg",cat:"activities"},{id:"twitter",fn:"twitter.svg",cat:"social"},{id:"two-people-dancing",fn:"two-people-dancing.svg",cat:"activities"},{id:"two-people-talking",fn:"two-people-talking.svg",cat:"activities"},{id:"umbrella-prohibited",fn:"umbrella-prohibited.svg",cat:"objects"},{id:"urban-landscape",fn:"urban-landscape.svg",cat:"places"},{id:"urinal",fn:"urinal.svg",cat:"signs"},{id:"user",fn:"user.svg",cat:"user"},{id:"van",fn:"van.svg",cat:"travel"},{id:"vertical-menu",fn:"vertical-menu.svg",cat:"ui"},{id:"viewpoint",fn:"viewpoint.svg",cat:"objects"},{id:"virus",fn:"virus.svg",cat:"objects"},{id:"vue",fn:"vue.svg",cat:"social"},{id:"walking",fn:"walking.svg",cat:"activities"},{id:"wardrobe-boys",fn:"wardrobe-boys.svg",cat:"signs"},{id:"wardrobe-girls",fn:"wardrobe-girls.svg",cat:"signs"},{id:"wardrobe",fn:"wardrobe.svg",cat:"objects"},{id:"waste-container",fn:"waste-container.svg",cat:"objects"},{id:"water-faucet",fn:"water-faucet.svg",cat:"health"},{id:"wheelchair-ramp",fn:"wheelchair-ramp.svg",cat:"activities"},{id:"wheelchair",fn:"wheelchair.svg",cat:"sign"},{id:"wifi",fn:"wifi.svg",cat:"signs"},{id:"wine-bottle",fn:"wine-bottle.svg",cat:"food"},{id:"workplace",fn:"workplace.svg",cat:"social"},{id:"wrench",fn:"wrench.svg",cat:"objects"},{id:"x",fn:"x.svg",cat:"social"}],A2=({propKey:r,spec:n,props:i,handleChange:l})=>{const c={BOOLEAN:"boolean",ICON:"icon",ARRAY:"array",OBJECT:"object",DATE:"ISOdatestring",NUMBER:"number"},h=(T,$)=>{l(r,{...i[r],[T]:$})},m=(T,$,N)=>{const R=[...i[r]];R[T]={...R[T],[$]:N},l(r,R)},D=()=>{const T=[...i[r],{}];l(r,T)},C=T=>{const $=i[r].filter((N,R)=>R!==T);l(r,$)};if(n.type===c.BOOLEAN)return O.jsx(n_,{label:n.name||r,forId:r,helptext:n.description||null,hasFieldset:!0,requiredTag:n.required,children:O.jsx(k0,{id:r,label:r,type:"checkbox",checked:i[r]||!1,onChange:T=>l(r,T.target.checked,n.displayAsFalse),labelPosition:"right",isSwitch:!0})});if(n.type===c.ICON)return O.jsxs(Lb,{label:n.name||r,helptext:n.description||null,id:r,value:i[r]||"",onChange:T=>l(r,T.target.value),requiredTag:n.required,children:[O.jsx("option",{value:""}),P4.map(T=>O.jsx("option",{value:T.id,children:T.id},T.id))]});if(n.type===c.DATE)return O.jsx(w0,{id:r,label:n.name||r,helptext:n.description||null,value:i[r]||"",multiple:n.variant==="multiple",maxlength:999,onChange:T=>l(r,T.target.value),requiredTag:n.required});if(Array.isArray(n)||Array.isArray(n.type)||Array.isArray(n.values)){const T=Array.isArray(n)?n:n.values||n.type;return O.jsxs(Lb,{label:n.name||r,helptext:n.description||null,id:r,value:i[r],onChange:$=>l(r,$.target.value),requiredTag:n.required,children:[O.jsx("option",{value:""}),T.map($=>O.jsx("option",{value:$,children:$},$))]})}return n.type===c.NUMBER?O.jsx(ev,{id:r,label:n.name||r,helptext:n.description||null,type:"number",value:i[r]||"",onChange:T=>l(r,parseFloat(T.currentTarget.value)),requiredTag:n.required}):n.type===c.OBJECT?(i[r]||(i[r]={}),O.jsxs("div",{children:[O.jsx("div",{className:"pkt-inputwrapper__label",children:O.jsx("h2",{children:n.name||r})}),n.description&&O.jsx("p",{children:n.description}),O.jsxs("fieldset",{children:[O.jsx("legend",{children:n.name||r}),Object.entries(n.properties).map(([T,$])=>O.jsx(A2,{propKey:T,props:i[r],spec:$,handleChange:(N,R)=>h(N,R)},T))]})]})):n.type===c.ARRAY&&n.items.type===c.OBJECT?(i[r]||(i[r]=[]),O.jsxs("div",{children:[O.jsx("div",{className:"pkt-inputwrapper__label",children:O.jsx("h2",{children:n.name||r})}),n.description&&O.jsx("p",{children:n.description}),i[r].map((T,$)=>O.jsx("div",{children:O.jsxs("fieldset",{children:[O.jsxs("legend",{children:["Item ",$+1]}),Object.entries(n.items.properties).map(([N,R])=>O.jsx(A2,{propKey:N,props:T,spec:R,handleChange:(L,j)=>m($,L,j)},N)),O.jsx($d,{onClick:()=>C($),children:"Fjern denne"})]})},$)),O.jsx($d,{onClick:D,children:"Legg til ny"})]})):O.jsx(ev,{id:r,label:n.name||r,helptext:n.description||null,type:"text",value:i[r]||"",onChange:T=>l(r,n.type==="number"?parseFloat(T.currentTarget.value):T.currentTarget.value),requiredTag:n.required})};Zg.registerLanguage("jsx",E4);const OE=({specs:r,children:n,fullWidth:i})=>{var He,dt;const l=r.props&&typeof r.props=="object"&&!Array.isArray(r.props)?Object.entries(r.props).reduce((Me,[Oe,de])=>(typeof de=="object"&&!Array.isArray(de)&&de.previewDefault!==void 0&&de.previewDefault!==null?(de.previewDefault==="false"&&(de.previewDefault=!1),de.previewDefault==="true"&&(de.previewDefault=!0),Me[Oe]=de.previewDefault):typeof de=="object"&&!Array.isArray(de)&&de.default!==void 0&&de.default!==null&&(de.default==="false"&&(de.default=!1),de.default==="true"&&(de.default=!0),Me[Oe]=de.default),Me),{}):{},[c,h]=$e.useState(0),[m,D]=$e.useState(l),[C,T]=$e.useState("light"),[$,N]=$e.useState(""),[R,L]=$e.useState(""),[j,J]=$e.useState(""),[G,Se]=$e.useState("Rediger innhold"),[q,W]=$e.useState([{text:"Rediger",icon:"adjust",active:!0},{text:"Kode (React)",icon:"react",active:!1},{text:`Kode (${r.isElement?"Element":"HTML"})`,icon:"code",active:!1},{text:"Egenskaper",icon:"list",active:!1}]),Z=Me=>{Me===1&&pe(),Me===2&&ae(),J(""),W(Oe=>Oe.map((de,Le)=>({...de,active:Le===Me})))},X=$e.useRef(null),ae=async()=>{if(r.isElement&&$e.isValidElement(Xe)){const Me=$e.isValidElement(Xe)?Xe.type.displayName||Xe.type.name:r.name,Oe=Object.entries(m).map(([Le,xe])=>{if(xe&&!be(xe)&&!Ge(xe))return typeof xe=="object"?`${Le}='${JSON.stringify(xe)}'`:`${Le}="${xe}"`}).join(" "),de=await Eb(`<${r.name||Me} ${Oe}>${G}</${r.name||Me}>`,{parser:"html",plugins:[j1]});N(`<!-- Denne koden bør testes grundig før bruk. Spør en Punkt-utvikler om du er usikker. -->
|
|
1546
1546
|
`+de)}else{const Me=await Eb(X.current.innerHTML,{parser:"html",plugins:[j1]});N(Me.replace(/<\!--.*?-->/g,""))}},pe=async()=>{const Me=await bL(Xe);return L(Me),Promise.resolve()},Te=(Me,Oe)=>{navigator.clipboard.writeText(Oe).then(()=>{J(Me),console.log("Copied to clipboard",Me)})},be=Me=>Array.isArray(Me)&&Me.length===0,Ge=Me=>Me&&typeof Me=="object"&&!Object.keys(Me).length,qe=(Me,Oe)=>O.jsxs("div",{className:"pkt-preview__copy",children:[j===Me&&O.jsx("span",{className:"pkt-preview__copied",children:"Kode kopiert til utklippstavle"}),O.jsx($d,{skin:"tertiary",variant:"icon-only",size:"small",iconName:"copy",onClick:()=>Te(Me,Oe),children:"Kopier kode"})]}),Xe=$e.isValidElement(n)&&$e.cloneElement(n,{...m},n.props.children?n.props.children:(He=r.slots)!=null&&He.default?G:null),nt=(Me,Oe,de=!1)=>{if(h(c+1),!de&&(!Oe||Oe=="false")){const{[Me]:Le,...xe}=m;D(xe)}else D(Le=>({...Le,[Me]:Oe}))};return O.jsxs("div",{className:"pkt-preview",children:[O.jsxs("div",{className:"pkt-preview__component-container","data-mode":C,children:[r["dark-mode"]&&O.jsx("div",{className:"pkt-preview__mode",children:O.jsx(k0,{id:"mode",label:"Dark mode",type:"checkbox",checked:C==="dark",onChange:Me=>T(Me.target.checked?"dark":"light"),labelPosition:"right",isSwitch:!0})}),O.jsx("div",{className:`pkt-preview__component ${i&&"pkt-preview__component--fullwidth"}`,ref:X,children:O.jsx("div",{children:Xe})},c)]}),O.jsx(LE,{tabs:q,onTabSelected:Z}),O.jsxs("div",{className:`pkt-grid pkt-preview__opts ${q[0].active?"":"pkt-hide"}`,children:[((dt=r.slots)==null?void 0:dt.default)&&!n.props.children&&O.jsxs("div",{className:"pkt-cell pkt-cell--span12 pkt-cell--span6-phablet-up",children:[O.jsx(Yh,{size:"small",skin:"blue-light",textStyle:"thin-text",children:"children"}),O.jsx(ev,{id:"slot",label:"Slot",helptext:r.slots.default.description||"Innholdet i slot",type:"text",value:G,onChange:Me=>Se(Me.currentTarget.value)})]}),r.props&&typeof r.props=="object"&&!Array.isArray(r.props)?Object.entries(r.props).map(([Me,Oe])=>O.jsxs("div",{className:"pkt-cell pkt-cell--span12 pkt-cell--span6-phablet-up",children:[O.jsx(Yh,{size:"small",skin:"blue-light",textStyle:"thin-text",children:Me}),O.jsx(A2,{propKey:Me,props:m,spec:Oe,handleChange:nt})]},Me)):O.jsx("p",{children:"OBS! Specs mangler props!"})]}),O.jsxs("div",{className:`pkt-preview__code ${q[1].active?"":"pkt-hide"}`,children:[O.jsx(Zg,{language:"jsx",style:RE,children:R}),qe("jsx",R)]}),O.jsxs("div",{className:`pkt-preview__code ${q[2].active?"":"pkt-hide"}`,children:[O.jsx(Zg,{language:"html",style:RE,children:$}),qe("html",$)]}),O.jsx("div",{className:`pkt-preview__specs ${q[3].active?"":"pkt-hide"}`,children:O.jsx(A4,{specs:r})})]})};OE.displayName="PktPreview";const N4=zr({tagName:"pkt-progressbar",elementClass:aa,react:$e,displayName:"PktProgressbar",events:{}}),BE=$e.forwardRef(({children:r,...n},i)=>O.jsx(N4,{ref:i,...n,children:O.jsx("div",{className:"pkt-contents",children:r})}));BE.displayName="PktProgressbar";const R4=zr({tagName:"pkt-radiobutton",elementClass:mu,react:$e,displayName:"PktRadioButton",events:{onChange:"change",onInput:"input",onBlur:"blur",onFocus:"focus",onValueChange:"valueChange"}}),L4=$e.forwardRef(({appearance:r="local",disabled:n=!1,fullwidth:i=!1,id:l,label:c,name:h,placeholder:m="Søk…",suggestions:D,value:C="",action:T,method:$,onChange:N,onSearch:R,onSuggestionClick:L,...j},J)=>{const G=(Z,X)=>{Z?Z():L&&L(X)},Se=Z=>{C=Z.target.value},q=`pkt-searchinput pkt-searchinput--${r} ${i?"pkt-searchinput--fullwidth":""}`;let W;return T?W=Z=>O.jsx("form",{role:"search",className:q,action:T,method:$,children:Z}):W=Z=>O.jsx("div",{role:"search",className:q,children:Z}),W(O.jsxs(O.Fragment,{children:[c&&O.jsx("label",{htmlFor:c?l:void 0,className:c?"pkt-inputwrapper__label":"",children:c}),O.jsxs("div",{className:r==="local"?"pkt-input__container":"pkt-searchinput__field",children:[O.jsx("input",{className:`pkt-input ${i?"pkt-input--fullwidth":""}`,type:"search",name:h||l,id:l,placeholder:m,defaultValue:C,disabled:n,autoComplete:"off","aria-autocomplete":"list",ref:J,"aria-controls":`${l}-suggestions`,onChange:N||Se,onKeyUp:R&&(Z=>{Z.key==="Enter"&&(Z.preventDefault(),R(C))}),...j}),O.jsx($d,{className:`pkt-searchinput__button ${r==="local"?"pkt-input-icon":""}`,variant:"icon-only",iconName:"magnifying-glass-big",skin:r==="local"?"tertiary":"primary",color:r==="global"?"yellow":void 0,type:"submit",disabled:n,onClick:R&&(Z=>{Z.preventDefault(),R(C)}),children:c||m})]}),D&&O.jsx("ul",{id:`${l}-suggestions`,className:"pkt-searchinput__suggestions","aria-live":"assertive",children:D.map((Z,X)=>O.jsx("li",{children:$e.createElement(Z.href?"a":Z.onClick?"button":"div",{href:Z.href,className:`pkt-searchinput__suggestion ${Z.onClick?"pkt-link-button":""} ${Z.href||Z.onClick?"pkt-searchinput__suggestion--has-hover":""}`,type:Z.onClick?"button":void 0,onClick:()=>G(Z.onClick,X),onKeyUp:ae=>ae.key==="Enter"&&G(Z.onClick,X)},O.jsxs(O.Fragment,{children:[Z.title&&O.jsx("h3",{className:"pkt-searchinput__suggestion-title",children:Z.title}),Z.text&&O.jsx("p",{className:"pkt-searchinput__suggestion-text",children:Z.text})]}))},`search-suggestion-${X}`))})]}))}),O4=$e.forwardRef(({activeStep:r,className:n,children:i,hideNonActiveSteps:l=!1,hideNonActiveStepsContent:c=!0,orientation:h="vertical",...m},D)=>{const C=ml(n,"pkt-stepper",h==="horizontal"?"pkt-stepper--horizontal":"pkt-stepper--vertical"),T=$e.Children.map(i,($,N)=>$e.isValidElement($)?$e.cloneElement($,{className:ml($.props.className,{"pkt-step--hideStep":l&&N!==r,"pkt-step--hideContent":c&&N!==r})}):$);return O.jsx("ol",{"data-testid":"pkt-stepper",className:C,ref:D,...m,children:T})}),B4=O.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",children:O.jsx("circle",{cx:"12",cy:"12",r:"7",style:{fill:"var(--pkt-color-grays-grey-200, #CCC)"}})}),M4=O.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",children:[O.jsx("circle",{opacity:".15",cx:"12",cy:"12",r:"12",fill:"#2A2859"}),O.jsx("circle",{cx:"12",cy:"12",r:"6",fill:"#2A2859"})]}),I4=O.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",children:[O.jsx("path",{fill:"#2A2859",d:"M3 3h18v18H3z"}),O.jsx("path",{d:"m10.34 16-1.11-1.14L7 12.58l1.11-1.15 2.23 2.28L15.88 8 17 9.15l-5.55 5.71L10.34 16Z",fill:"#F1FDFF"})]}),j4=({children:r,className:n,status:i="incomplete",title:l})=>O.jsxs("li",{className:ml("pkt-step",n,`pkt-step--${i}`),"data-testid":"pkt-step",children:[O.jsx("span",{className:"pkt-step__line pkt-step__line--1","aria-hidden":!0}),O.jsx("span",{className:"pkt-step__line pkt-step__line--2","aria-hidden":!0}),O.jsx("span",{className:ml("pkt-step__indicator"),children:i==="current"?M4:i==="completed"?I4:B4}),O.jsx("span",{className:"pkt-step__line pkt-step__line--3","aria-hidden":!0}),O.jsxs("div",{className:"pkt-step__wrapper",children:[O.jsx("div",{className:"pkt-step__title",children:l}),O.jsx("div",{className:"pkt-step__content",children:r})]})]}),z4=zr({tagName:"pkt-textarea",elementClass:qf,react:$e,displayName:"PktTextarea",events:{onChange:"change",onInput:"input",onBlur:"blur",onFocus:"focus",onValueChange:"valueChange",onToggleHelpText:"toggleHelpText"}}),ME=$e.forwardRef(({helptext:r,...n},i)=>O.jsx(z4,{...n,ref:i,children:r&&O.jsx("div",{slot:"helptext",className:"pkt-contents",children:r})}));ME.displayName="PktTextarea";var Gh=window.CustomEvent;(!Gh||typeof Gh=="object")&&(Gh=function(r,n){n=n||{};var i=document.createEvent("CustomEvent");return i.initCustomEvent(r,!!n.bubbles,!!n.cancelable,n.detail||null),i},Gh.prototype=window.Event.prototype);function IE(r,n){var i="on"+n.type.toLowerCase();return typeof r[i]=="function"&&r[i](n),r.dispatchEvent(n)}function U4(r){for(;r&&r!==document.body;){var n=window.getComputedStyle(r),i=function(l,c){return!(n[l]===void 0||n[l]===c)};if(n.opacity<1||i("zIndex","auto")||i("transform","none")||i("mixBlendMode","normal")||i("filter","none")||i("perspective","none")||n.isolation==="isolate"||n.position==="fixed"||n.webkitOverflowScrolling==="touch")return!0;r=r.parentElement}return!1}function tv(r){for(;r;){if(r.localName==="dialog")return r;r.parentElement?r=r.parentElement:r.parentNode?r=r.parentNode.host:r=null}return null}function jE(r){for(;r&&r.shadowRoot&&r.shadowRoot.activeElement;)r=r.shadowRoot.activeElement;r&&r.blur&&r!==document.body&&r.blur()}function H4(r,n){for(var i=0;i<r.length;++i)if(r[i]===n)return!0;return!1}function $2(r){return!r||!r.hasAttribute("method")?!1:r.getAttribute("method").toLowerCase()==="dialog"}function zE(r){var n=["button","input","keygen","select","textarea"],i=n.map(function(m){return m+":not([disabled])"});i.push('[tabindex]:not([disabled]):not([tabindex=""])');var l=r.querySelector(i.join(", "));if(!l&&"attachShadow"in Element.prototype)for(var c=r.querySelectorAll("*"),h=0;h<c.length&&!(c[h].tagName&&c[h].shadowRoot&&(l=zE(c[h].shadowRoot),l));h++);return l}function UE(r){return r.isConnected||document.body.contains(r)}function HE(r){if(r.submitter)return r.submitter;var n=r.target;if(!(n instanceof HTMLFormElement))return null;var i=In.formSubmitter;if(!i){var l=r.target,c="getRootNode"in l&&l.getRootNode()||document;i=c.activeElement}return!i||i.form!==n?null:i}function W4(r){if(!r.defaultPrevented){var n=r.target,i=In.imagemapUseValue,l=HE(r);i===null&&l&&(i=l.value);var c=tv(n);if(c){var h=l&&l.getAttribute("formmethod")||n.getAttribute("method");h==="dialog"&&(r.preventDefault(),i!=null?c.close(i):c.close())}}}function WE(r){if(this.dialog_=r,this.replacedStyleTop_=!1,this.openAsModal_=!1,r.hasAttribute("role")||r.setAttribute("role","dialog"),r.show=this.show.bind(this),r.showModal=this.showModal.bind(this),r.close=this.close.bind(this),r.addEventListener("submit",W4,!1),"returnValue"in r||(r.returnValue=""),"MutationObserver"in window){var n=new MutationObserver(this.maybeHideModal.bind(this));n.observe(r,{attributes:!0,attributeFilter:["open"]})}else{var i=!1,l=(function(){i?this.downgradeModal():this.maybeHideModal(),i=!1}).bind(this),c,h=function(m){if(m.target===r){var D="DOMNodeRemoved";i|=m.type.substr(0,D.length)===D,window.clearTimeout(c),c=window.setTimeout(l,0)}};["DOMAttrModified","DOMNodeRemoved","DOMNodeRemovedFromDocument"].forEach(function(m){r.addEventListener(m,h)})}Object.defineProperty(r,"open",{set:this.setOpen.bind(this),get:r.hasAttribute.bind(r,"open")}),this.backdrop_=document.createElement("div"),this.backdrop_.className="backdrop",this.backdrop_.addEventListener("mouseup",this.backdropMouseEvent_.bind(this)),this.backdrop_.addEventListener("mousedown",this.backdropMouseEvent_.bind(this)),this.backdrop_.addEventListener("click",this.backdropMouseEvent_.bind(this))}WE.prototype={get dialog(){return this.dialog_},maybeHideModal:function(){this.dialog_.hasAttribute("open")&&UE(this.dialog_)||this.downgradeModal()},downgradeModal:function(){this.openAsModal_&&(this.openAsModal_=!1,this.dialog_.style.zIndex="",this.replacedStyleTop_&&(this.dialog_.style.top="",this.replacedStyleTop_=!1),this.backdrop_.parentNode&&this.backdrop_.parentNode.removeChild(this.backdrop_),In.dm.removeDialog(this))},setOpen:function(r){r?this.dialog_.hasAttribute("open")||this.dialog_.setAttribute("open",""):(this.dialog_.removeAttribute("open"),this.maybeHideModal())},backdropMouseEvent_:function(r){if(this.dialog_.hasAttribute("tabindex"))this.dialog_.focus();else{var n=document.createElement("div");this.dialog_.insertBefore(n,this.dialog_.firstChild),n.tabIndex=-1,n.focus(),this.dialog_.removeChild(n)}var i=document.createEvent("MouseEvents");i.initMouseEvent(r.type,r.bubbles,r.cancelable,window,r.detail,r.screenX,r.screenY,r.clientX,r.clientY,r.ctrlKey,r.altKey,r.shiftKey,r.metaKey,r.button,r.relatedTarget),this.dialog_.dispatchEvent(i),r.stopPropagation()},focus_:function(){var r=this.dialog_.querySelector("[autofocus]:not([disabled])");!r&&this.dialog_.tabIndex>=0&&(r=this.dialog_),r||(r=zE(this.dialog_)),jE(document.activeElement),r&&r.focus()},updateZIndex:function(r,n){if(r<n)throw new Error("dialogZ should never be < backdropZ");this.dialog_.style.zIndex=r,this.backdrop_.style.zIndex=n},show:function(){this.dialog_.open||(this.setOpen(!0),this.focus_())},showModal:function(){if(this.dialog_.hasAttribute("open"))throw new Error("Failed to execute 'showModal' on dialog: The element is already open, and therefore cannot be opened modally.");if(!UE(this.dialog_))throw new Error("Failed to execute 'showModal' on dialog: The element is not in a Document.");if(!In.dm.pushDialog(this))throw new Error("Failed to execute 'showModal' on dialog: There are too many open modal dialogs.");U4(this.dialog_.parentElement)&&console.warn("A dialog is being shown inside a stacking context. This may cause it to be unusable. For more information, see this link: https://github.com/GoogleChrome/dialog-polyfill/#stacking-context"),this.setOpen(!0),this.openAsModal_=!0,In.needsCentering(this.dialog_)?(In.reposition(this.dialog_),this.replacedStyleTop_=!0):this.replacedStyleTop_=!1,this.dialog_.parentNode.insertBefore(this.backdrop_,this.dialog_.nextSibling),this.focus_()},close:function(r){if(!this.dialog_.hasAttribute("open"))throw new Error("Failed to execute 'close' on dialog: The element does not have an 'open' attribute, and therefore cannot be closed.");this.setOpen(!1),r!==void 0&&(this.dialog_.returnValue=r);var n=new Gh("close",{bubbles:!1,cancelable:!1});IE(this.dialog_,n)}};var In={};if(In.reposition=function(r){var n=document.body.scrollTop||document.documentElement.scrollTop,i=n+(window.innerHeight-r.offsetHeight)/2;r.style.top=Math.max(n,i)+"px"},In.isInlinePositionSetByStylesheet=function(r){for(var n=0;n<document.styleSheets.length;++n){var i=document.styleSheets[n],l=null;try{l=i.cssRules}catch{}if(l)for(var c=0;c<l.length;++c){var h=l[c],m=null;try{m=document.querySelectorAll(h.selectorText)}catch{}if(!(!m||!H4(m,r))){var D=h.style.getPropertyValue("top"),C=h.style.getPropertyValue("bottom");if(D&&D!=="auto"||C&&C!=="auto")return!0}}}return!1},In.needsCentering=function(r){var n=window.getComputedStyle(r);return n.position!=="absolute"||r.style.top!=="auto"&&r.style.top!==""||r.style.bottom!=="auto"&&r.style.bottom!==""?!1:!In.isInlinePositionSetByStylesheet(r)},In.forceRegisterDialog=function(r){if((window.HTMLDialogElement||r.showModal)&&console.warn("This browser already supports <dialog>, the polyfill may not work correctly",r),r.localName!=="dialog")throw new Error("Failed to register dialog: The element is not a dialog.");new WE(r)},In.registerDialog=function(r){r.showModal||In.forceRegisterDialog(r)},In.DialogManager=function(){this.pendingDialogStack=[];var r=this.checkDOM_.bind(this);this.overlay=document.createElement("div"),this.overlay.className="_dialog_overlay",this.overlay.addEventListener("click",(function(n){this.forwardTab_=void 0,n.stopPropagation(),r([])}).bind(this)),this.handleKey_=this.handleKey_.bind(this),this.handleFocus_=this.handleFocus_.bind(this),this.zIndexLow_=1e5,this.zIndexHigh_=100150,this.forwardTab_=void 0,"MutationObserver"in window&&(this.mo_=new MutationObserver(function(n){var i=[];n.forEach(function(l){for(var c=0,h;h=l.removedNodes[c];++c){if(h instanceof Element)h.localName==="dialog"&&i.push(h);else continue;i=i.concat(h.querySelectorAll("dialog"))}}),i.length&&r(i)}))},In.DialogManager.prototype.blockDocument=function(){document.documentElement.addEventListener("focus",this.handleFocus_,!0),document.addEventListener("keydown",this.handleKey_),this.mo_&&this.mo_.observe(document,{childList:!0,subtree:!0})},In.DialogManager.prototype.unblockDocument=function(){document.documentElement.removeEventListener("focus",this.handleFocus_,!0),document.removeEventListener("keydown",this.handleKey_),this.mo_&&this.mo_.disconnect()},In.DialogManager.prototype.updateStacking=function(){for(var r=this.zIndexHigh_,n=0,i;i=this.pendingDialogStack[n];++n)i.updateZIndex(--r,--r),n===0&&(this.overlay.style.zIndex=--r);var l=this.pendingDialogStack[0];if(l){var c=l.dialog.parentNode||document.body;c.appendChild(this.overlay)}else this.overlay.parentNode&&this.overlay.parentNode.removeChild(this.overlay)},In.DialogManager.prototype.containedByTopDialog_=function(r){for(;r=tv(r);){for(var n=0,i;i=this.pendingDialogStack[n];++n)if(i.dialog===r)return n===0;r=r.parentElement}return!1},In.DialogManager.prototype.handleFocus_=function(r){var n=r.composedPath?r.composedPath()[0]:r.target;if(!this.containedByTopDialog_(n)&&document.activeElement!==document.documentElement&&(r.preventDefault(),r.stopPropagation(),jE(n),this.forwardTab_!==void 0)){var i=this.pendingDialogStack[0],l=i.dialog,c=l.compareDocumentPosition(n);return c&Node.DOCUMENT_POSITION_PRECEDING&&(this.forwardTab_?i.focus_():n!==document.documentElement&&document.documentElement.focus()),!1}},In.DialogManager.prototype.handleKey_=function(r){if(this.forwardTab_=void 0,r.keyCode===27){r.preventDefault(),r.stopPropagation();var n=new Gh("cancel",{bubbles:!1,cancelable:!0}),i=this.pendingDialogStack[0];i&&IE(i.dialog,n)&&i.dialog.close()}else r.keyCode===9&&(this.forwardTab_=!r.shiftKey)},In.DialogManager.prototype.checkDOM_=function(r){var n=this.pendingDialogStack.slice();n.forEach(function(i){r.indexOf(i.dialog)!==-1?i.downgradeModal():i.maybeHideModal()})},In.DialogManager.prototype.pushDialog=function(r){var n=(this.zIndexHigh_-this.zIndexLow_)/2-1;return this.pendingDialogStack.length>=n?!1:(this.pendingDialogStack.unshift(r)===1&&this.blockDocument(),this.updateStacking(),!0)},In.DialogManager.prototype.removeDialog=function(r){var n=this.pendingDialogStack.indexOf(r);n!==-1&&(this.pendingDialogStack.splice(n,1),this.pendingDialogStack.length===0&&this.unblockDocument(),this.updateStacking())},In.dm=new In.DialogManager,In.formSubmitter=null,In.imagemapUseValue=null,window.HTMLDialogElement===void 0){var qE=document.createElement("form");if(qE.setAttribute("method","dialog"),qE.method!=="dialog"){var Xh=Object.getOwnPropertyDescriptor(HTMLFormElement.prototype,"method");if(Xh){var q4=Xh.get;Xh.get=function(){return $2(this)?"dialog":q4.call(this)};var V4=Xh.set;Xh.set=function(r){return typeof r=="string"&&r.toLowerCase()==="dialog"?this.setAttribute("method",r):V4.call(this,r)},Object.defineProperty(HTMLFormElement.prototype,"method",Xh)}}document.addEventListener("click",function(r){if(In.formSubmitter=null,In.imagemapUseValue=null,!r.defaultPrevented){var n=r.target;if("composedPath"in r){var i=r.composedPath();n=i.shift()||n}if(!(!n||!$2(n.form))){var l=n.type==="submit"&&["button","input"].indexOf(n.localName)>-1;if(!l){if(!(n.localName==="input"&&n.type==="image"))return;In.imagemapUseValue=r.offsetX+","+r.offsetY}var c=tv(n);c&&(In.formSubmitter=n)}}},!1),document.addEventListener("submit",function(r){var n=r.target,i=tv(n);if(!i){var l=HE(r),c=l&&l.getAttribute("formmethod")||n.getAttribute("method");c==="dialog"&&r.preventDefault()}});var Y4=HTMLFormElement.prototype.submit,G4=function(){if(!$2(this))return Y4.call(this);var r=tv(this);r&&r.close()};HTMLFormElement.prototype.submit=G4}const X4=Object.freeze(Object.defineProperty({__proto__:null,default:In},Symbol.toStringTag,{value:"Module"}));Rt.PktAccordion=Yx,Rt.PktAccordionItem=Gx,Rt.PktAlert=Xx,Rt.PktBackLink=Jx,Rt.PktBreadcrumbs=hR,Rt.PktButton=$d,Rt.PktCard=Qx,Rt.PktCheckbox=k0,Rt.PktCombobox=Kx,Rt.PktConsent=ib,Rt.PktDatepicker=w0,Rt.PktFooter=yR,Rt.PktFooterSimple=bR,Rt.PktHeader=wR,Rt.PktHelptext=e_,Rt.PktIcon=or,Rt.PktInput=t_,Rt.PktInputWrapper=n_,Rt.PktLink=r_,Rt.PktLinkCard=a_,Rt.PktLoader=i_,Rt.PktMessagebox=o_,Rt.PktModal=s_,Rt.PktPreview=OE,Rt.PktProgressbar=BE,Rt.PktRadioButton=R4,Rt.PktSearchInput=L4,Rt.PktSelect=Lb,Rt.PktStep=j4,Rt.PktStepper=O4,Rt.PktTable=Pb,Rt.PktTableBody=Rb,Rt.PktTableDataCell=Zo,Rt.PktTableHeader=Nb,Rt.PktTableHeaderCell=gl,Rt.PktTableRow=rp,Rt.PktTabs=LE,Rt.PktTag=Yh,Rt.PktTextarea=ME,Rt.PktTextinput=ev,Object.defineProperty(Rt,Symbol.toStringTag,{value:"Module"})});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@oslokommune/punkt-react",
|
|
3
|
-
"version": "12.43.
|
|
3
|
+
"version": "12.43.2",
|
|
4
4
|
"description": "React komponentbibliotek til Punkt, et designsystem laget av Oslo Origo",
|
|
5
5
|
"homepage": "https://punkt.oslo.kommune.no",
|
|
6
6
|
"author": "Team Designsystem, Oslo Origo",
|
|
@@ -38,7 +38,7 @@
|
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@lit-labs/ssr-dom-shim": "^1.2.1",
|
|
40
40
|
"@lit/react": "^1.0.7",
|
|
41
|
-
"@oslokommune/punkt-elements": "^12.43.
|
|
41
|
+
"@oslokommune/punkt-elements": "^12.43.2",
|
|
42
42
|
"angular-html-parser": "^6.0.2",
|
|
43
43
|
"html-format": "^1.1.7",
|
|
44
44
|
"prettier": "^3.3.3",
|
|
@@ -48,8 +48,8 @@
|
|
|
48
48
|
},
|
|
49
49
|
"devDependencies": {
|
|
50
50
|
"@babel/plugin-proposal-private-property-in-object": "^7.18.6",
|
|
51
|
-
"@oslokommune/punkt-assets": "^12.43.
|
|
52
|
-
"@oslokommune/punkt-css": "^12.43.
|
|
51
|
+
"@oslokommune/punkt-assets": "^12.43.2",
|
|
52
|
+
"@oslokommune/punkt-css": "^12.43.2",
|
|
53
53
|
"@testing-library/jest-dom": "^6.5.0",
|
|
54
54
|
"@testing-library/react": "^16.0.1",
|
|
55
55
|
"@testing-library/user-event": "^14.5.2",
|
|
@@ -112,5 +112,5 @@
|
|
|
112
112
|
"url": "https://github.com/oslokommune/punkt/issues"
|
|
113
113
|
},
|
|
114
114
|
"license": "MIT",
|
|
115
|
-
"gitHead": "
|
|
115
|
+
"gitHead": "e6129504ff4bd5c109780783832e2a02d763f9dc"
|
|
116
116
|
}
|