highsoft-ui 1.0.72 → 1.0.74

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.
@@ -22,11 +22,12 @@ export interface Notification {
22
22
  closable?: boolean;
23
23
  }
24
24
  export declare function Header({ subItems, children, notifications: initialNotifications, // TODO: Fetch these from the internets
25
- link: Link, host, pathname }: {
25
+ link: Link, host, pathname, topCssVariable }: {
26
26
  subItems?: Array<SubHeaderItem>;
27
27
  children?: ReactNode;
28
28
  notifications?: Array<Notification>;
29
29
  link?: ElementType;
30
30
  host?: string;
31
31
  pathname?: string;
32
+ topCssVariable?: boolean;
32
33
  }): import("react/jsx-runtime").JSX.Element;
@@ -1,23 +1,23 @@
1
- import { jsx as e, jsxs as i, Fragment as z } from "react/jsx-runtime";
2
- import { useRef as A, useState as Q, useEffect as L } from "react";
3
- import { a as S, J } from "../../utils-C7rfowvr.js";
4
- import { A as U } from "../../Announcement03-obPaH4LK.js";
1
+ import { jsx as e, jsxs as i, Fragment as A } from "react/jsx-runtime";
2
+ import { useRef as J, useState as L, useEffect as T } from "react";
3
+ import { a as M, J as U } from "../../utils-C7rfowvr.js";
4
+ import { A as G } from "../../Announcement03-obPaH4LK.js";
5
5
  import { _ as m } from "../../extends-hS2Bh-Yp.js";
6
- import { N as G, X as R } from "../../index-pnL-sAld.js";
6
+ import { N as R, X as $ } from "../../index-pnL-sAld.js";
7
7
  import { c as k } from "../../clsx-OuTLNxxd.js";
8
8
  import { Button as h } from "../Button/index.js";
9
- import { Container as P } from "../Container/index.js";
10
- import { ThemedLogo as y } from "../Logo/index.js";
11
- import { NewTag as Y } from "../NewTag/index.js";
12
- import { PrefPanel as T } from "../PrefPanel/index.js";
13
- var F = function(n) {
9
+ import { Container as V } from "../Container/index.js";
10
+ import { ThemedLogo as H } from "../Logo/index.js";
11
+ import { NewTag as F } from "../NewTag/index.js";
12
+ import { PrefPanel as I } from "../PrefPanel/index.js";
13
+ var Y = function(o) {
14
14
  return /* @__PURE__ */ e("svg", m({
15
15
  xmlns: "http://www.w3.org/2000/svg",
16
16
  width: 24,
17
17
  height: 24,
18
18
  fill: "none",
19
19
  viewBox: "0 0 24 24"
20
- }, n, {
20
+ }, o, {
21
21
  children: /* @__PURE__ */ e("path", {
22
22
  stroke: "currentColor",
23
23
  strokeLinecap: "round",
@@ -26,14 +26,14 @@ var F = function(n) {
26
26
  d: "M6 11v4m12-6v4m-1-9c2.4487 0 3.7731.3748 4.4321.6654.0878.0388.1317.0581.2583.179.0759.0724.2145.285.2501.3837.0595.1646.0595.2546.0595.4346v10.7484c0 .9088 0 1.3632-.1363 1.5968-.1386.2375-.2723.348-.5318.4393-.255.0897-.7699-.0092-1.7997-.2071A13.45 13.45 0 0 0 17 18c-3 0-6 2-10 2-2.4487 0-3.7731-.3748-4.4321-.6654-.0878-.0388-.1317-.0581-.2583-.179-.076-.0724-.2145-.285-.2501-.3837C2 18.6073 2 18.5173 2 18.3373V7.5889c0-.9088 0-1.3632.1363-1.5968.1386-.2375.2723-.348.5318-.4393.255-.0898.77.0092 1.7997.207A13.44 13.44 0 0 0 7 6c3 0 6-2 10-2m-2.5 8c0 1.3807-1.1193 2.5-2.5 2.5S9.5 13.3807 9.5 12s1.1193-2.5 2.5-2.5 2.5 1.1193 2.5 2.5"
27
27
  })
28
28
  }));
29
- }, D = function(n) {
29
+ }, D = function(o) {
30
30
  return /* @__PURE__ */ e("svg", m({
31
31
  xmlns: "http://www.w3.org/2000/svg",
32
32
  width: 24,
33
33
  height: 24,
34
34
  fill: "none",
35
35
  viewBox: "0 0 24 24"
36
- }, n, {
36
+ }, o, {
37
37
  children: /* @__PURE__ */ e("path", {
38
38
  stroke: "currentColor",
39
39
  strokeLinecap: "round",
@@ -42,14 +42,14 @@ var F = function(n) {
42
42
  d: "M11 3H7.8c-1.6802 0-2.5202 0-3.162.327a3 3 0 0 0-1.311 1.311C3 5.2798 3 6.1198 3 7.8v8.4c0 1.6802 0 2.5202.327 3.162a3 3 0 0 0 1.311 1.311C5.2798 21 6.1198 21 7.8 21h8.4c1.6802 0 2.5202 0 3.162-.327a3 3 0 0 0 1.311-1.311C21 18.7202 21 17.8802 21 16.2V13m-9-5h4v4m-.5-8.5V2m3.9393 2.5607L20.5 3.5m.0103 5h1.5M3 13.3471c.652.1007 1.3199.1529 2 .1529 4.3864 0 8.2653-2.1724 10.6197-5.5"
43
43
  })
44
44
  }));
45
- }, K = function(n) {
45
+ }, K = function(o) {
46
46
  return /* @__PURE__ */ e("svg", m({
47
47
  xmlns: "http://www.w3.org/2000/svg",
48
48
  width: 24,
49
49
  height: 24,
50
50
  fill: "none",
51
51
  viewBox: "0 0 24 24"
52
- }, n, {
52
+ }, o, {
53
53
  children: /* @__PURE__ */ e("path", {
54
54
  stroke: "currentColor",
55
55
  strokeLinecap: "round",
@@ -58,14 +58,14 @@ var F = function(n) {
58
58
  d: "M14 2.2695v4.1306c0 .56 0 .84.109 1.054a1 1 0 0 0 .437.437C14.7599 8 15.0399 8 15.6 8h4.1305M16 13H8m8 4H8m2-8H8m6-7H8.8c-1.6802 0-2.5202 0-3.162.327a3 3 0 0 0-1.311 1.311C4 4.2798 4 5.1198 4 6.8v10.4c0 1.6802 0 2.5202.327 3.162a3 3 0 0 0 1.311 1.311C6.2798 22 7.1198 22 8.8 22h6.4c1.6802 0 2.5202 0 3.162-.327a3 3 0 0 0 1.311-1.311C20 19.7202 20 18.8802 20 17.2V8z"
59
59
  })
60
60
  }));
61
- }, X = function(n) {
61
+ }, X = function(o) {
62
62
  return /* @__PURE__ */ e("svg", m({
63
63
  xmlns: "http://www.w3.org/2000/svg",
64
64
  width: 24,
65
65
  height: 24,
66
66
  fill: "none",
67
67
  viewBox: "0 0 24 24"
68
- }, n, {
68
+ }, o, {
69
69
  children: /* @__PURE__ */ e("path", {
70
70
  stroke: "currentColor",
71
71
  strokeLinecap: "round",
@@ -74,14 +74,14 @@ var F = function(n) {
74
74
  d: "M3 12h12M3 6h18M3 18h18"
75
75
  })
76
76
  }));
77
- }, $ = function(n) {
77
+ }, Z = function(o) {
78
78
  return /* @__PURE__ */ e("svg", m({
79
79
  xmlns: "http://www.w3.org/2000/svg",
80
80
  width: 24,
81
81
  height: 24,
82
82
  fill: "none",
83
83
  viewBox: "0 0 24 24"
84
- }, n, {
84
+ }, o, {
85
85
  children: /* @__PURE__ */ e("path", {
86
86
  stroke: "currentColor",
87
87
  strokeLinecap: "round",
@@ -90,14 +90,14 @@ var F = function(n) {
90
90
  d: "M10 8.0022a2.2485 2.2485 0 0 1 2.501-1.4698 2.248 2.248 0 0 1 1.8682 2.2193c0 1.4989-2.2483 2.2483-2.2483 2.2483m.029 3h.01M7 18v2.3355c0 .5329 0 .7993.1092.9361a.5.5 0 0 0 .3913.1881c.1751-.0002.3832-.1666.7993-.4995l2.3854-1.9084c.4873-.3898.731-.5847 1.0023-.7233a3 3 0 0 1 .7617-.2672C12.7477 18 13.0597 18 13.6837 18H16.2c1.6802 0 2.5202 0 3.162-.327a3 3 0 0 0 1.311-1.311C21 15.7202 21 14.8802 21 13.2V7.8c0-1.6802 0-2.5202-.327-3.162a3 3 0 0 0-1.311-1.311C18.7202 3 17.8802 3 16.2 3H7.8c-1.6802 0-2.5202 0-3.162.327a3 3 0 0 0-1.311 1.311C3 5.2798 3 6.1198 3 7.8V14c0 .93 0 1.395.1022 1.7765a3 3 0 0 0 2.1213 2.1213C5.605 18 6.07 18 7 18"
91
91
  })
92
92
  }));
93
- }, Z = function(n) {
93
+ }, ee = function(o) {
94
94
  return /* @__PURE__ */ e("svg", m({
95
95
  xmlns: "http://www.w3.org/2000/svg",
96
96
  width: 24,
97
97
  height: 24,
98
98
  fill: "none",
99
99
  viewBox: "0 0 24 24"
100
- }, n, {
100
+ }, o, {
101
101
  children: /* @__PURE__ */ e("path", {
102
102
  stroke: "currentColor",
103
103
  strokeLinecap: "round",
@@ -106,14 +106,14 @@ var F = function(n) {
106
106
  d: "M12 16v5m6 0-3.9514-3.2928c-.7288-.6074-1.0932-.911-1.4999-1.0271a2 2 0 0 0-1.0974 0c-.4067.1161-.7711.4197-1.4999 1.0271L6 21m2-10v1m4-3v3m4-5v5m6-9H2m1 0h18v8.2c0 1.6802 0 2.5202-.327 3.162a3 3 0 0 1-1.311 1.311C18.7202 16 17.8802 16 16.2 16H7.8c-1.6802 0-2.5202 0-3.162-.327a3 3 0 0 1-1.311-1.311C3 13.7202 3 12.8802 3 11.2z"
107
107
  })
108
108
  }));
109
- }, H = function(n) {
109
+ }, W = function(o) {
110
110
  return /* @__PURE__ */ e("svg", m({
111
111
  xmlns: "http://www.w3.org/2000/svg",
112
112
  width: 24,
113
113
  height: 24,
114
114
  fill: "none",
115
115
  viewBox: "0 0 24 24"
116
- }, n, {
116
+ }, o, {
117
117
  children: /* @__PURE__ */ e("path", {
118
118
  stroke: "currentColor",
119
119
  strokeLinecap: "round",
@@ -122,14 +122,14 @@ var F = function(n) {
122
122
  d: "m21 21-4.35-4.35M19 11c0 4.4183-3.5817 8-8 8s-8-3.5817-8-8 3.5817-8 8-8 8 3.5817 8 8"
123
123
  })
124
124
  }));
125
- }, I = function(n) {
125
+ }, j = function(o) {
126
126
  return /* @__PURE__ */ e("svg", m({
127
127
  xmlns: "http://www.w3.org/2000/svg",
128
128
  width: 24,
129
129
  height: 24,
130
130
  fill: "none",
131
131
  viewBox: "0 0 24 24"
132
- }, n, {
132
+ }, o, {
133
133
  children: /* @__PURE__ */ e("path", {
134
134
  stroke: "currentColor",
135
135
  strokeLinecap: "round",
@@ -138,14 +138,14 @@ var F = function(n) {
138
138
  d: "M4.5 22v-5m0-10V2M2 4.5h5m-5 15h5M13 3l-1.7342 4.5089c-.282.7332-.423 1.0998-.6423 1.4082a3 3 0 0 1-.7064.7064c-.3084.2193-.675.3603-1.4082.6423L4 12l4.5089 1.7342c.7332.282 1.0998.423 1.4082.6423.2733.1943.5121.4331.7064.7064.2193.3084.3603.675.6423 1.4082L13 21l1.7342-4.5089c.282-.7332.423-1.0998.6423-1.4082a3 3 0 0 1 .7064-.7064c.3084-.2193.675-.3603 1.4082-.6423L22 12l-4.5089-1.7342c-.7332-.282-1.0998-.423-1.4082-.6423a3 3 0 0 1-.7064-.7064c-.2193-.3084-.3603-.675-.6423-1.4082z"
139
139
  })
140
140
  }));
141
- }, W = function(n) {
141
+ }, P = function(o) {
142
142
  return /* @__PURE__ */ e("svg", m({
143
143
  xmlns: "http://www.w3.org/2000/svg",
144
144
  width: 24,
145
145
  height: 24,
146
146
  fill: "none",
147
147
  viewBox: "0 0 24 24"
148
- }, n, {
148
+ }, o, {
149
149
  children: /* @__PURE__ */ e("path", {
150
150
  stroke: "currentColor",
151
151
  strokeLinecap: "round",
@@ -154,14 +154,14 @@ var F = function(n) {
154
154
  d: "m7 15 3-3-3-3m6 6h4m-9.2 6h8.4c1.6802 0 2.5202 0 3.162-.327a3 3 0 0 0 1.311-1.311C21 18.7202 21 17.8802 21 16.2V7.8c0-1.6802 0-2.5202-.327-3.162a3 3 0 0 0-1.311-1.311C18.7202 3 17.8802 3 16.2 3H7.8c-1.6802 0-2.5202 0-3.162.327a3 3 0 0 0-1.311 1.311C3 5.2798 3 6.1198 3 7.8v8.4c0 1.6802 0 2.5202.327 3.162a3 3 0 0 0 1.311 1.311C5.2798 21 6.1198 21 7.8 21"
155
155
  })
156
156
  }));
157
- }, j = function(n) {
157
+ }, E = function(o) {
158
158
  return /* @__PURE__ */ e("svg", m({
159
159
  xmlns: "http://www.w3.org/2000/svg",
160
160
  width: 24,
161
161
  height: 24,
162
162
  fill: "none",
163
163
  viewBox: "0 0 24 24"
164
- }, n, {
164
+ }, o, {
165
165
  children: /* @__PURE__ */ e("path", {
166
166
  stroke: "currentColor",
167
167
  strokeLinecap: "round",
@@ -171,27 +171,27 @@ var F = function(n) {
171
171
  })
172
172
  }));
173
173
  };
174
- const ee = "m_QBtq_buttons", te = "m_QBtq_container", ne = "m_QBtq_gpt", re = "m_QBtq_header", oe = "m_QBtq_icon", se = "m_QBtq_icons", ie = "m_QBtq_links", ce = "m_QBtq_logo", ae = "m_QBtq_main", le = "m_QBtq_menu", he = "m_QBtq_mobile", de = "m_QBtq_mobileOverlay", me = "m_QBtq_open", ue = "m_QBtq_outer", pe = "m_QBtq_selectableIcon", we = "m_QBtq_selected", ge = "m_QBtq_selectedIcon", ve = "m_QBtq_skip", fe = "m_QBtq_sub", ke = "m_QBtq_subContainer", Ce = "m_QBtq_subTitle", t = {
175
- buttons: ee,
176
- container: te,
177
- gpt: ne,
174
+ const te = "m_QBtq_buttons", ne = "m_QBtq_container", oe = "m_QBtq_gpt", re = "m_QBtq_header", se = "m_QBtq_icon", ie = "m_QBtq_icons", ce = "m_QBtq_links", ae = "m_QBtq_logo", le = "m_QBtq_main", he = "m_QBtq_menu", de = "m_QBtq_mobile", me = "m_QBtq_mobileOverlay", ue = "m_QBtq_open", pe = "m_QBtq_outer", we = "m_QBtq_selectableIcon", ge = "m_QBtq_selected", ve = "m_QBtq_selectedIcon", fe = "m_QBtq_skip", ke = "m_QBtq_sub", _e = "m_QBtq_subContainer", Ce = "m_QBtq_subTitle", t = {
175
+ buttons: te,
176
+ container: ne,
177
+ gpt: oe,
178
178
  header: re,
179
- icon: oe,
180
- icons: se,
181
- links: ie,
182
- logo: ce,
183
- main: ae,
184
- menu: le,
185
- mobile: he,
186
- mobileOverlay: de,
187
- open: me,
188
- outer: ue,
189
- selectableIcon: pe,
190
- selected: we,
191
- selectedIcon: ge,
192
- skip: ve,
193
- sub: fe,
194
- subContainer: ke,
179
+ icon: se,
180
+ icons: ie,
181
+ links: ce,
182
+ logo: ae,
183
+ main: le,
184
+ menu: he,
185
+ mobile: de,
186
+ mobileOverlay: me,
187
+ open: ue,
188
+ outer: pe,
189
+ selectableIcon: we,
190
+ selected: ge,
191
+ selectedIcon: ve,
192
+ skip: fe,
193
+ sub: ke,
194
+ subContainer: _e,
195
195
  subTitle: Ce
196
196
  }, O = [
197
197
  {
@@ -202,12 +202,12 @@ const ee = "m_QBtq_buttons", te = "m_QBtq_container", ne = "m_QBtq_gpt", re = "m
202
202
  {
203
203
  title: "Demos",
204
204
  url: "https://www.highcharts.com/demo",
205
- icon: /* @__PURE__ */ e(Z, {})
205
+ icon: /* @__PURE__ */ e(ee, {})
206
206
  },
207
207
  {
208
208
  title: "Support",
209
209
  url: "https://www.highcharts.com/support/",
210
- icon: /* @__PURE__ */ e($, {})
210
+ icon: /* @__PURE__ */ e(Z, {})
211
211
  },
212
212
  {
213
213
  title: "Resources",
@@ -217,116 +217,121 @@ const ee = "m_QBtq_buttons", te = "m_QBtq_container", ne = "m_QBtq_gpt", re = "m
217
217
  {
218
218
  title: "Pricing",
219
219
  url: "https://shop.highcharts.com/",
220
- icon: /* @__PURE__ */ e(F, {})
220
+ icon: /* @__PURE__ */ e(Y, {})
221
221
  },
222
222
  {
223
223
  title: "Blog",
224
224
  url: "https://www.highcharts.com/blog/",
225
- icon: /* @__PURE__ */ e(U, {})
225
+ icon: /* @__PURE__ */ e(G, {})
226
226
  }
227
227
  ];
228
- function d(c, n) {
229
- return n ? c.replace(n, "") : c;
228
+ function d(c, o) {
229
+ return o ? c.replace(o, "") : c;
230
230
  }
231
231
  function be({
232
232
  items: c,
233
- link: n = "a",
233
+ link: o = "a",
234
234
  host: p = "https://www.highcharts.com",
235
235
  pathname: a = typeof window < "u" ? window.location.pathname : ""
236
236
  }) {
237
- return /* @__PURE__ */ e("div", { className: k(t.sub, t.outer), children: /* @__PURE__ */ e(P, { className: t.subContainer, as: "ul", children: c.map(
238
- ({ title: l, url: C, icon: b, selectedIcon: _, tag: B, tagVariant: g = "success" }, u) => {
239
- const x = typeof window < "u" && window.location.origin || "http://example.com", v = new URL(C, x), f = v.origin === x && v.pathname === a;
237
+ return /* @__PURE__ */ e("div", { className: k(t.sub, t.outer), children: /* @__PURE__ */ e(V, { className: t.subContainer, as: "ul", children: c.map(
238
+ ({ title: l, url: _, icon: g, selectedIcon: v, tag: B, tagVariant: N = "success" }, f) => {
239
+ const u = typeof window < "u" && window.location.origin || "http://example.com", C = new URL(_, u), b = C.origin === u && C.pathname === a;
240
240
  return /* @__PURE__ */ e("li", { children: /* @__PURE__ */ i(
241
- n,
241
+ o,
242
242
  {
243
- href: d(C, p),
243
+ href: d(_, p),
244
244
  className: k({
245
- [t.selectableIcon]: _,
246
- [t.selected]: f
245
+ [t.selectableIcon]: v,
246
+ [t.selected]: b
247
247
  }),
248
248
  children: [
249
249
  /* @__PURE__ */ i("span", { className: t.icons, children: [
250
- /* @__PURE__ */ e("span", { className: t.selectedIcon, children: _ }),
251
- /* @__PURE__ */ e("span", { className: t.icon, children: b })
250
+ /* @__PURE__ */ e("span", { className: t.selectedIcon, children: v }),
251
+ /* @__PURE__ */ e("span", { className: t.icon, children: g })
252
252
  ] }),
253
253
  /* @__PURE__ */ i("span", { className: t.subTitle, children: [
254
254
  l,
255
- B && /* @__PURE__ */ e(Y, { variant: g, icon: !1 })
255
+ B && /* @__PURE__ */ e(F, { variant: N, icon: !1 })
256
256
  ] })
257
257
  ]
258
258
  }
259
- ) }, u);
259
+ ) }, f);
260
260
  }
261
261
  ) }) });
262
262
  }
263
- function Ie({
263
+ function We({
264
264
  subItems: c,
265
- children: n,
265
+ children: o,
266
266
  notifications: p = [],
267
267
  // TODO: Fetch these from the internets
268
268
  link: a = "a",
269
269
  host: l = "https://www.highcharts.com",
270
- pathname: C = typeof window < "u" ? window.location.pathname : ""
270
+ pathname: _ = typeof window < "u" ? window.location.pathname : "",
271
+ topCssVariable: g
271
272
  }) {
272
- const b = S("(max-width: 374px)"), _ = S("(max-width: 849px)"), B = S("(min-width: 850px) and (max-width: 999px)"), g = A(null), [u, x] = Q(!1), [v, f] = Q([]);
273
- L(() => {
274
- let o = window.scrollY, r = -82, s = r;
273
+ const v = M("(max-width: 374px)"), B = M("(max-width: 849px)"), N = M("(min-width: 850px) and (max-width: 999px)"), f = J(null), [u, C] = L(!1), [b, S] = L([]);
274
+ T(() => {
275
+ let r = window.scrollY, n = -82, s = n;
276
+ g && document.documentElement.style.setProperty("--header-top", `${n}px`);
275
277
  const w = () => {
276
- const N = window.scrollY - o;
277
- r -= N, r < -82 ? r = -82 : r > 0 && (r = 0), g.current && r !== s && (g.current.style.top = `${r}px`), o = window.scrollY, s = r;
278
+ const x = window.scrollY, q = x - r;
279
+ n -= q, n < -82 ? n = -82 : n > 0 && (n = 0), f.current && n !== s && (f.current.style.top = `${n}px`, g && document.documentElement.style.setProperty(
280
+ "--header-top",
281
+ `${n}px`
282
+ )), r = x, s = n;
278
283
  };
279
284
  return window.addEventListener("scroll", w), () => window.removeEventListener("scroll", w);
280
- }, []), L(() => {
285
+ }, [g]), T(() => {
281
286
  if (p.length) {
282
- const o = localStorage.getItem("notifications");
283
- if (o) {
284
- const r = JSON.parse(o);
285
- f(
287
+ const r = localStorage.getItem("notifications");
288
+ if (r) {
289
+ const n = JSON.parse(r);
290
+ S(
286
291
  p.filter(
287
- (s) => !s.id || !r.closed.includes(s.id)
292
+ (s) => !s.id || !n.closed.includes(s.id)
288
293
  )
289
294
  );
290
295
  } else
291
- f(p);
296
+ S(p);
292
297
  }
293
298
  }, [p]);
294
- const q = (o) => {
295
- if (o.preventDefault(), !(o.nativeEvent instanceof KeyboardEvent) || o.nativeEvent.code === "Enter" || o.nativeEvent.code === "Space") {
296
- const r = document.querySelector("main");
297
- r && (r.scrollIntoView(), r.getAttribute("tabindex") !== "-1" && r.setAttribute("tabindex", "-1"), r.focus());
299
+ const Q = (r) => {
300
+ if (r.preventDefault(), !(r.nativeEvent instanceof KeyboardEvent) || r.nativeEvent.code === "Enter" || r.nativeEvent.code === "Space") {
301
+ const n = document.querySelector("main");
302
+ n && (n.scrollIntoView(), n.getAttribute("tabindex") !== "-1" && n.setAttribute("tabindex", "-1"), n.focus());
298
303
  }
299
- }, M = () => {
300
- x(!u);
301
- }, V = (o) => {
302
- f(v.filter((s) => !s.id || s.id !== o));
303
- const r = localStorage.getItem("notifications");
304
- if (r) {
305
- const s = JSON.parse(r);
306
- s.closed.includes(o) || (s.closed.push(o), localStorage.setItem("notifications", JSON.stringify(s)));
304
+ }, y = () => {
305
+ C(!u);
306
+ }, z = (r) => {
307
+ S(b.filter((s) => !s.id || s.id !== r));
308
+ const n = localStorage.getItem("notifications");
309
+ if (n) {
310
+ const s = JSON.parse(n);
311
+ s.closed.includes(r) || (s.closed.push(r), localStorage.setItem("notifications", JSON.stringify(s)));
307
312
  } else
308
313
  localStorage.setItem(
309
314
  "notifications",
310
315
  JSON.stringify({
311
- closed: [o]
316
+ closed: [r]
312
317
  })
313
318
  );
314
319
  };
315
- return /* @__PURE__ */ e(J, { children: /* @__PURE__ */ i("header", { className: t.header, ref: g, children: [
316
- v?.map(
317
- ({ id: o, title: r, description: s, variant: w, closable: N }, E) => /* @__PURE__ */ e(
318
- G,
320
+ return /* @__PURE__ */ e(U, { children: /* @__PURE__ */ i("header", { className: t.header, ref: f, children: [
321
+ b?.map(
322
+ ({ id: r, title: n, description: s, variant: w, closable: x }, q) => /* @__PURE__ */ e(
323
+ R,
319
324
  {
320
325
  description: s,
321
326
  variant: w,
322
- closable: N,
323
- onClose: () => V(o),
324
- children: r
327
+ closable: x,
328
+ onClose: () => z(r),
329
+ children: n
325
330
  },
326
- E
331
+ q
327
332
  )
328
333
  ),
329
- /* @__PURE__ */ e("div", { className: k(t.main, t.outer), children: /* @__PURE__ */ i(P, { as: "nav", className: t.container, children: [
334
+ /* @__PURE__ */ e("div", { className: k(t.main, t.outer), children: /* @__PURE__ */ i(V, { as: "nav", className: t.container, children: [
330
335
  /* @__PURE__ */ e(
331
336
  h,
332
337
  {
@@ -334,8 +339,8 @@ function Ie({
334
339
  className: t.skip,
335
340
  size: 500,
336
341
  tabIndex: "0",
337
- onClick: q,
338
- onKeyPress: q,
342
+ onClick: Q,
343
+ onKeyPress: Q,
339
344
  children: "Skip to content"
340
345
  }
341
346
  ),
@@ -344,17 +349,17 @@ function Ie({
344
349
  {
345
350
  className: t.logo,
346
351
  href: d("https://www.highcharts.com/", l),
347
- children: /* @__PURE__ */ e(y, { showText: !B && !b })
352
+ children: /* @__PURE__ */ e(H, { showText: !N && !v })
348
353
  }
349
354
  ),
350
- /* @__PURE__ */ e("ul", { className: t.links, children: O.map(({ title: o, url: r }, s) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e(
355
+ /* @__PURE__ */ e("ul", { className: t.links, children: O.map(({ title: r, url: n }, s) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ e(
351
356
  h,
352
357
  {
353
358
  variant: "plain",
354
359
  size: 300,
355
360
  as: a,
356
- href: d(r, l),
357
- children: o
361
+ href: d(n, l),
362
+ children: r
358
363
  }
359
364
  ) }, s)) }),
360
365
  /* @__PURE__ */ i("div", { className: t.buttons, children: [
@@ -369,12 +374,12 @@ function Ie({
369
374
  ),
370
375
  children: [
371
376
  /* @__PURE__ */ e("span", { className: t.gpt, children: "Highcharts GPT" }),
372
- /* @__PURE__ */ e(I, {})
377
+ /* @__PURE__ */ e(j, {})
373
378
  ]
374
379
  }
375
380
  ),
376
- /* @__PURE__ */ e(h, { variant: "transparent", "aria-label": "Search", children: /* @__PURE__ */ e(H, {}) }),
377
- /* @__PURE__ */ e(T, {}),
381
+ /* @__PURE__ */ e(h, { variant: "transparent", "aria-label": "Search", children: /* @__PURE__ */ e(W, {}) }),
382
+ /* @__PURE__ */ e(I, {}),
378
383
  /* @__PURE__ */ e(
379
384
  h,
380
385
  {
@@ -382,7 +387,7 @@ function Ie({
382
387
  as: a,
383
388
  href: d("https://shop.highcharts.com/account", l),
384
389
  "aria-label": "Login",
385
- children: /* @__PURE__ */ e(j, {})
390
+ children: /* @__PURE__ */ e(E, {})
386
391
  }
387
392
  ),
388
393
  /* @__PURE__ */ i(
@@ -395,7 +400,7 @@ function Ie({
395
400
  l
396
401
  ),
397
402
  children: [
398
- /* @__PURE__ */ e(W, {}),
403
+ /* @__PURE__ */ e(P, {}),
399
404
  "Get started"
400
405
  ]
401
406
  }
@@ -405,10 +410,10 @@ function Ie({
405
410
  {
406
411
  variant: u ? "white" : "transparent",
407
412
  className: t.menu,
408
- onClick: M,
413
+ onClick: y,
409
414
  children: [
410
415
  u ? "Close" : "Menu",
411
- u ? /* @__PURE__ */ e(R, {}) : /* @__PURE__ */ e(X, {})
416
+ u ? /* @__PURE__ */ e($, {}) : /* @__PURE__ */ e(X, {})
412
417
  ]
413
418
  }
414
419
  )
@@ -420,16 +425,16 @@ function Ie({
420
425
  items: c,
421
426
  link: a,
422
427
  host: l,
423
- pathname: C
428
+ pathname: _
424
429
  }
425
430
  ),
426
- n,
427
- _ && /* @__PURE__ */ i(z, { children: [
431
+ o,
432
+ B && /* @__PURE__ */ i(A, { children: [
428
433
  /* @__PURE__ */ e(
429
434
  "div",
430
435
  {
431
436
  className: k(t.mobileOverlay, { [t.open]: u }),
432
- onClick: M
437
+ onClick: y
433
438
  }
434
439
  ),
435
440
  /* @__PURE__ */ i(
@@ -445,7 +450,7 @@ function Ie({
445
450
  {
446
451
  className: t.logo,
447
452
  href: d("https://www.highcharts.com/", l),
448
- children: /* @__PURE__ */ e(y, { showText: !b })
453
+ children: /* @__PURE__ */ e(H, { showText: !v })
449
454
  }
450
455
  ),
451
456
  /* @__PURE__ */ i("div", { className: t.buttons, children: [
@@ -460,12 +465,12 @@ function Ie({
460
465
  ),
461
466
  children: [
462
467
  /* @__PURE__ */ e("span", { className: t.gpt, children: "Highcharts GPT" }),
463
- /* @__PURE__ */ e(I, {})
468
+ /* @__PURE__ */ e(j, {})
464
469
  ]
465
470
  }
466
471
  ),
467
- /* @__PURE__ */ e(h, { variant: "transparent", "aria-label": "Search", children: /* @__PURE__ */ e(H, {}) }),
468
- /* @__PURE__ */ e(T, {})
472
+ /* @__PURE__ */ e(h, { variant: "transparent", "aria-label": "Search", children: /* @__PURE__ */ e(W, {}) }),
473
+ /* @__PURE__ */ e(I, {})
469
474
  ] })
470
475
  ] }),
471
476
  /* @__PURE__ */ i("div", { className: t.buttons, children: [
@@ -480,7 +485,7 @@ function Ie({
480
485
  l
481
486
  ),
482
487
  children: [
483
- /* @__PURE__ */ e(j, {}),
488
+ /* @__PURE__ */ e(E, {}),
484
489
  "Login"
485
490
  ]
486
491
  }
@@ -496,23 +501,23 @@ function Ie({
496
501
  l
497
502
  ),
498
503
  children: [
499
- /* @__PURE__ */ e(W, {}),
504
+ /* @__PURE__ */ e(P, {}),
500
505
  "Get started"
501
506
  ]
502
507
  }
503
508
  )
504
509
  ] }),
505
- /* @__PURE__ */ e("ul", { className: t.links, children: O.map(({ title: o, url: r, icon: s }, w) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ i(
510
+ /* @__PURE__ */ e("ul", { className: t.links, children: O.map(({ title: r, url: n, icon: s }, w) => /* @__PURE__ */ e("li", { children: /* @__PURE__ */ i(
506
511
  h,
507
512
  {
508
513
  variant: "plain",
509
514
  size: 500,
510
515
  fullWidth: !0,
511
516
  as: a,
512
- href: d(r, l),
517
+ href: d(n, l),
513
518
  children: [
514
519
  s,
515
- o
520
+ r
516
521
  ]
517
522
  }
518
523
  ) }, w)) })
@@ -523,6 +528,6 @@ function Ie({
523
528
  ] }) });
524
529
  }
525
530
  export {
526
- Ie as Header,
531
+ We as Header,
527
532
  be as SubHeader
528
533
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "highsoft-ui",
3
- "version": "1.0.72",
3
+ "version": "1.0.74",
4
4
  "description": "Highsoft UI",
5
5
  "type": "module",
6
6
  "main": "dist/main.js",