@rbxts/uiblox 0.1.7 → 0.1.10
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 +33 -37
- package/out/index.d.ts +2 -2
- package/out/{init.lua → init.luau} +1 -1
- package/out/theme/components/ThemeProvider.d.ts +3 -3
- package/out/theme/components/{ThemeProvider.lua → ThemeProvider.luau} +6 -22
- package/out/theme/components/ThemeStore.d.ts +1 -2
- package/out/theme/components/{ThemeStore.lua → ThemeStore.luau} +1 -1
- package/out/theme/components/ThemeWrapper.d.ts +3 -3
- package/out/theme/components/{ThemeWrapper.lua → ThemeWrapper.luau} +6 -21
- package/out/theme/components/{init.lua → init.luau} +1 -1
- package/out/theme/constants/NumberConstants.d.ts +1 -1
- package/out/theme/constants/{NumberConstants.lua → NumberConstants.luau} +1 -1
- package/out/theme/constants/ThemeConstants.d.ts +2 -2
- package/out/theme/constants/{ThemeConstants.lua → ThemeConstants.luau} +1 -1
- package/out/theme/constants/{init.lua → init.luau} +1 -1
- package/out/theme/index.d.ts +17 -17
- package/out/theme/{init.lua → init.luau} +1 -1
- package/out/theme/interfaces/iconSizes/IconSizes.luau +2 -0
- package/out/theme/interfaces/iconSizes/init.luau +2 -0
- package/out/theme/interfaces/index.d.ts +13 -13
- package/out/theme/interfaces/{init.lua → init.luau} +1 -1
- package/out/theme/interfaces/palette/Palette.d.ts +0 -1
- package/out/theme/interfaces/palette/Palette.luau +2 -0
- package/out/theme/interfaces/palette/colorTokens/ColorTokens.d.ts +1 -2
- package/out/theme/interfaces/palette/colorTokens/ColorTokens.luau +2 -0
- package/out/theme/interfaces/palette/colorTokens/init.luau +2 -0
- package/out/theme/interfaces/palette/colors/{Blue.lua → Blue.luau} +1 -1
- package/out/theme/interfaces/palette/colors/Colors.d.ts +0 -1
- package/out/theme/interfaces/palette/colors/Colors.luau +2 -0
- package/out/theme/interfaces/palette/colors/Common.d.ts +0 -1
- package/out/theme/interfaces/palette/colors/{Common.lua → Common.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Dark.lua → Dark.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Gray.lua → Gray.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Green.lua → Green.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Light.lua → Light.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Magenta.lua → Magenta.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Orange.lua → Orange.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Purple.lua → Purple.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Red.lua → Red.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Turquoise.lua → Turquoise.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{Yellow.lua → Yellow.luau} +1 -1
- package/out/theme/interfaces/palette/colors/{init.lua → init.luau} +1 -1
- package/out/theme/interfaces/palette/index.d.ts +2 -2
- package/out/theme/interfaces/palette/{init.lua → init.luau} +1 -1
- package/out/theme/interfaces/spacing/Borders.luau +2 -0
- package/out/theme/interfaces/spacing/Padding.luau +2 -0
- package/out/theme/interfaces/spacing/Shape.luau +2 -0
- package/out/theme/interfaces/spacing/Spacing.luau +2 -0
- package/out/theme/interfaces/spacing/init.luau +2 -0
- package/out/theme/interfaces/theme/Theme.d.ts +3 -3
- package/out/theme/interfaces/theme/Theme.luau +2 -0
- package/out/theme/interfaces/theme/ThemeConstants.d.ts +4 -4
- package/out/theme/interfaces/theme/ThemeConstants.luau +2 -0
- package/out/theme/interfaces/theme/ThemeOptions.luau +2 -0
- package/out/theme/interfaces/theme/init.luau +2 -0
- package/out/theme/interfaces/tokens/Tokens.luau +2 -0
- package/out/theme/interfaces/tokens/init.luau +2 -0
- package/out/theme/interfaces/typography/{FontFamilies.lua → FontFamilies.luau} +1 -1
- package/out/theme/interfaces/typography/FontFamilyOptions.d.ts +0 -2
- package/out/theme/interfaces/typography/FontFamilyOptions.luau +2 -0
- package/out/theme/interfaces/typography/FontSizeOptions.d.ts +0 -1
- package/out/theme/interfaces/typography/FontSizeOptions.luau +2 -0
- package/out/theme/interfaces/typography/{FontSizes.lua → FontSizes.luau} +1 -1
- package/out/theme/interfaces/typography/ThemeTypography.luau +2 -0
- package/out/theme/interfaces/typography/{Variants.lua → Variants.luau} +1 -1
- package/out/theme/interfaces/typography/{init.lua → init.luau} +1 -1
- package/out/theme/styles/index.d.ts +5 -5
- package/out/theme/styles/{init.lua → init.luau} +1 -1
- package/out/theme/styles/types/WriteableStyle.d.ts +0 -2
- package/out/theme/styles/types/WriteableStyle.luau +2 -0
- package/out/theme/styles/types/init.luau +2 -0
- package/out/theme/styles/types/styles.d.ts +0 -2
- package/out/theme/styles/types/styles.luau +2 -0
- package/out/theme/styles/utilities/classNames.d.ts +2 -3
- package/out/theme/styles/utilities/classNames.luau +33 -0
- package/out/theme/styles/utilities/{createStyles.lua → createStyles.luau} +1 -1
- package/out/theme/styles/utilities/{init.lua → init.luau} +1 -1
- package/out/theme/styles/utilities/makeStyles.d.ts +1 -1
- package/out/theme/styles/utilities/{makeStyles.lua → makeStyles.luau} +1 -1
- package/out/theme/themes/DarkTheme.d.ts +1 -1
- package/out/theme/themes/{DarkTheme.lua → DarkTheme.luau} +1 -1
- package/out/theme/themes/LightTheme.d.ts +1 -1
- package/out/theme/themes/{LightTheme.lua → LightTheme.luau} +1 -1
- package/out/theme/themes/{init.lua → init.luau} +1 -1
- package/out/theme/types/init.luau +2 -0
- package/out/theme/types/types.d.ts +5 -8
- package/out/theme/types/{types.lua → types.luau} +1 -1
- package/out/theme/utilites/{Color3FromHex.lua → Color3FromHex.luau} +2 -2
- package/out/theme/utilites/{init.lua → init.luau} +1 -1
- package/out/ui/constants/{ImageConstants.lua → ImageConstants.luau} +1 -1
- package/out/ui/constants/{LayoutConstants.lua → LayoutConstants.luau} +1 -1
- package/out/ui/constants/{init.lua → init.luau} +1 -1
- package/out/ui/enums/Directions.luau +12 -0
- package/out/ui/enums/Icons.luau +44 -0
- package/out/ui/enums/Orientations.luau +8 -0
- package/out/ui/enums/{init.lua → init.luau} +1 -1
- package/out/ui/index.d.ts +34 -34
- package/out/ui/{init.lua → init.luau} +1 -1
- package/out/ui/packages/button/components/Button.d.ts +3 -5
- package/out/ui/packages/button/components/{Button.lua → Button.luau} +63 -88
- package/out/ui/packages/button/components/Button.styles.d.ts +1 -1
- package/out/ui/packages/button/components/{Button.styles.lua → Button.styles.luau} +1 -1
- package/out/ui/packages/button/index.d.ts +3 -3
- package/out/ui/packages/button/{init.lua → init.luau} +1 -1
- package/out/ui/packages/button/types/ButtonColor.luau +2 -0
- package/out/ui/packages/button/types/ButtonSize.luau +2 -0
- package/out/ui/packages/button/types/ButtonVariant.luau +2 -0
- package/out/ui/packages/button/types/init.luau +2 -0
- package/out/ui/packages/divider/components/Divider.d.ts +2 -6
- package/out/ui/packages/divider/components/{Divider.lua → Divider.luau} +6 -10
- package/out/ui/packages/divider/components/Divider.styles.d.ts +1 -1
- package/out/ui/packages/divider/components/{Divider.styles.lua → Divider.styles.luau} +1 -1
- package/out/ui/packages/divider/{init.lua → init.luau} +1 -1
- package/out/ui/packages/icon/components/Icon.d.ts +2 -5
- package/out/ui/packages/icon/components/{Icon.lua → Icon.luau} +5 -9
- package/out/ui/packages/icon/components/Icon.styles.d.ts +1 -1
- package/out/ui/packages/icon/components/{Icon.styles.lua → Icon.styles.luau} +1 -1
- package/out/ui/packages/icon/{init.lua → init.luau} +1 -1
- package/out/ui/packages/iconButton/components/IconButton.d.ts +2 -5
- package/out/ui/packages/iconButton/components/{IconButton.lua → IconButton.luau} +18 -20
- package/out/ui/packages/iconButton/components/IconButton.styles.d.ts +1 -1
- package/out/ui/packages/iconButton/components/{IconButton.styles.lua → IconButton.styles.luau} +1 -1
- package/out/ui/packages/iconButton/{init.lua → init.luau} +1 -1
- package/out/ui/packages/index.d.ts +11 -11
- package/out/ui/packages/{init.lua → init.luau} +1 -1
- package/out/ui/packages/input/components/Input.d.ts +2 -6
- package/out/ui/packages/input/components/{Input.lua → Input.luau} +38 -69
- package/out/ui/packages/input/components/Input.styles.d.ts +1 -1
- package/out/ui/packages/input/components/{Input.styles.lua → Input.styles.luau} +1 -1
- package/out/ui/packages/input/index.d.ts +3 -3
- package/out/ui/packages/input/{init.lua → init.luau} +1 -1
- package/out/ui/packages/input/types/InputColor.luau +2 -0
- package/out/ui/packages/input/types/InputMargin.luau +2 -0
- package/out/ui/packages/input/types/InputVariant.luau +2 -0
- package/out/ui/packages/input/types/init.luau +2 -0
- package/out/ui/packages/progressBar/components/ProgressBar.d.ts +1 -3
- package/out/ui/packages/progressBar/components/ProgressBar.luau +46 -0
- package/out/ui/packages/progressBar/components/ProgressBar.styles.d.ts +1 -1
- package/out/ui/packages/progressBar/components/{ProgressBar.styles.lua → ProgressBar.styles.luau} +1 -1
- package/out/ui/packages/progressBar/{init.lua → init.luau} +1 -1
- package/out/ui/packages/shadow/components/Shadow.d.ts +0 -1
- package/out/ui/packages/shadow/components/{Shadow.lua → Shadow.luau} +14 -24
- package/out/ui/packages/shadow/components/Shadow.styles.d.ts +1 -1
- package/out/ui/packages/shadow/components/{Shadow.styles.lua → Shadow.styles.luau} +1 -1
- package/out/ui/packages/shadow/{init.lua → init.luau} +1 -1
- package/out/ui/packages/sidebar/components/Sidebar.d.ts +1 -3
- package/out/ui/packages/sidebar/components/Sidebar.luau +26 -0
- package/out/ui/packages/sidebar/components/Sidebar.styles.d.ts +1 -1
- package/out/ui/packages/sidebar/components/{Sidebar.styles.lua → Sidebar.styles.luau} +1 -1
- package/out/ui/packages/sidebar/index.d.ts +1 -1
- package/out/ui/packages/sidebar/{init.lua → init.luau} +1 -1
- package/out/ui/packages/sidebar/types/SidebarType.luau +2 -0
- package/out/ui/packages/sidebar/types/init.luau +2 -0
- package/out/ui/packages/toast/components/Toast.d.ts +0 -1
- package/out/ui/packages/toast/components/{Toast.lua → Toast.luau} +21 -29
- package/out/ui/packages/toast/components/Toast.styles.d.ts +1 -1
- package/out/ui/packages/toast/components/{Toast.styles.lua → Toast.styles.luau} +1 -1
- package/out/ui/packages/toast/enums/ToastVariants.luau +11 -0
- package/out/ui/packages/toast/{init.lua → init.luau} +1 -1
- package/out/ui/packages/toast/interfaces/ToastEvent.luau +2 -0
- package/out/ui/packages/treeView/components/TreeView.d.ts +2 -4
- package/out/ui/packages/treeView/components/{TreeView.lua → TreeView.luau} +116 -149
- package/out/ui/packages/treeView/components/TreeView.styles.d.ts +1 -1
- package/out/ui/packages/treeView/components/{TreeView.styles.lua → TreeView.styles.luau} +1 -1
- package/out/ui/packages/treeView/{init.lua → init.luau} +1 -1
- package/out/ui/packages/treeView/interfaces/Branch.luau +2 -0
- package/out/ui/packages/treeView/interfaces/Leaf.luau +2 -0
- package/out/ui/packages/treeView/interfaces/Tree.luau +2 -0
- package/out/ui/packages/typography/components/Typography.d.ts +2 -4
- package/out/ui/packages/typography/components/{Typography.lua → Typography.luau} +7 -22
- package/out/ui/packages/typography/components/Typography.styles.d.ts +1 -1
- package/out/ui/packages/typography/components/{Typography.styles.lua → Typography.styles.luau} +1 -1
- package/out/ui/packages/typography/index.d.ts +3 -3
- package/out/ui/packages/typography/{init.lua → init.luau} +1 -1
- package/out/ui/packages/typography/types/TypographyAlignment.luau +2 -0
- package/out/ui/packages/typography/types/TypographyColor.luau +2 -0
- package/out/ui/packages/typography/types/TypographyDisplay.luau +2 -0
- package/out/ui/packages/typography/types/init.luau +2 -0
- package/package.json +16 -19
- package/out/theme/interfaces/iconSizes/IconSizes.lua +0 -2
- package/out/theme/interfaces/iconSizes/init.lua +0 -2
- package/out/theme/interfaces/palette/Palette.lua +0 -2
- package/out/theme/interfaces/palette/colorTokens/ColorTokens.lua +0 -2
- package/out/theme/interfaces/palette/colorTokens/init.lua +0 -2
- package/out/theme/interfaces/palette/colors/Colors.lua +0 -2
- package/out/theme/interfaces/spacing/Borders.lua +0 -2
- package/out/theme/interfaces/spacing/Padding.lua +0 -2
- package/out/theme/interfaces/spacing/Shape.lua +0 -2
- package/out/theme/interfaces/spacing/Spacing.lua +0 -2
- package/out/theme/interfaces/spacing/init.lua +0 -2
- package/out/theme/interfaces/theme/Theme.lua +0 -2
- package/out/theme/interfaces/theme/ThemeConstants.lua +0 -2
- package/out/theme/interfaces/theme/ThemeOptions.lua +0 -2
- package/out/theme/interfaces/theme/init.lua +0 -2
- package/out/theme/interfaces/tokens/Tokens.lua +0 -2
- package/out/theme/interfaces/tokens/init.lua +0 -2
- package/out/theme/interfaces/typography/FontFamilyOptions.lua +0 -2
- package/out/theme/interfaces/typography/FontSizeOptions.lua +0 -2
- package/out/theme/interfaces/typography/ThemeTypography.lua +0 -2
- package/out/theme/styles/types/WriteableStyle.lua +0 -2
- package/out/theme/styles/types/init.lua +0 -2
- package/out/theme/styles/types/styles.lua +0 -2
- package/out/theme/styles/utilities/classNames.lua +0 -31
- package/out/theme/types/init.lua +0 -2
- package/out/ui/enums/Directions.lua +0 -23
- package/out/ui/enums/Icons.lua +0 -87
- package/out/ui/enums/Orientations.lua +0 -15
- package/out/ui/packages/button/types/ButtonColor.lua +0 -2
- package/out/ui/packages/button/types/ButtonSize.lua +0 -2
- package/out/ui/packages/button/types/ButtonVariant.lua +0 -2
- package/out/ui/packages/button/types/init.lua +0 -2
- package/out/ui/packages/input/types/InputColor.lua +0 -2
- package/out/ui/packages/input/types/InputMargin.lua +0 -2
- package/out/ui/packages/input/types/InputVariant.lua +0 -2
- package/out/ui/packages/input/types/init.lua +0 -2
- package/out/ui/packages/progressBar/components/ProgressBar.lua +0 -76
- package/out/ui/packages/sidebar/components/Sidebar.lua +0 -46
- package/out/ui/packages/sidebar/types/SidebarType.lua +0 -2
- package/out/ui/packages/sidebar/types/init.lua +0 -2
- package/out/ui/packages/toast/enums/ToastVariants.lua +0 -20
- package/out/ui/packages/toast/interfaces/ToastEvent.lua +0 -2
- package/out/ui/packages/treeView/interfaces/Branch.lua +0 -2
- package/out/ui/packages/treeView/interfaces/Leaf.lua +0 -2
- package/out/ui/packages/treeView/interfaces/Tree.lua +0 -2
- package/out/ui/packages/typography/types/TypographyAlignment.lua +0 -2
- package/out/ui/packages/typography/types/TypographyColor.lua +0 -2
- package/out/ui/packages/typography/types/TypographyDisplay.lua +0 -2
- package/out/ui/packages/typography/types/init.lua +0 -2
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
-- Compiled with roblox-ts
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
|
-
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src)
|
|
3
|
+
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src.ts)
|
|
4
4
|
local _roact_hooked = TS.import(script, TS.getModule(script, "@rbxts", "roact-hooked").src)
|
|
5
5
|
local markPureComponent = _roact_hooked.markPureComponent
|
|
6
6
|
local useState = _roact_hooked.useState
|
|
@@ -40,24 +40,22 @@ local function Button(props)
|
|
|
40
40
|
local mouseEnter = _binding.mouseEnter
|
|
41
41
|
local mouseLeave = _binding.mouseLeave
|
|
42
42
|
local className = _binding.className
|
|
43
|
-
local children = _binding
|
|
43
|
+
local children = _binding.children
|
|
44
44
|
local _binding_1 = useButtonStyles(props)
|
|
45
45
|
local root = _binding_1.root
|
|
46
46
|
local font = _binding_1.font
|
|
47
47
|
local corner = _binding_1.corner
|
|
48
48
|
local stroke = _binding_1.stroke
|
|
49
49
|
local hovering, setHovering = useState(false)
|
|
50
|
-
local _attributes =
|
|
51
|
-
|
|
52
|
-
_attributes[_k] = _v
|
|
53
|
-
end
|
|
50
|
+
local _attributes = table.clone(root)
|
|
51
|
+
setmetatable(_attributes, nil)
|
|
54
52
|
for _k, _v in font do
|
|
55
53
|
_attributes[_k] = _v
|
|
56
54
|
end
|
|
57
55
|
_attributes.Active = not disabled and not loading
|
|
58
56
|
_attributes.Text = text
|
|
59
57
|
local _result
|
|
60
|
-
if (not hoveringDisabled and hovering) or
|
|
58
|
+
if (not hoveringDisabled and hovering) or disabled or loading then
|
|
61
59
|
_result = 0.75
|
|
62
60
|
else
|
|
63
61
|
local _result_1 = className
|
|
@@ -71,60 +69,62 @@ local function Button(props)
|
|
|
71
69
|
_result = _condition
|
|
72
70
|
end
|
|
73
71
|
_attributes.BackgroundTransparency = _result
|
|
74
|
-
_attributes
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
mouseEnter
|
|
78
|
-
|
|
79
|
-
end
|
|
80
|
-
_attributes[Roact.Event.MouseLeave] = function()
|
|
81
|
-
setHovering(false)
|
|
82
|
-
if mouseLeave then
|
|
83
|
-
mouseLeave()
|
|
84
|
-
end
|
|
85
|
-
end
|
|
86
|
-
_attributes[Roact.Event.MouseButton1Click] = function()
|
|
87
|
-
if not disabled and not loading then
|
|
88
|
-
if onLeftClick then
|
|
89
|
-
onLeftClick()
|
|
72
|
+
_attributes.Event = {
|
|
73
|
+
MouseEnter = function()
|
|
74
|
+
setHovering(true)
|
|
75
|
+
if mouseEnter then
|
|
76
|
+
mouseEnter()
|
|
90
77
|
end
|
|
91
|
-
end
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
onLeftDown()
|
|
78
|
+
end,
|
|
79
|
+
MouseLeave = function()
|
|
80
|
+
setHovering(false)
|
|
81
|
+
if mouseLeave then
|
|
82
|
+
mouseLeave()
|
|
97
83
|
end
|
|
98
|
-
end
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
84
|
+
end,
|
|
85
|
+
MouseButton1Click = function()
|
|
86
|
+
if not disabled and not loading then
|
|
87
|
+
if onLeftClick then
|
|
88
|
+
onLeftClick()
|
|
89
|
+
end
|
|
104
90
|
end
|
|
105
|
-
end
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
91
|
+
end,
|
|
92
|
+
MouseButton1Down = function()
|
|
93
|
+
if not disabled and not loading then
|
|
94
|
+
if onLeftDown then
|
|
95
|
+
onLeftDown()
|
|
96
|
+
end
|
|
111
97
|
end
|
|
112
|
-
end
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
98
|
+
end,
|
|
99
|
+
MouseButton1Up = function()
|
|
100
|
+
if not disabled and not loading then
|
|
101
|
+
if onLeftUp then
|
|
102
|
+
onLeftUp()
|
|
103
|
+
end
|
|
118
104
|
end
|
|
119
|
-
end
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
105
|
+
end,
|
|
106
|
+
MouseButton2Click = function()
|
|
107
|
+
if not disabled and not loading then
|
|
108
|
+
if onRightClick then
|
|
109
|
+
onRightClick()
|
|
110
|
+
end
|
|
125
111
|
end
|
|
126
|
-
end
|
|
127
|
-
|
|
112
|
+
end,
|
|
113
|
+
MouseButton2Down = function()
|
|
114
|
+
if not disabled and not loading then
|
|
115
|
+
if onRightDown then
|
|
116
|
+
onRightDown()
|
|
117
|
+
end
|
|
118
|
+
end
|
|
119
|
+
end,
|
|
120
|
+
MouseButton2Up = function()
|
|
121
|
+
if not disabled and not loading then
|
|
122
|
+
if onRightUp then
|
|
123
|
+
onRightUp()
|
|
124
|
+
end
|
|
125
|
+
end
|
|
126
|
+
end,
|
|
127
|
+
}
|
|
128
128
|
if className then
|
|
129
129
|
for _k, _v in className do
|
|
130
130
|
_attributes[_k] = _v
|
|
@@ -132,42 +132,17 @@ local function Button(props)
|
|
|
132
132
|
end
|
|
133
133
|
local _condition = variant == "outlined"
|
|
134
134
|
if _condition then
|
|
135
|
-
local _attributes_1 =
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
end
|
|
139
|
-
_condition = Roact.createElement("UIStroke", _attributes_1)
|
|
140
|
-
end
|
|
141
|
-
local _children = {}
|
|
142
|
-
local _length = #_children
|
|
143
|
-
if _condition then
|
|
144
|
-
_children[_length + 1] = _condition
|
|
135
|
+
local _attributes_1 = table.clone(stroke)
|
|
136
|
+
setmetatable(_attributes_1, nil)
|
|
137
|
+
_condition = Roact.jsx("uistroke", _attributes_1)
|
|
145
138
|
end
|
|
146
|
-
_length = #_children
|
|
147
139
|
local _condition_1 = rounded
|
|
148
140
|
if _condition_1 then
|
|
149
|
-
local _attributes_1 =
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
end
|
|
153
|
-
_condition_1 = Roact.createElement("UICorner", _attributes_1)
|
|
154
|
-
end
|
|
155
|
-
if _condition_1 then
|
|
156
|
-
_children[_length + 1] = _condition_1
|
|
157
|
-
end
|
|
158
|
-
_length = #_children
|
|
159
|
-
if children then
|
|
160
|
-
for _k, _v in children do
|
|
161
|
-
if type(_k) == "number" then
|
|
162
|
-
_children[_length + _k] = _v
|
|
163
|
-
else
|
|
164
|
-
_children[_k] = _v
|
|
165
|
-
end
|
|
166
|
-
end
|
|
141
|
+
local _attributes_1 = table.clone(corner)
|
|
142
|
+
setmetatable(_attributes_1, nil)
|
|
143
|
+
_condition_1 = Roact.jsx("uicorner", _attributes_1)
|
|
167
144
|
end
|
|
168
|
-
return Roact.
|
|
169
|
-
Button = Roact.createElement("TextButton", _attributes, _children),
|
|
170
|
-
})
|
|
145
|
+
return Roact.jsx("textbutton", _attributes, _condition, _condition_1, children)
|
|
171
146
|
end
|
|
172
147
|
local default = markPureComponent(Button)
|
|
173
148
|
return {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ButtonProps } from "./Button";
|
|
2
|
-
declare const useButtonStyles: (props: ButtonProps) => import("../../../../theme").ClassNameMap<string>;
|
|
2
|
+
declare const useButtonStyles: (props: ButtonProps) => import("../../../../theme/index").ClassNameMap<string>;
|
|
3
3
|
export default useButtonStyles;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export { default as Button } from "./components/Button";
|
|
2
2
|
export { ButtonProps } from "./components/Button";
|
|
3
3
|
export * from "./components/Button";
|
|
4
|
-
export { ButtonColor } from "./types";
|
|
5
|
-
export { ButtonSize } from "./types";
|
|
6
|
-
export { ButtonVariant } from "./types";
|
|
4
|
+
export { ButtonColor } from "./types/index";
|
|
5
|
+
export { ButtonSize } from "./types/index";
|
|
6
|
+
export { ButtonVariant } from "./types/index";
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
/// <reference types="@rbxts/types" />
|
|
2
|
-
/// <reference types="@rbxts/types" />
|
|
3
|
-
/// <reference types="@rbxts/types" />
|
|
4
|
-
/// <reference types="roact" />
|
|
5
1
|
import Roact from "@rbxts/roact";
|
|
6
|
-
import { CustomizedProps } from "../../../../theme";
|
|
7
|
-
import { Orientations } from "../../../enums";
|
|
2
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
3
|
+
import { Orientations } from "../../../enums/index";
|
|
8
4
|
type DefaultDividerComponent = Frame;
|
|
9
5
|
export interface DividerProps {
|
|
10
6
|
position?: UDim2;
|
|
@@ -1,25 +1,21 @@
|
|
|
1
|
-
-- Compiled with roblox-ts
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
|
-
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src)
|
|
3
|
+
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src.ts)
|
|
4
4
|
local useDividerStyles = TS.import(script, script.Parent, "Divider.styles").default
|
|
5
5
|
local function Divider(props)
|
|
6
6
|
local _binding = props
|
|
7
7
|
local className = _binding.className
|
|
8
8
|
local _binding_1 = useDividerStyles(props)
|
|
9
9
|
local root = _binding_1.root
|
|
10
|
-
local _attributes =
|
|
11
|
-
|
|
12
|
-
_attributes[_k] = _v
|
|
13
|
-
end
|
|
10
|
+
local _attributes = table.clone(root)
|
|
11
|
+
setmetatable(_attributes, nil)
|
|
14
12
|
_attributes.BorderSizePixel = 0
|
|
15
|
-
if className then
|
|
13
|
+
if className ~= 0 and className == className and className ~= "" and className then
|
|
16
14
|
for _k, _v in className do
|
|
17
15
|
_attributes[_k] = _v
|
|
18
16
|
end
|
|
19
17
|
end
|
|
20
|
-
return Roact.
|
|
21
|
-
Divider = Roact.createElement("Frame", _attributes),
|
|
22
|
-
})
|
|
18
|
+
return Roact.jsx("frame", _attributes)
|
|
23
19
|
end
|
|
24
20
|
local default = Divider
|
|
25
21
|
return {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { DividerProps } from "./Divider";
|
|
2
|
-
declare const useDividerStyles: (props: DividerProps) => import("../../../../theme").ClassNameMap<string>;
|
|
2
|
+
declare const useDividerStyles: (props: DividerProps) => import("../../../../theme/index").ClassNameMap<string>;
|
|
3
3
|
export default useDividerStyles;
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
/// <reference types="@rbxts/types" />
|
|
2
|
-
/// <reference types="@rbxts/types" />
|
|
3
|
-
/// <reference types="roact" />
|
|
4
1
|
import Roact from "@rbxts/roact";
|
|
5
|
-
import { Icons } from "../../../enums";
|
|
6
|
-
import { CustomizedProps } from "../../../../theme";
|
|
2
|
+
import { Icons } from "../../../enums/index";
|
|
3
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
7
4
|
export interface IconProps {
|
|
8
5
|
icon: Icons;
|
|
9
6
|
size?: "xxs" | "xs" | "sm" | "md" | "lg" | "xl";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
-- Compiled with roblox-ts
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
|
-
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src)
|
|
3
|
+
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src.ts)
|
|
4
4
|
local markPureComponent = TS.import(script, TS.getModule(script, "@rbxts", "roact-hooked").src).markPureComponent
|
|
5
5
|
local useIconStyles = TS.import(script, script.Parent, "Icon.styles").default
|
|
6
6
|
local function Icon(props)
|
|
@@ -10,10 +10,8 @@ local function Icon(props)
|
|
|
10
10
|
local className = _binding.className
|
|
11
11
|
local _binding_1 = useIconStyles(props)
|
|
12
12
|
local container = _binding_1.container
|
|
13
|
-
local _attributes =
|
|
14
|
-
|
|
15
|
-
_attributes[_k] = _v
|
|
16
|
-
end
|
|
13
|
+
local _attributes = table.clone(container)
|
|
14
|
+
setmetatable(_attributes, nil)
|
|
17
15
|
if className then
|
|
18
16
|
for _k, _v in className do
|
|
19
17
|
_attributes[_k] = _v
|
|
@@ -21,9 +19,7 @@ local function Icon(props)
|
|
|
21
19
|
end
|
|
22
20
|
_attributes.Image = tostring(icon)
|
|
23
21
|
_attributes.ImageColor3 = tint or container.ImageColor3
|
|
24
|
-
return Roact.
|
|
25
|
-
Icon = Roact.createElement("ImageLabel", _attributes),
|
|
26
|
-
})
|
|
22
|
+
return Roact.jsx("imagelabel", _attributes)
|
|
27
23
|
end
|
|
28
24
|
local default = markPureComponent(Icon)
|
|
29
25
|
return {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { IconProps } from "./Icon";
|
|
2
|
-
declare const useIconStyles: (props: IconProps) => import("../../../../theme").ClassNameMap<string>;
|
|
2
|
+
declare const useIconStyles: (props: IconProps) => import("../../../../theme/index").ClassNameMap<string>;
|
|
3
3
|
export default useIconStyles;
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
/// <reference types="@rbxts/types" />
|
|
2
|
-
/// <reference types="@rbxts/types" />
|
|
3
|
-
/// <reference types="roact" />
|
|
4
1
|
import Roact from "@rbxts/roact";
|
|
5
|
-
import { Icons } from "../../../enums";
|
|
6
|
-
import { CustomizedProps } from "../../../../theme";
|
|
2
|
+
import { Icons } from "../../../enums/index";
|
|
3
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
7
4
|
export interface IconButtonProps {
|
|
8
5
|
icon: Icons;
|
|
9
6
|
size?: "xxs" | "xs" | "sm" | "md" | "lg" | "xl";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
-- Compiled with roblox-ts
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
|
-
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src)
|
|
3
|
+
local Roact = TS.import(script, TS.getModule(script, "@rbxts", "roact").src.ts)
|
|
4
4
|
local _roact_hooked = TS.import(script, TS.getModule(script, "@rbxts", "roact-hooked").src)
|
|
5
5
|
local markPureComponent = _roact_hooked.markPureComponent
|
|
6
6
|
local useState = _roact_hooked.useState
|
|
@@ -15,10 +15,8 @@ local function IconButton(props)
|
|
|
15
15
|
local _binding_1 = useIconButtonStyles(props)
|
|
16
16
|
local container = _binding_1.container
|
|
17
17
|
local hovering, setHovering = useState(false)
|
|
18
|
-
local _attributes =
|
|
19
|
-
|
|
20
|
-
_attributes[_k] = _v
|
|
21
|
-
end
|
|
18
|
+
local _attributes = table.clone(container)
|
|
19
|
+
setmetatable(_attributes, nil)
|
|
22
20
|
if className then
|
|
23
21
|
for _k, _v in className do
|
|
24
22
|
_attributes[_k] = _v
|
|
@@ -27,20 +25,20 @@ local function IconButton(props)
|
|
|
27
25
|
_attributes.BackgroundTransparency = if hovering or selected then 0.5 else 1
|
|
28
26
|
_attributes.Image = tostring(icon)
|
|
29
27
|
_attributes.ImageColor3 = tint or container.ImageColor3
|
|
30
|
-
_attributes
|
|
31
|
-
|
|
32
|
-
onClick
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
28
|
+
_attributes.Event = {
|
|
29
|
+
MouseButton1Click = function()
|
|
30
|
+
if onClick then
|
|
31
|
+
onClick()
|
|
32
|
+
end
|
|
33
|
+
end,
|
|
34
|
+
MouseEnter = function()
|
|
35
|
+
setHovering(true)
|
|
36
|
+
end,
|
|
37
|
+
MouseLeave = function()
|
|
38
|
+
setHovering(false)
|
|
39
|
+
end,
|
|
40
|
+
}
|
|
41
|
+
return Roact.jsx("imagebutton", _attributes)
|
|
44
42
|
end
|
|
45
43
|
local default = markPureComponent(IconButton)
|
|
46
44
|
return {
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { IconButtonProps } from "./IconButton";
|
|
2
|
-
declare const useIconButtonStyles: (props: IconButtonProps) => import("../../../../theme").ClassNameMap<string>;
|
|
2
|
+
declare const useIconButtonStyles: (props: IconButtonProps) => import("../../../../theme/index").ClassNameMap<string>;
|
|
3
3
|
export default useIconButtonStyles;
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export * from "./divider";
|
|
2
|
-
export * from "./icon";
|
|
3
|
-
export * from "./iconButton";
|
|
4
|
-
export * from "./input";
|
|
5
|
-
export * from "./progressBar";
|
|
6
|
-
export * from "./shadow";
|
|
7
|
-
export * from "./sidebar";
|
|
8
|
-
export * from "./toast";
|
|
9
|
-
export * from "./treeView";
|
|
10
|
-
export * from "./typography";
|
|
11
|
-
export * from "./button";
|
|
1
|
+
export * from "./divider/index";
|
|
2
|
+
export * from "./icon/index";
|
|
3
|
+
export * from "./iconButton/index";
|
|
4
|
+
export * from "./input/index";
|
|
5
|
+
export * from "./progressBar/index";
|
|
6
|
+
export * from "./shadow/index";
|
|
7
|
+
export * from "./sidebar/index";
|
|
8
|
+
export * from "./toast/index";
|
|
9
|
+
export * from "./treeView/index";
|
|
10
|
+
export * from "./typography/index";
|
|
11
|
+
export * from "./button/index";
|
|
@@ -1,10 +1,6 @@
|
|
|
1
|
-
/// <reference types="@rbxts/types" />
|
|
2
|
-
/// <reference types="@rbxts/types" />
|
|
3
|
-
/// <reference types="@rbxts/types" />
|
|
4
|
-
/// <reference types="roact" />
|
|
5
1
|
import Roact from "@rbxts/roact";
|
|
6
|
-
import { CustomizedProps } from "../../../../theme";
|
|
7
|
-
import { InputColor, InputMargin, InputVariant } from "../types";
|
|
2
|
+
import { CustomizedProps } from "../../../../theme/index";
|
|
3
|
+
import { InputColor, InputMargin, InputVariant } from "../types/index";
|
|
8
4
|
export type DefaultInputComponent = Frame;
|
|
9
5
|
export interface InputProps {
|
|
10
6
|
color?: InputColor;
|