@rbxts/uiblox 0.1.52 → 0.2.0-alpha.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/README.md +67 -2
- package/out/foundation/guard.d.ts +3 -0
- package/out/foundation/guard.luau +23 -0
- package/out/foundation/index.d.ts +1 -0
- package/out/foundation/init.luau +8 -0
- package/out/hooks/breakpoints.d.ts +10 -0
- package/out/hooks/breakpoints.luau +60 -0
- package/out/hooks/index.d.ts +4 -0
- package/out/hooks/init.luau +10 -0
- package/out/hooks/useBreakpoints.d.ts +6 -0
- package/out/hooks/useBreakpoints.luau +39 -0
- package/out/hooks/useReducedMotion.d.ts +1 -0
- package/out/hooks/useReducedMotion.luau +12 -0
- package/out/index.d.ts +3 -0
- package/out/init.luau +9 -0
- package/out/interaction/index.d.ts +4 -0
- package/out/interaction/init.luau +9 -0
- package/out/interaction/pointerRoute.d.ts +6 -0
- package/out/interaction/pointerRoute.luau +35 -0
- package/out/interaction/usePointer.d.ts +11 -0
- package/out/interaction/usePointer.luau +99 -0
- package/out/theme/constants/ColorConstants.d.ts +0 -3
- package/out/theme/constants/ColorConstants.luau +0 -96
- package/out/theme/context/ThemeProvider.d.ts +3 -0
- package/out/theme/context/ThemeProvider.luau +15 -8
- package/out/theme/context/themeScope.d.ts +5 -0
- package/out/theme/context/themeScope.luau +7 -0
- package/out/theme/hooks/useTheme.luau +15 -14
- package/out/theme/interfaces/density/controlMetrics.d.ts +21 -0
- package/out/theme/interfaces/density/controlMetrics.luau +67 -0
- package/out/theme/interfaces/density/index.d.ts +1 -0
- package/out/theme/interfaces/density/init.luau +7 -0
- package/out/theme/interfaces/index.d.ts +1 -0
- package/out/theme/interfaces/init.luau +3 -0
- package/out/theme/interfaces/palette/Palette.d.ts +39 -18
- package/out/theme/interfaces/palette/colors/index.d.ts +0 -1
- package/out/theme/interfaces/palette/index.d.ts +1 -0
- package/out/theme/interfaces/theme/Theme.d.ts +13 -0
- package/out/theme/interfaces/theme/ThemeConstants.d.ts +0 -18
- package/out/theme/styles/index.d.ts +1 -2
- package/out/theme/styles/init.luau +3 -1
- package/out/theme/styles/types/index.d.ts +0 -1
- package/out/theme/styles/utilities/classNames.d.ts +3 -2
- package/out/theme/styles/utilities/classNames.luau +7 -173
- package/out/theme/styles/utilities/componentStyles.d.ts +7 -0
- package/out/theme/styles/utilities/componentStyles.luau +31 -0
- package/out/theme/styles/utilities/componentTheme.d.ts +20 -0
- package/out/theme/styles/utilities/componentTheme.luau +53 -0
- package/out/theme/styles/utilities/createStyles.d.ts +1 -2
- package/out/theme/styles/utilities/index.d.ts +5 -1
- package/out/theme/styles/utilities/init.luau +7 -1
- package/out/theme/styles/utilities/interaction.d.ts +13 -0
- package/out/theme/styles/utilities/interaction.luau +68 -0
- package/out/theme/styles/utilities/makeStyles.luau +14 -15
- package/out/theme/styles/utilities/styleCache.d.ts +2 -0
- package/out/theme/styles/utilities/styleCache.luau +68 -0
- package/out/theme/styles/utilities/variants.d.ts +19 -0
- package/out/theme/styles/utilities/variants.luau +59 -0
- package/out/theme/themes/DarkTheme.luau +4 -57
- package/out/theme/themes/LightTheme.luau +4 -57
- package/out/theme/themes/createPalette.d.ts +3 -0
- package/out/theme/themes/createPalette.luau +111 -0
- package/out/theme/themes/index.d.ts +1 -0
- package/out/theme/themes/init.luau +3 -0
- package/out/theme/types/types.d.ts +1 -0
- package/out/theme/utilites/colorMath.d.ts +8 -0
- package/out/theme/utilites/colorMath.luau +35 -0
- package/out/theme/utilites/index.d.ts +1 -0
- package/out/theme/utilites/init.luau +6 -0
- package/out/ui/enums/Icons.d.ts +5 -1
- package/out/ui/enums/Icons.luau +4 -0
- package/out/ui/index.d.ts +12 -0
- package/out/ui/init.luau +5 -0
- package/out/ui/packages/accordion/components/Accordion.d.ts +11 -0
- package/out/ui/packages/accordion/components/Accordion.luau +93 -0
- package/out/ui/packages/accordion/components/Accordion.styles.d.ts +4 -0
- package/out/ui/packages/accordion/components/Accordion.styles.luau +65 -0
- package/out/ui/packages/accordion/components/accordionOpen.d.ts +1 -0
- package/out/ui/packages/accordion/components/accordionOpen.luau +10 -0
- package/out/ui/packages/accordion/index.d.ts +2 -0
- package/out/ui/packages/accordion/init.luau +5 -0
- package/out/ui/packages/assetField/components/AssetField.d.ts +10 -0
- package/out/ui/packages/assetField/components/AssetField.luau +75 -0
- package/out/ui/packages/assetField/components/AssetField.styles.d.ts +2 -0
- package/out/ui/packages/assetField/components/AssetField.styles.luau +33 -0
- package/out/ui/packages/assetField/components/assetPreviewUri.d.ts +1 -0
- package/out/ui/packages/assetField/components/assetPreviewUri.luau +25 -0
- package/out/ui/packages/assetField/index.d.ts +2 -0
- package/out/ui/packages/assetField/init.luau +5 -0
- package/out/ui/packages/autocomplete/components/Autocomplete.d.ts +5 -0
- package/out/ui/packages/autocomplete/components/Autocomplete.luau +45 -0
- package/out/ui/packages/autocomplete/components/autocompleteSearchable.d.ts +1 -0
- package/out/ui/packages/autocomplete/components/autocompleteSearchable.luau +7 -0
- package/out/ui/packages/autocomplete/index.d.ts +2 -0
- package/out/ui/packages/autocomplete/init.luau +5 -0
- package/out/ui/packages/avatar/components/Avatar.d.ts +8 -0
- package/out/ui/packages/avatar/components/Avatar.luau +69 -0
- package/out/ui/packages/avatar/components/Avatar.styles.d.ts +4 -0
- package/out/ui/packages/avatar/components/Avatar.styles.luau +39 -0
- package/out/ui/packages/avatar/components/avatarText.d.ts +1 -0
- package/out/ui/packages/avatar/components/avatarText.luau +17 -0
- package/out/ui/packages/avatar/index.d.ts +3 -0
- package/out/ui/packages/avatar/init.luau +6 -0
- package/out/ui/packages/badge/components/Badge.d.ts +10 -0
- package/out/ui/packages/badge/components/Badge.luau +69 -0
- package/out/ui/packages/badge/components/Badge.styles.d.ts +2 -0
- package/out/ui/packages/badge/components/Badge.styles.luau +38 -0
- package/out/ui/packages/badge/components/badgeValue.d.ts +1 -0
- package/out/ui/packages/badge/components/badgeValue.luau +7 -0
- package/out/ui/packages/badge/index.d.ts +3 -0
- package/out/ui/packages/badge/init.luau +6 -0
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.d.ts +11 -0
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.luau +82 -0
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.styles.d.ts +2 -0
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.styles.luau +47 -0
- package/out/ui/packages/breadcrumbs/components/breadcrumbItems.d.ts +1 -0
- package/out/ui/packages/breadcrumbs/components/breadcrumbItems.luau +7 -0
- package/out/ui/packages/breadcrumbs/index.d.ts +2 -0
- package/out/ui/packages/breadcrumbs/init.luau +5 -0
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.d.ts +9 -0
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.luau +234 -0
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.styles.d.ts +2 -0
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.styles.luau +98 -0
- package/out/ui/packages/brickColorPicker/components/brickColorCatalog.d.ts +1 -0
- package/out/ui/packages/brickColorPicker/components/brickColorCatalog.luau +26 -0
- package/out/ui/packages/brickColorPicker/components/brickColorFilter.d.ts +2 -0
- package/out/ui/packages/brickColorPicker/components/brickColorFilter.luau +26 -0
- package/out/ui/packages/brickColorPicker/index.d.ts +3 -0
- package/out/ui/packages/brickColorPicker/init.luau +8 -0
- package/out/ui/packages/button/components/Button.d.ts +4 -0
- package/out/ui/packages/button/components/Button.luau +90 -37
- package/out/ui/packages/button/components/Button.styles.luau +18 -32
- package/out/ui/packages/button/components/activation.d.ts +1 -0
- package/out/ui/packages/button/components/activation.luau +7 -0
- package/out/ui/packages/button/components/buttonLook.d.ts +12 -0
- package/out/ui/packages/button/components/buttonLook.luau +55 -0
- package/out/ui/packages/button/types/ButtonSize.d.ts +1 -1
- package/out/ui/packages/card/components/Card.d.ts +11 -0
- package/out/ui/packages/card/components/Card.luau +74 -0
- package/out/ui/packages/card/components/Card.styles.d.ts +2 -0
- package/out/ui/packages/card/components/Card.styles.luau +66 -0
- package/out/ui/packages/card/index.d.ts +2 -0
- package/out/ui/packages/card/init.luau +5 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.d.ts +8 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.luau +89 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.styles.d.ts +2 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.styles.luau +46 -0
- package/out/ui/packages/cframeEditor/components/cframeValue.d.ts +3 -0
- package/out/ui/packages/cframeEditor/components/cframeValue.luau +15 -0
- package/out/ui/packages/cframeEditor/index.d.ts +2 -0
- package/out/ui/packages/cframeEditor/init.luau +5 -0
- package/out/ui/packages/checkbox/components/Checkbox.d.ts +11 -0
- package/out/ui/packages/checkbox/components/Checkbox.luau +136 -0
- package/out/ui/packages/checkbox/components/Checkbox.styles.d.ts +6 -0
- package/out/ui/packages/checkbox/components/Checkbox.styles.luau +69 -0
- package/out/ui/packages/checkbox/components/checkboxLook.d.ts +5 -0
- package/out/ui/packages/checkbox/components/checkboxLook.luau +52 -0
- package/out/ui/packages/checkbox/components/nextChecked.d.ts +1 -0
- package/out/ui/packages/checkbox/components/nextChecked.luau +7 -0
- package/out/ui/packages/checkbox/index.d.ts +2 -0
- package/out/ui/packages/checkbox/init.luau +5 -0
- package/out/ui/packages/chip/components/Chip.d.ts +9 -0
- package/out/ui/packages/chip/components/Chip.luau +63 -0
- package/out/ui/packages/chip/components/Chip.styles.d.ts +5 -0
- package/out/ui/packages/chip/components/Chip.styles.luau +47 -0
- package/out/ui/packages/chip/index.d.ts +2 -0
- package/out/ui/packages/chip/init.luau +5 -0
- package/out/ui/packages/circularProgress/components/CircularProgress.d.ts +11 -0
- package/out/ui/packages/circularProgress/components/CircularProgress.luau +109 -0
- package/out/ui/packages/circularProgress/index.d.ts +2 -0
- package/out/ui/packages/circularProgress/init.luau +5 -0
- package/out/ui/packages/colorPicker/components/ColorPicker.d.ts +8 -0
- package/out/ui/packages/colorPicker/components/ColorPicker.luau +512 -0
- package/out/ui/packages/colorPicker/components/ColorPicker.styles.d.ts +2 -0
- package/out/ui/packages/colorPicker/components/ColorPicker.styles.luau +145 -0
- package/out/ui/packages/colorPicker/components/ColorSequenceEditor.d.ts +8 -0
- package/out/ui/packages/colorPicker/components/ColorSequenceEditor.luau +190 -0
- package/out/ui/packages/colorPicker/components/NumberSequenceEditor.d.ts +8 -0
- package/out/ui/packages/colorPicker/components/NumberSequenceEditor.luau +240 -0
- package/out/ui/packages/colorPicker/components/colorValue.d.ts +22 -0
- package/out/ui/packages/colorPicker/components/colorValue.luau +157 -0
- package/out/ui/packages/colorPicker/components/sequenceValue.d.ts +26 -0
- package/out/ui/packages/colorPicker/components/sequenceValue.luau +307 -0
- package/out/ui/packages/colorPicker/index.d.ts +11 -0
- package/out/ui/packages/colorPicker/init.luau +37 -0
- package/out/ui/packages/dialog/components/Dialog.d.ts +11 -0
- package/out/ui/packages/dialog/components/Dialog.luau +56 -0
- package/out/ui/packages/dialog/components/Dialog.styles.d.ts +2 -0
- package/out/ui/packages/dialog/components/Dialog.styles.luau +55 -0
- package/out/ui/packages/dialog/index.d.ts +2 -0
- package/out/ui/packages/dialog/init.luau +5 -0
- package/out/ui/packages/divider/components/Divider.luau +6 -0
- package/out/ui/packages/divider/components/Divider.styles.luau +4 -4
- package/out/ui/packages/drawer/components/Drawer.d.ts +11 -0
- package/out/ui/packages/drawer/components/Drawer.luau +77 -0
- package/out/ui/packages/drawer/components/Drawer.styles.d.ts +2 -0
- package/out/ui/packages/drawer/components/Drawer.styles.luau +40 -0
- package/out/ui/packages/drawer/components/drawerPlacement.d.ts +2 -0
- package/out/ui/packages/drawer/components/drawerPlacement.luau +7 -0
- package/out/ui/packages/drawer/index.d.ts +3 -0
- package/out/ui/packages/drawer/init.luau +5 -0
- package/out/ui/packages/enumPicker/components/EnumPicker.d.ts +11 -0
- package/out/ui/packages/enumPicker/components/EnumPicker.luau +42 -0
- package/out/ui/packages/enumPicker/components/enumOptions.d.ts +5 -0
- package/out/ui/packages/enumPicker/components/enumOptions.luau +28 -0
- package/out/ui/packages/enumPicker/index.d.ts +2 -0
- package/out/ui/packages/enumPicker/init.luau +5 -0
- package/out/ui/packages/fontEditor/components/FontEditor.d.ts +8 -0
- package/out/ui/packages/fontEditor/components/FontEditor.luau +223 -0
- package/out/ui/packages/fontEditor/components/FontEditor.styles.d.ts +2 -0
- package/out/ui/packages/fontEditor/components/FontEditor.styles.luau +56 -0
- package/out/ui/packages/fontEditor/components/fontValue.d.ts +10 -0
- package/out/ui/packages/fontEditor/components/fontValue.luau +81 -0
- package/out/ui/packages/fontEditor/index.d.ts +4 -0
- package/out/ui/packages/fontEditor/init.luau +10 -0
- package/out/ui/packages/gradientEditor/components/GradientEditor.d.ts +10 -0
- package/out/ui/packages/gradientEditor/components/GradientEditor.luau +156 -0
- package/out/ui/packages/gradientEditor/components/GradientEditor.styles.d.ts +2 -0
- package/out/ui/packages/gradientEditor/components/GradientEditor.styles.luau +37 -0
- package/out/ui/packages/gradientEditor/components/gradientPatch.d.ts +8 -0
- package/out/ui/packages/gradientEditor/components/gradientPatch.luau +17 -0
- package/out/ui/packages/gradientEditor/components/gradientValue.d.ts +9 -0
- package/out/ui/packages/gradientEditor/components/gradientValue.luau +23 -0
- package/out/ui/packages/gradientEditor/index.d.ts +2 -0
- package/out/ui/packages/gradientEditor/init.luau +5 -0
- package/out/ui/packages/icon/components/Icon.luau +6 -0
- package/out/ui/packages/icon/components/Icon.styles.luau +3 -3
- package/out/ui/packages/iconButton/components/IconButton.d.ts +3 -0
- package/out/ui/packages/iconButton/components/IconButton.luau +53 -5
- package/out/ui/packages/iconButton/components/IconButton.styles.luau +3 -3
- package/out/ui/packages/index.d.ts +46 -0
- package/out/ui/packages/init.luau +138 -0
- package/out/ui/packages/input/components/Input.d.ts +6 -1
- package/out/ui/packages/input/components/Input.luau +137 -54
- package/out/ui/packages/input/components/Input.styles.d.ts +3 -1
- package/out/ui/packages/input/components/Input.styles.luau +74 -52
- package/out/ui/packages/input/components/inputDraft.d.ts +1 -0
- package/out/ui/packages/input/components/inputDraft.luau +17 -0
- package/out/ui/packages/input/components/inputInsets.d.ts +4 -0
- package/out/ui/packages/input/components/inputInsets.luau +10 -0
- package/out/ui/packages/layout/components/Grid.luau +8 -2
- package/out/ui/packages/layout/components/List.luau +8 -2
- package/out/ui/packages/listItem/components/ListItem.d.ts +9 -0
- package/out/ui/packages/listItem/components/ListItem.luau +67 -0
- package/out/ui/packages/listItem/components/ListItem.styles.d.ts +5 -0
- package/out/ui/packages/listItem/components/ListItem.styles.luau +64 -0
- package/out/ui/packages/listItem/index.d.ts +2 -0
- package/out/ui/packages/listItem/init.luau +5 -0
- package/out/ui/packages/loadingStroke/components/LoadingStroke.luau +27 -22
- package/out/ui/packages/menu/components/Menu.d.ts +14 -0
- package/out/ui/packages/menu/components/Menu.luau +60 -0
- package/out/ui/packages/menu/components/Menu.styles.d.ts +2 -0
- package/out/ui/packages/menu/components/Menu.styles.luau +26 -0
- package/out/ui/packages/menu/index.d.ts +2 -0
- package/out/ui/packages/menu/init.luau +5 -0
- package/out/ui/packages/modal/components/Modal.d.ts +9 -0
- package/out/ui/packages/modal/components/Modal.luau +97 -0
- package/out/ui/packages/modal/components/Modal.styles.d.ts +2 -0
- package/out/ui/packages/modal/components/Modal.styles.luau +47 -0
- package/out/ui/packages/modal/components/dismissInput.d.ts +1 -0
- package/out/ui/packages/modal/components/dismissInput.luau +8 -0
- package/out/ui/packages/modal/components/focusTrap.d.ts +2 -0
- package/out/ui/packages/modal/components/focusTrap.luau +22 -0
- package/out/ui/packages/modal/index.d.ts +2 -0
- package/out/ui/packages/modal/init.luau +5 -0
- package/out/ui/packages/motion/duration.d.ts +2 -0
- package/out/ui/packages/motion/duration.luau +17 -0
- package/out/ui/packages/motion/index.d.ts +5 -0
- package/out/ui/packages/motion/init.luau +16 -0
- package/out/ui/packages/motion/loop.d.ts +1 -0
- package/out/ui/packages/motion/loop.luau +18 -0
- package/out/ui/packages/motion/play.d.ts +1 -0
- package/out/ui/packages/motion/play.luau +23 -0
- package/out/ui/packages/motion/resolveReduced.d.ts +1 -0
- package/out/ui/packages/motion/resolveReduced.luau +10 -0
- package/out/ui/packages/motion/unit.d.ts +8 -0
- package/out/ui/packages/motion/unit.luau +80 -0
- package/out/ui/packages/numberInput/components/NumberInput.d.ts +14 -0
- package/out/ui/packages/numberInput/components/NumberInput.luau +44 -0
- package/out/ui/packages/numberInput/components/numberValue.d.ts +2 -0
- package/out/ui/packages/numberInput/components/numberValue.luau +29 -0
- package/out/ui/packages/numberInput/index.d.ts +2 -0
- package/out/ui/packages/numberInput/init.luau +5 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.d.ts +8 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.luau +96 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.styles.d.ts +2 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.styles.luau +41 -0
- package/out/ui/packages/numberRangeEditor/components/numberRangeValue.d.ts +4 -0
- package/out/ui/packages/numberRangeEditor/components/numberRangeValue.luau +16 -0
- package/out/ui/packages/numberRangeEditor/index.d.ts +2 -0
- package/out/ui/packages/numberRangeEditor/init.luau +5 -0
- package/out/ui/packages/pagination/components/Pagination.d.ts +9 -0
- package/out/ui/packages/pagination/components/Pagination.luau +72 -0
- package/out/ui/packages/pagination/components/Pagination.styles.d.ts +2 -0
- package/out/ui/packages/pagination/components/Pagination.styles.luau +39 -0
- package/out/ui/packages/pagination/components/pageRange.d.ts +1 -0
- package/out/ui/packages/pagination/components/pageRange.luau +24 -0
- package/out/ui/packages/pagination/index.d.ts +2 -0
- package/out/ui/packages/pagination/init.luau +5 -0
- package/out/ui/packages/paper/components/Paper.d.ts +8 -0
- package/out/ui/packages/paper/components/Paper.luau +31 -0
- package/out/ui/packages/paper/components/Paper.styles.d.ts +4 -0
- package/out/ui/packages/paper/components/Paper.styles.luau +32 -0
- package/out/ui/packages/paper/index.d.ts +2 -0
- package/out/ui/packages/paper/init.luau +5 -0
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.d.ts +8 -0
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.luau +85 -0
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.styles.d.ts +2 -0
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.styles.luau +46 -0
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.d.ts +3 -0
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.luau +14 -0
- package/out/ui/packages/physicalPropertiesEditor/index.d.ts +2 -0
- package/out/ui/packages/physicalPropertiesEditor/init.luau +5 -0
- package/out/ui/packages/popup/components/Popup.d.ts +13 -0
- package/out/ui/packages/popup/components/Popup.luau +131 -0
- package/out/ui/packages/popup/components/Portal.d.ts +7 -0
- package/out/ui/packages/popup/components/Portal.luau +15 -0
- package/out/ui/packages/popup/components/placement.d.ts +9 -0
- package/out/ui/packages/popup/components/placement.luau +41 -0
- package/out/ui/packages/popup/components/portalTarget.d.ts +1 -0
- package/out/ui/packages/popup/components/portalTarget.luau +13 -0
- package/out/ui/packages/popup/index.d.ts +4 -0
- package/out/ui/packages/popup/init.luau +6 -0
- package/out/ui/packages/preloader/components/Preloader.luau +6 -0
- package/out/ui/packages/preloader/components/Preloader.styles.luau +3 -3
- package/out/ui/packages/progressBar/components/ProgressBar.d.ts +8 -1
- package/out/ui/packages/progressBar/components/ProgressBar.luau +61 -11
- package/out/ui/packages/progressBar/components/ProgressBar.styles.luau +2 -2
- package/out/ui/packages/progressBar/index.d.ts +2 -3
- package/out/ui/packages/progressBar/init.luau +3 -4
- package/out/ui/packages/radioGroup/components/RadioGroup.d.ts +16 -0
- package/out/ui/packages/radioGroup/components/RadioGroup.luau +112 -0
- package/out/ui/packages/radioGroup/components/RadioGroup.styles.d.ts +6 -0
- package/out/ui/packages/radioGroup/components/RadioGroup.styles.luau +66 -0
- package/out/ui/packages/radioGroup/index.d.ts +2 -0
- package/out/ui/packages/radioGroup/init.luau +5 -0
- package/out/ui/packages/rayEditor/components/RayEditor.d.ts +8 -0
- package/out/ui/packages/rayEditor/components/RayEditor.luau +83 -0
- package/out/ui/packages/rayEditor/components/RayEditor.styles.d.ts +2 -0
- package/out/ui/packages/rayEditor/components/RayEditor.styles.luau +37 -0
- package/out/ui/packages/rayEditor/components/rayParts.d.ts +1 -0
- package/out/ui/packages/rayEditor/components/rayParts.luau +10 -0
- package/out/ui/packages/rayEditor/index.d.ts +2 -0
- package/out/ui/packages/rayEditor/init.luau +5 -0
- package/out/ui/packages/rectEditor/components/RectEditor.d.ts +8 -0
- package/out/ui/packages/rectEditor/components/RectEditor.luau +85 -0
- package/out/ui/packages/rectEditor/components/RectEditor.styles.d.ts +2 -0
- package/out/ui/packages/rectEditor/components/RectEditor.styles.luau +46 -0
- package/out/ui/packages/rectEditor/components/rectValue.d.ts +3 -0
- package/out/ui/packages/rectEditor/components/rectValue.luau +14 -0
- package/out/ui/packages/rectEditor/index.d.ts +2 -0
- package/out/ui/packages/rectEditor/init.luau +5 -0
- package/out/ui/packages/scroll/dragScroll.d.ts +8 -0
- package/out/ui/packages/scroll/dragScroll.luau +51 -0
- package/out/ui/packages/scroll/index.d.ts +2 -0
- package/out/ui/packages/scroll/init.luau +5 -0
- package/out/ui/packages/scroll/useDragScroll.d.ts +5 -0
- package/out/ui/packages/scroll/useDragScroll.luau +127 -0
- package/out/ui/packages/select/components/Select.d.ts +15 -0
- package/out/ui/packages/select/components/Select.luau +432 -0
- package/out/ui/packages/select/components/Select.styles.d.ts +6 -0
- package/out/ui/packages/select/components/Select.styles.luau +104 -0
- package/out/ui/packages/select/components/optionLabel.d.ts +1 -0
- package/out/ui/packages/select/components/optionLabel.luau +7 -0
- package/out/ui/packages/select/components/selectFilter.d.ts +4 -0
- package/out/ui/packages/select/components/selectFilter.luau +27 -0
- package/out/ui/packages/select/components/selectFocus.d.ts +4 -0
- package/out/ui/packages/select/components/selectFocus.luau +16 -0
- package/out/ui/packages/select/components/selectGroups.d.ts +18 -0
- package/out/ui/packages/select/components/selectGroups.luau +38 -0
- package/out/ui/packages/select/components/selectKey.d.ts +4 -0
- package/out/ui/packages/select/components/selectKey.luau +14 -0
- package/out/ui/packages/select/components/selectMotion.d.ts +2 -0
- package/out/ui/packages/select/components/selectMotion.luau +12 -0
- package/out/ui/packages/select/components/selectMulti.d.ts +5 -0
- package/out/ui/packages/select/components/selectMulti.luau +26 -0
- package/out/ui/packages/select/components/selectTypeahead.d.ts +4 -0
- package/out/ui/packages/select/components/selectTypeahead.luau +58 -0
- package/out/ui/packages/select/components/stepChoice.d.ts +3 -0
- package/out/ui/packages/select/components/stepChoice.luau +24 -0
- package/out/ui/packages/select/index.d.ts +3 -0
- package/out/ui/packages/select/init.luau +8 -0
- package/out/ui/packages/shadow/components/Shadow.styles.luau +3 -3
- package/out/ui/packages/sidebar/components/Sidebar.luau +6 -0
- package/out/ui/packages/sidebar/components/Sidebar.styles.luau +3 -3
- package/out/ui/packages/skeleton/components/Skeleton.d.ts +15 -0
- package/out/ui/packages/skeleton/components/Skeleton.luau +224 -0
- package/out/ui/packages/skeleton/components/Skeleton.styles.d.ts +2 -0
- package/out/ui/packages/skeleton/components/Skeleton.styles.luau +27 -0
- package/out/ui/packages/skeleton/components/skeletonMotion.d.ts +3 -0
- package/out/ui/packages/skeleton/components/skeletonMotion.luau +17 -0
- package/out/ui/packages/skeleton/index.d.ts +3 -0
- package/out/ui/packages/skeleton/init.luau +7 -0
- package/out/ui/packages/slider/components/Slider.d.ts +13 -0
- package/out/ui/packages/slider/components/Slider.luau +204 -0
- package/out/ui/packages/slider/components/Slider.styles.d.ts +6 -0
- package/out/ui/packages/slider/components/Slider.styles.luau +47 -0
- package/out/ui/packages/slider/components/sliderNudge.d.ts +4 -0
- package/out/ui/packages/slider/components/sliderNudge.luau +39 -0
- package/out/ui/packages/slider/index.d.ts +2 -0
- package/out/ui/packages/slider/init.luau +5 -0
- package/out/ui/packages/snackbar/components/Snackbar.d.ts +11 -0
- package/out/ui/packages/snackbar/components/Snackbar.luau +41 -0
- package/out/ui/packages/snackbar/index.d.ts +2 -0
- package/out/ui/packages/snackbar/init.luau +5 -0
- package/out/ui/packages/splitPane/components/SplitPane.d.ts +14 -0
- package/out/ui/packages/splitPane/components/SplitPane.luau +241 -0
- package/out/ui/packages/splitPane/components/SplitPane.styles.d.ts +2 -0
- package/out/ui/packages/splitPane/components/SplitPane.styles.luau +59 -0
- package/out/ui/packages/splitPane/components/splitLook.d.ts +5 -0
- package/out/ui/packages/splitPane/components/splitLook.luau +49 -0
- package/out/ui/packages/splitPane/components/splitSize.d.ts +10 -0
- package/out/ui/packages/splitPane/components/splitSize.luau +46 -0
- package/out/ui/packages/splitPane/index.d.ts +2 -0
- package/out/ui/packages/splitPane/init.luau +5 -0
- package/out/ui/packages/stateMatrix.d.ts +30 -0
- package/out/ui/packages/stateMatrix.luau +1369 -0
- package/out/ui/packages/stepper/components/Stepper.d.ts +7 -0
- package/out/ui/packages/stepper/components/Stepper.luau +62 -0
- package/out/ui/packages/stepper/components/Stepper.styles.d.ts +2 -0
- package/out/ui/packages/stepper/components/Stepper.styles.luau +39 -0
- package/out/ui/packages/stepper/components/stepState.d.ts +2 -0
- package/out/ui/packages/stepper/components/stepState.luau +13 -0
- package/out/ui/packages/stepper/index.d.ts +3 -0
- package/out/ui/packages/stepper/init.luau +6 -0
- package/out/ui/packages/switch/components/Switch.d.ts +11 -0
- package/out/ui/packages/switch/components/Switch.luau +170 -0
- package/out/ui/packages/switch/components/Switch.styles.d.ts +6 -0
- package/out/ui/packages/switch/components/Switch.styles.luau +62 -0
- package/out/ui/packages/switch/components/switchLook.d.ts +10 -0
- package/out/ui/packages/switch/components/switchLook.luau +63 -0
- package/out/ui/packages/switch/index.d.ts +2 -0
- package/out/ui/packages/switch/init.luau +5 -0
- package/out/ui/packages/table/components/Table.d.ts +9 -0
- package/out/ui/packages/table/components/Table.luau +135 -0
- package/out/ui/packages/table/components/Table.styles.d.ts +2 -0
- package/out/ui/packages/table/components/Table.styles.luau +70 -0
- package/out/ui/packages/table/components/rowSelected.d.ts +1 -0
- package/out/ui/packages/table/components/rowSelected.luau +7 -0
- package/out/ui/packages/table/index.d.ts +2 -0
- package/out/ui/packages/table/init.luau +5 -0
- package/out/ui/packages/tabs/components/Tabs.d.ts +10 -0
- package/out/ui/packages/tabs/components/Tabs.luau +113 -0
- package/out/ui/packages/tabs/components/Tabs.styles.d.ts +2 -0
- package/out/ui/packages/tabs/components/Tabs.styles.luau +55 -0
- package/out/ui/packages/tabs/index.d.ts +2 -0
- package/out/ui/packages/tabs/init.luau +5 -0
- package/out/ui/packages/toast/components/Toast.luau +6 -0
- package/out/ui/packages/toast/components/Toast.styles.luau +23 -10
- package/out/ui/packages/tooltip/components/Tooltip.d.ts +7 -0
- package/out/ui/packages/tooltip/components/Tooltip.luau +119 -0
- package/out/ui/packages/tooltip/components/Tooltip.styles.d.ts +2 -0
- package/out/ui/packages/tooltip/components/Tooltip.styles.luau +43 -0
- package/out/ui/packages/tooltip/index.d.ts +2 -0
- package/out/ui/packages/tooltip/init.luau +5 -0
- package/out/ui/packages/treeView/components/TreeView.d.ts +1 -0
- package/out/ui/packages/treeView/components/TreeView.luau +201 -225
- package/out/ui/packages/treeView/components/TreeView.styles.luau +6 -34
- package/out/ui/packages/treeView/components/treeRows.d.ts +23 -0
- package/out/ui/packages/treeView/components/treeRows.luau +147 -0
- package/out/ui/packages/treeView/interfaces/Branch.d.ts +3 -0
- package/out/ui/packages/treeView/interfaces/Leaf.d.ts +2 -0
- package/out/ui/packages/typography/components/Typography.luau +6 -0
- package/out/ui/packages/typography/components/Typography.styles.luau +8 -11
- package/out/ui/packages/udimEditor/components/UDimEditor.d.ts +8 -0
- package/out/ui/packages/udimEditor/components/UDimEditor.luau +127 -0
- package/out/ui/packages/udimEditor/components/UDimEditor.styles.d.ts +2 -0
- package/out/ui/packages/udimEditor/components/UDimEditor.styles.luau +50 -0
- package/out/ui/packages/udimEditor/index.d.ts +2 -0
- package/out/ui/packages/udimEditor/init.luau +5 -0
- package/out/ui/packages/vectorEditor/components/VectorEditor.d.ts +10 -0
- package/out/ui/packages/vectorEditor/components/VectorEditor.luau +87 -0
- package/out/ui/packages/vectorEditor/components/VectorEditor.styles.d.ts +2 -0
- package/out/ui/packages/vectorEditor/components/VectorEditor.styles.luau +41 -0
- package/out/ui/packages/vectorEditor/components/vectorValue.d.ts +10 -0
- package/out/ui/packages/vectorEditor/components/vectorValue.luau +49 -0
- package/out/ui/packages/vectorEditor/index.d.ts +4 -0
- package/out/ui/packages/vectorEditor/init.luau +11 -0
- package/out/ui/packages/virtualList/components/VirtualList.d.ts +23 -0
- package/out/ui/packages/virtualList/components/VirtualList.luau +178 -0
- package/out/ui/packages/virtualList/components/VirtualList.styles.d.ts +2 -0
- package/out/ui/packages/virtualList/components/VirtualList.styles.luau +29 -0
- package/out/ui/packages/virtualList/components/virtualWindow.d.ts +10 -0
- package/out/ui/packages/virtualList/components/virtualWindow.luau +66 -0
- package/out/ui/packages/virtualList/index.d.ts +2 -0
- package/out/ui/packages/virtualList/init.luau +5 -0
- package/package.json +7 -3
- package/out/theme/interfaces/palette/colors/Colors.d.ts +0 -42
- package/out/theme/interfaces/palette/colors/Colors.luau +0 -2
- package/out/theme/styles/types/ConditionalStylesMap.d.ts +0 -2
- package/out/theme/styles/types/ConditionalStylesMap.luau +0 -2
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local function treeRowLayout(depth, indent, chevronWidth, iconWidth)
|
|
3
|
+
local chevronX = depth * indent
|
|
4
|
+
local iconX = chevronX + chevronWidth
|
|
5
|
+
return {
|
|
6
|
+
chevronX = chevronX,
|
|
7
|
+
iconX = iconX,
|
|
8
|
+
labelX = iconX + iconWidth,
|
|
9
|
+
}
|
|
10
|
+
end
|
|
11
|
+
local function count(list)
|
|
12
|
+
if list == nil then
|
|
13
|
+
return 0
|
|
14
|
+
end
|
|
15
|
+
local total = 0
|
|
16
|
+
for _, _ in list do
|
|
17
|
+
total += 1
|
|
18
|
+
end
|
|
19
|
+
return total
|
|
20
|
+
end
|
|
21
|
+
local function branchHoldsSelection(branchPath, selected)
|
|
22
|
+
if selected == nil or selected == "" or branchPath == "" then
|
|
23
|
+
return false
|
|
24
|
+
end
|
|
25
|
+
if selected == branchPath then
|
|
26
|
+
return true
|
|
27
|
+
end
|
|
28
|
+
local branchParts = string.split(branchPath, "/")
|
|
29
|
+
local selectedParts = string.split(selected, "/")
|
|
30
|
+
if count(branchParts) >= count(selectedParts) then
|
|
31
|
+
return false
|
|
32
|
+
end
|
|
33
|
+
local index = 0
|
|
34
|
+
for _, part in branchParts do
|
|
35
|
+
if selectedParts[index + 1] ~= part then
|
|
36
|
+
return false
|
|
37
|
+
end
|
|
38
|
+
index += 1
|
|
39
|
+
end
|
|
40
|
+
return true
|
|
41
|
+
end
|
|
42
|
+
local function branchHit(branch, matches)
|
|
43
|
+
if matches(branch.title) then
|
|
44
|
+
return true
|
|
45
|
+
end
|
|
46
|
+
for _, leaf in branch.leaves do
|
|
47
|
+
if matches(leaf.title) then
|
|
48
|
+
return true
|
|
49
|
+
end
|
|
50
|
+
end
|
|
51
|
+
for _, child in branch.branches or {} do
|
|
52
|
+
if branchHit(child, matches) then
|
|
53
|
+
return true
|
|
54
|
+
end
|
|
55
|
+
end
|
|
56
|
+
return false
|
|
57
|
+
end
|
|
58
|
+
local function pathsToExpand(branches, matches)
|
|
59
|
+
local paths = {}
|
|
60
|
+
local visit
|
|
61
|
+
visit = function(branch, parentPath)
|
|
62
|
+
local path = if parentPath == "" then branch.title else `{parentPath}/{branch.title}`
|
|
63
|
+
local hit = matches(branch.title)
|
|
64
|
+
for _, leaf in branch.leaves do
|
|
65
|
+
if matches(leaf.title) then
|
|
66
|
+
hit = true
|
|
67
|
+
end
|
|
68
|
+
end
|
|
69
|
+
for _, child in branch.branches or {} do
|
|
70
|
+
if visit(child, path) then
|
|
71
|
+
hit = true
|
|
72
|
+
end
|
|
73
|
+
end
|
|
74
|
+
if hit then
|
|
75
|
+
table.insert(paths, path)
|
|
76
|
+
end
|
|
77
|
+
return hit
|
|
78
|
+
end
|
|
79
|
+
for _, branch in branches do
|
|
80
|
+
visit(branch, "")
|
|
81
|
+
end
|
|
82
|
+
return paths
|
|
83
|
+
end
|
|
84
|
+
local function visibleRows(branches, expanded, selected, clickedPath, matches)
|
|
85
|
+
local rows = {}
|
|
86
|
+
local isOpen = function(path)
|
|
87
|
+
for _, item in expanded do
|
|
88
|
+
if item == path then
|
|
89
|
+
return true
|
|
90
|
+
end
|
|
91
|
+
end
|
|
92
|
+
return false
|
|
93
|
+
end
|
|
94
|
+
local visit
|
|
95
|
+
visit = function(branch, parentPath, depth)
|
|
96
|
+
if matches ~= nil and not branchHit(branch, matches) then
|
|
97
|
+
return nil
|
|
98
|
+
end
|
|
99
|
+
local path = if parentPath == "" then branch.title else `{parentPath}/{branch.title}`
|
|
100
|
+
local expandable = count(branch.leaves) > 0 or count(branch.branches) > 0
|
|
101
|
+
local _arg0 = {
|
|
102
|
+
kind = "branch",
|
|
103
|
+
title = branch.title,
|
|
104
|
+
path = path,
|
|
105
|
+
depth = depth,
|
|
106
|
+
emphasized = if selected ~= nil and selected ~= "" then branchHoldsSelection(path, selected) else clickedPath == path,
|
|
107
|
+
expandable = expandable,
|
|
108
|
+
icon = branch.icon,
|
|
109
|
+
branch = branch,
|
|
110
|
+
}
|
|
111
|
+
table.insert(rows, _arg0)
|
|
112
|
+
if not isOpen(path) then
|
|
113
|
+
return nil
|
|
114
|
+
end
|
|
115
|
+
for _, child in branch.branches or {} do
|
|
116
|
+
visit(child, path, depth + 1)
|
|
117
|
+
end
|
|
118
|
+
local showAllLeaves = matches == nil or matches(branch.title)
|
|
119
|
+
for _, leaf in branch.leaves do
|
|
120
|
+
if not showAllLeaves and not matches(leaf.title) then
|
|
121
|
+
continue
|
|
122
|
+
end
|
|
123
|
+
local leafPath = `{path}/{leaf.title}`
|
|
124
|
+
local _arg0_1 = {
|
|
125
|
+
kind = "leaf",
|
|
126
|
+
title = leaf.title,
|
|
127
|
+
path = leafPath,
|
|
128
|
+
depth = depth + 1,
|
|
129
|
+
emphasized = selected == leafPath,
|
|
130
|
+
expandable = false,
|
|
131
|
+
icon = leaf.icon,
|
|
132
|
+
leaf = leaf,
|
|
133
|
+
}
|
|
134
|
+
table.insert(rows, _arg0_1)
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
for _, branch in branches do
|
|
138
|
+
visit(branch, "", 0)
|
|
139
|
+
end
|
|
140
|
+
return rows
|
|
141
|
+
end
|
|
142
|
+
return {
|
|
143
|
+
treeRowLayout = treeRowLayout,
|
|
144
|
+
branchHoldsSelection = branchHoldsSelection,
|
|
145
|
+
pathsToExpand = pathsToExpand,
|
|
146
|
+
visibleRows = visibleRows,
|
|
147
|
+
}
|
|
@@ -9,6 +9,7 @@ local function Typography(props)
|
|
|
9
9
|
text = ""
|
|
10
10
|
end
|
|
11
11
|
local className = _binding.className
|
|
12
|
+
local sx = _binding.sx
|
|
12
13
|
local children = _binding.children
|
|
13
14
|
local id = _binding.id
|
|
14
15
|
local ref = _binding.ref
|
|
@@ -34,6 +35,11 @@ local function Typography(props)
|
|
|
34
35
|
for _k, _v in variantToken do
|
|
35
36
|
_attributes[_k] = _v
|
|
36
37
|
end
|
|
38
|
+
if sx ~= 0 and sx == sx and sx ~= "" and sx then
|
|
39
|
+
for _k, _v in sx do
|
|
40
|
+
_attributes[_k] = _v
|
|
41
|
+
end
|
|
42
|
+
end
|
|
37
43
|
return React.createElement("textlabel", _attributes, children)
|
|
38
44
|
end
|
|
39
45
|
local default = Typography
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
|
|
4
4
|
local createStyles = _theme.createStyles
|
|
5
|
-
local
|
|
6
|
-
local useTypographyStyles =
|
|
5
|
+
local componentStyles = _theme.componentStyles
|
|
6
|
+
local useTypographyStyles = componentStyles("Typography", function(theme, _param)
|
|
7
7
|
local color = _param.color
|
|
8
8
|
if color == nil then
|
|
9
9
|
color = "initial"
|
|
@@ -29,15 +29,14 @@ local useTypographyStyles = makeStyles(function(theme, _param)
|
|
|
29
29
|
lineClamp = false
|
|
30
30
|
end
|
|
31
31
|
local DEFAULT_COLOR = theme.palette.text.primary
|
|
32
|
-
|
|
33
|
-
local COLOR_TO_PALLETTE_MAP = {
|
|
32
|
+
local COLOR_TO_PALETTE_MAP = {
|
|
34
33
|
initial = DEFAULT_COLOR,
|
|
35
34
|
primary = theme.palette.primary.main,
|
|
36
|
-
secondary = theme.palette.
|
|
35
|
+
secondary = theme.palette.accent.main,
|
|
37
36
|
textPrimary = theme.palette.text.primary,
|
|
38
37
|
textSecondary = theme.palette.text.secondary,
|
|
39
|
-
error = theme.palette.error.main,
|
|
40
|
-
warning = theme.palette.warning.main,
|
|
38
|
+
error = theme.palette.status.error.main,
|
|
39
|
+
warning = theme.palette.status.warning.main,
|
|
41
40
|
}
|
|
42
41
|
local COLOR_TO_PALETTE = function(color, parent)
|
|
43
42
|
if color == "inherit" and parent then
|
|
@@ -47,14 +46,12 @@ local useTypographyStyles = makeStyles(function(theme, _param)
|
|
|
47
46
|
return DEFAULT_COLOR
|
|
48
47
|
end
|
|
49
48
|
local _color = color
|
|
50
|
-
local lookup =
|
|
49
|
+
local lookup = COLOR_TO_PALETTE_MAP[_color]
|
|
51
50
|
return lookup or DEFAULT_COLOR
|
|
52
51
|
end
|
|
53
52
|
local makeRootStyles = function()
|
|
54
53
|
local defaultStyles = {}
|
|
55
|
-
if color
|
|
56
|
-
defaultStyles.TextColor3 = theme.options.constants.colors.caution
|
|
57
|
-
elseif color then
|
|
54
|
+
if color then
|
|
58
55
|
defaultStyles.TextColor3 = COLOR_TO_PALETTE(color)
|
|
59
56
|
end
|
|
60
57
|
repeat
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
2
|
+
export interface UDimEditorProps {
|
|
3
|
+
value: UDim | UDim2;
|
|
4
|
+
onChange: (value: UDim | UDim2) => void;
|
|
5
|
+
disabled?: boolean;
|
|
6
|
+
}
|
|
7
|
+
declare function UDimEditor(props: CustomizedProps<Frame, UDimEditorProps>): JSX.Element;
|
|
8
|
+
export default UDimEditor;
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
+
local NumberInput = TS.import(script, script.Parent.Parent.Parent, "numberInput").NumberInput
|
|
5
|
+
local _vectorValue = TS.import(script, script.Parent.Parent.Parent, "vectorEditor", "components", "vectorValue")
|
|
6
|
+
local writeUDim = _vectorValue.writeUDim
|
|
7
|
+
local writeUDim2 = _vectorValue.writeUDim2
|
|
8
|
+
local useUDimEditorStyles = TS.import(script, script.Parent, "UDimEditor.styles").default
|
|
9
|
+
local function UDimEditor(props)
|
|
10
|
+
local _binding = props
|
|
11
|
+
local value = _binding.value
|
|
12
|
+
local onChange = _binding.onChange
|
|
13
|
+
local disabled = _binding.disabled
|
|
14
|
+
local className = _binding.className
|
|
15
|
+
local sx = _binding.sx
|
|
16
|
+
local id = _binding.id
|
|
17
|
+
local ref = _binding.ref
|
|
18
|
+
local styles = useUDimEditorStyles()
|
|
19
|
+
local isUDim2 = typeof(value) == "UDim2"
|
|
20
|
+
local field = function(key, label, amount, commit, order)
|
|
21
|
+
local _attributes = {
|
|
22
|
+
key = key,
|
|
23
|
+
}
|
|
24
|
+
for _k, _v in styles.field do
|
|
25
|
+
_attributes[_k] = _v
|
|
26
|
+
end
|
|
27
|
+
_attributes.LayoutOrder = order
|
|
28
|
+
local _attributes_1 = table.clone(styles.row)
|
|
29
|
+
setmetatable(_attributes_1, nil)
|
|
30
|
+
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
31
|
+
local _attributes_2 = table.clone(styles.label)
|
|
32
|
+
setmetatable(_attributes_2, nil)
|
|
33
|
+
_attributes_2.Text = label
|
|
34
|
+
local _exp_1 = React.createElement("textlabel", _attributes_2)
|
|
35
|
+
local _attributes_3 = table.clone(styles.input)
|
|
36
|
+
setmetatable(_attributes_3, nil)
|
|
37
|
+
return React.createElement("frame", _attributes, _exp, _exp_1, React.createElement("frame", _attributes_3, React.createElement(NumberInput, {
|
|
38
|
+
value = amount,
|
|
39
|
+
disabled = disabled,
|
|
40
|
+
width = UDim.new(1, 0),
|
|
41
|
+
onChange = commit,
|
|
42
|
+
})))
|
|
43
|
+
end
|
|
44
|
+
local _attributes = {}
|
|
45
|
+
local _condition = id
|
|
46
|
+
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
47
|
+
_condition = "UDimEditor"
|
|
48
|
+
end
|
|
49
|
+
_attributes.key = _condition
|
|
50
|
+
_attributes.ref = ref
|
|
51
|
+
for _k, _v in styles.root do
|
|
52
|
+
_attributes[_k] = _v
|
|
53
|
+
end
|
|
54
|
+
if className then
|
|
55
|
+
for _k, _v in className do
|
|
56
|
+
_attributes[_k] = _v
|
|
57
|
+
end
|
|
58
|
+
end
|
|
59
|
+
if sx then
|
|
60
|
+
for _k, _v in sx do
|
|
61
|
+
_attributes[_k] = _v
|
|
62
|
+
end
|
|
63
|
+
end
|
|
64
|
+
local _attributes_1 = table.clone(styles.column)
|
|
65
|
+
setmetatable(_attributes_1, nil)
|
|
66
|
+
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
67
|
+
local _result
|
|
68
|
+
if isUDim2 then
|
|
69
|
+
local _attributes_2 = table.clone(styles.column)
|
|
70
|
+
setmetatable(_attributes_2, nil)
|
|
71
|
+
local _exp_1 = React.createElement("uilistlayout", _attributes_2)
|
|
72
|
+
local _attributes_3 = {
|
|
73
|
+
key = "X",
|
|
74
|
+
}
|
|
75
|
+
for _k, _v in styles.axis do
|
|
76
|
+
_attributes_3[_k] = _v
|
|
77
|
+
end
|
|
78
|
+
_attributes_3.LayoutOrder = 1
|
|
79
|
+
local _attributes_4 = table.clone(styles.row)
|
|
80
|
+
setmetatable(_attributes_4, nil)
|
|
81
|
+
local _exp_2 = React.createElement("frame", _attributes_3, React.createElement("uilistlayout", _attributes_4), field("XS", "XS", value.X.Scale, function(amount)
|
|
82
|
+
return onChange(writeUDim2(value, "X", "Scale", amount))
|
|
83
|
+
end, 1), field("XO", "XO", value.X.Offset, function(amount)
|
|
84
|
+
return onChange(writeUDim2(value, "X", "Offset", amount))
|
|
85
|
+
end, 2))
|
|
86
|
+
local _attributes_5 = {
|
|
87
|
+
key = "Y",
|
|
88
|
+
}
|
|
89
|
+
for _k, _v in styles.axis do
|
|
90
|
+
_attributes_5[_k] = _v
|
|
91
|
+
end
|
|
92
|
+
_attributes_5.LayoutOrder = 2
|
|
93
|
+
local _attributes_6 = table.clone(styles.row)
|
|
94
|
+
setmetatable(_attributes_6, nil)
|
|
95
|
+
_result = (React.createElement("frame", {
|
|
96
|
+
key = "Axes",
|
|
97
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
98
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
99
|
+
BackgroundTransparency = 1,
|
|
100
|
+
LayoutOrder = 1,
|
|
101
|
+
}, _exp_1, _exp_2, React.createElement("frame", _attributes_5, React.createElement("uilistlayout", _attributes_6), field("YS", "YS", value.Y.Scale, function(amount)
|
|
102
|
+
return onChange(writeUDim2(value, "Y", "Scale", amount))
|
|
103
|
+
end, 1), field("YO", "YO", value.Y.Offset, function(amount)
|
|
104
|
+
return onChange(writeUDim2(value, "Y", "Offset", amount))
|
|
105
|
+
end, 2))))
|
|
106
|
+
else
|
|
107
|
+
local _attributes_2 = {
|
|
108
|
+
key = "UDim",
|
|
109
|
+
}
|
|
110
|
+
for _k, _v in styles.axis do
|
|
111
|
+
_attributes_2[_k] = _v
|
|
112
|
+
end
|
|
113
|
+
_attributes_2.LayoutOrder = 1
|
|
114
|
+
local _attributes_3 = table.clone(styles.row)
|
|
115
|
+
setmetatable(_attributes_3, nil)
|
|
116
|
+
_result = (React.createElement("frame", _attributes_2, React.createElement("uilistlayout", _attributes_3), field("S", "S", value.Scale, function(amount)
|
|
117
|
+
return onChange(writeUDim(value, "Scale", amount))
|
|
118
|
+
end, 1), field("O", "O", value.Offset, function(amount)
|
|
119
|
+
return onChange(writeUDim(value, "Offset", amount))
|
|
120
|
+
end, 2)))
|
|
121
|
+
end
|
|
122
|
+
return React.createElement("frame", _attributes, _exp, _result)
|
|
123
|
+
end
|
|
124
|
+
local default = UDimEditor
|
|
125
|
+
return {
|
|
126
|
+
default = default,
|
|
127
|
+
}
|
|
@@ -0,0 +1,50 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
|
|
4
|
+
local createStyles = _theme.createStyles
|
|
5
|
+
local componentStyles = _theme.componentStyles
|
|
6
|
+
local useUDimEditorStyles = componentStyles("UDimEditor", function(theme)
|
|
7
|
+
return createStyles({
|
|
8
|
+
root = {
|
|
9
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
10
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
11
|
+
BackgroundTransparency = 1,
|
|
12
|
+
BorderSizePixel = 0,
|
|
13
|
+
},
|
|
14
|
+
column = {
|
|
15
|
+
FillDirection = Enum.FillDirection.Vertical,
|
|
16
|
+
Padding = UDim.new(0, theme.padding.calc(1)),
|
|
17
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
18
|
+
},
|
|
19
|
+
row = {
|
|
20
|
+
FillDirection = Enum.FillDirection.Horizontal,
|
|
21
|
+
Padding = UDim.new(0, theme.padding.calc(1)),
|
|
22
|
+
VerticalAlignment = Enum.VerticalAlignment.Center,
|
|
23
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
24
|
+
},
|
|
25
|
+
axis = {
|
|
26
|
+
Size = UDim2.new(1, 0, 0, theme.spacing.calc(2)),
|
|
27
|
+
BackgroundTransparency = 1,
|
|
28
|
+
},
|
|
29
|
+
field = {
|
|
30
|
+
Size = UDim2.new(0.5, -theme.padding.calc(1), 0, theme.spacing.calc(2)),
|
|
31
|
+
BackgroundTransparency = 1,
|
|
32
|
+
},
|
|
33
|
+
label = {
|
|
34
|
+
Size = UDim2.new(0, theme.spacing.calc(2), 1, 0),
|
|
35
|
+
BackgroundTransparency = 1,
|
|
36
|
+
Font = theme.typography.fontFamilies.default,
|
|
37
|
+
TextSize = theme.typography.fontSizes.caption,
|
|
38
|
+
TextColor3 = theme.palette.text.secondary,
|
|
39
|
+
TextXAlignment = Enum.TextXAlignment.Left,
|
|
40
|
+
},
|
|
41
|
+
input = {
|
|
42
|
+
Size = UDim2.new(1, -theme.spacing.calc(2), 1, 0),
|
|
43
|
+
BackgroundTransparency = 1,
|
|
44
|
+
},
|
|
45
|
+
})
|
|
46
|
+
end)
|
|
47
|
+
local default = useUDimEditorStyles
|
|
48
|
+
return {
|
|
49
|
+
default = default,
|
|
50
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
2
|
+
import { AxisKey } from "./vectorValue";
|
|
3
|
+
export interface VectorEditorProps {
|
|
4
|
+
value: Vector2 | Vector3;
|
|
5
|
+
onChange: (value: Vector2 | Vector3) => void;
|
|
6
|
+
axes?: AxisKey[];
|
|
7
|
+
disabled?: boolean;
|
|
8
|
+
}
|
|
9
|
+
declare function VectorEditor(props: CustomizedProps<Frame, VectorEditorProps>): JSX.Element;
|
|
10
|
+
export default VectorEditor;
|
|
@@ -0,0 +1,87 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
+
local NumberInput = TS.import(script, script.Parent.Parent.Parent, "numberInput").NumberInput
|
|
5
|
+
local useVectorEditorStyles = TS.import(script, script.Parent, "VectorEditor.styles").default
|
|
6
|
+
local _vectorValue = TS.import(script, script.Parent, "vectorValue")
|
|
7
|
+
local readAxis = _vectorValue.readAxis
|
|
8
|
+
local writeVector2 = _vectorValue.writeVector2
|
|
9
|
+
local writeVector3 = _vectorValue.writeVector3
|
|
10
|
+
local function VectorEditor(props)
|
|
11
|
+
local _binding = props
|
|
12
|
+
local value = _binding.value
|
|
13
|
+
local onChange = _binding.onChange
|
|
14
|
+
local disabled = _binding.disabled
|
|
15
|
+
local className = _binding.className
|
|
16
|
+
local sx = _binding.sx
|
|
17
|
+
local id = _binding.id
|
|
18
|
+
local ref = _binding.ref
|
|
19
|
+
local styles = useVectorEditorStyles()
|
|
20
|
+
local isVector3 = typeof(value) == "Vector3"
|
|
21
|
+
local axes = props.axes or (if isVector3 then ({ "X", "Y", "Z" }) else ({ "X", "Y" }))
|
|
22
|
+
local _attributes = {}
|
|
23
|
+
local _condition = id
|
|
24
|
+
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
25
|
+
_condition = "VectorEditor"
|
|
26
|
+
end
|
|
27
|
+
_attributes.key = _condition
|
|
28
|
+
_attributes.ref = ref
|
|
29
|
+
for _k, _v in styles.root do
|
|
30
|
+
_attributes[_k] = _v
|
|
31
|
+
end
|
|
32
|
+
if className then
|
|
33
|
+
for _k, _v in className do
|
|
34
|
+
_attributes[_k] = _v
|
|
35
|
+
end
|
|
36
|
+
end
|
|
37
|
+
if sx then
|
|
38
|
+
for _k, _v in sx do
|
|
39
|
+
_attributes[_k] = _v
|
|
40
|
+
end
|
|
41
|
+
end
|
|
42
|
+
local _attributes_1 = table.clone(styles.row)
|
|
43
|
+
setmetatable(_attributes_1, nil)
|
|
44
|
+
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
45
|
+
-- ▼ ReadonlyArray.map ▼
|
|
46
|
+
local _newValue = table.create(#axes)
|
|
47
|
+
local _callback = function(axis, index)
|
|
48
|
+
local _attributes_2 = {
|
|
49
|
+
key = axis,
|
|
50
|
+
}
|
|
51
|
+
for _k, _v in styles.axis do
|
|
52
|
+
_attributes_2[_k] = _v
|
|
53
|
+
end
|
|
54
|
+
_attributes_2.Size = UDim2.new(1 / #axes, 0, 0, 32)
|
|
55
|
+
_attributes_2.LayoutOrder = index + 1
|
|
56
|
+
local _attributes_3 = table.clone(styles.row)
|
|
57
|
+
setmetatable(_attributes_3, nil)
|
|
58
|
+
local _exp_1 = React.createElement("uilistlayout", _attributes_3)
|
|
59
|
+
local _attributes_4 = table.clone(styles.label)
|
|
60
|
+
setmetatable(_attributes_4, nil)
|
|
61
|
+
_attributes_4.Text = axis
|
|
62
|
+
local _exp_2 = React.createElement("textlabel", _attributes_4)
|
|
63
|
+
local _attributes_5 = table.clone(styles.field)
|
|
64
|
+
setmetatable(_attributes_5, nil)
|
|
65
|
+
return React.createElement("frame", _attributes_2, _exp_1, _exp_2, React.createElement("frame", _attributes_5, React.createElement(NumberInput, {
|
|
66
|
+
value = readAxis(value, axis),
|
|
67
|
+
disabled = disabled,
|
|
68
|
+
width = UDim.new(1, 0),
|
|
69
|
+
onChange = function(amount)
|
|
70
|
+
if isVector3 then
|
|
71
|
+
onChange(writeVector3(value, axis, amount))
|
|
72
|
+
elseif axis == "X" or axis == "Y" then
|
|
73
|
+
onChange(writeVector2(value, axis, amount))
|
|
74
|
+
end
|
|
75
|
+
end,
|
|
76
|
+
})))
|
|
77
|
+
end
|
|
78
|
+
for _k, _v in axes do
|
|
79
|
+
_newValue[_k] = _callback(_v, _k - 1, axes)
|
|
80
|
+
end
|
|
81
|
+
-- ▲ ReadonlyArray.map ▲
|
|
82
|
+
return React.createElement("frame", _attributes, _exp, _newValue)
|
|
83
|
+
end
|
|
84
|
+
local default = VectorEditor
|
|
85
|
+
return {
|
|
86
|
+
default = default,
|
|
87
|
+
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
|
|
4
|
+
local createStyles = _theme.createStyles
|
|
5
|
+
local componentStyles = _theme.componentStyles
|
|
6
|
+
local useVectorEditorStyles = componentStyles("VectorEditor", function(theme)
|
|
7
|
+
return createStyles({
|
|
8
|
+
root = {
|
|
9
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
10
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
11
|
+
BackgroundTransparency = 1,
|
|
12
|
+
BorderSizePixel = 0,
|
|
13
|
+
},
|
|
14
|
+
row = {
|
|
15
|
+
FillDirection = Enum.FillDirection.Horizontal,
|
|
16
|
+
Padding = UDim.new(0, theme.padding.calc(1)),
|
|
17
|
+
VerticalAlignment = Enum.VerticalAlignment.Center,
|
|
18
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
19
|
+
},
|
|
20
|
+
axis = {
|
|
21
|
+
Size = UDim2.new(1, 0, 0, theme.spacing.calc(2)),
|
|
22
|
+
BackgroundTransparency = 1,
|
|
23
|
+
},
|
|
24
|
+
label = {
|
|
25
|
+
Size = UDim2.new(0, theme.spacing.calc(1.5), 1, 0),
|
|
26
|
+
BackgroundTransparency = 1,
|
|
27
|
+
Font = theme.typography.fontFamilies.default,
|
|
28
|
+
TextSize = theme.typography.fontSizes.caption,
|
|
29
|
+
TextColor3 = theme.palette.text.secondary,
|
|
30
|
+
TextXAlignment = Enum.TextXAlignment.Left,
|
|
31
|
+
},
|
|
32
|
+
field = {
|
|
33
|
+
Size = UDim2.new(1, -theme.spacing.calc(1.5), 1, 0),
|
|
34
|
+
BackgroundTransparency = 1,
|
|
35
|
+
},
|
|
36
|
+
})
|
|
37
|
+
end)
|
|
38
|
+
local default = useVectorEditorStyles
|
|
39
|
+
return {
|
|
40
|
+
default = default,
|
|
41
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export type AxisKey = "X" | "Y" | "Z";
|
|
2
|
+
export declare function readAxis(value: {
|
|
3
|
+
X: number;
|
|
4
|
+
Y: number;
|
|
5
|
+
Z?: number;
|
|
6
|
+
}, axis: AxisKey): number;
|
|
7
|
+
export declare function writeVector2(value: Vector2, axis: "X" | "Y", amount: number): Vector2;
|
|
8
|
+
export declare function writeVector3(value: Vector3, axis: AxisKey, amount: number): Vector3;
|
|
9
|
+
export declare function writeUDim(value: UDim, field: "Scale" | "Offset", amount: number): UDim;
|
|
10
|
+
export declare function writeUDim2(value: UDim2, axis: "X" | "Y", field: "Scale" | "Offset", amount: number): UDim2;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local function readAxis(value, axis)
|
|
3
|
+
if axis == "X" then
|
|
4
|
+
return value.X
|
|
5
|
+
end
|
|
6
|
+
if axis == "Y" then
|
|
7
|
+
return value.Y
|
|
8
|
+
end
|
|
9
|
+
local _condition = value.Z
|
|
10
|
+
if _condition == nil then
|
|
11
|
+
_condition = 0
|
|
12
|
+
end
|
|
13
|
+
return _condition
|
|
14
|
+
end
|
|
15
|
+
local function writeVector2(value, axis, amount)
|
|
16
|
+
if axis == "X" then
|
|
17
|
+
return Vector2.new(amount, value.Y)
|
|
18
|
+
end
|
|
19
|
+
return Vector2.new(value.X, amount)
|
|
20
|
+
end
|
|
21
|
+
local function writeVector3(value, axis, amount)
|
|
22
|
+
if axis == "X" then
|
|
23
|
+
return Vector3.new(amount, value.Y, value.Z)
|
|
24
|
+
end
|
|
25
|
+
if axis == "Y" then
|
|
26
|
+
return Vector3.new(value.X, amount, value.Z)
|
|
27
|
+
end
|
|
28
|
+
return Vector3.new(value.X, value.Y, amount)
|
|
29
|
+
end
|
|
30
|
+
local function writeUDim(value, field, amount)
|
|
31
|
+
if field == "Scale" then
|
|
32
|
+
return UDim.new(amount, value.Offset)
|
|
33
|
+
end
|
|
34
|
+
return UDim.new(value.Scale, amount)
|
|
35
|
+
end
|
|
36
|
+
local function writeUDim2(value, axis, field, amount)
|
|
37
|
+
local xScale = if axis == "X" and field == "Scale" then amount else value.X.Scale
|
|
38
|
+
local xOffset = if axis == "X" and field == "Offset" then amount else value.X.Offset
|
|
39
|
+
local yScale = if axis == "Y" and field == "Scale" then amount else value.Y.Scale
|
|
40
|
+
local yOffset = if axis == "Y" and field == "Offset" then amount else value.Y.Offset
|
|
41
|
+
return UDim2.new(xScale, xOffset, yScale, yOffset)
|
|
42
|
+
end
|
|
43
|
+
return {
|
|
44
|
+
readAxis = readAxis,
|
|
45
|
+
writeVector2 = writeVector2,
|
|
46
|
+
writeVector3 = writeVector3,
|
|
47
|
+
writeUDim = writeUDim,
|
|
48
|
+
writeUDim2 = writeUDim2,
|
|
49
|
+
}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
export { default as VectorEditor } from "./components/VectorEditor";
|
|
2
|
+
export { VectorEditorProps } from "./components/VectorEditor";
|
|
3
|
+
export { readAxis, writeUDim, writeUDim2, writeVector2, writeVector3, } from "./components/vectorValue";
|
|
4
|
+
export { AxisKey } from "./components/vectorValue";
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local exports = {}
|
|
4
|
+
exports.VectorEditor = TS.import(script, script, "components", "VectorEditor").default
|
|
5
|
+
local _vectorValue = TS.import(script, script, "components", "vectorValue")
|
|
6
|
+
exports.readAxis = _vectorValue.readAxis
|
|
7
|
+
exports.writeUDim = _vectorValue.writeUDim
|
|
8
|
+
exports.writeUDim2 = _vectorValue.writeUDim2
|
|
9
|
+
exports.writeVector2 = _vectorValue.writeVector2
|
|
10
|
+
exports.writeVector3 = _vectorValue.writeVector3
|
|
11
|
+
return exports
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import React from "@rbxts/react";
|
|
2
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
3
|
+
import { type VirtualListAlign } from "./virtualWindow";
|
|
4
|
+
export type { VirtualListAlign };
|
|
5
|
+
export interface VirtualListItemState {
|
|
6
|
+
index: number;
|
|
7
|
+
}
|
|
8
|
+
export interface VirtualListHandle {
|
|
9
|
+
scrollToIndex: (index: number, align?: VirtualListAlign) => void;
|
|
10
|
+
ensureVisible: (index: number, align?: VirtualListAlign) => void;
|
|
11
|
+
suppressClick: () => boolean;
|
|
12
|
+
}
|
|
13
|
+
export interface VirtualListProps<T> {
|
|
14
|
+
items: ReadonlyArray<T>;
|
|
15
|
+
getKey: (item: T, index: number) => string;
|
|
16
|
+
renderItem: (item: T, index: number, state: VirtualListItemState) => React.Element;
|
|
17
|
+
itemHeight: number;
|
|
18
|
+
overscan?: number;
|
|
19
|
+
listRef?: React.MutableRefObject<VirtualListHandle | undefined>;
|
|
20
|
+
empty?: React.Element;
|
|
21
|
+
}
|
|
22
|
+
declare function VirtualList<T>(props: CustomizedProps<ScrollingFrame, VirtualListProps<T>>): JSX.Element;
|
|
23
|
+
export default VirtualList;
|