@politiet/sheriff-web-components 2.13.1 → 2.14.0

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.
Files changed (123) hide show
  1. package/custom-elements.json +3949 -1463
  2. package/dist/controllers/index.d.ts +3 -0
  3. package/dist/controllers/index.d.ts.map +1 -0
  4. package/dist/controllers/index.js +3 -0
  5. package/dist/controllers/index.js.map +1 -0
  6. package/dist/controllers/sds-drag-drop-controller.d.ts +25 -0
  7. package/dist/controllers/sds-drag-drop-controller.d.ts.map +1 -0
  8. package/dist/controllers/sds-drag-drop-controller.js +52 -0
  9. package/dist/controllers/sds-drag-drop-controller.js.map +1 -0
  10. package/dist/controllers/sds-file-preview-controller.d.ts +38 -0
  11. package/dist/controllers/sds-file-preview-controller.d.ts.map +1 -0
  12. package/dist/controllers/sds-file-preview-controller.js +90 -0
  13. package/dist/controllers/sds-file-preview-controller.js.map +1 -0
  14. package/dist/frameworks/preact.d.ts +14 -1
  15. package/dist/frameworks/preact.d.ts.map +1 -1
  16. package/dist/frameworks/react.d.ts +30 -1
  17. package/dist/frameworks/react.d.ts.map +1 -1
  18. package/dist/frameworks/solidjs.d.ts +4 -0
  19. package/dist/frameworks/solidjs.d.ts.map +1 -1
  20. package/dist/frameworks/svelte.d.ts +4 -0
  21. package/dist/frameworks/svelte.d.ts.map +1 -1
  22. package/dist/frameworks/vue.d.ts +24 -1
  23. package/dist/frameworks/vue.d.ts.map +1 -1
  24. package/dist/index.d.ts +8 -0
  25. package/dist/index.d.ts.map +1 -1
  26. package/dist/index.js +4 -0
  27. package/dist/index.js.map +1 -1
  28. package/dist/react-wrappers/SDSDialogWrapper.d.ts +1 -0
  29. package/dist/react-wrappers/SDSDialogWrapper.d.ts.map +1 -1
  30. package/dist/react-wrappers/SDSDialogWrapper.js +1 -0
  31. package/dist/react-wrappers/SDSDialogWrapper.js.map +1 -1
  32. package/dist/react-wrappers/SDSFileUploadFileListWrapper.d.ts +3 -0
  33. package/dist/react-wrappers/SDSFileUploadFileListWrapper.d.ts.map +1 -0
  34. package/dist/react-wrappers/SDSFileUploadFileListWrapper.js +10 -0
  35. package/dist/react-wrappers/SDSFileUploadFileListWrapper.js.map +1 -0
  36. package/dist/react-wrappers/SDSFileUploadItemWrapper.d.ts +6 -0
  37. package/dist/react-wrappers/SDSFileUploadItemWrapper.d.ts.map +1 -0
  38. package/dist/react-wrappers/SDSFileUploadItemWrapper.js +12 -0
  39. package/dist/react-wrappers/SDSFileUploadItemWrapper.js.map +1 -0
  40. package/dist/react-wrappers/SDSFileUploadWrapper.d.ts +12 -0
  41. package/dist/react-wrappers/SDSFileUploadWrapper.d.ts.map +1 -0
  42. package/dist/react-wrappers/SDSFileUploadWrapper.js +18 -0
  43. package/dist/react-wrappers/SDSFileUploadWrapper.js.map +1 -0
  44. package/dist/react-wrappers/SDSSearchWrapper.d.ts +15 -0
  45. package/dist/react-wrappers/SDSSearchWrapper.d.ts.map +1 -0
  46. package/dist/react-wrappers/SDSSearchWrapper.js +19 -0
  47. package/dist/react-wrappers/SDSSearchWrapper.js.map +1 -0
  48. package/dist/react-wrappers/index.d.ts +4 -0
  49. package/dist/react-wrappers/index.d.ts.map +1 -1
  50. package/dist/react-wrappers/index.js +4 -0
  51. package/dist/react-wrappers/index.js.map +1 -1
  52. package/dist/sds-button/sds-button.component.d.ts +0 -1
  53. package/dist/sds-button/sds-button.component.d.ts.map +1 -1
  54. package/dist/sds-button/sds-button.component.js +10 -16
  55. package/dist/sds-button/sds-button.component.js.map +1 -1
  56. package/dist/sds-dialog/sds-dialog.component.d.ts.map +1 -1
  57. package/dist/sds-dialog/sds-dialog.component.js +11 -1
  58. package/dist/sds-dialog/sds-dialog.component.js.map +1 -1
  59. package/dist/sds-file-upload/sds-file-upload.d.ts +102 -0
  60. package/dist/sds-file-upload/sds-file-upload.d.ts.map +1 -0
  61. package/dist/sds-file-upload/sds-file-upload.js +384 -0
  62. package/dist/sds-file-upload/sds-file-upload.js.map +1 -0
  63. package/dist/sds-file-upload/sds-file-upload.styles.d.ts +2 -0
  64. package/dist/sds-file-upload/sds-file-upload.styles.d.ts.map +1 -0
  65. package/dist/sds-file-upload/sds-file-upload.styles.js +234 -0
  66. package/dist/sds-file-upload/sds-file-upload.styles.js.map +1 -0
  67. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.d.ts +14 -0
  68. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.d.ts.map +1 -0
  69. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.js +26 -0
  70. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.js.map +1 -0
  71. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.styles.d.ts +2 -0
  72. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.styles.d.ts.map +1 -0
  73. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.styles.js +19 -0
  74. package/dist/sds-file-upload-file-list/sds-file-upload-file-list.styles.js.map +1 -0
  75. package/dist/sds-file-upload-item/assets/u-progress.js +2 -0
  76. package/dist/sds-file-upload-item/sds-file-upload-item.d.ts +62 -0
  77. package/dist/sds-file-upload-item/sds-file-upload-item.d.ts.map +1 -0
  78. package/dist/sds-file-upload-item/sds-file-upload-item.js +205 -0
  79. package/dist/sds-file-upload-item/sds-file-upload-item.js.map +1 -0
  80. package/dist/sds-file-upload-item/sds-file-upload-item.styles.d.ts +2 -0
  81. package/dist/sds-file-upload-item/sds-file-upload-item.styles.d.ts.map +1 -0
  82. package/dist/sds-file-upload-item/sds-file-upload-item.styles.js +227 -0
  83. package/dist/sds-file-upload-item/sds-file-upload-item.styles.js.map +1 -0
  84. package/dist/sds-search/sds-search.component.d.ts +128 -0
  85. package/dist/sds-search/sds-search.component.d.ts.map +1 -0
  86. package/dist/sds-search/sds-search.component.js +345 -0
  87. package/dist/sds-search/sds-search.component.js.map +1 -0
  88. package/dist/sds-search/sds-search.d.ts +13 -0
  89. package/dist/sds-search/sds-search.d.ts.map +1 -0
  90. package/dist/sds-search/sds-search.js +18 -0
  91. package/dist/sds-search/sds-search.js.map +1 -0
  92. package/dist/sds-search/sds-search.styles.d.ts +2 -0
  93. package/dist/sds-search/sds-search.styles.d.ts.map +1 -0
  94. package/dist/sds-search/sds-search.styles.js +74 -0
  95. package/dist/sds-search/sds-search.styles.js.map +1 -0
  96. package/dist/sds-textfield/sds-textfield.component.d.ts +4 -1
  97. package/dist/sds-textfield/sds-textfield.component.d.ts.map +1 -1
  98. package/dist/sds-textfield/sds-textfield.component.js +20 -5
  99. package/dist/sds-textfield/sds-textfield.component.js.map +1 -1
  100. package/dist/sds-textfield/sds-textfield.styles.d.ts.map +1 -1
  101. package/dist/sds-textfield/sds-textfield.styles.js +11 -0
  102. package/dist/sds-textfield/sds-textfield.styles.js.map +1 -1
  103. package/dist/sheriff-web-components.js +1015 -294
  104. package/dist/skill/SKILL.md +44 -36
  105. package/dist/skill/references/components.md +88 -3
  106. package/dist/skill/references/react-wrappers.md +25 -18
  107. package/dist/utils/file-validation.d.ts +31 -0
  108. package/dist/utils/file-validation.d.ts.map +1 -0
  109. package/dist/utils/file-validation.js +57 -0
  110. package/dist/utils/file-validation.js.map +1 -0
  111. package/dist/utils/format-bytes.d.ts +6 -0
  112. package/dist/utils/format-bytes.d.ts.map +1 -0
  113. package/dist/utils/format-bytes.js +13 -0
  114. package/dist/utils/format-bytes.js.map +1 -0
  115. package/dist/utils/video-thumbnail.d.ts +8 -0
  116. package/dist/utils/video-thumbnail.d.ts.map +1 -0
  117. package/dist/utils/video-thumbnail.js +77 -0
  118. package/dist/utils/video-thumbnail.js.map +1 -0
  119. package/dist/version.d.ts +1 -1
  120. package/dist/version.js +1 -1
  121. package/dist/version.js.map +1 -1
  122. package/package.json +24 -4
  123. package/web-types.json +3431 -1120
@@ -1,4 +1,4 @@
1
- var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,o=/* @__PURE__ */Symbol(),r=/* @__PURE__ */new WeakMap;let a=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==o)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(s&&void 0===t){const s=void 0!==e&&1===e.length;s&&(t=r.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&r.set(e,t))}return t}toString(){return this.cssText}};const i=t=>new a("string"==typeof t?t:t+"",void 0,o),d=(t,...e)=>{const s=1===t.length?t[0]:e.reduce((e,s,o)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[o+1],t[0]);return new a(s,t,o)},n=s?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return i(e)})(t):t,{is:l,defineProperty:c,getOwnPropertyDescriptor:h,getOwnPropertyNames:p,getOwnPropertySymbols:g,getPrototypeOf:v}=Object,u=globalThis,f=u.trustedTypes,b=f?f.emptyScript:"",_=u.reactiveElementPolyfillSupport,m=(t,e)=>t,x={toAttribute(t,e){switch(e){case Boolean:t=t?b:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let s=t;switch(e){case Boolean:s=null!==t;break;case Number:s=null===t?null:Number(t);break;case Object:case Array:try{s=JSON.parse(t)}catch(o){s=null}}return s}},y=(t,e)=>!l(t,e),w={attribute:!0,type:String,converter:x,reflect:!1,useDefault:!1,hasChanged:y};Symbol.metadata??=/* @__PURE__ */Symbol("metadata"),u.litPropertyMetadata??=/* @__PURE__ */new WeakMap;let k=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=w){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const s=/* @__PURE__ */Symbol(),o=this.getPropertyDescriptor(t,s,e);void 0!==o&&c(this.prototype,t,o)}}static getPropertyDescriptor(t,e,s){const{get:o,set:r}=h(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:o,set(e){const a=o?.call(this);r?.call(this,e),this.requestUpdate(t,a,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??w}static _$Ei(){if(this.hasOwnProperty(m("elementProperties")))return;const t=v(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(m("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(m("properties"))){const t=this.properties,e=[...p(t),...g(t)];for(const s of e)this.createProperty(s,t[s])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,s]of e)this.elementProperties.set(t,s)}this._$Eh=/* @__PURE__ */new Map;for(const[e,s]of this.elementProperties){const t=this._$Eu(e,s);void 0!==t&&this._$Eh.set(t,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const s=new Set(t.flat(1/0).reverse());for(const t of s)e.unshift(n(t))}else void 0!==t&&e.push(n(t));return e}static _$Eu(t,e){const s=e.attribute;return!1===s?void 0:"string"==typeof s?s:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=/* @__PURE__ */new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=/* @__PURE__ */new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=/* @__PURE__ */new Map,e=this.constructor.elementProperties;for(const s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(s)t.adoptedStyleSheets=o.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const s of o){const o=document.createElement("style"),r=e.litNonce;void 0!==r&&o.setAttribute("nonce",r),o.textContent=s.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$ET(t,e){const s=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,s);if(void 0!==o&&!0===s.reflect){const r=(void 0!==s.converter?.toAttribute?s.converter:x).toAttribute(e,s.type);this._$Em=t,null==r?this.removeAttribute(o):this.setAttribute(o,r),this._$Em=null}}_$AK(t,e){const s=this.constructor,o=s._$Eh.get(t);if(void 0!==o&&this._$Em!==o){const t=s.getPropertyOptions(o),r="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:x;this._$Em=o;const a=r.fromAttribute(e,t.type);this[o]=a??this._$Ej?.get(o)??a,this._$Em=null}}requestUpdate(t,e,s,o=!1,r){if(void 0!==t){const a=this.constructor;if(!1===o&&(r=this[t]),s??=a.getPropertyOptions(t),!((s.hasChanged??y)(r,e)||s.useDefault&&s.reflect&&r===this._$Ej?.get(t)&&!this.hasAttribute(a._$Eu(t,s))))return;this.C(t,e,s)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:o,wrapped:r},a){s&&!(this._$Ej??=/* @__PURE__ */new Map).has(t)&&(this._$Ej.set(t,a??e??this[t]),!0!==r||void 0!==a)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),!0===o&&this._$Em!==t&&(this._$Eq??=/* @__PURE__ */new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,s]of t){const{wrapped:t}=s,o=this[e];!0!==t||this._$AL.has(e)||void 0===o||this.C(e,void 0,s,o)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(t=>t.hostUpdate?.()),this.update(e)):this._$EM()}catch(s){throw t=!1,this._$EM(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=/* @__PURE__ */new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(t){}firstUpdated(t){}};k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[m("elementProperties")]=/* @__PURE__ */new Map,k[m("finalized")]=/* @__PURE__ */new Map,_?.({ReactiveElement:k}),(u.reactiveElementVersions??=[]).push("2.1.2");const z={attribute:!0,type:String,converter:x,reflect:!1,hasChanged:y},$=(t=z,e,s)=>{const{kind:o,metadata:r}=s;let a=globalThis.litPropertyMetadata.get(r);if(void 0===a&&globalThis.litPropertyMetadata.set(r,a=/* @__PURE__ */new Map),"setter"===o&&((t=Object.create(t)).wrapped=!0),a.set(s.name,t),"accessor"===o){const{name:o}=s;return{set(s){const r=e.get.call(this);e.set.call(this,s),this.requestUpdate(o,r,t,!0,s)},init(e){return void 0!==e&&this.C(o,void 0,t,e),e}}}if("setter"===o){const{name:o}=s;return function(s){const r=this[o];e.call(this,s),this.requestUpdate(o,r,t,!0,s)}}throw Error("Unsupported decorator location: "+o)};function S(t){return(e,s)=>"object"==typeof s?$(t,e,s):((t,e,s)=>{const o=e.hasOwnProperty(s);return e.constructor.createProperty(s,t),o?Object.getOwnPropertyDescriptor(e,s):void 0})(t,e,s)}function C(t){return S({...t,state:!0,attribute:!1})}const E=(t,e,s)=>(s.configurable=!0,s.enumerable=!0,Reflect.decorate&&"object"!=typeof e&&Object.defineProperty(t,e,s),s);function A(t,e){return(e,s,o)=>E(e,s,{get(){return e=this,e.renderRoot?.querySelector(t)??null;var e}})}function L(t){return(e,s)=>{const{slot:o,selector:r}=t??{},a="slot"+(o?`[name=${o}]`:":not([name])");return E(e,s,{get(){const e=this.renderRoot?.querySelector(a),s=e?.assignedElements(t)??[];return void 0===r?s:s.filter(t=>t.matches(r))}})}}function O(t){return e=>{var s;customElements.get(t)||(s=t,(t,e)=>{void 0!==e?e.addInitializer(()=>{customElements.define(s,t)}):customElements.define(s,t)})(e)}}const P=globalThis,D=t=>t,T=P.trustedTypes,q=T?T.createPolicy("lit-html",{createHTML:t=>t}):void 0,M="$lit$",V=`lit$${Math.random().toFixed(9).slice(2)}$`,B="?"+V,R=`<${B}>`,j=document,I=()=>j.createComment(""),N=t=>null===t||"object"!=typeof t&&"function"!=typeof t,H=Array.isArray,F="[ \t\n\f\r]",U=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,G=/-->/g,K=/>/g,W=RegExp(`>|${F}(?:([^\\s"'>=/]+)(${F}*=${F}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Z=/'/g,Y=/"/g,Q=/^(?:script|style|textarea|title)$/i,X=t=>(e,...s)=>({_$litType$:t,strings:e,values:s}),J=X(1),tt=X(2),et=/* @__PURE__ */Symbol.for("lit-noChange"),st=/* @__PURE__ */Symbol.for("lit-nothing"),ot=/* @__PURE__ */new WeakMap,rt=j.createTreeWalker(j,129);function at(t,e){if(!H(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==q?q.createHTML(e):e}class it{constructor({strings:t,_$litType$:e},s){let o;this.parts=[];let r=0,a=0;const i=t.length-1,d=this.parts,[n,l]=((t,e)=>{const s=t.length-1,o=[];let r,a=2===e?"<svg>":3===e?"<math>":"",i=U;for(let d=0;d<s;d++){const e=t[d];let s,n,l=-1,c=0;for(;c<e.length&&(i.lastIndex=c,n=i.exec(e),null!==n);)c=i.lastIndex,i===U?"!--"===n[1]?i=G:void 0!==n[1]?i=K:void 0!==n[2]?(Q.test(n[2])&&(r=RegExp("</"+n[2],"g")),i=W):void 0!==n[3]&&(i=W):i===W?">"===n[0]?(i=r??U,l=-1):void 0===n[1]?l=-2:(l=i.lastIndex-n[2].length,s=n[1],i=void 0===n[3]?W:'"'===n[3]?Y:Z):i===Y||i===Z?i=W:i===G||i===K?i=U:(i=W,r=void 0);const h=i===W&&t[d+1].startsWith("/>")?" ":"";a+=i===U?e+R:l>=0?(o.push(s),e.slice(0,l)+M+e.slice(l)+V+h):e+V+(-2===l?d:h)}return[at(t,a+(t[s]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),o]})(t,e);if(this.el=it.createElement(n,s),rt.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(o=rt.nextNode())&&d.length<i;){if(1===o.nodeType){if(o.hasAttributes())for(const t of o.getAttributeNames())if(t.endsWith(M)){const e=l[a++],s=o.getAttribute(t).split(V),i=/([.?@])?(.*)/.exec(e);d.push({type:1,index:r,name:i[2],strings:s,ctor:"."===i[1]?ht:"?"===i[1]?pt:"@"===i[1]?gt:ct}),o.removeAttribute(t)}else t.startsWith(V)&&(d.push({type:6,index:r}),o.removeAttribute(t));if(Q.test(o.tagName)){const t=o.textContent.split(V),e=t.length-1;if(e>0){o.textContent=T?T.emptyScript:"";for(let s=0;s<e;s++)o.append(t[s],I()),rt.nextNode(),d.push({type:2,index:++r});o.append(t[e],I())}}}else if(8===o.nodeType)if(o.data===B)d.push({type:2,index:r});else{let t=-1;for(;-1!==(t=o.data.indexOf(V,t+1));)d.push({type:7,index:r}),t+=V.length-1}r++}}static createElement(t,e){const s=j.createElement("template");return s.innerHTML=t,s}}function dt(t,e,s=t,o){if(e===et)return e;let r=void 0!==o?s._$Co?.[o]:s._$Cl;const a=N(e)?void 0:e._$litDirective$;return r?.constructor!==a&&(r?._$AO?.(!1),void 0===a?r=void 0:(r=new a(t),r._$AT(t,s,o)),void 0!==o?(s._$Co??=[])[o]=r:s._$Cl=r),void 0!==r&&(e=dt(t,r._$AS(t,e.values),r,o)),e}class nt{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:s}=this._$AD,o=(t?.creationScope??j).importNode(e,!0);rt.currentNode=o;let r=rt.nextNode(),a=0,i=0,d=s[0];for(;void 0!==d;){if(a===d.index){let e;2===d.type?e=new lt(r,r.nextSibling,this,t):1===d.type?e=new d.ctor(r,d.name,d.strings,this,t):6===d.type&&(e=new vt(r,this,t)),this._$AV.push(e),d=s[++i]}a!==d?.index&&(r=rt.nextNode(),a++)}return rt.currentNode=j,o}p(t){let e=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}}class lt{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,o){this.type=2,this._$AH=st,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=o,this._$Cv=o?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=dt(this,t,e),N(t)?t===st||null==t||""===t?(this._$AH!==st&&this._$AR(),this._$AH=st):t!==this._$AH&&t!==et&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>H(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==st&&N(this._$AH)?this._$AA.nextSibling.data=t:this.T(j.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:s}=t,o="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=it.createElement(at(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===o)this._$AH.p(e);else{const t=new nt(o,this),s=t.u(this.options);t.p(e),this.T(s),this._$AH=t}}_$AC(t){let e=ot.get(t.strings);return void 0===e&&ot.set(t.strings,e=new it(t)),e}k(t){H(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let s,o=0;for(const r of t)o===e.length?e.push(s=new lt(this.O(I()),this.O(I()),this,this.options)):s=e[o],s._$AI(r),o++;o<e.length&&(this._$AR(s&&s._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){const e=D(t).nextSibling;D(t).remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class ct{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,o,r){this.type=1,this._$AH=st,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=r,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=st}_$AI(t,e=this,s,o){const r=this.strings;let a=!1;if(void 0===r)t=dt(this,t,e,0),a=!N(t)||t!==this._$AH&&t!==et,a&&(this._$AH=t);else{const o=t;let i,d;for(t=r[0],i=0;i<r.length-1;i++)d=dt(this,o[s+i],e,i),d===et&&(d=this._$AH[i]),a||=!N(d)||d!==this._$AH[i],d===st?t=st:t!==st&&(t+=(d??"")+r[i+1]),this._$AH[i]=d}a&&!o&&this.j(t)}j(t){t===st?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class ht extends ct{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===st?void 0:t}}class pt extends ct{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==st)}}class gt extends ct{constructor(t,e,s,o,r){super(t,e,s,o,r),this.type=5}_$AI(t,e=this){if((t=dt(this,t,e,0)??st)===et)return;const s=this._$AH,o=t===st&&s!==st||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,r=t!==st&&(s===st||o);o&&this.element.removeEventListener(this.name,this,s),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class vt{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){dt(this,t)}}const ut=P.litHtmlPolyfillSupport;ut?.(it,lt),(P.litHtmlVersions??=[]).push("3.3.3");const ft=globalThis;let bt=class extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,s)=>{const o=s?.renderBefore??e;let r=o._$litPart$;if(void 0===r){const t=s?.renderBefore??null;o._$litPart$=r=new lt(e.insertBefore(I(),t),t,void 0,s??{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return et}};bt._$litElement$=!0,bt.finalized=!0,ft.litElementHydrateSupport?.({LitElement:bt});const _t=ft.litElementPolyfillSupport;_t?.({LitElement:bt}),(ft.litElementVersions??=[]).push("4.2.2");class mt extends bt{constructor(){super(...arguments),this.sheriffVersion="2.13.1"}}const xt=/* @__PURE__ */Symbol.for(""),yt=t=>{if(t?.r===xt)return t?._$litStatic$},wt=t=>({_$litStatic$:t,r:xt}),kt=(t,...e)=>({_$litStatic$:e.reduce((e,s,o)=>e+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n take care to ensure page security.`)})(s)+t[o+1],t[0]),r:xt}),zt=/* @__PURE__ */new Map,$t=(St=J,(t,...e)=>{const s=e.length;let o,r;const a=[],i=[];let d,n=0,l=!1;for(;n<s;){for(d=t[n];n<s&&void 0!==(r=e[n],o=yt(r));)d+=o+t[++n],l=!0;n!==s&&i.push(r),a.push(d),n++}if(n===s&&a.push(t[s]),l){const s=a.join("$$lit$$");void 0===(t=zt.get(s))&&(a.raw=a,zt.set(s,t=a)),e=i}return St(t,...e)});var St;const Ct=d`
1
+ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,o=/* @__PURE__ */Symbol(),r=/* @__PURE__ */new WeakMap;let a=class{constructor(t,e,s){if(this._$cssResult$=!0,s!==o)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=e}get styleSheet(){let t=this.o;const e=this.t;if(s&&void 0===t){const s=void 0!==e&&1===e.length;s&&(t=r.get(e)),void 0===t&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),s&&r.set(e,t))}return t}toString(){return this.cssText}};const i=t=>new a("string"==typeof t?t:t+"",void 0,o),d=(t,...e)=>{const s=1===t.length?t[0]:e.reduce((e,s,o)=>e+(t=>{if(!0===t._$cssResult$)return t.cssText;if("number"==typeof t)return t;throw Error("Value passed to 'css' function must be a 'css' function result: "+t+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(s)+t[o+1],t[0]);return new a(s,t,o)},n=s?t=>t:t=>t instanceof CSSStyleSheet?(t=>{let e="";for(const s of t.cssRules)e+=s.cssText;return i(e)})(t):t,{is:l,defineProperty:c,getOwnPropertyDescriptor:h,getOwnPropertyNames:p,getOwnPropertySymbols:g,getPrototypeOf:v}=Object,u=globalThis,f=u.trustedTypes,b=f?f.emptyScript:"",_=u.reactiveElementPolyfillSupport,m=(t,e)=>t,x={toAttribute(t,e){switch(e){case Boolean:t=t?b:null;break;case Object:case Array:t=null==t?t:JSON.stringify(t)}return t},fromAttribute(t,e){let s=t;switch(e){case Boolean:s=null!==t;break;case Number:s=null===t?null:Number(t);break;case Object:case Array:try{s=JSON.parse(t)}catch(o){s=null}}return s}},y=(t,e)=>!l(t,e),w={attribute:!0,type:String,converter:x,reflect:!1,useDefault:!1,hasChanged:y};Symbol.metadata??=/* @__PURE__ */Symbol("metadata"),u.litPropertyMetadata??=/* @__PURE__ */new WeakMap;let k=class extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??=[]).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,e=w){if(e.state&&(e.attribute=!1),this._$Ei(),this.prototype.hasOwnProperty(t)&&((e=Object.create(e)).wrapped=!0),this.elementProperties.set(t,e),!e.noAccessor){const s=/* @__PURE__ */Symbol(),o=this.getPropertyDescriptor(t,s,e);void 0!==o&&c(this.prototype,t,o)}}static getPropertyDescriptor(t,e,s){const{get:o,set:r}=h(this.prototype,t)??{get(){return this[e]},set(t){this[e]=t}};return{get:o,set(e){const a=o?.call(this);r?.call(this,e),this.requestUpdate(t,a,s)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??w}static _$Ei(){if(this.hasOwnProperty(m("elementProperties")))return;const t=v(this);t.finalize(),void 0!==t.l&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(m("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(m("properties"))){const t=this.properties,e=[...p(t),...g(t)];for(const s of e)this.createProperty(s,t[s])}const t=this[Symbol.metadata];if(null!==t){const e=litPropertyMetadata.get(t);if(void 0!==e)for(const[t,s]of e)this.elementProperties.set(t,s)}this._$Eh=/* @__PURE__ */new Map;for(const[e,s]of this.elementProperties){const t=this._$Eu(e,s);void 0!==t&&this._$Eh.set(t,e)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const e=[];if(Array.isArray(t)){const s=new Set(t.flat(1/0).reverse());for(const t of s)e.unshift(n(t))}else void 0!==t&&e.push(n(t));return e}static _$Eu(t,e){const s=e.attribute;return!1===s?void 0:"string"==typeof s?s:"string"==typeof t?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){this._$ES=new Promise(t=>this.enableUpdating=t),this._$AL=/* @__PURE__ */new Map,this._$E_(),this.requestUpdate(),this.constructor.l?.forEach(t=>t(this))}addController(t){(this._$EO??=/* @__PURE__ */new Set).add(t),void 0!==this.renderRoot&&this.isConnected&&t.hostConnected?.()}removeController(t){this._$EO?.delete(t)}_$E_(){const t=/* @__PURE__ */new Map,e=this.constructor.elementProperties;for(const s of e.keys())this.hasOwnProperty(s)&&(t.set(s,this[s]),delete this[s]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return((t,o)=>{if(s)t.adoptedStyleSheets=o.map(t=>t instanceof CSSStyleSheet?t:t.styleSheet);else for(const s of o){const o=document.createElement("style"),r=e.litNonce;void 0!==r&&o.setAttribute("nonce",r),o.textContent=s.cssText,t.appendChild(o)}})(t,this.constructor.elementStyles),t}connectedCallback(){this.renderRoot??=this.createRenderRoot(),this.enableUpdating(!0),this._$EO?.forEach(t=>t.hostConnected?.())}enableUpdating(t){}disconnectedCallback(){this._$EO?.forEach(t=>t.hostDisconnected?.())}attributeChangedCallback(t,e,s){this._$AK(t,s)}_$ET(t,e){const s=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,s);if(void 0!==o&&!0===s.reflect){const r=(void 0!==s.converter?.toAttribute?s.converter:x).toAttribute(e,s.type);this._$Em=t,null==r?this.removeAttribute(o):this.setAttribute(o,r),this._$Em=null}}_$AK(t,e){const s=this.constructor,o=s._$Eh.get(t);if(void 0!==o&&this._$Em!==o){const t=s.getPropertyOptions(o),r="function"==typeof t.converter?{fromAttribute:t.converter}:void 0!==t.converter?.fromAttribute?t.converter:x;this._$Em=o;const a=r.fromAttribute(e,t.type);this[o]=a??this._$Ej?.get(o)??a,this._$Em=null}}requestUpdate(t,e,s,o=!1,r){if(void 0!==t){const a=this.constructor;if(!1===o&&(r=this[t]),s??=a.getPropertyOptions(t),!((s.hasChanged??y)(r,e)||s.useDefault&&s.reflect&&r===this._$Ej?.get(t)&&!this.hasAttribute(a._$Eu(t,s))))return;this.C(t,e,s)}!1===this.isUpdatePending&&(this._$ES=this._$EP())}C(t,e,{useDefault:s,reflect:o,wrapped:r},a){s&&!(this._$Ej??=/* @__PURE__ */new Map).has(t)&&(this._$Ej.set(t,a??e??this[t]),!0!==r||void 0!==a)||(this._$AL.has(t)||(this.hasUpdated||s||(e=void 0),this._$AL.set(t,e)),!0===o&&this._$Em!==t&&(this._$Eq??=/* @__PURE__ */new Set).add(t))}async _$EP(){this.isUpdatePending=!0;try{await this._$ES}catch(e){Promise.reject(e)}const t=this.scheduleUpdate();return null!=t&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??=this.createRenderRoot(),this._$Ep){for(const[t,e]of this._$Ep)this[t]=e;this._$Ep=void 0}const t=this.constructor.elementProperties;if(t.size>0)for(const[e,s]of t){const{wrapped:t}=s,o=this[e];!0!==t||this._$AL.has(e)||void 0===o||this.C(e,void 0,s,o)}}let t=!1;const e=this._$AL;try{t=this.shouldUpdate(e),t?(this.willUpdate(e),this._$EO?.forEach(t=>t.hostUpdate?.()),this.update(e)):this._$EM()}catch(s){throw t=!1,this._$EM(),s}t&&this._$AE(e)}willUpdate(t){}_$AE(t){this._$EO?.forEach(t=>t.hostUpdated?.()),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EM(){this._$AL=/* @__PURE__ */new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Eq&&=this._$Eq.forEach(t=>this._$ET(t,this[t])),this._$EM()}updated(t){}firstUpdated(t){}};k.elementStyles=[],k.shadowRootOptions={mode:"open"},k[m("elementProperties")]=/* @__PURE__ */new Map,k[m("finalized")]=/* @__PURE__ */new Map,_?.({ReactiveElement:k}),(u.reactiveElementVersions??=[]).push("2.1.2");const z={attribute:!0,type:String,converter:x,reflect:!1,hasChanged:y},$=(t=z,e,s)=>{const{kind:o,metadata:r}=s;let a=globalThis.litPropertyMetadata.get(r);if(void 0===a&&globalThis.litPropertyMetadata.set(r,a=/* @__PURE__ */new Map),"setter"===o&&((t=Object.create(t)).wrapped=!0),a.set(s.name,t),"accessor"===o){const{name:o}=s;return{set(s){const r=e.get.call(this);e.set.call(this,s),this.requestUpdate(o,r,t,!0,s)},init(e){return void 0!==e&&this.C(o,void 0,t,e),e}}}if("setter"===o){const{name:o}=s;return function(s){const r=this[o];e.call(this,s),this.requestUpdate(o,r,t,!0,s)}}throw Error("Unsupported decorator location: "+o)};function S(t){return(e,s)=>"object"==typeof s?$(t,e,s):((t,e,s)=>{const o=e.hasOwnProperty(s);return e.constructor.createProperty(s,t),o?Object.getOwnPropertyDescriptor(e,s):void 0})(t,e,s)}function C(t){return S({...t,state:!0,attribute:!1})}const E=(t,e,s)=>(s.configurable=!0,s.enumerable=!0,Reflect.decorate&&"object"!=typeof e&&Object.defineProperty(t,e,s),s);function L(t,e){return(e,s,o)=>E(e,s,{get(){return e=this,e.renderRoot?.querySelector(t)??null;var e}})}function O(t){return(e,s)=>{const{slot:o,selector:r}=t??{},a="slot"+(o?`[name=${o}]`:":not([name])");return E(e,s,{get(){const e=this.renderRoot?.querySelector(a),s=e?.assignedElements(t)??[];return void 0===r?s:s.filter(t=>t.matches(r))}})}}function A(t){return e=>{var s;customElements.get(t)||(s=t,(t,e)=>{void 0!==e?e.addInitializer(()=>{customElements.define(s,t)}):customElements.define(s,t)})(e)}}const D=globalThis,P=t=>t,T=D.trustedTypes,q=T?T.createPolicy("lit-html",{createHTML:t=>t}):void 0,M="$lit$",V=`lit$${Math.random().toFixed(9).slice(2)}$`,B="?"+V,I=`<${B}>`,R=document,j=()=>R.createComment(""),F=t=>null===t||"object"!=typeof t&&"function"!=typeof t,N=Array.isArray,U="[ \t\n\f\r]",H=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,K=/-->/g,G=/>/g,W=RegExp(`>|${U}(?:([^\\s"'>=/]+)(${U}*=${U}*(?:[^ \t\n\f\r"'\`<>=]|("|')|))|$)`,"g"),Z=/'/g,Y=/"/g,Q=/^(?:script|style|textarea|title)$/i,X=t=>(e,...s)=>({_$litType$:t,strings:e,values:s}),J=X(1),tt=X(2),et=/* @__PURE__ */Symbol.for("lit-noChange"),st=/* @__PURE__ */Symbol.for("lit-nothing"),ot=/* @__PURE__ */new WeakMap,rt=R.createTreeWalker(R,129);function at(t,e){if(!N(t)||!t.hasOwnProperty("raw"))throw Error("invalid template strings array");return void 0!==q?q.createHTML(e):e}class it{constructor({strings:t,_$litType$:e},s){let o;this.parts=[];let r=0,a=0;const i=t.length-1,d=this.parts,[n,l]=((t,e)=>{const s=t.length-1,o=[];let r,a=2===e?"<svg>":3===e?"<math>":"",i=H;for(let d=0;d<s;d++){const e=t[d];let s,n,l=-1,c=0;for(;c<e.length&&(i.lastIndex=c,n=i.exec(e),null!==n);)c=i.lastIndex,i===H?"!--"===n[1]?i=K:void 0!==n[1]?i=G:void 0!==n[2]?(Q.test(n[2])&&(r=RegExp("</"+n[2],"g")),i=W):void 0!==n[3]&&(i=W):i===W?">"===n[0]?(i=r??H,l=-1):void 0===n[1]?l=-2:(l=i.lastIndex-n[2].length,s=n[1],i=void 0===n[3]?W:'"'===n[3]?Y:Z):i===Y||i===Z?i=W:i===K||i===G?i=H:(i=W,r=void 0);const h=i===W&&t[d+1].startsWith("/>")?" ":"";a+=i===H?e+I:l>=0?(o.push(s),e.slice(0,l)+M+e.slice(l)+V+h):e+V+(-2===l?d:h)}return[at(t,a+(t[s]||"<?>")+(2===e?"</svg>":3===e?"</math>":"")),o]})(t,e);if(this.el=it.createElement(n,s),rt.currentNode=this.el.content,2===e||3===e){const t=this.el.content.firstChild;t.replaceWith(...t.childNodes)}for(;null!==(o=rt.nextNode())&&d.length<i;){if(1===o.nodeType){if(o.hasAttributes())for(const t of o.getAttributeNames())if(t.endsWith(M)){const e=l[a++],s=o.getAttribute(t).split(V),i=/([.?@])?(.*)/.exec(e);d.push({type:1,index:r,name:i[2],strings:s,ctor:"."===i[1]?ht:"?"===i[1]?pt:"@"===i[1]?gt:ct}),o.removeAttribute(t)}else t.startsWith(V)&&(d.push({type:6,index:r}),o.removeAttribute(t));if(Q.test(o.tagName)){const t=o.textContent.split(V),e=t.length-1;if(e>0){o.textContent=T?T.emptyScript:"";for(let s=0;s<e;s++)o.append(t[s],j()),rt.nextNode(),d.push({type:2,index:++r});o.append(t[e],j())}}}else if(8===o.nodeType)if(o.data===B)d.push({type:2,index:r});else{let t=-1;for(;-1!==(t=o.data.indexOf(V,t+1));)d.push({type:7,index:r}),t+=V.length-1}r++}}static createElement(t,e){const s=R.createElement("template");return s.innerHTML=t,s}}function dt(t,e,s=t,o){if(e===et)return e;let r=void 0!==o?s._$Co?.[o]:s._$Cl;const a=F(e)?void 0:e._$litDirective$;return r?.constructor!==a&&(r?._$AO?.(!1),void 0===a?r=void 0:(r=new a(t),r._$AT(t,s,o)),void 0!==o?(s._$Co??=[])[o]=r:s._$Cl=r),void 0!==r&&(e=dt(t,r._$AS(t,e.values),r,o)),e}class nt{constructor(t,e){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=e}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:e},parts:s}=this._$AD,o=(t?.creationScope??R).importNode(e,!0);rt.currentNode=o;let r=rt.nextNode(),a=0,i=0,d=s[0];for(;void 0!==d;){if(a===d.index){let e;2===d.type?e=new lt(r,r.nextSibling,this,t):1===d.type?e=new d.ctor(r,d.name,d.strings,this,t):6===d.type&&(e=new vt(r,this,t)),this._$AV.push(e),d=s[++i]}a!==d?.index&&(r=rt.nextNode(),a++)}return rt.currentNode=R,o}p(t){let e=0;for(const s of this._$AV)void 0!==s&&(void 0!==s.strings?(s._$AI(t,s,e),e+=s.strings.length-2):s._$AI(t[e])),e++}}class lt{get _$AU(){return this._$AM?._$AU??this._$Cv}constructor(t,e,s,o){this.type=2,this._$AH=st,this._$AN=void 0,this._$AA=t,this._$AB=e,this._$AM=s,this.options=o,this._$Cv=o?.isConnected??!0}get parentNode(){let t=this._$AA.parentNode;const e=this._$AM;return void 0!==e&&11===t?.nodeType&&(t=e.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,e=this){t=dt(this,t,e),F(t)?t===st||null==t||""===t?(this._$AH!==st&&this._$AR(),this._$AH=st):t!==this._$AH&&t!==et&&this._(t):void 0!==t._$litType$?this.$(t):void 0!==t.nodeType?this.T(t):(t=>N(t)||"function"==typeof t?.[Symbol.iterator])(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==st&&F(this._$AH)?this._$AA.nextSibling.data=t:this.T(R.createTextNode(t)),this._$AH=t}$(t){const{values:e,_$litType$:s}=t,o="number"==typeof s?this._$AC(t):(void 0===s.el&&(s.el=it.createElement(at(s.h,s.h[0]),this.options)),s);if(this._$AH?._$AD===o)this._$AH.p(e);else{const t=new nt(o,this),s=t.u(this.options);t.p(e),this.T(s),this._$AH=t}}_$AC(t){let e=ot.get(t.strings);return void 0===e&&ot.set(t.strings,e=new it(t)),e}k(t){N(this._$AH)||(this._$AH=[],this._$AR());const e=this._$AH;let s,o=0;for(const r of t)o===e.length?e.push(s=new lt(this.O(j()),this.O(j()),this,this.options)):s=e[o],s._$AI(r),o++;o<e.length&&(this._$AR(s&&s._$AB.nextSibling,o),e.length=o)}_$AR(t=this._$AA.nextSibling,e){for(this._$AP?.(!1,!0,e);t!==this._$AB;){const e=P(t).nextSibling;P(t).remove(),t=e}}setConnected(t){void 0===this._$AM&&(this._$Cv=t,this._$AP?.(t))}}class ct{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,e,s,o,r){this.type=1,this._$AH=st,this._$AN=void 0,this.element=t,this.name=e,this._$AM=o,this.options=r,s.length>2||""!==s[0]||""!==s[1]?(this._$AH=Array(s.length-1).fill(new String),this.strings=s):this._$AH=st}_$AI(t,e=this,s,o){const r=this.strings;let a=!1;if(void 0===r)t=dt(this,t,e,0),a=!F(t)||t!==this._$AH&&t!==et,a&&(this._$AH=t);else{const o=t;let i,d;for(t=r[0],i=0;i<r.length-1;i++)d=dt(this,o[s+i],e,i),d===et&&(d=this._$AH[i]),a||=!F(d)||d!==this._$AH[i],d===st?t=st:t!==st&&(t+=(d??"")+r[i+1]),this._$AH[i]=d}a&&!o&&this.j(t)}j(t){t===st?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class ht extends ct{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===st?void 0:t}}class pt extends ct{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==st)}}class gt extends ct{constructor(t,e,s,o,r){super(t,e,s,o,r),this.type=5}_$AI(t,e=this){if((t=dt(this,t,e,0)??st)===et)return;const s=this._$AH,o=t===st&&s!==st||t.capture!==s.capture||t.once!==s.once||t.passive!==s.passive,r=t!==st&&(s===st||o);o&&this.element.removeEventListener(this.name,this,s),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){"function"==typeof this._$AH?this._$AH.call(this.options?.host??this.element,t):this._$AH.handleEvent(t)}}class vt{constructor(t,e,s){this.element=t,this.type=6,this._$AN=void 0,this._$AM=e,this.options=s}get _$AU(){return this._$AM._$AU}_$AI(t){dt(this,t)}}const ut=D.litHtmlPolyfillSupport;ut?.(it,lt),(D.litHtmlVersions??=[]).push("3.3.3");const ft=globalThis;let bt=class extends k{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){const t=super.createRenderRoot();return this.renderOptions.renderBefore??=t.firstChild,t}update(t){const e=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=((t,e,s)=>{const o=s?.renderBefore??e;let r=o._$litPart$;if(void 0===r){const t=s?.renderBefore??null;o._$litPart$=r=new lt(e.insertBefore(j(),t),t,void 0,s??{})}return r._$AI(t),r})(e,this.renderRoot,this.renderOptions)}connectedCallback(){super.connectedCallback(),this._$Do?.setConnected(!0)}disconnectedCallback(){super.disconnectedCallback(),this._$Do?.setConnected(!1)}render(){return et}};bt._$litElement$=!0,bt.finalized=!0,ft.litElementHydrateSupport?.({LitElement:bt});const _t=ft.litElementPolyfillSupport;_t?.({LitElement:bt}),(ft.litElementVersions??=[]).push("4.2.2");class mt extends bt{constructor(){super(...arguments),this.sheriffVersion="2.14.0"}}const xt=/* @__PURE__ */Symbol.for(""),yt=t=>{if(t?.r===xt)return t?._$litStatic$},wt=t=>({_$litStatic$:t,r:xt}),kt=(t,...e)=>({_$litStatic$:e.reduce((e,s,o)=>e+(t=>{if(void 0!==t._$litStatic$)return t._$litStatic$;throw Error(`Value passed to 'literal' function must be a 'literal' result: ${t}. Use 'unsafeStatic' to pass non-literal values, but\n take care to ensure page security.`)})(s)+t[o+1],t[0]),r:xt}),zt=/* @__PURE__ */new Map,$t=(St=J,(t,...e)=>{const s=e.length;let o,r;const a=[],i=[];let d,n=0,l=!1;for(;n<s;){for(d=t[n];n<s&&void 0!==(r=e[n],o=yt(r));)d+=o+t[++n],l=!0;n!==s&&i.push(r),a.push(d),n++}if(n===s&&a.push(t[s]),l){const s=a.join("$$lit$$");void 0===(t=zt.get(s))&&(a.raw=a,zt.set(s,t=a)),e=i}return St(t,...e)});var St;const Ct=d`
2
2
  :host {
3
3
  --_sds-alert-background-color: var(--sds-alert-background-color, var(--sds-color-alert-info-surface-tinted));
4
4
 
@@ -174,7 +174,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
174
174
  margin: 0 !important;
175
175
  max-width: var(--_sds-alert-max-line-width) !important;
176
176
  }
177
- `,Et=/* @__PURE__ */new Set(["focus","blur","focusin","focusout","input","change","play","pause","ended","volumechange","timeupdate","durationchange","loadeddata","loadedmetadata","loadstart","canplay","canplaythrough","playing","seeked","stalled","suspend","waiting","ratechange","close","load","unload","abort","error","resize","scroll","keyup","select"]);function At(t){return class extends t{dispatchSheriffEvent(t,e,s=!Et.has(t)){return this.dispatchEvent(new CustomEvent(t,{detail:e,bubbles:!0,composed:!0,cancelable:s}))}dispatchKeyboardEvent(t,e){return this.dispatchEvent(new KeyboardEvent(t,{key:e.key,code:e.code,bubbles:!0,composed:!0,cancelable:!Et.has(t),ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,metaKey:e.metaKey,repeat:e.repeat,isComposing:e.isComposing,location:e.location}))}}}var Lt=Object.defineProperty,Ot=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Lt(e,s,a),a};const Pt={info:"InformationSquareFill-aksel-filled",success:"check_circle-material-filled",attention:"warning-material-filled",danger:"dangerous-material-filled"},Dt=class extends(At(mt)){constructor(){super(...arguments),this.variant="primary",this.size="md",this.palette="info",this.iconTag=kt`sds-icon`,this.buttonTag=kt`sds-button`,this._remove=()=>{this.dispatchSheriffEvent("sds-remove")},this._renderIcon=(t,e)=>$t`<${this.iconTag} name="${t}" size=${e}></${this.iconTag}>`,this._renderRemoveButton=t=>$t`<${this.buttonTag}
177
+ `,Et=/* @__PURE__ */new Set(["focus","blur","focusin","focusout","input","change","play","pause","ended","volumechange","timeupdate","durationchange","loadeddata","loadedmetadata","loadstart","canplay","canplaythrough","playing","seeked","stalled","suspend","waiting","ratechange","close","load","unload","abort","error","resize","scroll","keyup","select"]);function Lt(t){return class extends t{dispatchSheriffEvent(t,e,s=!Et.has(t)){return this.dispatchEvent(new CustomEvent(t,{detail:e,bubbles:!0,composed:!0,cancelable:s}))}dispatchKeyboardEvent(t,e){return this.dispatchEvent(new KeyboardEvent(t,{key:e.key,code:e.code,bubbles:!0,composed:!0,cancelable:!Et.has(t),ctrlKey:e.ctrlKey,shiftKey:e.shiftKey,altKey:e.altKey,metaKey:e.metaKey,repeat:e.repeat,isComposing:e.isComposing,location:e.location}))}}}var Ot=Object.defineProperty,At=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Ot(e,s,a),a};const Dt={info:"InformationSquareFill-aksel-filled",success:"check_circle-material-filled",attention:"warning-material-filled",danger:"dangerous-material-filled"},Pt=class extends(Lt(mt)){constructor(){super(...arguments),this.variant="primary",this.size="md",this.palette="info",this.iconTag=kt`sds-icon`,this.buttonTag=kt`sds-button`,this._remove=()=>{this.dispatchSheriffEvent("sds-remove")},this._renderIcon=(t,e)=>$t`<${this.iconTag} name="${t}" size=${e}></${this.iconTag}>`,this._renderRemoveButton=t=>$t`<${this.buttonTag}
178
178
  class="sds-alert__remove-btn"
179
179
  variant="tertiary"
180
180
  size="sm"
@@ -183,14 +183,14 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
183
183
  @click=${this._remove}
184
184
  >
185
185
  ${this._renderIcon("close-material-outlined","sm")}
186
- </${this.buttonTag}>`}render(){const t="primary"===this.variant?"md":this.size??"md",e=Pt[this.palette]??Pt.info;return J`<div class="sds-alert">
186
+ </${this.buttonTag}>`}render(){const t="primary"===this.variant?"md":this.size??"md",e=Dt[this.palette]??Dt.info;return J`<div class="sds-alert">
187
187
  <div class="sds-alert__type">${this._renderIcon(e,t)}</div>
188
188
  <div class="sds-alert__content">
189
189
  <slot name="title"></slot>
190
190
  <slot name="message"></slot>
191
191
  </div>
192
192
  ${this.removableLabel&&"primary"===this.variant?J`<div class="sds-alert__actions">${this._renderRemoveButton(this.removableLabel)}</div>`:st}
193
- </div>`}};Dt.styles=[Ct];let Tt=Dt;Ot([S({type:String,reflect:!0})],Tt.prototype,"variant"),Ot([S({type:String,reflect:!0})],Tt.prototype,"size"),Ot([S({type:String,attribute:"removable-label",reflect:!0})],Tt.prototype,"removableLabel"),Ot([S({type:String,attribute:"data-palette",reflect:!0})],Tt.prototype,"palette");const qt=t=>t??st,Mt=1,Vt=2,Bt=t=>(...e)=>({_$litDirective$:t,values:e});class Rt{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this._$Ct=t,this._$AM=e,this._$Ci=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}let jt=class extends Rt{constructor(t){if(super(t),this.it=st,t.type!==Vt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===st||null==t)return this._t=void 0,this.it=t;if(t===et)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const e=[t];return e.raw=e,this._t={_$litType$:this.constructor.resultType,strings:e,values:[]}}};jt.directiveName="unsafeHTML",jt.resultType=1;let It=class extends jt{};It.directiveName="unsafeSVG",It.resultType=2;const Nt=Bt(It),Ht=["arrow_forward-material-outlined","check_circle-material-filled","close-material-outlined","dangerous-material-filled","InformationSquareFill-aksel-filled","lock-material-filled","search-material-filled","warning-material-filled","chevron_up-material-filled"],Ft={"arrow_forward-material-outlined":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M662.82-440.39H145.87v-79.22h516.95L423.87-758.57 480-814.7 814.7-480 480-145.87l-56.13-55.56z"/></svg>',"check_circle-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="m419.87-289.52 289.22-289.22-57.31-56.87L419.87-403.7 304.96-518.61l-56.31 56.87zm60.21 223.65q-85.47 0-161.01-32.39-75.53-32.4-131.97-88.84T98.26-318.99q-32.39-75.46-32.39-160.93 0-86.47 32.39-162.01 32.4-75.53 88.75-131.5t131.85-88.62 161.01-32.65q86.52 0 162.12 32.61 75.61 32.6 131.53 88.5 55.93 55.89 88.55 131.45Q894.7-566.58 894.7-480q0 85.55-32.65 161.07-32.65 75.53-88.62 131.9T642.01-98.26q-75.46 32.39-161.93 32.39"/></svg>',"close-material-outlined":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M249-193.43 193.43-249l231-231-231-231L249-766.57l231 231 231-231L766.57-711l-231 231 231 231L711-193.43l-231-231z"/></svg>',"dangerous-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M324.35-105.87 105.87-324.35v-311.87L324.35-854.7h311.87L854.7-636.22v311.87L636.22-105.87zm34.91-206.87L480-433.48l120.74 120.74 47.09-46.52L526.52-480l121.31-120.74-47.09-47.09L480-526.52 359.26-647.83l-46.52 47.09L433.48-480 312.74-359.26z"/></svg>',"InformationSquareFill-aksel-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path fill-rule="evenodd" d="M3.25 4A.75.75 0 0 1 4 3.25h16a.75.75 0 0 1 .75.75v16a.75.75 0 0 1-.75.75H4a.75.75 0 0 1-.75-.75zM11 7.75a1 1 0 1 1 2 0 1 1 0 0 1-2 0m-1.25 3a.75.75 0 0 1 .75-.75H12a.75.75 0 0 1 .75.75v4.75h.75a.75.75 0 0 1 0 1.5h-3a.75.75 0 0 1 0-1.5h.75v-4h-.75a.75.75 0 0 1-.75-.75" clip-rule="evenodd"/></svg>',"lock-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M225.09-67q-32.68 0-55.95-23.27t-23.27-55.95v-423.82q0-32.91 23.27-56.35t55.95-23.44h58.69v-83.56q0-82.44 57.17-140.18 57.16-57.73 139.02-57.73t139.05 57.73q57.2 57.74 57.2 140.18v83.56h58.69q32.91 0 56.35 23.44t23.44 56.35v423.82q0 32.68-23.44 55.95T734.91-67zm255.08-214.13q31.83 0 54.33-22.03t22.5-52.97q0-30-22.67-54.5t-54.5-24.5-54.33 24.5-22.5 55 22.67 52.5 54.5 22M363-649.83h234v-83.43q0-49.96-33.79-84.11-33.8-34.15-82.96-34.15t-83.21 34.15Q363-783.22 363-733.26z"/></svg>',"search-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M795.43-105.17 529.04-371q-29.43 24.26-69.11 37.94-39.67 13.67-85.32 13.67-112.12 0-189.87-77.83Q107-475.04 107-585t77.83-187.78q77.82-77.83 188.28-77.83t187.78 77.83q77.33 77.82 77.33 187.93 0 43.98-13.15 83.13-13.16 39.15-39.46 73.59L853-162.74zM373.81-398.61q77.66 0 131.42-54.53Q559-507.67 559-585t-53.85-131.86-131.34-54.53q-78.33 0-132.96 54.53T186.22-585t54.55 131.86 133.04 54.53"/></svg>',"warning-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M27.56-112.65 480-894.7l452.44 782.05zm456.62-125.48q13.15 0 22.61-9.64 9.47-9.65 9.47-22.8t-9.64-22.33q-9.65-9.19-22.8-9.19t-22.61 9.36q-9.47 9.36-9.47 22.51t9.64 22.62q9.65 9.47 22.8 9.47M454-348h60v-219.48h-60z"/></svg>',"chevron_up-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 32 32"><path d="m16 11.5 8 8-1.867 1.867L16 15.233l-6.133 6.134L8 19.5z"/></svg>'},Ut=t=>import(`@politiet/sheriff-icons/dist/assets/${t}.js`).then(({default:t})=>t),Gt=t=>fetch(`https://cdn.jsdelivr.net/npm/@politiet/sheriff-icons/dist/assets/${t}.svg`).then(e=>{if(!e.ok)throw new TypeError(`Sheriff: unknown icon: '${t}'`);return e.text()});const Kt=d`
193
+ </div>`}};Pt.styles=[Ct];let Tt=Pt;At([S({type:String,reflect:!0})],Tt.prototype,"variant"),At([S({type:String,reflect:!0})],Tt.prototype,"size"),At([S({type:String,attribute:"removable-label",reflect:!0})],Tt.prototype,"removableLabel"),At([S({type:String,attribute:"data-palette",reflect:!0})],Tt.prototype,"palette");const qt=t=>t??st,Mt=1,Vt=2,Bt=3,It=4,Rt=t=>(...e)=>({_$litDirective$:t,values:e});class jt{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,e,s){this._$Ct=t,this._$AM=e,this._$Ci=s}_$AS(t,e){return this.update(t,e)}update(t,e){return this.render(...e)}}let Ft=class extends jt{constructor(t){if(super(t),this.it=st,t.type!==Vt)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===st||null==t)return this._t=void 0,this.it=t;if(t===et)return t;if("string"!=typeof t)throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const e=[t];return e.raw=e,this._t={_$litType$:this.constructor.resultType,strings:e,values:[]}}};Ft.directiveName="unsafeHTML",Ft.resultType=1;let Nt=class extends Ft{};Nt.directiveName="unsafeSVG",Nt.resultType=2;const Ut=Rt(Nt),Ht=["arrow_forward-material-outlined","check_circle-material-filled","close-material-outlined","dangerous-material-filled","InformationSquareFill-aksel-filled","lock-material-filled","search-material-filled","warning-material-filled","chevron_up-material-filled"],Kt={"arrow_forward-material-outlined":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M662.82-440.39H145.87v-79.22h516.95L423.87-758.57 480-814.7 814.7-480 480-145.87l-56.13-55.56z"/></svg>',"check_circle-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="m419.87-289.52 289.22-289.22-57.31-56.87L419.87-403.7 304.96-518.61l-56.31 56.87zm60.21 223.65q-85.47 0-161.01-32.39-75.53-32.4-131.97-88.84T98.26-318.99q-32.39-75.46-32.39-160.93 0-86.47 32.39-162.01 32.4-75.53 88.75-131.5t131.85-88.62 161.01-32.65q86.52 0 162.12 32.61 75.61 32.6 131.53 88.5 55.93 55.89 88.55 131.45Q894.7-566.58 894.7-480q0 85.55-32.65 161.07-32.65 75.53-88.62 131.9T642.01-98.26q-75.46 32.39-161.93 32.39"/></svg>',"close-material-outlined":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M249-193.43 193.43-249l231-231-231-231L249-766.57l231 231 231-231L766.57-711l-231 231 231 231L711-193.43l-231-231z"/></svg>',"dangerous-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M324.35-105.87 105.87-324.35v-311.87L324.35-854.7h311.87L854.7-636.22v311.87L636.22-105.87zm34.91-206.87L480-433.48l120.74 120.74 47.09-46.52L526.52-480l121.31-120.74-47.09-47.09L480-526.52 359.26-647.83l-46.52 47.09L433.48-480 312.74-359.26z"/></svg>',"InformationSquareFill-aksel-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 24 24"><path fill-rule="evenodd" d="M3.25 4A.75.75 0 0 1 4 3.25h16a.75.75 0 0 1 .75.75v16a.75.75 0 0 1-.75.75H4a.75.75 0 0 1-.75-.75zM11 7.75a1 1 0 1 1 2 0 1 1 0 0 1-2 0m-1.25 3a.75.75 0 0 1 .75-.75H12a.75.75 0 0 1 .75.75v4.75h.75a.75.75 0 0 1 0 1.5h-3a.75.75 0 0 1 0-1.5h.75v-4h-.75a.75.75 0 0 1-.75-.75" clip-rule="evenodd"/></svg>',"lock-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M225.09-67q-32.68 0-55.95-23.27t-23.27-55.95v-423.82q0-32.91 23.27-56.35t55.95-23.44h58.69v-83.56q0-82.44 57.17-140.18 57.16-57.73 139.02-57.73t139.05 57.73q57.2 57.74 57.2 140.18v83.56h58.69q32.91 0 56.35 23.44t23.44 56.35v423.82q0 32.68-23.44 55.95T734.91-67zm255.08-214.13q31.83 0 54.33-22.03t22.5-52.97q0-30-22.67-54.5t-54.5-24.5-54.33 24.5-22.5 55 22.67 52.5 54.5 22M363-649.83h234v-83.43q0-49.96-33.79-84.11-33.8-34.15-82.96-34.15t-83.21 34.15Q363-783.22 363-733.26z"/></svg>',"search-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M795.43-105.17 529.04-371q-29.43 24.26-69.11 37.94-39.67 13.67-85.32 13.67-112.12 0-189.87-77.83Q107-475.04 107-585t77.83-187.78q77.82-77.83 188.28-77.83t187.78 77.83q77.33 77.82 77.33 187.93 0 43.98-13.15 83.13-13.16 39.15-39.46 73.59L853-162.74zM373.81-398.61q77.66 0 131.42-54.53Q559-507.67 559-585t-53.85-131.86-131.34-54.53q-78.33 0-132.96 54.53T186.22-585t54.55 131.86 133.04 54.53"/></svg>',"warning-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 -960 960 960"><path d="M27.56-112.65 480-894.7l452.44 782.05zm456.62-125.48q13.15 0 22.61-9.64 9.47-9.65 9.47-22.8t-9.64-22.33q-9.65-9.19-22.8-9.19t-22.61 9.36q-9.47 9.36-9.47 22.51t9.64 22.62q9.65 9.47 22.8 9.47M454-348h60v-219.48h-60z"/></svg>',"chevron_up-material-filled":'<svg xmlns="http://www.w3.org/2000/svg" fill="currentColor" viewBox="0 0 32 32"><path d="m16 11.5 8 8-1.867 1.867L16 15.233l-6.133 6.134L8 19.5z"/></svg>'},Gt=t=>import(`@politiet/sheriff-icons/dist/assets/${t}.js`).then(({default:t})=>t),Wt=t=>fetch(`https://cdn.jsdelivr.net/npm/@politiet/sheriff-icons/dist/assets/${t}.svg`).then(e=>{if(!e.ok)throw new TypeError(`Sheriff: unknown icon: '${t}'`);return e.text()});const Zt=d`
194
194
  :host {
195
195
  --_sds-icon-size: var(--sds-icon-size, var(--sds-components-icon-md));
196
196
  --_sds-icon-color: var(--sds-icon-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
@@ -223,11 +223,11 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
223
223
  height: 100%;
224
224
  overflow: hidden;
225
225
  }
226
- `;var Wt=Object.defineProperty,Zt=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Wt(e,s,a),a};const Yt=((t=class extends mt{constructor(){super(...arguments),this.name="",this.color="",this.label="",this.svg=""}static setLoadLocal(t){this.iconLoader.loadLocal=t}static registerResolver(t){this.iconLoader.resolver=t}render(){return J`
226
+ `;var Yt=Object.defineProperty,Qt=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Yt(e,s,a),a};const Xt=((t=class extends mt{constructor(){super(...arguments),this.name="",this.color="",this.label="",this.svg=""}static setLoadLocal(t){this.iconLoader.loadLocal=t}static registerResolver(t){this.iconLoader.resolver=t}render(){return J`
227
227
  <div class="sds-icon" role="${qt(this.label?"img":void 0)}" style="${qt(this.color?`color:${this.color}`:void 0)}" aria-label="${qt(this.label)}">
228
- ${this.name?J`<slot aria-hidden="true">${Nt(this.svg)}</slot>`:J`<slot aria-hidden="true"></slot>`}
228
+ ${this.name?J`<slot aria-hidden="true">${Ut(this.svg)}</slot>`:J`<slot aria-hidden="true"></slot>`}
229
229
  </div>
230
- `}async fetchIcon(){if(!this.name)return void(this.svg="");const e=await new Promise(e=>{t.iconLoader.resolve(this.name,e)});this.svg=e}updated(t){super.updated(t),t.has("name")&&this.name&&this.fetchIcon()}}).styles=[Kt],t.iconLoader=new class{constructor(){this.cache=/* @__PURE__ */new Map,this.pending=/* @__PURE__ */new Map,this._loadLocal=!1,this._disableSystemIcons=!1,this.resolver=this._loadLocal?Ut:Gt}get loadLocal(){return this._loadLocal}set loadLocal(t){this._loadLocal=t,this.resolver=t?Ut:Gt}set disableSystemIcons(t){this._disableSystemIcons=t}resolve(t,e){if(!this._disableSystemIcons&&(t=>Ht.includes(t))(t))return void e(Ft[t]);const s=this.cache.get(t);if("string"==typeof s)e(s);else{const s=this.pending.get(t);if(s)return void s.then(e);const o=this.resolver(t).then(e=>(this.cache.set(t,e),e)).catch(()=>"").finally(()=>{this.pending.delete(t)});this.pending.set(t,o),o.then(e)}}clear(){this.cache.clear(),this.pending.clear()}get currentLoader(){return this.resolver}},t);Zt([S({type:String,reflect:!0})],Yt.prototype,"name"),Zt([S({type:String,reflect:!0})],Yt.prototype,"size"),Zt([S({type:String,reflect:!0})],Yt.prototype,"color"),Zt([S({type:String,reflect:!0})],Yt.prototype,"label"),Zt([C()],Yt.prototype,"svg");let Qt=Yt;var Xt=Object.getOwnPropertyDescriptor;let Jt=class extends Qt{};Jt=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Xt(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-icon")],Jt);const te=Bt(class extends Rt{constructor(t){if(super(t),t.type!==Mt||"class"!==t.name||t.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter(e=>t[e]).join(" ")+" "}update(t,[e]){if(void 0===this.st){this.st=/* @__PURE__ */new Set,void 0!==t.strings&&(this.nt=new Set(t.strings.join(" ").split(/\s/).filter(t=>""!==t)));for(const t in e)e[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(e)}const s=t.element.classList;for(const o of this.st)o in e||(s.remove(o),this.st.delete(o));for(const o in e){const t=!!e[o];t===this.st.has(o)||this.nt?.has(o)||(t?(s.add(o),this.st.add(o)):(s.remove(o),this.st.delete(o)))}return et}}),ee=d`
230
+ `}async fetchIcon(){if(!this.name)return void(this.svg="");const e=await new Promise(e=>{t.iconLoader.resolve(this.name,e)});this.svg=e}updated(t){super.updated(t),t.has("name")&&this.name&&this.fetchIcon()}}).styles=[Zt],t.iconLoader=new class{constructor(){this.cache=/* @__PURE__ */new Map,this.pending=/* @__PURE__ */new Map,this._loadLocal=!1,this._disableSystemIcons=!1,this.resolver=this._loadLocal?Gt:Wt}get loadLocal(){return this._loadLocal}set loadLocal(t){this._loadLocal=t,this.resolver=t?Gt:Wt}set disableSystemIcons(t){this._disableSystemIcons=t}resolve(t,e){if(!this._disableSystemIcons&&(t=>Ht.includes(t))(t))return void e(Kt[t]);const s=this.cache.get(t);if("string"==typeof s)e(s);else{const s=this.pending.get(t);if(s)return void s.then(e);const o=this.resolver(t).then(e=>(this.cache.set(t,e),e)).catch(()=>"").finally(()=>{this.pending.delete(t)});this.pending.set(t,o),o.then(e)}}clear(){this.cache.clear(),this.pending.clear()}get currentLoader(){return this.resolver}},t);Qt([S({type:String,reflect:!0})],Xt.prototype,"name"),Qt([S({type:String,reflect:!0})],Xt.prototype,"size"),Qt([S({type:String,reflect:!0})],Xt.prototype,"color"),Qt([S({type:String,reflect:!0})],Xt.prototype,"label"),Qt([C()],Xt.prototype,"svg");let Jt=Xt;var te=Object.getOwnPropertyDescriptor;let ee=class extends Jt{};ee=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?te(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-icon")],ee);const se=Rt(class extends jt{constructor(t){if(super(t),t.type!==Mt||"class"!==t.name||t.strings?.length>2)throw Error("`classMap()` can only be used in the `class` attribute and must be the only part in the attribute.")}render(t){return" "+Object.keys(t).filter(e=>t[e]).join(" ")+" "}update(t,[e]){if(void 0===this.st){this.st=/* @__PURE__ */new Set,void 0!==t.strings&&(this.nt=new Set(t.strings.join(" ").split(/\s/).filter(t=>""!==t)));for(const t in e)e[t]&&!this.nt?.has(t)&&this.st.add(t);return this.render(e)}const s=t.element.classList;for(const o of this.st)o in e||(s.remove(o),this.st.delete(o));for(const o in e){const t=!!e[o];t===this.st.has(o)||this.nt?.has(o)||(t?(s.add(o),this.st.add(o)):(s.remove(o),this.st.delete(o)))}return et}}),oe=d`
231
231
  :host {
232
232
  --_sds-button-background-color: var(--sds-button-background-color, var(--sds-color-action-default, var(--sds-color-main-action-default)));
233
233
  --_sds-button-border-color: var(--sds-button-border-color, var(--sds-color-action-default, var(--sds-color-main-action-default)));
@@ -484,7 +484,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
484
484
  --_sds-button-text-color: var(--sds-button-text-color, var(--sds-color-action-contrast-default, var(--sds-color-neutral-action-contrast-default)));
485
485
  }
486
486
  }
487
- `;function se(t){return class extends t{focus(){this.disabled||this.control?.focus()}blur(){this.disabled||this.control?.blur()}click(){this.disabled||this.readOnly||this.control?.click()}}}var oe=Object.defineProperty,re=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&oe(e,s,a),a};function ae(t){const e=class extends t{constructor(...t){super(...t),this.disabled=!1,this.readOnly=!1,this.internals=this.attachInternals()}get readonly(){return this.readOnly}set readonly(t){this.readOnly=t??!1}get form(){return this.internals.form}formDisabledCallback(t){this.disabled=t}firstUpdated(t){super.firstUpdated(t),this.updateValidity()}updateValidity(){}};e.formAssociated=!0,e.shadowRootOptions={...bt.shadowRootOptions,delegatesFocus:!0};let s=e;return re([S({type:String,reflect:!0})],s.prototype,"name"),re([S({type:Boolean,reflect:!0})],s.prototype,"disabled"),re([S({type:Boolean,attribute:"readonly",reflect:!0})],s.prototype,"readOnly"),s}var ie=Object.defineProperty,de=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ie(e,s,a),a};var ne=Object.defineProperty,le=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ne(e,s,a),a};var ce=Object.defineProperty,he=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ce(e,s,a),a};const pe=class extends(function(t){class e extends t{get effectiveCommand(){return this.command??this.dataCommand}get effectiveCommandFor(){return this.commandFor??this.dataCommandFor}updated(t){super.updated(t),(t.has("command")||t.has("commandFor")||t.has("dataCommand")||t.has("dataCommandFor"))&&this._updateCommandTarget()}connectedCallback(){super.connectedCallback(),this.hasUpdated&&this._updateCommandTarget()}disconnectedCallback(){super.disconnectedCallback(),this._cleanupDialogObserver()}_cleanupDialogObserver(){this._dialogOpenObserver&&(this._dialogOpenObserver.disconnect(),this._dialogOpenObserver=void 0),this._dialogElement=void 0}_observeDialog(t,e){this._dialogOpenObserver=new MutationObserver(s=>{for(const o of s)if("open"===o.attributeName){const s=e.hasAttribute("open");t.setAttribute("aria-expanded",String(s))}}),this._dialogOpenObserver.observe(e,{attributes:!0,attributeFilter:["open"]})}_clearAriaFields(t){t.removeAttribute("aria-haspopup"),t.removeAttribute("aria-expanded"),t.removeAttribute("aria-controls")}_updateCommandTarget(){this._cleanupDialogObserver();const t=this.shadowRoot?.querySelector("#control");if(!t)return;const e=this.effectiveCommand,s=this.effectiveCommandFor;if(!s||!e)return void this._clearAriaFields(t);const o=this.getRootNode(),r=o.getElementById?.(s)??document.getElementById(s);var a;null!=(a=r)&&"showModal"in a&&"requestClose"in a&&"close"in a&&"open"in a?(this._dialogElement=r,"show-modal"===e?(t.setAttribute("aria-haspopup","dialog"),t.setAttribute("aria-expanded",String(r.open)),t.setAttribute("aria-controls",s),this._observeDialog(t,r)):this._clearAriaFields(t)):this._clearAriaFields(t)}runDialogCommand(){if(this._dialogElement?.isConnected||this._updateCommandTarget(),this._dialogElement)switch(this.effectiveCommand){case"show-modal":this._dialogElement.showModal();break;case"close":this._dialogElement.close();break;case"request-close":this._dialogElement.requestClose()}}}return de([S({type:String,attribute:"command",reflect:!0})],e.prototype,"command"),de([S({type:String,attribute:"commandfor",reflect:!0})],e.prototype,"commandFor"),de([S({type:String,attribute:"data-command"})],e.prototype,"dataCommand"),de([S({type:String,attribute:"data-commandfor"})],e.prototype,"dataCommandFor"),e}(function(t){class e extends t{updated(t){super.updated(t),(t.has("popoverTarget")||t.has("popoverTargetAction"))&&this._updatePopoverTarget()}disconnectedCallback(){super.disconnectedCallback(),this._cleanupPopoverListener()}_cleanupPopoverListener(){this._popoverToggleHandler&&this._popoverElement&&(this._popoverElement.removeEventListener("toggle",this._popoverToggleHandler),this._popoverToggleHandler=void 0,this._popoverElement=void 0)}_updatePopoverTarget(){const t=this.shadowRoot?.querySelector("#control");if(t)if(this._cleanupPopoverListener(),this.popoverTarget){const e=this.getRootNode(),s=e.getElementById?.(this.popoverTarget)??document.getElementById(this.popoverTarget);if(s){t.popoverTargetElement=s,this._popoverElement=s;const e=s.getAttribute("role");"tooltip"===e?t.setAttribute("aria-describedby",this.popoverTarget):(this._popoverToggleHandler=e=>{const s="open"===e.newState;t.setAttribute("aria-expanded",String(s))},s.addEventListener("toggle",this._popoverToggleHandler),t.setAttribute("aria-haspopup",e||"dialog"),t.setAttribute("aria-expanded","false"),t.setAttribute("aria-controls",this.popoverTarget))}this.popoverTargetAction&&(t.popoverTargetAction=this.popoverTargetAction)}else t.popoverTargetElement=null,t.popoverTargetAction="",t.removeAttribute("aria-haspopup"),t.removeAttribute("aria-expanded"),t.removeAttribute("aria-controls"),t.removeAttribute("aria-describedby")}}return le([S({type:String,attribute:"popovertarget"})],e.prototype,"popoverTarget"),le([S({type:String,attribute:"popovertargetaction"})],e.prototype,"popoverTargetAction"),e}(se(At(mt))))){constructor(){super(),this.disabled=!1,this.icon=!1,this.inverted=!1,this.loading=!1,this.size="lg",this.type="button",this.value="",this.variant="primary",this.label=void 0,this._handleClick=t=>{this.popoverTarget?this._handlePopoverClick(t):(t.preventDefault(),t.stopImmediatePropagation(),this.disabled||(this.effectiveCommandFor&&this.effectiveCommand?this._handleDialogCommandClick():"submit"===this.type?this._handleSubmitClick():"reset"===this.type?this._handleResetClick():this.dispatchSheriffEvent("click")))},this.internals=this.attachInternals()}updated(t){super.updated(t),t.has("variant")&&"critical"===this.variant&&this.setAttribute("data-palette","danger")}_resolveForm(){if(this.form){return this.getRootNode().querySelector(`form#${this.form}`)}return this.internals.form}_handlePopoverClick(t){t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("click")}_handleDialogCommandClick(){this.runDialogCommand(),this.dispatchSheriffEvent("click")}_handleSubmitClick(){this.dispatchSheriffEvent("submit")&&this._resolveForm()?.requestSubmit()}_handleResetClick(){this.dispatchSheriffEvent("reset")&&this._resolveForm()?.reset()}render(){const t={"sds-button":!0,"sds-button--as-link":!!this.href};return this.href?J` <a id="link" class="${te(t)}" href="${this.href}" target="${qt(this.target)}">
487
+ `;function re(t){return class extends t{focus(){this.disabled||this.control?.focus()}blur(){this.disabled||this.control?.blur()}click(){this.disabled||this.readOnly||this.control?.click()}}}var ae=Object.defineProperty,ie=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ae(e,s,a),a};function de(t){const e=class extends t{constructor(...t){super(...t),this.disabled=!1,this.readOnly=!1,this.internals=this.attachInternals()}get readonly(){return this.readOnly}set readonly(t){this.readOnly=t??!1}get form(){return this.internals.form}formDisabledCallback(t){this.disabled=t}firstUpdated(t){super.firstUpdated(t),this.updateValidity()}updateValidity(){}};e.formAssociated=!0,e.shadowRootOptions={...bt.shadowRootOptions,delegatesFocus:!0};let s=e;return ie([S({type:String,reflect:!0})],s.prototype,"name"),ie([S({type:Boolean,reflect:!0})],s.prototype,"disabled"),ie([S({type:Boolean,attribute:"readonly",reflect:!0})],s.prototype,"readOnly"),s}var ne=Object.defineProperty,le=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ne(e,s,a),a};var ce=Object.defineProperty,he=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&ce(e,s,a),a};var pe=Object.defineProperty,ge=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&pe(e,s,a),a};const ve=class extends(function(t){class e extends t{get effectiveCommand(){return this.command??this.dataCommand}get effectiveCommandFor(){return this.commandFor??this.dataCommandFor}updated(t){super.updated(t),(t.has("command")||t.has("commandFor")||t.has("dataCommand")||t.has("dataCommandFor"))&&this._updateCommandTarget()}connectedCallback(){super.connectedCallback(),this.hasUpdated&&this._updateCommandTarget()}disconnectedCallback(){super.disconnectedCallback(),this._cleanupDialogObserver()}_cleanupDialogObserver(){this._dialogOpenObserver&&(this._dialogOpenObserver.disconnect(),this._dialogOpenObserver=void 0),this._dialogElement=void 0}_observeDialog(t,e){this._dialogOpenObserver=new MutationObserver(s=>{for(const o of s)if("open"===o.attributeName){const s=e.hasAttribute("open");t.setAttribute("aria-expanded",String(s))}}),this._dialogOpenObserver.observe(e,{attributes:!0,attributeFilter:["open"]})}_clearAriaFields(t){t.removeAttribute("aria-haspopup"),t.removeAttribute("aria-expanded"),t.removeAttribute("aria-controls")}_updateCommandTarget(){this._cleanupDialogObserver();const t=this.shadowRoot?.querySelector("#control");if(!t)return;const e=this.effectiveCommand,s=this.effectiveCommandFor;if(!s||!e)return void this._clearAriaFields(t);const o=this.getRootNode(),r=o.getElementById?.(s)??document.getElementById(s);var a;null!=(a=r)&&"showModal"in a&&"requestClose"in a&&"close"in a&&"open"in a?(this._dialogElement=r,"show-modal"===e?(t.setAttribute("aria-haspopup","dialog"),t.setAttribute("aria-expanded",String(r.open)),t.setAttribute("aria-controls",s),this._observeDialog(t,r)):this._clearAriaFields(t)):this._clearAriaFields(t)}runDialogCommand(){if(this._dialogElement?.isConnected||this._updateCommandTarget(),this._dialogElement)switch(this.effectiveCommand){case"show-modal":this._dialogElement.showModal();break;case"close":this._dialogElement.close();break;case"request-close":this._dialogElement.requestClose()}}}return le([S({type:String,attribute:"command",reflect:!0})],e.prototype,"command"),le([S({type:String,attribute:"commandfor",reflect:!0})],e.prototype,"commandFor"),le([S({type:String,attribute:"data-command"})],e.prototype,"dataCommand"),le([S({type:String,attribute:"data-commandfor"})],e.prototype,"dataCommandFor"),e}(function(t){class e extends t{updated(t){super.updated(t),(t.has("popoverTarget")||t.has("popoverTargetAction"))&&this._updatePopoverTarget()}disconnectedCallback(){super.disconnectedCallback(),this._cleanupPopoverListener()}_cleanupPopoverListener(){this._popoverToggleHandler&&this._popoverElement&&(this._popoverElement.removeEventListener("toggle",this._popoverToggleHandler),this._popoverToggleHandler=void 0,this._popoverElement=void 0)}_updatePopoverTarget(){const t=this.shadowRoot?.querySelector("#control");if(t)if(this._cleanupPopoverListener(),this.popoverTarget){const e=this.getRootNode(),s=e.getElementById?.(this.popoverTarget)??document.getElementById(this.popoverTarget);if(s){t.popoverTargetElement=s,this._popoverElement=s;const e=s.getAttribute("role");"tooltip"===e?t.setAttribute("aria-describedby",this.popoverTarget):(this._popoverToggleHandler=e=>{const s="open"===e.newState;t.setAttribute("aria-expanded",String(s))},s.addEventListener("toggle",this._popoverToggleHandler),t.setAttribute("aria-haspopup",e||"dialog"),t.setAttribute("aria-expanded","false"),t.setAttribute("aria-controls",this.popoverTarget))}this.popoverTargetAction&&(t.popoverTargetAction=this.popoverTargetAction)}else t.popoverTargetElement=null,t.popoverTargetAction="",t.removeAttribute("aria-haspopup"),t.removeAttribute("aria-expanded"),t.removeAttribute("aria-controls"),t.removeAttribute("aria-describedby")}}return he([S({type:String,attribute:"popovertarget"})],e.prototype,"popoverTarget"),he([S({type:String,attribute:"popovertargetaction"})],e.prototype,"popoverTargetAction"),e}(re(Lt(mt))))){constructor(){super(),this.disabled=!1,this.icon=!1,this.inverted=!1,this.loading=!1,this.size="lg",this.type="button",this.value="",this.variant="primary",this.label=void 0,this._handleClick=t=>{if(this.popoverTarget)return void this._handlePopoverClick(t);if(t.preventDefault(),t.stopImmediatePropagation(),this.disabled)return;const e=this.internals.form;e&&"submit"===this.type?this._handleSubmitClick():e&&"reset"===this.type?this._handleResetClick():this.effectiveCommandFor&&this.effectiveCommand?this._handleDialogCommandClick():this.dispatchSheriffEvent("click")},this.internals=this.attachInternals()}updated(t){super.updated(t),t.has("variant")&&"critical"===this.variant&&this.setAttribute("data-palette","danger")}_handlePopoverClick(t){t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("click")}_handleDialogCommandClick(){this.runDialogCommand(),this.dispatchSheriffEvent("click")}_handleSubmitClick(){this.dispatchSheriffEvent("submit")&&this.internals.form?.requestSubmit()}_handleResetClick(){this.dispatchSheriffEvent("reset")&&this.internals.form?.reset()}render(){const t={"sds-button":!0,"sds-button--as-link":!!this.href};return this.href?J` <a id="link" class="${se(t)}" href="${this.href}" target="${qt(this.target)}">
488
488
  <slot name="before"></slot>
489
489
  <slot></slot>
490
490
  <slot name="after"></slot>
@@ -492,7 +492,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
492
492
  <button
493
493
  id="control"
494
494
  form="${qt(this.form)}"
495
- class="${te(t)}"
495
+ class="${se(t)}"
496
496
  type="${this.type}"
497
497
  name="${qt(this.name)}"
498
498
  value="${qt(this.value)}"
@@ -500,11 +500,12 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
500
500
  @click="${this._handleClick}"
501
501
  aria-label="${qt(this.label)}"
502
502
  >
503
- ${this.loading?J`<sds-loader slot="before" ?contrast="${this.inverted||"primary"!==this.variant}"></sds-loader>`:st} ${this.loading?st:J`<slot name="before"></slot>`}
503
+ ${this.loading?J`<sds-loader slot="before" ?contrast="${this.inverted||"primary"!==this.variant}"></sds-loader>`:st}
504
+ ${this.loading?st:J`<slot name="before"></slot>`}
504
505
  <slot></slot>
505
506
  ${this.loading?st:J`<slot name="after"></slot>`}
506
507
  </button>
507
- `}};pe.styles=[ee],pe.formAssociated=!0,pe.shadowRootOptions={...mt.shadowRootOptions,delegatesFocus:!0};let ge=pe;he([S({type:Boolean,reflect:!0})],ge.prototype,"disabled"),he([S({type:Boolean,reflect:!0})],ge.prototype,"icon"),he([S({type:Boolean,reflect:!0})],ge.prototype,"inverted"),he([S({type:Boolean,reflect:!0})],ge.prototype,"loading"),he([S({type:String,reflect:!0})],ge.prototype,"form"),he([S({type:String,reflect:!0})],ge.prototype,"href"),he([S({type:String,reflect:!0})],ge.prototype,"name"),he([S({type:String,reflect:!0})],ge.prototype,"size"),he([S({type:String,reflect:!0})],ge.prototype,"target"),he([S({type:String,reflect:!0})],ge.prototype,"type"),he([S({type:String,reflect:!0})],ge.prototype,"value"),he([S({type:String,reflect:!0})],ge.prototype,"variant"),he([S({type:String,reflect:!0})],ge.prototype,"label"),he([A("#control")],ge.prototype,"control");var ve=Object.getOwnPropertyDescriptor;let ue=class extends ge{};ue=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?ve(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-button")],ue);var fe=Object.getOwnPropertyDescriptor;let be=class extends Tt{};function _e(t,e,s,o){const r=t?.assignedNodes({flatten:!0}).filter(t=>{if(t.nodeType===Node.TEXT_NODE){return(t.textContent?.trim()??"").length>0}if(t.nodeType===Node.ELEMENT_NODE){const s=t,o=s.tagName.toUpperCase();if(!e.includes(o))return!0;return Array.from(s.childNodes).some(t=>t.nodeType===Node.ELEMENT_NODE)}return!1});r?.length>0&&console.warn(o,...r)}be=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?fe(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-alert")],be);const me=d`
508
+ `}};ve.styles=[oe],ve.formAssociated=!0,ve.shadowRootOptions={...mt.shadowRootOptions,delegatesFocus:!0};let ue=ve;ge([S({type:Boolean,reflect:!0})],ue.prototype,"disabled"),ge([S({type:Boolean,reflect:!0})],ue.prototype,"icon"),ge([S({type:Boolean,reflect:!0})],ue.prototype,"inverted"),ge([S({type:Boolean,reflect:!0})],ue.prototype,"loading"),ge([S({type:String,reflect:!0})],ue.prototype,"form"),ge([S({type:String,reflect:!0})],ue.prototype,"href"),ge([S({type:String,reflect:!0})],ue.prototype,"name"),ge([S({type:String,reflect:!0})],ue.prototype,"size"),ge([S({type:String,reflect:!0})],ue.prototype,"target"),ge([S({type:String,reflect:!0})],ue.prototype,"type"),ge([S({type:String,reflect:!0})],ue.prototype,"value"),ge([S({type:String,reflect:!0})],ue.prototype,"variant"),ge([S({type:String,reflect:!0})],ue.prototype,"label"),ge([L("#control")],ue.prototype,"control");var fe=Object.getOwnPropertyDescriptor;let be=class extends ue{};be=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?fe(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-button")],be);var _e=Object.getOwnPropertyDescriptor;let me=class extends Tt{};function xe(t,e,s,o){const r=t?.assignedNodes({flatten:!0}).filter(t=>{if(t.nodeType===Node.TEXT_NODE){return(t.textContent?.trim()??"").length>0}if(t.nodeType===Node.ELEMENT_NODE){const s=t,o=s.tagName.toUpperCase();if(!e.includes(o))return!0;return Array.from(s.childNodes).some(t=>t.nodeType===Node.ELEMENT_NODE)}return!1});r?.length>0&&console.warn(o,...r)}me=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?_e(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-alert")],me);const ye=d`
508
509
  :host {
509
510
  --_sds-card-background-color: var(--sds-card-background-color, var(--sds-color-surface-tinted, var(--sds-color-main-surface-tinted)));
510
511
  --_sds-card-border-radius: var(--sds-card-border-radius, var(--sds-radius-md));
@@ -639,11 +640,11 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
639
640
  --_sds-card-text-line-height: var(--sds-card-text-line-height, var(--sds-typography-body-md-desktop-line-height));
640
641
  }
641
642
  }
642
- `;var xe=Object.defineProperty,ye=Object.getOwnPropertyDescriptor,we=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?ye(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&xe(e,s,a),a};let ke=class extends mt{constructor(){super(...arguments),this._textSlotEmpty=!1,this._contentWarning="[sds-card] text slot should only contain top-level <p> elements with no nested elements:",this._headerWarning="[sds-card] header slot should only contain one of <h2>–<h6> elements:",this._handleHeadingSlotChange=()=>{this.headingSlot.assignedNodes({flatten:!0}).length>0&&_e(this.headingSlot,["H2","H3","H4","H5","H6"],0,this._headerWarning)},this._handleTextSlotChange=()=>{_e(this.textSlot,["P"],0,this._contentWarning),this._textSlotEmpty=0===this.textSlot.assignedElements({flatten:!0}).length}}firstUpdated(){_e(this.textSlot,["P"],0,this._contentWarning),this._textSlotEmpty=0===this.textSlot.assignedElements({flatten:!0}).length;this.headingSlot.assignedNodes({flatten:!0}).length>0&&_e(this.headingSlot,["H2","H3","H4","H5","H6"],0,this._headerWarning)}render(){const t=J`
643
+ `;var we=Object.defineProperty,ke=Object.getOwnPropertyDescriptor,ze=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?ke(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&we(e,s,a),a};let $e=class extends mt{constructor(){super(...arguments),this._textSlotEmpty=!1,this._contentWarning="[sds-card] text slot should only contain top-level <p> elements with no nested elements:",this._headerWarning="[sds-card] header slot should only contain one of <h2>–<h6> elements:",this._handleHeadingSlotChange=()=>{this.headingSlot.assignedNodes({flatten:!0}).length>0&&xe(this.headingSlot,["H2","H3","H4","H5","H6"],0,this._headerWarning)},this._handleTextSlotChange=()=>{xe(this.textSlot,["P"],0,this._contentWarning),this._textSlotEmpty=0===this.textSlot.assignedElements({flatten:!0}).length}}firstUpdated(){xe(this.textSlot,["P"],0,this._contentWarning),this._textSlotEmpty=0===this.textSlot.assignedElements({flatten:!0}).length;this.headingSlot.assignedNodes({flatten:!0}).length>0&&xe(this.headingSlot,["H2","H3","H4","H5","H6"],0,this._headerWarning)}render(){const t=J`
643
644
  <slot name="heading" id="heading" @slotchange=${this._handleHeadingSlotChange}></slot>
644
645
  <slot name="text" id="content" @slotchange=${this._handleTextSlotChange}></slot>
645
646
  <sds-icon name="arrow_forward-material-outlined" size="md" class="sds-card__icon" role="presentation"></sds-icon>
646
- `,e={"sds-card__content":!0,"sds-card__content--no-text":this._textSlotEmpty};return J`<article class="sds-card">${this.link?J`<a href="${this.link}" class=${te(e)}>${t}</a>`:J`<div class=${te(e)}>${t}</div>`}</article>`}};ke.styles=[me],we([S({type:String,reflect:!0})],ke.prototype,"link",2),we([A("slot#heading")],ke.prototype,"headingSlot",2),we([A("slot#content")],ke.prototype,"textSlot",2),we([C()],ke.prototype,"_textSlotEmpty",2),ke=we([O("sds-card")],ke);const ze=d`
647
+ `,e={"sds-card__content":!0,"sds-card__content--no-text":this._textSlotEmpty};return J`<article class="sds-card">${this.link?J`<a href="${this.link}" class=${se(e)}>${t}</a>`:J`<div class=${se(e)}>${t}</div>`}</article>`}};$e.styles=[ye],ze([S({type:String,reflect:!0})],$e.prototype,"link",2),ze([L("slot#heading")],$e.prototype,"headingSlot",2),ze([L("slot#content")],$e.prototype,"textSlot",2),ze([C()],$e.prototype,"_textSlotEmpty",2),$e=ze([A("sds-card")],$e);const Se=d`
647
648
  :host {
648
649
  --_sds-checkbox-block-gap: var(--sds-checkbox-block-gap, var(--sds-spacing-4xs));
649
650
  --_sds-checkbox-inline-gap: var(--sds-checkbox-inline-gap, var(--sds-spacing-3xs));
@@ -868,8 +869,8 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
868
869
  margin-block-start: -1px;
869
870
  }
870
871
  }
871
- `;var $e=Object.defineProperty,Se=Object.getOwnPropertyDescriptor,Ce=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Se(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&$e(e,s,a),a};let Ee=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.checked=!1,this.error=!1,this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._disabled=!1,this._disabledIsAuthorControlled=!1,this._settingDisabledFromParent=!1,this._parentRequestDisabled=!1,this._initialChecked=!1,this._handleChange=t=>{if(t.stopImmediatePropagation(),this.disabled||this.readOnly)return t.target.checked=this.checked,void t.preventDefault();const e=t.target;this.checked=e.checked,this.internals.setFormValue(e.checked?e.value:null),this._validate(),this.dispatchSheriffEvent("change")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("blur")},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}get disabled(){return this._disabled}set disabled(t){const e=t??!1,s=this._disabled;s!==e&&(this._disabled=e,this.requestUpdate("disabled",s),this._settingDisabledFromParent||(this._disabledIsAuthorControlled=e))}get parentRequestDisabled(){return this._parentRequestDisabled}set parentRequestDisabled(t){const e=t??!1,s=this._parentRequestDisabled;s!==e&&(this._parentRequestDisabled=e,this.requestUpdate("parentRequestDisabled",s),this._disabledIsAuthorControlled||(this._settingDisabledFromParent=!0,this.disabled=e,this._settingDisabledFromParent=!1))}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked,this.internals.role="none",this.checked&&this.internals.setFormValue(this.value??"on")}firstUpdated(t){super.firstUpdated(t),this.control&&(this.control.required=this.required),this._validate()}formResetCallback(){this.checked=this._initialChecked,this.control&&(this.control.checked=this._initialChecked);const t=this.checked?this.value??"on":null;this.internals.setFormValue(t),this._validate()}_validate(){this.required&&!this.checked?this.internals.setValidity({valueMissing:!0},this.control.validationMessage,this.control):this.internals.setValidity({})}updated(t){super.updated(t),t.has("required")&&this.control&&(this.control.required=this.required),t.has("checked")&&this._validate(),this._disabledIsAuthorControlled||this.disabled===this._parentRequestDisabled||(this._settingDisabledFromParent=!0,this.disabled=this._parentRequestDisabled??!1,this._settingDisabledFromParent=!1)}get type(){return"checkbox"}render(){const t={"sds-checkbox":!0,"sds-checkbox--error":Boolean(this.error)},e=this._hasSlottedLabel||Boolean(this.label),s={"sds-checkbox__input":!0,"sds-checkbox__input--error":Boolean(this.error)},o=this.helpText?"help-text":void 0;return J`
872
- <div class="${te(t)}">
872
+ `;var Ce=Object.defineProperty,Ee=Object.getOwnPropertyDescriptor,Le=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ee(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Ce(e,s,a),a};let Oe=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.checked=!1,this.error=!1,this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._disabled=!1,this._disabledIsAuthorControlled=!1,this._settingDisabledFromParent=!1,this._parentRequestDisabled=!1,this._initialChecked=!1,this._handleChange=t=>{if(t.stopImmediatePropagation(),this.disabled||this.readOnly)return t.target.checked=this.checked,void t.preventDefault();const e=t.target;this.checked=e.checked,this.internals.setFormValue(e.checked?e.value:null),this._validate(),this.dispatchSheriffEvent("change")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("blur")},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}get disabled(){return this._disabled}set disabled(t){const e=t??!1,s=this._disabled;s!==e&&(this._disabled=e,this.requestUpdate("disabled",s),this._settingDisabledFromParent||(this._disabledIsAuthorControlled=e))}get parentRequestDisabled(){return this._parentRequestDisabled}set parentRequestDisabled(t){const e=t??!1,s=this._parentRequestDisabled;s!==e&&(this._parentRequestDisabled=e,this.requestUpdate("parentRequestDisabled",s),this._disabledIsAuthorControlled||(this._settingDisabledFromParent=!0,this.disabled=e,this._settingDisabledFromParent=!1))}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked,this.internals.role="none",this.checked&&this.internals.setFormValue(this.value??"on")}firstUpdated(t){super.firstUpdated(t),this.control&&(this.control.required=this.required),this._validate()}formResetCallback(){this.checked=this._initialChecked,this.control&&(this.control.checked=this._initialChecked);const t=this.checked?this.value??"on":null;this.internals.setFormValue(t),this._validate()}_validate(){this.required&&!this.checked?this.internals.setValidity({valueMissing:!0},this.control.validationMessage,this.control):this.internals.setValidity({})}updated(t){super.updated(t),t.has("required")&&this.control&&(this.control.required=this.required),t.has("checked")&&this._validate(),this._disabledIsAuthorControlled||this.disabled===this._parentRequestDisabled||(this._settingDisabledFromParent=!0,this.disabled=this._parentRequestDisabled??!1,this._settingDisabledFromParent=!1)}get type(){return"checkbox"}render(){const t={"sds-checkbox":!0,"sds-checkbox--error":Boolean(this.error)},e=this._hasSlottedLabel||Boolean(this.label),s={"sds-checkbox__input":!0,"sds-checkbox__input--error":Boolean(this.error)},o=this.helpText?"help-text":void 0;return J`
873
+ <div class="${se(t)}">
873
874
  <input
874
875
  id="control"
875
876
  type="checkbox"
@@ -885,14 +886,14 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
885
886
  @change="${this._handleChange}"
886
887
  @focus="${this._handleFocus}"
887
888
  @blur="${this._handleBlur}"
888
- class="${te(s)}"
889
+ class="${se(s)}"
889
890
  />
890
891
  <label for="control" class="sds-checkbox__label" ?hidden="${!e}">
891
892
  <slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
892
893
  </label>
893
894
  ${this.helpText?J`<span id="help-text" class="sds-checkbox__help-text">${this.helpText}</span>`:st}
894
895
  </div>
895
- `}};Ee.styles=[ze],Ce([S({type:String,reflect:!0})],Ee.prototype,"label",2),Ce([S({type:String})],Ee.prototype,"value",2),Ce([S({type:Boolean,reflect:!0})],Ee.prototype,"checked",2),Ce([S({type:Boolean,reflect:!0})],Ee.prototype,"error",2),Ce([S({type:Boolean,reflect:!0})],Ee.prototype,"required",2),Ce([S({type:String,reflect:!0})],Ee.prototype,"size",2),Ce([S({type:String,attribute:"help-text"})],Ee.prototype,"helpText",2),Ce([S({type:Boolean,reflect:!0})],Ee.prototype,"disabled",1),Ce([S({type:Boolean,attribute:!1})],Ee.prototype,"parentRequestDisabled",1),Ce([A("#control")],Ee.prototype,"control",2),Ce([C()],Ee.prototype,"_hasSlottedLabel",2),Ee=Ce([O("sds-checkbox")],Ee);const Ae=d`
896
+ `}};Oe.styles=[Se],Le([S({type:String,reflect:!0})],Oe.prototype,"label",2),Le([S({type:String})],Oe.prototype,"value",2),Le([S({type:Boolean,reflect:!0})],Oe.prototype,"checked",2),Le([S({type:Boolean,reflect:!0})],Oe.prototype,"error",2),Le([S({type:Boolean,reflect:!0})],Oe.prototype,"required",2),Le([S({type:String,reflect:!0})],Oe.prototype,"size",2),Le([S({type:String,attribute:"help-text"})],Oe.prototype,"helpText",2),Le([S({type:Boolean,reflect:!0})],Oe.prototype,"disabled",1),Le([S({type:Boolean,attribute:!1})],Oe.prototype,"parentRequestDisabled",1),Le([L("#control")],Oe.prototype,"control",2),Le([C()],Oe.prototype,"_hasSlottedLabel",2),Oe=Le([A("sds-checkbox")],Oe);const Ae=d`
896
897
  :host {
897
898
  --_sds-checkbox-group-gap: var(--sds-checkbox-group-gap, var(--sds-spacing-xs));
898
899
  --_sds-checkbox-group-font-family: var(--sds-checkbox-group-font-family, var(--sds-typography-font-family-roboto));
@@ -984,8 +985,8 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
984
985
  --_sds-checkbox-group-help-text-font-size: var(--sds-checkbox-group-help-text-font-size, var(--sds-components-font-size-content-lg));
985
986
  --_sds-checkbox-group-help-text-line-height: var(--sds-checkbox-group-help-text-line-height, var(--sds-components-line-height-squeezed-lg));
986
987
  }
987
- `;var Le=Object.defineProperty,Oe=Object.getOwnPropertyDescriptor,Pe=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Oe(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Le(e,s,a),a};const De=["disabled","errorMessage","readOnly","size"];let Te=class extends(At(mt)){constructor(){super(...arguments),this.readOnly=!1,this.disabled=!1,this.size="md",this._selectedValues=[],this._handleCheckboxChange=t=>{const e=t.target,s=e.value,o=e.checked;this._selectedValues=o?[...this._selectedValues,s]:this._selectedValues.filter(t=>t!==s),this.dispatchSheriffEvent("sds-update")},this._handleSlotChange=()=>{this._updateChildProps([...De])}}_getChildCheckboxes(){return this._slotElement?.assignedElements({flatten:!0}).filter(t=>"SDS-CHECKBOX"===t.tagName)??[]}_updateChildProps(t){const e=this._getChildCheckboxes();for(const s of e)for(const e of t)switch(e){case"readOnly":s.readOnly=this.readOnly;break;case"disabled":s.parentRequestDisabled=this.disabled;break;case"errorMessage":s.error=Boolean(this.errorMessage);break;case"size":s.size=this.size}}updated(t){super.updated(t);const e=Array.from(t.keys());(e.includes("errorMessage")||e.includes("error-message"))&&this._updateChildProps(["errorMessage"])}attributeChangedCallback(t,e,s){if(super.attributeChangedCallback(t,e,s),"readonly"===t)return void this._updateChildProps(["readOnly"]);const o=t;De.includes(o)&&this._updateChildProps([o])}get value(){return{selectedValues:this._selectedValues}}render(){const t={"sds-checkbox-group":!0,"sds-checkbox-group--disabled":this.disabled,"sds-checkbox-group--error":Boolean(this.errorMessage)},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0;return J`
988
- <fieldset class="${te(t)}" aria-describedby="${qt(e)}" aria-invalid="${this.errorMessage?"true":"false"}">
988
+ `;var De=Object.defineProperty,Pe=Object.getOwnPropertyDescriptor,Te=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Pe(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&De(e,s,a),a};const qe=["disabled","errorMessage","readOnly","size"];let Me=class extends(Lt(mt)){constructor(){super(...arguments),this.readOnly=!1,this.disabled=!1,this.size="md",this._selectedValues=[],this._handleCheckboxChange=t=>{const e=t.target,s=e.value,o=e.checked;this._selectedValues=o?[...this._selectedValues,s]:this._selectedValues.filter(t=>t!==s),this.dispatchSheriffEvent("sds-update")},this._handleSlotChange=()=>{this._updateChildProps([...qe])}}_getChildCheckboxes(){return this._slotElement?.assignedElements({flatten:!0}).filter(t=>"SDS-CHECKBOX"===t.tagName)??[]}_updateChildProps(t){const e=this._getChildCheckboxes();for(const s of e)for(const e of t)switch(e){case"readOnly":s.readOnly=this.readOnly;break;case"disabled":s.parentRequestDisabled=this.disabled;break;case"errorMessage":s.error=Boolean(this.errorMessage);break;case"size":s.size=this.size}}updated(t){super.updated(t);const e=Array.from(t.keys());(e.includes("errorMessage")||e.includes("error-message"))&&this._updateChildProps(["errorMessage"])}attributeChangedCallback(t,e,s){if(super.attributeChangedCallback(t,e,s),"readonly"===t)return void this._updateChildProps(["readOnly"]);const o=t;qe.includes(o)&&this._updateChildProps([o])}get value(){return{selectedValues:this._selectedValues}}render(){const t={"sds-checkbox-group":!0,"sds-checkbox-group--disabled":this.disabled,"sds-checkbox-group--error":Boolean(this.errorMessage)},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0;return J`
989
+ <fieldset class="${se(t)}" aria-describedby="${qt(e)}" aria-invalid="${this.errorMessage?"true":"false"}">
989
990
  ${this.legend?J`<legend class="sds-checkbox-group__legend">${this.readOnly?J`<sds-icon name="lock-material-filled" size="md"></sds-icon>`:st}</sds-icon>${this.legend}</legend>`:st}
990
991
  ${this.helpText?J`<p id="help-text" class="sds-checkbox-group__help-text">${this.helpText}</p>`:st}
991
992
  <div class="sds-checkbox-group__checkboxes" @change=${this._handleCheckboxChange}>
@@ -993,7 +994,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
993
994
  </div>
994
995
  ${this.errorMessage?J`<sds-alert id="error-message" variant="secondary" data-palette="danger"><p slot="message">${this.errorMessage}</p></sds-alert>`:st}
995
996
  </fieldset>
996
- `}};Te.styles=[Ae],Pe([S({type:String,reflect:!0})],Te.prototype,"legend",2),Pe([S({type:String,attribute:"help-text",reflect:!0})],Te.prototype,"helpText",2),Pe([S({type:String,attribute:"error-message",reflect:!0})],Te.prototype,"errorMessage",2),Pe([S({type:Boolean,attribute:"readonly",reflect:!0})],Te.prototype,"readOnly",2),Pe([S({type:Boolean,reflect:!0})],Te.prototype,"disabled",2),Pe([S({type:String,reflect:!0})],Te.prototype,"size",2),Pe([C()],Te.prototype,"_selectedValues",2),Pe([A("slot")],Te.prototype,"_slotElement",2),Te=Pe([O("sds-checkbox-group")],Te);const qe=d`
997
+ `}};Me.styles=[Ae],Te([S({type:String,reflect:!0})],Me.prototype,"legend",2),Te([S({type:String,attribute:"help-text",reflect:!0})],Me.prototype,"helpText",2),Te([S({type:String,attribute:"error-message",reflect:!0})],Me.prototype,"errorMessage",2),Te([S({type:Boolean,attribute:"readonly",reflect:!0})],Me.prototype,"readOnly",2),Te([S({type:Boolean,reflect:!0})],Me.prototype,"disabled",2),Te([S({type:String,reflect:!0})],Me.prototype,"size",2),Te([C()],Me.prototype,"_selectedValues",2),Te([L("slot")],Me.prototype,"_slotElement",2),Me=Te([A("sds-checkbox-group")],Me);const Ve=d`
997
998
  :host {
998
999
  --_sds-chip-font-family: var(--sds-chip-font-family, var(--sds-typography-font-family-roboto));
999
1000
  --_sds-chip-font-weight: var(--sds-chip-font-weight, var(--sds-typography-font-weight-regular));
@@ -1138,10 +1139,10 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1138
1139
  white-space: nowrap;
1139
1140
  }
1140
1141
  }
1141
- `;var Me=Object.defineProperty,Ve=Object.getOwnPropertyDescriptor,Be=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ve(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Me(e,s,a),a};let Re=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this._initialChecked=!1,this._readOnly=!1,this._slotLabel="",this.variant="selectable",this.size="md",this.checked=!1,this._handleSlotChange=t=>{const e=t.target;this._slotLabel=e.assignedNodes().map(t=>t.textContent).join("").trim()},this._handleChange=t=>{if(t.stopImmediatePropagation(),!(t.target instanceof HTMLInputElement))return;if(this.disabled||this.readOnly)return void(t.target.checked=this.checked??!1);const e=t.target;this.checked=e.checked,this.internals.setFormValue(this.checked?this.value??"on":null),this.dispatchSheriffEvent("change")},this._remove=()=>{this.disabled||this.readOnly||this.dispatchSheriffEvent("sds-remove")},this._keypress=t=>{" "!==t.key&&"Enter"!==t.key||this._remove()}}get readOnly(){return this._readOnly}set readOnly(t){const e=this._readOnly;this._readOnly=t??!1,this.requestUpdate("readOnly",e)}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked??!1,this.internals.role="none",this.checked&&this.internals.setFormValue(this.value??null)}formResetCallback(){this.checked=this._initialChecked,this.internals.setFormValue(this.value??null)}get type(){return"checkbox"}render(){const t="removable"===this.variant&&!this.readOnly&&!this.disabled,e={"sds-chip":!0,"sds-chip--small":"small"===this.size||"sm"===this.size,"sds-chip--large":"large"===this.size||"lg"===this.size,"sds-chip--removable":t};return t?J`<button class="${te(e)}" @click=${this._remove} @keyup="${this._keypress}">
1142
+ `;var Be=Object.defineProperty,Ie=Object.getOwnPropertyDescriptor,Re=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ie(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Be(e,s,a),a};let je=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this._initialChecked=!1,this._readOnly=!1,this._slotLabel="",this.variant="selectable",this.size="md",this.checked=!1,this._handleSlotChange=t=>{const e=t.target;this._slotLabel=e.assignedNodes().map(t=>t.textContent).join("").trim()},this._handleChange=t=>{if(t.stopImmediatePropagation(),!(t.target instanceof HTMLInputElement))return;if(this.disabled||this.readOnly)return void(t.target.checked=this.checked??!1);const e=t.target;this.checked=e.checked,this.internals.setFormValue(this.checked?this.value??"on":null),this.dispatchSheriffEvent("change")},this._remove=()=>{this.disabled||this.readOnly||this.dispatchSheriffEvent("sds-remove")},this._keypress=t=>{" "!==t.key&&"Enter"!==t.key||this._remove()}}get readOnly(){return this._readOnly}set readOnly(t){const e=this._readOnly;this._readOnly=t??!1,this.requestUpdate("readOnly",e)}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked??!1,this.internals.role="none",this.checked&&this.internals.setFormValue(this.value??null)}formResetCallback(){this.checked=this._initialChecked,this.internals.setFormValue(this.value??null)}get type(){return"checkbox"}render(){const t="removable"===this.variant&&!this.readOnly&&!this.disabled,e={"sds-chip":!0,"sds-chip--small":"small"===this.size||"sm"===this.size,"sds-chip--large":"large"===this.size||"lg"===this.size,"sds-chip--removable":t};return t?J`<button class="${se(e)}" @click=${this._remove} @keyup="${this._keypress}">
1142
1143
  <slot></slot>
1143
1144
  <sds-icon name="close-material-outlined" size="s"></sds-icon>
1144
- </button>`:J`<label class="${te(e)}">
1145
+ </button>`:J`<label class="${se(e)}">
1145
1146
  <input
1146
1147
  id="control"
1147
1148
  type="checkbox"
@@ -1155,7 +1156,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1155
1156
  @change="${this._handleChange}"
1156
1157
  />
1157
1158
  <span aria-hidden="true"><slot @slotchange="${this._handleSlotChange}"></slot></span>
1158
- </label>`}};Re.styles=[qe],Be([A("#control")],Re.prototype,"control",2),Be([C()],Re.prototype,"_slotLabel",2),Be([S({type:String,reflect:!0})],Re.prototype,"variant",2),Be([S({type:String,reflect:!0})],Re.prototype,"size",2),Be([S({type:Boolean,reflect:!0})],Re.prototype,"checked",2),Be([S({type:String})],Re.prototype,"value",2),Be([S({type:Boolean,attribute:"readonly",reflect:!0})],Re.prototype,"readOnly",1),Re=Be([O("sds-chip")],Re);const je=d`
1159
+ </label>`}};je.styles=[Ve],Re([L("#control")],je.prototype,"control",2),Re([C()],je.prototype,"_slotLabel",2),Re([S({type:String,reflect:!0})],je.prototype,"variant",2),Re([S({type:String,reflect:!0})],je.prototype,"size",2),Re([S({type:Boolean,reflect:!0})],je.prototype,"checked",2),Re([S({type:String})],je.prototype,"value",2),Re([S({type:Boolean,attribute:"readonly",reflect:!0})],je.prototype,"readOnly",1),je=Re([A("sds-chip")],je);const Fe=d`
1159
1160
  :host {
1160
1161
  --_sds-env-banner-background-color: var(--sds-env-banner-background-color, var(--sds-color-alert-info-surface-active));
1161
1162
  --_sds-env-banner-text-color: var(--sds-env-banner-text-color, var(--sds-color-alert-info-text-default));
@@ -1250,12 +1251,605 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1250
1251
  --_sds-env-banner-build-grid-column: var(--sds-env-banner-build-grid-column, 3 / 4);
1251
1252
  }
1252
1253
  }
1253
- `;var Ie=Object.defineProperty,Ne=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Ie(e,s,a),a};const He={opplaering:"Opplæring",local:"Local",dev:"Dev",test:"Test",stage:"Stage",prod:"Prod"},Fe=class extends bt{render(){const t=this.env?He[this.env]:st;return J`
1254
+ `;var Ne=Object.defineProperty,Ue=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Ne(e,s,a),a};const He={opplaering:"Opplæring",local:"Local",dev:"Dev",test:"Test",stage:"Stage",prod:"Prod"},Ke=class extends bt{render(){const t=this.env?He[this.env]:st;return J`
1254
1255
  <div class="sds-env-banner">
1255
1256
  ${t?J`<span class="sds-env-banner__env">${t}</span>`:st}
1256
1257
  ${this.build?J`<span class="sds-env-banner__build">${this.build}</span>`:st}
1257
1258
  </div>
1258
- `}};Fe.styles=[je];let Ue=Fe;Ne([S({type:String,reflect:!0})],Ue.prototype,"env"),Ne([S({type:String,reflect:!0})],Ue.prototype,"build");var Ge=Object.getOwnPropertyDescriptor;let Ke=class extends Ue{};Ke=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ge(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-environment-banner")],Ke);const We=d`
1259
+ `}};Ke.styles=[Fe];let Ge=Ke;Ue([S({type:String,reflect:!0})],Ge.prototype,"env"),Ue([S({type:String,reflect:!0})],Ge.prototype,"build");var We=Object.getOwnPropertyDescriptor;let Ze=class extends Ge{};function Ye(t){if(0===t)return"0 B";const e=["B","kB","MB","GB"],s=Math.min(Math.floor(Math.log(t)/Math.log(1024)),e.length-1);return`${(t/1024**s).toFixed(0===s?0:1).replace(".",",")} ${e[s]}`}function Qe(t,e){if(!e)return!0;const s=e.split(",").map(t=>t.trim().toLowerCase()).filter(Boolean);if(0===s.length)return!0;const o=t.name.toLowerCase(),r=t.type.toLowerCase();return s.some(t=>t.startsWith(".")?o.endsWith(t):t.endsWith("/*")?r.startsWith(t.slice(0,-1)):r===t)}function Xe(t,e){return t===e||t.name===e.name&&t.size===e.size&&t.lastModified===e.lastModified}Ze=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?We(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-environment-banner")],Ze);class Je{constructor(t,e,s=()=>!1){this.host=t,this.onFiles=e,this.isDisabled=s,this._dragging=!1,this.handleDragOver=t=>{this.isDisabled()||(t.preventDefault(),t.dataTransfer&&(t.dataTransfer.dropEffect="copy"),this._setDragging(!0))},this.handleDragLeave=()=>{this._setDragging(!1)},this.handleDrop=t=>{if(this._setDragging(!1),this.isDisabled())return;t.preventDefault();const e=Array.from(t.dataTransfer?.files??[]);e.length&&this.onFiles(e)},t.addController(this)}get dragging(){return this._dragging}hostDisconnected(){this._dragging=!1}_setDragging(t){this._dragging!==t&&(this._dragging=t,this.host.requestUpdate())}}let ts;function es(t){return new Promise((e,s)=>{const o=URL.createObjectURL(t),r=document.createElement("video");let a=!1;const i=()=>{clearTimeout(n),r.removeAttribute("src"),r.load(),URL.revokeObjectURL(o)},d=t=>{a||(a=!0,i(),s(t instanceof Error?t:new Error(String(t))))},n=setTimeout(()=>d(new Error("Video thumbnail generation timed out")),5e3);r.muted=!0,r.playsInline=!0,r.preload="auto",r.addEventListener("error",()=>d(new Error("Video could not be decoded"))),r.addEventListener("loadeddata",()=>{r.currentTime=Math.min(.1,(r.duration||0)/2)},{once:!0}),r.addEventListener("seeked",()=>{try{const t=r.videoWidth,s=r.videoHeight;if(!t||!s)throw new Error("Video has no dimensions");const o=document.createElement("canvas");o.width=t,o.height=s;const n=o.getContext("2d");if(!n)throw new Error("Canvas 2D context unavailable");n.drawImage(r,0,0,t,s);const l=function(){if(void 0===ts){const t=document.createElement("canvas");t.width=t.height=1,ts=t.toDataURL("image/webp").startsWith("data:image/webp")}return ts}()?"image/webp":"image/jpeg";o.toBlob(t=>{return t?(s=URL.createObjectURL(t),void(a?URL.revokeObjectURL(s):(a=!0,i(),e(s)))):d(new Error("Canvas toBlob returned null"));var s},l,.75)}catch(t){d(t)}},{once:!0}),r.src=o})}class ss{constructor(t,e){this.host=t,this.onReady=e,this._urls=/* @__PURE__ */new Map,this._pending=/* @__PURE__ */new Set,this._files=[],t.addController(this)}hostConnected(){this.sync(this._files)}hostDisconnected(){for(const t of this._urls.values())URL.revokeObjectURL(t);this._urls.clear(),this._pending.clear()}sync(t){this._files=t;for(const[e,s]of this._urls)t.includes(e)||(URL.revokeObjectURL(s),this._urls.delete(e));for(const e of t)if(!this._urls.has(e))if(e.type.startsWith("image/")){const t=URL.createObjectURL(e);this._urls.set(e,t),queueMicrotask(()=>{this.host.isConnected&&this._urls.get(e)===t&&this.onReady(e,t)})}else e.type.startsWith("video/")&&!this._pending.has(e)&&this._generateVideoPreview(e)}get(t){const e=this._urls.get(t);if(e)return e;const s=this._files.find(e=>Xe(e,t));return s?this._urls.get(s):void 0}_generateVideoPreview(t){this._pending.add(t),es(t).then(e=>{this.host.isConnected&&this._files.includes(t)?(this._urls.set(t,e),this.host.requestUpdate(),this.onReady(t,e)):URL.revokeObjectURL(e)}).catch(()=>{}).finally(()=>this._pending.delete(t))}}const os=d`
1260
+ :host {
1261
+ --_sds-file-upload-gap: var(--sds-file-upload-gap, var(--sds-spacing-4xs));
1262
+ --_sds-file-upload-font-family: var(--sds-file-upload-font-family, var(--sds-typography-font-family));
1263
+ --_sds-file-upload-margin-block-end: var(--sds-file-upload-margin-block-end, var(--sds-spacing-3xs));
1264
+
1265
+ --_sds-file-upload-label-font-size: var(--sds-file-upload-label-font-size, var(--sds-components-font-size-content-md));
1266
+ --_sds-file-upload-label-font-weight: var(--sds-file-upload-label-font-weight, var(--sds-typography-font-weight-medium));
1267
+ --_sds-file-upload-label-line-height: var(--sds-file-upload-label-line-height, var(--sds-components-line-height-squeezed-md));
1268
+ --_sds-file-upload-label-text-color: var(--sds-file-upload-label-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
1269
+
1270
+ --_sds-file-upload-helptext-text-color: var(--sds-file-upload-helptext-text-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
1271
+ --_sds-file-upload-helptext-font-size: var(--sds-file-upload-helptext-font-size, var(--sds-components-font-size-content-md));
1272
+ --_sds-file-upload-helptext-font-weight: var(--sds-file-upload-helptext-font-weight, var(--sds-typography-font-weight-regular));
1273
+ --_sds-file-upload-helptext-line-height: var(--sds-file-upload-helptext-line-height, var(--sds-components-line-height-squeezed-md));
1274
+
1275
+ --_sds-file-upload-file-limitation-text-font-size: var(--sds-file-upload-file-limitation-text-font-size, var(--sds-typography-detail-xs-desktop-font-size));
1276
+ --_sds-file-upload-file-limitation-text-font-weight: var(--sds-file-upload-file-limitation-text-font-weight, var(--sds-typography-detail-xs-desktop-font-weight));
1277
+ --_sds-file-upload-file-limitation-text-line-height: var(--sds-file-upload-file-limitation-text-line-height, var(--sds-typography-detail-xs-desktop-line-height));
1278
+ --_sds-file-upload-file-limitation-text-color: var(--sds-file-upload-file-limitation-text-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
1279
+
1280
+ --_sds-file-upload-dropzone-background: var(--sds-file-upload-dropzone-background, var(--sds-color-surface-default, var(--sds-color-neutral-surface-default)));
1281
+ --_sds-file-upload-dropzone-border-color: var(--sds-file-upload-dropzone-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
1282
+ --_sds-file-upload-dropzone-border-width: var(--sds-file-upload-dropzone-border-width, var(--sds-border-sm));
1283
+ --_sds-file-upload-dropzone-border-radius: var(--sds-file-upload-dropzone-border-radius, var(--sds-radius-md));
1284
+ --_sds-file-upload-dropzone-padding: var(--sds-file-upload-dropzone-padding, var(--sds-spacing-sm));
1285
+ --_sds-file-upload-dropzone-margin-block-start: var(--sds-file-upload-dropzone-margin-block-start, var(--sds-spacing-3xs));
1286
+ --_sds-file-upload-dropzone-gap: var(--sds-file-upload-dropzone-gap, var(--sds-spacing-xs));
1287
+ --_sds-file-upload-dropzone-dragging-filter: var(--sds-file-upload-dropzone-dragging-filter, blur(8px));
1288
+ --_sds-file-upload-dropzone-drop-hint-display: var(--sds-file-upload-dropzone-drop-hint-display, none);
1289
+
1290
+ --_sds-file-upload-drop-text-font-size: var(--sds-file-upload-drop-text-font-size, var(--sds-components-font-size-content-md));
1291
+ --_sds-file-upload-drop-text-line-height: var(--sds-file-upload-drop-text-line-height, var(--sds-components-line-height-squeezed-md));
1292
+ --_sds-file-upload-drop-text-font-weight: var(--sds-file-upload-drop-text-font-weight, var(--sds-typography-body-md-desktop-font-weight));
1293
+ --_sds-file-upload-drop-text-color: var(--sds-file-upload-drop-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
1294
+
1295
+ --_sds-file-upload-error-border-color: var(--sds-file-upload-error-border-color, var(--sds-color-alert-danger-border-default));
1296
+
1297
+ --_sds-file-upload-focus-color-outer: var(--sds-file-upload-focus-color-outer, var(--sds-color-states-focus-outer));
1298
+ --_sds-file-upload-focus-color-inner: var(--sds-file-upload-focus-color-inner, var(--sds-color-states-focus-inner));
1299
+ --_sds-file-upload-focus-spacing: var(--sds-file-upload-focus-spacing, var(--sds-color-states-focus-spacing));
1300
+ --_sds-file-upload-focus-outline-size: var(--sds-file-upload-focus-outline-size, var(--sds-color-states-focus-outline-size));
1301
+
1302
+ --_sds-file-upload-disabled-opacity: var(--sds-file-upload-disabled-opacity, var(--sds-color-states-disabled-opacity));
1303
+
1304
+ --sds-icon-color: var(--sds-file-upload-icon-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
1305
+
1306
+ all: unset;
1307
+ display: block;
1308
+ }
1309
+
1310
+ :host([size='sm']) {
1311
+ --_sds-file-upload-label-font-size: var(--sds-file-upload-label-font-size, var(--sds-components-font-size-content-sm));
1312
+ --_sds-file-upload-label-line-height: var(--sds-file-upload-label-line-height, var(--sds-components-line-height-squeezed-sm));
1313
+ --_sds-file-upload-helptext-font-size: var(--sds-file-upload-helptext-font-size, var(--sds-components-font-size-content-sm));
1314
+ --_sds-file-upload-helptext-line-height: var(--sds-file-upload-helptext-line-height, var(--sds-components-line-height-squeezed-sm));
1315
+ --_sds-file-upload-drop-text-font-size: var(--sds-file-upload-drop-text-font-size, var(--sds-components-font-size-content-sm));
1316
+ --_sds-file-upload-drop-text-line-height: var(--sds-file-upload-drop-text-line-height, var(--sds-components-line-height-squeezed-sm));
1317
+ }
1318
+
1319
+ :host([size='lg']) {
1320
+ --_sds-file-upload-label-font-size: var(--sds-file-upload-label-font-size, var(--sds-components-font-size-content-lg));
1321
+ --_sds-file-upload-label-line-height: var(--sds-file-upload-label-line-height, var(--sds-components-line-height-squeezed-lg));
1322
+ --_sds-file-upload-helptext-font-size: var(--sds-file-upload-helptext-font-size, var(--sds-components-font-size-content-lg));
1323
+ --_sds-file-upload-helptext-line-height: var(--sds-file-upload-helptext-line-height, var(--sds-components-line-height-squeezed-lg));
1324
+ --_sds-file-upload-drop-text-font-size: var(--sds-file-upload-drop-text-font-size, var(--sds-components-font-size-content-lg));
1325
+ --_sds-file-upload-drop-text-line-height: var(--sds-file-upload-drop-text-line-height, var(--sds-components-line-height-squeezed-lg));
1326
+ }
1327
+
1328
+ :host([hidden]) {
1329
+ display: none;
1330
+ }
1331
+
1332
+ :host([disabled]) {
1333
+ opacity: var(--_sds-file-upload-disabled-opacity);
1334
+ pointer-events: none;
1335
+ }
1336
+
1337
+ .sds-file-upload {
1338
+ display: flex;
1339
+ flex-direction: column;
1340
+ gap: var(--_sds-file-upload-gap);
1341
+ font-family: var(--_sds-file-upload-font-family);
1342
+ margin-block-end: var(--_sds-file-upload-margin-block-end);
1343
+ }
1344
+
1345
+ .sds-file-upload__label {
1346
+ font-size: var(--_sds-file-upload-label-font-size);
1347
+ font-weight: var(--_sds-file-upload-label-font-weight);
1348
+ line-height: var(--_sds-file-upload-label-line-height);
1349
+ color: var(--_sds-file-upload-label-text-color);
1350
+
1351
+ &[hidden] {
1352
+ display: none;
1353
+ }
1354
+ }
1355
+
1356
+ .sds-file-upload__help-text {
1357
+ display: block;
1358
+ color: var(--_sds-file-upload-helptext-text-color);
1359
+ font-size: var(--_sds-file-upload-helptext-font-size);
1360
+ font-weight: var(--_sds-file-upload-helptext-font-weight);
1361
+ line-height: var(--_sds-file-upload-helptext-line-height);
1362
+ margin: 0;
1363
+ }
1364
+
1365
+ .sds-file-upload__file-limitation-text {
1366
+ margin: 0;
1367
+ font-size: var(--_sds-file-upload-file-limitation-text-font-size);
1368
+ font-weight: var(--_sds-file-upload-file-limitation-text-font-weight);
1369
+ line-height: var(--_sds-file-upload-file-limitation-text-line-height);
1370
+ color: var(--_sds-file-upload-file-limitation-text-color);
1371
+ }
1372
+
1373
+ .sds-file-upload__input {
1374
+ position: absolute;
1375
+ inset: 0;
1376
+ width: 100%;
1377
+ height: 100%;
1378
+ margin: 0;
1379
+ opacity: 0;
1380
+ cursor: pointer;
1381
+ }
1382
+
1383
+ .sds-file-upload__dropzone:has(.sds-file-upload__input:focus-visible) {
1384
+ box-shadow: 0 0 0 var(--_sds-file-upload-focus-spacing) var(--_sds-file-upload-focus-color-inner);
1385
+ outline: var(--_sds-file-upload-focus-outline-size) solid var(--_sds-file-upload-focus-color-outer);
1386
+ outline-offset: var(--_sds-file-upload-focus-spacing);
1387
+ }
1388
+
1389
+ .sds-file-upload__dropzone {
1390
+ display: flex;
1391
+ flex-direction: column;
1392
+ align-items: center;
1393
+ justify-content: center;
1394
+ gap: var(--_sds-file-upload-dropzone-gap);
1395
+ padding: var(--_sds-file-upload-dropzone-padding);
1396
+ margin-block-start: var(--_sds-file-upload-dropzone-margin-block-start);
1397
+ text-align: center;
1398
+ cursor: pointer;
1399
+ background: var(--_sds-file-upload-dropzone-background);
1400
+ border: var(--_sds-file-upload-dropzone-border-width) dashed var(--_sds-file-upload-dropzone-border-color);
1401
+ border-radius: var(--_sds-file-upload-dropzone-border-radius);
1402
+ box-sizing: border-box;
1403
+ position: relative;
1404
+ transition:
1405
+ background-color 0.1s ease-in-out,
1406
+ border-color 0.1s ease-in-out;
1407
+
1408
+ &:hover {
1409
+ --_sds-file-upload-dropzone-background: var(--sds-file-upload-dropzone-background, var(--sds-color-surface-hover, var(--sds-color-main-surface-hover)));
1410
+ --_sds-file-upload-dropzone-border-color: var(--sds-file-upload-dropzone-border-color, var(--sds-color-border-strong, var(--sds-color-main-border-strong)));
1411
+ }
1412
+
1413
+ &:hover .sds-file-upload__trigger {
1414
+ --sds-button-background-color: transparent;
1415
+ --sds-button-border-color: var(--sds-color-action-default, var(--sds-color-main-action-default));
1416
+ --sds-button-text-color: var(--sds-color-action-default, var(--sds-color-main-action-default));
1417
+ }
1418
+
1419
+ &:active .sds-file-upload__trigger {
1420
+ --sds-button-background-color: var(--sds-color-surface-active, var(--sds-color-main-surface-active));
1421
+ --sds-button-border-color: var(--sds-color-action-active, var(--sds-color-main-action-active));
1422
+ }
1423
+
1424
+ .sds-file-upload__drop-hint {
1425
+ backdrop-filter: var(--_sds-file-upload-dropzone-dragging-filter);
1426
+ display: var(--_sds-file-upload-dropzone-drop-hint-display);
1427
+ flex-direction: column;
1428
+ align-items: center;
1429
+ justify-content: center;
1430
+ gap: var(--_sds-file-upload-dropzone-gap);
1431
+ position: absolute;
1432
+ inset: var(--_sds-file-upload-dropzone-border-width);
1433
+ border-radius: var(--_sds-file-upload-dropzone-border-radius);
1434
+ pointer-events: none;
1435
+
1436
+ .sds-file-upload__drop-hint-text {
1437
+ font-size: var(--_sds-file-upload-drop-text-font-size);
1438
+ font-weight: var(--_sds-file-upload-drop-text-font-weight);
1439
+ line-height: var(--_sds-file-upload-drop-text-line-height);
1440
+ }
1441
+ }
1442
+ }
1443
+
1444
+ .sds-file-upload__dropzone--dragging {
1445
+ --_sds-file-upload-dropzone-background: var(--sds-file-upload-dropzone-background, var(--sds-color-surface-hover, var(--sds-color-main-surface-hover)));
1446
+ --_sds-file-upload-dropzone-border-color: var(--sds-file-upload-dropzone-border-color, var(--sds-color-border-strong, var(--sds-color-main-border-strong)));
1447
+
1448
+ .sds-file-upload__trigger {
1449
+ --sds-button-background-color: transparent;
1450
+ --sds-button-border-color: var(--sds-color-action-default, var(--sds-color-main-action-default));
1451
+ --sds-button-text-color: var(--sds-color-action-default, var(--sds-color-main-action-default));
1452
+ }
1453
+
1454
+ .sds-file-upload__drop-hint {
1455
+ --_sds-file-upload-dropzone-drop-hint-display: var(--sds-file-upload-dropzone-drop-hint-display, flex);
1456
+ }
1457
+ }
1458
+
1459
+ .sds-file-upload__dropzone--error {
1460
+ border-color: var(--_sds-file-upload-error-border-color);
1461
+ }
1462
+
1463
+ :host([variant='compact']) .sds-file-upload__dropzone {
1464
+ --_sds-file-upload-dropzone-gap: var(--sds-file-upload-dropzone-gap, var(--sds-spacing-3xs));
1465
+ flex-direction: row;
1466
+ flex-wrap: wrap;
1467
+
1468
+ .sds-file-upload__drop-hint {
1469
+ flex-direction: row;
1470
+ }
1471
+ }
1472
+
1473
+ .sds-file-upload__trigger {
1474
+ --sds-button-background-color: transparent;
1475
+ --sds-button-border-color: var(--sds-color-action-default, var(--sds-color-neutral-action-default));
1476
+ --sds-button-text-color: var(--sds-color-action-default, var(--sds-color-neutral-action-default));
1477
+ }
1478
+
1479
+ .sds-file-upload__drop-text {
1480
+ margin: 0;
1481
+ font-size: var(--_sds-file-upload-drop-text-font-size);
1482
+ font-weight: var(--_sds-file-upload-drop-text-font-weight);
1483
+ line-height: var(--_sds-file-upload-drop-text-line-height);
1484
+ color: var(--_sds-file-upload-drop-text-color);
1485
+ }
1486
+
1487
+ .sds-file-upload__error-message {
1488
+ margin-block-end: var(--_sds-file-upload-margin-block-end);
1489
+ }
1490
+ `,rs=d`
1491
+ :host {
1492
+ --_sds-file-upload-item-background: var(--sds-file-upload-item-background, var(--sds-color-surface-default, var(--sds-color-neutral-surface-default)));
1493
+ --_sds-file-upload-item-border-color: var(--sds-file-upload-item-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
1494
+ --_sds-file-upload-item-border-width: var(--sds-file-upload-item-border-width, var(--sds-border-sm));
1495
+ --_sds-file-upload-item-border-radius: var(--sds-file-upload-item-border-radius, var(--sds-radius-md));
1496
+ --_sds-file-upload-item-padding: var(--sds-file-upload-item-padding, var(--sds-spacing-3xs) var(--sds-spacing-xs));
1497
+ --_sds-file-upload-item-gap: var(--sds-file-upload-item-gap, var(--sds-spacing-2xs));
1498
+ --_sds-file-upload-item-actions-gap: var(--sds-file-upload-item-actions-gap, var(--sds-spacing-5xs));
1499
+
1500
+ --_sds-file-upload-item-content-gap: var(--sds-file-upload-item-content-gap, var(--sds-spacing-3xs));
1501
+ --_sds-file-upload-item-content-data-gap: var(--sds-file-upload-item-content-data-gap, var(--sds-spacing-5xs));
1502
+ --_sds-file-upload-item-content-icon-color: var(--sds-file-upload-item-content-icon-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
1503
+ --_sds-file-upload-item-content-preview-size: var(--sds-file-upload-item-content-preview-size, var(--sds-spacing-lg));
1504
+ --_sds-file-upload-item-content-preview-radius: var(--sds-file-upload-item-content-preview-radius, var(--sds-radius-xs));
1505
+ --_sds-file-upload-item-content-preview-background: var(--sds-file-upload-item-content-preview-background, var(--sds-color-surface-tinted, var(--sds-color-neutral-surface-tinted)));
1506
+ --_sds-file-upload-item-content-preview-highlight: var(--sds-file-upload-item-content-preview-highlight, var(--sds-color-surface-default, var(--sds-color-neutral-surface-default)));
1507
+ --_sds-file-upload-item-content-preview-loading-duration: var(--sds-file-upload-item-content-preview-loading-duration, 5500ms);
1508
+ --_sds-file-upload-item-content-file-name-font-size: var(--sds-file-upload-item-content-file-name-font-size, var(--sds-typography-body-md-desktop-font-size));
1509
+ --_sds-file-upload-item-content-file-name-font-weight: var(--sds-file-upload-item-content-file-name-font-weight, var(--sds-typography-body-md-desktop-font-weight));
1510
+ --_sds-file-upload-item-content-file-name-line-height: var(--sds-file-upload-item-content-file-name-line-height, var(--sds-typography-body-md-desktop-line-height));
1511
+ --_sds-file-upload-item-content-file-name-text-color: var(--sds-file-upload-item-content-file-name-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
1512
+ --_sds-file-upload-item-content-file-detail-font-size: var(--sds-file-upload-item-content-file-detail-font-size, var(--sds-typography-detail-xs-desktop-font-size));
1513
+ --_sds-file-upload-item-content-file-detail-font-weight: var(--sds-file-upload-item-content-file-detail-font-weight, var(--sds-typography-detail-xs-desktop-font-weight));
1514
+ --_sds-file-upload-item-content-file-detail-line-height: var(--sds-file-upload-item-content-file-detail-line-height, var(--sds-typography-detail-xs-desktop-line-height));
1515
+ --_sds-file-upload-item-content-file-detail-color: var(--sds-file-upload-item-content-file-detail-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
1516
+
1517
+ --_sds-file-upload-item-progress-track-color: var(--sds-file-upload-item-progress-track-color, var(--sds-color-surface-tinted, var(--sds-color-neutral-surface-tinted)));
1518
+ --_sds-file-upload-item-progress-value-color: var(--sds-file-upload-item-progress-value-color, var(--sds-color-action-default, var(--sds-color-main-action-default)));
1519
+ --_sds-file-upload-item-progress-height: var(--sds-file-upload-item-progress-height, 0.375rem);
1520
+ --_sds-file-upload-item-progress-radius: var(--sds-file-upload-item-progress-radius, var(--sds-radius-full));
1521
+ --_sds-file-upload-item-progress-gap: var(--sds-file-upload-item-progress-gap, var(--sds-spacing-4xs));
1522
+ --_sds-file-upload-item-progress-spacing: var(--sds-file-upload-item-progress-spacing, var(--sds-spacing-2xs));
1523
+
1524
+ --_sds-file-upload-item-error-alert-spacing: var(--sds-file-upload-item-error-alert-spacing, var(--sds-spacing-3xs));
1525
+
1526
+ --_sds-file-upload-item-disabled-opacity: var(--sds-file-upload-item-disabled-opacity, var(--sds-color-states-disabled-opacity));
1527
+
1528
+ display: block;
1529
+ }
1530
+
1531
+ :host([hidden]) {
1532
+ display: none;
1533
+ }
1534
+
1535
+ :host([disabled]) {
1536
+ opacity: var(--_sds-file-upload-item-disabled-opacity);
1537
+ }
1538
+
1539
+ :host([error-message]) {
1540
+ --_sds-file-upload-item-border-color: var(--sds-file-upload-item-border-color, var(--sds-color-alert-danger-border-default));
1541
+ --_sds-file-upload-item-content-icon-color: var(--sds-file-upload-item-content-icon-color, var(--sds-color-alert-danger-text-default));
1542
+ --_sds-file-upload-item-content-file-detail-color: var(--sds-file-upload-item-content-file-detail-color, var(--sds-color-alert-danger-text-default));
1543
+ }
1544
+
1545
+ .sds-file-upload-item {
1546
+ display: flex;
1547
+ flex-direction: column;
1548
+ gap: var(--_sds-file-upload-item-progress-spacing);
1549
+ padding: var(--_sds-file-upload-item-padding);
1550
+ border: var(--_sds-file-upload-item-border-width) solid var(--_sds-file-upload-item-border-color);
1551
+ border-radius: var(--_sds-file-upload-item-border-radius);
1552
+ background: var(--_sds-file-upload-item-background);
1553
+ }
1554
+
1555
+ .sds-file-upload-item__row {
1556
+ display: flex;
1557
+ align-items: center;
1558
+ gap: var(--_sds-file-upload-item-gap);
1559
+ }
1560
+
1561
+ .sds-file-upload-item__content {
1562
+ display: flex;
1563
+ flex-grow: 1;
1564
+ min-width: 0;
1565
+ align-items: center;
1566
+ gap: var(--_sds-file-upload-item-content-gap);
1567
+ }
1568
+
1569
+ .sds-file-upload-item__actions {
1570
+ display: flex;
1571
+ flex: 0 0 auto;
1572
+ align-items: center;
1573
+ gap: var(--_sds-file-upload-item-actions-gap);
1574
+ }
1575
+
1576
+ .sds-file-upload-item__content-icon {
1577
+ color: var(--_sds-file-upload-item-content-icon-color);
1578
+ }
1579
+
1580
+ .sds-file-upload-item__content-preview {
1581
+ position: relative;
1582
+ flex: 0 0 auto;
1583
+ width: var(--_sds-file-upload-item-content-preview-size);
1584
+ height: var(--_sds-file-upload-item-content-preview-size);
1585
+ border-radius: var(--_sds-file-upload-item-content-preview-radius);
1586
+ overflow: hidden;
1587
+ background-color: var(--_sds-file-upload-item-content-preview-background);
1588
+
1589
+ &::before {
1590
+ content: '';
1591
+ position: absolute;
1592
+ inset: 0;
1593
+ background-color: var(--_sds-file-upload-item-content-preview-highlight);
1594
+ opacity: 0;
1595
+ will-change: opacity;
1596
+ animation: sds-file-upload-item-preview-breathe var(--_sds-file-upload-item-content-preview-loading-duration) ease-in-out infinite;
1597
+ }
1598
+ }
1599
+
1600
+ .sds-file-upload-item__content-preview-image {
1601
+ position: relative;
1602
+ display: block;
1603
+ width: 100%;
1604
+ height: 100%;
1605
+ object-fit: cover;
1606
+ }
1607
+
1608
+ .sds-file-upload-item__content-preview[data-loaded] {
1609
+ background-color: transparent;
1610
+
1611
+ &::before {
1612
+ content: none;
1613
+ }
1614
+ }
1615
+
1616
+ @keyframes sds-file-upload-item-preview-breathe {
1617
+ 0% { opacity: 0.15; }
1618
+ 40% { opacity: 1; }
1619
+ 55% { opacity: 1; }
1620
+ 100%{ opacity: 0.15; }
1621
+ }
1622
+
1623
+ @media (prefers-reduced-motion: reduce) {
1624
+ .sds-file-upload-item__content-preview::before {
1625
+ animation: none;
1626
+ opacity: 0;
1627
+ }
1628
+ }
1629
+
1630
+ .sds-file-upload-item__content-data {
1631
+ display: flex;
1632
+ flex-direction: column;
1633
+ min-width: 0;
1634
+ gap: var(--_sds-file-upload-item-content-data-gap);
1635
+ }
1636
+
1637
+ .sds-file-upload-item__content-file-name {
1638
+ overflow: hidden;
1639
+ text-overflow: ellipsis;
1640
+ white-space: nowrap;
1641
+ font-size: var(--_sds-file-upload-item-content-file-name-font-size);
1642
+ font-weight: var(--_sds-file-upload-item-content-file-name-font-weight);
1643
+ line-height: var(--_sds-file-upload-item-content-file-name-line-height);
1644
+ color: var(--_sds-file-upload-item-content-file-name-text-color);
1645
+ }
1646
+
1647
+ .sds-file-upload-item__content-file-detail {
1648
+ font-size: var(--_sds-file-upload-item-content-file-detail-font-size);
1649
+ font-weight: var(--_sds-file-upload-item-content-file-detail-font-weight);
1650
+ line-height: var(--_sds-file-upload-item-content-file-detail-line-height);
1651
+ color: var(--_sds-file-upload-item-content-file-detail-color);
1652
+ }
1653
+
1654
+ .sds-file-upload-item__content-file-error {
1655
+ font-size: var(--_sds-file-upload-item-content-file-detail-font-size);
1656
+ font-weight: var(--_sds-file-upload-item-content-file-detail-font-weight);
1657
+ line-height: var(--_sds-file-upload-item-content-file-detail-line-height);
1658
+ color: var(--_sds-file-upload-item-content-file-detail-color);
1659
+ }
1660
+
1661
+ .sds-file-upload-item__error-alert {
1662
+ display: block;
1663
+ margin-block-start: var(--_sds-file-upload-item-error-alert-spacing);
1664
+ }
1665
+
1666
+ .sds-file-upload-item__progress {
1667
+ display: flex;
1668
+ flex-direction: column;
1669
+ gap: var(--_sds-file-upload-item-progress-gap);
1670
+ }
1671
+
1672
+ /* The track is the <u-progress> host; the fill is its ::before (width + 0.2s transition come from u-progress). */
1673
+ .sds-file-upload-item__progress-track {
1674
+ display: block;
1675
+ inline-size: 100%;
1676
+ block-size: var(--_sds-file-upload-item-progress-height);
1677
+ border: none;
1678
+ border-radius: var(--_sds-file-upload-item-progress-radius);
1679
+ background-color: var(--_sds-file-upload-item-progress-track-color);
1680
+ overflow: hidden;
1681
+ }
1682
+
1683
+ .sds-file-upload-item__progress-track::before {
1684
+ border-radius: inherit;
1685
+ background-color: var(--_sds-file-upload-item-progress-value-color);
1686
+ }
1687
+
1688
+ .sds-file-upload-item__progress-meta {
1689
+ display: flex;
1690
+ gap: var(--_sds-file-upload-item-content-data-gap);
1691
+ font-size: var(--_sds-file-upload-item-content-file-detail-font-size);
1692
+ font-weight: var(--_sds-file-upload-item-content-file-detail-font-weight);
1693
+ line-height: var(--_sds-file-upload-item-content-file-detail-line-height);
1694
+ color: var(--_sds-file-upload-item-content-file-detail-color);
1695
+ }
1696
+
1697
+ .sds-file-upload-item__progress-percent {
1698
+ margin-inline-start: auto;
1699
+ }
1700
+
1701
+ sds-button {
1702
+ --sds-button-text-color: var(--sds-color-action-default, var(--sds-color-neutral-action-default));
1703
+
1704
+ &:hover {
1705
+ --sds-button-text-color: var(--sds-color-action-hover, var(--sds-color-neutral-action-hover));
1706
+ --sds-button-background-color: var(--sds-color-surface-hover, var(--sds-color-neutral-surface-hover));
1707
+ }
1708
+
1709
+ &:active {
1710
+ --sds-button-text-color: var(--sds-color-action-active, var(--sds-color-neutral-action-active));
1711
+ --sds-button-background-color: var(--sds-color-surface-active, var(--sds-color-neutral-surface-active));
1712
+ }
1713
+ }
1714
+ `;var as=Object.defineProperty,is=Object.getOwnPropertyDescriptor,ds=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?is(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&as(e,s,a),a};let ns=class extends(Lt(mt)){constructor(){super(),this.disabled=!1,this._previewLoaded=!1,this._handleRemove=t=>{if(t.stopPropagation(),this.disabled)return;this.dispatchSheriffEvent("sds-remove")&&this._removeFromAssociatedUpload()},this._renderThumbnail=()=>this.preview&&!this._hasError?J`<span class="sds-file-upload-item__content-preview" ?data-loaded="${this._previewLoaded}">
1715
+ <img class="sds-file-upload-item__content-preview-image" src="${this.preview}" alt="" />
1716
+ </span>`:J`<sds-icon
1717
+ class="sds-file-upload-item__content-icon"
1718
+ name="${this._hasError?"scan_delete-material-outlined":"draft-material-outlined"}"
1719
+ size="md"
1720
+ ></sds-icon>`,this._renderFileData=()=>{const t=void 0!==this.sizeInBytes?Ye(this.sizeInBytes):void 0;return J`
1721
+ <span class="sds-file-upload-item__content-data">
1722
+ <span class="sds-file-upload-item__content-file-name">${this.file}</span>
1723
+ ${this._hasError?J`<span class="sds-file-upload-item__content-file-error">Feil ved opplasting</span>`:t?J`<span class="sds-file-upload-item__content-file-detail">${t}</span>`:st}
1724
+ </span>
1725
+ `},this._renderRemoveButton=()=>J`
1726
+ <sds-button
1727
+ class="sds-file-upload-item__remove"
1728
+ icon
1729
+ variant="tertiary"
1730
+ size="sm"
1731
+ type="button"
1732
+ label="${this.file?`Fjern ${this.file}`:"Fjern fil"}"
1733
+ ?disabled="${this.disabled}"
1734
+ @click="${this._handleRemove}"
1735
+ >
1736
+ <sds-icon name="delete-material-outlined" size="md"></sds-icon>
1737
+ </sds-button>
1738
+ `,this._renderProgress=()=>{const t=Math.max(0,Math.min(100,Math.round(this.uploadedPercent??0)));return J`
1739
+ <div class="sds-file-upload-item__progress">
1740
+ <u-progress class="sds-file-upload-item__progress-track" value="${t}" max="100" aria-label="Laster opp ${this.file??""}"></u-progress>
1741
+ <div class="sds-file-upload-item__progress-meta">
1742
+ ${void 0!==this.uploadedSizeInBytes?J`<span class="sds-file-upload-item__progress-uploaded">${Ye(this.uploadedSizeInBytes)}</span>`:st}
1743
+ <span class="sds-file-upload-item__progress-percent">${t}%</span>
1744
+ </div>
1745
+ </div>
1746
+ `},this._renderErrorAlert=()=>J`
1747
+ <sds-alert class="sds-file-upload-item__error-alert" size="sm" variant="secondary" data-palette="danger">
1748
+ <p slot="message">${this.errorMessage}</p>
1749
+ </sds-alert>
1750
+ `,this.internals=this.attachInternals(),this.internals.role="listitem"}willUpdate(t){t.has("preview")&&(this._previewLoaded=!1)}updated(t){if(!t.has("preview"))return;const e=this._previewImg;if(!this.preview||this.errorMessage||!e)return;const s=e.src,o=()=>{e.src===s&&(this._previewLoaded=!0)};e.decode?e.decode().then(o).catch(()=>{}):o()}focus(t){this._removeButton?.focus(t)}get _hasError(){return Boolean(this.errorMessage)}_removeFromAssociatedUpload(){if(!this.htmlFor)return;const t=this.getRootNode(),e=t.getElementById?.(this.htmlFor)??document.getElementById(this.htmlFor);if(!e||!("removeFile"in e)||!("dismissRejected"in e))return;const s=e,o=(t,e)=>t===this.file&&(void 0===this.sizeInBytes||e===this.sizeInBytes);if(this.errorMessage){const t=s.rejectedFiles.find(({file:t})=>o(t.name,t.size));t&&s.dismissRejected(t.file)}else{const t=s.files.find(t=>o(t.name,t.size));t&&s.removeFile(t)}this.remove()}render(){const t={"sds-file-upload-item":!0,"sds-file-upload-item--error":this._hasError},e=void 0!==this.uploadedPercent&&!this._hasError;return J`
1751
+ <div class="${se(t)}">
1752
+ <div class="sds-file-upload-item__row">
1753
+ <div class="sds-file-upload-item__content">
1754
+ ${this._renderThumbnail()}
1755
+ ${this._renderFileData()}
1756
+ </div>
1757
+ <div class="sds-file-upload-item__actions">
1758
+ <slot name="actions-end"></slot>
1759
+ ${this._renderRemoveButton()}
1760
+ </div>
1761
+ </div>
1762
+ ${e?this._renderProgress():st}
1763
+ </div>
1764
+ ${this._hasError?this._renderErrorAlert():st}
1765
+ `}};ns.styles=[rs],ds([S({type:String,reflect:!0})],ns.prototype,"file",2),ds([S({type:Number,attribute:"size-in-bytes",reflect:!0})],ns.prototype,"sizeInBytes",2),ds([S({type:String,attribute:"error-message",reflect:!0})],ns.prototype,"errorMessage",2),ds([S({type:String,reflect:!0})],ns.prototype,"preview",2),ds([S({type:Number,attribute:"uploaded-percent",reflect:!0})],ns.prototype,"uploadedPercent",2),ds([S({type:Number,attribute:"uploaded-size-in-bytes",reflect:!0})],ns.prototype,"uploadedSizeInBytes",2),ds([S({type:Boolean,reflect:!0})],ns.prototype,"disabled",2),ds([S({type:String,attribute:"for",reflect:!0})],ns.prototype,"htmlFor",2),ds([L(".sds-file-upload-item__content-preview-image")],ns.prototype,"_previewImg",2),ds([L(".sds-file-upload-item__remove")],ns.prototype,"_removeButton",2),ds([C()],ns.prototype,"_previewLoaded",2),ns=ds([A("sds-file-upload-item")],ns);const ls=d`
1766
+ :host {
1767
+ display: block;
1768
+ }
1769
+
1770
+ :host([hidden]) {
1771
+ display: none;
1772
+ }
1773
+
1774
+ .sds-file-upload-file-list__items {
1775
+ --_sds-file-upload-file-list-gap: var(--sds-file-upload-file-list-gap, var(--sds-spacing-3xs));
1776
+
1777
+ display: flex;
1778
+ flex-direction: column;
1779
+ gap: var(--_sds-file-upload-file-list-gap);
1780
+ }
1781
+ `;var cs=Object.getOwnPropertyDescriptor;let hs=class extends mt{constructor(){super(),this.internals=this.attachInternals(),this.internals.role="list"}render(){return J`<div class="sds-file-upload-file-list__items" role="presentation"><slot></slot></div>`}};hs.styles=[ls],hs=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?cs(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-file-upload-file-list")],hs);var ps=Object.defineProperty,gs=Object.getOwnPropertyDescriptor,vs=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?gs(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&ps(e,s,a),a};let us=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.multiple=!1,this.required=!1,this.variant="default",this.size="md",this.hideFileList=!1,this._files=[],this._rejectedFiles=[],this._hasSlottedLabel=!1,this._previews=new ss(this,(t,e)=>this.dispatchSheriffEvent("sds-preview-ready",{file:t,url:e})),this._dragDrop=new Je(this,t=>this._processFiles(t),()=>Boolean(this.disabled)),this._handleInputChange=t=>{t.stopImmediatePropagation();const e=t.target;this._processFiles(Array.from(e.files??[]))},this._handleNativeInput=t=>{t.stopImmediatePropagation()},this._handleInputCancel=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("cancel",void 0,!1)},this._handleItemRemove=async(t,e,s)=>{const o=this._builtInItems().indexOf(t.currentTarget);s?this.dismissRejected(e):this.removeFile(e),await this.updateComplete;const r=this._builtInItems();(r[o]??r[o-1]??this).focus()},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("blur")},this._renderItem=(t,e)=>J`
1782
+ <sds-file-upload-item
1783
+ file="${t.name}"
1784
+ size-in-bytes="${t.size}"
1785
+ preview="${qt(e?void 0:this._previews.get(t))}"
1786
+ error-message="${qt(e?.reason)}"
1787
+ ?disabled="${!e&&this.disabled}"
1788
+ @sds-remove="${s=>this._handleItemRemove(s,t,e)}"
1789
+ ></sds-file-upload-item>
1790
+ `,this._renderFileList=()=>J`
1791
+ <sds-file-upload-file-list aria-label="Valgte filer" aria-live="polite">
1792
+ ${this._files.map(t=>this._renderItem(t))}
1793
+ ${this._rejectedFiles.map(t=>this._renderItem(t.file,t))}
1794
+ </sds-file-upload-file-list>
1795
+ `,this._renderInput=()=>{const t=[this.errorMessage?"error-message":null,this.helpText?"help-text":null,this.fileLimitationText?"file-limitation-text":null].filter(Boolean).join(" ")||void 0;return J`
1796
+ <input
1797
+ id="control"
1798
+ class="sds-file-upload__input"
1799
+ type="file"
1800
+ accept="${qt(this.accept)}"
1801
+ name="${qt(this.name)}"
1802
+ ?multiple="${this.multiple}"
1803
+ ?required="${this.required}"
1804
+ ?disabled="${this.disabled}"
1805
+ aria-label="${qt(this._showLabel?void 0:this._triggerText)}"
1806
+ aria-describedby="${qt(t)}"
1807
+ aria-invalid="${this.errorMessage?"true":"false"}"
1808
+ @input="${this._handleNativeInput}"
1809
+ @change="${this._handleInputChange}"
1810
+ @cancel="${this._handleInputCancel}"
1811
+ @focus="${this._handleFocus}"
1812
+ @blur="${this._handleBlur}"
1813
+ />
1814
+ `},this._renderDropzone=()=>{const t={"sds-file-upload__dropzone":!0,"sds-file-upload__dropzone--dragging":this._dragDrop.dragging,"sds-file-upload__dropzone--error":Boolean(this.errorMessage)},e="compact"===this.variant?this.size:"lg";return J`
1815
+ <div
1816
+ class="${se(t)}"
1817
+ @dragover="${this._dragDrop.handleDragOver}"
1818
+ @dragleave="${this._dragDrop.handleDragLeave}"
1819
+ @drop="${this._dragDrop.handleDrop}"
1820
+ >
1821
+ ${this._renderInput()}
1822
+ <sds-icon name="upload-material-outlined" size="${e}"></sds-icon>
1823
+ <p class="sds-file-upload__drop-text" aria-hidden="true">${this.multiple?"Dra og slipp filene her eller":"Dra og slipp filen her eller"}</p>
1824
+ <sds-button
1825
+ class="sds-file-upload__trigger"
1826
+ variant="secondary"
1827
+ size="${"compact"===this.variant?"sm":this.size}"
1828
+ type="button"
1829
+ ?disabled="${this.disabled}"
1830
+ inert
1831
+ >
1832
+ <span class="sds-file-upload__button-label">${this._triggerText}</span>
1833
+ </sds-button>
1834
+ <div class="sds-file-upload__drop-hint" aria-hidden="true">
1835
+ <sds-icon name="upload-material-outlined" size="${e}"></sds-icon>
1836
+ <span class="sds-file-upload__drop-hint-text">Slipp fil</span>
1837
+ </div>
1838
+ </div>
1839
+ `}}get files(){return this._files}get rejectedFiles(){return this._rejectedFiles}get value(){return this._files[0]?`C:\\fakepath\\${this._files[0].name}`:""}set value(t){if(""!==t)throw new DOMException("Failed to set the 'value' property on sds-file-upload: only the empty string may be assigned.","InvalidStateError");this._reset()}removeFile(t){const e=this._files;this._files=e.filter(e=>!Xe(e,t)),this._commitSelection(e)}clear(){const t=this._files;this._files=[],this._rejectedFiles=[],this._commitSelection(t)}dismissRejected(t){this._rejectedFiles=this._rejectedFiles.filter(e=>!Xe(e.file,t))}getPreviewUrl(t){return this._previews.get(t)}focus(t){this.disabled||this.control?.focus(t)}blur(){this.disabled||this.control?.blur()}checkValidity(){return this.internals.checkValidity()}reportValidity(){return this.internals.reportValidity()}setCustomValidity(t){this.errorMessage=t||void 0,this.updateValidity()}connectedCallback(){super.connectedCallback(),this._updateFormValue()}formResetCallback(){this._reset()}updated(t){super.updated(t),(t.has("required")||t.has("errorMessage")||t.has("disabled"))&&this.updateValidity(),t.has("name")&&this._updateFormValue()}updateValidity(){if(this.control)if(this.disabled)this.internals.setValidity({});else if(this.errorMessage)this.internals.setValidity({customError:!0},this.errorMessage,this.control);else{if(this.required&&0===this._files.length){const t=this.control.validationMessage;if(!t)return;return void this.internals.setValidity({valueMissing:!0},t,this.control)}this.internals.setValidity({})}}_reset(){this._files=[],this._rejectedFiles=[],this.control&&(this.control.value=""),this._previews.sync(this._files),this._updateFormValue(),this.updateValidity()}get type(){return"file"}get _showLabel(){return this._hasSlottedLabel||Boolean(this.label)}get _triggerText(){return this.multiple?"Velg filer":"Velg fil"}_processFiles(t){if(0===t.length)return;const e=this._files,{accepted:s,rejected:o}=function(t,e){const{accept:s,maxSizeInBytes:o,multiple:r=!1}=e,a=[],i=[],d=r?t:t.slice(0,1);for(const n of d)Qe(n,s)?o&&n.size>o?i.push({file:n,reason:`Filen er for stor. Maks ${Ye(o)}.`,errorCode:"too-large"}):a.some(t=>Xe(t,n))||a.push(n):i.push({file:n,reason:"Filtypen støttes ikke.",errorCode:"type-mismatch"});return{accepted:a,rejected:i}}(t,{accept:this.accept,maxSizeInBytes:this.maxSizeInBytes,multiple:this.multiple});this._files=s,this._rejectedFiles=o,this._commitSelection(e),o.length&&this.dispatchSheriffEvent("sds-reject",{rejected:o})}_builtInItems(){return Array.from(this.renderRoot.querySelectorAll("sds-file-upload-file-list > sds-file-upload-item"))}_isSameSelection(t,e){return t.length===e.length&&t.every((t,s)=>{const o=e[s];return void 0!==o&&Xe(t,o)})}_syncSelection(){this._previews.sync(this._files),this._syncNativeInput(),this._updateFormValue(),this.updateValidity()}_commitSelection(t){this._syncSelection(),this._isSameSelection(t,this._files)||(this.dispatchSheriffEvent("input"),this.dispatchSheriffEvent("change"))}_syncNativeInput(){if(!this.control)return;const t=new DataTransfer;for(const e of this._files)t.items.add(e);this.control.files=t.files}_updateFormValue(){if(!this.name)return void this.internals.setFormValue(null);const t=new FormData;0===this._files.length&&t.append(this.name,new File([],"",{type:"application/octet-stream"}));for(const e of this._files)t.append(this.name,e,e.name);this.internals.setFormValue(t)}render(){return J`
1840
+ <div class="sds-file-upload">
1841
+ <label for="control" class="sds-file-upload__label" ?hidden="${!this._showLabel}">
1842
+ <slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
1843
+ </label>
1844
+ ${this.helpText?J`<p id="help-text" class="sds-file-upload__help-text">${this.helpText}</p>`:st}
1845
+
1846
+ ${this._renderDropzone()}
1847
+
1848
+ ${this.fileLimitationText?J`<p id="file-limitation-text" class="sds-file-upload__file-limitation-text">${this.fileLimitationText}</p>`:st}
1849
+ </div>
1850
+ ${this.errorMessage?J`<sds-alert class="sds-file-upload__error-message" id="error-message" variant="secondary" data-palette="danger"><p slot="message">${this.errorMessage}</p></sds-alert>`:st}
1851
+ ${this.hideFileList?st:this._renderFileList()}
1852
+ `}};us.styles=[os],vs([S({type:String,reflect:!0})],us.prototype,"accept",2),vs([S({type:String,reflect:!0})],us.prototype,"label",2),vs([S({type:Boolean,reflect:!0})],us.prototype,"multiple",2),vs([S({type:Boolean,reflect:!0})],us.prototype,"required",2),vs([S({type:Number,attribute:"max-size-in-bytes",reflect:!0})],us.prototype,"maxSizeInBytes",2),vs([S({type:String,attribute:"help-text",reflect:!0})],us.prototype,"helpText",2),vs([S({type:String,attribute:"error-message",reflect:!0})],us.prototype,"errorMessage",2),vs([S({type:String,attribute:"file-limitation-text",reflect:!0})],us.prototype,"fileLimitationText",2),vs([S({type:String,reflect:!0})],us.prototype,"variant",2),vs([S({type:String,reflect:!0})],us.prototype,"size",2),vs([S({type:Boolean,attribute:"hide-file-list",reflect:!0})],us.prototype,"hideFileList",2),vs([L("#control")],us.prototype,"control",2),vs([C()],us.prototype,"_files",2),vs([C()],us.prototype,"_rejectedFiles",2),vs([C()],us.prototype,"_hasSlottedLabel",2),us=vs([A("sds-file-upload")],us);const fs=d`
1259
1853
  :host {
1260
1854
  --_sds-details-text-color: var(--sds-details-text-color, var(--sds-color-text-default, var(--sds-color-main-text-default)));
1261
1855
 
@@ -1393,7 +1987,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1393
1987
  display: inline;
1394
1988
  margin: 0;
1395
1989
  }
1396
- `;var Ze=Object.defineProperty,Ye=Object.getOwnPropertyDescriptor,Qe=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ye(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Ze(e,s,a),a};let Xe=class extends(At(mt)){constructor(){super(...arguments),this.open=!1,this.standalone=!1,this.name=void 0,this._initialized=!1,this._handleToggle=t=>{const e=t.currentTarget;this.open!==e.open&&(this.open=e.open)}}updated(t){this._initialized?t.has("open")&&this.dispatchSheriffEvent("toggle",{open:!!this.open}):this._initialized=!0}render(){return J`
1990
+ `;var bs=Object.defineProperty,_s=Object.getOwnPropertyDescriptor,ms=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?_s(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&bs(e,s,a),a};let xs=class extends(Lt(mt)){constructor(){super(...arguments),this.open=!1,this.standalone=!1,this.name=void 0,this._initialized=!1,this._handleToggle=t=>{const e=t.currentTarget;this.open!==e.open&&(this.open=e.open)}}updated(t){this._initialized?t.has("open")&&this.dispatchSheriffEvent("toggle",{open:!!this.open}):this._initialized=!0}render(){return J`
1397
1991
  <details class="sds-details" .name="${this.name??""}" ?data-standalone="${this.standalone}" ?open="${this.open}" @toggle="${this._handleToggle}">
1398
1992
  <summary class="sds-details__summary">
1399
1993
  <sds-icon name="chevron_up-material-filled" role="presentation"></sds-icon>
@@ -1405,7 +1999,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1405
1999
  <slot></slot>
1406
2000
  </div>
1407
2001
  </details>
1408
- `}};Xe.styles=[We],Qe([S({type:Boolean,reflect:!0})],Xe.prototype,"open",2),Qe([S({type:Boolean,reflect:!0})],Xe.prototype,"standalone",2),Qe([S({type:String,reflect:!0})],Xe.prototype,"name",2),Xe=Qe([O("sds-details")],Xe);const Je=d`
2002
+ `}};xs.styles=[fs],ms([S({type:Boolean,reflect:!0})],xs.prototype,"open",2),ms([S({type:Boolean,reflect:!0})],xs.prototype,"standalone",2),ms([S({type:String,reflect:!0})],xs.prototype,"name",2),xs=ms([A("sds-details")],xs);const ys=d`
1409
2003
  :host {
1410
2004
  display: block;
1411
2005
  }
@@ -1442,7 +2036,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1442
2036
  :host([outlined]) div ::slotted(sds-details:only-child[open]) {
1443
2037
  --sds-details-summary-border-radius: var(--sds-radius-md) var(--sds-radius-md) 0 0;
1444
2038
  }
1445
- `;var ts=Object.defineProperty,es=Object.getOwnPropertyDescriptor,ss=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?es(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&ts(e,s,a),a};let os=class extends mt{constructor(){super(...arguments),this.outlined=!1,this._toggleListeners=/* @__PURE__ */new Map}updated(t){t.has("name")&&this._syncChildren()}disconnectedCallback(){super.disconnectedCallback(),this._removeListeners()}_handleSlotChange(){this._syncChildren()}_syncChildren(){this._removeListeners();const t=this._detailsChildren;t.forEach(e=>{if(e.name=this.name,this.name){const s=s=>{const{open:o}=s.detail;o&&t.forEach(t=>{t!==e&&t.open&&(t.open=!1)})};e.addEventListener("toggle",s),this._toggleListeners.set(e,s)}})}_removeListeners(){this._toggleListeners.forEach((t,e)=>{e.removeEventListener("toggle",t)}),this._toggleListeners.clear()}render(){return J`<div><slot @slotchange="${this._handleSlotChange}"></slot></div>`}};os.styles=[Je],ss([S({type:Boolean,reflect:!0})],os.prototype,"outlined",2),ss([S({type:String,reflect:!0})],os.prototype,"name",2),ss([L({selector:"sds-details"})],os.prototype,"_detailsChildren",2),os=ss([O("sds-details-group")],os);const rs=d`
2039
+ `;var ws=Object.defineProperty,ks=Object.getOwnPropertyDescriptor,zs=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?ks(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&ws(e,s,a),a};let $s=class extends mt{constructor(){super(...arguments),this.outlined=!1,this._toggleListeners=/* @__PURE__ */new Map}updated(t){t.has("name")&&this._syncChildren()}disconnectedCallback(){super.disconnectedCallback(),this._removeListeners()}_handleSlotChange(){this._syncChildren()}_syncChildren(){this._removeListeners();const t=this._detailsChildren;t.forEach(e=>{if(e.name=this.name,this.name){const s=s=>{const{open:o}=s.detail;o&&t.forEach(t=>{t!==e&&t.open&&(t.open=!1)})};e.addEventListener("toggle",s),this._toggleListeners.set(e,s)}})}_removeListeners(){this._toggleListeners.forEach((t,e)=>{e.removeEventListener("toggle",t)}),this._toggleListeners.clear()}render(){return J`<div><slot @slotchange="${this._handleSlotChange}"></slot></div>`}};$s.styles=[ys],zs([S({type:Boolean,reflect:!0})],$s.prototype,"outlined",2),zs([S({type:String,reflect:!0})],$s.prototype,"name",2),zs([O({selector:"sds-details"})],$s.prototype,"_detailsChildren",2),$s=zs([A("sds-details-group")],$s);const Ss=d`
1446
2040
  :host {
1447
2041
  --_sds-dialog-background-color: var(--sds-dialog-background-color, var(--sds-color-surface-default, var(--sds-color-main-surface-default)));
1448
2042
  --_sds-dialog-backdrop-color: var(--sds-dialog-backdrop-color, rgba(0, 0, 0, 0.5));
@@ -1562,7 +2156,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1562
2156
  --_sds-dialog-animation-duration: 0ms;
1563
2157
  }
1564
2158
  }
1565
- `;var as=Object.defineProperty,is=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&as(e,s,a),a};let ds=!1;const ns=class extends(At(mt)){constructor(){super(...arguments),this.open=!1,this.modal=!1,this.closedby="closerequest",this.closeButtonLabel="Lukk dialogvindu",this._isHeaderSlotEmpty=!0,this._pointerDownInside=!1,this._handleClose=()=>{this.open=!1,this.dispatchSheriffEvent("close"),this.dispatchSheriffEvent("sds-close")},this._handleClick=t=>{const e=t.target;e?.closest('[data-command="close"],[command="close"]')&&this._closeDialog()},this._handlePointerDown=t=>{const e=this._dialog.getBoundingClientRect(),{clientX:s,clientY:o}=t;this._pointerDownInside=e.top<=o&&o<=e.bottom&&e.left<=s&&s<=e.right},this._handlePointerUp=t=>{const e=this._pointerDownInside;this._pointerDownInside=!1,"any"!==this.closedby||e||t.target===this._dialog&&requestAnimationFrame(()=>{this._dialog&&this._dialog.open&&this._closeDialog()})},this._handleCancel=t=>{"none"===this.closedby&&t.preventDefault()},this._handleHeaderSlotChange=t=>{const e=t.target;this._isHeaderSlotEmpty=0===e.assignedElements().length},this._handleAutoFocus=()=>{const t=this.shadowRoot?.querySelector("slot:not([name])")?.assignedElements({flatten:!0});if(!t||0===t.length)return;const e=t.find(t=>null!=t.getAttribute("autofocus"));e instanceof HTMLElement&&document.activeElement!==e&&e.focus()}}addEventListener(t,e,s){"sds-close"!==t||ds||(ds=!0,console.warn("[Sheriff] The 'sds-close' event on sds-dialog is deprecated and will be removed in the next major release. Listen for the 'close' event instead.")),super.addEventListener(t,e,s)}firstUpdated(){this._setupEventListeners(),this.open&&this._openDialog()}updated(t){t.has("open")&&(this.open?this._openDialog():this._closeDialog())}_setupEventListeners(){this._dialog.addEventListener("close",this._handleClose),this._dialog.addEventListener("cancel",this._handleCancel),this._dialog.addEventListener("click",this._handleClick),this._dialog.addEventListener("pointerdown",this._handlePointerDown),this._dialog.addEventListener("pointerup",this._handlePointerUp),this._dialog.addEventListener("animationend",this._handleAutoFocus)}_openDialog(){this._dialog&&(this.modal?this._dialog.showModal():this._dialog.show())}_closeDialog(){this._dialog&&this._dialog.close()}show(){this.open=!0}showModal(){this.modal=!0,this.open=!0}close(){this.open=!1}requestClose(){this._dialog&&this._dialog.requestClose()}render(){return J`
2159
+ `;var Cs=Object.defineProperty,Es=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Cs(e,s,a),a};let Ls=!1;const Os=class extends(Lt(mt)){constructor(){super(...arguments),this.open=!1,this.modal=!1,this.closedby="closerequest",this.closeButtonLabel="Lukk dialogvindu",this._isHeaderSlotEmpty=!0,this._pointerDownInside=!1,this._handleClose=t=>{t.target===this._dialog&&(this.open=!1,this.dispatchSheriffEvent("close"),this.dispatchSheriffEvent("sds-close"))},this._handleClick=t=>{const e=t.target;e?.closest('[data-command="close"],[command="close"]')&&this._closeDialog()},this._handlePointerDown=t=>{const e=this._dialog.getBoundingClientRect(),{clientX:s,clientY:o}=t;this._pointerDownInside=e.top<=o&&o<=e.bottom&&e.left<=s&&s<=e.right},this._handlePointerUp=t=>{const e=this._pointerDownInside;this._pointerDownInside=!1,"any"!==this.closedby||e||t.target===this._dialog&&requestAnimationFrame(()=>{this._dialog&&this._dialog.open&&this._closeDialog()})},this._handleCancel=t=>{t.target===this._dialog&&("none"!==this.closedby&&this.dispatchEvent(new CustomEvent("cancel",{cancelable:t.cancelable}))||t.preventDefault())},this._handleHeaderSlotChange=t=>{const e=t.target;this._isHeaderSlotEmpty=0===e.assignedElements().length},this._handleAutoFocus=()=>{const t=this.shadowRoot?.querySelector("slot:not([name])")?.assignedElements({flatten:!0});if(!t||0===t.length)return;const e=t.find(t=>null!=t.getAttribute("autofocus"));e instanceof HTMLElement&&document.activeElement!==e&&e.focus()}}addEventListener(t,e,s){"sds-close"!==t||Ls||(Ls=!0,console.warn("[Sheriff] The 'sds-close' event on sds-dialog is deprecated and will be removed in the next major release. Listen for the 'close' event instead.")),super.addEventListener(t,e,s)}firstUpdated(){this._setupEventListeners(),this.open&&this._openDialog()}updated(t){t.has("open")&&(this.open?this._openDialog():this._closeDialog())}_setupEventListeners(){this._dialog.addEventListener("close",this._handleClose),this._dialog.addEventListener("cancel",this._handleCancel),this._dialog.addEventListener("click",this._handleClick),this._dialog.addEventListener("pointerdown",this._handlePointerDown),this._dialog.addEventListener("pointerup",this._handlePointerUp),this._dialog.addEventListener("animationend",this._handleAutoFocus)}_openDialog(){this._dialog&&(this.modal?this._dialog.showModal():this._dialog.show())}_closeDialog(){this._dialog&&this._dialog.close()}show(){this.open=!0}showModal(){this.modal=!0,this.open=!0}close(){this.open=!1}requestClose(){this._dialog&&this._dialog.requestClose()}render(){return J`
1566
2160
  <dialog .closedBy="${this.closedby}" class=${this._isHeaderSlotEmpty?"sds-dialog__empty-header":""}>
1567
2161
  <div class="sds-dialog__header">
1568
2162
  <slot name="header" @slotchange=${this._handleHeaderSlotChange}></slot>
@@ -1575,7 +2169,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1575
2169
  <slot></slot>
1576
2170
  <slot name="footer"></slot>
1577
2171
  </dialog>
1578
- `}};ns.styles=[rs];let ls=ns;is([S({type:Boolean,reflect:!0})],ls.prototype,"open"),is([S({type:Boolean,reflect:!0})],ls.prototype,"modal"),is([S({type:String,reflect:!0})],ls.prototype,"closedby"),is([S({type:String,attribute:"close-button-label"})],ls.prototype,"closeButtonLabel"),is([A("dialog")],ls.prototype,"_dialog"),is([C()],ls.prototype,"_isHeaderSlotEmpty");var cs=Object.getOwnPropertyDescriptor;let hs=class extends ls{};hs=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?cs(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-dialog")],hs);const ps=d`
2172
+ `}};Os.styles=[Ss];let As=Os;Es([S({type:Boolean,reflect:!0})],As.prototype,"open"),Es([S({type:Boolean,reflect:!0})],As.prototype,"modal"),Es([S({type:String,reflect:!0})],As.prototype,"closedby"),Es([S({type:String,attribute:"close-button-label"})],As.prototype,"closeButtonLabel"),Es([L("dialog")],As.prototype,"_dialog"),Es([C()],As.prototype,"_isHeaderSlotEmpty");var Ds=Object.getOwnPropertyDescriptor;let Ps=class extends As{};Ps=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ds(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-dialog")],Ps);const Ts=d`
1579
2173
  :host {
1580
2174
  --_sds-heading-font-family: var(--sds-heading-font-family, var(--sds-typography-font-family-roboto));
1581
2175
  --_sds-heading-text-color: var(--sds-heading-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
@@ -1734,7 +2328,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1734
2328
  --_sds-heading-line-height: var(--sds-heading-line-height, var(--sds-typography-heading-xs-desktop-line-height));
1735
2329
  }
1736
2330
  }
1737
- `;var gs=Object.defineProperty,vs=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&gs(e,s,a),a};const us=class extends mt{constructor(){super(...arguments),this.level="h1"}render(){const t={"sds-heading":!0,"sds-heading--xl":"xl"===this.size,"sds-heading--lg":"l"===this.size||"lg"===this.size,"sds-heading--md":"m"===this.size||"md"===this.size,"sds-heading--sm":"s"===this.size||"sm"===this.size,"sds-heading--xs":"xs"===this.size};switch(this.level?.toLowerCase()){case"h1":default:return J`<h1 class=${te(t)}><slot></slot></h1>`;case"h2":return J`<h2 class=${te(t)}><slot></slot></h2>`;case"h3":return J`<h3 class=${te(t)}><slot></slot></h3>`;case"h4":return J`<h4 class=${te(t)}><slot></slot></h4>`;case"h5":return J`<h5 class=${te(t)}><slot></slot></h5>`;case"h6":return J`<h6 class=${te(t)}><slot></slot></h6>`}}};us.styles=[ps];let fs=us;vs([S({type:String,reflect:!0})],fs.prototype,"level"),vs([S({type:String,reflect:!0})],fs.prototype,"size");var bs=Object.getOwnPropertyDescriptor;let _s=class extends fs{};_s=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?bs(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-heading")],_s);const ms=d`
2331
+ `;var qs=Object.defineProperty,Ms=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&qs(e,s,a),a};const Vs=class extends mt{constructor(){super(...arguments),this.level="h1"}render(){const t={"sds-heading":!0,"sds-heading--xl":"xl"===this.size,"sds-heading--lg":"l"===this.size||"lg"===this.size,"sds-heading--md":"m"===this.size||"md"===this.size,"sds-heading--sm":"s"===this.size||"sm"===this.size,"sds-heading--xs":"xs"===this.size};switch(this.level?.toLowerCase()){case"h1":default:return J`<h1 class=${se(t)}><slot></slot></h1>`;case"h2":return J`<h2 class=${se(t)}><slot></slot></h2>`;case"h3":return J`<h3 class=${se(t)}><slot></slot></h3>`;case"h4":return J`<h4 class=${se(t)}><slot></slot></h4>`;case"h5":return J`<h5 class=${se(t)}><slot></slot></h5>`;case"h6":return J`<h6 class=${se(t)}><slot></slot></h6>`}}};Vs.styles=[Ts];let Bs=Vs;Ms([S({type:String,reflect:!0})],Bs.prototype,"level"),Ms([S({type:String,reflect:!0})],Bs.prototype,"size");var Is=Object.getOwnPropertyDescriptor;let Rs=class extends Bs{};Rs=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Is(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-heading")],Rs);const js=d`
1738
2332
  :host {
1739
2333
  --_sds-internal-header-background-color: var(--sds-internal-header-background-color, var(--sds-color-action-default, var(--sds-color-accent-action-default)));
1740
2334
  --_sds-internal-header-text-color: var(--sds-internal-header-text-color, var(--sds-color-action-contrast-default, var(--sds-color-main-action-contrast-default)));
@@ -1853,7 +2447,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1853
2447
  --_sds-internal-header-title-line-height: var(--sds-internal-header-title-line-height, var(--sds-typography-heading-sm-desktop-line-height));
1854
2448
  }
1855
2449
  }
1856
- `;var xs=Object.defineProperty,ys=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&xs(e,s,a),a};const ws=class extends bt{constructor(){super(...arguments),this.appName="",this.homeHref=""}get internalLogo(){return tt`
2450
+ `;var Fs=Object.defineProperty,Ns=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Fs(e,s,a),a};const Us=class extends bt{constructor(){super(...arguments),this.appName="",this.homeHref=""}get internalLogo(){return tt`
1857
2451
  <svg class="sds-internal-header__internal-logo" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 26 32" fill="currentColor" aria-hidden="true">
1858
2452
  <path d="M6.5 24.3333H0L13.6667 0H20L6.5 24.3333Z" fill="var(--sds-color-support-3-action-default)" />
1859
2453
  <path d="M12.5 32H6L19.6667 7.66663H26L12.5 32Z" fill="var(--sds-color-neutral-border-default)" />
@@ -1870,7 +2464,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1870
2464
  </div>
1871
2465
  </div>
1872
2466
  </header>
1873
- `}};ws.styles=[ms];let ks=ws;ys([S({type:String,attribute:"app-name",reflect:!0})],ks.prototype,"appName"),ys([S({type:String,attribute:"home-href",reflect:!0})],ks.prototype,"homeHref");var zs=Object.getOwnPropertyDescriptor;let $s=class extends ks{};$s=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?zs(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-internal-header")],$s);const Ss=d`
2467
+ `}};Us.styles=[js];let Hs=Us;Ns([S({type:String,attribute:"app-name",reflect:!0})],Hs.prototype,"appName"),Ns([S({type:String,attribute:"home-href",reflect:!0})],Hs.prototype,"homeHref");var Ks=Object.getOwnPropertyDescriptor;let Gs=class extends Hs{};Gs=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ks(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-internal-header")],Gs);const Ws=d`
1874
2468
  :host {
1875
2469
  --_sds-loader-main-color: var(--sds-loader-main-color, var(--sds-color-action-contrast-default, var(--sds-color-main-action-contrast-default)));
1876
2470
  --_sds-loader-secondary-color: var(--sds-loader-secondary-color, var(--sds-color-border-subtle, var(--sds-color-main-border-subtle)));
@@ -1946,10 +2540,10 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
1946
2540
  stroke-dashoffset: -120px;
1947
2541
  }
1948
2542
  }
1949
- `;var Cs=Object.defineProperty,Es=Object.getOwnPropertyDescriptor,As=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Es(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Cs(e,s,a),a};let Ls=class extends mt{constructor(){super(...arguments),this.size="md",this.contrast=!1}render(){return J`<svg aria-label="Laster" class="sds-loader" role="img" viewBox="0 0 50 50">
2543
+ `;var Zs=Object.defineProperty,Ys=Object.getOwnPropertyDescriptor,Qs=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ys(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Zs(e,s,a),a};let Xs=class extends mt{constructor(){super(...arguments),this.size="md",this.contrast=!1}render(){return J`<svg aria-label="Laster" class="sds-loader" role="img" viewBox="0 0 50 50">
1950
2544
  <circle class="sds-loader__background" cx="25" cy="25" r="20" fill="none" stroke-width="7"></circle>
1951
2545
  <circle class="sds-loader__circle" cx="25" cy="25" r="20" fill="none" stroke-width="7"></circle>
1952
- </svg>`}};Ls.styles=[Ss],As([S({type:String,reflect:!0})],Ls.prototype,"size",2),As([S({type:Boolean,reflect:!0})],Ls.prototype,"contrast",2),Ls=As([O("sds-loader")],Ls);const Os=d`
2546
+ </svg>`}};Xs.styles=[Ws],Qs([S({type:String,reflect:!0})],Xs.prototype,"size",2),Qs([S({type:Boolean,reflect:!0})],Xs.prototype,"contrast",2),Xs=Qs([A("sds-loader")],Xs);const Js=d`
1953
2547
  :host {
1954
2548
  --_sds-notification-background-color: var(--sds-notification-background-color, var(--sds-color-alert-info-surface-tinted));
1955
2549
 
@@ -2086,9 +2680,9 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2086
2680
  margin: 0 !important;
2087
2681
  max-width: var(--_sds-notification-max-line-width) !important;
2088
2682
  }
2089
- `;var Ps=Object.defineProperty,Ds=Object.getOwnPropertyDescriptor,Ts=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ds(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Ps(e,s,a),a};const qs={info:"InformationSquareFill-aksel-filled",success:"check_circle-material-filled",attention:"warning-material-filled",warning:"warning-material-filled",danger:"dangerous-material-filled",critical:"dangerous-material-filled"};let Ms=!1,Vs=class extends(At(mt)){constructor(){super(),this.variant="info",this._remove=()=>{this.dispatchSheriffEvent("sds-remove")},Ms||(Ms=!0,console.warn("[Sheriff] The Notification component is deprecated and will be removed in the next major release. Please migrate to the Alert component."))}updated(t){t.has("variant")&&"critical"===this.variant?this.variant="danger":t.has("variant")&&"warning"===this.variant&&(this.variant="attention")}render(){const t="danger"===this.variant||"critical"===this.variant?"danger":"accent";return J`<div class="${te({"sds-notification":!0})}">
2683
+ `;var to=Object.defineProperty,eo=Object.getOwnPropertyDescriptor,so=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?eo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&to(e,s,a),a};const oo={info:"InformationSquareFill-aksel-filled",success:"check_circle-material-filled",attention:"warning-material-filled",warning:"warning-material-filled",danger:"dangerous-material-filled",critical:"dangerous-material-filled"};let ro=!1,ao=class extends(Lt(mt)){constructor(){super(),this.variant="info",this._remove=()=>{this.dispatchSheriffEvent("sds-remove")},ro||(ro=!0,console.warn("[Sheriff] The Notification component is deprecated and will be removed in the next major release. Please migrate to the Alert component."))}updated(t){t.has("variant")&&"critical"===this.variant?this.variant="danger":t.has("variant")&&"warning"===this.variant&&(this.variant="attention")}render(){const t="danger"===this.variant||"critical"===this.variant?"danger":"accent";return J`<div class="${se({"sds-notification":!0})}">
2090
2684
  <div class="sds-notification__type">
2091
- <sds-icon class="sds-notification__icon" name="${qs[this.variant]}" size="md"></sds-icon>
2685
+ <sds-icon class="sds-notification__icon" name="${oo[this.variant]}" size="md"></sds-icon>
2092
2686
  </div>
2093
2687
  <div class="sds-notification__content">
2094
2688
  <slot name="title"></slot>
@@ -2099,12 +2693,12 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2099
2693
  <sds-icon name="close-material-outlined" size="sm"></sds-icon>
2100
2694
  </sds-button>
2101
2695
  </div>`:st}
2102
- </div>`}};Vs.styles=[Os],Ts([S({type:String,reflect:!0})],Vs.prototype,"variant",2),Ts([S({type:String,attribute:"removable-label",reflect:!0})],Vs.prototype,"removableLabel",2),Vs=Ts([O("sds-notification")],Vs);const Bs=d`
2696
+ </div>`}};ao.styles=[Js],so([S({type:String,reflect:!0})],ao.prototype,"variant",2),so([S({type:String,attribute:"removable-label",reflect:!0})],ao.prototype,"removableLabel",2),ao=so([A("sds-notification")],ao);const io=d`
2103
2697
  :host {
2104
2698
  display: flex;
2105
2699
  flex-direction: column;
2106
2700
  }
2107
- `;var Rs=Object.defineProperty,js=Object.getOwnPropertyDescriptor,Is=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?js(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Rs(e,s,a),a};let Ns=class extends mt{constructor(){super(),this.internals=this.attachInternals(),this.internals.role="list"}render(){return J`<slot></slot>`}};Ns.styles=[Bs],Is([S({type:String,reflect:!0,attribute:"heading-level"})],Ns.prototype,"headingLevel",2),Ns=Is([O("sds-process")],Ns);const Hs=d`
2701
+ `;var no=Object.defineProperty,lo=Object.getOwnPropertyDescriptor,co=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?lo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&no(e,s,a),a};let ho=class extends mt{constructor(){super(),this.internals=this.attachInternals(),this.internals.role="list"}render(){return J`<slot></slot>`}};ho.styles=[io],co([S({type:String,reflect:!0,attribute:"heading-level"})],ho.prototype,"headingLevel",2),ho=co([A("sds-process")],ho);const po=d`
2108
2702
  :host {
2109
2703
  --_sds-process-step-border-width: var(--sds-process-step-border-width, 2px);
2110
2704
  --_sds-process-step-border-color: var(--sds-process-step-border-color, var(--sds-color-action-default, var(--sds-color-main-action-default)));
@@ -2248,7 +2842,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2248
2842
  :host(:last-of-type) {
2249
2843
  --_sds-process-step-line-display: none;
2250
2844
  }
2251
- `;var Fs=Object.defineProperty,Us=Object.getOwnPropertyDescriptor,Gs=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Us(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Fs(e,s,a),a};let Ks=class extends mt{constructor(){super(),this._headingLevel="h2",this._handleMarkerSlotChange=()=>{if(!this.markerSlot||!this.step)return;const t=0===this.markerSlot.assignedNodes({flatten:!0}).length;this.step.classList.toggle("sds-process-step--sub-step",t)},this.internals=this.attachInternals(),this.internals.role="listitem"}connectedCallback(){super.connectedCallback();const t=this.closest("sds-process");t&&t.headingLevel&&(this._headingLevel=t.headingLevel)}firstUpdated(){this._handleMarkerSlotChange()}get safeHeadingLevel(){return["h2","h3","h4","h5","h6"].includes(this._headingLevel)?this._headingLevel:"h2"}render(){return $t`
2845
+ `;var go=Object.defineProperty,vo=Object.getOwnPropertyDescriptor,uo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?vo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&go(e,s,a),a};let fo=class extends mt{constructor(){super(),this._headingLevel="h2",this._handleMarkerSlotChange=()=>{if(!this.markerSlot||!this.step)return;const t=0===this.markerSlot.assignedNodes({flatten:!0}).length;this.step.classList.toggle("sds-process-step--sub-step",t)},this.internals=this.attachInternals(),this.internals.role="listitem"}connectedCallback(){super.connectedCallback();const t=this.closest("sds-process");t&&t.headingLevel&&(this._headingLevel=t.headingLevel)}firstUpdated(){this._handleMarkerSlotChange()}get safeHeadingLevel(){return["h2","h3","h4","h5","h6"].includes(this._headingLevel)?this._headingLevel:"h2"}render(){return $t`
2252
2846
  <div class="sds-process-step">
2253
2847
  <div class="sds-process-step__item">
2254
2848
  <div class="sds-process-step__marker" aria-hidden="true">
@@ -2262,7 +2856,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2262
2856
  </div>
2263
2857
  <span class="sds-process-step__line"></span>
2264
2858
  </div>
2265
- `}};Ks.styles=[Hs],Gs([S({type:String,reflect:!0})],Ks.prototype,"heading",2),Gs([S({type:String,reflect:!0})],Ks.prototype,"timestamp",2),Gs([A('slot[name="marker"]')],Ks.prototype,"markerSlot",2),Gs([A(".sds-process-step")],Ks.prototype,"step",2),Ks=Gs([O("sds-process-step")],Ks);const Ws=d`
2859
+ `}};fo.styles=[po],uo([S({type:String,reflect:!0})],fo.prototype,"heading",2),uo([S({type:String,reflect:!0})],fo.prototype,"timestamp",2),uo([L('slot[name="marker"]')],fo.prototype,"markerSlot",2),uo([L(".sds-process-step")],fo.prototype,"step",2),fo=uo([A("sds-process-step")],fo);const bo=d`
2266
2860
  ${i(':host{--_ds-floating:top;--_ds-floating-arrow-size:0;--_ds-floating-arrow-visibility:inherit;animation:ds-fade-in .15s ease-in-out forwards;inset:0 auto auto 0;margin:0;overflow:visible;position:absolute}:host:before{background:inherit;border:inherit;border-left-color:transparent;border-top-color:transparent;box-sizing:border-box;content:"";height:var(--_ds-floating-arrow-size);left:var(--_ds-floating-arrow-x,50%);position:absolute;rotate:45deg;top:var(--_ds-floating-arrow-y,100%);translate:-50% -50%;visibility:var(--_ds-floating-arrow-visibility);width:var(--_ds-floating-arrow-size)}:host[data-overscroll=contain]{--_ds-floating-overscroll:contain;overscroll-behavior:contain;overflow:auto}:host{&[data-floating|=top]:before{top:100%;rotate:45deg}&[data-floating|=right]:before{left:0;rotate:135deg}&[data-floating|=bottom]:before{top:0;rotate:-135deg}&[data-floating|=left]:before{left:100%;rotate:-45deg}--_ds-floating:var(--dsc-popover-placement);--_ds-floating-arrow-size:var(--dsc-popover-arrow-size);--dsc-popover-background:var(--ds-color-surface-default);--dsc-popover-border-width:var(--ds-border-width-default);--dsc-popover-border-style:solid;--dsc-popover-border-color:var(--ds-color-border-default);--dsc-popover-color:var(--ds-color-text-default);--dsc-popover-arrow-size:var(--ds-size-3);--dsc-popover-border-radius:var(--ds-border-radius-md);--dsc-popover-max-width:300px;--dsc-popover-padding:var(--ds-size-3) var(--ds-size-4);--dsc-popover-box-shadow:var(--ds-shadow-md);--dsc-popover-placement:top;background:var(--dsc-popover-background);border-radius:var(--dsc-popover-border-radius);border-width:var(--dsc-popover-border-width);border-style:var(--dsc-popover-border-style);border-color:var(--dsc-popover-border-color);box-shadow:var(--dsc-popover-box-shadow);box-sizing:border-box;color:var(--dsc-popover-color);max-width:var(--dsc-popover-max-width);padding:var(--dsc-popover-padding)}:host[data-variant=default]{--dsc-popover-background:var(--ds-color-surface-default)}:host[data-variant=tinted]{--dsc-popover-background:var(--ds-color-surface-tinted)}[data-popover=inline]{all:unset;cursor:pointer;text-decoration:underline dotted;text-underline-offset:.27em;font-size:inherit}[data-popover=inline]:not([hidden]){display:inline}[data-popover=inline]:focus-visible{box-shadow:var(--_ds--focus,var(--dsc-focus-boxShadow));outline:var(--_ds--focus,var(--dsc-focus-outline));outline-offset:var(--_ds--focus,var(--ds-border-width-focus))}[data-popover=inline]:focus-visible *{--_ds--focus: }')}
2267
2861
 
2268
2862
  :host {
@@ -2310,7 +2904,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2310
2904
  animation: none;
2311
2905
  }
2312
2906
  }
2313
- `;var Zs=Object.defineProperty,Ys=Object.getOwnPropertyDescriptor,Qs=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Ys(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Zs(e,s,a),a};let Xs=class extends mt{constructor(){super(...arguments),this.placement="top",this.autoPlacement=void 0,this.overscroll=void 0}connectedCallback(){super.connectedCallback(),this.hasAttribute("popover")||this.setAttribute("popover","auto"),this.syncDataAttributes()}updated(t){(t.has("placement")||t.has("autoPlacement")||t.has("overscroll"))&&this.syncDataAttributes()}syncDataAttributes(){this.placement&&(this.dataset.placement=this.placement),this.autoPlacement&&(this.dataset.autoplacement=this.autoPlacement),this.overscroll&&(this.dataset.overscroll=this.overscroll)}render(){return J`<slot></slot>`}};Xs.styles=[Ws],Qs([S({type:String,reflect:!0})],Xs.prototype,"placement",2),Qs([S({type:String,reflect:!0})],Xs.prototype,"autoPlacement",2),Qs([S({type:String,reflect:!0})],Xs.prototype,"overscroll",2),Xs=Qs([O("sds-popover")],Xs);const Js=d`
2907
+ `;var _o=Object.defineProperty,mo=Object.getOwnPropertyDescriptor,xo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?mo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&_o(e,s,a),a};let yo=class extends mt{constructor(){super(...arguments),this.placement="top",this.autoPlacement=void 0,this.overscroll=void 0}connectedCallback(){super.connectedCallback(),this.hasAttribute("popover")||this.setAttribute("popover","auto"),this.syncDataAttributes()}updated(t){(t.has("placement")||t.has("autoPlacement")||t.has("overscroll"))&&this.syncDataAttributes()}syncDataAttributes(){this.placement&&(this.dataset.placement=this.placement),this.autoPlacement&&(this.dataset.autoplacement=this.autoPlacement),this.overscroll&&(this.dataset.overscroll=this.overscroll)}render(){return J`<slot></slot>`}};yo.styles=[bo],xo([S({type:String,reflect:!0})],yo.prototype,"placement",2),xo([S({type:String,reflect:!0})],yo.prototype,"autoPlacement",2),xo([S({type:String,reflect:!0})],yo.prototype,"overscroll",2),yo=xo([A("sds-popover")],yo);const wo=d`
2314
2908
  :host {
2315
2909
  --_sds-radio-font-family: var(--sds-radio-font-family, var(--sds-typography-font-family-roboto));
2316
2910
  --_sds-radio-disabled-opacity: var(--sds-radio-disabled-opacity, var(--sds-color-states-disabled-opacity));
@@ -2519,8 +3113,8 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2519
3113
  margin-block-start: -1px;
2520
3114
  }
2521
3115
  }
2522
- `;var to=Object.defineProperty,eo=Object.getOwnPropertyDescriptor,so=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?eo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&to(e,s,a),a};let oo=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.required=!1,this.label="",this.hideLabel=!1,this.value="on",this.checked=!1,this.error=!1,this.size="md",this._hasSlottedLabel=!1,this._slottedLabelText="",this._rootNode=null,this._disabled=!1,this._disabledIsAuthorControlled=!1,this._settingDisabledFromParent=!1,this._parentRequestDisabled=!1,this._initialChecked=!1,this._pendingGroupSync=!1,this._handleMouseDown=()=>{this.disabled||this.focus()},this._handleClick=()=>this._select(),this._handleKeydown=t=>{if(this.disabled)return;if(t.altKey||t.ctrlKey||t.shiftKey||t.metaKey)return;if(" "===t.key)return t.preventDefault(),void this.click();if(!this.name)return;const e=this._getGroupRadios().filter(t=>!t.disabled),s=e.indexOf(this);if(-1===s)return;let o;switch(t.key){case"ArrowUp":case"ArrowLeft":o=e[s>0?s-1:e.length-1];break;case"ArrowDown":case"ArrowRight":o=e[s<e.length-1?s+1:0];break;default:return}t.preventDefault(),e.length<2||(o?.focus(),o?.click())},this._handleFocus=t=>{t instanceof CustomEvent||(t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus"))},this._handleBlur=t=>{t instanceof CustomEvent||(t.stopImmediatePropagation(),this.dispatchSheriffEvent("blur"))},this._handleLabelSlotChange=t=>{const e=t.target.assignedNodes();this._hasSlottedLabel=e.length>0,this._slottedLabelText=e.map(t=>t.textContent??"").join("").trim()}}get disabled(){return this._disabled}set disabled(t){const e=t??!1,s=this._disabled;s!==e&&(this._disabled=e,this.requestUpdate("disabled",s),this._settingDisabledFromParent||(this._disabledIsAuthorControlled=e))}get parentRequestDisabled(){return this._parentRequestDisabled}set parentRequestDisabled(t){const e=t??!1,s=this._parentRequestDisabled;s!==e&&(this._parentRequestDisabled=e,this.requestUpdate("parentRequestDisabled",s),this._disabledIsAuthorControlled||(this._settingDisabledFromParent=!0,this.disabled=e,this._settingDisabledFromParent=!1))}connectedCallback(){this._rootNode=this.getRootNode(),super.connectedCallback(),this.setAttribute("role","radio"),this._initialChecked||(this._initialChecked=this.checked??!1),this.addEventListener("keydown",this._handleKeydown),this.addEventListener("mousedown",this._handleMouseDown),this.addEventListener("click",this._handleClick),this.addEventListener("focus",this._handleFocus),this.addEventListener("blur",this._handleBlur),this._scheduleGroupSync()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this._handleKeydown),this.removeEventListener("mousedown",this._handleMouseDown),this.removeEventListener("click",this._handleClick),this.removeEventListener("focus",this._handleFocus),this.removeEventListener("blur",this._handleBlur),this._syncGroup(this._getGroupRadios()),this._rootNode=null}firstUpdated(t){super.firstUpdated(t),this._updateGroupValidation()}updated(t){super.updated(t),t.has("checked")&&(this.checked?(this._uncheckSiblings(),this.internals.setFormValue(this.value??null)):this.internals.setFormValue(null),this._updateGroupValidation()),t.has("required")&&this.control&&(this.control.required=this.required??!1),t.has("name")&&(this._syncGroup(this._getGroupRadios(t.get("name"))),this._syncGroup(this.name?this._getGroupRadios():[this])),this._disabledIsAuthorControlled||this.disabled===this._parentRequestDisabled||(this._settingDisabledFromParent=!0,this.disabled=this._parentRequestDisabled??!1,this._settingDisabledFromParent=!1),(t.has("checked")||t.has("disabled"))&&this._updateGroupTabStops(this.name?this._getGroupRadios():[this]),this._syncHostAria()}_getGroupRadios(t=this.name,e=this._rootNode??this.getRootNode()){return t&&e?Array.from(e.querySelectorAll("sds-radio")).filter(e=>e.name===t):[]}_syncHostAria(){this.setAttribute("aria-checked",this.checked?"true":"false"),this.setAttribute("aria-invalid",this.error?"true":"false"),this.disabled?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"),this.required?this.setAttribute("aria-required","true"):this.removeAttribute("aria-required");const t=this._hasSlottedLabel?this._slottedLabelText:this.label??"";t?this.setAttribute("aria-label",t):this.removeAttribute("aria-label"),oo._supportsAriaElementReferences&&(this.internals.ariaDescribedByElements=this._helpTextElement?[this._helpTextElement]:[])}_select(){this.disabled||this.readOnly||this.checked||(this.checked=!0,this._uncheckSiblings(),this._updateGroupValidation(),this.dispatchSheriffEvent("change"))}_updateGroupPositions(t){t.forEach((e,s)=>{e.setAttribute("aria-posinset",String(s+1)),e.setAttribute("aria-setsize",String(t.length))})}_updateGroupTabStops(t){const e=t.filter(t=>!t.disabled),s=e.find(t=>t.checked)??e[0];for(const o of t)o.disabled?o.removeAttribute("tabindex"):o.tabIndex=o===s?0:-1}_syncGroup(t){this._updateGroupPositions(t),this._updateGroupTabStops(t)}_scheduleGroupSync(){this._pendingGroupSync||(this._pendingGroupSync=!0,queueMicrotask(()=>{this._pendingGroupSync=!1,this.isConnected&&this._syncGroup(this.name?this._getGroupRadios():[this])}))}_updateGroupValidation(){const t=this.name?this._getGroupRadios():[this],e=t.some(t=>t.checked),s=t.some(t=>t.required);t.forEach(t=>{t.control&&(s?t.internals.setValidity(e?{}:{valueMissing:!0},e?"":t.control.validationMessage,t.control):t.internals.setValidity({}))})}formResetCallback(){this.checked=this._initialChecked,this.control.checked=this._initialChecked,this.internals.setFormValue(this.checked?this.value??"on":null),this._updateGroupValidation()}_uncheckSiblings(){if(!this.name)return;const t=this._getGroupRadios();for(const e of t)e!==this&&e.checked&&(e.checked=!1,e.internals.setFormValue(null))}focus(t){this.disabled||HTMLElement.prototype.focus.call(this,t)}blur(){HTMLElement.prototype.blur.call(this)}click(){this.disabled||this.readOnly||HTMLElement.prototype.click.call(this)}get type(){return"radio"}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}get willValidate(){return this.internals.willValidate}checkValidity(){return this.internals.checkValidity()}reportValidity(){return this.internals.reportValidity()}setCustomValidity(t){this.internals.setValidity({customError:!!t},t)}formDisabledCallback(t){this._settingDisabledFromParent=!0,this.disabled=t,this._settingDisabledFromParent=!1,this.control&&(this.control.disabled=t)}render(){const t={"sds-radio":!0,"sds-radio--error":Boolean(this.error)},e=this._hasSlottedLabel||Boolean(this.label),s={"sds-radio__input":!0,"sds-radio__input--error":Boolean(this.error)};return J`
2523
- <div class="${te(t)}">
3116
+ `;var ko=Object.defineProperty,zo=Object.getOwnPropertyDescriptor,$o=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?zo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&ko(e,s,a),a};let So=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.required=!1,this.label="",this.hideLabel=!1,this.value="on",this.checked=!1,this.error=!1,this.size="md",this._hasSlottedLabel=!1,this._slottedLabelText="",this._rootNode=null,this._disabled=!1,this._disabledIsAuthorControlled=!1,this._settingDisabledFromParent=!1,this._parentRequestDisabled=!1,this._initialChecked=!1,this._pendingGroupSync=!1,this._handleMouseDown=()=>{this.disabled||this.focus()},this._handleClick=()=>this._select(),this._handleKeydown=t=>{if(this.disabled)return;if(t.altKey||t.ctrlKey||t.shiftKey||t.metaKey)return;if(" "===t.key)return t.preventDefault(),void this.click();if(!this.name)return;const e=this._getGroupRadios().filter(t=>!t.disabled),s=e.indexOf(this);if(-1===s)return;let o;switch(t.key){case"ArrowUp":case"ArrowLeft":o=e[s>0?s-1:e.length-1];break;case"ArrowDown":case"ArrowRight":o=e[s<e.length-1?s+1:0];break;default:return}t.preventDefault(),e.length<2||(o?.focus(),o?.click())},this._handleFocus=t=>{t instanceof CustomEvent||(t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus"))},this._handleBlur=t=>{t instanceof CustomEvent||(t.stopImmediatePropagation(),this.dispatchSheriffEvent("blur"))},this._handleLabelSlotChange=t=>{const e=t.target.assignedNodes();this._hasSlottedLabel=e.length>0,this._slottedLabelText=e.map(t=>t.textContent??"").join("").trim()}}get disabled(){return this._disabled}set disabled(t){const e=t??!1,s=this._disabled;s!==e&&(this._disabled=e,this.requestUpdate("disabled",s),this._settingDisabledFromParent||(this._disabledIsAuthorControlled=e))}get parentRequestDisabled(){return this._parentRequestDisabled}set parentRequestDisabled(t){const e=t??!1,s=this._parentRequestDisabled;s!==e&&(this._parentRequestDisabled=e,this.requestUpdate("parentRequestDisabled",s),this._disabledIsAuthorControlled||(this._settingDisabledFromParent=!0,this.disabled=e,this._settingDisabledFromParent=!1))}connectedCallback(){this._rootNode=this.getRootNode(),super.connectedCallback(),this.setAttribute("role","radio"),this._initialChecked||(this._initialChecked=this.checked??!1),this.addEventListener("keydown",this._handleKeydown),this.addEventListener("mousedown",this._handleMouseDown),this.addEventListener("click",this._handleClick),this.addEventListener("focus",this._handleFocus),this.addEventListener("blur",this._handleBlur),this._scheduleGroupSync()}disconnectedCallback(){super.disconnectedCallback(),this.removeEventListener("keydown",this._handleKeydown),this.removeEventListener("mousedown",this._handleMouseDown),this.removeEventListener("click",this._handleClick),this.removeEventListener("focus",this._handleFocus),this.removeEventListener("blur",this._handleBlur),this._syncGroup(this._getGroupRadios()),this._rootNode=null}firstUpdated(t){super.firstUpdated(t),this._updateGroupValidation()}updated(t){super.updated(t),t.has("checked")&&(this.checked?(this._uncheckSiblings(),this.internals.setFormValue(this.value??null)):this.internals.setFormValue(null),this._updateGroupValidation()),t.has("required")&&this.control&&(this.control.required=this.required??!1),t.has("name")&&(this._syncGroup(this._getGroupRadios(t.get("name"))),this._syncGroup(this.name?this._getGroupRadios():[this])),this._disabledIsAuthorControlled||this.disabled===this._parentRequestDisabled||(this._settingDisabledFromParent=!0,this.disabled=this._parentRequestDisabled??!1,this._settingDisabledFromParent=!1),(t.has("checked")||t.has("disabled"))&&this._updateGroupTabStops(this.name?this._getGroupRadios():[this]),this._syncHostAria()}_getGroupRadios(t=this.name,e=this._rootNode??this.getRootNode()){return t&&e?Array.from(e.querySelectorAll("sds-radio")).filter(e=>e.name===t):[]}_syncHostAria(){this.setAttribute("aria-checked",this.checked?"true":"false"),this.setAttribute("aria-invalid",this.error?"true":"false"),this.disabled?this.setAttribute("aria-disabled","true"):this.removeAttribute("aria-disabled"),this.required?this.setAttribute("aria-required","true"):this.removeAttribute("aria-required");const t=this._hasSlottedLabel?this._slottedLabelText:this.label??"";t?this.setAttribute("aria-label",t):this.removeAttribute("aria-label"),So._supportsAriaElementReferences&&(this.internals.ariaDescribedByElements=this._helpTextElement?[this._helpTextElement]:[])}_select(){this.disabled||this.readOnly||this.checked||(this.checked=!0,this._uncheckSiblings(),this._updateGroupValidation(),this.dispatchSheriffEvent("change"))}_updateGroupPositions(t){t.forEach((e,s)=>{e.setAttribute("aria-posinset",String(s+1)),e.setAttribute("aria-setsize",String(t.length))})}_updateGroupTabStops(t){const e=t.filter(t=>!t.disabled),s=e.find(t=>t.checked)??e[0];for(const o of t)o.disabled?o.removeAttribute("tabindex"):o.tabIndex=o===s?0:-1}_syncGroup(t){this._updateGroupPositions(t),this._updateGroupTabStops(t)}_scheduleGroupSync(){this._pendingGroupSync||(this._pendingGroupSync=!0,queueMicrotask(()=>{this._pendingGroupSync=!1,this.isConnected&&this._syncGroup(this.name?this._getGroupRadios():[this])}))}_updateGroupValidation(){const t=this.name?this._getGroupRadios():[this],e=t.some(t=>t.checked),s=t.some(t=>t.required);t.forEach(t=>{t.control&&(s?t.internals.setValidity(e?{}:{valueMissing:!0},e?"":t.control.validationMessage,t.control):t.internals.setValidity({}))})}formResetCallback(){this.checked=this._initialChecked,this.control.checked=this._initialChecked,this.internals.setFormValue(this.checked?this.value??"on":null),this._updateGroupValidation()}_uncheckSiblings(){if(!this.name)return;const t=this._getGroupRadios();for(const e of t)e!==this&&e.checked&&(e.checked=!1,e.internals.setFormValue(null))}focus(t){this.disabled||HTMLElement.prototype.focus.call(this,t)}blur(){HTMLElement.prototype.blur.call(this)}click(){this.disabled||this.readOnly||HTMLElement.prototype.click.call(this)}get type(){return"radio"}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}get willValidate(){return this.internals.willValidate}checkValidity(){return this.internals.checkValidity()}reportValidity(){return this.internals.reportValidity()}setCustomValidity(t){this.internals.setValidity({customError:!!t},t)}formDisabledCallback(t){this._settingDisabledFromParent=!0,this.disabled=t,this._settingDisabledFromParent=!1,this.control&&(this.control.disabled=t)}render(){const t={"sds-radio":!0,"sds-radio--error":Boolean(this.error)},e=this._hasSlottedLabel||Boolean(this.label),s={"sds-radio__input":!0,"sds-radio__input--error":Boolean(this.error)};return J`
3117
+ <div class="${se(t)}">
2524
3118
  <input
2525
3119
  id="control"
2526
3120
  type="radio"
@@ -2533,14 +3127,14 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2533
3127
  ?required="${this.required}"
2534
3128
  ?readonly="${this.readOnly}"
2535
3129
  inert
2536
- class="${te(s)}"
3130
+ class="${se(s)}"
2537
3131
  />
2538
3132
  <label class="sds-radio__label" ?hidden="${!e}">
2539
3133
  <slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
2540
3134
  </label>
2541
3135
  ${this.helpText?J`<span id="help-text" class="sds-radio__help-text">${this.helpText}</span>`:st}
2542
3136
  </div>
2543
- `}};oo.styles=[Js],oo.shadowRootOptions={...bt.shadowRootOptions,delegatesFocus:!1},oo._supportsAriaElementReferences="undefined"!=typeof ElementInternals&&"ariaDescribedByElements"in ElementInternals.prototype,so([S({type:Boolean,reflect:!0})],oo.prototype,"required",2),so([S({type:String,reflect:!0})],oo.prototype,"label",2),so([S({type:Boolean,reflect:!0,attribute:"hide-label"})],oo.prototype,"hideLabel",2),so([S({type:String})],oo.prototype,"value",2),so([S({type:Boolean,reflect:!0})],oo.prototype,"checked",2),so([S({type:Boolean,reflect:!0})],oo.prototype,"error",2),so([S({type:String,reflect:!0})],oo.prototype,"size",2),so([S({type:String,attribute:"help-text"})],oo.prototype,"helpText",2),so([S({type:Boolean,reflect:!0})],oo.prototype,"disabled",1),so([S({type:Boolean,attribute:!1})],oo.prototype,"parentRequestDisabled",1),so([A("#control")],oo.prototype,"control",2),so([A("#help-text")],oo.prototype,"_helpTextElement",2),so([C()],oo.prototype,"_hasSlottedLabel",2),so([C()],oo.prototype,"_slottedLabelText",2),oo=so([O("sds-radio")],oo);const ro=d`
3137
+ `}};So.styles=[wo],So.shadowRootOptions={...bt.shadowRootOptions,delegatesFocus:!1},So._supportsAriaElementReferences="undefined"!=typeof ElementInternals&&"ariaDescribedByElements"in ElementInternals.prototype,$o([S({type:Boolean,reflect:!0})],So.prototype,"required",2),$o([S({type:String,reflect:!0})],So.prototype,"label",2),$o([S({type:Boolean,reflect:!0,attribute:"hide-label"})],So.prototype,"hideLabel",2),$o([S({type:String})],So.prototype,"value",2),$o([S({type:Boolean,reflect:!0})],So.prototype,"checked",2),$o([S({type:Boolean,reflect:!0})],So.prototype,"error",2),$o([S({type:String,reflect:!0})],So.prototype,"size",2),$o([S({type:String,attribute:"help-text"})],So.prototype,"helpText",2),$o([S({type:Boolean,reflect:!0})],So.prototype,"disabled",1),$o([S({type:Boolean,attribute:!1})],So.prototype,"parentRequestDisabled",1),$o([L("#control")],So.prototype,"control",2),$o([L("#help-text")],So.prototype,"_helpTextElement",2),$o([C()],So.prototype,"_hasSlottedLabel",2),$o([C()],So.prototype,"_slottedLabelText",2),So=$o([A("sds-radio")],So);const Co=d`
2544
3138
  :host {
2545
3139
  --_sds-radio-group-gap: var(--sds-radio-group-gap, var(--sds-spacing-xs));
2546
3140
  --_sds-radio-group-row-gap: var(--sds-radio-group-row-gap, var(--sds-spacing-md));
@@ -2638,12 +3232,12 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2638
3232
  --_sds-radio-group-help-text-font-size: var(--sds-radio-group-help-text-font-size, var(--sds-components-font-size-content-lg));
2639
3233
  --_sds-radio-group-help-text-line-height: var(--sds-radio-group-help-text-line-height, var(--sds-components-line-height-squeezed-lg));
2640
3234
  }
2641
- `;var ao=Object.defineProperty,io=Object.getOwnPropertyDescriptor,no=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?io(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&ao(e,s,a),a};const lo=["disabled","errorMessage","readOnly","required","size"];let co=class extends(At(mt)){constructor(){super(...arguments),this.readOnly=!1,this.direction="column",this.disabled=!1,this.required=!1,this.size="md",this._selectedValue=null,this._handleRadioChange=t=>{const e=t.composedPath().find(t=>t instanceof HTMLElement&&"SDS-RADIO"===t.tagName);e&&(this._selectedValue=e.getAttribute("value")||null,this.dispatchSheriffEvent("sds-update"))},this._handleSlotChange=()=>{this._updateChildProps([...lo])}}_getChildRadios(){return this._slotElement?.assignedElements({flatten:!0}).filter(t=>"SDS-RADIO"===t.tagName)??[]}_updateChildProps(t){const e=this._getChildRadios();for(const s of e)for(const e of t)switch(e){case"readOnly":s.readOnly=this.readOnly;break;case"disabled":s.parentRequestDisabled=this.disabled;break;case"errorMessage":s.error=Boolean(this.errorMessage);break;case"required":s.required=this.required;break;case"size":s.size=this.size}}updated(t){super.updated(t);const e=Array.from(t.keys());(e.includes("errorMessage")||e.includes("error-message"))&&this._updateChildProps(["errorMessage"])}attributeChangedCallback(t,e,s){if(super.attributeChangedCallback(t,e,s),"readonly"===t)return void this._updateChildProps(["readOnly"]);const o=t;lo.includes(o)&&this._updateChildProps([o])}render(){const t={"sds-radio-group":!0,"sds-radio-group--readonly":this.readOnly??!1,"sds-radio-group--disabled":this.disabled??!1},e={"sds-radio-group__radios":!0,"sds-radio-group--column":"column"===this.direction,"sds-radio-group--row":"row"===this.direction},s=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0;return J`
2642
- <fieldset class="${te(t)}" role="none">
3235
+ `;var Eo=Object.defineProperty,Lo=Object.getOwnPropertyDescriptor,Oo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Lo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Eo(e,s,a),a};const Ao=["disabled","errorMessage","readOnly","required","size"];let Do=class extends(Lt(mt)){constructor(){super(...arguments),this.readOnly=!1,this.direction="column",this.disabled=!1,this.required=!1,this.size="md",this._selectedValue=null,this._handleRadioChange=t=>{const e=t.composedPath().find(t=>t instanceof HTMLElement&&"SDS-RADIO"===t.tagName);e&&(this._selectedValue=e.getAttribute("value")||null,this.dispatchSheriffEvent("sds-update"))},this._handleSlotChange=()=>{this._updateChildProps([...Ao])}}_getChildRadios(){return this._slotElement?.assignedElements({flatten:!0}).filter(t=>"SDS-RADIO"===t.tagName)??[]}_updateChildProps(t){const e=this._getChildRadios();for(const s of e)for(const e of t)switch(e){case"readOnly":s.readOnly=this.readOnly;break;case"disabled":s.parentRequestDisabled=this.disabled;break;case"errorMessage":s.error=Boolean(this.errorMessage);break;case"required":s.required=this.required;break;case"size":s.size=this.size}}updated(t){super.updated(t);const e=Array.from(t.keys());(e.includes("errorMessage")||e.includes("error-message"))&&this._updateChildProps(["errorMessage"])}attributeChangedCallback(t,e,s){if(super.attributeChangedCallback(t,e,s),"readonly"===t)return void this._updateChildProps(["readOnly"]);const o=t;Ao.includes(o)&&this._updateChildProps([o])}render(){const t={"sds-radio-group":!0,"sds-radio-group--readonly":this.readOnly??!1,"sds-radio-group--disabled":this.disabled??!1},e={"sds-radio-group__radios":!0,"sds-radio-group--column":"column"===this.direction,"sds-radio-group--row":"row"===this.direction},s=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0;return J`
3236
+ <fieldset class="${se(t)}" role="none">
2643
3237
  ${this.legend?J`<legend id="group-legend" class="sds-radio-group__legend">${this.readOnly?J`<sds-icon name="lock-material-filled" size="md"></sds-icon>`:st}${this.legend}</legend>`:st}
2644
3238
  ${this.helpText?J`<p id="help-text" class="sds-radio-group__help-text">${this.helpText}</p>`:st}
2645
3239
  <div
2646
- class="${te(e)}"
3240
+ class="${se(e)}"
2647
3241
  role="radiogroup"
2648
3242
  aria-labelledby="${qt(this.legend?"group-legend":void 0)}"
2649
3243
  aria-describedby="${qt(s)}"
@@ -2656,31 +3250,368 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2656
3250
  <p slot="message">${this.errorMessage}</p>
2657
3251
  </sds-alert>`:st}
2658
3252
  </fieldset>
2659
- `}get value(){return{selectedValue:this._selectedValue}}};co.styles=[ro],no([S({type:String})],co.prototype,"legend",2),no([S({type:String,attribute:"help-text"})],co.prototype,"helpText",2),no([S({type:String,attribute:"error-message"})],co.prototype,"errorMessage",2),no([S({type:Boolean,attribute:"readonly",reflect:!0})],co.prototype,"readOnly",2),no([S({type:String})],co.prototype,"direction",2),no([S({type:Boolean,reflect:!0})],co.prototype,"disabled",2),no([S({type:Boolean,reflect:!0})],co.prototype,"required",2),no([S({type:String,reflect:!0})],co.prototype,"size",2),no([C()],co.prototype,"_selectedValue",2),no([A("slot")],co.prototype,"_slotElement",2),co=no([O("sds-radio-group")],co);const ho=d`
3253
+ `}get value(){return{selectedValue:this._selectedValue}}};Do.styles=[Co],Oo([S({type:String})],Do.prototype,"legend",2),Oo([S({type:String,attribute:"help-text"})],Do.prototype,"helpText",2),Oo([S({type:String,attribute:"error-message"})],Do.prototype,"errorMessage",2),Oo([S({type:Boolean,attribute:"readonly",reflect:!0})],Do.prototype,"readOnly",2),Oo([S({type:String})],Do.prototype,"direction",2),Oo([S({type:Boolean,reflect:!0})],Do.prototype,"disabled",2),Oo([S({type:Boolean,reflect:!0})],Do.prototype,"required",2),Oo([S({type:String,reflect:!0})],Do.prototype,"size",2),Oo([C()],Do.prototype,"_selectedValue",2),Oo([L("slot")],Do.prototype,"_slotElement",2),Do=Oo([A("sds-radio-group")],Do);const Po=d`
3254
+ /*
3255
+ * The search controls radius and border of inner button and textfield.
3256
+ */
2660
3257
  :host {
2661
- --_sds-select-background-color: var(--sds-select-background-color, var(--sds-color-background-default, var(--sds-color-neutral-background-default)));
2662
- --_sds-select-text-color: var(--sds-select-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3258
+ --_sds-search-radius: var(--sds-search-radius, var(--sds-radius-sm));
3259
+ --_sds-search-border-width: var(--sds-search-border-width, var(--sds-border-sm));
2663
3260
 
2664
- --_sds-select-border-color: var(--sds-select-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
2665
- --_sds-select-border-width: var(--sds-select-border-width, var(--sds-border-sm));
2666
- --_sds-select-border-radius: var(--sds-select-border-radius, var(--sds-radius-sm));
3261
+ display: block;
3262
+ text-align: start;
3263
+ }
2667
3264
 
2668
- --_sds-select-font-family: var(--sds-select-font-family, var(--sds-typography-font-family-roboto));
2669
- --_sds-select-font-size: var(--sds-select-font-size, var(--sds-components-font-size-content-md));
2670
- --_sds-select-font-weight: var(--sds-select-font-weight, var(--sds-typography-font-weight-regular));
2671
- --_sds-select-line-height: var(--sds-select-line-height, var(--sds-components-line-height-squeezed-md));
2672
- --_sds-select-min-height: var(--sds-select-height, var(--sds-components-button-md));
3265
+ .sds-search {
3266
+ display: flex;
3267
+ /* Align to the top; the button is nudged down to the input row in JS so a
3268
+ stacked label, help text, or an error message never drags it out of line. */
3269
+ align-items: flex-start;
3270
+ inline-size: 100%;
3271
+ }
2673
3272
 
2674
- --_sds-select-gap: var(--sds-select-gap, var(--sds-spacing-3xs));
2675
- --_sds-select-padding-block: var(--sds-select-padding-block, 0);
2676
- --_sds-select-padding-inline: var(--sds-select-padding-inline, var(--sds-spacing-xs));
2677
- --_sds-select-padding-icon-inline-end: var(--sds-spacing-lg);
3273
+ /*
3274
+ * The field keeps its rounded corners on the inline-start side and squares the
3275
+ * edge that meets the button; the button mirrors it.
3276
+ */
3277
+ .sds-search__field {
3278
+ flex: 1 1 auto;
3279
+ /* Allow the field to shrink below its intrinsic min-width inside flex. */
3280
+ min-inline-size: 0;
3281
+ /* Let the surrounding container govern the width instead of the
3282
+ textfield's default 60ch cap. */
3283
+ --sds-textfield-input-max-width: none;
3284
+ --sds-textfield-border-width: var(--_sds-search-border-width);
3285
+ --sds-textfield-border-radius: var(--_sds-search-radius) 0 0 var(--_sds-search-radius);
3286
+ }
2678
3287
 
2679
- --_sds-select-disabled-opacity: var(--sds-select-disabled-opacity, var(--sds-color-states-disabled-opacity));
2680
- --_sds-select-max-width: var(--sds-select-max-width, var(--sds-typography-max-line-width, 60ch));
2681
- --_sds-select-width: var(--sds-select-width, fit-content);
3288
+ .sds-search__button,
3289
+ ::slotted([slot='button']) {
3290
+ --sds-button-border-width: var(--_sds-search-border-width);
3291
+ --sds-button-radius: 0 var(--_sds-search-radius) var(--_sds-search-radius) 0;
3292
+ }
2682
3293
 
2683
- --_sds-select-label-text-color: var(--sds-select-label-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3294
+ .sds-search__button-col {
3295
+ display: flex;
3296
+ flex-direction: column;
3297
+ /* Keep the button at its intrinsic size instead of stretching it. */
3298
+ align-items: flex-start;
3299
+ flex: 0 0 auto;
3300
+ /* Overlap the borders so the field and button share a single border. */
3301
+ margin-inline-start: calc(-1 * var(--_sds-search-border-width));
3302
+ }
3303
+
3304
+ /* Raise whichever control is focused so its focus outline is painted on
3305
+ top of the neighbouring control and never clipped by it. */
3306
+ .sds-search__field:focus-within,
3307
+ .sds-search__button-col:focus-within {
3308
+ position: relative;
3309
+ z-index: 1;
3310
+ }
3311
+
3312
+ /*
3313
+ * border-radius is physical, so mirror the rounded corners for RTL. Logical
3314
+ * layout (DOM order, logical margins) already flips on its own.
3315
+ */
3316
+ :host(:dir(rtl)) .sds-search__field {
3317
+ --sds-textfield-border-radius: 0 var(--_sds-search-radius) var(--_sds-search-radius) 0;
3318
+ }
3319
+
3320
+ :host(:dir(rtl)) .sds-search__button,
3321
+ :host(:dir(rtl)) ::slotted([slot='button']) {
3322
+ --sds-button-radius: var(--_sds-search-radius) 0 0 var(--_sds-search-radius);
3323
+ }
3324
+ `,To={},qo=Rt(class extends jt{constructor(t){if(super(t),t.type!==Bt&&t.type!==Mt&&t.type!==It)throw Error("The `live` directive is not allowed on child or event bindings");if(void 0!==t.strings)throw Error("`live` bindings can only contain a single expression")}render(t){return t}update(t,[e]){if(e===et||e===st)return e;const s=t.element,o=t.name;if(t.type===Bt){if(e===s[o])return et}else if(t.type===It){if(!!e===s.hasAttribute(o))return et}else if(t.type===Mt&&s.getAttribute(o)===e+"")return et;return((t,e=To)=>{t._$AH=e})(t),e}}),Mo=d`
3325
+ :host {
3326
+ --_sds-textfield-background-color: var(--sds-textfield-background-color, var(--sds-color-background-default, var(--sds-color-neutral-background-default)));
3327
+ --_sds-textfield-text-color: var(--sds-textfield-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3328
+
3329
+ --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
3330
+ --_sds-textfield-border-width: var(--sds-textfield-border-width, var(--sds-border-sm));
3331
+ --_sds-textfield-border-radius: var(--sds-textfield-border-radius, var(--sds-radius-sm));
3332
+
3333
+ --_sds-textfield-font-family: var(--sds-textfield-font-family, var(--sds-typography-font-family-roboto));
3334
+ --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-md));
3335
+ --_sds-textfield-font-weight: var(--sds-textfield-font-weight, var(--sds-typography-font-weight-regular));
3336
+ --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-md));
3337
+ --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-md));
3338
+
3339
+ --_sds-textfield-gap: var(--sds-textfield-gap, var(--sds-spacing-3xs));
3340
+ --_sds-textfield-padding-block: var(--sds-textfield-padding-block, 0);
3341
+ --_sds-textfield-padding-inline: var(--sds-textfield-padding-inline, var(--sds-spacing-xs));
3342
+ --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-md)));
3343
+ --_sds-textfield-disabled-opacity: var(--sds-textfield-disabled-opacity, var(--sds-color-states-disabled-opacity));
3344
+ --_sds-textfield-max-width: var(--sds-textfield-input-max-width, var(--sds-typography-max-line-width, 60ch));
3345
+
3346
+ --_sds-textfield-label-text-color: var(--sds-textfield-label-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3347
+ --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-md));
3348
+ --_sds-textfield-label-font-weight: var(--sds-textfield-label-font-weight, var(--sds-typography-font-weight-medium));
3349
+ --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-md));
3350
+
3351
+ --_sds-textfield-helptext-text-color: var(--sds-textfield-helptext-text-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
3352
+ --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-md));
3353
+ --_sds-textfield-helptext-font-weight: var(--sds-textfield-helptext-font-weight, var(--sds-typography-font-weight-regular));
3354
+ --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-md));
3355
+
3356
+ --_sds-textfield-focus-color: var(--sds-textfield-focus-color, var(--sds-color-states-focus-outer));
3357
+ --_sds-textfield-focus-inner-color: var(--sds-textfield-focus-inner-color, var(--sds-color-states-focus-inner));
3358
+ --_sds-textfield-focus-spacing: var(--sds-textfield-focus-spacing, var(--sds-color-states-focus-spacing));
3359
+ --_sds-textfield-focus-outline-size: var(--sds-textfield-focus-outline-size, var(--sds-color-states-focus-outline-size));
3360
+
3361
+ --_sds-textfield-cursor: var(--sds-textfield-cursor, auto);
3362
+
3363
+ --_sds-textfield-icon-right: var(--sds-textfield-icon-right, var(--sds-spacing-xs));
3364
+ --_sds-textfield-icon-top: var(--sds-textfield-icon-top, var(--sds-spacing-3xs));
3365
+
3366
+ all: unset;
3367
+ display: block;
3368
+ text-align: start;
3369
+ }
3370
+
3371
+ .sds-textfield {
3372
+ display: flex;
3373
+ flex-direction: column;
3374
+ gap: var(--_sds-textfield-gap);
3375
+ font-family: var(--_sds-textfield-font-family);
3376
+
3377
+ .sds-textfield__input-container {
3378
+ position: relative;
3379
+ font-size: var(--_sds-textfield-font-size);
3380
+ max-width: var(--_sds-textfield-max-width);
3381
+ }
3382
+
3383
+ .sds-textfield__input {
3384
+ box-sizing: border-box;
3385
+ color: var(--_sds-textfield-text-color);
3386
+ padding: var(--_sds-textfield-padding-block) var(--_sds-textfield-padding-inline);
3387
+ line-height: var(--_sds-textfield-line-height);
3388
+ font-size: var(--_sds-textfield-font-size);
3389
+ font-weight: var(--_sds-textfield-font-weight);
3390
+ font-family: var(--_sds-textfield-font-family);
3391
+ min-height: var(--_sds-textfield-min-height);
3392
+ border-radius: var(--_sds-textfield-border-radius);
3393
+ border: var(--_sds-textfield-border-width) solid var(--_sds-textfield-border-color);
3394
+ background: var(--_sds-textfield-background-color);
3395
+ cursor: var(--_sds-textfield-cursor);
3396
+ width: 100%;
3397
+
3398
+ &:hover {
3399
+ --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-border-strong, var(--sds-color-neutral-border-strong)));
3400
+ }
3401
+
3402
+ &:focus-visible {
3403
+ box-shadow: 0 0 0 var(--_sds-textfield-focus-spacing) var(--_sds-textfield-focus-inner-color);
3404
+ outline: var(--_sds-textfield-focus-outline-size) solid var(--_sds-textfield-focus-color);
3405
+ outline-offset: var(--_sds-textfield-focus-spacing);
3406
+ }
3407
+ }
3408
+
3409
+ .sds-textfield__label {
3410
+ color: var(--_sds-textfield-text-color);
3411
+ font-size: var(--_sds-textfield-label-font-size);
3412
+ font-weight: var(--_sds-textfield-label-font-weight);
3413
+ line-height: var(--_sds-textfield-label-line-height);
3414
+ }
3415
+
3416
+ .sds-textfield__label:has(sds-icon) {
3417
+ display: flex;
3418
+ flex-direction: row;
3419
+ align-items: center;
3420
+ gap: var(--_sds-textfield-gap);
3421
+ }
3422
+
3423
+ /* Visually hidden, but still the input's accessible name. Taking the label out of
3424
+ the flex flow also drops the gap above the input. */
3425
+ .sds-textfield__label--hidden {
3426
+ clip-path: inset(50%);
3427
+ height: 1px;
3428
+ overflow: hidden;
3429
+ position: absolute;
3430
+ white-space: nowrap;
3431
+ width: 1px;
3432
+ }
3433
+
3434
+ .sds-textfield__help-text {
3435
+ display: block;
3436
+ color: var(--_sds-textfield-helptext-text-color);
3437
+ font-size: var(--_sds-textfield-helptext-font-size);
3438
+ font-weight: var(--_sds-textfield-helptext-font-weight);
3439
+ line-height: var(--_sds-textfield-helptext-line-height);
3440
+ margin: 0;
3441
+ }
3442
+ }
3443
+
3444
+ .sds-textfield--error {
3445
+ --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-alert-danger-border-default));
3446
+
3447
+ & .sds-textfield__input:hover,
3448
+ & .sds-textfield__input:hover {
3449
+ --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-alert-danger-border-default));
3450
+ }
3451
+ }
3452
+
3453
+ :host([readonly]) {
3454
+ --_sds-textfield-background-color: var(--sds-textfield-background-color, var(--sds-color-surface-tinted, var(--sds-color-neutral-surface-tinted)));
3455
+ --_sds-textfield-cursor: var(--sds-textfield-cursor, default);
3456
+ }
3457
+
3458
+ :host(:disabled) {
3459
+ opacity: var(--_sds-textfield-disabled-opacity);
3460
+ pointer-events: none;
3461
+ }
3462
+
3463
+ .sds-textfield--has-icon {
3464
+ .sds-textfield__input {
3465
+ padding-right: var(--_sds-textfield-padding-icon);
3466
+ }
3467
+ }
3468
+
3469
+ ::slotted([slot='after']) {
3470
+ position: absolute;
3471
+ top: var(--_sds-textfield-icon-top);
3472
+ right: var(--_sds-textfield-icon-right);
3473
+ pointer-events: none;
3474
+ }
3475
+
3476
+ :host([size='sm']) {
3477
+ --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-sm));
3478
+ --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-sm));
3479
+ --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-sm));
3480
+ --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-sm));
3481
+ --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-sm));
3482
+ --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-sm));
3483
+ --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-sm));
3484
+ --_sds-textfield-icon-top: var(--sds-textfield-icon-top, calc((var(--_sds-textfield-min-height) - var(--sds-components-icon-sm)) / 2));
3485
+ --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-sm)));
3486
+
3487
+ &:has(sds-icon:not([size])) {
3488
+ --sds-icon-size: var(--sds-textfield-icon-size, var(--sds-components-icon-sm));
3489
+ }
3490
+ }
3491
+
3492
+ :host([size='lg']) {
3493
+ --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-lg));
3494
+ --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-lg));
3495
+ --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-lg));
3496
+ --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-lg));
3497
+ --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-lg));
3498
+ --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-lg));
3499
+ --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-lg));
3500
+ --_sds-textfield-icon-top: var(--sds-textfield-icon-top, var(--sds-spacing-3xs));
3501
+ --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-lg)));
3502
+
3503
+ &:has(sds-icon:not([size])) {
3504
+ --sds-icon-size: var(--sds-textfield-icon-size, var(--sds-components-icon-lg));
3505
+ }
3506
+ }
3507
+ `;var Vo=Object.defineProperty,Bo=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Vo(e,s,a),a};const Io=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.type="text",this.hideLabel=!1,this.required=!1,this.size="md",this.hasIcon=!1,this._hasSlottedLabel=!1,this._defaultValue=null,this.handleSlotChange=t=>{const e=t.target;this.hasIcon=e.assignedNodes({flatten:!0}).length>0},this._handleLabelSlotChange=t=>{const e=t.currentTarget;this._hasSlottedLabel=e.assignedNodes({flatten:!0}).some(t=>t.nodeType===Node.ELEMENT_NODE||Boolean(t.textContent?.trim()))},this._handleInputChange=t=>{t.stopImmediatePropagation(),!this.disabled&&t.target instanceof HTMLInputElement&&(this.value=t.target.value,this.internals.setFormValue(""===this.value?null:this.value),this.updateValidity(),this.dispatchSheriffEvent(t.type))},this._handleSelect=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("select")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleKeyDown=t=>{t.stopImmediatePropagation();if(this.dispatchKeyboardEvent("keydown",t)&&"Enter"===t.key){for(const t of Array.from(this.form?.elements??[]))if(t instanceof HTMLButtonElement||t instanceof HTMLInputElement){if("submit"!==t.type)continue;if(t.disabled)return;return void t.click()}this.form?.requestSubmit()}}}connectedCallback(){super.connectedCallback(),this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue)}updated(t){super.updated(t),t.has("value")&&(this.internals.setFormValue(this.value??""),this.control&&this.control.value!==(this.value??"")&&(this.control.value=this.value??""))}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}formResetCallback(){this.internals.setFormValue(this._defaultValue);const t=this._defaultValue??"";this.control.value=t,this.value=t,this.updateValidity()}select(){this.disabled||this.control.select()}get selectionStart(){return this.control?this.control.selectionStart:null}set selectionStart(t){this.control&&null!==t&&(this.control.selectionStart=t)}get selectionEnd(){return this.control?this.control.selectionEnd:null}set selectionEnd(t){this.control&&null!==t&&(this.control.selectionEnd=t)}setSelectionRange(t,e,s){this.control&&this.control.setSelectionRange(t,e,s)}checkValidity(){return this.control.checkValidity()}reportValidity(){return this.control.reportValidity()}setCustomValidity(t){this.control.setCustomValidity(t),this.updateValidity()}render(){const t={"sds-textfield":!0,"sds-textfield--error":Boolean(this.errorMessage),"sds-textfield--has-icon":this.hasIcon},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0,s=this._hasSlottedLabel||Boolean(this.label),o={"sds-textfield__label":!0,"sds-textfield__label--hidden":Boolean(this.hideLabel)};return J`
3508
+ <div class="${se(t)}">
3509
+ <label for="sds-textfield" class="${se(o)}" ?hidden="${!s}">
3510
+ ${this.readOnly?J`<sds-icon name="lock-material-filled" size="m"></sds-icon>`:st}
3511
+ <slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
3512
+ </label>
3513
+ ${this.helpText?J`<p id="help-text" class="sds-textfield__help-text">${this.helpText}</p>`:st}
3514
+ <div class="sds-textfield__input-container">
3515
+ <input
3516
+ part="input"
3517
+ class="sds-textfield__input"
3518
+ type="${qt(this.type)}"
3519
+ id="sds-textfield"
3520
+ ?disabled="${this.disabled}"
3521
+ ?readonly="${this.readOnly}"
3522
+ placeholder="${qt(this.placeholder)}"
3523
+ .value="${qo(this.value??"")}"
3524
+ name="${qt(this.name)}"
3525
+ autocomplete="${qt(this.autocomplete)}"
3526
+ ?required="${this.required}"
3527
+ pattern="${qt(this.pattern)}"
3528
+ min="${qt(this.min)}"
3529
+ minlength="${qt(this.minlength)}"
3530
+ max="${qt(this.max)}"
3531
+ maxlength="${qt(this.maxlength)}"
3532
+ aria-describedby="${qt(e)}"
3533
+ aria-invalid="${this.errorMessage?"true":"false"}"
3534
+ @input="${this._handleInputChange}"
3535
+ @change="${this._handleInputChange}"
3536
+ @select="${this._handleSelect}"
3537
+ @focus="${this._handleFocus}"
3538
+ @blur="${this._handleBlur}"
3539
+ @keydown="${this._handleKeyDown}"
3540
+ />
3541
+ <slot name="after" @slotchange="${this.handleSlotChange}" aria-hidden="true"></slot>
3542
+ </div>
3543
+ ${this.errorMessage?J`<sds-alert id="error-message" variant="secondary" data-palette="danger"><p slot="message">${this.errorMessage}</p></sds-alert>`:st}
3544
+ </div>
3545
+ `}};Io.styles=[Mo];let Ro=Io;Bo([S({type:String,reflect:!0})],Ro.prototype,"type"),Bo([S({type:String})],Ro.prototype,"value"),Bo([S({type:String,reflect:!0})],Ro.prototype,"label"),Bo([S({type:Boolean,attribute:"hide-label",reflect:!0})],Ro.prototype,"hideLabel"),Bo([S({type:String,reflect:!0})],Ro.prototype,"placeholder"),Bo([S({type:String,attribute:"help-text",reflect:!0})],Ro.prototype,"helpText"),Bo([S({type:String,attribute:"error-message",reflect:!0})],Ro.prototype,"errorMessage"),Bo([S({type:String,reflect:!0})],Ro.prototype,"autocomplete"),Bo([S({type:Boolean,reflect:!0})],Ro.prototype,"required"),Bo([S({type:String,reflect:!0})],Ro.prototype,"pattern"),Bo([S({type:Number,reflect:!0})],Ro.prototype,"minlength"),Bo([S({type:Number,reflect:!0})],Ro.prototype,"maxlength"),Bo([S({type:String,reflect:!0})],Ro.prototype,"min"),Bo([S({type:String,reflect:!0})],Ro.prototype,"max"),Bo([S({type:String,reflect:!0})],Ro.prototype,"size"),Bo([C()],Ro.prototype,"hasIcon"),Bo([C()],Ro.prototype,"_hasSlottedLabel"),Bo([L("#sds-textfield")],Ro.prototype,"control");var jo=Object.getOwnPropertyDescriptor;let Fo=class extends Ro{};Fo=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?jo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-textfield")],Fo);var No=Object.defineProperty,Uo=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&No(e,s,a),a};const Ho=class extends(Lt(de(mt))){constructor(){super(),this.value="",this.hideLabel=!1,this.size="md",this.buttonLabel="Søk",this.buttonVariant="primary",this.required=!1,this._defaultValue="",this._customValidityMessage="",this._handleFocusIn=t=>{this._isOwnNode(t.relatedTarget)||this.dispatchEvent(new FocusEvent("focus",{composed:!0,relatedTarget:t.relatedTarget}))},this._handleFocusOut=t=>{this._isOwnNode(t.relatedTarget)||this.dispatchEvent(new FocusEvent("blur",{composed:!0,relatedTarget:t.relatedTarget}))},this._stopChildEvent=t=>{t.stopImmediatePropagation()},this._reemitChildEvent=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent(t.type)},this._handleInput=t=>{t.stopImmediatePropagation();const e=t.target;e&&"value"in e&&"string"==typeof e.value?this.value=e.value:this.value="",this.updateValidity(),this.dispatchSheriffEvent("input")},this._handleButtonClick=()=>{this._submit()},this._handleKeydown=t=>{t.stopImmediatePropagation(),this.dispatchKeyboardEvent("keydown",t)?"Enter"!==t.key||t.isComposing||(t.preventDefault(),this._submit()):t.preventDefault()},this.addEventListener("focusin",this._handleFocusIn),this.addEventListener("focusout",this._handleFocusOut)}connectedCallback(){super.connectedCallback(),this._defaultValue=this.value,this.internals.setFormValue(this.value);const t=new ResizeObserver(()=>this._alignButtonToInput());this._resizeObserver=t,this.updateComplete.then(()=>{this._resizeObserver===t&&this._field&&t.observe(this._field)})}disconnectedCallback(){super.disconnectedCallback(),this._resizeObserver?.disconnect(),this._resizeObserver=void 0}updated(t){super.updated(t),t.has("value")&&this.internals.setFormValue(this.value),this._field?.updateComplete.then(()=>this.updateValidity());1===t.size&&t.has("value")||this._alignButtonToInput()}updateValidity(){const t=this._field,e=t?.control;t&&e&&(t.setCustomValidity(this._customValidityMessage),this.internals.setValidity(e.validity,e.validationMessage,e))}get validity(){return this.internals.validity}get validationMessage(){return this.internals.validationMessage}get willValidate(){return this.internals.willValidate}checkValidity(){return this.internals.checkValidity()}reportValidity(){return this.internals.reportValidity()}setCustomValidity(t){this._customValidityMessage=t,this.updateValidity()}select(){this._field?.select()}get selectionStart(){return this._field?.selectionStart??null}set selectionStart(t){this._field&&(this._field.selectionStart=t)}get selectionEnd(){return this._field?.selectionEnd??null}set selectionEnd(t){this._field&&(this._field.selectionEnd=t)}setSelectionRange(t,e,s){this._field?.setSelectionRange(t,e,s)}formResetCallback(){this.value=this._defaultValue}formStateRestoreCallback(t){"string"==typeof t&&(this.value=t)}async _alignButtonToInput(){const t=this._field,e=this._buttonCol;if(!t||!e)return;await t.updateComplete;const s=t.control;if(!s)return;const o=s.getBoundingClientRect().top-t.getBoundingClientRect().top;e.style.marginBlockStart=o>0?`${o}px`:""}_submit(){if(this.disabled)return;if(!this.form?.noValidate&&!this.reportValidity())return;this.dispatchSheriffEvent("search",{value:this.value})&&this.form?.requestSubmit()}_isOwnNode(t){return t instanceof Node&&(t===this||this.contains(t)||Boolean(this.shadowRoot?.contains(t)))}_renderField(){return J`
3546
+ <sds-textfield
3547
+ class="sds-search__field"
3548
+ type="search"
3549
+ size="${this.size??"md"}"
3550
+ .value="${this.value}"
3551
+ ?hide-label="${this.hideLabel}"
3552
+ placeholder="${qt(this.placeholder)}"
3553
+ help-text="${qt(this.helpText)}"
3554
+ error-message="${qt(this.errorMessage)}"
3555
+ ?disabled="${this.disabled}"
3556
+ ?readonly="${this.readOnly}"
3557
+ autocomplete="${qt(this.autocomplete)}"
3558
+ ?required="${this.required}"
3559
+ minlength="${qt(this.minlength)}"
3560
+ maxlength="${qt(this.maxlength)}"
3561
+ pattern="${qt(this.pattern)}"
3562
+ @input="${this._handleInput}"
3563
+ @change="${this._reemitChildEvent}"
3564
+ @select="${this._reemitChildEvent}"
3565
+ @keydown="${this._handleKeydown}"
3566
+ @focus="${this._stopChildEvent}"
3567
+ @blur="${this._stopChildEvent}"
3568
+ >
3569
+ <slot name="label" slot="label">${this.label}</slot>
3570
+ </sds-textfield>
3571
+ `}_renderButtonColumn(){return J`
3572
+ <div class="sds-search__button-col">
3573
+ <slot name="button">
3574
+ <sds-button
3575
+ class="sds-search__button"
3576
+ icon
3577
+ type="button"
3578
+ size="${this.size??"md"}"
3579
+ variant="${this.buttonVariant}"
3580
+ label="${this.buttonLabel}"
3581
+ ?disabled="${this.disabled}"
3582
+ @click="${this._handleButtonClick}"
3583
+ @focus="${this._stopChildEvent}"
3584
+ @blur="${this._stopChildEvent}"
3585
+ >
3586
+ <sds-icon name="search-material-outlined" size="${this.size}"></sds-icon>
3587
+ </sds-button>
3588
+ </slot>
3589
+ </div>
3590
+ `}render(){return J`<div class="sds-search">${this._renderField()} ${this._renderButtonColumn()}</div>`}};Ho.styles=[Po];let Ko=Ho;Uo([S({type:String})],Ko.prototype,"value"),Uo([S({type:String,reflect:!0})],Ko.prototype,"label"),Uo([S({type:Boolean,attribute:"hide-label",reflect:!0})],Ko.prototype,"hideLabel"),Uo([S({type:String,reflect:!0})],Ko.prototype,"placeholder"),Uo([S({type:String,attribute:"help-text",reflect:!0})],Ko.prototype,"helpText"),Uo([S({type:String,attribute:"error-message",reflect:!0})],Ko.prototype,"errorMessage"),Uo([S({type:String,reflect:!0})],Ko.prototype,"size"),Uo([S({type:String,attribute:"button-label",reflect:!0})],Ko.prototype,"buttonLabel"),Uo([S({type:String,attribute:"button-variant",reflect:!0})],Ko.prototype,"buttonVariant"),Uo([S({type:String,reflect:!0})],Ko.prototype,"autocomplete"),Uo([S({type:Boolean,reflect:!0})],Ko.prototype,"required"),Uo([S({type:Number,reflect:!0})],Ko.prototype,"minlength"),Uo([S({type:Number,reflect:!0})],Ko.prototype,"maxlength"),Uo([S({type:String,reflect:!0})],Ko.prototype,"pattern"),Uo([L(".sds-search__field")],Ko.prototype,"_field"),Uo([L(".sds-search__button-col")],Ko.prototype,"_buttonCol");var Go=Object.getOwnPropertyDescriptor;let Wo=class extends Ko{};Wo=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Go(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-search")],Wo);const Zo=d`
3591
+ :host {
3592
+ --_sds-select-background-color: var(--sds-select-background-color, var(--sds-color-background-default, var(--sds-color-neutral-background-default)));
3593
+ --_sds-select-text-color: var(--sds-select-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3594
+
3595
+ --_sds-select-border-color: var(--sds-select-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
3596
+ --_sds-select-border-width: var(--sds-select-border-width, var(--sds-border-sm));
3597
+ --_sds-select-border-radius: var(--sds-select-border-radius, var(--sds-radius-sm));
3598
+
3599
+ --_sds-select-font-family: var(--sds-select-font-family, var(--sds-typography-font-family-roboto));
3600
+ --_sds-select-font-size: var(--sds-select-font-size, var(--sds-components-font-size-content-md));
3601
+ --_sds-select-font-weight: var(--sds-select-font-weight, var(--sds-typography-font-weight-regular));
3602
+ --_sds-select-line-height: var(--sds-select-line-height, var(--sds-components-line-height-squeezed-md));
3603
+ --_sds-select-min-height: var(--sds-select-height, var(--sds-components-button-md));
3604
+
3605
+ --_sds-select-gap: var(--sds-select-gap, var(--sds-spacing-3xs));
3606
+ --_sds-select-padding-block: var(--sds-select-padding-block, 0);
3607
+ --_sds-select-padding-inline: var(--sds-select-padding-inline, var(--sds-spacing-xs));
3608
+ --_sds-select-padding-icon-inline-end: var(--sds-spacing-lg);
3609
+
3610
+ --_sds-select-disabled-opacity: var(--sds-select-disabled-opacity, var(--sds-color-states-disabled-opacity));
3611
+ --_sds-select-max-width: var(--sds-select-max-width, var(--sds-typography-max-line-width, 60ch));
3612
+ --_sds-select-width: var(--sds-select-width, fit-content);
3613
+
3614
+ --_sds-select-label-text-color: var(--sds-select-label-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
2684
3615
  --_sds-select-label-font-size: var(--sds-select-label-font-size, var(--sds-components-font-size-content-md));
2685
3616
  --_sds-select-label-font-weight: var(--sds-select-label-font-weight, var(--sds-typography-font-weight-medium));
2686
3617
  --_sds-select-label-line-height: var(--sds-select-label-line-height, var(--sds-components-line-height-squeezed-md));
@@ -2827,8 +3758,8 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2827
3758
  --_sds-select-helptext-line-height: var(--sds-select-helptext-line-height, var(--sds-components-line-height-squeezed-lg));
2828
3759
  --_sds-select-icon-background-size: var(--sds-select-icon-background-size, var(--sds-components-icon-lg));
2829
3760
  }
2830
- `;var po=Object.defineProperty,go=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&po(e,s,a),a};const vo=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._defaultValue=null,this._pendingLightDomSync=!1,this._handleSlotChange=()=>{if(null==this.value){const t=this.getLightDomSelectedValue();null!=t&&(this.value=t)}this._scheduleLightDomSync()},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0},this._handleChange=t=>{t.stopImmediatePropagation(),t.target instanceof HTMLSelectElement&&(this.disabled||this.readOnly?t.target.value=this.value??"":(this.value=t.target.value,this._setFormValue(this.value),this.updateValidity(),this.dispatchSheriffEvent("input"),this.dispatchSheriffEvent("change")))},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleKeyDown=t=>{if(!this.readOnly)return;if(t.altKey||t.ctrlKey||t.shiftKey||t.metaKey)return;/* @__PURE__ */new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Home","End","PageUp","PageDown"," ","Enter"]).has(t.key)&&(t.preventDefault(),t.stopImmediatePropagation())}}connectedCallback(){if(super.connectedCallback(),null==this.value){const t=Array.from(this.querySelectorAll("option")).find(t=>t.hasAttribute("selected")||t.defaultSelected);t&&(this.value=t.value)}this._startObservingLightDom()}disconnectedCallback(){this._stopObservingLightDom(),super.disconnectedCallback()}firstUpdated(){const t=this.control?.value??"";this.value=this.value??this.defaultValue??t,this.control.value=this.value??"",this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue),this.updateValidity()}updated(t){super.updated(t),this.control&&t.has("value")&&(this.control.value=this.value??"",this._setFormValue(this.value),this.updateValidity())}_setFormValue(t){this.internals.setFormValue(null==t?null:t)}_scheduleLightDomSync(){this._pendingLightDomSync||(this._pendingLightDomSync=!0,queueMicrotask(()=>{this._pendingLightDomSync=!1;const t=this.getLightDomSelectedValue();void 0!==t&&t!==this.value&&(this.value=t),this.requestUpdate(),this.updateComplete.then(()=>{this.control&&(this.control.value=this.value??"",this._setFormValue(this.value),this.updateValidity())})}))}_startObservingLightDom(){this._lightDomObserver||(this._lightDomObserver=new MutationObserver(t=>{for(const e of t){if("childList"===e.type)return void this._scheduleLightDomSync();if("characterData"===e.type)return void this._scheduleLightDomSync();if("attributes"===e.type){const t=e.target;if(!(t instanceof HTMLElement))continue;const s=t.tagName;if("OPTION"===s||"OPTGROUP"===s||"HR"===s)return void this._scheduleLightDomSync()}}}),this._lightDomObserver.observe(this,{subtree:!0,childList:!0,attributes:!0,characterData:!0}))}_stopObservingLightDom(){this._lightDomObserver?.disconnect(),this._lightDomObserver=void 0,this._pendingLightDomSync=!1}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}getLightDomSelectedValue(){const t=Array.from(this.querySelectorAll("option")).find(t=>t.hasAttribute("selected")||t.defaultSelected);return t?.value}formResetCallback(){this.internals.setFormValue(this._defaultValue);const t=this._defaultValue??"";this.control&&(this.control.value=t),this.value=this._defaultValue??"",this.updateValidity()}renderFromLightDom(){const t=this.children??[];return Array.from(t).filter(t=>t instanceof HTMLElement).map(t=>{switch(t.tagName){case"OPTION":return this.renderOption(t);case"OPTGROUP":return this.renderOptgroup(t);case"HR":return J`<hr />`;default:return st}})}renderOption(t){const e=t.getAttribute("value"),s=t.value,o=null!=this.value&&s===this.value;return J` <option value=${qt(null===e?void 0:e)} ?disabled=${t.disabled} .selected=${o}>${t.text}</option> `}renderOptgroup(t){const e=Array.from(t.querySelectorAll("option"));return J` <optgroup label=${qt(t.label||void 0)} ?disabled=${t.disabled}>${e.map(t=>this.renderOption(t))}</optgroup> `}render(){const t={"sds-select":!0,"sds-select--error":Boolean(this.errorMessage)},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0,s=this._hasSlottedLabel||Boolean(this.label);return J`
2831
- <div class="${te(t)}">
3761
+ `;var Yo=Object.defineProperty,Qo=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Yo(e,s,a),a};const Xo=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._defaultValue=null,this._pendingLightDomSync=!1,this._handleSlotChange=()=>{if(null==this.value){const t=this.getLightDomSelectedValue();null!=t&&(this.value=t)}this._scheduleLightDomSync()},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0},this._handleChange=t=>{t.stopImmediatePropagation(),t.target instanceof HTMLSelectElement&&(this.disabled||this.readOnly?t.target.value=this.value??"":(this.value=t.target.value,this._setFormValue(this.value),this.updateValidity(),this.dispatchSheriffEvent("input"),this.dispatchSheriffEvent("change")))},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleKeyDown=t=>{if(!this.readOnly)return;if(t.altKey||t.ctrlKey||t.shiftKey||t.metaKey)return;/* @__PURE__ */new Set(["ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Home","End","PageUp","PageDown"," ","Enter"]).has(t.key)&&(t.preventDefault(),t.stopImmediatePropagation())}}connectedCallback(){if(super.connectedCallback(),null==this.value){const t=Array.from(this.querySelectorAll("option")).find(t=>t.hasAttribute("selected")||t.defaultSelected);t&&(this.value=t.value)}this._startObservingLightDom()}disconnectedCallback(){this._stopObservingLightDom(),super.disconnectedCallback()}firstUpdated(){const t=this.control?.value??"";this.value=this.value??this.defaultValue??t,this.control.value=this.value??"",this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue),this.updateValidity()}updated(t){super.updated(t),this.control&&t.has("value")&&(this.control.value=this.value??"",this._setFormValue(this.value),this.updateValidity())}_setFormValue(t){this.internals.setFormValue(null==t?null:t)}_scheduleLightDomSync(){this._pendingLightDomSync||(this._pendingLightDomSync=!0,queueMicrotask(()=>{this._pendingLightDomSync=!1;const t=this.getLightDomSelectedValue();void 0!==t&&t!==this.value&&(this.value=t),this.requestUpdate(),this.updateComplete.then(()=>{this.control&&(this.control.value=this.value??"",this._setFormValue(this.value),this.updateValidity())})}))}_startObservingLightDom(){this._lightDomObserver||(this._lightDomObserver=new MutationObserver(t=>{for(const e of t){if("childList"===e.type)return void this._scheduleLightDomSync();if("characterData"===e.type)return void this._scheduleLightDomSync();if("attributes"===e.type){const t=e.target;if(!(t instanceof HTMLElement))continue;const s=t.tagName;if("OPTION"===s||"OPTGROUP"===s||"HR"===s)return void this._scheduleLightDomSync()}}}),this._lightDomObserver.observe(this,{subtree:!0,childList:!0,attributes:!0,characterData:!0}))}_stopObservingLightDom(){this._lightDomObserver?.disconnect(),this._lightDomObserver=void 0,this._pendingLightDomSync=!1}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}getLightDomSelectedValue(){const t=Array.from(this.querySelectorAll("option")).find(t=>t.hasAttribute("selected")||t.defaultSelected);return t?.value}formResetCallback(){this.internals.setFormValue(this._defaultValue);const t=this._defaultValue??"";this.control&&(this.control.value=t),this.value=this._defaultValue??"",this.updateValidity()}renderFromLightDom(){const t=this.children??[];return Array.from(t).filter(t=>t instanceof HTMLElement).map(t=>{switch(t.tagName){case"OPTION":return this.renderOption(t);case"OPTGROUP":return this.renderOptgroup(t);case"HR":return J`<hr />`;default:return st}})}renderOption(t){const e=t.getAttribute("value"),s=t.value,o=null!=this.value&&s===this.value;return J` <option value=${qt(null===e?void 0:e)} ?disabled=${t.disabled} .selected=${o}>${t.text}</option> `}renderOptgroup(t){const e=Array.from(t.querySelectorAll("option"));return J` <optgroup label=${qt(t.label||void 0)} ?disabled=${t.disabled}>${e.map(t=>this.renderOption(t))}</optgroup> `}render(){const t={"sds-select":!0,"sds-select--error":Boolean(this.errorMessage)},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0,s=this._hasSlottedLabel||Boolean(this.label);return J`
3762
+ <div class="${se(t)}">
2832
3763
  <label for="control" class="sds-select__label" ?hidden="${!s}">
2833
3764
  ${this.readOnly?J`<sds-icon name="lock-material-filled" size="m"></sds-icon>`:st}<slot name="label" @slotchange=${this._handleLabelSlotChange}>${this.label}</slot>
2834
3765
  </label>
@@ -2861,7 +3792,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2861
3792
  </sds-alert>
2862
3793
  `:st}
2863
3794
  </div>
2864
- `}};vo.styles=[ho];let uo=vo;go([S({type:String,reflect:!0})],uo.prototype,"label"),go([S({type:String,attribute:!1})],uo.prototype,"value"),go([S({type:String,attribute:"default-value"})],uo.prototype,"defaultValue"),go([S({type:String,attribute:"help-text",reflect:!0})],uo.prototype,"helpText"),go([S({type:String,attribute:"error-message",reflect:!0})],uo.prototype,"errorMessage"),go([S({type:Boolean,reflect:!0})],uo.prototype,"required"),go([S({type:String,reflect:!0})],uo.prototype,"size"),go([A("#control")],uo.prototype,"control"),go([C()],uo.prototype,"_hasSlottedLabel");var fo=Object.getOwnPropertyDescriptor;let bo=class extends uo{};bo=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?fo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-select")],bo);const _o=d`
3795
+ `}};Xo.styles=[Zo];let Jo=Xo;Qo([S({type:String,reflect:!0})],Jo.prototype,"label"),Qo([S({type:String,attribute:!1})],Jo.prototype,"value"),Qo([S({type:String,attribute:"default-value"})],Jo.prototype,"defaultValue"),Qo([S({type:String,attribute:"help-text",reflect:!0})],Jo.prototype,"helpText"),Qo([S({type:String,attribute:"error-message",reflect:!0})],Jo.prototype,"errorMessage"),Qo([S({type:Boolean,reflect:!0})],Jo.prototype,"required"),Qo([S({type:String,reflect:!0})],Jo.prototype,"size"),Qo([L("#control")],Jo.prototype,"control"),Qo([C()],Jo.prototype,"_hasSlottedLabel");var tr=Object.getOwnPropertyDescriptor;let er=class extends Jo{};er=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?tr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-select")],er);const sr=d`
2865
3796
  :host {
2866
3797
  display: flex;
2867
3798
  flex-direction: row;
@@ -2896,7 +3827,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
2896
3827
 
2897
3828
  --sds-stepper-step-step-gap: 0 var(--sds-spacing-3xs);
2898
3829
  }
2899
- `;var mo=Object.defineProperty,xo=Object.getOwnPropertyDescriptor,yo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?xo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&mo(e,s,a),a};let wo=class extends(At(mt)){constructor(){super(),this.orientation="horizontal",this._setActiveStep=(t,e)=>{t.forEach((t,s)=>{t.active=s===e})},this._handleChildClick=t=>{t.preventDefault(),t.stopImmediatePropagation();const e=t.composedPath().find(t=>t instanceof Element&&"sds-stepper-step"===t.tagName.toLowerCase());if(!e)return;const s=this.steps.indexOf(e);-1!==s&&(this._setActiveStep(this.steps,s),this.dispatchSheriffEvent("change",{index:s}))},this.internals=this.attachInternals(),this.internals.role="tablist"}getActiveStep(){return this.steps.findIndex(t=>t.active)}connectedCallback(){super.connectedCallback(),this.hasAttribute("aria-label")||(this.ariaLabel="Steg")}goToStep(t){t<0||t>=this.steps.length||(this._setActiveStep(this.steps,t),this.dispatchSheriffEvent("change",{index:t}))}_applyStepNumbers(){this.steps.forEach((t,e)=>{t.style.setProperty("--sds-stepper-step-counter-content",`"${e+1}"`)})}firstUpdated(){const t=navigator.userAgent;if(/safari/i.test(t)&&!/chrome/i.test(t)&&!/crios/i.test(t)&&!/edgios/i.test(t)&&!/fxios/i.test(t)){this.shadowRoot.querySelector("slot").addEventListener("slotchange",()=>this._applyStepNumbers()),this._applyStepNumbers()}}render(){return J`<slot @_sds-step-clicked="${this._handleChildClick}"></slot>`}};wo.styles=[_o],yo([S({type:String,reflect:!0})],wo.prototype,"orientation",2),yo([L({selector:"sds-stepper-step",flatten:!0})],wo.prototype,"steps",2),wo=yo([O("sds-stepper")],wo);const ko=d`
3830
+ `;var or=Object.defineProperty,rr=Object.getOwnPropertyDescriptor,ar=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?rr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&or(e,s,a),a};let ir=class extends(Lt(mt)){constructor(){super(),this.orientation="horizontal",this._setActiveStep=(t,e)=>{t.forEach((t,s)=>{t.active=s===e})},this._handleChildClick=t=>{t.preventDefault(),t.stopImmediatePropagation();const e=t.composedPath().find(t=>t instanceof Element&&"sds-stepper-step"===t.tagName.toLowerCase());if(!e)return;const s=this.steps.indexOf(e);-1!==s&&(this._setActiveStep(this.steps,s),this.dispatchSheriffEvent("change",{index:s}))},this.internals=this.attachInternals(),this.internals.role="tablist"}getActiveStep(){return this.steps.findIndex(t=>t.active)}connectedCallback(){super.connectedCallback(),this.hasAttribute("aria-label")||(this.ariaLabel="Steg")}goToStep(t){t<0||t>=this.steps.length||(this._setActiveStep(this.steps,t),this.dispatchSheriffEvent("change",{index:t}))}_applyStepNumbers(){this.steps.forEach((t,e)=>{t.style.setProperty("--sds-stepper-step-counter-content",`"${e+1}"`)})}firstUpdated(){const t=navigator.userAgent;if(/safari/i.test(t)&&!/chrome/i.test(t)&&!/crios/i.test(t)&&!/edgios/i.test(t)&&!/fxios/i.test(t)){this.shadowRoot.querySelector("slot").addEventListener("slotchange",()=>this._applyStepNumbers()),this._applyStepNumbers()}}render(){return J`<slot @_sds-step-clicked="${this._handleChildClick}"></slot>`}};ir.styles=[sr],ar([S({type:String,reflect:!0})],ir.prototype,"orientation",2),ar([O({selector:"sds-stepper-step",flatten:!0})],ir.prototype,"steps",2),ir=ar([A("sds-stepper")],ir);const dr=d`
2900
3831
  :host {
2901
3832
  /* Sizing */
2902
3833
  --_sds-stepper-step-circle-size: var(--sds-stepper-circle-size, 28px);
@@ -3157,7 +4088,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3157
4088
  --_sds-stepper-step-counter-border-color: var(--sds-stepper-step-counter-border-color, var(--sds-color-neutral-border-strong));
3158
4089
  --_sds-stepper-step-counter-text-color: var(--sds-stepper-step-counter-text-color, var(--sds-color-neutral-text-default));
3159
4090
  }
3160
- `;var zo=Object.defineProperty,$o=Object.getOwnPropertyDescriptor,So=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?$o(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&zo(e,s,a),a};let Co=class extends(At(mt)){constructor(){super(),this.complete=!1,this.interactive=!1,this.active=!1,this._handleClick=t=>{t.preventDefault(),t.stopImmediatePropagation(),this.dispatchSheriffEvent("_sds-step-clicked")},this._renderNonInteractiveStep=()=>J`<div class="sds-stepper-step__step--static">
4091
+ `;var nr=Object.defineProperty,lr=Object.getOwnPropertyDescriptor,cr=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?lr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&nr(e,s,a),a};let hr=class extends(Lt(mt)){constructor(){super(),this.complete=!1,this.interactive=!1,this.active=!1,this._handleClick=t=>{t.preventDefault(),t.stopImmediatePropagation(),this.dispatchSheriffEvent("_sds-step-clicked")},this._renderNonInteractiveStep=()=>J`<div class="sds-stepper-step__step--static">
3161
4092
  <span class="sds-stepper-step__counter"></span>
3162
4093
  <div class="sds-stepper-step__label"><slot></slot></div>
3163
4094
  </div>`,this._renderInteractiveStep=()=>J`<button type="button" role="tab" aria-selected="${this.active?"true":"false"}" id="button" class="sds-stepper-step__step" @click="${this._handleClick}">
@@ -3171,7 +4102,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3171
4102
  <span class="sds-stepper-step__divider sds-stepper-step__divider--before"></span>
3172
4103
  ${this._renderNonInteractiveStep()}
3173
4104
  <span class="sds-stepper-step__divider sds-stepper-step__divider--after"></span>
3174
- </div>`}};Co.styles=[ko],Co.shadowRootOptions={...mt.shadowRootOptions,delegatesFocus:!0},So([S({type:Boolean,reflect:!0})],Co.prototype,"complete",2),So([S({type:Boolean,reflect:!0})],Co.prototype,"interactive",2),So([S({type:Boolean,reflect:!0})],Co.prototype,"active",2),Co=So([O("sds-stepper-step")],Co);const Eo=d`
4105
+ </div>`}};hr.styles=[dr],hr.shadowRootOptions={...mt.shadowRootOptions,delegatesFocus:!0},cr([S({type:Boolean,reflect:!0})],hr.prototype,"complete",2),cr([S({type:Boolean,reflect:!0})],hr.prototype,"interactive",2),cr([S({type:Boolean,reflect:!0})],hr.prototype,"active",2),hr=cr([A("sds-stepper-step")],hr);const pr=d`
3175
4106
  :host {
3176
4107
  --_sds-switch-background-color: var(--sds-switch-background-color, var(--sds-color-surface-default, var(--sds-color-neutral-surface-default)));
3177
4108
  --_sds-switch-text-color: var(--sds-switch-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
@@ -3321,7 +4252,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3321
4252
  .sds-switch__input:checked::before {
3322
4253
  --_sds-switch-button-position: calc(var(--_sds-switch-width) - var(--_sds-switch-button-size) - var(--_sds-switch-button-gap) - var(--_sds-switch-border-width));
3323
4254
  }
3324
- `;var Ao=Object.defineProperty,Lo=Object.getOwnPropertyDescriptor,Oo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Lo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Ao(e,s,a),a};let Po=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.label="",this.hideLabel=!1,this.reverse=!1,this.checked=!1,this.size="md",this._hasSlottedLabel=!1,this._initialChecked=!1,this._handleChange=t=>{if(t.stopImmediatePropagation(),this.disabled||this.readOnly)return t.target.checked=this.checked,void t.preventDefault();const e=t.target;this.checked=e.checked,this.internals.setFormValue(this.checked?"on":"off"),this.dispatchSheriffEvent("change")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("blur")},this.getIconSize=()=>{switch(this.size){case"sm":case"md":case"lg":return this.size;case"l":return"lg";case"s":return"sm"}},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked,this.internals.setFormValue(this.checked?"on":"off")}updated(t){super.updated(t),t.has("checked")&&(this.control.checked=this.checked,this.internals.setFormValue(this.checked?"on":"off"))}formResetCallback(){this.checked=this._initialChecked,this.control.checked=this._initialChecked,this.internals.setFormValue(this._initialChecked?"on":"off")}formStateRestoreCallback(t){this.checked=t}get value(){return this.checked?"on":"off"}get type(){return"checkbox"}render(){const t={"sds-switch__label":!0,"sds-switch__label--hidden":this.hideLabel},e=J`<input
4255
+ `;var gr=Object.defineProperty,vr=Object.getOwnPropertyDescriptor,ur=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?vr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&gr(e,s,a),a};let fr=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.label="",this.hideLabel=!1,this.reverse=!1,this.checked=!1,this.size="md",this._hasSlottedLabel=!1,this._initialChecked=!1,this._handleChange=t=>{if(t.stopImmediatePropagation(),this.disabled||this.readOnly)return t.target.checked=this.checked,void t.preventDefault();const e=t.target;this.checked=e.checked,this.internals.setFormValue(this.checked?"on":"off"),this.dispatchSheriffEvent("change")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("blur")},this.getIconSize=()=>{switch(this.size){case"sm":case"md":case"lg":return this.size;case"l":return"lg";case"s":return"sm"}},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}connectedCallback(){super.connectedCallback(),this._initialChecked=this.checked,this.internals.setFormValue(this.checked?"on":"off")}updated(t){super.updated(t),t.has("checked")&&(this.control.checked=this.checked,this.internals.setFormValue(this.checked?"on":"off"))}formResetCallback(){this.checked=this._initialChecked,this.control.checked=this._initialChecked,this.internals.setFormValue(this._initialChecked?"on":"off")}formStateRestoreCallback(t){this.checked=t}get value(){return this.checked?"on":"off"}get type(){return"checkbox"}render(){const t={"sds-switch__label":!0,"sds-switch__label--hidden":this.hideLabel},e=J`<input
3325
4256
  class="sds-switch__input"
3326
4257
  id="control"
3327
4258
  type="checkbox"
@@ -3334,9 +4265,9 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3334
4265
  @change="${this._handleChange}"
3335
4266
  @focus="${this._handleFocus}"
3336
4267
  @blur="${this._handleBlur}"
3337
- />`,s=this.readOnly?J`<sds-icon name="lock-material-filled" size="${this.getIconSize()}"></sds-icon>`:st,o=this._hasSlottedLabel||Boolean(this.label),r=J`<label class="${te(t)}" for="control" ?hidden="${!o}">
4268
+ />`,s=this.readOnly?J`<sds-icon name="lock-material-filled" size="${this.getIconSize()}"></sds-icon>`:st,o=this._hasSlottedLabel||Boolean(this.label),r=J`<label class="${se(t)}" for="control" ?hidden="${!o}">
3338
4269
  ${s}<slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
3339
- </label>`;return J`<div class="${te({"sds-switch":!0})}">${this.reverse?[r,e]:[e,r]}</div>`}};Po.styles=[Eo],Oo([S({type:String,reflect:!0})],Po.prototype,"label",2),Oo([S({type:Boolean,reflect:!0,attribute:"hide-label"})],Po.prototype,"hideLabel",2),Oo([S({type:Boolean,reflect:!0})],Po.prototype,"reverse",2),Oo([S({type:Boolean,reflect:!0})],Po.prototype,"checked",2),Oo([S({type:String,reflect:!0})],Po.prototype,"size",2),Oo([A("#control")],Po.prototype,"control",2),Oo([C()],Po.prototype,"_hasSlottedLabel",2),Po=Oo([O("sds-switch")],Po);const Do=d`
4270
+ </label>`;return J`<div class="${se({"sds-switch":!0})}">${this.reverse?[r,e]:[e,r]}</div>`}};fr.styles=[pr],ur([S({type:String,reflect:!0})],fr.prototype,"label",2),ur([S({type:Boolean,reflect:!0,attribute:"hide-label"})],fr.prototype,"hideLabel",2),ur([S({type:Boolean,reflect:!0})],fr.prototype,"reverse",2),ur([S({type:Boolean,reflect:!0})],fr.prototype,"checked",2),ur([S({type:String,reflect:!0})],fr.prototype,"size",2),ur([L("#control")],fr.prototype,"control",2),ur([C()],fr.prototype,"_hasSlottedLabel",2),fr=ur([A("sds-switch")],fr);const br=d`
3340
4271
  :host {
3341
4272
  --_sds-tag-background-color: var(--sds-tag-background-color, var(--sds-color-surface-tinted, var(--sds-color-neutral-surface-tinted)));
3342
4273
  --_sds-tag-text-color: var(--sds-tag-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
@@ -3397,9 +4328,9 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3397
4328
  --_sds-tag-font-size: var(--sds-tag-font-size, var(--sds-components-font-size-content-lg));
3398
4329
  --_sds-tag-line-height: var(--sds-tag-line-height, var(--sds-components-line-height-squeezed-lg));
3399
4330
  }
3400
- `;var To=Object.defineProperty,qo=Object.getOwnPropertyDescriptor,Mo=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?qo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&To(e,s,a),a};let Vo=class extends mt{constructor(){super(...arguments),this.size="md"}render(){return J`<span class="${te({"sds-tag":!0})}">
4331
+ `;var _r=Object.defineProperty,mr=Object.getOwnPropertyDescriptor,xr=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?mr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&_r(e,s,a),a};let yr=class extends mt{constructor(){super(...arguments),this.size="md"}render(){return J`<span class="${se({"sds-tag":!0})}">
3401
4332
  <slot></slot>
3402
- </span>`}};Vo.styles=[Do],Mo([S({type:String,reflect:!0})],Vo.prototype,"size",2),Vo=Mo([O("sds-tag")],Vo);const Bo=d`
4333
+ </span>`}};yr.styles=[br],xr([S({type:String,reflect:!0})],yr.prototype,"size",2),yr=xr([A("sds-tag")],yr);const wr=d`
3403
4334
  ${i('[data-tooltip]{--ds-tooltip:"";--_ds-data-tooltip:var(--ds-tooltip)}:host{--_ds-floating:top;--_ds-floating-arrow-size:0;--_ds-floating-arrow-visibility:inherit;animation:ds-fade-in .15s ease-in-out forwards;inset:0 auto auto 0;margin:0;overflow:visible;position:absolute}:host:before{background:inherit;border:inherit;border-left-color:transparent;border-top-color:transparent;box-sizing:border-box;content:"";height:var(--_ds-floating-arrow-size);left:var(--_ds-floating-arrow-x,50%);position:absolute;rotate:45deg;top:var(--_ds-floating-arrow-y,100%);translate:-50% -50%;visibility:var(--_ds-floating-arrow-visibility);width:var(--_ds-floating-arrow-size)}:host[data-overscroll=contain]{--_ds-floating-overscroll:contain;overscroll-behavior:contain;overflow:auto}:host{&[data-floating|=top]:before{top:100%;rotate:45deg}&[data-floating|=right]:before{left:0;rotate:135deg}&[data-floating|=bottom]:before{top:0;rotate:-135deg}&[data-floating|=left]:before{left:100%;rotate:-45deg}--_ds-floating:var(--dsc-tooltip-placement);--_ds-floating-arrow-size:var(--dsc-tooltip-arrow-size);--dsc-tooltip-background:var(--ds-color-neutral-text-default);--dsc-tooltip-color:var(--ds-color-neutral-background-default);--dsc-tooltip-border-radius:var(--ds-border-radius-default);--dsc-tooltip-padding:var(--ds-size-1) var(--ds-size-2);--dsc-tooltip-arrow-size:var(--ds-size-2);--dsc-tooltip-transition-duration:0.2s;--dsc-tooltip-transition-delay:150ms;--dsc-tooltip-placement:top;background:var(--dsc-tooltip-background);border-radius:var(--dsc-tooltip-border-radius);border:0;box-sizing:border-box;color:var(--dsc-tooltip-color);line-height:var(--ds-line-height-sm);padding:var(--dsc-tooltip-padding);view-transition-name:ds-tooltip}:host:after{content:"";box-sizing:border-box;height:var(--_dsc-tooltip-safearea-height,0);width:var(--_dsc-tooltip-safearea-width,0);translate:var(--_dsc-tooltip-safearea-translate);position:absolute;left:var(--_ds-floating-arrow-x,50%);top:var(--_ds-floating-arrow-y,100%)}:host[data-floating=bottom]:after,:host[data-floating=top]:after{top:100%;left:0;width:100%;height:var(--dsc-tooltip-arrow-size)}:host[data-floating=left]:after,:host[data-floating=right]:after{top:0;left:100%;width:var(--dsc-tooltip-arrow-size);height:100%}:host[data-floating=bottom]:after{top:calc(var(--dsc-tooltip-arrow-size)*-1)}:host[data-floating=right]:after{left:calc(var(--dsc-tooltip-arrow-size)*-1)}:host:not([popover]){display:none}@media (forced-colors:active){:host{background:CanvasText}}')}
3404
4335
 
3405
4336
  :host {
@@ -3482,7 +4413,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3482
4413
  border: 1px solid CanvasText;
3483
4414
  }
3484
4415
  }
3485
- `;var Ro=Object.defineProperty,jo=Object.getOwnPropertyDescriptor,Io=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?jo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&Ro(e,s,a),a};let No=class extends(At(mt)){constructor(){super(...arguments),this.placement="top",this.triggers=[],this.cleanups=[],this.onSelfMouseEnter=()=>{clearTimeout(this.hoverTimeout)},this.onSelfMouseLeave=()=>this.hide(),this.onKeyDown=t=>{"Escape"===t.key&&this.hide()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","tooltip"),this.setAttribute("popover","manual"),this.setAttribute("aria-hidden","true"),this.dataset.placement=this.placement,this.bindTriggers(),requestAnimationFrame(()=>this.syncTriggerLabels())}updated(t){t.has("placement")&&(this.dataset.placement=this.placement)}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.hoverTimeout),document.removeEventListener("keydown",this.onKeyDown);for(const t of this.cleanups)t();this.cleanups=[],this.triggers=[],this.activeTrigger=void 0}render(){return J`<slot @slotchange=${this.syncTriggerLabels}></slot>`}syncTriggerLabels(){const t=this.textContent?.trim()??"";t&&this.triggers.map(e=>{const s=e.shadowRoot?.querySelector("button, a")??e;this.cleanups.push(()=>s.removeAttribute("aria-label")),s.setAttribute("aria-label",t)})}bindTriggers(){if(this.id){this.triggers=[...document.querySelectorAll("[aria-describedby]")].filter(t=>{const e=t.getAttribute("aria-describedby");return e?.split(/\s+/).includes(this.id)??!1});for(const t of this.triggers){const e=()=>this.show(t),s=()=>this.scheduleHide(),o=()=>this.show(t),r=()=>this.hide();t.addEventListener("mouseenter",e),t.addEventListener("mouseleave",s),t.addEventListener("focusin",o),t.addEventListener("focusout",r),this.cleanups.push(()=>{t.removeEventListener("mouseenter",e),t.removeEventListener("mouseleave",s),t.removeEventListener("focusin",o),t.removeEventListener("focusout",r)})}this.addEventListener("mouseenter",this.onSelfMouseEnter),this.addEventListener("mouseleave",this.onSelfMouseLeave),this.cleanups.push(()=>{this.removeEventListener("mouseenter",this.onSelfMouseEnter),this.removeEventListener("mouseleave",this.onSelfMouseLeave)})}}show(t){clearTimeout(this.hoverTimeout),this.matches(":popover-open")||this.showPopover(),this.activeTrigger!==t&&(this.activeTrigger=t,this.dispatchSheriffEvent("toggle",t)),document.addEventListener("keydown",this.onKeyDown)}hide(){clearTimeout(this.hoverTimeout);try{this.hidePopover()}catch{}this.activeTrigger=void 0,document.removeEventListener("keydown",this.onKeyDown)}scheduleHide(){clearTimeout(this.hoverTimeout),this.hoverTimeout=setTimeout(()=>this.hide(),200)}};No.styles=[Bo],Io([S({type:String,reflect:!0})],No.prototype,"placement",2),No=Io([O("sds-tooltip")],No);const Ho=d`
4416
+ `;var kr=Object.defineProperty,zr=Object.getOwnPropertyDescriptor,$r=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?zr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&kr(e,s,a),a};let Sr=class extends(Lt(mt)){constructor(){super(...arguments),this.placement="top",this.triggers=[],this.cleanups=[],this.onSelfMouseEnter=()=>{clearTimeout(this.hoverTimeout)},this.onSelfMouseLeave=()=>this.hide(),this.onKeyDown=t=>{"Escape"===t.key&&this.hide()}}connectedCallback(){super.connectedCallback(),this.setAttribute("role","tooltip"),this.setAttribute("popover","manual"),this.setAttribute("aria-hidden","true"),this.dataset.placement=this.placement,this.bindTriggers(),requestAnimationFrame(()=>this.syncTriggerLabels())}updated(t){t.has("placement")&&(this.dataset.placement=this.placement)}disconnectedCallback(){super.disconnectedCallback(),clearTimeout(this.hoverTimeout),document.removeEventListener("keydown",this.onKeyDown);for(const t of this.cleanups)t();this.cleanups=[],this.triggers=[],this.activeTrigger=void 0}render(){return J`<slot @slotchange=${this.syncTriggerLabels}></slot>`}syncTriggerLabels(){const t=this.textContent?.trim()??"";t&&this.triggers.map(e=>{const s=e.shadowRoot?.querySelector("button, a")??e;this.cleanups.push(()=>s.removeAttribute("aria-label")),s.setAttribute("aria-label",t)})}bindTriggers(){if(this.id){this.triggers=[...document.querySelectorAll("[aria-describedby]")].filter(t=>{const e=t.getAttribute("aria-describedby");return e?.split(/\s+/).includes(this.id)??!1});for(const t of this.triggers){const e=()=>this.show(t),s=()=>this.scheduleHide(),o=()=>this.show(t),r=()=>this.hide();t.addEventListener("mouseenter",e),t.addEventListener("mouseleave",s),t.addEventListener("focusin",o),t.addEventListener("focusout",r),this.cleanups.push(()=>{t.removeEventListener("mouseenter",e),t.removeEventListener("mouseleave",s),t.removeEventListener("focusin",o),t.removeEventListener("focusout",r)})}this.addEventListener("mouseenter",this.onSelfMouseEnter),this.addEventListener("mouseleave",this.onSelfMouseLeave),this.cleanups.push(()=>{this.removeEventListener("mouseenter",this.onSelfMouseEnter),this.removeEventListener("mouseleave",this.onSelfMouseLeave)})}}show(t){clearTimeout(this.hoverTimeout),this.matches(":popover-open")||this.showPopover(),this.activeTrigger!==t&&(this.activeTrigger=t,this.dispatchSheriffEvent("toggle",t)),document.addEventListener("keydown",this.onKeyDown)}hide(){clearTimeout(this.hoverTimeout);try{this.hidePopover()}catch{}this.activeTrigger=void 0,document.removeEventListener("keydown",this.onKeyDown)}scheduleHide(){clearTimeout(this.hoverTimeout),this.hoverTimeout=setTimeout(()=>this.hide(),200)}};Sr.styles=[wr],$r([S({type:String,reflect:!0})],Sr.prototype,"placement",2),Sr=$r([A("sds-tooltip")],Sr);const Cr=d`
3486
4417
  :host {
3487
4418
  --_sds-text-font-family: var(--sds-text-font-family, var(--sds-typography-font-family-roboto));
3488
4419
  --_sds-text-font-size: var(--sds-text-font-size, var(--sds-typography-body-md-mobile-font-size));
@@ -3901,217 +4832,7 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
3901
4832
  --_sds-text-line-height: var(--sds-text-line-height, var(--sds-typography-leadtext-xl-strong-tall-desktop-line-height));
3902
4833
  }
3903
4834
  }
3904
- `;var Fo=Object.defineProperty,Uo=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Fo(e,s,a),a};const Go=class extends mt{constructor(){super(...arguments),this.size="md",this.strong=!1,this.subtle=!1,this.tall=!1}render(){return J`<p><slot></slot></p>`}};Go.styles=[Ho];let Ko=Go;Uo([S({type:String,reflect:!0})],Ko.prototype,"size"),Uo([S({type:Boolean,reflect:!0})],Ko.prototype,"strong"),Uo([S({type:Boolean,reflect:!0})],Ko.prototype,"subtle"),Uo([S({type:Boolean,reflect:!0})],Ko.prototype,"tall");var Wo=Object.getOwnPropertyDescriptor;let Zo=class extends Ko{};Zo=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Wo(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-text")],Zo);const Yo=d`
3905
- :host {
3906
- --_sds-textfield-background-color: var(--sds-textfield-background-color, var(--sds-color-background-default, var(--sds-color-neutral-background-default)));
3907
- --_sds-textfield-text-color: var(--sds-textfield-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3908
-
3909
- --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-border-default, var(--sds-color-neutral-border-default)));
3910
- --_sds-textfield-border-width: var(--sds-textfield-border-width, var(--sds-border-sm));
3911
- --_sds-textfield-border-radius: var(--sds-textfield-border-radius, var(--sds-radius-sm));
3912
-
3913
- --_sds-textfield-font-family: var(--sds-textfield-font-family, var(--sds-typography-font-family-roboto));
3914
- --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-md));
3915
- --_sds-textfield-font-weight: var(--sds-textfield-font-weight, var(--sds-typography-font-weight-regular));
3916
- --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-md));
3917
- --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-md));
3918
-
3919
- --_sds-textfield-gap: var(--sds-textfield-gap, var(--sds-spacing-3xs));
3920
- --_sds-textfield-padding-block: var(--sds-textfield-padding-block, 0);
3921
- --_sds-textfield-padding-inline: var(--sds-textfield-padding-inline, var(--sds-spacing-xs));
3922
- --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-md)));
3923
- --_sds-textfield-disabled-opacity: var(--sds-textfield-disabled-opacity, var(--sds-color-states-disabled-opacity));
3924
- --_sds-textfield-max-width: var(--sds-textfield-input-max-width, var(--sds-typography-max-line-width, 60ch));
3925
-
3926
- --_sds-textfield-label-text-color: var(--sds-textfield-label-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
3927
- --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-md));
3928
- --_sds-textfield-label-font-weight: var(--sds-textfield-label-font-weight, var(--sds-typography-font-weight-medium));
3929
- --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-md));
3930
-
3931
- --_sds-textfield-helptext-text-color: var(--sds-textfield-helptext-text-color, var(--sds-color-text-subtle, var(--sds-color-neutral-text-subtle)));
3932
- --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-md));
3933
- --_sds-textfield-helptext-font-weight: var(--sds-textfield-helptext-font-weight, var(--sds-typography-font-weight-regular));
3934
- --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-md));
3935
-
3936
- --_sds-textfield-focus-color: var(--sds-textfield-focus-color, var(--sds-color-states-focus-outer));
3937
- --_sds-textfield-focus-inner-color: var(--sds-textfield-focus-inner-color, var(--sds-color-states-focus-inner));
3938
- --_sds-textfield-focus-spacing: var(--sds-textfield-focus-spacing, var(--sds-color-states-focus-spacing));
3939
- --_sds-textfield-focus-outline-size: var(--sds-textfield-focus-outline-size, var(--sds-color-states-focus-outline-size));
3940
-
3941
- --_sds-textfield-cursor: var(--sds-textfield-cursor, auto);
3942
-
3943
- --_sds-textfield-icon-right: var(--sds-textfield-icon-right, var(--sds-spacing-xs));
3944
- --_sds-textfield-icon-top: var(--sds-textfield-icon-top, var(--sds-spacing-3xs));
3945
-
3946
- all: unset;
3947
- display: block;
3948
- text-align: start;
3949
- }
3950
-
3951
- .sds-textfield {
3952
- display: flex;
3953
- flex-direction: column;
3954
- gap: var(--_sds-textfield-gap);
3955
- font-family: var(--_sds-textfield-font-family);
3956
-
3957
- .sds-textfield__input-container {
3958
- position: relative;
3959
- font-size: var(--_sds-textfield-font-size);
3960
- max-width: var(--_sds-textfield-max-width);
3961
- }
3962
-
3963
- .sds-textfield__input {
3964
- box-sizing: border-box;
3965
- color: var(--_sds-textfield-text-color);
3966
- padding: var(--_sds-textfield-padding-block) var(--_sds-textfield-padding-inline);
3967
- line-height: var(--_sds-textfield-line-height);
3968
- font-size: var(--_sds-textfield-font-size);
3969
- font-weight: var(--_sds-textfield-font-weight);
3970
- font-family: var(--_sds-textfield-font-family);
3971
- min-height: var(--_sds-textfield-min-height);
3972
- border-radius: var(--_sds-textfield-border-radius);
3973
- border: var(--_sds-textfield-border-width) solid var(--_sds-textfield-border-color);
3974
- background: var(--_sds-textfield-background-color);
3975
- cursor: var(--_sds-textfield-cursor);
3976
- width: 100%;
3977
-
3978
- &:hover {
3979
- --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-border-strong, var(--sds-color-neutral-border-strong)));
3980
- }
3981
-
3982
- &:focus-visible {
3983
- box-shadow: 0 0 0 var(--_sds-textfield-focus-spacing) var(--_sds-textfield-focus-inner-color);
3984
- outline: var(--_sds-textfield-focus-outline-size) solid var(--_sds-textfield-focus-color);
3985
- outline-offset: var(--_sds-textfield-focus-spacing);
3986
- }
3987
- }
3988
-
3989
- .sds-textfield__label {
3990
- color: var(--_sds-textfield-text-color);
3991
- font-size: var(--_sds-textfield-label-font-size);
3992
- font-weight: var(--_sds-textfield-label-font-weight);
3993
- line-height: var(--_sds-textfield-label-line-height);
3994
- }
3995
-
3996
- .sds-textfield__label:has(sds-icon) {
3997
- display: flex;
3998
- flex-direction: row;
3999
- align-items: center;
4000
- gap: var(--_sds-textfield-gap);
4001
- }
4002
-
4003
- .sds-textfield__help-text {
4004
- display: block;
4005
- color: var(--_sds-textfield-helptext-text-color);
4006
- font-size: var(--_sds-textfield-helptext-font-size);
4007
- font-weight: var(--_sds-textfield-helptext-font-weight);
4008
- line-height: var(--_sds-textfield-helptext-line-height);
4009
- margin: 0;
4010
- }
4011
- }
4012
-
4013
- .sds-textfield--error {
4014
- --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-alert-danger-border-default));
4015
-
4016
- & .sds-textfield__input:hover,
4017
- & .sds-textfield__input:hover {
4018
- --_sds-textfield-border-color: var(--sds-textfield-border-color, var(--sds-color-alert-danger-border-default));
4019
- }
4020
- }
4021
-
4022
- :host([readonly]) {
4023
- --_sds-textfield-background-color: var(--sds-textfield-background-color, var(--sds-color-surface-tinted, var(--sds-color-neutral-surface-tinted)));
4024
- --_sds-textfield-cursor: var(--sds-textfield-cursor, default);
4025
- }
4026
-
4027
- :host(:disabled) {
4028
- opacity: var(--_sds-textfield-disabled-opacity);
4029
- pointer-events: none;
4030
- }
4031
-
4032
- .sds-textfield--has-icon {
4033
- .sds-textfield__input {
4034
- padding-right: var(--_sds-textfield-padding-icon);
4035
- }
4036
- }
4037
-
4038
- ::slotted([slot='after']) {
4039
- position: absolute;
4040
- top: var(--_sds-textfield-icon-top);
4041
- right: var(--_sds-textfield-icon-right);
4042
- pointer-events: none;
4043
- }
4044
-
4045
- :host([size='sm']) {
4046
- --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-sm));
4047
- --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-sm));
4048
- --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-sm));
4049
- --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-sm));
4050
- --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-sm));
4051
- --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-sm));
4052
- --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-sm));
4053
- --_sds-textfield-icon-top: var(--sds-textfield-icon-top, calc((var(--_sds-textfield-min-height) - var(--sds-components-icon-sm)) / 2));
4054
- --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-sm)));
4055
-
4056
- &:has(sds-icon:not([size])) {
4057
- --sds-icon-size: var(--sds-textfield-icon-size, var(--sds-components-icon-sm));
4058
- }
4059
- }
4060
-
4061
- :host([size='lg']) {
4062
- --_sds-textfield-min-height: var(--sds-textfield-height, var(--sds-components-button-lg));
4063
- --_sds-textfield-font-size: var(--sds-textfield-font-size, var(--sds-components-font-size-content-lg));
4064
- --_sds-textfield-line-height: var(--sds-textfield-line-height, var(--sds-components-line-height-squeezed-lg));
4065
- --_sds-textfield-label-font-size: var(--sds-textfield-label-font-size, var(--sds-components-font-size-content-lg));
4066
- --_sds-textfield-label-line-height: var(--sds-textfield-label-line-height, var(--sds-components-line-height-squeezed-lg));
4067
- --_sds-textfield-helptext-font-size: var(--sds-textfield-helptext-font-size, var(--sds-components-font-size-content-lg));
4068
- --_sds-textfield-helptext-line-height: var(--sds-textfield-helptext-line-height, var(--sds-components-line-height-squeezed-lg));
4069
- --_sds-textfield-icon-top: var(--sds-textfield-icon-top, var(--sds-spacing-3xs));
4070
- --_sds-textfield-padding-icon: var(--sds-textfield-padding-icon, calc(var(--sds-spacing-xs) + var(--sds-components-icon-lg)));
4071
-
4072
- &:has(sds-icon:not([size])) {
4073
- --sds-icon-size: var(--sds-textfield-icon-size, var(--sds-components-icon-lg));
4074
- }
4075
- }
4076
- `;var Qo=Object.defineProperty,Xo=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Qo(e,s,a),a};const Jo=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.type="text",this.required=!1,this.size="md",this.hasIcon=!1,this._hasSlottedLabel=!1,this._defaultValue=null,this.handleSlotChange=t=>{const e=t.target;this.hasIcon=e.assignedNodes({flatten:!0}).length>0},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0},this._handleInputChange=t=>{t.stopImmediatePropagation(),!this.disabled&&t.target instanceof HTMLInputElement&&(this.value=t.target.value,this.internals.setFormValue(""===this.value?null:this.value),this.updateValidity(),this.dispatchSheriffEvent(t.type))},this._handleSelect=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("select")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleKeyDown=t=>{t.stopImmediatePropagation();if(this.dispatchKeyboardEvent("keydown",t)&&"Enter"===t.key){for(const t of Array.from(this.form?.elements??[]))if(t instanceof HTMLButtonElement||t instanceof HTMLInputElement){if("submit"!==t.type)continue;if(t.disabled)return;return void t.click()}this.form?.requestSubmit()}}}connectedCallback(){super.connectedCallback(),this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue)}updated(t){super.updated(t),t.has("value")&&(this.internals.setFormValue(this.value??""),this.control&&(this.control.value=this.value??""))}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}formResetCallback(){this.internals.setFormValue(this._defaultValue);const t=this._defaultValue??"";this.control.value=t,this.value=t,this.updateValidity()}select(){this.disabled||this.control.select()}get selectionStart(){return this.control?this.control.selectionStart:null}set selectionStart(t){this.control&&null!==t&&(this.control.selectionStart=t)}get selectionEnd(){return this.control?this.control.selectionEnd:null}set selectionEnd(t){this.control&&null!==t&&(this.control.selectionEnd=t)}setSelectionRange(t,e,s){this.control&&this.control.setSelectionRange(t,e,s)}checkValidity(){return this.control.checkValidity()}reportValidity(){return this.control.reportValidity()}setCustomValidity(t){this.control.setCustomValidity(t),this.updateValidity()}render(){const t={"sds-textfield":!0,"sds-textfield--error":Boolean(this.errorMessage),"sds-textfield--has-icon":this.hasIcon},e=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0,s=this._hasSlottedLabel||Boolean(this.label);return J`
4077
- <div class="${te(t)}">
4078
- <label for="sds-textfield" class="sds-textfield__label" ?hidden="${!s}">
4079
- ${this.readOnly?J`<sds-icon name="lock-material-filled" size="m"></sds-icon>`:st}
4080
- <slot name="label" @slotchange="${this._handleLabelSlotChange}">${this.label}</slot>
4081
- </label>
4082
- ${this.helpText?J`<p id="help-text" class="sds-textfield__help-text">${this.helpText}</p>`:st}
4083
- <div class="sds-textfield__input-container">
4084
- <input
4085
- part="input"
4086
- class="sds-textfield__input"
4087
- type="${qt(this.type)}"
4088
- id="sds-textfield"
4089
- ?disabled="${this.disabled}"
4090
- ?readonly="${this.readOnly}"
4091
- placeholder="${qt(this.placeholder)}"
4092
- .value="${this.value??""}"
4093
- name="${qt(this.name)}"
4094
- autocomplete="${qt(this.autocomplete)}"
4095
- ?required="${this.required}"
4096
- pattern="${qt(this.pattern)}"
4097
- min="${qt(this.min)}"
4098
- minlength="${qt(this.minlength)}"
4099
- max="${qt(this.max)}"
4100
- maxlength="${qt(this.maxlength)}"
4101
- aria-describedby="${qt(e)}"
4102
- aria-invalid="${this.errorMessage?"true":"false"}"
4103
- @input="${this._handleInputChange}"
4104
- @change="${this._handleInputChange}"
4105
- @select="${this._handleSelect}"
4106
- @focus="${this._handleFocus}"
4107
- @blur="${this._handleBlur}"
4108
- @keydown="${this._handleKeyDown}"
4109
- />
4110
- <slot name="after" @slotchange="${this.handleSlotChange}" aria-hidden="true"></slot>
4111
- </div>
4112
- ${this.errorMessage?J`<sds-alert id="error-message" variant="secondary" data-palette="danger"><p slot="message">${this.errorMessage}</p></sds-alert>`:st}
4113
- </div>
4114
- `}};Jo.styles=[Yo];let tr=Jo;Xo([S({type:String,reflect:!0})],tr.prototype,"type"),Xo([S({type:String})],tr.prototype,"value"),Xo([S({type:String,reflect:!0})],tr.prototype,"label"),Xo([S({type:String,reflect:!0})],tr.prototype,"placeholder"),Xo([S({type:String,attribute:"help-text",reflect:!0})],tr.prototype,"helpText"),Xo([S({type:String,attribute:"error-message",reflect:!0})],tr.prototype,"errorMessage"),Xo([S({type:String,reflect:!0})],tr.prototype,"autocomplete"),Xo([S({type:Boolean,reflect:!0})],tr.prototype,"required"),Xo([S({type:String,reflect:!0})],tr.prototype,"pattern"),Xo([S({type:Number,reflect:!0})],tr.prototype,"minlength"),Xo([S({type:Number,reflect:!0})],tr.prototype,"maxlength"),Xo([S({type:String,reflect:!0})],tr.prototype,"min"),Xo([S({type:String,reflect:!0})],tr.prototype,"max"),Xo([S({type:String,reflect:!0})],tr.prototype,"size"),Xo([C()],tr.prototype,"hasIcon"),Xo([C()],tr.prototype,"_hasSlottedLabel"),Xo([A("#sds-textfield")],tr.prototype,"control");var er=Object.getOwnPropertyDescriptor;let sr=class extends tr{};sr=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?er(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([O("sds-textfield")],sr);const or=d`
4835
+ `;var Er=Object.defineProperty,Lr=(t,e,s,o)=>{for(var r,a=void 0,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(e,s,a)||a);return a&&Er(e,s,a),a};const Or=class extends mt{constructor(){super(...arguments),this.size="md",this.strong=!1,this.subtle=!1,this.tall=!1}render(){return J`<p><slot></slot></p>`}};Or.styles=[Cr];let Ar=Or;Lr([S({type:String,reflect:!0})],Ar.prototype,"size"),Lr([S({type:Boolean,reflect:!0})],Ar.prototype,"strong"),Lr([S({type:Boolean,reflect:!0})],Ar.prototype,"subtle"),Lr([S({type:Boolean,reflect:!0})],Ar.prototype,"tall");var Dr=Object.getOwnPropertyDescriptor;let Pr=class extends Ar{};Pr=((t,e,s,o)=>{for(var r,a=o>1?void 0:o?Dr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=r(a)||a);return a})([A("sds-text")],Pr);const Tr=d`
4115
4836
  :host {
4116
4837
  --_sds-textarea-background-color: var(--sds-textarea-background-color, var(--sds-color-background-default, var(--sds-color-neutral-background-default)));
4117
4838
  --_sds-textarea-text-color: var(--sds-textarea-text-color, var(--sds-color-text-default, var(--sds-color-neutral-text-default)));
@@ -4314,10 +5035,10 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
4314
5035
  --_sds-textarea-counter-font-size: var(--sds-textarea-counter-font-size, var(--sds-components-font-size-content-lg));
4315
5036
  --_sds-textarea-counter-line-height: var(--sds-textarea-counter-line-height, var(--sds-components-line-height-squeezed-lg));
4316
5037
  }
4317
- `;var rr=Object.defineProperty,ar=Object.getOwnPropertyDescriptor,ir=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?ar(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&rr(e,s,a),a};let dr=class extends(se(At(ae(mt)))){constructor(){super(...arguments),this.autosize=!1,this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._defaultValue=null,this._handleInputChange=t=>{t.stopImmediatePropagation(),!this.disabled&&t.target instanceof HTMLTextAreaElement&&(this.value=t.target.value,this.internals.setFormValue(""===this.value?null:this.value),this.updateValidity(),this.dispatchSheriffEvent(t.type))},this._handleSelect=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("select")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}connectedCallback(){super.connectedCallback(),this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue)}updated(t){super.updated(t),t.has("value")&&(this.internals.setFormValue(this.value??""),this.control&&(this.control.value=this.value??""))}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}hasTypedTooManyCharacters(){if(!this.counter)return!1;return(this.value?.length||0)>this.counter}renderCharacterCounter(){if(void 0===this.counter)return st;const t=this.value?.length||0;return this.hasTypedTooManyCharacters()?J`<sds-alert variant="secondary" data-palette="danger"
5038
+ `;var qr=Object.defineProperty,Mr=Object.getOwnPropertyDescriptor,Vr=(t,e,s,o)=>{for(var r,a=o>1?void 0:o?Mr(e,s):e,i=t.length-1;i>=0;i--)(r=t[i])&&(a=(o?r(e,s,a):r(a))||a);return o&&a&&qr(e,s,a),a};let Br=class extends(re(Lt(de(mt)))){constructor(){super(...arguments),this.autosize=!1,this.required=!1,this.size="md",this._hasSlottedLabel=!1,this._defaultValue=null,this._handleInputChange=t=>{t.stopImmediatePropagation(),!this.disabled&&t.target instanceof HTMLTextAreaElement&&(this.value=t.target.value,this.internals.setFormValue(""===this.value?null:this.value),this.updateValidity(),this.dispatchSheriffEvent(t.type))},this._handleSelect=t=>{t.stopImmediatePropagation(),this.disabled||this.dispatchSheriffEvent("select")},this._handleFocus=t=>{t.stopImmediatePropagation(),this.dispatchSheriffEvent("focus")},this._handleBlur=t=>{t.stopImmediatePropagation(),this.updateValidity(),this.dispatchSheriffEvent("blur")},this._handleLabelSlotChange=t=>{this._hasSlottedLabel=t.target.assignedNodes().length>0}}connectedCallback(){super.connectedCallback(),this._defaultValue=this.value??null,this.internals.setFormValue(this._defaultValue)}updated(t){super.updated(t),t.has("value")&&(this.internals.setFormValue(this.value??""),this.control&&(this.control.value=this.value??""))}updateValidity(){this.control&&(this.control.checkValidity()?this.internals.setValidity({}):this.internals.setValidity({customError:!0},this.control.validationMessage,this.control))}hasTypedTooManyCharacters(){if(!this.counter)return!1;return(this.value?.length||0)>this.counter}renderCharacterCounter(){if(void 0===this.counter)return st;const t=this.value?.length||0;return this.hasTypedTooManyCharacters()?J`<sds-alert variant="secondary" data-palette="danger"
4318
5039
  ><p class="sds-textarea__character-counter" slot="message">Du har ${t-this.counter} tegn for mye</p></sds-alert
4319
5040
  >`:J`<p class="sds-textarea__character-counter">Du har ${this.counter-t} tegn igjen</p>`}formResetCallback(){this.internals.setFormValue(this._defaultValue);const t=this._defaultValue??"";this.control.value=t,this.value=t,this.updateValidity()}select(){this.disabled||this.control.select()}type(){return"textarea"}get selectionStart(){return this.control?this.control.selectionStart:null}set selectionStart(t){this.control&&null!==t&&(this.control.selectionStart=t)}get selectionEnd(){return this.control?this.control.selectionEnd:null}set selectionEnd(t){this.control&&null!==t&&(this.control.selectionEnd=t)}setSelectionRange(t,e,s){this.control&&this.control.setSelectionRange(t,e,s)}checkValidity(){return this.control.checkValidity()}reportValidity(){return this.control.reportValidity()}setCustomValidity(t){this.control.setCustomValidity(t),this.updateValidity()}render(){const t=Boolean(this.errorMessage||this.hasTypedTooManyCharacters()),e=this._hasSlottedLabel||Boolean(this.label),s={"sds-textarea":!0,"sds-textarea--error":t},o=[this.errorMessage?"error-message":null,this.helpText?"help-text":null].filter(Boolean).join(" ")||void 0;return J`
4320
- <div class="${te(s)}">
5041
+ <div class="${se(s)}">
4321
5042
  <div style="${e||this.helpText?st:"display: none"}">
4322
5043
  <label for="sds-textarea" class="sds-textarea__label" ?hidden="${!e}">
4323
5044
  ${this.readOnly?J`<sds-icon name="lock-material-filled" size="m"></sds-icon>`:st}
@@ -4353,4 +5074,4 @@ var t;const e=globalThis,s=e.ShadowRoot&&(void 0===e.ShadyCSS||e.ShadyCSS.native
4353
5074
  ${this.errorMessage?J`<sds-alert id="error-message" variant="secondary" data-palette="danger"><p slot="message">${this.errorMessage}</p></sds-alert>`:st}
4354
5075
  ${this.renderCharacterCounter()}
4355
5076
  </div>
4356
- `}};dr.styles=[or],ir([S({type:String})],dr.prototype,"value",2),ir([S({type:String,reflect:!0})],dr.prototype,"label",2),ir([S({type:String,reflect:!0})],dr.prototype,"placeholder",2),ir([S({type:String,attribute:"help-text",reflect:!0})],dr.prototype,"helpText",2),ir([S({type:String,attribute:"error-message",reflect:!0})],dr.prototype,"errorMessage",2),ir([S({type:String,reflect:!0})],dr.prototype,"autocomplete",2),ir([S({type:Boolean,reflect:!0})],dr.prototype,"autosize",2),ir([S({type:Boolean,reflect:!0})],dr.prototype,"required",2),ir([S({type:Number,reflect:!0})],dr.prototype,"rows",2),ir([S({type:Number,reflect:!0})],dr.prototype,"cols",2),ir([S({type:String,reflect:!0})],dr.prototype,"wrap",2),ir([S({type:Number,reflect:!0})],dr.prototype,"minlength",2),ir([S({type:Number,reflect:!0})],dr.prototype,"maxlength",2),ir([S({type:Number,reflect:!0})],dr.prototype,"counter",2),ir([S({type:String,reflect:!0})],dr.prototype,"size",2),ir([A("#sds-textarea")],dr.prototype,"control",2),ir([C()],dr.prototype,"_hasSlottedLabel",2),dr=ir([O("sds-textarea")],dr);export{be as SDSAlert,ue as SDSButton,ke as SDSCard,Ee as SDSCheckbox,Te as SDSCheckboxGroup,Re as SDSChip,Xe as SDSDetails,os as SDSDetailsGroup,hs as SDSDialog,Ke as SDSEnvironmentBanner,_s as SDSHeading,Jt as SDSIcon,$s as SDSInternalHeader,Ls as SDSLoader,Vs as SDSNotification,Xs as SDSPopover,Ns as SDSProcess,Ks as SDSProcessStep,oo as SDSRadio,co as SDSRadioGroup,bo as SDSSelect,wo as SDSStepper,Co as SDSStepperStep,Po as SDSSwitch,Vo as SDSTag,Zo as SDSText,dr as SDSTextArea,sr as SDSTextField,No as SDSTooltip};
5077
+ `}};Br.styles=[Tr],Vr([S({type:String})],Br.prototype,"value",2),Vr([S({type:String,reflect:!0})],Br.prototype,"label",2),Vr([S({type:String,reflect:!0})],Br.prototype,"placeholder",2),Vr([S({type:String,attribute:"help-text",reflect:!0})],Br.prototype,"helpText",2),Vr([S({type:String,attribute:"error-message",reflect:!0})],Br.prototype,"errorMessage",2),Vr([S({type:String,reflect:!0})],Br.prototype,"autocomplete",2),Vr([S({type:Boolean,reflect:!0})],Br.prototype,"autosize",2),Vr([S({type:Boolean,reflect:!0})],Br.prototype,"required",2),Vr([S({type:Number,reflect:!0})],Br.prototype,"rows",2),Vr([S({type:Number,reflect:!0})],Br.prototype,"cols",2),Vr([S({type:String,reflect:!0})],Br.prototype,"wrap",2),Vr([S({type:Number,reflect:!0})],Br.prototype,"minlength",2),Vr([S({type:Number,reflect:!0})],Br.prototype,"maxlength",2),Vr([S({type:Number,reflect:!0})],Br.prototype,"counter",2),Vr([S({type:String,reflect:!0})],Br.prototype,"size",2),Vr([L("#sds-textarea")],Br.prototype,"control",2),Vr([C()],Br.prototype,"_hasSlottedLabel",2),Br=Vr([A("sds-textarea")],Br);export{me as SDSAlert,be as SDSButton,$e as SDSCard,Oe as SDSCheckbox,Me as SDSCheckboxGroup,je as SDSChip,xs as SDSDetails,$s as SDSDetailsGroup,Ps as SDSDialog,Ze as SDSEnvironmentBanner,us as SDSFileUpload,hs as SDSFileUploadFileList,ns as SDSFileUploadItem,Rs as SDSHeading,ee as SDSIcon,Gs as SDSInternalHeader,Xs as SDSLoader,ao as SDSNotification,yo as SDSPopover,ho as SDSProcess,fo as SDSProcessStep,So as SDSRadio,Do as SDSRadioGroup,Wo as SDSSearch,er as SDSSelect,ir as SDSStepper,hr as SDSStepperStep,fr as SDSSwitch,yr as SDSTag,Pr as SDSText,Br as SDSTextArea,Fo as SDSTextField,Sr as SDSTooltip};