@rbxts/uiblox 0.2.0-alpha.25 → 0.2.0-alpha.27
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 +27 -109
- package/out/ui/packages/accordion/components/Accordion.luau +12 -16
- package/out/ui/packages/alert/components/Alert.luau +9 -16
- package/out/ui/packages/appBar/components/AppBar.luau +9 -16
- package/out/ui/packages/assetField/components/AssetField.luau +12 -16
- package/out/ui/packages/avatar/components/Avatar.luau +9 -16
- package/out/ui/packages/backdrop/components/Backdrop.luau +9 -16
- package/out/ui/packages/badge/components/Badge.luau +9 -16
- package/out/ui/packages/bottomNavigation/components/BottomNavigation.luau +12 -16
- package/out/ui/packages/breadcrumbs/components/Breadcrumbs.luau +9 -16
- package/out/ui/packages/brickColorPicker/components/BrickColorPicker.luau +12 -16
- package/out/ui/packages/button/components/Button.luau +20 -18
- package/out/ui/packages/card/components/Card.d.ts +2 -1
- package/out/ui/packages/card/components/Card.luau +8 -0
- package/out/ui/packages/cframeEditor/components/CFrameEditor.luau +12 -16
- package/out/ui/packages/checkbox/components/Checkbox.luau +16 -16
- package/out/ui/packages/chip/components/Chip.luau +13 -16
- package/out/ui/packages/circularProgress/components/CircularProgress.luau +16 -16
- package/out/ui/packages/colorPicker/components/ColorPicker.luau +12 -16
- package/out/ui/packages/colorPicker/components/ColorSequenceEditor.luau +12 -16
- package/out/ui/packages/colorPicker/components/NumberSequenceEditor.luau +12 -16
- package/out/ui/packages/dialog/components/Dialog.d.ts +2 -1
- package/out/ui/packages/dialog/components/Dialog.luau +21 -10
- package/out/ui/packages/divider/components/Divider.luau +20 -33
- package/out/ui/packages/drawer/components/Drawer.d.ts +2 -1
- package/out/ui/packages/drawer/components/Drawer.luau +18 -5
- package/out/ui/packages/fab/components/Fab.luau +31 -26
- package/out/ui/packages/fab/components/Fab.styles.luau +6 -0
- package/out/ui/packages/fontEditor/components/FontEditor.luau +12 -16
- package/out/ui/packages/formText/components/FormHelperText.luau +12 -16
- package/out/ui/packages/formText/components/FormLabel.luau +12 -16
- package/out/ui/packages/gradientEditor/components/GradientEditor.luau +12 -16
- package/out/ui/packages/host/components/SxHost.d.ts +18 -0
- package/out/ui/packages/host/components/SxHost.luau +197 -0
- package/out/ui/packages/host/hostPaint.d.ts +11 -0
- package/out/ui/packages/host/hostPaint.luau +33 -0
- package/out/ui/packages/host/hostRules.d.ts +15 -0
- package/out/ui/packages/host/hostRules.luau +92 -0
- package/out/ui/packages/host/index.d.ts +3 -0
- package/out/ui/packages/host/init.luau +13 -0
- package/out/ui/packages/icon/components/Icon.luau +9 -16
- package/out/ui/packages/iconButton/components/IconButton.luau +16 -16
- package/out/ui/packages/imageList/components/ImageList.luau +9 -16
- package/out/ui/packages/imageList/components/ImageList.styles.luau +4 -3
- package/out/ui/packages/input/components/Input.luau +14 -16
- package/out/ui/packages/layout/components/Box.luau +6 -15
- package/out/ui/packages/layout/components/Container.luau +6 -15
- package/out/ui/packages/layout/components/FlexItem.luau +6 -15
- package/out/ui/packages/layout/components/Grid.luau +6 -15
- package/out/ui/packages/layout/components/List.luau +9 -16
- package/out/ui/packages/layout/components/Stack.luau +6 -15
- package/out/ui/packages/link/components/Link.luau +13 -16
- package/out/ui/packages/listItem/components/ListItem.d.ts +2 -1
- package/out/ui/packages/listItem/components/ListItem.luau +23 -4
- package/out/ui/packages/loadingStroke/components/LoadingStroke.d.ts +5 -1
- package/out/ui/packages/loadingStroke/components/loadingStrokeSx.d.ts +11 -0
- package/out/ui/packages/loadingStroke/components/loadingStrokeSx.luau +2 -0
- package/out/ui/packages/markdown/components/Markdown.luau +9 -16
- package/out/ui/packages/markdown/components/MarkdownEditor.luau +9 -16
- package/out/ui/packages/menu/components/Menu.d.ts +2 -1
- package/out/ui/packages/menu/components/Menu.luau +23 -12
- package/out/ui/packages/modal/components/Modal.d.ts +2 -1
- package/out/ui/packages/modal/components/Modal.luau +29 -5
- package/out/ui/packages/numberInput/components/NumberInput.d.ts +1 -0
- package/out/ui/packages/numberInput/components/NumberInput.luau +14 -3
- package/out/ui/packages/numberInput/components/numberValue.d.ts +1 -0
- package/out/ui/packages/numberInput/components/numberValue.luau +45 -0
- package/out/ui/packages/numberRangeEditor/components/NumberRangeEditor.luau +12 -16
- package/out/ui/packages/pagination/components/Pagination.luau +12 -16
- package/out/ui/packages/paper/components/Paper.d.ts +2 -1
- package/out/ui/packages/paper/components/Paper.luau +21 -12
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.luau +63 -38
- package/out/ui/packages/physicalPropertiesEditor/components/PhysicalPropertiesEditor.styles.luau +21 -7
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.d.ts +2 -0
- package/out/ui/packages/physicalPropertiesEditor/components/physicalParts.luau +14 -0
- package/out/ui/packages/popup/components/Popup.d.ts +2 -1
- package/out/ui/packages/popup/components/Popup.luau +35 -18
- package/out/ui/packages/preloader/components/Preloader.luau +9 -16
- package/out/ui/packages/progressBar/components/ProgressBar.luau +12 -16
- package/out/ui/packages/radioGroup/components/RadioGroup.luau +12 -16
- package/out/ui/packages/rating/components/Rating.luau +12 -16
- package/out/ui/packages/rayEditor/components/RayEditor.luau +12 -16
- package/out/ui/packages/rectEditor/components/RectEditor.luau +86 -43
- package/out/ui/packages/rectEditor/components/RectEditor.styles.luau +30 -7
- package/out/ui/packages/select/components/Select.luau +13 -16
- package/out/ui/packages/shadow/components/Shadow.d.ts +2 -1
- package/out/ui/packages/shadow/components/Shadow.luau +39 -17
- package/out/ui/packages/shadow/components/Shadow.styles.luau +7 -2
- package/out/ui/packages/sidebar/components/Sidebar.luau +9 -16
- package/out/ui/packages/skeleton/components/Skeleton.luau +19 -28
- package/out/ui/packages/slider/components/Slider.luau +16 -17
- package/out/ui/packages/speedDial/components/SpeedDial.luau +12 -16
- package/out/ui/packages/splitPane/components/SplitPane.luau +12 -16
- package/out/ui/packages/stateMatrix.luau +1209 -725
- package/out/ui/packages/stepper/components/Stepper.luau +9 -16
- package/out/ui/packages/switch/components/Switch.luau +16 -16
- package/out/ui/packages/table/components/Table.luau +9 -16
- package/out/ui/packages/tabs/components/Tabs.luau +12 -16
- package/out/ui/packages/toast/components/Toast.luau +16 -13
- package/out/ui/packages/toggleButton/components/ToggleButton.luau +24 -32
- package/out/ui/packages/tooltip/components/Tooltip.luau +9 -16
- package/out/ui/packages/treeView/components/TreeView.luau +9 -16
- package/out/ui/packages/typography/components/Typography.luau +13 -14
- package/out/ui/packages/udimEditor/components/UDimEditor.luau +12 -16
- package/out/ui/packages/vectorEditor/components/VectorEditor.luau +12 -16
- package/out/ui/packages/virtualList/components/EmptyListHint.d.ts +2 -1
- package/out/ui/packages/virtualList/components/EmptyListHint.luau +15 -4
- package/out/ui/packages/virtualList/components/VirtualList.luau +9 -16
- package/package.json +2 -2
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
4
|
local canActivate = TS.import(script, script.Parent.Parent.Parent, "button", "components", "activation").canActivate
|
|
5
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
5
6
|
local useRadioGroupStyles = TS.import(script, script.Parent, "RadioGroup.styles").default
|
|
6
7
|
local function RadioGroup(props)
|
|
7
8
|
local _binding = props
|
|
@@ -28,26 +29,21 @@ local function RadioGroup(props)
|
|
|
28
29
|
local stroke = _binding_1.stroke
|
|
29
30
|
local corner = _binding_1.corner
|
|
30
31
|
local label = _binding_1.label
|
|
31
|
-
local _attributes = {
|
|
32
|
+
local _attributes = {
|
|
33
|
+
tag = "frame",
|
|
34
|
+
}
|
|
32
35
|
local _condition = id
|
|
33
36
|
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
34
37
|
_condition = "RadioGroup"
|
|
35
38
|
end
|
|
36
39
|
_attributes.key = _condition
|
|
37
|
-
_attributes.
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
end
|
|
45
|
-
end
|
|
46
|
-
if sx then
|
|
47
|
-
for _k, _v in sx do
|
|
48
|
-
_attributes[_k] = _v
|
|
49
|
-
end
|
|
50
|
-
end
|
|
40
|
+
_attributes.hostRef = ref
|
|
41
|
+
_attributes.base = root
|
|
42
|
+
_attributes.className = className
|
|
43
|
+
_attributes.sx = sx
|
|
44
|
+
_attributes.state = {
|
|
45
|
+
disabled = disabled,
|
|
46
|
+
}
|
|
51
47
|
local _attributes_1 = table.clone(list)
|
|
52
48
|
setmetatable(_attributes_1, nil)
|
|
53
49
|
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
@@ -106,7 +102,7 @@ local function RadioGroup(props)
|
|
|
106
102
|
_newValue[_k] = _callback(_v, _k - 1, options)
|
|
107
103
|
end
|
|
108
104
|
-- ▲ ReadonlyArray.map ▲
|
|
109
|
-
return React.createElement(
|
|
105
|
+
return React.createElement(SxHost, _attributes, _exp, React.createElement(React.Fragment, nil, _newValue))
|
|
110
106
|
end
|
|
111
107
|
local default = RadioGroup
|
|
112
108
|
return {
|
|
@@ -3,6 +3,7 @@ local TS = _G[script]
|
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
4
|
local Icons = TS.import(script, script.Parent.Parent.Parent.Parent, "enums").Icons
|
|
5
5
|
local canActivate = TS.import(script, script.Parent.Parent.Parent, "button", "components", "activation").canActivate
|
|
6
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
6
7
|
local useRatingStyles = TS.import(script, script.Parent, "Rating.styles").default
|
|
7
8
|
local function Rating(props)
|
|
8
9
|
local _binding = props
|
|
@@ -44,26 +45,21 @@ local function Rating(props)
|
|
|
44
45
|
table.insert(stars, _i)
|
|
45
46
|
end
|
|
46
47
|
end
|
|
47
|
-
local _attributes = {
|
|
48
|
+
local _attributes = {
|
|
49
|
+
tag = "frame",
|
|
50
|
+
}
|
|
48
51
|
local _condition = id
|
|
49
52
|
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
50
53
|
_condition = "Rating"
|
|
51
54
|
end
|
|
52
55
|
_attributes.key = _condition
|
|
53
|
-
_attributes.
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
end
|
|
61
|
-
end
|
|
62
|
-
if sx then
|
|
63
|
-
for _k, _v in sx do
|
|
64
|
-
_attributes[_k] = _v
|
|
65
|
-
end
|
|
66
|
-
end
|
|
56
|
+
_attributes.hostRef = ref
|
|
57
|
+
_attributes.base = styles.root
|
|
58
|
+
_attributes.className = className
|
|
59
|
+
_attributes.sx = sx
|
|
60
|
+
_attributes.state = {
|
|
61
|
+
disabled = disabled,
|
|
62
|
+
}
|
|
67
63
|
local _attributes_1 = table.clone(styles.list)
|
|
68
64
|
setmetatable(_attributes_1, nil)
|
|
69
65
|
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
@@ -93,7 +89,7 @@ local function Rating(props)
|
|
|
93
89
|
_newValue[_k] = _callback(_v, _k - 1, stars)
|
|
94
90
|
end
|
|
95
91
|
-- ▲ ReadonlyArray.map ▲
|
|
96
|
-
return React.createElement(
|
|
92
|
+
return React.createElement(SxHost, _attributes, _exp, React.createElement(React.Fragment, nil, _newValue))
|
|
97
93
|
end
|
|
98
94
|
local default = Rating
|
|
99
95
|
return {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
4
5
|
local VectorEditor = TS.import(script, script.Parent.Parent.Parent, "vectorEditor").VectorEditor
|
|
5
6
|
local useRayEditorStyles = TS.import(script, script.Parent, "RayEditor.styles").default
|
|
6
7
|
local function RayEditor(props)
|
|
@@ -13,26 +14,21 @@ local function RayEditor(props)
|
|
|
13
14
|
local id = _binding.id
|
|
14
15
|
local ref = _binding.ref
|
|
15
16
|
local styles = useRayEditorStyles()
|
|
16
|
-
local _attributes = {
|
|
17
|
+
local _attributes = {
|
|
18
|
+
tag = "frame",
|
|
19
|
+
}
|
|
17
20
|
local _condition = id
|
|
18
21
|
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
19
22
|
_condition = "RayEditor"
|
|
20
23
|
end
|
|
21
24
|
_attributes.key = _condition
|
|
22
|
-
_attributes.
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
end
|
|
30
|
-
end
|
|
31
|
-
if sx then
|
|
32
|
-
for _k, _v in sx do
|
|
33
|
-
_attributes[_k] = _v
|
|
34
|
-
end
|
|
35
|
-
end
|
|
25
|
+
_attributes.hostRef = ref
|
|
26
|
+
_attributes.base = styles.root
|
|
27
|
+
_attributes.className = className
|
|
28
|
+
_attributes.sx = sx
|
|
29
|
+
_attributes.state = {
|
|
30
|
+
disabled = disabled,
|
|
31
|
+
}
|
|
36
32
|
local _attributes_1 = table.clone(styles.column)
|
|
37
33
|
setmetatable(_attributes_1, nil)
|
|
38
34
|
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
@@ -69,7 +65,7 @@ local function RayEditor(props)
|
|
|
69
65
|
local _attributes_7 = table.clone(styles.label)
|
|
70
66
|
setmetatable(_attributes_7, nil)
|
|
71
67
|
_attributes_7.Text = "Direction"
|
|
72
|
-
return React.createElement(
|
|
68
|
+
return React.createElement(SxHost, _attributes, _exp, _exp_2, React.createElement("frame", _attributes_5, _exp_3, React.createElement("textlabel", _attributes_7), React.createElement(VectorEditor, {
|
|
73
69
|
value = value.Direction,
|
|
74
70
|
disabled = disabled,
|
|
75
71
|
onChange = function(direction)
|
|
@@ -1,11 +1,17 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
4
5
|
local NumberInput = TS.import(script, script.Parent.Parent.Parent, "numberInput").NumberInput
|
|
5
6
|
local useRectEditorStyles = TS.import(script, script.Parent, "RectEditor.styles").default
|
|
6
|
-
local
|
|
7
|
-
local
|
|
8
|
-
|
|
7
|
+
local writeRectParts = TS.import(script, script.Parent, "rectValue").writeRectParts
|
|
8
|
+
local GROUPS = { {
|
|
9
|
+
title = "Min",
|
|
10
|
+
fields = { "MinX", "MinY" },
|
|
11
|
+
}, {
|
|
12
|
+
title = "Max",
|
|
13
|
+
fields = { "MaxX", "MaxY" },
|
|
14
|
+
} }
|
|
9
15
|
local function RectEditor(props)
|
|
10
16
|
local _binding = props
|
|
11
17
|
local value = _binding.value
|
|
@@ -16,68 +22,105 @@ local function RectEditor(props)
|
|
|
16
22
|
local id = _binding.id
|
|
17
23
|
local ref = _binding.ref
|
|
18
24
|
local styles = useRectEditorStyles()
|
|
19
|
-
local amounts = {
|
|
25
|
+
local amounts = {
|
|
26
|
+
MinX = value.Min.X,
|
|
27
|
+
MinY = value.Min.Y,
|
|
28
|
+
MaxX = value.Max.X,
|
|
29
|
+
MaxY = value.Max.Y,
|
|
30
|
+
}
|
|
20
31
|
local commit = function(field, amount)
|
|
21
32
|
local parts = writeRectParts(value.Min.X, value.Min.Y, value.Max.X, value.Max.Y, field, amount)
|
|
22
33
|
onChange(Rect.new(parts[1], parts[2], parts[3], parts[4]))
|
|
23
34
|
end
|
|
24
|
-
local _attributes = {
|
|
35
|
+
local _attributes = {
|
|
36
|
+
tag = "frame",
|
|
37
|
+
}
|
|
25
38
|
local _condition = id
|
|
26
39
|
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
27
40
|
_condition = "RectEditor"
|
|
28
41
|
end
|
|
29
42
|
_attributes.key = _condition
|
|
30
|
-
_attributes.
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
end
|
|
38
|
-
end
|
|
39
|
-
if sx then
|
|
40
|
-
for _k, _v in sx do
|
|
41
|
-
_attributes[_k] = _v
|
|
42
|
-
end
|
|
43
|
-
end
|
|
43
|
+
_attributes.hostRef = ref
|
|
44
|
+
_attributes.base = styles.root
|
|
45
|
+
_attributes.className = className
|
|
46
|
+
_attributes.sx = sx
|
|
47
|
+
_attributes.state = {
|
|
48
|
+
disabled = disabled,
|
|
49
|
+
}
|
|
44
50
|
local _attributes_1 = table.clone(styles.wrap)
|
|
45
51
|
setmetatable(_attributes_1, nil)
|
|
46
52
|
local _exp = React.createElement("uilistlayout", _attributes_1)
|
|
47
|
-
local _exp_1 = rectFields()
|
|
48
53
|
-- ▼ ReadonlyArray.map ▼
|
|
49
|
-
local _newValue = table.create(#
|
|
50
|
-
local _callback = function(
|
|
54
|
+
local _newValue = table.create(#GROUPS)
|
|
55
|
+
local _callback = function(group, groupIndex)
|
|
51
56
|
local _attributes_2 = {
|
|
52
|
-
key =
|
|
57
|
+
key = group.title,
|
|
53
58
|
}
|
|
54
|
-
for _k, _v in styles.
|
|
59
|
+
for _k, _v in styles.group do
|
|
55
60
|
_attributes_2[_k] = _v
|
|
56
61
|
end
|
|
57
|
-
_attributes_2.LayoutOrder =
|
|
58
|
-
local _attributes_3 = table.clone(styles.
|
|
62
|
+
_attributes_2.LayoutOrder = groupIndex + 1
|
|
63
|
+
local _attributes_3 = table.clone(styles.wrap)
|
|
59
64
|
setmetatable(_attributes_3, nil)
|
|
60
|
-
local
|
|
61
|
-
local _attributes_4 = table.clone(styles.
|
|
65
|
+
local _exp_1 = React.createElement("uilistlayout", _attributes_3)
|
|
66
|
+
local _attributes_4 = table.clone(styles.groupLabel)
|
|
62
67
|
setmetatable(_attributes_4, nil)
|
|
63
|
-
_attributes_4.Text =
|
|
64
|
-
|
|
65
|
-
local
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
68
|
+
_attributes_4.Text = group.title
|
|
69
|
+
_attributes_4.LayoutOrder = 1
|
|
70
|
+
local _exp_2 = React.createElement("textlabel", _attributes_4)
|
|
71
|
+
local _attributes_5 = {
|
|
72
|
+
key = "Pair",
|
|
73
|
+
}
|
|
74
|
+
for _k, _v in styles.group do
|
|
75
|
+
_attributes_5[_k] = _v
|
|
76
|
+
end
|
|
77
|
+
_attributes_5.LayoutOrder = 2
|
|
78
|
+
local _attributes_6 = table.clone(styles.pair)
|
|
79
|
+
setmetatable(_attributes_6, nil)
|
|
80
|
+
local _exp_3 = React.createElement("uilistlayout", _attributes_6)
|
|
81
|
+
local _exp_4 = group.fields
|
|
82
|
+
-- ▼ ReadonlyArray.map ▼
|
|
83
|
+
local _newValue_1 = table.create(#_exp_4)
|
|
84
|
+
local _callback_1 = function(field, index)
|
|
85
|
+
local _attributes_7 = {
|
|
86
|
+
key = field,
|
|
87
|
+
}
|
|
88
|
+
for _k, _v in styles.cell do
|
|
89
|
+
_attributes_7[_k] = _v
|
|
90
|
+
end
|
|
91
|
+
_attributes_7.LayoutOrder = index + 1
|
|
92
|
+
local _attributes_8 = table.clone(styles.stack)
|
|
93
|
+
setmetatable(_attributes_8, nil)
|
|
94
|
+
local _exp_5 = React.createElement("uilistlayout", _attributes_8)
|
|
95
|
+
local _attributes_9 = table.clone(styles.label)
|
|
96
|
+
setmetatable(_attributes_9, nil)
|
|
97
|
+
_attributes_9.Text = field
|
|
98
|
+
_attributes_9.LayoutOrder = 1
|
|
99
|
+
local _exp_6 = React.createElement("textlabel", _attributes_9)
|
|
100
|
+
local _attributes_10 = table.clone(styles.field)
|
|
101
|
+
setmetatable(_attributes_10, nil)
|
|
102
|
+
_attributes_10.LayoutOrder = 2
|
|
103
|
+
return React.createElement("frame", _attributes_7, _exp_5, _exp_6, React.createElement("frame", _attributes_10, React.createElement(NumberInput, {
|
|
104
|
+
value = amounts[field],
|
|
105
|
+
places = 4,
|
|
106
|
+
disabled = disabled,
|
|
107
|
+
width = UDim.new(1, 0),
|
|
108
|
+
onChange = function(amount)
|
|
109
|
+
return commit(field, amount)
|
|
110
|
+
end,
|
|
111
|
+
})))
|
|
112
|
+
end
|
|
113
|
+
for _k, _v in _exp_4 do
|
|
114
|
+
_newValue_1[_k] = _callback_1(_v, _k - 1, _exp_4)
|
|
115
|
+
end
|
|
116
|
+
-- ▲ ReadonlyArray.map ▲
|
|
117
|
+
return React.createElement("frame", _attributes_2, _exp_1, _exp_2, React.createElement("frame", _attributes_5, _exp_3, React.createElement(React.Fragment, nil, _newValue_1)))
|
|
75
118
|
end
|
|
76
|
-
for _k, _v in
|
|
77
|
-
_newValue[_k] = _callback(_v, _k - 1,
|
|
119
|
+
for _k, _v in GROUPS do
|
|
120
|
+
_newValue[_k] = _callback(_v, _k - 1, GROUPS)
|
|
78
121
|
end
|
|
79
122
|
-- ▲ ReadonlyArray.map ▲
|
|
80
|
-
return React.createElement(
|
|
123
|
+
return React.createElement(SxHost, _attributes, _exp, React.createElement(React.Fragment, nil, _newValue))
|
|
81
124
|
end
|
|
82
125
|
local default = RectEditor
|
|
83
126
|
return {
|
|
@@ -1,9 +1,11 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
|
|
4
|
+
local controlMetrics = _theme.controlMetrics
|
|
4
5
|
local createStyles = _theme.createStyles
|
|
5
6
|
local componentStyles = _theme.componentStyles
|
|
6
7
|
local useRectEditorStyles = componentStyles("RectEditor", function(theme)
|
|
8
|
+
local gap = theme.padding.calc(1)
|
|
7
9
|
return createStyles({
|
|
8
10
|
root = {
|
|
9
11
|
Size = UDim2.new(1, 0, 0, 0),
|
|
@@ -16,26 +18,47 @@ local useRectEditorStyles = componentStyles("RectEditor", function(theme)
|
|
|
16
18
|
Padding = UDim.new(0, theme.padding.calc(0.5)),
|
|
17
19
|
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
18
20
|
},
|
|
19
|
-
|
|
21
|
+
group = {
|
|
22
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
23
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
24
|
+
BackgroundTransparency = 1,
|
|
25
|
+
},
|
|
26
|
+
groupLabel = {
|
|
27
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
28
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
29
|
+
BackgroundTransparency = 1,
|
|
30
|
+
Font = theme.typography.fontFamilies.default,
|
|
31
|
+
TextSize = theme.typography.fontSizes.caption,
|
|
32
|
+
TextColor3 = theme.palette.text.secondary,
|
|
33
|
+
TextXAlignment = Enum.TextXAlignment.Left,
|
|
34
|
+
},
|
|
35
|
+
pair = {
|
|
20
36
|
FillDirection = Enum.FillDirection.Horizontal,
|
|
21
|
-
Padding = UDim.new(0,
|
|
22
|
-
VerticalAlignment = Enum.VerticalAlignment.Center,
|
|
37
|
+
Padding = UDim.new(0, gap),
|
|
23
38
|
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
24
39
|
},
|
|
25
|
-
|
|
26
|
-
Size = UDim2.new(
|
|
40
|
+
cell = {
|
|
41
|
+
Size = UDim2.new(0.5, -gap / 2, 0, 0),
|
|
42
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
27
43
|
BackgroundTransparency = 1,
|
|
28
44
|
},
|
|
45
|
+
stack = {
|
|
46
|
+
FillDirection = Enum.FillDirection.Vertical,
|
|
47
|
+
Padding = UDim.new(0, theme.padding.calc(0.5)),
|
|
48
|
+
SortOrder = Enum.SortOrder.LayoutOrder,
|
|
49
|
+
},
|
|
29
50
|
label = {
|
|
30
|
-
Size = UDim2.new(
|
|
51
|
+
Size = UDim2.new(1, 0, 0, 0),
|
|
52
|
+
AutomaticSize = Enum.AutomaticSize.Y,
|
|
31
53
|
BackgroundTransparency = 1,
|
|
32
54
|
Font = theme.typography.fontFamilies.default,
|
|
33
55
|
TextSize = theme.typography.fontSizes.caption,
|
|
34
56
|
TextColor3 = theme.palette.text.secondary,
|
|
35
57
|
TextXAlignment = Enum.TextXAlignment.Left,
|
|
58
|
+
TextTruncate = Enum.TextTruncate.AtEnd,
|
|
36
59
|
},
|
|
37
60
|
field = {
|
|
38
|
-
Size = UDim2.new(1,
|
|
61
|
+
Size = UDim2.new(1, 0, 0, controlMetrics(theme.density).height),
|
|
39
62
|
BackgroundTransparency = 1,
|
|
40
63
|
},
|
|
41
64
|
})
|
|
@@ -17,6 +17,7 @@ local canActivate = TS.import(script, script.Parent.Parent.Parent, "button", "co
|
|
|
17
17
|
local spinnerPixels = TS.import(script, script.Parent.Parent.Parent, "button", "components", "buttonLook").spinnerPixels
|
|
18
18
|
local CircularProgress = TS.import(script, script.Parent.Parent.Parent, "circularProgress").CircularProgress
|
|
19
19
|
local Input = TS.import(script, script.Parent.Parent.Parent, "input").Input
|
|
20
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
20
21
|
local Popup = TS.import(script, script.Parent.Parent.Parent, "popup").Popup
|
|
21
22
|
local Shadow = TS.import(script, script.Parent.Parent.Parent, "shadow").Shadow
|
|
22
23
|
local _virtualList = TS.import(script, script.Parent.Parent.Parent, "virtualList")
|
|
@@ -244,26 +245,22 @@ local function Select(props)
|
|
|
244
245
|
setQuery("")
|
|
245
246
|
end
|
|
246
247
|
end, { loading, open })
|
|
247
|
-
local _attributes = {
|
|
248
|
+
local _attributes = {
|
|
249
|
+
tag = "frame",
|
|
250
|
+
}
|
|
248
251
|
local _condition_2 = id
|
|
249
252
|
if not (_condition_2 ~= 0 and _condition_2 == _condition_2 and _condition_2 ~= "" and _condition_2) then
|
|
250
253
|
_condition_2 = "Select"
|
|
251
254
|
end
|
|
252
255
|
_attributes.key = _condition_2
|
|
253
|
-
_attributes.
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
end
|
|
262
|
-
if sx then
|
|
263
|
-
for _k, _v in sx do
|
|
264
|
-
_attributes[_k] = _v
|
|
265
|
-
end
|
|
266
|
-
end
|
|
256
|
+
_attributes.hostRef = ref
|
|
257
|
+
_attributes.base = styles.root
|
|
258
|
+
_attributes.className = className
|
|
259
|
+
_attributes.sx = sx
|
|
260
|
+
_attributes.state = {
|
|
261
|
+
disabled = disabled,
|
|
262
|
+
loading = loading,
|
|
263
|
+
}
|
|
267
264
|
local _attributes_1 = {
|
|
268
265
|
key = "Trigger",
|
|
269
266
|
ref = setAnchor,
|
|
@@ -434,7 +431,7 @@ local function Select(props)
|
|
|
434
431
|
end,
|
|
435
432
|
})))))
|
|
436
433
|
end
|
|
437
|
-
return React.createElement(
|
|
434
|
+
return React.createElement(SxHost, _attributes, _exp_2, _condition_3)
|
|
438
435
|
end
|
|
439
436
|
local default = Select
|
|
440
437
|
return {
|
|
@@ -4,49 +4,63 @@ local _react = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
|
4
4
|
local React = _react
|
|
5
5
|
local useEffect = _react.useEffect
|
|
6
6
|
local useState = _react.useState
|
|
7
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
7
8
|
local useShadowStyles = TS.import(script, script.Parent, "Shadow.styles").default
|
|
8
|
-
local function Shadow()
|
|
9
|
+
local function Shadow(props)
|
|
9
10
|
local _binding = useShadowStyles()
|
|
10
11
|
local container = _binding.container
|
|
12
|
+
local blob = _binding.blob
|
|
11
13
|
local parent, setParent = useState(nil)
|
|
12
14
|
local cornerRadius, setCornerRadius = useState()
|
|
15
|
+
local blobSize, setBlobSize = useState(UDim2.fromOffset(0, 0))
|
|
16
|
+
local _binding_1 = props
|
|
17
|
+
local className = _binding_1.className
|
|
18
|
+
local sx = _binding_1.sx
|
|
19
|
+
local id = _binding_1.id
|
|
20
|
+
local ref = _binding_1.ref
|
|
13
21
|
local _condition = container.ZIndex
|
|
14
22
|
if _condition == nil then
|
|
15
23
|
_condition = 0
|
|
16
24
|
end
|
|
17
25
|
local defaultZIndex = _condition
|
|
18
26
|
local zIndex, setZIndex = useState(defaultZIndex)
|
|
19
|
-
-- Set any inherited properties
|
|
20
27
|
useEffect(function()
|
|
21
28
|
if not parent then
|
|
22
29
|
return nil
|
|
23
30
|
end
|
|
24
|
-
local _cornerRadius = parent
|
|
31
|
+
local _cornerRadius = parent:FindFirstChildOfClass("UICorner")
|
|
25
32
|
if _cornerRadius ~= nil then
|
|
26
|
-
_cornerRadius = _cornerRadius
|
|
27
|
-
if _cornerRadius ~= nil then
|
|
28
|
-
_cornerRadius = _cornerRadius.CornerRadius
|
|
29
|
-
end
|
|
33
|
+
_cornerRadius = _cornerRadius.CornerRadius
|
|
30
34
|
end
|
|
31
35
|
local cornerRadius = _cornerRadius
|
|
32
36
|
setCornerRadius(cornerRadius)
|
|
33
|
-
local
|
|
34
|
-
if _result ~= nil then
|
|
35
|
-
_result = _result.ZIndex
|
|
36
|
-
end
|
|
37
|
-
local _condition_1 = _result
|
|
37
|
+
local _condition_1 = parent.ZIndex
|
|
38
38
|
if _condition_1 == nil then
|
|
39
39
|
_condition_1 = defaultZIndex
|
|
40
40
|
end
|
|
41
41
|
setZIndex(_condition_1 - 1)
|
|
42
42
|
parent.ClipsDescendants = false
|
|
43
|
+
local sync = function()
|
|
44
|
+
setBlobSize(UDim2.fromOffset(parent.AbsoluteSize.X, parent.AbsoluteSize.Y))
|
|
45
|
+
end
|
|
46
|
+
sync()
|
|
47
|
+
local conn = parent:GetPropertyChangedSignal("AbsoluteSize"):Connect(sync)
|
|
48
|
+
return function()
|
|
49
|
+
return conn:Disconnect()
|
|
50
|
+
end
|
|
43
51
|
end, { parent })
|
|
44
52
|
local _attributes = {
|
|
45
|
-
|
|
53
|
+
tag = "frame",
|
|
46
54
|
}
|
|
47
|
-
|
|
48
|
-
|
|
55
|
+
local _condition_1 = id
|
|
56
|
+
if not (_condition_1 ~= 0 and _condition_1 == _condition_1 and _condition_1 ~= "" and _condition_1) then
|
|
57
|
+
_condition_1 = "Shadow"
|
|
49
58
|
end
|
|
59
|
+
_attributes.key = _condition_1
|
|
60
|
+
_attributes.hostRef = ref
|
|
61
|
+
_attributes.base = container
|
|
62
|
+
_attributes.className = className
|
|
63
|
+
_attributes.sx = sx
|
|
50
64
|
_attributes.ZIndex = zIndex
|
|
51
65
|
_attributes.Event = {
|
|
52
66
|
AncestryChanged = function(rbx, parent)
|
|
@@ -55,10 +69,18 @@ local function Shadow()
|
|
|
55
69
|
end
|
|
56
70
|
end,
|
|
57
71
|
}
|
|
58
|
-
|
|
72
|
+
local _attributes_1 = {
|
|
73
|
+
key = "Blob",
|
|
74
|
+
}
|
|
75
|
+
for _k, _v in blob do
|
|
76
|
+
_attributes_1[_k] = _v
|
|
77
|
+
end
|
|
78
|
+
_attributes_1.Size = blobSize
|
|
79
|
+
_attributes_1.ZIndex = zIndex
|
|
80
|
+
return React.createElement(SxHost, _attributes, React.createElement("frame", _attributes_1, cornerRadius ~= nil and React.createElement("uicorner", {
|
|
59
81
|
key = "Corner",
|
|
60
82
|
CornerRadius = cornerRadius,
|
|
61
|
-
}))
|
|
83
|
+
})))
|
|
62
84
|
end
|
|
63
85
|
local default = Shadow
|
|
64
86
|
return {
|
|
@@ -6,11 +6,16 @@ local componentStyles = _theme.componentStyles
|
|
|
6
6
|
local useShadowStyles = componentStyles("Shadow", function(theme)
|
|
7
7
|
return createStyles({
|
|
8
8
|
container = {
|
|
9
|
-
Size = UDim2.
|
|
9
|
+
Size = UDim2.fromOffset(0, 0),
|
|
10
|
+
BackgroundTransparency = 1,
|
|
11
|
+
BorderSizePixel = 0,
|
|
12
|
+
ZIndex = -100,
|
|
13
|
+
},
|
|
14
|
+
blob = {
|
|
10
15
|
BackgroundColor3 = theme.palette.shadow,
|
|
11
16
|
BackgroundTransparency = 0.8,
|
|
12
17
|
BorderSizePixel = 0,
|
|
13
|
-
|
|
18
|
+
Position = UDim2.fromOffset(theme.spacing.calc(0.25), theme.spacing.calc(0.25)),
|
|
14
19
|
},
|
|
15
20
|
})
|
|
16
21
|
end)
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
+
local SxHost = TS.import(script, script.Parent.Parent.Parent, "host").SxHost
|
|
4
5
|
local useSidebarStyles = TS.import(script, script.Parent, "Sidebar.styles").default
|
|
5
6
|
local function Sidebar(props)
|
|
6
7
|
local _binding = props
|
|
@@ -12,33 +13,25 @@ local function Sidebar(props)
|
|
|
12
13
|
local _binding_1 = useSidebarStyles(props)
|
|
13
14
|
local root = _binding_1.root
|
|
14
15
|
local container = _binding_1.container
|
|
15
|
-
local _attributes = {
|
|
16
|
+
local _attributes = {
|
|
17
|
+
tag = "frame",
|
|
18
|
+
}
|
|
16
19
|
local _condition = id
|
|
17
20
|
if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
|
|
18
21
|
_condition = "Sidebar"
|
|
19
22
|
end
|
|
20
23
|
_attributes.key = _condition
|
|
21
|
-
_attributes.
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
if className ~= 0 and className == className and className ~= "" and className then
|
|
26
|
-
for _k, _v in className do
|
|
27
|
-
_attributes[_k] = _v
|
|
28
|
-
end
|
|
29
|
-
end
|
|
30
|
-
if sx ~= 0 and sx == sx and sx ~= "" and sx then
|
|
31
|
-
for _k, _v in sx do
|
|
32
|
-
_attributes[_k] = _v
|
|
33
|
-
end
|
|
34
|
-
end
|
|
24
|
+
_attributes.hostRef = ref
|
|
25
|
+
_attributes.base = root
|
|
26
|
+
_attributes.className = className
|
|
27
|
+
_attributes.sx = sx
|
|
35
28
|
local _attributes_1 = {
|
|
36
29
|
key = "Container",
|
|
37
30
|
}
|
|
38
31
|
for _k, _v in container do
|
|
39
32
|
_attributes_1[_k] = _v
|
|
40
33
|
end
|
|
41
|
-
return React.createElement(
|
|
34
|
+
return React.createElement(SxHost, _attributes, React.createElement("frame", _attributes_1, children))
|
|
42
35
|
end
|
|
43
36
|
local default = Sidebar
|
|
44
37
|
return {
|