chop-logic-components 2.0.1 → 2.2.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 (115) hide show
  1. package/README.md +4 -4
  2. package/dist/{icons → assets/icons}/index.d.ts +2 -2
  3. package/dist/{icons → assets/icons}/svg/ArrowDownIcon.d.ts +1 -1
  4. package/dist/{icons → assets/icons}/svg/ArrowUpIcon.d.ts +1 -1
  5. package/dist/{icons → assets/icons}/svg/BackIcon.d.ts +1 -1
  6. package/dist/{icons → assets/icons}/svg/CancelIcon.d.ts +1 -1
  7. package/dist/{icons → assets/icons}/svg/CheckMarkIcon.d.ts +1 -1
  8. package/dist/{icons → assets/icons}/svg/CheckboxCheckedIcon.d.ts +1 -1
  9. package/dist/{icons → assets/icons}/svg/CheckboxUncheckedIcon.d.ts +1 -1
  10. package/dist/{icons → assets/icons}/svg/ChevronDownIcon.d.ts +1 -1
  11. package/dist/{icons → assets/icons}/svg/ChevronLeftIcon.d.ts +1 -1
  12. package/dist/{icons → assets/icons}/svg/ChevronRightIcon.d.ts +1 -1
  13. package/dist/{icons → assets/icons}/svg/ChevronUpIcon.d.ts +1 -1
  14. package/dist/{icons → assets/icons}/svg/ClearIcon.d.ts +1 -1
  15. package/dist/{icons → assets/icons}/svg/CopyIcon.d.ts +1 -1
  16. package/dist/{icons → assets/icons}/svg/CutIcon.d.ts +1 -1
  17. package/dist/{icons → assets/icons}/svg/DeleteIcon.d.ts +1 -1
  18. package/dist/{icons → assets/icons}/svg/DownloadIcon.d.ts +1 -1
  19. package/dist/{icons → assets/icons}/svg/ErrorIcon.d.ts +1 -1
  20. package/dist/{icons → assets/icons}/svg/ForwardIcon.d.ts +1 -1
  21. package/dist/{icons → assets/icons}/svg/GraduateIcon.d.ts +1 -1
  22. package/dist/{icons → assets/icons}/svg/HelpIcon.d.ts +1 -1
  23. package/dist/{icons → assets/icons}/svg/HideIcon.d.ts +1 -1
  24. package/dist/{icons → assets/icons}/svg/HomeIcon.d.ts +1 -1
  25. package/dist/{icons → assets/icons}/svg/InfoIcon.d.ts +1 -1
  26. package/dist/{icons → assets/icons}/svg/LoginIcon.d.ts +1 -1
  27. package/dist/{icons → assets/icons}/svg/PasteIcon.d.ts +1 -1
  28. package/dist/{icons → assets/icons}/svg/QuestionIcon.d.ts +1 -1
  29. package/dist/{icons → assets/icons}/svg/RemoveIcon.d.ts +1 -1
  30. package/dist/{icons → assets/icons}/svg/SaveIcon.d.ts +1 -1
  31. package/dist/{icons → assets/icons}/svg/ShowIcon.d.ts +1 -1
  32. package/dist/{icons → assets/icons}/svg/UploadIcon.d.ts +1 -1
  33. package/dist/{icons → assets/icons}/svg/WarningIcon.d.ts +1 -1
  34. package/dist/chop-logic-components.css +1 -0
  35. package/dist/components/containers/grid/elements/Body.d.ts +1 -2
  36. package/dist/components/containers/grid/elements/Checkbox.d.ts +0 -2
  37. package/dist/components/containers/grid/elements/ColumnGroup.d.ts +1 -2
  38. package/dist/components/containers/grid/elements/DataCell.d.ts +0 -2
  39. package/dist/components/containers/grid/elements/Head.d.ts +1 -2
  40. package/dist/components/containers/grid/elements/HeaderCell.d.ts +0 -2
  41. package/dist/components/containers/grid/elements/Row.d.ts +0 -2
  42. package/dist/components/containers/grid/elements/SelectAllRowsCell.d.ts +0 -2
  43. package/dist/components/containers/grid/elements/SelectRowCell.d.ts +0 -2
  44. package/dist/components/containers/menu/elements/MenuItem.d.ts +1 -2
  45. package/dist/components/containers/menu/elements/MenuLeaf.d.ts +3 -5
  46. package/dist/components/containers/menu/elements/SubMenu.d.ts +1 -2
  47. package/dist/components/containers/tabs/elements/TabButton.d.ts +0 -2
  48. package/dist/components/containers/tabs/elements/TabContent.d.ts +1 -2
  49. package/dist/components/containers/tabs/elements/TabList.d.ts +1 -2
  50. package/dist/components/inputs/multi-select/elements/Combobox.d.ts +1 -2
  51. package/dist/components/inputs/multi-select/elements/Dropdown.d.ts +1 -2
  52. package/dist/components/inputs/multi-select/elements/Option.d.ts +1 -2
  53. package/dist/components/inputs/select/elements/Combobox.d.ts +1 -2
  54. package/dist/components/inputs/select/elements/Dropdown.d.ts +1 -2
  55. package/dist/components/inputs/select/elements/Option.d.ts +1 -2
  56. package/dist/components/modals/alert/elements/{Header.d.ts → AlertHeader.d.ts} +3 -5
  57. package/dist/components/modals/dialog/elements/{Header.d.ts → Header/index.d.ts} +0 -2
  58. package/dist/components/modals/dialog/elements/{Layout.d.ts → Layout/index.d.ts} +0 -2
  59. package/dist/contexts/form/context.d.ts +8 -0
  60. package/dist/contexts/index.d.ts +3 -2
  61. package/dist/contexts/theme/context.d.ts +6 -0
  62. package/dist/contexts/theme/provider.d.ts +6 -0
  63. package/dist/elements/error-message/ErrorMessage.d.ts +0 -2
  64. package/dist/elements/input-inner-button/InputInnerButton.d.ts +0 -2
  65. package/dist/elements/label/Label.d.ts +0 -2
  66. package/dist/enums/chop-logic-theme-mode.d.ts +2 -2
  67. package/dist/hooks/index.d.ts +1 -1
  68. package/dist/hooks/use-chop-logic-theme/index.d.ts +1 -1
  69. package/dist/index.cjs.js +4 -974
  70. package/dist/index.cjs.js.map +1 -1
  71. package/dist/index.es.js +1341 -3576
  72. package/dist/index.es.js.map +1 -1
  73. package/dist/models/components/form.d.ts +0 -5
  74. package/dist/models/index.d.ts +1 -2
  75. package/dist/utils/get-class-name.d.ts +5 -0
  76. package/dist/utils/index.d.ts +1 -1
  77. package/package.json +20 -17
  78. package/dist/components/containers/form/Form.styled.d.ts +0 -8
  79. package/dist/components/containers/grid/Grid.styled.d.ts +0 -37
  80. package/dist/components/containers/menu/Meny.styled.d.ts +0 -20
  81. package/dist/components/containers/tabs/Tabs.styled.d.ts +0 -18
  82. package/dist/components/inputs/button/Button.styled.d.ts +0 -12
  83. package/dist/components/inputs/checkbox/Checkbox.styled.d.ts +0 -6
  84. package/dist/components/inputs/numeric/NumericInput.styled.d.ts +0 -4
  85. package/dist/components/inputs/text/TextInput.styled.d.ts +0 -4
  86. package/dist/components/modals/alert/Alert.styled.d.ts +0 -11
  87. package/dist/components/modals/dialog/Dialog.styled.d.ts +0 -14
  88. package/dist/components/modals/tooltip/Tooltip.styled.d.ts +0 -4
  89. package/dist/contexts/chop-logic-form-context.d.ts +0 -3
  90. package/dist/contexts/chop-logic-theme-context.d.ts +0 -3
  91. package/dist/css/__docs__/ExampleDivContainer.styled.d.ts +0 -4
  92. package/dist/css/__docs__/ExampleGridContainer.styled.d.ts +0 -8
  93. package/dist/css/__docs__/story-wrapper-styles.d.ts +0 -2
  94. package/dist/css/animations.d.ts +0 -2
  95. package/dist/css/common/Select.styled.d.ts +0 -19
  96. package/dist/css/index.d.ts +0 -3
  97. package/dist/css/screen-breakpoints.d.ts +0 -7
  98. package/dist/css/themes.d.ts +0 -3
  99. package/dist/elements/error-message/ErrorMessage.styled.d.ts +0 -5
  100. package/dist/elements/input-inner-button/InputInnerButton.styled.d.ts +0 -4
  101. package/dist/elements/label/Label.styled.d.ts +0 -4
  102. package/dist/elements/loader/views/Arrow.styled.d.ts +0 -4
  103. package/dist/elements/loader/views/Brackets.styled.d.ts +0 -4
  104. package/dist/elements/loader/views/Circle.styled.d.ts +0 -4
  105. package/dist/elements/loader/views/Dots.styled.d.ts +0 -4
  106. package/dist/elements/loader/views/Filler.styled.d.ts +0 -4
  107. package/dist/elements/loader/views/Linear.styled.d.ts +0 -4
  108. package/dist/elements/loader/views/Pulse.styled.d.ts +0 -4
  109. package/dist/elements/loader/views/Rotation.styled.d.ts +0 -4
  110. package/dist/elements/loader/views/Square.styled.d.ts +0 -4
  111. package/dist/models/chop-logic-theme.d.ts +0 -35
  112. package/dist/utils/get-chop-logic-theme.d.ts +0 -2
  113. /package/dist/{icons → assets/icons}/__tests__/icons.test.d.ts +0 -0
  114. /package/dist/{__tests__ → components/__tests__}/index.test.d.ts +0 -0
  115. /package/dist/utils/__tests__/{get-chop-logic-theme.test.d.ts → get-class-name.test.d.ts} +0 -0
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicGridColumn, ChopLogicGridItem, ChopLogicTheme, RenderDataItemCallback } from '../../../../models';
2
+ import { ChopLogicGridColumn, ChopLogicGridItem, RenderDataItemCallback } from '../../../../models';
3
3
  type ChopLogicGridBodyProps = {
4
4
  data: ChopLogicGridItem[];
5
5
  columns: ChopLogicGridColumn[];
@@ -8,7 +8,6 @@ type ChopLogicGridBodyProps = {
8
8
  deselectRowById: (id: string) => void;
9
9
  renderDataItem?: RenderDataItemCallback;
10
10
  selectable: boolean;
11
- theme: ChopLogicTheme;
12
11
  };
13
12
  declare const ChopLogicGridBody: React.FC<ChopLogicGridBodyProps>;
14
13
  export default ChopLogicGridBody;
@@ -1,8 +1,6 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  type ChopLogicGridCheckboxProps = React.InputHTMLAttributes<HTMLInputElement> & {
4
3
  label: string;
5
- theme: ChopLogicTheme;
6
4
  };
7
5
  declare const GridCheckbox: React.FC<ChopLogicGridCheckboxProps>;
8
6
  export default GridCheckbox;
@@ -1,8 +1,7 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicGridColumn, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicGridColumn } from '../../../../models';
3
3
  declare const GridColumnGroup: React.FC<{
4
4
  columns: ChopLogicGridColumn[];
5
5
  selectable: boolean;
6
- theme: ChopLogicTheme;
7
6
  }>;
8
7
  export default GridColumnGroup;
@@ -1,7 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  declare const GridDataCell: React.FC<{
4
3
  value: React.ReactElement | string;
5
- theme: ChopLogicTheme;
6
4
  }>;
7
5
  export default GridDataCell;
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicGridColumn, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicGridColumn } from '../../../../models';
3
3
  type ChopLogicGridHeadProps = {
4
4
  columns: ChopLogicGridColumn[];
5
5
  gridId: string;
@@ -8,7 +8,6 @@ type ChopLogicGridHeadProps = {
8
8
  isAllCheckboxDisabled?: boolean;
9
9
  selectAll: () => void;
10
10
  deselectAll: () => void;
11
- theme: ChopLogicTheme;
12
11
  };
13
12
  declare const ChopLogicGridHead: React.FC<ChopLogicGridHeadProps>;
14
13
  export default ChopLogicGridHead;
@@ -1,8 +1,6 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  declare const GridHeaderCell: React.FC<{
4
3
  title?: string;
5
4
  component?: React.ReactElement;
6
- theme: ChopLogicTheme;
7
5
  }>;
8
6
  export default GridHeaderCell;
@@ -1,5 +1,4 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  export type GridRowProps = {
4
3
  rowId: string;
5
4
  selectedIds: string[];
@@ -8,7 +7,6 @@ export type GridRowProps = {
8
7
  selectable: boolean;
9
8
  values: (string | React.ReactElement)[];
10
9
  disabled?: boolean;
11
- theme: ChopLogicTheme;
12
10
  };
13
11
  declare const GridRow: React.FC<GridRowProps>;
14
12
  export default GridRow;
@@ -1,12 +1,10 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  type SelectAllGridRowsCheckbox = {
4
3
  gridId: string;
5
4
  isAllSelected: boolean;
6
5
  selectAll: () => void;
7
6
  deselectAll: () => void;
8
7
  disabled?: boolean;
9
- theme: ChopLogicTheme;
10
8
  };
11
9
  declare const SelectAllRowsCell: React.FC<SelectAllGridRowsCheckbox>;
12
10
  export default SelectAllRowsCell;
@@ -1,12 +1,10 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  type SelectAllGridRowsCheckbox = {
4
3
  rowId: string;
5
4
  isRowSelected: boolean;
6
5
  selectRowById: (id: string) => void;
7
6
  deselectRowById: (id: string) => void;
8
7
  disabled?: boolean;
9
- theme: ChopLogicTheme;
10
8
  };
11
9
  declare const SelectGridRowCell: React.FC<SelectAllGridRowsCheckbox>;
12
10
  export default SelectGridRowCell;
@@ -1,9 +1,8 @@
1
1
  import { default as React, PropsWithChildren } from 'react';
2
2
  import { ChopLogicOrientationMode } from '../../../../enums';
3
- import { ChopLogicMenuItem, ChopLogicTheme } from '../../../../models';
3
+ import { ChopLogicMenuItem } from '../../../../models';
4
4
  type MenuItemProps = PropsWithChildren & {
5
5
  item: ChopLogicMenuItem;
6
- theme: ChopLogicTheme;
7
6
  mode: ChopLogicOrientationMode;
8
7
  };
9
8
  declare const MenuItem: React.FC<MenuItemProps>;
@@ -1,8 +1,6 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicMenuItem, ChopLogicTheme } from '../../../../models';
3
- type MenuLeafProps = {
2
+ import { ChopLogicMenuItem } from '../../../../models';
3
+ declare const MenuLeaf: ({ item }: {
4
4
  item: ChopLogicMenuItem;
5
- theme: ChopLogicTheme;
6
- };
7
- declare const MenuLeaf: React.FC<MenuLeafProps>;
5
+ }) => React.ReactElement;
8
6
  export default MenuLeaf;
@@ -1,9 +1,8 @@
1
1
  import { default as React, PropsWithChildren } from 'react';
2
2
  import { ChopLogicOrientationMode } from '../../../../enums';
3
- import { ChopLogicMenuItem, ChopLogicTheme } from '../../../../models';
3
+ import { ChopLogicMenuItem } from '../../../../models';
4
4
  type SubMenuProps = PropsWithChildren & {
5
5
  item: ChopLogicMenuItem;
6
- theme: ChopLogicTheme;
7
6
  isSubMenuOpened: boolean;
8
7
  mode: ChopLogicOrientationMode;
9
8
  toggleSubMenu: () => void;
@@ -1,6 +1,5 @@
1
1
  import { default as React } from 'react';
2
2
  import { ChopLogicOrientationMode } from '../../../../enums';
3
- import { ChopLogicTheme } from '../../../../models';
4
3
  type ChopLogicTabButtonProps = {
5
4
  title: string;
6
5
  tabId: string;
@@ -9,7 +8,6 @@ type ChopLogicTabButtonProps = {
9
8
  isSelected: boolean;
10
9
  mode: ChopLogicOrientationMode;
11
10
  isDisabled?: boolean;
12
- theme: ChopLogicTheme;
13
11
  };
14
12
  declare const ChopLogicTabButton: React.FC<ChopLogicTabButtonProps>;
15
13
  export default ChopLogicTabButton;
@@ -1,8 +1,7 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTabItem, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicTabItem } from '../../../../models';
3
3
  declare const ChopLogicTabContent: React.FC<{
4
4
  tabs: ChopLogicTabItem[];
5
5
  selectedTabId: string;
6
- theme: ChopLogicTheme;
7
6
  }>;
8
7
  export default ChopLogicTabContent;
@@ -1,6 +1,6 @@
1
1
  import { default as React } from 'react';
2
2
  import { ChopLogicOrientationMode } from '../../../../enums';
3
- import { ChopLogicTabItem, ChopLogicTheme } from '../../../../models';
3
+ import { ChopLogicTabItem } from '../../../../models';
4
4
  type ChopLogicTabListProps = {
5
5
  tabs: ChopLogicTabItem[];
6
6
  tabIds: string[];
@@ -8,7 +8,6 @@ type ChopLogicTabListProps = {
8
8
  selectedTabId: string;
9
9
  tabPanelIds: string[];
10
10
  mode: ChopLogicOrientationMode;
11
- theme: ChopLogicTheme;
12
11
  };
13
12
  declare const ChopLogicTabList: React.FC<ChopLogicTabListProps>;
14
13
  export default ChopLogicTabList;
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicMultiSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicMultiSelectValue } from '../../../../models';
3
3
  type MultiSelectComboboxProps = {
4
4
  opened: boolean;
5
5
  disabled: boolean;
@@ -10,7 +10,6 @@ type MultiSelectComboboxProps = {
10
10
  values?: ChopLogicMultiSelectValue[];
11
11
  placeholder?: string;
12
12
  name: string;
13
- theme: ChopLogicTheme;
14
13
  };
15
14
  declare const SelectCombobox: React.FC<MultiSelectComboboxProps>;
16
15
  export default SelectCombobox;
@@ -1,12 +1,11 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicMultiSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicMultiSelectValue } from '../../../../models';
3
3
  type MultiSelectDropdownProps = {
4
4
  options: ChopLogicMultiSelectValue[];
5
5
  opened: boolean;
6
6
  dropdownId: string;
7
7
  onClose: () => void;
8
8
  onSelect: (id: string) => void;
9
- theme: ChopLogicTheme;
10
9
  };
11
10
  declare const MultiSelectDropdown: React.FC<MultiSelectDropdownProps>;
12
11
  export default MultiSelectDropdown;
@@ -1,9 +1,8 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicMultiSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicMultiSelectValue } from '../../../../models';
3
3
  type MultiSelectOptionProps = {
4
4
  value: ChopLogicMultiSelectValue;
5
5
  onSelect: (id: string) => void;
6
- theme: ChopLogicTheme;
7
6
  };
8
7
  declare const SelectOption: React.FC<MultiSelectOptionProps>;
9
8
  export default SelectOption;
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicSelectValue } from '../../../../models';
3
3
  type SelectComboboxProps = {
4
4
  opened: boolean;
5
5
  disabled: boolean;
@@ -10,7 +10,6 @@ type SelectComboboxProps = {
10
10
  selected?: ChopLogicSelectValue;
11
11
  placeholder?: string;
12
12
  name: string;
13
- theme: ChopLogicTheme;
14
13
  };
15
14
  declare const SelectCombobox: React.FC<SelectComboboxProps>;
16
15
  export default SelectCombobox;
@@ -1,5 +1,5 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicSelectValue } from '../../../../models';
3
3
  type SelectDropdownProps = {
4
4
  options: ChopLogicSelectValue[];
5
5
  opened: boolean;
@@ -9,7 +9,6 @@ type SelectDropdownProps = {
9
9
  selected?: ChopLogicSelectValue;
10
10
  onSelect: (id: string) => void;
11
11
  onClear: () => void;
12
- theme: ChopLogicTheme;
13
12
  };
14
13
  declare const SelectDropdown: React.FC<SelectDropdownProps>;
15
14
  export default SelectDropdown;
@@ -1,11 +1,10 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicSelectValue, ChopLogicTheme } from '../../../../models';
2
+ import { ChopLogicSelectValue } from '../../../../models';
3
3
  type SelectOptionProps = {
4
4
  value: ChopLogicSelectValue;
5
5
  selected: boolean;
6
6
  onSelect: (id: string) => void;
7
7
  onClear: () => void;
8
- theme: ChopLogicTheme;
9
8
  };
10
9
  declare const SelectOption: React.FC<SelectOptionProps>;
11
10
  export default SelectOption;
@@ -1,12 +1,10 @@
1
1
  import { default as React } from 'react';
2
2
  import { ChopLogicAlertMode, ChopLogicIconName } from '../../../../enums';
3
- import { ChopLogicTheme } from '../../../../models';
4
- type ChopLogicAlertHeaderProps = {
3
+ type AlertHeaderProps = {
5
4
  onClose: () => void;
6
- theme: ChopLogicTheme;
7
5
  mode: ChopLogicAlertMode;
8
6
  title?: string;
9
7
  icon?: ChopLogicIconName;
10
8
  };
11
- declare const ChopLogicAlertHeader: React.FC<ChopLogicAlertHeaderProps>;
12
- export default ChopLogicAlertHeader;
9
+ declare const AlertHeader: React.FC<AlertHeaderProps>;
10
+ export default AlertHeader;
@@ -1,8 +1,6 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  declare const ChopLogicModalLayoutHeader: React.FC<{
4
3
  title: string;
5
4
  onClose: () => void;
6
- theme: ChopLogicTheme;
7
5
  }>;
8
6
  export default ChopLogicModalLayoutHeader;
@@ -1,10 +1,8 @@
1
1
  import { default as React, HTMLAttributes, PropsWithChildren } from 'react';
2
- import { ChopLogicTheme } from '../../../../models';
3
2
  type DialogLayoutProps = PropsWithChildren & HTMLAttributes<HTMLDivElement> & {
4
3
  title: string;
5
4
  onClose: () => void;
6
5
  isOpened: boolean;
7
- theme: ChopLogicTheme;
8
6
  };
9
7
  declare const ChopLogicModalLayout: React.FC<DialogLayoutProps>;
10
8
  export default ChopLogicModalLayout;
@@ -0,0 +1,8 @@
1
+ import { default as React } from 'react';
2
+ import { ChopLogicFormData, ChopLogicFormInputParams } from '../../models';
3
+ export interface ChopLogicFormContextProps {
4
+ onChangeFormInput?: (params: ChopLogicFormInputParams) => void;
5
+ initialValues?: ChopLogicFormData;
6
+ resetSignal?: number;
7
+ }
8
+ export declare const ChopLogicFormContext: React.Context<ChopLogicFormContextProps>;
@@ -1,2 +1,3 @@
1
- export { ChopLogicFormContext } from './chop-logic-form-context';
2
- export { ChopLogicThemeContext } from './chop-logic-theme-context';
1
+ export { ChopLogicFormContext } from './form/context.tsx';
2
+ export { ChopLogicThemeContext } from './theme/context.ts';
3
+ export { ChopLogicThemeProvider } from './theme/provider.tsx';
@@ -0,0 +1,6 @@
1
+ import { ChopLogicThemeMode } from '../../enums';
2
+ export interface ChopLogicThemeContextProps {
3
+ mode?: ChopLogicThemeMode;
4
+ setMode: (mode: ChopLogicThemeMode) => void;
5
+ }
6
+ export declare const ChopLogicThemeContext: import('react').Context<ChopLogicThemeContextProps>;
@@ -0,0 +1,6 @@
1
+ import { FC, ReactNode } from 'react';
2
+ import { ChopLogicThemeMode } from '../../enums';
3
+ export declare const ChopLogicThemeProvider: FC<{
4
+ children: ReactNode;
5
+ injectedMode?: ChopLogicThemeMode;
6
+ }>;
@@ -1,12 +1,10 @@
1
1
  import { default as React } from 'react';
2
- import { ChopLogicTheme } from '../../models';
3
2
  type ChopLogicErrorMessageProps = {
4
3
  errorId: string;
5
4
  visible?: boolean;
6
5
  message?: string;
7
6
  testId?: string;
8
7
  style?: React.CSSProperties;
9
- theme: ChopLogicTheme;
10
8
  };
11
9
  declare const ChopLogicErrorMessage: React.FC<ChopLogicErrorMessageProps>;
12
10
  export default ChopLogicErrorMessage;
@@ -1,12 +1,10 @@
1
1
  import { default as React } from 'react';
2
2
  import { ChopLogicIconName } from '../../enums';
3
- import { ChopLogicTheme } from '../../models';
4
3
  type ClearInputButtonProps = {
5
4
  onClick: (event: React.MouseEvent<HTMLButtonElement>) => void;
6
5
  label: string;
7
6
  icon: ChopLogicIconName;
8
7
  disabled?: boolean;
9
- theme: ChopLogicTheme;
10
8
  };
11
9
  declare const InputInnerButton: React.FC<ClearInputButtonProps>;
12
10
  export default InputInnerButton;
@@ -1,10 +1,8 @@
1
1
  import { default as React, PropsWithChildren } from 'react';
2
- import { ChopLogicTheme } from '../../models';
3
2
  type ChopLogicLabelProps = {
4
3
  label: string;
5
4
  required: boolean;
6
5
  inputId: string;
7
- theme: ChopLogicTheme;
8
6
  isTextHidden?: boolean;
9
7
  icon?: React.ReactElement;
10
8
  iconPosition?: 'left' | 'right';
@@ -1,4 +1,4 @@
1
1
  export declare enum ChopLogicThemeMode {
2
- Light = "light",
3
- Dark = "dark"
2
+ Light = "cl-components-light-theme",
3
+ Dark = "cl-components-dark-theme"
4
4
  }
@@ -1,4 +1,3 @@
1
- export { useChopLogicTheme } from './use-chop-logic-theme';
2
1
  export { useClickOutside } from './use-click-outside';
3
2
  export { useContainerDimensions } from './use-container-dimensions';
4
3
  export { useElementIds } from './use-element-ids';
@@ -8,3 +7,4 @@ export { useMount } from './use-mount';
8
7
  export { useResetFormInput } from './use-reset-form-input';
9
8
  export { useTooltipPosition } from './use-tooltip-position';
10
9
  export { useWindowDimensions } from './use-window-dimensions';
10
+ export { useChopLogicTheme } from './use-chop-logic-theme';
@@ -1 +1 @@
1
- export declare const useChopLogicTheme: () => import('../..').ChopLogicTheme;
1
+ export declare const useChopLogicTheme: () => import('../../contexts/theme/context').ChopLogicThemeContextProps;