@umituz/react-native-design-system 1.3.1 → 1.3.3
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/README.md +1 -1
- package/lib/domains/icons/domain/config/IconLibraryConfig.d.ts +91 -0
- package/lib/domains/icons/domain/config/IconLibraryConfig.d.ts.map +1 -0
- package/lib/domains/icons/domain/config/IconLibraryConfig.js +85 -0
- package/lib/domains/icons/domain/config/IconLibraryConfig.js.map +1 -0
- package/lib/domains/icons/domain/entities/Icon.d.ts +111 -0
- package/lib/domains/icons/domain/entities/Icon.d.ts.map +1 -0
- package/lib/domains/icons/domain/entities/Icon.js +87 -0
- package/lib/domains/icons/domain/entities/Icon.js.map +1 -0
- package/lib/domains/icons/domain/interfaces/IIconAdapter.d.ts +114 -0
- package/lib/domains/icons/domain/interfaces/IIconAdapter.d.ts.map +1 -0
- package/lib/domains/icons/domain/interfaces/IIconAdapter.js +17 -0
- package/lib/domains/icons/domain/interfaces/IIconAdapter.js.map +1 -0
- package/lib/domains/icons/index.d.ts +84 -0
- package/lib/domains/icons/index.d.ts.map +1 -0
- package/lib/domains/icons/index.js +89 -0
- package/lib/domains/icons/index.js.map +1 -0
- package/lib/domains/icons/infrastructure/adapters/LucideAdapter.d.ts +24 -0
- package/lib/domains/icons/infrastructure/adapters/LucideAdapter.d.ts.map +1 -0
- package/lib/domains/icons/infrastructure/adapters/LucideAdapter.js +85 -0
- package/lib/domains/icons/infrastructure/adapters/LucideAdapter.js.map +1 -0
- package/lib/domains/icons/infrastructure/registries/ExpoIconRegistry.d.ts +23 -0
- package/lib/domains/icons/infrastructure/registries/ExpoIconRegistry.d.ts.map +1 -0
- package/lib/domains/icons/infrastructure/registries/ExpoIconRegistry.js +178 -0
- package/lib/domains/icons/infrastructure/registries/ExpoIconRegistry.js.map +1 -0
- package/lib/domains/icons/presentation/components/Icon.d.ts +42 -0
- package/lib/domains/icons/presentation/components/Icon.d.ts.map +1 -0
- package/lib/domains/icons/presentation/components/Icon.js +86 -0
- package/lib/domains/icons/presentation/components/Icon.js.map +1 -0
- package/lib/domains/icons/presentation/hooks/useIconLibrary.d.ts +38 -0
- package/lib/domains/icons/presentation/hooks/useIconLibrary.d.ts.map +1 -0
- package/lib/domains/icons/presentation/hooks/useIconLibrary.js +114 -0
- package/lib/domains/icons/presentation/hooks/useIconLibrary.js.map +1 -0
- package/lib/index.d.ts +66 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +106 -0
- package/lib/index.js.map +1 -0
- package/lib/infrastructure/theme/globalThemeStore.d.ts +42 -0
- package/lib/infrastructure/theme/globalThemeStore.d.ts.map +1 -0
- package/lib/infrastructure/theme/globalThemeStore.js +38 -0
- package/lib/infrastructure/theme/globalThemeStore.js.map +1 -0
- package/lib/presentation/atoms/AtomicAvatar.d.ts +48 -0
- package/lib/presentation/atoms/AtomicAvatar.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicAvatar.js +85 -0
- package/lib/presentation/atoms/AtomicAvatar.js.map +1 -0
- package/lib/presentation/atoms/AtomicAvatarGroup.d.ts +56 -0
- package/lib/presentation/atoms/AtomicAvatarGroup.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicAvatarGroup.js +83 -0
- package/lib/presentation/atoms/AtomicAvatarGroup.js.map +1 -0
- package/lib/presentation/atoms/AtomicBadge.d.ts +42 -0
- package/lib/presentation/atoms/AtomicBadge.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicBadge.js +168 -0
- package/lib/presentation/atoms/AtomicBadge.js.map +1 -0
- package/lib/presentation/atoms/AtomicButton.d.ts +22 -0
- package/lib/presentation/atoms/AtomicButton.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicButton.js +193 -0
- package/lib/presentation/atoms/AtomicButton.js.map +1 -0
- package/lib/presentation/atoms/AtomicCard.d.ts +15 -0
- package/lib/presentation/atoms/AtomicCard.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicCard.js +89 -0
- package/lib/presentation/atoms/AtomicCard.js.map +1 -0
- package/lib/presentation/atoms/AtomicChip.d.ts +53 -0
- package/lib/presentation/atoms/AtomicChip.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicChip.js +131 -0
- package/lib/presentation/atoms/AtomicChip.js.map +1 -0
- package/lib/presentation/atoms/AtomicDatePicker.d.ts +75 -0
- package/lib/presentation/atoms/AtomicDatePicker.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicDatePicker.js +246 -0
- package/lib/presentation/atoms/AtomicDatePicker.js.map +1 -0
- package/lib/presentation/atoms/AtomicDivider.d.ts +45 -0
- package/lib/presentation/atoms/AtomicDivider.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicDivider.js +58 -0
- package/lib/presentation/atoms/AtomicDivider.js.map +1 -0
- package/lib/presentation/atoms/AtomicFab.d.ts +38 -0
- package/lib/presentation/atoms/AtomicFab.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicFab.js +69 -0
- package/lib/presentation/atoms/AtomicFab.js.map +1 -0
- package/lib/presentation/atoms/AtomicFilter.d.ts +37 -0
- package/lib/presentation/atoms/AtomicFilter.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicFilter.js +104 -0
- package/lib/presentation/atoms/AtomicFilter.js.map +1 -0
- package/lib/presentation/atoms/AtomicFormError.d.ts +30 -0
- package/lib/presentation/atoms/AtomicFormError.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicFormError.js +64 -0
- package/lib/presentation/atoms/AtomicFormError.js.map +1 -0
- package/lib/presentation/atoms/AtomicIcon.d.ts +36 -0
- package/lib/presentation/atoms/AtomicIcon.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicIcon.js +30 -0
- package/lib/presentation/atoms/AtomicIcon.js.map +1 -0
- package/lib/presentation/atoms/AtomicImage.d.ts +40 -0
- package/lib/presentation/atoms/AtomicImage.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicImage.js +92 -0
- package/lib/presentation/atoms/AtomicImage.js.map +1 -0
- package/lib/presentation/atoms/AtomicInput.d.ts +71 -0
- package/lib/presentation/atoms/AtomicInput.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicInput.js +196 -0
- package/lib/presentation/atoms/AtomicInput.js.map +1 -0
- package/lib/presentation/atoms/AtomicNumberInput.d.ts +69 -0
- package/lib/presentation/atoms/AtomicNumberInput.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicNumberInput.js +125 -0
- package/lib/presentation/atoms/AtomicNumberInput.js.map +1 -0
- package/lib/presentation/atoms/AtomicPicker.d.ts +52 -0
- package/lib/presentation/atoms/AtomicPicker.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicPicker.js +299 -0
- package/lib/presentation/atoms/AtomicPicker.js.map +1 -0
- package/lib/presentation/atoms/AtomicProgress.d.ts +47 -0
- package/lib/presentation/atoms/AtomicProgress.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicProgress.js +81 -0
- package/lib/presentation/atoms/AtomicProgress.js.map +1 -0
- package/lib/presentation/atoms/AtomicSearchBar.d.ts +19 -0
- package/lib/presentation/atoms/AtomicSearchBar.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicSearchBar.js +46 -0
- package/lib/presentation/atoms/AtomicSearchBar.js.map +1 -0
- package/lib/presentation/atoms/AtomicSkeleton.d.ts +43 -0
- package/lib/presentation/atoms/AtomicSkeleton.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicSkeleton.js +84 -0
- package/lib/presentation/atoms/AtomicSkeleton.js.map +1 -0
- package/lib/presentation/atoms/AtomicSort.d.ts +72 -0
- package/lib/presentation/atoms/AtomicSort.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicSort.js +77 -0
- package/lib/presentation/atoms/AtomicSort.js.map +1 -0
- package/lib/presentation/atoms/AtomicSwitch.d.ts +43 -0
- package/lib/presentation/atoms/AtomicSwitch.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicSwitch.js +104 -0
- package/lib/presentation/atoms/AtomicSwitch.js.map +1 -0
- package/lib/presentation/atoms/AtomicText.d.ts +14 -0
- package/lib/presentation/atoms/AtomicText.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicText.js +36 -0
- package/lib/presentation/atoms/AtomicText.js.map +1 -0
- package/lib/presentation/atoms/AtomicTextArea.d.ts +85 -0
- package/lib/presentation/atoms/AtomicTextArea.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicTextArea.js +196 -0
- package/lib/presentation/atoms/AtomicTextArea.js.map +1 -0
- package/lib/presentation/atoms/AtomicTouchable.d.ts +87 -0
- package/lib/presentation/atoms/AtomicTouchable.d.ts.map +1 -0
- package/lib/presentation/atoms/AtomicTouchable.js +151 -0
- package/lib/presentation/atoms/AtomicTouchable.js.map +1 -0
- package/lib/presentation/atoms/fab/styles/fabStyles.d.ts +23 -0
- package/lib/presentation/atoms/fab/styles/fabStyles.d.ts.map +1 -0
- package/lib/presentation/atoms/fab/styles/fabStyles.js +63 -0
- package/lib/presentation/atoms/fab/styles/fabStyles.js.map +1 -0
- package/lib/presentation/atoms/fab/types/index.d.ts +76 -0
- package/lib/presentation/atoms/fab/types/index.d.ts.map +1 -0
- package/lib/presentation/atoms/fab/types/index.js +2 -0
- package/lib/presentation/atoms/fab/types/index.js.map +1 -0
- package/lib/presentation/atoms/filter/styles/filterStyles.d.ts +15 -0
- package/lib/presentation/atoms/filter/styles/filterStyles.d.ts.map +1 -0
- package/lib/presentation/atoms/filter/styles/filterStyles.js +29 -0
- package/lib/presentation/atoms/filter/styles/filterStyles.js.map +1 -0
- package/lib/presentation/atoms/filter/types/index.d.ts +76 -0
- package/lib/presentation/atoms/filter/types/index.d.ts.map +1 -0
- package/lib/presentation/atoms/filter/types/index.js +2 -0
- package/lib/presentation/atoms/filter/types/index.js.map +1 -0
- package/lib/presentation/atoms/index.d.ts +276 -0
- package/lib/presentation/atoms/index.d.ts.map +1 -0
- package/lib/presentation/atoms/index.js +149 -0
- package/lib/presentation/atoms/index.js.map +1 -0
- package/lib/presentation/atoms/input/hooks/useInputState.d.ts +7 -0
- package/lib/presentation/atoms/input/hooks/useInputState.d.ts.map +1 -0
- package/lib/presentation/atoms/input/hooks/useInputState.js +13 -0
- package/lib/presentation/atoms/input/hooks/useInputState.js.map +1 -0
- package/lib/presentation/atoms/input/styles/inputStyles.d.ts +13 -0
- package/lib/presentation/atoms/input/styles/inputStyles.d.ts.map +1 -0
- package/lib/presentation/atoms/input/styles/inputStyles.js +59 -0
- package/lib/presentation/atoms/input/styles/inputStyles.js.map +1 -0
- package/lib/presentation/atoms/input/types/index.d.ts +24 -0
- package/lib/presentation/atoms/input/types/index.d.ts.map +1 -0
- package/lib/presentation/atoms/input/types/index.js +2 -0
- package/lib/presentation/atoms/input/types/index.js.map +1 -0
- package/lib/presentation/atoms/picker/styles/pickerStyles.d.ts +96 -0
- package/lib/presentation/atoms/picker/styles/pickerStyles.d.ts.map +1 -0
- package/lib/presentation/atoms/picker/styles/pickerStyles.js +177 -0
- package/lib/presentation/atoms/picker/styles/pickerStyles.js.map +1 -0
- package/lib/presentation/atoms/picker/types/index.d.ts +38 -0
- package/lib/presentation/atoms/picker/types/index.d.ts.map +1 -0
- package/lib/presentation/atoms/picker/types/index.js +2 -0
- package/lib/presentation/atoms/picker/types/index.js.map +1 -0
- package/lib/presentation/atoms/touchable/styles/touchableStyles.d.ts +36 -0
- package/lib/presentation/atoms/touchable/styles/touchableStyles.d.ts.map +1 -0
- package/lib/presentation/atoms/touchable/styles/touchableStyles.js +62 -0
- package/lib/presentation/atoms/touchable/styles/touchableStyles.js.map +1 -0
- package/lib/presentation/atoms/touchable/types/index.d.ts +140 -0
- package/lib/presentation/atoms/touchable/types/index.d.ts.map +1 -0
- package/lib/presentation/atoms/touchable/types/index.js +2 -0
- package/lib/presentation/atoms/touchable/types/index.js.map +1 -0
- package/lib/presentation/hooks/useAppDesignTokens.d.ts +34 -0
- package/lib/presentation/hooks/useAppDesignTokens.d.ts.map +1 -0
- package/lib/presentation/hooks/useAppDesignTokens.js +39 -0
- package/lib/presentation/hooks/useAppDesignTokens.js.map +1 -0
- package/lib/presentation/hooks/useResponsive.d.ts +80 -0
- package/lib/presentation/hooks/useResponsive.d.ts.map +1 -0
- package/lib/presentation/hooks/useResponsive.js +82 -0
- package/lib/presentation/hooks/useResponsive.js.map +1 -0
- package/lib/presentation/loading/index.d.ts +23 -0
- package/lib/presentation/loading/index.d.ts.map +1 -0
- package/lib/presentation/loading/index.js +26 -0
- package/lib/presentation/loading/index.js.map +1 -0
- package/lib/presentation/loading/presentation/components/LoadingSpinner.d.ts +28 -0
- package/lib/presentation/loading/presentation/components/LoadingSpinner.d.ts.map +1 -0
- package/lib/presentation/loading/presentation/components/LoadingSpinner.js +77 -0
- package/lib/presentation/loading/presentation/components/LoadingSpinner.js.map +1 -0
- package/lib/presentation/loading/presentation/components/LoadingState.d.ts +39 -0
- package/lib/presentation/loading/presentation/components/LoadingState.d.ts.map +1 -0
- package/lib/presentation/loading/presentation/components/LoadingState.js +123 -0
- package/lib/presentation/loading/presentation/components/LoadingState.js.map +1 -0
- package/lib/presentation/loading/presentation/hooks/useLoading.d.ts +50 -0
- package/lib/presentation/loading/presentation/hooks/useLoading.d.ts.map +1 -0
- package/lib/presentation/loading/presentation/hooks/useLoading.js +49 -0
- package/lib/presentation/loading/presentation/hooks/useLoading.js.map +1 -0
- package/lib/presentation/molecules/AtomicConfirmationModal.d.ts +73 -0
- package/lib/presentation/molecules/AtomicConfirmationModal.d.ts.map +1 -0
- package/lib/presentation/molecules/AtomicConfirmationModal.js +172 -0
- package/lib/presentation/molecules/AtomicConfirmationModal.js.map +1 -0
- package/lib/presentation/molecules/EmptyState.d.ts +41 -0
- package/lib/presentation/molecules/EmptyState.d.ts.map +1 -0
- package/lib/presentation/molecules/EmptyState.js +68 -0
- package/lib/presentation/molecules/EmptyState.js.map +1 -0
- package/lib/presentation/molecules/FormField.d.ts +22 -0
- package/lib/presentation/molecules/FormField.d.ts.map +1 -0
- package/lib/presentation/molecules/FormField.js +76 -0
- package/lib/presentation/molecules/FormField.js.map +1 -0
- package/lib/presentation/molecules/GridContainer.d.ts +40 -0
- package/lib/presentation/molecules/GridContainer.d.ts.map +1 -0
- package/lib/presentation/molecules/GridContainer.js +77 -0
- package/lib/presentation/molecules/GridContainer.js.map +1 -0
- package/lib/presentation/molecules/IconContainer.d.ts +29 -0
- package/lib/presentation/molecules/IconContainer.d.ts.map +1 -0
- package/lib/presentation/molecules/IconContainer.js +60 -0
- package/lib/presentation/molecules/IconContainer.js.map +1 -0
- package/lib/presentation/molecules/LanguageSwitcher.d.ts +10 -0
- package/lib/presentation/molecules/LanguageSwitcher.d.ts.map +1 -0
- package/lib/presentation/molecules/LanguageSwitcher.js +24 -0
- package/lib/presentation/molecules/LanguageSwitcher.js.map +1 -0
- package/lib/presentation/molecules/ListItem.d.ts +5 -0
- package/lib/presentation/molecules/ListItem.d.ts.map +1 -0
- package/lib/presentation/molecules/ListItem.js +24 -0
- package/lib/presentation/molecules/ListItem.js.map +1 -0
- package/lib/presentation/molecules/ScreenHeader.d.ts +55 -0
- package/lib/presentation/molecules/ScreenHeader.d.ts.map +1 -0
- package/lib/presentation/molecules/ScreenHeader.js +94 -0
- package/lib/presentation/molecules/ScreenHeader.js.map +1 -0
- package/lib/presentation/molecules/SearchBar.d.ts +18 -0
- package/lib/presentation/molecules/SearchBar.d.ts.map +1 -0
- package/lib/presentation/molecules/SearchBar.js +47 -0
- package/lib/presentation/molecules/SearchBar.js.map +1 -0
- package/lib/presentation/molecules/SectionCard.d.ts +25 -0
- package/lib/presentation/molecules/SectionCard.d.ts.map +1 -0
- package/lib/presentation/molecules/SectionCard.js +47 -0
- package/lib/presentation/molecules/SectionCard.js.map +1 -0
- package/lib/presentation/molecules/SectionContainer.d.ts +33 -0
- package/lib/presentation/molecules/SectionContainer.d.ts.map +1 -0
- package/lib/presentation/molecules/SectionContainer.js +64 -0
- package/lib/presentation/molecules/SectionContainer.js.map +1 -0
- package/lib/presentation/molecules/SectionHeader.d.ts +37 -0
- package/lib/presentation/molecules/SectionHeader.d.ts.map +1 -0
- package/lib/presentation/molecules/SectionHeader.js +73 -0
- package/lib/presentation/molecules/SectionHeader.js.map +1 -0
- package/lib/presentation/molecules/confirmation-modal/styles/confirmationModalStyles.d.ts +50 -0
- package/lib/presentation/molecules/confirmation-modal/styles/confirmationModalStyles.d.ts.map +1 -0
- package/lib/presentation/molecules/confirmation-modal/styles/confirmationModalStyles.js +115 -0
- package/lib/presentation/molecules/confirmation-modal/styles/confirmationModalStyles.js.map +1 -0
- package/lib/presentation/molecules/confirmation-modal/types/index.d.ts +88 -0
- package/lib/presentation/molecules/confirmation-modal/types/index.d.ts.map +1 -0
- package/lib/presentation/molecules/confirmation-modal/types/index.js +7 -0
- package/lib/presentation/molecules/confirmation-modal/types/index.js.map +1 -0
- package/lib/presentation/molecules/index.d.ts +28 -0
- package/lib/presentation/molecules/index.d.ts.map +1 -0
- package/lib/presentation/molecules/index.js +18 -0
- package/lib/presentation/molecules/index.js.map +1 -0
- package/lib/presentation/molecules/languageswitcher/config/languageSwitcherConfig.d.ts +11 -0
- package/lib/presentation/molecules/languageswitcher/config/languageSwitcherConfig.d.ts.map +1 -0
- package/lib/presentation/molecules/languageswitcher/config/languageSwitcherConfig.js +6 -0
- package/lib/presentation/molecules/languageswitcher/config/languageSwitcherConfig.js.map +1 -0
- package/lib/presentation/molecules/languageswitcher/hooks/useLanguageNavigation.d.ts +5 -0
- package/lib/presentation/molecules/languageswitcher/hooks/useLanguageNavigation.d.ts.map +1 -0
- package/lib/presentation/molecules/languageswitcher/hooks/useLanguageNavigation.js +12 -0
- package/lib/presentation/molecules/languageswitcher/hooks/useLanguageNavigation.js.map +1 -0
- package/lib/presentation/molecules/listitem/styles/listItemStyles.d.ts +12 -0
- package/lib/presentation/molecules/listitem/styles/listItemStyles.d.ts.map +1 -0
- package/lib/presentation/molecules/listitem/styles/listItemStyles.js +15 -0
- package/lib/presentation/molecules/listitem/styles/listItemStyles.js.map +1 -0
- package/lib/presentation/molecules/listitem/types/index.d.ts +17 -0
- package/lib/presentation/molecules/listitem/types/index.d.ts.map +1 -0
- package/lib/presentation/molecules/listitem/types/index.js +2 -0
- package/lib/presentation/molecules/listitem/types/index.js.map +1 -0
- package/lib/presentation/organisms/AppHeader.d.ts +30 -0
- package/lib/presentation/organisms/AppHeader.d.ts.map +1 -0
- package/lib/presentation/organisms/AppHeader.js +78 -0
- package/lib/presentation/organisms/AppHeader.js.map +1 -0
- package/lib/presentation/organisms/FormContainer.d.ts +76 -0
- package/lib/presentation/organisms/FormContainer.d.ts.map +1 -0
- package/lib/presentation/organisms/FormContainer.js +127 -0
- package/lib/presentation/organisms/FormContainer.js.map +1 -0
- package/lib/presentation/organisms/ScreenLayout.d.ts +99 -0
- package/lib/presentation/organisms/ScreenLayout.d.ts.map +1 -0
- package/lib/presentation/organisms/ScreenLayout.js +78 -0
- package/lib/presentation/organisms/ScreenLayout.js.map +1 -0
- package/lib/presentation/organisms/index.d.ts +16 -0
- package/lib/presentation/organisms/index.d.ts.map +1 -0
- package/lib/presentation/organisms/index.js +14 -0
- package/lib/presentation/organisms/index.js.map +1 -0
- package/lib/presentation/tokens/AppDesignTokens.d.ts +14 -0
- package/lib/presentation/tokens/AppDesignTokens.d.ts.map +1 -0
- package/lib/presentation/tokens/AppDesignTokens.js +23 -0
- package/lib/presentation/tokens/AppDesignTokens.js.map +1 -0
- package/lib/presentation/tokens/commonStyles.d.ts +122 -0
- package/lib/presentation/tokens/commonStyles.d.ts.map +1 -0
- package/lib/presentation/tokens/commonStyles.js +220 -0
- package/lib/presentation/tokens/commonStyles.js.map +1 -0
- package/lib/presentation/tokens/core/BaseTokens.d.ts +337 -0
- package/lib/presentation/tokens/core/BaseTokens.d.ts.map +1 -0
- package/lib/presentation/tokens/core/BaseTokens.js +322 -0
- package/lib/presentation/tokens/core/BaseTokens.js.map +1 -0
- package/lib/presentation/tokens/core/ColorPalette.d.ts +216 -0
- package/lib/presentation/tokens/core/ColorPalette.d.ts.map +1 -0
- package/lib/presentation/tokens/core/ColorPalette.js +330 -0
- package/lib/presentation/tokens/core/ColorPalette.js.map +1 -0
- package/lib/presentation/tokens/core/TokenFactory.d.ts +229 -0
- package/lib/presentation/tokens/core/TokenFactory.d.ts.map +1 -0
- package/lib/presentation/tokens/core/TokenFactory.js +87 -0
- package/lib/presentation/tokens/core/TokenFactory.js.map +1 -0
- package/lib/presentation/utils/platformConstants.d.ts +100 -0
- package/lib/presentation/utils/platformConstants.d.ts.map +1 -0
- package/lib/presentation/utils/platformConstants.js +114 -0
- package/lib/presentation/utils/platformConstants.js.map +1 -0
- package/lib/presentation/utils/responsive.d.ts +218 -0
- package/lib/presentation/utils/responsive.d.ts.map +1 -0
- package/lib/presentation/utils/responsive.js +452 -0
- package/lib/presentation/utils/responsive.js.map +1 -0
- package/lib/presentation/utils/variants/compound.d.ts +10 -0
- package/lib/presentation/utils/variants/compound.d.ts.map +1 -0
- package/lib/presentation/utils/variants/compound.js +16 -0
- package/lib/presentation/utils/variants/compound.js.map +1 -0
- package/lib/presentation/utils/variants/core.d.ts +15 -0
- package/lib/presentation/utils/variants/core.d.ts.map +1 -0
- package/lib/presentation/utils/variants/core.js +23 -0
- package/lib/presentation/utils/variants/core.js.map +1 -0
- package/lib/presentation/utils/variants/helpers.d.ts +5 -0
- package/lib/presentation/utils/variants/helpers.d.ts.map +1 -0
- package/lib/presentation/utils/variants/helpers.js +10 -0
- package/lib/presentation/utils/variants/helpers.js.map +1 -0
- package/lib/presentation/utils/variants.d.ts +4 -0
- package/lib/presentation/utils/variants.d.ts.map +1 -0
- package/lib/presentation/utils/variants.js +4 -0
- package/lib/presentation/utils/variants.js.map +1 -0
- package/package.json +40 -4
- package/src/domains/icons/domain/interfaces/IIconAdapter.ts +5 -3
- package/src/domains/icons/infrastructure/adapters/LucideAdapter.ts +1 -1
- package/src/presentation/molecules/AtomicConfirmationModal.tsx +1 -1
- package/src/presentation/molecules/languageswitcher/hooks/useLanguageNavigation.ts +1 -2
|
@@ -0,0 +1,229 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TOKEN FACTORY - THEME INJECTION LOGIC
|
|
3
|
+
*
|
|
4
|
+
* ✅ Factory Pattern for creating complete design tokens
|
|
5
|
+
* ✅ Combines static tokens (BaseTokens) + dynamic colors (ColorPalette)
|
|
6
|
+
* ✅ Type-safe token generation
|
|
7
|
+
* ✅ Zero duplication - SINGLE SOURCE OF TRUTH
|
|
8
|
+
*
|
|
9
|
+
* @module TokenFactory
|
|
10
|
+
*/
|
|
11
|
+
import { BASE_TOKENS } from './BaseTokens';
|
|
12
|
+
import { withAlpha, type ThemeMode, type ColorPalette } from './ColorPalette';
|
|
13
|
+
/**
|
|
14
|
+
* Complete design tokens shape
|
|
15
|
+
* Combines static tokens (spacing, typography, animations, borders) + dynamic colors
|
|
16
|
+
*/
|
|
17
|
+
export type DesignTokens = {
|
|
18
|
+
colors: ColorPalette;
|
|
19
|
+
spacing: typeof BASE_TOKENS.spacing;
|
|
20
|
+
typography: typeof BASE_TOKENS.typography;
|
|
21
|
+
animations: typeof BASE_TOKENS.animations;
|
|
22
|
+
iconSizes: typeof BASE_TOKENS.iconSizes;
|
|
23
|
+
opacity: typeof BASE_TOKENS.opacity;
|
|
24
|
+
avatarSizes: typeof BASE_TOKENS.avatarSizes;
|
|
25
|
+
borders: typeof BASE_TOKENS.borders & {
|
|
26
|
+
card: typeof BASE_TOKENS.borders.card & {
|
|
27
|
+
borderColor: string;
|
|
28
|
+
};
|
|
29
|
+
input: typeof BASE_TOKENS.borders.input & {
|
|
30
|
+
borderColor: string;
|
|
31
|
+
};
|
|
32
|
+
};
|
|
33
|
+
};
|
|
34
|
+
/**
|
|
35
|
+
* Create complete design tokens for a specific theme mode
|
|
36
|
+
*
|
|
37
|
+
* @param mode - Theme mode ('light' or 'dark')
|
|
38
|
+
* @returns Complete design tokens object
|
|
39
|
+
*
|
|
40
|
+
* @example
|
|
41
|
+
* ```typescript
|
|
42
|
+
* const lightTokens = createDesignTokens('light');
|
|
43
|
+
* const darkTokens = createDesignTokens('dark');
|
|
44
|
+
*
|
|
45
|
+
* // Use in components
|
|
46
|
+
* <View style={{ backgroundColor: lightTokens.colors.primary }}>
|
|
47
|
+
* <Text style={lightTokens.typography.bodyLarge}>Hello!</Text>
|
|
48
|
+
* </View>
|
|
49
|
+
* ```
|
|
50
|
+
*/
|
|
51
|
+
export declare const createDesignTokens: (mode: ThemeMode) => DesignTokens;
|
|
52
|
+
/**
|
|
53
|
+
* STATIC DESIGN TOKENS - LIGHT THEME ONLY
|
|
54
|
+
*
|
|
55
|
+
* ⚠️ WARNING: These are STATIC and use light theme colors only!
|
|
56
|
+
* ⚠️ DO NOT USE in React components - use useAppDesignTokens() hook instead
|
|
57
|
+
*
|
|
58
|
+
* Only use these in:
|
|
59
|
+
* - Utility functions
|
|
60
|
+
* - Constants files
|
|
61
|
+
* - Non-React JavaScript code
|
|
62
|
+
*
|
|
63
|
+
* @deprecated Use useAppDesignTokens() hook in React components
|
|
64
|
+
*/
|
|
65
|
+
export declare const STATIC_DESIGN_TOKENS: DesignTokens;
|
|
66
|
+
/**
|
|
67
|
+
* STATIC TOKENS (spacing, typography, animations, borders)
|
|
68
|
+
* These DON'T change with theme - safe to use anywhere
|
|
69
|
+
*/
|
|
70
|
+
export declare const STATIC_TOKENS: {
|
|
71
|
+
readonly spacing: {
|
|
72
|
+
readonly xs: 4;
|
|
73
|
+
readonly sm: 8;
|
|
74
|
+
readonly md: 16;
|
|
75
|
+
readonly lg: 24;
|
|
76
|
+
readonly xl: 32;
|
|
77
|
+
readonly xxl: 48;
|
|
78
|
+
readonly xxxl: 64;
|
|
79
|
+
readonly screenPadding: 20;
|
|
80
|
+
readonly cardPadding: 16;
|
|
81
|
+
readonly buttonPadding: 16;
|
|
82
|
+
readonly inputPadding: 8;
|
|
83
|
+
readonly sectionSpacing: 24;
|
|
84
|
+
readonly iconSizeSmall: 16;
|
|
85
|
+
readonly iconSizeMedium: 20;
|
|
86
|
+
readonly iconSizeLarge: 24;
|
|
87
|
+
readonly iconSizeXLarge: 32;
|
|
88
|
+
readonly iconSizeHero: 64;
|
|
89
|
+
readonly buttonHeight: 48;
|
|
90
|
+
readonly inputHeight: 48;
|
|
91
|
+
readonly appBarHeight: 56;
|
|
92
|
+
readonly tabBarHeight: 60;
|
|
93
|
+
};
|
|
94
|
+
readonly typography: {
|
|
95
|
+
readonly fontPrimary: "System";
|
|
96
|
+
readonly fontSecondary: "System";
|
|
97
|
+
readonly fontMono: "Courier New";
|
|
98
|
+
readonly xs: 12;
|
|
99
|
+
readonly sm: 14;
|
|
100
|
+
readonly md: 16;
|
|
101
|
+
readonly lg: 18;
|
|
102
|
+
readonly xl: 20;
|
|
103
|
+
readonly xxl: 24;
|
|
104
|
+
readonly xxxl: 32;
|
|
105
|
+
readonly light: "300";
|
|
106
|
+
readonly regular: "400";
|
|
107
|
+
readonly medium: "500";
|
|
108
|
+
readonly semibold: "600";
|
|
109
|
+
readonly bold: "700";
|
|
110
|
+
readonly lineHeightTight: 1.2;
|
|
111
|
+
readonly lineHeightNormal: 1.5;
|
|
112
|
+
readonly lineHeightRelaxed: 1.7;
|
|
113
|
+
readonly displayLarge: import("react-native").TextStyle;
|
|
114
|
+
readonly displayMedium: import("react-native").TextStyle;
|
|
115
|
+
readonly displaySmall: import("react-native").TextStyle;
|
|
116
|
+
readonly headlineLarge: import("react-native").TextStyle;
|
|
117
|
+
readonly headlineMedium: import("react-native").TextStyle;
|
|
118
|
+
readonly headlineSmall: import("react-native").TextStyle;
|
|
119
|
+
readonly titleLarge: import("react-native").TextStyle;
|
|
120
|
+
readonly titleMedium: import("react-native").TextStyle;
|
|
121
|
+
readonly titleSmall: import("react-native").TextStyle;
|
|
122
|
+
readonly bodyLarge: import("react-native").TextStyle;
|
|
123
|
+
readonly bodyMedium: import("react-native").TextStyle;
|
|
124
|
+
readonly bodySmall: import("react-native").TextStyle;
|
|
125
|
+
readonly labelLarge: import("react-native").TextStyle;
|
|
126
|
+
readonly labelMedium: import("react-native").TextStyle;
|
|
127
|
+
readonly labelSmall: import("react-native").TextStyle;
|
|
128
|
+
readonly headingLarge: import("react-native").TextStyle;
|
|
129
|
+
readonly headingMedium: import("react-native").TextStyle;
|
|
130
|
+
readonly headingSmall: import("react-native").TextStyle;
|
|
131
|
+
readonly button: import("react-native").TextStyle;
|
|
132
|
+
readonly caption: import("react-native").TextStyle;
|
|
133
|
+
readonly overline: import("react-native").TextStyle;
|
|
134
|
+
};
|
|
135
|
+
readonly animations: {
|
|
136
|
+
readonly fastest: 150;
|
|
137
|
+
readonly fast: 150;
|
|
138
|
+
readonly normal: 300;
|
|
139
|
+
readonly slow: 500;
|
|
140
|
+
readonly slower: 750;
|
|
141
|
+
readonly slowest: 1000;
|
|
142
|
+
readonly easeInOut: "ease-in-out";
|
|
143
|
+
readonly easeIn: "ease-in";
|
|
144
|
+
readonly easeOut: "ease-out";
|
|
145
|
+
readonly linear: "linear";
|
|
146
|
+
};
|
|
147
|
+
readonly opacity: {
|
|
148
|
+
readonly disabled: 0.6;
|
|
149
|
+
readonly subtle: 0.8;
|
|
150
|
+
readonly medium: 0.5;
|
|
151
|
+
readonly light: 0.3;
|
|
152
|
+
readonly veryLight: 0.1;
|
|
153
|
+
};
|
|
154
|
+
readonly borders: {
|
|
155
|
+
readonly radius: {
|
|
156
|
+
readonly none: 0;
|
|
157
|
+
readonly xs: 2;
|
|
158
|
+
readonly sm: 4;
|
|
159
|
+
readonly md: 8;
|
|
160
|
+
readonly lg: 12;
|
|
161
|
+
readonly xl: 16;
|
|
162
|
+
readonly xxl: 24;
|
|
163
|
+
readonly full: 9999;
|
|
164
|
+
};
|
|
165
|
+
readonly width: {
|
|
166
|
+
readonly none: 0;
|
|
167
|
+
readonly thin: 1;
|
|
168
|
+
readonly medium: 2;
|
|
169
|
+
readonly thick: 4;
|
|
170
|
+
};
|
|
171
|
+
readonly button: {
|
|
172
|
+
readonly borderRadius: 8;
|
|
173
|
+
readonly borderWidth: 0;
|
|
174
|
+
};
|
|
175
|
+
readonly card: {
|
|
176
|
+
readonly borderRadius: 12;
|
|
177
|
+
readonly borderWidth: 1;
|
|
178
|
+
};
|
|
179
|
+
readonly input: {
|
|
180
|
+
readonly borderRadius: 8;
|
|
181
|
+
readonly borderWidth: 1;
|
|
182
|
+
};
|
|
183
|
+
readonly pill: {
|
|
184
|
+
readonly borderRadius: 9999;
|
|
185
|
+
readonly borderWidth: 0;
|
|
186
|
+
};
|
|
187
|
+
};
|
|
188
|
+
readonly sizes: {
|
|
189
|
+
readonly touchTarget: 44;
|
|
190
|
+
readonly touchTargetSmall: 36;
|
|
191
|
+
readonly touchTargetLarge: 56;
|
|
192
|
+
readonly buttonHeight: {
|
|
193
|
+
readonly sm: 40;
|
|
194
|
+
readonly md: 48;
|
|
195
|
+
readonly lg: 56;
|
|
196
|
+
readonly xl: 64;
|
|
197
|
+
};
|
|
198
|
+
readonly dot: {
|
|
199
|
+
readonly inactive: 8;
|
|
200
|
+
readonly active: 24;
|
|
201
|
+
};
|
|
202
|
+
readonly progressBar: {
|
|
203
|
+
readonly thin: 2;
|
|
204
|
+
readonly normal: 4;
|
|
205
|
+
readonly thick: 6;
|
|
206
|
+
};
|
|
207
|
+
readonly divider: 1;
|
|
208
|
+
readonly separator: 2;
|
|
209
|
+
};
|
|
210
|
+
readonly iconSizes: {
|
|
211
|
+
readonly xs: 12;
|
|
212
|
+
readonly sm: 16;
|
|
213
|
+
readonly md: 20;
|
|
214
|
+
readonly lg: 24;
|
|
215
|
+
readonly xl: 32;
|
|
216
|
+
readonly xxl: 40;
|
|
217
|
+
};
|
|
218
|
+
readonly avatarSizes: {
|
|
219
|
+
readonly xs: 24;
|
|
220
|
+
readonly sm: 32;
|
|
221
|
+
readonly md: 40;
|
|
222
|
+
readonly lg: 48;
|
|
223
|
+
readonly xl: 64;
|
|
224
|
+
readonly xxl: 80;
|
|
225
|
+
};
|
|
226
|
+
};
|
|
227
|
+
export { withAlpha };
|
|
228
|
+
export type { ThemeMode, ColorPalette };
|
|
229
|
+
//# sourceMappingURL=TokenFactory.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TokenFactory.d.ts","sourceRoot":"","sources":["../../../../src/presentation/tokens/core/TokenFactory.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,EAAmB,SAAS,EAAE,KAAK,SAAS,EAAE,KAAK,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAM/F;;;GAGG;AACH,MAAM,MAAM,YAAY,GAAG;IACzB,MAAM,EAAE,YAAY,CAAC;IACrB,OAAO,EAAE,OAAO,WAAW,CAAC,OAAO,CAAC;IACpC,UAAU,EAAE,OAAO,WAAW,CAAC,UAAU,CAAC;IAC1C,UAAU,EAAE,OAAO,WAAW,CAAC,UAAU,CAAC;IAC1C,SAAS,EAAE,OAAO,WAAW,CAAC,SAAS,CAAC;IACxC,OAAO,EAAE,OAAO,WAAW,CAAC,OAAO,CAAC;IACpC,WAAW,EAAE,OAAO,WAAW,CAAC,WAAW,CAAC;IAC5C,OAAO,EAAE,OAAO,WAAW,CAAC,OAAO,GAAG;QACpC,IAAI,EAAE,OAAO,WAAW,CAAC,OAAO,CAAC,IAAI,GAAG;YAAE,WAAW,EAAE,MAAM,CAAA;SAAE,CAAC;QAChE,KAAK,EAAE,OAAO,WAAW,CAAC,OAAO,CAAC,KAAK,GAAG;YAAE,WAAW,EAAE,MAAM,CAAA;SAAE,CAAC;KACnE,CAAC;CACH,CAAC;AAMF;;;;;;;;;;;;;;;;GAgBG;AACH,eAAO,MAAM,kBAAkB,GAAI,MAAM,SAAS,KAAG,YA8BpD,CAAC;AAMF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,oBAAoB,cAA8B,CAAC;AAEhE;;;GAGG;AACH,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAAc,CAAC;AAMzC,OAAO,EAAE,SAAS,EAAE,CAAC;AACrB,YAAY,EAAE,SAAS,EAAE,YAAY,EAAE,CAAC"}
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TOKEN FACTORY - THEME INJECTION LOGIC
|
|
3
|
+
*
|
|
4
|
+
* ✅ Factory Pattern for creating complete design tokens
|
|
5
|
+
* ✅ Combines static tokens (BaseTokens) + dynamic colors (ColorPalette)
|
|
6
|
+
* ✅ Type-safe token generation
|
|
7
|
+
* ✅ Zero duplication - SINGLE SOURCE OF TRUTH
|
|
8
|
+
*
|
|
9
|
+
* @module TokenFactory
|
|
10
|
+
*/
|
|
11
|
+
import { BASE_TOKENS } from './BaseTokens';
|
|
12
|
+
import { getColorPalette, withAlpha } from './ColorPalette';
|
|
13
|
+
// =============================================================================
|
|
14
|
+
// TOKEN FACTORY FUNCTION
|
|
15
|
+
// =============================================================================
|
|
16
|
+
/**
|
|
17
|
+
* Create complete design tokens for a specific theme mode
|
|
18
|
+
*
|
|
19
|
+
* @param mode - Theme mode ('light' or 'dark')
|
|
20
|
+
* @returns Complete design tokens object
|
|
21
|
+
*
|
|
22
|
+
* @example
|
|
23
|
+
* ```typescript
|
|
24
|
+
* const lightTokens = createDesignTokens('light');
|
|
25
|
+
* const darkTokens = createDesignTokens('dark');
|
|
26
|
+
*
|
|
27
|
+
* // Use in components
|
|
28
|
+
* <View style={{ backgroundColor: lightTokens.colors.primary }}>
|
|
29
|
+
* <Text style={lightTokens.typography.bodyLarge}>Hello!</Text>
|
|
30
|
+
* </View>
|
|
31
|
+
* ```
|
|
32
|
+
*/
|
|
33
|
+
export const createDesignTokens = (mode) => {
|
|
34
|
+
// Get color palette for theme mode
|
|
35
|
+
const colors = getColorPalette(mode);
|
|
36
|
+
// Combine static tokens + dynamic colors
|
|
37
|
+
return {
|
|
38
|
+
// ✅ DYNAMIC: Colors from theme mode
|
|
39
|
+
colors,
|
|
40
|
+
// ✅ STATIC: These don't change with theme
|
|
41
|
+
spacing: BASE_TOKENS.spacing,
|
|
42
|
+
typography: BASE_TOKENS.typography,
|
|
43
|
+
animations: BASE_TOKENS.animations,
|
|
44
|
+
iconSizes: BASE_TOKENS.iconSizes,
|
|
45
|
+
opacity: BASE_TOKENS.opacity,
|
|
46
|
+
avatarSizes: BASE_TOKENS.avatarSizes,
|
|
47
|
+
// ✅ BORDERS: Static + injected border colors from theme
|
|
48
|
+
borders: {
|
|
49
|
+
...BASE_TOKENS.borders,
|
|
50
|
+
card: {
|
|
51
|
+
...BASE_TOKENS.borders.card,
|
|
52
|
+
borderColor: colors.border,
|
|
53
|
+
},
|
|
54
|
+
input: {
|
|
55
|
+
...BASE_TOKENS.borders.input,
|
|
56
|
+
borderColor: colors.border,
|
|
57
|
+
},
|
|
58
|
+
},
|
|
59
|
+
};
|
|
60
|
+
};
|
|
61
|
+
// =============================================================================
|
|
62
|
+
// STATIC TOKEN INSTANCES (for non-React contexts)
|
|
63
|
+
// =============================================================================
|
|
64
|
+
/**
|
|
65
|
+
* STATIC DESIGN TOKENS - LIGHT THEME ONLY
|
|
66
|
+
*
|
|
67
|
+
* ⚠️ WARNING: These are STATIC and use light theme colors only!
|
|
68
|
+
* ⚠️ DO NOT USE in React components - use useAppDesignTokens() hook instead
|
|
69
|
+
*
|
|
70
|
+
* Only use these in:
|
|
71
|
+
* - Utility functions
|
|
72
|
+
* - Constants files
|
|
73
|
+
* - Non-React JavaScript code
|
|
74
|
+
*
|
|
75
|
+
* @deprecated Use useAppDesignTokens() hook in React components
|
|
76
|
+
*/
|
|
77
|
+
export const STATIC_DESIGN_TOKENS = createDesignTokens('light');
|
|
78
|
+
/**
|
|
79
|
+
* STATIC TOKENS (spacing, typography, animations, borders)
|
|
80
|
+
* These DON'T change with theme - safe to use anywhere
|
|
81
|
+
*/
|
|
82
|
+
export const STATIC_TOKENS = BASE_TOKENS;
|
|
83
|
+
// =============================================================================
|
|
84
|
+
// UTILITY EXPORTS
|
|
85
|
+
// =============================================================================
|
|
86
|
+
export { withAlpha };
|
|
87
|
+
//# sourceMappingURL=TokenFactory.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TokenFactory.js","sourceRoot":"","sources":["../../../../src/presentation/tokens/core/TokenFactory.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAC3C,OAAO,EAAE,eAAe,EAAE,SAAS,EAAqC,MAAM,gBAAgB,CAAC;AAwB/F,gFAAgF;AAChF,yBAAyB;AACzB,gFAAgF;AAEhF;;;;;;;;;;;;;;;;GAgBG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,IAAe,EAAgB,EAAE;IAClE,mCAAmC;IACnC,MAAM,MAAM,GAAG,eAAe,CAAC,IAAI,CAAC,CAAC;IAErC,yCAAyC;IACzC,OAAO;QACL,oCAAoC;QACpC,MAAM;QAEN,0CAA0C;QAC1C,OAAO,EAAE,WAAW,CAAC,OAAO;QAC5B,UAAU,EAAE,WAAW,CAAC,UAAU;QAClC,UAAU,EAAE,WAAW,CAAC,UAAU;QAClC,SAAS,EAAE,WAAW,CAAC,SAAS;QAChC,OAAO,EAAE,WAAW,CAAC,OAAO;QAC5B,WAAW,EAAE,WAAW,CAAC,WAAW;QAEpC,wDAAwD;QACxD,OAAO,EAAE;YACP,GAAG,WAAW,CAAC,OAAO;YACtB,IAAI,EAAE;gBACJ,GAAG,WAAW,CAAC,OAAO,CAAC,IAAI;gBAC3B,WAAW,EAAE,MAAM,CAAC,MAAM;aAC3B;YACD,KAAK,EAAE;gBACL,GAAG,WAAW,CAAC,OAAO,CAAC,KAAK;gBAC5B,WAAW,EAAE,MAAM,CAAC,MAAM;aAC3B;SACF;KACF,CAAC;AACJ,CAAC,CAAC;AAEF,gFAAgF;AAChF,kDAAkD;AAClD,gFAAgF;AAEhF;;;;;;;;;;;;GAYG;AACH,MAAM,CAAC,MAAM,oBAAoB,GAAG,kBAAkB,CAAC,OAAO,CAAC,CAAC;AAEhE;;;GAGG;AACH,MAAM,CAAC,MAAM,aAAa,GAAG,WAAW,CAAC;AAEzC,gFAAgF;AAChF,kBAAkB;AAClB,gFAAgF;AAEhF,OAAO,EAAE,SAAS,EAAE,CAAC"}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Platform-Specific Constants
|
|
3
|
+
*
|
|
4
|
+
* Design system constants that ensure compliance with platform guidelines.
|
|
5
|
+
* These values are based on official Human Interface Guidelines (HIG) from Apple and Material Design from Google.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* iOS Human Interface Guidelines (HIG) Constants
|
|
9
|
+
*
|
|
10
|
+
* @see https://developer.apple.com/design/human-interface-guidelines/layout
|
|
11
|
+
*/
|
|
12
|
+
export declare const IOS_HIG: {
|
|
13
|
+
/**
|
|
14
|
+
* Minimum Touch Target Size
|
|
15
|
+
*
|
|
16
|
+
* Apple requires a minimum tappable area of 44pt x 44pt for ALL interactive controls.
|
|
17
|
+
* This is enforced during App Store review.
|
|
18
|
+
*
|
|
19
|
+
* @critical Violating this can result in App Store rejection
|
|
20
|
+
*/
|
|
21
|
+
readonly MIN_TOUCH_TARGET: 44;
|
|
22
|
+
/**
|
|
23
|
+
* Recommended Minimum Touch Target Size
|
|
24
|
+
*
|
|
25
|
+
* For better accessibility and usability, Apple recommends 48pt x 48pt.
|
|
26
|
+
*/
|
|
27
|
+
readonly RECOMMENDED_TOUCH_TARGET: 48;
|
|
28
|
+
/**
|
|
29
|
+
* Minimum Text Size
|
|
30
|
+
*
|
|
31
|
+
* Minimum font size for body text to ensure readability.
|
|
32
|
+
*/
|
|
33
|
+
readonly MIN_TEXT_SIZE: 17;
|
|
34
|
+
/**
|
|
35
|
+
* Minimum Contrast Ratio
|
|
36
|
+
*
|
|
37
|
+
* WCAG AA compliance requires 4.5:1 for normal text.
|
|
38
|
+
*/
|
|
39
|
+
readonly MIN_CONTRAST_RATIO: 4.5;
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* Android Material Design Guidelines Constants
|
|
43
|
+
*
|
|
44
|
+
* @see https://m3.material.io/foundations/layout/applying-layout/window-size-classes
|
|
45
|
+
*/
|
|
46
|
+
export declare const ANDROID_MATERIAL: {
|
|
47
|
+
/**
|
|
48
|
+
* Minimum Touch Target Size
|
|
49
|
+
*
|
|
50
|
+
* Material Design 3 recommends a minimum of 48dp x 48dp.
|
|
51
|
+
*/
|
|
52
|
+
readonly MIN_TOUCH_TARGET: 48;
|
|
53
|
+
/**
|
|
54
|
+
* Minimum Text Size
|
|
55
|
+
*
|
|
56
|
+
* Minimum font size for body text.
|
|
57
|
+
*/
|
|
58
|
+
readonly MIN_TEXT_SIZE: 14;
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Universal Platform Constants
|
|
62
|
+
*
|
|
63
|
+
* These values work across both iOS and Android, taking the more restrictive requirement.
|
|
64
|
+
*/
|
|
65
|
+
export declare const PLATFORM_CONSTANTS: {
|
|
66
|
+
/**
|
|
67
|
+
* Minimum Touch Target Size
|
|
68
|
+
*
|
|
69
|
+
* Uses iOS requirement (44pt) as it's more restrictive than Android (48dp).
|
|
70
|
+
* This ensures compliance on both platforms.
|
|
71
|
+
*/
|
|
72
|
+
readonly MIN_TOUCH_TARGET: number;
|
|
73
|
+
/**
|
|
74
|
+
* Recommended Touch Target Size
|
|
75
|
+
*
|
|
76
|
+
* Uses the higher value between iOS and Android recommendations.
|
|
77
|
+
*/
|
|
78
|
+
readonly RECOMMENDED_TOUCH_TARGET: 48;
|
|
79
|
+
/**
|
|
80
|
+
* Minimum Text Size
|
|
81
|
+
*
|
|
82
|
+
* Uses iOS requirement as it's larger.
|
|
83
|
+
*/
|
|
84
|
+
readonly MIN_TEXT_SIZE: number;
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* Helper function to validate touch target size
|
|
88
|
+
*
|
|
89
|
+
* @param size - The size to validate (in pt/dp)
|
|
90
|
+
* @returns true if size meets platform requirements
|
|
91
|
+
*/
|
|
92
|
+
export declare const isValidTouchTarget: (size: number) => boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Helper function to get minimum touch target for component
|
|
95
|
+
*
|
|
96
|
+
* @param componentType - The type of component ('button' | 'input' | 'icon' | 'generic')
|
|
97
|
+
* @returns The minimum touch target size for that component type
|
|
98
|
+
*/
|
|
99
|
+
export declare const getMinTouchTarget: (componentType?: "button" | "input" | "icon" | "generic") => number;
|
|
100
|
+
//# sourceMappingURL=platformConstants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platformConstants.d.ts","sourceRoot":"","sources":["../../../src/presentation/utils/platformConstants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;;;GAIG;AACH,eAAO,MAAM,OAAO;IAClB;;;;;;;OAOG;;IAGH;;;;OAIG;;IAGH;;;;OAIG;;IAGH;;;;OAIG;;CAEK,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,gBAAgB;IAC3B;;;;OAIG;;IAGH;;;;OAIG;;CAEK,CAAC;AAEX;;;;GAIG;AACH,eAAO,MAAM,kBAAkB;IAC7B;;;;;OAKG;;IAGH;;;;OAIG;;IAGH;;;;OAIG;;CAEK,CAAC;AAEX;;;;;GAKG;AACH,eAAO,MAAM,kBAAkB,GAAI,MAAM,MAAM,KAAG,OAEjD,CAAC;AAEF;;;;;GAKG;AACH,eAAO,MAAM,iBAAiB,GAAI,gBAAe,QAAQ,GAAG,OAAO,GAAG,MAAM,GAAG,SAAqB,KAAG,MAYtG,CAAC"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Platform-Specific Constants
|
|
3
|
+
*
|
|
4
|
+
* Design system constants that ensure compliance with platform guidelines.
|
|
5
|
+
* These values are based on official Human Interface Guidelines (HIG) from Apple and Material Design from Google.
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* iOS Human Interface Guidelines (HIG) Constants
|
|
9
|
+
*
|
|
10
|
+
* @see https://developer.apple.com/design/human-interface-guidelines/layout
|
|
11
|
+
*/
|
|
12
|
+
export const IOS_HIG = {
|
|
13
|
+
/**
|
|
14
|
+
* Minimum Touch Target Size
|
|
15
|
+
*
|
|
16
|
+
* Apple requires a minimum tappable area of 44pt x 44pt for ALL interactive controls.
|
|
17
|
+
* This is enforced during App Store review.
|
|
18
|
+
*
|
|
19
|
+
* @critical Violating this can result in App Store rejection
|
|
20
|
+
*/
|
|
21
|
+
MIN_TOUCH_TARGET: 44,
|
|
22
|
+
/**
|
|
23
|
+
* Recommended Minimum Touch Target Size
|
|
24
|
+
*
|
|
25
|
+
* For better accessibility and usability, Apple recommends 48pt x 48pt.
|
|
26
|
+
*/
|
|
27
|
+
RECOMMENDED_TOUCH_TARGET: 48,
|
|
28
|
+
/**
|
|
29
|
+
* Minimum Text Size
|
|
30
|
+
*
|
|
31
|
+
* Minimum font size for body text to ensure readability.
|
|
32
|
+
*/
|
|
33
|
+
MIN_TEXT_SIZE: 17,
|
|
34
|
+
/**
|
|
35
|
+
* Minimum Contrast Ratio
|
|
36
|
+
*
|
|
37
|
+
* WCAG AA compliance requires 4.5:1 for normal text.
|
|
38
|
+
*/
|
|
39
|
+
MIN_CONTRAST_RATIO: 4.5,
|
|
40
|
+
};
|
|
41
|
+
/**
|
|
42
|
+
* Android Material Design Guidelines Constants
|
|
43
|
+
*
|
|
44
|
+
* @see https://m3.material.io/foundations/layout/applying-layout/window-size-classes
|
|
45
|
+
*/
|
|
46
|
+
export const ANDROID_MATERIAL = {
|
|
47
|
+
/**
|
|
48
|
+
* Minimum Touch Target Size
|
|
49
|
+
*
|
|
50
|
+
* Material Design 3 recommends a minimum of 48dp x 48dp.
|
|
51
|
+
*/
|
|
52
|
+
MIN_TOUCH_TARGET: 48,
|
|
53
|
+
/**
|
|
54
|
+
* Minimum Text Size
|
|
55
|
+
*
|
|
56
|
+
* Minimum font size for body text.
|
|
57
|
+
*/
|
|
58
|
+
MIN_TEXT_SIZE: 14,
|
|
59
|
+
};
|
|
60
|
+
/**
|
|
61
|
+
* Universal Platform Constants
|
|
62
|
+
*
|
|
63
|
+
* These values work across both iOS and Android, taking the more restrictive requirement.
|
|
64
|
+
*/
|
|
65
|
+
export const PLATFORM_CONSTANTS = {
|
|
66
|
+
/**
|
|
67
|
+
* Minimum Touch Target Size
|
|
68
|
+
*
|
|
69
|
+
* Uses iOS requirement (44pt) as it's more restrictive than Android (48dp).
|
|
70
|
+
* This ensures compliance on both platforms.
|
|
71
|
+
*/
|
|
72
|
+
MIN_TOUCH_TARGET: Math.max(IOS_HIG.MIN_TOUCH_TARGET, ANDROID_MATERIAL.MIN_TOUCH_TARGET),
|
|
73
|
+
/**
|
|
74
|
+
* Recommended Touch Target Size
|
|
75
|
+
*
|
|
76
|
+
* Uses the higher value between iOS and Android recommendations.
|
|
77
|
+
*/
|
|
78
|
+
RECOMMENDED_TOUCH_TARGET: 48,
|
|
79
|
+
/**
|
|
80
|
+
* Minimum Text Size
|
|
81
|
+
*
|
|
82
|
+
* Uses iOS requirement as it's larger.
|
|
83
|
+
*/
|
|
84
|
+
MIN_TEXT_SIZE: Math.max(IOS_HIG.MIN_TEXT_SIZE, ANDROID_MATERIAL.MIN_TEXT_SIZE),
|
|
85
|
+
};
|
|
86
|
+
/**
|
|
87
|
+
* Helper function to validate touch target size
|
|
88
|
+
*
|
|
89
|
+
* @param size - The size to validate (in pt/dp)
|
|
90
|
+
* @returns true if size meets platform requirements
|
|
91
|
+
*/
|
|
92
|
+
export const isValidTouchTarget = (size) => {
|
|
93
|
+
return size >= IOS_HIG.MIN_TOUCH_TARGET;
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* Helper function to get minimum touch target for component
|
|
97
|
+
*
|
|
98
|
+
* @param componentType - The type of component ('button' | 'input' | 'icon' | 'generic')
|
|
99
|
+
* @returns The minimum touch target size for that component type
|
|
100
|
+
*/
|
|
101
|
+
export const getMinTouchTarget = (componentType = 'generic') => {
|
|
102
|
+
switch (componentType) {
|
|
103
|
+
case 'button':
|
|
104
|
+
return PLATFORM_CONSTANTS.RECOMMENDED_TOUCH_TARGET; // 48pt recommended for buttons
|
|
105
|
+
case 'input':
|
|
106
|
+
return PLATFORM_CONSTANTS.RECOMMENDED_TOUCH_TARGET; // 48pt recommended for inputs
|
|
107
|
+
case 'icon':
|
|
108
|
+
return IOS_HIG.MIN_TOUCH_TARGET; // 44pt minimum for icon buttons
|
|
109
|
+
case 'generic':
|
|
110
|
+
default:
|
|
111
|
+
return IOS_HIG.MIN_TOUCH_TARGET; // 44pt minimum for all other interactive elements
|
|
112
|
+
}
|
|
113
|
+
};
|
|
114
|
+
//# sourceMappingURL=platformConstants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"platformConstants.js","sourceRoot":"","sources":["../../../src/presentation/utils/platformConstants.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH;;;;GAIG;AACH,MAAM,CAAC,MAAM,OAAO,GAAG;IACrB;;;;;;;OAOG;IACH,gBAAgB,EAAE,EAAE;IAEpB;;;;OAIG;IACH,wBAAwB,EAAE,EAAE;IAE5B;;;;OAIG;IACH,aAAa,EAAE,EAAE;IAEjB;;;;OAIG;IACH,kBAAkB,EAAE,GAAG;CACf,CAAC;AAEX;;;;GAIG;AACH,MAAM,CAAC,MAAM,gBAAgB,GAAG;IAC9B;;;;OAIG;IACH,gBAAgB,EAAE,EAAE;IAEpB;;;;OAIG;IACH,aAAa,EAAE,EAAE;CACT,CAAC;AAEX;;;;GAIG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG;IAChC;;;;;OAKG;IACH,gBAAgB,EAAE,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,gBAAgB,EAAE,gBAAgB,CAAC,gBAAgB,CAAC;IAEvF;;;;OAIG;IACH,wBAAwB,EAAE,EAAE;IAE5B;;;;OAIG;IACH,aAAa,EAAE,IAAI,CAAC,GAAG,CAAC,OAAO,CAAC,aAAa,EAAE,gBAAgB,CAAC,aAAa,CAAC;CACtE,CAAC;AAEX;;;;;GAKG;AACH,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,IAAY,EAAW,EAAE;IAC1D,OAAO,IAAI,IAAI,OAAO,CAAC,gBAAgB,CAAC;AAC1C,CAAC,CAAC;AAEF;;;;;GAKG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,gBAAyD,SAAS,EAAU,EAAE;IAC9G,QAAQ,aAAa,EAAE,CAAC;QACtB,KAAK,QAAQ;YACX,OAAO,kBAAkB,CAAC,wBAAwB,CAAC,CAAC,+BAA+B;QACrF,KAAK,OAAO;YACV,OAAO,kBAAkB,CAAC,wBAAwB,CAAC,CAAC,8BAA8B;QACpF,KAAK,MAAM;YACT,OAAO,OAAO,CAAC,gBAAgB,CAAC,CAAC,gCAAgC;QACnE,KAAK,SAAS,CAAC;QACf;YACE,OAAO,OAAO,CAAC,gBAAgB,CAAC,CAAC,kDAAkD;IACvF,CAAC;AACH,CAAC,CAAC"}
|