@rbxts/uiblox 0.2.0-alpha.4 → 0.2.0-alpha.6

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.
Files changed (76) hide show
  1. package/out/ui/packages/alert/components/Alert.luau +34 -27
  2. package/out/ui/packages/alert/components/Alert.styles.d.ts +1 -0
  3. package/out/ui/packages/alert/components/Alert.styles.luau +10 -2
  4. package/out/ui/packages/autocomplete/components/Autocomplete.luau +8 -0
  5. package/out/ui/packages/checkbox/components/checkboxLook.d.ts +1 -1
  6. package/out/ui/packages/chip/components/Chip.d.ts +1 -0
  7. package/out/ui/packages/chip/components/Chip.luau +37 -2
  8. package/out/ui/packages/chip/components/Chip.styles.d.ts +1 -0
  9. package/out/ui/packages/chip/components/Chip.styles.luau +29 -1
  10. package/out/ui/packages/circularProgress/components/CircularProgress.luau +13 -2
  11. package/out/ui/packages/formText/components/FormHelperText.d.ts +8 -0
  12. package/out/ui/packages/formText/components/FormHelperText.luau +44 -0
  13. package/out/ui/packages/formText/components/FormLabel.d.ts +9 -0
  14. package/out/ui/packages/formText/components/FormLabel.luau +46 -0
  15. package/out/ui/packages/formText/components/FormText.styles.d.ts +5 -0
  16. package/out/ui/packages/formText/components/FormText.styles.luau +33 -0
  17. package/out/ui/packages/formText/index.d.ts +4 -0
  18. package/out/ui/packages/formText/init.luau +6 -0
  19. package/out/ui/packages/imageList/components/ImageList.d.ts +14 -0
  20. package/out/ui/packages/imageList/components/ImageList.luau +84 -0
  21. package/out/ui/packages/imageList/components/ImageList.styles.d.ts +6 -0
  22. package/out/ui/packages/imageList/components/ImageList.styles.luau +54 -0
  23. package/out/ui/packages/imageList/components/imageListLayout.d.ts +3 -0
  24. package/out/ui/packages/imageList/components/imageListLayout.luau +24 -0
  25. package/out/ui/packages/imageList/index.d.ts +2 -0
  26. package/out/ui/packages/imageList/init.luau +5 -0
  27. package/out/ui/packages/index.d.ts +3 -0
  28. package/out/ui/packages/init.luau +9 -0
  29. package/out/ui/packages/layout/components/Box.d.ts +11 -0
  30. package/out/ui/packages/layout/components/Box.luau +49 -0
  31. package/out/ui/packages/layout/components/Box.styles.d.ts +7 -0
  32. package/out/ui/packages/layout/components/Box.styles.luau +34 -0
  33. package/out/ui/packages/layout/components/Stack.d.ts +12 -0
  34. package/out/ui/packages/layout/components/Stack.luau +49 -0
  35. package/out/ui/packages/layout/components/Stack.styles.d.ts +8 -0
  36. package/out/ui/packages/layout/components/Stack.styles.luau +72 -0
  37. package/out/ui/packages/layout/components/boxPad.d.ts +14 -0
  38. package/out/ui/packages/layout/components/boxPad.luau +59 -0
  39. package/out/ui/packages/layout/components/stackAlign.d.ts +8 -0
  40. package/out/ui/packages/layout/components/stackAlign.luau +29 -0
  41. package/out/ui/packages/layout/index.d.ts +7 -0
  42. package/out/ui/packages/layout/init.luau +2 -0
  43. package/out/ui/packages/menu/components/Menu.d.ts +3 -0
  44. package/out/ui/packages/menu/components/Menu.luau +48 -23
  45. package/out/ui/packages/menu/components/Menu.styles.luau +5 -1
  46. package/out/ui/packages/motion/index.d.ts +1 -1
  47. package/out/ui/packages/motion/init.luau +1 -0
  48. package/out/ui/packages/motion/unit.d.ts +5 -0
  49. package/out/ui/packages/motion/unit.luau +23 -0
  50. package/out/ui/packages/radioGroup/components/RadioGroup.d.ts +1 -0
  51. package/out/ui/packages/radioGroup/components/RadioGroup.luau +4 -2
  52. package/out/ui/packages/radioGroup/components/RadioGroup.styles.d.ts +1 -0
  53. package/out/ui/packages/radioGroup/components/RadioGroup.styles.luau +4 -1
  54. package/out/ui/packages/select/components/Select.d.ts +5 -0
  55. package/out/ui/packages/select/components/Select.luau +48 -24
  56. package/out/ui/packages/select/components/Select.styles.luau +1 -1
  57. package/out/ui/packages/skeleton/components/Skeleton.styles.luau +7 -3
  58. package/out/ui/packages/skeleton/components/skeletonTone.d.ts +20 -0
  59. package/out/ui/packages/skeleton/components/skeletonTone.luau +14 -0
  60. package/out/ui/packages/speedDial/components/SpeedDial.d.ts +17 -0
  61. package/out/ui/packages/speedDial/components/SpeedDial.luau +92 -0
  62. package/out/ui/packages/speedDial/components/SpeedDial.styles.d.ts +2 -0
  63. package/out/ui/packages/speedDial/components/SpeedDial.styles.luau +26 -0
  64. package/out/ui/packages/speedDial/index.d.ts +2 -0
  65. package/out/ui/packages/speedDial/init.luau +5 -0
  66. package/out/ui/packages/splitPane/components/splitLook.d.ts +1 -1
  67. package/out/ui/packages/stateMatrix.d.ts +1 -0
  68. package/out/ui/packages/stateMatrix.luau +239 -81
  69. package/out/ui/packages/switch/components/switchLook.d.ts +1 -1
  70. package/out/ui/packages/virtualList/components/EmptyListHint.d.ts +6 -0
  71. package/out/ui/packages/virtualList/components/EmptyListHint.luau +32 -0
  72. package/out/ui/packages/virtualList/components/EmptyListHint.styles.d.ts +5 -0
  73. package/out/ui/packages/virtualList/components/EmptyListHint.styles.luau +26 -0
  74. package/out/ui/packages/virtualList/index.d.ts +2 -0
  75. package/out/ui/packages/virtualList/init.luau +1 -0
  76. package/package.json +2 -2
@@ -10,17 +10,19 @@ local function RadioGroup(props)
10
10
  local onChange = _binding.onChange
11
11
  local disabled = _binding.disabled
12
12
  local size = _binding.size
13
+ local row = _binding.row
13
14
  local className = _binding.className
14
15
  local sx = _binding.sx
15
16
  local id = _binding.id
16
17
  local ref = _binding.ref
17
18
  local _binding_1 = useRadioGroupStyles({
18
19
  size = size,
20
+ row = row,
19
21
  })
20
22
  local root = _binding_1.root
21
23
  local list = _binding_1.list
22
24
  local option = _binding_1.option
23
- local row = _binding_1.row
25
+ local optionRow = _binding_1.optionRow
24
26
  local ring = _binding_1.ring
25
27
  local dot = _binding_1.dot
26
28
  local stroke = _binding_1.stroke
@@ -70,7 +72,7 @@ local function RadioGroup(props)
70
72
  end
71
73
  end,
72
74
  }
73
- local _attributes_3 = table.clone(row)
75
+ local _attributes_3 = table.clone(optionRow)
74
76
  setmetatable(_attributes_3, nil)
75
77
  local _exp_1 = React.createElement("uilistlayout", _attributes_3)
76
78
  local _attributes_4 = table.clone(ring)
@@ -1,6 +1,7 @@
1
1
  import { ControlSize } from "../../../../theme/index";
2
2
  export interface RadioGroupStyleProps {
3
3
  size?: ControlSize;
4
+ row?: boolean;
4
5
  }
5
6
  declare const useRadioGroupStyles: (props: RadioGroupStyleProps) => import("../../../../theme/index").ClassNameMap<string>;
6
7
  export default useRadioGroupStyles;
@@ -6,6 +6,7 @@ local createStyles = _theme.createStyles
6
6
  local componentStyles = _theme.componentStyles
7
7
  local useRadioGroupStyles = componentStyles("RadioGroup", function(theme, _param)
8
8
  local size = _param.size
9
+ local row = _param.row
9
10
  local metrics = controlMetrics(theme.density, size)
10
11
  return createStyles({
11
12
  root = {
@@ -15,8 +16,10 @@ local useRadioGroupStyles = componentStyles("RadioGroup", function(theme, _param
15
16
  BorderSizePixel = 0,
16
17
  },
17
18
  list = {
19
+ FillDirection = if row == true then Enum.FillDirection.Horizontal else Enum.FillDirection.Vertical,
18
20
  Padding = UDim.new(0, theme.padding.default),
19
21
  SortOrder = Enum.SortOrder.LayoutOrder,
22
+ VerticalAlignment = Enum.VerticalAlignment.Center,
20
23
  },
21
24
  option = {
22
25
  AutomaticSize = Enum.AutomaticSize.XY,
@@ -25,7 +28,7 @@ local useRadioGroupStyles = componentStyles("RadioGroup", function(theme, _param
25
28
  BorderSizePixel = 0,
26
29
  Text = "",
27
30
  },
28
- row = {
31
+ optionRow = {
29
32
  FillDirection = Enum.FillDirection.Horizontal,
30
33
  Padding = UDim.new(0, theme.padding.default),
31
34
  VerticalAlignment = Enum.VerticalAlignment.Center,
@@ -1,3 +1,4 @@
1
+ import React from "@rbxts/react";
1
2
  import { ControlSize, CustomizedProps } from "../../../../theme/index";
2
3
  import { ChoiceOption } from "../../radioGroup/index";
3
4
  export interface SelectProps<T> {
@@ -9,6 +10,10 @@ export interface SelectProps<T> {
9
10
  loading?: boolean;
10
11
  placeholder?: string;
11
12
  searchable?: boolean;
13
+ defaultOpen?: boolean;
14
+ defaultQuery?: string;
15
+ emptyText?: string;
16
+ empty?: React.Element;
12
17
  reducedMotion?: boolean;
13
18
  size?: ControlSize;
14
19
  }
@@ -20,7 +20,9 @@ local Input = TS.import(script, script.Parent.Parent.Parent, "input").Input
20
20
  local playProperty = TS.import(script, script.Parent.Parent.Parent, "motion").playProperty
21
21
  local Popup = TS.import(script, script.Parent.Parent.Parent, "popup").Popup
22
22
  local Shadow = TS.import(script, script.Parent.Parent.Parent, "shadow").Shadow
23
- local VirtualList = TS.import(script, script.Parent.Parent.Parent, "virtualList").VirtualList
23
+ local _virtualList = TS.import(script, script.Parent.Parent.Parent, "virtualList")
24
+ local EmptyListHint = _virtualList.EmptyListHint
25
+ local VirtualList = _virtualList.VirtualList
24
26
  local useSelectStyles = TS.import(script, script.Parent, "Select.styles").default
25
27
  local optionLabel = TS.import(script, script.Parent, "optionLabel").optionLabel
26
28
  local _selectFilter = TS.import(script, script.Parent, "selectFilter")
@@ -53,6 +55,10 @@ local function Select(props)
53
55
  placeholder = ""
54
56
  end
55
57
  local searchable = _binding.searchable
58
+ local defaultOpen = _binding.defaultOpen
59
+ local defaultQuery = _binding.defaultQuery
60
+ local emptyText = _binding.emptyText
61
+ local empty = _binding.empty
56
62
  local reducedProp = _binding.reducedMotion
57
63
  local size = _binding.size
58
64
  local className = _binding.className
@@ -68,11 +74,15 @@ local function Select(props)
68
74
  local row = controlMetrics(theme.density, size).height
69
75
  local active = canActivate(disabled, loading)
70
76
  local anchor, setAnchor = useState()
71
- local open, setOpen = useState(false)
77
+ local open, setOpen = useState(defaultOpen == true and not loading)
72
78
  local held, setHeld = useState(false)
73
79
  local focused, setFocused = useState(false)
74
80
  local highlight, setHighlight = useState(-1)
75
- local query, setQuery = useState("")
81
+ local _condition = defaultQuery
82
+ if _condition == nil then
83
+ _condition = ""
84
+ end
85
+ local query, setQuery = useState(_condition)
76
86
  local recent = useRef()
77
87
  local typed = useRef()
78
88
  local onKeyRef = useRef()
@@ -95,7 +105,20 @@ local function Select(props)
95
105
  local search = usesSelectSearch(#options, searchable)
96
106
  local filtered = filterChoices(options, query)
97
107
  local rows = groupRows(filtered)
98
- local menuHeight = math.min(#rows * row, theme.spacing.calc(16)) + (if search then row else 0)
108
+ local listHeight = if #rows == 0 then row else math.min(#rows * row, theme.spacing.calc(16))
109
+ local menuHeight = listHeight + (if search then row else 0)
110
+ local _condition_1 = empty
111
+ if _condition_1 == nil then
112
+ local _attributes = {}
113
+ local _condition_2 = emptyText
114
+ if _condition_2 == nil then
115
+ _condition_2 = (if #query > 0 or #options > 0 then "No results" else "No options")
116
+ end
117
+ _attributes.text = _condition_2
118
+ _attributes.height = row
119
+ _condition_1 = (React.createElement(EmptyListHint, _attributes))
120
+ end
121
+ local emptyHint = _condition_1
99
122
  local close = function()
100
123
  setOpen(false)
101
124
  setQuery("")
@@ -125,15 +148,15 @@ local function Select(props)
125
148
  if fromPointer == nil then
126
149
  fromPointer = false
127
150
  end
128
- local _condition = fromPointer
129
- if _condition then
151
+ local _condition_2 = fromPointer
152
+ if _condition_2 then
130
153
  local _result_1 = listRef.current
131
154
  if _result_1 ~= nil then
132
155
  _result_1 = _result_1.suppressClick()
133
156
  end
134
- _condition = _result_1
157
+ _condition_2 = _result_1
135
158
  end
136
- if _condition then
159
+ if _condition_2 then
137
160
  return nil
138
161
  end
139
162
  local choice = filtered[index + 1]
@@ -254,11 +277,11 @@ local function Select(props)
254
277
  end
255
278
  end, { shown, held, reducedMotion })
256
279
  local _attributes = {}
257
- local _condition = id
258
- if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
259
- _condition = "Select"
280
+ local _condition_2 = id
281
+ if not (_condition_2 ~= 0 and _condition_2 == _condition_2 and _condition_2 ~= "" and _condition_2) then
282
+ _condition_2 = "Select"
260
283
  end
261
- _attributes.key = _condition
284
+ _attributes.key = _condition_2
262
285
  _attributes.ref = ref
263
286
  for _k, _v in styles.root do
264
287
  _attributes[_k] = _v
@@ -290,11 +313,11 @@ local function Select(props)
290
313
  if _result_2 ~= nil then
291
314
  _result_2 = _result_2.label
292
315
  end
293
- local _condition_1 = _result_2
294
- if _condition_1 == nil then
295
- _condition_1 = placeholder
316
+ local _condition_3 = _result_2
317
+ if _condition_3 == nil then
318
+ _condition_3 = placeholder
296
319
  end
297
- _result_1 = _condition_1
320
+ _result_1 = _condition_3
298
321
  end
299
322
  _attributes_1.Text = _result_1
300
323
  _attributes_1.Active = active
@@ -337,8 +360,8 @@ local function Select(props)
337
360
  Position = UDim2.new(1, -theme.padding.calc(1), 0.5, 0),
338
361
  },
339
362
  })))
340
- local _condition_1 = (shown or held)
341
- if _condition_1 then
363
+ local _condition_3 = (shown or held)
364
+ if _condition_3 then
342
365
  local _attributes_5 = {
343
366
  key = "Menu",
344
367
  }
@@ -356,8 +379,8 @@ local function Select(props)
356
379
  FillDirection = Enum.FillDirection.Vertical,
357
380
  SortOrder = Enum.SortOrder.LayoutOrder,
358
381
  })
359
- local _condition_2 = search
360
- if _condition_2 then
382
+ local _condition_4 = search
383
+ if _condition_4 then
361
384
  local _attributes_8 = {
362
385
  key = "Search",
363
386
  }
@@ -365,7 +388,7 @@ local function Select(props)
365
388
  _attributes_8[_k] = _v
366
389
  end
367
390
  _attributes_8.LayoutOrder = 1
368
- _condition_2 = (React.createElement("frame", _attributes_8, React.createElement(Input, {
391
+ _condition_4 = (React.createElement("frame", _attributes_8, React.createElement(Input, {
369
392
  text = query,
370
393
  placeholder = "Search",
371
394
  width = UDim.new(1, 0),
@@ -375,7 +398,7 @@ local function Select(props)
375
398
  end,
376
399
  })))
377
400
  end
378
- _condition_1 = (React.createElement(Popup, {
401
+ _condition_3 = (React.createElement(Popup, {
379
402
  anchor = anchor,
380
403
  preferredHeight = menuHeight,
381
404
  onDismiss = close,
@@ -387,7 +410,7 @@ local function Select(props)
387
410
  Size = UDim2.fromScale(1, 1),
388
411
  BackgroundTransparency = 1,
389
412
  GroupTransparency = 1,
390
- }, React.createElement("frame", _attributes_5, _exp_3, _exp_4, _exp_5, _exp_6, _condition_2, React.createElement("frame", {
413
+ }, React.createElement("frame", _attributes_5, _exp_3, _exp_4, _exp_5, _exp_6, _condition_4, React.createElement("frame", {
391
414
  key = "ListHost",
392
415
  Size = UDim2.new(1, 0, 1, if search then -row else 0),
393
416
  BackgroundTransparency = 1,
@@ -400,6 +423,7 @@ local function Select(props)
400
423
  end,
401
424
  itemHeight = row,
402
425
  listRef = listRef,
426
+ empty = emptyHint,
403
427
  className = styles.list,
404
428
  renderItem = function(row)
405
429
  if row.kind == "header" then
@@ -447,7 +471,7 @@ local function Select(props)
447
471
  end,
448
472
  }))))))
449
473
  end
450
- return React.createElement("frame", _attributes, _exp_2, _condition_1)
474
+ return React.createElement("frame", _attributes, _exp_2, _condition_3)
451
475
  end
452
476
  local default = Select
453
477
  return {
@@ -44,7 +44,7 @@ local useSelectStyles = componentStyles("Select", function(theme, _param)
44
44
  },
45
45
  list = {
46
46
  Size = UDim2.fromScale(1, 1),
47
- BackgroundColor3 = theme.palette.surface.elevated,
47
+ BackgroundTransparency = 1,
48
48
  BorderSizePixel = 0,
49
49
  ScrollBarThickness = theme.padding.default,
50
50
  ScrollBarImageColor3 = theme.palette.text.secondary,
@@ -3,16 +3,20 @@ local TS = _G[script]
3
3
  local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
4
4
  local createStyles = _theme.createStyles
5
5
  local componentStyles = _theme.componentStyles
6
+ local skeletonTone = TS.import(script, script.Parent, "skeletonTone").skeletonTone
6
7
  local useSkeletonStyles = componentStyles("Skeleton", function(theme)
8
+ local _binding = skeletonTone(theme)
9
+ local bone = _binding.bone
10
+ local shine = _binding.shine
7
11
  return createStyles({
8
12
  block = {
9
- BackgroundColor3 = theme.palette.divider,
13
+ BackgroundColor3 = bone,
10
14
  BackgroundTransparency = 0,
11
15
  BorderSizePixel = 0,
12
16
  },
13
17
  highlight = {
14
- Color = ColorSequence.new({ ColorSequenceKeypoint.new(0, theme.palette.divider), ColorSequenceKeypoint.new(0.5, theme.palette.text.secondary), ColorSequenceKeypoint.new(1, theme.palette.divider) }),
15
- Transparency = NumberSequence.new({ NumberSequenceKeypoint.new(0, 0.25), NumberSequenceKeypoint.new(0.5, 0), NumberSequenceKeypoint.new(1, 0.25) }),
18
+ Color = ColorSequence.new({ ColorSequenceKeypoint.new(0, bone), ColorSequenceKeypoint.new(0.5, shine), ColorSequenceKeypoint.new(1, bone) }),
19
+ Transparency = NumberSequence.new({ NumberSequenceKeypoint.new(0, 0.35), NumberSequenceKeypoint.new(0.5, 0), NumberSequenceKeypoint.new(1, 0.35) }),
16
20
  },
17
21
  rounded = {
18
22
  CornerRadius = UDim.new(0, theme.shape.borderRadius),
@@ -0,0 +1,20 @@
1
+ interface SkeletonPalette {
2
+ surface: {
3
+ canvas: Color3;
4
+ elevated: Color3;
5
+ };
6
+ action: {
7
+ hover: Color3;
8
+ };
9
+ text: {
10
+ secondary: Color3;
11
+ };
12
+ }
13
+ /** Bone + shimmer peak from semantic tokens; shine always lifts off the bone vs canvas. */
14
+ export declare function skeletonTone(theme: {
15
+ palette: SkeletonPalette;
16
+ }): {
17
+ bone: Color3;
18
+ shine: Color3;
19
+ };
20
+ export {};
@@ -0,0 +1,14 @@
1
+ -- Compiled with roblox-ts v3.0.0
2
+ local TS = _G[script]
3
+ local relativeLuminance = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme", "utilites", "colorMath").relativeLuminance
4
+ --* Bone + shimmer peak from semantic tokens; shine always lifts off the bone vs canvas.
5
+ local function skeletonTone(theme)
6
+ local lightCanvas = relativeLuminance(theme.palette.surface.canvas) > 0.5
7
+ return {
8
+ bone = theme.palette.action.hover,
9
+ shine = if lightCanvas then theme.palette.surface.elevated else theme.palette.text.secondary,
10
+ }
11
+ end
12
+ return {
13
+ skeletonTone = skeletonTone,
14
+ }
@@ -0,0 +1,17 @@
1
+ import { CustomizedProps } from "../../../../theme/index";
2
+ import { Icons } from "../../../enums/index";
3
+ export interface SpeedDialAction {
4
+ icon: Icons;
5
+ disabled?: boolean;
6
+ onClick?: () => void;
7
+ }
8
+ export interface SpeedDialProps {
9
+ open: boolean;
10
+ onOpenChange: (open: boolean) => void;
11
+ actions: SpeedDialAction[];
12
+ icon?: Icons;
13
+ openIcon?: Icons;
14
+ disabled?: boolean;
15
+ }
16
+ declare function SpeedDial(props: CustomizedProps<Frame, SpeedDialProps>): JSX.Element;
17
+ export default SpeedDial;
@@ -0,0 +1,92 @@
1
+ -- Compiled with roblox-ts v3.0.0
2
+ local TS = _G[script]
3
+ local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
4
+ local Icons = TS.import(script, script.Parent.Parent.Parent.Parent, "enums").Icons
5
+ local Fab = TS.import(script, script.Parent.Parent.Parent, "fab").Fab
6
+ local useSpeedDialStyles = TS.import(script, script.Parent, "SpeedDial.styles").default
7
+ local function SpeedDial(props)
8
+ local _binding = props
9
+ local open = _binding.open
10
+ local onOpenChange = _binding.onOpenChange
11
+ local actions = _binding.actions
12
+ local icon = _binding.icon
13
+ if icon == nil then
14
+ icon = Icons.OpenBox
15
+ end
16
+ local openIcon = _binding.openIcon
17
+ if openIcon == nil then
18
+ openIcon = Icons.Close
19
+ end
20
+ local disabled = _binding.disabled
21
+ local className = _binding.className
22
+ local sx = _binding.sx
23
+ local id = _binding.id
24
+ local ref = _binding.ref
25
+ local styles = useSpeedDialStyles()
26
+ local _attributes = {}
27
+ local _condition = id
28
+ if not (_condition ~= 0 and _condition == _condition and _condition ~= "" and _condition) then
29
+ _condition = "SpeedDial"
30
+ end
31
+ _attributes.key = _condition
32
+ _attributes.ref = ref
33
+ for _k, _v in styles.root do
34
+ _attributes[_k] = _v
35
+ end
36
+ if className then
37
+ for _k, _v in className do
38
+ _attributes[_k] = _v
39
+ end
40
+ end
41
+ if sx then
42
+ for _k, _v in sx do
43
+ _attributes[_k] = _v
44
+ end
45
+ end
46
+ local _attributes_1 = table.clone(styles.list)
47
+ setmetatable(_attributes_1, nil)
48
+ local _exp = React.createElement("uilistlayout", _attributes_1)
49
+ local _condition_1 = open
50
+ if _condition_1 then
51
+ -- ▼ ReadonlyArray.map ▼
52
+ local _newValue = table.create(#actions)
53
+ local _callback = function(action, index)
54
+ return React.createElement(Fab, {
55
+ key = `Action-{index}`,
56
+ icon = action.icon,
57
+ size = "small",
58
+ disabled = disabled == true or action.disabled == true,
59
+ onClick = function()
60
+ local _result = action.onClick
61
+ if _result ~= nil then
62
+ _result()
63
+ end
64
+ onOpenChange(false)
65
+ end,
66
+ className = {
67
+ LayoutOrder = index,
68
+ },
69
+ })
70
+ end
71
+ for _k, _v in actions do
72
+ _newValue[_k] = _callback(_v, _k - 1, actions)
73
+ end
74
+ -- ▲ ReadonlyArray.map ▲
75
+ _condition_1 = _newValue
76
+ end
77
+ return React.createElement("frame", _attributes, _exp, _condition_1, React.createElement(Fab, {
78
+ key = "Main",
79
+ icon = if open then openIcon else icon,
80
+ disabled = disabled,
81
+ onClick = function()
82
+ return onOpenChange(not open)
83
+ end,
84
+ className = {
85
+ LayoutOrder = 1000,
86
+ },
87
+ }))
88
+ end
89
+ local default = SpeedDial
90
+ return {
91
+ default = default,
92
+ }
@@ -0,0 +1,2 @@
1
+ declare const useSpeedDialStyles: () => import("../../../../theme/index").ClassNameMap<string>;
2
+ export default useSpeedDialStyles;
@@ -0,0 +1,26 @@
1
+ -- Compiled with roblox-ts v3.0.0
2
+ local TS = _G[script]
3
+ local _theme = TS.import(script, script.Parent.Parent.Parent.Parent.Parent, "theme")
4
+ local componentStyles = _theme.componentStyles
5
+ local createStyles = _theme.createStyles
6
+ local useSpeedDialStyles = componentStyles("SpeedDial", function(theme)
7
+ return createStyles({
8
+ root = {
9
+ AutomaticSize = Enum.AutomaticSize.XY,
10
+ Size = UDim2.fromScale(0, 0),
11
+ BackgroundTransparency = 1,
12
+ BorderSizePixel = 0,
13
+ },
14
+ list = {
15
+ FillDirection = Enum.FillDirection.Vertical,
16
+ HorizontalAlignment = Enum.HorizontalAlignment.Center,
17
+ VerticalAlignment = Enum.VerticalAlignment.Bottom,
18
+ SortOrder = Enum.SortOrder.LayoutOrder,
19
+ Padding = UDim.new(0, theme.padding.calc(1)),
20
+ },
21
+ })
22
+ end)
23
+ local default = useSpeedDialStyles
24
+ return {
25
+ default = default,
26
+ }
@@ -0,0 +1,2 @@
1
+ export { default as SpeedDial } from "./components/SpeedDial";
2
+ export { SpeedDialProps, SpeedDialAction } from "./components/SpeedDial";
@@ -0,0 +1,5 @@
1
+ -- Compiled with roblox-ts v3.0.0
2
+ local TS = _G[script]
3
+ local exports = {}
4
+ exports.SpeedDial = TS.import(script, script, "components", "SpeedDial").default
5
+ return exports
@@ -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.35 | 0.7 | 0.55;
3
+ export declare function splitRuleTransparency(pointer: SplitPointer, disabled?: boolean): 0.25 | 0.7 | 0.55 | 0.35;
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;
@@ -26,5 +26,6 @@ export interface StateCapture {
26
26
  indeterminate?: boolean;
27
27
  size?: StateSize;
28
28
  density?: StateDensity;
29
+ row?: boolean;
29
30
  }
30
31
  export declare const stateMatrix: StateCapture[];