@arkitektbedriftene/fe-lib 4.2.2 → 4.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,109 +1,110 @@
1
- var ce = Object.defineProperty;
2
- var de = (t, r, e) => r in t ? ce(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
3
- var O = (t, r, e) => (de(t, typeof r != "symbol" ? r + "" : r, e), e);
4
- import { createHeadlessEditor as At } from "@lexical/headless";
5
- import { $generateHtmlFromNodes as zt } from "@lexical/html";
6
- import { $getRoot as G, ParagraphNode as he, $createParagraphNode as W, $createTextNode as I, $setSelection as V, $getNodeByKey as ot, DecoratorNode as ue, $applyNodeReplacement as ge, SELECTION_CHANGE_COMMAND as Y, $getSelection as y, COMMAND_PRIORITY_CRITICAL as ct, $isRangeSelection as N, $isRootOrShadowRoot as $t, FORMAT_TEXT_COMMAND as K, COMMAND_PRIORITY_LOW as R, KEY_ARROW_DOWN_COMMAND as pe, KEY_ARROW_UP_COMMAND as me, KEY_ESCAPE_COMMAND as Dt, KEY_SPACE_COMMAND as fe, $getNearestNodeFromDOMNode as dt, KEY_ARROW_LEFT_COMMAND as ke, $isElementNode as be, createCommand as Me, $insertNodes as Ce, COMMAND_PRIORITY_EDITOR as ve, COMMAND_PRIORITY_NORMAL as Te, $createRangeSelection as Bt, COMMAND_PRIORITY_HIGH as _e, FORMAT_ELEMENT_COMMAND as it } from "lexical";
7
- import { trimTextContentFromAnchor as Le, $setBlocksType as at, $isAtNodeEnd as Lt } from "@lexical/selection";
8
- import { $dfs as xe, $getNearestNodeOfType as we, $findMatchingParent as Pt, mergeRegister as Z, isHTMLElement as xt, $wrapNodeInElement as ye, mediaFileReader as Ne, isMimeType as Se } from "@lexical/utils";
9
- import { LinkNode as F, AutoLinkNode as Ft, $isLinkNode as J, TOGGLE_LINK_COMMAND as tt } from "@lexical/link";
10
- import { ListNode as ht, ListItemNode as Ht, $isListNode as ut, INSERT_UNORDERED_LIST_COMMAND as Ee, INSERT_ORDERED_LIST_COMMAND as Re, INSERT_CHECK_LIST_COMMAND as Ut, insertList as Ie, $isListItemNode as H } from "@lexical/list";
11
- import { HeadingNode as Wt, QuoteNode as jt, $isHeadingNode as Oe, $createHeadingNode as Ae, $createQuoteNode as ze, DRAG_DROP_PASTE as $e } from "@lexical/rich-text";
12
- import { TableNode as Kt, TableRowNode as Gt, TableCellNode as Yt, INSERT_TABLE_COMMAND as De, $getTableCellNodeFromLexicalNode as Be, $deleteTableColumn__EXPERIMENTAL as Pe, $deleteTableRow__EXPERIMENTAL as Fe, $insertTableColumn__EXPERIMENTAL as wt, $insertTableRow__EXPERIMENTAL as yt } from "@lexical/table";
13
- import { jsx as o, jsxs as u, Fragment as j } from "react/jsx-runtime";
14
- import { createContext as He, useState as b, useRef as q, useCallback as T, useContext as Ue, useEffect as _, useMemo as qt, useLayoutEffect as We } from "react";
15
- import { Box as U, Stack as je, Button as L, DropdownMenu as et, ToolbarButton as gt, DropdownMenuIconItem as v, ToolbarToggleGroup as Jt, ToolbarToggleItem as P, OverlayCard as Xt, Toolbar as Ke, ToolbarSeparator as Ge, styled as Ye, Spinner as pt, Dialog as Qt, DialogHeader as qe, TextInput as mt, DialogActions as rt, DropdownMenuItem as B, DropdownMenuSeparator as Nt, NavBar as Je, NavBarItem as lt, Combobox as Xe } from "./ui.es.js";
16
- import { f as Qe, g as Ve, h as Ze, G as f, i as tr, j as er } from "./index.esm-787a7997.js";
1
+ var Ce = Object.defineProperty;
2
+ var Me = (t, r, e) => r in t ? Ce(t, r, { enumerable: !0, configurable: !0, writable: !0, value: e }) : t[r] = e;
3
+ var $ = (t, r, e) => (Me(t, typeof r != "symbol" ? r + "" : r, e), e);
4
+ import { createHeadlessEditor as Bt } from "@lexical/headless";
5
+ import { $generateHtmlFromNodes as Pt } from "@lexical/html";
6
+ import { $getRoot as Y, ParagraphNode as Te, $createParagraphNode as G, $createTextNode as z, $setSelection as nt, $getNodeByKey as ct, DecoratorNode as xe, $applyNodeReplacement as Le, SELECTION_CHANGE_COMMAND as X, $getSelection as L, COMMAND_PRIORITY_EDITOR as q, $isRangeSelection as N, $isRootOrShadowRoot as Ft, FORMAT_TEXT_COMMAND as A, COMMAND_PRIORITY_LOW as D, KEY_ARROW_DOWN_COMMAND as _e, KEY_ARROW_UP_COMMAND as we, KEY_ESCAPE_COMMAND as Ht, KEY_SPACE_COMMAND as ye, $getNearestNodeFromDOMNode as pt, KEY_ARROW_LEFT_COMMAND as Se, $isElementNode as Ne, createCommand as Ee, $insertNodes as Re, $createRangeSelection as Ut, COMMAND_PRIORITY_HIGH as Ie, FORMAT_ELEMENT_COMMAND as dt } from "lexical";
7
+ import { trimTextContentFromAnchor as Oe, $setBlocksType as ht, $getSelectionStyleValueForProperty as ze, $patchStyleText as $e, $isAtNodeEnd as yt } from "@lexical/selection";
8
+ import { $dfs as Ae, $getNearestNodeOfType as De, $findMatchingParent as Wt, mergeRegister as ot, isHTMLElement as St, $wrapNodeInElement as Be, mediaFileReader as Pe, isMimeType as Fe } from "@lexical/utils";
9
+ import { LinkNode as j, AutoLinkNode as jt, $isLinkNode as Z, TOGGLE_LINK_COMMAND as it } from "@lexical/link";
10
+ import { ListNode as mt, ListItemNode as Kt, $isListNode as ft, INSERT_UNORDERED_LIST_COMMAND as He, INSERT_ORDERED_LIST_COMMAND as Ue, INSERT_CHECK_LIST_COMMAND as Gt, insertList as We, $isListItemNode as K } from "@lexical/list";
11
+ import { HeadingNode as qt, QuoteNode as Jt, $isHeadingNode as je, $createHeadingNode as Ke, $createQuoteNode as Ge, DRAG_DROP_PASTE as qe } from "@lexical/rich-text";
12
+ import { TableNode as Yt, TableRowNode as Xt, TableCellNode as Vt, INSERT_TABLE_COMMAND as Je, $getTableCellNodeFromLexicalNode as Ye, $deleteTableColumn__EXPERIMENTAL as Xe, $deleteTableRow__EXPERIMENTAL as Ve, $insertTableColumn__EXPERIMENTAL as Nt, $insertTableRow__EXPERIMENTAL as Et } from "@lexical/table";
13
+ import { jsx as n, jsxs as h, Fragment as F } from "react/jsx-runtime";
14
+ import { createContext as Qe, useState as m, useRef as V, useCallback as M, useContext as Ze, useEffect as _, useMemo as Qt, useLayoutEffect as tr } from "react";
15
+ import { Box as P, Stack as er, Button as w, DropdownMenu as at, ToolbarButton as lt, DropdownMenuIconItem as T, ToolbarToggleGroup as tt, ToolbarToggleItem as O, Popover as Zt, PopoverTrigger as te, PopoverContent as ee, OverlayCard as re, Toolbar as rr, ToolbarSeparator as Rt, styled as nr, Spinner as kt, Dialog as ne, DialogHeader as or, TextInput as bt, DialogActions as st, DropdownMenuItem as W, DropdownMenuSeparator as It, NavBar as ir, NavBarItem as ut, Combobox as ar } from "./ui.es.js";
16
+ import { f as lr, g as sr, h as cr, G as f, i as dr, j as hr, k as ur, l as gr } from "./index.esm-fa9e6ea7.js";
17
17
  import { useLexicalComposerContext as x } from "@lexical/react/LexicalComposerContext.js";
18
- import { LexicalComposer as rr } from "@lexical/react/LexicalComposer.js";
19
- import { RichTextPlugin as nr } from "@lexical/react/LexicalRichTextPlugin.js";
20
- import { LexicalErrorBoundary as or } from "@lexical/react/LexicalErrorBoundary.js";
21
- import { useFloating as ft, autoUpdate as Vt, size as ir, flip as ar, offset as Zt, shift as lr, useInteractions as te, useRole as ee, FloatingPortal as re, inline as sr, useDismiss as cr } from "@floating-ui/react";
22
- import { s as dr, c as hr } from "./stitches.config-00c23cdb.js";
23
- import { ListPlugin as ur } from "@lexical/react/LexicalListPlugin.js";
24
- import { HistoryPlugin as gr } from "@lexical/react/LexicalHistoryPlugin.js";
25
- import { TablePlugin as pr } from "@lexical/react/LexicalTablePlugin.js";
26
- import { TabIndentationPlugin as mr } from "@lexical/react/LexicalTabIndentationPlugin.js";
27
- import { useLexicalComposerContext as kt } from "@lexical/react/LexicalComposerContext";
18
+ import { LexicalComposer as pr } from "@lexical/react/LexicalComposer.js";
19
+ import { RichTextPlugin as mr } from "@lexical/react/LexicalRichTextPlugin.js";
20
+ import { LexicalErrorBoundary as fr } from "@lexical/react/LexicalErrorBoundary.js";
21
+ import { useFloating as vt, autoUpdate as oe, size as kr, flip as br, offset as ie, shift as vr, useInteractions as ae, useRole as le, FloatingPortal as se, inline as Cr, useDismiss as Mr } from "@floating-ui/react";
22
+ import { s as Tr, c as xr } from "./stitches.config-00c23cdb.js";
23
+ import { ListPlugin as Lr } from "@lexical/react/LexicalListPlugin.js";
24
+ import { HistoryPlugin as _r } from "@lexical/react/LexicalHistoryPlugin.js";
25
+ import { TablePlugin as wr } from "@lexical/react/LexicalTablePlugin.js";
26
+ import { TabIndentationPlugin as yr } from "@lexical/react/LexicalTabIndentationPlugin.js";
27
+ import { useLexicalComposerContext as Ct } from "@lexical/react/LexicalComposerContext";
28
28
  import "@stitches/react";
29
- const fr = ({
29
+ const Sr = ({
30
30
  text: t,
31
31
  maxChars: r,
32
32
  maxLines: e
33
33
  }) => {
34
34
  if (t.length === 0)
35
35
  return 0;
36
- const n = typeof e == "number", i = typeof r == "number";
37
- if (!n && !i)
36
+ const o = typeof e == "number", i = typeof r == "number";
37
+ if (!o && !i)
38
38
  return t.length;
39
39
  let a = 0, l = 0;
40
- for (; l < t.length && (!n || a < e) && (!i || l < r); )
40
+ for (; l < t.length && (!o || a < e) && (!i || l < r); )
41
41
  t[l] === `
42
42
  ` && a++, l++;
43
43
  return t.slice(0, l).length;
44
- }, ne = ({
44
+ }, ce = ({
45
45
  editor: t,
46
46
  maxChars: r,
47
47
  maxLines: e
48
48
  }) => {
49
- const n = G(), i = n.getTextContent(), a = fr({ text: i, maxChars: r, maxLines: e }), l = i.length - a, d = n.select().anchor;
50
- Le(t, d, l);
51
- const c = n.getLastChild();
52
- return c instanceof he && c.getChildrenSize() === 0 && c.remove(), l;
53
- }, bt = {
49
+ const o = Y(), i = o.getTextContent(), a = Sr({ text: i, maxChars: r, maxLines: e }), l = i.length - a, d = o.select().anchor;
50
+ Oe(t, d, l);
51
+ const c = o.getLastChild();
52
+ return c instanceof Te && c.getChildrenSize() === 0 && c.remove(), l;
53
+ }, Mt = {
54
54
  quote: "ain-rich-text-quote",
55
55
  text: {
56
56
  bold: "ain-rich-text-bold",
57
57
  italic: "ain-rich-text-italic",
58
- underline: "ain-rich-text-underline"
58
+ underline: "ain-rich-text-underline",
59
+ strikethrough: "ain-rich-text-strikethrough"
59
60
  },
60
61
  list: {
61
62
  nested: {
62
63
  listitem: "ain-rich-text-nested-list-item"
63
64
  }
64
65
  }
65
- }, Mt = (t) => t[0] === "{", kr = (t) => t !== null && typeof t == "object" && "isEmpty" in t, br = (t, r) => {
66
+ }, Tt = (t) => t[0] === "{", Nr = (t) => t !== null && typeof t == "object" && "isEmpty" in t, Er = (t, r) => {
66
67
  t.update(
67
68
  () => {
68
- const e = G();
69
+ const e = Y();
69
70
  e.clear();
70
- const n = W();
71
- n.append(I("")), e.append(n), V(null);
71
+ const o = G();
72
+ o.append(z("")), e.append(o), nt(null);
72
73
  },
73
74
  {
74
75
  tag: r
75
76
  }
76
77
  );
77
- }, Mr = (t, r, e) => {
78
+ }, Rr = (t, r, e) => {
78
79
  r.update(
79
80
  () => {
80
- const n = G();
81
- n.clear();
82
- const i = W();
83
- i.append(I(t.trim())), n.append(i), V(null);
81
+ const o = Y();
82
+ o.clear();
83
+ const i = G();
84
+ i.append(z(t.trim())), o.append(i), nt(null);
84
85
  },
85
86
  {
86
87
  tag: e
87
88
  }
88
89
  ), r.blur();
89
- }, Pn = async (t, r, e) => {
90
+ }, ro = async (t, r, e) => {
90
91
  var l;
91
- let n = 0;
92
- const i = At({
92
+ let o = 0;
93
+ const i = Bt({
93
94
  nodes: r,
94
95
  editable: !1,
95
- theme: bt
96
+ theme: Mt
96
97
  });
97
98
  if (t)
98
99
  try {
99
- if (typeof t == "string" && !Mt(t))
100
+ if (typeof t == "string" && !Tt(t))
100
101
  i.update(() => {
101
- const s = G(), d = W();
102
- d.append(I(t.trim())), s.append(d);
102
+ const s = Y(), d = G();
103
+ d.append(z(t.trim())), s.append(d);
103
104
  });
104
105
  else {
105
106
  const s = i.parseEditorState(t, () => {
106
- (e == null ? void 0 : e.maxLines) !== void 0 && (n = ne({
107
+ (e == null ? void 0 : e.maxLines) !== void 0 && (o = ce({
107
108
  editor: i,
108
109
  maxLines: e.maxLines
109
110
  }));
@@ -116,25 +117,25 @@ const fr = ({
116
117
  await ((l = e == null ? void 0 : e.updateFn) == null ? void 0 : l.call(e, i));
117
118
  let a = "";
118
119
  return i.read(() => {
119
- a = zt(i);
120
- }), { html: a, trimCount: n };
121
- }, Fn = (t, r, e) => {
122
- let n = 0;
123
- const i = At({
120
+ a = Pt(i);
121
+ }), { html: a, trimCount: o };
122
+ }, no = (t, r, e) => {
123
+ let o = 0;
124
+ const i = Bt({
124
125
  nodes: r,
125
126
  editable: !1,
126
- theme: bt
127
+ theme: Mt
127
128
  });
128
129
  if (t)
129
130
  try {
130
- if (typeof t == "string" && !Mt(t))
131
+ if (typeof t == "string" && !Tt(t))
131
132
  i.update(() => {
132
- const l = G(), s = W();
133
- s.append(I(t.trim())), l.append(s);
133
+ const l = Y(), s = G();
134
+ s.append(z(t.trim())), l.append(s);
134
135
  });
135
136
  else {
136
137
  const l = i.parseEditorState(t, () => {
137
- (e == null ? void 0 : e.maxLines) !== void 0 && (n = ne({
138
+ (e == null ? void 0 : e.maxLines) !== void 0 && (o = ce({
138
139
  editor: i,
139
140
  maxLines: e.maxLines
140
141
  }));
@@ -147,17 +148,17 @@ const fr = ({
147
148
  let a = "";
148
149
  try {
149
150
  i.read(() => {
150
- a = zt(i);
151
+ a = Pt(i);
151
152
  });
152
153
  } catch {
153
154
  }
154
- return { html: a, trimCount: n };
155
- }, Hn = (t) => xe().map(({ node: r }) => r).filter((r) => t.some((e) => r instanceof e));
156
- class X extends F {
155
+ return { html: a, trimCount: o };
156
+ }, oo = (t) => Ae().map(({ node: r }) => r).filter((r) => t.some((e) => r instanceof e));
157
+ class et extends j {
157
158
  static getType() {
158
159
  return "target-link";
159
160
  }
160
- constructor(r, e, n) {
161
+ constructor(r, e, o) {
161
162
  let i = !1;
162
163
  const a = { ...e };
163
164
  try {
@@ -165,10 +166,10 @@ class X extends F {
165
166
  window.location.hostname !== l.hostname && (i = !0);
166
167
  } catch {
167
168
  }
168
- i && (a.target = "_blank", a.rel = "noopener noreferrer"), super(r, a, n);
169
+ i && (a.target = "_blank", a.rel = "noopener noreferrer"), super(r, a, o);
169
170
  }
170
171
  static clone(r) {
171
- return new X(
172
+ return new et(
172
173
  r.__url,
173
174
  { rel: r.__rel, target: r.__target, title: r.__title },
174
175
  r.__key
@@ -178,19 +179,19 @@ class X extends F {
178
179
  return super.exportJSON();
179
180
  }
180
181
  static importJSON(r) {
181
- return F.importJSON(r);
182
+ return j.importJSON(r);
182
183
  }
183
184
  }
184
- const oe = He({
185
+ const de = Qe({
185
186
  hasFocus: !1,
186
187
  editorRef: { current: null },
187
188
  signUrl: void 0,
188
189
  fileUpload: void 0
189
- }), Cr = ({ onBlur: t }) => {
190
- const [r, e] = b(!1), n = q(null), i = T(() => {
191
- e(!0), n.current && window.clearTimeout(n.current);
192
- }, []), a = T(() => {
193
- n.current = window.setTimeout(() => {
190
+ }), Ir = ({ onBlur: t }) => {
191
+ const [r, e] = m(!1), o = V(null), i = M(() => {
192
+ e(!0), o.current && window.clearTimeout(o.current);
193
+ }, []), a = M(() => {
194
+ o.current = window.setTimeout(() => {
194
195
  e(!1), t == null || t();
195
196
  }, 0);
196
197
  }, [t]);
@@ -201,50 +202,50 @@ const oe = He({
201
202
  onBlur: a
202
203
  }
203
204
  };
204
- }, z = () => Ue(oe);
205
- function vr({
205
+ }, H = () => Ze(de);
206
+ function Or({
206
207
  src: t,
207
208
  altText: r,
208
209
  width: e,
209
- height: n,
210
+ height: o,
210
211
  nodeKey: i
211
212
  }) {
212
- const { signUrl: a } = z(), [l, s] = b(a ? "" : t), [d, c] = b(!1), h = q(!1), [g] = x();
213
+ const { signUrl: a } = H(), [l, s] = m(a ? "" : t), [d, c] = m(!1), u = V(!1), [g] = x();
213
214
  _(() => {
214
- const m = async () => {
215
+ const p = async () => {
215
216
  s(await (a == null ? void 0 : a(t)) ?? t);
216
217
  };
217
- !l && !h.current && (h.current = !0, m());
218
+ !l && !u.current && (u.current = !0, p());
218
219
  }, []);
219
- const k = (m) => (C) => {
220
- C.relatedTarget instanceof HTMLElement && C.relatedTarget.dataset.controls === "true" || c(m);
221
- }, S = () => {
220
+ const k = (p) => (C) => {
221
+ C.relatedTarget instanceof HTMLElement && C.relatedTarget.dataset.controls === "true" || c(p);
222
+ }, E = () => {
222
223
  g.update(() => {
223
- const m = ot(i);
224
- m && m.remove();
224
+ const p = ct(i);
225
+ p && p.remove();
225
226
  });
226
- }, E = () => {
227
+ }, R = () => {
227
228
  g.update(() => {
228
- var p;
229
- const m = ot(i);
230
- if (!m)
229
+ var y;
230
+ const p = ct(i);
231
+ if (!p)
231
232
  return;
232
- const C = m.getPreviousSibling() || ((p = m.getParent()) == null ? void 0 : p.getPreviousSibling());
233
- C && C.insertBefore(m);
233
+ const C = p.getPreviousSibling() || ((y = p.getParent()) == null ? void 0 : y.getPreviousSibling());
234
+ C && C.insertBefore(p);
234
235
  });
235
- }, M = () => {
236
+ }, b = () => {
236
237
  g.update(() => {
237
- var p;
238
- const m = ot(i);
239
- if (!m)
238
+ var y;
239
+ const p = ct(i);
240
+ if (!p)
240
241
  return;
241
- const C = m.getNextSibling() || ((p = m.getParent()) == null ? void 0 : p.getNextSibling());
242
- C && C.insertAfter(m);
242
+ const C = p.getNextSibling() || ((y = p.getParent()) == null ? void 0 : y.getNextSibling());
243
+ C && C.insertAfter(p);
243
244
  });
244
245
  };
245
- return l ? /* @__PURE__ */ u(U, { css: { position: "relative", display: "inline-block" }, children: [
246
- /* @__PURE__ */ u(
247
- je,
246
+ return l ? /* @__PURE__ */ h(P, { css: { position: "relative", display: "inline-block" }, children: [
247
+ /* @__PURE__ */ h(
248
+ er,
248
249
  {
249
250
  css: {
250
251
  position: "absolute",
@@ -258,47 +259,47 @@ function vr({
258
259
  "data-controls": "true",
259
260
  onMouseLeave: k(!1),
260
261
  children: [
261
- /* @__PURE__ */ o(
262
- L,
262
+ /* @__PURE__ */ n(
263
+ w,
263
264
  {
264
265
  icon: !0,
265
266
  size: "sm",
266
267
  css: { width: "20px", height: "20px" },
267
- onClick: S,
268
+ onClick: E,
268
269
  color: "danger",
269
- children: /* @__PURE__ */ o(Qe, {})
270
+ children: /* @__PURE__ */ n(lr, {})
270
271
  }
271
272
  ),
272
- /* @__PURE__ */ o(
273
- L,
273
+ /* @__PURE__ */ n(
274
+ w,
274
275
  {
275
276
  icon: !0,
276
277
  size: "sm",
277
278
  css: { width: "20px", height: "20px" },
278
- onClick: E,
279
- children: /* @__PURE__ */ o(Ve, {})
279
+ onClick: R,
280
+ children: /* @__PURE__ */ n(sr, {})
280
281
  }
281
282
  ),
282
- /* @__PURE__ */ o(
283
- L,
283
+ /* @__PURE__ */ n(
284
+ w,
284
285
  {
285
286
  icon: !0,
286
287
  size: "sm",
287
288
  css: { width: "20px", height: "20px" },
288
- onClick: M,
289
- children: /* @__PURE__ */ o(Ze, {})
289
+ onClick: b,
290
+ children: /* @__PURE__ */ n(cr, {})
290
291
  }
291
292
  )
292
293
  ]
293
294
  }
294
295
  ),
295
- /* @__PURE__ */ o(
296
+ /* @__PURE__ */ n(
296
297
  "img",
297
298
  {
298
299
  src: l,
299
300
  alt: r,
300
301
  style: {
301
- height: n,
302
+ height: o,
302
303
  width: e
303
304
  },
304
305
  className: "ain-rich-text-image",
@@ -307,27 +308,27 @@ function vr({
307
308
  "data-controls": "true"
308
309
  }
309
310
  )
310
- ] }) : /* @__PURE__ */ o("span", {});
311
+ ] }) : /* @__PURE__ */ n("span", {});
311
312
  }
312
- function Tr(t) {
313
- const r = t, { alt: e, src: n, width: i, height: a } = r;
314
- return { node: Ct({ altText: e, height: a, src: n, width: i }) };
313
+ function zr(t) {
314
+ const r = t, { alt: e, src: o, width: i, height: a } = r;
315
+ return { node: xt({ altText: e, height: a, src: o, width: i }) };
315
316
  }
316
- class $ extends ue {
317
- constructor(e, n, i, a, l, s) {
317
+ class U extends xe {
318
+ constructor(e, o, i, a, l, s) {
318
319
  super(s);
319
- O(this, "__src");
320
- O(this, "__altText");
321
- O(this, "__width");
322
- O(this, "__height");
323
- O(this, "__meta");
324
- this.__src = e, this.__altText = n, this.__width = i || "inherit", this.__height = a || "inherit", this.__meta = l;
320
+ $(this, "__src");
321
+ $(this, "__altText");
322
+ $(this, "__width");
323
+ $(this, "__height");
324
+ $(this, "__meta");
325
+ this.__src = e, this.__altText = o, this.__width = i || "inherit", this.__height = a || "inherit", this.__meta = l;
325
326
  }
326
327
  static getType() {
327
328
  return "image";
328
329
  }
329
330
  static clone(e) {
330
- return new $(
331
+ return new U(
331
332
  e.__src,
332
333
  e.__altText,
333
334
  e.__width,
@@ -337,9 +338,9 @@ class $ extends ue {
337
338
  );
338
339
  }
339
340
  static importJSON(e) {
340
- const { altText: n, height: i, width: a, src: l, meta: s } = e;
341
- return Ct({
342
- altText: n,
341
+ const { altText: o, height: i, width: a, src: l, meta: s } = e;
342
+ return xt({
343
+ altText: o,
343
344
  height: i,
344
345
  src: l,
345
346
  width: a,
@@ -353,7 +354,7 @@ class $ extends ue {
353
354
  static importDOM() {
354
355
  return {
355
356
  img: (e) => ({
356
- conversion: Tr,
357
+ conversion: zr,
357
358
  priority: 0
358
359
  })
359
360
  };
@@ -373,12 +374,12 @@ class $ extends ue {
373
374
  return this.__meta ?? { width: 0, height: 0 };
374
375
  }
375
376
  setSrc(e) {
376
- const n = this.getWritable();
377
- n.__src = e;
377
+ const o = this.getWritable();
378
+ o.__src = e;
378
379
  }
379
- setWidthAndHeight(e, n) {
380
+ setWidthAndHeight(e, o) {
380
381
  const i = this.getWritable();
381
- i.__width = e, i.__height = n;
382
+ i.__width = e, i.__height = o;
382
383
  }
383
384
  // View
384
385
  createDOM(e) {
@@ -394,8 +395,8 @@ class $ extends ue {
394
395
  return this.__altText;
395
396
  }
396
397
  decorate() {
397
- return /* @__PURE__ */ o(
398
- vr,
398
+ return /* @__PURE__ */ n(
399
+ Or,
399
400
  {
400
401
  src: this.__src,
401
402
  altText: this.__altText,
@@ -406,119 +407,128 @@ class $ extends ue {
406
407
  );
407
408
  }
408
409
  }
409
- function Ct({
410
+ function xt({
410
411
  altText: t,
411
412
  height: r,
412
413
  src: e,
413
- width: n,
414
+ width: o,
414
415
  meta: i,
415
416
  key: a
416
417
  }) {
417
- return ge(
418
- new $(e, t, n, r, i, a)
418
+ return Le(
419
+ new U(e, t, o, r, i, a)
419
420
  );
420
421
  }
421
- function Un(t) {
422
- return t instanceof $;
422
+ function io(t) {
423
+ return t instanceof U;
423
424
  }
424
- const Wn = [
425
- Wt,
426
- jt,
427
- ht,
428
- Ht,
429
- Ft,
430
- F,
425
+ const ao = [
426
+ qt,
427
+ Jt,
428
+ mt,
431
429
  Kt,
432
- Gt,
433
- Yt,
434
- $
435
- ], jn = [
436
- Wt,
437
430
  jt,
438
- ht,
439
- Ht,
440
- Ft,
441
- F,
431
+ j,
432
+ Yt,
433
+ Xt,
434
+ Vt,
435
+ U
436
+ ], lo = [
437
+ qt,
438
+ Jt,
439
+ mt,
442
440
  Kt,
443
- Gt,
441
+ jt,
442
+ j,
444
443
  Yt,
445
- $,
446
- X,
444
+ Xt,
445
+ Vt,
446
+ U,
447
+ et,
447
448
  {
448
- replace: F,
449
- with: (t) => new X(
449
+ replace: j,
450
+ with: (t) => new et(
450
451
  t.getURL(),
451
452
  { rel: t.__rel, target: t.__target, title: t.__title }
452
453
  )
453
454
  }
454
455
  ];
455
- function _r(t) {
456
+ function $r(t) {
456
457
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M4 6l16 0" } }, { tag: "path", attr: { d: "M8 12l8 0" } }, { tag: "path", attr: { d: "M6 18l12 0" } }] })(t);
457
458
  }
458
- function St(t) {
459
+ function Ot(t) {
459
460
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M4 6l16 0" } }, { tag: "path", attr: { d: "M4 12l10 0" } }, { tag: "path", attr: { d: "M4 18l14 0" } }] })(t);
460
461
  }
461
- function Lr(t) {
462
+ function Ar(t) {
462
463
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M4 6l16 0" } }, { tag: "path", attr: { d: "M10 12l10 0" } }, { tag: "path", attr: { d: "M6 18l14 0" } }] })(t);
463
464
  }
464
- function xr(t) {
465
+ function Dr(t) {
465
466
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M7 5h6a3.5 3.5 0 0 1 0 7h-6z" } }, { tag: "path", attr: { d: "M13 12h1a3.5 3.5 0 0 1 0 7h-7v-7" } }] })(t);
466
467
  }
467
- function wr(t) {
468
+ function Br(t) {
468
469
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M7 8l-4 4l4 4" } }, { tag: "path", attr: { d: "M17 8l4 4l-4 4" } }, { tag: "path", attr: { d: "M14 4l-4 16" } }] })(t);
469
470
  }
470
- function yr(t) {
471
+ function Pr(t) {
471
472
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M19 18v-8l-2 2" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
472
473
  }
473
- function Nr(t) {
474
+ function Fr(t) {
474
475
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M17 12a2 2 0 1 1 4 0c0 .591 -.417 1.318 -.816 1.858l-3.184 4.143l4 0" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
475
476
  }
476
- function Sr(t) {
477
+ function Hr(t) {
477
478
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M19 14a2 2 0 1 0 -2 -2" } }, { tag: "path", attr: { d: "M17 16a2 2 0 1 0 2 -2" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
478
479
  }
479
- function Er(t) {
480
+ function Ur(t) {
480
481
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M20 18v-8l-4 6h5" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
481
482
  }
482
- function Rr(t) {
483
+ function Wr(t) {
483
484
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M17 18h2a2 2 0 1 0 0 -4h-2v-4h4" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
484
485
  }
485
- function Ir(t) {
486
+ function jr(t) {
486
487
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M19 14a2 2 0 1 0 0 4a2 2 0 0 0 0 -4z" } }, { tag: "path", attr: { d: "M21 12a2 2 0 1 0 -4 0v4" } }, { tag: "path", attr: { d: "M4 6v12" } }, { tag: "path", attr: { d: "M12 6v12" } }, { tag: "path", attr: { d: "M11 18h2" } }, { tag: "path", attr: { d: "M3 18h2" } }, { tag: "path", attr: { d: "M4 12h8" } }, { tag: "path", attr: { d: "M3 6h2" } }, { tag: "path", attr: { d: "M11 6h2" } }] })(t);
487
488
  }
488
- function Or(t) {
489
+ function Kr(t) {
489
490
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M11 5l6 0" } }, { tag: "path", attr: { d: "M7 19l6 0" } }, { tag: "path", attr: { d: "M14 5l-4 14" } }] })(t);
490
491
  }
491
- function Ar(t) {
492
+ function Gr(t) {
492
493
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M17.5 15.5m-3.5 0a3.5 3.5 0 1 0 7 0a3.5 3.5 0 1 0 -7 0" } }, { tag: "path", attr: { d: "M3 19v-10.5a3.5 3.5 0 0 1 7 0v10.5" } }, { tag: "path", attr: { d: "M3 13h7" } }, { tag: "path", attr: { d: "M21 12v7" } }] })(t);
493
494
  }
494
- function zr(t) {
495
+ function qr(t) {
495
496
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M10 14a3.5 3.5 0 0 0 5 0l4 -4a3.5 3.5 0 0 0 -5 -5l-.5 .5" } }, { tag: "path", attr: { d: "M14 10a3.5 3.5 0 0 0 -5 0l-4 4a3.5 3.5 0 0 0 5 5l.5 -.5" } }] })(t);
496
497
  }
497
- function $r(t) {
498
+ function Jr(t) {
498
499
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M3.5 5.5l1.5 1.5l2.5 -2.5" } }, { tag: "path", attr: { d: "M3.5 11.5l1.5 1.5l2.5 -2.5" } }, { tag: "path", attr: { d: "M3.5 17.5l1.5 1.5l2.5 -2.5" } }, { tag: "path", attr: { d: "M11 6l9 0" } }, { tag: "path", attr: { d: "M11 12l9 0" } }, { tag: "path", attr: { d: "M11 18l9 0" } }] })(t);
499
500
  }
500
- function Dr(t) {
501
+ function Yr(t) {
501
502
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M11 6h9" } }, { tag: "path", attr: { d: "M11 12h9" } }, { tag: "path", attr: { d: "M12 18h8" } }, { tag: "path", attr: { d: "M4 16a2 2 0 1 1 4 0c0 .591 -.5 1 -1 1.5l-3 2.5h4" } }, { tag: "path", attr: { d: "M6 10v-6l-2 2" } }] })(t);
502
503
  }
503
- function Br(t) {
504
+ function Xr(t) {
504
505
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M9 6l11 0" } }, { tag: "path", attr: { d: "M9 12l11 0" } }, { tag: "path", attr: { d: "M9 18l11 0" } }, { tag: "path", attr: { d: "M5 6l0 .01" } }, { tag: "path", attr: { d: "M5 12l0 .01" } }, { tag: "path", attr: { d: "M5 18l0 .01" } }] })(t);
505
506
  }
506
- function Pr(t) {
507
+ function Vr(t) {
507
508
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M10 11h-4a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1h3a1 1 0 0 1 1 1v6c0 2.667 -1.333 4.333 -4 5" } }, { tag: "path", attr: { d: "M19 11h-4a1 1 0 0 1 -1 -1v-3a1 1 0 0 1 1 -1h3a1 1 0 0 1 1 1v6c0 2.667 -1.333 4.333 -4 5" } }] })(t);
508
509
  }
509
- function Fr(t) {
510
+ function Qr(t) {
511
+ return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M5 12l14 0" } }, { tag: "path", attr: { d: "M16 6.5a4 2 0 0 0 -4 -1.5h-1a3.5 3.5 0 0 0 0 7h2a3.5 3.5 0 0 1 0 7h-1.5a4 2 0 0 1 -4 -1.5" } }] })(t);
512
+ }
513
+ function Zr(t) {
514
+ return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M5 7l8 10m-8 0l8 -10" } }, { tag: "path", attr: { d: "M21 20h-4l3.5 -4a1.73 1.73 0 0 0 -3.5 -2" } }] })(t);
515
+ }
516
+ function tn(t) {
510
517
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M5 7l8 10m-8 0l8 -10" } }, { tag: "path", attr: { d: "M21 11h-4l3.5 -4a1.73 1.73 0 0 0 -3.5 -2" } }] })(t);
511
518
  }
512
- function Hr(t) {
519
+ function en(t) {
513
520
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M4 4m0 2a2 2 0 0 1 2 -2h12a2 2 0 0 1 2 2v12a2 2 0 0 1 -2 2h-12a2 2 0 0 1 -2 -2z" } }, { tag: "path", attr: { d: "M4 10l16 0" } }, { tag: "path", attr: { d: "M10 4l0 16" } }] })(t);
514
521
  }
515
- function Ur(t) {
522
+ function rn(t) {
523
+ return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M9 15v-7a3 3 0 0 1 6 0v7" } }, { tag: "path", attr: { d: "M9 11h6" } }, { tag: "path", attr: { d: "M5 19h14" } }] })(t);
524
+ }
525
+ function nn(t) {
516
526
  return f({ tag: "svg", attr: { viewBox: "0 0 24 24", strokeWidth: "2", stroke: "currentColor", fill: "none", strokeLinecap: "round", strokeLinejoin: "round" }, child: [{ tag: "path", attr: { stroke: "none", d: "M0 0h24v24H0z", fill: "none" } }, { tag: "path", attr: { d: "M7 5v5a5 5 0 0 0 10 0v-5" } }, { tag: "path", attr: { d: "M5 19h14" } }] })(t);
517
527
  }
518
- const Wr = dr("div", {
528
+ const on = Tr("div", {
519
529
  width: "10rem",
520
530
  display: "flex"
521
- }), ie = {
531
+ }), he = {
522
532
  bullet: "Punktliste",
523
533
  h1: "Overskrift 1",
524
534
  h2: "Overskrift 2",
@@ -530,24 +540,24 @@ const Wr = dr("div", {
530
540
  paragraph: "Normal",
531
541
  quote: "Sitat",
532
542
  check: "Avkrysningsliste"
533
- }, jr = {
534
- bullet: /* @__PURE__ */ o(Br, { size: "1.25rem" }),
535
- h1: /* @__PURE__ */ o(yr, { size: "1.25rem" }),
536
- h2: /* @__PURE__ */ o(Nr, { size: "1.25rem" }),
537
- h3: /* @__PURE__ */ o(Sr, { size: "1.25rem" }),
538
- h4: /* @__PURE__ */ o(Er, { size: "1.25rem" }),
539
- h5: /* @__PURE__ */ o(Rr, { size: "1.25rem" }),
540
- h6: /* @__PURE__ */ o(Ir, { size: "1.25rem" }),
541
- number: /* @__PURE__ */ o(Dr, { size: "1.25rem" }),
542
- check: /* @__PURE__ */ o($r, { size: "1.25rem" }),
543
- paragraph: /* @__PURE__ */ o(Ar, { size: "1.25rem" }),
544
- quote: /* @__PURE__ */ o(Pr, { size: "1.25rem" })
545
- }, w = ({
543
+ }, an = {
544
+ bullet: /* @__PURE__ */ n(Xr, { size: "1.25rem" }),
545
+ h1: /* @__PURE__ */ n(Pr, { size: "1.25rem" }),
546
+ h2: /* @__PURE__ */ n(Fr, { size: "1.25rem" }),
547
+ h3: /* @__PURE__ */ n(Hr, { size: "1.25rem" }),
548
+ h4: /* @__PURE__ */ n(Ur, { size: "1.25rem" }),
549
+ h5: /* @__PURE__ */ n(Wr, { size: "1.25rem" }),
550
+ h6: /* @__PURE__ */ n(jr, { size: "1.25rem" }),
551
+ number: /* @__PURE__ */ n(Yr, { size: "1.25rem" }),
552
+ check: /* @__PURE__ */ n(Jr, { size: "1.25rem" }),
553
+ paragraph: /* @__PURE__ */ n(Gr, { size: "1.25rem" }),
554
+ quote: /* @__PURE__ */ n(Vr, { size: "1.25rem" })
555
+ }, S = ({
546
556
  blockType: t
547
- }) => /* @__PURE__ */ u(j, { children: [
548
- /* @__PURE__ */ o(U, { css: { display: "flex", flex: "0 0 auto" }, children: jr[t] }),
549
- /* @__PURE__ */ o(
550
- U,
557
+ }) => /* @__PURE__ */ h(F, { children: [
558
+ /* @__PURE__ */ n(P, { css: { display: "flex", flex: "0 0 auto" }, children: an[t] }),
559
+ /* @__PURE__ */ n(
560
+ P,
551
561
  {
552
562
  css: {
553
563
  flex: "1 1 auto",
@@ -555,189 +565,292 @@ const Wr = dr("div", {
555
565
  textOverflow: "ellipsis",
556
566
  whiteSpace: "nowrap"
557
567
  },
558
- children: ie[t]
568
+ children: he[t]
559
569
  }
560
570
  )
561
- ] }), Kr = (t) => {
571
+ ] }), ln = (t) => {
562
572
  if (!N(t))
563
573
  return null;
564
574
  const r = t.anchor.getNode();
565
- let e = r.getKey() === "root" ? r : Pt(r, (n) => {
566
- const i = n.getParent();
567
- return i !== null && $t(i);
575
+ let e = r.getKey() === "root" ? r : Wt(r, (o) => {
576
+ const i = o.getParent();
577
+ return i !== null && Ft(i);
568
578
  });
569
579
  return e === null && (e = r.getTopLevelElementOrThrow()), {
570
580
  anchorNode: r,
571
581
  element: e
572
582
  };
573
- }, Gr = () => {
574
- const [t] = x(), [r, e] = b("paragraph");
583
+ }, sn = () => {
584
+ const [t] = x(), [r, e] = m("paragraph");
575
585
  _(() => t.registerCommand(
576
- Y,
586
+ X,
577
587
  () => {
578
- const c = y(), h = Kr(c);
579
- if (!h)
588
+ const c = L(), u = ln(c);
589
+ if (!u)
580
590
  return !1;
581
- const { element: g, anchorNode: k } = h, S = g.getKey();
582
- if (t.getElementByKey(S) !== null)
583
- if (ut(g)) {
584
- const M = we(
591
+ const { element: g, anchorNode: k } = u, E = g.getKey();
592
+ if (t.getElementByKey(E) !== null)
593
+ if (ft(g)) {
594
+ const b = De(
585
595
  k,
586
- ht
587
- ), m = M ? M.getListType() : g.getListType();
588
- e(m);
596
+ mt
597
+ ), p = b ? b.getListType() : g.getListType();
598
+ e(p);
589
599
  } else {
590
- const M = Oe(g) ? g.getTag() : g.getType();
591
- M in ie && e(M);
600
+ const b = je(g) ? g.getTag() : g.getType();
601
+ b in he && e(b);
592
602
  }
593
603
  return !1;
594
604
  },
595
- ct
605
+ q
596
606
  ), [t]);
597
- const n = (c) => {
607
+ const o = (c) => {
598
608
  r !== c && t.update(() => {
599
- const h = y();
600
- N(h) && (at(h, () => Ae(c)), e(c));
609
+ const u = L();
610
+ N(u) && (ht(u, () => Ke(c)), e(c));
601
611
  });
602
612
  };
603
- return /* @__PURE__ */ o(Wr, { children: /* @__PURE__ */ u(
604
- et,
613
+ return /* @__PURE__ */ n(on, { children: /* @__PURE__ */ h(
614
+ at,
605
615
  {
606
- trigger: /* @__PURE__ */ o(
607
- gt,
616
+ trigger: /* @__PURE__ */ n(
617
+ lt,
608
618
  {
609
619
  dropdown: !0,
610
620
  css: { display: "flex", width: "100%", overflow: "hidden" },
611
- children: /* @__PURE__ */ o(w, { blockType: r })
621
+ children: /* @__PURE__ */ n(S, { blockType: r })
612
622
  }
613
623
  ),
614
624
  side: "bottom",
615
625
  align: "start",
616
626
  children: [
617
- /* @__PURE__ */ o(v, { onClick: () => {
627
+ /* @__PURE__ */ n(T, { onClick: () => {
618
628
  r !== "paragraph" && t.update(() => {
619
- const c = y();
620
- N(c) && (at(c, () => W()), e("paragraph"));
629
+ const c = L();
630
+ N(c) && (ht(c, () => G()), e("paragraph"));
621
631
  });
622
- }, children: /* @__PURE__ */ o(w, { blockType: "paragraph" }) }),
623
- /* @__PURE__ */ o(v, { onClick: () => n("h1"), children: /* @__PURE__ */ o(w, { blockType: "h1" }) }),
624
- /* @__PURE__ */ o(v, { onClick: () => n("h2"), children: /* @__PURE__ */ o(w, { blockType: "h2" }) }),
625
- /* @__PURE__ */ o(v, { onClick: () => n("h3"), children: /* @__PURE__ */ o(w, { blockType: "h3" }) }),
626
- /* @__PURE__ */ o(v, { onClick: () => n("h4"), children: /* @__PURE__ */ o(w, { blockType: "h4" }) }),
627
- /* @__PURE__ */ o(v, { onClick: () => n("h5"), children: /* @__PURE__ */ o(w, { blockType: "h5" }) }),
628
- /* @__PURE__ */ o(v, { onClick: () => n("h6"), children: /* @__PURE__ */ o(w, { blockType: "h6" }) }),
629
- /* @__PURE__ */ o(v, { onClick: () => {
630
- r !== "bullet" && (t.dispatchCommand(Ee, void 0), e("bullet"));
631
- }, children: /* @__PURE__ */ o(w, { blockType: "bullet" }) }),
632
- /* @__PURE__ */ o(v, { onClick: () => {
633
- r !== "number" && (t.dispatchCommand(Re, void 0), e("number"));
634
- }, children: /* @__PURE__ */ o(w, { blockType: "number" }) }),
635
- /* @__PURE__ */ o(v, { onClick: () => {
636
- r !== "check" && (t.dispatchCommand(Ut, void 0), e("check"));
637
- }, children: /* @__PURE__ */ o(w, { blockType: "check" }) }),
638
- /* @__PURE__ */ o(v, { onClick: () => {
632
+ }, children: /* @__PURE__ */ n(S, { blockType: "paragraph" }) }),
633
+ /* @__PURE__ */ n(T, { onClick: () => o("h1"), children: /* @__PURE__ */ n(S, { blockType: "h1" }) }),
634
+ /* @__PURE__ */ n(T, { onClick: () => o("h2"), children: /* @__PURE__ */ n(S, { blockType: "h2" }) }),
635
+ /* @__PURE__ */ n(T, { onClick: () => o("h3"), children: /* @__PURE__ */ n(S, { blockType: "h3" }) }),
636
+ /* @__PURE__ */ n(T, { onClick: () => o("h4"), children: /* @__PURE__ */ n(S, { blockType: "h4" }) }),
637
+ /* @__PURE__ */ n(T, { onClick: () => o("h5"), children: /* @__PURE__ */ n(S, { blockType: "h5" }) }),
638
+ /* @__PURE__ */ n(T, { onClick: () => o("h6"), children: /* @__PURE__ */ n(S, { blockType: "h6" }) }),
639
+ /* @__PURE__ */ n(T, { onClick: () => {
640
+ r !== "bullet" && (t.dispatchCommand(He, void 0), e("bullet"));
641
+ }, children: /* @__PURE__ */ n(S, { blockType: "bullet" }) }),
642
+ /* @__PURE__ */ n(T, { onClick: () => {
643
+ r !== "number" && (t.dispatchCommand(Ue, void 0), e("number"));
644
+ }, children: /* @__PURE__ */ n(S, { blockType: "number" }) }),
645
+ /* @__PURE__ */ n(T, { onClick: () => {
646
+ r !== "check" && (t.dispatchCommand(Gt, void 0), e("check"));
647
+ }, children: /* @__PURE__ */ n(S, { blockType: "check" }) }),
648
+ /* @__PURE__ */ n(T, { onClick: () => {
639
649
  r !== "quote" && t.update(() => {
640
- const c = y();
641
- N(c) && (at(c, () => ze()), e("quote"));
650
+ const c = L();
651
+ N(c) && (ht(c, () => Ge()), e("quote"));
642
652
  });
643
- }, children: /* @__PURE__ */ o(w, { blockType: "quote" }) })
653
+ }, children: /* @__PURE__ */ n(S, { blockType: "quote" }) })
644
654
  ]
645
655
  }
646
656
  ) });
647
- }, Yr = () => {
648
- const [t] = x(), [r, e] = b(!1), [n, i] = b(!1), [a, l] = b(!1), [s, d] = b(!1), [c, h] = b(!1), g = T(() => {
649
- const p = y();
650
- N(p) && (e(p.hasFormat("bold")), i(p.hasFormat("italic")), l(p.hasFormat("underline")), d(p.hasFormat("code")), h(p.hasFormat("superscript")));
657
+ }, cn = () => {
658
+ const [t] = x(), [r, e] = m(!1), [o, i] = m(!1), [a, l] = m(!1), [s, d] = m(!1), [c, u] = m(!1), [g, k] = m(!1), [E, R] = m(!1), [b, p] = m(""), [C, y] = m(!1), I = M(() => {
659
+ const v = L();
660
+ N(v) && (e(v.hasFormat("bold")), i(v.hasFormat("italic")), l(v.hasFormat("underline")), d(v.hasFormat("strikethrough")), u(v.hasFormat("code")), k(v.hasFormat("superscript")), R(v.hasFormat("subscript")), p(ze(v, "color", "")));
651
661
  }, []);
652
- _(() => Z(
662
+ _(() => ot(
653
663
  t.registerCommand(
654
- Y,
655
- () => (g(), !1),
656
- ct
664
+ X,
665
+ () => (I(), !1),
666
+ q
657
667
  ),
658
- t.registerUpdateListener(({ editorState: p }) => {
659
- p.read(() => {
660
- g();
668
+ t.registerUpdateListener(({ editorState: v }) => {
669
+ v.read(() => {
670
+ I();
661
671
  });
662
672
  })
663
- ), [t, g]);
664
- const k = T(
665
- () => t.dispatchCommand(K, "bold"),
673
+ ), [t, I]);
674
+ const J = M(
675
+ () => t.dispatchCommand(A, "bold"),
666
676
  [t]
667
- ), S = T(
668
- () => t.dispatchCommand(K, "italic"),
677
+ ), Q = M(
678
+ () => t.dispatchCommand(A, "italic"),
669
679
  [t]
670
- ), E = T(
671
- () => t.dispatchCommand(K, "underline"),
680
+ ), me = M(
681
+ () => t.dispatchCommand(A, "underline"),
672
682
  [t]
673
- ), M = T(
674
- () => t.dispatchCommand(K, "code"),
683
+ ), fe = M(
684
+ () => t.dispatchCommand(A, "strikethrough"),
675
685
  [t]
676
- ), m = T(
677
- () => t.dispatchCommand(K, "superscript"),
686
+ ), ke = M(
687
+ () => t.dispatchCommand(A, "code"),
678
688
  [t]
679
- ), C = qt(() => {
680
- const p = [];
681
- return r && p.push("bold"), n && p.push("italic"), a && p.push("underline"), s && p.push("code"), c && p.push("superscript"), p;
682
- }, [r, n, a, s, c]);
683
- return /* @__PURE__ */ u(
684
- Jt,
685
- {
686
- type: "multiple",
687
- "aria-label": "Tekstformattering",
688
- value: C,
689
- children: [
690
- /* @__PURE__ */ o(P, { onClick: k, title: "Fet tekst", value: "bold", children: /* @__PURE__ */ o(xr, { size: "1.25rem" }) }),
691
- /* @__PURE__ */ o(
692
- P,
693
- {
694
- onClick: S,
695
- title: "Kursiv tekst",
696
- value: "italic",
697
- children: /* @__PURE__ */ o(Or, { size: "1.25rem" })
698
- }
699
- ),
700
- /* @__PURE__ */ o(
701
- P,
702
- {
703
- onClick: E,
704
- title: "Understreket tekst",
705
- value: "underline",
706
- children: /* @__PURE__ */ o(Ur, { size: "1.25rem" })
707
- }
708
- ),
709
- /* @__PURE__ */ o(P, { onClick: M, title: "Kode", value: "code", children: /* @__PURE__ */ o(wr, { size: "1.25rem" }) }),
710
- /* @__PURE__ */ o(
711
- P,
689
+ ), be = M(
690
+ () => t.dispatchCommand(A, "superscript"),
691
+ [t]
692
+ ), ve = M(
693
+ () => t.dispatchCommand(A, "subscript"),
694
+ [t]
695
+ ), wt = Qt(() => {
696
+ const v = [];
697
+ return r && v.push("bold"), o && v.push("italic"), a && v.push("underline"), s && v.push("strikethrough"), c && v.push("code"), g && v.push("superscript"), E && v.push("subscript"), b && v.push("color"), v;
698
+ }, [
699
+ r,
700
+ o,
701
+ a,
702
+ c,
703
+ g,
704
+ E,
705
+ s,
706
+ b
707
+ ]);
708
+ return /* @__PURE__ */ h(F, { children: [
709
+ /* @__PURE__ */ h(
710
+ tt,
711
+ {
712
+ type: "multiple",
713
+ "aria-label": "Tekstformattering",
714
+ value: wt,
715
+ children: [
716
+ /* @__PURE__ */ n(O, { onClick: J, title: "Fet tekst", value: "bold", children: /* @__PURE__ */ n(Dr, { size: "1.25rem" }) }),
717
+ /* @__PURE__ */ n(
718
+ O,
719
+ {
720
+ onClick: Q,
721
+ title: "Kursiv tekst",
722
+ value: "italic",
723
+ children: /* @__PURE__ */ n(Kr, { size: "1.25rem" })
724
+ }
725
+ ),
726
+ /* @__PURE__ */ n(
727
+ O,
728
+ {
729
+ onClick: me,
730
+ title: "Understreket tekst",
731
+ value: "underline",
732
+ children: /* @__PURE__ */ n(nn, { size: "1.25rem" })
733
+ }
734
+ )
735
+ ]
736
+ }
737
+ ),
738
+ /* @__PURE__ */ h(Zt, { open: C, onOpenChange: y, children: [
739
+ /* @__PURE__ */ n(te, { children: /* @__PURE__ */ n(lt, { children: /* @__PURE__ */ n(dr, { size: "1.25rem" }) }) }),
740
+ /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ h(
741
+ tt,
742
+ {
743
+ type: "multiple",
744
+ "aria-label": "Tekstformattering",
745
+ value: wt,
746
+ css: { margin: "$1" },
747
+ children: [
748
+ /* @__PURE__ */ n(
749
+ O,
750
+ {
751
+ onClick: fe,
752
+ title: "Gjennomstreking",
753
+ value: "strikethrough",
754
+ children: /* @__PURE__ */ n(Qr, { size: "1.25rem" })
755
+ }
756
+ ),
757
+ /* @__PURE__ */ n(
758
+ O,
759
+ {
760
+ onClick: be,
761
+ title: "Superscript",
762
+ value: "superscript",
763
+ children: /* @__PURE__ */ n(tn, { size: "1.25rem" })
764
+ }
765
+ ),
766
+ /* @__PURE__ */ n(
767
+ O,
768
+ {
769
+ onClick: ve,
770
+ title: "Subscript",
771
+ value: "subscript",
772
+ children: /* @__PURE__ */ n(Zr, { size: "1.25rem" })
773
+ }
774
+ ),
775
+ /* @__PURE__ */ n(O, { onClick: ke, title: "Kode", value: "code", children: /* @__PURE__ */ n(Br, { size: "1.25rem" }) }),
776
+ /* @__PURE__ */ n(hn, { activeColor: b })
777
+ ]
778
+ }
779
+ ) })
780
+ ] })
781
+ ] });
782
+ }, dn = [
783
+ { name: "Reset", value: "" },
784
+ { name: "Rød", value: "#df2222" },
785
+ { name: "Grønn", value: "#1ca021" },
786
+ { name: "Blå", value: "#2044b8" },
787
+ { name: "Lilla", value: "#9c31de" }
788
+ ], hn = ({ activeColor: t }) => {
789
+ const [r] = x(), [e, o] = m(!1), i = (a) => {
790
+ r.update(() => {
791
+ const l = L();
792
+ l && $e(l, { color: a });
793
+ });
794
+ };
795
+ return /* @__PURE__ */ h(Zt, { open: e, onOpenChange: o, children: [
796
+ /* @__PURE__ */ n(te, { children: /* @__PURE__ */ n(O, { value: "color", title: "Tekstfarge", children: /* @__PURE__ */ n(rn, { size: "1.25rem" }) }) }),
797
+ /* @__PURE__ */ n(ee, { children: /* @__PURE__ */ n(
798
+ tt,
799
+ {
800
+ type: "single",
801
+ "aria-label": "Tekstfarge",
802
+ value: t,
803
+ css: { margin: "$1" },
804
+ children: dn.map((a) => /* @__PURE__ */ n(
805
+ O,
712
806
  {
713
- onClick: m,
714
- title: "Superscript",
715
- value: "superscript",
716
- children: /* @__PURE__ */ o(Fr, { size: "1.25rem" })
717
- }
718
- )
719
- ]
720
- }
721
- );
722
- }, qr = ({ children: t }) => {
723
- const { hasFocus: r, editorRef: e } = z(), n = r, [i, a] = b(n);
724
- We(() => {
725
- a(n);
726
- }, [n]);
727
- const { context: l, refs: s, floatingStyles: d } = ft({
807
+ value: a.value,
808
+ onClick: () => i(
809
+ !a.value || a.value === t ? null : a.value
810
+ ),
811
+ children: a.value ? /* @__PURE__ */ n(
812
+ P,
813
+ {
814
+ css: {
815
+ width: "1rem",
816
+ height: "1rem",
817
+ backgroundColor: a.value,
818
+ borderRadius: "$full",
819
+ flexShrink: 0
820
+ }
821
+ }
822
+ ) : /* @__PURE__ */ n(
823
+ hr,
824
+ {
825
+ size: "1.25rem",
826
+ style: { color: "#000" }
827
+ }
828
+ )
829
+ },
830
+ a.name
831
+ ))
832
+ }
833
+ ) })
834
+ ] });
835
+ }, un = ({ children: t }) => {
836
+ const { hasFocus: r, editorRef: e } = H(), o = r, [i, a] = m(o);
837
+ tr(() => {
838
+ a(o);
839
+ }, [o]);
840
+ const { context: l, refs: s, floatingStyles: d } = vt({
728
841
  placement: "top",
729
- whileElementsMounted: Vt,
842
+ whileElementsMounted: oe,
730
843
  middleware: [
731
- ir({
732
- apply: ({ rects: h, elements: g }) => {
733
- g.floating.style.minWidth = `${h.reference.width}px`;
844
+ kr({
845
+ apply: ({ rects: u, elements: g }) => {
846
+ g.floating.style.minWidth = `${u.reference.width}px`;
734
847
  }
735
848
  }),
736
- ar(),
737
- Zt({
849
+ br(),
850
+ ie({
738
851
  mainAxis: 8
739
852
  }),
740
- lr({
853
+ vr({
741
854
  padding: 8
742
855
  })
743
856
  ],
@@ -746,13 +859,13 @@ const Wr = dr("div", {
746
859
  elements: {
747
860
  reference: e.current
748
861
  }
749
- }), { getFloatingProps: c } = te([
750
- ee(l, {
862
+ }), { getFloatingProps: c } = ae([
863
+ le(l, {
751
864
  role: "dialog"
752
865
  })
753
866
  ]);
754
- return i ? /* @__PURE__ */ o(re, { children: /* @__PURE__ */ o(
755
- Xt,
867
+ return i ? /* @__PURE__ */ n(se, { children: /* @__PURE__ */ n(
868
+ re,
756
869
  {
757
870
  ref: s.setFloating,
758
871
  style: d,
@@ -763,72 +876,73 @@ const Wr = dr("div", {
763
876
  overflow: "hidden",
764
877
  boxShadow: "$md"
765
878
  },
766
- children: /* @__PURE__ */ o(Jr, { children: t })
879
+ children: /* @__PURE__ */ n(gn, { children: t })
767
880
  }
768
881
  ) }) : null;
769
- }, Jr = ({
882
+ }, gn = ({
770
883
  children: t,
771
884
  ...r
772
- }) => /* @__PURE__ */ u(Ke, { "aria-label": "Formattering", ...r, children: [
773
- /* @__PURE__ */ o(Gr, {}),
774
- /* @__PURE__ */ o(Ge, {}),
775
- /* @__PURE__ */ o(Yr, {}),
885
+ }) => /* @__PURE__ */ h(rr, { "aria-label": "Formattering", ...r, children: [
886
+ /* @__PURE__ */ n(sn, {}),
887
+ /* @__PURE__ */ n(Rt, {}),
888
+ /* @__PURE__ */ n(cn, {}),
889
+ /* @__PURE__ */ n(Rt, {}),
776
890
  t
777
891
  ] });
778
- function Xr() {
892
+ function pn() {
779
893
  const [t] = x();
780
- return _(() => Z(
894
+ return _(() => ot(
781
895
  t.registerCommand(
782
- Ut,
783
- () => (Ie(t, "check"), !0),
784
- R
896
+ Gt,
897
+ () => (We(t, "check"), !0),
898
+ D
785
899
  ),
786
900
  t.registerCommand(
787
- pe,
788
- (r) => It(r, t, !1),
789
- R
901
+ _e,
902
+ (r) => At(r, t, !1),
903
+ D
790
904
  ),
791
905
  t.registerCommand(
792
- me,
793
- (r) => It(r, t, !0),
794
- R
906
+ we,
907
+ (r) => At(r, t, !0),
908
+ D
795
909
  ),
796
910
  t.registerCommand(
797
- Dt,
911
+ Ht,
798
912
  (r) => {
799
- if (st() != null) {
800
- const n = t.getRootElement();
801
- return n != null && n.focus(), !0;
913
+ if (gt() != null) {
914
+ const o = t.getRootElement();
915
+ return o != null && o.focus(), !0;
802
916
  }
803
917
  return !1;
804
918
  },
805
- R
919
+ D
806
920
  ),
807
921
  t.registerCommand(
808
- fe,
922
+ ye,
809
923
  (r) => {
810
- const e = st();
924
+ const e = gt();
811
925
  return e != null && t.isEditable() ? (t.update(() => {
812
- const n = dt(e);
813
- H(n) && (r.preventDefault(), n.toggleChecked());
926
+ const o = pt(e);
927
+ K(o) && (r.preventDefault(), o.toggleChecked());
814
928
  }), !0) : !1;
815
929
  },
816
- R
930
+ D
817
931
  ),
818
932
  t.registerCommand(
819
- ke,
933
+ Se,
820
934
  (r) => t.getEditorState().read(() => {
821
- const e = y();
935
+ const e = L();
822
936
  if (N(e) && e.isCollapsed()) {
823
- const { anchor: n } = e, i = n.type === "element";
824
- if (i || n.offset === 0) {
825
- const a = n.getNode(), l = Pt(
937
+ const { anchor: o } = e, i = o.type === "element";
938
+ if (i || o.offset === 0) {
939
+ const a = o.getNode(), l = Wt(
826
940
  a,
827
- (s) => be(s) && !s.isInline()
941
+ (s) => Ne(s) && !s.isInline()
828
942
  );
829
- if (H(l)) {
943
+ if (K(l)) {
830
944
  const s = l.getParent();
831
- if (ut(s) && s.getListType() === "check" && (i || l.getFirstDescendant() === a)) {
945
+ if (ft(s) && s.getListType() === "check" && (i || l.getFirstDescendant() === a)) {
832
946
  const d = t.getElementByKey(l.__key);
833
947
  if (d != null && document.activeElement !== d)
834
948
  return d.focus(), r.preventDefault(), !0;
@@ -838,19 +952,19 @@ function Xr() {
838
952
  }
839
953
  return !1;
840
954
  }),
841
- R
955
+ D
842
956
  ),
843
957
  t.registerRootListener((r, e) => {
844
- r !== null && (r.addEventListener("click", Et), r.addEventListener("pointerdown", Rt)), e !== null && (e.removeEventListener("click", Et), e.removeEventListener("pointerdown", Rt));
958
+ r !== null && (r.addEventListener("click", zt), r.addEventListener("pointerdown", $t)), e !== null && (e.removeEventListener("click", zt), e.removeEventListener("pointerdown", $t));
845
959
  })
846
960
  ), [t]), null;
847
961
  }
848
- function ae(t, r) {
962
+ function ue(t, r) {
849
963
  const e = t.target;
850
- if (e === null || !xt(e))
964
+ if (e === null || !St(e))
851
965
  return;
852
- const n = e.firstChild;
853
- if (n != null && xt(n) && (n.tagName === "UL" || n.tagName === "OL"))
966
+ const o = e.firstChild;
967
+ if (o != null && St(o) && (o.tagName === "UL" || o.tagName === "OL"))
854
968
  return;
855
969
  const i = e.parentNode;
856
970
  if (!i || i.__lexicalListType !== "check")
@@ -858,23 +972,23 @@ function ae(t, r) {
858
972
  const a = t.pageX, l = e.getBoundingClientRect();
859
973
  (e.dir === "rtl" ? a < l.right && a > l.right - 20 : a > l.left && a < l.left + 20) && r();
860
974
  }
861
- function Et(t) {
862
- ae(t, () => {
863
- const r = t.target, e = Qr(r);
975
+ function zt(t) {
976
+ ue(t, () => {
977
+ const r = t.target, e = mn(r);
864
978
  e != null && e.isEditable() && e.update(() => {
865
979
  if (t.target) {
866
- const n = dt(r);
867
- H(n) && (r.focus(), n.toggleChecked());
980
+ const o = pt(r);
981
+ K(o) && (r.focus(), o.toggleChecked());
868
982
  }
869
983
  });
870
984
  });
871
985
  }
872
- function Rt(t) {
873
- ae(t, () => {
986
+ function $t(t) {
987
+ ue(t, () => {
874
988
  t.preventDefault();
875
989
  });
876
990
  }
877
- function Qr(t) {
991
+ function mn(t) {
878
992
  let r = t;
879
993
  for (; r; ) {
880
994
  if (r.__lexicalEditor)
@@ -883,30 +997,30 @@ function Qr(t) {
883
997
  }
884
998
  return null;
885
999
  }
886
- function st() {
1000
+ function gt() {
887
1001
  const t = document.activeElement;
888
1002
  return t != null && t.tagName === "LI" && t.parentNode != null && // @ts-ignore internal field
889
1003
  t.parentNode.__lexicalListType === "check" ? t : null;
890
1004
  }
891
- function Vr(t, r) {
892
- let e = r ? t.getPreviousSibling() : t.getNextSibling(), n = t;
893
- for (; e == null && H(n); )
894
- n = n.getParentOrThrow().getParent(), n != null && (e = r ? n.getPreviousSibling() : n.getNextSibling());
895
- for (; H(e); ) {
1005
+ function fn(t, r) {
1006
+ let e = r ? t.getPreviousSibling() : t.getNextSibling(), o = t;
1007
+ for (; e == null && K(o); )
1008
+ o = o.getParentOrThrow().getParent(), o != null && (e = r ? o.getPreviousSibling() : o.getNextSibling());
1009
+ for (; K(e); ) {
896
1010
  const i = r ? e.getLastChild() : e.getFirstChild();
897
- if (!ut(i))
1011
+ if (!ft(i))
898
1012
  return e;
899
1013
  e = r ? i.getLastChild() : i.getFirstChild();
900
1014
  }
901
1015
  return null;
902
1016
  }
903
- function It(t, r, e) {
904
- const n = st();
905
- return n != null && r.update(() => {
906
- const i = dt(n);
907
- if (!H(i))
1017
+ function At(t, r, e) {
1018
+ const o = gt();
1019
+ return o != null && r.update(() => {
1020
+ const i = pt(o);
1021
+ if (!K(i))
908
1022
  return;
909
- const a = Vr(i, e);
1023
+ const a = fn(i, e);
910
1024
  if (a != null) {
911
1025
  a.selectStart();
912
1026
  const l = r.getElementByKey(a.__key);
@@ -916,54 +1030,54 @@ function It(t, r, e) {
916
1030
  }
917
1031
  }), !1;
918
1032
  }
919
- const vt = Me("INSERT_IMAGE_COMMAND");
920
- function Zr() {
921
- const [t] = kt();
1033
+ const Lt = Ee("INSERT_IMAGE_COMMAND");
1034
+ function kn() {
1035
+ const [t] = Ct();
922
1036
  return _(() => {
923
- if (!t.hasNodes([$]))
1037
+ if (!t.hasNodes([U]))
924
1038
  throw new Error("ImagePlugin: ImageNode not registered on editor");
925
- return Z(
1039
+ return ot(
926
1040
  t.registerCommand(
927
- vt,
1041
+ Lt,
928
1042
  (r) => {
929
- const e = Ct(r);
930
- return Ce([e]), $t(e.getParentOrThrow()) && ye(e, W).selectEnd(), !0;
1043
+ const e = xt(r);
1044
+ return Re([e]), Ft(e.getParentOrThrow()) && Be(e, G).selectEnd(), !0;
931
1045
  },
932
- ve
1046
+ q
933
1047
  )
934
1048
  );
935
1049
  }, [t]), null;
936
1050
  }
937
- const tn = () => /* @__PURE__ */ u(j, { children: [
938
- /* @__PURE__ */ o(ur, {}),
939
- /* @__PURE__ */ o(pr, {}),
940
- /* @__PURE__ */ o(gr, {}),
941
- /* @__PURE__ */ o(Xr, {}),
942
- /* @__PURE__ */ o(mr, {}),
943
- /* @__PURE__ */ o(Zr, {})
944
- ] }), en = ({
1051
+ const bn = () => /* @__PURE__ */ h(F, { children: [
1052
+ /* @__PURE__ */ n(Lr, {}),
1053
+ /* @__PURE__ */ n(wr, {}),
1054
+ /* @__PURE__ */ n(_r, {}),
1055
+ /* @__PURE__ */ n(pn, {}),
1056
+ /* @__PURE__ */ n(yr, {}),
1057
+ /* @__PURE__ */ n(kn, {})
1058
+ ] }), vn = ({
945
1059
  state: t
946
1060
  }) => {
947
- const [r] = x(), e = q(!1);
1061
+ const [r] = x(), e = V(!1);
948
1062
  return _(() => {
949
1063
  !t || e.current || (e.current = !0, window.queueMicrotask(() => {
950
1064
  try {
951
- if (kr(t)) {
952
- t.isEmpty() ? br(r) : r.setEditorState(t);
1065
+ if (Nr(t)) {
1066
+ t.isEmpty() ? Er(r) : r.setEditorState(t);
953
1067
  return;
954
1068
  }
955
- if (typeof t == "string" && !Mt(t)) {
956
- Mr(t, r);
1069
+ if (typeof t == "string" && !Tt(t)) {
1070
+ Rr(t, r);
957
1071
  return;
958
1072
  }
959
- const n = r.parseEditorState(t);
960
- n.isEmpty() || r.setEditorState(n);
961
- } catch (n) {
962
- console.error("Could not parse"), console.error(n);
1073
+ const o = r.parseEditorState(t);
1074
+ o.isEmpty() || r.setEditorState(o);
1075
+ } catch (o) {
1076
+ console.error("Could not parse"), console.error(o);
963
1077
  }
964
1078
  }));
965
1079
  }, []), null;
966
- }, rn = Ye("div", {
1080
+ }, Cn = nr("div", {
967
1081
  border: "1px solid $borderDarker",
968
1082
  borderRadius: "$md",
969
1083
  position: "relative",
@@ -1000,10 +1114,10 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1000
1114
  }
1001
1115
  }
1002
1116
  ]
1003
- }), nn = ({
1117
+ }), Mn = ({
1004
1118
  isLoading: t
1005
- }) => /* @__PURE__ */ o(
1006
- U,
1119
+ }) => /* @__PURE__ */ n(
1120
+ P,
1007
1121
  {
1008
1122
  css: {
1009
1123
  visibility: t ? "visible" : "hidden",
@@ -1012,58 +1126,58 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1012
1126
  right: "1rem",
1013
1127
  display: "flex"
1014
1128
  },
1015
- children: /* @__PURE__ */ o(pt, {})
1129
+ children: /* @__PURE__ */ n(kt, {})
1016
1130
  }
1017
- ), Kn = ({
1131
+ ), so = ({
1018
1132
  isLoading: t,
1019
1133
  children: r,
1020
1134
  placeholderText: e,
1021
- nodes: n,
1135
+ nodes: o,
1022
1136
  plugins: i,
1023
1137
  toolbar: a,
1024
1138
  toolbarContent: l,
1025
1139
  content: s,
1026
1140
  hideBorder: d,
1027
1141
  onBlur: c,
1028
- defaultState: h,
1142
+ defaultState: u,
1029
1143
  css: g,
1030
1144
  signUrl: k,
1031
- fileUpload: S,
1032
- editable: E = !0
1145
+ fileUpload: E,
1146
+ editable: R = !0
1033
1147
  }) => {
1034
- const { hasFocus: M, attributes: m } = Cr({ onBlur: c }), C = q(null), p = qt(
1035
- () => ({ hasFocus: M, editorRef: C, signUrl: k, fileUpload: S }),
1036
- [M, k, S]
1148
+ const { hasFocus: b, attributes: p } = Ir({ onBlur: c }), C = V(null), y = Qt(
1149
+ () => ({ hasFocus: b, editorRef: C, signUrl: k, fileUpload: E }),
1150
+ [b, k, E]
1037
1151
  );
1038
- return /* @__PURE__ */ o(oe.Provider, { value: p, children: /* @__PURE__ */ u(
1039
- rr,
1152
+ return /* @__PURE__ */ n(de.Provider, { value: y, children: /* @__PURE__ */ h(
1153
+ pr,
1040
1154
  {
1041
1155
  initialConfig: {
1042
1156
  namespace: "ain-rich-text",
1043
- onError: (D) => {
1044
- console.error(D);
1157
+ onError: (I) => {
1158
+ console.error(I);
1045
1159
  },
1046
- theme: bt,
1047
- nodes: n,
1048
- editable: E
1160
+ theme: Mt,
1161
+ nodes: o,
1162
+ editable: R
1049
1163
  },
1050
1164
  children: [
1051
- /* @__PURE__ */ u(
1052
- rn,
1165
+ /* @__PURE__ */ h(
1166
+ Cn,
1053
1167
  {
1054
1168
  ref: C,
1055
- hasFocus: M,
1169
+ hasFocus: b,
1056
1170
  hideBorder: d,
1057
1171
  css: g,
1058
- ...m,
1172
+ ...p,
1059
1173
  children: [
1060
1174
  a,
1061
- /* @__PURE__ */ o(
1062
- nr,
1175
+ /* @__PURE__ */ n(
1176
+ mr,
1063
1177
  {
1064
1178
  contentEditable: s,
1065
- placeholder: e ? /* @__PURE__ */ o(
1066
- U,
1179
+ placeholder: e ? /* @__PURE__ */ n(
1180
+ P,
1067
1181
  {
1068
1182
  css: {
1069
1183
  position: "absolute",
@@ -1076,22 +1190,22 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1076
1190
  children: e
1077
1191
  }
1078
1192
  ) : null,
1079
- ErrorBoundary: or
1193
+ ErrorBoundary: fr
1080
1194
  }
1081
1195
  ),
1082
- /* @__PURE__ */ o(tn, {}),
1196
+ /* @__PURE__ */ n(bn, {}),
1083
1197
  i,
1084
- /* @__PURE__ */ o(nn, { isLoading: t }),
1085
- E && !a && /* @__PURE__ */ o(qr, { children: l })
1198
+ /* @__PURE__ */ n(Mn, { isLoading: t }),
1199
+ R && !a && /* @__PURE__ */ n(un, { children: l })
1086
1200
  ]
1087
1201
  }
1088
1202
  ),
1089
- /* @__PURE__ */ o(en, { state: h }),
1090
- /* @__PURE__ */ o(j, { children: r })
1203
+ /* @__PURE__ */ n(vn, { state: u }),
1204
+ /* @__PURE__ */ n(F, { children: r })
1091
1205
  ]
1092
1206
  }
1093
1207
  ) });
1094
- }, on = {
1208
+ }, Tn = {
1095
1209
  fontSize: "1rem",
1096
1210
  lineHeight: "1.5",
1097
1211
  "h1, h2, h3, h4, h5, h6": {
@@ -1138,6 +1252,9 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1138
1252
  ".ain-rich-text-underline": {
1139
1253
  textDecoration: "underline"
1140
1254
  },
1255
+ ".ain-rich-text-strikethrough": {
1256
+ textDecoration: "line-through"
1257
+ },
1141
1258
  "ul, ol": {
1142
1259
  paddingLeft: "1.8em",
1143
1260
  listStylePosition: "outside",
@@ -1285,32 +1402,32 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1285
1402
  defaultVariants: {
1286
1403
  size: "md"
1287
1404
  }
1288
- }, Gn = hr(on), an = ({
1405
+ }, co = xr(Tn), xn = ({
1289
1406
  fileUpload: t,
1290
1407
  ...r
1291
1408
  }) => {
1292
- const [e] = x(), [n, i] = b(null), a = (s) => {
1409
+ const [e] = x(), [o, i] = m(null), a = (s) => {
1293
1410
  var c;
1294
1411
  const d = (c = s.target.files) == null ? void 0 : c[0];
1295
1412
  if (d) {
1296
- const h = new Image(), g = window.URL.createObjectURL(d);
1297
- h.onload = async () => {
1413
+ const u = new Image(), g = window.URL.createObjectURL(d);
1414
+ u.onload = async () => {
1298
1415
  const k = await t.uploadFile({ file: d });
1299
- i({ url: k, width: h.naturalWidth, height: h.naturalHeight }), window.URL.revokeObjectURL(g);
1300
- }, h.src = g;
1416
+ i({ url: k, width: u.naturalWidth, height: u.naturalHeight }), window.URL.revokeObjectURL(g);
1417
+ }, u.src = g;
1301
1418
  }
1302
1419
  }, l = () => {
1303
- n && !t.isLoading && (e.dispatchCommand(vt, {
1304
- src: n.url,
1305
- altText: `Image: ${n.url}`,
1306
- meta: { width: n.width, height: n.height }
1420
+ o && !t.isLoading && (e.dispatchCommand(Lt, {
1421
+ src: o.url,
1422
+ altText: `Image: ${o.url}`,
1423
+ meta: { width: o.width, height: o.height }
1307
1424
  }), r.onOpenChange(!1));
1308
1425
  };
1309
- return /* @__PURE__ */ u(Qt, { ...r, children: [
1310
- /* @__PURE__ */ o(qe, { children: "Sett inn bilde" }),
1311
- t.isLoading && /* @__PURE__ */ o(pt, {}),
1312
- /* @__PURE__ */ o(
1313
- mt,
1426
+ return /* @__PURE__ */ h(ne, { ...r, children: [
1427
+ /* @__PURE__ */ n(or, { children: "Sett inn bilde" }),
1428
+ t.isLoading && /* @__PURE__ */ n(kt, {}),
1429
+ /* @__PURE__ */ n(
1430
+ bt,
1314
1431
  {
1315
1432
  type: "file",
1316
1433
  accept: "image/*",
@@ -1318,113 +1435,113 @@ const tn = () => /* @__PURE__ */ u(j, { children: [
1318
1435
  disabled: t.isLoading
1319
1436
  }
1320
1437
  ),
1321
- /* @__PURE__ */ u(rt, { children: [
1322
- /* @__PURE__ */ o(L, { onClick: () => r.onOpenChange(!1), children: "Avbryt" }),
1323
- /* @__PURE__ */ o(
1324
- L,
1438
+ /* @__PURE__ */ h(st, { children: [
1439
+ /* @__PURE__ */ n(w, { onClick: () => r.onOpenChange(!1), children: "Avbryt" }),
1440
+ /* @__PURE__ */ n(
1441
+ w,
1325
1442
  {
1326
1443
  variant: "primary",
1327
- disabled: !n || t.isLoading,
1444
+ disabled: !o || t.isLoading,
1328
1445
  onClick: l,
1329
1446
  children: "Sett inn"
1330
1447
  }
1331
1448
  )
1332
1449
  ] })
1333
1450
  ] });
1334
- }, Yn = () => {
1335
- const [t] = x(), { fileUpload: r } = z(), [e, n] = b(!1), i = T(() => {
1336
- t.dispatchCommand(De, {
1451
+ }, ho = () => {
1452
+ const [t] = x(), { fileUpload: r } = H(), [e, o] = m(!1), i = M(() => {
1453
+ t.dispatchCommand(Je, {
1337
1454
  rows: "3",
1338
1455
  columns: "3",
1339
1456
  includeHeaders: !1
1340
1457
  });
1341
1458
  }, [t]);
1342
- return /* @__PURE__ */ u(j, { children: [
1343
- /* @__PURE__ */ u(
1344
- et,
1459
+ return /* @__PURE__ */ h(F, { children: [
1460
+ /* @__PURE__ */ h(
1461
+ at,
1345
1462
  {
1346
- trigger: /* @__PURE__ */ o(gt, { dropdown: !0, children: "Sett inn" }),
1463
+ trigger: /* @__PURE__ */ n(lt, { dropdown: !0, children: "Sett inn" }),
1347
1464
  side: "bottom",
1348
1465
  align: "end",
1349
1466
  children: [
1350
- /* @__PURE__ */ u(v, { onClick: i, children: [
1351
- /* @__PURE__ */ o(Hr, { size: "1.25rem" }),
1467
+ /* @__PURE__ */ h(T, { onClick: i, children: [
1468
+ /* @__PURE__ */ n(en, { size: "1.25rem" }),
1352
1469
  " Tabell"
1353
1470
  ] }),
1354
- r && /* @__PURE__ */ u(v, { onClick: () => n(!0), children: [
1355
- /* @__PURE__ */ o(tr, { size: "1.25rem" }),
1471
+ r && /* @__PURE__ */ h(T, { onClick: () => o(!0), children: [
1472
+ /* @__PURE__ */ n(ur, { size: "1.25rem" }),
1356
1473
  " Bilde"
1357
1474
  ] })
1358
1475
  ]
1359
1476
  }
1360
1477
  ),
1361
- r && /* @__PURE__ */ o(
1362
- an,
1478
+ r && /* @__PURE__ */ n(
1479
+ xn,
1363
1480
  {
1364
1481
  open: e,
1365
- onOpenChange: n,
1482
+ onOpenChange: o,
1366
1483
  fileUpload: r
1367
1484
  }
1368
1485
  )
1369
1486
  ] });
1370
1487
  };
1371
- function ln(t) {
1488
+ function Ln(t) {
1372
1489
  return f({ tag: "svg", attr: { viewBox: "0 0 512 512" }, child: [{ tag: "circle", attr: { cx: "256", cy: "256", r: "48" } }, { tag: "circle", attr: { cx: "416", cy: "256", r: "48" } }, { tag: "circle", attr: { cx: "96", cy: "256", r: "48" } }] })(t);
1373
1490
  }
1374
- const qn = () => {
1375
- const [t] = x(), [r, e] = b(null), { hasFocus: n } = z();
1491
+ const uo = () => {
1492
+ const [t] = x(), [r, e] = m(null), { hasFocus: o } = H();
1376
1493
  _(() => {
1377
- !n && r && e(null);
1378
- }, [n, r]);
1379
- const { refs: i, floatingStyles: a } = ft({
1494
+ !o && r && e(null);
1495
+ }, [o, r]);
1496
+ const { refs: i, floatingStyles: a } = vt({
1380
1497
  placement: "top-end",
1381
1498
  open: !!r,
1382
1499
  elements: {
1383
1500
  reference: r
1384
1501
  },
1385
- middleware: [Zt({ mainAxis: -20, crossAxis: -2 })]
1502
+ middleware: [ie({ mainAxis: -20, crossAxis: -2 })]
1386
1503
  });
1387
1504
  _(() => t.registerCommand(
1388
- Y,
1505
+ X,
1389
1506
  () => {
1390
- const s = y();
1507
+ const s = L();
1391
1508
  if (N(s)) {
1392
- const d = s.anchor.getNode(), c = Be(d);
1509
+ const d = s.anchor.getNode(), c = Ye(d);
1393
1510
  e(c ? t.getElementByKey(c.getKey()) : null);
1394
1511
  }
1395
1512
  return !1;
1396
1513
  },
1397
- Te
1514
+ q
1398
1515
  ), [t]);
1399
1516
  const l = (s) => () => {
1400
1517
  t.update(() => {
1401
1518
  switch (s) {
1402
1519
  case "add-row-over":
1403
- yt(!1);
1520
+ Et(!1);
1404
1521
  break;
1405
1522
  case "add-row-under":
1406
- yt(!0);
1523
+ Et(!0);
1407
1524
  break;
1408
1525
  case "add-column-left":
1409
- wt(!1);
1526
+ Nt(!1);
1410
1527
  break;
1411
1528
  case "add-column-right":
1412
- wt(!0);
1529
+ Nt(!0);
1413
1530
  break;
1414
1531
  case "delete-row":
1415
- Fe();
1532
+ Ve();
1416
1533
  break;
1417
1534
  case "delete-column":
1418
- Pe();
1535
+ Xe();
1419
1536
  break;
1420
1537
  }
1421
1538
  });
1422
1539
  };
1423
- return r ? /* @__PURE__ */ u(
1424
- et,
1540
+ return r ? /* @__PURE__ */ h(
1541
+ at,
1425
1542
  {
1426
- trigger: /* @__PURE__ */ o(
1427
- L,
1543
+ trigger: /* @__PURE__ */ n(
1544
+ w,
1428
1545
  {
1429
1546
  icon: !0,
1430
1547
  variant: "primary",
@@ -1432,44 +1549,44 @@ const qn = () => {
1432
1549
  ref: i.setFloating,
1433
1550
  style: a,
1434
1551
  css: { padding: "2px", width: "18px", height: "18px" },
1435
- children: /* @__PURE__ */ o(ln, {})
1552
+ children: /* @__PURE__ */ n(Ln, {})
1436
1553
  }
1437
1554
  ),
1438
1555
  children: [
1439
- /* @__PURE__ */ o(B, { onClick: l("add-row-over"), children: "Legg til rad over" }),
1440
- /* @__PURE__ */ o(B, { onClick: l("add-row-under"), children: "Legg til rad under" }),
1441
- /* @__PURE__ */ o(Nt, {}),
1442
- /* @__PURE__ */ o(B, { onClick: l("add-column-left"), children: "Legg til kolonne venstre" }),
1443
- /* @__PURE__ */ o(B, { onClick: l("add-column-right"), children: "Legg til kolonne høyre" }),
1444
- /* @__PURE__ */ o(Nt, {}),
1445
- /* @__PURE__ */ o(B, { onClick: l("delete-row"), children: "Fjern rad" }),
1446
- /* @__PURE__ */ o(B, { onClick: l("delete-column"), children: "Fjern kolonne" })
1556
+ /* @__PURE__ */ n(W, { onClick: l("add-row-over"), children: "Legg til rad over" }),
1557
+ /* @__PURE__ */ n(W, { onClick: l("add-row-under"), children: "Legg til rad under" }),
1558
+ /* @__PURE__ */ n(It, {}),
1559
+ /* @__PURE__ */ n(W, { onClick: l("add-column-left"), children: "Legg til kolonne venstre" }),
1560
+ /* @__PURE__ */ n(W, { onClick: l("add-column-right"), children: "Legg til kolonne høyre" }),
1561
+ /* @__PURE__ */ n(It, {}),
1562
+ /* @__PURE__ */ n(W, { onClick: l("delete-row"), children: "Fjern rad" }),
1563
+ /* @__PURE__ */ n(W, { onClick: l("delete-column"), children: "Fjern kolonne" })
1447
1564
  ]
1448
1565
  }
1449
1566
  ) : null;
1450
1567
  };
1451
- function Tt(t) {
1568
+ function _t(t) {
1452
1569
  let r = t;
1453
- const e = /^(?:(?:https?|mailto|ftp|tel|file|sms):|[^&:/?#]*(?:[/?#]|$))/gi, n = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i;
1454
- return r = String(r).trim(), r.match(e) || r.match(n) ? r : "https://";
1570
+ const e = /^(?:(?:https?|mailto|ftp|tel|file|sms):|[^&:/?#]*(?:[/?#]|$))/gi, o = /^data:(?:image\/(?:bmp|gif|jpeg|jpg|png|tiff|webp)|video\/(?:mpeg|mp4|ogg|webm)|audio\/(?:mp3|oga|ogg|opus));base64,[a-z0-9+/]+=*$/i;
1571
+ return r = String(r).trim(), r.match(e) || r.match(o) ? r : "https://";
1455
1572
  }
1456
- function le(t) {
1457
- const r = t.anchor, e = t.focus, n = t.anchor.getNode(), i = t.focus.getNode();
1458
- return n === i ? n : t.isBackward() ? Lt(e) ? n : i : Lt(r) ? n : i;
1573
+ function ge(t) {
1574
+ const r = t.anchor, e = t.focus, o = t.anchor.getNode(), i = t.focus.getNode();
1575
+ return o === i ? o : t.isBackward() ? yt(e) ? o : i : yt(r) ? o : i;
1459
1576
  }
1460
- const Jn = (t) => (A.baseURL = t, A), Q = class extends F {
1577
+ const go = (t) => (B.baseURL = t, B), rt = class extends j {
1461
1578
  static getType() {
1462
1579
  return "rutine_link";
1463
1580
  }
1464
1581
  static clone(r) {
1465
- return new Q(r.__url, {}, r.__key);
1582
+ return new rt(r.__url, {}, r.__key);
1466
1583
  }
1467
1584
  createDOM(r) {
1468
1585
  const e = super.createDOM(r);
1469
1586
  return e.setAttribute("href", this.getURL()), e.setAttribute("target", "_blank"), e.setAttribute("rel", "noopener noreferrer"), e.classList.add("rutine-link"), e;
1470
1587
  }
1471
1588
  static importJSON(r) {
1472
- return se(r.url);
1589
+ return pe(r.url);
1473
1590
  }
1474
1591
  exportJSON() {
1475
1592
  return {
@@ -1481,58 +1598,58 @@ const Jn = (t) => (A.baseURL = t, A), Q = class extends F {
1481
1598
  }
1482
1599
  getURL() {
1483
1600
  try {
1484
- return new URL(this.__url, Q.baseURL).toString();
1601
+ return new URL(this.__url, rt.baseURL).toString();
1485
1602
  } catch {
1486
1603
  return "";
1487
1604
  }
1488
1605
  }
1489
1606
  };
1490
- let A = Q;
1491
- O(A, "baseURL", "");
1492
- function se(t) {
1493
- return new A(t);
1607
+ let B = rt;
1608
+ $(B, "baseURL", "");
1609
+ function pe(t) {
1610
+ return new B(t);
1494
1611
  }
1495
- function sn(t) {
1496
- return t instanceof A;
1612
+ function _n(t) {
1613
+ return t instanceof B;
1497
1614
  }
1498
- const cn = ({ onClose: t }) => {
1499
- const [r] = x(), e = T(
1615
+ const wn = ({ onClose: t }) => {
1616
+ const [r] = x(), e = M(
1500
1617
  (i) => {
1501
1618
  r.update(() => {
1502
- const a = y();
1619
+ const a = L();
1503
1620
  if (N(a) && a.isCollapsed()) {
1504
- const l = I(i);
1621
+ const l = z(i);
1505
1622
  a.insertNodes([l]);
1506
- const s = Bt();
1507
- s.setTextNodeRange(l, 0, l, i.length), V(s);
1623
+ const s = Ut();
1624
+ s.setTextNodeRange(l, 0, l, i.length), nt(s);
1508
1625
  }
1509
- r.dispatchCommand(tt, Tt(i));
1626
+ r.dispatchCommand(it, _t(i));
1510
1627
  });
1511
1628
  },
1512
1629
  [r]
1513
1630
  );
1514
- return /* @__PURE__ */ u("form", { onSubmit: (i) => {
1631
+ return /* @__PURE__ */ h("form", { onSubmit: (i) => {
1515
1632
  e(i.currentTarget.url.value), t();
1516
1633
  }, children: [
1517
- /* @__PURE__ */ o(mt, { name: "url", label: "URL", type: "url", required: !0 }),
1518
- /* @__PURE__ */ u(rt, { children: [
1519
- /* @__PURE__ */ o(L, { onClick: t, children: "Avbryt" }),
1520
- /* @__PURE__ */ o(L, { type: "submit", variant: "primary", children: "Sett inn" })
1634
+ /* @__PURE__ */ n(bt, { name: "url", label: "URL", type: "url", required: !0 }),
1635
+ /* @__PURE__ */ h(st, { children: [
1636
+ /* @__PURE__ */ n(w, { onClick: t, children: "Avbryt" }),
1637
+ /* @__PURE__ */ n(w, { type: "submit", variant: "primary", children: "Sett inn" })
1521
1638
  ] })
1522
1639
  ] });
1523
- }, dn = ({
1640
+ }, yn = ({
1524
1641
  onClose: t,
1525
1642
  getDocs: r
1526
1643
  }) => {
1527
- const [e] = x(), [n, i] = b([]), a = r(), l = T(
1644
+ const [e] = x(), [o, i] = m([]), a = r(), l = M(
1528
1645
  (s) => {
1529
1646
  e.update(() => {
1530
- const d = y();
1647
+ const d = L();
1531
1648
  if (N(d)) {
1532
1649
  const c = [];
1533
- for (const [h, g] of s.entries()) {
1534
- const k = se(g.value);
1535
- k.append(I(g.label)), c.push(k), h !== s.length - 1 && c.push(I(" "));
1650
+ for (const [u, g] of s.entries()) {
1651
+ const k = pe(g.value);
1652
+ k.append(z(g.label)), c.push(k), u !== s.length - 1 && c.push(z(" "));
1536
1653
  }
1537
1654
  d.insertNodes(c);
1538
1655
  }
@@ -1540,37 +1657,37 @@ const cn = ({ onClose: t }) => {
1540
1657
  },
1541
1658
  [e]
1542
1659
  );
1543
- return /* @__PURE__ */ u(j, { children: [
1544
- /* @__PURE__ */ o(
1545
- Xe,
1660
+ return /* @__PURE__ */ h(F, { children: [
1661
+ /* @__PURE__ */ n(
1662
+ ar,
1546
1663
  {
1547
1664
  isMulti: !0,
1548
1665
  options: a,
1549
1666
  onChange: (s) => i(s)
1550
1667
  }
1551
1668
  ),
1552
- /* @__PURE__ */ u(rt, { children: [
1553
- /* @__PURE__ */ o(L, { onClick: t, children: "Avbryt" }),
1554
- /* @__PURE__ */ o(
1555
- L,
1669
+ /* @__PURE__ */ h(st, { children: [
1670
+ /* @__PURE__ */ n(w, { onClick: t, children: "Avbryt" }),
1671
+ /* @__PURE__ */ n(
1672
+ w,
1556
1673
  {
1557
1674
  variant: "primary",
1558
1675
  onClick: () => {
1559
- l(n), t();
1676
+ l(o), t();
1560
1677
  },
1561
1678
  children: "Sett inn"
1562
1679
  }
1563
1680
  )
1564
1681
  ] })
1565
1682
  ] });
1566
- }, hn = ({
1683
+ }, Sn = ({
1567
1684
  onClose: t,
1568
1685
  fileUpload: r,
1569
1686
  filePrefix: e
1570
1687
  }) => {
1571
- const [n] = x(), [i, a] = b(null), l = async (d) => {
1572
- var h;
1573
- const c = (h = d.target.files) == null ? void 0 : h[0];
1688
+ const [o] = x(), [i, a] = m(null), l = async (d) => {
1689
+ var u;
1690
+ const c = (u = d.target.files) == null ? void 0 : u[0];
1574
1691
  if (c) {
1575
1692
  const g = await r.uploadFile({ file: c });
1576
1693
  a({
@@ -1578,34 +1695,34 @@ const cn = ({ onClose: t }) => {
1578
1695
  url: e ? `${e}${g}` : g
1579
1696
  });
1580
1697
  }
1581
- }, s = T(() => {
1582
- n.update(() => {
1698
+ }, s = M(() => {
1699
+ o.update(() => {
1583
1700
  if (!i)
1584
1701
  return;
1585
- const d = y();
1702
+ const d = L();
1586
1703
  if (N(d) && d.isCollapsed()) {
1587
- const c = I(i.name);
1704
+ const c = z(i.name);
1588
1705
  d.insertNodes([c]);
1589
- const h = Bt();
1590
- h.setTextNodeRange(c, 0, c, i.name.length), V(h);
1706
+ const u = Ut();
1707
+ u.setTextNodeRange(c, 0, c, i.name.length), nt(u);
1591
1708
  }
1592
- n.dispatchCommand(tt, Tt(i.url));
1709
+ o.dispatchCommand(it, _t(i.url));
1593
1710
  });
1594
- }, [n, i]);
1595
- return /* @__PURE__ */ u(j, { children: [
1596
- r.isLoading && /* @__PURE__ */ o(pt, {}),
1597
- /* @__PURE__ */ o(
1598
- mt,
1711
+ }, [o, i]);
1712
+ return /* @__PURE__ */ h(F, { children: [
1713
+ r.isLoading && /* @__PURE__ */ n(kt, {}),
1714
+ /* @__PURE__ */ n(
1715
+ bt,
1599
1716
  {
1600
1717
  type: "file",
1601
1718
  onChange: l,
1602
1719
  disabled: r.isLoading
1603
1720
  }
1604
1721
  ),
1605
- /* @__PURE__ */ u(rt, { children: [
1606
- /* @__PURE__ */ o(L, { onClick: t, children: "Avbryt" }),
1607
- /* @__PURE__ */ o(
1608
- L,
1722
+ /* @__PURE__ */ h(st, { children: [
1723
+ /* @__PURE__ */ n(w, { onClick: t, children: "Avbryt" }),
1724
+ /* @__PURE__ */ n(
1725
+ w,
1609
1726
  {
1610
1727
  variant: "primary",
1611
1728
  onClick: () => {
@@ -1617,68 +1734,68 @@ const cn = ({ onClose: t }) => {
1617
1734
  )
1618
1735
  ] })
1619
1736
  ] });
1620
- }, un = ({
1737
+ }, Nn = ({
1621
1738
  open: t,
1622
1739
  onOpenChange: r,
1623
1740
  getDocs: e,
1624
- filePrefix: n
1741
+ filePrefix: o
1625
1742
  }) => {
1626
- const { fileUpload: i } = z(), [a, l] = b("url"), s = () => {
1743
+ const { fileUpload: i } = H(), [a, l] = m("url"), s = () => {
1627
1744
  r(!1);
1628
1745
  };
1629
- return /* @__PURE__ */ u(Qt, { open: t, onOpenChange: r, css: { width: "600px" }, children: [
1630
- /* @__PURE__ */ u(Je, { css: { marginBottom: "$8" }, children: [
1631
- /* @__PURE__ */ o(lt, { active: a === "url", onClick: () => l("url"), children: "URL" }),
1632
- e && /* @__PURE__ */ o(
1633
- lt,
1746
+ return /* @__PURE__ */ h(ne, { open: t, onOpenChange: r, css: { width: "600px" }, children: [
1747
+ /* @__PURE__ */ h(ir, { css: { marginBottom: "$8" }, children: [
1748
+ /* @__PURE__ */ n(ut, { active: a === "url", onClick: () => l("url"), children: "URL" }),
1749
+ e && /* @__PURE__ */ n(
1750
+ ut,
1634
1751
  {
1635
1752
  active: a === "rutine",
1636
1753
  onClick: () => l("rutine"),
1637
1754
  children: "Rutine"
1638
1755
  }
1639
1756
  ),
1640
- i && /* @__PURE__ */ o(lt, { active: a === "file", onClick: () => l("file"), children: "Fil" })
1757
+ i && /* @__PURE__ */ n(ut, { active: a === "file", onClick: () => l("file"), children: "Fil" })
1641
1758
  ] }),
1642
- a === "url" && /* @__PURE__ */ o(cn, { onClose: s }),
1643
- a === "rutine" && e && /* @__PURE__ */ o(dn, { onClose: s, getDocs: e }),
1644
- a === "file" && i && /* @__PURE__ */ o(
1645
- hn,
1759
+ a === "url" && /* @__PURE__ */ n(wn, { onClose: s }),
1760
+ a === "rutine" && e && /* @__PURE__ */ n(yn, { onClose: s, getDocs: e }),
1761
+ a === "file" && i && /* @__PURE__ */ n(
1762
+ Sn,
1646
1763
  {
1647
1764
  onClose: s,
1648
1765
  fileUpload: i,
1649
- filePrefix: n
1766
+ filePrefix: o
1650
1767
  }
1651
1768
  )
1652
1769
  ] });
1653
- }, Xn = ({
1770
+ }, po = ({
1654
1771
  getDocs: t,
1655
1772
  filePrefix: r
1656
1773
  }) => {
1657
- const [e] = x(), [n, i] = b(!1), [a, l] = b(!1), s = T(() => {
1658
- const d = y();
1774
+ const [e] = x(), [o, i] = m(!1), [a, l] = m(!1), s = M(() => {
1775
+ const d = L();
1659
1776
  if (N(d)) {
1660
- const c = le(d), h = c.getParent();
1661
- i(J(h) || J(c));
1777
+ const c = ge(d), u = c.getParent();
1778
+ i(Z(u) || Z(c));
1662
1779
  }
1663
1780
  }, []);
1664
1781
  return _(() => e.registerCommand(
1665
- Y,
1782
+ X,
1666
1783
  () => (s(), !1),
1667
- ct
1668
- ), [e, s]), /* @__PURE__ */ u(Jt, { type: "single", value: n ? "link" : "", children: [
1669
- /* @__PURE__ */ o(
1670
- P,
1784
+ q
1785
+ ), [e, s]), /* @__PURE__ */ h(tt, { type: "single", value: o ? "link" : "", children: [
1786
+ /* @__PURE__ */ n(
1787
+ O,
1671
1788
  {
1672
1789
  onClick: () => {
1673
- n ? e.dispatchCommand(tt, null) : l(!0);
1790
+ o ? e.dispatchCommand(it, null) : l(!0);
1674
1791
  },
1675
1792
  title: "Lenke",
1676
1793
  value: "link",
1677
- children: /* @__PURE__ */ o(zr, { size: "1.25rem" })
1794
+ children: /* @__PURE__ */ n(qr, { size: "1.25rem" })
1678
1795
  }
1679
1796
  ),
1680
- /* @__PURE__ */ o(
1681
- un,
1797
+ /* @__PURE__ */ n(
1798
+ Nn,
1682
1799
  {
1683
1800
  open: a,
1684
1801
  onOpenChange: l,
@@ -1687,67 +1804,67 @@ const cn = ({ onClose: t }) => {
1687
1804
  }
1688
1805
  )
1689
1806
  ] });
1690
- }, Qn = () => {
1691
- const [t] = x(), r = q(null), [e, n] = b(null), [i, a] = b(""), { hasFocus: l } = z();
1807
+ }, mo = () => {
1808
+ const [t] = x(), r = V(null), [e, o] = m(null), [i, a] = m(""), { hasFocus: l } = H();
1692
1809
  _(() => {
1693
1810
  e ? t.update(() => {
1694
1811
  a(e.getURL());
1695
1812
  }) : a("");
1696
1813
  }, [t, e]);
1697
- const s = !!(e && i && l), { refs: d, floatingStyles: c, context: h } = ft({
1814
+ const s = !!(e && i && l), { refs: d, floatingStyles: c, context: u } = vt({
1698
1815
  placement: "top",
1699
1816
  strategy: "fixed",
1700
1817
  open: s,
1701
- whileElementsMounted: Vt,
1818
+ whileElementsMounted: oe,
1702
1819
  elements: {
1703
1820
  reference: r.current
1704
1821
  },
1705
- middleware: [sr()]
1706
- }), { getFloatingProps: g } = te([
1707
- ee(h),
1708
- cr(h)
1709
- ]), k = T(() => {
1710
- var m;
1711
- const M = y();
1712
- if (N(M)) {
1713
- const C = le(M), p = C.getParent();
1714
- let D = null;
1715
- if (J(p) ? D = p : J(C) && (D = C), D) {
1716
- const nt = window.getSelection(), _t = t.getRootElement();
1717
- M !== null && nt !== null && _t !== null && _t.contains(nt.anchorNode) && t.isEditable() && (r.current = ((m = nt.focusNode) == null ? void 0 : m.parentElement) ?? null);
1822
+ middleware: [Cr()]
1823
+ }), { getFloatingProps: g } = ae([
1824
+ le(u),
1825
+ Mr(u)
1826
+ ]), k = M(() => {
1827
+ var p;
1828
+ const b = L();
1829
+ if (N(b)) {
1830
+ const C = ge(b), y = C.getParent();
1831
+ let I = null;
1832
+ if (Z(y) ? I = y : Z(C) && (I = C), I) {
1833
+ const J = window.getSelection(), Q = t.getRootElement();
1834
+ b !== null && J !== null && Q !== null && Q.contains(J.anchorNode) && t.isEditable() && (r.current = ((p = J.focusNode) == null ? void 0 : p.parentElement) ?? null);
1718
1835
  }
1719
- n(D);
1836
+ o(I);
1720
1837
  }
1721
- }, [t]), S = T(() => {
1722
- e && sn(e) && t.update(() => {
1838
+ }, [t]), E = M(() => {
1839
+ e && _n(e) && t.update(() => {
1723
1840
  e.remove();
1724
- }), t.dispatchCommand(tt, null);
1841
+ }), t.dispatchCommand(it, null);
1725
1842
  }, [t, e]);
1726
1843
  if (_(() => {
1727
1844
  t.getEditorState().read(() => {
1728
1845
  k();
1729
1846
  });
1730
- }, [t, k]), _(() => Z(
1731
- t.registerUpdateListener(({ editorState: M }) => {
1732
- M.read(() => {
1847
+ }, [t, k]), _(() => ot(
1848
+ t.registerUpdateListener(({ editorState: b }) => {
1849
+ b.read(() => {
1733
1850
  k();
1734
1851
  });
1735
1852
  }),
1736
1853
  t.registerCommand(
1737
- Y,
1738
- () => (k(), !0),
1739
- R
1854
+ X,
1855
+ () => (k(), !1),
1856
+ q
1740
1857
  ),
1741
1858
  t.registerCommand(
1742
- Dt,
1743
- () => e ? (n(null), !0) : !1,
1744
- _e
1859
+ Ht,
1860
+ () => e ? (o(null), !0) : !1,
1861
+ Ie
1745
1862
  )
1746
1863
  ), [t, k, e]), !s)
1747
1864
  return null;
1748
- const E = Tt(i);
1749
- return /* @__PURE__ */ o(re, { children: /* @__PURE__ */ u(
1750
- Xt,
1865
+ const R = _t(i);
1866
+ return /* @__PURE__ */ n(se, { children: /* @__PURE__ */ h(
1867
+ re,
1751
1868
  {
1752
1869
  ref: d.setFloating,
1753
1870
  css: {
@@ -1760,8 +1877,8 @@ const cn = ({ onClose: t }) => {
1760
1877
  style: c,
1761
1878
  ...g(),
1762
1879
  children: [
1763
- /* @__PURE__ */ o(
1764
- U,
1880
+ /* @__PURE__ */ n(
1881
+ P,
1765
1882
  {
1766
1883
  as: "a",
1767
1884
  css: {
@@ -1771,51 +1888,51 @@ const cn = ({ onClose: t }) => {
1771
1888
  textOverflow: "ellipsis",
1772
1889
  marginRight: "$4"
1773
1890
  },
1774
- href: E,
1775
- title: E,
1891
+ href: R,
1892
+ title: R,
1776
1893
  target: "_blank",
1777
1894
  rel: "noreferrer",
1778
1895
  children: i
1779
1896
  }
1780
1897
  ),
1781
- /* @__PURE__ */ o(L, { color: "danger", icon: !0, size: "sm", onClick: S, children: /* @__PURE__ */ o(er, { size: 24 }) })
1898
+ /* @__PURE__ */ n(w, { color: "danger", icon: !0, size: "sm", onClick: E, children: /* @__PURE__ */ n(gr, { size: 24 }) })
1782
1899
  ]
1783
1900
  }
1784
1901
  ) });
1785
- }, Vn = () => {
1786
- const [t] = kt();
1787
- return /* @__PURE__ */ u(
1788
- et,
1902
+ }, fo = () => {
1903
+ const [t] = Ct();
1904
+ return /* @__PURE__ */ h(
1905
+ at,
1789
1906
  {
1790
1907
  align: "end",
1791
- trigger: /* @__PURE__ */ o(gt, { dropdown: !0, children: /* @__PURE__ */ o(St, { size: "1.25rem" }) }),
1908
+ trigger: /* @__PURE__ */ n(lt, { dropdown: !0, children: /* @__PURE__ */ n(Ot, { size: "1.25rem" }) }),
1792
1909
  children: [
1793
- /* @__PURE__ */ u(
1794
- v,
1910
+ /* @__PURE__ */ h(
1911
+ T,
1795
1912
  {
1796
- onClick: () => t.dispatchCommand(it, "left"),
1913
+ onClick: () => t.dispatchCommand(dt, "left"),
1797
1914
  children: [
1798
- /* @__PURE__ */ o(St, { size: "1.25rem" }),
1915
+ /* @__PURE__ */ n(Ot, { size: "1.25rem" }),
1799
1916
  "Venstre"
1800
1917
  ]
1801
1918
  }
1802
1919
  ),
1803
- /* @__PURE__ */ u(
1804
- v,
1920
+ /* @__PURE__ */ h(
1921
+ T,
1805
1922
  {
1806
- onClick: () => t.dispatchCommand(it, "center"),
1923
+ onClick: () => t.dispatchCommand(dt, "center"),
1807
1924
  children: [
1808
- /* @__PURE__ */ o(_r, { size: "1.25rem" }),
1925
+ /* @__PURE__ */ n($r, { size: "1.25rem" }),
1809
1926
  "Midt"
1810
1927
  ]
1811
1928
  }
1812
1929
  ),
1813
- /* @__PURE__ */ u(
1814
- v,
1930
+ /* @__PURE__ */ h(
1931
+ T,
1815
1932
  {
1816
- onClick: () => t.dispatchCommand(it, "right"),
1933
+ onClick: () => t.dispatchCommand(dt, "right"),
1817
1934
  children: [
1818
- /* @__PURE__ */ o(Lr, { size: "1.25rem" }),
1935
+ /* @__PURE__ */ n(Ar, { size: "1.25rem" }),
1819
1936
  "Høyre"
1820
1937
  ]
1821
1938
  }
@@ -1823,21 +1940,21 @@ const cn = ({ onClose: t }) => {
1823
1940
  ]
1824
1941
  }
1825
1942
  );
1826
- }, Ot = ["image/"], Zn = () => {
1827
- const [t] = kt(), { fileUpload: r } = z();
1943
+ }, Dt = ["image/"], ko = () => {
1944
+ const [t] = Ct(), { fileUpload: r } = H();
1828
1945
  return _(() => t.registerCommand(
1829
- $e,
1946
+ qe,
1830
1947
  (e) => ((async () => {
1831
- const n = await Ne(
1948
+ const o = await Pe(
1832
1949
  e,
1833
- [Ot].flatMap((i) => i)
1950
+ [Dt].flatMap((i) => i)
1834
1951
  );
1835
- for (const { file: i, result: a } of n)
1836
- if (Se(i, Ot)) {
1952
+ for (const { file: i, result: a } of o)
1953
+ if (Fe(i, Dt)) {
1837
1954
  let l = a;
1838
1955
  const s = new Image(), d = window.URL.createObjectURL(i);
1839
1956
  s.onload = async () => {
1840
- r && (l = await r.uploadFile({ file: i })), t.dispatchCommand(vt, {
1957
+ r && (l = await r.uploadFile({ file: i })), t.dispatchCommand(Lt, {
1841
1958
  src: l,
1842
1959
  altText: i.name,
1843
1960
  meta: { width: s.naturalWidth, height: s.naturalHeight }
@@ -1845,39 +1962,39 @@ const cn = ({ onClose: t }) => {
1845
1962
  }, s.src = d;
1846
1963
  }
1847
1964
  })(), !0),
1848
- R
1965
+ D
1849
1966
  ), [t, r]), null;
1850
1967
  };
1851
1968
  export {
1852
- Ct as $createImageNode,
1853
- se as $createRutineLinkNode,
1854
- Hn as $getNodesOfTypes,
1855
- Un as $isImageNode,
1856
- sn as $isRutineLinkNode,
1857
- Vn as AlignToolbarDropdown,
1858
- Zn as DragDropPastePlugin,
1859
- qr as FloatingToolbar,
1860
- $ as ImageNode,
1861
- Yn as InsertSelector,
1862
- Qn as LinkEditPlugin,
1863
- X as LinkTargetNode,
1864
- Xn as LinkToolbarButton,
1865
- Kn as RichTextEditor,
1866
- Jr as RichTextToolbar,
1867
- A as RutineLinkNode,
1868
- Jn as RutineLinkNodeInit,
1869
- qn as TableEditPlugin,
1870
- br as clearEditorState,
1871
- Wn as defaultNodes,
1872
- jn as defaultViewNodes,
1873
- kr as isEditorState,
1874
- Mt as isJSON,
1875
- oe as richTextContext,
1876
- Gn as richTextCss,
1877
- on as richTextStyleObj,
1878
- Mr as setStateFromPlainText,
1879
- Pn as stateToHTML,
1880
- Fn as syncStateToHTML,
1881
- Cr as useHasFocusWithin,
1882
- z as useRichTextContext
1969
+ xt as $createImageNode,
1970
+ pe as $createRutineLinkNode,
1971
+ oo as $getNodesOfTypes,
1972
+ io as $isImageNode,
1973
+ _n as $isRutineLinkNode,
1974
+ fo as AlignToolbarDropdown,
1975
+ ko as DragDropPastePlugin,
1976
+ un as FloatingToolbar,
1977
+ U as ImageNode,
1978
+ ho as InsertSelector,
1979
+ mo as LinkEditPlugin,
1980
+ et as LinkTargetNode,
1981
+ po as LinkToolbarButton,
1982
+ so as RichTextEditor,
1983
+ gn as RichTextToolbar,
1984
+ B as RutineLinkNode,
1985
+ go as RutineLinkNodeInit,
1986
+ uo as TableEditPlugin,
1987
+ Er as clearEditorState,
1988
+ ao as defaultNodes,
1989
+ lo as defaultViewNodes,
1990
+ Nr as isEditorState,
1991
+ Tt as isJSON,
1992
+ de as richTextContext,
1993
+ co as richTextCss,
1994
+ Tn as richTextStyleObj,
1995
+ Rr as setStateFromPlainText,
1996
+ ro as stateToHTML,
1997
+ no as syncStateToHTML,
1998
+ Ir as useHasFocusWithin,
1999
+ H as useRichTextContext
1883
2000
  };