@mindlogic-ai/logician-ui 4.0.0-alpha.9 → 4.0.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/USAGE.md +17 -0
- package/dist/components/Appear/Appear.d.ts +45 -0
- package/dist/components/Appear/Appear.d.ts.map +1 -0
- package/dist/components/Appear/Appear.js +61 -0
- package/dist/components/Appear/Appear.js.map +1 -0
- package/dist/components/Appear/Appear.mjs +59 -0
- package/dist/components/Appear/Appear.mjs.map +1 -0
- package/dist/components/Appear/Appear.styles.d.ts +18 -0
- package/dist/components/Appear/Appear.styles.d.ts.map +1 -0
- package/dist/components/Appear/Appear.styles.js +32 -0
- package/dist/components/Appear/Appear.styles.js.map +1 -0
- package/dist/components/Appear/Appear.styles.mjs +30 -0
- package/dist/components/Appear/Appear.styles.mjs.map +1 -0
- package/dist/components/Appear/Appear.types.d.ts +18 -0
- package/dist/components/Appear/Appear.types.d.ts.map +1 -0
- package/dist/components/Appear/index.d.ts +3 -0
- package/dist/components/Appear/index.d.ts.map +1 -0
- package/dist/components/Badge/Badge.d.ts +2 -15
- package/dist/components/Badge/Badge.d.ts.map +1 -1
- package/dist/components/Badge/Badge.js +5 -2
- package/dist/components/Badge/Badge.js.map +1 -1
- package/dist/components/Badge/Badge.mjs +5 -2
- package/dist/components/Badge/Badge.mjs.map +1 -1
- package/dist/components/Badge/Badge.types.d.ts +15 -2
- package/dist/components/Badge/Badge.types.d.ts.map +1 -1
- package/dist/components/Badge/index.d.ts +1 -1
- package/dist/components/Badge/index.d.ts.map +1 -1
- package/dist/components/Banner/Banner.js +2 -1
- package/dist/components/Banner/Banner.js.map +1 -1
- package/dist/components/Banner/Banner.mjs +2 -1
- package/dist/components/Banner/Banner.mjs.map +1 -1
- package/dist/components/BottomSheet/BottomSheet.d.ts +28 -0
- package/dist/components/BottomSheet/BottomSheet.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.js +38 -0
- package/dist/components/BottomSheet/BottomSheet.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.mjs +36 -0
- package/dist/components/BottomSheet/BottomSheet.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.styles.d.ts +32 -0
- package/dist/components/BottomSheet/BottomSheet.styles.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.styles.js +164 -0
- package/dist/components/BottomSheet/BottomSheet.styles.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.styles.mjs +161 -0
- package/dist/components/BottomSheet/BottomSheet.styles.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheet.types.d.ts +43 -0
- package/dist/components/BottomSheet/BottomSheet.types.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetBody.d.ts +8 -0
- package/dist/components/BottomSheet/BottomSheetBody.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetBody.js +17 -0
- package/dist/components/BottomSheet/BottomSheetBody.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetBody.mjs +15 -0
- package/dist/components/BottomSheet/BottomSheetBody.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.d.ts +11 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.js +27 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.mjs +25 -0
- package/dist/components/BottomSheet/BottomSheetCloseButton.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContent.d.ts +12 -0
- package/dist/components/BottomSheet/BottomSheetContent.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContent.js +25 -0
- package/dist/components/BottomSheet/BottomSheetContent.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContent.mjs +23 -0
- package/dist/components/BottomSheet/BottomSheetContent.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContext.d.ts +28 -0
- package/dist/components/BottomSheet/BottomSheetContext.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContext.js +53 -0
- package/dist/components/BottomSheet/BottomSheetContext.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetContext.mjs +40 -0
- package/dist/components/BottomSheet/BottomSheetContext.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetFooter.d.ts +4 -0
- package/dist/components/BottomSheet/BottomSheetFooter.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetFooter.js +13 -0
- package/dist/components/BottomSheet/BottomSheetFooter.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetFooter.mjs +11 -0
- package/dist/components/BottomSheet/BottomSheetFooter.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetHeader.d.ts +8 -0
- package/dist/components/BottomSheet/BottomSheetHeader.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetHeader.js +19 -0
- package/dist/components/BottomSheet/BottomSheetHeader.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetHeader.mjs +17 -0
- package/dist/components/BottomSheet/BottomSheetHeader.mjs.map +1 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.d.ts +8 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.d.ts.map +1 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.js +17 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.js.map +1 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.mjs +15 -0
- package/dist/components/BottomSheet/BottomSheetOverlay.mjs.map +1 -0
- package/dist/components/BottomSheet/index.d.ts +11 -0
- package/dist/components/BottomSheet/index.d.ts.map +1 -0
- package/dist/components/Button/Button.d.ts +2 -18
- package/dist/components/Button/Button.d.ts.map +1 -1
- package/dist/components/Button/Button.js +66 -4
- package/dist/components/Button/Button.js.map +1 -1
- package/dist/components/Button/Button.mjs +67 -5
- package/dist/components/Button/Button.mjs.map +1 -1
- package/dist/components/Button/Button.styles.d.ts +1 -0
- package/dist/components/Button/Button.styles.d.ts.map +1 -1
- package/dist/components/Button/Button.styles.js +123 -42
- package/dist/components/Button/Button.styles.js.map +1 -1
- package/dist/components/Button/Button.styles.mjs +123 -43
- package/dist/components/Button/Button.styles.mjs.map +1 -1
- package/dist/components/Button/Button.types.d.ts +38 -1
- package/dist/components/Button/Button.types.d.ts.map +1 -1
- package/dist/components/Button/index.d.ts +1 -1
- package/dist/components/Button/index.d.ts.map +1 -1
- package/dist/components/Card/Card.d.ts +2 -5
- package/dist/components/Card/Card.d.ts.map +1 -1
- package/dist/components/Card/Card.js +12 -4
- package/dist/components/Card/Card.js.map +1 -1
- package/dist/components/Card/Card.mjs +12 -4
- package/dist/components/Card/Card.mjs.map +1 -1
- package/dist/components/Card/Card.styles.d.ts +26 -3
- package/dist/components/Card/Card.styles.d.ts.map +1 -1
- package/dist/components/Card/Card.styles.js +36 -5
- package/dist/components/Card/Card.styles.js.map +1 -1
- package/dist/components/Card/Card.styles.mjs +36 -5
- package/dist/components/Card/Card.styles.mjs.map +1 -1
- package/dist/components/Card/Card.types.d.ts +20 -2
- package/dist/components/Card/Card.types.d.ts.map +1 -1
- package/dist/components/Card/index.d.ts +1 -1
- package/dist/components/Card/index.d.ts.map +1 -1
- package/dist/components/Checkbox/Checkbox.styles.d.ts +16 -0
- package/dist/components/Checkbox/Checkbox.styles.d.ts.map +1 -0
- package/dist/components/Checkbox/Checkbox.styles.js +30 -0
- package/dist/components/Checkbox/Checkbox.styles.js.map +1 -0
- package/dist/components/Checkbox/Checkbox.styles.mjs +28 -0
- package/dist/components/Checkbox/Checkbox.styles.mjs.map +1 -0
- package/dist/components/Checkbox/CheckboxControl.d.ts.map +1 -1
- package/dist/components/Checkbox/CheckboxControl.js +6 -1
- package/dist/components/Checkbox/CheckboxControl.js.map +1 -1
- package/dist/components/Checkbox/CheckboxControl.mjs +6 -1
- package/dist/components/Checkbox/CheckboxControl.mjs.map +1 -1
- package/dist/components/Chip/Chip.d.ts +3 -16
- package/dist/components/Chip/Chip.d.ts.map +1 -1
- package/dist/components/Chip/Chip.js +5 -2
- package/dist/components/Chip/Chip.js.map +1 -1
- package/dist/components/Chip/Chip.mjs +5 -2
- package/dist/components/Chip/Chip.mjs.map +1 -1
- package/dist/components/Chip/Chip.types.d.ts +11 -2
- package/dist/components/Chip/Chip.types.d.ts.map +1 -1
- package/dist/components/Chip/index.d.ts +1 -1
- package/dist/components/Chip/index.d.ts.map +1 -1
- package/dist/components/CodeTabs/CodeTabs.js +1 -0
- package/dist/components/CodeTabs/CodeTabs.js.map +1 -1
- package/dist/components/CodeTabs/CodeTabs.mjs +1 -0
- package/dist/components/CodeTabs/CodeTabs.mjs.map +1 -1
- package/dist/components/Collapsible/CollapsibleContent.d.ts.map +1 -1
- package/dist/components/Collapsible/CollapsibleContent.js +5 -1
- package/dist/components/Collapsible/CollapsibleContent.js.map +1 -1
- package/dist/components/Collapsible/CollapsibleContent.mjs +5 -1
- package/dist/components/Collapsible/CollapsibleContent.mjs.map +1 -1
- package/dist/components/ColorMode/ColorModeToggle.d.ts.map +1 -1
- package/dist/components/ColorMode/ColorModeToggle.js +4 -2
- package/dist/components/ColorMode/ColorModeToggle.js.map +1 -1
- package/dist/components/ColorMode/ColorModeToggle.mjs +5 -3
- package/dist/components/ColorMode/ColorModeToggle.mjs.map +1 -1
- package/dist/components/Confetti/Confetti.d.ts +50 -0
- package/dist/components/Confetti/Confetti.d.ts.map +1 -0
- package/dist/components/Confetti/Confetti.js +149 -0
- package/dist/components/Confetti/Confetti.js.map +1 -0
- package/dist/components/Confetti/Confetti.mjs +147 -0
- package/dist/components/Confetti/Confetti.mjs.map +1 -0
- package/dist/components/Confetti/Confetti.styles.d.ts +32 -0
- package/dist/components/Confetti/Confetti.styles.d.ts.map +1 -0
- package/dist/components/Confetti/Confetti.styles.js +60 -0
- package/dist/components/Confetti/Confetti.styles.js.map +1 -0
- package/dist/components/Confetti/Confetti.styles.mjs +58 -0
- package/dist/components/Confetti/Confetti.styles.mjs.map +1 -0
- package/dist/components/Confetti/Confetti.types.d.ts +13 -0
- package/dist/components/Confetti/Confetti.types.d.ts.map +1 -0
- package/dist/components/Confetti/index.d.ts +3 -0
- package/dist/components/Confetti/index.d.ts.map +1 -0
- package/dist/components/Container/Container.d.ts +3 -4
- package/dist/components/Container/Container.d.ts.map +1 -1
- package/dist/components/Container/Container.js +5 -1
- package/dist/components/Container/Container.js.map +1 -1
- package/dist/components/Container/Container.mjs +5 -1
- package/dist/components/Container/Container.mjs.map +1 -1
- package/dist/components/Container/Container.types.d.ts +16 -0
- package/dist/components/Container/Container.types.d.ts.map +1 -0
- package/dist/components/Container/index.d.ts +1 -0
- package/dist/components/Container/index.d.ts.map +1 -1
- package/dist/components/CopyableCode/CopyableCode.d.ts +6 -0
- package/dist/components/CopyableCode/CopyableCode.d.ts.map +1 -1
- package/dist/components/CopyableCode/CopyableCode.js +49 -1
- package/dist/components/CopyableCode/CopyableCode.js.map +1 -1
- package/dist/components/CopyableCode/CopyableCode.mjs +50 -2
- package/dist/components/CopyableCode/CopyableCode.mjs.map +1 -1
- package/dist/components/CountUp/CountUp.d.ts +30 -0
- package/dist/components/CountUp/CountUp.d.ts.map +1 -0
- package/dist/components/CountUp/CountUp.js +95 -0
- package/dist/components/CountUp/CountUp.js.map +1 -0
- package/dist/components/CountUp/CountUp.mjs +93 -0
- package/dist/components/CountUp/CountUp.mjs.map +1 -0
- package/dist/components/CountUp/CountUp.types.d.ts +19 -0
- package/dist/components/CountUp/CountUp.types.d.ts.map +1 -0
- package/dist/components/CountUp/index.d.ts +3 -0
- package/dist/components/CountUp/index.d.ts.map +1 -0
- package/dist/components/ErrorFallback/ErrorFallback.d.ts.map +1 -1
- package/dist/components/ErrorFallback/ErrorFallback.js +17 -2
- package/dist/components/ErrorFallback/ErrorFallback.js.map +1 -1
- package/dist/components/ErrorFallback/ErrorFallback.mjs +17 -2
- package/dist/components/ErrorFallback/ErrorFallback.mjs.map +1 -1
- package/dist/components/ExpandableText/ExpandableText.d.ts +31 -10
- package/dist/components/ExpandableText/ExpandableText.d.ts.map +1 -1
- package/dist/components/ExpandableText/ExpandableText.js +22 -3
- package/dist/components/ExpandableText/ExpandableText.js.map +1 -1
- package/dist/components/ExpandableText/ExpandableText.mjs +22 -3
- package/dist/components/ExpandableText/ExpandableText.mjs.map +1 -1
- package/dist/components/ExpandableText/useExpandableText.d.ts +28 -3
- package/dist/components/ExpandableText/useExpandableText.d.ts.map +1 -1
- package/dist/components/ExpandableText/useExpandableText.js +74 -72
- package/dist/components/ExpandableText/useExpandableText.js.map +1 -1
- package/dist/components/ExpandableText/useExpandableText.mjs +75 -73
- package/dist/components/ExpandableText/useExpandableText.mjs.map +1 -1
- package/dist/components/FileInput/FileInput.d.ts.map +1 -1
- package/dist/components/FileInput/FileInput.js +11 -1
- package/dist/components/FileInput/FileInput.js.map +1 -1
- package/dist/components/FileInput/FileInput.mjs +12 -2
- package/dist/components/FileInput/FileInput.mjs.map +1 -1
- package/dist/components/FileItem/FileItem.js +2 -1
- package/dist/components/FileItem/FileItem.js.map +1 -1
- package/dist/components/FileItem/FileItem.mjs +3 -2
- package/dist/components/FileItem/FileItem.mjs.map +1 -1
- package/dist/components/FileList/FileList.d.ts +1 -1
- package/dist/components/FileList/FileList.d.ts.map +1 -1
- package/dist/components/FileList/FileList.js +11 -3
- package/dist/components/FileList/FileList.js.map +1 -1
- package/dist/components/FileList/FileList.mjs +12 -4
- package/dist/components/FileList/FileList.mjs.map +1 -1
- package/dist/components/FileList/FileList.types.d.ts +9 -0
- package/dist/components/FileList/FileList.types.d.ts.map +1 -1
- package/dist/components/FlyTo/FlyTo.d.ts +35 -0
- package/dist/components/FlyTo/FlyTo.d.ts.map +1 -0
- package/dist/components/FlyTo/FlyTo.js +69 -0
- package/dist/components/FlyTo/FlyTo.js.map +1 -0
- package/dist/components/FlyTo/FlyTo.mjs +67 -0
- package/dist/components/FlyTo/FlyTo.mjs.map +1 -0
- package/dist/components/FlyTo/FlyTo.styles.d.ts +19 -0
- package/dist/components/FlyTo/FlyTo.styles.d.ts.map +1 -0
- package/dist/components/FlyTo/FlyTo.styles.js +35 -0
- package/dist/components/FlyTo/FlyTo.styles.js.map +1 -0
- package/dist/components/FlyTo/FlyTo.styles.mjs +33 -0
- package/dist/components/FlyTo/FlyTo.styles.mjs.map +1 -0
- package/dist/components/FlyTo/FlyTo.types.d.ts +15 -0
- package/dist/components/FlyTo/FlyTo.types.d.ts.map +1 -0
- package/dist/components/FlyTo/index.d.ts +3 -0
- package/dist/components/FlyTo/index.d.ts.map +1 -0
- package/dist/components/Form/FieldError/FieldError.d.ts +15 -0
- package/dist/components/Form/FieldError/FieldError.d.ts.map +1 -0
- package/dist/components/Form/FieldError/FieldError.js +22 -0
- package/dist/components/Form/FieldError/FieldError.js.map +1 -0
- package/dist/components/Form/FieldError/FieldError.mjs +20 -0
- package/dist/components/Form/FieldError/FieldError.mjs.map +1 -0
- package/dist/components/Form/FieldError/index.d.ts +3 -0
- package/dist/components/Form/FieldError/index.d.ts.map +1 -0
- package/dist/components/Form/FieldHelp/FieldHelp.d.ts +14 -0
- package/dist/components/Form/FieldHelp/FieldHelp.d.ts.map +1 -0
- package/dist/components/Form/FieldHelp/FieldHelp.js +19 -0
- package/dist/components/Form/FieldHelp/FieldHelp.js.map +1 -0
- package/dist/components/Form/FieldHelp/FieldHelp.mjs +17 -0
- package/dist/components/Form/FieldHelp/FieldHelp.mjs.map +1 -0
- package/dist/components/Form/FieldHelp/index.d.ts +3 -0
- package/dist/components/Form/FieldHelp/index.d.ts.map +1 -0
- package/dist/components/Form/FieldLabel/FieldLabel.d.ts +12 -0
- package/dist/components/Form/FieldLabel/FieldLabel.d.ts.map +1 -0
- package/dist/components/Form/FieldLabel/FieldLabel.js +33 -0
- package/dist/components/Form/FieldLabel/FieldLabel.js.map +1 -0
- package/dist/components/Form/FieldLabel/FieldLabel.mjs +31 -0
- package/dist/components/Form/FieldLabel/FieldLabel.mjs.map +1 -0
- package/dist/components/Form/FieldLabel/FieldLabel.types.d.ts +21 -0
- package/dist/components/Form/FieldLabel/FieldLabel.types.d.ts.map +1 -0
- package/dist/components/Form/FieldLabel/index.d.ts +3 -0
- package/dist/components/Form/FieldLabel/index.d.ts.map +1 -0
- package/dist/components/Form/FieldRow/FieldRow.d.ts +15 -0
- package/dist/components/Form/FieldRow/FieldRow.d.ts.map +1 -0
- package/dist/components/Form/FieldRow/FieldRow.js +27 -0
- package/dist/components/Form/FieldRow/FieldRow.js.map +1 -0
- package/dist/components/Form/FieldRow/FieldRow.mjs +25 -0
- package/dist/components/Form/FieldRow/FieldRow.mjs.map +1 -0
- package/dist/components/Form/FieldRow/FieldRow.types.d.ts +27 -0
- package/dist/components/Form/FieldRow/FieldRow.types.d.ts.map +1 -0
- package/dist/components/Form/FieldRow/index.d.ts +3 -0
- package/dist/components/Form/FieldRow/index.d.ts.map +1 -0
- package/dist/components/Form/FormFooter/FormFooter.d.ts +11 -0
- package/dist/components/Form/FormFooter/FormFooter.d.ts.map +1 -0
- package/dist/components/Form/FormFooter/FormFooter.js +20 -0
- package/dist/components/Form/FormFooter/FormFooter.js.map +1 -0
- package/dist/components/Form/FormFooter/FormFooter.mjs +18 -0
- package/dist/components/Form/FormFooter/FormFooter.mjs.map +1 -0
- package/dist/components/Form/FormFooter/FormFooter.types.d.ts +23 -0
- package/dist/components/Form/FormFooter/FormFooter.types.d.ts.map +1 -0
- package/dist/components/Form/FormFooter/index.d.ts +3 -0
- package/dist/components/Form/FormFooter/index.d.ts.map +1 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.d.ts +19 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.d.ts.map +1 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.js +42 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.js.map +1 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.mjs +40 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.mjs.map +1 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.types.d.ts +49 -0
- package/dist/components/Form/FormModalFooter/FormModalFooter.types.d.ts.map +1 -0
- package/dist/components/Form/FormModalFooter/index.d.ts +3 -0
- package/dist/components/Form/FormModalFooter/index.d.ts.map +1 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.d.ts +14 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.d.ts.map +1 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.js +18 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.js.map +1 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.mjs +16 -0
- package/dist/components/Form/FormScrollArea/FormScrollArea.mjs.map +1 -0
- package/dist/components/Form/FormScrollArea/index.d.ts +2 -0
- package/dist/components/Form/FormScrollArea/index.d.ts.map +1 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.d.ts +10 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.d.ts.map +1 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.js +46 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.js.map +1 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.mjs +44 -0
- package/dist/components/Form/FormSection/CollapsibleFormSection.mjs.map +1 -0
- package/dist/components/Form/FormSection/FlatFormSection.d.ts +6 -0
- package/dist/components/Form/FormSection/FlatFormSection.d.ts.map +1 -0
- package/dist/components/Form/FormSection/FlatFormSection.js +12 -0
- package/dist/components/Form/FormSection/FlatFormSection.js.map +1 -0
- package/dist/components/Form/FormSection/FlatFormSection.mjs +10 -0
- package/dist/components/Form/FormSection/FlatFormSection.mjs.map +1 -0
- package/dist/components/Form/FormSection/FormSection.d.ts +13 -0
- package/dist/components/Form/FormSection/FormSection.d.ts.map +1 -0
- package/dist/components/Form/FormSection/FormSection.js +21 -0
- package/dist/components/Form/FormSection/FormSection.js.map +1 -0
- package/dist/components/Form/FormSection/FormSection.mjs +19 -0
- package/dist/components/Form/FormSection/FormSection.mjs.map +1 -0
- package/dist/components/Form/FormSection/FormSection.types.d.ts +34 -0
- package/dist/components/Form/FormSection/FormSection.types.d.ts.map +1 -0
- package/dist/components/Form/FormSection/index.d.ts +3 -0
- package/dist/components/Form/FormSection/index.d.ts.map +1 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.d.ts +13 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.d.ts.map +1 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.js +31 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.js.map +1 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.mjs +29 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.mjs.map +1 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.types.d.ts +17 -0
- package/dist/components/Form/FormSectionHeader/FormSectionHeader.types.d.ts.map +1 -0
- package/dist/components/Form/FormSectionHeader/index.d.ts +3 -0
- package/dist/components/Form/FormSectionHeader/index.d.ts.map +1 -0
- package/dist/components/Form/index.d.ts +18 -0
- package/dist/components/Form/index.d.ts.map +1 -0
- package/dist/components/Icon/_constants/iconList.d.ts +2 -1
- package/dist/components/Icon/_constants/iconList.d.ts.map +1 -1
- package/dist/components/Icon/_constants/iconList.js +309 -134
- package/dist/components/Icon/_constants/iconList.js.map +1 -1
- package/dist/components/Icon/_constants/iconList.mjs +337 -162
- package/dist/components/Icon/_constants/iconList.mjs.map +1 -1
- package/dist/components/Icon/_utils/createIcon.d.ts.map +1 -1
- package/dist/components/Icon/_utils/createIcon.js +1 -0
- package/dist/components/Icon/_utils/createIcon.js.map +1 -1
- package/dist/components/Icon/_utils/createIcon.mjs +1 -0
- package/dist/components/Icon/_utils/createIcon.mjs.map +1 -1
- package/dist/components/Icon/index.d.ts +1 -1
- package/dist/components/Icon/index.d.ts.map +1 -1
- package/dist/components/Icon/index.js +205 -42
- package/dist/components/Icon/index.js.map +1 -1
- package/dist/components/Icon/index.mjs +3 -43
- package/dist/components/Icon/index.mjs.map +1 -1
- package/dist/components/IconButton/IconButton.d.ts +2 -17
- package/dist/components/IconButton/IconButton.d.ts.map +1 -1
- package/dist/components/IconButton/IconButton.js +11 -3
- package/dist/components/IconButton/IconButton.js.map +1 -1
- package/dist/components/IconButton/IconButton.mjs +11 -3
- package/dist/components/IconButton/IconButton.mjs.map +1 -1
- package/dist/components/IconButton/IconButton.types.d.ts +15 -1
- package/dist/components/IconButton/IconButton.types.d.ts.map +1 -1
- package/dist/components/IconButton/index.d.ts +1 -1
- package/dist/components/IconButton/index.d.ts.map +1 -1
- package/dist/components/InfoSprinkle/InfoSprinkle.d.ts.map +1 -1
- package/dist/components/InfoSprinkle/InfoSprinkle.js +1 -1
- package/dist/components/InfoSprinkle/InfoSprinkle.js.map +1 -1
- package/dist/components/InfoSprinkle/InfoSprinkle.mjs +1 -1
- package/dist/components/InfoSprinkle/InfoSprinkle.mjs.map +1 -1
- package/dist/components/InlineCode/InlineCode.d.ts.map +1 -1
- package/dist/components/InlineCode/InlineCode.js +10 -1
- package/dist/components/InlineCode/InlineCode.js.map +1 -1
- package/dist/components/InlineCode/InlineCode.mjs +10 -1
- package/dist/components/InlineCode/InlineCode.mjs.map +1 -1
- package/dist/components/Input/Input.d.ts.map +1 -1
- package/dist/components/Input/Input.js +2 -1
- package/dist/components/Input/Input.js.map +1 -1
- package/dist/components/Input/Input.mjs +2 -1
- package/dist/components/Input/Input.mjs.map +1 -1
- package/dist/components/Loaders/PageLoader.d.ts.map +1 -1
- package/dist/components/Loaders/PageLoader.js +4 -1
- package/dist/components/Loaders/PageLoader.js.map +1 -1
- package/dist/components/Loaders/PageLoader.mjs +4 -1
- package/dist/components/Loaders/PageLoader.mjs.map +1 -1
- package/dist/components/Loaders/SectionLoader.d.ts.map +1 -1
- package/dist/components/Loaders/SectionLoader.js +1 -1
- package/dist/components/Loaders/SectionLoader.js.map +1 -1
- package/dist/components/Loaders/SectionLoader.mjs +1 -1
- package/dist/components/Loaders/SectionLoader.mjs.map +1 -1
- package/dist/components/Markdown/Markdown.d.ts.map +1 -1
- package/dist/components/Markdown/Markdown.js +7 -1
- package/dist/components/Markdown/Markdown.js.map +1 -1
- package/dist/components/Markdown/Markdown.mjs +7 -1
- package/dist/components/Markdown/Markdown.mjs.map +1 -1
- package/dist/components/MaxLengthIndicator/MaxLengthIndicator.js +1 -0
- package/dist/components/MaxLengthIndicator/MaxLengthIndicator.js.map +1 -1
- package/dist/components/MaxLengthIndicator/MaxLengthIndicator.mjs +1 -0
- package/dist/components/MaxLengthIndicator/MaxLengthIndicator.mjs.map +1 -1
- package/dist/components/Menu/Menu.d.ts +2 -1
- package/dist/components/Menu/Menu.d.ts.map +1 -1
- package/dist/components/Menu/MenuItem.d.ts +2 -2
- package/dist/components/Menu/MenuItem.d.ts.map +1 -1
- package/dist/components/Menu/MenuItem.js +8 -2
- package/dist/components/Menu/MenuItem.js.map +1 -1
- package/dist/components/Menu/MenuItem.mjs +8 -2
- package/dist/components/Menu/MenuItem.mjs.map +1 -1
- package/dist/components/Menu/MenuItem.types.d.ts +17 -2
- package/dist/components/Menu/MenuItem.types.d.ts.map +1 -1
- package/dist/components/Menu/MenuItem.types.js.map +1 -1
- package/dist/components/Menu/MenuItem.types.mjs.map +1 -1
- package/dist/components/Menu/MenuList.d.ts +20 -0
- package/dist/components/Menu/MenuList.d.ts.map +1 -1
- package/dist/components/Menu/MenuList.js +20 -2
- package/dist/components/Menu/MenuList.js.map +1 -1
- package/dist/components/Menu/MenuList.mjs +21 -3
- package/dist/components/Menu/MenuList.mjs.map +1 -1
- package/dist/components/Modal/Modal.d.ts.map +1 -1
- package/dist/components/Modal/Modal.js +2 -2
- package/dist/components/Modal/Modal.js.map +1 -1
- package/dist/components/Modal/Modal.mjs +2 -2
- package/dist/components/Modal/Modal.mjs.map +1 -1
- package/dist/components/Modal/Modal.styles.d.ts +22 -0
- package/dist/components/Modal/Modal.styles.d.ts.map +1 -1
- package/dist/components/Modal/Modal.styles.js +24 -0
- package/dist/components/Modal/Modal.styles.js.map +1 -0
- package/dist/components/Modal/Modal.styles.mjs +22 -0
- package/dist/components/Modal/Modal.styles.mjs.map +1 -0
- package/dist/components/Modal/Modal.types.d.ts +10 -2
- package/dist/components/Modal/Modal.types.d.ts.map +1 -1
- package/dist/components/Modal/ModalContent/ModalContent.d.ts.map +1 -1
- package/dist/components/Modal/ModalContent/ModalContent.js +2 -1
- package/dist/components/Modal/ModalContent/ModalContent.js.map +1 -1
- package/dist/components/Modal/ModalContent/ModalContent.mjs +2 -1
- package/dist/components/Modal/ModalContent/ModalContent.mjs.map +1 -1
- package/dist/components/Modal/ModalContext.js +1 -1
- package/dist/components/Modal/ModalContext.js.map +1 -1
- package/dist/components/Modal/ModalContext.mjs +1 -1
- package/dist/components/Modal/ModalContext.mjs.map +1 -1
- package/dist/components/Modal/ModalOverlay.d.ts.map +1 -1
- package/dist/components/Modal/ModalOverlay.js +3 -1
- package/dist/components/Modal/ModalOverlay.js.map +1 -1
- package/dist/components/Modal/ModalOverlay.mjs +3 -1
- package/dist/components/Modal/ModalOverlay.mjs.map +1 -1
- package/dist/components/MonthPicker/MonthPicker.js +1 -0
- package/dist/components/MonthPicker/MonthPicker.js.map +1 -1
- package/dist/components/MonthPicker/MonthPicker.mjs +1 -0
- package/dist/components/MonthPicker/MonthPicker.mjs.map +1 -1
- package/dist/components/Pagination/Pagination.d.ts.map +1 -1
- package/dist/components/Pagination/Pagination.js +8 -2
- package/dist/components/Pagination/Pagination.js.map +1 -1
- package/dist/components/Pagination/Pagination.mjs +9 -3
- package/dist/components/Pagination/Pagination.mjs.map +1 -1
- package/dist/components/PasswordInput/PasswordInput.d.ts.map +1 -1
- package/dist/components/PasswordInput/PasswordInput.js +2 -2
- package/dist/components/PasswordInput/PasswordInput.js.map +1 -1
- package/dist/components/PasswordInput/PasswordInput.mjs +2 -2
- package/dist/components/PasswordInput/PasswordInput.mjs.map +1 -1
- package/dist/components/PinInput/PinInput.d.ts +1 -4
- package/dist/components/PinInput/PinInput.d.ts.map +1 -1
- package/dist/components/PinInput/PinInput.js +5 -22
- package/dist/components/PinInput/PinInput.js.map +1 -1
- package/dist/components/PinInput/PinInput.mjs +8 -25
- package/dist/components/PinInput/PinInput.mjs.map +1 -1
- package/dist/components/PinInput/PinInput.types.d.ts +7 -24
- package/dist/components/PinInput/PinInput.types.d.ts.map +1 -1
- package/dist/components/Popover/PopoverContent.d.ts.map +1 -1
- package/dist/components/Popover/PopoverContent.js +4 -1
- package/dist/components/Popover/PopoverContent.js.map +1 -1
- package/dist/components/Popover/PopoverContent.mjs +4 -1
- package/dist/components/Popover/PopoverContent.mjs.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.d.ts +1 -1
- package/dist/components/ProgressBar/ProgressBar.d.ts.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.js +19 -2
- package/dist/components/ProgressBar/ProgressBar.js.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.mjs +20 -3
- package/dist/components/ProgressBar/ProgressBar.mjs.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.styles.d.ts +18 -0
- package/dist/components/ProgressBar/ProgressBar.styles.d.ts.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.styles.js +24 -0
- package/dist/components/ProgressBar/ProgressBar.styles.js.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.styles.mjs +24 -1
- package/dist/components/ProgressBar/ProgressBar.styles.mjs.map +1 -1
- package/dist/components/ProgressBar/ProgressBar.types.d.ts +10 -0
- package/dist/components/ProgressBar/ProgressBar.types.d.ts.map +1 -1
- package/dist/components/Pulse/Pulse.d.ts +40 -0
- package/dist/components/Pulse/Pulse.d.ts.map +1 -0
- package/dist/components/Pulse/Pulse.js +64 -0
- package/dist/components/Pulse/Pulse.js.map +1 -0
- package/dist/components/Pulse/Pulse.mjs +62 -0
- package/dist/components/Pulse/Pulse.mjs.map +1 -0
- package/dist/components/Pulse/Pulse.styles.d.ts +35 -0
- package/dist/components/Pulse/Pulse.styles.d.ts.map +1 -0
- package/dist/components/Pulse/Pulse.styles.js +46 -0
- package/dist/components/Pulse/Pulse.styles.js.map +1 -0
- package/dist/components/Pulse/Pulse.styles.mjs +44 -0
- package/dist/components/Pulse/Pulse.styles.mjs.map +1 -0
- package/dist/components/Pulse/Pulse.types.d.ts +12 -0
- package/dist/components/Pulse/Pulse.types.d.ts.map +1 -0
- package/dist/components/Pulse/index.d.ts +3 -0
- package/dist/components/Pulse/index.d.ts.map +1 -0
- package/dist/components/RadialProgress/RadialProgress.js +1 -0
- package/dist/components/RadialProgress/RadialProgress.js.map +1 -1
- package/dist/components/RadialProgress/RadialProgress.mjs +1 -0
- package/dist/components/RadialProgress/RadialProgress.mjs.map +1 -1
- package/dist/components/Radio/Radio.styles.d.ts +13 -0
- package/dist/components/Radio/Radio.styles.d.ts.map +1 -0
- package/dist/components/Radio/Radio.styles.js +28 -0
- package/dist/components/Radio/Radio.styles.js.map +1 -0
- package/dist/components/Radio/Radio.styles.mjs +26 -0
- package/dist/components/Radio/Radio.styles.mjs.map +1 -0
- package/dist/components/Radio/RadioControl.d.ts.map +1 -1
- package/dist/components/Radio/RadioControl.js +19 -1
- package/dist/components/Radio/RadioControl.js.map +1 -1
- package/dist/components/Radio/RadioControl.mjs +20 -2
- package/dist/components/Radio/RadioControl.mjs.map +1 -1
- package/dist/components/Reveal/Reveal.d.ts +33 -0
- package/dist/components/Reveal/Reveal.d.ts.map +1 -0
- package/dist/components/Reveal/Reveal.js +46 -0
- package/dist/components/Reveal/Reveal.js.map +1 -0
- package/dist/components/Reveal/Reveal.mjs +44 -0
- package/dist/components/Reveal/Reveal.mjs.map +1 -0
- package/dist/components/Reveal/Reveal.styles.d.ts +25 -0
- package/dist/components/Reveal/Reveal.styles.d.ts.map +1 -0
- package/dist/components/Reveal/Reveal.styles.js +42 -0
- package/dist/components/Reveal/Reveal.styles.js.map +1 -0
- package/dist/components/Reveal/Reveal.styles.mjs +40 -0
- package/dist/components/Reveal/Reveal.styles.mjs.map +1 -0
- package/dist/components/Reveal/Reveal.types.d.ts +6 -0
- package/dist/components/Reveal/Reveal.types.d.ts.map +1 -0
- package/dist/components/Reveal/index.d.ts +3 -0
- package/dist/components/Reveal/index.d.ts.map +1 -0
- package/dist/components/SeeMoreButton/SeeMoreButton.d.ts +3 -10
- package/dist/components/SeeMoreButton/SeeMoreButton.d.ts.map +1 -1
- package/dist/components/SeeMoreButton/SeeMoreButton.js +6 -2
- package/dist/components/SeeMoreButton/SeeMoreButton.js.map +1 -1
- package/dist/components/SeeMoreButton/SeeMoreButton.mjs +7 -3
- package/dist/components/SeeMoreButton/SeeMoreButton.mjs.map +1 -1
- package/dist/components/SeeMoreButton/SeeMoreButton.types.d.ts +10 -3
- package/dist/components/SeeMoreButton/SeeMoreButton.types.d.ts.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.d.ts.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.js +5 -1
- package/dist/components/SegmentedControl/SegmentedControl.js.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.mjs +5 -1
- package/dist/components/SegmentedControl/SegmentedControl.mjs.map +1 -1
- package/dist/components/SegmentedControl/SegmentedControl.styles.d.ts +16 -0
- package/dist/components/SegmentedControl/SegmentedControl.styles.d.ts.map +1 -0
- package/dist/components/SegmentedControl/SegmentedControl.styles.js +26 -0
- package/dist/components/SegmentedControl/SegmentedControl.styles.js.map +1 -0
- package/dist/components/SegmentedControl/SegmentedControl.styles.mjs +24 -0
- package/dist/components/SegmentedControl/SegmentedControl.styles.mjs.map +1 -0
- package/dist/components/Select/Combobox.d.ts.map +1 -1
- package/dist/components/Select/Combobox.js +9 -2
- package/dist/components/Select/Combobox.js.map +1 -1
- package/dist/components/Select/Combobox.mjs +9 -2
- package/dist/components/Select/Combobox.mjs.map +1 -1
- package/dist/components/Select/ComboboxField.d.ts +1 -1
- package/dist/components/Select/ComboboxField.d.ts.map +1 -1
- package/dist/components/Select/ComboboxField.js +2 -2
- package/dist/components/Select/ComboboxField.js.map +1 -1
- package/dist/components/Select/ComboboxField.mjs +2 -2
- package/dist/components/Select/ComboboxField.mjs.map +1 -1
- package/dist/components/Select/Select.d.ts.map +1 -1
- package/dist/components/Select/Select.js +4 -1
- package/dist/components/Select/Select.js.map +1 -1
- package/dist/components/Select/Select.mjs +4 -1
- package/dist/components/Select/Select.mjs.map +1 -1
- package/dist/components/Select/Select.types.d.ts +26 -1
- package/dist/components/Select/Select.types.d.ts.map +1 -1
- package/dist/components/Select/SelectField.d.ts +1 -1
- package/dist/components/Select/SelectField.d.ts.map +1 -1
- package/dist/components/Select/SelectField.js +3 -2
- package/dist/components/Select/SelectField.js.map +1 -1
- package/dist/components/Select/SelectField.mjs +3 -2
- package/dist/components/Select/SelectField.mjs.map +1 -1
- package/dist/components/Shake/Shake.d.ts +35 -0
- package/dist/components/Shake/Shake.d.ts.map +1 -0
- package/dist/components/Shake/Shake.js +61 -0
- package/dist/components/Shake/Shake.js.map +1 -0
- package/dist/components/Shake/Shake.mjs +59 -0
- package/dist/components/Shake/Shake.mjs.map +1 -0
- package/dist/components/Shake/Shake.styles.d.ts +24 -0
- package/dist/components/Shake/Shake.styles.d.ts.map +1 -0
- package/dist/components/Shake/Shake.styles.js +35 -0
- package/dist/components/Shake/Shake.styles.js.map +1 -0
- package/dist/components/Shake/Shake.styles.mjs +33 -0
- package/dist/components/Shake/Shake.styles.mjs.map +1 -0
- package/dist/components/Shake/Shake.types.d.ts +11 -0
- package/dist/components/Shake/Shake.types.d.ts.map +1 -0
- package/dist/components/Shake/index.d.ts +3 -0
- package/dist/components/Shake/index.d.ts.map +1 -0
- package/dist/components/Slider/Slider.d.ts.map +1 -1
- package/dist/components/Slider/Slider.js +2 -2
- package/dist/components/Slider/Slider.js.map +1 -1
- package/dist/components/Slider/Slider.mjs +3 -3
- package/dist/components/Slider/Slider.mjs.map +1 -1
- package/dist/components/Slider/Slider.types.d.ts +15 -0
- package/dist/components/Slider/Slider.types.d.ts.map +1 -1
- package/dist/components/Spinner/Spinner.d.ts.map +1 -1
- package/dist/components/Spinner/Spinner.js +7 -2
- package/dist/components/Spinner/Spinner.js.map +1 -1
- package/dist/components/Spinner/Spinner.mjs +7 -2
- package/dist/components/Spinner/Spinner.mjs.map +1 -1
- package/dist/components/Spinner/Spinner.styles.d.ts +23 -0
- package/dist/components/Spinner/Spinner.styles.d.ts.map +1 -0
- package/dist/components/Spinner/Spinner.styles.js +36 -0
- package/dist/components/Spinner/Spinner.styles.js.map +1 -0
- package/dist/components/Spinner/Spinner.styles.mjs +34 -0
- package/dist/components/Spinner/Spinner.styles.mjs.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.d.ts +43 -0
- package/dist/components/SwapTransition/SwapTransition.d.ts.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.js +82 -0
- package/dist/components/SwapTransition/SwapTransition.js.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.mjs +80 -0
- package/dist/components/SwapTransition/SwapTransition.mjs.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.styles.d.ts +24 -0
- package/dist/components/SwapTransition/SwapTransition.styles.d.ts.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.styles.js +42 -0
- package/dist/components/SwapTransition/SwapTransition.styles.js.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.styles.mjs +38 -0
- package/dist/components/SwapTransition/SwapTransition.styles.mjs.map +1 -0
- package/dist/components/SwapTransition/SwapTransition.types.d.ts +22 -0
- package/dist/components/SwapTransition/SwapTransition.types.d.ts.map +1 -0
- package/dist/components/SwapTransition/index.d.ts +3 -0
- package/dist/components/SwapTransition/index.d.ts.map +1 -0
- package/dist/components/Switch/SwitchControl.d.ts.map +1 -1
- package/dist/components/Switch/SwitchControl.js +13 -1
- package/dist/components/Switch/SwitchControl.js.map +1 -1
- package/dist/components/Switch/SwitchControl.mjs +13 -1
- package/dist/components/Switch/SwitchControl.mjs.map +1 -1
- package/dist/components/Table/TableContext.d.ts +8 -0
- package/dist/components/Table/TableContext.d.ts.map +1 -1
- package/dist/components/Table/TableContext.js +79 -28
- package/dist/components/Table/TableContext.js.map +1 -1
- package/dist/components/Table/TableContext.mjs +80 -29
- package/dist/components/Table/TableContext.mjs.map +1 -1
- package/dist/components/Table/Td.d.ts.map +1 -1
- package/dist/components/Table/Td.js +12 -8
- package/dist/components/Table/Td.js.map +1 -1
- package/dist/components/Table/Td.mjs +13 -9
- package/dist/components/Table/Td.mjs.map +1 -1
- package/dist/components/Table/Th.d.ts.map +1 -1
- package/dist/components/Table/Th.js +12 -8
- package/dist/components/Table/Th.js.map +1 -1
- package/dist/components/Table/Th.mjs +13 -9
- package/dist/components/Table/Th.mjs.map +1 -1
- package/dist/components/Table/useRegisterStickyWidth.d.ts +48 -0
- package/dist/components/Table/useRegisterStickyWidth.d.ts.map +1 -0
- package/dist/components/Table/useRegisterStickyWidth.js +54 -0
- package/dist/components/Table/useRegisterStickyWidth.js.map +1 -0
- package/dist/components/Table/useRegisterStickyWidth.mjs +52 -0
- package/dist/components/Table/useRegisterStickyWidth.mjs.map +1 -0
- package/dist/components/Tabs/Tab/Tab.styles.d.ts +36 -3
- package/dist/components/Tabs/Tab/Tab.styles.d.ts.map +1 -1
- package/dist/components/Tabs/Tab/Tab.styles.js +48 -5
- package/dist/components/Tabs/Tab/Tab.styles.js.map +1 -1
- package/dist/components/Tabs/Tab/Tab.styles.mjs +48 -6
- package/dist/components/Tabs/Tab/Tab.styles.mjs.map +1 -1
- package/dist/components/Tabs/Tab/index.d.ts +1 -0
- package/dist/components/Tabs/Tab/index.d.ts.map +1 -1
- package/dist/components/Tabs/index.d.ts +1 -1
- package/dist/components/Tabs/index.d.ts.map +1 -1
- package/dist/components/Tag/Tag.d.ts +3 -21
- package/dist/components/Tag/Tag.d.ts.map +1 -1
- package/dist/components/Tag/Tag.js +6 -3
- package/dist/components/Tag/Tag.js.map +1 -1
- package/dist/components/Tag/Tag.mjs +6 -3
- package/dist/components/Tag/Tag.mjs.map +1 -1
- package/dist/components/Tag/Tag.styles.d.ts.map +1 -1
- package/dist/components/Tag/Tag.styles.js +27 -21
- package/dist/components/Tag/Tag.styles.js.map +1 -1
- package/dist/components/Tag/Tag.styles.mjs +27 -21
- package/dist/components/Tag/Tag.styles.mjs.map +1 -1
- package/dist/components/Tag/Tag.types.d.ts +9 -2
- package/dist/components/Tag/Tag.types.d.ts.map +1 -1
- package/dist/components/Tag/index.d.ts +1 -1
- package/dist/components/Tag/index.d.ts.map +1 -1
- package/dist/components/Textarea/Textarea.d.ts.map +1 -1
- package/dist/components/Textarea/Textarea.js +2 -1
- package/dist/components/Textarea/Textarea.js.map +1 -1
- package/dist/components/Textarea/Textarea.mjs +2 -1
- package/dist/components/Textarea/Textarea.mjs.map +1 -1
- package/dist/components/Toast/Toast.d.ts +7 -3
- package/dist/components/Toast/Toast.d.ts.map +1 -1
- package/dist/components/Toast/Toast.js +7 -3
- package/dist/components/Toast/Toast.js.map +1 -1
- package/dist/components/Toast/Toast.mjs +8 -4
- package/dist/components/Toast/Toast.mjs.map +1 -1
- package/dist/components/Toast/Toast.styles.d.ts +8 -0
- package/dist/components/Toast/Toast.styles.d.ts.map +1 -1
- package/dist/components/Toast/Toast.styles.js +59 -0
- package/dist/components/Toast/Toast.styles.js.map +1 -1
- package/dist/components/Toast/Toast.styles.mjs +57 -1
- package/dist/components/Toast/Toast.styles.mjs.map +1 -1
- package/dist/components/Toast/Toast.types.d.ts +25 -1
- package/dist/components/Toast/Toast.types.d.ts.map +1 -1
- package/dist/components/Toast/ToastIcon/ToastIcon.js +4 -4
- package/dist/components/Toast/ToastIcon/ToastIcon.js.map +1 -1
- package/dist/components/Toast/ToastIcon/ToastIcon.mjs +5 -5
- package/dist/components/Toast/ToastIcon/ToastIcon.mjs.map +1 -1
- package/dist/components/Toast/Toaster.d.ts.map +1 -1
- package/dist/components/Toast/Toaster.js +9 -1
- package/dist/components/Toast/Toaster.js.map +1 -1
- package/dist/components/Toast/Toaster.mjs +9 -1
- package/dist/components/Toast/Toaster.mjs.map +1 -1
- package/dist/components/Toast/useToast.d.ts +2 -2
- package/dist/components/Toast/useToast.d.ts.map +1 -1
- package/dist/components/Toast/useToast.js +9 -1
- package/dist/components/Toast/useToast.js.map +1 -1
- package/dist/components/Toast/useToast.mjs +10 -2
- package/dist/components/Toast/useToast.mjs.map +1 -1
- package/dist/components/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/components/Tooltip/Tooltip.js +15 -1
- package/dist/components/Tooltip/Tooltip.js.map +1 -1
- package/dist/components/Tooltip/Tooltip.mjs +15 -1
- package/dist/components/Tooltip/Tooltip.mjs.map +1 -1
- package/dist/components/Tree/TreeBranchIndicator.js +1 -1
- package/dist/components/Tree/TreeBranchIndicator.js.map +1 -1
- package/dist/components/Tree/TreeBranchIndicator.mjs +2 -2
- package/dist/components/Tree/TreeBranchIndicator.mjs.map +1 -1
- package/dist/components/Typography/Caption.d.ts +4 -0
- package/dist/components/Typography/Caption.d.ts.map +1 -0
- package/dist/components/Typography/Caption.js +33 -0
- package/dist/components/Typography/Caption.js.map +1 -0
- package/dist/components/Typography/Caption.mjs +31 -0
- package/dist/components/Typography/Caption.mjs.map +1 -0
- package/dist/components/Typography/H1.d.ts +3 -2
- package/dist/components/Typography/H1.d.ts.map +1 -1
- package/dist/components/Typography/H1.js +6 -3
- package/dist/components/Typography/H1.js.map +1 -1
- package/dist/components/Typography/H1.mjs +6 -3
- package/dist/components/Typography/H1.mjs.map +1 -1
- package/dist/components/Typography/H2.d.ts +3 -2
- package/dist/components/Typography/H2.d.ts.map +1 -1
- package/dist/components/Typography/H2.js +6 -3
- package/dist/components/Typography/H2.js.map +1 -1
- package/dist/components/Typography/H2.mjs +6 -3
- package/dist/components/Typography/H2.mjs.map +1 -1
- package/dist/components/Typography/H3.d.ts +3 -2
- package/dist/components/Typography/H3.d.ts.map +1 -1
- package/dist/components/Typography/H3.js +6 -3
- package/dist/components/Typography/H3.js.map +1 -1
- package/dist/components/Typography/H3.mjs +6 -3
- package/dist/components/Typography/H3.mjs.map +1 -1
- package/dist/components/Typography/H4.d.ts +3 -2
- package/dist/components/Typography/H4.d.ts.map +1 -1
- package/dist/components/Typography/H4.js +6 -3
- package/dist/components/Typography/H4.js.map +1 -1
- package/dist/components/Typography/H4.mjs +6 -3
- package/dist/components/Typography/H4.mjs.map +1 -1
- package/dist/components/Typography/H5.d.ts +3 -2
- package/dist/components/Typography/H5.d.ts.map +1 -1
- package/dist/components/Typography/H5.js +6 -3
- package/dist/components/Typography/H5.js.map +1 -1
- package/dist/components/Typography/H5.mjs +6 -3
- package/dist/components/Typography/H5.mjs.map +1 -1
- package/dist/components/Typography/Link.d.ts +39 -3
- package/dist/components/Typography/Link.d.ts.map +1 -1
- package/dist/components/Typography/Link.js +55 -10
- package/dist/components/Typography/Link.js.map +1 -1
- package/dist/components/Typography/Link.mjs +55 -11
- package/dist/components/Typography/Link.mjs.map +1 -1
- package/dist/components/Typography/Overline.d.ts +3 -13
- package/dist/components/Typography/Overline.d.ts.map +1 -1
- package/dist/components/Typography/Overline.js +5 -2
- package/dist/components/Typography/Overline.js.map +1 -1
- package/dist/components/Typography/Overline.mjs +5 -2
- package/dist/components/Typography/Overline.mjs.map +1 -1
- package/dist/components/Typography/Subtext.d.ts +3 -3
- package/dist/components/Typography/Subtext.d.ts.map +1 -1
- package/dist/components/Typography/Subtext.js +5 -2
- package/dist/components/Typography/Subtext.js.map +1 -1
- package/dist/components/Typography/Subtext.mjs +5 -2
- package/dist/components/Typography/Subtext.mjs.map +1 -1
- package/dist/components/Typography/Subtitle.d.ts +3 -2
- package/dist/components/Typography/Subtitle.d.ts.map +1 -1
- package/dist/components/Typography/Subtitle.js +23 -3
- package/dist/components/Typography/Subtitle.js.map +1 -1
- package/dist/components/Typography/Subtitle.mjs +23 -3
- package/dist/components/Typography/Subtitle.mjs.map +1 -1
- package/dist/components/Typography/Text.d.ts +3 -3
- package/dist/components/Typography/Text.d.ts.map +1 -1
- package/dist/components/Typography/Text.js +5 -2
- package/dist/components/Typography/Text.js.map +1 -1
- package/dist/components/Typography/Text.mjs +5 -2
- package/dist/components/Typography/Text.mjs.map +1 -1
- package/dist/components/Typography/Typography.types.d.ts +35 -2
- package/dist/components/Typography/Typography.types.d.ts.map +1 -1
- package/dist/components/Typography/index.d.ts +4 -3
- package/dist/components/Typography/index.d.ts.map +1 -1
- package/dist/components/Workflow/Workflow.d.ts +1 -1
- package/dist/components/Workflow/Workflow.d.ts.map +1 -1
- package/dist/components/Workflow/Workflow.js +2 -2
- package/dist/components/Workflow/Workflow.js.map +1 -1
- package/dist/components/Workflow/Workflow.mjs +2 -2
- package/dist/components/Workflow/Workflow.mjs.map +1 -1
- package/dist/components/Workflow/Workflow.types.d.ts +9 -0
- package/dist/components/Workflow/Workflow.types.d.ts.map +1 -1
- package/dist/components/Workflow/Workflow.types.js.map +1 -1
- package/dist/components/Workflow/Workflow.types.mjs.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/BranchLabelBadge.js +1 -1
- package/dist/components/Workflow/canvas/Canvas/BranchLabelBadge.js.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/BranchLabelBadge.mjs +2 -2
- package/dist/components/Workflow/canvas/Canvas/BranchLabelBadge.mjs.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/Canvas.d.ts +6 -2
- package/dist/components/Workflow/canvas/Canvas/Canvas.d.ts.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/Canvas.js +29 -23
- package/dist/components/Workflow/canvas/Canvas/Canvas.js.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/Canvas.mjs +31 -25
- package/dist/components/Workflow/canvas/Canvas/Canvas.mjs.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/CanvasControls.js +1 -1
- package/dist/components/Workflow/canvas/Canvas/CanvasControls.js.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/CanvasControls.mjs +2 -2
- package/dist/components/Workflow/canvas/Canvas/CanvasControls.mjs.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/LabeledEdge.js +2 -1
- package/dist/components/Workflow/canvas/Canvas/LabeledEdge.js.map +1 -1
- package/dist/components/Workflow/canvas/Canvas/LabeledEdge.mjs +3 -2
- package/dist/components/Workflow/canvas/Canvas/LabeledEdge.mjs.map +1 -1
- package/dist/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.d.ts.map +1 -1
- package/dist/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.js +2 -1
- package/dist/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.js.map +1 -1
- package/dist/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.mjs +3 -2
- package/dist/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.mjs.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerHeader.js +3 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerHeader.js.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerHeader.mjs +4 -2
- package/dist/components/Workflow/canvas/DrawerShell/DrawerHeader.mjs.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerIssues.js +2 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerIssues.js.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerIssues.mjs +3 -2
- package/dist/components/Workflow/canvas/DrawerShell/DrawerIssues.mjs.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerShell.js +3 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerShell.js.map +1 -1
- package/dist/components/Workflow/canvas/DrawerShell/DrawerShell.mjs +4 -2
- package/dist/components/Workflow/canvas/DrawerShell/DrawerShell.mjs.map +1 -1
- package/dist/components/Workflow/canvas/EdgeInspector/BuiltInEdgeInspector.js +1 -0
- package/dist/components/Workflow/canvas/EdgeInspector/BuiltInEdgeInspector.js.map +1 -1
- package/dist/components/Workflow/canvas/EdgeInspector/BuiltInEdgeInspector.mjs +1 -0
- package/dist/components/Workflow/canvas/EdgeInspector/BuiltInEdgeInspector.mjs.map +1 -1
- package/dist/components/Workflow/canvas/FieldWrapper/FieldWrapper.js +2 -1
- package/dist/components/Workflow/canvas/FieldWrapper/FieldWrapper.js.map +1 -1
- package/dist/components/Workflow/canvas/FieldWrapper/FieldWrapper.mjs +3 -2
- package/dist/components/Workflow/canvas/FieldWrapper/FieldWrapper.mjs.map +1 -1
- package/dist/components/Workflow/canvas/GenericNode/GenericNode.js +1 -1
- package/dist/components/Workflow/canvas/GenericNode/GenericNode.js.map +1 -1
- package/dist/components/Workflow/canvas/GenericNode/GenericNode.mjs +2 -2
- package/dist/components/Workflow/canvas/GenericNode/GenericNode.mjs.map +1 -1
- package/dist/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.d.ts.map +1 -1
- package/dist/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.js +2 -1
- package/dist/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.js.map +1 -1
- package/dist/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.mjs +3 -2
- package/dist/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.mjs.map +1 -1
- package/dist/components/Workflow/canvas/IssueList/IssueList.js +1 -0
- package/dist/components/Workflow/canvas/IssueList/IssueList.js.map +1 -1
- package/dist/components/Workflow/canvas/IssueList/IssueList.mjs +1 -0
- package/dist/components/Workflow/canvas/IssueList/IssueList.mjs.map +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePalette.d.ts.map +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePalette.js +21 -3
- package/dist/components/Workflow/canvas/NodePalette/NodePalette.js.map +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePalette.mjs +22 -4
- package/dist/components/Workflow/canvas/NodePalette/NodePalette.mjs.map +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePaletteToggle.js +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePaletteToggle.js.map +1 -1
- package/dist/components/Workflow/canvas/NodePalette/NodePaletteToggle.mjs +2 -2
- package/dist/components/Workflow/canvas/NodePalette/NodePaletteToggle.mjs.map +1 -1
- package/dist/components/Workflow/canvas/NodeShell/NodeShell.js +4 -3
- package/dist/components/Workflow/canvas/NodeShell/NodeShell.js.map +1 -1
- package/dist/components/Workflow/canvas/NodeShell/NodeShell.mjs +5 -4
- package/dist/components/Workflow/canvas/NodeShell/NodeShell.mjs.map +1 -1
- package/dist/components/Workflow/createNode.d.ts +25 -1
- package/dist/components/Workflow/createNode.d.ts.map +1 -1
- package/dist/components/Workflow/createNode.js +39 -1
- package/dist/components/Workflow/createNode.js.map +1 -1
- package/dist/components/Workflow/createNode.mjs +38 -2
- package/dist/components/Workflow/createNode.mjs.map +1 -1
- package/dist/components/Workflow/index.d.ts +2 -0
- package/dist/components/Workflow/index.d.ts.map +1 -1
- package/dist/components/Workflow/layout/autoLayout.d.ts +10 -0
- package/dist/components/Workflow/layout/autoLayout.d.ts.map +1 -1
- package/dist/components/Workflow/layout/autoLayout.js +4 -0
- package/dist/components/Workflow/layout/autoLayout.js.map +1 -1
- package/dist/components/Workflow/layout/autoLayout.mjs +1 -1
- package/dist/components/Workflow/layout/autoLayout.mjs.map +1 -1
- package/dist/components/Workflow/placement.d.ts +65 -0
- package/dist/components/Workflow/placement.d.ts.map +1 -0
- package/dist/components/Workflow/placement.js +100 -0
- package/dist/components/Workflow/placement.js.map +1 -0
- package/dist/components/Workflow/placement.mjs +96 -0
- package/dist/components/Workflow/placement.mjs.map +1 -0
- package/dist/components/Workflow/useWorkflowActions.d.ts +54 -0
- package/dist/components/Workflow/useWorkflowActions.d.ts.map +1 -0
- package/dist/components/Workflow/useWorkflowActions.js +105 -0
- package/dist/components/Workflow/useWorkflowActions.js.map +1 -0
- package/dist/components/Workflow/useWorkflowActions.mjs +103 -0
- package/dist/components/Workflow/useWorkflowActions.mjs.map +1 -0
- package/dist/icons.js +203 -0
- package/dist/icons.js.map +1 -1
- package/dist/icons.mjs +1 -1
- package/dist/index.d.ts +18 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +81 -0
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +36 -2
- package/dist/index.mjs.map +1 -1
- package/dist/styles.d.ts +21 -0
- package/dist/styles.d.ts.map +1 -0
- package/dist/styles.js +9 -0
- package/dist/styles.js.map +1 -0
- package/dist/styles.mjs +3 -0
- package/dist/styles.mjs.map +1 -0
- package/dist/theme/colors.d.ts +168 -49
- package/dist/theme/colors.d.ts.map +1 -1
- package/dist/theme/colors.js +150 -82
- package/dist/theme/colors.js.map +1 -1
- package/dist/theme/colors.mjs +150 -82
- package/dist/theme/colors.mjs.map +1 -1
- package/dist/theme/formControls.d.ts +56 -0
- package/dist/theme/formControls.d.ts.map +1 -0
- package/dist/theme/formControls.js +62 -0
- package/dist/theme/formControls.js.map +1 -0
- package/dist/theme/formControls.mjs +60 -0
- package/dist/theme/formControls.mjs.map +1 -0
- package/dist/theme/index.d.ts.map +1 -1
- package/dist/theme/index.js +77 -4
- package/dist/theme/index.js.map +1 -1
- package/dist/theme/index.mjs +78 -5
- package/dist/theme/index.mjs.map +1 -1
- package/dist/theme/motion.d.ts +648 -0
- package/dist/theme/motion.d.ts.map +1 -0
- package/dist/theme/motion.js +629 -0
- package/dist/theme/motion.js.map +1 -0
- package/dist/theme/motion.mjs +617 -0
- package/dist/theme/motion.mjs.map +1 -0
- package/dist/theme/recipes/accordion.d.ts +12 -0
- package/dist/theme/recipes/accordion.d.ts.map +1 -0
- package/dist/theme/recipes/accordion.js +25 -0
- package/dist/theme/recipes/accordion.js.map +1 -0
- package/dist/theme/recipes/accordion.mjs +23 -0
- package/dist/theme/recipes/accordion.mjs.map +1 -0
- package/dist/translations/Defaults.translations.json.js +10 -1
- package/dist/translations/Defaults.translations.json.js.map +1 -1
- package/dist/translations/Defaults.translations.json.mjs +10 -2
- package/dist/translations/Defaults.translations.json.mjs.map +1 -1
- package/dist/types/polymorphic.d.ts +101 -0
- package/dist/types/polymorphic.d.ts.map +1 -0
- package/dist/types/polymorphic.js +57 -0
- package/dist/types/polymorphic.js.map +1 -0
- package/dist/types/polymorphic.mjs +55 -0
- package/dist/types/polymorphic.mjs.map +1 -0
- package/dist/utils/cubicBezier.d.ts +30 -0
- package/dist/utils/cubicBezier.d.ts.map +1 -0
- package/dist/utils/cubicBezier.js +67 -0
- package/dist/utils/cubicBezier.js.map +1 -0
- package/dist/utils/cubicBezier.mjs +65 -0
- package/dist/utils/cubicBezier.mjs.map +1 -0
- package/dist/utils/focusRing.d.ts +7 -6
- package/dist/utils/focusRing.d.ts.map +1 -1
- package/dist/utils/focusRing.js +7 -4
- package/dist/utils/focusRing.js.map +1 -1
- package/dist/utils/focusRing.mjs +7 -4
- package/dist/utils/focusRing.mjs.map +1 -1
- package/dist/utils/mergeCss.js +2 -2
- package/dist/utils/mergeCss.js.map +1 -1
- package/dist/utils/mergeCss.mjs +1 -1
- package/dist/utils/staggerProps.d.ts +52 -0
- package/dist/utils/staggerProps.d.ts.map +1 -0
- package/dist/utils/staggerProps.js +62 -0
- package/dist/utils/staggerProps.js.map +1 -0
- package/dist/utils/staggerProps.mjs +59 -0
- package/dist/utils/staggerProps.mjs.map +1 -0
- package/package.json +9 -2
- package/src/components/Accordion/Accordion.presence.test.tsx +54 -0
- package/src/components/Appear/Appear.stories.tsx +219 -0
- package/src/components/Appear/Appear.styles.ts +28 -0
- package/src/components/Appear/Appear.tsx +85 -0
- package/src/components/Appear/Appear.types.ts +18 -0
- package/src/components/Appear/index.ts +2 -0
- package/src/components/Badge/Badge.tsx +8 -4
- package/src/components/Badge/Badge.types.ts +19 -2
- package/src/components/Badge/index.ts +1 -1
- package/src/components/Banner/Banner.tsx +1 -1
- package/src/components/BottomSheet/BottomSheet.stories.tsx +205 -0
- package/src/components/BottomSheet/BottomSheet.styles.ts +162 -0
- package/src/components/BottomSheet/BottomSheet.test.tsx +129 -0
- package/src/components/BottomSheet/BottomSheet.tsx +47 -0
- package/src/components/BottomSheet/BottomSheet.types.ts +50 -0
- package/src/components/BottomSheet/BottomSheetBody.tsx +15 -0
- package/src/components/BottomSheet/BottomSheetCloseButton.tsx +40 -0
- package/src/components/BottomSheet/BottomSheetContent.tsx +43 -0
- package/src/components/BottomSheet/BottomSheetContext.ts +79 -0
- package/src/components/BottomSheet/BottomSheetFooter.tsx +12 -0
- package/src/components/BottomSheet/BottomSheetHeader.tsx +22 -0
- package/src/components/BottomSheet/BottomSheetOverlay.tsx +16 -0
- package/src/components/BottomSheet/index.tsx +22 -0
- package/src/components/Button/Button.cursor.test.tsx +60 -0
- package/src/components/Button/Button.lift.test.tsx +150 -0
- package/src/components/Button/Button.press.test.tsx +54 -0
- package/src/components/Button/Button.stories.tsx +80 -1
- package/src/components/Button/Button.styles.ts +124 -42
- package/src/components/Button/Button.tsx +88 -9
- package/src/components/Button/Button.types.ts +47 -2
- package/src/components/Button/index.tsx +1 -0
- package/src/components/Card/Card.stories.tsx +33 -3
- package/src/components/Card/Card.styles.ts +37 -5
- package/src/components/Card/Card.tsx +13 -6
- package/src/components/Card/Card.types.ts +26 -2
- package/src/components/Card/index.ts +1 -1
- package/src/components/Checkbox/Checkbox.styles.ts +26 -0
- package/src/components/Checkbox/CheckboxControl.tsx +10 -1
- package/src/components/Chip/Chip.tsx +8 -4
- package/src/components/Chip/Chip.types.ts +19 -4
- package/src/components/Chip/index.ts +6 -1
- package/src/components/Collapsible/Collapsible.presence.test.tsx +83 -0
- package/src/components/Collapsible/CollapsibleContent.tsx +13 -1
- package/src/components/ColorMode/ColorModeToggle.tsx +33 -2
- package/src/components/Confetti/Confetti.stories.tsx +88 -0
- package/src/components/Confetti/Confetti.styles.ts +57 -0
- package/src/components/Confetti/Confetti.tsx +182 -0
- package/src/components/Confetti/Confetti.types.ts +13 -0
- package/src/components/Confetti/index.ts +2 -0
- package/src/components/Container/Container.tsx +10 -3
- package/src/components/Container/Container.types.ts +20 -0
- package/src/components/Container/index.ts +1 -0
- package/src/components/CopyableCode/CopyableCode.tsx +99 -4
- package/src/components/CountUp/CountUp.stories.tsx +127 -0
- package/src/components/CountUp/CountUp.tsx +122 -0
- package/src/components/CountUp/CountUp.types.ts +19 -0
- package/src/components/CountUp/index.ts +2 -0
- package/src/components/ErrorFallback/ErrorFallback.tsx +32 -3
- package/src/components/ExpandableText/ExpandableText.stories.tsx +7 -7
- package/src/components/ExpandableText/ExpandableText.tsx +41 -7
- package/src/components/ExpandableText/useExpandableText.ts +90 -103
- package/src/components/FileInput/FileInput.tsx +17 -5
- package/src/components/FileItem/FileItem.tsx +10 -10
- package/src/components/FileList/FileList.tsx +15 -4
- package/src/components/FileList/FileList.types.ts +9 -0
- package/src/components/FlyTo/FlyTo.stories.tsx +157 -0
- package/src/components/FlyTo/FlyTo.styles.ts +31 -0
- package/src/components/FlyTo/FlyTo.tsx +88 -0
- package/src/components/FlyTo/FlyTo.types.ts +15 -0
- package/src/components/FlyTo/index.ts +2 -0
- package/src/components/Form/FieldError/FieldError.test.tsx +33 -0
- package/src/components/Form/FieldError/FieldError.tsx +20 -0
- package/src/components/Form/FieldError/index.ts +2 -0
- package/src/components/Form/FieldHelp/FieldHelp.tsx +18 -0
- package/src/components/Form/FieldHelp/index.ts +2 -0
- package/src/components/Form/FieldLabel/FieldLabel.tsx +46 -0
- package/src/components/Form/FieldLabel/FieldLabel.types.ts +21 -0
- package/src/components/Form/FieldLabel/index.ts +2 -0
- package/src/components/Form/FieldRow/FieldRow.stories.tsx +85 -0
- package/src/components/Form/FieldRow/FieldRow.test.tsx +89 -0
- package/src/components/Form/FieldRow/FieldRow.tsx +46 -0
- package/src/components/Form/FieldRow/FieldRow.types.ts +32 -0
- package/src/components/Form/FieldRow/index.ts +2 -0
- package/src/components/Form/FormFooter/FormFooter.stories.tsx +70 -0
- package/src/components/Form/FormFooter/FormFooter.test.tsx +67 -0
- package/src/components/Form/FormFooter/FormFooter.tsx +46 -0
- package/src/components/Form/FormFooter/FormFooter.types.ts +23 -0
- package/src/components/Form/FormFooter/index.ts +2 -0
- package/src/components/Form/FormModalFooter/FormModalFooter.stories.tsx +64 -0
- package/src/components/Form/FormModalFooter/FormModalFooter.test.tsx +155 -0
- package/src/components/Form/FormModalFooter/FormModalFooter.tsx +83 -0
- package/src/components/Form/FormModalFooter/FormModalFooter.types.ts +53 -0
- package/src/components/Form/FormModalFooter/index.ts +2 -0
- package/src/components/Form/FormScrollArea/FormScrollArea.tsx +27 -0
- package/src/components/Form/FormScrollArea/index.ts +1 -0
- package/src/components/Form/FormSection/CollapsibleFormSection.tsx +35 -0
- package/src/components/Form/FormSection/FlatFormSection.tsx +41 -0
- package/src/components/Form/FormSection/FormSection.stories.tsx +115 -0
- package/src/components/Form/FormSection/FormSection.test.tsx +89 -0
- package/src/components/Form/FormSection/FormSection.tsx +33 -0
- package/src/components/Form/FormSection/FormSection.types.ts +34 -0
- package/src/components/Form/FormSection/index.ts +2 -0
- package/src/components/Form/FormSectionHeader/FormSectionHeader.stories.tsx +53 -0
- package/src/components/Form/FormSectionHeader/FormSectionHeader.test.tsx +74 -0
- package/src/components/Form/FormSectionHeader/FormSectionHeader.tsx +48 -0
- package/src/components/Form/FormSectionHeader/FormSectionHeader.types.ts +17 -0
- package/src/components/Form/FormSectionHeader/index.ts +2 -0
- package/src/components/Form/index.ts +17 -0
- package/src/components/Icon/ICON_MANAGEMENT.md +1 -0
- package/src/components/Icon/Icon.stories.tsx +6 -2
- package/src/components/Icon/_constants/iconList.ts +523 -299
- package/src/components/Icon/_utils/createIcon.tsx +1 -0
- package/src/components/Icon/index.tsx +210 -27
- package/src/components/IconButton/IconButton.tsx +14 -3
- package/src/components/IconButton/IconButton.types.ts +19 -2
- package/src/components/IconButton/index.tsx +1 -0
- package/src/components/InfoSprinkle/InfoSprinkle.tsx +0 -1
- package/src/components/InlineCode/InlineCode.tsx +9 -2
- package/src/components/Input/Input.stories.tsx +5 -5
- package/src/components/Input/Input.tsx +2 -0
- package/src/components/Loaders/PageLoader.tsx +5 -2
- package/src/components/Loaders/SectionLoader.tsx +2 -1
- package/src/components/Markdown/Markdown.tsx +6 -1
- package/src/components/Menu/MenuItem.tsx +11 -3
- package/src/components/Menu/MenuItem.types.ts +23 -2
- package/src/components/Menu/MenuList.tsx +35 -3
- package/src/components/Modal/Modal.stories.tsx +7 -6
- package/src/components/Modal/Modal.styles.ts +19 -0
- package/src/components/Modal/Modal.tsx +8 -2
- package/src/components/Modal/Modal.types.ts +10 -2
- package/src/components/Modal/ModalContent/ModalContent.tsx +10 -1
- package/src/components/Modal/ModalContext.ts +1 -1
- package/src/components/Modal/ModalOverlay.tsx +9 -1
- package/src/components/Pagination/Pagination.tsx +8 -3
- package/src/components/PasswordInput/PasswordInput.tsx +3 -2
- package/src/components/PinInput/PinInput.stories.tsx +36 -9
- package/src/components/PinInput/PinInput.tsx +54 -45
- package/src/components/PinInput/PinInput.types.ts +17 -25
- package/src/components/Popover/PopoverContent.tsx +3 -0
- package/src/components/ProgressBar/ProgressBar.indeterminate.test.tsx +55 -0
- package/src/components/ProgressBar/ProgressBar.styles.ts +26 -0
- package/src/components/ProgressBar/ProgressBar.tsx +34 -7
- package/src/components/ProgressBar/ProgressBar.types.ts +10 -0
- package/src/components/Pulse/Pulse.remount.test.tsx +179 -0
- package/src/components/Pulse/Pulse.stories.tsx +74 -0
- package/src/components/Pulse/Pulse.styles.ts +42 -0
- package/src/components/Pulse/Pulse.tsx +82 -0
- package/src/components/Pulse/Pulse.types.ts +12 -0
- package/src/components/Pulse/index.ts +2 -0
- package/src/components/Radio/Radio.stories.tsx +34 -22
- package/src/components/Radio/Radio.styles.ts +24 -0
- package/src/components/Radio/RadioControl.tsx +33 -6
- package/src/components/Reveal/Reveal.stories.tsx +61 -0
- package/src/components/Reveal/Reveal.styles.ts +38 -0
- package/src/components/Reveal/Reveal.test.tsx +80 -0
- package/src/components/Reveal/Reveal.tsx +62 -0
- package/src/components/Reveal/Reveal.types.ts +6 -0
- package/src/components/Reveal/index.ts +2 -0
- package/src/components/SeeMoreButton/SeeMoreButton.tsx +12 -5
- package/src/components/SeeMoreButton/SeeMoreButton.types.ts +14 -3
- package/src/components/SegmentedControl/SegmentedControl.styles.ts +22 -0
- package/src/components/SegmentedControl/SegmentedControl.timing.test.tsx +81 -0
- package/src/components/SegmentedControl/SegmentedControl.tsx +7 -1
- package/src/components/Select/Combobox.tsx +7 -1
- package/src/components/Select/ComboboxField.tsx +11 -1
- package/src/components/Select/Comparison.stories.tsx +19 -0
- package/src/components/Select/Select.tsx +3 -0
- package/src/components/Select/Select.types.ts +26 -1
- package/src/components/Select/SelectField.tsx +23 -3
- package/src/components/Shake/Shake.stories.tsx +155 -0
- package/src/components/Shake/Shake.styles.ts +31 -0
- package/src/components/Shake/Shake.tsx +79 -0
- package/src/components/Shake/Shake.types.ts +11 -0
- package/src/components/Shake/index.ts +2 -0
- package/src/components/Slider/Slider.tsx +16 -1
- package/src/components/Slider/Slider.types.ts +15 -0
- package/src/components/Spinner/Spinner.styles.ts +32 -0
- package/src/components/Spinner/Spinner.tsx +9 -2
- package/src/components/SwapTransition/SwapTransition.stories.tsx +229 -0
- package/src/components/SwapTransition/SwapTransition.styles.ts +38 -0
- package/src/components/SwapTransition/SwapTransition.test.tsx +127 -0
- package/src/components/SwapTransition/SwapTransition.tsx +130 -0
- package/src/components/SwapTransition/SwapTransition.types.ts +22 -0
- package/src/components/SwapTransition/index.ts +2 -0
- package/src/components/Switch/SwitchControl.tsx +11 -1
- package/src/components/Table/Table.stories.tsx +253 -0
- package/src/components/Table/TableContext.tsx +101 -35
- package/src/components/Table/Td.tsx +13 -8
- package/src/components/Table/Th.tsx +13 -8
- package/src/components/Table/contextStability.test.tsx +140 -0
- package/src/components/Table/stickyWidth.test.tsx +138 -0
- package/src/components/Table/useRegisterStickyWidth.ts +83 -0
- package/src/components/Tabs/Tab/Tab.styles.ts +48 -5
- package/src/components/Tabs/Tab/index.ts +1 -0
- package/src/components/Tabs/index.tsx +1 -1
- package/src/components/Tag/Tag.styles.ts +27 -21
- package/src/components/Tag/Tag.tsx +14 -4
- package/src/components/Tag/Tag.types.ts +17 -4
- package/src/components/Tag/index.ts +6 -1
- package/src/components/Textarea/Textarea.tsx +2 -0
- package/src/components/Toast/Toast.action.test.tsx +135 -0
- package/src/components/Toast/Toast.stories.tsx +111 -0
- package/src/components/Toast/Toast.styles.ts +60 -0
- package/src/components/Toast/Toast.tsx +16 -3
- package/src/components/Toast/Toast.types.ts +26 -1
- package/src/components/Toast/ToastIcon/ToastIcon.tsx +8 -8
- package/src/components/Toast/Toaster.tsx +11 -0
- package/src/components/Toast/useToast.tsx +17 -2
- package/src/components/Tooltip/Tooltip.instant.test.tsx +43 -0
- package/src/components/Tooltip/Tooltip.tsx +15 -1
- package/src/components/Tree/TreeBranchIndicator.tsx +4 -4
- package/src/components/Typography/Caption.tsx +41 -0
- package/src/components/Typography/H1.tsx +10 -3
- package/src/components/Typography/H2.tsx +10 -3
- package/src/components/Typography/H3.tsx +10 -4
- package/src/components/Typography/H4.tsx +10 -3
- package/src/components/Typography/H5.tsx +10 -3
- package/src/components/Typography/Link.tsx +71 -12
- package/src/components/Typography/Overline.tsx +9 -3
- package/src/components/Typography/Subtext.tsx +9 -3
- package/src/components/Typography/Subtitle.tsx +26 -4
- package/src/components/Typography/Text.tsx +9 -3
- package/src/components/Typography/Typography.stories.tsx +69 -1
- package/src/components/Typography/Typography.types.ts +47 -2
- package/src/components/Typography/index.ts +9 -2
- package/src/components/Workflow/README.md +64 -0
- package/src/components/Workflow/Workflow.tsx +2 -0
- package/src/components/Workflow/Workflow.types.ts +10 -0
- package/src/components/Workflow/canvas/Canvas/BranchLabelBadge.tsx +3 -3
- package/src/components/Workflow/canvas/Canvas/Canvas.tsx +57 -53
- package/src/components/Workflow/canvas/Canvas/CanvasControls.tsx +15 -15
- package/src/components/Workflow/canvas/Canvas/LabeledEdge.tsx +2 -2
- package/src/components/Workflow/canvas/CollapsibleSection/CollapsibleSection.tsx +8 -4
- package/src/components/Workflow/canvas/DrawerShell/DrawerHeader.tsx +3 -3
- package/src/components/Workflow/canvas/DrawerShell/DrawerIssues.tsx +2 -2
- package/src/components/Workflow/canvas/DrawerShell/DrawerShell.tsx +2 -2
- package/src/components/Workflow/canvas/FieldWrapper/FieldWrapper.tsx +3 -3
- package/src/components/Workflow/canvas/GenericNode/GenericNode.tsx +2 -2
- package/src/components/Workflow/canvas/GraphErrorBanner/GraphErrorBanner.tsx +8 -5
- package/src/components/Workflow/canvas/NodePalette/NodePalette.tsx +15 -5
- package/src/components/Workflow/canvas/NodePalette/NodePaletteToggle.tsx +2 -2
- package/src/components/Workflow/canvas/NodeShell/NodeShell.tsx +4 -4
- package/src/components/Workflow/createNode.test.ts +40 -2
- package/src/components/Workflow/createNode.ts +70 -2
- package/src/components/Workflow/index.ts +8 -0
- package/src/components/Workflow/layout/autoLayout.ts +4 -4
- package/src/components/Workflow/placement.test.ts +156 -0
- package/src/components/Workflow/placement.ts +172 -0
- package/src/components/Workflow/stories/Workflow.stories.tsx +79 -0
- package/src/components/Workflow/stories/toyNodeTypes.tsx +4 -4
- package/src/components/Workflow/useWorkflowActions.test.tsx +345 -0
- package/src/components/Workflow/useWorkflowActions.ts +196 -0
- package/src/components/a11y.kwcag.test.tsx +502 -0
- package/src/components/componentMotion.test.ts +110 -0
- package/src/guidelines/FeedbackActions.mdx +133 -0
- package/src/index.ts +60 -0
- package/src/styles.ts +20 -0
- package/src/test-support/setup.ts +13 -0
- package/src/theme/Motion.stories.tsx +1613 -0
- package/src/theme/MotionCases.stories.tsx +679 -0
- package/src/theme/Palette.stories.tsx +72 -23
- package/src/theme/animationStyles.test.ts +185 -0
- package/src/theme/claude.md +121 -2
- package/src/theme/colors.ts +154 -83
- package/src/theme/formControls.ts +58 -0
- package/src/theme/index.ts +82 -4
- package/src/theme/motion.test.ts +50 -0
- package/src/theme/motion.ts +668 -0
- package/src/theme/motionGuards.test.ts +137 -0
- package/src/theme/recipes/accordion.ts +20 -0
- package/src/translations/Defaults.translations.json +8 -1
- package/src/types/polymorphic.ts +114 -0
- package/src/utils/cubicBezier.ts +69 -0
- package/src/utils/focusRing.ts +7 -4
- package/src/utils/mergeCss.ts +1 -1
- package/src/utils/staggerProps.test.ts +105 -0
- package/src/utils/staggerProps.ts +63 -0
|
@@ -0,0 +1,1613 @@
|
|
|
1
|
+
import { Box, Grid, HStack, Stack } from '@chakra-ui/react';
|
|
2
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
3
|
+
import { useState } from 'react';
|
|
4
|
+
|
|
5
|
+
import { Appear } from '../components/Appear';
|
|
6
|
+
import { Badge } from '../components/Badge';
|
|
7
|
+
import { Button } from '../components/Button';
|
|
8
|
+
import { Chip } from '../components/Chip';
|
|
9
|
+
import { Collapsible } from '../components/Collapsible';
|
|
10
|
+
import { CountUp } from '../components/CountUp';
|
|
11
|
+
import { FileList } from '../components/FileList';
|
|
12
|
+
import { Menu } from '../components/Menu';
|
|
13
|
+
import {
|
|
14
|
+
Modal,
|
|
15
|
+
ModalBody,
|
|
16
|
+
ModalContent,
|
|
17
|
+
ModalHeader,
|
|
18
|
+
} from '../components/Modal';
|
|
19
|
+
import { Popover } from '../components/Popover';
|
|
20
|
+
import { Pulse } from '../components/Pulse';
|
|
21
|
+
import { Reveal } from '../components/Reveal';
|
|
22
|
+
import { SelectField } from '../components/Select';
|
|
23
|
+
import { Shake } from '../components/Shake';
|
|
24
|
+
import { Switch } from '../components/Switch';
|
|
25
|
+
import { Tooltip } from '../components/Tooltip';
|
|
26
|
+
import { H2, H3, Subtext, Text } from '../components/Typography';
|
|
27
|
+
import { staggerProps } from '../utils/staggerProps';
|
|
28
|
+
import {
|
|
29
|
+
MOTION_DURATION_MS,
|
|
30
|
+
MOTION_EASE_CSS,
|
|
31
|
+
MOTION_STAGGER_MAX,
|
|
32
|
+
} from './motion';
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* # Motion
|
|
36
|
+
*
|
|
37
|
+
* Three stories, in the order you need them:
|
|
38
|
+
*
|
|
39
|
+
* 1. **고르기** — building a component. Which name to type. Nearly always this one.
|
|
40
|
+
* 2. **스케일** — the raw durations and curves. Only for framer-motion, a
|
|
41
|
+
* keyframe string, or defining a new preset.
|
|
42
|
+
* 3. **규칙** — adding to or removing from the vocabulary.
|
|
43
|
+
*
|
|
44
|
+
* They were two pages until the loops moved out to their own components; what
|
|
45
|
+
* was left of the second page was three preset rows, which belong next to the
|
|
46
|
+
* other four.
|
|
47
|
+
*/
|
|
48
|
+
const meta = {
|
|
49
|
+
title: 'Theme/Motion',
|
|
50
|
+
parameters: { layout: 'fullscreen' },
|
|
51
|
+
} satisfies Meta;
|
|
52
|
+
|
|
53
|
+
export default meta;
|
|
54
|
+
|
|
55
|
+
type Story = StoryObj;
|
|
56
|
+
|
|
57
|
+
/* ------------------------------------------------------------------ shared */
|
|
58
|
+
|
|
59
|
+
/** Click-to-copy code, the same affordance the palette swatches have. */
|
|
60
|
+
const Code = ({ children }: { children: string }) => {
|
|
61
|
+
const [copied, setCopied] = useState(false);
|
|
62
|
+
|
|
63
|
+
return (
|
|
64
|
+
<Box
|
|
65
|
+
as="button"
|
|
66
|
+
onClick={() => {
|
|
67
|
+
navigator.clipboard?.writeText(children);
|
|
68
|
+
setCopied(true);
|
|
69
|
+
setTimeout(() => setCopied(false), 1200);
|
|
70
|
+
}}
|
|
71
|
+
position="relative"
|
|
72
|
+
display="block"
|
|
73
|
+
w="100%"
|
|
74
|
+
textAlign="left"
|
|
75
|
+
fontFamily="mono"
|
|
76
|
+
fontSize="xs"
|
|
77
|
+
lineHeight="1.7"
|
|
78
|
+
bg="bg.subtle"
|
|
79
|
+
color="fg.default"
|
|
80
|
+
border="1px solid"
|
|
81
|
+
borderColor="border.subtle"
|
|
82
|
+
px={3}
|
|
83
|
+
py={2}
|
|
84
|
+
borderRadius="sm"
|
|
85
|
+
overflowX="auto"
|
|
86
|
+
whiteSpace="pre"
|
|
87
|
+
cursor="pointer"
|
|
88
|
+
animationStyle="feedback"
|
|
89
|
+
transitionProperty="background-color, border-color"
|
|
90
|
+
_hover={{ borderColor: 'border.default' }}
|
|
91
|
+
>
|
|
92
|
+
{children}
|
|
93
|
+
<Box
|
|
94
|
+
position="absolute"
|
|
95
|
+
top={1}
|
|
96
|
+
right={2}
|
|
97
|
+
fontSize="2xs"
|
|
98
|
+
color="fg.subtle"
|
|
99
|
+
opacity={copied ? 1 : 0}
|
|
100
|
+
animationStyle="feedback"
|
|
101
|
+
transitionProperty="opacity"
|
|
102
|
+
>
|
|
103
|
+
복사됨
|
|
104
|
+
</Box>
|
|
105
|
+
</Box>
|
|
106
|
+
);
|
|
107
|
+
};
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* A closed-by-default block of reasoning.
|
|
111
|
+
*
|
|
112
|
+
* The "why" is what makes a decision defensible in review and what makes this
|
|
113
|
+
* page unreadable if it is inline. Native `<details>` rather than a component
|
|
114
|
+
* so the browser handles the state, the keyboard and find-in-page.
|
|
115
|
+
*/
|
|
116
|
+
const Detail = ({
|
|
117
|
+
summary,
|
|
118
|
+
children,
|
|
119
|
+
}: {
|
|
120
|
+
summary: string;
|
|
121
|
+
children: React.ReactNode;
|
|
122
|
+
}) => (
|
|
123
|
+
<Box
|
|
124
|
+
as="details"
|
|
125
|
+
borderTop="1px solid"
|
|
126
|
+
borderColor="border.subtle"
|
|
127
|
+
pt={3}
|
|
128
|
+
mt={3}
|
|
129
|
+
>
|
|
130
|
+
<Box
|
|
131
|
+
as="summary"
|
|
132
|
+
cursor="pointer"
|
|
133
|
+
fontSize="xs"
|
|
134
|
+
color="fg.muted"
|
|
135
|
+
_hover={{ color: 'fg.default' }}
|
|
136
|
+
animationStyle="feedback"
|
|
137
|
+
transitionProperty="color"
|
|
138
|
+
>
|
|
139
|
+
{summary}
|
|
140
|
+
</Box>
|
|
141
|
+
<Box pt={3}>{children}</Box>
|
|
142
|
+
</Box>
|
|
143
|
+
);
|
|
144
|
+
|
|
145
|
+
/* ------------------------------------------------------ story 1: 고르기 */
|
|
146
|
+
|
|
147
|
+
/**
|
|
148
|
+
* The whole vocabulary, in the order you would meet it.
|
|
149
|
+
*
|
|
150
|
+
* One row is one decision: the situation on the left is what a person actually
|
|
151
|
+
* has in front of them, and everything to its right follows from picking that
|
|
152
|
+
* row. There is no branch below the table — if a row matches, the line beside it
|
|
153
|
+
* is the answer.
|
|
154
|
+
*/
|
|
155
|
+
const VOCAB = [
|
|
156
|
+
{
|
|
157
|
+
when: '색 · 그림자 · 투명도가 바뀐다',
|
|
158
|
+
name: 'feedback',
|
|
159
|
+
line: 'animationStyle="feedback" transitionProperty="background-color"',
|
|
160
|
+
},
|
|
161
|
+
{
|
|
162
|
+
when: '손가락이 닿는다 (누르는 느낌)',
|
|
163
|
+
name: 'press',
|
|
164
|
+
line: 'animationStyle="press" _active={{ scale: \'0.94\' }}',
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
when: '위치 · 크기가 새 값으로 간다',
|
|
168
|
+
name: 'travel',
|
|
169
|
+
line: 'animationStyle="travel" transitionProperty="width"',
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
when: '물리적으로 넘어가거나, 둘이 교차한다',
|
|
173
|
+
name: 'spring',
|
|
174
|
+
line: 'animationStyle="spring" transitionProperty="translate"',
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
when: '열리고 닫힌다',
|
|
178
|
+
name: 'presence',
|
|
179
|
+
line: 'animationStyle="presence"',
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
when: '트리거에 붙은 팝업이 열리고 닫힌다',
|
|
183
|
+
name: 'presence-anchored',
|
|
184
|
+
line: 'animationStyle="presence-anchored"',
|
|
185
|
+
},
|
|
186
|
+
{
|
|
187
|
+
when: '목록이 차례로 도착한다',
|
|
188
|
+
name: 'stagger',
|
|
189
|
+
line: '{...staggerProps(index)}',
|
|
190
|
+
},
|
|
191
|
+
{
|
|
192
|
+
when: '한 요소 안에서 속성마다 속도가 다르다',
|
|
193
|
+
name: 'composite',
|
|
194
|
+
line: 'transition={직접조립} animationStyle="composite"',
|
|
195
|
+
},
|
|
196
|
+
];
|
|
197
|
+
|
|
198
|
+
/**
|
|
199
|
+
* A track with a dot that runs end to end, so a curve reads as travel.
|
|
200
|
+
*
|
|
201
|
+
* Both runners share one piece of state — pressing either sends both dots at
|
|
202
|
+
* once, which is the only way to see that `emphasized` and `overshoot` differ
|
|
203
|
+
* over this distance.
|
|
204
|
+
*/
|
|
205
|
+
const Runner = ({
|
|
206
|
+
style,
|
|
207
|
+
at,
|
|
208
|
+
onPlay,
|
|
209
|
+
}: {
|
|
210
|
+
style: string;
|
|
211
|
+
at: boolean;
|
|
212
|
+
onPlay: () => void;
|
|
213
|
+
}) => (
|
|
214
|
+
<HStack gap={3} w="100%">
|
|
215
|
+
<Box
|
|
216
|
+
position="relative"
|
|
217
|
+
h="14px"
|
|
218
|
+
flex="1"
|
|
219
|
+
maxW="190px"
|
|
220
|
+
bg="bg.subtle"
|
|
221
|
+
borderRadius="full"
|
|
222
|
+
>
|
|
223
|
+
<Box
|
|
224
|
+
position="absolute"
|
|
225
|
+
top="1px"
|
|
226
|
+
left={at ? 'calc(100% - 13px)' : '1px'}
|
|
227
|
+
w="12px"
|
|
228
|
+
h="12px"
|
|
229
|
+
borderRadius="full"
|
|
230
|
+
bg="primary.main"
|
|
231
|
+
animationStyle={style}
|
|
232
|
+
transitionProperty="left"
|
|
233
|
+
/>
|
|
234
|
+
</Box>
|
|
235
|
+
<Button size="xs" variant="outline" onClick={onPlay} flexShrink={0}>
|
|
236
|
+
재생
|
|
237
|
+
</Button>
|
|
238
|
+
</HStack>
|
|
239
|
+
);
|
|
240
|
+
|
|
241
|
+
/** The real Modal, so the enter/exit timing is the shipped one. */
|
|
242
|
+
const ModalDemo = () => {
|
|
243
|
+
const [open, setOpen] = useState(false);
|
|
244
|
+
|
|
245
|
+
return (
|
|
246
|
+
<>
|
|
247
|
+
<Button size="xs" variant="outline" onClick={() => setOpen(true)}>
|
|
248
|
+
모달 열기
|
|
249
|
+
</Button>
|
|
250
|
+
<Modal open={open} onOpenChange={(e) => setOpen(e.open)}>
|
|
251
|
+
<ModalContent maxW="320px">
|
|
252
|
+
<ModalHeader>진입과 퇴장</ModalHeader>
|
|
253
|
+
<ModalBody>
|
|
254
|
+
<Text mb={4}>
|
|
255
|
+
바깥을 클릭해 닫아 보세요. 퇴장이 진입의 절반입니다.
|
|
256
|
+
</Text>
|
|
257
|
+
<Button size="xs" onClick={() => setOpen(false)}>
|
|
258
|
+
닫기
|
|
259
|
+
</Button>
|
|
260
|
+
</ModalBody>
|
|
261
|
+
</ModalContent>
|
|
262
|
+
</Modal>
|
|
263
|
+
</>
|
|
264
|
+
);
|
|
265
|
+
};
|
|
266
|
+
|
|
267
|
+
/**
|
|
268
|
+
* The same element played symmetric and asymmetric at once.
|
|
269
|
+
*
|
|
270
|
+
* One at a time they both look fine; side by side the symmetric one reads as
|
|
271
|
+
* "not leaving". That difference is the entire argument for the ratio.
|
|
272
|
+
*/
|
|
273
|
+
const RatioDemo = () => {
|
|
274
|
+
const [open, setOpen] = useState(true);
|
|
275
|
+
|
|
276
|
+
return (
|
|
277
|
+
<Stack gap={4} maxW="440px">
|
|
278
|
+
<Button size="xs" variant="outline" onClick={() => setOpen((v) => !v)}>
|
|
279
|
+
{open ? '닫기' : '열기'}
|
|
280
|
+
</Button>
|
|
281
|
+
{[
|
|
282
|
+
{ label: '대칭 300 / 300', enter: 300, exit: 300 },
|
|
283
|
+
{ label: '비대칭 300 / 150 (presence)', enter: 300, exit: 150 },
|
|
284
|
+
].map((row) => (
|
|
285
|
+
<Grid
|
|
286
|
+
key={row.label}
|
|
287
|
+
templateColumns="180px 1fr"
|
|
288
|
+
gap={4}
|
|
289
|
+
alignItems="center"
|
|
290
|
+
>
|
|
291
|
+
<Subtext color="fg.muted" mb={0}>
|
|
292
|
+
{row.label}
|
|
293
|
+
</Subtext>
|
|
294
|
+
<Box h="44px" position="relative">
|
|
295
|
+
<Box
|
|
296
|
+
position="absolute"
|
|
297
|
+
inset="0"
|
|
298
|
+
borderRadius="md"
|
|
299
|
+
bg="bg.subtle"
|
|
300
|
+
border="1px solid"
|
|
301
|
+
borderColor="border.subtle"
|
|
302
|
+
opacity={open ? 1 : 0}
|
|
303
|
+
translate={open ? '0 0' : '0 -6px'}
|
|
304
|
+
transitionProperty="opacity, translate"
|
|
305
|
+
transitionDuration={`${open ? row.enter : row.exit}ms`}
|
|
306
|
+
transitionTimingFunction={
|
|
307
|
+
open
|
|
308
|
+
? 'var(--chakra-easings-emphasized)'
|
|
309
|
+
: 'var(--chakra-easings-standard)'
|
|
310
|
+
}
|
|
311
|
+
/>
|
|
312
|
+
</Box>
|
|
313
|
+
</Grid>
|
|
314
|
+
))}
|
|
315
|
+
</Stack>
|
|
316
|
+
);
|
|
317
|
+
};
|
|
318
|
+
|
|
319
|
+
const SELECT_OPTIONS = [
|
|
320
|
+
{ label: '전체', value: 'all' },
|
|
321
|
+
{ label: '진행 중', value: 'active' },
|
|
322
|
+
{ label: '검토 대기', value: 'review' },
|
|
323
|
+
{ label: '완료', value: 'done' },
|
|
324
|
+
];
|
|
325
|
+
|
|
326
|
+
const FILES = Array.from({ length: 5 }).map((_, i) => ({
|
|
327
|
+
id: i,
|
|
328
|
+
name: `첨부파일-${i + 1}.pdf`,
|
|
329
|
+
size: 1024 * (i + 1) * 37,
|
|
330
|
+
}));
|
|
331
|
+
|
|
332
|
+
/** Item count against the cap, so "no cap" reads as a queue rather than rhythm. */
|
|
333
|
+
const StaggerLab = () => {
|
|
334
|
+
const [count, setCount] = useState(10);
|
|
335
|
+
const [run, setRun] = useState(0);
|
|
336
|
+
|
|
337
|
+
return (
|
|
338
|
+
<Stack gap={4}>
|
|
339
|
+
<HStack gap={2}>
|
|
340
|
+
{[4, 10, 30].map((n) => (
|
|
341
|
+
<Button
|
|
342
|
+
key={n}
|
|
343
|
+
size="xs"
|
|
344
|
+
variant={count === n ? 'solid' : 'outline'}
|
|
345
|
+
onClick={() => {
|
|
346
|
+
setCount(n);
|
|
347
|
+
setRun((r) => r + 1);
|
|
348
|
+
}}
|
|
349
|
+
>
|
|
350
|
+
{n}개
|
|
351
|
+
</Button>
|
|
352
|
+
))}
|
|
353
|
+
<Button
|
|
354
|
+
size="xs"
|
|
355
|
+
variant="outline"
|
|
356
|
+
onClick={() => setRun((r) => r + 1)}
|
|
357
|
+
>
|
|
358
|
+
다시 재생
|
|
359
|
+
</Button>
|
|
360
|
+
</HStack>
|
|
361
|
+
|
|
362
|
+
<Grid templateColumns={{ base: '1fr', md: '1fr 1fr' }} gap={8}>
|
|
363
|
+
{[
|
|
364
|
+
{ label: `상한 있음 (${MOTION_STAGGER_MAX})`, max: undefined },
|
|
365
|
+
{ label: '상한 없음', max: 999 },
|
|
366
|
+
].map((col) => (
|
|
367
|
+
<Stack key={col.label} gap={2}>
|
|
368
|
+
<Subtext color="fg.muted" mb={0}>
|
|
369
|
+
{col.label} — 마지막 항목{' '}
|
|
370
|
+
{Math.min(count - 1, col.max ?? MOTION_STAGGER_MAX) *
|
|
371
|
+
MOTION_DURATION_MS.staggerStep}
|
|
372
|
+
ms
|
|
373
|
+
</Subtext>
|
|
374
|
+
<Stack key={run} gap="1px">
|
|
375
|
+
{Array.from({ length: count }).map((_, i) => {
|
|
376
|
+
const props = staggerProps(i);
|
|
377
|
+
return (
|
|
378
|
+
<Box
|
|
379
|
+
key={i}
|
|
380
|
+
px={3}
|
|
381
|
+
py={2}
|
|
382
|
+
bg="bg.subtle"
|
|
383
|
+
borderRadius="sm"
|
|
384
|
+
fontSize="xs"
|
|
385
|
+
{...props}
|
|
386
|
+
style={
|
|
387
|
+
col.max == null
|
|
388
|
+
? props.style
|
|
389
|
+
: { ...props.style, '--stagger-max': col.max }
|
|
390
|
+
}
|
|
391
|
+
>
|
|
392
|
+
항목 {i + 1}
|
|
393
|
+
</Box>
|
|
394
|
+
);
|
|
395
|
+
})}
|
|
396
|
+
</Stack>
|
|
397
|
+
</Stack>
|
|
398
|
+
))}
|
|
399
|
+
</Grid>
|
|
400
|
+
</Stack>
|
|
401
|
+
);
|
|
402
|
+
};
|
|
403
|
+
|
|
404
|
+
interface PresetProps {
|
|
405
|
+
name: string;
|
|
406
|
+
timing: string;
|
|
407
|
+
lead: string;
|
|
408
|
+
code: string;
|
|
409
|
+
demo: React.ReactNode;
|
|
410
|
+
children?: React.ReactNode;
|
|
411
|
+
}
|
|
412
|
+
|
|
413
|
+
/** One preset: name, timing, a one-line reason, the line to copy, and a demo. */
|
|
414
|
+
const Preset = ({ name, timing, lead, code, demo, children }: PresetProps) => (
|
|
415
|
+
<Box borderTop="1px solid" borderColor="border.subtle" py={6}>
|
|
416
|
+
<HStack gap={3} align="baseline" mb={3}>
|
|
417
|
+
<Text fontFamily="mono" fontWeight="700" fontSize="lg" mb={0}>
|
|
418
|
+
{name}
|
|
419
|
+
</Text>
|
|
420
|
+
<Subtext fontFamily="mono" fontSize="2xs" color="fg.muted" mb={0}>
|
|
421
|
+
{timing}
|
|
422
|
+
</Subtext>
|
|
423
|
+
</HStack>
|
|
424
|
+
|
|
425
|
+
<Grid
|
|
426
|
+
templateColumns={{ base: '1fr', lg: '280px 1fr' }}
|
|
427
|
+
gap={{ base: 4, lg: 8 }}
|
|
428
|
+
alignItems="start"
|
|
429
|
+
>
|
|
430
|
+
<Box minH="44px" display="flex" alignItems="center">
|
|
431
|
+
{demo}
|
|
432
|
+
</Box>
|
|
433
|
+
<Stack gap={2}>
|
|
434
|
+
<Subtext mb={0}>{lead}</Subtext>
|
|
435
|
+
<Code>{code}</Code>
|
|
436
|
+
{children}
|
|
437
|
+
</Stack>
|
|
438
|
+
</Grid>
|
|
439
|
+
</Box>
|
|
440
|
+
);
|
|
441
|
+
|
|
442
|
+
/**
|
|
443
|
+
* The eight primitives, named and findable.
|
|
444
|
+
*
|
|
445
|
+
* This page used to close by pointing at "여덟 개" in prose, without naming one
|
|
446
|
+
* of them — so someone who needed `Pulse` could read the whole page, agree with
|
|
447
|
+
* it, and still hand-roll the thing with `composite`. A name you cannot grep for
|
|
448
|
+
* is not a pointer.
|
|
449
|
+
*
|
|
450
|
+
* Four of them replay live here because they fit on one line. The other four are
|
|
451
|
+
* not stubs to fill in later: `Reveal` needs a block to open into, `FlyTo` needs
|
|
452
|
+
* two measured rects, `Confetti` needs a stage, and `SwapTransition` needs a
|
|
453
|
+
* sequence. Each has its own story with room for that — repeating those demos
|
|
454
|
+
* here would make this page longer without making it more useful.
|
|
455
|
+
*/
|
|
456
|
+
const PRIMITIVES: [string, string, boolean][] = [
|
|
457
|
+
['Pulse', '값이 방금 올랐다 — 한 번 튀기고 만다', true],
|
|
458
|
+
['Shake', '거절. Pulse와 짝이고, 절대 바꿔 쓰지 않습니다', true],
|
|
459
|
+
['Appear', '요소 하나가 마운트되며 등장 (페이드 · 스탬프 · 도착)', true],
|
|
460
|
+
['CountUp', '숫자가 올라감. 텍스트라 CSS로는 불가능한 유일한 것', true],
|
|
461
|
+
['Reveal', '읽던 것 아래로 블록이 펼쳐짐 — 레이아웃 점프 방지', false],
|
|
462
|
+
['FlyTo', '이게 저기로 갔다. 잰 rect 두 개 사이를 나는 고스트', false],
|
|
463
|
+
['Confetti', '축하 한 번. 유일하게 팔레트 밖 색을 씁니다', false],
|
|
464
|
+
['SwapTransition', '내용이 교체됨 — 단계 이동, 같은 자리의 다른 레코드', false],
|
|
465
|
+
];
|
|
466
|
+
|
|
467
|
+
const PrimitiveIndex = () => {
|
|
468
|
+
const [play, setPlay] = useState(0);
|
|
469
|
+
const [shown, setShown] = useState(false);
|
|
470
|
+
|
|
471
|
+
return (
|
|
472
|
+
<Box borderTop="1px solid" borderColor="border.subtle" pt={5}>
|
|
473
|
+
<HStack gap={3} mb={5} align="center">
|
|
474
|
+
<Button size="xs" variant="outline" onClick={() => setPlay((n) => n + 1)}>
|
|
475
|
+
재생
|
|
476
|
+
</Button>
|
|
477
|
+
<Pulse trigger={play}>
|
|
478
|
+
<Badge variant="success">Pulse</Badge>
|
|
479
|
+
</Pulse>
|
|
480
|
+
<Shake trigger={play}>
|
|
481
|
+
<Chip colorScheme="danger" variant="soft">
|
|
482
|
+
Shake
|
|
483
|
+
</Chip>
|
|
484
|
+
</Shake>
|
|
485
|
+
{/* Keyed so it remounts — Appear plays on mount, which is the point. */}
|
|
486
|
+
<Appear key={play} scaleFrom={0.6}>
|
|
487
|
+
<Chip colorScheme="primary" variant="soft">
|
|
488
|
+
Appear
|
|
489
|
+
</Chip>
|
|
490
|
+
</Appear>
|
|
491
|
+
{/* No `format` — the default `groupDigits` rounds and groups. Passing a
|
|
492
|
+
bare `${n}` here rendered mid-flight values like `1180.00698…`. */}
|
|
493
|
+
<CountUp key={`c${play}`} from={0} to={1250} />
|
|
494
|
+
</HStack>
|
|
495
|
+
|
|
496
|
+
<Stack gap={2}>
|
|
497
|
+
{PRIMITIVES.map(([name, use, live]) => (
|
|
498
|
+
<Grid
|
|
499
|
+
key={name}
|
|
500
|
+
templateColumns={{ base: '1fr', md: '150px 1fr' }}
|
|
501
|
+
gap={{ base: 0, md: 4 }}
|
|
502
|
+
alignItems="baseline"
|
|
503
|
+
>
|
|
504
|
+
<Text
|
|
505
|
+
fontFamily="mono"
|
|
506
|
+
fontSize="xs"
|
|
507
|
+
fontWeight="600"
|
|
508
|
+
color={live ? 'fg.default' : 'fg.muted'}
|
|
509
|
+
mb={0}
|
|
510
|
+
>
|
|
511
|
+
{name}
|
|
512
|
+
</Text>
|
|
513
|
+
<Subtext color="fg.muted" mb={0}>
|
|
514
|
+
{use}
|
|
515
|
+
</Subtext>
|
|
516
|
+
</Grid>
|
|
517
|
+
))}
|
|
518
|
+
</Stack>
|
|
519
|
+
|
|
520
|
+
<Box mt={5}>
|
|
521
|
+
<Button
|
|
522
|
+
size="xs"
|
|
523
|
+
variant="outline"
|
|
524
|
+
onClick={() => setShown((v) => !v)}
|
|
525
|
+
mb={shown ? 2 : 0}
|
|
526
|
+
>
|
|
527
|
+
{shown ? 'Reveal 닫기' : 'Reveal 열어보기'}
|
|
528
|
+
</Button>
|
|
529
|
+
{shown && (
|
|
530
|
+
<Reveal>
|
|
531
|
+
<Subtext color="fg.muted" mb={0}>
|
|
532
|
+
여덟 개 전부 <code>Components / Motion</code> 아래에 각자 스토리가
|
|
533
|
+
있습니다. 어느 것을 쓸지는 <code>Appear</code>의 TSDoc에 있는 세
|
|
534
|
+
가지 등장(<code>presence</code> · <code>stagger</code> ·{' '}
|
|
535
|
+
<code>Appear</code>) 구분이 출발점입니다.
|
|
536
|
+
</Subtext>
|
|
537
|
+
</Reveal>
|
|
538
|
+
)}
|
|
539
|
+
</Box>
|
|
540
|
+
</Box>
|
|
541
|
+
);
|
|
542
|
+
};
|
|
543
|
+
|
|
544
|
+
/**
|
|
545
|
+
* What to type.
|
|
546
|
+
*
|
|
547
|
+
* The table comes before the explanation on purpose: the reader arrives holding
|
|
548
|
+
* a component, not a question about motion theory. Everything below the table is
|
|
549
|
+
* for the second visit.
|
|
550
|
+
*/
|
|
551
|
+
export const Choose: Story = {
|
|
552
|
+
name: '1. 고르기',
|
|
553
|
+
render: () => {
|
|
554
|
+
const [at, setAt] = useState(false);
|
|
555
|
+
const [on, setOn] = useState(false);
|
|
556
|
+
|
|
557
|
+
// Send it back to the start, then off again on the next frame, so "재생"
|
|
558
|
+
// always runs the same direction however many times it is pressed.
|
|
559
|
+
const play = () => {
|
|
560
|
+
setAt(false);
|
|
561
|
+
requestAnimationFrame(() => requestAnimationFrame(() => setAt(true)));
|
|
562
|
+
};
|
|
563
|
+
|
|
564
|
+
return (
|
|
565
|
+
<Box p={10} maxW="1000px">
|
|
566
|
+
<H2 mb={2}>Motion</H2>
|
|
567
|
+
<Text color="fg.muted" mb={6}>
|
|
568
|
+
숫자를 직접 적을 일은 없습니다. <b>이름 하나를 고르는 것</b>이
|
|
569
|
+
전부이고, 그 이름이 시간과 곡선과 동작 줄이기를 함께 가져옵니다.
|
|
570
|
+
</Text>
|
|
571
|
+
|
|
572
|
+
{/* The three roles, kept as one visual unit so they can be recalled as
|
|
573
|
+
one. Everything else on this page is an instance of this.
|
|
574
|
+
|
|
575
|
+
Three rather than two because the two-prop version keeps producing
|
|
576
|
+
the same misreading — that the preset is "applied to hover". It is
|
|
577
|
+
not: a transition never sees the hover. It sees a property changing
|
|
578
|
+
and decides how long that takes. Naming the cause as its own row is
|
|
579
|
+
what separates those. */}
|
|
580
|
+
<Box
|
|
581
|
+
border="1px solid"
|
|
582
|
+
borderColor="border.default"
|
|
583
|
+
borderRadius="md"
|
|
584
|
+
p={5}
|
|
585
|
+
mb={10}
|
|
586
|
+
>
|
|
587
|
+
<Stack gap={4} mb={5}>
|
|
588
|
+
{[
|
|
589
|
+
{
|
|
590
|
+
role: '무엇이',
|
|
591
|
+
prop: 'transitionProperty="background-color"',
|
|
592
|
+
means: 'background-color가',
|
|
593
|
+
accent: false,
|
|
594
|
+
},
|
|
595
|
+
{
|
|
596
|
+
role: '어떻게',
|
|
597
|
+
prop: 'animationStyle="feedback"',
|
|
598
|
+
means: '150ms · standard 곡선으로 부드럽게',
|
|
599
|
+
accent: true,
|
|
600
|
+
},
|
|
601
|
+
{
|
|
602
|
+
role: '언제',
|
|
603
|
+
prop: "_hover={{ bg: 'primary.lightest' }}",
|
|
604
|
+
means: 'hover하면 값이 바뀐다',
|
|
605
|
+
accent: false,
|
|
606
|
+
},
|
|
607
|
+
].map(({ role, prop, means, accent }) => (
|
|
608
|
+
<Grid
|
|
609
|
+
key={role}
|
|
610
|
+
templateColumns={{ base: '1fr', md: '58px 1fr' }}
|
|
611
|
+
gap={{ base: 1, md: 4 }}
|
|
612
|
+
alignItems="baseline"
|
|
613
|
+
>
|
|
614
|
+
<Text
|
|
615
|
+
fontSize="sm"
|
|
616
|
+
fontWeight="700"
|
|
617
|
+
color="fg.muted"
|
|
618
|
+
mb={0}
|
|
619
|
+
flexShrink={0}
|
|
620
|
+
>
|
|
621
|
+
{role}
|
|
622
|
+
</Text>
|
|
623
|
+
<Box>
|
|
624
|
+
<Text
|
|
625
|
+
fontFamily="mono"
|
|
626
|
+
fontSize="xs"
|
|
627
|
+
fontWeight="600"
|
|
628
|
+
color={accent ? 'primary.main' : 'fg.default'}
|
|
629
|
+
mb={0}
|
|
630
|
+
>
|
|
631
|
+
{prop}
|
|
632
|
+
</Text>
|
|
633
|
+
<Subtext color="fg.muted" mb={0}>
|
|
634
|
+
{means}
|
|
635
|
+
</Subtext>
|
|
636
|
+
</Box>
|
|
637
|
+
</Grid>
|
|
638
|
+
))}
|
|
639
|
+
</Stack>
|
|
640
|
+
|
|
641
|
+
<Code>{`<Box
|
|
642
|
+
transitionProperty="background-color"
|
|
643
|
+
animationStyle="feedback"
|
|
644
|
+
_hover={{ bg: 'primary.lightest' }}
|
|
645
|
+
/>`}</Code>
|
|
646
|
+
|
|
647
|
+
<Subtext color="fg.muted" mt={4} mb={2}>
|
|
648
|
+
<b>프리셋은 hover에 붙는 게 아니라 background-color에 붙습니다.</b>{' '}
|
|
649
|
+
transition은 hover를 모릅니다 — "background-color가 바뀌면
|
|
650
|
+
150ms에 걸쳐 바꿔라"가 전부고, 값을 바꾼 게 hover든{' '}
|
|
651
|
+
<code>_focus</code>든 prop이든 상관하지 않습니다.{' '}
|
|
652
|
+
<code>_hover</code>를 <code>_focus</code>로 바꿔도 똑같이 돕니다.
|
|
653
|
+
</Subtext>
|
|
654
|
+
<Subtext color="fg.muted" mb={0}>
|
|
655
|
+
<b>"무엇이"를 빠뜨리면 아무것도 움직이지 않습니다</b> —
|
|
656
|
+
프리셋은 시간만 정하고, 무엇이 움직이는지는 요소마다 다르기
|
|
657
|
+
때문입니다. (<code>press</code>와 <code>presence</code>는 예외 —
|
|
658
|
+
각각 언제나 scale, 언제나 열림·닫힘이라 기본값이 들어 있습니다.)
|
|
659
|
+
</Subtext>
|
|
660
|
+
</Box>
|
|
661
|
+
|
|
662
|
+
<H3 mb={1}>무엇이 바뀌나요?</H3>
|
|
663
|
+
<Subtext color="fg.muted" mb={4}>
|
|
664
|
+
왼쪽에서 지금 만드는 것을 찾고, 오른쪽 줄을 눌러 복사하세요. 어휘는 이
|
|
665
|
+
일곱 개가 전부입니다.
|
|
666
|
+
</Subtext>
|
|
667
|
+
|
|
668
|
+
<Stack gap={3} mb={4}>
|
|
669
|
+
{VOCAB.map((v) => (
|
|
670
|
+
<Grid
|
|
671
|
+
key={v.name}
|
|
672
|
+
templateColumns={{ base: '1fr', md: '230px 108px 1fr' }}
|
|
673
|
+
gap={{ base: 1, md: 4 }}
|
|
674
|
+
alignItems="center"
|
|
675
|
+
>
|
|
676
|
+
<Subtext color="fg.muted" mb={0}>
|
|
677
|
+
{v.when}
|
|
678
|
+
</Subtext>
|
|
679
|
+
<Text
|
|
680
|
+
fontFamily="mono"
|
|
681
|
+
fontSize="sm"
|
|
682
|
+
fontWeight="700"
|
|
683
|
+
color="primary.main"
|
|
684
|
+
mb={0}
|
|
685
|
+
>
|
|
686
|
+
{v.name}
|
|
687
|
+
</Text>
|
|
688
|
+
<Code>{v.line}</Code>
|
|
689
|
+
</Grid>
|
|
690
|
+
))}
|
|
691
|
+
</Stack>
|
|
692
|
+
|
|
693
|
+
<Subtext color="fg.muted" mb={10}>
|
|
694
|
+
<b>고민되면 feedback을 쓰세요.</b> 가장 눈에 띄지 않아서 틀렸을 때
|
|
695
|
+
손해가 가장 작습니다.
|
|
696
|
+
</Subtext>
|
|
697
|
+
|
|
698
|
+
<H3 mb={2}>직접 만져보기</H3>
|
|
699
|
+
<Subtext color="fg.muted" mb={0}>
|
|
700
|
+
위 표의 순서 그대로입니다. 각 항목의 "왜"는 접어 두었습니다
|
|
701
|
+
— 리뷰에서 근거가 필요할 때만 펴면 됩니다.
|
|
702
|
+
</Subtext>
|
|
703
|
+
|
|
704
|
+
<Preset
|
|
705
|
+
name="feedback"
|
|
706
|
+
timing="150ms · standard"
|
|
707
|
+
lead="hover와 상태 변화. 방금 한 행동에 답하고 바로 비켜야 하므로 넷 중 가장 짧습니다."
|
|
708
|
+
code={`<Box
|
|
709
|
+
animationStyle="feedback"
|
|
710
|
+
transitionProperty="background-color, border-color"
|
|
711
|
+
_hover={{ bg: 'primary.lightest', borderColor: 'primary.main' }}
|
|
712
|
+
/>`}
|
|
713
|
+
demo={
|
|
714
|
+
<Box
|
|
715
|
+
px={5}
|
|
716
|
+
py={3}
|
|
717
|
+
borderRadius="md"
|
|
718
|
+
border="1px solid"
|
|
719
|
+
borderColor="border.default"
|
|
720
|
+
bg="bg.surface"
|
|
721
|
+
fontSize="sm"
|
|
722
|
+
animationStyle="feedback"
|
|
723
|
+
transitionProperty="background-color, border-color"
|
|
724
|
+
_hover={{ bg: 'primary.lightest', borderColor: 'primary.main' }}
|
|
725
|
+
>
|
|
726
|
+
hover 해보세요
|
|
727
|
+
</Box>
|
|
728
|
+
}
|
|
729
|
+
>
|
|
730
|
+
<Detail summary="왜 150ms인가 — 그리고 왜 우리 토큰이 아닌가">
|
|
731
|
+
<Subtext color="fg.muted" mb={0}>
|
|
732
|
+
Chakra의 <code>fast</code>가 이미 150ms입니다. 같은 값에 이름을 둘
|
|
733
|
+
만들지 않으려고 우리 스케일에는 150ms·200ms가 아예 없습니다.{' '}
|
|
734
|
+
<code>motion.</code> 접두어가 붙은 것만 우리 것입니다.
|
|
735
|
+
</Subtext>
|
|
736
|
+
</Detail>
|
|
737
|
+
</Preset>
|
|
738
|
+
|
|
739
|
+
<Preset
|
|
740
|
+
name="press"
|
|
741
|
+
timing="120ms · emphasized"
|
|
742
|
+
lead="포인터가 눌리는 순간의 접촉감. 유일하게 property를 안 적어도 되는 프리셋입니다 — 프레스는 언제나 scale이라 기본값이 들어 있습니다."
|
|
743
|
+
code={`<Box
|
|
744
|
+
scale="1"
|
|
745
|
+
animationStyle="press"
|
|
746
|
+
_active={{ scale: '0.94' }}
|
|
747
|
+
/>`}
|
|
748
|
+
demo={
|
|
749
|
+
<Box
|
|
750
|
+
as="button"
|
|
751
|
+
px={5}
|
|
752
|
+
py={2}
|
|
753
|
+
borderRadius="md"
|
|
754
|
+
bg="primary.main"
|
|
755
|
+
color="fg.inverse"
|
|
756
|
+
fontSize="sm"
|
|
757
|
+
fontWeight="600"
|
|
758
|
+
cursor="pointer"
|
|
759
|
+
scale="1"
|
|
760
|
+
animationStyle="press"
|
|
761
|
+
_active={{ scale: '0.94' }}
|
|
762
|
+
>
|
|
763
|
+
눌러보세요
|
|
764
|
+
</Box>
|
|
765
|
+
}
|
|
766
|
+
>
|
|
767
|
+
<Detail summary="왜 transform이 아니라 scale인가">
|
|
768
|
+
<Subtext color="fg.muted" mb={0}>
|
|
769
|
+
<code>scale</code>은 개별 transform 속성이라 호출부의{' '}
|
|
770
|
+
<code>transform</code>과 겹쳐 씁니다.{' '}
|
|
771
|
+
<code>transform: scale()</code>로 적었다면 버튼을 2px 내리는
|
|
772
|
+
코드가 프레스를 통째로 지웠을 겁니다.
|
|
773
|
+
</Subtext>
|
|
774
|
+
</Detail>
|
|
775
|
+
</Preset>
|
|
776
|
+
|
|
777
|
+
<Preset
|
|
778
|
+
name="travel"
|
|
779
|
+
timing="300ms · emphasized"
|
|
780
|
+
lead="새 위치나 크기로 이동. 거리 대부분을 먼저 덮고 마지막에 자리를 잡아서, 이미 바뀐 값을 따라잡는 것처럼 읽힙니다."
|
|
781
|
+
code={`<Progress.Range animationStyle="travel" transitionProperty="width" />`}
|
|
782
|
+
demo={<Runner style="travel" at={at} onPlay={play} />}
|
|
783
|
+
/>
|
|
784
|
+
|
|
785
|
+
<Preset
|
|
786
|
+
name="spring"
|
|
787
|
+
timing="300ms · overshoot"
|
|
788
|
+
lead="물리적인 전환, 또는 두 요소의 교차. 목표를 지나쳤다 돌아오므로 몇 px만 움직여도 눈에 보입니다 — 위 travel과 나란히 재생해 보세요."
|
|
789
|
+
code={`<Switch.Thumb animationStyle="spring" transitionProperty="translate" />`}
|
|
790
|
+
demo={
|
|
791
|
+
<Stack gap={3} w="100%">
|
|
792
|
+
<Runner style="spring" at={at} onPlay={play} />
|
|
793
|
+
<Switch checked={on} onCheckedChange={(e) => setOn(!!e.checked)}>
|
|
794
|
+
<Switch.Control />
|
|
795
|
+
<Switch.Label>알림 받기</Switch.Label>
|
|
796
|
+
</Switch>
|
|
797
|
+
</Stack>
|
|
798
|
+
}
|
|
799
|
+
>
|
|
800
|
+
<Detail summary="travel과 spring을 어떻게 구분하나">
|
|
801
|
+
<Subtext color="fg.muted" mb={0}>
|
|
802
|
+
같은 300ms이고 곡선만 다릅니다. 짧은 거리에서는{' '}
|
|
803
|
+
<code>standard</code>와 <code>emphasized</code>가 눈으로 구분되지
|
|
804
|
+
않지만 <code>overshoot</code>는 거리와 무관하게 보입니다 — 그래서
|
|
805
|
+
"움직인 게 보여야 하는가"가 실질적인 기준입니다.
|
|
806
|
+
</Subtext>
|
|
807
|
+
</Detail>
|
|
808
|
+
</Preset>
|
|
809
|
+
|
|
810
|
+
<Preset
|
|
811
|
+
name="presence"
|
|
812
|
+
timing="진입 300ms · emphasized / 퇴장 150ms · standard"
|
|
813
|
+
lead="열리고 닫히는 모든 것. 진입은 읽혀야 하고 퇴장은 이미 결정된 일이라 절반입니다. Modal · BottomSheet · Collapsible 은 300 / 150, 트리거에 붙은 Menu · Select · Combobox · Popover · Tooltip 은 presence-anchored 로 200 / 100 입니다."
|
|
814
|
+
code={`<Menu.List animationStyle="presence" />
|
|
815
|
+
|
|
816
|
+
// 무엇이 움직이는지는 각 recipe의 것이고, presence는 시계만 바꿉니다 —
|
|
817
|
+
// 그래서 Collapsible은 페이드가 아니라 여전히 높이가 늘어납니다.`}
|
|
818
|
+
demo={<ModalDemo />}
|
|
819
|
+
>
|
|
820
|
+
<Detail summary="비대칭을 눈으로 확인하기 (대칭과 나란히 재생)">
|
|
821
|
+
<RatioDemo />
|
|
822
|
+
</Detail>
|
|
823
|
+
<Detail summary="적용된 여섯 부품 — 만져보기">
|
|
824
|
+
<Stack gap={4}>
|
|
825
|
+
<Stack gap={1}>
|
|
826
|
+
{[
|
|
827
|
+
['Menu', '150 / 100 → 200 / 100 (anchored)'],
|
|
828
|
+
['Popover', '150 / 100 → 200 / 100 (anchored)'],
|
|
829
|
+
['Tooltip', '150 / 150 → 200 / 100 (anchored)'],
|
|
830
|
+
['Select', '150 / 50 → 200 / 100 (anchored)'],
|
|
831
|
+
['Collapsible', '200 / 200 → 300 / 150'],
|
|
832
|
+
['Modal', '자체 keyframe + presence 시계'],
|
|
833
|
+
].map(([name, change]) => (
|
|
834
|
+
<HStack key={name} gap={3} align="baseline">
|
|
835
|
+
<Text fontFamily="mono" fontSize="xs" minW="100px" mb={0}>
|
|
836
|
+
{name}
|
|
837
|
+
</Text>
|
|
838
|
+
<Subtext color="fg.muted" fontSize="2xs" mb={0}>
|
|
839
|
+
{change}
|
|
840
|
+
</Subtext>
|
|
841
|
+
</HStack>
|
|
842
|
+
))}
|
|
843
|
+
</Stack>
|
|
844
|
+
|
|
845
|
+
<HStack gap={4} wrap="wrap">
|
|
846
|
+
<Menu>
|
|
847
|
+
<Menu.Trigger asChild>
|
|
848
|
+
<Button size="xs" variant="outline">
|
|
849
|
+
Menu
|
|
850
|
+
</Button>
|
|
851
|
+
</Menu.Trigger>
|
|
852
|
+
<Menu.List>
|
|
853
|
+
<Menu.Item value="a">이름 바꾸기</Menu.Item>
|
|
854
|
+
<Menu.Item value="b">복제</Menu.Item>
|
|
855
|
+
<Menu.Item value="c">삭제</Menu.Item>
|
|
856
|
+
</Menu.List>
|
|
857
|
+
</Menu>
|
|
858
|
+
|
|
859
|
+
<Popover>
|
|
860
|
+
<Popover.Trigger asChild>
|
|
861
|
+
<Button size="xs" variant="outline">
|
|
862
|
+
Popover
|
|
863
|
+
</Button>
|
|
864
|
+
</Popover.Trigger>
|
|
865
|
+
<Popover.Content>
|
|
866
|
+
<Popover.Body>
|
|
867
|
+
<Subtext mb={0}>바깥을 클릭해 닫아 보세요.</Subtext>
|
|
868
|
+
</Popover.Body>
|
|
869
|
+
</Popover.Content>
|
|
870
|
+
</Popover>
|
|
871
|
+
|
|
872
|
+
<Tooltip content="가장 짧게 머무는 파트라 퇴장 시간이 가장 크게 체감됩니다">
|
|
873
|
+
<Button size="xs" variant="outline">
|
|
874
|
+
Tooltip
|
|
875
|
+
</Button>
|
|
876
|
+
</Tooltip>
|
|
877
|
+
|
|
878
|
+
<Box minW="180px">
|
|
879
|
+
<SelectField options={SELECT_OPTIONS} placeholder="Select" />
|
|
880
|
+
</Box>
|
|
881
|
+
</HStack>
|
|
882
|
+
|
|
883
|
+
<Collapsible.Root>
|
|
884
|
+
<Collapsible.Trigger>Collapsible</Collapsible.Trigger>
|
|
885
|
+
<Collapsible.Content>
|
|
886
|
+
<Subtext mb={0}>
|
|
887
|
+
이 패널만 페이드가 아니라 높이가 늘어납니다. presence가
|
|
888
|
+
animation-name을 정하지 않기 때문에 recipe의{' '}
|
|
889
|
+
<code>expand-height</code>가 그대로 남습니다.
|
|
890
|
+
</Subtext>
|
|
891
|
+
</Collapsible.Content>
|
|
892
|
+
</Collapsible.Root>
|
|
893
|
+
</Stack>
|
|
894
|
+
</Detail>
|
|
895
|
+
<Detail summary="Toast는 왜 빠졌나">
|
|
896
|
+
<Subtext color="fg.muted" mb={0}>
|
|
897
|
+
Chakra의 Toast는 keyframe이 아니라 transition 단축 속성으로
|
|
898
|
+
움직입니다. <code>animation-*</code> 시계를 얹어도 아무 일이
|
|
899
|
+
일어나지 않으므로, 적용된 척하는 대신 빼 두었습니다.
|
|
900
|
+
</Subtext>
|
|
901
|
+
</Detail>
|
|
902
|
+
</Preset>
|
|
903
|
+
|
|
904
|
+
<Preset
|
|
905
|
+
name="stagger"
|
|
906
|
+
timing="항목당 35ms · 최대 6칸 · 진입에만"
|
|
907
|
+
lead="목록이 한 덩어리 대신 차례로 도착합니다. JS 타이머도 framer-motion도 없습니다 — 항목마다 꽂는 인덱스 하나와 프리셋 안의 calc() 하나가 전부입니다."
|
|
908
|
+
code={`{options.map((option, i) => (
|
|
909
|
+
<Select.Item key={option.value} item={option} {...staggerProps(i)} />
|
|
910
|
+
))}`}
|
|
911
|
+
demo={
|
|
912
|
+
<Menu>
|
|
913
|
+
<Menu.Trigger asChild>
|
|
914
|
+
<Button size="xs" variant="outline">
|
|
915
|
+
Menu stagger
|
|
916
|
+
</Button>
|
|
917
|
+
</Menu.Trigger>
|
|
918
|
+
<Menu.List stagger>
|
|
919
|
+
<Menu.Item value="a">이름 바꾸기</Menu.Item>
|
|
920
|
+
<Menu.Item value="b">복제</Menu.Item>
|
|
921
|
+
<Menu.Item value="c">이동</Menu.Item>
|
|
922
|
+
<Menu.Item value="d">내보내기</Menu.Item>
|
|
923
|
+
<Menu.Item value="e">삭제</Menu.Item>
|
|
924
|
+
</Menu.List>
|
|
925
|
+
</Menu>
|
|
926
|
+
}
|
|
927
|
+
>
|
|
928
|
+
<Detail summary="상한이 왜 필요한가 (항목 수를 바꿔가며)">
|
|
929
|
+
<StaggerLab />
|
|
930
|
+
<Subtext color="fg.muted" mt={4} mb={0}>
|
|
931
|
+
오른쪽이 상한을 뺀 쪽입니다. 30개에서 마지막 항목이 1초 넘게 늦게
|
|
932
|
+
도착하고, 그건 리듬이 아니라 그냥 느린 화면입니다.
|
|
933
|
+
</Subtext>
|
|
934
|
+
</Detail>
|
|
935
|
+
<Detail summary="왜 transition-delay가 아니라 animation인가">
|
|
936
|
+
<Subtext mb={3}>
|
|
937
|
+
<code>transition-delay</code>는 그 요소의 <b>이후 모든</b> 속성
|
|
938
|
+
변화에 걸립니다 — hover 한 번에도 인덱스만큼 기다리고, 필터 한
|
|
939
|
+
글자마다 목록 전체가 다시 지연됩니다. <code>animation</code>은
|
|
940
|
+
마운트될 때 한 번 돌고 끝나며, 그게 정확히 진입입니다.
|
|
941
|
+
</Subtext>
|
|
942
|
+
<Subtext color="fg.muted" mb={0}>
|
|
943
|
+
<code>Masonry</code> · <code>Table</code> · <code>Combobox</code>{' '}
|
|
944
|
+
· <code>Toast</code>에는 붙이지 않습니다. 길거나, 가상 스크롤
|
|
945
|
+
후보이거나(인덱스가 "스크롤 창 안의 위치"가 됩니다),
|
|
946
|
+
필터·정렬로 매번 다시 마운트되는 목록이기 때문입니다.
|
|
947
|
+
</Subtext>
|
|
948
|
+
</Detail>
|
|
949
|
+
<Detail summary="실제 호출부 — FileList">
|
|
950
|
+
<FileList files={FILES} visibleCount={3} stagger />
|
|
951
|
+
<Subtext color="fg.muted" mt={3} mb={0}>
|
|
952
|
+
전부 opt-in입니다. "더 보기"로 드러나는 줄도 각자의
|
|
953
|
+
인덱스로 도착합니다.
|
|
954
|
+
</Subtext>
|
|
955
|
+
</Detail>
|
|
956
|
+
</Preset>
|
|
957
|
+
|
|
958
|
+
<Preset
|
|
959
|
+
name="composite"
|
|
960
|
+
timing="직접 조립 + 동작 줄이기 가드"
|
|
961
|
+
lead="한 요소 안에서 속성마다 다른 속도가 필요할 때만. Button은 프레스가 120ms인데 색은 150ms라 duration 하나로 표현이 안 됩니다. composite가 주는 것은 동작 줄이기 가드 하나뿐이고, 값은 반드시 토큰 var()로 적으세요."
|
|
962
|
+
code={`// Button.styles.ts
|
|
963
|
+
export const buttonTransition = [
|
|
964
|
+
'scale var(--chakra-durations-motion-press) var(--chakra-easings-emphasized)',
|
|
965
|
+
'background-color var(--chakra-durations-fast) var(--chakra-easings-standard)',
|
|
966
|
+
].join(', ');
|
|
967
|
+
|
|
968
|
+
// Button.tsx
|
|
969
|
+
<ChakraButton transition={buttonTransition} animationStyle="composite" />`}
|
|
970
|
+
demo={
|
|
971
|
+
<HStack gap={3}>
|
|
972
|
+
<Button colorPalette="primary" variant="solid">
|
|
973
|
+
눌러보세요
|
|
974
|
+
</Button>
|
|
975
|
+
<Button colorPalette="neutral" variant="outline">
|
|
976
|
+
Outline
|
|
977
|
+
</Button>
|
|
978
|
+
</HStack>
|
|
979
|
+
}
|
|
980
|
+
>
|
|
981
|
+
<Detail summary="여기 오기 전에 확인할 것">
|
|
982
|
+
<Subtext color="fg.muted" mb={0}>
|
|
983
|
+
속도가 정말 <b>속성마다</b> 달라야 하는지 먼저 보세요. 하나면 위
|
|
984
|
+
여섯 중 하나입니다. composite는 어휘의 탈출구이지 일곱 번째
|
|
985
|
+
선택지가 아닙니다.
|
|
986
|
+
</Subtext>
|
|
987
|
+
</Detail>
|
|
988
|
+
</Preset>
|
|
989
|
+
|
|
990
|
+
<H3 mt={10} mb={2}>
|
|
991
|
+
이렇게 쓰지 마세요
|
|
992
|
+
</H3>
|
|
993
|
+
<Stack gap={3} mb={10}>
|
|
994
|
+
<Box>
|
|
995
|
+
<Subtext color="danger.main" mb={1}>
|
|
996
|
+
❌ 숫자와 곡선을 직접 적기 — 파일마다 값이 갈라집니다
|
|
997
|
+
</Subtext>
|
|
998
|
+
<Code>{`<Box transitionDuration="300ms" transitionTimingFunction="ease-out" />`}</Code>
|
|
999
|
+
</Box>
|
|
1000
|
+
<Box>
|
|
1001
|
+
<Subtext color="danger.main" mb={1}>
|
|
1002
|
+
❌ property를 빠뜨리기 — 아무것도 움직이지 않습니다{' '}
|
|
1003
|
+
<b>(lint가 잡습니다)</b>
|
|
1004
|
+
</Subtext>
|
|
1005
|
+
<Code>{`<Box animationStyle="feedback" />`}</Code>
|
|
1006
|
+
</Box>
|
|
1007
|
+
<Box>
|
|
1008
|
+
<Subtext color="danger.main" mb={1}>
|
|
1009
|
+
❌ 이름을 두 개 주기 — 겹치는 게 아니라 반응형 브레이크포인트로
|
|
1010
|
+
읽힙니다 (모바일은 travel, 데스크톱은 spring){' '}
|
|
1011
|
+
<b>(lint가 잡습니다)</b>
|
|
1012
|
+
</Subtext>
|
|
1013
|
+
<Code>{`<Box animationStyle={['travel', 'spring']} />`}</Code>
|
|
1014
|
+
</Box>
|
|
1015
|
+
<Box>
|
|
1016
|
+
<Subtext color="success.main" mb={1}>
|
|
1017
|
+
✅ 이름 하나 + 무엇이 움직이는지
|
|
1018
|
+
</Subtext>
|
|
1019
|
+
<Code>{`<Box animationStyle="feedback" transitionProperty="opacity" />`}</Code>
|
|
1020
|
+
</Box>
|
|
1021
|
+
</Stack>
|
|
1022
|
+
|
|
1023
|
+
<Subtext color="fg.muted" mb={10}>
|
|
1024
|
+
<b>타입은 이 셋 중 아무것도 못 잡습니다.</b> Chakra가{' '}
|
|
1025
|
+
<code>animationStyle</code>을 <code>AnyString</code>으로 열어 두었고,{' '}
|
|
1026
|
+
<code>transitionProperty</code>는 별개의 optional prop이라 하나가 다른
|
|
1027
|
+
하나를 요구하게 만들려면 Chakra 컴포넌트 타입을 전부 포크해야 합니다.
|
|
1028
|
+
그래서 lint 규칙 셋(오타 · 이름 두 개 · property 누락)이 있고,{' '}
|
|
1029
|
+
<code>motionGuards.test.ts</code>가 그 규칙들이 아직 살아 있는지
|
|
1030
|
+
확인합니다. 다만 lint는 <b>JSX만</b> 봅니다 — <code>.styles.ts</code>{' '}
|
|
1031
|
+
안의 스타일 객체는 사각지대입니다.
|
|
1032
|
+
</Subtext>
|
|
1033
|
+
|
|
1034
|
+
<H3 mb={2}>따로 챙기지 않아도 되는 것</H3>
|
|
1035
|
+
<Text color="fg.muted" mb={10}>
|
|
1036
|
+
<b>동작 줄이기</b>는 프리셋 안에 들어 있습니다. OS에서{' '}
|
|
1037
|
+
<code>prefers-reduced-motion</code>을 켠 사람에게는 duration이
|
|
1038
|
+
자동으로 <code>0ms</code>가 됩니다 — 스위치는 여전히 켜지고 색도
|
|
1039
|
+
여전히 바뀌며, 이동만 사라집니다. 컴포넌트마다 적을 필요가 없습니다.
|
|
1040
|
+
</Text>
|
|
1041
|
+
|
|
1042
|
+
<H3 mb={2}>여기 없는 것</H3>
|
|
1043
|
+
<Text color="fg.muted" mb={0}>
|
|
1044
|
+
<b>계속 도는 것</b>(스피너 회전, indeterminate 막대)은 프리셋이
|
|
1045
|
+
아닙니다 — 쓰는 컴포넌트가 하나뿐이라 그 컴포넌트 옆에 삽니다(
|
|
1046
|
+
<code>Spinner.styles.ts</code> · <code>ProgressBar.styles.ts</code>).
|
|
1047
|
+
체크마크 그리기, 라디오 점, 세그먼트 인디케이터도 마찬가지입니다.
|
|
1048
|
+
기준과 그 이유는 <b>3. 규칙</b>에 있습니다.
|
|
1049
|
+
</Text>
|
|
1050
|
+
<Text color="fg.muted" mb={4}>
|
|
1051
|
+
한 번 튀기·흔들기·등장·펼치기처럼 <b>컴포넌트로 감싸야 하는 모션</b>도
|
|
1052
|
+
프리셋이 아닙니다. 프리셋은 <b>이미 있는 요소</b>에 시계를 얹는
|
|
1053
|
+
것이고, 아래 여덟 개는 요소를 <b>만들어 내거나 붙잡아 두는</b> 것이라
|
|
1054
|
+
컴포넌트여야 합니다 — <code>animationStyle</code>로는 표현할 자리가
|
|
1055
|
+
없습니다.
|
|
1056
|
+
</Text>
|
|
1057
|
+
<PrimitiveIndex />
|
|
1058
|
+
</Box>
|
|
1059
|
+
);
|
|
1060
|
+
},
|
|
1061
|
+
};
|
|
1062
|
+
|
|
1063
|
+
/* ------------------------------------------------------ story 2: 스케일 */
|
|
1064
|
+
|
|
1065
|
+
const OURS = [
|
|
1066
|
+
{
|
|
1067
|
+
name: 'motion.instant',
|
|
1068
|
+
ms: 0,
|
|
1069
|
+
use: '동작 줄이기가 넣는 값. 직접 쓸 일은 없습니다',
|
|
1070
|
+
},
|
|
1071
|
+
{
|
|
1072
|
+
name: 'motion.beat',
|
|
1073
|
+
ms: 60,
|
|
1074
|
+
use: '한 동작을 두 박자로 나누는 간격 (체크마크 · 라디오 점)',
|
|
1075
|
+
},
|
|
1076
|
+
{ name: 'motion.press', ms: 120, use: 'press 프리셋이 씁니다' },
|
|
1077
|
+
{ name: 'motion.base', ms: 300, use: 'travel · spring · presence 진입' },
|
|
1078
|
+
{ name: 'motion.slow', ms: 500, use: '화면을 가로지르는 이동 (프리셋 없음)' },
|
|
1079
|
+
{ name: 'motion.slower', ms: 700, use: '카운트업 (프리셋 없음)' },
|
|
1080
|
+
{
|
|
1081
|
+
name: 'motion.stagger.step',
|
|
1082
|
+
ms: 35,
|
|
1083
|
+
use: '목록 항목 사이 간격 (stagger 프리셋)',
|
|
1084
|
+
},
|
|
1085
|
+
{ name: 'motion.loop.turn', ms: 650, use: '스피너 한 바퀴 (Spinner)' },
|
|
1086
|
+
{
|
|
1087
|
+
name: 'motion.loop.sweep',
|
|
1088
|
+
ms: 1800,
|
|
1089
|
+
use: '컨테이너를 가로지르는 한 번 (ProgressBar indeterminate)',
|
|
1090
|
+
},
|
|
1091
|
+
];
|
|
1092
|
+
|
|
1093
|
+
const CHAKRAS = [
|
|
1094
|
+
{ name: 'fast', ms: 150, use: 'feedback 프리셋 · presence 퇴장' },
|
|
1095
|
+
{ name: 'faster', ms: 100, use: 'presence-anchored 퇴장' },
|
|
1096
|
+
{ name: 'moderate', ms: 200, use: 'presence-anchored 진입' },
|
|
1097
|
+
{ name: 'slow', ms: 300, use: '⚠️ 우리 motion.slow(500ms)와 다른 값' },
|
|
1098
|
+
{ name: 'slower', ms: 400, use: '⚠️ 우리 motion.slower(700ms)와 다른 값' },
|
|
1099
|
+
];
|
|
1100
|
+
|
|
1101
|
+
const CURVES = [
|
|
1102
|
+
{
|
|
1103
|
+
name: 'standard',
|
|
1104
|
+
d: 'M0,100 C40,100 20,0 100,0',
|
|
1105
|
+
half: '50%',
|
|
1106
|
+
use: 'feedback',
|
|
1107
|
+
},
|
|
1108
|
+
{
|
|
1109
|
+
name: 'emphasized',
|
|
1110
|
+
d: 'M0,100 C22,0 36,0 100,0',
|
|
1111
|
+
half: '96%',
|
|
1112
|
+
use: 'press · travel · presence 진입·퇴장',
|
|
1113
|
+
},
|
|
1114
|
+
{
|
|
1115
|
+
name: 'overshoot',
|
|
1116
|
+
d: 'M0,100 C34,-56 64,0 100,0',
|
|
1117
|
+
half: '109%',
|
|
1118
|
+
use: 'spring',
|
|
1119
|
+
},
|
|
1120
|
+
];
|
|
1121
|
+
|
|
1122
|
+
const Track = ({
|
|
1123
|
+
ms,
|
|
1124
|
+
at,
|
|
1125
|
+
ease,
|
|
1126
|
+
}: {
|
|
1127
|
+
ms: number;
|
|
1128
|
+
at: boolean;
|
|
1129
|
+
ease?: string;
|
|
1130
|
+
}) => (
|
|
1131
|
+
<Box
|
|
1132
|
+
position="relative"
|
|
1133
|
+
h="13px"
|
|
1134
|
+
flex="1"
|
|
1135
|
+
minW="110px"
|
|
1136
|
+
bg="bg.subtle"
|
|
1137
|
+
borderRadius="full"
|
|
1138
|
+
>
|
|
1139
|
+
<Box
|
|
1140
|
+
position="absolute"
|
|
1141
|
+
top="1px"
|
|
1142
|
+
left={at ? 'calc(100% - 12px)' : '1px'}
|
|
1143
|
+
w="11px"
|
|
1144
|
+
h="11px"
|
|
1145
|
+
borderRadius="full"
|
|
1146
|
+
bg="primary.main"
|
|
1147
|
+
transitionProperty="left"
|
|
1148
|
+
style={{
|
|
1149
|
+
transitionDuration: `${ms}ms`,
|
|
1150
|
+
transitionTimingFunction: ease ?? 'linear',
|
|
1151
|
+
}}
|
|
1152
|
+
/>
|
|
1153
|
+
</Box>
|
|
1154
|
+
);
|
|
1155
|
+
|
|
1156
|
+
const ScaleRow = ({
|
|
1157
|
+
name,
|
|
1158
|
+
ms,
|
|
1159
|
+
use,
|
|
1160
|
+
at,
|
|
1161
|
+
muted,
|
|
1162
|
+
}: {
|
|
1163
|
+
name: string;
|
|
1164
|
+
ms: number;
|
|
1165
|
+
use: string;
|
|
1166
|
+
at: boolean;
|
|
1167
|
+
muted?: boolean;
|
|
1168
|
+
}) => (
|
|
1169
|
+
<Grid
|
|
1170
|
+
templateColumns={{ base: '150px 56px 1fr', md: '150px 56px 1fr 300px' }}
|
|
1171
|
+
gap={4}
|
|
1172
|
+
alignItems="center"
|
|
1173
|
+
>
|
|
1174
|
+
<Text
|
|
1175
|
+
fontFamily="mono"
|
|
1176
|
+
fontSize="sm"
|
|
1177
|
+
color={muted ? 'fg.muted' : 'fg.default'}
|
|
1178
|
+
mb={0}
|
|
1179
|
+
>
|
|
1180
|
+
{name}
|
|
1181
|
+
</Text>
|
|
1182
|
+
<Text
|
|
1183
|
+
fontFamily="mono"
|
|
1184
|
+
fontSize="sm"
|
|
1185
|
+
color="fg.muted"
|
|
1186
|
+
textAlign="right"
|
|
1187
|
+
mb={0}
|
|
1188
|
+
>
|
|
1189
|
+
{ms}ms
|
|
1190
|
+
</Text>
|
|
1191
|
+
<Track ms={ms} at={at} />
|
|
1192
|
+
<Subtext color="fg.muted" mb={0} display={{ base: 'none', md: 'block' }}>
|
|
1193
|
+
{use}
|
|
1194
|
+
</Subtext>
|
|
1195
|
+
</Grid>
|
|
1196
|
+
);
|
|
1197
|
+
|
|
1198
|
+
/** One of the three situations that land you on this page. */
|
|
1199
|
+
const WhenCase = ({
|
|
1200
|
+
n,
|
|
1201
|
+
title,
|
|
1202
|
+
when,
|
|
1203
|
+
why,
|
|
1204
|
+
code,
|
|
1205
|
+
}: {
|
|
1206
|
+
n: string;
|
|
1207
|
+
title: string;
|
|
1208
|
+
when: string;
|
|
1209
|
+
why: string;
|
|
1210
|
+
code: string;
|
|
1211
|
+
}) => (
|
|
1212
|
+
<Box borderTop="1px solid" borderColor="border.subtle" pt={5}>
|
|
1213
|
+
<HStack gap={2} align="baseline" mb={2}>
|
|
1214
|
+
<Text fontFamily="mono" fontSize="sm" color="fg.muted" mb={0}>
|
|
1215
|
+
{n}
|
|
1216
|
+
</Text>
|
|
1217
|
+
<Text fontWeight="700" mb={0}>
|
|
1218
|
+
{title}
|
|
1219
|
+
</Text>
|
|
1220
|
+
</HStack>
|
|
1221
|
+
<Grid
|
|
1222
|
+
templateColumns={{ base: '1fr', lg: '86px 1fr' }}
|
|
1223
|
+
gap={{ base: 1, lg: 4 }}
|
|
1224
|
+
mb={2}
|
|
1225
|
+
>
|
|
1226
|
+
<Subtext color="fg.muted" fontSize="2xs" mb={0}>
|
|
1227
|
+
이런 상황
|
|
1228
|
+
</Subtext>
|
|
1229
|
+
<Subtext mb={0}>{when}</Subtext>
|
|
1230
|
+
</Grid>
|
|
1231
|
+
<Grid
|
|
1232
|
+
templateColumns={{ base: '1fr', lg: '86px 1fr' }}
|
|
1233
|
+
gap={{ base: 1, lg: 4 }}
|
|
1234
|
+
mb={3}
|
|
1235
|
+
>
|
|
1236
|
+
<Subtext color="fg.muted" fontSize="2xs" mb={0}>
|
|
1237
|
+
여기를 보는 이유
|
|
1238
|
+
</Subtext>
|
|
1239
|
+
<Subtext color="fg.muted" mb={0}>
|
|
1240
|
+
{why}
|
|
1241
|
+
</Subtext>
|
|
1242
|
+
</Grid>
|
|
1243
|
+
<Code>{code}</Code>
|
|
1244
|
+
</Box>
|
|
1245
|
+
);
|
|
1246
|
+
|
|
1247
|
+
/**
|
|
1248
|
+
* The raw scale, for the three cases a preset cannot cover.
|
|
1249
|
+
*
|
|
1250
|
+
* If none of those three is what you are doing, this page is not the one you
|
|
1251
|
+
* need — go back to 고르기.
|
|
1252
|
+
*/
|
|
1253
|
+
export const Scales: Story = {
|
|
1254
|
+
name: '2. 스케일',
|
|
1255
|
+
render: () => {
|
|
1256
|
+
const [at, setAt] = useState(false);
|
|
1257
|
+
const [ms, setMs] = useState(500);
|
|
1258
|
+
const play = () => {
|
|
1259
|
+
setAt(false);
|
|
1260
|
+
requestAnimationFrame(() => requestAnimationFrame(() => setAt(true)));
|
|
1261
|
+
};
|
|
1262
|
+
|
|
1263
|
+
return (
|
|
1264
|
+
<Box p={10} maxW="960px">
|
|
1265
|
+
<H2 mb={2}>스케일</H2>
|
|
1266
|
+
<Text color="fg.muted" mb={7}>
|
|
1267
|
+
여기는 <b>재료</b> 페이지입니다. 컴포넌트에 움직임을 넣는 중이라면{' '}
|
|
1268
|
+
<b>1. 고르기</b>로 가세요. 아래 세 상황에서만 필요합니다.
|
|
1269
|
+
</Text>
|
|
1270
|
+
|
|
1271
|
+
<Stack gap={7} mb={12}>
|
|
1272
|
+
<WhenCase
|
|
1273
|
+
n="1"
|
|
1274
|
+
title="framer-motion을 쓸 때"
|
|
1275
|
+
when="요소가 마운트·언마운트되며 등장하거나 사라질 때, 레이아웃 변화를 따라갈 때, 드래그·제스처 — CSS transition으로는 표현이 안 되는 것들입니다."
|
|
1276
|
+
why="framer-motion은 CSS 변수를 읽지 못하므로 숫자가 필요합니다. 프리셋을 못 쓸 뿐 타이밍 스케일은 그대로 씁니다 — 아래 표의 값을 그대로 가져가세요."
|
|
1277
|
+
code={`import { MOTION_DURATION_S, MOTION_EASE } from '@mindlogic-ai/logician-ui';
|
|
1278
|
+
|
|
1279
|
+
<motion.div transition={{ duration: MOTION_DURATION_S.base, ease: MOTION_EASE.emphasized }} />`}
|
|
1280
|
+
/>
|
|
1281
|
+
<WhenCase
|
|
1282
|
+
n="2"
|
|
1283
|
+
title="keyframe animation을 쓸 때"
|
|
1284
|
+
when="상태가 A에서 B로 바뀌는 게 아니라 스스로 도는 것 — 무한 반복(스피너), 중간 경유점이 필요한 동작(셰이크), 마운트하자마자 한 번 재생(체크마크 그리기)."
|
|
1285
|
+
why="프리셋의 대안이 아닙니다. 프리셋은 transition-*만, keyframe은 animation-*만 건드리므로 한 요소에 둘 다 붙어도 충돌하지 않습니다. 여기서 가져가는 건 duration과 곡선 값뿐입니다."
|
|
1286
|
+
code={`// Spinner.styles.ts — 이 컴포넌트만 쓰는 모션이라 여기 삽니다
|
|
1287
|
+
export const spinAnimation = {
|
|
1288
|
+
animationName: 'spin',
|
|
1289
|
+
animationDuration: 'motion.loop.turn',
|
|
1290
|
+
animationTimingFunction: 'linear',
|
|
1291
|
+
animationIterationCount: 'infinite',
|
|
1292
|
+
_motionReduce: { animationDuration: 'motion.loop.sweep' },
|
|
1293
|
+
};`}
|
|
1294
|
+
/>
|
|
1295
|
+
<WhenCase
|
|
1296
|
+
n="3"
|
|
1297
|
+
title="새 프리셋을 정의할 때"
|
|
1298
|
+
when="일곱 중 어디에도 맞지 않는 의도가 여러 컴포넌트에서 반복될 때. 호출부가 하나뿐이면 만들지 마세요 — 기준은 3. 규칙에 있습니다."
|
|
1299
|
+
why="src/theme/motion.ts에 추가합니다. 아래 스케일에서 duration과 곡선을 골라 조립하면 됩니다. 동작 줄이기 가드를 빠뜨리면 테스트가 잡습니다."
|
|
1300
|
+
code={`reveal: {
|
|
1301
|
+
value: {
|
|
1302
|
+
transitionProperty: 'none',
|
|
1303
|
+
transitionDuration: 'motion.slow',
|
|
1304
|
+
transitionTimingFunction: 'emphasized',
|
|
1305
|
+
_motionReduce: { transitionDuration: 'motion.instant' },
|
|
1306
|
+
},
|
|
1307
|
+
},`}
|
|
1308
|
+
/>
|
|
1309
|
+
</Stack>
|
|
1310
|
+
|
|
1311
|
+
<HStack justify="space-between" align="baseline" mb={4}>
|
|
1312
|
+
<H3 mb={0}>Duration</H3>
|
|
1313
|
+
<Button size="sm" onClick={play}>
|
|
1314
|
+
재생
|
|
1315
|
+
</Button>
|
|
1316
|
+
</HStack>
|
|
1317
|
+
|
|
1318
|
+
<Subtext color="fg.muted" mb={3}>
|
|
1319
|
+
우리 스케일. <code>motion.</code> 접두어가 붙는 이유는 아래 Chakra
|
|
1320
|
+
스케일과 이름이 겹치기 때문입니다.
|
|
1321
|
+
</Subtext>
|
|
1322
|
+
<Stack gap={2} mb={7}>
|
|
1323
|
+
{OURS.map((d) => (
|
|
1324
|
+
<ScaleRow key={d.name} {...d} at={at} />
|
|
1325
|
+
))}
|
|
1326
|
+
</Stack>
|
|
1327
|
+
|
|
1328
|
+
<Subtext color="fg.muted" mb={3}>
|
|
1329
|
+
Chakra 스케일. 그대로 두고 함께 씁니다 — 150ms·200ms는 여기 있으므로
|
|
1330
|
+
우리 쪽에 만들지 않았습니다. <code>slow</code>·<code>slower</code>는
|
|
1331
|
+
이름이 같고 값이 다르니 주의하세요.
|
|
1332
|
+
</Subtext>
|
|
1333
|
+
<Stack gap={2} mb={10}>
|
|
1334
|
+
{CHAKRAS.map((d) => (
|
|
1335
|
+
<ScaleRow key={d.name} {...d} at={at} muted />
|
|
1336
|
+
))}
|
|
1337
|
+
</Stack>
|
|
1338
|
+
|
|
1339
|
+
<HStack justify="space-between" align="baseline" mb={4}>
|
|
1340
|
+
<H3 mb={0}>Easing</H3>
|
|
1341
|
+
<HStack gap={2}>
|
|
1342
|
+
{[300, 500, 2000].map((v) => (
|
|
1343
|
+
<Button
|
|
1344
|
+
key={v}
|
|
1345
|
+
size="xs"
|
|
1346
|
+
variant={ms === v ? 'solid' : 'outline'}
|
|
1347
|
+
onClick={() => setMs(v)}
|
|
1348
|
+
>
|
|
1349
|
+
{v}ms
|
|
1350
|
+
</Button>
|
|
1351
|
+
))}
|
|
1352
|
+
</HStack>
|
|
1353
|
+
</HStack>
|
|
1354
|
+
|
|
1355
|
+
<Grid
|
|
1356
|
+
templateColumns="repeat(auto-fit, minmax(200px, 1fr))"
|
|
1357
|
+
gap={6}
|
|
1358
|
+
mb={6}
|
|
1359
|
+
>
|
|
1360
|
+
{CURVES.map((c) => (
|
|
1361
|
+
<Box key={c.name}>
|
|
1362
|
+
<Box maxW="130px" mb={3}>
|
|
1363
|
+
<svg
|
|
1364
|
+
viewBox="-6 -24 112 130"
|
|
1365
|
+
width="100%"
|
|
1366
|
+
role="img"
|
|
1367
|
+
aria-label={`${c.name} curve`}
|
|
1368
|
+
>
|
|
1369
|
+
<rect
|
|
1370
|
+
x="0"
|
|
1371
|
+
y="0"
|
|
1372
|
+
width="100"
|
|
1373
|
+
height="100"
|
|
1374
|
+
fill="none"
|
|
1375
|
+
stroke="var(--chakra-colors-border-default)"
|
|
1376
|
+
strokeWidth="1.5"
|
|
1377
|
+
/>
|
|
1378
|
+
<path
|
|
1379
|
+
d="M0,100 L100,0"
|
|
1380
|
+
fill="none"
|
|
1381
|
+
stroke="var(--chakra-colors-border-subtle)"
|
|
1382
|
+
strokeWidth="1.5"
|
|
1383
|
+
strokeDasharray="3 4"
|
|
1384
|
+
/>
|
|
1385
|
+
<path
|
|
1386
|
+
d={c.d}
|
|
1387
|
+
fill="none"
|
|
1388
|
+
stroke="var(--chakra-colors-primary-main)"
|
|
1389
|
+
strokeWidth="3.5"
|
|
1390
|
+
strokeLinecap="round"
|
|
1391
|
+
/>
|
|
1392
|
+
</svg>
|
|
1393
|
+
</Box>
|
|
1394
|
+
<Text fontFamily="mono" fontSize="sm" fontWeight="600" mb={1}>
|
|
1395
|
+
{c.name}
|
|
1396
|
+
</Text>
|
|
1397
|
+
<Subtext color="fg.muted" mb={1}>
|
|
1398
|
+
절반 지점에 <b>{c.half}</b> 이동
|
|
1399
|
+
</Subtext>
|
|
1400
|
+
<Subtext color="fg.muted" mb={0}>
|
|
1401
|
+
{c.use}
|
|
1402
|
+
</Subtext>
|
|
1403
|
+
</Box>
|
|
1404
|
+
))}
|
|
1405
|
+
</Grid>
|
|
1406
|
+
|
|
1407
|
+
<Stack gap={3} mb={3}>
|
|
1408
|
+
{CURVES.map((c) => (
|
|
1409
|
+
<Grid
|
|
1410
|
+
key={c.name}
|
|
1411
|
+
templateColumns="110px 1fr"
|
|
1412
|
+
gap={4}
|
|
1413
|
+
alignItems="center"
|
|
1414
|
+
>
|
|
1415
|
+
<Text fontFamily="mono" fontSize="sm" color="fg.muted" mb={0}>
|
|
1416
|
+
{c.name}
|
|
1417
|
+
</Text>
|
|
1418
|
+
<Track
|
|
1419
|
+
ms={ms}
|
|
1420
|
+
at={at}
|
|
1421
|
+
ease={MOTION_EASE_CSS[c.name as keyof typeof MOTION_EASE_CSS]}
|
|
1422
|
+
/>
|
|
1423
|
+
</Grid>
|
|
1424
|
+
))}
|
|
1425
|
+
</Stack>
|
|
1426
|
+
<Subtext color="fg.muted" mb={0}>
|
|
1427
|
+
<code>standard</code>와 <code>emphasized</code>는 그래프로는 크게
|
|
1428
|
+
다르지만 짧은 거리에서는 눈으로 구분되지 않습니다 — 2000ms로 본 뒤
|
|
1429
|
+
300ms로 내려보세요. <code>overshoot</code>만 거리와 무관하게 보입니다.
|
|
1430
|
+
새 프리셋에서 곡선을 고를 때 이게 기준입니다.
|
|
1431
|
+
</Subtext>
|
|
1432
|
+
</Box>
|
|
1433
|
+
);
|
|
1434
|
+
},
|
|
1435
|
+
};
|
|
1436
|
+
|
|
1437
|
+
/* -------------------------------------------------------- story 3: 규칙 */
|
|
1438
|
+
|
|
1439
|
+
/** The five questions a new preset has to answer, and what a "no" means. */
|
|
1440
|
+
const CHECKLIST = [
|
|
1441
|
+
[
|
|
1442
|
+
'호출부가 둘 이상인가',
|
|
1443
|
+
'Spinner 하나만 쓰는 회전이면 Spinner 안에 두세요 — 실제로 그렇게 내려갔습니다. presence가 프리셋인 건 여섯 부품이 같은 시계를 나눠 갖기 때문입니다.',
|
|
1444
|
+
],
|
|
1445
|
+
[
|
|
1446
|
+
'기존 어휘로 정말 안 되는가',
|
|
1447
|
+
'duration과 곡선만 다른 것이라면 새 프리셋이 아니라 기존 프리셋 + 호출부의 transitionProperty입니다.',
|
|
1448
|
+
],
|
|
1449
|
+
[
|
|
1450
|
+
'동작 줄이기에서 무엇이 남는가',
|
|
1451
|
+
'답이 없으면 아직 프리셋이 아닙니다. 루프라면 특히 — duration 0은 답이 아닙니다.',
|
|
1452
|
+
],
|
|
1453
|
+
[
|
|
1454
|
+
'테스트가 그 정책을 강제하는가',
|
|
1455
|
+
'_open이 있으면 _closed도 있어야 하고, 그 _closed가 더 짧아야 합니다. 컴포넌트로 내려간 모션도 동작 줄이기 분기를 갖고 있어야 합니다. 셋 다 이미 CI가 봅니다.',
|
|
1456
|
+
],
|
|
1457
|
+
[
|
|
1458
|
+
'lint 정규식 두 곳을 고쳤는가',
|
|
1459
|
+
'.eslintrc.js의 animationStyle 목록에 없으면 새 이름이 오타로 잡힙니다. 그리고 transition 계열 프리셋이면 scope 가드의 (feedback|travel|spring) 목록에도 넣어야, 호출부가 transitionProperty를 빠뜨렸을 때 잡힙니다. 타입이 못 가는 자리라 둘 다 수동입니다.',
|
|
1460
|
+
],
|
|
1461
|
+
];
|
|
1462
|
+
|
|
1463
|
+
/** Where each motion actually lives, so "왜 여기 없지"가 한 번에 끝나도록. */
|
|
1464
|
+
const MAP = [
|
|
1465
|
+
['press · feedback · travel · spring', 'theme/motion.ts', '전역 어휘'],
|
|
1466
|
+
['presence · stagger · composite', 'theme/motion.ts', '전역 어휘'],
|
|
1467
|
+
['스피너 회전', 'Spinner.styles.ts', '호출부 하나'],
|
|
1468
|
+
['indeterminate 막대', 'ProgressBar.styles.ts', '호출부 하나'],
|
|
1469
|
+
['체크마크 그리기', 'Checkbox.styles.ts', '호출부 하나'],
|
|
1470
|
+
['라디오 점', 'Radio.styles.ts', '호출부 하나'],
|
|
1471
|
+
['세그먼트 인디케이터', 'SegmentedControl.styles.ts', '호출부 하나'],
|
|
1472
|
+
[
|
|
1473
|
+
'모달 진입·퇴장 keyframe',
|
|
1474
|
+
'Modal.styles.ts',
|
|
1475
|
+
'이름만 지역 · 시계는 presence',
|
|
1476
|
+
],
|
|
1477
|
+
[
|
|
1478
|
+
'Pulse · Shake · Appear · Reveal',
|
|
1479
|
+
'components/*',
|
|
1480
|
+
'요소를 만들거나 붙잡아야 해서 컴포넌트',
|
|
1481
|
+
],
|
|
1482
|
+
['FlyTo · Confetti · CountUp · SwapTransition', 'components/*', '위와 같음'],
|
|
1483
|
+
];
|
|
1484
|
+
|
|
1485
|
+
/**
|
|
1486
|
+
* How the vocabulary grows and shrinks.
|
|
1487
|
+
*
|
|
1488
|
+
* A separate story rather than a footnote on 고르기: it is read once, by whoever
|
|
1489
|
+
* is about to add a name, and it should not be in the way of everyone else.
|
|
1490
|
+
*/
|
|
1491
|
+
export const Rules: Story = {
|
|
1492
|
+
name: '3. 규칙',
|
|
1493
|
+
render: () => (
|
|
1494
|
+
<Box p={10} maxW="820px">
|
|
1495
|
+
<H2 mb={2}>규칙</H2>
|
|
1496
|
+
<Text color="fg.muted" mb={8}>
|
|
1497
|
+
<b>
|
|
1498
|
+
새 프리셋에는, 기존 어휘로 표현할 수 없는 실제 호출부가 둘 필요합니다.
|
|
1499
|
+
</b>{' '}
|
|
1500
|
+
하나뿐이라면 그건 프리셋이 아니라 그 컴포넌트의 사정입니다. 프리셋이
|
|
1501
|
+
스무 개가 되면 프리셋이 없는 것과 같습니다 — 고르는 비용이 직접 적는
|
|
1502
|
+
비용을 넘어서는 순간부터 아무도 고르지 않기 때문입니다.
|
|
1503
|
+
</Text>
|
|
1504
|
+
|
|
1505
|
+
<H3 mb={3}>추가하기 전 다섯 가지</H3>
|
|
1506
|
+
<Stack gap={3} mb={10}>
|
|
1507
|
+
{CHECKLIST.map(([q, a]) => (
|
|
1508
|
+
<Box key={q}>
|
|
1509
|
+
<Text fontWeight="600" mb={1}>
|
|
1510
|
+
{q}
|
|
1511
|
+
</Text>
|
|
1512
|
+
<Subtext color="fg.muted" mb={0}>
|
|
1513
|
+
{a}
|
|
1514
|
+
</Subtext>
|
|
1515
|
+
</Box>
|
|
1516
|
+
))}
|
|
1517
|
+
</Stack>
|
|
1518
|
+
|
|
1519
|
+
<H3 mb={1}>지금 어디에 무엇이 있나</H3>
|
|
1520
|
+
<Subtext color="fg.muted" mb={4}>
|
|
1521
|
+
전역 어휘는 일곱 개뿐이고, 나머지는 쓰는 컴포넌트 옆에 삽니다.
|
|
1522
|
+
</Subtext>
|
|
1523
|
+
<Stack gap={2} mb={10}>
|
|
1524
|
+
{MAP.map(([what, where, why]) => (
|
|
1525
|
+
<Grid
|
|
1526
|
+
key={where + what}
|
|
1527
|
+
templateColumns={{ base: '1fr', md: '250px 230px 1fr' }}
|
|
1528
|
+
gap={{ base: 0, md: 4 }}
|
|
1529
|
+
alignItems="baseline"
|
|
1530
|
+
>
|
|
1531
|
+
<Subtext mb={0}>{what}</Subtext>
|
|
1532
|
+
<Text fontFamily="mono" fontSize="xs" color="fg.muted" mb={0}>
|
|
1533
|
+
{where}
|
|
1534
|
+
</Text>
|
|
1535
|
+
<Subtext color="fg.muted" fontSize="2xs" mb={0}>
|
|
1536
|
+
{why}
|
|
1537
|
+
</Subtext>
|
|
1538
|
+
</Grid>
|
|
1539
|
+
))}
|
|
1540
|
+
</Stack>
|
|
1541
|
+
<Subtext color="fg.muted" mb={10}>
|
|
1542
|
+
빼는 것도 같은 규칙입니다. 호출부가 하나로 줄어든 프리셋은 그 컴포넌트로
|
|
1543
|
+
돌려보내세요. 읽는 토큰(<code>motion.loop.*</code> 등)은 내려가도 여전히
|
|
1544
|
+
전역 스케일이고, 지역인 것은 <b>조합</b>뿐입니다.
|
|
1545
|
+
</Subtext>
|
|
1546
|
+
|
|
1547
|
+
<H3 mb={2}>루프는 duration 0으로 끄지 않습니다</H3>
|
|
1548
|
+
<Text color="fg.muted" mb={3}>
|
|
1549
|
+
끝나는 시점을 모르는 동안 계속 도는 움직임은 동작 줄이기의 답이
|
|
1550
|
+
다릅니다. 유한한 전환은 0으로 만들어도 <b>끝 상태가 남지만</b>, 루프는
|
|
1551
|
+
끝 상태가 없어서 0을 주면 주기 한가운데서 얼어붙습니다 — 멈춘 스피너는
|
|
1552
|
+
작동 중이라는 신호가 아니라 죽은 요청으로 읽힙니다.
|
|
1553
|
+
</Text>
|
|
1554
|
+
<Stack gap={2} mb={3} maxW="720px">
|
|
1555
|
+
{[
|
|
1556
|
+
[
|
|
1557
|
+
'스피너 회전',
|
|
1558
|
+
'느려지되 계속 돈다 (650ms → 1800ms)',
|
|
1559
|
+
'작업이 살아 있다는 유일한 신호라서',
|
|
1560
|
+
],
|
|
1561
|
+
[
|
|
1562
|
+
'indeterminate 막대',
|
|
1563
|
+
'멈춘다',
|
|
1564
|
+
'진행 중이라는 사실은 주변 UI가 말한다',
|
|
1565
|
+
],
|
|
1566
|
+
].map(([name, what, why]) => (
|
|
1567
|
+
<Grid
|
|
1568
|
+
key={name}
|
|
1569
|
+
templateColumns={{ base: '1fr', md: '160px 250px 1fr' }}
|
|
1570
|
+
gap={{ base: 1, md: 4 }}
|
|
1571
|
+
alignItems="baseline"
|
|
1572
|
+
>
|
|
1573
|
+
<Subtext mb={0}>{name}</Subtext>
|
|
1574
|
+
<Subtext color="fg.muted" mb={0}>
|
|
1575
|
+
{what}
|
|
1576
|
+
</Subtext>
|
|
1577
|
+
<Subtext color="fg.muted" fontSize="2xs" mb={0}>
|
|
1578
|
+
{why}
|
|
1579
|
+
</Subtext>
|
|
1580
|
+
</Grid>
|
|
1581
|
+
))}
|
|
1582
|
+
</Stack>
|
|
1583
|
+
<Subtext color="fg.muted" mb={10}>
|
|
1584
|
+
WCAG 2.2.2(일시정지 · 정지 · 숨기기)는 자동으로 시작해 5초 넘게 돌고
|
|
1585
|
+
다른 내용과 함께 놓이는 움직임을 다룹니다. 자리표시자에 정지 버튼을 달
|
|
1586
|
+
수 없으니 <code>prefers-reduced-motion</code>에서 실제로 멈추는 것이 그
|
|
1587
|
+
자리를 지키는 방법입니다.
|
|
1588
|
+
</Subtext>
|
|
1589
|
+
|
|
1590
|
+
<H3 mb={2}>둘을 같이 써야 한다면</H3>
|
|
1591
|
+
<Text color="fg.muted" mb={4}>
|
|
1592
|
+
<code>animationStyle</code> 슬롯은 하나뿐이라 이름은 한 번에 하나입니다.
|
|
1593
|
+
그렇다고 요소가 한 가지만 할 수 있는 건 아닙니다 —{' '}
|
|
1594
|
+
<b>transition과 animation은 서로 다른 CSS 속성</b>이라 겹치지 않고 같이
|
|
1595
|
+
돕니다. 프리셋으로 하나를 고르고, 나머지는 그냥 적으세요.
|
|
1596
|
+
</Text>
|
|
1597
|
+
|
|
1598
|
+
<Code>{`<Box
|
|
1599
|
+
animationStyle="presence" // 열림·닫힘 시계 (animation-*)
|
|
1600
|
+
transitionProperty="opacity" // 그와 별개로 도는 전환 (transition-*)
|
|
1601
|
+
transitionDuration="fast"
|
|
1602
|
+
/>`}</Code>
|
|
1603
|
+
|
|
1604
|
+
<Subtext color="fg.muted" mt={4} mb={0}>
|
|
1605
|
+
Chakra 자신이 이렇게 씁니다: 메뉴 레시피가 <code>animationStyle</code>로
|
|
1606
|
+
움직임 <b>이름</b>을 고르고 <code>animationDuration</code>으로{' '}
|
|
1607
|
+
<b>시계</b>를 따로 붙입니다. 우리 <code>presence</code>는 그 반대로
|
|
1608
|
+
시계만 주기 때문에, 레시피가 정한 이름을 덮지 않고 여섯 부품에 동시에
|
|
1609
|
+
앉을 수 있습니다.
|
|
1610
|
+
</Subtext>
|
|
1611
|
+
</Box>
|
|
1612
|
+
),
|
|
1613
|
+
};
|