orn-ui 0.2.10 → 0.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/AGENTS.md +66 -51
- package/README.md +3 -7
- package/lib/commonjs/atoms/Avatar.js +77 -5
- package/lib/commonjs/atoms/Avatar.js.map +1 -1
- package/lib/commonjs/atoms/Badge.js +17 -8
- package/lib/commonjs/atoms/Badge.js.map +1 -1
- package/lib/commonjs/atoms/Button.js +108 -39
- package/lib/commonjs/atoms/Button.js.map +1 -1
- package/lib/commonjs/atoms/Card.js +24 -2
- package/lib/commonjs/atoms/Card.js.map +1 -1
- package/lib/commonjs/atoms/Checkbox.js +41 -10
- package/lib/commonjs/atoms/Checkbox.js.map +1 -1
- package/lib/commonjs/atoms/Divider.js +30 -5
- package/lib/commonjs/atoms/Divider.js.map +1 -1
- package/lib/commonjs/atoms/EmptyState.js +58 -20
- package/lib/commonjs/atoms/EmptyState.js.map +1 -1
- package/lib/commonjs/atoms/Fab.js +32 -12
- package/lib/commonjs/atoms/Fab.js.map +1 -1
- package/lib/commonjs/atoms/Gradient.js +102 -36
- package/lib/commonjs/atoms/Gradient.js.map +1 -1
- package/lib/commonjs/atoms/IconButton.js +25 -4
- package/lib/commonjs/atoms/IconButton.js.map +1 -1
- package/lib/commonjs/atoms/Image.js +61 -25
- package/lib/commonjs/atoms/Image.js.map +1 -1
- package/lib/commonjs/atoms/Input.js +105 -17
- package/lib/commonjs/atoms/Input.js.map +1 -1
- package/lib/commonjs/atoms/KeyValueRow.js +37 -9
- package/lib/commonjs/atoms/KeyValueRow.js.map +1 -1
- package/lib/commonjs/atoms/PressableScale.js +25 -5
- package/lib/commonjs/atoms/PressableScale.js.map +1 -1
- package/lib/commonjs/atoms/ShinyText.js +29 -29
- package/lib/commonjs/atoms/Skeleton.js +28 -13
- package/lib/commonjs/atoms/Skeleton.js.map +1 -1
- package/lib/commonjs/atoms/Spinner.js +81 -22
- package/lib/commonjs/atoms/Spinner.js.map +1 -1
- package/lib/commonjs/atoms/Text.js +56 -5
- package/lib/commonjs/atoms/Text.js.map +1 -1
- package/lib/commonjs/atoms/Transition.js +46 -43
- package/lib/commonjs/atoms/Transition.js.map +1 -1
- package/lib/commonjs/atoms/index.js +6 -0
- package/lib/commonjs/atoms/index.js.map +1 -1
- package/lib/commonjs/atoms/inputValidation.js +56 -0
- package/lib/commonjs/atoms/inputValidation.js.map +1 -0
- package/lib/commonjs/icons/Icon.js +4 -4
- package/lib/commonjs/icons/defaultIcons.js +576 -24
- package/lib/commonjs/icons/defaultIcons.js.map +1 -1
- package/lib/commonjs/icons/index.js +6 -0
- package/lib/commonjs/icons/index.js.map +1 -1
- package/lib/commonjs/molecules/AvatarHeader.js +47 -14
- package/lib/commonjs/molecules/AvatarHeader.js.map +1 -1
- package/lib/commonjs/molecules/FormActions.js +25 -9
- package/lib/commonjs/molecules/FormActions.js.map +1 -1
- package/lib/commonjs/molecules/InfoRow.js +30 -14
- package/lib/commonjs/molecules/InfoRow.js.map +1 -1
- package/lib/commonjs/molecules/OptionCard.js +37 -22
- package/lib/commonjs/molecules/OptionCard.js.map +1 -1
- package/lib/commonjs/molecules/SegmentedControl.js +103 -14
- package/lib/commonjs/molecules/SegmentedControl.js.map +1 -1
- package/lib/commonjs/molecules/Stepper.js +61 -16
- package/lib/commonjs/molecules/Stepper.js.map +1 -1
- package/lib/commonjs/molecules/Steps.js +105 -41
- package/lib/commonjs/molecules/Steps.js.map +1 -1
- package/lib/commonjs/molecules/SymmetricGrid.js +26 -18
- package/lib/commonjs/molecules/SymmetricGrid.js.map +1 -1
- package/lib/commonjs/organisms/Alert.js +49 -35
- package/lib/commonjs/organisms/Alert.js.map +1 -1
- package/lib/commonjs/organisms/AlertProvider.js +10 -10
- package/lib/commonjs/organisms/BottomSheet.js +137 -85
- package/lib/commonjs/organisms/BottomSheet.js.map +1 -1
- package/lib/commonjs/organisms/Chart.js +174 -154
- package/lib/commonjs/organisms/Chart.js.map +1 -1
- package/lib/commonjs/organisms/DateField.js +36 -20
- package/lib/commonjs/organisms/DateField.js.map +1 -1
- package/lib/commonjs/organisms/DatePicker.js +56 -33
- package/lib/commonjs/organisms/DatePicker.js.map +1 -1
- package/lib/commonjs/organisms/List.js +62 -34
- package/lib/commonjs/organisms/List.js.map +1 -1
- package/lib/commonjs/organisms/Modal.js +120 -82
- package/lib/commonjs/organisms/Modal.js.map +1 -1
- package/lib/commonjs/organisms/NavigationBar.js +63 -24
- package/lib/commonjs/organisms/NavigationBar.js.map +1 -1
- package/lib/commonjs/organisms/OptionWheel.js +64 -64
- package/lib/commonjs/organisms/OptionWheel.js.map +1 -1
- package/lib/commonjs/organisms/ReorderableList.js +48 -27
- package/lib/commonjs/organisms/ReorderableList.js.map +1 -1
- package/lib/commonjs/organisms/Screen.js +68 -35
- package/lib/commonjs/organisms/Screen.js.map +1 -1
- package/lib/commonjs/organisms/SearchList.js +56 -26
- package/lib/commonjs/organisms/SearchList.js.map +1 -1
- package/lib/commonjs/organisms/Select.js +45 -24
- package/lib/commonjs/organisms/Select.js.map +1 -1
- package/lib/commonjs/organisms/Slides.js +36 -23
- package/lib/commonjs/organisms/Slides.js.map +1 -1
- package/lib/commonjs/organisms/ThemeToggle.js +10 -9
- package/lib/commonjs/organisms/ThemeToggle.js.map +1 -1
- package/lib/commonjs/organisms/Timeline.js +73 -56
- package/lib/commonjs/organisms/Timeline.js.map +1 -1
- package/lib/commonjs/organisms/Toast.js +46 -15
- package/lib/commonjs/organisms/Toast.js.map +1 -1
- package/lib/commonjs/organisms/ToastProvider.js +14 -10
- package/lib/commonjs/organisms/ToastProvider.js.map +1 -1
- package/lib/commonjs/organisms/Wizard.js +40 -15
- package/lib/commonjs/organisms/Wizard.js.map +1 -1
- package/lib/commonjs/organisms/chart/frame.js +25 -25
- package/lib/commonjs/organisms/chart/frame.js.map +1 -1
- package/lib/commonjs/organisms/chart/marks.js +42 -42
- package/lib/commonjs/organisms/chart/math.js +84 -85
- package/lib/commonjs/organisms/chart/math.js.map +1 -1
- package/lib/commonjs/organisms/chart/palette.js +28 -28
- package/lib/commonjs/organisms/imperativeBridge.js +5 -5
- package/lib/commonjs/organisms/imperativeBridge.js.map +1 -1
- package/lib/commonjs/organisms/useSlides.js +53 -21
- package/lib/commonjs/organisms/useSlides.js.map +1 -1
- package/lib/commonjs/safe-area/SafeAreaUIProvider.js +9 -66
- package/lib/commonjs/safe-area/SafeAreaUIProvider.js.map +1 -1
- package/lib/commonjs/safe-area/index.js.map +1 -1
- package/lib/commonjs/theme/KeyboardAvoidance.js +206 -0
- package/lib/commonjs/theme/KeyboardAvoidance.js.map +1 -0
- package/lib/commonjs/theme/NativeOverlay.js +263 -0
- package/lib/commonjs/theme/NativeOverlay.js.map +1 -0
- package/lib/commonjs/theme/UIProvider.js +86 -33
- package/lib/commonjs/theme/UIProvider.js.map +1 -1
- package/lib/commonjs/theme/colors.js +17 -17
- package/lib/commonjs/theme/colors.js.map +1 -1
- package/lib/commonjs/theme/createStyles.js +19 -16
- package/lib/commonjs/theme/createStyles.js.map +1 -1
- package/lib/commonjs/theme/createTheme.js +6 -6
- package/lib/commonjs/theme/index.js +6 -0
- package/lib/commonjs/theme/index.js.map +1 -1
- package/lib/commonjs/theme/insets.js +1 -1
- package/lib/commonjs/theme/labels.js +29 -1
- package/lib/commonjs/theme/labels.js.map +1 -1
- package/lib/commonjs/theme/palettes.js +25 -23
- package/lib/commonjs/theme/palettes.js.map +1 -1
- package/lib/commonjs/theme/tokens.js +28 -14
- package/lib/commonjs/theme/tokens.js.map +1 -1
- package/lib/commonjs/theme/useKeyboardField.js +36 -0
- package/lib/commonjs/theme/useKeyboardField.js.map +1 -0
- package/lib/commonjs/theme/useReduceMotion.js +31 -0
- package/lib/commonjs/theme/useReduceMotion.js.map +1 -0
- package/lib/module/atoms/Avatar.js +79 -8
- package/lib/module/atoms/Avatar.js.map +1 -1
- package/lib/module/atoms/Badge.js +17 -8
- package/lib/module/atoms/Badge.js.map +1 -1
- package/lib/module/atoms/Button.js +110 -41
- package/lib/module/atoms/Button.js.map +1 -1
- package/lib/module/atoms/Card.js +24 -2
- package/lib/module/atoms/Card.js.map +1 -1
- package/lib/module/atoms/Checkbox.js +42 -11
- package/lib/module/atoms/Checkbox.js.map +1 -1
- package/lib/module/atoms/Divider.js +31 -6
- package/lib/module/atoms/Divider.js.map +1 -1
- package/lib/module/atoms/EmptyState.js +58 -20
- package/lib/module/atoms/EmptyState.js.map +1 -1
- package/lib/module/atoms/Fab.js +33 -13
- package/lib/module/atoms/Fab.js.map +1 -1
- package/lib/module/atoms/Gradient.js +103 -37
- package/lib/module/atoms/Gradient.js.map +1 -1
- package/lib/module/atoms/IconButton.js +25 -4
- package/lib/module/atoms/IconButton.js.map +1 -1
- package/lib/module/atoms/Image.js +61 -25
- package/lib/module/atoms/Image.js.map +1 -1
- package/lib/module/atoms/Input.js +108 -20
- package/lib/module/atoms/Input.js.map +1 -1
- package/lib/module/atoms/KeyValueRow.js +37 -9
- package/lib/module/atoms/KeyValueRow.js.map +1 -1
- package/lib/module/atoms/PressableScale.js +25 -5
- package/lib/module/atoms/PressableScale.js.map +1 -1
- package/lib/module/atoms/ShinyText.js +29 -29
- package/lib/module/atoms/Skeleton.js +30 -13
- package/lib/module/atoms/Skeleton.js.map +1 -1
- package/lib/module/atoms/Spinner.js +82 -23
- package/lib/module/atoms/Spinner.js.map +1 -1
- package/lib/module/atoms/Text.js +56 -5
- package/lib/module/atoms/Text.js.map +1 -1
- package/lib/module/atoms/Transition.js +41 -42
- package/lib/module/atoms/Transition.js.map +1 -1
- package/lib/module/atoms/index.js +1 -1
- package/lib/module/atoms/index.js.map +1 -1
- package/lib/module/atoms/inputValidation.js +52 -0
- package/lib/module/atoms/inputValidation.js.map +1 -0
- package/lib/module/icons/Icon.js +4 -4
- package/lib/module/icons/defaultIcons.js +574 -24
- package/lib/module/icons/defaultIcons.js.map +1 -1
- package/lib/module/icons/index.js +1 -1
- package/lib/module/icons/index.js.map +1 -1
- package/lib/module/molecules/AvatarHeader.js +47 -14
- package/lib/module/molecules/AvatarHeader.js.map +1 -1
- package/lib/module/molecules/FormActions.js +25 -9
- package/lib/module/molecules/FormActions.js.map +1 -1
- package/lib/module/molecules/InfoRow.js +30 -14
- package/lib/module/molecules/InfoRow.js.map +1 -1
- package/lib/module/molecules/OptionCard.js +37 -22
- package/lib/module/molecules/OptionCard.js.map +1 -1
- package/lib/module/molecules/SegmentedControl.js +107 -18
- package/lib/module/molecules/SegmentedControl.js.map +1 -1
- package/lib/module/molecules/Stepper.js +63 -18
- package/lib/module/molecules/Stepper.js.map +1 -1
- package/lib/module/molecules/Steps.js +107 -43
- package/lib/module/molecules/Steps.js.map +1 -1
- package/lib/module/molecules/SymmetricGrid.js +26 -18
- package/lib/module/molecules/SymmetricGrid.js.map +1 -1
- package/lib/module/organisms/Alert.js +51 -37
- package/lib/module/organisms/Alert.js.map +1 -1
- package/lib/module/organisms/AlertProvider.js +10 -10
- package/lib/module/organisms/BottomSheet.js +142 -88
- package/lib/module/organisms/BottomSheet.js.map +1 -1
- package/lib/module/organisms/Chart.js +176 -156
- package/lib/module/organisms/Chart.js.map +1 -1
- package/lib/module/organisms/DateField.js +36 -20
- package/lib/module/organisms/DateField.js.map +1 -1
- package/lib/module/organisms/DatePicker.js +56 -33
- package/lib/module/organisms/DatePicker.js.map +1 -1
- package/lib/module/organisms/List.js +62 -34
- package/lib/module/organisms/List.js.map +1 -1
- package/lib/module/organisms/Modal.js +122 -84
- package/lib/module/organisms/Modal.js.map +1 -1
- package/lib/module/organisms/NavigationBar.js +64 -25
- package/lib/module/organisms/NavigationBar.js.map +1 -1
- package/lib/module/organisms/OptionWheel.js +64 -64
- package/lib/module/organisms/OptionWheel.js.map +1 -1
- package/lib/module/organisms/ReorderableList.js +48 -27
- package/lib/module/organisms/ReorderableList.js.map +1 -1
- package/lib/module/organisms/Screen.js +70 -37
- package/lib/module/organisms/Screen.js.map +1 -1
- package/lib/module/organisms/SearchList.js +56 -26
- package/lib/module/organisms/SearchList.js.map +1 -1
- package/lib/module/organisms/Select.js +46 -25
- package/lib/module/organisms/Select.js.map +1 -1
- package/lib/module/organisms/Slides.js +37 -24
- package/lib/module/organisms/Slides.js.map +1 -1
- package/lib/module/organisms/ThemeToggle.js +11 -10
- package/lib/module/organisms/ThemeToggle.js.map +1 -1
- package/lib/module/organisms/Timeline.js +73 -56
- package/lib/module/organisms/Timeline.js.map +1 -1
- package/lib/module/organisms/Toast.js +47 -16
- package/lib/module/organisms/Toast.js.map +1 -1
- package/lib/module/organisms/ToastProvider.js +15 -11
- package/lib/module/organisms/ToastProvider.js.map +1 -1
- package/lib/module/organisms/Wizard.js +41 -16
- package/lib/module/organisms/Wizard.js.map +1 -1
- package/lib/module/organisms/chart/frame.js +25 -25
- package/lib/module/organisms/chart/frame.js.map +1 -1
- package/lib/module/organisms/chart/marks.js +42 -42
- package/lib/module/organisms/chart/math.js +84 -85
- package/lib/module/organisms/chart/math.js.map +1 -1
- package/lib/module/organisms/chart/palette.js +28 -28
- package/lib/module/organisms/imperativeBridge.js +5 -5
- package/lib/module/organisms/imperativeBridge.js.map +1 -1
- package/lib/module/organisms/useSlides.js +53 -21
- package/lib/module/organisms/useSlides.js.map +1 -1
- package/lib/module/safe-area/SafeAreaUIProvider.js +10 -65
- package/lib/module/safe-area/SafeAreaUIProvider.js.map +1 -1
- package/lib/module/safe-area/index.js +1 -0
- package/lib/module/safe-area/index.js.map +1 -1
- package/lib/module/theme/KeyboardAvoidance.js +198 -0
- package/lib/module/theme/KeyboardAvoidance.js.map +1 -0
- package/lib/module/theme/NativeOverlay.js +257 -0
- package/lib/module/theme/NativeOverlay.js.map +1 -0
- package/lib/module/theme/UIProvider.js +88 -35
- package/lib/module/theme/UIProvider.js.map +1 -1
- package/lib/module/theme/colors.js +17 -17
- package/lib/module/theme/colors.js.map +1 -1
- package/lib/module/theme/createStyles.js +20 -16
- package/lib/module/theme/createStyles.js.map +1 -1
- package/lib/module/theme/createTheme.js +6 -6
- package/lib/module/theme/index.js +1 -1
- package/lib/module/theme/index.js.map +1 -1
- package/lib/module/theme/insets.js +1 -1
- package/lib/module/theme/labels.js +29 -1
- package/lib/module/theme/labels.js.map +1 -1
- package/lib/module/theme/palettes.js +25 -23
- package/lib/module/theme/palettes.js.map +1 -1
- package/lib/module/theme/tokens.js +27 -13
- package/lib/module/theme/tokens.js.map +1 -1
- package/lib/module/theme/useKeyboardField.js +33 -0
- package/lib/module/theme/useKeyboardField.js.map +1 -0
- package/lib/module/theme/useReduceMotion.js +28 -0
- package/lib/module/theme/useReduceMotion.js.map +1 -0
- package/lib/typescript/atoms/Avatar.d.ts +35 -5
- package/lib/typescript/atoms/Avatar.d.ts.map +1 -1
- package/lib/typescript/atoms/Badge.d.ts +14 -3
- package/lib/typescript/atoms/Badge.d.ts.map +1 -1
- package/lib/typescript/atoms/Button.d.ts +34 -3
- package/lib/typescript/atoms/Button.d.ts.map +1 -1
- package/lib/typescript/atoms/Card.d.ts +13 -2
- package/lib/typescript/atoms/Card.d.ts.map +1 -1
- package/lib/typescript/atoms/Checkbox.d.ts +26 -1
- package/lib/typescript/atoms/Checkbox.d.ts.map +1 -1
- package/lib/typescript/atoms/Divider.d.ts +18 -1
- package/lib/typescript/atoms/Divider.d.ts.map +1 -1
- package/lib/typescript/atoms/EmptyState.d.ts +30 -3
- package/lib/typescript/atoms/EmptyState.d.ts.map +1 -1
- package/lib/typescript/atoms/Fab.d.ts +24 -4
- package/lib/typescript/atoms/Fab.d.ts.map +1 -1
- package/lib/typescript/atoms/Gradient.d.ts +21 -15
- package/lib/typescript/atoms/Gradient.d.ts.map +1 -1
- package/lib/typescript/atoms/IconButton.d.ts +18 -4
- package/lib/typescript/atoms/IconButton.d.ts.map +1 -1
- package/lib/typescript/atoms/Image.d.ts +39 -17
- package/lib/typescript/atoms/Image.d.ts.map +1 -1
- package/lib/typescript/atoms/Input.d.ts +57 -7
- package/lib/typescript/atoms/Input.d.ts.map +1 -1
- package/lib/typescript/atoms/KeyValueRow.d.ts +16 -4
- package/lib/typescript/atoms/KeyValueRow.d.ts.map +1 -1
- package/lib/typescript/atoms/PressableScale.d.ts +12 -5
- package/lib/typescript/atoms/PressableScale.d.ts.map +1 -1
- package/lib/typescript/atoms/ShinyText.d.ts +17 -17
- package/lib/typescript/atoms/ShinyText.d.ts.map +1 -1
- package/lib/typescript/atoms/Skeleton.d.ts +12 -7
- package/lib/typescript/atoms/Skeleton.d.ts.map +1 -1
- package/lib/typescript/atoms/Spinner.d.ts +29 -1
- package/lib/typescript/atoms/Spinner.d.ts.map +1 -1
- package/lib/typescript/atoms/Text.d.ts +46 -0
- package/lib/typescript/atoms/Text.d.ts.map +1 -1
- package/lib/typescript/atoms/Transition.d.ts +19 -15
- package/lib/typescript/atoms/Transition.d.ts.map +1 -1
- package/lib/typescript/atoms/index.d.ts +3 -3
- package/lib/typescript/atoms/index.d.ts.map +1 -1
- package/lib/typescript/atoms/inputValidation.d.ts +29 -0
- package/lib/typescript/atoms/inputValidation.d.ts.map +1 -0
- package/lib/typescript/icons/Icon.d.ts +4 -4
- package/lib/typescript/icons/defaultIcons.d.ts +19 -2
- package/lib/typescript/icons/defaultIcons.d.ts.map +1 -1
- package/lib/typescript/icons/index.d.ts +2 -2
- package/lib/typescript/icons/index.d.ts.map +1 -1
- package/lib/typescript/icons/types.d.ts +13 -3
- package/lib/typescript/icons/types.d.ts.map +1 -1
- package/lib/typescript/molecules/AvatarHeader.d.ts +23 -4
- package/lib/typescript/molecules/AvatarHeader.d.ts.map +1 -1
- package/lib/typescript/molecules/FormActions.d.ts +21 -4
- package/lib/typescript/molecules/FormActions.d.ts.map +1 -1
- package/lib/typescript/molecules/InfoRow.d.ts +17 -3
- package/lib/typescript/molecules/InfoRow.d.ts.map +1 -1
- package/lib/typescript/molecules/OptionCard.d.ts +20 -5
- package/lib/typescript/molecules/OptionCard.d.ts.map +1 -1
- package/lib/typescript/molecules/SegmentedControl.d.ts +18 -2
- package/lib/typescript/molecules/SegmentedControl.d.ts.map +1 -1
- package/lib/typescript/molecules/Stepper.d.ts +23 -7
- package/lib/typescript/molecules/Stepper.d.ts.map +1 -1
- package/lib/typescript/molecules/Steps.d.ts +18 -4
- package/lib/typescript/molecules/Steps.d.ts.map +1 -1
- package/lib/typescript/molecules/SymmetricGrid.d.ts +15 -5
- package/lib/typescript/molecules/SymmetricGrid.d.ts.map +1 -1
- package/lib/typescript/organisms/Alert.d.ts +28 -2
- package/lib/typescript/organisms/Alert.d.ts.map +1 -1
- package/lib/typescript/organisms/AlertProvider.d.ts +10 -10
- package/lib/typescript/organisms/AlertProvider.d.ts.map +1 -1
- package/lib/typescript/organisms/BottomSheet.d.ts +20 -5
- package/lib/typescript/organisms/BottomSheet.d.ts.map +1 -1
- package/lib/typescript/organisms/Chart.d.ts +86 -75
- package/lib/typescript/organisms/Chart.d.ts.map +1 -1
- package/lib/typescript/organisms/DateField.d.ts +17 -3
- package/lib/typescript/organisms/DateField.d.ts.map +1 -1
- package/lib/typescript/organisms/DatePicker.d.ts +7 -11
- package/lib/typescript/organisms/DatePicker.d.ts.map +1 -1
- package/lib/typescript/organisms/List.d.ts +30 -3
- package/lib/typescript/organisms/List.d.ts.map +1 -1
- package/lib/typescript/organisms/Modal.d.ts +30 -3
- package/lib/typescript/organisms/Modal.d.ts.map +1 -1
- package/lib/typescript/organisms/NavigationBar.d.ts +26 -7
- package/lib/typescript/organisms/NavigationBar.d.ts.map +1 -1
- package/lib/typescript/organisms/OptionWheel.d.ts +20 -16
- package/lib/typescript/organisms/OptionWheel.d.ts.map +1 -1
- package/lib/typescript/organisms/ReorderableList.d.ts +20 -11
- package/lib/typescript/organisms/ReorderableList.d.ts.map +1 -1
- package/lib/typescript/organisms/Screen.d.ts +27 -8
- package/lib/typescript/organisms/Screen.d.ts.map +1 -1
- package/lib/typescript/organisms/SearchList.d.ts +46 -3
- package/lib/typescript/organisms/SearchList.d.ts.map +1 -1
- package/lib/typescript/organisms/Select.d.ts +26 -6
- package/lib/typescript/organisms/Select.d.ts.map +1 -1
- package/lib/typescript/organisms/Slides.d.ts +44 -26
- package/lib/typescript/organisms/Slides.d.ts.map +1 -1
- package/lib/typescript/organisms/ThemeToggle.d.ts +6 -2
- package/lib/typescript/organisms/ThemeToggle.d.ts.map +1 -1
- package/lib/typescript/organisms/Timeline.d.ts +26 -9
- package/lib/typescript/organisms/Timeline.d.ts.map +1 -1
- package/lib/typescript/organisms/Toast.d.ts +19 -4
- package/lib/typescript/organisms/Toast.d.ts.map +1 -1
- package/lib/typescript/organisms/ToastProvider.d.ts +8 -8
- package/lib/typescript/organisms/ToastProvider.d.ts.map +1 -1
- package/lib/typescript/organisms/Wizard.d.ts +24 -6
- package/lib/typescript/organisms/Wizard.d.ts.map +1 -1
- package/lib/typescript/organisms/chart/frame.d.ts +21 -21
- package/lib/typescript/organisms/chart/frame.d.ts.map +1 -1
- package/lib/typescript/organisms/chart/marks.d.ts +28 -28
- package/lib/typescript/organisms/chart/marks.d.ts.map +1 -1
- package/lib/typescript/organisms/chart/math.d.ts +69 -70
- package/lib/typescript/organisms/chart/math.d.ts.map +1 -1
- package/lib/typescript/organisms/chart/palette.d.ts +2 -2
- package/lib/typescript/organisms/chart/palette.d.ts.map +1 -1
- package/lib/typescript/organisms/imperativeBridge.d.ts +4 -4
- package/lib/typescript/organisms/useSlides.d.ts +8 -16
- package/lib/typescript/organisms/useSlides.d.ts.map +1 -1
- package/lib/typescript/safe-area/SafeAreaUIProvider.d.ts +9 -7
- package/lib/typescript/safe-area/SafeAreaUIProvider.d.ts.map +1 -1
- package/lib/typescript/safe-area/index.d.ts.map +1 -1
- package/lib/typescript/theme/KeyboardAvoidance.d.ts +62 -0
- package/lib/typescript/theme/KeyboardAvoidance.d.ts.map +1 -0
- package/lib/typescript/theme/NativeOverlay.d.ts +43 -0
- package/lib/typescript/theme/NativeOverlay.d.ts.map +1 -0
- package/lib/typescript/theme/UIProvider.d.ts +38 -20
- package/lib/typescript/theme/UIProvider.d.ts.map +1 -1
- package/lib/typescript/theme/colors.d.ts +13 -13
- package/lib/typescript/theme/colors.d.ts.map +1 -1
- package/lib/typescript/theme/createStyles.d.ts +20 -14
- package/lib/typescript/theme/createStyles.d.ts.map +1 -1
- package/lib/typescript/theme/createTheme.d.ts +5 -5
- package/lib/typescript/theme/index.d.ts +1 -1
- package/lib/typescript/theme/index.d.ts.map +1 -1
- package/lib/typescript/theme/insets.d.ts +1 -1
- package/lib/typescript/theme/insets.d.ts.map +1 -1
- package/lib/typescript/theme/labels.d.ts +57 -2
- package/lib/typescript/theme/labels.d.ts.map +1 -1
- package/lib/typescript/theme/palettes.d.ts +25 -19
- package/lib/typescript/theme/palettes.d.ts.map +1 -1
- package/lib/typescript/theme/tokens.d.ts +15 -8
- package/lib/typescript/theme/tokens.d.ts.map +1 -1
- package/lib/typescript/theme/types.d.ts +7 -7
- package/lib/typescript/theme/types.d.ts.map +1 -1
- package/lib/typescript/theme/useKeyboardField.d.ts +17 -0
- package/lib/typescript/theme/useKeyboardField.d.ts.map +1 -0
- package/lib/typescript/theme/useReduceMotion.d.ts +7 -0
- package/lib/typescript/theme/useReduceMotion.d.ts.map +1 -0
- package/llms.txt +4 -4
- package/package.json +15 -14
- package/registry/alert-provider.json +4 -3
- package/registry/alert.json +3 -2
- package/registry/avatar-header.json +1 -1
- package/registry/avatar.json +3 -2
- package/registry/badge.json +1 -1
- package/registry/bottom-sheet.json +1 -1
- package/registry/button.json +3 -2
- package/registry/card.json +1 -1
- package/registry/chart.json +5 -5
- package/registry/checkbox.json +3 -2
- package/registry/core.json +31 -15
- package/registry/date-field.json +1 -1
- package/registry/date-picker.json +3 -2
- package/registry/divider.json +1 -1
- package/registry/empty-state.json +4 -2
- package/registry/fab.json +3 -2
- package/registry/form-actions.json +3 -2
- package/registry/gradient.json +1 -1
- package/registry/icon-button.json +3 -2
- package/registry/image.json +1 -1
- package/registry/index.json +79 -61
- package/registry/info-row.json +1 -1
- package/registry/input.json +5 -1
- package/registry/key-value-row.json +1 -1
- package/registry/list.json +3 -1
- package/registry/manifest.json +3 -1
- package/registry/modal.json +1 -1
- package/registry/navigation-bar.json +1 -1
- package/registry/option-card.json +3 -2
- package/registry/option-wheel.json +1 -1
- package/registry/pressable-scale.json +3 -2
- package/registry/reorderable-list.json +1 -1
- package/registry/screen.json +1 -1
- package/registry/search-list.json +7 -1
- package/registry/segmented-control.json +1 -1
- package/registry/select.json +1 -1
- package/registry/shiny-text.json +1 -1
- package/registry/skeleton.json +3 -2
- package/registry/slides.json +2 -2
- package/registry/spinner.json +1 -1
- package/registry/stepper.json +1 -1
- package/registry/steps.json +1 -1
- package/registry/symmetric-grid.json +1 -1
- package/registry/theme-toggle.json +1 -1
- package/registry/timeline.json +1 -1
- package/registry/title.json +1 -1
- package/registry/toast-provider.json +2 -2
- package/registry/toast.json +1 -1
- package/registry/transition.json +1 -1
- package/registry/wizard.json +1 -1
- package/src/atoms/Avatar.tsx +117 -26
- package/src/atoms/Badge.tsx +20 -9
- package/src/atoms/Button.tsx +102 -30
- package/src/atoms/Card.tsx +23 -3
- package/src/atoms/Checkbox.tsx +49 -12
- package/src/atoms/Divider.tsx +34 -4
- package/src/atoms/EmptyState.tsx +63 -16
- package/src/atoms/Fab.tsx +56 -9
- package/src/atoms/Gradient.tsx +92 -41
- package/src/atoms/IconButton.tsx +27 -4
- package/src/atoms/Image.tsx +74 -28
- package/src/atoms/Input.tsx +129 -19
- package/src/atoms/KeyValueRow.tsx +72 -28
- package/src/atoms/PressableScale.tsx +31 -7
- package/src/atoms/ShinyText.tsx +31 -31
- package/src/atoms/Skeleton.tsx +37 -17
- package/src/atoms/Spinner.tsx +87 -24
- package/src/atoms/Text.tsx +66 -6
- package/src/atoms/Transition.tsx +40 -44
- package/src/atoms/index.ts +3 -3
- package/src/atoms/inputValidation.ts +59 -0
- package/src/icons/Icon.tsx +4 -4
- package/src/icons/defaultIcons.tsx +445 -22
- package/src/icons/index.ts +2 -2
- package/src/icons/types.ts +26 -4
- package/src/molecules/AvatarHeader.tsx +88 -34
- package/src/molecules/FormActions.tsx +36 -6
- package/src/molecules/InfoRow.tsx +39 -12
- package/src/molecules/OptionCard.tsx +55 -20
- package/src/molecules/SegmentedControl.tsx +135 -15
- package/src/molecules/Stepper.tsx +73 -19
- package/src/molecules/Steps.tsx +121 -39
- package/src/molecules/SymmetricGrid.tsx +28 -12
- package/src/organisms/Alert.tsx +97 -26
- package/src/organisms/AlertProvider.tsx +13 -13
- package/src/organisms/BottomSheet.tsx +115 -43
- package/src/organisms/Chart.tsx +193 -164
- package/src/organisms/DateField.tsx +40 -15
- package/src/organisms/DatePicker.tsx +53 -32
- package/src/organisms/List.tsx +64 -15
- package/src/organisms/Modal.tsx +122 -63
- package/src/organisms/NavigationBar.tsx +73 -23
- package/src/organisms/OptionWheel.tsx +70 -66
- package/src/organisms/ReorderableList.tsx +49 -27
- package/src/organisms/Screen.tsx +79 -42
- package/src/organisms/SearchList.tsx +84 -20
- package/src/organisms/Select.tsx +63 -29
- package/src/organisms/Slides.tsx +63 -44
- package/src/organisms/ThemeToggle.tsx +15 -6
- package/src/organisms/Timeline.tsx +79 -62
- package/src/organisms/Toast.tsx +50 -15
- package/src/organisms/ToastProvider.tsx +17 -13
- package/src/organisms/Wizard.tsx +58 -21
- package/src/organisms/chart/frame.tsx +35 -35
- package/src/organisms/chart/marks.tsx +53 -53
- package/src/organisms/chart/math.ts +93 -94
- package/src/organisms/chart/palette.ts +28 -28
- package/src/organisms/imperativeBridge.ts +5 -5
- package/src/organisms/useSlides.ts +66 -31
- package/src/safe-area/SafeAreaUIProvider.tsx +9 -70
- package/src/safe-area/index.ts +1 -0
- package/src/theme/KeyboardAvoidance.tsx +216 -0
- package/src/theme/NativeOverlay.tsx +269 -0
- package/src/theme/UIProvider.tsx +109 -46
- package/src/theme/colors.ts +21 -21
- package/src/theme/createStyles.ts +23 -19
- package/src/theme/createTheme.ts +6 -6
- package/src/theme/index.ts +1 -1
- package/src/theme/insets.ts +1 -1
- package/src/theme/labels.ts +85 -2
- package/src/theme/palettes.ts +33 -25
- package/src/theme/tokens.ts +27 -13
- package/src/theme/types.ts +7 -7
- package/src/theme/useKeyboardField.ts +33 -0
- package/src/theme/useReduceMotion.ts +27 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"UIProvider.d.ts","sourceRoot":"","sources":["../../../src/theme/UIProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"UIProvider.d.ts","sourceRoot":"","sources":["../../../src/theme/UIProvider.tsx"],"names":[],"mappings":"AAAA,OAAO,KAA+E,MAAM,OAAO,CAAC;AACpG,OAAO,EAAE,UAAU,EAAkC,MAAM,cAAc,CAAC;AAG1E,OAAO,EAAiB,KAAK,MAAM,EAAE,MAAM,UAAU,CAAC;AACtD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,KAAK,EAAE,KAAK,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAEhD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAGnD,MAAM,MAAM,SAAS,GAAG,QAAQ,GAAG,OAAO,GAAG,MAAM,CAAC;AAEpD;;;;;;GAMG;AACH,MAAM,WAAW,0BAA0B;IACzC,QAAQ,EAAE,CAAC,MAAM,EAAE,UAAU,KAAK,KAAK,CAAC,SAAS,CAAC;CACnD;AACD,MAAM,MAAM,8BAA8B,GAAG,KAAK,CAAC,aAAa,CAAC,0BAA0B,CAAC,CAAC;AA+C7F,MAAM,WAAW,eAAe;IAC9B,QAAQ,EAAE,KAAK,CAAC,SAAS,CAAC;IAC1B,8FAA8F;IAC9F,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,4EAA4E;IAC5E,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,wGAAwG;IACxG,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,SAAS,KAAK,IAAI,CAAC;IACzC,+DAA+D;IAC/D,KAAK,CAAC,EAAE,YAAY,CAAC;IACrB;;;OAGG;IACH,MAAM,CAAC,EAAE,UAAU,CAAC;IACpB,MAAM,CAAC,EAAE,OAAO,CAAC,MAAM,CAAC,CAAC;IACzB;;;;;OAKG;IACH,gBAAgB,CAAC,EAAE,OAAO,CAAC;IAC3B;;;;;OAKG;IACH,qBAAqB,CAAC,EAAE,OAAO,CAAC;IAChC;;;;;;OAMG;IACH,iBAAiB,CAAC,EAAE,OAAO,CAAC;CAC7B;AAMD;;;;;;;;GAQG;AACH,wBAAgB,UAAU,CAAC,EAAE,qBAA4B,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,qBAOrF;AAkFD,wBAAgB,QAAQ,IAAI,KAAK,CAEhC;AAED,wBAAgB,SAAS,IAAI,KAAK,CAAC,QAAQ,CAAC,CAE3C;AAED,wBAAgB,YAAY;;oBAjKV,SAAS,KAAK,IAAI;EAoKnC;AAED,wBAAgB,QAAQ,IAAI,YAAY,CAEvC;AAED,wBAAgB,SAAS,IAAI,UAAU,CAEtC;AAED,wBAAgB,SAAS,IAAI,MAAM,CAElC;AAED,wBAAgB,mBAAmB,IAAI,OAAO,CAE7C;AAED,uGAAuG;AACvG,wBAAgB,wBAAwB,IAAI,8BAA8B,CAEzE;AAED,kFAAkF;AAClF,eAAO,MAAM,WAAW;;CAAiB,CAAC"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
2
|
+
* Dependency-free color utilities, used to derive a family of roles
|
|
3
|
+
* (fill / on-top / soft / readable) from a single brand hex.
|
|
4
4
|
*/
|
|
5
|
-
/**
|
|
5
|
+
/** Minimum AA contrast for normal text. */
|
|
6
6
|
export declare const AA_CONTRAST = 4.5;
|
|
7
7
|
export interface Rgb {
|
|
8
8
|
r: number;
|
|
@@ -14,15 +14,15 @@ export interface Hsl {
|
|
|
14
14
|
s: number;
|
|
15
15
|
l: number;
|
|
16
16
|
}
|
|
17
|
-
/** Roles
|
|
17
|
+
/** Roles a theme accent needs, in a given scheme. */
|
|
18
18
|
export interface AccentRoles {
|
|
19
|
-
/**
|
|
19
|
+
/** Solid fill: button background, current step's circle. */
|
|
20
20
|
base: string;
|
|
21
|
-
/**
|
|
21
|
+
/** Text/icon placed on top of the fill. */
|
|
22
22
|
on: string;
|
|
23
|
-
/**
|
|
23
|
+
/** Subtle background: badges, active indicator pill. */
|
|
24
24
|
soft: string;
|
|
25
|
-
/**
|
|
25
|
+
/** The accent legible on `surface`: labels, links. */
|
|
26
26
|
text: string;
|
|
27
27
|
}
|
|
28
28
|
export declare function hexToRgb(hex: string): Rgb;
|
|
@@ -31,14 +31,14 @@ export declare function rgbToHsl({ r, g, b }: Rgb): Hsl;
|
|
|
31
31
|
export declare function hslToRgb({ h, s, l }: Hsl): Rgb;
|
|
32
32
|
export declare function toHsl(hex: string): Hsl;
|
|
33
33
|
export declare function toHex(hsl: Hsl): string;
|
|
34
|
-
/**
|
|
34
|
+
/** WCAG relative luminance of a hex. */
|
|
35
35
|
export declare function luminance(hex: string): number;
|
|
36
|
-
/**
|
|
36
|
+
/** WCAG contrast ratio between two hexes: 1 (equal) to 21 (white on black). */
|
|
37
37
|
export declare function contrast(a: string, b: string): number;
|
|
38
38
|
/**
|
|
39
|
-
*
|
|
40
|
-
* `surface`
|
|
41
|
-
*
|
|
39
|
+
* Derives an accent's four roles from a hex, for one scheme.
|
|
40
|
+
* `surface` is the background the `text` role has to be read on, so each
|
|
41
|
+
* scheme passes its own.
|
|
42
42
|
*/
|
|
43
43
|
export declare function deriveAccent(hex: string, scheme: 'light' | 'dark', surface: string): AccentRoles;
|
|
44
44
|
//# sourceMappingURL=colors.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"colors.d.ts","sourceRoot":"","sources":["../../../src/theme/colors.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,
|
|
1
|
+
{"version":3,"file":"colors.d.ts","sourceRoot":"","sources":["../../../src/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IG;AACH,wBAAgB,YAAY,CAAC,GAAG,EAAE,MAAM,EAAE,MAAM,EAAE,OAAO,GAAG,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,WAAW,CAsBhG"}
|
|
@@ -1,21 +1,27 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { type ImageStyle, type TextStyle, type ViewStyle } from 'react-native';
|
|
2
2
|
import type { Theme } from './types';
|
|
3
3
|
/**
|
|
4
4
|
* createStyles(factory)
|
|
5
|
-
*
|
|
6
|
-
* theme (WeakMap<Theme, Styles>),
|
|
7
|
-
*
|
|
8
|
-
*
|
|
9
|
-
*
|
|
5
|
+
* Returns a useStyles() hook that memoizes the resulting StyleSheet per
|
|
6
|
+
* theme (WeakMap<Theme, Styles>), not per component instance. All rows of a
|
|
7
|
+
* list share the same styles object: without this, N rows ⇒ N
|
|
8
|
+
* StyleSheet.create() per render, which is what every component of the
|
|
9
|
+
* original app did with `useMemo(() => createStyles(colors), [colors])`.
|
|
10
10
|
*
|
|
11
|
-
*
|
|
12
|
-
*
|
|
13
|
-
*
|
|
11
|
+
* The cache lives in the factory's closure (one WeakMap per createStyles
|
|
12
|
+
* call, i.e. one per component), so themes from different <UIProvider>s in
|
|
13
|
+
* the same tree don't collide with each other.
|
|
14
14
|
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
15
|
+
* The `factory` type follows RN's pattern for typed StyleSheets
|
|
16
|
+
* (`T extends NamedStyles<T> | NamedStyles<any>`): it is what gives TS the
|
|
17
|
+
* context to infer literals ('row', 'center', ...) instead of widening them
|
|
18
|
+
* to `string` inside the returned object. `NamedStyles` is declared here:
|
|
19
|
+
* react-native 0.88's generated types (Expo SDK 58) no longer export
|
|
20
|
+
* `StyleSheet.NamedStyles`.
|
|
19
21
|
*/
|
|
20
|
-
|
|
22
|
+
type NamedStyles<T> = {
|
|
23
|
+
[P in keyof T]: ViewStyle | TextStyle | ImageStyle;
|
|
24
|
+
};
|
|
25
|
+
export declare function createStyles<T extends NamedStyles<T> | NamedStyles<any>>(factory: (theme: Theme) => T | NamedStyles<T>): () => T;
|
|
26
|
+
export {};
|
|
21
27
|
//# sourceMappingURL=createStyles.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createStyles.d.ts","sourceRoot":"","sources":["../../../src/theme/createStyles.ts"],"names":[],"mappings":"AAAA,OAAO,
|
|
1
|
+
{"version":3,"file":"createStyles.d.ts","sourceRoot":"","sources":["../../../src/theme/createStyles.ts"],"names":[],"mappings":"AAAA,OAAO,EAAc,KAAK,UAAU,EAAE,KAAK,SAAS,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAE3F,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AAErC;;;;;;;;;;;;;;;;;;GAkBG;AACH,KAAK,WAAW,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,SAAS,GAAG,SAAS,GAAG,UAAU;CAAE,CAAC;AAE7E,wBAAgB,YAAY,CAAC,CAAC,SAAS,WAAW,CAAC,CAAC,CAAC,GAAG,WAAW,CAAC,GAAG,CAAC,EACtE,OAAO,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,CAAC,GAAG,WAAW,CAAC,CAAC,CAAC,GAC5C,MAAM,CAAC,CAgBT"}
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import type { ThemeOverrides, ThemePair } from './types';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
5
|
-
*
|
|
3
|
+
* Builds the light/dark theme pair consumed by <UIProvider theme={...}>.
|
|
4
|
+
* Never mutates the defaults: each call produces new objects, safe to share
|
|
5
|
+
* between different providers (tests, multi-brand in the same tree).
|
|
6
6
|
*
|
|
7
|
-
* `brand`
|
|
8
|
-
*
|
|
7
|
+
* `brand` is applied before `colors`, so a hand-written role always wins
|
|
8
|
+
* over the derived one.
|
|
9
9
|
*/
|
|
10
10
|
export declare function createTheme(overrides?: ThemeOverrides): ThemePair;
|
|
11
11
|
export declare const defaultTheme: ThemePair;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { spacing, radius, fontSize, fontWeight, lineHeight, duration, shadow, tokens } from './tokens';
|
|
1
|
+
export { spacing, radius, fontSize, fontWeight, lineHeight, letterSpacing, duration, shadow, tokens } from './tokens';
|
|
2
2
|
export type { Tokens } from './tokens';
|
|
3
3
|
export { lightPalette, darkPalette } from './palettes';
|
|
4
4
|
export type { ThemeColors } from './palettes';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/theme/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,UAAU,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/theme/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,UAAU,EAAE,aAAa,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACtH,YAAY,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AACvD,YAAY,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAC9C,OAAO,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,eAAe,CAAC;AAC1D,YAAY,EAAE,KAAK,EAAE,SAAS,EAAE,cAAc,EAAE,WAAW,EAAE,WAAW,EAAE,MAAM,SAAS,CAAC;AAC1F,OAAO,EAAE,YAAY,EAAE,QAAQ,EAAE,SAAS,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC1E,YAAY,EAAE,WAAW,EAAE,MAAM,UAAU,CAAC;AAC5C,OAAO,EAAE,aAAa,EAAE,MAAM,UAAU,CAAC;AACzC,YAAY,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AACtC,YAAY,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAC3C,OAAO,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAC9C,OAAO,EACL,UAAU,EACV,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,QAAQ,EACR,SAAS,EACT,SAAS,EACT,mBAAmB,GACpB,MAAM,cAAc,CAAC;AACtB,YAAY,EAAE,eAAe,EAAE,SAAS,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/** Structurally identical to react-native-safe-area-context's EdgeInsets, without depending on the package. */
|
|
2
2
|
export interface EdgeInsets {
|
|
3
3
|
top: number;
|
|
4
4
|
right: number;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"insets.d.ts","sourceRoot":"","sources":["../../../src/theme/insets.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"insets.d.ts","sourceRoot":"","sources":["../../../src/theme/insets.ts"],"names":[],"mappings":"AAAA,+GAA+G;AAC/G,MAAM,WAAW,UAAU;IACzB,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;CACd;AAED,eAAO,MAAM,UAAU,EAAE,UAAqD,CAAC"}
|
|
@@ -8,12 +8,67 @@ export interface Labels {
|
|
|
8
8
|
noResultsDescription: string;
|
|
9
9
|
search: string;
|
|
10
10
|
selectPlaceholder: string;
|
|
11
|
-
/**
|
|
11
|
+
/** Month names, January to December. */
|
|
12
12
|
months: string[];
|
|
13
|
-
/**
|
|
13
|
+
/** Weekday initials, index 0 = Sunday (matches `Date.getDay()`). */
|
|
14
14
|
weekdaysShort: string[];
|
|
15
15
|
selectDate: string;
|
|
16
16
|
clear: string;
|
|
17
|
+
/** Eye button in Input with `isPassword`. */
|
|
18
|
+
showPassword: string;
|
|
19
|
+
hidePassword: string;
|
|
20
|
+
/** Appended to the accessible name of a `required` field (the asterisk is visual only). */
|
|
21
|
+
required: string;
|
|
22
|
+
/** Input validation: shown when a `required` field is empty. */
|
|
23
|
+
requiredError: string;
|
|
24
|
+
/** Input validation, `rules.minLength`. `{n}` is replaced by the limit. */
|
|
25
|
+
minLengthError: string;
|
|
26
|
+
/** Input validation, `rules.maxLength`. `{n}` is replaced by the limit. */
|
|
27
|
+
maxLengthError: string;
|
|
28
|
+
/** Input validation, `rules.pattern`. */
|
|
29
|
+
patternError: string;
|
|
30
|
+
/** Stepper: accessible name of the numeric field. */
|
|
31
|
+
quantity: string;
|
|
32
|
+
/** Stepper: "+" button. */
|
|
33
|
+
increment: string;
|
|
34
|
+
/** Stepper: "-" button. */
|
|
35
|
+
decrement: string;
|
|
36
|
+
/** Steps: accessible name of a step. `{n}`, `{total}` and `{label}` are replaced. */
|
|
37
|
+
stepOf: string;
|
|
38
|
+
/** Steps: state of a step already done. */
|
|
39
|
+
stepCompleted: string;
|
|
40
|
+
/** Steps: state of the step in progress. */
|
|
41
|
+
stepCurrent: string;
|
|
42
|
+
/** Steps: state of a step not reached yet. */
|
|
43
|
+
stepPending: string;
|
|
44
|
+
/** DatePicker: button to the previous month. */
|
|
45
|
+
previousMonth: string;
|
|
46
|
+
/** DatePicker: button to the next month. */
|
|
47
|
+
nextMonth: string;
|
|
48
|
+
/** ReorderableList: screen-reader action that moves a row one place up. */
|
|
49
|
+
moveUp: string;
|
|
50
|
+
/** ReorderableList: screen-reader action that moves a row one place down. */
|
|
51
|
+
moveDown: string;
|
|
52
|
+
/** SearchList: accessible name of the scan button. */
|
|
53
|
+
scan: string;
|
|
54
|
+
/** Slides: indicator name. `{n}` and `{total}` are replaced. */
|
|
55
|
+
slideOf: string;
|
|
56
|
+
/** Slides: button that pauses autoPlay. */
|
|
57
|
+
pauseSlides: string;
|
|
58
|
+
/** Slides: button that resumes autoPlay. */
|
|
59
|
+
resumeSlides: string;
|
|
60
|
+
/** ThemeToggle: segment that follows the system appearance. */
|
|
61
|
+
themeSystem: string;
|
|
62
|
+
/** ThemeToggle: light segment. */
|
|
63
|
+
themeLight: string;
|
|
64
|
+
/** ThemeToggle: dark segment. */
|
|
65
|
+
themeDark: string;
|
|
66
|
+
/** Wizard: button to the previous step. */
|
|
67
|
+
back: string;
|
|
68
|
+
/** Wizard: button to the next step. */
|
|
69
|
+
next: string;
|
|
70
|
+
/** Wizard: next button on the last step. */
|
|
71
|
+
finish: string;
|
|
17
72
|
}
|
|
18
73
|
export declare const defaultLabels: Labels;
|
|
19
74
|
//# sourceMappingURL=labels.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"labels.d.ts","sourceRoot":"","sources":["../../../src/theme/labels.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,MAAM,CAAC;IACvB,oBAAoB,EAAE,MAAM,CAAC;IAC7B,MAAM,EAAE,MAAM,CAAC;IACf,iBAAiB,EAAE,MAAM,CAAC;IAC1B,
|
|
1
|
+
{"version":3,"file":"labels.d.ts","sourceRoot":"","sources":["../../../src/theme/labels.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACrB,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,EAAE,MAAM,CAAC;IACpB,cAAc,EAAE,MAAM,CAAC;IACvB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;IACrB,+DAA+D;IAC/D,WAAW,EAAE,MAAM,CAAC;IACpB,kCAAkC;IAClC,UAAU,EAAE,MAAM,CAAC;IACnB,iCAAiC;IACjC,SAAS,EAAE,MAAM,CAAC;IAClB,2CAA2C;IAC3C,IAAI,EAAE,MAAM,CAAC;IACb,uCAAuC;IACvC,IAAI,EAAE,MAAM,CAAC;IACb,4CAA4C;IAC5C,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,eAAO,MAAM,aAAa,EAAE,MA6C3B,CAAC"}
|
|
@@ -1,21 +1,21 @@
|
|
|
1
1
|
/**
|
|
2
|
-
*
|
|
3
|
-
*
|
|
4
|
-
*
|
|
2
|
+
* Each color is a `string`, not a literal (`as const`): light and dark have
|
|
3
|
+
* different values for the same key, and createTheme() must be able to
|
|
4
|
+
* accept any hex/rgba in the overrides — literal typing would prevent it.
|
|
5
5
|
*
|
|
6
|
-
*
|
|
6
|
+
* Each accent comes in four roles, and they are not interchangeable:
|
|
7
7
|
*
|
|
8
|
-
* `primary`
|
|
9
|
-
* `onPrimary`
|
|
10
|
-
* `primarySoft`
|
|
11
|
-
* `primaryText`
|
|
12
|
-
*
|
|
8
|
+
* `primary` solid fill (button background, selected day, FAB).
|
|
9
|
+
* `onPrimary` text/icon *on top of* that fill.
|
|
10
|
+
* `primarySoft` tinted background for selected states and pills.
|
|
11
|
+
* `primaryText` accent text/icon over `surface`, `background`
|
|
12
|
+
* or over its own `primarySoft`.
|
|
13
13
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
*
|
|
17
|
-
*
|
|
18
|
-
*
|
|
14
|
+
* The reason is contrast: an accent that reads well as a fill doesn't read
|
|
15
|
+
* as text. Components used to use `colors.primary` for both things and tinted
|
|
16
|
+
* it by appending alpha to the hex (`colors.primary + '15'`), which in dark
|
|
17
|
+
* gave 2.6:1 over the surface — well below WCAG AA's 4.5:1. Every pair in
|
|
18
|
+
* this palette passes AA in both schemes.
|
|
19
19
|
*/
|
|
20
20
|
export interface ThemeColors {
|
|
21
21
|
primary: string;
|
|
@@ -42,21 +42,27 @@ export interface ThemeColors {
|
|
|
42
42
|
black: string;
|
|
43
43
|
background: string;
|
|
44
44
|
surface: string;
|
|
45
|
+
/**
|
|
46
|
+
* Fill of a surface that sits on another surface (Card). In light it equals
|
|
47
|
+
* `surface` (the shadow separates it); in dark it is lighter, because
|
|
48
|
+
* shadows don't show and elevation reads as a lighter fill.
|
|
49
|
+
*/
|
|
50
|
+
surfaceRaised: string;
|
|
45
51
|
text: string;
|
|
46
52
|
textLight: string;
|
|
47
53
|
border: string;
|
|
48
54
|
inputBackground: string;
|
|
49
55
|
overlay: string;
|
|
50
|
-
/**
|
|
56
|
+
/** Semi-transparent veil over custom content (List's loading footer). */
|
|
51
57
|
scrim: string;
|
|
52
|
-
/**
|
|
58
|
+
/** Placeholder background while an image loads. */
|
|
53
59
|
skeleton: string;
|
|
54
60
|
}
|
|
55
61
|
export declare const lightPalette: ThemeColors;
|
|
56
62
|
/**
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
* `onPrimary`
|
|
63
|
+
* The dark accents are NOT the light ones: over `#1e1e1e` the accent's
|
|
64
|
+
* lightness has to go up and that of the text on top has to go down (which
|
|
65
|
+
* is why `onPrimary` is dark blue here and white in light).
|
|
60
66
|
*/
|
|
61
67
|
export declare const darkPalette: ThemeColors;
|
|
62
68
|
//# sourceMappingURL=palettes.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"palettes.d.ts","sourceRoot":"","sources":["../../../src/theme/palettes.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,WAAW,WAAW;IAC1B,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IAEpB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,aA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O,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAElB,OAAO,EAAE,MAAM,CAAC;IAChB,SAAS,EAAE,MAAM,CAAC;IAClB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IAEpB,KAAK,EAAE,MAAM,CAAC;IACd,KAAK,EAAE,MAAM,CAAC;IACd,UAAU,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,MAAM,CAAC;IAChB;;;;OAIG;IACH,aAAa,EAAE,MAAM,CAAC;IACtB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,eAAe,EAAE,MAAM,CAAC;IACxB,OAAO,EAAE,MAAM,CAAC;IAChB,yEAAyE;IACzE,KAAK,EAAE,MAAM,CAAC;IACd,mDAAmD;IACnD,QAAQ,EAAE,MAAM,CAAC;CAClB;AAOD,eAAO,MAAM,YAAY,EAAE,WAyC1B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,WAAW,EAAE,WAsCzB,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { type ViewStyle } from 'react-native';
|
|
2
2
|
/**
|
|
3
|
-
*
|
|
4
|
-
*
|
|
3
|
+
* Spacing scale. Always use these values instead of magic numbers so the
|
|
4
|
+
* vertical/horizontal rhythm is consistent across components.
|
|
5
5
|
*/
|
|
6
6
|
export declare const spacing: Record<'xxs' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl' | 'xxxl', number>;
|
|
7
7
|
export declare const radius: Record<'none' | 'xs' | 'sm' | 'md' | 'lg' | 'xl' | 'xxl' | 'full', number>;
|
|
@@ -12,14 +12,20 @@ export declare const fontWeight: {
|
|
|
12
12
|
readonly semibold: "600";
|
|
13
13
|
readonly bold: "700";
|
|
14
14
|
};
|
|
15
|
-
export declare const lineHeight: Record<'sm' | 'md' | 'lg', number>;
|
|
16
|
-
/**
|
|
15
|
+
export declare const lineHeight: Record<'sm' | 'md' | 'lg' | 'xl', number>;
|
|
16
|
+
/**
|
|
17
|
+
* Tracking (letterSpacing) in points. `tight` offsets the extra room that
|
|
18
|
+
* large sizes bring by default (titles); `normal` is the system's;
|
|
19
|
+
* `wide` spaces out small caps.
|
|
20
|
+
*/
|
|
21
|
+
export declare const letterSpacing: Record<'tight' | 'normal' | 'wide', number>;
|
|
22
|
+
/** Durations in ms for Animated.timing/spring. */
|
|
17
23
|
export declare const duration: Record<'fast' | 'base' | 'slow', number>;
|
|
18
24
|
type ShadowStyle = Pick<ViewStyle, 'shadowColor' | 'shadowOffset' | 'shadowOpacity' | 'shadowRadius' | 'elevation'>;
|
|
19
25
|
/**
|
|
20
|
-
*
|
|
21
|
-
* `shadowColor`
|
|
22
|
-
*
|
|
26
|
+
* Cross-platform shadows: shadow* for iOS, elevation for Android.
|
|
27
|
+
* `shadowColor` is left fixed at black — a per-theme shadow color is too
|
|
28
|
+
* fine a detail to justify the complexity of resolving it here.
|
|
23
29
|
*/
|
|
24
30
|
export declare const shadow: Record<'none' | 'sm' | 'md' | 'lg', ShadowStyle>;
|
|
25
31
|
export declare const tokens: {
|
|
@@ -32,7 +38,8 @@ export declare const tokens: {
|
|
|
32
38
|
readonly semibold: "600";
|
|
33
39
|
readonly bold: "700";
|
|
34
40
|
};
|
|
35
|
-
lineHeight: Record<"sm" | "md" | "lg", number>;
|
|
41
|
+
lineHeight: Record<"sm" | "md" | "lg" | "xl", number>;
|
|
42
|
+
letterSpacing: Record<"tight" | "normal" | "wide", number>;
|
|
36
43
|
duration: Record<"fast" | "base" | "slow", number>;
|
|
37
44
|
shadow: Record<"sm" | "md" | "lg" | "none", ShadowStyle>;
|
|
38
45
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tokens.d.ts","sourceRoot":"","sources":["../../../src/theme/tokens.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,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O,MAAM,UAAU;;;;;CAKb,CAAC;AAEX,eAAO,MAAM,UAAU,EAAE,MAAM,CAAC,IAAI,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,EAAE,MAAM,CAKhE,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,aAAa,EAAE,MAAM,CAAC,OAAO,GAAG,QAAQ,GAAG,MAAM,EAAE,MAAM,CAKrE,CAAC;AAEF,kDAAkD;AAClD,eAAO,MAAM,QAAQ,EAAE,MAAM,CAAC,MAAM,GAAG,MAAM,GAAG,MAAM,EAAE,MAAM,CAI7D,CAAC;AAEF,KAAK,WAAW,GAAG,IAAI,CACrB,SAAS,EACT,aAAa,GAAG,cAAc,GAAG,eAAe,GAAG,cAAc,GAAG,WAAW,CAChF,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,MAAM,EAAE,MAAM,CAAC,MAAM,GAAG,IAAI,GAAG,IAAI,GAAG,IAAI,EAAE,WAAW,CA0BnE,CAAC;AAEF,eAAO,MAAM,MAAM;;;;;;;;;;;;;;CASlB,CAAC;AAEF,MAAM,MAAM,MAAM,GAAG,OAAO,MAAM,CAAC"}
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import type { Tokens } from './tokens';
|
|
2
2
|
import type { ThemeColors } from './palettes';
|
|
3
|
-
/**
|
|
3
|
+
/** Resolved theme: the palette of a given scheme + shared tokens. */
|
|
4
4
|
export interface Theme {
|
|
5
5
|
colors: ThemeColors;
|
|
6
6
|
tokens: Tokens;
|
|
7
7
|
scheme: 'light' | 'dark';
|
|
8
8
|
}
|
|
9
|
-
/**
|
|
9
|
+
/** Light/dark theme pair produced by createTheme() and consumed by UIProvider. */
|
|
10
10
|
export interface ThemePair {
|
|
11
11
|
light: Theme;
|
|
12
12
|
dark: Theme;
|
|
@@ -14,14 +14,14 @@ export interface ThemePair {
|
|
|
14
14
|
export type DeepPartial<T> = {
|
|
15
15
|
[K in keyof T]?: T[K] extends object ? DeepPartial<T[K]> : T[K];
|
|
16
16
|
};
|
|
17
|
-
/**
|
|
17
|
+
/** Accents that can be defined with a single hex via `brand`. */
|
|
18
18
|
export type BrandAccent = 'primary' | 'secondary' | 'success' | 'error' | 'warning';
|
|
19
19
|
export interface ThemeOverrides {
|
|
20
20
|
/**
|
|
21
|
-
*
|
|
22
|
-
*
|
|
23
|
-
*
|
|
24
|
-
*
|
|
21
|
+
* One hex per accent; each one derives its four roles (fill, content on top,
|
|
22
|
+
* subtle background and the variant legible on `surface`) for light and
|
|
23
|
+
* dark, with contrast already resolved. A plain string sets `primary`.
|
|
24
|
+
* Anything passed in `colors` wins over the derived values.
|
|
25
25
|
*/
|
|
26
26
|
brand?: string | Partial<Record<BrandAccent, string>>;
|
|
27
27
|
colors?: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/theme/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C,
|
|
1
|
+
{"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../../src/theme/types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,MAAM,EAAE,MAAM,UAAU,CAAC;AACvC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,YAAY,CAAC;AAE9C,qEAAqE;AACrE,MAAM,WAAW,KAAK;IACpB,MAAM,EAAE,WAAW,CAAC;IACpB,MAAM,EAAE,MAAM,CAAC;IACf,MAAM,EAAE,OAAO,GAAG,MAAM,CAAC;CAC1B;AAED,kFAAkF;AAClF,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,KAAK,CAAC;IACb,IAAI,EAAE,KAAK,CAAC;CACb;AAED,MAAM,MAAM,WAAW,CAAC,CAAC,IAAI;KAC1B,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,CAAC,SAAS,MAAM,GAAG,WAAW,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAChE,CAAC;AAEF,iEAAiE;AACjE,MAAM,MAAM,WAAW,GAAG,SAAS,GAAG,WAAW,GAAG,SAAS,GAAG,OAAO,GAAG,SAAS,CAAC;AAEpF,MAAM,WAAW,cAAc;IAC7B;;;;;OAKG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,WAAW,EAAE,MAAM,CAAC,CAAC,CAAC;IACtD,MAAM,CAAC,EAAE;QACP,KAAK,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;QAC7B,IAAI,CAAC,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;KAC7B,CAAC;IACF,MAAM,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAC;CAC9B"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { type RefObject, type ComponentRef } from 'react';
|
|
2
|
+
import type { View } from 'react-native';
|
|
3
|
+
/**
|
|
4
|
+
* Registers a text field with the nearest keyboard host (a Screen's content or
|
|
5
|
+
* the root UIProvider) so it stays visible above the keyboard. `boxRef` is the
|
|
6
|
+
* block that has to be seen whole: label, field and error.
|
|
7
|
+
*
|
|
8
|
+
* Call `focus()` from the TextInput's onFocus (and again when the block grows,
|
|
9
|
+
* e.g. an error shows up while typing) and `blur()` from onBlur. Inside a
|
|
10
|
+
* container that already handles the keyboard there is no host and both are
|
|
11
|
+
* no-ops.
|
|
12
|
+
*/
|
|
13
|
+
export declare function useKeyboardField(boxRef: RefObject<ComponentRef<typeof View> | null>): {
|
|
14
|
+
focus: () => void | undefined;
|
|
15
|
+
blur: () => void | undefined;
|
|
16
|
+
};
|
|
17
|
+
//# sourceMappingURL=useKeyboardField.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useKeyboardField.d.ts","sourceRoot":"","sources":["../../../src/theme/useKeyboardField.ts"],"names":[],"mappings":"AAAA,OAAO,EAAmB,KAAK,SAAS,EAAE,KAAK,YAAY,EAAE,MAAM,OAAO,CAAC;AAC3E,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,cAAc,CAAC;AAGzC;;;;;;;;;GASG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,SAAS,CAAC,YAAY,CAAC,OAAO,IAAI,CAAC,GAAG,IAAI,CAAC;;;EAkBnF"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Follows the system "reduce motion" setting: when it is on, animations jump
|
|
3
|
+
* to their final state instead of being disabled, so callbacks and unmounting
|
|
4
|
+
* still happen the same way.
|
|
5
|
+
*/
|
|
6
|
+
export declare function useReduceMotion(): boolean;
|
|
7
|
+
//# sourceMappingURL=useReduceMotion.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"useReduceMotion.d.ts","sourceRoot":"","sources":["../../../src/theme/useReduceMotion.ts"],"names":[],"mappings":"AAGA;;;;GAIG;AACH,wBAAgB,eAAe,IAAI,OAAO,CAkBzC"}
|
package/llms.txt
CHANGED
|
@@ -15,9 +15,9 @@ Or copy the source into the project with no dependency: `npx orn-ui add button s
|
|
|
15
15
|
Import from subpaths (Metro does not tree-shake barrels):
|
|
16
16
|
`import { Button } from 'orn-ui/button'`, `import { UIProvider } from 'orn-ui/theme'`.
|
|
17
17
|
|
|
18
|
-
Wrap the app once: `<
|
|
19
|
-
|
|
20
|
-
`
|
|
18
|
+
Wrap the app once: `<UIProvider defaultMode="system">` from `orn-ui/theme`. It
|
|
19
|
+
measures the safe-area insets itself (`react-native-safe-area-context` is a
|
|
20
|
+
required peer). `SafeAreaUIProvider` from `orn-ui/safe-area` is a deprecated alias.
|
|
21
21
|
|
|
22
22
|
## Docs
|
|
23
23
|
|
|
@@ -31,4 +31,4 @@ Wrap the app once: `<SafeAreaUIProvider defaultMode="system">` from `orn-ui/safe
|
|
|
31
31
|
- Atoms: Title, Subtitle, Body, Caption, Button, IconButton, Input, Checkbox, Badge, Card, Divider, Gradient, Avatar, Image, Spinner, Skeleton, Transition, ShinyText, EmptyState, KeyValueRow, Fab, PressableScale
|
|
32
32
|
- Molecules: Stepper, OptionCard, InfoRow, FormActions, AvatarHeader, SegmentedControl, Steps, SymmetricGrid
|
|
33
33
|
- Organisms: Screen, Modal, BottomSheet, Select, OptionWheel, Timeline, List, SearchList, ReorderableList, Slides, Chart, Alert, AlertProvider, Toast, ToastProvider, DatePicker, DateField, Wizard, ThemeToggle, NavigationBar
|
|
34
|
-
- Theme: UIProvider, SafeAreaUIProvider, createTheme, createStyles, useTheme, useColors, useThemeMode, useIcons, useInsets, useLabels
|
|
34
|
+
- Theme: UIProvider, SafeAreaUIProvider (deprecated alias), createTheme, createStyles, useTheme, useColors, useThemeMode, useIcons, useInsets, useLabels
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "orn-ui",
|
|
3
|
-
"version": "0.
|
|
4
|
-
"description": "React Native / Expo component library: 50 typed components, light/dark theming, zero runtime dependencies. Verified on Expo SDK 54-
|
|
3
|
+
"version": "0.3.0",
|
|
4
|
+
"description": "React Native / Expo component library: 50 typed components, light/dark theming, zero runtime dependencies. Verified on Expo SDK 54-58. Agent-friendly: one component instead of hundreds of lines of hand-written UI.",
|
|
5
5
|
"author": "David Trujillo <davot098@gmail.com>",
|
|
6
6
|
"main": "lib/commonjs/index.js",
|
|
7
7
|
"module": "lib/module/index.js",
|
|
@@ -93,6 +93,11 @@
|
|
|
93
93
|
"react-native": "./src/atoms/Avatar.tsx",
|
|
94
94
|
"default": "./lib/module/atoms/Avatar.js"
|
|
95
95
|
},
|
|
96
|
+
"./initials-of": {
|
|
97
|
+
"types": "./lib/typescript/atoms/Avatar.d.ts",
|
|
98
|
+
"react-native": "./src/atoms/Avatar.tsx",
|
|
99
|
+
"default": "./lib/module/atoms/Avatar.js"
|
|
100
|
+
},
|
|
96
101
|
"./image": {
|
|
97
102
|
"types": "./lib/typescript/atoms/Image.d.ts",
|
|
98
103
|
"react-native": "./src/atoms/Image.tsx",
|
|
@@ -383,24 +388,19 @@
|
|
|
383
388
|
"react-native": ">=0.81.0",
|
|
384
389
|
"react-native-safe-area-context": ">=5.4.0"
|
|
385
390
|
},
|
|
386
|
-
"peerDependenciesMeta": {
|
|
387
|
-
"react-native-safe-area-context": {
|
|
388
|
-
"optional": true
|
|
389
|
-
}
|
|
390
|
-
},
|
|
391
391
|
"devDependencies": {
|
|
392
|
-
"@react-native/babel-preset": "^0.
|
|
393
|
-
"@react-native/jest-preset": "^0.
|
|
392
|
+
"@react-native/babel-preset": "^0.88.1",
|
|
393
|
+
"@react-native/jest-preset": "^0.88.1",
|
|
394
394
|
"@testing-library/react-native": "^13.3.3",
|
|
395
395
|
"@types/jest": "^29.5.14",
|
|
396
|
-
"@types/react": "~19.
|
|
396
|
+
"@types/react": "~19.3.0",
|
|
397
397
|
"@types/react-test-renderer": "^19.1.0",
|
|
398
398
|
"jest": "^29.7.0",
|
|
399
|
-
"react": "19.
|
|
400
|
-
"react-native": "0.
|
|
399
|
+
"react": "19.3.0",
|
|
400
|
+
"react-native": "0.88.1",
|
|
401
401
|
"react-native-builder-bob": "^0.35.3",
|
|
402
|
-
"react-native-safe-area-context": "~5.
|
|
403
|
-
"react-test-renderer": "19.
|
|
402
|
+
"react-native-safe-area-context": "~5.11.1",
|
|
403
|
+
"react-test-renderer": "19.3.0",
|
|
404
404
|
"typescript": "~5.9.3"
|
|
405
405
|
},
|
|
406
406
|
"keywords": [
|
|
@@ -410,6 +410,7 @@
|
|
|
410
410
|
"expo-sdk-55",
|
|
411
411
|
"expo-sdk-56",
|
|
412
412
|
"expo-sdk-57",
|
|
413
|
+
"expo-sdk-58",
|
|
413
414
|
"ui",
|
|
414
415
|
"components",
|
|
415
416
|
"component-library",
|