@oslokommune/punkt-elements 14.4.0 → 14.5.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (134) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/dist/{accordionitem-C_URrDjP.js → accordionitem-DB3tAjIZ.js} +4 -4
  3. package/dist/{accordionitem-DCZrHVNR.cjs → accordionitem-DHYmPA-o.cjs} +1 -1
  4. package/dist/{alert-UFQFbbzZ.js → alert-DqXar67l.js} +6 -6
  5. package/dist/{alert-SvqEDHuW.cjs → alert-GrKyqxuR.cjs} +1 -1
  6. package/dist/{backlink-C7qUmUzs.js → backlink-CqUcmiPQ.js} +11 -11
  7. package/dist/{backlink-BrIIpgJ7.cjs → backlink-QDcQd6vK.cjs} +1 -1
  8. package/dist/{button-DaM4jvhJ.cjs → button-R4l10Nqd.cjs} +1 -1
  9. package/dist/{button-CjXih_Nx.js → button-f36menSU.js} +5 -5
  10. package/dist/{calendar-CvfMj3fA.js → calendar-DiNuZ8Ai.js} +7 -8
  11. package/dist/{calendar-ZzLAjDpv.cjs → calendar-wuD6ZH0t.cjs} +3 -3
  12. package/dist/{card-C1gRTfXb.cjs → card-C2hWaMev.cjs} +1 -1
  13. package/dist/{card-CO3D8wQE.js → card-CnINxZma.js} +7 -7
  14. package/dist/{checkbox-uxeHrTLH.cjs → checkbox-B-0FOdwi.cjs} +1 -1
  15. package/dist/{checkbox-DfVUNTjH.js → checkbox-CkAwPK_E.js} +4 -4
  16. package/dist/{class-map-C_erArZz.cjs → class-map-CApIYSRo.cjs} +1 -1
  17. package/dist/{class-map-wy7PUk0P.js → class-map-Dt2jXOlF.js} +1 -1
  18. package/dist/{combobox-MZsqmVL-.js → combobox-Dxa7XjLz.js} +11 -11
  19. package/dist/{combobox-CcyHcqdW.cjs → combobox-yy6hIGmB.cjs} +1 -1
  20. package/dist/{consent-Daj-Xa7w.cjs → consent-FbFS1pmz.cjs} +1 -1
  21. package/dist/{consent-BO3Ga8N4.js → consent-c9PhWxnP.js} +3 -3
  22. package/dist/{datepicker-a2LvhbRb.js → datepicker-C7GWMtXH.js} +11 -11
  23. package/dist/{datepicker-BeMs_vsm.cjs → datepicker-D_3vYgMt.cjs} +1 -1
  24. package/dist/{directive-helpers-BzAtj9by.js → directive-helpers-CQef4qUQ.js} +1 -1
  25. package/dist/{directive-helpers-4oOjKnGY.cjs → directive-helpers-CYIEJ8pI.cjs} +1 -1
  26. package/dist/{element-CRDRygXu.js → element-BXsf_NlG.js} +3 -3
  27. package/dist/{element-CJ_QKaki.cjs → element-aUzIoa1s.cjs} +3 -3
  28. package/dist/{heading-Dv_cH6N1.cjs → heading-CBepYb7H.cjs} +1 -1
  29. package/dist/{heading-BUdy170t.js → heading-J7dN9nRi.js} +13 -13
  30. package/dist/{helptext-hlcc584n.cjs → helptext-DebHGRsD.cjs} +1 -1
  31. package/dist/{helptext-Bn17Picx.js → helptext-DuyRRfCn.js} +5 -5
  32. package/dist/{icon-BB7e5iQN.js → icon-BgG6oO4Q.js} +1 -1
  33. package/dist/{icon-MRx-m0Or.cjs → icon-Dl9ZPqe6.cjs} +1 -1
  34. package/dist/{if-defined-Bc9-_I01.cjs → if-defined-BElHLTlB.cjs} +1 -1
  35. package/dist/{if-defined-BWZGb3bh.js → if-defined-CxHgig4I.js} +1 -1
  36. package/dist/index.d.ts +0 -41
  37. package/dist/{input-element-CARcDzQB.js → input-element-DVZhYDJ_.js} +2 -2
  38. package/dist/{input-element-CiaV6jln.cjs → input-element-RBQVA8i0.cjs} +1 -1
  39. package/dist/{input-wrapper-1PCXqtiu.js → input-wrapper-3qfjLkrP.js} +7 -7
  40. package/dist/{input-wrapper-CtBiAb04.cjs → input-wrapper-rgXsRNkk.cjs} +1 -1
  41. package/dist/{link-BboUBUcg.js → link-CZvcdRek.js} +4 -4
  42. package/dist/{link-Dw39h-YN.cjs → link-D85g20GS.cjs} +1 -1
  43. package/dist/{linkcard-DUA3kGGd.cjs → linkcard-B-9K02q8.cjs} +1 -1
  44. package/dist/{linkcard-BqJmHFu8.js → linkcard-C3RTcMqc.js} +4 -4
  45. package/dist/{listbox-mvKKzH-v.js → listbox-CLtowV6W.js} +36 -36
  46. package/dist/{listbox-DnoqOo5u.cjs → listbox-C_0RhGhk.cjs} +2 -2
  47. package/dist/{loader-DjGxT7C3.cjs → loader-1EXLdxfq.cjs} +1 -1
  48. package/dist/{loader-DIum_s_D.js → loader-Dci0SrOz.js} +5 -5
  49. package/dist/{messagebox-aPlConlJ.js → messagebox-CnZlttZp.js} +5 -5
  50. package/dist/{messagebox-ChIKVTO_.cjs → messagebox-dscnWgCd.cjs} +1 -1
  51. package/dist/{modal-B4qq0VFB.cjs → modal-ncKVjcyZ.cjs} +1 -1
  52. package/dist/{modal-jAUtM-NP.js → modal-wSGthXAC.js} +5 -5
  53. package/dist/pkt-accordion.cjs +1 -1
  54. package/dist/pkt-accordion.js +2 -2
  55. package/dist/pkt-alert.cjs +1 -1
  56. package/dist/pkt-alert.js +1 -1
  57. package/dist/pkt-backlink.cjs +1 -1
  58. package/dist/pkt-backlink.js +1 -1
  59. package/dist/pkt-button.cjs +1 -1
  60. package/dist/pkt-button.js +1 -1
  61. package/dist/pkt-calendar.cjs +1 -1
  62. package/dist/pkt-calendar.js +1 -1
  63. package/dist/pkt-card.cjs +1 -1
  64. package/dist/pkt-card.js +1 -1
  65. package/dist/pkt-checkbox.cjs +1 -1
  66. package/dist/pkt-checkbox.js +1 -1
  67. package/dist/pkt-combobox.cjs +1 -1
  68. package/dist/pkt-combobox.js +1 -1
  69. package/dist/pkt-consent.cjs +1 -1
  70. package/dist/pkt-consent.js +1 -1
  71. package/dist/pkt-datepicker.cjs +1 -1
  72. package/dist/pkt-datepicker.js +2 -2
  73. package/dist/pkt-header.cjs +1 -1
  74. package/dist/pkt-header.js +9 -9
  75. package/dist/pkt-heading.cjs +1 -1
  76. package/dist/pkt-heading.js +1 -1
  77. package/dist/pkt-helptext.cjs +1 -1
  78. package/dist/pkt-helptext.js +1 -1
  79. package/dist/pkt-icon.cjs +1 -1
  80. package/dist/pkt-icon.js +1 -1
  81. package/dist/pkt-index.cjs +1 -29
  82. package/dist/pkt-index.js +60 -157
  83. package/dist/pkt-input-wrapper.cjs +1 -1
  84. package/dist/pkt-input-wrapper.js +1 -1
  85. package/dist/pkt-link.cjs +1 -1
  86. package/dist/pkt-link.js +1 -1
  87. package/dist/pkt-linkcard.cjs +1 -1
  88. package/dist/pkt-linkcard.js +1 -1
  89. package/dist/pkt-listbox.cjs +1 -1
  90. package/dist/pkt-listbox.js +1 -1
  91. package/dist/pkt-loader.cjs +1 -1
  92. package/dist/pkt-loader.js +1 -1
  93. package/dist/pkt-messagebox.cjs +1 -1
  94. package/dist/pkt-messagebox.js +1 -1
  95. package/dist/pkt-modal.cjs +1 -1
  96. package/dist/pkt-modal.js +1 -1
  97. package/dist/pkt-progressbar.cjs +1 -1
  98. package/dist/pkt-progressbar.js +2 -2
  99. package/dist/pkt-radiobutton.cjs +1 -1
  100. package/dist/pkt-radiobutton.js +1 -1
  101. package/dist/pkt-select.cjs +1 -1
  102. package/dist/pkt-select.js +1 -1
  103. package/dist/pkt-tabs.cjs +1 -1
  104. package/dist/pkt-tabs.js +2 -2
  105. package/dist/pkt-tag.cjs +1 -1
  106. package/dist/pkt-tag.js +1 -1
  107. package/dist/pkt-textarea.cjs +1 -1
  108. package/dist/pkt-textarea.js +1 -1
  109. package/dist/pkt-textinput.cjs +1 -1
  110. package/dist/pkt-textinput.js +1 -1
  111. package/dist/{progressbar-CmAQ-DVW.cjs → progressbar-ClY1WgnM.cjs} +1 -1
  112. package/dist/{progressbar-CVt73-JQ.js → progressbar-D5WBW1Dm.js} +5 -5
  113. package/dist/{radiobutton-DVe09YxP.cjs → radiobutton-iHuLnuAn.cjs} +1 -1
  114. package/dist/{radiobutton-BmgdSpYf.js → radiobutton-oA20HijB.js} +15 -15
  115. package/dist/{ref-Xa5dbh--.js → ref-BxiKhrfa.js} +2 -2
  116. package/dist/{ref-BFa5Utho.cjs → ref-C5iJMIE1.cjs} +1 -1
  117. package/dist/{repeat-CJ79egkN.js → repeat-B55jMEsG.js} +2 -2
  118. package/dist/{repeat-BZb41H64.cjs → repeat-DcYSFU2y.cjs} +1 -1
  119. package/dist/{select-CKqz-JKZ.js → select-Bug9sfr5.js} +6 -6
  120. package/dist/{select-7KFOnLln.cjs → select-jbIbD7hW.cjs} +1 -1
  121. package/dist/{state-DS_kr2Fy.js → state-DgnkjP0q.js} +1 -1
  122. package/dist/{state-DSjcvzDN.cjs → state-GDzxl12x.cjs} +1 -1
  123. package/dist/{tabitem-D5zyipN1.cjs → tabitem-CtltSqDK.cjs} +1 -1
  124. package/dist/{tabitem-NV2fzs_-.js → tabitem-CypTmORF.js} +30 -30
  125. package/dist/{tag-B02fKJ66.cjs → tag-BfjOlIyS.cjs} +1 -1
  126. package/dist/{tag-CES41g0D.js → tag-DgoTYNVA.js} +6 -6
  127. package/dist/{textarea-Bmrv_vve.js → textarea-Da9E3RM7.js} +9 -9
  128. package/dist/{textarea-VBUXPS1O.cjs → textarea-Dfa4_ZBy.cjs} +1 -1
  129. package/dist/{textinput-BkYKotc1.cjs → textinput-CLM9fRjm.cjs} +1 -1
  130. package/dist/{textinput-Lp1crOmj.js → textinput-DaMYc5gd.js} +8 -8
  131. package/package.json +2 -2
  132. package/src/components/header/header.ts +2 -0
  133. package/src/components/index.ts +0 -1
  134. package/src/components/select/select.ts +2 -0
@@ -1,8 +1,8 @@
1
- import { P as $, x as p, n as h, a as y } from "./element-CRDRygXu.js";
1
+ import { P as $, x as p, n as h, t as y } from "./element-BXsf_NlG.js";
2
2
  import { P as C } from "./pkt-slot-controller-BPGj-LC5.js";
3
- import { r as w } from "./state-DS_kr2Fy.js";
4
- import { e as x, n as f } from "./ref-Xa5dbh--.js";
5
- import { o as u } from "./if-defined-BWZGb3bh.js";
3
+ import { r as w } from "./state-DgnkjP0q.js";
4
+ import { e as x, n as f } from "./ref-BxiKhrfa.js";
5
+ import { o as u } from "./if-defined-CxHgig4I.js";
6
6
  /**
7
7
  * @license
8
8
  * Copyright 2021 Google LLC
@@ -25,11 +25,11 @@ let P = class extends Event {
25
25
  */
26
26
  let m = class {
27
27
  constructor(t, s, i, e) {
28
- if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (a, r) => {
29
- this.unsubscribe && (this.unsubscribe !== r && (this.provided = !1, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = a, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = !0, this.callback && this.callback(a, r)), this.unsubscribe = r;
28
+ if (this.subscribe = !1, this.provided = !1, this.value = void 0, this.t = (n, r) => {
29
+ this.unsubscribe && (this.unsubscribe !== r && (this.provided = !1, this.unsubscribe()), this.subscribe || this.unsubscribe()), this.value = n, this.host.requestUpdate(), this.provided && !this.subscribe || (this.provided = !0, this.callback && this.callback(n, r)), this.unsubscribe = r;
30
30
  }, this.host = t, s.context !== void 0) {
31
- const a = s;
32
- this.context = a.context, this.callback = a.callback, this.subscribe = a.subscribe ?? !1;
31
+ const n = s;
32
+ this.context = n.context, this.callback = n.callback, this.subscribe = n.subscribe ?? !1;
33
33
  } else this.context = s, this.callback = i, this.subscribe = e ?? !1;
34
34
  this.host.addController(this);
35
35
  }
@@ -88,17 +88,17 @@ let _ = class extends Event {
88
88
  };
89
89
  class g extends N {
90
90
  constructor(t, s, i) {
91
- var e, a;
91
+ var e, n;
92
92
  super(s.context !== void 0 ? s.initialValue : i), this.onContextRequest = (r) => {
93
93
  if (r.context !== this.context) return;
94
- const n = r.contextTarget ?? r.composedPath()[0];
95
- n !== this.host && (r.stopPropagation(), this.addCallback(r.callback, n, r.subscribe));
94
+ const a = r.contextTarget ?? r.composedPath()[0];
95
+ a !== this.host && (r.stopPropagation(), this.addCallback(r.callback, a, r.subscribe));
96
96
  }, this.onProviderRequest = (r) => {
97
97
  if (r.context !== this.context || (r.contextTarget ?? r.composedPath()[0]) === this.host) return;
98
- const n = /* @__PURE__ */ new Set();
99
- for (const [v, { consumerHost: k }] of this.subscriptions) n.has(v) || (n.add(v), k.dispatchEvent(new P(this.context, k, v, !0)));
98
+ const a = /* @__PURE__ */ new Set();
99
+ for (const [v, { consumerHost: k }] of this.subscriptions) a.has(v) || (a.add(v), k.dispatchEvent(new P(this.context, k, v, !0)));
100
100
  r.stopPropagation();
101
- }, this.host = t, s.context !== void 0 ? this.context = s.context : this.context = s, this.attachListeners(), (a = (e = this.host).addController) == null || a.call(e, this);
101
+ }, this.host = t, s.context !== void 0 ? this.context = s.context : this.context = s, this.attachListeners(), (n = (e = this.host).addController) == null || n.call(e, this);
102
102
  }
103
103
  attachListeners() {
104
104
  this.host.addEventListener("context-request", this.onContextRequest), this.host.addEventListener("context-provider", this.onProviderRequest);
@@ -127,21 +127,21 @@ function R({ context: o }) {
127
127
  i.set(r, new g(r, { context: o }));
128
128
  }));
129
129
  const e = Object.getOwnPropertyDescriptor(t, s);
130
- let a;
130
+ let n;
131
131
  if (e === void 0) {
132
132
  const r = /* @__PURE__ */ new WeakMap();
133
- a = { get() {
133
+ n = { get() {
134
134
  return r.get(this);
135
- }, set(n) {
136
- i.get(this).setValue(n), r.set(this, n);
135
+ }, set(a) {
136
+ i.get(this).setValue(a), r.set(this, a);
137
137
  }, configurable: !0, enumerable: !0 };
138
138
  } else {
139
139
  const r = e.set;
140
- a = { ...e, set(n) {
141
- i.get(this).setValue(n), r == null || r.call(this, n);
140
+ n = { ...e, set(a) {
141
+ i.get(this).setValue(a), r == null || r.call(this, a);
142
142
  } };
143
143
  }
144
- return void Object.defineProperty(t, s, a);
144
+ return void Object.defineProperty(t, s, n);
145
145
  }
146
146
  };
147
147
  }
@@ -157,16 +157,16 @@ function A({ context: o, subscribe: t }) {
157
157
  s.set.call(this, e);
158
158
  }, subscribe: t });
159
159
  })) : s.constructor.addInitializer(((e) => {
160
- new m(e, { context: o, callback: (a) => {
161
- e[i] = a;
160
+ new m(e, { context: o, callback: (n) => {
161
+ e[i] = n;
162
162
  }, subscribe: t });
163
163
  }));
164
164
  };
165
165
  }
166
166
  const S = Symbol("pkt-tabs-context");
167
167
  var O = Object.defineProperty, T = Object.getOwnPropertyDescriptor, d = (o, t, s, i) => {
168
- for (var e = i > 1 ? void 0 : i ? T(t, s) : t, a = o.length - 1, r; a >= 0; a--)
169
- (r = o[a]) && (e = (i ? r(t, s, e) : r(e)) || e);
168
+ for (var e = i > 1 ? void 0 : i ? T(t, s) : t, n = o.length - 1, r; n >= 0; n--)
169
+ (r = o[n]) && (e = (i ? r(t, s, e) : r(e)) || e);
170
170
  return i && e && O(t, s, e), e;
171
171
  };
172
172
  let b = class extends $ {
@@ -240,8 +240,8 @@ b = d([
240
240
  ], b);
241
241
  const M = b;
242
242
  var j = Object.defineProperty, q = Object.getOwnPropertyDescriptor, l = (o, t, s, i) => {
243
- for (var e = i > 1 ? void 0 : i ? q(t, s) : t, a = o.length - 1, r; a >= 0; a--)
244
- (r = o[a]) && (e = (i ? r(t, s, e) : r(e)) || e);
243
+ for (var e = i > 1 ? void 0 : i ? q(t, s) : t, n = o.length - 1, r; n >= 0; n--)
244
+ (r = o[n]) && (e = (i ? r(t, s, e) : r(e)) || e);
245
245
  return i && e && j(t, s, e), e;
246
246
  };
247
247
  let c = class extends $ {
@@ -261,7 +261,7 @@ let c = class extends $ {
261
261
  }
262
262
  render() {
263
263
  var r;
264
- const o = ((r = this.context) == null ? void 0 : r.useArrowNav) ?? !0, t = this.active ? "active" : "", s = o ? "tab" : void 0, i = o ? this.active : void 0, e = this.active || !o ? void 0 : -1, a = p`
264
+ const o = ((r = this.context) == null ? void 0 : r.useArrowNav) ?? !0, t = this.active ? "active" : "", s = o ? "tab" : void 0, i = o ? this.active : void 0, e = this.active || !o ? void 0 : -1, n = p`
265
265
  ${this.icon ? p`<pkt-icon name=${this.icon} class="pkt-icon--small"></pkt-icon>` : ""}
266
266
  <span ${f(this.defaultSlot)}></span>
267
267
  ${this.tag ? p`<pkt-tag skin=${this.tagSkin} size="small">${this.tag}</pkt-tag>` : ""}
@@ -278,7 +278,7 @@ let c = class extends $ {
278
278
  @click=${this.handleClick}
279
279
  @keyup=${this.handleKeyUp}
280
280
  >
281
- ${a}
281
+ ${n}
282
282
  </a>
283
283
  ` : p`
284
284
  <button
@@ -292,7 +292,7 @@ let c = class extends $ {
292
292
  @click=${this.handleClick}
293
293
  @keyup=${this.handleKeyUp}
294
294
  >
295
- ${a}
295
+ ${n}
296
296
  </button>
297
297
  `;
298
298
  }
@@ -1,4 +1,4 @@
1
- "use strict";const h=require("./class-map-C_erArZz.cjs"),t=require("./element-CJ_QKaki.cjs"),k=require("./state-DSjcvzDN.cjs"),g=require("./pkt-slot-controller-BzddBp7z.cjs"),c=require("./ref-BFa5Utho.cjs");require("./icon-MRx-m0Or.cjs");const u=require("./if-defined-Bc9-_I01.cjs"),d={size:{default:"medium"},skin:{default:"blue"},closeTag:{default:!1},type:{default:"button"}},r={props:d};var f=Object.defineProperty,y=Object.getOwnPropertyDescriptor,i=(n,e,a,o)=>{for(var s=o>1?void 0:o?y(e,a):e,l=n.length-1,p;l>=0;l--)(p=n[l])&&(s=(o?p(e,a,s):p(s))||s);return o&&s&&f(e,a,s),s};exports.PktTag=class extends t.PktElement{constructor(){super(),this.defaultSlot=c.e(),this.closeTag=r.props.closeTag.default,this.size=r.props.size.default,this.skin=r.props.skin.default,this.textStyle=null,this.iconName=void 0,this.type=r.props.type.default,this.ariaLabel=null,this._isClosed=!1,this._ariaDescription=null,this.close=e=>{this._isClosed=!0,this.dispatchEvent(new CustomEvent("close",{detail:{origin:e},bubbles:!1,composed:!0})),this.dispatchEvent(new CustomEvent("on-close",{detail:{origin:e},bubbles:!1,composed:!0}))},this.slotController=new g.PktSlotController(this,this.defaultSlot),this._isClosed=!1}firstUpdated(e){var a,o;if(super.firstUpdated(e),this.closeTag&&!this.ariaLabel){const s=(o=(a=this.defaultSlot.value)==null?void 0:a.textContent)==null?void 0:o.trim();s&&(this._ariaDescription=`Klikk for å fjerne ${s}`)}}render(){const e={"pkt-tag":!0,[`pkt-tag--${this.size}`]:!!this.size,[`pkt-tag--${this.skin}`]:!!this.skin,[`pkt-tag--${this.textStyle}`]:!!this.textStyle},a={"pkt-tag":!0,"pkt-btn":!0,"pkt-btn--tertiary":!0,[`pkt-tag--${this.textStyle}`]:!!this.textStyle,[`pkt-tag--${this.size}`]:!!this.size,[`pkt-tag--${this.skin}`]:!!this.skin,"pkt-btn--icons-right-and-left":this.closeTag&&!!this.iconName,"pkt-hide":this._isClosed};return this.closeTag?t.x`
1
+ "use strict";const h=require("./class-map-CApIYSRo.cjs"),t=require("./element-aUzIoa1s.cjs"),k=require("./state-GDzxl12x.cjs"),g=require("./pkt-slot-controller-BzddBp7z.cjs"),c=require("./ref-C5iJMIE1.cjs");require("./icon-Dl9ZPqe6.cjs");const u=require("./if-defined-BElHLTlB.cjs"),d={size:{default:"medium"},skin:{default:"blue"},closeTag:{default:!1},type:{default:"button"}},r={props:d};var f=Object.defineProperty,y=Object.getOwnPropertyDescriptor,i=(n,e,a,o)=>{for(var s=o>1?void 0:o?y(e,a):e,l=n.length-1,p;l>=0;l--)(p=n[l])&&(s=(o?p(e,a,s):p(s))||s);return o&&s&&f(e,a,s),s};exports.PktTag=class extends t.PktElement{constructor(){super(),this.defaultSlot=c.e(),this.closeTag=r.props.closeTag.default,this.size=r.props.size.default,this.skin=r.props.skin.default,this.textStyle=null,this.iconName=void 0,this.type=r.props.type.default,this.ariaLabel=null,this._isClosed=!1,this._ariaDescription=null,this.close=e=>{this._isClosed=!0,this.dispatchEvent(new CustomEvent("close",{detail:{origin:e},bubbles:!1,composed:!0})),this.dispatchEvent(new CustomEvent("on-close",{detail:{origin:e},bubbles:!1,composed:!0}))},this.slotController=new g.PktSlotController(this,this.defaultSlot),this._isClosed=!1}firstUpdated(e){var a,o;if(super.firstUpdated(e),this.closeTag&&!this.ariaLabel){const s=(o=(a=this.defaultSlot.value)==null?void 0:a.textContent)==null?void 0:o.trim();s&&(this._ariaDescription=`Klikk for å fjerne ${s}`)}}render(){const e={"pkt-tag":!0,[`pkt-tag--${this.size}`]:!!this.size,[`pkt-tag--${this.skin}`]:!!this.skin,[`pkt-tag--${this.textStyle}`]:!!this.textStyle},a={"pkt-tag":!0,"pkt-btn":!0,"pkt-btn--tertiary":!0,[`pkt-tag--${this.textStyle}`]:!!this.textStyle,[`pkt-tag--${this.size}`]:!!this.size,[`pkt-tag--${this.skin}`]:!!this.skin,"pkt-btn--icons-right-and-left":this.closeTag&&!!this.iconName,"pkt-hide":this._isClosed};return this.closeTag?t.x`
2
2
  <button
3
3
  class=${h.e(a)}
4
4
  type=${this.type}
@@ -1,10 +1,10 @@
1
- import { e as u } from "./class-map-wy7PUk0P.js";
2
- import { P as m, x as p, n as r, a as g } from "./element-CRDRygXu.js";
3
- import { r as k } from "./state-DS_kr2Fy.js";
1
+ import { e as u } from "./class-map-Dt2jXOlF.js";
2
+ import { P as m, x as p, n as r, t as g } from "./element-BXsf_NlG.js";
3
+ import { r as k } from "./state-DgnkjP0q.js";
4
4
  import { P as y } from "./pkt-slot-controller-BPGj-LC5.js";
5
- import { e as b, n as f } from "./ref-Xa5dbh--.js";
6
- import "./icon-BB7e5iQN.js";
7
- import { o as d } from "./if-defined-BWZGb3bh.js";
5
+ import { e as b, n as f } from "./ref-BxiKhrfa.js";
6
+ import "./icon-BgG6oO4Q.js";
7
+ import { o as d } from "./if-defined-CxHgig4I.js";
8
8
  const _ = { size: { default: "medium" }, skin: { default: "blue" }, closeTag: { default: !1 }, type: { default: "button" } }, n = {
9
9
  props: _
10
10
  };
@@ -1,14 +1,14 @@
1
- import { T as l, E as $, x as f, n as d, a as g } from "./element-CRDRygXu.js";
2
- import { o as u } from "./if-defined-BWZGb3bh.js";
3
- import { r as x } from "./state-DS_kr2Fy.js";
4
- import { e as m, n as c } from "./ref-Xa5dbh--.js";
5
- import { e as v } from "./class-map-wy7PUk0P.js";
1
+ import { T as l, E as $, x as f, n as d, t as g } from "./element-BXsf_NlG.js";
2
+ import { o as u } from "./if-defined-CxHgig4I.js";
3
+ import { r as x } from "./state-DgnkjP0q.js";
4
+ import { e as m, n as c } from "./ref-BxiKhrfa.js";
5
+ import { e as v } from "./class-map-Dt2jXOlF.js";
6
6
  import { e as T, i as b, t as a } from "./directive-oAbCiebi.js";
7
- import { f as y, m as w } from "./directive-helpers-BzAtj9by.js";
8
- import { P as C } from "./input-element-CARcDzQB.js";
7
+ import { f as y, m as w } from "./directive-helpers-CQef4qUQ.js";
8
+ import { P as C } from "./input-element-DVZhYDJ_.js";
9
9
  import { P as E } from "./pkt-slot-controller-BPGj-LC5.js";
10
- import "./input-wrapper-1PCXqtiu.js";
11
- import "./icon-BB7e5iQN.js";
10
+ import "./input-wrapper-3qfjLkrP.js";
11
+ import "./icon-BgG6oO4Q.js";
12
12
  /**
13
13
  * @license
14
14
  * Copyright 2020 Google LLC
@@ -1,4 +1,4 @@
1
- "use strict";const s=require("./element-CJ_QKaki.cjs"),p=require("./if-defined-Bc9-_I01.cjs"),c=require("./state-DSjcvzDN.cjs"),l=require("./ref-BFa5Utho.cjs"),$=require("./class-map-C_erArZz.cjs"),a=require("./directive-C7oCP5Bh.cjs"),d=require("./directive-helpers-4oOjKnGY.cjs"),x=require("./input-element-CiaV6jln.cjs"),T=require("./pkt-slot-controller-BzddBp7z.cjs");require("./input-wrapper-CtBiAb04.cjs");require("./icon-MRx-m0Or.cjs");/**
1
+ "use strict";const s=require("./element-aUzIoa1s.cjs"),p=require("./if-defined-BElHLTlB.cjs"),c=require("./state-GDzxl12x.cjs"),l=require("./ref-C5iJMIE1.cjs"),$=require("./class-map-CApIYSRo.cjs"),a=require("./directive-C7oCP5Bh.cjs"),d=require("./directive-helpers-CYIEJ8pI.cjs"),x=require("./input-element-RBQVA8i0.cjs"),T=require("./pkt-slot-controller-BzddBp7z.cjs");require("./input-wrapper-rgXsRNkk.cjs");require("./icon-Dl9ZPqe6.cjs");/**
2
2
  * @license
3
3
  * Copyright 2020 Google LLC
4
4
  * SPDX-License-Identifier: BSD-3-Clause
@@ -1,4 +1,4 @@
1
- "use strict";const t=require("./element-CJ_QKaki.cjs"),a=require("./if-defined-Bc9-_I01.cjs"),l=require("./state-DSjcvzDN.cjs"),h=require("./ref-BFa5Utho.cjs"),c=require("./class-map-C_erArZz.cjs"),d=require("./input-element-CiaV6jln.cjs"),x=require("./pkt-slot-controller-BzddBp7z.cjs");require("./input-wrapper-CtBiAb04.cjs");require("./icon-MRx-m0Or.cjs");var $=Object.defineProperty,f=Object.getOwnPropertyDescriptor,r=(u,i,s,n)=>{for(var e=n>1?void 0:n?f(i,s):i,o=u.length-1,p;o>=0;o--)(p=u[o])&&(e=(n?p(i,s,e):p(e))||e);return n&&e&&$(i,s,e),e};exports.PktTextinput=class extends d.PktInputElement{constructor(){super(),this.inputRef=h.e(),this.helptextSlot=h.e(),this.value="",this.type="text",this.size=null,this.autocomplete=null,this.iconNameRight=null,this.prefix=null,this.suffix=null,this.omitSearchIcon=!1,this.counterCurrent=0,this.slotController=new x.PktSlotController(this,this.helptextSlot)}attributeChangedCallback(i,s,n){i==="value"&&this.value!==s&&(this.counterCurrent=n?n.length:0,this.valueChanged(n,s)),super.attributeChangedCallback(i,s,n)}updated(i){var s;super.updated(i),i.has("value")&&(this.counterCurrent=((s=this.value)==null?void 0:s.length)||0,this.valueChanged(this.value,i.get("value"))),i.has("id")&&!this.name&&this.id&&(this.name=this.id)}render(){const i=this.type==="search"&&!this.iconNameRight&&!this.omitSearchIcon,s=c.e({"pkt-input":!0,"pkt-input--fullwidth":this.fullwidth,"pkt-input--counter-error":this.counter&&this.counterMaxLength&&this.value.length&&this.value.length>this.counterMaxLength}),n=this.ariaLabelledby||`${this.id}-input-label`;return t.x`
1
+ "use strict";const t=require("./element-aUzIoa1s.cjs"),a=require("./if-defined-BElHLTlB.cjs"),l=require("./state-GDzxl12x.cjs"),h=require("./ref-C5iJMIE1.cjs"),c=require("./class-map-CApIYSRo.cjs"),d=require("./input-element-RBQVA8i0.cjs"),x=require("./pkt-slot-controller-BzddBp7z.cjs");require("./input-wrapper-rgXsRNkk.cjs");require("./icon-Dl9ZPqe6.cjs");var $=Object.defineProperty,f=Object.getOwnPropertyDescriptor,r=(u,i,s,n)=>{for(var e=n>1?void 0:n?f(i,s):i,o=u.length-1,p;o>=0;o--)(p=u[o])&&(e=(n?p(i,s,e):p(e))||e);return n&&e&&$(i,s,e),e};exports.PktTextinput=class extends d.PktInputElement{constructor(){super(),this.inputRef=h.e(),this.helptextSlot=h.e(),this.value="",this.type="text",this.size=null,this.autocomplete=null,this.iconNameRight=null,this.prefix=null,this.suffix=null,this.omitSearchIcon=!1,this.counterCurrent=0,this.slotController=new x.PktSlotController(this,this.helptextSlot)}attributeChangedCallback(i,s,n){i==="value"&&this.value!==s&&(this.counterCurrent=n?n.length:0,this.valueChanged(n,s)),super.attributeChangedCallback(i,s,n)}updated(i){var s;super.updated(i),i.has("value")&&(this.counterCurrent=((s=this.value)==null?void 0:s.length)||0,this.valueChanged(this.value,i.get("value"))),i.has("id")&&!this.name&&this.id&&(this.name=this.id)}render(){const i=this.type==="search"&&!this.iconNameRight&&!this.omitSearchIcon,s=c.e({"pkt-input":!0,"pkt-input--fullwidth":this.fullwidth,"pkt-input--counter-error":this.counter&&this.counterMaxLength&&this.value.length&&this.value.length>this.counterMaxLength}),n=this.ariaLabelledby||`${this.id}-input-label`;return t.x`
2
2
  <pkt-input-wrapper
3
3
  label="${this.label}"
4
4
  ?counter=${this.counter}
@@ -1,12 +1,12 @@
1
- import { E as p, x as h, n as a, a as $ } from "./element-CRDRygXu.js";
2
- import { o as u } from "./if-defined-BWZGb3bh.js";
3
- import { r as f } from "./state-DS_kr2Fy.js";
4
- import { e as d, n as m } from "./ref-Xa5dbh--.js";
5
- import { e as g } from "./class-map-wy7PUk0P.js";
6
- import { P as x } from "./input-element-CARcDzQB.js";
1
+ import { E as p, x as h, n as a, t as $ } from "./element-BXsf_NlG.js";
2
+ import { o as u } from "./if-defined-CxHgig4I.js";
3
+ import { r as f } from "./state-DgnkjP0q.js";
4
+ import { e as d, n as m } from "./ref-BxiKhrfa.js";
5
+ import { e as g } from "./class-map-Dt2jXOlF.js";
6
+ import { P as x } from "./input-element-DVZhYDJ_.js";
7
7
  import { P as v } from "./pkt-slot-controller-BPGj-LC5.js";
8
- import "./input-wrapper-1PCXqtiu.js";
9
- import "./icon-BB7e5iQN.js";
8
+ import "./input-wrapper-3qfjLkrP.js";
9
+ import "./icon-BgG6oO4Q.js";
10
10
  var y = Object.defineProperty, b = Object.getOwnPropertyDescriptor, o = (i, e, r, t) => {
11
11
  for (var n = t > 1 ? void 0 : t ? b(e, r) : e, l = i.length - 1, c; l >= 0; l--)
12
12
  (c = i[l]) && (n = (t ? c(e, r, n) : c(n)) || n);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oslokommune/punkt-elements",
3
- "version": "14.4.0",
3
+ "version": "14.5.2",
4
4
  "description": "Komponentbiblioteket til Punkt, et designsystem laget av Oslo Origo",
5
5
  "homepage": "https://punkt.oslo.kommune.no",
6
6
  "author": "Team Designsystem, Oslo Origo",
@@ -79,5 +79,5 @@
79
79
  "url": "https://github.com/oslokommune/punkt/issues"
80
80
  },
81
81
  "license": "MIT",
82
- "gitHead": "60b409e10bc60371f696d76a84ce6e0d25cb225a"
82
+ "gitHead": "fd47b46c754cf9df72186df66db3f17d2bb925b4"
83
83
  }
@@ -88,9 +88,11 @@ export class PktHeader extends PktElement<IPktHeader> implements IPktHeader {
88
88
 
89
89
  private emitDeprecationWarnings() {
90
90
  if (this.userMenuFooter !== undefined) {
91
+ // eslint-disable-next-line no-console -- Deprecation warnings are intentional for library consumers
91
92
  console.warn('[PktHeader] userMenuFooter is deprecated. Use userMenu instead.')
92
93
  }
93
94
  if (this.userOptions !== undefined) {
95
+ // eslint-disable-next-line no-console -- Deprecation warnings are intentional for library consumers
94
96
  console.warn('[PktHeader] userOptions is deprecated. Use userMenu instead.')
95
97
  }
96
98
  }
@@ -8,7 +8,6 @@ export { PktCard } from '@/components/card'
8
8
  export { PktCombobox } from './combobox'
9
9
  export { PktConsent } from './consent'
10
10
  export { PktCheckbox } from '@/components/checkbox'
11
- export { PktComponent } from '../base-elements/component-template.js'
12
11
  export { PktDateTags } from '@/components/datepicker/date-tags.js'
13
12
  export { PktDatepicker } from '@/components/datepicker/datepicker.js'
14
13
  export { PktHeader, PktHeaderService, PktHeaderUserMenu } from '@/components/header'
@@ -125,6 +125,7 @@ export class PktSelect extends PktOptionsInputElement<{}, TSelectOption> impleme
125
125
  // Support native Select method `showPicker`
126
126
  public showPicker() {
127
127
  if (this.inputRef.value && 'showPicker' in this.inputRef.value) {
128
+ // eslint-disable-next-line @typescript-eslint/no-explicit-any -- showPicker is not in TypeScript's HTMLSelectElement type yet
128
129
  ;(this.inputRef.value as any).showPicker()
129
130
  }
130
131
  }
@@ -151,6 +152,7 @@ export class PktSelect extends PktOptionsInputElement<{}, TSelectOption> impleme
151
152
 
152
153
  // If no value is set and we have options, set to first option
153
154
  if (!this.value && this._options.length > 0) {
155
+ // eslint-disable-next-line lit/no-property-change-update -- Initial value setup is intentional
154
156
  this.value = this._options[0].value
155
157
  this.selectedIndex = 0
156
158
  }