@arkitektbedriftene/fe-lib 0.4.9 → 0.4.10

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.
@@ -11,7 +11,7 @@ import { HeadingNode as ae, QuoteNode as le, $isHeadingNode as se, $createHeadin
11
11
  import { TableNode as ue, TableRowNode as he, TableCellNode as pe, $getTableCellNodeFromLexicalNode as ge, $deleteTableColumn__EXPERIMENTAL as fe, $deleteTableRow__EXPERIMENTAL as me, $insertTableColumn__EXPERIMENTAL as st, $insertTableRow__EXPERIMENTAL as ct } from "@lexical/table";
12
12
  import { jsx as n, jsxs as m, Fragment as Y } from "react/jsx-runtime";
13
13
  import { createContext as ke, useState as b, useRef as et, useCallback as v, useContext as be, useEffect as N, useMemo as Mt, useLayoutEffect as ve } from "react";
14
- import { c as O, s as Lt, D as Tt, T as Ce, a as M, B as P, b as Nt, d as _, u as rt, e as yt, f as Me, g as Le, o as xt, h as Te, i as Et, j as St, F as wt, O as Rt, k as Ne, l as ye, S as xe, m as $, n as I, p as dt, q as Ee, N as Se, r as ut, t as we, v as It, C as Re, w as Ie, x as _e } from "./TextInput-c4d1672c.js";
14
+ import { c as O, s as Lt, D as Tt, T as Ce, a as M, B as P, b as Nt, d as _, u as rt, e as yt, f as Me, g as Le, o as xt, h as Te, i as Et, j as St, F as wt, O as Rt, k as Ne, l as ye, S as xe, m as $, n as I, p as dt, q as Ee, N as Se, r as ut, t as we, v as It, C as Re, w as Ie, x as _e } from "./TextInput-832f6509.js";
15
15
  import "react-select";
16
16
  import { LexicalComposer as ze } from "@lexical/react/LexicalComposer.js";
17
17
  import { RichTextPlugin as $e } from "@lexical/react/LexicalRichTextPlugin.js";
@@ -25,6 +25,7 @@ import { TablePlugin as Fe } from "@lexical/react/LexicalTablePlugin.js";
25
25
  import { TabIndentationPlugin as He } from "@lexical/react/LexicalTabIndentationPlugin.js";
26
26
  import "react-dom";
27
27
  import "@radix-ui/react-toolbar";
28
+ import "@radix-ui/react-dialog";
28
29
  import "@radix-ui/react-dropdown-menu";
29
30
  const We = ({
30
31
  text: t,
@@ -74,7 +75,7 @@ const We = ({
74
75
  tag: r
75
76
  }
76
77
  ), e.blur();
77
- }, cn = (t, e, r) => {
78
+ }, dn = (t, e, r) => {
78
79
  let o = 0;
79
80
  const i = Wt({
80
81
  nodes: e,
@@ -103,7 +104,7 @@ const We = ({
103
104
  return i.update(() => {
104
105
  l = Ut(i);
105
106
  }), { html: l, trimCount: o };
106
- }, dn = [
107
+ }, un = [
107
108
  ae,
108
109
  le,
109
110
  vt,
@@ -701,7 +702,7 @@ const Er = () => /* @__PURE__ */ m(Y, { children: [
701
702
  },
702
703
  children: /* @__PURE__ */ n(xe, {})
703
704
  }
704
- ), un = ({
705
+ ), hn = ({
705
706
  isLoading: t,
706
707
  children: e,
707
708
  placeholderText: r,
@@ -772,7 +773,7 @@ const Er = () => /* @__PURE__ */ m(Y, { children: [
772
773
  ]
773
774
  }
774
775
  ) });
775
- }, hn = O({
776
+ }, pn = O({
776
777
  fontSize: "1rem",
777
778
  lineHeight: "1.5",
778
779
  "h1, h2, h3, h4, h5, h6": {
@@ -947,7 +948,7 @@ const Er = () => /* @__PURE__ */ m(Y, { children: [
947
948
  function Ir(t) {
948
949
  return p({ 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);
949
950
  }
950
- const pn = () => {
951
+ const gn = () => {
951
952
  const [t] = y(), [e, r] = b(null), { hasFocus: o } = ot();
952
953
  N(() => {
953
954
  !o && e && r(null);
@@ -1033,7 +1034,7 @@ function At(t) {
1033
1034
  const e = t.anchor, r = t.focus, o = t.anchor.getNode(), i = t.focus.getNode();
1034
1035
  return o === i ? o : t.isBackward() ? lt(r) ? o : i : lt(e) ? o : i;
1035
1036
  }
1036
- const gn = (t) => (R.baseURL = t, R), U = class extends bt {
1037
+ const fn = (t) => (R.baseURL = t, R), U = class extends bt {
1037
1038
  static getType() {
1038
1039
  return "rutine_link";
1039
1040
  }
@@ -1145,7 +1146,7 @@ const zr = ({ onClose: t }) => {
1145
1146
  o === "url" && /* @__PURE__ */ n(zr, { onClose: l }),
1146
1147
  o === "rutine" && /* @__PURE__ */ n($r, { onClose: l, getDocs: r })
1147
1148
  ] });
1148
- }, fn = ({ getDocs: t }) => {
1149
+ }, mn = ({ getDocs: t }) => {
1149
1150
  const [e] = y(), [r, o] = b(!1), [i, l] = b(!1), a = v(() => {
1150
1151
  const s = L();
1151
1152
  if (T(s)) {
@@ -1178,7 +1179,7 @@ const zr = ({ onClose: t }) => {
1178
1179
  }
1179
1180
  )
1180
1181
  ] });
1181
- }, mn = () => {
1182
+ }, kn = () => {
1182
1183
  const [t] = y(), e = et(null), [r, o] = b(null), [i, l] = b(""), { hasFocus: a } = ot();
1183
1184
  N(() => {
1184
1185
  r ? t.update(() => {
@@ -1278,21 +1279,21 @@ export {
1278
1279
  Pt as $createRutineLinkNode,
1279
1280
  _r as $isRutineLinkNode,
1280
1281
  Lr as FloatingToolbar,
1281
- mn as LinkEditPlugin,
1282
- fn as LinkToolbarButton,
1283
- un as RichTextEditor,
1282
+ kn as LinkEditPlugin,
1283
+ mn as LinkToolbarButton,
1284
+ hn as RichTextEditor,
1284
1285
  Tr as RichTextToolbar,
1285
1286
  R as RutineLinkNode,
1286
- gn as RutineLinkNodeInit,
1287
- pn as TableEditPlugin,
1287
+ fn as RutineLinkNodeInit,
1288
+ gn as TableEditPlugin,
1288
1289
  Ke as clearEditorState,
1289
- dn as defaultNodes,
1290
+ un as defaultNodes,
1290
1291
  je as isEditorState,
1291
1292
  zt as isJSON,
1292
1293
  $t as richTextContext,
1293
- hn as richTextCss,
1294
+ pn as richTextCss,
1294
1295
  Ye as setStateFromPlainText,
1295
- cn as stateToHTML,
1296
+ dn as stateToHTML,
1296
1297
  Ze as useHasFocusWithin,
1297
1298
  ot as useRichTextContext
1298
1299
  };
@@ -1,9 +1,10 @@
1
- import { type ReactNode } from "react";
2
- export declare const Dialog: ({ children, open, onOpenChange, ...props }: {
1
+ import type { ReactNode } from "react";
2
+ export declare const Dialog: ({ children, open, onOpenChange, trigger, }: {
3
3
  children: ReactNode;
4
4
  open: boolean;
5
5
  onOpenChange: (bool: boolean) => void;
6
- }) => import("react").ReactPortal | null;
6
+ trigger?: ReactNode;
7
+ }) => JSX.Element;
7
8
  export declare const DialogHeader: import("@stitches/react/types/styled-component").StyledComponent<"h2", {}, {
8
9
  lg: "(min-width: 1200px)";
9
10
  print: "print";
package/dist/ui.es.js CHANGED
@@ -1,13 +1,14 @@
1
- import { P as t, y as n, z as l, R as p } from "./TextInput-c4d1672c.js";
2
- import { H as D, I as B, B as M, m as y, J as h, K as w, C as O, q as P, v as k, L as A, D as N, U as $, a as j, n as z, p as G, M as H, N as R, r as q, O as E, S as J, t as K, k as L, T as Q, l as U, b as F, d as V, c as W, G as X, E as Y, A as Z, Q as _, s as oo } from "./TextInput-c4d1672c.js";
1
+ import { P as t, y as n, z as l, R as p } from "./TextInput-832f6509.js";
2
+ import { H as B, I as M, B as y, m as h, J as w, K as O, C as P, q as k, v as A, L as N, D as $, U as j, a as z, n as G, p as H, M as R, N as q, r as E, O as J, S as K, t as L, k as Q, T as U, l as F, b as V, d as W, c as X, G as Y, E as Z, A as _, Q as oo, s as ao } from "./TextInput-832f6509.js";
3
3
  import { jsxs as i, jsx as e } from "react/jsx-runtime";
4
4
  import { useState as m } from "react";
5
5
  import "react-dom";
6
6
  import "@radix-ui/react-toolbar";
7
7
  import "./index.esm-b848a615.js";
8
+ import "@radix-ui/react-dialog";
8
9
  import "@radix-ui/react-dropdown-menu";
9
10
  import "react-select";
10
- const v = ({ children: o, content: a }) => {
11
+ const x = ({ children: o, content: a }) => {
11
12
  const [s, r] = m(!1);
12
13
  return /* @__PURE__ */ i(
13
14
  t,
@@ -31,7 +32,7 @@ const v = ({ children: o, content: a }) => {
31
32
  ]
32
33
  }
33
34
  );
34
- }, x = ({ clearable: o, ...a }) => /* @__PURE__ */ e(
35
+ }, I = ({ clearable: o, ...a }) => /* @__PURE__ */ e(
35
36
  p,
36
37
  {
37
38
  ...a,
@@ -41,41 +42,41 @@ const v = ({ children: o, content: a }) => {
41
42
  }
42
43
  );
43
44
  export {
44
- D as Alert,
45
- B as Badge,
46
- M as Box,
47
- y as Button,
48
- h as ButtonInToolbar,
49
- w as Card,
50
- O as Combobox,
51
- P as Dialog,
52
- k as DialogActions,
53
- A as DialogHeader,
54
- N as DropdownMenu,
55
- $ as DropdownMenuCheckboxItem,
56
- j as DropdownMenuIconItem,
57
- z as DropdownMenuItem,
58
- G as DropdownMenuSeparator,
59
- H as MenuOverlayCard,
60
- R as NavBar,
61
- q as NavBarItem,
62
- E as OverlayCard,
45
+ B as Alert,
46
+ M as Badge,
47
+ y as Box,
48
+ h as Button,
49
+ w as ButtonInToolbar,
50
+ O as Card,
51
+ P as Combobox,
52
+ k as Dialog,
53
+ A as DialogActions,
54
+ N as DialogHeader,
55
+ $ as DropdownMenu,
56
+ j as DropdownMenuCheckboxItem,
57
+ z as DropdownMenuIconItem,
58
+ G as DropdownMenuItem,
59
+ H as DropdownMenuSeparator,
60
+ R as MenuOverlayCard,
61
+ q as NavBar,
62
+ E as NavBarItem,
63
+ J as OverlayCard,
63
64
  t as Popover,
64
65
  l as PopoverContent,
65
66
  n as PopoverTrigger,
66
- x as Select,
67
- J as Spinner,
68
- K as TextInput,
69
- L as Toolbar,
70
- Q as ToolbarButton,
71
- U as ToolbarSeparator,
72
- F as ToolbarToggleGroup,
73
- V as ToolbarToggleItem,
74
- v as Tooltip,
75
- W as css,
76
- X as getCssText,
77
- Y as globalCss,
78
- Z as keyframes,
79
- _ as menuItemStyles,
80
- oo as styled
67
+ I as Select,
68
+ K as Spinner,
69
+ L as TextInput,
70
+ Q as Toolbar,
71
+ U as ToolbarButton,
72
+ F as ToolbarSeparator,
73
+ V as ToolbarToggleGroup,
74
+ W as ToolbarToggleItem,
75
+ x as Tooltip,
76
+ X as css,
77
+ Y as getCssText,
78
+ Z as globalCss,
79
+ _ as keyframes,
80
+ oo as menuItemStyles,
81
+ ao as styled
81
82
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arkitektbedriftene/fe-lib",
3
- "version": "0.4.9",
3
+ "version": "0.4.10",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  ".": {
@@ -71,15 +71,7 @@
71
71
  "vite-plugin-dts": "^2.1.0"
72
72
  },
73
73
  "dependencies": {
74
- "@radix-ui/react-dropdown-menu": "^2.0.6",
75
- "@radix-ui/react-toolbar": "^1.0.4",
76
74
  "@floating-ui/react": "^0.26.0",
77
- "@stitches/react": "^1.2.8",
78
- "oidc-client-ts": "^2.2.2",
79
- "react-icons": "^4.8.0",
80
- "react-select": "^5.8.0",
81
- "use-local-storage-state": "^18.2.1",
82
- "lexical": "~0.12.0",
83
75
  "@lexical/headless": "~0.12.0",
84
76
  "@lexical/html": "~0.12.0",
85
77
  "@lexical/link": "~0.12.0",
@@ -87,6 +79,15 @@
87
79
  "@lexical/react": "~0.12.0",
88
80
  "@lexical/rich-text": "~0.12.0",
89
81
  "@lexical/selection": "~0.12.0",
90
- "@lexical/table": "~0.12.0"
82
+ "@lexical/table": "~0.12.0",
83
+ "@radix-ui/react-dialog": "^1.0.5",
84
+ "@radix-ui/react-dropdown-menu": "^2.0.6",
85
+ "@radix-ui/react-toolbar": "^1.0.4",
86
+ "@stitches/react": "^1.2.8",
87
+ "lexical": "~0.12.0",
88
+ "oidc-client-ts": "^2.2.2",
89
+ "react-icons": "^4.8.0",
90
+ "react-select": "^5.8.0",
91
+ "use-local-storage-state": "^18.2.1"
91
92
  }
92
93
  }