@obosbbl/grunnmuren-react 3.7.0 → 3.8.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.
- package/README.md +17 -5
- package/dist/__stories__/form-validation.stories.cjs +2 -0
- package/dist/__stories__/form-validation.stories.d.cts +5 -5
- package/dist/__stories__/form-validation.stories.d.ts +5 -5
- package/dist/__stories__/form-validation.stories.js +2 -0
- package/dist/__stories__/home.stories.d.cts +2 -2
- package/dist/__stories__/home.stories.d.ts +2 -2
- package/dist/__stories__/icons.stories.d.cts +2 -2
- package/dist/__stories__/icons.stories.d.ts +2 -2
- package/dist/__stories__/layout.stories.cjs +9 -3
- package/dist/__stories__/layout.stories.d.cts +4 -4
- package/dist/__stories__/layout.stories.d.ts +4 -4
- package/dist/__stories__/layout.stories.js +9 -3
- package/dist/__stories__/typography.stories.d.cts +9 -9
- package/dist/__stories__/typography.stories.d.ts +9 -9
- package/dist/index.d.mts +120 -72
- package/dist/index.mjs +228 -12
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -1,19 +1,33 @@
|
|
|
1
1
|
# @obosbbl/grunnmuren-react
|
|
2
2
|
|
|
3
|
-
[](https://www.npmjs.com/package/@obosbbl/grunnmuren-react)
|
|
4
4
|
|
|
5
5
|
Grunnmuren React components.
|
|
6
6
|
|
|
7
7
|
## Install
|
|
8
8
|
|
|
9
|
+
`@obosbbl/grunnmuren-react` declares `@obosbbl/grunnmuren-tailwind` as a peer dependency — the components rely on Tailwind tokens and utilities defined in that package. Install both:
|
|
10
|
+
|
|
9
11
|
```sh
|
|
10
12
|
# npm
|
|
11
|
-
npm install @obosbbl/grunnmuren-react@
|
|
13
|
+
npm install @obosbbl/grunnmuren-react @obosbbl/grunnmuren-tailwind
|
|
12
14
|
|
|
13
15
|
# pnpm
|
|
14
|
-
pnpm add @obosbbl/grunnmuren-react@
|
|
16
|
+
pnpm add @obosbbl/grunnmuren-react @obosbbl/grunnmuren-tailwind
|
|
15
17
|
```
|
|
16
18
|
|
|
19
|
+
Then import the Tailwind preset in your global stylesheet. The preset already does `@import 'tailwindcss';` internally, so you should **not** import Tailwind separately:
|
|
20
|
+
|
|
21
|
+
```css
|
|
22
|
+
/* globals.css */
|
|
23
|
+
@import '@obosbbl/grunnmuren-tailwind';
|
|
24
|
+
|
|
25
|
+
/* Register the React package as a Tailwind source so the utilities used by the components are emitted. */
|
|
26
|
+
@source "../../node_modules/@obosbbl/grunnmuren-react/dist";
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
See [`@obosbbl/grunnmuren-tailwind`](../tailwind/) for the full preset documentation.
|
|
30
|
+
|
|
17
31
|
## Setup
|
|
18
32
|
|
|
19
33
|
### Internationalization
|
|
@@ -200,8 +214,6 @@ The plugin works with several different bundlers. See [React Aria's bundle size
|
|
|
200
214
|
|
|
201
215
|
## Usage
|
|
202
216
|
|
|
203
|
-
Before you start using the components you need to configure the [Tailwind preset](../tailwind/). Remember to add this package to the content scan.
|
|
204
|
-
|
|
205
217
|
```js
|
|
206
218
|
import { Button } from '@obosbbl/grunnmuren-react';
|
|
207
219
|
|
|
@@ -215,11 +215,13 @@ function Button({ ref = null, ...props }) {
|
|
|
215
215
|
return isLinkProps(restProps) ? /*#__PURE__*/ jsxRuntime.jsx(Link.Link, {
|
|
216
216
|
...restProps,
|
|
217
217
|
className: className,
|
|
218
|
+
"data-slot": "button",
|
|
218
219
|
ref: ref,
|
|
219
220
|
children: children
|
|
220
221
|
}) : /*#__PURE__*/ jsxRuntime.jsx(Button$1.Button, {
|
|
221
222
|
...restProps,
|
|
222
223
|
className: className,
|
|
224
|
+
"data-slot": "button",
|
|
223
225
|
isPending: isPending,
|
|
224
226
|
ref: ref,
|
|
225
227
|
children: children
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const NativeValidation: () =>
|
|
7
|
-
declare const RealtimeValidation: () =>
|
|
8
|
-
declare const ServerSideValidation: () =>
|
|
9
|
-
declare const ControlledValidation: () =>
|
|
6
|
+
declare const NativeValidation: () => react.JSX.Element;
|
|
7
|
+
declare const RealtimeValidation: () => react.JSX.Element;
|
|
8
|
+
declare const ServerSideValidation: () => react.JSX.Element;
|
|
9
|
+
declare const ControlledValidation: () => react.JSX.Element;
|
|
10
10
|
|
|
11
11
|
export { ControlledValidation, NativeValidation, RealtimeValidation, ServerSideValidation, meta as default };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const NativeValidation: () =>
|
|
7
|
-
declare const RealtimeValidation: () =>
|
|
8
|
-
declare const ServerSideValidation: () =>
|
|
9
|
-
declare const ControlledValidation: () =>
|
|
6
|
+
declare const NativeValidation: () => react.JSX.Element;
|
|
7
|
+
declare const RealtimeValidation: () => react.JSX.Element;
|
|
8
|
+
declare const ServerSideValidation: () => react.JSX.Element;
|
|
9
|
+
declare const ControlledValidation: () => react.JSX.Element;
|
|
10
10
|
|
|
11
11
|
export { ControlledValidation, NativeValidation, RealtimeValidation, ServerSideValidation, meta as default };
|
|
@@ -213,11 +213,13 @@ function Button({ ref = null, ...props }) {
|
|
|
213
213
|
return isLinkProps(restProps) ? /*#__PURE__*/ jsx(Link, {
|
|
214
214
|
...restProps,
|
|
215
215
|
className: className,
|
|
216
|
+
"data-slot": "button",
|
|
216
217
|
ref: ref,
|
|
217
218
|
children: children
|
|
218
219
|
}) : /*#__PURE__*/ jsx(Button$1, {
|
|
219
220
|
...restProps,
|
|
220
221
|
className: className,
|
|
222
|
+
"data-slot": "button",
|
|
221
223
|
isPending: isPending,
|
|
222
224
|
ref: ref,
|
|
223
225
|
children: children
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
6
|
declare const Page: {
|
|
7
|
-
render: () =>
|
|
7
|
+
render: () => react.JSX.Element;
|
|
8
8
|
};
|
|
9
9
|
|
|
10
10
|
export { Page, meta as default };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
6
|
declare const Page: {
|
|
7
|
-
render: () =>
|
|
7
|
+
render: () => react.JSX.Element;
|
|
8
8
|
};
|
|
9
9
|
|
|
10
10
|
export { Page, meta as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const Icons: () =>
|
|
6
|
+
declare const Icons: () => react.JSX.Element;
|
|
7
7
|
|
|
8
8
|
export { Icons, meta as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const Icons: () =>
|
|
6
|
+
declare const Icons: () => react.JSX.Element;
|
|
7
7
|
|
|
8
8
|
export { Icons, meta as default };
|
|
@@ -307,7 +307,11 @@ const oneColumnLayout = [
|
|
|
307
307
|
// Aligns <Content> and any element beside it (e.g. <Media>, <Badge>, <CTA> etc.) to the bottom of the <Content> container
|
|
308
308
|
'lg:items-end'
|
|
309
309
|
];
|
|
310
|
-
|
|
310
|
+
// Use `not-has-[video]` (tag selector) so that aspect-ratio rules also skip for video players
|
|
311
|
+
// that don't expose `data-slot="video"` (e.g., MuxPlayer).
|
|
312
|
+
// Aspect-ratio is applied to the `<Media>` element itself (not the img inside) so that the
|
|
313
|
+
// Media box fills the grid column and consumers don't need `!important` overrides when nesting.
|
|
314
|
+
const nonFullBleedAspectRatiosForSmallScreens = '*:data-[slot=media]:not-has-[video]:aspect-[1/1] sm:*:data-[slot=media]:not-has-[video]:aspect-4/3 md:*:data-[slot=media]:not-has-[video]:aspect-3/2';
|
|
311
315
|
const variants = cva.cva({
|
|
312
316
|
base: [
|
|
313
317
|
'container px-0',
|
|
@@ -332,7 +336,7 @@ const variants = cva.cva({
|
|
|
332
336
|
standard: [
|
|
333
337
|
oneColumnLayout,
|
|
334
338
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
335
|
-
'lg:*:data-[slot=media]:not-has-
|
|
339
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-2/1'
|
|
336
340
|
],
|
|
337
341
|
'full-bleed': [
|
|
338
342
|
oneColumnLayout,
|
|
@@ -361,7 +365,7 @@ const variants = cva.cva({
|
|
|
361
365
|
'lg:*:data-[slot=content]:gap-y-7',
|
|
362
366
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
363
367
|
// Set media aspect ratio to 1:1 (square)
|
|
364
|
-
'lg:*:data-[slot=media]:not-has-
|
|
368
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-square'
|
|
365
369
|
]
|
|
366
370
|
}
|
|
367
371
|
},
|
|
@@ -373,6 +377,8 @@ const variants = cva.cva({
|
|
|
373
377
|
],
|
|
374
378
|
className: [
|
|
375
379
|
'*:data-[slot=media]:*:rounded-3xl',
|
|
380
|
+
// Make non-video media (image/picture) fill the aspect-ratio-constrained Media box
|
|
381
|
+
'*:data-[slot=media]:not-has-[video]:*:size-full',
|
|
376
382
|
'*:data-[slot=carousel]:relative **:data-[slot=carousel-container]:rounded-3xl **:data-[slot=carousel-controls]:absolute **:data-[slot=carousel-controls]:right-4 **:data-[slot=carousel-controls]:bottom-4'
|
|
377
383
|
]
|
|
378
384
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const GridContainer: () =>
|
|
7
|
-
declare const GridContainerWithSubGrids: () =>
|
|
8
|
-
declare const OverridedColSpans: () =>
|
|
6
|
+
declare const GridContainer: () => react.JSX.Element;
|
|
7
|
+
declare const GridContainerWithSubGrids: () => react.JSX.Element;
|
|
8
|
+
declare const OverridedColSpans: () => react.JSX.Element;
|
|
9
9
|
|
|
10
10
|
export { GridContainer, GridContainerWithSubGrids, OverridedColSpans, meta as default };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
4
|
declare const meta: Meta;
|
|
5
5
|
|
|
6
|
-
declare const GridContainer: () =>
|
|
7
|
-
declare const GridContainerWithSubGrids: () =>
|
|
8
|
-
declare const OverridedColSpans: () =>
|
|
6
|
+
declare const GridContainer: () => react.JSX.Element;
|
|
7
|
+
declare const GridContainerWithSubGrids: () => react.JSX.Element;
|
|
8
|
+
declare const OverridedColSpans: () => react.JSX.Element;
|
|
9
9
|
|
|
10
10
|
export { GridContainer, GridContainerWithSubGrids, OverridedColSpans, meta as default };
|
|
@@ -305,7 +305,11 @@ const oneColumnLayout = [
|
|
|
305
305
|
// Aligns <Content> and any element beside it (e.g. <Media>, <Badge>, <CTA> etc.) to the bottom of the <Content> container
|
|
306
306
|
'lg:items-end'
|
|
307
307
|
];
|
|
308
|
-
|
|
308
|
+
// Use `not-has-[video]` (tag selector) so that aspect-ratio rules also skip for video players
|
|
309
|
+
// that don't expose `data-slot="video"` (e.g., MuxPlayer).
|
|
310
|
+
// Aspect-ratio is applied to the `<Media>` element itself (not the img inside) so that the
|
|
311
|
+
// Media box fills the grid column and consumers don't need `!important` overrides when nesting.
|
|
312
|
+
const nonFullBleedAspectRatiosForSmallScreens = '*:data-[slot=media]:not-has-[video]:aspect-[1/1] sm:*:data-[slot=media]:not-has-[video]:aspect-4/3 md:*:data-[slot=media]:not-has-[video]:aspect-3/2';
|
|
309
313
|
const variants = cva({
|
|
310
314
|
base: [
|
|
311
315
|
'container px-0',
|
|
@@ -330,7 +334,7 @@ const variants = cva({
|
|
|
330
334
|
standard: [
|
|
331
335
|
oneColumnLayout,
|
|
332
336
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
333
|
-
'lg:*:data-[slot=media]:not-has-
|
|
337
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-2/1'
|
|
334
338
|
],
|
|
335
339
|
'full-bleed': [
|
|
336
340
|
oneColumnLayout,
|
|
@@ -359,7 +363,7 @@ const variants = cva({
|
|
|
359
363
|
'lg:*:data-[slot=content]:gap-y-7',
|
|
360
364
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
361
365
|
// Set media aspect ratio to 1:1 (square)
|
|
362
|
-
'lg:*:data-[slot=media]:not-has-
|
|
366
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-square'
|
|
363
367
|
]
|
|
364
368
|
}
|
|
365
369
|
},
|
|
@@ -371,6 +375,8 @@ const variants = cva({
|
|
|
371
375
|
],
|
|
372
376
|
className: [
|
|
373
377
|
'*:data-[slot=media]:*:rounded-3xl',
|
|
378
|
+
// Make non-video media (image/picture) fill the aspect-ratio-constrained Media box
|
|
379
|
+
'*:data-[slot=media]:not-has-[video]:*:size-full',
|
|
374
380
|
'*:data-[slot=carousel]:relative **:data-[slot=carousel-container]:rounded-3xl **:data-[slot=carousel-controls]:absolute **:data-[slot=carousel-controls]:right-4 **:data-[slot=carousel-controls]:bottom-4'
|
|
375
381
|
]
|
|
376
382
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
|
-
declare const Default: () =>
|
|
5
|
-
declare const Headings: () =>
|
|
6
|
-
declare const Lead: () =>
|
|
7
|
-
declare const Body: () =>
|
|
8
|
-
declare const Blockquote: () =>
|
|
9
|
-
declare const Description: () =>
|
|
10
|
-
declare const Prose: () =>
|
|
11
|
-
declare const ProseWhite: () =>
|
|
4
|
+
declare const Default: () => react.JSX.Element;
|
|
5
|
+
declare const Headings: () => react.JSX.Element;
|
|
6
|
+
declare const Lead: () => react.JSX.Element;
|
|
7
|
+
declare const Body: () => react.JSX.Element;
|
|
8
|
+
declare const Blockquote: () => react.JSX.Element;
|
|
9
|
+
declare const Description: () => react.JSX.Element;
|
|
10
|
+
declare const Prose: () => react.JSX.Element;
|
|
11
|
+
declare const ProseWhite: () => react.JSX.Element;
|
|
12
12
|
declare const meta: Meta;
|
|
13
13
|
|
|
14
14
|
export { Blockquote, Body, Default, Description, Headings, Lead, Prose, ProseWhite, meta as default };
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import * as
|
|
1
|
+
import * as react from 'react';
|
|
2
2
|
import { Meta } from '@storybook/react-vite';
|
|
3
3
|
|
|
4
|
-
declare const Default: () =>
|
|
5
|
-
declare const Headings: () =>
|
|
6
|
-
declare const Lead: () =>
|
|
7
|
-
declare const Body: () =>
|
|
8
|
-
declare const Blockquote: () =>
|
|
9
|
-
declare const Description: () =>
|
|
10
|
-
declare const Prose: () =>
|
|
11
|
-
declare const ProseWhite: () =>
|
|
4
|
+
declare const Default: () => react.JSX.Element;
|
|
5
|
+
declare const Headings: () => react.JSX.Element;
|
|
6
|
+
declare const Lead: () => react.JSX.Element;
|
|
7
|
+
declare const Body: () => react.JSX.Element;
|
|
8
|
+
declare const Blockquote: () => react.JSX.Element;
|
|
9
|
+
declare const Description: () => react.JSX.Element;
|
|
10
|
+
declare const Prose: () => react.JSX.Element;
|
|
11
|
+
declare const ProseWhite: () => react.JSX.Element;
|
|
12
12
|
declare const meta: Meta;
|
|
13
13
|
|
|
14
14
|
export { Blockquote, Body, Default, Description, Headings, Lead, Prose, ProseWhite, meta as default };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { RouterProvider } from 'react-aria-components';
|
|
2
2
|
export { Form, Group } from 'react-aria-components';
|
|
3
|
-
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
4
3
|
import * as react from 'react';
|
|
5
4
|
import { RefAttributes, HTMLAttributes, HTMLProps, ComponentProps, Ref, ReactNode, RefObject, Dispatch, SetStateAction, JSX } from 'react';
|
|
6
5
|
import * as cva from 'cva';
|
|
@@ -31,6 +30,7 @@ import { ColumnResizerProps, TableProps as TableProps$1, TableBodyProps as Table
|
|
|
31
30
|
import { TabProps as TabProps$1, TabListProps as TabListProps$1, TabPanelProps as TabPanelProps$1, TabsProps as TabsProps$1 } from 'react-aria-components/Tabs';
|
|
32
31
|
import { TagGroupProps as TagGroupProps$1, TagListProps as TagListProps$1, TagProps as TagProps$1 } from 'react-aria-components/TagGroup';
|
|
33
32
|
import { TextFieldProps as TextFieldProps$1 } from 'react-aria-components/TextField';
|
|
33
|
+
import { PopoverProps } from 'react-aria-components/Popover';
|
|
34
34
|
import { HeaderProps } from 'react-aria-components/Header';
|
|
35
35
|
import { ListBoxItemProps, ListBoxSectionProps } from 'react-aria-components/ListBox';
|
|
36
36
|
export { ListBoxItemProps as ComboboxItemProps, ListBoxItemProps as SelectItemProps } from 'react-aria-components/ListBox';
|
|
@@ -48,17 +48,17 @@ declare const disclosureButtonVariants: (props?: ({
|
|
|
48
48
|
type DisclosureButtonProps = Omit<ButtonProps$1, 'children'> & VariantProps<typeof disclosureButtonVariants> & {
|
|
49
49
|
children?: React.ReactNode;
|
|
50
50
|
} & RefAttributes<HTMLButtonElement>;
|
|
51
|
-
declare const DisclosureButton: ({ className, withChevron, isIconOnly, children, ref: _ref, ...restProps }: DisclosureButtonProps) =>
|
|
51
|
+
declare const DisclosureButton: ({ className, withChevron, isIconOnly, children, ref: _ref, ...restProps }: DisclosureButtonProps) => react.JSX.Element;
|
|
52
52
|
type DisclosureProps = DisclosureProps$1 & RefAttributes<HTMLDivElement> & {
|
|
53
53
|
className?: string;
|
|
54
54
|
};
|
|
55
55
|
declare const DisclosureStateContext: react.Context<DisclosureState | null>;
|
|
56
|
-
declare const Disclosure: ({ ref: _ref, ..._props }: DisclosureProps) =>
|
|
56
|
+
declare const Disclosure: ({ ref: _ref, ..._props }: DisclosureProps) => react.JSX.Element;
|
|
57
57
|
type DisclosurePanelProps = Omit<HTMLAttributes<HTMLDivElement>, 'role'> & {
|
|
58
58
|
children: React.ReactNode;
|
|
59
59
|
role?: 'group' | 'region' | 'none';
|
|
60
60
|
} & RefAttributes<HTMLDivElement>;
|
|
61
|
-
declare const DisclosurePanel: ({ ref, children, ...props }: DisclosurePanelProps) =>
|
|
61
|
+
declare const DisclosurePanel: ({ ref, children, ...props }: DisclosurePanelProps) => react.JSX.Element;
|
|
62
62
|
|
|
63
63
|
type AccordionProps = HTMLProps<HTMLDivElement> & {
|
|
64
64
|
children: React.ReactNode;
|
|
@@ -72,8 +72,8 @@ type AccordionItemProps = DisclosureProps & {
|
|
|
72
72
|
/** @deprecated use onExpandedChange instead */
|
|
73
73
|
onOpenChange?: (isOpen: boolean) => void;
|
|
74
74
|
};
|
|
75
|
-
declare function Accordion(props: AccordionProps):
|
|
76
|
-
declare function AccordionItem(props: AccordionItemProps):
|
|
75
|
+
declare function Accordion(props: AccordionProps): react.JSX.Element;
|
|
76
|
+
declare function AccordionItem(props: AccordionItemProps): react.JSX.Element;
|
|
77
77
|
|
|
78
78
|
declare const alertVariants: (props?: ({
|
|
79
79
|
variant?: "info" | "success" | "warning" | "danger" | undefined;
|
|
@@ -116,10 +116,10 @@ type Props = VariantProps<typeof alertVariants> & {
|
|
|
116
116
|
*/
|
|
117
117
|
onDismiss?: () => void;
|
|
118
118
|
};
|
|
119
|
-
declare const Alertbox: ({ children, role, className, icon, variant, isDismissable, isDismissed, onDismiss, isExpandable, }: Props) =>
|
|
119
|
+
declare const Alertbox: ({ children, role, className, icon, variant, isDismissable, isDismissed, onDismiss, isExpandable, }: Props) => react.JSX.Element | undefined;
|
|
120
120
|
|
|
121
121
|
type AvatarProps = ComponentProps<'img'>;
|
|
122
|
-
declare const Avatar: ({ src, alt, className, onError, loading, ...rest }: AvatarProps) =>
|
|
122
|
+
declare const Avatar: ({ src, alt, className, onError, loading, ...rest }: AvatarProps) => react.JSX.Element;
|
|
123
123
|
|
|
124
124
|
type ButtonOrLinkProps$1 = {
|
|
125
125
|
children?: React.ReactNode;
|
|
@@ -135,7 +135,7 @@ type ButtonOrLinkProps$1 = {
|
|
|
135
135
|
ref?: Ref<HTMLAnchorElement | HTMLButtonElement>;
|
|
136
136
|
};
|
|
137
137
|
type BacklinkProps = (ButtonProps$1 | LinkProps$1) & ButtonOrLinkProps$1;
|
|
138
|
-
declare function Backlink(props: BacklinkProps):
|
|
138
|
+
declare function Backlink(props: BacklinkProps): react.JSX.Element;
|
|
139
139
|
|
|
140
140
|
type BadgeProps = VariantProps<typeof badgeVariants> & {
|
|
141
141
|
children?: React.ReactNode;
|
|
@@ -154,7 +154,7 @@ declare const badgeVariants: (props?: ({
|
|
|
154
154
|
class?: never;
|
|
155
155
|
className?: cva.ClassValue;
|
|
156
156
|
})) | undefined) => string;
|
|
157
|
-
declare function Badge(props: BadgeProps):
|
|
157
|
+
declare function Badge(props: BadgeProps): react.JSX.Element;
|
|
158
158
|
|
|
159
159
|
declare const linkVariants: (props?: (((VariantProps<(props?: ({
|
|
160
160
|
animateIcon?: "right" | "left" | "down" | "up" | "up-right" | undefined;
|
|
@@ -180,7 +180,7 @@ declare const linkVariants: (props?: (((VariantProps<(props?: ({
|
|
|
180
180
|
type LinkProps = VariantProps<typeof linkVariants> & LinkProps$1 & React.RefAttributes<HTMLAnchorElement> & {
|
|
181
181
|
children?: React.ReactNode;
|
|
182
182
|
};
|
|
183
|
-
declare const Link: ({ animateIcon, children, className, ...props }: LinkProps) =>
|
|
183
|
+
declare const Link: ({ animateIcon, children, className, ...props }: LinkProps) => react.JSX.Element;
|
|
184
184
|
|
|
185
185
|
type BreadcrumbProps = {
|
|
186
186
|
/** Additional CSS className for the element. */
|
|
@@ -193,7 +193,7 @@ type BreadcrumbProps = {
|
|
|
193
193
|
/** Ref to the element. */
|
|
194
194
|
ref?: Ref<HTMLLIElement>;
|
|
195
195
|
} & Omit<BreadcrumbProps$1, 'className' | 'style'>;
|
|
196
|
-
declare function Breadcrumb(props: BreadcrumbProps):
|
|
196
|
+
declare function Breadcrumb(props: BreadcrumbProps): react.JSX.Element;
|
|
197
197
|
|
|
198
198
|
type BreadcrumbsProps = {
|
|
199
199
|
/** Additional CSS className for the element. */
|
|
@@ -203,7 +203,7 @@ type BreadcrumbsProps = {
|
|
|
203
203
|
/** Ref to the element. */
|
|
204
204
|
ref?: Ref<HTMLOListElement>;
|
|
205
205
|
} & Omit<BreadcrumbsProps$1<BreadcrumbProps>, 'className' | 'style'>;
|
|
206
|
-
declare function Breadcrumbs(props: BreadcrumbsProps):
|
|
206
|
+
declare function Breadcrumbs(props: BreadcrumbsProps): react.JSX.Element;
|
|
207
207
|
|
|
208
208
|
/**
|
|
209
209
|
* Figma: https://www.figma.com/file/9OvSg0ZXI5E1eQYi7AWiWn/Grunnmuren-2.0-%E2%94%82-Designsystem?node-id=30%3A2574&mode=dev
|
|
@@ -244,7 +244,7 @@ type ButtonOrLinkProps = VariantProps<typeof buttonVariants> & {
|
|
|
244
244
|
};
|
|
245
245
|
type ButtonProps = (ButtonProps$1 | LinkProps$1) & ButtonOrLinkProps;
|
|
246
246
|
declare const ButtonContext: react.Context<ContextValue<ButtonProps, HTMLButtonElement | HTMLAnchorElement>>;
|
|
247
|
-
declare function Button({ ref, ...props }: ButtonProps):
|
|
247
|
+
declare function Button({ ref, ...props }: ButtonProps): react.JSX.Element;
|
|
248
248
|
|
|
249
249
|
type CardProps = VariantProps<typeof cardVariants> & HTMLAttributes<HTMLDivElement> & {
|
|
250
250
|
children?: React.ReactNode;
|
|
@@ -259,7 +259,7 @@ declare const cardVariants: (props?: ({
|
|
|
259
259
|
class?: never;
|
|
260
260
|
className?: cva.ClassValue;
|
|
261
261
|
})) | undefined) => string;
|
|
262
|
-
declare const Card: ({ children, className, variant, layout, ...restProps }: CardProps) =>
|
|
262
|
+
declare const Card: ({ children, className, variant, layout, ...restProps }: CardProps) => react.JSX.Element;
|
|
263
263
|
type CardLinkWrapperProps = {
|
|
264
264
|
children?: React.ReactNode;
|
|
265
265
|
className?: string;
|
|
@@ -271,7 +271,7 @@ type CardLinkProps = (Omit<LinkProps$1, 'href'> & Required<Pick<LinkProps$1, 'hr
|
|
|
271
271
|
* A component that creates a clickable area on a card.
|
|
272
272
|
* It can be used either as a wrapper around a link or as a standalone link.
|
|
273
273
|
*/
|
|
274
|
-
declare const CardLink: ({ className: _className, href, ...restProps }: CardLinkProps) =>
|
|
274
|
+
declare const CardLink: ({ className: _className, href, ...restProps }: CardLinkProps) => react.JSX.Element;
|
|
275
275
|
|
|
276
276
|
type CarouselMethods = {
|
|
277
277
|
/** Navigate to a specific slide by index. */
|
|
@@ -321,7 +321,7 @@ type CarouselProps = Omit<HTMLProps<HTMLDivElement>, 'onChange' | 'onSelect' | '
|
|
|
321
321
|
*/
|
|
322
322
|
scrollGestures?: boolean;
|
|
323
323
|
};
|
|
324
|
-
declare const Carousel: ({ autoPlayDelay, align, children, initialIndex, orientation, onSelect, onSettled, loop, scrollGestures, ref, ...rest }: CarouselProps) =>
|
|
324
|
+
declare const Carousel: ({ autoPlayDelay, align, children, initialIndex, orientation, onSelect, onSettled, loop, scrollGestures, ref, ...rest }: CarouselProps) => react.JSX.Element;
|
|
325
325
|
type CarouselContextValue = {
|
|
326
326
|
slidesInView: number[];
|
|
327
327
|
orientation: 'horizontal' | 'vertical';
|
|
@@ -335,12 +335,12 @@ declare const CarouselContext: react.Context<CarouselContextValue>;
|
|
|
335
335
|
type CarouselItemsContainer = HTMLProps<HTMLDivElement> & {
|
|
336
336
|
children: React.ReactNode;
|
|
337
337
|
};
|
|
338
|
-
declare const CarouselItemsContainer: ({ children, className, ...rest }: CarouselItemsContainer) =>
|
|
338
|
+
declare const CarouselItemsContainer: ({ children, className, ...rest }: CarouselItemsContainer) => react.JSX.Element;
|
|
339
339
|
type CarouselItemsProps = HTMLProps<HTMLDivElement> & {
|
|
340
340
|
/** The <CarouselItem/> components to be displayed within the carousel. */
|
|
341
341
|
children: React.ReactNode;
|
|
342
342
|
};
|
|
343
|
-
declare const CarouselItems: ({ className, children, ...restProps }: CarouselItemsProps) =>
|
|
343
|
+
declare const CarouselItems: ({ className, children, ...restProps }: CarouselItemsProps) => react.JSX.Element;
|
|
344
344
|
type CarouselControlsProps = HTMLProps<HTMLDivElement> & {
|
|
345
345
|
/** The <CarouselItem/> components to be displayed within the carousel. */
|
|
346
346
|
children: React.ReactNode;
|
|
@@ -349,16 +349,16 @@ type CarouselControlsProps = HTMLProps<HTMLDivElement> & {
|
|
|
349
349
|
* This is internal for now, but we will expose it in the future when we support more flexible positioning of prev/next and other actions.
|
|
350
350
|
* It is used to render the prev/next buttons in the carousel for now.
|
|
351
351
|
*/
|
|
352
|
-
declare const CarouselControls: ({ children, className, ...rest }: CarouselControlsProps) =>
|
|
352
|
+
declare const CarouselControls: ({ children, className, ...rest }: CarouselControlsProps) => react.JSX.Element;
|
|
353
353
|
type CarouselButtonProps = ButtonProps & {
|
|
354
354
|
slot: 'next' | 'prev';
|
|
355
355
|
};
|
|
356
|
-
declare const CarouselButton: ({ className, isIconOnly, slot, ...rest }: CarouselButtonProps) =>
|
|
356
|
+
declare const CarouselButton: ({ className, isIconOnly, slot, ...rest }: CarouselButtonProps) => react.JSX.Element;
|
|
357
357
|
type CarouselItemProps = HTMLProps<HTMLDivElement> & {
|
|
358
358
|
/** The component/components to display as the <CarouselItem/>. */
|
|
359
359
|
children: React.ReactNode;
|
|
360
360
|
};
|
|
361
|
-
declare const CarouselItem: ({ className, children, ...rest }: CarouselItemProps) =>
|
|
361
|
+
declare const CarouselItem: ({ className, children, ...rest }: CarouselItemProps) => react.JSX.Element;
|
|
362
362
|
|
|
363
363
|
type CheckboxProps = {
|
|
364
364
|
children: React.ReactNode;
|
|
@@ -373,7 +373,7 @@ type CheckboxProps = {
|
|
|
373
373
|
/** Ref for the element. */
|
|
374
374
|
ref?: Ref<HTMLLabelElement>;
|
|
375
375
|
} & Omit<CheckboxProps$1, 'isDisabled' | 'style' | 'children' | 'isIndeterminate' | 'isReadOnly'>;
|
|
376
|
-
declare function Checkbox(props: CheckboxProps):
|
|
376
|
+
declare function Checkbox(props: CheckboxProps): react.JSX.Element;
|
|
377
377
|
|
|
378
378
|
type CheckboxGroupProps = {
|
|
379
379
|
children: React.ReactNode;
|
|
@@ -390,17 +390,17 @@ type CheckboxGroupProps = {
|
|
|
390
390
|
/** Ref to the element. */
|
|
391
391
|
ref?: Ref<HTMLDivElement>;
|
|
392
392
|
} & Omit<CheckboxGroupProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style' | 'orientation'>;
|
|
393
|
-
declare function CheckboxGroup(props: CheckboxGroupProps):
|
|
393
|
+
declare function CheckboxGroup(props: CheckboxGroupProps): react.JSX.Element;
|
|
394
394
|
|
|
395
|
-
declare const ListBoxItem: (props: ListBoxItemProps) =>
|
|
395
|
+
declare const ListBoxItem: (props: ListBoxItemProps) => react.JSX.Element;
|
|
396
396
|
/**
|
|
397
397
|
* This component can be used to group items in a listbox
|
|
398
398
|
*/
|
|
399
|
-
declare const ListBoxSection: <T extends object>({ className, ...restProps }: ListBoxSectionProps<T>) =>
|
|
399
|
+
declare const ListBoxSection: <T extends object>({ className, ...restProps }: ListBoxSectionProps<T>) => react.JSX.Element;
|
|
400
400
|
/**
|
|
401
401
|
* This component can be used to label grouped items in a `ListBoxSection` with a heading
|
|
402
402
|
*/
|
|
403
|
-
declare const ListBoxHeader: (props: HeaderProps) =>
|
|
403
|
+
declare const ListBoxHeader: (props: HeaderProps) => react.JSX.Element;
|
|
404
404
|
|
|
405
405
|
type ComboboxProps<T extends object> = {
|
|
406
406
|
children: React.ReactNode;
|
|
@@ -424,7 +424,7 @@ type ComboboxProps<T extends object> = {
|
|
|
424
424
|
/** Ref for the input element. */
|
|
425
425
|
ref?: Ref<HTMLInputElement>;
|
|
426
426
|
} & Omit<ComboBoxProps<T>, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
427
|
-
declare function Combobox<T extends object>(props: ComboboxProps<T>):
|
|
427
|
+
declare function Combobox<T extends object>(props: ComboboxProps<T>): react.JSX.Element;
|
|
428
428
|
|
|
429
429
|
type HeadingProps = Omit<HTMLProps<HTMLHeadingElement>, 'size'> & VariantProps<typeof headingVariants> & {
|
|
430
430
|
children?: React.ReactNode;
|
|
@@ -447,7 +447,7 @@ declare const headingVariants: (props?: ({
|
|
|
447
447
|
class?: never;
|
|
448
448
|
className?: cva.ClassValue;
|
|
449
449
|
})) | undefined) => string;
|
|
450
|
-
declare const Heading: ({ ref, ...props }: HeadingProps) => string | number | bigint | boolean |
|
|
450
|
+
declare const Heading: ({ ref, ...props }: HeadingProps) => string | number | bigint | boolean | react.JSX.Element | Iterable<react.ReactNode> | Promise<string | number | bigint | boolean | react.ReactPortal | react.ReactElement<unknown, string | react.JSXElementConstructor<any>> | Iterable<react.ReactNode> | null | undefined> | null | undefined;
|
|
451
451
|
declare const ContentContext: react.Context<ContextValue<Partial<ContentProps>, HTMLDivElement>>;
|
|
452
452
|
type ContentProps = HTMLProps<HTMLDivElement> & {
|
|
453
453
|
children: React.ReactNode;
|
|
@@ -456,7 +456,7 @@ type ContentProps = HTMLProps<HTMLDivElement> & {
|
|
|
456
456
|
/** Ref for the element. */
|
|
457
457
|
ref?: Ref<HTMLDivElement>;
|
|
458
458
|
};
|
|
459
|
-
declare const Content: ({ ref, ...props }: ContentProps) => string | number | bigint | boolean |
|
|
459
|
+
declare const Content: ({ ref, ...props }: ContentProps) => string | number | bigint | boolean | react.JSX.Element | Iterable<react.ReactNode> | Promise<string | number | bigint | boolean | react.ReactPortal | react.ReactElement<unknown, string | react.JSXElementConstructor<any>> | Iterable<react.ReactNode> | null | undefined> | null | undefined;
|
|
460
460
|
type MediaProps = HTMLProps<HTMLDivElement> & VariantProps<typeof mediaVariant> & {
|
|
461
461
|
children: React.ReactNode;
|
|
462
462
|
/** Ref for the element. */
|
|
@@ -472,15 +472,15 @@ declare const mediaVariant: (props?: ({
|
|
|
472
472
|
className?: cva.ClassValue;
|
|
473
473
|
})) | undefined) => string;
|
|
474
474
|
declare const MediaContext: react.Context<ContextValue<Partial<MediaProps>, HTMLDivElement>>;
|
|
475
|
-
declare const Media: ({ ref, ...props }: MediaProps) =>
|
|
475
|
+
declare const Media: ({ ref, ...props }: MediaProps) => react.JSX.Element;
|
|
476
476
|
type FooterProps = HTMLProps<HTMLDivElement> & {
|
|
477
477
|
children: React.ReactNode;
|
|
478
478
|
};
|
|
479
479
|
type CaptionProps = HTMLProps<HTMLDivElement> & {
|
|
480
480
|
children: React.ReactNode;
|
|
481
481
|
};
|
|
482
|
-
declare const Caption: ({ className, ...restProps }: CaptionProps) =>
|
|
483
|
-
declare const Footer: (props: FooterProps) =>
|
|
482
|
+
declare const Caption: ({ className, ...restProps }: CaptionProps) => react.JSX.Element;
|
|
483
|
+
declare const Footer: (props: FooterProps) => react.JSX.Element;
|
|
484
484
|
|
|
485
485
|
type DateFormatterProps = {
|
|
486
486
|
value: Date | string;
|
|
@@ -514,7 +514,7 @@ type DrawerProps = Omit<ModalOverlayProps$1, 'isDismissable' | 'style'> & Pick<V
|
|
|
514
514
|
/** @default true Makes the drawer dismissable */
|
|
515
515
|
isDismissable?: boolean;
|
|
516
516
|
};
|
|
517
|
-
declare const Drawer: ({ isDismissable, isOpen, onOpenChange, defaultOpen, className, zIndex, placement, style, ...restProps }: DrawerProps) =>
|
|
517
|
+
declare const Drawer: ({ isDismissable, isOpen, onOpenChange, defaultOpen, className, zIndex, placement, style, ...restProps }: DrawerProps) => react.JSX.Element;
|
|
518
518
|
|
|
519
519
|
type FormValidationProps<T> = Parameters<typeof useFormValidationState<T>>[0];
|
|
520
520
|
type FileTriggerProps = Partial<Omit<FormValidationProps<File>, 'value'>> & FileTriggerProps$1 & Omit<HTMLAttributes<HTMLInputElement>, 'onSelect' | 'onChange' | 'required' | 'className'> & {
|
|
@@ -532,7 +532,7 @@ type FileUploadProps = Omit<FileTriggerProps, 'onSelect'> & {
|
|
|
532
532
|
isInvalid?: boolean;
|
|
533
533
|
errorMessage?: string;
|
|
534
534
|
};
|
|
535
|
-
declare const FileUpload: ({ children, files: _files, onChange, validate, isInvalid: _isInvalid, errorMessage, isRequired, allowsMultiple, ref, ...fileTriggerProps }: FileUploadProps) =>
|
|
535
|
+
declare const FileUpload: ({ children, files: _files, onChange, validate, isInvalid: _isInvalid, errorMessage, isRequired, allowsMultiple, ref, ...fileTriggerProps }: FileUploadProps) => react.JSX.Element;
|
|
536
536
|
|
|
537
537
|
type Locale = 'nb' | 'sv' | 'en';
|
|
538
538
|
/**
|
|
@@ -553,7 +553,7 @@ type GrunnmurenProviderProps = {
|
|
|
553
553
|
/** Converts a router-specific href to a native HTML href, e.g. prepending a base path */
|
|
554
554
|
useHref?: RouterProviderProps['useHref'];
|
|
555
555
|
};
|
|
556
|
-
declare function GrunnmurenProvider({ children, locale, navigate, useHref, }: GrunnmurenProviderProps):
|
|
556
|
+
declare function GrunnmurenProvider({ children, locale, navigate, useHref, }: GrunnmurenProviderProps): react.JSX.Element;
|
|
557
557
|
|
|
558
558
|
type HeroProps = HTMLProps<HTMLDivElement> & VariantProps<typeof variants> & {
|
|
559
559
|
children: React.ReactNode;
|
|
@@ -571,15 +571,15 @@ declare const variants: (props?: ({
|
|
|
571
571
|
class?: never;
|
|
572
572
|
className?: cva.ClassValue;
|
|
573
573
|
})) | undefined) => string;
|
|
574
|
-
declare const Hero: ({ variant, className, children, ...rest }: HeroProps) =>
|
|
574
|
+
declare const Hero: ({ variant, className, children, ...rest }: HeroProps) => react.JSX.Element;
|
|
575
575
|
|
|
576
576
|
type DescriptionProps = TextProps;
|
|
577
|
-
declare function Description(props: DescriptionProps):
|
|
577
|
+
declare function Description(props: DescriptionProps): react.JSX.Element;
|
|
578
578
|
|
|
579
579
|
type ErrorMessageProps = TextProps;
|
|
580
|
-
declare function ErrorMessage(props: ErrorMessageProps):
|
|
580
|
+
declare function ErrorMessage(props: ErrorMessageProps): react.JSX.Element;
|
|
581
581
|
|
|
582
|
-
declare function Label(props: LabelProps):
|
|
582
|
+
declare function Label(props: LabelProps): react.JSX.Element;
|
|
583
583
|
|
|
584
584
|
type LinkListContextValue = {
|
|
585
585
|
shouldRenderAutoIcons: boolean;
|
|
@@ -597,18 +597,18 @@ declare const linkListContainerVariants: (props?: ({
|
|
|
597
597
|
type LinkListContainerProps = VariantProps<typeof linkListContainerVariants> & React.HTMLProps<HTMLDivElement> & {
|
|
598
598
|
children: JSX.Element | JSX.Element[];
|
|
599
599
|
};
|
|
600
|
-
declare const LinkListContainer: ({ className, layout, ...props }: LinkListContainerProps) =>
|
|
600
|
+
declare const LinkListContainer: ({ className, layout, ...props }: LinkListContainerProps) => JSX.Element;
|
|
601
601
|
type LinkListProps = React.HTMLProps<HTMLUListElement> & {
|
|
602
602
|
children: JSX.Element | JSX.Element[];
|
|
603
603
|
};
|
|
604
|
-
declare const LinkList: ({ className, children, ...restProps }: LinkListProps) =>
|
|
604
|
+
declare const LinkList: ({ className, children, ...restProps }: LinkListProps) => JSX.Element;
|
|
605
605
|
type LinkListItemProps = React.HTMLProps<HTMLLIElement> & {
|
|
606
606
|
children: ReactNode;
|
|
607
607
|
};
|
|
608
|
-
declare const LinkListItem: ({ children, className, ...props }: LinkListItemProps) =>
|
|
608
|
+
declare const LinkListItem: ({ children, className, ...props }: LinkListItemProps) => JSX.Element;
|
|
609
609
|
|
|
610
610
|
type DialogTriggerProps = DialogTriggerProps$1;
|
|
611
|
-
declare const DialogTrigger: (props: DialogTriggerProps) =>
|
|
611
|
+
declare const DialogTrigger: (props: DialogTriggerProps) => react.JSX.Element;
|
|
612
612
|
type ModalOverlayProps = Omit<ModalOverlayProps$1, 'isDismissable' | 'style'> & {
|
|
613
613
|
/** Additional style properties for the element. */
|
|
614
614
|
style?: React.CSSProperties;
|
|
@@ -620,11 +620,11 @@ type ModalOverlayProps = Omit<ModalOverlayProps$1, 'isDismissable' | 'style'> &
|
|
|
620
620
|
fullscreen?: boolean;
|
|
621
621
|
};
|
|
622
622
|
type ModalProps = ModalOverlayProps;
|
|
623
|
-
declare const Modal: ({ isDismissable, isOpen, onOpenChange, defaultOpen, className, zIndex, fullscreen, ...restProps }: ModalProps) =>
|
|
623
|
+
declare const Modal: ({ isDismissable, isOpen, onOpenChange, defaultOpen, className, zIndex, fullscreen, ...restProps }: ModalProps) => react.JSX.Element;
|
|
624
624
|
type DialogProps = DialogProps$1 & {
|
|
625
625
|
children: React.ReactNode;
|
|
626
626
|
};
|
|
627
|
-
declare const Dialog: ({ className, children, ...restProps }: DialogProps) =>
|
|
627
|
+
declare const Dialog: ({ className, children, ...restProps }: DialogProps) => react.JSX.Element;
|
|
628
628
|
|
|
629
629
|
type NumberFieldProps = {
|
|
630
630
|
/** Additional CSS className for the element. */
|
|
@@ -659,7 +659,26 @@ type NumberFieldProps = {
|
|
|
659
659
|
/** Ref for the input element. */
|
|
660
660
|
ref?: Ref<HTMLInputElement>;
|
|
661
661
|
} & Omit<NumberFieldProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style' | 'hideStepper'>;
|
|
662
|
-
declare function NumberField(props: NumberFieldProps):
|
|
662
|
+
declare function NumberField(props: NumberFieldProps): react.JSX.Element;
|
|
663
|
+
|
|
664
|
+
type PaginationProps = {
|
|
665
|
+
/** The current page (1-indexed). */
|
|
666
|
+
page: number;
|
|
667
|
+
/** The total number of pages. */
|
|
668
|
+
count: number;
|
|
669
|
+
/** Given a page number, returns the href for navigating to that page. The
|
|
670
|
+
* value is set as the `href` attribute on the rendered link, enabling
|
|
671
|
+
* right-click, middle-click and SEO. Client-side routing is set up via
|
|
672
|
+
* `routerOptions` on `<GrunnmurenProvider />`. */
|
|
673
|
+
getItemHref: (page: number) => string;
|
|
674
|
+
/** Optional callback fired when the user activates a page link. Useful for
|
|
675
|
+
* keeping local state in sync with the URL. Navigation still happens via
|
|
676
|
+
* the link's href. */
|
|
677
|
+
onChange?: (page: number) => void;
|
|
678
|
+
/** Additional class name for the root `<ol>`. */
|
|
679
|
+
className?: string;
|
|
680
|
+
};
|
|
681
|
+
declare const Pagination: (props: PaginationProps) => react.JSX.Element;
|
|
663
682
|
|
|
664
683
|
type RadioProps = {
|
|
665
684
|
children: React.ReactNode;
|
|
@@ -672,7 +691,7 @@ type RadioProps = {
|
|
|
672
691
|
/** Ref for the element. */
|
|
673
692
|
ref?: Ref<HTMLLabelElement>;
|
|
674
693
|
} & Omit<RadioProps$1, 'isDisabled' | 'children' | 'style'>;
|
|
675
|
-
declare function Radio(props: RadioProps):
|
|
694
|
+
declare function Radio(props: RadioProps): react.JSX.Element;
|
|
676
695
|
|
|
677
696
|
type RadioGroupProps = {
|
|
678
697
|
children: React.ReactNode;
|
|
@@ -689,7 +708,7 @@ type RadioGroupProps = {
|
|
|
689
708
|
/** Ref for the element. */
|
|
690
709
|
ref?: Ref<HTMLDivElement>;
|
|
691
710
|
} & Omit<RadioGroupProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style' | 'orientation'>;
|
|
692
|
-
declare function RadioGroup(props: RadioGroupProps):
|
|
711
|
+
declare function RadioGroup(props: RadioGroupProps): react.JSX.Element;
|
|
693
712
|
|
|
694
713
|
type SelectProps<T extends object> = {
|
|
695
714
|
children: React.ReactNode;
|
|
@@ -708,7 +727,7 @@ type SelectProps<T extends object> = {
|
|
|
708
727
|
/** Ref for the button element. */
|
|
709
728
|
ref?: Ref<HTMLButtonElement>;
|
|
710
729
|
} & Omit<SelectProps$1<T>, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
711
|
-
declare function Select<T extends object>(props: SelectProps<T>):
|
|
730
|
+
declare function Select<T extends object>(props: SelectProps<T>): react.JSX.Element;
|
|
712
731
|
|
|
713
732
|
type StepperProps = HTMLAttributes<HTMLDivElement> & {
|
|
714
733
|
children: React.ReactNode;
|
|
@@ -717,7 +736,7 @@ type StepperProps = HTMLAttributes<HTMLDivElement> & {
|
|
|
717
736
|
/** Handler that is called when the step changes. */
|
|
718
737
|
onStepChange?: (step: number) => void;
|
|
719
738
|
};
|
|
720
|
-
declare const Stepper: ({ children, activeStep, onStepChange, ...restProps }: StepperProps) =>
|
|
739
|
+
declare const Stepper: ({ children, activeStep, onStepChange, ...restProps }: StepperProps) => react.JSX.Element;
|
|
721
740
|
type StepProps = HTMLProps<HTMLLIElement> & {
|
|
722
741
|
/**
|
|
723
742
|
* The state fo the step, whether the step is completed or not.
|
|
@@ -733,7 +752,7 @@ type StepProps = HTMLProps<HTMLLIElement> & {
|
|
|
733
752
|
/** @private */
|
|
734
753
|
'~stepIndex'?: number;
|
|
735
754
|
};
|
|
736
|
-
declare const Step: ({ isDisabled, state, children, "~stepIndex": stepIndex, progress, ...restProps }: StepProps) =>
|
|
755
|
+
declare const Step: ({ isDisabled, state, children, "~stepIndex": stepIndex, progress, ...restProps }: StepProps) => react.JSX.Element;
|
|
737
756
|
|
|
738
757
|
type TableVariant = 'default' | 'zebra-striped';
|
|
739
758
|
type TableProps = Omit<TableProps$1, 'aria-label' | 'aria-labelledby'> & RefAttributes<HTMLTableElement> & {
|
|
@@ -763,25 +782,25 @@ type ResizableTableContainerProps = ResizableTableContainerProps$1;
|
|
|
763
782
|
/**
|
|
764
783
|
* A container component for displaying tabular data with horizontal scrolling support.
|
|
765
784
|
*/
|
|
766
|
-
declare function Table(props: TableProps):
|
|
785
|
+
declare function Table(props: TableProps): react.JSX.Element;
|
|
767
786
|
/**
|
|
768
787
|
* Container that enables column resizing and horizontal scrolling for the
|
|
769
788
|
* nested <Table>. Use when you want resizable columns or want to apply
|
|
770
789
|
* `maxWidth`/`minWidth` truncation on columns.
|
|
771
790
|
*/
|
|
772
|
-
declare function ResizableTableContainer({ className, children, ...restProps }: ResizableTableContainerProps):
|
|
791
|
+
declare function ResizableTableContainer({ className, children, ...restProps }: ResizableTableContainerProps): react.JSX.Element;
|
|
773
792
|
/**
|
|
774
793
|
* Container for table column headers.
|
|
775
794
|
*/
|
|
776
|
-
declare function TableHeader({ className, children, ...restProps }: TableHeaderProps):
|
|
777
|
-
declare function TableColumn(props: TableColumnProps):
|
|
778
|
-
declare const TableColumnResizer: ({ className, ...restProps }: TableColumnResizerProps) =>
|
|
795
|
+
declare function TableHeader({ className, children, ...restProps }: TableHeaderProps): react.JSX.Element;
|
|
796
|
+
declare function TableColumn(props: TableColumnProps): react.JSX.Element;
|
|
797
|
+
declare const TableColumnResizer: ({ className, ...restProps }: TableColumnResizerProps) => react.JSX.Element;
|
|
779
798
|
/**
|
|
780
799
|
* Container for table rows.
|
|
781
800
|
*/
|
|
782
|
-
declare function TableBody({ className, children, ...restProps }: TableBodyProps):
|
|
783
|
-
declare function TableRow(props: TableRowProps):
|
|
784
|
-
declare function TableCell(props: TableCellProps):
|
|
801
|
+
declare function TableBody({ className, children, ...restProps }: TableBodyProps): react.JSX.Element;
|
|
802
|
+
declare function TableRow(props: TableRowProps): react.JSX.Element;
|
|
803
|
+
declare function TableCell(props: TableCellProps): react.JSX.Element;
|
|
785
804
|
/** @deprecated Use `UNSAFE_ResizableTableContainer` instead. */
|
|
786
805
|
declare const UNSAFE_TableContainer: typeof ResizableTableContainer;
|
|
787
806
|
/** @deprecated Use `UNSAFE_ResizableTableContainerProps` instead. */
|
|
@@ -818,19 +837,19 @@ type TabPanelProps = Omit<TabPanelProps$1, 'className'> & RefAttributes<HTMLDivE
|
|
|
818
837
|
* A container component that organizes content into multiple sections
|
|
819
838
|
* and allows users to navigate between them.
|
|
820
839
|
*/
|
|
821
|
-
declare function Tabs(props: TabsProps):
|
|
840
|
+
declare function Tabs(props: TabsProps): react.JSX.Element;
|
|
822
841
|
/**
|
|
823
842
|
* A container component for Tab components within Tabs.
|
|
824
843
|
*/
|
|
825
|
-
declare function TabList({ className, children, ...restProps }: TabListProps):
|
|
844
|
+
declare function TabList({ className, children, ...restProps }: TabListProps): react.JSX.Element;
|
|
826
845
|
/**
|
|
827
846
|
* An individual tab that can be selected to display its associated content.
|
|
828
847
|
*/
|
|
829
|
-
declare function Tab(props: TabProps):
|
|
848
|
+
declare function Tab(props: TabProps): react.JSX.Element;
|
|
830
849
|
/**
|
|
831
850
|
* The content area that displays the selected tab's content.
|
|
832
851
|
*/
|
|
833
|
-
declare function TabPanel(props: TabPanelProps):
|
|
852
|
+
declare function TabPanel(props: TabPanelProps): react.JSX.Element;
|
|
834
853
|
|
|
835
854
|
type TagGroupProps = Omit<TagGroupProps$1, 'className'> & RefAttributes<HTMLDivElement> & {
|
|
836
855
|
/**
|
|
@@ -863,15 +882,15 @@ type TagProps = Omit<TagProps$1, 'className'> & RefAttributes<HTMLDivElement> &
|
|
|
863
882
|
/**
|
|
864
883
|
* A group component for Tag components that enables selection and organization of options.
|
|
865
884
|
*/
|
|
866
|
-
declare function TagGroup(props: TagGroupProps):
|
|
885
|
+
declare function TagGroup(props: TagGroupProps): react.JSX.Element;
|
|
867
886
|
/**
|
|
868
887
|
* A container component for Tag components within a TagGroup.
|
|
869
888
|
*/
|
|
870
|
-
declare function TagList(props: TagListProps):
|
|
889
|
+
declare function TagList(props: TagListProps): react.JSX.Element;
|
|
871
890
|
/**
|
|
872
891
|
* Interactive tag component for selections, filtering, and categorization.
|
|
873
892
|
*/
|
|
874
|
-
declare function Tag(props: TagProps):
|
|
893
|
+
declare function Tag(props: TagProps): react.JSX.Element;
|
|
875
894
|
|
|
876
895
|
type TextAreaProps = {
|
|
877
896
|
/** Additional CSS className for the element. */
|
|
@@ -894,7 +913,7 @@ type TextAreaProps = {
|
|
|
894
913
|
/** Ref for the textarea element. */
|
|
895
914
|
ref?: Ref<HTMLTextAreaElement>;
|
|
896
915
|
} & Omit<TextFieldProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
897
|
-
declare function TextArea(props: TextAreaProps):
|
|
916
|
+
declare function TextArea(props: TextAreaProps): react.JSX.Element;
|
|
898
917
|
|
|
899
918
|
type TextFieldProps = {
|
|
900
919
|
/** Additional CSS className for the element. */
|
|
@@ -925,7 +944,36 @@ type TextFieldProps = {
|
|
|
925
944
|
/** Ref for the input element. */
|
|
926
945
|
ref?: Ref<HTMLInputElement>;
|
|
927
946
|
} & Omit<TextFieldProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
928
|
-
declare function TextField(props: TextFieldProps):
|
|
947
|
+
declare function TextField(props: TextFieldProps): react.JSX.Element;
|
|
948
|
+
|
|
949
|
+
type ToggletipProps = DialogTriggerProps$1;
|
|
950
|
+
/** Root of the toggletip. Wraps a `<ToggletipTrigger>` and a `<ToggletipContent>`. */
|
|
951
|
+
declare const Toggletip: (props: ToggletipProps) => react.JSX.Element;
|
|
952
|
+
type ToggletipTriggerProps = Omit<ButtonProps$1, 'children' | 'className'> & {
|
|
953
|
+
children: React.ReactNode;
|
|
954
|
+
/**
|
|
955
|
+
* Visual preset: `definition` (an inline, dashed-underlined term) or `info`
|
|
956
|
+
* (a 44x44 icon button). Omit it to style the trigger yourself — children and
|
|
957
|
+
* appearance are then up to you.
|
|
958
|
+
*/
|
|
959
|
+
variant?: 'definition' | 'info';
|
|
960
|
+
/** Additional class name for the trigger button. */
|
|
961
|
+
className?: string;
|
|
962
|
+
};
|
|
963
|
+
/**
|
|
964
|
+
* The button that toggles the toggletip. Needs an accessible name — `aria-label`
|
|
965
|
+
* for an icon, or the visible text for a definition term.
|
|
966
|
+
*/
|
|
967
|
+
declare const ToggletipTrigger: ({ variant, className, ...restProps }: ToggletipTriggerProps) => react.JSX.Element;
|
|
968
|
+
type ToggletipContentProps = Omit<PopoverProps, 'children' | 'className'> & {
|
|
969
|
+
/** Accessible label for the dialog. Required, since the content has no heading. */
|
|
970
|
+
'aria-label': string;
|
|
971
|
+
children: React.ReactNode;
|
|
972
|
+
/** Additional class name for the popover. */
|
|
973
|
+
className?: string;
|
|
974
|
+
};
|
|
975
|
+
/** The popover content of the toggletip: a `Dialog` (with `aria-label`) and a close button. */
|
|
976
|
+
declare const ToggletipContent: ({ "aria-label": ariaLabel, children, className, ...restProps }: ToggletipContentProps) => react.JSX.Element;
|
|
929
977
|
|
|
930
978
|
type VideoLoopProps = {
|
|
931
979
|
/** The video url */
|
|
@@ -941,7 +989,7 @@ type VideoLoopProps = {
|
|
|
941
989
|
alt?: string;
|
|
942
990
|
className?: string;
|
|
943
991
|
};
|
|
944
|
-
declare const VideoLoop: ({ src, format, alt, className }: VideoLoopProps) =>
|
|
992
|
+
declare const VideoLoop: ({ src, format, alt, className }: VideoLoopProps) => react.JSX.Element;
|
|
945
993
|
|
|
946
|
-
export { Accordion, AccordionItem, Alertbox, Avatar, Backlink, Badge, Breadcrumb, Breadcrumbs, Button, ButtonContext, Caption, Card, CardLink, Checkbox, CheckboxGroup, Combobox, ListBoxHeader as ComboboxHeader, ListBoxItem as ComboboxItem, ListBoxSection as ComboboxSection, Content, ContentContext, DateFormatter, Description, Disclosure, DisclosureButton, DisclosurePanel, DisclosureStateContext, ErrorMessage, Footer, GrunnmurenProvider, Heading, HeadingContext, Label, Link, LinkList, LinkListContainer, LinkListContext, LinkListItem, Media, MediaContext, NumberField, Radio, RadioGroup, Select, ListBoxHeader as SelectHeader, ListBoxItem as SelectItem, ListBoxSection as SelectSection, Tab, TabList, TabPanel, Tabs, Tag, TagGroup, TagList, TextArea, TextField, Carousel as UNSAFE_Carousel, CarouselButton as UNSAFE_CarouselButton, CarouselContext as UNSAFE_CarouselContext, CarouselControls as UNSAFE_CarouselControls, CarouselItem as UNSAFE_CarouselItem, CarouselItems as UNSAFE_CarouselItems, CarouselItemsContainer as UNSAFE_CarouselItemsContainer, CarouselItemsContainer as UNSAFE_CarouselItemsContainerProps, Dialog as UNSAFE_Dialog, DialogTrigger as UNSAFE_DialogTrigger, Drawer as UNSAFE_Drawer, FileUpload as UNSAFE_FileUpload,
|
|
947
|
-
export type { AccordionItemProps, AccordionProps, Props as AlertboxProps, AvatarProps, BacklinkProps, BadgeProps, BreadcrumbProps, BreadcrumbsProps, ButtonProps, CaptionProps, CardLinkProps, CardProps, CheckboxGroupProps, CheckboxProps, ComboboxProps, ContentProps, DateFormatterProps, DescriptionProps, DisclosureButtonProps, DisclosurePanelProps, DisclosureProps, ErrorMessageProps, FooterProps, GrunnmurenProviderProps, HeadingProps, LinkListContainerProps, LinkListContextValue, LinkListItemProps, LinkListProps, LinkProps, Locale, MediaProps, NumberFieldProps, RadioGroupProps, RadioProps, SelectProps, TabListProps, TabPanelProps, TabProps, TabsProps, TagGroupProps, TagListProps, TagProps, TextAreaProps, TextFieldProps, CarouselButtonProps as UNSAFE_CarouselButtonProps, CarouselContextValue as UNSAFE_CarouselContextValue, CarouselControlsProps as UNSAFE_CarouselControlsProps, CarouselItemProps as UNSAFE_CarouselItemProps, CarouselItemsProps as UNSAFE_CarouselItemsProps, CarouselProps as UNSAFE_CarouselProps, CarouselElement as UNSAFE_CarouselRef, DialogProps as UNSAFE_DialogProps, DialogTriggerProps as UNSAFE_DialogTriggerProps, DrawerProps as UNSAFE_DrawerProps, FileUploadProps as UNSAFE_FileUploadProps,
|
|
994
|
+
export { Accordion, AccordionItem, Alertbox, Avatar, Backlink, Badge, Breadcrumb, Breadcrumbs, Button, ButtonContext, Caption, Card, CardLink, Checkbox, CheckboxGroup, Combobox, ListBoxHeader as ComboboxHeader, ListBoxItem as ComboboxItem, ListBoxSection as ComboboxSection, Content, ContentContext, DateFormatter, Description, Disclosure, DisclosureButton, DisclosurePanel, DisclosureStateContext, ErrorMessage, Footer, GrunnmurenProvider, Heading, HeadingContext, Hero, HeroContext, Label, Link, LinkList, LinkListContainer, LinkListContext, LinkListItem, Media, MediaContext, NumberField, Radio, RadioGroup, Select, ListBoxHeader as SelectHeader, ListBoxItem as SelectItem, ListBoxSection as SelectSection, Tab, TabList, TabPanel, Tabs, Tag, TagGroup, TagList, TextArea, TextField, Carousel as UNSAFE_Carousel, CarouselButton as UNSAFE_CarouselButton, CarouselContext as UNSAFE_CarouselContext, CarouselControls as UNSAFE_CarouselControls, CarouselItem as UNSAFE_CarouselItem, CarouselItems as UNSAFE_CarouselItems, CarouselItemsContainer as UNSAFE_CarouselItemsContainer, CarouselItemsContainer as UNSAFE_CarouselItemsContainerProps, Dialog as UNSAFE_Dialog, DialogTrigger as UNSAFE_DialogTrigger, Drawer as UNSAFE_Drawer, FileUpload as UNSAFE_FileUpload, Modal as UNSAFE_Modal, Pagination as UNSAFE_Pagination, ResizableTableContainer as UNSAFE_ResizableTableContainer, Step as UNSAFE_Step, Stepper as UNSAFE_Stepper, Table as UNSAFE_Table, TableBody as UNSAFE_TableBody, TableCell as UNSAFE_TableCell, TableColumn as UNSAFE_TableColumn, TableColumnResizer as UNSAFE_TableColumnResizer, UNSAFE_TableContainer, TableHeader as UNSAFE_TableHeader, TableRow as UNSAFE_TableRow, Toggletip as UNSAFE_Toggletip, ToggletipContent as UNSAFE_ToggletipContent, ToggletipTrigger as UNSAFE_ToggletipTrigger, VideoLoop, _useLocale as useLocale };
|
|
995
|
+
export type { AccordionItemProps, AccordionProps, Props as AlertboxProps, AvatarProps, BacklinkProps, BadgeProps, BreadcrumbProps, BreadcrumbsProps, ButtonProps, CaptionProps, CardLinkProps, CardProps, CheckboxGroupProps, CheckboxProps, ComboboxProps, ContentProps, DateFormatterProps, DescriptionProps, DisclosureButtonProps, DisclosurePanelProps, DisclosureProps, ErrorMessageProps, FooterProps, GrunnmurenProviderProps, HeadingProps, HeroContextValue, HeroProps, LinkListContainerProps, LinkListContextValue, LinkListItemProps, LinkListProps, LinkProps, Locale, MediaProps, NumberFieldProps, RadioGroupProps, RadioProps, SelectProps, TabListProps, TabPanelProps, TabProps, TabsProps, TagGroupProps, TagListProps, TagProps, TextAreaProps, TextFieldProps, CarouselButtonProps as UNSAFE_CarouselButtonProps, CarouselContextValue as UNSAFE_CarouselContextValue, CarouselControlsProps as UNSAFE_CarouselControlsProps, CarouselItemProps as UNSAFE_CarouselItemProps, CarouselItemsProps as UNSAFE_CarouselItemsProps, CarouselProps as UNSAFE_CarouselProps, CarouselElement as UNSAFE_CarouselRef, DialogProps as UNSAFE_DialogProps, DialogTriggerProps as UNSAFE_DialogTriggerProps, DrawerProps as UNSAFE_DrawerProps, FileUploadProps as UNSAFE_FileUploadProps, ModalProps as UNSAFE_ModalProps, PaginationProps as UNSAFE_PaginationProps, ResizableTableContainerProps as UNSAFE_ResizableTableContainerProps, StepProps as UNSAFE_StepProps, StepperProps as UNSAFE_StepperProps, TableBodyProps as UNSAFE_TableBodyProps, TableCellProps as UNSAFE_TableCellProps, TableColumnProps as UNSAFE_TableColumnProps, TableColumnResizerProps as UNSAFE_TableColumnResizerProps, UNSAFE_TableContainerProps, TableHeaderProps as UNSAFE_TableHeaderProps, TableProps as UNSAFE_TableProps, TableRowProps as UNSAFE_TableRowProps, ToggletipContentProps as UNSAFE_ToggletipContentProps, ToggletipProps as UNSAFE_ToggletipProps, ToggletipTriggerProps as UNSAFE_ToggletipTriggerProps };
|
package/dist/index.mjs
CHANGED
|
@@ -3,7 +3,7 @@ import { RouterProvider } from 'react-aria-components';
|
|
|
3
3
|
export { Form, Group } from 'react-aria-components';
|
|
4
4
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
5
5
|
import { cva, cx, compose } from 'cva';
|
|
6
|
-
import { createContext, useContext, useId, useRef, Children, useState, useEffect, useMemo, useCallback, useImperativeHandle, isValidElement, use, cloneElement } from 'react';
|
|
6
|
+
import { createContext, useContext, useId, useRef, Children, useState, useEffect, useMemo, useCallback, useImperativeHandle, isValidElement, useLayoutEffect, use, cloneElement } from 'react';
|
|
7
7
|
import { useContextProps, Provider, DEFAULT_SLOT, useSlottedContext } from 'react-aria-components/slots';
|
|
8
8
|
import { ChevronDown, Error, Warning, CheckCircle, InfoCircle, Close, User, ChevronLeft, Download, LinkExternal, ArrowRight, ChevronRight, LoadingSpinner, Check, Trash, Edit, PlayerPause, PlayerPlay } from '@obosbbl/grunnmuren-icons-react';
|
|
9
9
|
import { ButtonContext as ButtonContext$1, Button as Button$1 } from 'react-aria-components/Button';
|
|
@@ -32,7 +32,7 @@ import { FieldError, FieldErrorContext } from 'react-aria-components/FieldError'
|
|
|
32
32
|
import { Label as Label$1, LabelContext } from 'react-aria-components/Label';
|
|
33
33
|
import { ComboBox } from 'react-aria-components/ComboBox';
|
|
34
34
|
import { Input, InputContext } from 'react-aria-components/Input';
|
|
35
|
-
import { Popover } from 'react-aria-components/Popover';
|
|
35
|
+
import { Popover, OverlayArrow } from 'react-aria-components/Popover';
|
|
36
36
|
import { Header } from 'react-aria-components/Header';
|
|
37
37
|
import { ListBoxItem as ListBoxItem$1, ListBoxSection as ListBoxSection$1, ListBox as ListBox$1 } from 'react-aria-components/ListBox';
|
|
38
38
|
import { useDateFormatter } from 'react-aria/useDateFormatter';
|
|
@@ -397,6 +397,21 @@ const translations$1 = {
|
|
|
397
397
|
sv: 'Nästa',
|
|
398
398
|
en: 'Next'
|
|
399
399
|
},
|
|
400
|
+
pagination: {
|
|
401
|
+
nb: 'Paginering',
|
|
402
|
+
sv: 'Paginering',
|
|
403
|
+
en: 'Pagination'
|
|
404
|
+
},
|
|
405
|
+
previousPage: {
|
|
406
|
+
nb: 'Forrige side',
|
|
407
|
+
sv: 'Föregående sida',
|
|
408
|
+
en: 'Previous page'
|
|
409
|
+
},
|
|
410
|
+
nextPage: {
|
|
411
|
+
nb: 'Neste side',
|
|
412
|
+
sv: 'Nästa sida',
|
|
413
|
+
en: 'Next page'
|
|
414
|
+
},
|
|
400
415
|
externalLink: {
|
|
401
416
|
nb: '(ekstern lenke)',
|
|
402
417
|
sv: '(extern länk)',
|
|
@@ -945,11 +960,13 @@ function Button({ ref = null, ...props }) {
|
|
|
945
960
|
return isLinkProps(restProps) ? /*#__PURE__*/ jsx(Link$1, {
|
|
946
961
|
...restProps,
|
|
947
962
|
className: className,
|
|
963
|
+
"data-slot": "button",
|
|
948
964
|
ref: ref,
|
|
949
965
|
children: children
|
|
950
966
|
}) : /*#__PURE__*/ jsx(Button$1, {
|
|
951
967
|
...restProps,
|
|
952
968
|
className: className,
|
|
969
|
+
"data-slot": "button",
|
|
953
970
|
isPending: isPending,
|
|
954
971
|
ref: ref,
|
|
955
972
|
children: children
|
|
@@ -1188,7 +1205,11 @@ const oneColumnLayout = [
|
|
|
1188
1205
|
// Aligns <Content> and any element beside it (e.g. <Media>, <Badge>, <CTA> etc.) to the bottom of the <Content> container
|
|
1189
1206
|
'lg:items-end'
|
|
1190
1207
|
];
|
|
1191
|
-
|
|
1208
|
+
// Use `not-has-[video]` (tag selector) so that aspect-ratio rules also skip for video players
|
|
1209
|
+
// that don't expose `data-slot="video"` (e.g., MuxPlayer).
|
|
1210
|
+
// Aspect-ratio is applied to the `<Media>` element itself (not the img inside) so that the
|
|
1211
|
+
// Media box fills the grid column and consumers don't need `!important` overrides when nesting.
|
|
1212
|
+
const nonFullBleedAspectRatiosForSmallScreens = '*:data-[slot=media]:not-has-[video]:aspect-[1/1] sm:*:data-[slot=media]:not-has-[video]:aspect-4/3 md:*:data-[slot=media]:not-has-[video]:aspect-3/2';
|
|
1192
1213
|
const variants = cva({
|
|
1193
1214
|
base: [
|
|
1194
1215
|
'container px-0',
|
|
@@ -1213,7 +1234,7 @@ const variants = cva({
|
|
|
1213
1234
|
standard: [
|
|
1214
1235
|
oneColumnLayout,
|
|
1215
1236
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
1216
|
-
'lg:*:data-[slot=media]:not-has-
|
|
1237
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-2/1'
|
|
1217
1238
|
],
|
|
1218
1239
|
'full-bleed': [
|
|
1219
1240
|
oneColumnLayout,
|
|
@@ -1242,7 +1263,7 @@ const variants = cva({
|
|
|
1242
1263
|
'lg:*:data-[slot=content]:gap-y-7',
|
|
1243
1264
|
nonFullBleedAspectRatiosForSmallScreens,
|
|
1244
1265
|
// Set media aspect ratio to 1:1 (square)
|
|
1245
|
-
'lg:*:data-[slot=media]:not-has-
|
|
1266
|
+
'lg:*:data-[slot=media]:not-has-[video]:aspect-square'
|
|
1246
1267
|
]
|
|
1247
1268
|
}
|
|
1248
1269
|
},
|
|
@@ -1254,6 +1275,8 @@ const variants = cva({
|
|
|
1254
1275
|
],
|
|
1255
1276
|
className: [
|
|
1256
1277
|
'*:data-[slot=media]:*:rounded-3xl',
|
|
1278
|
+
// Make non-video media (image/picture) fill the aspect-ratio-constrained Media box
|
|
1279
|
+
'*:data-[slot=media]:not-has-[video]:*:size-full',
|
|
1257
1280
|
'*:data-[slot=carousel]:relative **:data-[slot=carousel-container]:rounded-3xl **:data-[slot=carousel-controls]:absolute **:data-[slot=carousel-controls]:right-4 **:data-[slot=carousel-controls]:bottom-4'
|
|
1258
1281
|
]
|
|
1259
1282
|
}
|
|
@@ -1354,7 +1377,7 @@ const Modal = ({ isDismissable = true, isOpen, onOpenChange, defaultOpen, classN
|
|
|
1354
1377
|
fullscreen: fullscreen,
|
|
1355
1378
|
children: /*#__PURE__*/ jsx(Modal$1, {
|
|
1356
1379
|
...restProps,
|
|
1357
|
-
className: ({ isEntering, isExiting })=>cx(className, 'overflow-auto bg-white text-left shadow-xl', fullscreen ? 'fixed inset-0' : 'w-full max-w-md rounded-2xl
|
|
1380
|
+
className: ({ isEntering, isExiting })=>cx(className, 'overflow-auto bg-white text-left shadow-xl', fullscreen ? 'fixed inset-0' : 'w-full max-w-md rounded-2xl align-middle', isEntering && 'zoom-in-95 animate-in duration-300 ease-out', isExiting && 'zoom-out-95 animate-out duration-200 ease-in', // Using the motion-safe class does not work, so we use motion-reduce to overwrite instead
|
|
1358
1381
|
'motion-reduce:animate-none')
|
|
1359
1382
|
})
|
|
1360
1383
|
})
|
|
@@ -1362,7 +1385,7 @@ const Modal = ({ isDismissable = true, isOpen, onOpenChange, defaultOpen, classN
|
|
|
1362
1385
|
};
|
|
1363
1386
|
const Dialog = ({ className, children, ...restProps })=>/*#__PURE__*/ jsx(Dialog$1, {
|
|
1364
1387
|
...restProps,
|
|
1365
|
-
className: cx(className, 'relative flex flex-col gap-y-5 outline-none', // Footer
|
|
1388
|
+
className: cx(className, 'relative flex flex-col gap-y-5 p-4 outline-none', // Footer
|
|
1366
1389
|
'**:data-[slot="footer"]:flex **:data-[slot="footer"]:gap-x-2'),
|
|
1367
1390
|
children: ({ close })=>/*#__PURE__*/ jsx(Provider, {
|
|
1368
1391
|
values: [
|
|
@@ -2059,10 +2082,10 @@ const drawerVariants = cva({
|
|
|
2059
2082
|
],
|
|
2060
2083
|
variants: {
|
|
2061
2084
|
placement: {
|
|
2062
|
-
right: 'top-0 right-0 h-dvh w-full max-w-md rounded-l-2xl
|
|
2063
|
-
left: 'top-0 left-0 h-dvh w-full max-w-md rounded-r-2xl
|
|
2064
|
-
top: 'inset-x-0 top-0 max-h-[80dvh] w-full rounded-b-2xl
|
|
2065
|
-
bottom: 'inset-x-0 bottom-0 max-h-[80dvh] w-full rounded-t-2xl
|
|
2085
|
+
right: 'top-0 right-0 h-dvh w-full max-w-md rounded-l-2xl',
|
|
2086
|
+
left: 'top-0 left-0 h-dvh w-full max-w-md rounded-r-2xl',
|
|
2087
|
+
top: 'inset-x-0 top-0 max-h-[80dvh] w-full rounded-b-2xl',
|
|
2088
|
+
bottom: 'inset-x-0 bottom-0 max-h-[80dvh] w-full rounded-t-2xl'
|
|
2066
2089
|
},
|
|
2067
2090
|
isEntering: {
|
|
2068
2091
|
true: 'animate-in duration-300 ease-out'
|
|
@@ -2571,6 +2594,157 @@ function NumberField(props) {
|
|
|
2571
2594
|
});
|
|
2572
2595
|
}
|
|
2573
2596
|
|
|
2597
|
+
// Lives here, not in `translations`, because it interpolates the hidden range
|
|
2598
|
+
// — the static-string `translations` map doesn't support function values.
|
|
2599
|
+
const HIDDEN_PAGES_LABEL = {
|
|
2600
|
+
nb: (start, end)=>start === end ? `Skjuler side ${start}` : `Skjuler side ${start} til ${end}`,
|
|
2601
|
+
sv: (start, end)=>start === end ? `Döljer sida ${start}` : `Döljer sida ${start} till ${end}`,
|
|
2602
|
+
en: (start, end)=>start === end ? `Hides page ${start}` : `Hides pages ${start} to ${end}`
|
|
2603
|
+
};
|
|
2604
|
+
// Number of pages shown on each side of the current page on desktop. On
|
|
2605
|
+
// narrow containers, CSS hides the outermost visible pages via the
|
|
2606
|
+
// `data-outer` attribute so the entire pagination fits a 320px viewport
|
|
2607
|
+
// without changing the rendered DOM.
|
|
2608
|
+
const SIBLING_COUNT = 2;
|
|
2609
|
+
/**
|
|
2610
|
+
* Returns the page numbers (1-indexed) that should be rendered between the
|
|
2611
|
+
* always-visible first page and the next/prev buttons. Mirrors v1's ellipsis
|
|
2612
|
+
* behaviour: only a single (left) ellipsis is ever shown, and the last page
|
|
2613
|
+
* is not guaranteed to be rendered.
|
|
2614
|
+
*
|
|
2615
|
+
* Page 1 is filtered out because it's rendered separately as a fixed slot —
|
|
2616
|
+
* keeping it here would duplicate when the special-case extension lands the
|
|
2617
|
+
* window on it.
|
|
2618
|
+
*/ function getVisiblePages(currentPage, pageCount) {
|
|
2619
|
+
const end = Math.min(Math.max(2 + SIBLING_COUNT * 2, currentPage + SIBLING_COUNT), pageCount);
|
|
2620
|
+
let start = Math.max(Math.min(currentPage - SIBLING_COUNT, end - SIBLING_COUNT * 2), 1);
|
|
2621
|
+
// When `start` lands exactly SIBLING_COUNT pages past page 1, we have room
|
|
2622
|
+
// to render one extra page to the left without needing an ellipsis.
|
|
2623
|
+
if (start - SIBLING_COUNT === 0) {
|
|
2624
|
+
start = start - 1;
|
|
2625
|
+
}
|
|
2626
|
+
const pages = Array.from({
|
|
2627
|
+
length: end - start
|
|
2628
|
+
}, (_, i)=>start + i + 1);
|
|
2629
|
+
return pages.filter((p)=>p > 1);
|
|
2630
|
+
}
|
|
2631
|
+
/**
|
|
2632
|
+
* Returns the indices of the two visible pages farthest from `currentPage`.
|
|
2633
|
+
* These get marked with `data-outer` so the CSS container query can hide them
|
|
2634
|
+
* on narrow viewports, dropping the slot count from 8 to 6 without changing
|
|
2635
|
+
* the rendered DOM. Returns an empty set when there's nothing to gain.
|
|
2636
|
+
*/ function getOuterIndices(visiblePages, currentPage) {
|
|
2637
|
+
if (visiblePages.length <= 3) {
|
|
2638
|
+
return new Set();
|
|
2639
|
+
}
|
|
2640
|
+
return new Set(visiblePages.map((p, i)=>({
|
|
2641
|
+
i,
|
|
2642
|
+
distance: Math.abs(p - currentPage)
|
|
2643
|
+
})).sort((a, b)=>b.distance - a.distance).slice(0, 2).map((entry)=>entry.i));
|
|
2644
|
+
}
|
|
2645
|
+
const Pagination = (props)=>{
|
|
2646
|
+
const { page, count, getItemHref, onChange, className } = props;
|
|
2647
|
+
const locale = _useLocale();
|
|
2648
|
+
const currentPage = Math.max(1, Math.min(page, Math.max(1, count)));
|
|
2649
|
+
const pageCount = Math.max(1, count);
|
|
2650
|
+
const visiblePages = getVisiblePages(currentPage, pageCount);
|
|
2651
|
+
const outerIndices = getOuterIndices(visiblePages, currentPage);
|
|
2652
|
+
// Show the left ellipsis whenever there's a gap between page 1 and the
|
|
2653
|
+
// first visible page. This matches v1 for SIBLING_COUNT=2.
|
|
2654
|
+
const showLeftEllipsis = visiblePages.length > 0 && visiblePages[0] > 2;
|
|
2655
|
+
const canGoPrev = currentPage > 1;
|
|
2656
|
+
const canGoNext = currentPage < pageCount;
|
|
2657
|
+
// Prev/next switches element type (<a> with href ↔ <button> without) when
|
|
2658
|
+
// crossing a boundary. React replaces the DOM node, so the browser blurs
|
|
2659
|
+
// the focused element — restore it manually after the re-render.
|
|
2660
|
+
const prevButtonRef = useRef(null);
|
|
2661
|
+
const nextButtonRef = useRef(null);
|
|
2662
|
+
const restoreFocusToRef = useRef(null);
|
|
2663
|
+
useLayoutEffect(()=>{
|
|
2664
|
+
if (restoreFocusToRef.current === 'prev') {
|
|
2665
|
+
prevButtonRef.current?.focus();
|
|
2666
|
+
} else if (restoreFocusToRef.current === 'next') {
|
|
2667
|
+
nextButtonRef.current?.focus();
|
|
2668
|
+
}
|
|
2669
|
+
restoreFocusToRef.current = null;
|
|
2670
|
+
}, [
|
|
2671
|
+
currentPage
|
|
2672
|
+
]);
|
|
2673
|
+
return /*#__PURE__*/ jsxs("ol", {
|
|
2674
|
+
"aria-label": translations$1.pagination[locale],
|
|
2675
|
+
className: cx('gm-pagination', className),
|
|
2676
|
+
children: [
|
|
2677
|
+
/*#__PURE__*/ jsx("li", {
|
|
2678
|
+
children: /*#__PURE__*/ jsx(Button, {
|
|
2679
|
+
"aria-disabled": !canGoPrev,
|
|
2680
|
+
"aria-label": translations$1.previousPage[locale],
|
|
2681
|
+
color: "white",
|
|
2682
|
+
href: canGoPrev ? getItemHref(currentPage - 1) : undefined,
|
|
2683
|
+
isIconOnly: true,
|
|
2684
|
+
onPress: canGoPrev ? ()=>{
|
|
2685
|
+
restoreFocusToRef.current = 'prev';
|
|
2686
|
+
onChange?.(currentPage - 1);
|
|
2687
|
+
} : undefined,
|
|
2688
|
+
ref: prevButtonRef,
|
|
2689
|
+
children: /*#__PURE__*/ jsx(ChevronLeft, {})
|
|
2690
|
+
})
|
|
2691
|
+
}),
|
|
2692
|
+
/*#__PURE__*/ jsx(PageItem, {
|
|
2693
|
+
getItemHref: getItemHref,
|
|
2694
|
+
isActive: currentPage === 1,
|
|
2695
|
+
onChange: onChange,
|
|
2696
|
+
page: 1
|
|
2697
|
+
}),
|
|
2698
|
+
showLeftEllipsis && /*#__PURE__*/ jsxs("li", {
|
|
2699
|
+
"data-slot": "ellipsis",
|
|
2700
|
+
children: [
|
|
2701
|
+
/*#__PURE__*/ jsx("span", {
|
|
2702
|
+
"aria-hidden": "true",
|
|
2703
|
+
children: "…"
|
|
2704
|
+
}),
|
|
2705
|
+
/*#__PURE__*/ jsx("span", {
|
|
2706
|
+
children: HIDDEN_PAGES_LABEL[locale](2, visiblePages[0] - 1)
|
|
2707
|
+
})
|
|
2708
|
+
]
|
|
2709
|
+
}),
|
|
2710
|
+
visiblePages.map((p, i)=>/*#__PURE__*/ jsx(PageItem, {
|
|
2711
|
+
getItemHref: getItemHref,
|
|
2712
|
+
isActive: p === currentPage,
|
|
2713
|
+
isOuter: outerIndices.has(i),
|
|
2714
|
+
onChange: onChange,
|
|
2715
|
+
page: p
|
|
2716
|
+
}, p)),
|
|
2717
|
+
/*#__PURE__*/ jsx("li", {
|
|
2718
|
+
children: /*#__PURE__*/ jsx(Button, {
|
|
2719
|
+
"aria-disabled": !canGoNext,
|
|
2720
|
+
"aria-label": translations$1.nextPage[locale],
|
|
2721
|
+
color: "white",
|
|
2722
|
+
href: canGoNext ? getItemHref(currentPage + 1) : undefined,
|
|
2723
|
+
isIconOnly: true,
|
|
2724
|
+
onPress: canGoNext ? ()=>{
|
|
2725
|
+
restoreFocusToRef.current = 'next';
|
|
2726
|
+
onChange?.(currentPage + 1);
|
|
2727
|
+
} : undefined,
|
|
2728
|
+
ref: nextButtonRef,
|
|
2729
|
+
children: /*#__PURE__*/ jsx(ChevronRight, {})
|
|
2730
|
+
})
|
|
2731
|
+
})
|
|
2732
|
+
]
|
|
2733
|
+
});
|
|
2734
|
+
};
|
|
2735
|
+
const PageItem = ({ page, isActive, isOuter, getItemHref, onChange })=>{
|
|
2736
|
+
return /*#__PURE__*/ jsx("li", {
|
|
2737
|
+
"data-outer": isOuter || undefined,
|
|
2738
|
+
children: /*#__PURE__*/ jsx(Button, {
|
|
2739
|
+
"aria-current": isActive ? 'page' : undefined,
|
|
2740
|
+
color: isActive ? 'blue' : 'white',
|
|
2741
|
+
href: getItemHref(page),
|
|
2742
|
+
onPress: ()=>onChange?.(page),
|
|
2743
|
+
children: page
|
|
2744
|
+
})
|
|
2745
|
+
});
|
|
2746
|
+
};
|
|
2747
|
+
|
|
2574
2748
|
const defaultClasses = cx([
|
|
2575
2749
|
'relative -ml-2.5 inline-flex max-w-fit cursor-pointer items-start gap-4 py-2.5 pl-2.5 leading-7',
|
|
2576
2750
|
// the radio button itself
|
|
@@ -3395,6 +3569,48 @@ function TextField(props) {
|
|
|
3395
3569
|
});
|
|
3396
3570
|
}
|
|
3397
3571
|
|
|
3572
|
+
/** Root of the toggletip. Wraps a `<ToggletipTrigger>` and a `<ToggletipContent>`. */ const Toggletip = (props)=>/*#__PURE__*/ jsx(DialogTrigger$1, {
|
|
3573
|
+
...props
|
|
3574
|
+
});
|
|
3575
|
+
/**
|
|
3576
|
+
* The button that toggles the toggletip. Needs an accessible name — `aria-label`
|
|
3577
|
+
* for an icon, or the visible text for a definition term.
|
|
3578
|
+
*/ const ToggletipTrigger = ({ variant, className, ...restProps })=>/*#__PURE__*/ jsx(Button$1, {
|
|
3579
|
+
...restProps,
|
|
3580
|
+
className: cx('gm-toggletip-trigger', className),
|
|
3581
|
+
"data-variant": variant
|
|
3582
|
+
});
|
|
3583
|
+
/** The popover content of the toggletip: a `Dialog` (with `aria-label`) and a close button. */ const ToggletipContent = ({ 'aria-label': ariaLabel, children, className, ...restProps })=>{
|
|
3584
|
+
const locale = _useLocale();
|
|
3585
|
+
return /*#__PURE__*/ jsxs(Popover, {
|
|
3586
|
+
...restProps,
|
|
3587
|
+
className: cx('gm-toggletip', className),
|
|
3588
|
+
offset: 8,
|
|
3589
|
+
children: [
|
|
3590
|
+
/*#__PURE__*/ jsx(OverlayArrow, {
|
|
3591
|
+
"data-slot": "toggletip-arrow"
|
|
3592
|
+
}),
|
|
3593
|
+
/*#__PURE__*/ jsx(Dialog$1, {
|
|
3594
|
+
"aria-label": ariaLabel,
|
|
3595
|
+
"data-slot": "toggletip-dialog",
|
|
3596
|
+
children: ({ close })=>/*#__PURE__*/ jsxs(Fragment, {
|
|
3597
|
+
children: [
|
|
3598
|
+
/*#__PURE__*/ jsx(Button, {
|
|
3599
|
+
"aria-label": translations$1.close[locale],
|
|
3600
|
+
color: "white",
|
|
3601
|
+
isIconOnly: true,
|
|
3602
|
+
onPress: close,
|
|
3603
|
+
variant: "tertiary",
|
|
3604
|
+
children: /*#__PURE__*/ jsx(Close, {})
|
|
3605
|
+
}),
|
|
3606
|
+
children
|
|
3607
|
+
]
|
|
3608
|
+
})
|
|
3609
|
+
})
|
|
3610
|
+
]
|
|
3611
|
+
});
|
|
3612
|
+
};
|
|
3613
|
+
|
|
3398
3614
|
const VideoLoop = ({ src, format, alt, className })=>{
|
|
3399
3615
|
// Control the video playback state, so that the user can pause and play the video at will, also control the video autoplay
|
|
3400
3616
|
const [shouldPlay, setShouldPlay] = useState(false);
|
|
@@ -3476,4 +3692,4 @@ const VideoLoop = ({ src, format, alt, className })=>{
|
|
|
3476
3692
|
});
|
|
3477
3693
|
};
|
|
3478
3694
|
|
|
3479
|
-
export { Accordion, AccordionItem, Alertbox, Avatar, Backlink, Badge, Breadcrumb, Breadcrumbs, Button, ButtonContext, Caption, Card, CardLink, Checkbox, CheckboxGroup, Combobox, ListBoxHeader as ComboboxHeader, ListBoxItem as ComboboxItem, ListBoxSection as ComboboxSection, Content, ContentContext, DateFormatter, Description, Disclosure, DisclosureButton, DisclosurePanel, DisclosureStateContext, ErrorMessage, Footer, GrunnmurenProvider, Heading, HeadingContext, Label, Link, LinkList, LinkListContainer, LinkListContext, LinkListItem, Media, MediaContext, NumberField, Radio, RadioGroup, Select, ListBoxHeader as SelectHeader, ListBoxItem as SelectItem, ListBoxSection as SelectSection, Tab, TabList, TabPanel, Tabs, Tag, TagGroup, TagList, TextArea, TextField, Carousel as UNSAFE_Carousel, CarouselButton as UNSAFE_CarouselButton, CarouselContext as UNSAFE_CarouselContext, CarouselControls as UNSAFE_CarouselControls, CarouselItem as UNSAFE_CarouselItem, CarouselItems as UNSAFE_CarouselItems, CarouselItemsContainer as UNSAFE_CarouselItemsContainer, Dialog as UNSAFE_Dialog, DialogTrigger as UNSAFE_DialogTrigger, Drawer as UNSAFE_Drawer, FileUpload as UNSAFE_FileUpload,
|
|
3695
|
+
export { Accordion, AccordionItem, Alertbox, Avatar, Backlink, Badge, Breadcrumb, Breadcrumbs, Button, ButtonContext, Caption, Card, CardLink, Checkbox, CheckboxGroup, Combobox, ListBoxHeader as ComboboxHeader, ListBoxItem as ComboboxItem, ListBoxSection as ComboboxSection, Content, ContentContext, DateFormatter, Description, Disclosure, DisclosureButton, DisclosurePanel, DisclosureStateContext, ErrorMessage, Footer, GrunnmurenProvider, Heading, HeadingContext, Hero, HeroContext, Label, Link, LinkList, LinkListContainer, LinkListContext, LinkListItem, Media, MediaContext, NumberField, Radio, RadioGroup, Select, ListBoxHeader as SelectHeader, ListBoxItem as SelectItem, ListBoxSection as SelectSection, Tab, TabList, TabPanel, Tabs, Tag, TagGroup, TagList, TextArea, TextField, Carousel as UNSAFE_Carousel, CarouselButton as UNSAFE_CarouselButton, CarouselContext as UNSAFE_CarouselContext, CarouselControls as UNSAFE_CarouselControls, CarouselItem as UNSAFE_CarouselItem, CarouselItems as UNSAFE_CarouselItems, CarouselItemsContainer as UNSAFE_CarouselItemsContainer, Dialog as UNSAFE_Dialog, DialogTrigger as UNSAFE_DialogTrigger, Drawer as UNSAFE_Drawer, FileUpload as UNSAFE_FileUpload, Modal as UNSAFE_Modal, Pagination as UNSAFE_Pagination, ResizableTableContainer as UNSAFE_ResizableTableContainer, Step as UNSAFE_Step, Stepper as UNSAFE_Stepper, Table as UNSAFE_Table, TableBody as UNSAFE_TableBody, TableCell as UNSAFE_TableCell, TableColumn as UNSAFE_TableColumn, TableColumnResizer as UNSAFE_TableColumnResizer, UNSAFE_TableContainer, TableHeader as UNSAFE_TableHeader, TableRow as UNSAFE_TableRow, Toggletip as UNSAFE_Toggletip, ToggletipContent as UNSAFE_ToggletipContent, ToggletipTrigger as UNSAFE_ToggletipTrigger, VideoLoop, _useLocale as useLocale };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@obosbbl/grunnmuren-react",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.8.1",
|
|
4
4
|
"description": "Grunnmuren components in React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -33,7 +33,8 @@
|
|
|
33
33
|
"tailwindcss": "4.2.2"
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|
|
36
|
-
"react": "^19"
|
|
36
|
+
"react": "^19",
|
|
37
|
+
"@obosbbl/grunnmuren-tailwind": "^2.4.12"
|
|
37
38
|
},
|
|
38
39
|
"scripts": {
|
|
39
40
|
"build": "bunchee"
|