@bootsmonday/corncob-design-language-react 0.1.0 → 0.2.2

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 (133) hide show
  1. package/CHANGELOG.md +11 -0
  2. package/dist-types/common/choice-name.d.ts +8 -0
  3. package/dist-types/common/field.d.ts +22 -0
  4. package/dist-types/common/form-item.d.ts +11 -0
  5. package/dist-types/components/badges/badge.d.ts +12 -0
  6. package/dist-types/components/button-bars/button-bar.d.ts +12 -0
  7. package/dist-types/components/buttons/button.d.ts +16 -0
  8. package/dist-types/components/checkboxes/checkbox-group.d.ts +13 -0
  9. package/dist-types/components/checkboxes/checkbox.d.ts +20 -0
  10. package/dist-types/components/expandables/expandable.d.ts +43 -0
  11. package/dist-types/components/footers/footer.d.ts +62 -0
  12. package/dist-types/components/headers/header.d.ts +72 -0
  13. package/dist-types/components/links/link.d.ts +22 -0
  14. package/dist-types/components/messages/message.d.ts +42 -0
  15. package/dist-types/components/modals/modal.d.ts +30 -0
  16. package/dist-types/components/panel-menus/panel-menu.d.ts +33 -0
  17. package/dist-types/components/panels/panel.d.ts +11 -0
  18. package/dist-types/components/popovers/popover.d.ts +35 -0
  19. package/dist-types/components/radio-buttons/radio-button-group.d.ts +13 -0
  20. package/dist-types/components/radio-buttons/radio-button.d.ts +18 -0
  21. package/dist-types/components/selects/select.d.ts +14 -0
  22. package/dist-types/components/sliders/slider.d.ts +7 -0
  23. package/dist-types/components/text-inputs/text-input.d.ts +6 -0
  24. package/dist-types/components/toasts/toast.d.ts +7 -0
  25. package/dist-types/components/toggles/toggle.d.ts +13 -0
  26. package/dist-types/components/tooltips/tooltip.d.ts +8 -0
  27. package/dist-types/custom-elements.d.ts +3 -0
  28. package/dist-types/index.d.ts +24 -0
  29. package/dist-types/utils/assign-ref.d.ts +7 -0
  30. package/dist-types/utils/class-names.d.ts +14 -0
  31. package/package.json +29 -8
  32. package/src/common/choice-name.js +7 -0
  33. package/src/common/field.jsx +17 -0
  34. package/src/common/form-item.jsx +5 -0
  35. package/src/components/badges/badge.jsx +5 -0
  36. package/src/components/button-bars/button-bar.jsx +5 -1
  37. package/src/components/buttons/button.jsx +5 -1
  38. package/src/components/checkboxes/checkbox-group.jsx +5 -0
  39. package/src/components/checkboxes/checkbox.jsx +5 -0
  40. package/src/components/expandables/expandable.jsx +20 -0
  41. package/src/components/footers/footer.jsx +30 -0
  42. package/src/components/headers/header.jsx +35 -0
  43. package/src/components/links/link.jsx +10 -0
  44. package/src/components/messages/message.jsx +20 -0
  45. package/src/components/modals/modal.jsx +15 -0
  46. package/src/components/panel-menus/panel-menu.jsx +15 -0
  47. package/src/components/panels/panel.jsx +5 -0
  48. package/src/components/popovers/popover.jsx +15 -0
  49. package/src/components/radio-buttons/radio-button-group.jsx +5 -0
  50. package/src/components/radio-buttons/radio-button.jsx +5 -0
  51. package/src/components/selects/select.jsx +10 -0
  52. package/src/components/sliders/slider.jsx +5 -0
  53. package/src/components/text-inputs/text-input.jsx +5 -0
  54. package/src/components/toasts/toast.jsx +5 -0
  55. package/src/components/toggles/toggle.jsx +10 -0
  56. package/src/components/tooltips/tooltip.jsx +5 -0
  57. package/src/custom-elements.d.ts +9 -0
  58. package/src/utils/assign-ref.js +6 -0
  59. package/src/utils/class-names.js +12 -0
  60. package/.changelog/README.md +0 -33
  61. package/jest.config.cjs +0 -17
  62. package/jest.setup.cjs +0 -19
  63. package/src/common/choice-name.test.js +0 -46
  64. package/src/common/field.test.js +0 -33
  65. package/src/common/form-item.test.js +0 -45
  66. package/src/components/badges/badge.stickersheet.jsx +0 -39
  67. package/src/components/badges/badge.test.js +0 -69
  68. package/src/components/button-bars/button-bar.stickersheet.jsx +0 -86
  69. package/src/components/button-bars/button-bar.test.js +0 -58
  70. package/src/components/buttons/button.stickersheet.jsx +0 -204
  71. package/src/components/buttons/button.test.js +0 -84
  72. package/src/components/checkboxes/checkbox.stickersheet.jsx +0 -53
  73. package/src/components/checkboxes/checkbox.test.js +0 -154
  74. package/src/components/expandables/expandable.stickersheet.jsx +0 -100
  75. package/src/components/expandables/expandable.test.js +0 -125
  76. package/src/components/footers/footer.stickersheet.jsx +0 -77
  77. package/src/components/footers/footer.test.js +0 -64
  78. package/src/components/headers/header.stickersheet.jsx +0 -63
  79. package/src/components/headers/header.test.js +0 -63
  80. package/src/components/links/link.stickersheet.jsx +0 -75
  81. package/src/components/links/link.test.js +0 -70
  82. package/src/components/messages/message.stickersheet.jsx +0 -96
  83. package/src/components/messages/message.test.js +0 -92
  84. package/src/components/modals/modal.stickersheet.jsx +0 -44
  85. package/src/components/modals/modal.test.js +0 -32
  86. package/src/components/panel-menus/panel-menu.stickersheet.jsx +0 -34
  87. package/src/components/panel-menus/panel-menu.test.js +0 -98
  88. package/src/components/panels/panel.stickersheet.jsx +0 -13
  89. package/src/components/panels/panel.test.js +0 -54
  90. package/src/components/popovers/popover.stickersheet.jsx +0 -236
  91. package/src/components/popovers/popover.test.js +0 -98
  92. package/src/components/radio-buttons/radio-button.stickersheet.jsx +0 -40
  93. package/src/components/radio-buttons/radio-button.test.js +0 -119
  94. package/src/components/selects/select.stickersheet.jsx +0 -34
  95. package/src/components/selects/select.test.js +0 -119
  96. package/src/components/sliders/slider.stickersheet.jsx +0 -29
  97. package/src/components/sliders/slider.test.js +0 -81
  98. package/src/components/text-inputs/text-input.stickersheet.jsx +0 -41
  99. package/src/components/text-inputs/text-input.test.js +0 -83
  100. package/src/components/toasts/toast.stickersheet.jsx +0 -54
  101. package/src/components/toasts/toast.test.js +0 -50
  102. package/src/components/toggles/toggle.stickersheet.jsx +0 -81
  103. package/src/components/toggles/toggle.test.js +0 -165
  104. package/src/components/tooltips/tooltip.stickersheet.jsx +0 -34
  105. package/src/components/tooltips/tooltip.test.js +0 -60
  106. package/src/stickersheets/badges.html +0 -31
  107. package/src/stickersheets/button-bars.html +0 -29
  108. package/src/stickersheets/buttons-standard.html +0 -33
  109. package/src/stickersheets/checkboxes.html +0 -32
  110. package/src/stickersheets/expandables.html +0 -29
  111. package/src/stickersheets/footers.html +0 -29
  112. package/src/stickersheets/headers.html +0 -29
  113. package/src/stickersheets/index.html +0 -56
  114. package/src/stickersheets/links.html +0 -29
  115. package/src/stickersheets/messages.html +0 -29
  116. package/src/stickersheets/modals.html +0 -29
  117. package/src/stickersheets/panel-menus.html +0 -29
  118. package/src/stickersheets/panels.html +0 -29
  119. package/src/stickersheets/popovers.html +0 -29
  120. package/src/stickersheets/radio-buttons.html +0 -32
  121. package/src/stickersheets/select.html +0 -31
  122. package/src/stickersheets/sliders.html +0 -31
  123. package/src/stickersheets/src/stickersheet-controls.html +0 -13
  124. package/src/stickersheets/src/stickersheet-header.html +0 -17
  125. package/src/stickersheets/src/stickersheet-react-header.html +0 -17
  126. package/src/stickersheets/src/stickersheet.css +0 -17
  127. package/src/stickersheets/src/stickersheet.js +0 -80
  128. package/src/stickersheets/text-inputs.html +0 -31
  129. package/src/stickersheets/toasts.html +0 -29
  130. package/src/stickersheets/toggles.html +0 -32
  131. package/src/stickersheets/tooltips.html +0 -29
  132. package/src/utils/assign-ref.test.js +0 -35
  133. package/src/utils/class-names.test.js +0 -21
package/CHANGELOG.md CHANGED
@@ -7,3 +7,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
7
7
  Entries are generated from markdown fragments in `.changelog/` using the React release GitHub Actions workflow.
8
8
 
9
9
  ## [Unreleased]
10
+
11
+ ## [0.2.0] - 2026-10-28
12
+
13
+ ### Added
14
+
15
+ - typescript types: Added TypeScript types for the React components.
16
+
17
+ ### Changed
18
+
19
+ - react: The React package now requires `@bootsmonday/corncob-design-language` `^0.3.2`. The wrappers use its class names and custom elements.
20
+
@@ -0,0 +1,8 @@
1
+ /**
2
+ * Takes React children and assigns a name prop to those of specified types if they don't already have one.
3
+ * @param {React.ReactNode} children
4
+ * @param {string} name
5
+ * @param {Array<React.ElementType>} types
6
+ * @returns {React.ReactNode}
7
+ */
8
+ export declare function withChoiceName(children: React.ReactNode, name: string, types: Array<React.ElementType>): React.ReactNode;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Resolves the label for a field based on the provided label and children.
3
+ * @param {string} label
4
+ * @param {React.ReactNode} children
5
+ * @returns {string|null}
6
+ */
7
+ export declare function resolveFieldLabel(label: string, children: React.ReactNode): string | null;
8
+ /**
9
+ * Returns the class name for a field item based on the status variant and additional class names.
10
+ * @param {string} statusVariant
11
+ * @param {string} itemClassName
12
+ * @returns {string}
13
+ */
14
+ export declare function fieldItemClassName(statusVariant: string, itemClassName?: string): string;
15
+ /**
16
+ * Returns the status element for a field if the status is provided.
17
+ * @param {{ status: string }} param0
18
+ * @returns {JSX.Element|null}
19
+ */
20
+ export declare function FieldStatus({ status }: {
21
+ status: string;
22
+ }): JSX.Element | null;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Renders a form item component with the specified props and children.
3
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} props
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornFormItem({ ref, as: Component, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ as?: React.ElementType;
9
+ className?: string;
10
+ children: React.ReactNode;
11
+ }): JSX.Element;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * Renders a badge component with the specified variant, size, and children.
3
+ * @param {{ ref?: React.Ref<any>, variant?: string, size?: string, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornBadge({ ref, variant, size, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ variant?: string;
9
+ size?: string;
10
+ className?: string;
11
+ children: React.ReactNode;
12
+ }): JSX.Element;
@@ -0,0 +1,12 @@
1
+ import '../../custom-elements.js';
2
+ /**
3
+ * Renders a button bar component with the specified overflow label and children.
4
+ * @param {{ ref?: React.Ref<any>, className?: string, overflowLabel?: string, children: React.ReactNode }} param0
5
+ * @returns {JSX.Element}
6
+ */
7
+ export declare function CornButtonBar({ ref, className, overflowLabel, children, ...props }: {
8
+ ref?: React.Ref<any>;
9
+ className?: string;
10
+ overflowLabel?: string;
11
+ children: React.ReactNode;
12
+ }): JSX.Element;
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Renders a button component with the specified variant, size, icon, type, and children.
3
+ * @param {{ ref?: React.Ref<any>, variant?: string, size?: string, icon?: boolean, type?: string, as?: React.ElementType, className?: string, disabled?: boolean, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornButton({ ref, variant, size, icon, type, as: Component, className, disabled, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ variant?: string;
9
+ size?: string;
10
+ icon?: boolean;
11
+ type?: string;
12
+ as?: React.ElementType;
13
+ className?: string;
14
+ disabled?: boolean;
15
+ children: React.ReactNode;
16
+ }): JSX.Element;
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Renders a checkbox group component with the specified legend, name, inline display, and children.
3
+ * @param {{ ref?: React.Ref<any>, legend?: string, name: string, inline?: boolean, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornCheckboxGroup({ ref, legend, name, inline, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ legend?: string;
9
+ name: string;
10
+ inline?: boolean;
11
+ className?: string;
12
+ children: React.ReactNode;
13
+ }): JSX.Element;
@@ -0,0 +1,20 @@
1
+ /**
2
+ * Renders a checkbox component with the specified size, task style, indeterminate state, and other input properties.
3
+ * @param {{ ref?: React.Ref<any>, size?: string, task?: boolean, indeterminate?: boolean, id?: string, name?: string, label?: React.ReactNode, className?: string, checked?: boolean, defaultChecked?: boolean, onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void, value?: string, children?: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornCheckbox({ ref, size, task, indeterminate, id, name, label, className, checked, defaultChecked, onChange, value, children, ...inputProps }: {
7
+ ref?: React.Ref<any>;
8
+ size?: string;
9
+ task?: boolean;
10
+ indeterminate?: boolean;
11
+ id?: string;
12
+ name?: string;
13
+ label?: React.ReactNode;
14
+ className?: string;
15
+ checked?: boolean;
16
+ defaultChecked?: boolean;
17
+ onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
18
+ value?: string;
19
+ children?: React.ReactNode;
20
+ }): JSX.Element;
@@ -0,0 +1,43 @@
1
+ import '../../custom-elements.js';
2
+ /**
3
+ * Renders an expandable component with the specified open state, name, and children.
4
+ * @param {{ ref?: React.Ref<any>, className?: string, open?: boolean, name?: string, children: React.ReactNode }} param0
5
+ * @returns {JSX.Element}
6
+ */
7
+ export declare function CornExpandable({ ref, className, open, name, children, ...props }: {
8
+ ref?: React.Ref<any>;
9
+ className?: string;
10
+ open?: boolean;
11
+ name?: string;
12
+ children: React.ReactNode;
13
+ }): JSX.Element;
14
+ /**
15
+ * Renders an expandable summary component with the specified class name and children.
16
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
17
+ * @returns {JSX.Element}
18
+ */
19
+ export declare function CornExpandableSummary({ ref, className, children, ...props }: {
20
+ ref?: React.Ref<any>;
21
+ className?: string;
22
+ children: React.ReactNode;
23
+ }): JSX.Element;
24
+ /**
25
+ * Renders an expandable content component with the specified class name and children.
26
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
27
+ * @returns {JSX.Element}
28
+ */
29
+ export declare function CornExpandableContent({ ref, className, children, ...props }: {
30
+ ref?: React.Ref<any>;
31
+ className?: string;
32
+ children: React.ReactNode;
33
+ }): JSX.Element;
34
+ /**
35
+ * Renders an accordion component with the specified class name and children.
36
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
37
+ * @returns {JSX.Element}
38
+ */
39
+ export declare function CornAccordion({ ref, className, children, ...props }: {
40
+ ref?: React.Ref<any>;
41
+ className?: string;
42
+ children: React.ReactNode;
43
+ }): JSX.Element;
@@ -0,0 +1,62 @@
1
+ /**
2
+ * Renders a footer component with the specified class name and children.
3
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornFooter({ ref, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ className?: string;
9
+ children: React.ReactNode;
10
+ }): JSX.Element;
11
+ /**
12
+ * Renders a footer intro component with the specified class name and children.
13
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
14
+ * @returns {JSX.Element}
15
+ */
16
+ export declare function CornFooterIntro({ ref, className, children, ...props }: {
17
+ ref?: React.Ref<any>;
18
+ className?: string;
19
+ children: React.ReactNode;
20
+ }): JSX.Element;
21
+ /**
22
+ * Renders a footer content component with the specified class name and children.
23
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
24
+ * @returns {JSX.Element}
25
+ */
26
+ export declare function CornFooterContent({ ref, className, children, ...props }: {
27
+ ref?: React.Ref<any>;
28
+ className?: string;
29
+ children: React.ReactNode;
30
+ }): JSX.Element;
31
+ /**
32
+ * Renders a footer section component with the specified class name, title, and children.
33
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, title?: React.ReactNode, children: React.ReactNode }} param0
34
+ * @returns {JSX.Element}
35
+ */
36
+ export declare function CornFooterSection({ ref, as: Component, className, title, children, ...props }: {
37
+ ref?: React.Ref<any>;
38
+ as?: React.ElementType;
39
+ className?: string;
40
+ title?: React.ReactNode;
41
+ children: React.ReactNode;
42
+ }): JSX.Element;
43
+ /**
44
+ * Renders a footer social component with the specified class name and children.
45
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
46
+ * @returns {JSX.Element}
47
+ */
48
+ export declare function CornFooterSocial({ ref, className, children, ...props }: {
49
+ ref?: React.Ref<any>;
50
+ className?: string;
51
+ children: React.ReactNode;
52
+ }): JSX.Element;
53
+ /**
54
+ * Renders a footer copyright component with the specified class name and children.
55
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
56
+ * @returns {JSX.Element}
57
+ */
58
+ export declare function CornFooterCopyright({ ref, className, children, ...props }: {
59
+ ref?: React.Ref<any>;
60
+ className?: string;
61
+ children: React.ReactNode;
62
+ }): JSX.Element;
@@ -0,0 +1,72 @@
1
+ /**
2
+ * Renders a header component with the specified class name and children.
3
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornHeader({ ref, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ className?: string;
9
+ children: React.ReactNode;
10
+ }): JSX.Element;
11
+ /**
12
+ * Renders a header company component with the specified class name and children.
13
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
14
+ * @returns {JSX.Element}
15
+ */
16
+ export declare function CornHeaderCompany({ ref, className, children, ...props }: {
17
+ ref?: React.Ref<any>;
18
+ className?: string;
19
+ children: React.ReactNode;
20
+ }): JSX.Element;
21
+ /**
22
+ * Renders a header company logo component with the specified class name and children.
23
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
24
+ * @returns {JSX.Element}
25
+ */
26
+ export declare function CornHeaderCompanyLogo({ ref, className, children, ...props }: {
27
+ ref?: React.Ref<any>;
28
+ className?: string;
29
+ children: React.ReactNode;
30
+ }): JSX.Element;
31
+ /**
32
+ * Renders a header company name component with the specified class name and children.
33
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} param0
34
+ * @returns {JSX.Element}
35
+ */
36
+ export declare function CornHeaderCompanyName({ ref, as: Component, className, children, ...props }: {
37
+ ref?: React.Ref<any>;
38
+ as?: React.ElementType;
39
+ className?: string;
40
+ children: React.ReactNode;
41
+ }): JSX.Element;
42
+ /**
43
+ * Renders a header title component with the specified class name and children.
44
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} param0
45
+ * @returns {JSX.Element}
46
+ */
47
+ export declare function CornHeaderTitle({ ref, as: Component, className, children, ...props }: {
48
+ ref?: React.Ref<any>;
49
+ as?: React.ElementType;
50
+ className?: string;
51
+ children: React.ReactNode;
52
+ }): JSX.Element;
53
+ /**
54
+ * Renders a header navigation component with the specified class name and children.
55
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
56
+ * @returns {JSX.Element}
57
+ */
58
+ export declare function CornHeaderNav({ ref, className, children, ...props }: {
59
+ ref?: React.Ref<any>;
60
+ className?: string;
61
+ children: React.ReactNode;
62
+ }): JSX.Element;
63
+ /**
64
+ * Renders a header actions component with the specified class name and children.
65
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
66
+ * @returns {JSX.Element}
67
+ */
68
+ export declare function CornHeaderActions({ ref, className, children, ...props }: {
69
+ ref?: React.Ref<any>;
70
+ className?: string;
71
+ children: React.ReactNode;
72
+ }): JSX.Element;
@@ -0,0 +1,22 @@
1
+ /**
2
+ * Renders a link component with the specified class name, underline option, and children.
3
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, underline?: boolean, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornLink({ ref, as: Component, underline, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ as?: React.ElementType;
9
+ underline?: boolean;
10
+ className?: string;
11
+ children: React.ReactNode;
12
+ }): JSX.Element;
13
+ /**
14
+ * Renders a link list component with the specified class name and children.
15
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
16
+ * @returns {JSX.Element}
17
+ */
18
+ export declare function CornLinkList({ ref, className, children, ...props }: {
19
+ ref?: React.Ref<any>;
20
+ className?: string;
21
+ children: React.ReactNode;
22
+ }): JSX.Element;
@@ -0,0 +1,42 @@
1
+ /**
2
+ * Renders a message component with the specified variant, class name, and children.
3
+ * @param {{ ref?: React.Ref<any>, variant?: 'info' | 'success' | 'warning' | 'error', className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornMessage({ ref, variant, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ variant?: 'info' | 'success' | 'warning' | 'error';
9
+ className?: string;
10
+ children: React.ReactNode;
11
+ }): JSX.Element;
12
+ /**
13
+ * Renders a message status component with the specified class name and children.
14
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
15
+ * @returns {JSX.Element}
16
+ */
17
+ export declare function CornMessageStatus({ ref, className, children, ...props }: {
18
+ ref?: React.Ref<any>;
19
+ className?: string;
20
+ children: React.ReactNode;
21
+ }): JSX.Element;
22
+ /**
23
+ * Renders a message content component with the specified class name and children.
24
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
25
+ * @returns {JSX.Element}
26
+ */
27
+ export declare function CornMessageContent({ ref, className, children, ...props }: {
28
+ ref?: React.Ref<any>;
29
+ className?: string;
30
+ children: React.ReactNode;
31
+ }): JSX.Element;
32
+ /**
33
+ * Renders a message title component with the specified class name and children.
34
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} param0
35
+ * @returns {JSX.Element}
36
+ */
37
+ export declare function CornMessageTitle({ ref, as: Component, className, children, ...props }: {
38
+ ref?: React.Ref<any>;
39
+ as?: React.ElementType;
40
+ className?: string;
41
+ children: React.ReactNode;
42
+ }): JSX.Element;
@@ -0,0 +1,30 @@
1
+ /**
2
+ * Renders a modal component with the specified class name and children.
3
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornModal({ ref, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ className?: string;
9
+ children: React.ReactNode;
10
+ }): JSX.Element;
11
+ /**
12
+ * Renders a modal header component with the specified class name and children.
13
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
14
+ * @returns {JSX.Element}
15
+ */
16
+ export declare function CornModalHeader({ ref, className, children, ...props }: {
17
+ ref?: React.Ref<any>;
18
+ className?: string;
19
+ children: React.ReactNode;
20
+ }): JSX.Element;
21
+ /**
22
+ * Renders a modal content component with the specified class name and children.
23
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
24
+ * @returns {JSX.Element}
25
+ */
26
+ export declare function CornModalContent({ ref, className, children, ...props }: {
27
+ ref?: React.Ref<any>;
28
+ className?: string;
29
+ children: React.ReactNode;
30
+ }): JSX.Element;
@@ -0,0 +1,33 @@
1
+ /**
2
+ * Renders a panel menu component with the specified class name and children.
3
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornPanelMenu({ ref, as: Component, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ as?: React.ElementType;
9
+ className?: string;
10
+ children: React.ReactNode;
11
+ }): JSX.Element;
12
+ /**
13
+ * Renders a panel menu item component with the specified class name, active state, and children.
14
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, active?: boolean, className?: string, children: React.ReactNode }} param0
15
+ * @returns {JSX.Element}
16
+ */
17
+ export declare function CornPanelMenuItem({ ref, as: Component, active, className, children, ...props }: {
18
+ ref?: React.Ref<any>;
19
+ as?: React.ElementType;
20
+ active?: boolean;
21
+ className?: string;
22
+ children: React.ReactNode;
23
+ }): JSX.Element;
24
+ /**
25
+ * Renders a panel menu submenu component with the specified class name and children.
26
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
27
+ * @returns {JSX.Element}
28
+ */
29
+ export declare function CornPanelMenuSubmenu({ ref, className, children, ...props }: {
30
+ ref?: React.Ref<any>;
31
+ className?: string;
32
+ children: React.ReactNode;
33
+ }): JSX.Element;
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Renders a panel component with the specified class name and children.
3
+ * @param {{ ref?: React.Ref<any>, as?: React.ElementType, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornPanel({ ref, as: Component, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ as?: React.ElementType;
9
+ className?: string;
10
+ children: React.ReactNode;
11
+ }): JSX.Element;
@@ -0,0 +1,35 @@
1
+ import '../../custom-elements.js';
2
+ export declare const CORN_POPOVER_POSITIONS: string[];
3
+ /**
4
+ * Renders a popover trigger component with the specified class name and children.
5
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
6
+ * @returns {JSX.Element}
7
+ */
8
+ export declare function CornPopoverTrigger({ ref, children, className, ...props }: {
9
+ ref?: React.Ref<any>;
10
+ className?: string;
11
+ children: React.ReactNode;
12
+ }): JSX.Element;
13
+ /**
14
+ * Renders a popover content component with the specified class name and children.
15
+ * @param {{ ref?: React.Ref<any>, className?: string, children: React.ReactNode }} param0
16
+ * @returns {JSX.Element}
17
+ */
18
+ export declare function CornPopoverContent({ ref, children, className, ...props }: {
19
+ ref?: React.Ref<any>;
20
+ className?: string;
21
+ children: React.ReactNode;
22
+ }): JSX.Element;
23
+ /**
24
+ * Renders a popover component with the specified class name, anchor class name, and children.
25
+ * @param {{ ref?: React.Ref<any>, id?: string, position?: string, className?: string, anchorClassName?: string, children: React.ReactNode }} param0
26
+ * @returns {JSX.Element}
27
+ */
28
+ export declare function CornPopover({ ref, id, position, className, anchorClassName, children, ...props }: {
29
+ ref?: React.Ref<any>;
30
+ id?: string;
31
+ position?: string;
32
+ className?: string;
33
+ anchorClassName?: string;
34
+ children: React.ReactNode;
35
+ }): JSX.Element;
@@ -0,0 +1,13 @@
1
+ /**
2
+ * Renders a radio button group component with the specified legend, name, inline state, class name, and children.
3
+ * @param {{ ref?: React.Ref<any>, legend?: string, name: string, inline?: boolean, className?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornRadioButtonGroup({ ref, legend, name, inline, className, children, ...props }: {
7
+ ref?: React.Ref<any>;
8
+ legend?: string;
9
+ name: string;
10
+ inline?: boolean;
11
+ className?: string;
12
+ children: React.ReactNode;
13
+ }): JSX.Element;
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Renders a radio button component with the specified size, id, name, label, class name, checked state, default checked state, change handler, value, and children.
3
+ * @param {{ ref?: React.Ref<any>, size?: string, id?: string, name: string, label?: string, className?: string, checked?: boolean, defaultChecked?: boolean, onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void, value?: string, children: React.ReactNode }} param0
4
+ * @returns {JSX.Element}
5
+ */
6
+ export declare function CornRadioButton({ ref, size, id, name, label, className, checked, defaultChecked, onChange, value, children, ...inputProps }: {
7
+ ref?: React.Ref<any>;
8
+ size?: string;
9
+ id?: string;
10
+ name: string;
11
+ label?: string;
12
+ className?: string;
13
+ checked?: boolean;
14
+ defaultChecked?: boolean;
15
+ onChange?: (event: React.ChangeEvent<HTMLInputElement>) => void;
16
+ value?: string;
17
+ children: React.ReactNode;
18
+ }): JSX.Element;
@@ -0,0 +1,14 @@
1
+ import '../../custom-elements.js';
2
+ export declare const CORN_SELECT_SIZES: string[];
3
+ /**
4
+ * Renders a select option component with the specified ref, value, and children.
5
+ * @param {*} param0 The props for the CornSelectOption component.
6
+ * @returns {JSX.Element} The rendered CornSelectOption component.
7
+ */
8
+ export declare function CornSelectOption({ ref, value, children, ...props }: any): JSX.Element;
9
+ /**
10
+ * Renders a select component with the specified ref, id, class name, size, label, name, placeholder, multiple state, required state, disabled state, value, status, status variant, item class name, and children.
11
+ * @param {*} param0 The props for the CornSelect component.
12
+ * @returns {JSX.Element} The rendered CornSelect component.
13
+ */
14
+ export declare function CornSelect({ ref, id, className, size, label, name, placeholder, multiple, required, disabled, value, status, statusVariant, itemClassName, children, ...props }: any): JSX.Element;
@@ -0,0 +1,7 @@
1
+ export declare const CORN_SLIDER_SIZES: string[];
2
+ /**
3
+ * Renders a slider component with the specified ref, id, name, label, size, class name, item class name, label class name, status, status variant, min, max, step, value, default value, disabled state, change handler, and children.
4
+ * @param {*} param0 The props for the CornSlider component.
5
+ * @returns {JSX.Element} The rendered CornSlider component.
6
+ */
7
+ export declare function CornSlider({ ref, id, name, label, size, className, itemClassName, labelClassName, status, statusVariant, min, max, step, value, defaultValue, disabled, onChange, children, ...inputProps }: any): JSX.Element;
@@ -0,0 +1,6 @@
1
+ /**
2
+ * Renders a text input component with the specified ref, size, label, id, status, status variant, placeholder, disabled state, class name, item class name, label class name, aria-invalid state, and children.
3
+ * @param {*} param0 The props for the CornTextInput component.
4
+ * @returns {JSX.Element} The rendered CornTextInput component.
5
+ */
6
+ export declare function CornTextInput({ ref, size, label, id, status, statusVariant, placeholder, disabled, className, itemClassName, labelClassName, 'aria-invalid': ariaInvalid, children, ...inputProps }: any): JSX.Element;
@@ -0,0 +1,7 @@
1
+ import '../../custom-elements.js';
2
+ /**
3
+ * Renders a toast component with the specified ref, class name, children, and other props.
4
+ * @param {*} param0 The props for the CornToast component.
5
+ * @returns {JSX.Element} The rendered CornToast component.
6
+ */
7
+ export declare function CornToast({ ref, className, children, ...props }: any): JSX.Element;
@@ -0,0 +1,13 @@
1
+ export declare const CORN_TOGGLE_SIZES: string[];
2
+ /**
3
+ * Renders a toggle component with the specified ref, id, name, label, class name, checked state, default checked state, disabled state, change handler, value, and children.
4
+ * @param {*} param0 The props for the CornToggle component.
5
+ * @returns {JSX.Element} The rendered CornToggle component.
6
+ */
7
+ export declare function CornToggle({ ref, id, name, label, className, checked, defaultChecked, disabled, onChange, value, children, ...inputProps }: any): JSX.Element;
8
+ /**
9
+ * Renders a toggle group component with the specified ref, legend, name, size, class name, toggles class name, and children.
10
+ * @param {*} param0 The props for the CornToggleGroup component.
11
+ * @returns {JSX.Element} The rendered CornToggleGroup component.
12
+ */
13
+ export declare function CornToggleGroup({ ref, legend, name, size, className, togglesClassName, children, ...props }: any): JSX.Element;
@@ -0,0 +1,8 @@
1
+ import '../../custom-elements.js';
2
+ export declare const CORN_TOOLTIP_POSITIONS: string[];
3
+ /**
4
+ * Renders a tooltip component with the specified ref, position, class name, children, and other props.
5
+ * @param {*} param0 The props for the CornTooltip component.
6
+ * @returns {JSX.Element} The rendered CornTooltip component.
7
+ */
8
+ export declare function CornTooltip({ ref, position, className, children, ...props }: any): JSX.Element;
@@ -0,0 +1,3 @@
1
+ // Resolves the side-effect import kept in the React component declarations.
2
+ // This stub must not import the vanilla component sources.
3
+ export {};
@@ -0,0 +1,24 @@
1
+ export { joinClassNames } from './utils/class-names.js';
2
+ export { CornFormItem } from './common/form-item.jsx';
3
+ export { CornButton } from './components/buttons/button.jsx';
4
+ export { CornButtonBar } from './components/button-bars/button-bar.jsx';
5
+ export { CornBadge } from './components/badges/badge.jsx';
6
+ export { CornMessage, CornMessageStatus, CornMessageContent, CornMessageTitle } from './components/messages/message.jsx';
7
+ export { CornModal, CornModalHeader, CornModalContent } from './components/modals/modal.jsx';
8
+ export { CornAccordion, CornExpandable, CornExpandableSummary, CornExpandableContent } from './components/expandables/expandable.jsx';
9
+ export { CornPanel } from './components/panels/panel.jsx';
10
+ export { CornFooter, CornFooterIntro, CornFooterContent, CornFooterSection, CornFooterSocial, CornFooterCopyright } from './components/footers/footer.jsx';
11
+ export { CornTextInput } from './components/text-inputs/text-input.jsx';
12
+ export { CornLink, CornLinkList } from './components/links/link.jsx';
13
+ export { CornCheckbox } from './components/checkboxes/checkbox.jsx';
14
+ export { CornCheckboxGroup } from './components/checkboxes/checkbox-group.jsx';
15
+ export { CornRadioButton } from './components/radio-buttons/radio-button.jsx';
16
+ export { CornRadioButtonGroup } from './components/radio-buttons/radio-button-group.jsx';
17
+ export { CornPopover, CornPopoverTrigger, CornPopoverContent, CORN_POPOVER_POSITIONS } from './components/popovers/popover.jsx';
18
+ export { CornSelect, CornSelectOption, CORN_SELECT_SIZES } from './components/selects/select.jsx';
19
+ export { CornSlider, CORN_SLIDER_SIZES } from './components/sliders/slider.jsx';
20
+ export { CornToggle, CornToggleGroup, CORN_TOGGLE_SIZES } from './components/toggles/toggle.jsx';
21
+ export { CornPanelMenu, CornPanelMenuItem, CornPanelMenuSubmenu } from './components/panel-menus/panel-menu.jsx';
22
+ export { CornToast } from './components/toasts/toast.jsx';
23
+ export { CornHeader, CornHeaderActions, CornHeaderCompany, CornHeaderCompanyLogo, CornHeaderCompanyName, CornHeaderNav, CornHeaderTitle } from './components/headers/header.jsx';
24
+ export { CORN_TOOLTIP_POSITIONS, CornTooltip } from './components/tooltips/tooltip.jsx';
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Assigns a reference to a DOM node or component instance.
3
+ * @param {*} ref The reference to assign.
4
+ * @param {*} node The DOM node or component instance.
5
+ * @returns {Function|undefined} A cleanup function if applicable.
6
+ */
7
+ export declare function assignRef(ref: any, node: any): Function | undefined;