@rbxts/uiblox 0.2.0-alpha.36 → 0.2.0-alpha.38
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -18
- package/out/theme/constants/NumberConstants.d.ts +10 -0
- package/out/theme/constants/NumberConstants.luau +12 -0
- package/out/theme/interfaces/density/controlMetrics.luau +2 -2
- package/out/theme/interfaces/palette/Palette.d.ts +7 -0
- package/out/theme/interfaces/spacing/Shape.d.ts +6 -0
- package/out/theme/interfaces/theme/Theme.d.ts +6 -0
- package/out/theme/interfaces/typography/FontFamilies.luau +1 -0
- package/out/theme/interfaces/typography/FontFamilyOptions.d.ts +1 -1
- package/out/theme/interfaces/typography/FontSizeOptions.d.ts +1 -1
- package/out/theme/interfaces/typography/FontSizes.luau +2 -0
- package/out/theme/interfaces/typography/Variants.d.ts +3 -1
- package/out/theme/interfaces/typography/Variants.luau +25 -1
- package/out/theme/styles/utilities/focusRing.d.ts +7 -0
- package/out/theme/styles/utilities/focusRing.luau +14 -0
- package/out/theme/styles/utilities/index.d.ts +1 -0
- package/out/theme/styles/utilities/init.luau +3 -0
- package/out/theme/styles/utilities/resolveSx.d.ts +6 -1
- package/out/theme/styles/utilities/resolveSx.luau +53 -12
- package/out/theme/themes/DarkTheme.luau +4 -0
- package/out/theme/themes/LightTheme.luau +4 -0
- package/out/theme/themes/createPalette.luau +15 -0
- package/out/ui/packages/accordion/components/Accordion.d.ts +1 -0
- package/out/ui/packages/accordion/components/Accordion.luau +112 -32
- package/out/ui/packages/accordion/components/Accordion.styles.luau +70 -32
- package/out/ui/packages/accordion/components/accordionNote.d.ts +2 -0
- package/out/ui/packages/accordion/components/accordionNote.luau +11 -0
- package/out/ui/packages/alert/components/Alert.d.ts +2 -0
- package/out/ui/packages/alert/components/Alert.luau +39 -12
- package/out/ui/packages/alert/components/Alert.styles.luau +44 -22
- package/out/ui/packages/alert/components/alertAction.d.ts +2 -0
- package/out/ui/packages/alert/components/alertAction.luau +11 -0
- package/out/ui/packages/appBar/components/AppBar.d.ts +1 -0
- package/out/ui/packages/appBar/components/AppBar.luau +88 -22
- package/out/ui/packages/appBar/components/AppBar.styles.luau +41 -11
- package/out/ui/packages/appBar/components/appBarSubtitle.d.ts +2 -0
- package/out/ui/packages/appBar/components/appBarSubtitle.luau +11 -0
- package/out/ui/packages/autocomplete/components/Autocomplete.luau +4 -0
- package/out/ui/packages/avatar/components/Avatar.d.ts +2 -0
- package/out/ui/packages/avatar/components/Avatar.luau +9 -2
- package/out/ui/packages/avatar/components/Avatar.styles.luau +7 -0
- package/out/ui/packages/avatarGroup/components/AvatarGroup.d.ts +14 -0
- package/out/ui/packages/avatarGroup/components/AvatarGroup.luau +107 -0
- package/out/ui/packages/avatarGroup/components/AvatarGroup.styles.d.ts +6 -0
- package/out/ui/packages/avatarGroup/components/AvatarGroup.styles.luau +55 -0
- package/out/ui/packages/avatarGroup/components/avatarGroupCut.d.ts +2 -0
- package/out/ui/packages/avatarGroup/components/avatarGroupCut.luau +11 -0
- package/out/ui/packages/avatarGroup/index.d.ts +3 -0
- package/out/ui/packages/avatarGroup/init.luau +6 -0
- package/out/ui/packages/badge/components/Badge.luau +14 -11
- package/out/ui/packages/badge/components/Badge.styles.luau +5 -1
- package/out/ui/packages/bottomNavigation/components/BottomNavigation.d.ts +4 -1
- package/out/ui/packages/bottomNavigation/components/BottomNavigation.luau +19 -1
- package/out/ui/packages/bottomNavigation/components/BottomNavigation.styles.luau +24 -3
- package/out/ui/packages/bottomNavigation/components/navBadge.d.ts +2 -0
- package/out/ui/packages/bottomNavigation/components/navBadge.luau +14 -0
- package/out/ui/packages/bottomNavigation/index.d.ts +1 -1
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.luau +21 -6
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.styles.luau +10 -0
- package/out/ui/packages/breadcrumbs/components/breadcrumbItems.d.ts +2 -0
- package/out/ui/packages/breadcrumbs/components/breadcrumbItems.luau +8 -0
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.luau +20 -2
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.styles.luau +72 -66
- package/out/ui/packages/button/components/Button.d.ts +2 -0
- package/out/ui/packages/button/components/Button.luau +112 -36
- package/out/ui/packages/button/components/Button.styles.luau +2 -0
- package/out/ui/packages/button/components/buttonLook.d.ts +2 -0
- package/out/ui/packages/button/components/buttonLook.luau +11 -0
- package/out/ui/packages/button/components/buttonPaint.d.ts +16 -0
- package/out/ui/packages/button/components/buttonPaint.luau +70 -0
- package/out/ui/packages/buttonGroup/components/ButtonGroup.d.ts +14 -0
- package/out/ui/packages/buttonGroup/components/ButtonGroup.luau +117 -0
- package/out/ui/packages/buttonGroup/components/ButtonGroup.styles.d.ts +5 -0
- package/out/ui/packages/buttonGroup/components/ButtonGroup.styles.luau +57 -0
- package/out/ui/packages/buttonGroup/components/buttonGroupEdge.d.ts +2 -0
- package/out/ui/packages/buttonGroup/components/buttonGroupEdge.luau +16 -0
- package/out/ui/packages/buttonGroup/index.d.ts +3 -0
- package/out/ui/packages/buttonGroup/init.luau +6 -0
- package/out/ui/packages/card/components/Card.d.ts +1 -0
- package/out/ui/packages/card/components/Card.luau +21 -2
- package/out/ui/packages/card/components/Card.styles.d.ts +3 -1
- package/out/ui/packages/card/components/Card.styles.luau +20 -9
- package/out/ui/packages/card/components/cardWidth.d.ts +10 -0
- package/out/ui/packages/card/components/cardWidth.luau +36 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.luau +18 -5
- package/out/ui/packages/cframeEditor/components/CFrameEditor.styles.luau +50 -32
- package/out/ui/packages/cframeEditor/components/cframeValue.d.ts +1 -0
- package/out/ui/packages/cframeEditor/components/cframeValue.luau +13 -0
- package/out/ui/packages/checkbox/components/Checkbox.luau +7 -5
- package/out/ui/packages/checkbox/components/Checkbox.styles.luau +2 -0
- package/out/ui/packages/checkbox/components/checkboxLook.d.ts +2 -2
- package/out/ui/packages/checkbox/components/checkboxLook.luau +2 -2
- package/out/ui/packages/chip/components/Chip.luau +16 -14
- package/out/ui/packages/chip/components/Chip.styles.d.ts +2 -1
- package/out/ui/packages/chip/components/Chip.styles.luau +15 -9
- package/out/ui/packages/chip/components/chipTone.d.ts +3 -0
- package/out/ui/packages/chip/components/chipTone.luau +11 -0
- package/out/ui/packages/circularProgress/components/CircularProgress.luau +10 -3
- package/out/ui/packages/codeEditor/components/CodeEditor.d.ts +12 -0
- package/out/ui/packages/codeEditor/components/CodeEditor.luau +262 -0
- package/out/ui/packages/codeEditor/components/CodeEditor.styles.d.ts +6 -0
- package/out/ui/packages/codeEditor/components/CodeEditor.styles.luau +124 -0
- package/out/ui/packages/codeEditor/highlightCode.d.ts +11 -0
- package/out/ui/packages/codeEditor/highlightCode.luau +503 -0
- package/out/ui/packages/codeEditor/index.d.ts +2 -0
- package/out/ui/packages/codeEditor/init.luau +5 -0
- package/out/ui/packages/collapse/components/Collapse.d.ts +8 -0
- package/out/ui/packages/collapse/components/Collapse.luau +34 -0
- package/out/ui/packages/collapse/components/Collapse.styles.d.ts +2 -0
- package/out/ui/packages/collapse/components/Collapse.styles.luau +20 -0
- package/out/ui/packages/collapse/components/collapseOpen.d.ts +1 -0
- package/out/ui/packages/collapse/components/collapseOpen.luau +7 -0
- package/out/ui/packages/collapse/index.d.ts +3 -0
- package/out/ui/packages/collapse/init.luau +6 -0
- package/out/ui/packages/colorPicker/components/ColorPicker.luau +9 -1
- package/out/ui/packages/colorPicker/components/ColorPicker.styles.luau +74 -67
- package/out/ui/packages/colorPicker/components/ColorSequenceEditor.luau +16 -6
- package/out/ui/packages/colorPicker/components/NumberSequenceEditor.luau +16 -6
- package/out/ui/packages/colorPicker/components/sequenceValue.d.ts +2 -0
- package/out/ui/packages/colorPicker/components/sequenceValue.luau +8 -0
- package/out/ui/packages/colorPicker/index.d.ts +1 -1
- package/out/ui/packages/colorPicker/init.luau +2 -0
- package/out/ui/packages/copyButton/components/CopyButton.d.ts +8 -0
- package/out/ui/packages/copyButton/components/CopyButton.luau +32 -0
- package/out/ui/packages/copyButton/components/copyInvoke.d.ts +2 -0
- package/out/ui/packages/copyButton/components/copyInvoke.luau +12 -0
- package/out/ui/packages/copyButton/index.d.ts +3 -0
- package/out/ui/packages/copyButton/init.luau +6 -0
- package/out/ui/packages/cover/components/Cover.d.ts +8 -0
- package/out/ui/packages/cover/components/Cover.luau +47 -0
- package/out/ui/packages/cover/components/coverFill.d.ts +2 -0
- package/out/ui/packages/cover/components/coverFill.luau +14 -0
- package/out/ui/packages/cover/index.d.ts +3 -0
- package/out/ui/packages/cover/init.luau +6 -0
- package/out/ui/packages/dateRange/components/DateRangePicker.d.ts +3 -0
- package/out/ui/packages/dateRange/components/DateRangePicker.luau +186 -95
- package/out/ui/packages/dateRange/dateRangeValue.d.ts +5 -0
- package/out/ui/packages/dateRange/dateRangeValue.luau +34 -0
- package/out/ui/packages/dateRange/index.d.ts +1 -1
- package/out/ui/packages/dateRange/init.luau +3 -0
- package/out/ui/packages/dialog/components/Dialog.d.ts +1 -0
- package/out/ui/packages/dialog/components/Dialog.luau +55 -6
- package/out/ui/packages/dialog/components/Dialog.styles.luau +9 -5
- package/out/ui/packages/dialog/components/dialogWidth.d.ts +7 -0
- package/out/ui/packages/dialog/components/dialogWidth.luau +35 -0
- package/out/ui/packages/divider/components/Divider.luau +60 -13
- package/out/ui/packages/divider/components/Divider.styles.luau +1 -0
- package/out/ui/packages/divider/components/dividerLabel.d.ts +2 -0
- package/out/ui/packages/divider/components/dividerLabel.luau +11 -0
- package/out/ui/packages/drawer/components/Drawer.d.ts +2 -0
- package/out/ui/packages/drawer/components/Drawer.luau +51 -7
- package/out/ui/packages/drawer/components/Drawer.styles.luau +13 -5
- package/out/ui/packages/drawer/components/drawerPlacement.d.ts +15 -1
- package/out/ui/packages/drawer/components/drawerPlacement.luau +46 -0
- package/out/ui/packages/editorFace.d.ts +22 -0
- package/out/ui/packages/editorFace.luau +49 -0
- package/out/ui/packages/fab/components/Fab.luau +19 -6
- package/out/ui/packages/fab/components/Fab.styles.luau +4 -3
- package/out/ui/packages/fontEditor/components/FontEditor.luau +13 -3
- package/out/ui/packages/fontEditor/components/FontEditor.styles.luau +36 -27
- package/out/ui/packages/gradientEditor/components/GradientEditor.luau +21 -13
- package/out/ui/packages/gradientEditor/components/GradientEditor.styles.luau +52 -44
- package/out/ui/packages/icon/components/DrawnGlyph.d.ts +11 -0
- package/out/ui/packages/icon/components/DrawnGlyph.luau +87 -0
- package/out/ui/packages/icon/components/Icon.d.ts +6 -2
- package/out/ui/packages/icon/components/Icon.luau +23 -3
- package/out/ui/packages/icon/components/Icon.styles.luau +3 -0
- package/out/ui/packages/icon/components/glyphs.d.ts +28 -0
- package/out/ui/packages/icon/components/glyphs.luau +64 -0
- package/out/ui/packages/icon/index.d.ts +1 -0
- package/out/ui/packages/iconButton/components/IconButton.d.ts +6 -1
- package/out/ui/packages/iconButton/components/IconButton.luau +112 -11
- package/out/ui/packages/iconButton/components/IconButton.styles.luau +4 -27
- package/out/ui/packages/iconButton/components/iconButtonBox.d.ts +11 -0
- package/out/ui/packages/iconButton/components/iconButtonBox.luau +48 -0
- package/out/ui/packages/iconButton/components/transportGlyph.d.ts +10 -0
- package/out/ui/packages/iconButton/components/transportGlyph.luau +77 -0
- package/out/ui/packages/imageList/components/ImageList.d.ts +4 -0
- package/out/ui/packages/imageList/components/ImageList.luau +28 -7
- package/out/ui/packages/imageList/components/ImageList.styles.d.ts +1 -0
- package/out/ui/packages/imageList/components/ImageList.styles.luau +17 -10
- package/out/ui/packages/imageList/components/imageListLayout.d.ts +8 -0
- package/out/ui/packages/imageList/components/imageListLayout.luau +36 -0
- package/out/ui/packages/index.d.ts +12 -0
- package/out/ui/packages/init.luau +36 -0
- package/out/ui/packages/input/components/Input.d.ts +4 -0
- package/out/ui/packages/input/components/Input.luau +74 -37
- package/out/ui/packages/input/components/Input.styles.d.ts +1 -0
- package/out/ui/packages/input/components/Input.styles.luau +45 -18
- package/out/ui/packages/input/components/clampText.d.ts +2 -0
- package/out/ui/packages/input/components/clampText.luau +16 -0
- package/out/ui/packages/input/components/fieldChrome.d.ts +5 -0
- package/out/ui/packages/input/components/fieldChrome.luau +11 -0
- package/out/ui/packages/input/components/multilineHeight.d.ts +1 -0
- package/out/ui/packages/input/components/multilineHeight.luau +11 -0
- package/out/ui/packages/layout/components/Box.luau +92 -13
- package/out/ui/packages/layout/components/Box.styles.d.ts +0 -2
- package/out/ui/packages/layout/components/Box.styles.luau +0 -9
- package/out/ui/packages/layout/components/Grid.luau +81 -16
- package/out/ui/packages/layout/components/Pad.d.ts +24 -0
- package/out/ui/packages/layout/components/Pad.luau +88 -0
- package/out/ui/packages/layout/components/Stack.luau +79 -13
- package/out/ui/packages/link/components/Link.luau +17 -7
- package/out/ui/packages/link/components/Link.styles.d.ts +0 -1
- package/out/ui/packages/link/components/Link.styles.luau +3 -5
- package/out/ui/packages/listItem/components/ListItem.d.ts +6 -0
- package/out/ui/packages/listItem/components/ListItem.luau +155 -40
- package/out/ui/packages/listItem/components/ListItem.styles.d.ts +4 -0
- package/out/ui/packages/listItem/components/ListItem.styles.luau +70 -31
- package/out/ui/packages/listItem/components/listItemInk.d.ts +3 -0
- package/out/ui/packages/listItem/components/listItemInk.luau +14 -0
- package/out/ui/packages/listItem/components/listItemLayout.d.ts +22 -0
- package/out/ui/packages/listItem/components/listItemLayout.luau +68 -0
- package/out/ui/packages/markdown/components/Markdown.d.ts +2 -0
- package/out/ui/packages/markdown/components/Markdown.luau +244 -46
- package/out/ui/packages/markdown/components/Markdown.styles.luau +125 -51
- package/out/ui/packages/markdown/components/MarkdownEditor.luau +215 -146
- package/out/ui/packages/markdown/components/MarkdownEditor.styles.d.ts +1 -0
- package/out/ui/packages/markdown/components/MarkdownEditor.styles.luau +153 -83
- package/out/ui/packages/markdown/index.d.ts +2 -2
- package/out/ui/packages/markdown/init.luau +2 -0
- package/out/ui/packages/markdown/parseMarkdown.d.ts +30 -2
- package/out/ui/packages/markdown/parseMarkdown.luau +453 -25
- package/out/ui/packages/menu/components/Menu.d.ts +4 -1
- package/out/ui/packages/menu/components/Menu.luau +76 -28
- package/out/ui/packages/menu/components/Menu.styles.luau +6 -1
- package/out/ui/packages/menu/components/menuIcon.d.ts +6 -0
- package/out/ui/packages/menu/components/menuIcon.luau +32 -0
- package/out/ui/packages/numberInput/components/NumberInput.d.ts +1 -0
- package/out/ui/packages/numberInput/components/NumberInput.luau +82 -1
- package/out/ui/packages/numberInput/components/numberValue.d.ts +2 -0
- package/out/ui/packages/numberInput/components/numberValue.luau +10 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.luau +9 -1
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.styles.luau +23 -16
- package/out/ui/packages/pager/components/Pager.d.ts +11 -0
- package/out/ui/packages/pager/components/Pager.luau +114 -0
- package/out/ui/packages/pager/components/Pager.styles.d.ts +2 -0
- package/out/ui/packages/pager/components/Pager.styles.luau +66 -0
- package/out/ui/packages/pager/components/pagerStep.d.ts +3 -0
- package/out/ui/packages/pager/components/pagerStep.luau +24 -0
- package/out/ui/packages/pager/index.d.ts +3 -0
- package/out/ui/packages/pager/init.luau +9 -0
- package/out/ui/packages/pagination/components/Pagination.styles.luau +4 -1
- package/out/ui/packages/paper/components/Paper.luau +17 -11
- package/out/ui/packages/paper/components/Paper.styles.luau +12 -5
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.luau +14 -1
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.styles.luau +24 -19
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.d.ts +5 -0
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.luau +22 -0
- package/out/ui/packages/popover/components/Popover.d.ts +12 -0
- package/out/ui/packages/popover/components/Popover.luau +52 -0
- package/out/ui/packages/popover/components/Popover.styles.d.ts +2 -0
- package/out/ui/packages/popover/components/Popover.styles.luau +32 -0
- package/out/ui/packages/popover/index.d.ts +2 -0
- package/out/ui/packages/popover/init.luau +5 -0
- package/out/ui/packages/popup/components/Popup.d.ts +2 -0
- package/out/ui/packages/popup/components/Popup.luau +64 -2
- package/out/ui/packages/popup/components/placement.luau +6 -4
- package/out/ui/packages/progressBar/components/ProgressBar.luau +1 -1
- package/out/ui/packages/progressBar/components/ProgressBar.styles.luau +3 -2
- package/out/ui/packages/radioGroup/components/RadioGroup.d.ts +4 -1
- package/out/ui/packages/radioGroup/components/RadioGroup.luau +53 -9
- package/out/ui/packages/radioGroup/components/RadioGroup.styles.luau +26 -2
- package/out/ui/packages/radioGroup/components/radioHint.d.ts +2 -0
- package/out/ui/packages/radioGroup/components/radioHint.luau +11 -0
- package/out/ui/packages/radioGroup/index.d.ts +1 -1
- package/out/ui/packages/rating/components/Rating.d.ts +1 -1
- package/out/ui/packages/rating/components/Rating.luau +48 -4
- package/out/ui/packages/rating/components/Rating.styles.luau +1 -1
- package/out/ui/packages/rating/components/ratingCommit.d.ts +2 -0
- package/out/ui/packages/rating/components/ratingCommit.luau +11 -0
- package/out/ui/packages/rayEditor/components/RayEditor.luau +9 -1
- package/out/ui/packages/rayEditor/components/RayEditor.styles.luau +17 -11
- package/out/ui/packages/rectEditor/components/RectEditor.luau +9 -1
- package/out/ui/packages/rectEditor/components/RectEditor.styles.luau +49 -42
- package/out/ui/packages/scroll/components/ScrollView.luau +76 -7
- package/out/ui/packages/select/components/Select.d.ts +2 -0
- package/out/ui/packages/select/components/Select.luau +164 -105
- package/out/ui/packages/select/components/Select.styles.d.ts +2 -0
- package/out/ui/packages/select/components/Select.styles.luau +30 -9
- package/out/ui/packages/select/components/selectWidth.d.ts +2 -0
- package/out/ui/packages/select/components/selectWidth.luau +15 -0
- package/out/ui/packages/shadow/components/Shadow.luau +202 -21
- package/out/ui/packages/sidebar/components/Sidebar.styles.luau +1 -0
- package/out/ui/packages/skeleton/components/Skeleton.luau +4 -0
- package/out/ui/packages/slider/components/RangeSlider.d.ts +16 -0
- package/out/ui/packages/slider/components/RangeSlider.luau +232 -0
- package/out/ui/packages/slider/components/RangeSlider.styles.d.ts +7 -0
- package/out/ui/packages/slider/components/RangeSlider.styles.luau +48 -0
- package/out/ui/packages/slider/components/Slider.d.ts +1 -0
- package/out/ui/packages/slider/components/Slider.luau +53 -25
- package/out/ui/packages/slider/components/Slider.styles.d.ts +1 -0
- package/out/ui/packages/slider/components/Slider.styles.luau +19 -5
- package/out/ui/packages/slider/components/rangeValue.d.ts +21 -0
- package/out/ui/packages/slider/components/rangeValue.luau +77 -0
- package/out/ui/packages/slider/components/sliderLabel.d.ts +4 -0
- package/out/ui/packages/slider/components/sliderLabel.luau +30 -0
- package/out/ui/packages/slider/index.d.ts +3 -0
- package/out/ui/packages/slider/init.luau +6 -0
- package/out/ui/packages/snackbar/components/Snackbar.d.ts +1 -0
- package/out/ui/packages/snackbar/components/Snackbar.luau +2 -0
- package/out/ui/packages/sparkline/components/Sparkline.d.ts +3 -0
- package/out/ui/packages/sparkline/components/Sparkline.luau +72 -8
- package/out/ui/packages/sparkline/index.d.ts +1 -1
- package/out/ui/packages/sparkline/init.luau +6 -1
- package/out/ui/packages/sparkline/sparklineLayout.d.ts +17 -0
- package/out/ui/packages/sparkline/sparklineLayout.luau +132 -8
- package/out/ui/packages/speedDial/components/SpeedDial.d.ts +1 -0
- package/out/ui/packages/speedDial/components/SpeedDial.luau +59 -9
- package/out/ui/packages/speedDial/components/SpeedDial.styles.d.ts +1 -0
- package/out/ui/packages/speedDial/components/SpeedDial.styles.luau +50 -3
- package/out/ui/packages/speedDial/components/speedDialLabel.d.ts +4 -0
- package/out/ui/packages/speedDial/components/speedDialLabel.luau +16 -0
- package/out/ui/packages/splitPane/components/splitLook.d.ts +1 -1
- package/out/ui/packages/stateMatrix.d.ts +1 -0
- package/out/ui/packages/stateMatrix.luau +9 -0
- package/out/ui/packages/stepper/components/Stepper.d.ts +2 -0
- package/out/ui/packages/stepper/components/Stepper.luau +35 -7
- package/out/ui/packages/stepper/components/Stepper.styles.luau +12 -6
- package/out/ui/packages/stepper/components/stepState.d.ts +4 -2
- package/out/ui/packages/stepper/components/stepState.luau +12 -1
- package/out/ui/packages/stepper/index.d.ts +1 -1
- package/out/ui/packages/stepper/init.luau +3 -1
- package/out/ui/packages/switch/components/Switch.luau +2 -2
- package/out/ui/packages/switch/components/Switch.styles.luau +2 -5
- package/out/ui/packages/switch/components/switchLook.d.ts +3 -3
- package/out/ui/packages/switch/components/switchLook.luau +4 -10
- package/out/ui/packages/table/components/Table.d.ts +1 -0
- package/out/ui/packages/table/components/Table.luau +99 -57
- package/out/ui/packages/table/components/Table.styles.luau +23 -6
- package/out/ui/packages/table/components/tableColumns.d.ts +2 -0
- package/out/ui/packages/table/components/tableColumns.luau +2 -0
- package/out/ui/packages/table/components/tableSort.d.ts +2 -0
- package/out/ui/packages/table/components/tableSort.luau +95 -0
- package/out/ui/packages/table/index.d.ts +1 -0
- package/out/ui/packages/table/init.luau +1 -0
- package/out/ui/packages/tabs/components/Tabs.luau +77 -6
- package/out/ui/packages/tabs/components/Tabs.styles.luau +12 -11
- package/out/ui/packages/tabs/components/tabIndicator.d.ts +7 -0
- package/out/ui/packages/tabs/components/tabIndicator.luau +21 -0
- package/out/ui/packages/tabs/components/tabScroll.d.ts +2 -0
- package/out/ui/packages/tabs/components/tabScroll.luau +18 -0
- package/out/ui/packages/text/components/Text.d.ts +9 -0
- package/out/ui/packages/text/components/Text.luau +64 -0
- package/out/ui/packages/text/components/textBox.d.ts +12 -0
- package/out/ui/packages/text/components/textBox.luau +21 -0
- package/out/ui/packages/text/index.d.ts +2 -0
- package/out/ui/packages/text/init.luau +5 -0
- package/out/ui/packages/timeField/components/TimeField.d.ts +13 -0
- package/out/ui/packages/timeField/components/TimeField.luau +106 -0
- package/out/ui/packages/timeField/index.d.ts +4 -0
- package/out/ui/packages/timeField/init.luau +9 -0
- package/out/ui/packages/timeField/timeValue.d.ts +8 -0
- package/out/ui/packages/timeField/timeValue.luau +49 -0
- package/out/ui/packages/timeline/components/Timeline.d.ts +12 -0
- package/out/ui/packages/timeline/components/Timeline.luau +102 -0
- package/out/ui/packages/timeline/components/Timeline.styles.d.ts +2 -0
- package/out/ui/packages/timeline/components/Timeline.styles.luau +115 -0
- package/out/ui/packages/timeline/components/timelineRail.d.ts +4 -0
- package/out/ui/packages/timeline/components/timelineRail.luau +15 -0
- package/out/ui/packages/timeline/index.d.ts +3 -0
- package/out/ui/packages/timeline/init.luau +8 -0
- package/out/ui/packages/toast/components/Toast.d.ts +1 -0
- package/out/ui/packages/toast/components/Toast.luau +200 -57
- package/out/ui/packages/toast/components/Toast.styles.luau +40 -20
- package/out/ui/packages/toast/components/toastPlace.d.ts +16 -0
- package/out/ui/packages/toast/components/toastPlace.luau +44 -0
- package/out/ui/packages/toast/enums/ToastVariants.d.ts +2 -1
- package/out/ui/packages/toast/enums/ToastVariants.luau +1 -0
- package/out/ui/packages/toggleButton/components/ToggleButton.luau +43 -4
- package/out/ui/packages/toggleButton/components/ToggleButton.styles.luau +1 -1
- package/out/ui/packages/tooltip/components/Tooltip.d.ts +1 -0
- package/out/ui/packages/tooltip/components/Tooltip.luau +109 -31
- package/out/ui/packages/tooltip/components/Tooltip.styles.luau +31 -1
- package/out/ui/packages/tooltip/components/tooltipBox.d.ts +4 -0
- package/out/ui/packages/tooltip/components/tooltipBox.luau +12 -0
- package/out/ui/packages/tooltip/components/tooltipPointer.d.ts +2 -0
- package/out/ui/packages/tooltip/components/tooltipPointer.luau +11 -0
- package/out/ui/packages/treeView/components/TreeView.luau +12 -13
- package/out/ui/packages/treeView/components/TreeView.styles.luau +6 -0
- package/out/ui/packages/typography/components/Typography.d.ts +2 -0
- package/out/ui/packages/typography/components/Typography.luau +8 -0
- package/out/ui/packages/typography/components/Typography.styles.luau +3 -1
- package/out/ui/packages/udimEditor/components/UDimEditor.luau +9 -1
- package/out/ui/packages/udimEditor/components/UDimEditor.styles.luau +25 -18
- package/out/ui/packages/vectorEditor/components/VectorEditor.luau +18 -3
- package/out/ui/packages/vectorEditor/components/VectorEditor.styles.luau +30 -16
- package/out/ui/packages/virtualList/components/VirtualList.styles.luau +1 -0
- package/out/ui/packages/weekGrid/components/WeekGrid.d.ts +24 -0
- package/out/ui/packages/weekGrid/components/WeekGrid.luau +187 -0
- package/out/ui/packages/weekGrid/components/weekColumns.d.ts +9 -0
- package/out/ui/packages/weekGrid/components/weekColumns.luau +25 -0
- package/out/ui/packages/weekGrid/index.d.ts +3 -0
- package/out/ui/packages/weekGrid/init.luau +8 -0
- package/package.json +2 -2
|
@@ -1,12 +1,8 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
|
-
|
|
3
|
-
local function sparklineLayout(values, width, height, pad)
|
|
4
|
-
if pad == nil then
|
|
5
|
-
pad = 4
|
|
6
|
-
end
|
|
2
|
+
local function sparklinePoints(values, width, height, pad)
|
|
7
3
|
local count = #values
|
|
8
4
|
if count < 2 or width <= pad * 2 or height <= pad * 2 then
|
|
9
|
-
return
|
|
5
|
+
return nil
|
|
10
6
|
end
|
|
11
7
|
local min = values[1]
|
|
12
8
|
local max = values[1]
|
|
@@ -42,7 +38,22 @@ local function sparklineLayout(values, width, height, pad)
|
|
|
42
38
|
table.insert(points, _arg0)
|
|
43
39
|
end
|
|
44
40
|
end
|
|
41
|
+
return {
|
|
42
|
+
points = points,
|
|
43
|
+
baseline = pad + innerH,
|
|
44
|
+
}
|
|
45
|
+
end
|
|
46
|
+
--* Line segments for a number series. Empty and single-point series draw nothing.
|
|
47
|
+
local function sparklineLayout(values, width, height, pad)
|
|
48
|
+
if pad == nil then
|
|
49
|
+
pad = 4
|
|
50
|
+
end
|
|
51
|
+
local laid = sparklinePoints(values, width, height, pad)
|
|
52
|
+
if laid == nil then
|
|
53
|
+
return {}
|
|
54
|
+
end
|
|
45
55
|
local segments = {}
|
|
56
|
+
local count = #laid.points
|
|
46
57
|
do
|
|
47
58
|
local index = 0
|
|
48
59
|
local _shouldIncrement = false
|
|
@@ -55,8 +66,8 @@ local function sparklineLayout(values, width, height, pad)
|
|
|
55
66
|
if not (index < count - 1) then
|
|
56
67
|
break
|
|
57
68
|
end
|
|
58
|
-
local start = points[index + 1]
|
|
59
|
-
local finish = points[index + 2]
|
|
69
|
+
local start = laid.points[index + 1]
|
|
70
|
+
local finish = laid.points[index + 2]
|
|
60
71
|
local dx = finish.x - start.x
|
|
61
72
|
local dy = finish.y - start.y
|
|
62
73
|
local _arg0 = {
|
|
@@ -70,6 +81,119 @@ local function sparklineLayout(values, width, height, pad)
|
|
|
70
81
|
end
|
|
71
82
|
return segments
|
|
72
83
|
end
|
|
84
|
+
--* Vertical slices under the line. Missing when the series cannot draw.
|
|
85
|
+
local function sparklineArea(values, width, height, pad)
|
|
86
|
+
if pad == nil then
|
|
87
|
+
pad = 4
|
|
88
|
+
end
|
|
89
|
+
local laid = sparklinePoints(values, width, height, pad)
|
|
90
|
+
if laid == nil then
|
|
91
|
+
return {}
|
|
92
|
+
end
|
|
93
|
+
local bars = {}
|
|
94
|
+
local count = #laid.points
|
|
95
|
+
do
|
|
96
|
+
local index = 0
|
|
97
|
+
local _shouldIncrement = false
|
|
98
|
+
while true do
|
|
99
|
+
if _shouldIncrement then
|
|
100
|
+
index += 1
|
|
101
|
+
else
|
|
102
|
+
_shouldIncrement = true
|
|
103
|
+
end
|
|
104
|
+
if not (index < count - 1) then
|
|
105
|
+
break
|
|
106
|
+
end
|
|
107
|
+
local start = laid.points[index + 1]
|
|
108
|
+
local finish = laid.points[index + 2]
|
|
109
|
+
local span = finish.x - start.x
|
|
110
|
+
local slices = math.max(1, math.floor(span / 4))
|
|
111
|
+
local sliceW = span / slices
|
|
112
|
+
do
|
|
113
|
+
local slice = 0
|
|
114
|
+
local _shouldIncrement_1 = false
|
|
115
|
+
while true do
|
|
116
|
+
if _shouldIncrement_1 then
|
|
117
|
+
slice += 1
|
|
118
|
+
else
|
|
119
|
+
_shouldIncrement_1 = true
|
|
120
|
+
end
|
|
121
|
+
if not (slice < slices) then
|
|
122
|
+
break
|
|
123
|
+
end
|
|
124
|
+
local y = start.y + (finish.y - start.y) * (slice / slices)
|
|
125
|
+
local top = math.min(y, laid.baseline)
|
|
126
|
+
local _arg0 = {
|
|
127
|
+
x = start.x + slice * sliceW,
|
|
128
|
+
y = top,
|
|
129
|
+
width = sliceW,
|
|
130
|
+
height = math.max(0, laid.baseline - top),
|
|
131
|
+
}
|
|
132
|
+
table.insert(bars, _arg0)
|
|
133
|
+
end
|
|
134
|
+
end
|
|
135
|
+
end
|
|
136
|
+
end
|
|
137
|
+
return bars
|
|
138
|
+
end
|
|
139
|
+
--* Nearest sample from a local x. Undefined when the trace cannot be hit.
|
|
140
|
+
local function sparklineIndex(localX, count, width, pad)
|
|
141
|
+
if pad == nil then
|
|
142
|
+
pad = 4
|
|
143
|
+
end
|
|
144
|
+
if count < 1 or width <= pad * 2 then
|
|
145
|
+
return nil
|
|
146
|
+
end
|
|
147
|
+
local span = width - pad * 2
|
|
148
|
+
local along = (localX - pad) / span
|
|
149
|
+
if along < 0 then
|
|
150
|
+
along = 0
|
|
151
|
+
end
|
|
152
|
+
if along > 1 then
|
|
153
|
+
along = 1
|
|
154
|
+
end
|
|
155
|
+
if count == 1 then
|
|
156
|
+
return 0
|
|
157
|
+
end
|
|
158
|
+
local index = math.floor(along * (count - 1) + 0.5)
|
|
159
|
+
if index < 0 then
|
|
160
|
+
return 0
|
|
161
|
+
end
|
|
162
|
+
if index > count - 1 then
|
|
163
|
+
return count - 1
|
|
164
|
+
end
|
|
165
|
+
return index
|
|
166
|
+
end
|
|
167
|
+
--* Calls onPick with the nearest sample. Does nothing when the callback is absent.
|
|
168
|
+
local function sparklinePick(localX, count, width, onPick, pad)
|
|
169
|
+
if pad == nil then
|
|
170
|
+
pad = 4
|
|
171
|
+
end
|
|
172
|
+
if onPick == nil then
|
|
173
|
+
return nil
|
|
174
|
+
end
|
|
175
|
+
local index = sparklineIndex(localX, count, width, pad)
|
|
176
|
+
if index == nil then
|
|
177
|
+
return nil
|
|
178
|
+
end
|
|
179
|
+
onPick(index)
|
|
180
|
+
return index
|
|
181
|
+
end
|
|
182
|
+
--* Point for a sample, used to mark the trace.
|
|
183
|
+
local function sparklinePoint(values, index, width, height, pad)
|
|
184
|
+
if pad == nil then
|
|
185
|
+
pad = 4
|
|
186
|
+
end
|
|
187
|
+
local laid = sparklinePoints(values, width, height, pad)
|
|
188
|
+
if laid == nil or index < 0 or index >= #laid.points then
|
|
189
|
+
return nil
|
|
190
|
+
end
|
|
191
|
+
return laid.points[index + 1]
|
|
192
|
+
end
|
|
73
193
|
return {
|
|
74
194
|
sparklineLayout = sparklineLayout,
|
|
195
|
+
sparklineArea = sparklineArea,
|
|
196
|
+
sparklineIndex = sparklineIndex,
|
|
197
|
+
sparklinePick = sparklinePick,
|
|
198
|
+
sparklinePoint = sparklinePoint,
|
|
75
199
|
}
|
|
@@ -5,6 +5,9 @@ local Icons = TS.import(script, script.Parent.Parent.Parent.Parent, "enums").Ico
|
|
|
5
5
|
local Fab = TS.import(script, script.Parent.Parent.Parent, "fab").Fab
|
|
6
6
|
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
7
7
|
local useSpeedDialStyles = TS.import(script, script.Parent, "SpeedDial.styles").default
|
|
8
|
+
local _speedDialLabel = TS.import(script, script.Parent, "speedDialLabel")
|
|
9
|
+
local speedDialLabel = _speedDialLabel.speedDialLabel
|
|
10
|
+
local speedDialLabelFirst = _speedDialLabel.speedDialLabelFirst
|
|
8
11
|
local function SpeedDial(props)
|
|
9
12
|
local _binding = props
|
|
10
13
|
local open = _binding.open
|
|
@@ -27,9 +30,24 @@ local function SpeedDial(props)
|
|
|
27
30
|
local sx = _binding.sx
|
|
28
31
|
local id = _binding.id
|
|
29
32
|
local ref = _binding.ref
|
|
33
|
+
-- ▼ ReadonlyArray.some ▼
|
|
34
|
+
local _result = false
|
|
35
|
+
local _callback = function(action)
|
|
36
|
+
return speedDialLabel(action.label) ~= nil
|
|
37
|
+
end
|
|
38
|
+
for _k, _v in actions do
|
|
39
|
+
if _callback(_v, _k - 1, actions) then
|
|
40
|
+
_result = true
|
|
41
|
+
break
|
|
42
|
+
end
|
|
43
|
+
end
|
|
44
|
+
-- ▲ ReadonlyArray.some ▲
|
|
45
|
+
local labeled = _result
|
|
30
46
|
local styles = useSpeedDialStyles({
|
|
31
47
|
direction = direction,
|
|
48
|
+
labeled = labeled,
|
|
32
49
|
})
|
|
50
|
+
local labelFirst = speedDialLabelFirst(direction)
|
|
33
51
|
local mainFirst = direction == "down" or direction == "right"
|
|
34
52
|
local mainOrder = if mainFirst then 0 else 1000
|
|
35
53
|
local actionBase = if mainFirst then 1 else 0
|
|
@@ -55,26 +73,58 @@ local function SpeedDial(props)
|
|
|
55
73
|
if _condition_1 then
|
|
56
74
|
-- ▼ ReadonlyArray.map ▼
|
|
57
75
|
local _newValue = table.create(#actions)
|
|
58
|
-
local
|
|
59
|
-
|
|
60
|
-
|
|
76
|
+
local _callback_1 = function(action, index)
|
|
77
|
+
local name = speedDialLabel(action.label)
|
|
78
|
+
local order = actionBase + index
|
|
79
|
+
local button = (React.createElement(Fab, {
|
|
80
|
+
key = if name == nil then `Action-{index}` else "Action",
|
|
61
81
|
icon = action.icon,
|
|
62
82
|
size = "small",
|
|
63
83
|
disabled = disabled == true or action.disabled == true,
|
|
64
84
|
onClick = function()
|
|
65
|
-
local
|
|
66
|
-
if
|
|
67
|
-
|
|
85
|
+
local _result_1 = action.onClick
|
|
86
|
+
if _result_1 ~= nil then
|
|
87
|
+
_result_1()
|
|
68
88
|
end
|
|
69
89
|
onOpenChange(false)
|
|
70
90
|
end,
|
|
71
91
|
className = {
|
|
72
|
-
LayoutOrder =
|
|
92
|
+
LayoutOrder = if name == nil then order elseif labelFirst then 2 else 1,
|
|
73
93
|
},
|
|
74
|
-
})
|
|
94
|
+
}))
|
|
95
|
+
if name == nil then
|
|
96
|
+
return button
|
|
97
|
+
end
|
|
98
|
+
local _attributes_2 = {
|
|
99
|
+
key = `Action-{index}`,
|
|
100
|
+
}
|
|
101
|
+
for _k, _v in styles.action do
|
|
102
|
+
_attributes_2[_k] = _v
|
|
103
|
+
end
|
|
104
|
+
_attributes_2.LayoutOrder = order
|
|
105
|
+
local _attributes_3 = table.clone(styles.actionRow)
|
|
106
|
+
setmetatable(_attributes_3, nil)
|
|
107
|
+
local _exp_1 = React.createElement("uilistlayout", _attributes_3)
|
|
108
|
+
local _attributes_4 = {
|
|
109
|
+
key = "Label",
|
|
110
|
+
}
|
|
111
|
+
for _k, _v in styles.actionLabel do
|
|
112
|
+
_attributes_4[_k] = _v
|
|
113
|
+
end
|
|
114
|
+
_attributes_4.Text = name
|
|
115
|
+
_attributes_4.LayoutOrder = if labelFirst then 1 else 2
|
|
116
|
+
local _attributes_5 = table.clone(styles.actionPad)
|
|
117
|
+
setmetatable(_attributes_5, nil)
|
|
118
|
+
local _exp_2 = React.createElement("uipadding", _attributes_5)
|
|
119
|
+
local _attributes_6 = table.clone(styles.actionCorner)
|
|
120
|
+
setmetatable(_attributes_6, nil)
|
|
121
|
+
local _exp_3 = React.createElement("uicorner", _attributes_6)
|
|
122
|
+
local _attributes_7 = table.clone(styles.actionCap)
|
|
123
|
+
setmetatable(_attributes_7, nil)
|
|
124
|
+
return React.createElement("frame", _attributes_2, _exp_1, React.createElement("textlabel", _attributes_4, _exp_2, _exp_3, React.createElement("uisizeconstraint", _attributes_7)), button)
|
|
75
125
|
end
|
|
76
126
|
for _k, _v in actions do
|
|
77
|
-
_newValue[_k] =
|
|
127
|
+
_newValue[_k] = _callback_1(_v, _k - 1, actions)
|
|
78
128
|
end
|
|
79
129
|
-- ▲ ReadonlyArray.map ▲
|
|
80
130
|
_condition_1 = (React.createElement(React.Fragment, nil, _newValue))
|
|
@@ -8,8 +8,12 @@ local useSpeedDialStyles = componentStyles("SpeedDial", function(theme, _param)
|
|
|
8
8
|
if direction == nil then
|
|
9
9
|
direction = "up"
|
|
10
10
|
end
|
|
11
|
+
local labeled = _param.labeled
|
|
12
|
+
if labeled == nil then
|
|
13
|
+
labeled = false
|
|
14
|
+
end
|
|
11
15
|
local vertical = direction == "up" or direction == "down"
|
|
12
|
-
|
|
16
|
+
local _object = {
|
|
13
17
|
root = {
|
|
14
18
|
AutomaticSize = Enum.AutomaticSize.XY,
|
|
15
19
|
Size = UDim2.fromScale(0, 0),
|
|
@@ -18,12 +22,55 @@ local useSpeedDialStyles = componentStyles("SpeedDial", function(theme, _param)
|
|
|
18
22
|
},
|
|
19
23
|
list = {
|
|
20
24
|
FillDirection = if vertical then Enum.FillDirection.Vertical else Enum.FillDirection.Horizontal,
|
|
21
|
-
HorizontalAlignment = if direction == "left" then Enum.HorizontalAlignment.Right elseif direction == "right" then Enum.HorizontalAlignment.Left else Enum.HorizontalAlignment.Center,
|
|
25
|
+
HorizontalAlignment = if vertical and labeled then Enum.HorizontalAlignment.Right elseif direction == "left" then Enum.HorizontalAlignment.Right elseif direction == "right" then Enum.HorizontalAlignment.Left else Enum.HorizontalAlignment.Center,
|
|
22
26
|
VerticalAlignment = if direction == "up" then Enum.VerticalAlignment.Bottom elseif direction == "down" then Enum.VerticalAlignment.Top else Enum.VerticalAlignment.Center,
|
|
23
27
|
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
24
28
|
Padding = UDim.new(0, theme.padding.calc(1)),
|
|
25
29
|
},
|
|
26
|
-
|
|
30
|
+
action = {
|
|
31
|
+
AutomaticSize = Enum.AutomaticSize.XY,
|
|
32
|
+
Size = UDim2.fromScale(0, 0),
|
|
33
|
+
BackgroundTransparency = 1,
|
|
34
|
+
BorderSizePixel = 0,
|
|
35
|
+
},
|
|
36
|
+
actionRow = {
|
|
37
|
+
FillDirection = Enum.FillDirection.Horizontal,
|
|
38
|
+
VerticalAlignment = Enum.VerticalAlignment.Center,
|
|
39
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
40
|
+
Padding = UDim.new(0, theme.padding.calc(1)),
|
|
41
|
+
},
|
|
42
|
+
}
|
|
43
|
+
local _left = "actionLabel"
|
|
44
|
+
local _object_1 = {
|
|
45
|
+
AutomaticSize = Enum.AutomaticSize.XY,
|
|
46
|
+
Size = UDim2.fromScale(0, 0),
|
|
47
|
+
BackgroundColor3 = theme.palette.surface.paper,
|
|
48
|
+
BorderSizePixel = 0,
|
|
49
|
+
Font = theme.typography.fontFamilies.default,
|
|
50
|
+
}
|
|
51
|
+
local _left_1 = "TextSize"
|
|
52
|
+
local _condition = theme.typography.fontSizes.caption
|
|
53
|
+
if _condition == nil then
|
|
54
|
+
_condition = theme.typography.fontSizes.body
|
|
55
|
+
end
|
|
56
|
+
_object_1[_left_1] = _condition
|
|
57
|
+
_object_1.TextColor3 = theme.palette.text.primary
|
|
58
|
+
_object_1.TextTruncate = Enum.TextTruncate.AtEnd
|
|
59
|
+
_object_1.TextWrapped = false
|
|
60
|
+
_object[_left] = _object_1
|
|
61
|
+
_object.actionCap = {
|
|
62
|
+
MaxSize = Vector2.new(theme.spacing.calc(16), math.huge),
|
|
63
|
+
}
|
|
64
|
+
_object.actionPad = {
|
|
65
|
+
PaddingLeft = UDim.new(0, theme.padding.calc(1)),
|
|
66
|
+
PaddingRight = UDim.new(0, theme.padding.calc(1)),
|
|
67
|
+
PaddingTop = UDim.new(0, theme.padding.calc(0.5)),
|
|
68
|
+
PaddingBottom = UDim.new(0, theme.padding.calc(0.5)),
|
|
69
|
+
}
|
|
70
|
+
_object.actionCorner = {
|
|
71
|
+
CornerRadius = UDim.new(0, theme.shape.borderRadius),
|
|
72
|
+
}
|
|
73
|
+
return createStyles(_object)
|
|
27
74
|
end)
|
|
28
75
|
local default = useSpeedDialStyles
|
|
29
76
|
return {
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
/** An empty name stays off the action. */
|
|
2
|
+
export declare function speedDialLabel(text?: string): string | undefined;
|
|
3
|
+
/** The name sits beside the button, opposite the way the dial travels. */
|
|
4
|
+
export declare function speedDialLabelFirst(direction: "up" | "down" | "left" | "right"): direction is "down" | "up" | "right";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
--* An empty name stays off the action.
|
|
3
|
+
local function speedDialLabel(text)
|
|
4
|
+
if text == nil or text == "" then
|
|
5
|
+
return nil
|
|
6
|
+
end
|
|
7
|
+
return text
|
|
8
|
+
end
|
|
9
|
+
--* The name sits beside the button, opposite the way the dial travels.
|
|
10
|
+
local function speedDialLabelFirst(direction)
|
|
11
|
+
return direction ~= "left"
|
|
12
|
+
end
|
|
13
|
+
return {
|
|
14
|
+
speedDialLabel = speedDialLabel,
|
|
15
|
+
speedDialLabelFirst = speedDialLabelFirst,
|
|
16
|
+
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export type SplitPointer = "rest" | "hover" | "press";
|
|
2
2
|
export declare function splitPointer(hovering: boolean, pressed: boolean): SplitPointer;
|
|
3
|
-
export declare function splitRuleTransparency(pointer: SplitPointer, disabled?: boolean): 0.25 | 0.
|
|
3
|
+
export declare function splitRuleTransparency(pointer: SplitPointer, disabled?: boolean): 0.25 | 0.35 | 0.7 | 0.55;
|
|
4
4
|
export declare function splitMarkTransparency(pointer: SplitPointer, disabled?: boolean): 0 | 0.55 | 0.1;
|
|
5
5
|
export declare function splitHitTransparency(pointer: SplitPointer, disabled?: boolean): 1 | 0.9 | 0.94;
|
|
@@ -146,6 +146,11 @@ local function controlsRows()
|
|
|
146
146
|
text = LONG,
|
|
147
147
|
width = NARROW,
|
|
148
148
|
})
|
|
149
|
+
pushPair(out, "Input", "multiline", {
|
|
150
|
+
text = "First line\nSecond line",
|
|
151
|
+
width = NARROW,
|
|
152
|
+
multiline = true,
|
|
153
|
+
})
|
|
149
154
|
pushPair(out, "Input", "sx", {
|
|
150
155
|
variant = "sx",
|
|
151
156
|
})
|
|
@@ -282,6 +287,10 @@ local function editorsRows()
|
|
|
282
287
|
value = "0,0,0",
|
|
283
288
|
disabled = true,
|
|
284
289
|
})
|
|
290
|
+
pushPair(out, "CFrameEditor", "narrow", {
|
|
291
|
+
value = "0,0,0",
|
|
292
|
+
width = 320,
|
|
293
|
+
})
|
|
285
294
|
pushPair(out, "CFrameEditor", "sx", {
|
|
286
295
|
value = "0,0,0",
|
|
287
296
|
})
|
|
@@ -3,6 +3,8 @@ export interface StepperProps {
|
|
|
3
3
|
steps: string[];
|
|
4
4
|
activeStep: number;
|
|
5
5
|
orientation?: "horizontal" | "vertical";
|
|
6
|
+
errorStep?: number;
|
|
7
|
+
onStep?: (index: number) => void;
|
|
6
8
|
}
|
|
7
9
|
declare function Stepper(props: CustomizedProps<Frame, StepperProps>): JSX.Element;
|
|
8
10
|
export default Stepper;
|
|
@@ -2,7 +2,9 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
4
|
local cx = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme").cx
|
|
5
|
-
local
|
|
5
|
+
local _stepState = TS.import(script, script.Parent, "stepState")
|
|
6
|
+
local stepPress = _stepState.stepPress
|
|
7
|
+
local stepState = _stepState.stepState
|
|
6
8
|
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
7
9
|
local useStepperStyles = TS.import(script, script.Parent, "Stepper.styles").default
|
|
8
10
|
local function Stepper(props)
|
|
@@ -13,6 +15,8 @@ local function Stepper(props)
|
|
|
13
15
|
if orientation == nil then
|
|
14
16
|
orientation = "horizontal"
|
|
15
17
|
end
|
|
18
|
+
local errorStep = _binding.errorStep
|
|
19
|
+
local onStep = _binding.onStep
|
|
16
20
|
local className = _binding.className
|
|
17
21
|
local sx = _binding.sx
|
|
18
22
|
local id = _binding.id
|
|
@@ -37,17 +41,41 @@ local function Stepper(props)
|
|
|
37
41
|
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
38
42
|
-- ▼ ReadonlyArray.map ▼
|
|
39
43
|
local _newValue = table.create(#steps)
|
|
40
|
-
local _callback = function(
|
|
41
|
-
local state = stepState(index, activeStep)
|
|
44
|
+
local _callback = function(title, index)
|
|
45
|
+
local state = stepState(index, activeStep, errorStep)
|
|
46
|
+
local caption = `{index + 1}. {title}`
|
|
47
|
+
local look = cx(styles.step, state == "active" and styles.active, state == "complete" and styles.complete, state == "error" and styles.error)
|
|
48
|
+
local press = if onStep ~= nil then stepPress(index, activeStep) else nil
|
|
49
|
+
if onStep == nil then
|
|
50
|
+
local _attributes_2 = {
|
|
51
|
+
key = `{title}-{index}`,
|
|
52
|
+
}
|
|
53
|
+
for _k, _v in look do
|
|
54
|
+
_attributes_2[_k] = _v
|
|
55
|
+
end
|
|
56
|
+
_attributes_2.Text = caption
|
|
57
|
+
_attributes_2.LayoutOrder = index
|
|
58
|
+
return React.createElement("textlabel", _attributes_2)
|
|
59
|
+
end
|
|
42
60
|
local _attributes_2 = {
|
|
43
|
-
key = `{
|
|
61
|
+
key = `{title}-{index}`,
|
|
44
62
|
}
|
|
45
|
-
for _k, _v in
|
|
63
|
+
for _k, _v in look do
|
|
46
64
|
_attributes_2[_k] = _v
|
|
47
65
|
end
|
|
48
|
-
_attributes_2.Text =
|
|
66
|
+
_attributes_2.Text = caption
|
|
49
67
|
_attributes_2.LayoutOrder = index
|
|
50
|
-
|
|
68
|
+
_attributes_2.AutoButtonColor = false
|
|
69
|
+
_attributes_2.Active = press ~= nil
|
|
70
|
+
_attributes_2.Selectable = press ~= nil
|
|
71
|
+
_attributes_2.Event = {
|
|
72
|
+
Activated = function()
|
|
73
|
+
if press ~= nil then
|
|
74
|
+
onStep(press)
|
|
75
|
+
end
|
|
76
|
+
end,
|
|
77
|
+
}
|
|
78
|
+
return React.createElement("textbutton", _attributes_2)
|
|
51
79
|
end
|
|
52
80
|
for _k, _v in steps do
|
|
53
81
|
_newValue[_k] = _callback(_v, _k - 1, steps)
|
|
@@ -8,10 +8,11 @@ local useStepperStyles = componentStyles("Stepper", function(theme, _param)
|
|
|
8
8
|
if orientation == nil then
|
|
9
9
|
orientation = "horizontal"
|
|
10
10
|
end
|
|
11
|
+
local heading = theme.typography.variants.h6
|
|
11
12
|
return createStyles({
|
|
12
13
|
root = {
|
|
13
|
-
AutomaticSize = Enum.AutomaticSize.XY,
|
|
14
|
-
Size = UDim2.fromScale(0, 0),
|
|
14
|
+
AutomaticSize = if orientation == "vertical" then Enum.AutomaticSize.Y else Enum.AutomaticSize.XY,
|
|
15
|
+
Size = if orientation == "vertical" then UDim2.new(1, 0, 0, 0) else UDim2.fromScale(0, 0),
|
|
15
16
|
BackgroundTransparency = 1,
|
|
16
17
|
BorderSizePixel = 0,
|
|
17
18
|
},
|
|
@@ -21,12 +22,14 @@ local useStepperStyles = componentStyles("Stepper", function(theme, _param)
|
|
|
21
22
|
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
22
23
|
},
|
|
23
24
|
step = {
|
|
24
|
-
AutomaticSize = Enum.AutomaticSize.XY,
|
|
25
|
-
Size = UDim2.fromScale(0, 0),
|
|
25
|
+
AutomaticSize = if orientation == "vertical" then Enum.AutomaticSize.Y else Enum.AutomaticSize.XY,
|
|
26
|
+
Size = if orientation == "vertical" then UDim2.new(1, 0, 0, 0) else UDim2.fromScale(0, 0),
|
|
26
27
|
BackgroundTransparency = 1,
|
|
27
28
|
BorderSizePixel = 0,
|
|
28
|
-
Font = theme.typography.fontFamilies.
|
|
29
|
-
TextSize =
|
|
29
|
+
Font = theme.typography.fontFamilies[heading.family],
|
|
30
|
+
TextSize = heading.size,
|
|
31
|
+
LineHeight = heading.leading,
|
|
32
|
+
TextWrapped = true,
|
|
30
33
|
TextColor3 = theme.palette.text.secondary,
|
|
31
34
|
},
|
|
32
35
|
active = {
|
|
@@ -35,6 +38,9 @@ local useStepperStyles = componentStyles("Stepper", function(theme, _param)
|
|
|
35
38
|
complete = {
|
|
36
39
|
TextColor3 = theme.palette.text.primary,
|
|
37
40
|
},
|
|
41
|
+
error = {
|
|
42
|
+
TextColor3 = theme.palette.status.error.main,
|
|
43
|
+
},
|
|
38
44
|
})
|
|
39
45
|
end)
|
|
40
46
|
local default = useStepperStyles
|
|
@@ -1,2 +1,4 @@
|
|
|
1
|
-
export type StepState = "complete" | "active" | "pending";
|
|
2
|
-
export declare function stepState(index: number, activeStep: number): StepState;
|
|
1
|
+
export type StepState = "complete" | "active" | "pending" | "error";
|
|
2
|
+
export declare function stepState(index: number, activeStep: number, errorStep?: number): StepState;
|
|
3
|
+
/** Completed and current steps can be pressed. A later step cannot. */
|
|
4
|
+
export declare function stepPress(index: number, activeStep: number): number | undefined;
|
|
@@ -1,5 +1,8 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
|
-
local function stepState(index, activeStep)
|
|
2
|
+
local function stepState(index, activeStep, errorStep)
|
|
3
|
+
if errorStep ~= nil and index == errorStep then
|
|
4
|
+
return "error"
|
|
5
|
+
end
|
|
3
6
|
if index < activeStep then
|
|
4
7
|
return "complete"
|
|
5
8
|
end
|
|
@@ -8,6 +11,14 @@ local function stepState(index, activeStep)
|
|
|
8
11
|
end
|
|
9
12
|
return "pending"
|
|
10
13
|
end
|
|
14
|
+
--* Completed and current steps can be pressed. A later step cannot.
|
|
15
|
+
local function stepPress(index, activeStep)
|
|
16
|
+
if index < 0 or index > activeStep then
|
|
17
|
+
return nil
|
|
18
|
+
end
|
|
19
|
+
return index
|
|
20
|
+
end
|
|
11
21
|
return {
|
|
12
22
|
stepState = stepState,
|
|
23
|
+
stepPress = stepPress,
|
|
13
24
|
}
|
|
@@ -2,5 +2,7 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local exports = {}
|
|
4
4
|
exports.Stepper = TS.import(script, script, "components", "Stepper").default
|
|
5
|
-
|
|
5
|
+
local _stepState = TS.import(script, script, "components", "stepState")
|
|
6
|
+
exports.stepPress = _stepState.stepPress
|
|
7
|
+
exports.stepState = _stepState.stepState
|
|
6
8
|
return exports
|
|
@@ -7,6 +7,7 @@ local useRef = _react.useRef
|
|
|
7
7
|
local useState = _react.useState
|
|
8
8
|
local useReducedMotion = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "hooks").useReducedMotion
|
|
9
9
|
local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
|
|
10
|
+
local controlFade = _theme.controlFade
|
|
10
11
|
local controlMetrics = _theme.controlMetrics
|
|
11
12
|
local cx = _theme.cx
|
|
12
13
|
local useTheme = _theme.useTheme
|
|
@@ -100,7 +101,6 @@ local function Switch(props)
|
|
|
100
101
|
}
|
|
101
102
|
_attributes.Active = active
|
|
102
103
|
_attributes.Selectable = not disabled
|
|
103
|
-
_attributes.BackgroundTransparency = if focused and active then 0.85 else 1
|
|
104
104
|
_attributes.Event = {
|
|
105
105
|
MouseButton1Click = function()
|
|
106
106
|
if active then
|
|
@@ -163,7 +163,7 @@ local function Switch(props)
|
|
|
163
163
|
local _attributes_7 = table.clone(labelStyle)
|
|
164
164
|
setmetatable(_attributes_7, nil)
|
|
165
165
|
_attributes_7.Text = label
|
|
166
|
-
_attributes_7.TextTransparency = if disabled == true then
|
|
166
|
+
_attributes_7.TextTransparency = if disabled == true then controlFade else 0
|
|
167
167
|
_attributes_7.LayoutOrder = 2
|
|
168
168
|
_condition_1 = (React.createElement("textlabel", _attributes_7))
|
|
169
169
|
end
|
|
@@ -4,6 +4,7 @@ local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "the
|
|
|
4
4
|
local controlMetrics = _theme.controlMetrics
|
|
5
5
|
local createStyles = _theme.createStyles
|
|
6
6
|
local componentStyles = _theme.componentStyles
|
|
7
|
+
local focusRing = _theme.focusRing
|
|
7
8
|
local useSwitchStyles = componentStyles("Switch", function(theme, _param)
|
|
8
9
|
local size = _param.size
|
|
9
10
|
local color = _param.color
|
|
@@ -54,11 +55,7 @@ local useSwitchStyles = componentStyles("Switch", function(theme, _param)
|
|
|
54
55
|
corner = {
|
|
55
56
|
CornerRadius = UDim.new(theme.shape.pillScale, 0),
|
|
56
57
|
},
|
|
57
|
-
stroke =
|
|
58
|
-
Color = theme.palette.focus,
|
|
59
|
-
Thickness = 2,
|
|
60
|
-
ApplyStrokeMode = Enum.ApplyStrokeMode.Border,
|
|
61
|
-
},
|
|
58
|
+
stroke = focusRing(theme.palette.focus),
|
|
62
59
|
})
|
|
63
60
|
end)
|
|
64
61
|
local default = useSwitchStyles
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
export type SwitchPointer = "rest" | "hover" | "press" | "focus";
|
|
2
2
|
export declare function switchPointer(hovering: boolean, pressed: boolean, focused: boolean): SwitchPointer;
|
|
3
|
-
export declare function switchTrackTransparency(on: boolean, disabled: boolean, pointer: SwitchPointer): 0 | 0.
|
|
4
|
-
export declare function switchThumbTransparency(disabled: boolean): 0 | 0.
|
|
5
|
-
export declare function switchStrokeTransparency(disabled: boolean, pointer: SwitchPointer): 1 | 0
|
|
3
|
+
export declare function switchTrackTransparency(on: boolean, disabled: boolean, pointer: SwitchPointer): 0 | 0.5 | 0.25 | 0.35 | 0.15 | 0.08;
|
|
4
|
+
export declare function switchThumbTransparency(disabled: boolean): 0 | 0.5;
|
|
5
|
+
export declare function switchStrokeTransparency(disabled: boolean, pointer: SwitchPointer): 1 | 0;
|
|
6
6
|
export declare function switchThumbPlacement(on: boolean, inset: number): {
|
|
7
7
|
scaleX: number;
|
|
8
8
|
offsetX: number;
|