@obosbbl/grunnmuren-react 1.14.9 → 2.0.0

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.
Files changed (110) hide show
  1. package/LICENSE +1 -1
  2. package/dist/Button/Button.d.mts +71 -0
  3. package/dist/Button/Button.d.ts +70 -15
  4. package/dist/Button/Button.mjs +86 -0
  5. package/package.json +21 -44
  6. package/README.md +0 -45
  7. package/dist/Accordion/Accordion.d.ts +0 -27
  8. package/dist/Accordion/index.d.ts +0 -1
  9. package/dist/Accordion/stories/Accordion.stories.d.ts +0 -9
  10. package/dist/Alert/Alert.d.ts +0 -9
  11. package/dist/Alert/index.d.ts +0 -1
  12. package/dist/Alert/stories/Alert.stories.d.ts +0 -5
  13. package/dist/Banner/Banner.d.ts +0 -11
  14. package/dist/Banner/BannerImage.d.ts +0 -6
  15. package/dist/Banner/index.d.ts +0 -2
  16. package/dist/Banner/stories/Banner.stories.d.ts +0 -5
  17. package/dist/Button/ButtonColorContext.d.ts +0 -3
  18. package/dist/Button/index.d.ts +0 -2
  19. package/dist/Button/stories/Button.stories.d.ts +0 -31
  20. package/dist/Campaign/Campaign.d.ts +0 -26
  21. package/dist/Campaign/index.d.ts +0 -1
  22. package/dist/Campaign/stories/Campaign.stories.d.ts +0 -9
  23. package/dist/Card/Card.d.ts +0 -8
  24. package/dist/Card/CardContent.d.ts +0 -5
  25. package/dist/Card/CardImage.d.ts +0 -7
  26. package/dist/Card/CardLinkOverlay.d.ts +0 -4
  27. package/dist/Card/CardList.d.ts +0 -7
  28. package/dist/Card/index.d.ts +0 -5
  29. package/dist/Card/stories/Card.stories.d.ts +0 -34
  30. package/dist/Checkbox/Checkbox.d.ts +0 -13
  31. package/dist/Checkbox/index.d.ts +0 -1
  32. package/dist/Checkbox/stories/Checkbox.stories.d.ts +0 -8
  33. package/dist/Chip/Chip.d.ts +0 -10
  34. package/dist/Chip/index.d.ts +0 -1
  35. package/dist/Chip/stories/Chip.stories.d.ts +0 -5
  36. package/dist/Footer/Footer.d.ts +0 -7
  37. package/dist/Footer/index.d.ts +0 -1
  38. package/dist/Footer/stories/Footer.stories.d.ts +0 -5
  39. package/dist/Form/Form.d.ts +0 -9
  40. package/dist/Form/FormError.d.ts +0 -4
  41. package/dist/Form/FormErrorMessage.d.ts +0 -5
  42. package/dist/Form/FormHelperText.d.ts +0 -5
  43. package/dist/Form/FormLabel.d.ts +0 -7
  44. package/dist/Form/FormSuccess.d.ts +0 -6
  45. package/dist/Form/MultiStep/FormStep.d.ts +0 -17
  46. package/dist/Form/MultiStep/FormStepContext.d.ts +0 -20
  47. package/dist/Form/MultiStep/FormStepHeader.d.ts +0 -18
  48. package/dist/Form/MultiStep/index.d.ts +0 -3
  49. package/dist/Form/index.d.ts +0 -7
  50. package/dist/Form/stories/Form.stories.d.ts +0 -14
  51. package/dist/Hero/Hero.d.ts +0 -21
  52. package/dist/Hero/HeroActions.d.ts +0 -7
  53. package/dist/Hero/HeroContent.d.ts +0 -9
  54. package/dist/Hero/HeroImage.d.ts +0 -9
  55. package/dist/Hero/index.d.ts +0 -4
  56. package/dist/Hero/stories/Hero.stories.d.ts +0 -33
  57. package/dist/Hero/utils.d.ts +0 -2
  58. package/dist/Input/Input.d.ts +0 -11
  59. package/dist/Input/index.d.ts +0 -1
  60. package/dist/Input/stories/Input.stories.d.ts +0 -8
  61. package/dist/Link/Link.d.ts +0 -8
  62. package/dist/Link/index.d.ts +0 -1
  63. package/dist/Navbar/Navbar.d.ts +0 -6
  64. package/dist/Navbar/NavbarCollapsible.d.ts +0 -6
  65. package/dist/Navbar/NavbarContent.d.ts +0 -7
  66. package/dist/Navbar/NavbarContext.d.ts +0 -6
  67. package/dist/Navbar/NavbarExpandedMobileContent.d.ts +0 -9
  68. package/dist/Navbar/NavbarItem.d.ts +0 -7
  69. package/dist/Navbar/NavbarItems.d.ts +0 -6
  70. package/dist/Navbar/NavbarMenuButton.d.ts +0 -4
  71. package/dist/Navbar/index.d.ts +0 -6
  72. package/dist/Navbar/stories/Navbar.stories.d.ts +0 -5
  73. package/dist/Pagination/Pagination.d.ts +0 -23
  74. package/dist/Pagination/index.d.ts +0 -1
  75. package/dist/Pagination/stories/Pagination.stories.d.ts +0 -24
  76. package/dist/Radio/Radio.d.ts +0 -5
  77. package/dist/Radio/RadioContext.d.ts +0 -10
  78. package/dist/Radio/RadioGroup.d.ts +0 -20
  79. package/dist/Radio/index.d.ts +0 -2
  80. package/dist/Radio/stories/Radio.stories.d.ts +0 -12
  81. package/dist/Select/Select.d.ts +0 -21
  82. package/dist/Select/SelectPlain.d.ts +0 -15
  83. package/dist/Select/index.d.ts +0 -1
  84. package/dist/Select/stories/Select.stories.d.ts +0 -26
  85. package/dist/Snackbar/Snackbar.d.ts +0 -8
  86. package/dist/Snackbar/SnackbarButton.d.ts +0 -6
  87. package/dist/Snackbar/SnackbarContent.d.ts +0 -5
  88. package/dist/Snackbar/index.d.ts +0 -3
  89. package/dist/Snackbar/stories/Snackbar.stories.d.ts +0 -9
  90. package/dist/StepList/StepList.d.ts +0 -25
  91. package/dist/StepList/index.d.ts +0 -1
  92. package/dist/StepList/stories/StepList.stories.d.ts +0 -19
  93. package/dist/TextArea/TextArea.d.ts +0 -15
  94. package/dist/TextArea/index.d.ts +0 -1
  95. package/dist/TextArea/stories/TextArea.stories.d.ts +0 -8
  96. package/dist/TextField/TextField.d.ts +0 -19
  97. package/dist/TextField/index.d.ts +0 -1
  98. package/dist/TextField/stories/TextField.stories.d.ts +0 -9
  99. package/dist/__stories__/Icon.stories.d.ts +0 -8
  100. package/dist/__stories__/PageLayout.stories.d.ts +0 -5
  101. package/dist/__stories__/Typography.stories.d.ts +0 -9
  102. package/dist/grunnmuren.mjs +0 -1552
  103. package/dist/hooks/index.d.ts +0 -5
  104. package/dist/hooks/useBlockBackgroundColor.d.ts +0 -2
  105. package/dist/hooks/useFallbackId.d.ts +0 -4
  106. package/dist/hooks/useFormControlValidity.d.ts +0 -15
  107. package/dist/hooks/usePrefersReducedMotion.d.ts +0 -1
  108. package/dist/hooks/useScreenMaxWidthMd.d.ts +0 -1
  109. package/dist/index.d.ts +0 -22
  110. package/dist/utils/index.d.ts +0 -2
@@ -1 +0,0 @@
1
- export * from './Checkbox';
@@ -1,8 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- };
7
- export default metadata;
8
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
@@ -1,10 +0,0 @@
1
- /// <reference types="react" />
2
- export type ChipColor = 'sky' | 'mint' | 'red-light' | 'orange-light' | 'green-light' | 'blue-light';
3
- export interface ChipProps {
4
- icon?: React.ReactNode;
5
- color?: ChipColor;
6
- className?: string;
7
- children: React.ReactNode;
8
- variant?: 'outline' | 'filled';
9
- }
10
- export declare const Chip: (props: ChipProps) => import("react/jsx-runtime").JSX.Element;
@@ -1 +0,0 @@
1
- export * from './Chip';
@@ -1,5 +0,0 @@
1
- declare const _default: {
2
- title: string;
3
- };
4
- export default _default;
5
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- interface FooterProps {
3
- className?: string;
4
- children: React.ReactNode;
5
- }
6
- export declare const Footer: (props: FooterProps) => import("react/jsx-runtime").JSX.Element;
7
- export {};
@@ -1 +0,0 @@
1
- export * from './Footer';
@@ -1,5 +0,0 @@
1
- declare const _default: {
2
- title: string;
3
- };
4
- export default _default;
5
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
@@ -1,9 +0,0 @@
1
- /// <reference types="react" />
2
- export interface FormProps extends React.ComponentPropsWithoutRef<'form'> {
3
- children: React.ReactNode;
4
- heading?: string;
5
- }
6
- export declare const Form: (props: FormProps) => import("react/jsx-runtime").JSX.Element;
7
- export interface FormHeadingProps extends React.ComponentPropsWithoutRef<'div'> {
8
- }
9
- export declare const FormHeading: (props: FormHeadingProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,4 +0,0 @@
1
- /// <reference types="react" />
2
- export interface FormErrorProps extends React.ComponentPropsWithoutRef<'div'> {
3
- }
4
- export declare const FormError: (props: FormErrorProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- export interface FormErrorMessageProps extends React.ComponentPropsWithoutRef<'div'> {
3
- children: React.ReactNode;
4
- }
5
- export declare const FormErrorMessage: (props: FormErrorMessageProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- export interface FormHelperTextProps extends React.ComponentPropsWithoutRef<'div'> {
3
- children: React.ReactNode;
4
- }
5
- export declare const FormHelperText: (props: FormHelperTextProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- export interface LabelProps extends React.ComponentPropsWithoutRef<'label'> {
3
- children: React.ReactNode;
4
- isRequired?: boolean;
5
- isInvalid?: boolean;
6
- }
7
- export declare const FormLabel: (props: LabelProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export interface FormSuccessProps extends React.ComponentPropsWithoutRef<'div'> {
3
- heading?: string;
4
- text?: string;
5
- }
6
- export declare const FormSuccess: (props: FormSuccessProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,17 +0,0 @@
1
- import { FormEventHandler } from 'react';
2
- import { FormProps } from '..';
3
- interface FormStepProps extends FormProps {
4
- step: number;
5
- heading: string;
6
- formStatus: FormStatus;
7
- onSubmit: FormEventHandler<HTMLFormElement>;
8
- onHeaderClick?: (step: number) => void;
9
- }
10
- export interface FormStepData<T> {
11
- formId: string;
12
- status: FormStatus;
13
- formData?: T;
14
- }
15
- export type FormStatus = 'blank' | 'completed';
16
- export declare const FormStep: (props: FormStepProps) => import("react/jsx-runtime").JSX.Element;
17
- export {};
@@ -1,20 +0,0 @@
1
- /// <reference types="react" />
2
- export type FieldValues = Record<string, unknown>;
3
- export declare function useFormContext(): {
4
- activeStep: number;
5
- formData: any;
6
- setActiveStep: (step: number) => void;
7
- };
8
- export declare function useFormStepContext<FormStepData extends FieldValues>(formStep: number): {
9
- isActive: boolean;
10
- activeStep: number;
11
- setActiveStep: (step: number) => void;
12
- previousFormStep: () => Promise<void>;
13
- nextFormStep: () => void;
14
- submitAndNextFormStep: (formValues: FormStepData) => void;
15
- setFormData: (formValues: FormStepData) => void;
16
- formData: any;
17
- };
18
- export declare function FormStepProvider({ children }: {
19
- children: React.ReactNode;
20
- }): import("react/jsx-runtime").JSX.Element;
@@ -1,18 +0,0 @@
1
- import { ReactNode } from 'react';
2
- import { FormStatus } from './FormStep';
3
- export interface FormStepHeaderProps {
4
- className?: string;
5
- collapsed: boolean;
6
- step: number;
7
- onClick: (e: React.MouseEvent<HTMLButtonElement, MouseEvent>) => void;
8
- children: ReactNode;
9
- formStatus: FormStatus;
10
- }
11
- export declare const FormStepHeader: (props: FormStepHeaderProps) => import("react/jsx-runtime").JSX.Element;
12
- export interface FormStepHeaderContentProps {
13
- collapsed: boolean;
14
- step: number;
15
- children: ReactNode;
16
- formStatus: FormStatus;
17
- }
18
- export declare const FormStepHeaderContent: (props: FormStepHeaderContentProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,3 +0,0 @@
1
- export * from './FormStep';
2
- export * from './FormStepContext';
3
- export * from './FormStepHeader';
@@ -1,7 +0,0 @@
1
- export * from './Form';
2
- export * from './FormError';
3
- export * from './FormErrorMessage';
4
- export * from './FormHelperText';
5
- export * from './FormLabel';
6
- export * from './FormSuccess';
7
- export * from './MultiStep';
@@ -1,14 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- };
7
- export default metadata;
8
- export declare const Label: () => import("react/jsx-runtime").JSX.Element;
9
- export declare const ErrorMessage: () => import("react/jsx-runtime").JSX.Element;
10
- export declare const Success: () => import("react/jsx-runtime").JSX.Element;
11
- export declare const HelperText: () => import("react/jsx-runtime").JSX.Element;
12
- export declare const Form: () => import("react/jsx-runtime").JSX.Element;
13
- export declare const FormError: () => import("react/jsx-runtime").JSX.Element;
14
- export declare const MultiStep: () => import("react/jsx-runtime").JSX.Element;
@@ -1,21 +0,0 @@
1
- /// <reference types="react" />
2
- export declare const HeroContext: import("react").Context<{
3
- bgColor: HeroColor;
4
- contentPosition: HeroContentPosition;
5
- hasImage: boolean;
6
- }>;
7
- export type HeroColor = 'green' | 'blue' | 'white';
8
- export type HeroContentPosition = 'below-center' | 'below-left' | 'top-left' | 'bottom-left' | 'top-right' | 'bottom-right' | 'center' | 'vertical-split';
9
- export interface HeroProps extends React.ComponentPropsWithoutRef<'div'> {
10
- /** @default white */
11
- bgColor?: HeroColor;
12
- className?: string;
13
- children: React.ReactNode;
14
- /** Positioning of the content relative to the image. Only affects wider screens
15
- * @default below-center
16
- */
17
- contentPosition?: HeroContentPosition;
18
- /** Instance of HeroImage */
19
- image?: React.ReactNode;
20
- }
21
- export declare const Hero: import("react").ForwardRefExoticComponent<HeroProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- interface HeroActionsProps extends React.ComponentPropsWithoutRef<'div'> {
3
- className?: string;
4
- children?: React.ReactNode;
5
- }
6
- export declare const HeroActions: import("react").ForwardRefExoticComponent<HeroActionsProps & import("react").RefAttributes<HTMLDivElement>>;
7
- export {};
@@ -1,9 +0,0 @@
1
- /// <reference types="react" />
2
- interface HeroContentProps extends React.ComponentPropsWithoutRef<'div'> {
3
- children?: React.ReactNode;
4
- className?: string;
5
- heading: string;
6
- description?: string;
7
- }
8
- export declare const HeroContent: import("react").ForwardRefExoticComponent<HeroContentProps & import("react").RefAttributes<HTMLDivElement>>;
9
- export {};
@@ -1,9 +0,0 @@
1
- /// <reference types="react" />
2
- interface HeroImageProps {
3
- src: string;
4
- mdSrc: string;
5
- alt?: string;
6
- className?: string;
7
- }
8
- export declare const HeroImage: import("react").ForwardRefExoticComponent<HeroImageProps & import("react").RefAttributes<HTMLPictureElement>>;
9
- export {};
@@ -1,4 +0,0 @@
1
- export * from './Hero';
2
- export * from './HeroImage';
3
- export * from './HeroContent';
4
- export * from './HeroActions';
@@ -1,33 +0,0 @@
1
- import { HeroProps } from '../../';
2
- declare const metadata: {
3
- title: string;
4
- argTypes: {
5
- contentPosition: {
6
- options: string[];
7
- control: {
8
- type: string;
9
- };
10
- };
11
- bgColor: {
12
- options: string[];
13
- control: {
14
- type: string;
15
- };
16
- };
17
- };
18
- };
19
- export default metadata;
20
- export declare function WithImage(props: HeroProps): import("react/jsx-runtime").JSX.Element;
21
- export declare namespace WithImage {
22
- var args: {
23
- readonly contentPosition: "below-center";
24
- readonly bgColor: "white";
25
- };
26
- }
27
- export declare function WithoutImage(props: HeroProps): import("react/jsx-runtime").JSX.Element;
28
- export declare namespace WithoutImage {
29
- var args: {
30
- contentPosition: string;
31
- bgColor: string;
32
- };
33
- }
@@ -1,2 +0,0 @@
1
- import type { HeroContentPosition } from './Hero';
2
- export declare function usesGridAreaPlacement(contentPosition: HeroContentPosition): boolean;
@@ -1,11 +0,0 @@
1
- /// <reference types="react" />
2
- export interface InputProps extends React.ComponentPropsWithoutRef<'input'> {
3
- as?: string;
4
- /** React node on the left (ex. icon, text, component) */
5
- leftAddon?: React.ReactNode;
6
- /** React node on the left (ex. icon, text, component) */
7
- rightAddon?: React.ReactNode;
8
- /** Render input as invalid. Sets `aria-invalid` to true */
9
- isInvalid?: boolean;
10
- }
11
- export declare const Input: import("react").ForwardRefExoticComponent<InputProps & import("react").RefAttributes<HTMLInputElement>>;
@@ -1 +0,0 @@
1
- export * from './Input';
@@ -1,8 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- };
7
- export default metadata;
8
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
@@ -1,8 +0,0 @@
1
- /// <reference types="react" />
2
- export interface LinkProps {
3
- children: React.ReactNode;
4
- icon?: React.ReactNode;
5
- href: string;
6
- className?: string;
7
- }
8
- export declare const Link: (props: LinkProps) => import("react/jsx-runtime").JSX.Element;
@@ -1 +0,0 @@
1
- export * from './Link';
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarProps {
3
- children: React.ReactNode;
4
- className?: string;
5
- }
6
- export declare const Navbar: (props: NavbarProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarCollapsibleProps {
3
- children: React.ReactNode;
4
- className?: string;
5
- }
6
- export declare const NavbarCollapsible: (props: NavbarCollapsibleProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarContentProps {
3
- children?: React.ReactNode;
4
- logo: React.ReactNode;
5
- className?: string;
6
- }
7
- export declare const NavbarContent: (props: NavbarContentProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export declare const NavbarContext: import("react").Context<{
3
- isExpanded: boolean;
4
- setIsExpanded: React.Dispatch<React.SetStateAction<boolean>>;
5
- collapsibleId: string;
6
- }>;
@@ -1,9 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarExpandedMobileContentProps {
3
- children: React.ReactNode;
4
- }
5
- /**
6
- * Helper component that only renders when the navbar is expanded and on a small screen
7
- * Simplifies having a totally different navbar layout than on desktop
8
- */
9
- export declare const NavbarExpandedMobileContent: (props: NavbarExpandedMobileContentProps) => import("react/jsx-runtime").JSX.Element | null;
@@ -1,7 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarItemProps extends React.ComponentPropsWithoutRef<'a'> {
3
- active?: boolean;
4
- children?: React.ReactNode;
5
- className?: string;
6
- }
7
- export declare const NavbarItem: import("react").ForwardRefExoticComponent<NavbarItemProps & import("react").RefAttributes<HTMLAnchorElement>>;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export interface NavbarItemsProps {
3
- children: React.ReactNode;
4
- className?: string;
5
- }
6
- export declare const NavbarItems: (props: NavbarItemsProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,4 +0,0 @@
1
- /**
2
- * TODO: Add support for setting custom button text (eg for obos.se)
3
- */
4
- export declare const NavbarMenuButton: () => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- export * from './Navbar';
2
- export * from './NavbarItems';
3
- export * from './NavbarItem';
4
- export * from './NavbarContent';
5
- export * from './NavbarCollapsible';
6
- export * from './NavbarExpandedMobileContent';
@@ -1,5 +0,0 @@
1
- declare const _default: {
2
- title: string;
3
- };
4
- export default _default;
5
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
@@ -1,23 +0,0 @@
1
- /// <reference types="react" />
2
- import type { RequireAtLeastOne } from 'type-fest';
3
- interface BasePaginationProps extends Omit<React.ComponentPropsWithoutRef<'nav'>, 'onChange'> {
4
- /** The current page number.
5
- * @note Starts at 1
6
- */
7
- page: number;
8
- /** The total number of pages. */
9
- count: number;
10
- /** Given a page number, should return a valid href string. */
11
- getItemHref: (page: number) => string;
12
- /** Given a page number, should return a valid href string. */
13
- getItemAriaLabel: (page: number) => string;
14
- /** Aria label for the next page button link */
15
- nextPageAriaLabel: string;
16
- /** Aria label for the previous page button link */
17
- prevPageAriaLabel: string;
18
- /** Handler that is called with the page number to navigate to. `event.preventDefault` is called for you. Fallbacks to default browser behavior if undefined. */
19
- onChange?: (page: number) => void;
20
- }
21
- type PaginationProps = RequireAtLeastOne<BasePaginationProps, 'aria-label' | 'aria-labelledby'>;
22
- export declare const Pagination: (props: PaginationProps) => import("react/jsx-runtime").JSX.Element;
23
- export {};
@@ -1 +0,0 @@
1
- export * from './Pagination';
@@ -1,24 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- argTypes: {
7
- pageCount: {
8
- control: {
9
- type: string;
10
- min: number;
11
- max: number;
12
- };
13
- };
14
- };
15
- };
16
- export default metadata;
17
- export declare const Default: {
18
- (props: {
19
- pageCount: number;
20
- }): import("react/jsx-runtime").JSX.Element;
21
- args: {
22
- pageCount: number;
23
- };
24
- };
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- export interface RadioProps extends React.ComponentPropsWithoutRef<'input'> {
3
- children: React.ReactNode;
4
- }
5
- export declare const Radio: import("react").ForwardRefExoticComponent<RadioProps & import("react").RefAttributes<HTMLInputElement>>;
@@ -1,10 +0,0 @@
1
- /// <reference types="react" />
2
- export declare const RadioContext: import("react").Context<{
3
- defaultValue?: string | undefined;
4
- isControlled: boolean;
5
- name?: string | undefined;
6
- onChange?(event: React.ChangeEvent<HTMLInputElement>): void;
7
- required?: boolean | undefined;
8
- value?: string | undefined;
9
- error?: boolean | undefined;
10
- }>;
@@ -1,20 +0,0 @@
1
- /// <reference types="react" />
2
- export interface RadioGroupProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'onChange'> {
3
- /** The value of the radio button to be initially selected. For uncontrolled usage */
4
- defaultValue?: string;
5
- /** Help text for the radio group. */
6
- description?: React.ReactNode;
7
- /** Error message for the form control */
8
- error?: string;
9
- /** The `name` attribute for the radio buttons. */
10
- name: string;
11
- /** The label for the radio group. */
12
- label?: string;
13
- /** Event handler called when the value changes. */
14
- onChange?(value: string): void;
15
- /** Whether a value selection is required. */
16
- required?: boolean;
17
- /** The value of the selected radio button. For controlled usage */
18
- value?: string;
19
- }
20
- export declare const RadioGroup: import("react").ForwardRefExoticComponent<RadioGroupProps & import("react").RefAttributes<HTMLDivElement>>;
@@ -1,2 +0,0 @@
1
- export * from './Radio';
2
- export * from './RadioGroup';
@@ -1,12 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- };
7
- export default metadata;
8
- export declare const Uncontrolled: () => import("react/jsx-runtime").JSX.Element;
9
- export declare const Controlled: () => import("react/jsx-runtime").JSX.Element;
10
- export declare const WithLabelAndHelpText: () => import("react/jsx-runtime").JSX.Element;
11
- export declare const WithLongLabelThatBreaksLines: () => import("react/jsx-runtime").JSX.Element;
12
- export declare const WithErrorText: () => import("react/jsx-runtime").JSX.Element;
@@ -1,21 +0,0 @@
1
- /// <reference types="react" />
2
- export interface SelectProps extends Omit<React.ComponentPropsWithoutRef<'select'>, 'size'> {
3
- /**
4
- * Collection of <option />-elements
5
- */
6
- children: React.ReactNode;
7
- /** Help text for the form control */
8
- description?: React.ReactNode;
9
- /** Disables the built in HTML5 validation. If using custom validation for an entire form, consider setting `noValidate` on the form element instead. @default false */
10
- disableValidation?: boolean;
11
- /** Error message for the form control */
12
- error?: string;
13
- /** Label for the form control */
14
- label: string;
15
- /**
16
- * Changes font-size, padding and gaps
17
- * @default medium
18
- */
19
- size?: 'medium' | 'small';
20
- }
21
- export declare const Select: import("react").ForwardRefExoticComponent<SelectProps & import("react").RefAttributes<HTMLSelectElement>>;
@@ -1,15 +0,0 @@
1
- /// <reference types="react" />
2
- export interface SelectPlainProps extends Omit<React.ComponentPropsWithoutRef<'select'>, 'size'> {
3
- /**
4
- * Collection of <option />-elements
5
- */
6
- children: React.ReactNode;
7
- /** Render select as invalid. Sets `aria-invalid` to true */
8
- isInvalid?: boolean;
9
- /**
10
- * Changes font-size, padding and gaps
11
- * @default medium
12
- */
13
- size?: 'medium' | 'small';
14
- }
15
- export declare const SelectPlain: import("react").ForwardRefExoticComponent<SelectPlainProps & import("react").RefAttributes<HTMLSelectElement>>;
@@ -1 +0,0 @@
1
- export * from './Select';
@@ -1,26 +0,0 @@
1
- import { SelectProps } from '../';
2
- declare const metadata: {
3
- title: string;
4
- parameters: {
5
- layout: string;
6
- };
7
- argTypes: {
8
- description: {
9
- defaultValue: string;
10
- control: string;
11
- };
12
- size: {
13
- defaultValue: string;
14
- options: string[];
15
- control: {
16
- type: string;
17
- };
18
- };
19
- required: {
20
- defaultValue: boolean;
21
- control: string;
22
- };
23
- };
24
- };
25
- export default metadata;
26
- export declare const Default: (props: SelectProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,8 +0,0 @@
1
- /// <reference types="react" />
2
- export interface SnackbarProps {
3
- children?: React.ReactNode;
4
- id?: string;
5
- heading: string;
6
- closeSnackbar?: () => void;
7
- }
8
- export declare const Snackbar: (props: SnackbarProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,6 +0,0 @@
1
- /// <reference types="react" />
2
- export interface SnackbarButtonProps extends React.ComponentPropsWithoutRef<'button'> {
3
- children: React.ReactNode;
4
- className?: string;
5
- }
6
- export declare const SnackbarButton: (props: SnackbarButtonProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,5 +0,0 @@
1
- /// <reference types="react" />
2
- export interface SnackbarContentProps extends React.ComponentPropsWithoutRef<'div'> {
3
- children?: React.ReactNode;
4
- }
5
- export declare const SnackbarContent: (props: SnackbarContentProps) => import("react/jsx-runtime").JSX.Element;
@@ -1,3 +0,0 @@
1
- export * from './Snackbar';
2
- export * from './SnackbarButton';
3
- export * from './SnackbarContent';
@@ -1,9 +0,0 @@
1
- declare const metadata: {
2
- title: string;
3
- parameters: {
4
- layout: string;
5
- };
6
- };
7
- export default metadata;
8
- export declare const Default: () => import("react/jsx-runtime").JSX.Element;
9
- export declare const SnackbarWithContent: () => import("react/jsx-runtime").JSX.Element;