@obosbbl/grunnmuren-react 3.8.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/dist/__stories__/form-validation.stories.d.cts +5 -5
- package/dist/__stories__/form-validation.stories.d.ts +5 -5
- 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.d.cts +4 -4
- package/dist/__stories__/layout.stories.d.ts +4 -4
- package/dist/__stories__/typography.stories.d.cts +9 -9
- package/dist/__stories__/typography.stories.d.ts +9 -9
- package/dist/index.d.mts +103 -74
- package/dist/index.mjs +44 -2
- package/package.json +2 -2
|
@@ -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 };
|
|
@@ -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 };
|
|
@@ -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 };
|
|
@@ -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;
|
|
@@ -439,7 +439,7 @@ type HeadingProps = Omit<HTMLProps<HTMLHeadingElement>, 'size'> & VariantProps<t
|
|
|
439
439
|
};
|
|
440
440
|
declare const HeadingContext: react.Context<ContextValue<Partial<HeadingProps>, HTMLHeadingElement>>;
|
|
441
441
|
declare const headingVariants: (props?: ({
|
|
442
|
-
size?: "
|
|
442
|
+
size?: "xl" | "l" | "m" | "s" | "xs" | undefined;
|
|
443
443
|
} & ({
|
|
444
444
|
class?: cva.ClassValue;
|
|
445
445
|
className?: never;
|
|
@@ -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,7 @@ 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
663
|
|
|
664
664
|
type PaginationProps = {
|
|
665
665
|
/** The current page (1-indexed). */
|
|
@@ -678,7 +678,7 @@ type PaginationProps = {
|
|
|
678
678
|
/** Additional class name for the root `<ol>`. */
|
|
679
679
|
className?: string;
|
|
680
680
|
};
|
|
681
|
-
declare const Pagination: (props: PaginationProps) =>
|
|
681
|
+
declare const Pagination: (props: PaginationProps) => react.JSX.Element;
|
|
682
682
|
|
|
683
683
|
type RadioProps = {
|
|
684
684
|
children: React.ReactNode;
|
|
@@ -691,7 +691,7 @@ type RadioProps = {
|
|
|
691
691
|
/** Ref for the element. */
|
|
692
692
|
ref?: Ref<HTMLLabelElement>;
|
|
693
693
|
} & Omit<RadioProps$1, 'isDisabled' | 'children' | 'style'>;
|
|
694
|
-
declare function Radio(props: RadioProps):
|
|
694
|
+
declare function Radio(props: RadioProps): react.JSX.Element;
|
|
695
695
|
|
|
696
696
|
type RadioGroupProps = {
|
|
697
697
|
children: React.ReactNode;
|
|
@@ -708,7 +708,7 @@ type RadioGroupProps = {
|
|
|
708
708
|
/** Ref for the element. */
|
|
709
709
|
ref?: Ref<HTMLDivElement>;
|
|
710
710
|
} & Omit<RadioGroupProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style' | 'orientation'>;
|
|
711
|
-
declare function RadioGroup(props: RadioGroupProps):
|
|
711
|
+
declare function RadioGroup(props: RadioGroupProps): react.JSX.Element;
|
|
712
712
|
|
|
713
713
|
type SelectProps<T extends object> = {
|
|
714
714
|
children: React.ReactNode;
|
|
@@ -727,7 +727,7 @@ type SelectProps<T extends object> = {
|
|
|
727
727
|
/** Ref for the button element. */
|
|
728
728
|
ref?: Ref<HTMLButtonElement>;
|
|
729
729
|
} & Omit<SelectProps$1<T>, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
730
|
-
declare function Select<T extends object>(props: SelectProps<T>):
|
|
730
|
+
declare function Select<T extends object>(props: SelectProps<T>): react.JSX.Element;
|
|
731
731
|
|
|
732
732
|
type StepperProps = HTMLAttributes<HTMLDivElement> & {
|
|
733
733
|
children: React.ReactNode;
|
|
@@ -736,7 +736,7 @@ type StepperProps = HTMLAttributes<HTMLDivElement> & {
|
|
|
736
736
|
/** Handler that is called when the step changes. */
|
|
737
737
|
onStepChange?: (step: number) => void;
|
|
738
738
|
};
|
|
739
|
-
declare const Stepper: ({ children, activeStep, onStepChange, ...restProps }: StepperProps) =>
|
|
739
|
+
declare const Stepper: ({ children, activeStep, onStepChange, ...restProps }: StepperProps) => react.JSX.Element;
|
|
740
740
|
type StepProps = HTMLProps<HTMLLIElement> & {
|
|
741
741
|
/**
|
|
742
742
|
* The state fo the step, whether the step is completed or not.
|
|
@@ -752,7 +752,7 @@ type StepProps = HTMLProps<HTMLLIElement> & {
|
|
|
752
752
|
/** @private */
|
|
753
753
|
'~stepIndex'?: number;
|
|
754
754
|
};
|
|
755
|
-
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;
|
|
756
756
|
|
|
757
757
|
type TableVariant = 'default' | 'zebra-striped';
|
|
758
758
|
type TableProps = Omit<TableProps$1, 'aria-label' | 'aria-labelledby'> & RefAttributes<HTMLTableElement> & {
|
|
@@ -782,25 +782,25 @@ type ResizableTableContainerProps = ResizableTableContainerProps$1;
|
|
|
782
782
|
/**
|
|
783
783
|
* A container component for displaying tabular data with horizontal scrolling support.
|
|
784
784
|
*/
|
|
785
|
-
declare function Table(props: TableProps):
|
|
785
|
+
declare function Table(props: TableProps): react.JSX.Element;
|
|
786
786
|
/**
|
|
787
787
|
* Container that enables column resizing and horizontal scrolling for the
|
|
788
788
|
* nested <Table>. Use when you want resizable columns or want to apply
|
|
789
789
|
* `maxWidth`/`minWidth` truncation on columns.
|
|
790
790
|
*/
|
|
791
|
-
declare function ResizableTableContainer({ className, children, ...restProps }: ResizableTableContainerProps):
|
|
791
|
+
declare function ResizableTableContainer({ className, children, ...restProps }: ResizableTableContainerProps): react.JSX.Element;
|
|
792
792
|
/**
|
|
793
793
|
* Container for table column headers.
|
|
794
794
|
*/
|
|
795
|
-
declare function TableHeader({ className, children, ...restProps }: TableHeaderProps):
|
|
796
|
-
declare function TableColumn(props: TableColumnProps):
|
|
797
|
-
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;
|
|
798
798
|
/**
|
|
799
799
|
* Container for table rows.
|
|
800
800
|
*/
|
|
801
|
-
declare function TableBody({ className, children, ...restProps }: TableBodyProps):
|
|
802
|
-
declare function TableRow(props: TableRowProps):
|
|
803
|
-
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;
|
|
804
804
|
/** @deprecated Use `UNSAFE_ResizableTableContainer` instead. */
|
|
805
805
|
declare const UNSAFE_TableContainer: typeof ResizableTableContainer;
|
|
806
806
|
/** @deprecated Use `UNSAFE_ResizableTableContainerProps` instead. */
|
|
@@ -837,19 +837,19 @@ type TabPanelProps = Omit<TabPanelProps$1, 'className'> & RefAttributes<HTMLDivE
|
|
|
837
837
|
* A container component that organizes content into multiple sections
|
|
838
838
|
* and allows users to navigate between them.
|
|
839
839
|
*/
|
|
840
|
-
declare function Tabs(props: TabsProps):
|
|
840
|
+
declare function Tabs(props: TabsProps): react.JSX.Element;
|
|
841
841
|
/**
|
|
842
842
|
* A container component for Tab components within Tabs.
|
|
843
843
|
*/
|
|
844
|
-
declare function TabList({ className, children, ...restProps }: TabListProps):
|
|
844
|
+
declare function TabList({ className, children, ...restProps }: TabListProps): react.JSX.Element;
|
|
845
845
|
/**
|
|
846
846
|
* An individual tab that can be selected to display its associated content.
|
|
847
847
|
*/
|
|
848
|
-
declare function Tab(props: TabProps):
|
|
848
|
+
declare function Tab(props: TabProps): react.JSX.Element;
|
|
849
849
|
/**
|
|
850
850
|
* The content area that displays the selected tab's content.
|
|
851
851
|
*/
|
|
852
|
-
declare function TabPanel(props: TabPanelProps):
|
|
852
|
+
declare function TabPanel(props: TabPanelProps): react.JSX.Element;
|
|
853
853
|
|
|
854
854
|
type TagGroupProps = Omit<TagGroupProps$1, 'className'> & RefAttributes<HTMLDivElement> & {
|
|
855
855
|
/**
|
|
@@ -882,15 +882,15 @@ type TagProps = Omit<TagProps$1, 'className'> & RefAttributes<HTMLDivElement> &
|
|
|
882
882
|
/**
|
|
883
883
|
* A group component for Tag components that enables selection and organization of options.
|
|
884
884
|
*/
|
|
885
|
-
declare function TagGroup(props: TagGroupProps):
|
|
885
|
+
declare function TagGroup(props: TagGroupProps): react.JSX.Element;
|
|
886
886
|
/**
|
|
887
887
|
* A container component for Tag components within a TagGroup.
|
|
888
888
|
*/
|
|
889
|
-
declare function TagList(props: TagListProps):
|
|
889
|
+
declare function TagList(props: TagListProps): react.JSX.Element;
|
|
890
890
|
/**
|
|
891
891
|
* Interactive tag component for selections, filtering, and categorization.
|
|
892
892
|
*/
|
|
893
|
-
declare function Tag(props: TagProps):
|
|
893
|
+
declare function Tag(props: TagProps): react.JSX.Element;
|
|
894
894
|
|
|
895
895
|
type TextAreaProps = {
|
|
896
896
|
/** Additional CSS className for the element. */
|
|
@@ -913,7 +913,7 @@ type TextAreaProps = {
|
|
|
913
913
|
/** Ref for the textarea element. */
|
|
914
914
|
ref?: Ref<HTMLTextAreaElement>;
|
|
915
915
|
} & Omit<TextFieldProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
916
|
-
declare function TextArea(props: TextAreaProps):
|
|
916
|
+
declare function TextArea(props: TextAreaProps): react.JSX.Element;
|
|
917
917
|
|
|
918
918
|
type TextFieldProps = {
|
|
919
919
|
/** Additional CSS className for the element. */
|
|
@@ -944,7 +944,36 @@ type TextFieldProps = {
|
|
|
944
944
|
/** Ref for the input element. */
|
|
945
945
|
ref?: Ref<HTMLInputElement>;
|
|
946
946
|
} & Omit<TextFieldProps$1, 'className' | 'isReadOnly' | 'isDisabled' | 'children' | 'style'>;
|
|
947
|
-
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;
|
|
948
977
|
|
|
949
978
|
type VideoLoopProps = {
|
|
950
979
|
/** The video url */
|
|
@@ -960,7 +989,7 @@ type VideoLoopProps = {
|
|
|
960
989
|
alt?: string;
|
|
961
990
|
className?: string;
|
|
962
991
|
};
|
|
963
|
-
declare const VideoLoop: ({ src, format, alt, className }: VideoLoopProps) =>
|
|
992
|
+
declare const VideoLoop: ({ src, format, alt, className }: VideoLoopProps) => react.JSX.Element;
|
|
964
993
|
|
|
965
|
-
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, VideoLoop, _useLocale as useLocale };
|
|
966
|
-
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 };
|
|
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
|
@@ -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';
|
|
@@ -3569,6 +3569,48 @@ function TextField(props) {
|
|
|
3569
3569
|
});
|
|
3570
3570
|
}
|
|
3571
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
|
+
|
|
3572
3614
|
const VideoLoop = ({ src, format, alt, className })=>{
|
|
3573
3615
|
// Control the video playback state, so that the user can pause and play the video at will, also control the video autoplay
|
|
3574
3616
|
const [shouldPlay, setShouldPlay] = useState(false);
|
|
@@ -3650,4 +3692,4 @@ const VideoLoop = ({ src, format, alt, className })=>{
|
|
|
3650
3692
|
});
|
|
3651
3693
|
};
|
|
3652
3694
|
|
|
3653
|
-
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, VideoLoop, _useLocale as useLocale };
|
|
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.8.
|
|
3
|
+
"version": "3.8.1",
|
|
4
4
|
"description": "Grunnmuren components in React",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"repository": {
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
},
|
|
35
35
|
"peerDependencies": {
|
|
36
36
|
"react": "^19",
|
|
37
|
-
"@obosbbl/grunnmuren-tailwind": "^2.4.
|
|
37
|
+
"@obosbbl/grunnmuren-tailwind": "^2.4.12"
|
|
38
38
|
},
|
|
39
39
|
"scripts": {
|
|
40
40
|
"build": "bunchee"
|