pixelize-design-library 2.3.22 → 2.4.1-beta.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.
- package/.claude/settings.local.json +51 -0
- package/.cursor/TASK-SETUP.md +43 -0
- package/.cursor/agents/be-impl.md +37 -0
- package/.cursor/agents/fe-impl.md +39 -0
- package/.cursor/agents/task-plan.md +56 -0
- package/.cursor/agents/test-create.md +31 -0
- package/.cursor/agents/test-exec.md +26 -0
- package/.cursor/hooks/task-hint.env +1 -0
- package/.cursor/hooks/task-skill-nudge.sh +71 -0
- package/.cursor/hooks/task-slash-guard.sh +31 -0
- package/.cursor/hooks.json +13 -0
- package/.cursor/modules/account-management/MODULE.md +41 -0
- package/.cursor/modules/buttons/MODULE.md +47 -0
- package/.cursor/modules/cards/MODULE.md +55 -0
- package/.cursor/modules/charts/MODULE.md +40 -0
- package/.cursor/modules/common/MODULE.md +36 -0
- package/.cursor/modules/contact-auth/MODULE.md +19 -0
- package/.cursor/modules/data-display/MODULE.md +42 -0
- package/.cursor/modules/feedback/MODULE.md +38 -0
- package/.cursor/modules/form/MODULE.md +13 -0
- package/.cursor/modules/inputs-basic/MODULE.md +42 -0
- package/.cursor/modules/inputs-date-file/MODULE.md +67 -0
- package/.cursor/modules/inputs-select/MODULE.md +89 -0
- package/.cursor/modules/inputs-toggle/MODULE.md +24 -0
- package/.cursor/modules/kanban/MODULE.md +22 -0
- package/.cursor/modules/layout-navigation/MODULE.md +319 -0
- package/.cursor/modules/overlays/MODULE.md +82 -0
- package/.cursor/modules/playground/MODULE.md +28 -0
- package/.cursor/modules/table/MODULE.md +84 -0
- package/.cursor/modules/theme/MODULE.md +431 -0
- package/.cursor/modules/types-exports/MODULE.md +17 -0
- package/.cursor/modules/utility-ui/MODULE.md +50 -0
- package/.cursor/modules/utils-hooks/MODULE.md +35 -0
- package/.cursor/pixelize-task-statusline.sh +64 -0
- package/.cursor/plans/blocked/.gitkeep +0 -0
- package/.cursor/plans/current.md +12 -0
- package/.cursor/plans/current.theme-tokens-dark-mode.md +77 -0
- package/.cursor/plans/current.theme-tokens-dark.md +155 -0
- package/.cursor/plans/done/.gitkeep +0 -0
- package/.cursor/rules +31 -0
- package/.cursor/skills/task/SKILL.md +167 -0
- package/CLAUDE.md +148 -0
- package/README.md +77 -10
- package/__mocks__/styleMock.js +8 -0
- package/coverage/clover.xml +405 -0
- package/coverage/coverage-final.json +16 -0
- package/coverage/coverage-summary.json +50 -0
- package/coverage/lcov-report/Button/Button.tsx.html +244 -0
- package/coverage/lcov-report/Button/index.html +116 -0
- package/coverage/lcov-report/Checkbox/Checkbox.tsx.html +433 -0
- package/coverage/lcov-report/Checkbox/index.html +116 -0
- package/coverage/lcov-report/Common/ErrorMessage.tsx.html +148 -0
- package/coverage/lcov-report/Common/FormLabel.tsx.html +331 -0
- package/coverage/lcov-report/Common/HelperText.tsx.html +124 -0
- package/coverage/lcov-report/Common/index.html +146 -0
- package/coverage/lcov-report/Components/Button/Button.tsx.html +244 -0
- package/coverage/lcov-report/Components/Button/index.html +116 -0
- package/coverage/lcov-report/Components/Checkbox/Checkbox.tsx.html +433 -0
- package/coverage/lcov-report/Components/Checkbox/index.html +116 -0
- package/coverage/lcov-report/Components/Common/ErrorMessage.tsx.html +148 -0
- package/coverage/lcov-report/Components/Common/FormLabel.tsx.html +331 -0
- package/coverage/lcov-report/Components/Common/HelperText.tsx.html +124 -0
- package/coverage/lcov-report/Components/Common/index.html +146 -0
- package/coverage/lcov-report/Components/CustomModulesTable/CustomModulesTable.tsx.html +712 -0
- package/coverage/lcov-report/Components/CustomModulesTable/DeleteModuleModal.tsx.html +343 -0
- package/coverage/lcov-report/Components/CustomModulesTable/EditModuleModal.tsx.html +313 -0
- package/coverage/lcov-report/Components/CustomModulesTable/index.html +146 -0
- package/coverage/lcov-report/Components/Divider/Divider.tsx.html +133 -0
- package/coverage/lcov-report/Components/Divider/index.html +116 -0
- package/coverage/lcov-report/Components/Dropdown/DropDown.tsx.html +994 -0
- package/coverage/lcov-report/Components/Dropdown/index.html +116 -0
- package/coverage/lcov-report/Components/EmptyState/EmptyState.tsx.html +466 -0
- package/coverage/lcov-report/Components/EmptyState/index.html +116 -0
- package/coverage/lcov-report/Components/Header/HeaderActions.tsx.html +373 -0
- package/coverage/lcov-report/Components/Header/index.html +116 -0
- package/coverage/lcov-report/Components/Input/TextInput.tsx.html +487 -0
- package/coverage/lcov-report/Components/Input/index.html +116 -0
- package/coverage/lcov-report/Components/Input/textInputIconSize.ts.html +205 -0
- package/coverage/lcov-report/Components/KanbanBoard/AccountCard.tsx.html +547 -0
- package/coverage/lcov-report/Components/KanbanBoard/AccountRow.tsx.html +190 -0
- package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/KanbanActions.tsx.html +247 -0
- package/coverage/lcov-report/Components/KanbanBoard/KanbanActions/index.html +116 -0
- package/coverage/lcov-report/Components/KanbanBoard/KanbanBoard.tsx.html +3598 -0
- package/coverage/lcov-report/Components/KanbanBoard/MeasuredItem.tsx.html +283 -0
- package/coverage/lcov-report/Components/KanbanBoard/index.html +161 -0
- package/coverage/lcov-report/Components/OrganizationDetails/CreateOrgModal.tsx.html +511 -0
- package/coverage/lcov-report/Components/OrganizationDetails/DeleteOrgModal.tsx.html +334 -0
- package/coverage/lcov-report/Components/OrganizationDetails/OrganizationDetails.tsx.html +1519 -0
- package/coverage/lcov-report/Components/OrganizationDetails/index.html +146 -0
- package/coverage/lcov-report/Components/RolesPermission/DeleteRoleModal.tsx.html +328 -0
- package/coverage/lcov-report/Components/RolesPermission/RolesPermission.tsx.html +1732 -0
- package/coverage/lcov-report/Components/RolesPermission/index.html +131 -0
- package/coverage/lcov-report/Components/SearchSelect/SearchSelect.tsx.html +2575 -0
- package/coverage/lcov-report/Components/SearchSelect/SelectTruncatedLabel.tsx.html +202 -0
- package/coverage/lcov-report/Components/SearchSelect/index.html +146 -0
- package/coverage/lcov-report/Components/SearchSelect/searchSelectSize.ts.html +496 -0
- package/coverage/lcov-report/Components/Select/Select.tsx.html +361 -0
- package/coverage/lcov-report/Components/Select/index.html +116 -0
- package/coverage/lcov-report/Components/SideBar/components/OtherApps.tsx.html +562 -0
- package/coverage/lcov-report/Components/SideBar/components/OverflowTooltipText.tsx.html +346 -0
- package/coverage/lcov-report/Components/SideBar/components/index.html +116 -0
- package/coverage/lcov-report/Components/SignInActivityTable/SignInActivityTable.tsx.html +490 -0
- package/coverage/lcov-report/Components/SignInActivityTable/index.html +116 -0
- package/coverage/lcov-report/Components/Table/components/TableActions.tsx.html +595 -0
- package/coverage/lcov-report/Components/Table/components/TableBody.tsx.html +2212 -0
- package/coverage/lcov-report/Components/Table/components/TableGroupRow.tsx.html +358 -0
- package/coverage/lcov-report/Components/Table/components/TableLoading.tsx.html +358 -0
- package/coverage/lcov-report/Components/Table/components/index.html +161 -0
- package/coverage/lcov-report/Components/Table/settings/ManageColumns.tsx.html +856 -0
- package/coverage/lcov-report/Components/Table/settings/index.html +116 -0
- package/coverage/lcov-report/Components/Tag/Tag.styles.tsx.html +331 -0
- package/coverage/lcov-report/Components/Tag/Tag.tsx.html +256 -0
- package/coverage/lcov-report/Components/Tag/index.html +131 -0
- package/coverage/lcov-report/Components/ToolTip/ToolTip.tsx.html +286 -0
- package/coverage/lcov-report/Components/ToolTip/index.html +116 -0
- package/coverage/lcov-report/Components/UserDetails/AddUserModal.tsx.html +709 -0
- package/coverage/lcov-report/Components/UserDetails/ChangeRoleModal.tsx.html +505 -0
- package/coverage/lcov-report/Components/UserDetails/DeactivateConfirmModal.tsx.html +379 -0
- package/coverage/lcov-report/Components/UserDetails/UserDetails.tsx.html +1900 -0
- package/coverage/lcov-report/Components/UserDetails/index.html +161 -0
- package/coverage/lcov-report/EmptyState/EmptyState.tsx.html +466 -0
- package/coverage/lcov-report/EmptyState/index.html +116 -0
- package/coverage/lcov-report/Hooks/index.html +116 -0
- package/coverage/lcov-report/Hooks/usePreferences.ts.html +421 -0
- package/coverage/lcov-report/Input/TextInput.tsx.html +487 -0
- package/coverage/lcov-report/Input/index.html +131 -0
- package/coverage/lcov-report/Input/textInputIconSize.ts.html +205 -0
- package/coverage/lcov-report/KanbanBoard.tsx.html +3481 -0
- package/coverage/lcov-report/OrganizationDetails/CreateOrgModal.tsx.html +511 -0
- package/coverage/lcov-report/OrganizationDetails/DeleteOrgModal.tsx.html +334 -0
- package/coverage/lcov-report/OrganizationDetails/OrganizationDetails.tsx.html +1519 -0
- package/coverage/lcov-report/OrganizationDetails/index.html +146 -0
- package/coverage/lcov-report/RolesPermission/DeleteRoleModal.tsx.html +328 -0
- package/coverage/lcov-report/RolesPermission/RolesPermission.tsx.html +1732 -0
- package/coverage/lcov-report/RolesPermission/index.html +116 -0
- package/coverage/lcov-report/SearchSelect/SearchSelect.tsx.html +2575 -0
- package/coverage/lcov-report/SearchSelect/SelectTruncatedLabel.tsx.html +202 -0
- package/coverage/lcov-report/SearchSelect/index.html +146 -0
- package/coverage/lcov-report/SearchSelect/searchSelectSize.ts.html +496 -0
- package/coverage/lcov-report/Table/CompactSelect.tsx.html +379 -0
- package/coverage/lcov-report/Table/Components/ActiveFilters.tsx.html +514 -0
- package/coverage/lcov-report/Table/Components/HeaderActions.tsx.html +373 -0
- package/coverage/lcov-report/Table/Components/Pagination.tsx.html +574 -0
- package/coverage/lcov-report/Table/Components/TableActions.tsx.html +574 -0
- package/coverage/lcov-report/Table/Components/TableBody.tsx.html +1027 -0
- package/coverage/lcov-report/Table/Components/TableFilters.tsx.html +397 -0
- package/coverage/lcov-report/Table/Components/TableHeader.tsx.html +1060 -0
- package/coverage/lcov-report/Table/Components/TableLoading.tsx.html +361 -0
- package/coverage/lcov-report/Table/Components/TableSearch.tsx.html +337 -0
- package/coverage/lcov-report/Table/Components/index.html +266 -0
- package/coverage/lcov-report/Table/Components/useDebounce.ts.html +178 -0
- package/coverage/lcov-report/Table/Components/useTable.ts.html +778 -0
- package/coverage/lcov-report/Table/LeftFilterPane.tsx.html +1810 -0
- package/coverage/lcov-report/Table/SelectOperationControls.tsx.html +178 -0
- package/coverage/lcov-report/Table/Table.tsx.html +1567 -0
- package/coverage/lcov-report/Table/TableProps.tsx.html +658 -0
- package/coverage/lcov-report/Table/TableSettings/ManageColumns.tsx.html +619 -0
- package/coverage/lcov-report/Table/TableSettings/TableFilters.tsx.html +229 -0
- package/coverage/lcov-report/Table/TableSettings/TableSettings.tsx.html +532 -0
- package/coverage/lcov-report/Table/TableSettings/index.html +146 -0
- package/coverage/lcov-report/Table/TableToDo.tsx.html +973 -0
- package/coverage/lcov-report/Table/TextOperationControls.tsx.html +271 -0
- package/coverage/lcov-report/Table/filterTypes.ts.html +97 -0
- package/coverage/lcov-report/Table/index.html +176 -0
- package/coverage/lcov-report/Table/settings/ManageColumns.tsx.html +856 -0
- package/coverage/lcov-report/Table/settings/index.html +116 -0
- package/coverage/lcov-report/Tag/Tag.tsx.html +256 -0
- package/coverage/lcov-report/Tag/index.html +116 -0
- package/coverage/lcov-report/Theme/buildBrandTokens.ts.html +175 -0
- package/coverage/lcov-report/Theme/chartColorsFromTheme.ts.html +214 -0
- package/coverage/lcov-report/Theme/index.html +131 -0
- package/coverage/lcov-report/Theme/useCustomTheme.ts.html +100 -0
- package/coverage/lcov-report/ToolTip/ToolTip.tsx.html +286 -0
- package/coverage/lcov-report/ToolTip/index.html +116 -0
- package/coverage/lcov-report/UserDetails/AddUserModal.tsx.html +709 -0
- package/coverage/lcov-report/UserDetails/ChangeRoleModal.tsx.html +505 -0
- package/coverage/lcov-report/UserDetails/index.html +116 -0
- package/coverage/lcov-report/Utils/functions.ts.html +106 -0
- package/coverage/lcov-report/Utils/index.html +116 -0
- package/coverage/lcov-report/Utils/table.ts.html +1189 -0
- package/coverage/lcov-report/base.css +224 -0
- package/coverage/lcov-report/block-navigation.js +87 -0
- package/coverage/lcov-report/favicon.png +0 -0
- package/coverage/lcov-report/index.html +251 -0
- package/coverage/lcov-report/prettify.css +1 -0
- package/coverage/lcov-report/prettify.js +2 -0
- package/coverage/lcov-report/sort-arrow-sprite.png +0 -0
- package/coverage/lcov-report/sorter.js +210 -0
- package/coverage/lcov.info +981 -0
- package/dist/App.d.ts +4 -0
- package/dist/App.d.ts.map +1 -1
- package/dist/App.js +95 -0
- package/dist/Assets/defaultLogo.d.ts.map +1 -1
- package/dist/Assets/defaultLogo.js +1 -3
- package/dist/Assets/defaultLogo.tsx +26 -0
- package/dist/Components/Accordion/Accordion.d.ts.map +1 -1
- package/dist/Components/Accordion/Accordion.js +15 -12
- package/dist/Components/Accordion/accordionColors.d.ts +6 -0
- package/dist/Components/Accordion/accordionColors.d.ts.map +1 -0
- package/dist/Components/Accordion/accordionColors.js +20 -0
- package/dist/Components/AlertDialog/AlertDialog.d.ts.map +1 -1
- package/dist/Components/AlertDialog/AlertDialog.js +4 -1
- package/dist/Components/Apexcharts/ApexBarChart/ApexBarChart.d.ts.map +1 -1
- package/dist/Components/Apexcharts/ApexBarChart/ApexBarChart.js +5 -1
- package/dist/Components/Apexcharts/ApexLineChart/ApexLineChart.d.ts.map +1 -1
- package/dist/Components/Apexcharts/ApexLineChart/ApexLineChart.js +6 -4
- package/dist/Components/Apexcharts/ApexPieChart/ApexPieChart.d.ts.map +1 -1
- package/dist/Components/Apexcharts/ApexPieChart/ApexPieChart.js +5 -1
- package/dist/Components/Apexcharts/ApexPolarCharts/ApexPolarCharts.d.ts.map +1 -1
- package/dist/Components/Apexcharts/ApexPolarCharts/ApexPolarCharts.js +5 -1
- package/dist/Components/Button/Button.styles.d.ts.map +1 -1
- package/dist/Components/Button/Button.styles.js +100 -47
- package/dist/Components/ButtonGroupIcon/ButtonGroupIcon.d.ts.map +1 -1
- package/dist/Components/ButtonGroupIcon/ButtonGroupIcon.js +11 -3
- package/dist/Components/Card/PaymentCard/PaymentCard.d.ts.map +1 -1
- package/dist/Components/Card/PaymentCard/PaymentCard.js +17 -12
- package/dist/Components/Checkbox/Checkbox.d.ts.map +1 -1
- package/dist/Components/Checkbox/Checkbox.js +2 -1
- package/dist/Components/Common/ErrorComponent.d.ts.map +1 -1
- package/dist/Components/Common/ErrorComponent.js +7 -3
- package/dist/Components/Common/ErrorMessage.d.ts.map +1 -1
- package/dist/Components/Common/ErrorMessage.js +7 -1
- package/dist/Components/Common/FormLabel.d.ts.map +1 -1
- package/dist/Components/Common/FormLabel.js +7 -1
- package/dist/Components/Common/Label.d.ts.map +1 -1
- package/dist/Components/Common/Label.js +4 -2
- package/dist/Components/Common/fieldStyles.d.ts.map +1 -1
- package/dist/Components/Common/fieldStyles.js +3 -1
- package/dist/Components/CopyButton/CopyButton.d.ts.map +1 -1
- package/dist/Components/CopyButton/CopyButton.js +14 -6
- package/dist/Components/CustomModulesTable/CustomModulesTable.d.ts.map +1 -1
- package/dist/Components/CustomModulesTable/CustomModulesTable.js +9 -6
- package/dist/Components/CustomModulesTable/DeleteModuleModal.d.ts.map +1 -1
- package/dist/Components/CustomModulesTable/DeleteModuleModal.js +2 -2
- package/dist/Components/CustomModulesTable/EditModuleModal.d.ts.map +1 -1
- package/dist/Components/CustomModulesTable/EditModuleModal.js +2 -2
- package/dist/Components/DatePicker/CalendarPanel.d.ts.map +1 -1
- package/dist/Components/DatePicker/CalendarPanel.js +13 -4
- package/dist/Components/DatePicker/DatePicker.js +1 -1
- package/dist/Components/DatePicker/RangeDatePicker.d.ts.map +1 -1
- package/dist/Components/DatePicker/RangeDatePicker.js +1 -1
- package/dist/Components/DatePicker/SingleDatePicker.d.ts.map +1 -1
- package/dist/Components/DatePicker/SingleDatePicker.js +11 -9
- package/dist/Components/DatePicker/TimeOnlyPicker.d.ts.map +1 -1
- package/dist/Components/DatePicker/TimeOnlyPicker.js +5 -3
- package/dist/Components/DatePicker/TimePicker.d.ts.map +1 -1
- package/dist/Components/DatePicker/TimePicker.js +14 -2
- package/dist/Components/DatePicker/TimePickerInput.d.ts.map +1 -1
- package/dist/Components/DatePicker/TimePickerInput.js +9 -1
- package/dist/Components/Drawer/Drawer.d.ts.map +1 -1
- package/dist/Components/Drawer/Drawer.js +4 -1
- package/dist/Components/Dropdown/DropDown.js +5 -5
- package/dist/Components/Editor/Editor.d.ts.map +1 -1
- package/dist/Components/Editor/Editor.js +32 -2
- package/dist/Components/Editor/joditThemeVars.d.ts +21 -0
- package/dist/Components/Editor/joditThemeVars.d.ts.map +1 -0
- package/dist/Components/Editor/joditThemeVars.js +70 -0
- package/dist/Components/EmailCards/VerifyEmailOtp/VerifyEmailOtp.d.ts.map +1 -1
- package/dist/Components/EmailCards/VerifyEmailOtp/VerifyEmailOtp.js +5 -1
- package/dist/Components/EmptyState/EmptyState.js +3 -3
- package/dist/Components/FieldSelectModal/FieldSelectModal.d.ts.map +1 -1
- package/dist/Components/FieldSelectModal/FieldSelectModal.js +4 -2
- package/dist/Components/FilePreview/FilePreview.d.ts.map +1 -1
- package/dist/Components/FilePreview/FilePreview.js +7 -1
- package/dist/Components/FileUpload/FileUpload.js +4 -4
- package/dist/Components/FileUploader/FileUploader.d.ts.map +1 -1
- package/dist/Components/FileUploader/FileUploader.js +7 -2
- package/dist/Components/FilterSidebar/FilterSidebar.d.ts.map +1 -1
- package/dist/Components/FilterSidebar/FilterSidebar.js +166 -142
- package/dist/Components/FilterSidebar/filterHoverStyle.d.ts +12 -0
- package/dist/Components/FilterSidebar/filterHoverStyle.d.ts.map +1 -0
- package/dist/Components/FilterSidebar/filterHoverStyle.js +14 -0
- package/dist/Components/Form/FormWrapper.js +2 -2
- package/dist/Components/Header/Header.d.ts +17 -0
- package/dist/Components/Header/Header.d.ts.map +1 -1
- package/dist/Components/Header/Header.js +34 -6
- package/dist/Components/Header/HeaderActions.d.ts.map +1 -1
- package/dist/Components/Header/HeaderActions.js +3 -2
- package/dist/Components/Header/components/desktopMenu.d.ts.map +1 -1
- package/dist/Components/Header/components/desktopMenu.js +21 -5
- package/dist/Components/Input/Input/Input.d.ts.map +1 -1
- package/dist/Components/Input/Input/Input.js +6 -2
- package/dist/Components/Input/Switch/InputSwitch.d.ts.map +1 -1
- package/dist/Components/Input/Switch/InputSwitch.js +4 -2
- package/dist/Components/Input/TextInput.styles.d.ts.map +1 -1
- package/dist/Components/Input/TextInput.styles.js +6 -1
- package/dist/Components/InputTextArea/InputTextArea.style.d.ts.map +1 -1
- package/dist/Components/InputTextArea/InputTextArea.style.js +4 -1
- package/dist/Components/KanbanBoard/AccountCard.js +4 -4
- package/dist/Components/LazyWrapper/LazyWrapper.js +1 -2
- package/dist/Components/Modal/Modal.d.ts.map +1 -1
- package/dist/Components/Modal/Modal.js +4 -1
- package/dist/Components/MoreItems/MoreItems.d.ts.map +1 -1
- package/dist/Components/MoreItems/MoreItems.js +10 -4
- package/dist/Components/MultiSelect/MultiSelect.d.ts.map +1 -1
- package/dist/Components/MultiSelect/MultiSelect.js +5 -2
- package/dist/Components/NavigationBar/NavigationBar.d.ts.map +1 -1
- package/dist/Components/NavigationBar/NavigationBar.js +8 -2
- package/dist/Components/NoteTextArea/NoteTextArea.d.ts.map +1 -1
- package/dist/Components/NoteTextArea/NoteTextArea.js +5 -2
- package/dist/Components/Notification/Notification.d.ts.map +1 -1
- package/dist/Components/Notification/Notification.js +9 -5
- package/dist/Components/NumberInput/NumberInput.styles.d.ts.map +1 -1
- package/dist/Components/NumberInput/NumberInput.styles.js +4 -1
- package/dist/Components/OrgSwitcher/OrgSwitcher.d.ts.map +1 -1
- package/dist/Components/OrgSwitcher/OrgSwitcher.js +14 -7
- package/dist/Components/OrganizationDetails/CreateOrgModal.d.ts.map +1 -1
- package/dist/Components/OrganizationDetails/CreateOrgModal.js +1 -1
- package/dist/Components/OrganizationDetails/DeleteOrgModal.js +2 -2
- package/dist/Components/OrganizationDetails/OrganizationDetails.js +11 -11
- package/dist/Components/PdfViewer/PdfViewer.js +1 -2
- package/dist/Components/PinInput/PinInput.d.ts.map +1 -1
- package/dist/Components/PinInput/PinInput.js +5 -1
- package/dist/Components/PinInputs/PinInputs.d.ts.map +1 -1
- package/dist/Components/PinInputs/PinInputs.js +3 -1
- package/dist/Components/ProductCard/ProductCard.js +1 -1
- package/dist/Components/ProductCard/ProductPrice.d.ts.map +1 -1
- package/dist/Components/ProductCard/ProductPrice.js +7 -4
- package/dist/Components/ProductCard/ProductReview.d.ts.map +1 -1
- package/dist/Components/ProductCard/ProductReview.js +7 -3
- package/dist/Components/ProductCard/ProductTags.js +1 -1
- package/dist/Components/ProductDetails/ProductDtlPrice.d.ts.map +1 -1
- package/dist/Components/ProductDetails/ProductDtlPrice.js +4 -1
- package/dist/Components/ProductDetails/ProductImageSlider.js +4 -4
- package/dist/Components/ProfilePhotoViewer/ProfilePhotoViewer.d.ts.map +1 -1
- package/dist/Components/ProfilePhotoViewer/ProfilePhotoViewer.js +10 -7
- package/dist/Components/Reorder/Reorder.js +2 -1
- package/dist/Components/RolesPermission/DeleteRoleModal.d.ts.map +1 -1
- package/dist/Components/RolesPermission/DeleteRoleModal.js +4 -2
- package/dist/Components/RolesPermission/RolesPermission.js +6 -6
- package/dist/Components/SearchSelect/SearchSelect.d.ts.map +1 -1
- package/dist/Components/SearchSelect/SearchSelect.js +4 -4
- package/dist/Components/Select/Select.styles.d.ts.map +1 -1
- package/dist/Components/Select/Select.styles.js +4 -1
- package/dist/Components/SelectSearch/SelectSearch.d.ts.map +1 -1
- package/dist/Components/SelectSearch/SelectSearch.js +5 -3
- package/dist/Components/SelectV2/SelectV2.d.ts +3 -0
- package/dist/Components/SelectV2/SelectV2.d.ts.map +1 -0
- package/dist/Components/SelectV2/SelectV2.js +185 -0
- package/dist/Components/SelectV2/SelectV2Props.d.ts +67 -0
- package/dist/Components/SelectV2/SelectV2Props.d.ts.map +1 -0
- package/dist/Components/SelectV2/SelectV2Props.js +2 -0
- package/dist/Components/SideBar/SecondaryBar.d.ts.map +1 -1
- package/dist/Components/SideBar/SecondaryBar.js +14 -3
- package/dist/Components/SideBar/SideBar.d.ts.map +1 -1
- package/dist/Components/SideBar/SideBar.js +19 -5
- package/dist/Components/SideBar/components/MenuItemBox.d.ts.map +1 -1
- package/dist/Components/SideBar/components/MenuItemBox.js +13 -9
- package/dist/Components/SideBar/components/MenuPopoverContent.d.ts.map +1 -1
- package/dist/Components/SideBar/components/MenuPopoverContent.js +7 -2
- package/dist/Components/SideBar/sidebarAccentColors.d.ts +21 -0
- package/dist/Components/SideBar/sidebarAccentColors.d.ts.map +1 -0
- package/dist/Components/SideBar/sidebarAccentColors.js +36 -0
- package/dist/Components/SignInActivityTable/SignInActivityTable.d.ts.map +1 -1
- package/dist/Components/SignInActivityTable/SignInActivityTable.js +7 -6
- package/dist/Components/StageProgress/StageProgress.d.ts.map +1 -1
- package/dist/Components/StageProgress/StageProgress.js +9 -4
- package/dist/Components/StageProgress/StageProgressProps.d.ts.map +1 -1
- package/dist/Components/StageProgress/StageProgressProps.js +13 -4
- package/dist/Components/StageProgress/StepperStage.js +1 -1
- package/dist/Components/Switch/Switch.d.ts.map +1 -1
- package/dist/Components/Switch/Switch.js +5 -3
- package/dist/Components/Table/Table.d.ts.map +1 -1
- package/dist/Components/Table/Table.js +9 -9
- package/dist/Components/Table/TableProps.d.ts +1 -0
- package/dist/Components/Table/TableProps.d.ts.map +1 -1
- package/dist/Components/Table/components/HeaderActions.d.ts.map +1 -1
- package/dist/Components/Table/components/HeaderActions.js +2 -1
- package/dist/Components/Table/components/TableActions.js +1 -1
- package/dist/Components/Table/components/TableBody.d.ts.map +1 -1
- package/dist/Components/Table/components/TableBody.js +21 -15
- package/dist/Components/Table/components/TableHeader.d.ts.map +1 -1
- package/dist/Components/Table/components/TableHeader.js +7 -4
- package/dist/Components/Table/components/tableRowHoverStyle.d.ts +13 -0
- package/dist/Components/Table/components/tableRowHoverStyle.d.ts.map +1 -0
- package/dist/Components/Table/components/tableRowHoverStyle.js +26 -0
- package/dist/Components/Table/filters/CompactSelect.d.ts.map +1 -1
- package/dist/Components/Table/filters/CompactSelect.js +4 -1
- package/dist/Components/Table/filters/LeftFilterPane.d.ts.map +1 -1
- package/dist/Components/Table/filters/LeftFilterPane.js +5 -4
- package/dist/Components/Tag/Tag.styles.d.ts.map +1 -1
- package/dist/Components/Tag/Tag.styles.js +21 -8
- package/dist/Components/Timeline/Timeline.d.ts.map +1 -1
- package/dist/Components/Timeline/Timeline.js +18 -17
- package/dist/Components/Toaster/Toaster.d.ts.map +1 -1
- package/dist/Components/Toaster/Toaster.js +8 -5
- package/dist/Components/Toggle/TableToggle.js +2 -2
- package/dist/Components/ToolTip/ToolTip.d.ts.map +1 -1
- package/dist/Components/ToolTip/ToolTip.js +14 -2
- package/dist/Components/Trail/EditableCell.js +1 -1
- package/dist/Components/UpgradeButton/UpgradeButton.d.ts.map +1 -1
- package/dist/Components/UpgradeButton/UpgradeButton.js +9 -4
- package/dist/Components/UserDetails/AddUserModal.d.ts.map +1 -1
- package/dist/Components/UserDetails/AddUserModal.js +1 -1
- package/dist/Components/UserDetails/ChangeRoleModal.js +2 -2
- package/dist/Components/UserDetails/DeactivateConfirmModal.d.ts.map +1 -1
- package/dist/Components/UserDetails/DeactivateConfirmModal.js +5 -2
- package/dist/Components/UserDetails/UserDetails.d.ts.map +1 -1
- package/dist/Components/UserDetails/UserDetails.js +15 -8
- package/dist/Components/WorkspaceWindow/WorkspaceTrayPreview.d.ts.map +1 -1
- package/dist/Components/WorkspaceWindow/WorkspaceTrayPreview.js +4 -1
- package/dist/Components/WorkspaceWindow/WorkspaceWindow.d.ts +2 -2
- package/dist/Components/WorkspaceWindow/WorkspaceWindow.d.ts.map +1 -1
- package/dist/Components/WorkspaceWindow/WorkspaceWindow.js +29 -4
- package/dist/Components/WorkspaceWindow/WorkspaceWindowProps.d.ts +18 -0
- package/dist/Components/WorkspaceWindow/WorkspaceWindowProps.d.ts.map +1 -1
- package/dist/Layout.d.ts +3 -0
- package/dist/Layout.js +286 -0
- package/dist/Pages/TInput.d.ts +3 -0
- package/dist/Pages/TInput.d.ts.map +1 -0
- package/dist/Pages/TInput.js +20 -0
- package/dist/Pages/accordion.d.ts +3 -0
- package/dist/Pages/accordion.d.ts.map +1 -0
- package/dist/Pages/accordion.js +21 -0
- package/dist/Pages/alertdialog.d.ts +3 -0
- package/dist/Pages/alertdialog.d.ts.map +1 -0
- package/dist/Pages/alertdialog.js +53 -0
- package/dist/Pages/button.d.ts +3 -0
- package/dist/Pages/button.d.ts.map +1 -0
- package/dist/Pages/button.js +32 -0
- package/dist/Pages/card.d.ts +3 -0
- package/dist/Pages/card.d.ts.map +1 -0
- package/dist/Pages/card.js +102 -0
- package/dist/Pages/chart.d.ts +4 -0
- package/dist/Pages/chart.d.ts.map +1 -0
- package/dist/Pages/chart.js +25 -0
- package/dist/Pages/checkbox.d.ts +3 -0
- package/dist/Pages/checkbox.d.ts.map +1 -0
- package/dist/Pages/checkbox.js +11 -0
- package/dist/Pages/contactForm.d.ts +3 -0
- package/dist/Pages/contactForm.d.ts.map +1 -0
- package/dist/Pages/contactForm.js +15 -0
- package/dist/Pages/customModulesTable.d.ts +4 -0
- package/dist/Pages/customModulesTable.d.ts.map +1 -0
- package/dist/Pages/customModulesTable.js +25 -0
- package/dist/Pages/datePick.d.ts +3 -0
- package/dist/Pages/datePick.d.ts.map +1 -0
- package/dist/Pages/datePick.js +49 -0
- package/dist/Pages/drawer.d.ts +3 -0
- package/dist/Pages/drawer.d.ts.map +1 -0
- package/dist/Pages/drawer.js +53 -0
- package/dist/Pages/dropdown.d.ts +3 -0
- package/dist/Pages/dropdown.d.ts.map +1 -0
- package/dist/Pages/dropdown.js +21 -0
- package/dist/Pages/editor.d.ts +3 -0
- package/dist/Pages/editor.d.ts.map +1 -0
- package/dist/Pages/editor.js +13 -0
- package/dist/Pages/feedback.d.ts +2 -0
- package/dist/Pages/feedback.d.ts.map +1 -0
- package/dist/Pages/feedback.js +12 -0
- package/dist/Pages/fileUpload.d.ts +2 -0
- package/dist/Pages/fileUpload.d.ts.map +1 -0
- package/dist/Pages/fileUpload.js +36 -0
- package/dist/Pages/input.d.ts +3 -0
- package/dist/Pages/input.d.ts.map +1 -0
- package/dist/Pages/input.js +48 -0
- package/dist/Pages/kanbanboard.d.ts +3 -0
- package/dist/Pages/kanbanboard.d.ts.map +1 -0
- package/dist/Pages/kanbanboard.js +182 -0
- package/dist/Pages/modal.d.ts +3 -0
- package/dist/Pages/modal.d.ts.map +1 -0
- package/dist/Pages/modal.js +61 -0
- package/dist/Pages/multiSelect.d.ts +3 -0
- package/dist/Pages/multiSelect.d.ts.map +1 -0
- package/dist/Pages/multiSelect.js +22 -0
- package/dist/Pages/noteArea.d.ts +3 -0
- package/dist/Pages/noteArea.d.ts.map +1 -0
- package/dist/Pages/noteArea.js +26 -0
- package/dist/Pages/notification.d.ts +3 -0
- package/dist/Pages/notification.d.ts.map +1 -0
- package/dist/Pages/notification.js +37 -0
- package/dist/Pages/numberInput.d.ts +3 -0
- package/dist/Pages/numberInput.d.ts.map +1 -0
- package/dist/Pages/numberInput.js +16 -0
- package/dist/Pages/orgSwitcher.d.ts +4 -0
- package/dist/Pages/orgSwitcher.d.ts.map +1 -0
- package/dist/Pages/orgSwitcher.js +36 -0
- package/dist/Pages/organizationDetails.d.ts +4 -0
- package/dist/Pages/organizationDetails.d.ts.map +1 -0
- package/dist/Pages/organizationDetails.js +64 -0
- package/dist/Pages/photoViewer.d.ts +3 -0
- package/dist/Pages/photoViewer.d.ts.map +1 -0
- package/dist/Pages/photoViewer.js +12 -0
- package/dist/Pages/pinInputs.d.ts +3 -0
- package/dist/Pages/pinInputs.d.ts.map +1 -0
- package/dist/Pages/pinInputs.js +11 -0
- package/dist/Pages/productCaard.d.ts +3 -0
- package/dist/Pages/productCaard.d.ts.map +1 -0
- package/dist/Pages/productCaard.js +311 -0
- package/dist/Pages/productDetailCard.d.ts +3 -0
- package/dist/Pages/productDetailCard.d.ts.map +1 -0
- package/dist/Pages/productDetailCard.js +78 -0
- package/dist/Pages/productFilter.d.ts +3 -0
- package/dist/Pages/productFilter.d.ts.map +1 -0
- package/dist/Pages/productFilter.js +148 -0
- package/dist/Pages/progressbar.d.ts +3 -0
- package/dist/Pages/progressbar.d.ts.map +1 -0
- package/dist/Pages/progressbar.js +11 -0
- package/dist/Pages/radioButton.d.ts +3 -0
- package/dist/Pages/radioButton.d.ts.map +1 -0
- package/dist/Pages/radioButton.js +18 -0
- package/dist/Pages/rolesPermission.d.ts +4 -0
- package/dist/Pages/rolesPermission.d.ts.map +1 -0
- package/dist/Pages/rolesPermission.js +144 -0
- package/dist/Pages/search.d.ts +3 -0
- package/dist/Pages/search.d.ts.map +1 -0
- package/dist/Pages/search.js +21 -0
- package/dist/Pages/searchSelect.d.ts +3 -0
- package/dist/Pages/searchSelect.d.ts.map +1 -0
- package/dist/Pages/searchSelect.js +97 -0
- package/dist/Pages/select.d.ts +3 -0
- package/dist/Pages/select.d.ts.map +1 -0
- package/dist/Pages/select.js +20 -0
- package/dist/Pages/selectSearch.d.ts +3 -0
- package/dist/Pages/selectSearch.d.ts.map +1 -0
- package/dist/Pages/selectSearch.js +58 -0
- package/dist/Pages/signInActivityTable.d.ts +4 -0
- package/dist/Pages/signInActivityTable.d.ts.map +1 -0
- package/dist/Pages/signInActivityTable.js +17 -0
- package/dist/Pages/skeleton.d.ts +3 -0
- package/dist/Pages/skeleton.d.ts.map +1 -0
- package/dist/Pages/skeleton.js +12 -0
- package/dist/Pages/stageProgress.d.ts +4 -0
- package/dist/Pages/stageProgress.d.ts.map +1 -0
- package/dist/Pages/stageProgress.js +31 -0
- package/dist/Pages/switch.d.ts +3 -0
- package/dist/Pages/switch.d.ts.map +1 -0
- package/dist/Pages/switch.js +17 -0
- package/dist/Pages/table.d.ts +3 -0
- package/dist/Pages/table.d.ts.map +1 -0
- package/dist/Pages/table.js +182 -0
- package/dist/Pages/tag.d.ts +3 -0
- package/dist/Pages/tag.d.ts.map +1 -0
- package/dist/Pages/tag.js +27 -0
- package/dist/Pages/textArea.d.ts +3 -0
- package/dist/Pages/textArea.d.ts.map +1 -0
- package/dist/Pages/textArea.js +14 -0
- package/dist/Pages/tier1.d.ts +4 -0
- package/dist/Pages/tier1.d.ts.map +1 -0
- package/dist/Pages/tier1.js +86 -0
- package/dist/Pages/timeline.d.ts +3 -0
- package/dist/Pages/timeline.d.ts.map +1 -0
- package/dist/Pages/timeline.js +73 -0
- package/dist/Pages/tooltip.d.ts +3 -0
- package/dist/Pages/tooltip.d.ts.map +1 -0
- package/dist/Pages/tooltip.js +11 -0
- package/dist/Pages/toster.d.ts +3 -0
- package/dist/Pages/toster.d.ts.map +1 -0
- package/dist/Pages/toster.js +53 -0
- package/dist/Pages/upgradeButton.d.ts +4 -0
- package/dist/Pages/upgradeButton.d.ts.map +1 -0
- package/dist/Pages/upgradeButton.js +17 -0
- package/dist/Pages/userDetails.d.ts +4 -0
- package/dist/Pages/userDetails.d.ts.map +1 -0
- package/dist/Pages/userDetails.js +79 -0
- package/dist/Pages/verifyEmail.d.ts +3 -0
- package/dist/Pages/verifyEmail.d.ts.map +1 -0
- package/dist/Pages/verifyEmail.js +17 -0
- package/dist/Theme/chakra/Avatar.styles.d.ts +33 -0
- package/dist/Theme/chakra/Avatar.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Avatar.styles.js +28 -0
- package/dist/Theme/chakra/Drawer.styles.d.ts +32 -0
- package/dist/Theme/chakra/Drawer.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Drawer.styles.js +26 -0
- package/dist/Theme/chakra/Menu.styles.d.ts +70 -0
- package/dist/Theme/chakra/Menu.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Menu.styles.js +50 -0
- package/dist/Theme/chakra/Modal.styles.d.ts +32 -0
- package/dist/Theme/chakra/Modal.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Modal.styles.js +26 -0
- package/dist/Theme/chakra/Popover.styles.d.ts +37 -0
- package/dist/Theme/chakra/Popover.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Popover.styles.js +30 -0
- package/dist/Theme/chakra/Slider.styles.d.ts +31 -0
- package/dist/Theme/chakra/Slider.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Slider.styles.js +25 -0
- package/dist/Theme/chakra/Switch.styles.d.ts +31 -0
- package/dist/Theme/chakra/Switch.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Switch.styles.js +24 -0
- package/dist/Theme/chakra/Tabs.styles.d.ts +43 -0
- package/dist/Theme/chakra/Tabs.styles.d.ts.map +1 -0
- package/dist/Theme/chakra/Tabs.styles.js +41 -0
- package/dist/Theme/chakra/common.web.d.ts +171 -0
- package/dist/Theme/chakra/common.web.d.ts.map +1 -0
- package/dist/Theme/chakra/common.web.js +21 -0
- package/dist/Theme/chakra/componentStyles.d.ts +240 -0
- package/dist/Theme/chakra/componentStyles.d.ts.map +1 -0
- package/dist/Theme/chakra/componentStyles.js +150 -0
- package/dist/Theme/chakra/createBrandTheme.d.ts +18 -0
- package/dist/Theme/chakra/createBrandTheme.d.ts.map +1 -0
- package/dist/Theme/chakra/createBrandTheme.js +78 -0
- package/dist/Theme/chakra/fonts.web.d.ts +42 -0
- package/dist/Theme/chakra/fonts.web.d.ts.map +1 -0
- package/dist/Theme/chakra/fonts.web.js +15 -0
- package/dist/Theme/index.d.ts +29 -8
- package/dist/Theme/index.d.ts.map +1 -1
- package/dist/Theme/index.js +54 -22
- package/dist/Theme/provider/PixelizeThemeProvider.d.ts +46 -0
- package/dist/Theme/provider/PixelizeThemeProvider.d.ts.map +1 -0
- package/dist/Theme/provider/PixelizeThemeProvider.js +124 -0
- package/dist/Theme/provider/ThemeSwitcher.d.ts +8 -0
- package/dist/Theme/provider/ThemeSwitcher.d.ts.map +1 -0
- package/dist/Theme/provider/ThemeSwitcher.js +111 -0
- package/dist/Theme/provider/colorModeStorage.d.ts +10 -0
- package/dist/Theme/provider/colorModeStorage.d.ts.map +1 -0
- package/dist/Theme/provider/colorModeStorage.js +106 -0
- package/dist/Theme/provider/index.d.ts +6 -0
- package/dist/Theme/provider/index.d.ts.map +1 -0
- package/dist/Theme/provider/index.js +9 -0
- package/dist/Theme/provider/useThemeMode.d.ts +3 -0
- package/dist/Theme/provider/useThemeMode.d.ts.map +1 -0
- package/dist/Theme/provider/useThemeMode.js +13 -0
- package/dist/Theme/themeProps.d.ts +10 -373
- package/dist/Theme/themeProps.d.ts.map +1 -1
- package/dist/Theme/tokens/brands/emerald/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/emerald/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/emerald/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/emerald/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/emerald/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/emerald/palette.light.js +135 -0
- package/dist/Theme/tokens/brands/index.d.ts +28 -0
- package/dist/Theme/tokens/brands/index.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/index.js +93 -0
- package/dist/Theme/tokens/brands/lavender/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/lavender/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/lavender/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/lavender/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/lavender/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/lavender/palette.light.js +316 -0
- package/dist/Theme/tokens/brands/meadow/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/meadow/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/meadow/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/meadow/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/meadow/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/meadow/palette.light.js +133 -0
- package/dist/Theme/tokens/brands/radiant/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/radiant/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/radiant/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/radiant/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/radiant/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/radiant/palette.light.js +135 -0
- package/dist/Theme/tokens/brands/rosewood/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/rosewood/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/rosewood/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/rosewood/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/rosewood/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/rosewood/palette.light.js +139 -0
- package/dist/Theme/tokens/brands/skyline/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/skyline/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/skyline/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/skyline/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/skyline/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/skyline/palette.light.js +133 -0
- package/dist/Theme/tokens/brands/slate/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/slate/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/slate/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/slate/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/slate/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/slate/palette.light.js +137 -0
- package/dist/Theme/tokens/brands/storefront/palette.dark.d.ts +7 -0
- package/dist/Theme/tokens/brands/storefront/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/storefront/palette.dark.js +13 -0
- package/dist/Theme/tokens/brands/storefront/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/storefront/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/storefront/palette.light.js +127 -0
- package/dist/Theme/tokens/brands/zinc/palette.dark.d.ts +204 -0
- package/dist/Theme/tokens/brands/zinc/palette.dark.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/zinc/palette.dark.js +204 -0
- package/dist/Theme/tokens/brands/zinc/palette.light.d.ts +375 -0
- package/dist/Theme/tokens/brands/zinc/palette.light.d.ts.map +1 -0
- package/dist/Theme/tokens/brands/zinc/palette.light.js +383 -0
- package/dist/Theme/tokens/builders/accentText.d.ts +56 -0
- package/dist/Theme/tokens/builders/accentText.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/accentText.js +92 -0
- package/dist/Theme/tokens/builders/buildBrandTokens.d.ts +16 -0
- package/dist/Theme/tokens/builders/buildBrandTokens.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/buildBrandTokens.js +33 -0
- package/dist/Theme/tokens/builders/buildDarkPalette.d.ts +23 -0
- package/dist/Theme/tokens/builders/buildDarkPalette.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/buildDarkPalette.js +282 -0
- package/dist/Theme/tokens/builders/chartColorsFromTheme.d.ts +17 -0
- package/dist/Theme/tokens/builders/chartColorsFromTheme.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/chartColorsFromTheme.js +26 -0
- package/dist/Theme/tokens/builders/color.d.ts +50 -0
- package/dist/Theme/tokens/builders/color.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/color.js +156 -0
- package/dist/Theme/tokens/builders/index.d.ts +6 -0
- package/dist/Theme/tokens/builders/index.d.ts.map +1 -0
- package/dist/Theme/tokens/builders/index.js +21 -0
- package/dist/Theme/tokens/index.d.ts +15 -0
- package/dist/Theme/tokens/index.d.ts.map +1 -0
- package/dist/Theme/tokens/index.js +30 -0
- package/dist/Theme/tokens/primitives/breakpoints.d.ts +9 -0
- package/dist/Theme/tokens/primitives/breakpoints.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/breakpoints.js +10 -0
- package/dist/Theme/tokens/primitives/index.d.ts +10 -0
- package/dist/Theme/tokens/primitives/index.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/index.js +27 -0
- package/dist/Theme/tokens/primitives/letterSpacings.d.ts +10 -0
- package/dist/Theme/tokens/primitives/letterSpacings.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/letterSpacings.js +11 -0
- package/dist/Theme/tokens/primitives/lineHeights.d.ts +19 -0
- package/dist/Theme/tokens/primitives/lineHeights.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/lineHeights.js +20 -0
- package/dist/Theme/tokens/primitives/radii.d.ts +13 -0
- package/dist/Theme/tokens/primitives/radii.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/radii.js +14 -0
- package/dist/Theme/tokens/primitives/shadows.d.ts +16 -0
- package/dist/Theme/tokens/primitives/shadows.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/shadows.js +17 -0
- package/dist/Theme/tokens/primitives/sizes.d.ts +63 -0
- package/dist/Theme/tokens/primitives/sizes.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/sizes.js +39 -0
- package/dist/Theme/tokens/primitives/space.d.ts +34 -0
- package/dist/Theme/tokens/primitives/space.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/space.js +35 -0
- package/dist/Theme/tokens/primitives/typography.d.ts +73 -0
- package/dist/Theme/tokens/primitives/typography.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/typography.js +43 -0
- package/dist/Theme/tokens/primitives/zIndices.d.ts +17 -0
- package/dist/Theme/tokens/primitives/zIndices.d.ts.map +1 -0
- package/dist/Theme/tokens/primitives/zIndices.js +18 -0
- package/dist/Theme/tokens/types.d.ts +116 -0
- package/dist/Theme/tokens/types.d.ts.map +1 -0
- package/dist/Theme/tokens/types.js +8 -0
- package/dist/Utils/table.d.ts +9 -2
- package/dist/Utils/table.d.ts.map +1 -1
- package/dist/Utils/table.js +23 -7
- package/dist/bootstrap.d.ts +2 -0
- package/dist/bootstrap.js +16 -0
- package/dist/index.d.ts +13 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +54 -1
- package/eslint.config.js +48 -0
- package/index.html +13 -0
- package/package.json +2 -6
- package/vite.config.ts +13 -0
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.componentStyles = void 0;
|
|
4
|
+
const react_1 = require("@chakra-ui/react");
|
|
5
|
+
const Button_styles_1 = require("../../Components/Button/Button.styles");
|
|
6
|
+
const Checkbox_styles_1 = require("../../Components/Checkbox/Checkbox.styles");
|
|
7
|
+
const TextInput_styles_1 = require("../../Components/Input/TextInput.styles");
|
|
8
|
+
const Select_styles_1 = require("../../Components/Select/Select.styles");
|
|
9
|
+
const Tag_styles_1 = require("../../Components/Tag/Tag.styles");
|
|
10
|
+
const InputTextArea_style_1 = require("../../Components/InputTextArea/InputTextArea.style");
|
|
11
|
+
const NumberInput_styles_1 = require("../../Components/NumberInput/NumberInput.styles");
|
|
12
|
+
const accentText_1 = require("../tokens/builders/accentText");
|
|
13
|
+
const color_1 = require("../tokens/builders/color");
|
|
14
|
+
const Drawer_styles_1 = require("./Drawer.styles");
|
|
15
|
+
const Menu_styles_1 = require("./Menu.styles");
|
|
16
|
+
const Modal_styles_1 = require("./Modal.styles");
|
|
17
|
+
const Popover_styles_1 = require("./Popover.styles");
|
|
18
|
+
const Slider_styles_1 = require("./Slider.styles");
|
|
19
|
+
const Switch_styles_1 = require("./Switch.styles");
|
|
20
|
+
const Tabs_styles_1 = require("./Tabs.styles");
|
|
21
|
+
const Avatar_styles_1 = require("./Avatar.styles");
|
|
22
|
+
// `colorScheme` accepts any Chakra scale, including built-ins we never themed (blackAlpha,
|
|
23
|
+
// whiteAlpha) whose rungs are translucent `rgba(...)` strings, not opaque hex — our contrast
|
|
24
|
+
// math (hexToRgb) throws on those on purpose (see color.ts). Guard so those scales fall back to
|
|
25
|
+
// Chakra's own original fixed rung instead of computing contrast on a color it can't parse.
|
|
26
|
+
const isHexColor = (color) => typeof color === "string" && /^#([0-9a-f]{3}|[0-9a-f]{6})$/i.test(color);
|
|
27
|
+
// Badge isn't its own component family (no Components/Badge/), so its style config lives here —
|
|
28
|
+
// Chakra's stock `solid` variant hardcodes a white label on a variable fill, same AA gap Tag had.
|
|
29
|
+
const Badge = {
|
|
30
|
+
variants: {
|
|
31
|
+
solid: ({ theme, colorScheme = "gray" }) => {
|
|
32
|
+
var _a, _b, _c, _d, _e, _f, _g, _h;
|
|
33
|
+
const swatch = (_d = (_b = (_a = theme.colors) === null || _a === void 0 ? void 0 : _a[colorScheme]) !== null && _b !== void 0 ? _b : (_c = theme.colors) === null || _c === void 0 ? void 0 : _c.gray) !== null && _d !== void 0 ? _d : {};
|
|
34
|
+
const bg = swatch === null || swatch === void 0 ? void 0 : swatch[500];
|
|
35
|
+
const white = (_f = (_e = theme.colors) === null || _e === void 0 ? void 0 : _e.white) !== null && _f !== void 0 ? _f : "#fff";
|
|
36
|
+
const black = (_h = (_g = theme.colors) === null || _g === void 0 ? void 0 : _g.black) !== null && _h !== void 0 ? _h : "#000";
|
|
37
|
+
return {
|
|
38
|
+
bg,
|
|
39
|
+
color: isHexColor(bg) ? (0, accentText_1.onFilled)(bg, white, black) : swatch === null || swatch === void 0 ? void 0 : swatch[800],
|
|
40
|
+
};
|
|
41
|
+
},
|
|
42
|
+
// Chakra's stock `subtle` picks its bg/color pair via `mode()`, keyed to Chakra's own
|
|
43
|
+
// colorMode — which this app never toggles (dark mode swaps the palette object instead), so
|
|
44
|
+
// it always takes the light-mode branch. Applied to our mode-reversed dark scales, that
|
|
45
|
+
// branch's fixed rung pair (100/800) measures 4.06 in dark mode, just under AA.
|
|
46
|
+
subtle: ({ theme, colorScheme = "gray" }) => {
|
|
47
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j;
|
|
48
|
+
const swatch = (_d = (_b = (_a = theme.colors) === null || _a === void 0 ? void 0 : _a[colorScheme]) !== null && _b !== void 0 ? _b : (_c = theme.colors) === null || _c === void 0 ? void 0 : _c.gray) !== null && _d !== void 0 ? _d : {};
|
|
49
|
+
const bg = (_e = swatch === null || swatch === void 0 ? void 0 : swatch[100]) !== null && _e !== void 0 ? _e : swatch === null || swatch === void 0 ? void 0 : swatch[50];
|
|
50
|
+
if (!isHexColor(bg))
|
|
51
|
+
return { bg, color: swatch === null || swatch === void 0 ? void 0 : swatch[800] };
|
|
52
|
+
// accentTextOnCanvas keeps brand hue by trying this scale's own rungs first, but some
|
|
53
|
+
// narrow-gamut hues (e.g. yellow) don't reach far enough at either end to clear AA against
|
|
54
|
+
// every bg they can land on in dark mode (measured 4.42 for a reversed-yellow badge) — its
|
|
55
|
+
// own doc admits it falls back to "the most extreme rung" rather than guaranteeing AA. Verify
|
|
56
|
+
// the candidate actually clears AA; if not, drop brand hue for the guaranteed white/black ink
|
|
57
|
+
// (onFilled is provably >=4.5 against any bg) rather than ship a near-miss.
|
|
58
|
+
const accent = (0, accentText_1.accentTextOnCanvas)(swatch, bg);
|
|
59
|
+
if ((0, color_1.contrastRatio)(accent, bg) >= 4.5)
|
|
60
|
+
return { bg, color: accent };
|
|
61
|
+
const white = (_g = (_f = theme.colors) === null || _f === void 0 ? void 0 : _f.white) !== null && _g !== void 0 ? _g : "#fff";
|
|
62
|
+
const black = (_j = (_h = theme.colors) === null || _h === void 0 ? void 0 : _h.black) !== null && _j !== void 0 ? _j : "#000";
|
|
63
|
+
return { bg, color: (0, accentText_1.onFilled)(bg, white, black) };
|
|
64
|
+
},
|
|
65
|
+
},
|
|
66
|
+
defaultProps: {
|
|
67
|
+
variant: "subtle",
|
|
68
|
+
colorScheme: "gray",
|
|
69
|
+
},
|
|
70
|
+
};
|
|
71
|
+
// Chakra's stock FormErrorMessage hardcodes `colors.red.500` (our own `red[500]`, since
|
|
72
|
+
// `createBrandTheme` sets `theme.colors = palette`) — same AA gap as our own ErrorMessage/
|
|
73
|
+
// ErrorComponent, fixed the same way rather than leaving Chakra's raw usage (e.g. FeedbackForm)
|
|
74
|
+
// unfixed.
|
|
75
|
+
const FormError = {
|
|
76
|
+
baseStyle: ({ theme }) => {
|
|
77
|
+
var _a, _b, _c, _d;
|
|
78
|
+
// `icon` (FormErrorIcon) shares the same AA gap as `text` — both must be fixed together or
|
|
79
|
+
// the icon stays on Chakra's raw `red.500`.
|
|
80
|
+
const color = (0, accentText_1.accentTextOnCanvas)((_a = theme.colors) === null || _a === void 0 ? void 0 : _a.red, (_d = (_c = (_b = theme.colors) === null || _b === void 0 ? void 0 : _b.backgroundColor) === null || _c === void 0 ? void 0 : _c.main) !== null && _d !== void 0 ? _d : "#ffffff");
|
|
81
|
+
return {
|
|
82
|
+
text: { color },
|
|
83
|
+
icon: { color },
|
|
84
|
+
};
|
|
85
|
+
},
|
|
86
|
+
};
|
|
87
|
+
const $tooltipBg = (0, react_1.cssVar)("tooltip-bg");
|
|
88
|
+
const $tooltipFg = (0, react_1.cssVar)("tooltip-fg");
|
|
89
|
+
/**
|
|
90
|
+
* Chakra's own Tooltip baseStyle hardcodes `--tooltip-bg`/`--tooltip-fg` to `colors.gray.700`/
|
|
91
|
+
* `colors.whiteAlpha.900` (gated behind `_dark`, which this theme-swap app never triggers — see
|
|
92
|
+
* Menu.styles.ts / createBrandTheme's colorMode comment). Our reversed dark gray ramp makes
|
|
93
|
+
* `gray.700` LIGHT (~L79), so every bare `<Tooltip>` renders a near-white bubble with near-white
|
|
94
|
+
* text on the dark canvas — invisible. A tooltip floats over arbitrary content in either mode, so
|
|
95
|
+
* unlike Menu/Modal/Drawer (which follow the canvas) it needs a FIXED high-contrast chip that
|
|
96
|
+
* doesn't invert with the palette — `black`/`white` are exactly the two tokens `buildDarkPalette`
|
|
97
|
+
* deliberately never remaps, so they stay a stable dark-bg/white-text pair in both modes.
|
|
98
|
+
*/
|
|
99
|
+
const Tooltip = {
|
|
100
|
+
baseStyle: ({ theme }) => {
|
|
101
|
+
var _a, _b, _c, _d;
|
|
102
|
+
return ({
|
|
103
|
+
[$tooltipBg.variable]: (_b = (_a = theme.colors) === null || _a === void 0 ? void 0 : _a.black) !== null && _b !== void 0 ? _b : "colors.gray.700",
|
|
104
|
+
[$tooltipFg.variable]: (_d = (_c = theme.colors) === null || _c === void 0 ? void 0 : _c.white) !== null && _d !== void 0 ? _d : "colors.whiteAlpha.900",
|
|
105
|
+
});
|
|
106
|
+
},
|
|
107
|
+
};
|
|
108
|
+
const $skeletonStart = (0, react_1.cssVar)("skeleton-start-color");
|
|
109
|
+
const $skeletonEnd = (0, react_1.cssVar)("skeleton-end-color");
|
|
110
|
+
/**
|
|
111
|
+
* Chakra's own Skeleton baseStyle hardcodes `--skeleton-start-color`/`--skeleton-end-color` to
|
|
112
|
+
* `colors.gray.100`/`colors.gray.400` the same `_dark`-gated way Menu/Popover did (Wave G/H), so
|
|
113
|
+
* every bare `<Skeleton>` shimmers between two near-white tones on the dark canvas. Fixed at the
|
|
114
|
+
* theme level rather than in `Skeletons.tsx`: Chakra's `Skeleton` only writes these vars from its
|
|
115
|
+
* `startColor`/`endColor` PROPS when a caller actually passes them (`useToken` on an empty string
|
|
116
|
+
* resolves to `undefined`, so the prop-driven `cssVarStyles` object stays empty) — an explicit
|
|
117
|
+
* prop still wins via that mechanism, this only supplies the default the base style already owns.
|
|
118
|
+
*/
|
|
119
|
+
const Skeleton = {
|
|
120
|
+
baseStyle: ({ theme }) => {
|
|
121
|
+
var _a, _b, _c, _d, _e, _f;
|
|
122
|
+
return ({
|
|
123
|
+
[$skeletonStart.variable]: (_c = (_b = (_a = theme.colors) === null || _a === void 0 ? void 0 : _a.gray) === null || _b === void 0 ? void 0 : _b[100]) !== null && _c !== void 0 ? _c : "colors.gray.100",
|
|
124
|
+
[$skeletonEnd.variable]: (_f = (_e = (_d = theme.colors) === null || _d === void 0 ? void 0 : _d.gray) === null || _e === void 0 ? void 0 : _e[300]) !== null && _f !== void 0 ? _f : "colors.gray.400",
|
|
125
|
+
background: $skeletonStart.reference,
|
|
126
|
+
borderColor: $skeletonEnd.reference,
|
|
127
|
+
});
|
|
128
|
+
},
|
|
129
|
+
};
|
|
130
|
+
exports.componentStyles = {
|
|
131
|
+
Checkbox: Checkbox_styles_1.Checkbox,
|
|
132
|
+
Input: TextInput_styles_1.Input,
|
|
133
|
+
Button: Button_styles_1.Button,
|
|
134
|
+
Select: Select_styles_1.Select,
|
|
135
|
+
Tag: Tag_styles_1.Tag,
|
|
136
|
+
Textarea: InputTextArea_style_1.Textarea,
|
|
137
|
+
NumberInput: NumberInput_styles_1.NumberInput,
|
|
138
|
+
Badge,
|
|
139
|
+
FormError,
|
|
140
|
+
Drawer: Drawer_styles_1.Drawer,
|
|
141
|
+
Menu: Menu_styles_1.Menu,
|
|
142
|
+
Modal: Modal_styles_1.Modal,
|
|
143
|
+
Popover: Popover_styles_1.Popover,
|
|
144
|
+
Slider: Slider_styles_1.Slider,
|
|
145
|
+
Switch: Switch_styles_1.Switch,
|
|
146
|
+
Tabs: Tabs_styles_1.Tabs,
|
|
147
|
+
Avatar: Avatar_styles_1.Avatar,
|
|
148
|
+
Skeleton,
|
|
149
|
+
Tooltip,
|
|
150
|
+
};
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import type { PaletteProps, ResolvedColorMode } from "../tokens/types";
|
|
2
|
+
export interface CreateBrandThemeOptions {
|
|
3
|
+
/** Which palette this theme represents. Defaults to `light`. */
|
|
4
|
+
colorMode?: ResolvedColorMode;
|
|
5
|
+
}
|
|
6
|
+
/**
|
|
7
|
+
* Builds a Chakra theme from a pure brand palette.
|
|
8
|
+
*
|
|
9
|
+
* Replaces the seven byte-identical `<Brand>/theme.ts` files — they differed only in
|
|
10
|
+
* which palette they imported.
|
|
11
|
+
*
|
|
12
|
+
* Dark mode works by swapping which palette the theme carries: `componentStyles` variants
|
|
13
|
+
* are functions of `({ theme })` and `useCustomTheme()` reads `theme.colors`, so both follow
|
|
14
|
+
* the palette automatically without any per-component `_dark` overrides.
|
|
15
|
+
*/
|
|
16
|
+
export declare const createBrandTheme: (palette: PaletteProps, options?: CreateBrandThemeOptions) => Record<string, any>;
|
|
17
|
+
export default createBrandTheme;
|
|
18
|
+
//# sourceMappingURL=createBrandTheme.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"createBrandTheme.d.ts","sourceRoot":"","sources":["../../../src/Theme/chakra/createBrandTheme.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,iBAAiB,CAAC;AAMvE,MAAM,WAAW,uBAAuB;IACtC,gEAAgE;IAChE,SAAS,CAAC,EAAE,iBAAiB,CAAC;CAC/B;AAED;;;;;;;;;GASG;AACH,eAAO,MAAM,gBAAgB,GAC3B,SAAS,YAAY,EACrB,UAAS,uBAA4B,wBAwDtC,CAAC;AAEF,eAAe,gBAAgB,CAAC"}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.createBrandTheme = void 0;
|
|
7
|
+
const react_1 = require("@chakra-ui/react");
|
|
8
|
+
const common_web_1 = __importDefault(require("./common.web"));
|
|
9
|
+
const fonts_web_1 = __importDefault(require("./fonts.web"));
|
|
10
|
+
const componentStyles_1 = require("./componentStyles");
|
|
11
|
+
/**
|
|
12
|
+
* Builds a Chakra theme from a pure brand palette.
|
|
13
|
+
*
|
|
14
|
+
* Replaces the seven byte-identical `<Brand>/theme.ts` files — they differed only in
|
|
15
|
+
* which palette they imported.
|
|
16
|
+
*
|
|
17
|
+
* Dark mode works by swapping which palette the theme carries: `componentStyles` variants
|
|
18
|
+
* are functions of `({ theme })` and `useCustomTheme()` reads `theme.colors`, so both follow
|
|
19
|
+
* the palette automatically without any per-component `_dark` overrides.
|
|
20
|
+
*/
|
|
21
|
+
const createBrandTheme = (palette, options = {}) => {
|
|
22
|
+
var _a;
|
|
23
|
+
const colorMode = (_a = options.colorMode) !== null && _a !== void 0 ? _a : "light";
|
|
24
|
+
const brand = {
|
|
25
|
+
colors: palette,
|
|
26
|
+
...fonts_web_1.default,
|
|
27
|
+
...common_web_1.default,
|
|
28
|
+
};
|
|
29
|
+
return (0, react_1.extendTheme)({
|
|
30
|
+
...brand,
|
|
31
|
+
config: {
|
|
32
|
+
...common_web_1.default.config,
|
|
33
|
+
// Deliberately ALWAYS "light", even for the dark theme — this is not a bug.
|
|
34
|
+
//
|
|
35
|
+
// Dark works by swapping the palette, so the palette is ALREADY mode-adapted by the time
|
|
36
|
+
// Chakra sees it. Telling Chakra it is in dark mode makes it adapt a second time: its
|
|
37
|
+
// built-ins carry `_dark` blocks that reach for `gray.700`/`gray.800` assuming a scale where
|
|
38
|
+
// those rungs are dark. Our dark gray ramp runs dark -> light, so those rungs are LIGHT —
|
|
39
|
+
// producing a light Card/Skeleton/Menu on a dark canvas. Adapting twice cancels out.
|
|
40
|
+
//
|
|
41
|
+
// Keeping Chakra on its `_light` branch is what makes the swap work: those defaults are
|
|
42
|
+
// gray-RUNG references (`gray.100`, `gray.200`, `gray.600`), and our reversed ramp already
|
|
43
|
+
// maps each rung to the right value per mode. `semanticTokens` below patches the one default
|
|
44
|
+
// that hardcodes a literal color instead of a rung.
|
|
45
|
+
initialColorMode: "light",
|
|
46
|
+
useSystemColorMode: false,
|
|
47
|
+
},
|
|
48
|
+
// `chakra-body-bg` is the only stock semantic token that resolves to a LITERAL (`white`)
|
|
49
|
+
// rather than a gray rung, so it is the only one the palette swap cannot correct on its own —
|
|
50
|
+
// it is what paints a white Card/Modal/Menu on the dark canvas. `background[50]` is the
|
|
51
|
+
// canvas-following equivalent: byte-identical `#ffffff` in light, the canvas in dark.
|
|
52
|
+
// `chakra-inverse-text` is the same literal-`white` problem in text form.
|
|
53
|
+
semanticTokens: {
|
|
54
|
+
colors: {
|
|
55
|
+
"chakra-body-bg": palette.background[50],
|
|
56
|
+
"chakra-inverse-text": palette.background[50],
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
// Light themes intentionally declare no global styles — that is the pre-existing
|
|
60
|
+
// behavior, and adding any would shift every consuming app's light rendering.
|
|
61
|
+
// Dark needs a canvas, otherwise the page stays white behind the components.
|
|
62
|
+
...(colorMode === "dark"
|
|
63
|
+
? {
|
|
64
|
+
styles: {
|
|
65
|
+
global: {
|
|
66
|
+
body: {
|
|
67
|
+
bg: palette.backgroundColor.main,
|
|
68
|
+
color: palette.text[900],
|
|
69
|
+
},
|
|
70
|
+
},
|
|
71
|
+
},
|
|
72
|
+
}
|
|
73
|
+
: {}),
|
|
74
|
+
components: componentStyles_1.componentStyles,
|
|
75
|
+
});
|
|
76
|
+
};
|
|
77
|
+
exports.createBrandTheme = createBrandTheme;
|
|
78
|
+
exports.default = exports.createBrandTheme;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
/** Self-hosted Inter Variable (wght 100–900); required for theme fontWeights to render correctly. */
|
|
2
|
+
import "@fontsource-variable/inter/index.css";
|
|
3
|
+
/**
|
|
4
|
+
* Web font binding: loads the Inter font face (CSS side-effect) and re-exports the pure
|
|
5
|
+
* typography tokens. The CSS import lives here rather than in `tokens/` so the token
|
|
6
|
+
* layer stays portable to mobile.
|
|
7
|
+
*/
|
|
8
|
+
declare const fonts: {
|
|
9
|
+
fonts: {
|
|
10
|
+
body: string;
|
|
11
|
+
heading: string;
|
|
12
|
+
mono: string;
|
|
13
|
+
};
|
|
14
|
+
fontSizes: {
|
|
15
|
+
xs: string;
|
|
16
|
+
sm: string;
|
|
17
|
+
md: string;
|
|
18
|
+
lg: string;
|
|
19
|
+
xl: string;
|
|
20
|
+
"2xl": string;
|
|
21
|
+
"3xl": string;
|
|
22
|
+
"4xl": string;
|
|
23
|
+
"5xl": string;
|
|
24
|
+
"6xl": string;
|
|
25
|
+
"7xl": string;
|
|
26
|
+
"8xl": string;
|
|
27
|
+
"9xl": string;
|
|
28
|
+
};
|
|
29
|
+
fontWeights: {
|
|
30
|
+
hairline: number;
|
|
31
|
+
thin: number;
|
|
32
|
+
light: number;
|
|
33
|
+
normal: number;
|
|
34
|
+
medium: number;
|
|
35
|
+
semibold: number;
|
|
36
|
+
bold: number;
|
|
37
|
+
extrabold: number;
|
|
38
|
+
black: number;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
export default fonts;
|
|
42
|
+
//# sourceMappingURL=fonts.web.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"fonts.web.d.ts","sourceRoot":"","sources":["../../../src/Theme/chakra/fonts.web.ts"],"names":[],"mappings":"AAAA,qGAAqG;AACrG,OAAO,sCAAsC,CAAC;AAG9C;;;;GAIG;AACH,QAAA,MAAM,KAAK;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAa,CAAC;AAEzB,eAAe,KAAK,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
/** Self-hosted Inter Variable (wght 100–900); required for theme fontWeights to render correctly. */
|
|
7
|
+
require("@fontsource-variable/inter/index.css");
|
|
8
|
+
const typography_1 = __importDefault(require("../tokens/primitives/typography"));
|
|
9
|
+
/**
|
|
10
|
+
* Web font binding: loads the Inter font face (CSS side-effect) and re-exports the pure
|
|
11
|
+
* typography tokens. The CSS import lives here rather than in `tokens/` so the token
|
|
12
|
+
* layer stays portable to mobile.
|
|
13
|
+
*/
|
|
14
|
+
const fonts = typography_1.default;
|
|
15
|
+
exports.default = fonts;
|
package/dist/Theme/index.d.ts
CHANGED
|
@@ -1,11 +1,27 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
1
|
+
import createBrandTheme from "./chakra/createBrandTheme";
|
|
2
|
+
import type { ResolvedColorMode, ThemeName } from "./tokens/types";
|
|
3
|
+
/**
|
|
4
|
+
* Chakra themes per brand, built from the pure palettes in `tokens/brands`.
|
|
5
|
+
*
|
|
6
|
+
* These used to be seven near-identical `<Brand>/theme.ts` files that differed only in
|
|
7
|
+
* which palette they imported; `createBrandTheme` is that shared body.
|
|
8
|
+
*/
|
|
9
|
+
declare const lavender: Record<string, any>;
|
|
10
|
+
declare const meadow: Record<string, any>;
|
|
11
|
+
declare const radiant: Record<string, any>;
|
|
12
|
+
declare const skyline: Record<string, any>;
|
|
13
|
+
declare const slate: Record<string, any>;
|
|
14
|
+
declare const emerald: Record<string, any>;
|
|
15
|
+
declare const rosewood: Record<string, any>;
|
|
16
|
+
declare const storefront: Record<string, any>;
|
|
17
|
+
declare const zinc: Record<string, any>;
|
|
18
|
+
export { skyline, meadow, radiant, lavender, slate, emerald, rosewood, storefront, zinc };
|
|
19
|
+
/**
|
|
20
|
+
* Published contract — consumers iterate this to render theme pickers, so both the keys
|
|
21
|
+
* and their order are load-bearing. Stays light-only: these are the exact theme objects
|
|
22
|
+
* apps already pass to `withTheme`, and dark is opt-in via `PixelizeThemeProvider`.
|
|
23
|
+
* `storefront`/`zinc` are appended at the end — additive, doesn't reorder existing entries.
|
|
24
|
+
*/
|
|
9
25
|
export declare const ThemesList: {
|
|
10
26
|
lavender: Record<string, any>;
|
|
11
27
|
meadow: Record<string, any>;
|
|
@@ -14,5 +30,10 @@ export declare const ThemesList: {
|
|
|
14
30
|
rosewood: Record<string, any>;
|
|
15
31
|
slate: Record<string, any>;
|
|
16
32
|
radiant: Record<string, any>;
|
|
33
|
+
storefront: Record<string, any>;
|
|
34
|
+
zinc: Record<string, any>;
|
|
17
35
|
};
|
|
36
|
+
export type BrandThemes = Record<ThemeName, Record<ResolvedColorMode, ReturnType<typeof createBrandTheme>>>;
|
|
37
|
+
/** Light + dark theme per brand. `PixelizeThemeProvider` swaps between these. */
|
|
38
|
+
export declare const brandThemes: BrandThemes;
|
|
18
39
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/Theme/index.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/Theme/index.ts"],"names":[],"mappings":"AAAA,OAAO,gBAAgB,MAAM,2BAA2B,CAAC;AAEzD,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAC;AAEnE;;;;;GAKG;AACH,QAAA,MAAM,QAAQ,qBAA2C,CAAC;AAC1D,QAAA,MAAM,MAAM,qBAAyC,CAAC;AACtD,QAAA,MAAM,OAAO,qBAA0C,CAAC;AACxD,QAAA,MAAM,OAAO,qBAA0C,CAAC;AACxD,QAAA,MAAM,KAAK,qBAAwC,CAAC;AACpD,QAAA,MAAM,OAAO,qBAA0C,CAAC;AACxD,QAAA,MAAM,QAAQ,qBAA2C,CAAC;AAC1D,QAAA,MAAM,UAAU,qBAA6C,CAAC;AAC9D,QAAA,MAAM,IAAI,qBAAuC,CAAC;AAElD,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,QAAQ,EAAE,KAAK,EAAE,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,IAAI,EAAE,CAAC;AAE1F;;;;;GAKG;AACH,eAAO,MAAM,UAAU;;;;;;;;;;CAUtB,CAAC;AAEF,MAAM,MAAM,WAAW,GAAG,MAAM,CAC9B,SAAS,EACT,MAAM,CAAC,iBAAiB,EAAE,UAAU,CAAC,OAAO,gBAAgB,CAAC,CAAC,CAC/D,CAAC;AAEF,iFAAiF;AACjF,eAAO,MAAM,WAAW,EAAE,WAUzB,CAAC"}
|
package/dist/Theme/index.js
CHANGED
|
@@ -3,27 +3,59 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
3
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
4
|
};
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.ThemesList = exports.rosewood = exports.emerald = exports.slate = exports.lavender = exports.radiant = exports.meadow = exports.skyline = void 0;
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
const
|
|
16
|
-
exports.
|
|
17
|
-
const
|
|
18
|
-
exports.
|
|
19
|
-
const
|
|
20
|
-
exports.
|
|
6
|
+
exports.brandThemes = exports.ThemesList = exports.zinc = exports.storefront = exports.rosewood = exports.emerald = exports.slate = exports.lavender = exports.radiant = exports.meadow = exports.skyline = void 0;
|
|
7
|
+
const createBrandTheme_1 = __importDefault(require("./chakra/createBrandTheme"));
|
|
8
|
+
const brands_1 = require("./tokens/brands");
|
|
9
|
+
/**
|
|
10
|
+
* Chakra themes per brand, built from the pure palettes in `tokens/brands`.
|
|
11
|
+
*
|
|
12
|
+
* These used to be seven near-identical `<Brand>/theme.ts` files that differed only in
|
|
13
|
+
* which palette they imported; `createBrandTheme` is that shared body.
|
|
14
|
+
*/
|
|
15
|
+
const lavender = (0, createBrandTheme_1.default)(brands_1.lightPalettes.lavender);
|
|
16
|
+
exports.lavender = lavender;
|
|
17
|
+
const meadow = (0, createBrandTheme_1.default)(brands_1.lightPalettes.meadow);
|
|
18
|
+
exports.meadow = meadow;
|
|
19
|
+
const radiant = (0, createBrandTheme_1.default)(brands_1.lightPalettes.radiant);
|
|
20
|
+
exports.radiant = radiant;
|
|
21
|
+
const skyline = (0, createBrandTheme_1.default)(brands_1.lightPalettes.skyline);
|
|
22
|
+
exports.skyline = skyline;
|
|
23
|
+
const slate = (0, createBrandTheme_1.default)(brands_1.lightPalettes.slate);
|
|
24
|
+
exports.slate = slate;
|
|
25
|
+
const emerald = (0, createBrandTheme_1.default)(brands_1.lightPalettes.emerald);
|
|
26
|
+
exports.emerald = emerald;
|
|
27
|
+
const rosewood = (0, createBrandTheme_1.default)(brands_1.lightPalettes.rosewood);
|
|
28
|
+
exports.rosewood = rosewood;
|
|
29
|
+
const storefront = (0, createBrandTheme_1.default)(brands_1.lightPalettes.storefront);
|
|
30
|
+
exports.storefront = storefront;
|
|
31
|
+
const zinc = (0, createBrandTheme_1.default)(brands_1.lightPalettes.zinc);
|
|
32
|
+
exports.zinc = zinc;
|
|
33
|
+
/**
|
|
34
|
+
* Published contract — consumers iterate this to render theme pickers, so both the keys
|
|
35
|
+
* and their order are load-bearing. Stays light-only: these are the exact theme objects
|
|
36
|
+
* apps already pass to `withTheme`, and dark is opt-in via `PixelizeThemeProvider`.
|
|
37
|
+
* `storefront`/`zinc` are appended at the end — additive, doesn't reorder existing entries.
|
|
38
|
+
*/
|
|
21
39
|
exports.ThemesList = {
|
|
22
|
-
lavender:
|
|
23
|
-
meadow:
|
|
24
|
-
skyline:
|
|
25
|
-
emerald:
|
|
26
|
-
rosewood:
|
|
27
|
-
slate:
|
|
28
|
-
radiant:
|
|
40
|
+
lavender: lavender,
|
|
41
|
+
meadow: meadow,
|
|
42
|
+
skyline: skyline,
|
|
43
|
+
emerald: emerald,
|
|
44
|
+
rosewood: rosewood,
|
|
45
|
+
slate: slate,
|
|
46
|
+
radiant: radiant,
|
|
47
|
+
storefront: storefront,
|
|
48
|
+
zinc: zinc,
|
|
49
|
+
};
|
|
50
|
+
/** Light + dark theme per brand. `PixelizeThemeProvider` swaps between these. */
|
|
51
|
+
exports.brandThemes = {
|
|
52
|
+
lavender: { light: lavender, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.lavender, { colorMode: "dark" }) },
|
|
53
|
+
meadow: { light: meadow, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.meadow, { colorMode: "dark" }) },
|
|
54
|
+
radiant: { light: radiant, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.radiant, { colorMode: "dark" }) },
|
|
55
|
+
skyline: { light: skyline, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.skyline, { colorMode: "dark" }) },
|
|
56
|
+
slate: { light: slate, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.slate, { colorMode: "dark" }) },
|
|
57
|
+
emerald: { light: emerald, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.emerald, { colorMode: "dark" }) },
|
|
58
|
+
rosewood: { light: rosewood, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.rosewood, { colorMode: "dark" }) },
|
|
59
|
+
storefront: { light: storefront, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.storefront, { colorMode: "dark" }) },
|
|
60
|
+
zinc: { light: zinc, dark: (0, createBrandTheme_1.default)(brands_1.darkPalettes.zinc, { colorMode: "dark" }) },
|
|
29
61
|
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import React from "react";
|
|
2
|
+
import type { ColorMode, ResolvedColorMode, ThemeName } from "../tokens/types";
|
|
3
|
+
export type ThemeModeContextValue = {
|
|
4
|
+
mode: ColorMode;
|
|
5
|
+
resolvedMode: ResolvedColorMode;
|
|
6
|
+
setMode: (mode: ColorMode) => void;
|
|
7
|
+
toggle: () => void;
|
|
8
|
+
brand: ThemeName;
|
|
9
|
+
setBrand: (brand: ThemeName) => void;
|
|
10
|
+
};
|
|
11
|
+
export type PixelizeThemeProviderProps = {
|
|
12
|
+
children: React.ReactNode;
|
|
13
|
+
/** Initial brand. A persisted brand wins over this. */
|
|
14
|
+
brand?: ThemeName;
|
|
15
|
+
/** Initial color mode. A persisted mode wins over this. */
|
|
16
|
+
defaultMode?: ColorMode;
|
|
17
|
+
storageKey?: string;
|
|
18
|
+
disablePersistence?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* App-specific theme overrides (fonts, sizes, component defaultProps, zIndices, ...) merged
|
|
21
|
+
* onto the resolved `brandThemes[brand][resolvedMode]` via `extendTheme`. Re-evaluated whenever
|
|
22
|
+
* `brand`/`resolvedMode` change, so overrides always layer onto the CURRENT palette rather than
|
|
23
|
+
* a stale one. Safe to merge post-resolution: `createBrandTheme` already fixes
|
|
24
|
+
* `config.initialColorMode` to `"light"` on every palette, and `extendTheme` is a pure additive
|
|
25
|
+
* merge — it does not re-derive `_dark:` blocks or re-run color-mode resolution, so this cannot
|
|
26
|
+
* reintroduce the double-adaptation bug `forcedLightColorModeManager` avoids (see above).
|
|
27
|
+
*/
|
|
28
|
+
themeOverrides?: Record<string, unknown>;
|
|
29
|
+
};
|
|
30
|
+
export declare const ThemeModeContext: React.Context<ThemeModeContextValue | undefined>;
|
|
31
|
+
/**
|
|
32
|
+
* Chakra's own color mode is deliberately NOT synced to `resolvedMode`, and must not be.
|
|
33
|
+
*
|
|
34
|
+
* This provider adapts for dark by swapping the palette, so `theme.colors` is already correct for
|
|
35
|
+
* the active mode. Putting Chakra into dark mode on top of that adapts a second time: its built-in
|
|
36
|
+
* `_dark` blocks reach for `gray.700`/`gray.800` expecting those rungs to be dark, but our dark
|
|
37
|
+
* ramp runs dark -> light, so they resolve LIGHT — a white Card/Skeleton/Menu on a dark canvas.
|
|
38
|
+
* A previous revision synced it to keep `useColorModeValue()` working and shipped exactly that.
|
|
39
|
+
*
|
|
40
|
+
* Consequence for consumers: `useColorModeValue(light, dark)` always returns its LIGHT argument.
|
|
41
|
+
* That is correct here — the palette has already resolved the mode, so the "light" argument is
|
|
42
|
+
* whatever the active palette says. Read the mode from `useThemeMode()` instead. Existing apps are
|
|
43
|
+
* unaffected: they are light-only, where that argument was always the one returned anyway.
|
|
44
|
+
*/
|
|
45
|
+
export declare const PixelizeThemeProvider: ({ children, brand: brandProp, defaultMode, storageKey, disablePersistence, themeOverrides, }: PixelizeThemeProviderProps) => import("react/jsx-runtime").JSX.Element;
|
|
46
|
+
//# sourceMappingURL=PixelizeThemeProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"PixelizeThemeProvider.d.ts","sourceRoot":"","sources":["../../../src/Theme/provider/PixelizeThemeProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAON,MAAM,OAAO,CAAC;AAEf,OAAO,KAAK,EAAE,SAAS,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAU/E,MAAM,MAAM,qBAAqB,GAAG;IAClC,IAAI,EAAE,SAAS,CAAC;IAChB,YAAY,EAAE,iBAAiB,CAAC;IAChC,OAAO,EAAE,CAAC,IAAI,EAAE,SAAS,KAAK,IAAI,CAAC;IACnC,MAAM,EAAE,MAAM,IAAI,CAAC;IACnB,KAAK,EAAE,SAAS,CAAC;IACjB,QAAQ,EAAE,CAAC,KAAK,EAAE,SAAS,KAAK,IAAI,CAAC;CACtC,CAAC;AAEF,MAAM,MAAM,0BAA0B,GAAG;IACvC,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,uDAAuD;IACvD,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,2DAA2D;IAC3D,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,kBAAkB,CAAC,EAAE,OAAO,CAAC;IAC7B;;;;;;;;OAQG;IACH,cAAc,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;CAC1C,CAAC;AA2BF,eAAO,MAAM,gBAAgB,kDAE5B,CAAC;AAEF;;;;;;;;;;;;;GAaG;AACH,eAAO,MAAM,qBAAqB,GAAI,8FAOnC,0BAA0B,4CA8F5B,CAAC"}
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.PixelizeThemeProvider = exports.ThemeModeContext = void 0;
|
|
7
|
+
const jsx_runtime_1 = require("react/jsx-runtime");
|
|
8
|
+
const react_1 = require("react");
|
|
9
|
+
const react_2 = require("@chakra-ui/react");
|
|
10
|
+
const index_1 = require("../index");
|
|
11
|
+
const Toaster_1 = __importDefault(require("../../Components/Toaster/Toaster"));
|
|
12
|
+
const colorModeStorage_1 = require("./colorModeStorage");
|
|
13
|
+
const DEFAULT_BRAND = "lavender";
|
|
14
|
+
const DEFAULT_MODE = "system";
|
|
15
|
+
const DEFAULT_STORAGE_KEY = "pixelize-theme";
|
|
16
|
+
/**
|
|
17
|
+
* Chakra's default `colorModeManager` reads/writes its OWN `localStorage["chakra-ui-color-mode"]`
|
|
18
|
+
* key — entirely separate from this app's `storageKey` above — and that stored value wins over
|
|
19
|
+
* `theme.config.initialColorMode` on every load. `createBrandTheme` sets `initialColorMode: "light"`
|
|
20
|
+
* on every theme object specifically so Chakra's native dark mode (and every un-migrated built-in
|
|
21
|
+
* `_dark:` block — Card's "elevated" variant reaches for `gray.700`, which our reversed dark ramp
|
|
22
|
+
* makes LIGHT) never fires. But a stale `"dark"` value in that key — from Chakra's own toggle ever
|
|
23
|
+
* having been used on this origin, by this app or a prior version of it — silently overrides that
|
|
24
|
+
* default and reintroduces exactly the bug `initialColorMode: "light"` was meant to prevent: a
|
|
25
|
+
* washed-out light Card on an otherwise-correct dark canvas, while everything reading the palette
|
|
26
|
+
* directly (i.e. everything else) stays right. Forcing this manager to always report `"light"` and
|
|
27
|
+
* never persist removes Chakra's native color mode from the equation entirely, so no stray
|
|
28
|
+
* `_dark:` block anywhere (present or future) can ever fire, regardless of what's in storage.
|
|
29
|
+
*/
|
|
30
|
+
const forcedLightColorModeManager = {
|
|
31
|
+
type: "localStorage",
|
|
32
|
+
ssr: false,
|
|
33
|
+
get: () => "light",
|
|
34
|
+
set: () => { },
|
|
35
|
+
};
|
|
36
|
+
exports.ThemeModeContext = (0, react_1.createContext)(undefined);
|
|
37
|
+
/**
|
|
38
|
+
* Chakra's own color mode is deliberately NOT synced to `resolvedMode`, and must not be.
|
|
39
|
+
*
|
|
40
|
+
* This provider adapts for dark by swapping the palette, so `theme.colors` is already correct for
|
|
41
|
+
* the active mode. Putting Chakra into dark mode on top of that adapts a second time: its built-in
|
|
42
|
+
* `_dark` blocks reach for `gray.700`/`gray.800` expecting those rungs to be dark, but our dark
|
|
43
|
+
* ramp runs dark -> light, so they resolve LIGHT — a white Card/Skeleton/Menu on a dark canvas.
|
|
44
|
+
* A previous revision synced it to keep `useColorModeValue()` working and shipped exactly that.
|
|
45
|
+
*
|
|
46
|
+
* Consequence for consumers: `useColorModeValue(light, dark)` always returns its LIGHT argument.
|
|
47
|
+
* That is correct here — the palette has already resolved the mode, so the "light" argument is
|
|
48
|
+
* whatever the active palette says. Read the mode from `useThemeMode()` instead. Existing apps are
|
|
49
|
+
* unaffected: they are light-only, where that argument was always the one returned anyway.
|
|
50
|
+
*/
|
|
51
|
+
const PixelizeThemeProvider = ({ children, brand: brandProp = DEFAULT_BRAND, defaultMode = DEFAULT_MODE, storageKey = DEFAULT_STORAGE_KEY, disablePersistence = false, themeOverrides, }) => {
|
|
52
|
+
const [mode, setModeState] = (0, react_1.useState)(defaultMode);
|
|
53
|
+
const [brand, setBrandState] = (0, react_1.useState)(brandProp);
|
|
54
|
+
// Deterministic on the server and on the first client render — the real OS value lands in
|
|
55
|
+
// the effect below, so hydration always matches.
|
|
56
|
+
const [systemMode, setSystemMode] = (0, react_1.useState)("light");
|
|
57
|
+
(0, react_1.useEffect)(() => {
|
|
58
|
+
setSystemMode((0, colorModeStorage_1.getSystemColorMode)());
|
|
59
|
+
return (0, colorModeStorage_1.subscribeToSystemColorMode)(setSystemMode);
|
|
60
|
+
}, []);
|
|
61
|
+
(0, react_1.useEffect)(() => {
|
|
62
|
+
if (disablePersistence)
|
|
63
|
+
return;
|
|
64
|
+
const stored = (0, colorModeStorage_1.readStoredTheme)(storageKey);
|
|
65
|
+
if (stored.mode)
|
|
66
|
+
setModeState(stored.mode);
|
|
67
|
+
if (stored.brand)
|
|
68
|
+
setBrandState(stored.brand);
|
|
69
|
+
}, [disablePersistence, storageKey]);
|
|
70
|
+
// `brandProp` only seeds initial state above, so a consumer that re-renders with a new
|
|
71
|
+
// `brand` prop after mount (e.g. persisting the pick through its own store, like tickets'
|
|
72
|
+
// Settings page dispatching Redux instead of calling `setBrand`) would otherwise never see
|
|
73
|
+
// it applied — the same gap `colorMode` has, which callers work around with an effect
|
|
74
|
+
// mirroring `mode`. Sync it here instead so every consumer gets it for free.
|
|
75
|
+
const isFirstBrandPropRun = (0, react_1.useRef)(true);
|
|
76
|
+
(0, react_1.useEffect)(() => {
|
|
77
|
+
if (isFirstBrandPropRun.current) {
|
|
78
|
+
isFirstBrandPropRun.current = false;
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
setBrandState(brandProp);
|
|
82
|
+
// Only re-sync when the prop itself changes — not on every local `setBrand` call (that
|
|
83
|
+
// would fight the user's own in-session brand picking, e.g. via ThemeSwitcher).
|
|
84
|
+
// eslint-disable-next-line react-hooks/exhaustive-deps
|
|
85
|
+
}, [brandProp]);
|
|
86
|
+
// Skipping the mount run keeps the defaults from being written over a stored value before
|
|
87
|
+
// the rehydrate effect above has applied it.
|
|
88
|
+
const isFirstPersistRun = (0, react_1.useRef)(true);
|
|
89
|
+
(0, react_1.useEffect)(() => {
|
|
90
|
+
if (isFirstPersistRun.current) {
|
|
91
|
+
isFirstPersistRun.current = false;
|
|
92
|
+
return;
|
|
93
|
+
}
|
|
94
|
+
if (disablePersistence)
|
|
95
|
+
return;
|
|
96
|
+
(0, colorModeStorage_1.writeStoredTheme)(storageKey, { mode, brand });
|
|
97
|
+
}, [mode, brand, disablePersistence, storageKey]);
|
|
98
|
+
const resolvedMode = mode === "system" ? systemMode : mode;
|
|
99
|
+
/**
|
|
100
|
+
* Native browser UI (the `<select>` dropdown popup chrome, the `<input type="date">` calendar
|
|
101
|
+
* picker) is painted by the browser's own UA stylesheet keyed off the CSS `color-scheme`
|
|
102
|
+
* property, entirely separate from Chakra/React theming — no component style or palette swap
|
|
103
|
+
* above can reach it. Without this, that chrome always renders light, even on an otherwise dark
|
|
104
|
+
* page. Scoped to this provider (not a global stylesheet) so `withTheme` consumers — deliberately
|
|
105
|
+
* light-only, see the module doc's "Key rules" — are untouched.
|
|
106
|
+
*/
|
|
107
|
+
(0, react_1.useEffect)(() => {
|
|
108
|
+
document.documentElement.style.colorScheme = resolvedMode;
|
|
109
|
+
}, [resolvedMode]);
|
|
110
|
+
const setMode = (0, react_1.useCallback)((next) => setModeState(next), []);
|
|
111
|
+
const setBrand = (0, react_1.useCallback)((next) => setBrandState(next), []);
|
|
112
|
+
// From "system", flip to the opposite of what the OS currently gives, so a click always
|
|
113
|
+
// visibly changes the UI.
|
|
114
|
+
const toggle = (0, react_1.useCallback)(() => setModeState(resolvedMode === "dark" ? "light" : "dark"), [resolvedMode]);
|
|
115
|
+
const value = (0, react_1.useMemo)(() => ({ mode, resolvedMode, setMode, toggle, brand, setBrand }), [mode, resolvedMode, setMode, toggle, brand, setBrand]);
|
|
116
|
+
const resolvedTheme = (0, react_1.useMemo)(() => {
|
|
117
|
+
const base = index_1.brandThemes[brand][resolvedMode];
|
|
118
|
+
return themeOverrides
|
|
119
|
+
? (0, react_2.extendTheme)(base, themeOverrides)
|
|
120
|
+
: base;
|
|
121
|
+
}, [brand, resolvedMode, themeOverrides]);
|
|
122
|
+
return ((0, jsx_runtime_1.jsx)(exports.ThemeModeContext.Provider, { value: value, children: (0, jsx_runtime_1.jsx)(react_2.ChakraProvider, { theme: resolvedTheme, colorModeManager: forcedLightColorModeManager, children: (0, jsx_runtime_1.jsx)(Toaster_1.default, { children: children }) }) }));
|
|
123
|
+
};
|
|
124
|
+
exports.PixelizeThemeProvider = PixelizeThemeProvider;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
export type ThemeSwitcherProps = {
|
|
2
|
+
variant?: "icon" | "segmented" | "menu";
|
|
3
|
+
showBrandPicker?: boolean;
|
|
4
|
+
size?: "sm" | "md" | "lg";
|
|
5
|
+
"aria-label"?: string;
|
|
6
|
+
};
|
|
7
|
+
export declare const ThemeSwitcher: ({ variant, showBrandPicker, size, "aria-label": ariaLabel, }: ThemeSwitcherProps) => import("react/jsx-runtime").JSX.Element;
|
|
8
|
+
//# sourceMappingURL=ThemeSwitcher.d.ts.map
|