@arkitektbedriftene/fe-lib 0.3.16 → 0.3.17

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.
@@ -0,0 +1,489 @@
1
+ /// <reference types="react" />
2
+ import * as T from "@radix-ui/react-toolbar";
3
+ export declare const Toolbar: import("@stitches/react/types/styled-component").StyledComponent<import("react").ForwardRefExoticComponent<T.ToolbarProps & import("react").RefAttributes<HTMLDivElement>>, {}, {
4
+ lg: "(min-width: 1200px)";
5
+ print: "print";
6
+ }, import("@stitches/react/types/css-util").CSS<{
7
+ lg: "(min-width: 1200px)";
8
+ print: "print";
9
+ }, {
10
+ colors: {
11
+ gray50: string;
12
+ gray100: string;
13
+ gray200: string;
14
+ gray300: string;
15
+ gray400: string;
16
+ gray500: string;
17
+ gray600: string;
18
+ gray700: string;
19
+ gray800: string;
20
+ gray900: string;
21
+ blue50: string;
22
+ blue100: string;
23
+ blue200: string;
24
+ blue300: string;
25
+ blue400: string;
26
+ blue500: string;
27
+ blue600: string;
28
+ blue700: string;
29
+ blue800: string;
30
+ blue900: string;
31
+ yellow50: string;
32
+ yellow100: string;
33
+ yellow200: string;
34
+ yellow300: string;
35
+ yellow400: string;
36
+ yellow500: string;
37
+ yellow600: string;
38
+ yellow700: string;
39
+ yellow800: string;
40
+ yellow900: string;
41
+ orange500: string;
42
+ red50: string;
43
+ red100: string;
44
+ red200: string;
45
+ red300: string;
46
+ red400: string;
47
+ red500: string;
48
+ red600: string;
49
+ red700: string;
50
+ red800: string;
51
+ red900: string;
52
+ green50: string;
53
+ green100: string;
54
+ green200: string;
55
+ green300: string;
56
+ green400: string;
57
+ green500: string;
58
+ green600: string;
59
+ green700: string;
60
+ green800: string;
61
+ green900: string;
62
+ primaryTextOnLightBg: string;
63
+ primaryBg: string;
64
+ primaryBgHover: string;
65
+ primaryTextOnWhite: string;
66
+ bodyGray: string;
67
+ hoverDarker: string;
68
+ borderDarker: string;
69
+ selectedDarker: string;
70
+ selectedOnBodyGray: string;
71
+ darkGrayBg: string;
72
+ border: string;
73
+ text: string;
74
+ secondaryText: string;
75
+ focusRing: string;
76
+ };
77
+ fontSizes: {
78
+ xs: string;
79
+ sm: string;
80
+ md: string;
81
+ lg: string;
82
+ xl: string;
83
+ "2xl": string;
84
+ "3xl": string;
85
+ };
86
+ fontWeights: {
87
+ normal: string;
88
+ medium: string;
89
+ bold: string;
90
+ };
91
+ space: {
92
+ 1: string;
93
+ 2: string;
94
+ 3: string;
95
+ 4: string;
96
+ 6: string;
97
+ 8: string;
98
+ };
99
+ shadows: {
100
+ xs: string;
101
+ sm: string;
102
+ md: string;
103
+ lg: string;
104
+ overlayCard: string;
105
+ };
106
+ radii: {
107
+ xs: string;
108
+ sm: string;
109
+ md: string;
110
+ mdmd: string;
111
+ full: string;
112
+ };
113
+ zIndices: {
114
+ toast: number;
115
+ overlayCard: number;
116
+ modal: number;
117
+ };
118
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>;
119
+ export declare const ToolbarToggleGroup: import("@stitches/react/types/styled-component").StyledComponent<import("react").ForwardRefExoticComponent<(T.ToolbarToggleGroupSingleProps | T.ToolbarToggleGroupMultipleProps) & import("react").RefAttributes<HTMLDivElement>>, {}, {
120
+ lg: "(min-width: 1200px)";
121
+ print: "print";
122
+ }, import("@stitches/react/types/css-util").CSS<{
123
+ lg: "(min-width: 1200px)";
124
+ print: "print";
125
+ }, {
126
+ colors: {
127
+ gray50: string;
128
+ gray100: string;
129
+ gray200: string;
130
+ gray300: string;
131
+ gray400: string;
132
+ gray500: string;
133
+ gray600: string;
134
+ gray700: string;
135
+ gray800: string;
136
+ gray900: string;
137
+ blue50: string;
138
+ blue100: string;
139
+ blue200: string;
140
+ blue300: string;
141
+ blue400: string;
142
+ blue500: string;
143
+ blue600: string;
144
+ blue700: string;
145
+ blue800: string;
146
+ blue900: string;
147
+ yellow50: string;
148
+ yellow100: string;
149
+ yellow200: string;
150
+ yellow300: string;
151
+ yellow400: string;
152
+ yellow500: string;
153
+ yellow600: string;
154
+ yellow700: string;
155
+ yellow800: string;
156
+ yellow900: string;
157
+ orange500: string;
158
+ red50: string;
159
+ red100: string;
160
+ red200: string;
161
+ red300: string;
162
+ red400: string;
163
+ red500: string;
164
+ red600: string;
165
+ red700: string;
166
+ red800: string;
167
+ red900: string;
168
+ green50: string;
169
+ green100: string;
170
+ green200: string;
171
+ green300: string;
172
+ green400: string;
173
+ green500: string;
174
+ green600: string;
175
+ green700: string;
176
+ green800: string;
177
+ green900: string;
178
+ primaryTextOnLightBg: string;
179
+ primaryBg: string;
180
+ primaryBgHover: string;
181
+ primaryTextOnWhite: string;
182
+ bodyGray: string;
183
+ hoverDarker: string;
184
+ borderDarker: string;
185
+ selectedDarker: string;
186
+ selectedOnBodyGray: string;
187
+ darkGrayBg: string;
188
+ border: string;
189
+ text: string;
190
+ secondaryText: string;
191
+ focusRing: string;
192
+ };
193
+ fontSizes: {
194
+ xs: string;
195
+ sm: string;
196
+ md: string;
197
+ lg: string;
198
+ xl: string;
199
+ "2xl": string;
200
+ "3xl": string;
201
+ };
202
+ fontWeights: {
203
+ normal: string;
204
+ medium: string;
205
+ bold: string;
206
+ };
207
+ space: {
208
+ 1: string;
209
+ 2: string;
210
+ 3: string;
211
+ 4: string;
212
+ 6: string;
213
+ 8: string;
214
+ };
215
+ shadows: {
216
+ xs: string;
217
+ sm: string;
218
+ md: string;
219
+ lg: string;
220
+ overlayCard: string;
221
+ };
222
+ radii: {
223
+ xs: string;
224
+ sm: string;
225
+ md: string;
226
+ mdmd: string;
227
+ full: string;
228
+ };
229
+ zIndices: {
230
+ toast: number;
231
+ overlayCard: number;
232
+ modal: number;
233
+ };
234
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>;
235
+ export declare const ToolbarSeparator: import("@stitches/react/types/styled-component").StyledComponent<import("react").ForwardRefExoticComponent<T.ToolbarSeparatorProps & import("react").RefAttributes<HTMLDivElement>>, {}, {
236
+ lg: "(min-width: 1200px)";
237
+ print: "print";
238
+ }, import("@stitches/react/types/css-util").CSS<{
239
+ lg: "(min-width: 1200px)";
240
+ print: "print";
241
+ }, {
242
+ colors: {
243
+ gray50: string;
244
+ gray100: string;
245
+ gray200: string;
246
+ gray300: string;
247
+ gray400: string;
248
+ gray500: string;
249
+ gray600: string;
250
+ gray700: string;
251
+ gray800: string;
252
+ gray900: string;
253
+ blue50: string;
254
+ blue100: string;
255
+ blue200: string;
256
+ blue300: string;
257
+ blue400: string;
258
+ blue500: string;
259
+ blue600: string;
260
+ blue700: string;
261
+ blue800: string;
262
+ blue900: string;
263
+ yellow50: string;
264
+ yellow100: string;
265
+ yellow200: string;
266
+ yellow300: string;
267
+ yellow400: string;
268
+ yellow500: string;
269
+ yellow600: string;
270
+ yellow700: string;
271
+ yellow800: string;
272
+ yellow900: string;
273
+ orange500: string;
274
+ red50: string;
275
+ red100: string;
276
+ red200: string;
277
+ red300: string;
278
+ red400: string;
279
+ red500: string;
280
+ red600: string;
281
+ red700: string;
282
+ red800: string;
283
+ red900: string;
284
+ green50: string;
285
+ green100: string;
286
+ green200: string;
287
+ green300: string;
288
+ green400: string;
289
+ green500: string;
290
+ green600: string;
291
+ green700: string;
292
+ green800: string;
293
+ green900: string;
294
+ primaryTextOnLightBg: string;
295
+ primaryBg: string;
296
+ primaryBgHover: string;
297
+ primaryTextOnWhite: string;
298
+ bodyGray: string;
299
+ hoverDarker: string;
300
+ borderDarker: string;
301
+ selectedDarker: string;
302
+ selectedOnBodyGray: string;
303
+ darkGrayBg: string;
304
+ border: string;
305
+ text: string;
306
+ secondaryText: string;
307
+ focusRing: string;
308
+ };
309
+ fontSizes: {
310
+ xs: string;
311
+ sm: string;
312
+ md: string;
313
+ lg: string;
314
+ xl: string;
315
+ "2xl": string;
316
+ "3xl": string;
317
+ };
318
+ fontWeights: {
319
+ normal: string;
320
+ medium: string;
321
+ bold: string;
322
+ };
323
+ space: {
324
+ 1: string;
325
+ 2: string;
326
+ 3: string;
327
+ 4: string;
328
+ 6: string;
329
+ 8: string;
330
+ };
331
+ shadows: {
332
+ xs: string;
333
+ sm: string;
334
+ md: string;
335
+ lg: string;
336
+ overlayCard: string;
337
+ };
338
+ radii: {
339
+ xs: string;
340
+ sm: string;
341
+ md: string;
342
+ mdmd: string;
343
+ full: string;
344
+ };
345
+ zIndices: {
346
+ toast: number;
347
+ overlayCard: number;
348
+ modal: number;
349
+ };
350
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}>>;
351
+ export declare const ButtonInToolbar: import("react").ForwardRefExoticComponent<Omit<Omit<Omit<Omit<import("react").DetailedHTMLProps<import("react").ButtonHTMLAttributes<HTMLButtonElement>, HTMLButtonElement>, "ref"> & {
352
+ ref?: ((instance: HTMLButtonElement | null) => void) | import("react").RefObject<HTMLButtonElement> | null | undefined;
353
+ }, "color" | "css" | "size" | "icon" | "variant"> & import("@stitches/react/types/styled-component").TransformProps<{
354
+ color?: "warning" | "danger" | "success" | "primary" | "secondary" | undefined;
355
+ size?: "md" | "lg" | undefined;
356
+ variant?: "outline" | "transparent" | "primary" | undefined;
357
+ icon?: boolean | "true" | undefined;
358
+ }, {
359
+ lg: "(min-width: 1200px)";
360
+ print: "print";
361
+ }> & {
362
+ css?: import("@stitches/react/types/css-util").CSS<{
363
+ lg: "(min-width: 1200px)";
364
+ print: "print";
365
+ }, {
366
+ colors: {
367
+ gray50: string;
368
+ gray100: string;
369
+ gray200: string;
370
+ gray300: string;
371
+ gray400: string;
372
+ gray500: string;
373
+ gray600: string;
374
+ gray700: string;
375
+ gray800: string;
376
+ gray900: string;
377
+ blue50: string;
378
+ blue100: string;
379
+ blue200: string;
380
+ blue300: string;
381
+ blue400: string;
382
+ blue500: string;
383
+ blue600: string;
384
+ blue700: string;
385
+ blue800: string;
386
+ blue900: string;
387
+ yellow50: string;
388
+ yellow100: string;
389
+ yellow200: string;
390
+ yellow300: string;
391
+ yellow400: string;
392
+ yellow500: string;
393
+ yellow600: string;
394
+ yellow700: string;
395
+ yellow800: string;
396
+ yellow900: string;
397
+ orange500: string;
398
+ red50: string;
399
+ red100: string;
400
+ red200: string;
401
+ red300: string;
402
+ red400: string;
403
+ red500: string;
404
+ red600: string;
405
+ red700: string;
406
+ red800: string;
407
+ red900: string;
408
+ green50: string;
409
+ green100: string;
410
+ green200: string;
411
+ green300: string;
412
+ green400: string;
413
+ green500: string;
414
+ green600: string;
415
+ green700: string;
416
+ green800: string;
417
+ green900: string;
418
+ primaryTextOnLightBg: string;
419
+ primaryBg: string;
420
+ primaryBgHover: string;
421
+ primaryTextOnWhite: string;
422
+ bodyGray: string;
423
+ hoverDarker: string;
424
+ borderDarker: string;
425
+ selectedDarker: string;
426
+ selectedOnBodyGray: string;
427
+ darkGrayBg: string;
428
+ border: string;
429
+ text: string;
430
+ secondaryText: string;
431
+ focusRing: string;
432
+ };
433
+ fontSizes: {
434
+ xs: string;
435
+ sm: string;
436
+ md: string;
437
+ lg: string;
438
+ xl: string;
439
+ "2xl": string;
440
+ "3xl": string;
441
+ };
442
+ fontWeights: {
443
+ normal: string;
444
+ medium: string;
445
+ bold: string;
446
+ };
447
+ space: {
448
+ 1: string;
449
+ 2: string;
450
+ 3: string;
451
+ 4: string;
452
+ 6: string;
453
+ 8: string;
454
+ };
455
+ shadows: {
456
+ xs: string;
457
+ sm: string;
458
+ md: string;
459
+ lg: string;
460
+ overlayCard: string;
461
+ };
462
+ radii: {
463
+ xs: string;
464
+ sm: string;
465
+ md: string;
466
+ mdmd: string;
467
+ full: string;
468
+ };
469
+ zIndices: {
470
+ toast: number;
471
+ overlayCard: number;
472
+ modal: number;
473
+ };
474
+ }, import("@stitches/react/types/config").DefaultThemeMap, {}> | undefined;
475
+ } & {
476
+ as?: import("react").ElementType<any> | undefined;
477
+ isLoading?: boolean | undefined;
478
+ }, "ref"> & import("react").RefAttributes<HTMLButtonElement>, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
479
+ type ToolbarButtonProps = {
480
+ children: React.ReactNode;
481
+ dropdown?: boolean;
482
+ } & React.ComponentProps<typeof ButtonInToolbar>;
483
+ export declare const ToolbarButton: import("react").ForwardRefExoticComponent<Omit<ToolbarButtonProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
484
+ type ToolbarToogleItemProps = {
485
+ children: React.ReactNode;
486
+ value: string;
487
+ } & React.ComponentProps<typeof ButtonInToolbar>;
488
+ export declare const ToolbarToggleItem: import("react").ForwardRefExoticComponent<Omit<ToolbarToogleItemProps, "ref"> & import("react").RefAttributes<HTMLButtonElement>>;
489
+ export {};
package/dist/ui/ui.d.ts CHANGED
@@ -7,5 +7,6 @@ export * from './components/Popover';
7
7
  export * from './components/Box';
8
8
  export * from './components/Tooltip';
9
9
  export * from './components/Badge';
10
+ export * from './components/Toolbar';
10
11
  export * from './components/Menu/Menu';
11
12
  export * from './components/Menu/DropdownMenu';
package/dist/ui.es.js CHANGED
@@ -1,54 +1,62 @@
1
- import { P as t, a as n, b as p } from "./DropdownMenu-8d580c1a.js";
2
- import { A as v, e as C, B as M, d as h, D as j, j as y, i as D, h as S, f as b, M as w, O as I, S as O, c as P, g as k, k as B, m as A, s as $ } from "./DropdownMenu-8d580c1a.js";
3
- import { j as o } from "./jsx-runtime-d0aa4c5b.js";
1
+ import { P as t, a as n, b as p } from "./DropdownMenu-c57acb78.js";
2
+ import { A as C, e as I, B as M, d as S, i as h, D as y, q as B, p as D, o as w, n as O, M as P, O as k, S as j, T as A, j as $, h as q, f as z, l as G, c as E, g as F, k as H, m as J, s as K } from "./DropdownMenu-c57acb78.js";
3
+ import { jsxs as l, jsx as o } from "react/jsx-runtime";
4
4
  import { useState as m } from "react";
5
5
  import "react-dom";
6
- import "./index.esm-ddc5d570.js";
7
- const u = ({ children: e, content: s }) => {
8
- const [r, a] = m(!1);
9
- return /* @__PURE__ */ o.jsxs(
6
+ import "@radix-ui/react-toolbar";
7
+ import "./index.esm-d078f232.js";
8
+ import "@radix-ui/react-dropdown-menu";
9
+ const T = ({ children: r, content: a }) => {
10
+ const [e, s] = m(!1);
11
+ return /* @__PURE__ */ l(
10
12
  t,
11
13
  {
12
- open: r,
13
- onOpenChange: a,
14
+ open: e,
15
+ onOpenChange: s,
14
16
  trigger: "hover",
15
17
  placement: "top",
16
18
  offset: { mainAxis: 8 },
17
19
  role: "tooltip",
18
20
  children: [
19
- /* @__PURE__ */ o.jsx(n, { children: e }),
20
- /* @__PURE__ */ o.jsx(p, { overlayCardProps: {
21
+ /* @__PURE__ */ o(n, { children: r }),
22
+ /* @__PURE__ */ o(p, { overlayCardProps: {
21
23
  css: {
22
24
  background: "rgba(0,0,0, 0.9)",
23
25
  color: "#fff",
24
26
  fontSize: "$sm",
25
27
  padding: "$1 $2"
26
28
  }
27
- }, children: s })
29
+ }, children: a })
28
30
  ]
29
31
  }
30
32
  );
31
33
  };
32
34
  export {
33
- v as Alert,
34
- C as Badge,
35
+ C as Alert,
36
+ I as Badge,
35
37
  M as Box,
36
- h as Button,
37
- j as DropdownMenu,
38
- y as DropdownMenuCheckboxItem,
38
+ S as Button,
39
+ h as ButtonInToolbar,
40
+ y as DropdownMenu,
41
+ B as DropdownMenuCheckboxItem,
39
42
  D as DropdownMenuIconItem,
40
- S as DropdownMenuItem,
41
- b as DropdownMenuSeparator,
42
- w as MenuOverlayCard,
43
- I as OverlayCard,
43
+ w as DropdownMenuItem,
44
+ O as DropdownMenuSeparator,
45
+ P as MenuOverlayCard,
46
+ k as OverlayCard,
44
47
  t as Popover,
45
48
  p as PopoverContent,
46
49
  n as PopoverTrigger,
47
- O as Spinner,
48
- u as Tooltip,
49
- P as css,
50
- k as globalCss,
51
- B as keyframes,
52
- A as menuItemStyles,
53
- $ as styled
50
+ j as Spinner,
51
+ A as Toolbar,
52
+ $ as ToolbarButton,
53
+ q as ToolbarSeparator,
54
+ z as ToolbarToggleGroup,
55
+ G as ToolbarToggleItem,
56
+ T as Tooltip,
57
+ E as css,
58
+ F as globalCss,
59
+ H as keyframes,
60
+ J as menuItemStyles,
61
+ K as styled
54
62
  };
package/package.json CHANGED
@@ -1,9 +1,7 @@
1
1
  {
2
2
  "name": "@arkitektbedriftene/fe-lib",
3
- "version": "0.3.16",
3
+ "version": "0.3.17",
4
4
  "type": "module",
5
- "main": "./dist/index.umd.cjs",
6
- "module": "./dist/index.es.js",
7
5
  "exports": {
8
6
  ".": {
9
7
  "import": "./dist/index.es.js",
@@ -50,7 +48,7 @@
50
48
  "registry": "https://registry.npmjs.org/"
51
49
  },
52
50
  "scripts": {
53
- "dev": "vite",
51
+ "dev": "vite build --watch",
54
52
  "build": "tsc && vite build",
55
53
  "docs": "cd ./src/docs && next",
56
54
  "test": "tsc"
@@ -84,6 +82,7 @@
84
82
  },
85
83
  "dependencies": {
86
84
  "@radix-ui/react-dropdown-menu": "^2.0.6",
85
+ "@radix-ui/react-toolbar": "^1.0.4",
87
86
  "@stitches/react": "^1.2.8",
88
87
  "oidc-client-ts": "^2.2.2",
89
88
  "react-icons": "^4.8.0",