@rbxts-ui/components 2.1.0 → 3.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/DynamicWindow/DynamicWindow.d.ts +19 -0
- package/dist/DynamicWindow/DynamicWindow.luau +327 -0
- package/dist/DynamicWindow/DynamicWindow.utils.d.ts +13 -0
- package/dist/DynamicWindow/DynamicWindow.utils.luau +46 -0
- package/dist/DynamicWindow/ResizeCornerButton.d.ts +13 -0
- package/dist/DynamicWindow/ResizeCornerButton.luau +47 -0
- package/dist/DynamicWindow/TrafficLightButton.d.ts +8 -0
- package/dist/DynamicWindow/TrafficLightButton.luau +26 -0
- package/dist/{DropdownButton.d.ts → buttons/DropdownButton.d.ts} +1 -3
- package/dist/{DropdownButton.luau → buttons/DropdownButton.luau} +4 -9
- package/dist/{DropdownOptionButton.d.ts → buttons/DropdownOptionButton.d.ts} +1 -3
- package/dist/{DropdownOptionButton.luau → buttons/DropdownOptionButton.luau} +3 -7
- package/dist/{IconRoundButton.d.ts → buttons/IconRoundButton.d.ts} +1 -3
- package/dist/{IconRoundButton.luau → buttons/IconRoundButton.luau} +4 -8
- package/dist/{IconTileButton.d.ts → buttons/IconTileButton.d.ts} +1 -3
- package/dist/{IconTileButton.luau → buttons/IconTileButton.luau} +8 -11
- package/dist/{PrimaryButton.d.ts → buttons/PrimaryButton.d.ts} +1 -3
- package/dist/{PrimaryButton.luau → buttons/PrimaryButton.luau} +4 -9
- package/dist/{ReactiveButton.d.ts → buttons/ReactiveButton.d.ts} +1 -3
- package/dist/{ReactiveButton.luau → buttons/ReactiveButton.luau} +5 -10
- package/dist/{TextButton.d.ts → buttons/TextButton.d.ts} +1 -3
- package/dist/{TextButton.luau → buttons/TextButton.luau} +7 -11
- package/dist/display/AlertBox.d.ts +11 -0
- package/dist/display/AlertBox.luau +56 -0
- package/dist/display/AlertBox.story.d.ts +12 -0
- package/dist/display/AlertBox.story.luau +37 -0
- package/dist/{Checkmark.luau → display/Checkmark.luau} +1 -1
- package/dist/{Legend.luau → display/Legend.luau} +1 -1
- package/dist/{PillText.d.ts → display/PillText.d.ts} +0 -2
- package/dist/{PillText.luau → display/PillText.luau} +6 -10
- package/dist/error-handler/ErrorHandler.d.ts +3 -0
- package/dist/error-handler/ErrorHandler.luau +18 -0
- package/dist/error-handler/ErrorPage.d.ts +6 -0
- package/dist/error-handler/ErrorPage.luau +144 -0
- package/dist/error-handler/index.d.ts +3 -0
- package/dist/error-handler/init.luau +6 -0
- package/dist/{Checkbox.d.ts → form/Checkbox.d.ts} +1 -3
- package/dist/{Checkbox.luau → form/Checkbox.luau} +5 -10
- package/dist/{CheckboxRow.d.ts → form/CheckboxRow.d.ts} +1 -3
- package/dist/{CheckboxRow.luau → form/CheckboxRow.luau} +4 -8
- package/dist/{Dropdown.d.ts → form/Dropdown.d.ts} +0 -2
- package/dist/{Dropdown.luau → form/Dropdown.luau} +7 -12
- package/dist/form/DropdownRow.d.ts +18 -0
- package/dist/form/DropdownRow.luau +28 -0
- package/dist/form/FormRow.d.ts +9 -0
- package/dist/{FormRow.luau → form/FormRow.luau} +3 -6
- package/dist/form/InputRound.d.ts +18 -0
- package/dist/form/InputRound.luau +218 -0
- package/dist/form/InputRow.d.ts +13 -0
- package/dist/form/InputRow.luau +32 -0
- package/dist/{Radio.d.ts → form/Radio.d.ts} +1 -3
- package/dist/{Radio.luau → form/Radio.luau} +5 -10
- package/dist/{RadioRow.d.ts → form/RadioRow.d.ts} +1 -3
- package/dist/{RadioRow.luau → form/RadioRow.luau} +4 -8
- package/dist/form/RoundEmoji.d.ts +8 -0
- package/dist/form/RoundEmoji.luau +40 -0
- package/dist/form/TextBox.d.ts +24 -0
- package/dist/form/TextBox.luau +57 -0
- package/dist/{TextField.d.ts → form/TextField.d.ts} +1 -1
- package/dist/{TextField.luau → form/TextField.luau} +4 -2
- package/dist/form/validation.d.ts +13 -0
- package/dist/form/validation.luau +80 -0
- package/dist/{use-button-animation.d.ts → hooks/use-button-animation.d.ts} +1 -3
- package/dist/{use-button-animation.luau → hooks/use-button-animation.luau} +3 -6
- package/dist/icons/InfoIcon.d.ts +8 -0
- package/dist/icons/InfoIcon.luau +80 -0
- package/dist/icons/WarningIcon.d.ts +8 -0
- package/dist/icons/WarningIcon.luau +85 -0
- package/dist/icons/WarningIcon.story.d.ts +16 -0
- package/dist/icons/WarningIcon.story.luau +60 -0
- package/dist/index.d.ts +52 -32
- package/dist/init.luau +68 -34
- package/dist/{Accordion.d.ts → layout/Accordion.d.ts} +1 -3
- package/dist/{Accordion.luau → layout/Accordion.luau} +4 -8
- package/dist/{Divider.luau → layout/Divider.luau} +1 -1
- package/dist/{Section.d.ts → layout/Section.d.ts} +1 -3
- package/dist/{Section.luau → layout/Section.luau} +4 -7
- package/dist/{SegmentedToggle.d.ts → layout/SegmentedToggle.d.ts} +1 -3
- package/dist/{SegmentedToggle.luau → layout/SegmentedToggle.luau} +4 -7
- package/dist/layout/SegmentedToggle.story.d.ts +10 -0
- package/dist/layout/SegmentedToggle.story.luau +72 -0
- package/dist/table/ExampleTable.d.ts +2 -0
- package/dist/table/ExampleTable.luau +46 -0
- package/dist/table/Table.d.ts +10 -0
- package/dist/table/Table.luau +26 -0
- package/dist/table/TableCell.d.ts +9 -0
- package/dist/table/TableCell.luau +26 -0
- package/dist/table/TableFooter.d.ts +9 -0
- package/dist/table/TableFooter.luau +12 -0
- package/dist/table/TableHeader.d.ts +9 -0
- package/dist/table/TableHeader.luau +12 -0
- package/dist/table/TableRow.d.ts +9 -0
- package/dist/table/TableRow.luau +24 -0
- package/dist/tooltip/Tooltip.d.ts +14 -0
- package/dist/tooltip/Tooltip.luau +65 -0
- package/dist/tooltip/useTooltip.d.ts +12 -0
- package/dist/tooltip/useTooltip.luau +40 -0
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/utils/InputCapture.d.ts +14 -0
- package/dist/utils/InputCapture.luau +217 -0
- package/dist/{Outline.d.ts → utils/Outline.d.ts} +1 -3
- package/dist/{Outline.luau → utils/Outline.luau} +3 -6
- package/package.json +12 -9
- package/dist/FormRow.d.ts +0 -11
- package/dist/theme.d.ts +0 -41
- package/dist/theme.luau +0 -58
- /package/dist/{Button.d.ts → buttons/Button.d.ts} +0 -0
- /package/dist/{Button.luau → buttons/Button.luau} +0 -0
- /package/dist/{Checkmark.d.ts → display/Checkmark.d.ts} +0 -0
- /package/dist/{Legend.d.ts → display/Legend.d.ts} +0 -0
- /package/dist/{TimeAgo.d.ts → display/TimeAgo.d.ts} +0 -0
- /package/dist/{TimeAgo.luau → display/TimeAgo.luau} +0 -0
- /package/dist/{use-button-state.d.ts → hooks/use-button-state.d.ts} +0 -0
- /package/dist/{use-button-state.luau → hooks/use-button-state.luau} +0 -0
- /package/dist/{use-input-device.d.ts → hooks/use-input-device.d.ts} +0 -0
- /package/dist/{use-input-device.luau → hooks/use-input-device.luau} +0 -0
- /package/dist/{Divider.d.ts → layout/Divider.d.ts} +0 -0
- /package/dist/{Padding.d.ts → layout/Padding.d.ts} +0 -0
- /package/dist/{Padding.luau → layout/Padding.luau} +0 -0
- /package/dist/{ClickOutsideOverlay.d.ts → utils/ClickOutsideOverlay.d.ts} +0 -0
- /package/dist/{ClickOutsideOverlay.luau → utils/ClickOutsideOverlay.luau} +0 -0
- /package/dist/{DelayRender.d.ts → utils/DelayRender.d.ts} +0 -0
- /package/dist/{DelayRender.luau → utils/DelayRender.luau} +0 -0
- /package/dist/{ErrorBoundary.d.ts → utils/ErrorBoundary.d.ts} +0 -0
- /package/dist/{ErrorBoundary.luau → utils/ErrorBoundary.luau} +0 -0
package/dist/init.luau
CHANGED
|
@@ -1,47 +1,81 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local exports = {}
|
|
4
|
-
exports.
|
|
5
|
-
|
|
6
|
-
exports.
|
|
7
|
-
exports.
|
|
8
|
-
exports.
|
|
9
|
-
exports.TextField = TS.import(script, script, "TextField").TextField
|
|
10
|
-
|
|
11
|
-
exports.
|
|
4
|
+
exports.Checkmark = TS.import(script, script, "display", "Checkmark").Checkmark
|
|
5
|
+
local _error_handler = TS.import(script, script, "error-handler")
|
|
6
|
+
exports.ErrorHandler = _error_handler.ErrorHandler
|
|
7
|
+
exports.ErrorPage = _error_handler.ErrorPage
|
|
8
|
+
exports.TextBox = TS.import(script, script, "form", "TextBox").TextBox
|
|
9
|
+
exports.TextField = TS.import(script, script, "form", "TextField").TextField
|
|
10
|
+
exports.Divider = TS.import(script, script, "layout", "Divider").Divider
|
|
11
|
+
exports.Padding = TS.import(script, script, "layout", "Padding").Padding
|
|
12
|
+
exports.DelayRender = TS.import(script, script, "utils", "DelayRender").DelayRender
|
|
13
|
+
exports.ErrorBoundary = TS.import(script, script, "utils", "ErrorBoundary").ErrorBoundary
|
|
12
14
|
-- Utilities
|
|
13
|
-
exports.
|
|
14
|
-
exports.
|
|
15
|
-
exports.
|
|
16
|
-
|
|
17
|
-
exports.
|
|
15
|
+
exports.Button = TS.import(script, script, "buttons", "Button").Button
|
|
16
|
+
exports.ReactiveButton = TS.import(script, script, "buttons", "ReactiveButton").ReactiveButton
|
|
17
|
+
exports.useButtonAnimation = TS.import(script, script, "hooks", "use-button-animation").useButtonAnimation
|
|
18
|
+
exports.useButtonState = TS.import(script, script, "hooks", "use-button-state").useButtonState
|
|
19
|
+
exports.useInputDevice = TS.import(script, script, "hooks", "use-input-device").useInputDevice
|
|
20
|
+
exports.useTooltip = TS.import(script, script, "tooltip", "useTooltip").useTooltip
|
|
21
|
+
local _ClickOutsideOverlay = TS.import(script, script, "utils", "ClickOutsideOverlay")
|
|
18
22
|
exports.ClickOutsideLayer = _ClickOutsideOverlay.ClickOutsideLayer
|
|
19
|
-
exports.
|
|
20
|
-
exports.
|
|
21
|
-
exports.
|
|
23
|
+
exports.ClickOutsideOverlay = _ClickOutsideOverlay.ClickOutsideOverlay
|
|
24
|
+
exports.InputCapture = TS.import(script, script, "utils", "InputCapture").InputCapture
|
|
25
|
+
exports.Outline = TS.import(script, script, "utils", "Outline").Outline
|
|
22
26
|
-- Form Inputs
|
|
23
|
-
exports.Checkbox = TS.import(script, script, "Checkbox").Checkbox
|
|
24
|
-
exports.Radio = TS.import(script, script, "Radio").Radio
|
|
27
|
+
exports.Checkbox = TS.import(script, script, "form", "Checkbox").Checkbox
|
|
28
|
+
exports.Radio = TS.import(script, script, "form", "Radio").Radio
|
|
25
29
|
-- Buttons
|
|
26
|
-
exports.
|
|
27
|
-
|
|
30
|
+
exports.IconRoundButton = TS.import(script, script, "buttons", "IconRoundButton").IconRoundButton
|
|
31
|
+
exports.IconTileButton = TS.import(script, script, "buttons", "IconTileButton").IconTileButton
|
|
32
|
+
exports.PrimaryButton = TS.import(script, script, "buttons", "PrimaryButton").PrimaryButton
|
|
33
|
+
local _TextButton = TS.import(script, script, "buttons", "TextButton")
|
|
28
34
|
exports.TextButton = _TextButton.TextButton
|
|
29
35
|
exports.TextButtonVariant = _TextButton.TextButtonVariant
|
|
30
|
-
exports.IconRoundButton = TS.import(script, script, "IconRoundButton").IconRoundButton
|
|
31
|
-
exports.IconTileButton = TS.import(script, script, "IconTileButton").IconTileButton
|
|
32
36
|
-- Form Layout
|
|
33
|
-
exports.
|
|
34
|
-
exports.
|
|
35
|
-
exports.
|
|
36
|
-
exports.
|
|
37
|
-
exports.
|
|
38
|
-
exports.Accordion = TS.import(script, script, "Accordion").Accordion
|
|
37
|
+
exports.CheckboxRow = TS.import(script, script, "form", "CheckboxRow").CheckboxRow
|
|
38
|
+
exports.DropdownRow = TS.import(script, script, "form", "DropdownRow").DropdownRow
|
|
39
|
+
exports.FormRow = TS.import(script, script, "form", "FormRow").FormRow
|
|
40
|
+
exports.InputRow = TS.import(script, script, "form", "InputRow").InputRow
|
|
41
|
+
exports.RadioRow = TS.import(script, script, "form", "RadioRow").RadioRow
|
|
42
|
+
exports.Accordion = TS.import(script, script, "layout", "Accordion").Accordion
|
|
43
|
+
exports.Section = TS.import(script, script, "layout", "Section").Section
|
|
44
|
+
exports.SegmentedToggle = TS.import(script, script, "layout", "SegmentedToggle").SegmentedToggle
|
|
45
|
+
-- Table
|
|
46
|
+
exports.ExampleTable = TS.import(script, script, "table", "ExampleTable").ExampleTable
|
|
47
|
+
exports.Table = TS.import(script, script, "table", "Table").Table
|
|
48
|
+
exports.TableCell = TS.import(script, script, "table", "TableCell").TableCell
|
|
49
|
+
exports.TableFooter = TS.import(script, script, "table", "TableFooter").TableFooter
|
|
50
|
+
exports.TableHeader = TS.import(script, script, "table", "TableHeader").TableHeader
|
|
51
|
+
exports.TableRow = TS.import(script, script, "table", "TableRow").TableRow
|
|
39
52
|
-- Dropdown
|
|
40
|
-
exports.
|
|
41
|
-
exports.
|
|
42
|
-
exports.
|
|
53
|
+
exports.DropdownButton = TS.import(script, script, "buttons", "DropdownButton").DropdownButton
|
|
54
|
+
exports.DropdownOptionButton = TS.import(script, script, "buttons", "DropdownOptionButton").DropdownOptionButton
|
|
55
|
+
exports.Dropdown = TS.import(script, script, "form", "Dropdown").Dropdown
|
|
43
56
|
-- Display
|
|
44
|
-
exports.
|
|
45
|
-
exports.Legend = TS.import(script, script, "Legend").Legend
|
|
46
|
-
exports.PillText = TS.import(script, script, "PillText").PillText
|
|
57
|
+
exports.AlertBox = TS.import(script, script, "display", "AlertBox").AlertBox
|
|
58
|
+
exports.Legend = TS.import(script, script, "display", "Legend").Legend
|
|
59
|
+
exports.PillText = TS.import(script, script, "display", "PillText").PillText
|
|
60
|
+
exports.TimeAgo = TS.import(script, script, "display", "TimeAgo").TimeAgo
|
|
61
|
+
exports.Tooltip = TS.import(script, script, "tooltip", "Tooltip").Tooltip
|
|
62
|
+
-- Icons
|
|
63
|
+
exports.InfoIcon = TS.import(script, script, "icons", "InfoIcon").InfoIcon
|
|
64
|
+
exports.WarningIcon = TS.import(script, script, "icons", "WarningIcon").WarningIcon
|
|
65
|
+
-- Form Validation
|
|
66
|
+
local _validation = TS.import(script, script, "form", "validation")
|
|
67
|
+
exports.validateAngle = _validation.validateAngle
|
|
68
|
+
exports.validateNumber = _validation.validateNumber
|
|
69
|
+
exports.validateNumberBounds = _validation.validateNumberBounds
|
|
70
|
+
exports.validatePosNumber = _validation.validatePosNumber
|
|
71
|
+
-- Form Input Components
|
|
72
|
+
exports.InputRound = TS.import(script, script, "form", "InputRound").InputRound
|
|
73
|
+
exports.RoundEmoji = TS.import(script, script, "form", "RoundEmoji").RoundEmoji
|
|
74
|
+
-- DynamicWindow
|
|
75
|
+
exports.DynamicWindow = TS.import(script, script, "DynamicWindow", "DynamicWindow").DynamicWindow
|
|
76
|
+
local _DynamicWindow_utils = TS.import(script, script, "DynamicWindow", "DynamicWindow.utils")
|
|
77
|
+
exports.clampViewportPosition = _DynamicWindow_utils.clampViewportPosition
|
|
78
|
+
exports.getInputViewportPos = _DynamicWindow_utils.getInputViewportPos
|
|
79
|
+
exports.getMouseViewportPos = _DynamicWindow_utils.getMouseViewportPos
|
|
80
|
+
exports.resolveWindowSpawnPosition = _DynamicWindow_utils.resolveWindowSpawnPosition
|
|
47
81
|
return exports
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import React from "@rbxts/react";
|
|
2
|
-
import { type Theme } from "./theme";
|
|
3
2
|
interface AccordionProps {
|
|
4
3
|
title: string;
|
|
5
4
|
children: React.ReactNode;
|
|
@@ -9,8 +8,7 @@ interface AccordionProps {
|
|
|
9
8
|
backgroundTransparency?: number;
|
|
10
9
|
cornerRadius?: number;
|
|
11
10
|
sortOrder?: Enum.SortOrder;
|
|
12
|
-
theme?: Theme;
|
|
13
11
|
}
|
|
14
|
-
export declare function Accordion({ title, children, backgroundColor, backgroundTransparency, cornerRadius, sortOrder, isExpanded, onExpandedChange,
|
|
12
|
+
export declare function Accordion({ title, children, backgroundColor, backgroundTransparency, cornerRadius, sortOrder, isExpanded, onExpandedChange, }: AccordionProps): JSX.Element;
|
|
15
13
|
export type { AccordionProps };
|
|
16
14
|
//# sourceMappingURL=Accordion.d.ts.map
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local VStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).VStack
|
|
4
4
|
local Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
5
|
-
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "rem")
|
|
5
|
+
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
6
6
|
local useMotion = TS.import(script, TS.getModule(script, "@rbxts", "pretty-react-hooks").out).useMotion
|
|
7
7
|
local _react = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
8
8
|
local React = _react
|
|
9
9
|
local useEffect = _react.useEffect
|
|
10
10
|
local useState = _react.useState
|
|
11
|
-
local ReactiveButton = TS.import(script, script.Parent, "ReactiveButton").ReactiveButton
|
|
12
|
-
local defaultTheme = TS.import(script, script
|
|
11
|
+
local ReactiveButton = TS.import(script, script.Parent.Parent, "buttons", "ReactiveButton").ReactiveButton
|
|
12
|
+
local defaultTheme = TS.import(script, TS.getModule(script, "@rbxts-ui", "theme").dist).defaultTheme
|
|
13
13
|
local DEFAULT_EXPANDED = true
|
|
14
14
|
local function Accordion(_param)
|
|
15
15
|
local title = _param.title
|
|
@@ -29,10 +29,7 @@ local function Accordion(_param)
|
|
|
29
29
|
end
|
|
30
30
|
local isExpanded = _param.isExpanded
|
|
31
31
|
local onExpandedChange = _param.onExpandedChange
|
|
32
|
-
local theme =
|
|
33
|
-
if theme == nil then
|
|
34
|
-
theme = defaultTheme
|
|
35
|
-
end
|
|
32
|
+
local theme = defaultTheme
|
|
36
33
|
local rem = useRem()
|
|
37
34
|
local contentHeight, setContentHeight = useState(0)
|
|
38
35
|
-- Header visual height must match the header button height below (rem(5))
|
|
@@ -63,7 +60,6 @@ local function Accordion(_param)
|
|
|
63
60
|
onClick = handleToggle,
|
|
64
61
|
backgroundTransparency = 1,
|
|
65
62
|
size = UDim2.new(1, 0, 0, rem(5)),
|
|
66
|
-
theme = theme,
|
|
67
63
|
}, React.createElement(Text, {
|
|
68
64
|
text = title,
|
|
69
65
|
textSize = textSize,
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
local TS = _G[script]
|
|
3
3
|
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
4
|
local Frame = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Frame
|
|
5
|
-
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "rem")
|
|
5
|
+
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
6
6
|
local DEFAULT_COLOR = Color3.fromRGB(255, 255, 255)
|
|
7
7
|
local function Divider(_param)
|
|
8
8
|
local orientation = _param.orientation
|
|
@@ -1,12 +1,10 @@
|
|
|
1
1
|
import React from "@rbxts/react";
|
|
2
|
-
import { type Theme } from "./theme";
|
|
3
2
|
interface SectionProps {
|
|
4
3
|
title: string;
|
|
5
4
|
children: React.ReactNode;
|
|
6
5
|
cornerRadius?: number;
|
|
7
6
|
sortOrder?: Enum.SortOrder;
|
|
8
|
-
theme?: Theme;
|
|
9
7
|
}
|
|
10
|
-
export declare function Section({ title, children, cornerRadius, sortOrder,
|
|
8
|
+
export declare function Section({ title, children, cornerRadius, sortOrder, }: SectionProps): JSX.Element;
|
|
11
9
|
export type { SectionProps };
|
|
12
10
|
//# sourceMappingURL=Section.d.ts.map
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
-- Compiled with roblox-ts v3.0.0
|
|
2
2
|
local TS = _G[script]
|
|
3
|
-
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
4
|
-
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "rem").dist).useRem
|
|
5
3
|
local VStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).VStack
|
|
6
4
|
local Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
7
|
-
local
|
|
5
|
+
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
6
|
+
local React = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
7
|
+
local defaultTheme = TS.import(script, TS.getModule(script, "@rbxts-ui", "theme").dist).defaultTheme
|
|
8
8
|
local function Section(_param)
|
|
9
9
|
local title = _param.title
|
|
10
10
|
local children = _param.children
|
|
@@ -16,10 +16,7 @@ local function Section(_param)
|
|
|
16
16
|
if sortOrder == nil then
|
|
17
17
|
sortOrder = Enum.SortOrder.Name
|
|
18
18
|
end
|
|
19
|
-
local theme =
|
|
20
|
-
if theme == nil then
|
|
21
|
-
theme = defaultTheme
|
|
22
|
-
end
|
|
19
|
+
local theme = defaultTheme
|
|
23
20
|
local rem = useRem()
|
|
24
21
|
local textSize = rem(3.5)
|
|
25
22
|
return React.createElement(VStack, {
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import React from "@rbxts/react";
|
|
2
|
-
import { type Theme } from "./theme";
|
|
3
2
|
export interface SegmentedToggleOption<T extends string> {
|
|
4
3
|
id: T;
|
|
5
4
|
label: string;
|
|
@@ -13,7 +12,6 @@ export interface SegmentedToggleProps<T extends string> {
|
|
|
13
12
|
size?: "default" | "small";
|
|
14
13
|
label?: string;
|
|
15
14
|
children?: React.ReactNode;
|
|
16
|
-
theme?: Theme;
|
|
17
15
|
}
|
|
18
|
-
export declare function SegmentedToggle<T extends string>({ options, value, onChange, disabled, size, label, children,
|
|
16
|
+
export declare function SegmentedToggle<T extends string>({ options, value, onChange, disabled, size, label, children, }: SegmentedToggleProps<T>): JSX.Element;
|
|
19
17
|
//# sourceMappingURL=SegmentedToggle.d.ts.map
|
|
@@ -1,14 +1,14 @@
|
|
|
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 useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "rem")
|
|
5
|
-
local Button = TS.import(script, script.Parent, "Button").Button
|
|
4
|
+
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
5
|
+
local Button = TS.import(script, script.Parent.Parent, "buttons", "Button").Button
|
|
6
6
|
local Frame = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Frame
|
|
7
7
|
local Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
8
8
|
local _layout = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist)
|
|
9
9
|
local HStack = _layout.HStack
|
|
10
10
|
local VStack = _layout.VStack
|
|
11
|
-
local defaultTheme = TS.import(script, script
|
|
11
|
+
local defaultTheme = TS.import(script, TS.getModule(script, "@rbxts-ui", "theme").dist).defaultTheme
|
|
12
12
|
local function SegmentedToggle(_param)
|
|
13
13
|
local options = _param.options
|
|
14
14
|
local value = _param.value
|
|
@@ -23,10 +23,7 @@ local function SegmentedToggle(_param)
|
|
|
23
23
|
end
|
|
24
24
|
local label = _param.label
|
|
25
25
|
local children = _param.children
|
|
26
|
-
local theme =
|
|
27
|
-
if theme == nil then
|
|
28
|
-
theme = defaultTheme
|
|
29
|
-
end
|
|
26
|
+
local theme = defaultTheme
|
|
30
27
|
local rem = useRem()
|
|
31
28
|
local count = #options
|
|
32
29
|
if count == 0 then
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import React from "@rbxts/react";
|
|
2
|
+
import ReactRoblox from "@rbxts/react-roblox";
|
|
3
|
+
declare const story: {
|
|
4
|
+
react: typeof React;
|
|
5
|
+
reactRoblox: typeof ReactRoblox;
|
|
6
|
+
controls: {};
|
|
7
|
+
story: () => JSX.Element;
|
|
8
|
+
};
|
|
9
|
+
export = story;
|
|
10
|
+
//# sourceMappingURL=SegmentedToggle.story.d.ts.map
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
-- Compiled with roblox-ts v3.0.0
|
|
2
|
+
local TS = _G[script]
|
|
3
|
+
local VStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).VStack
|
|
4
|
+
local Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
5
|
+
local _rem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem"))
|
|
6
|
+
local RemProvider = _rem.RemProvider
|
|
7
|
+
local useRem = _rem.useRem
|
|
8
|
+
local defaultTheme = TS.import(script, TS.getModule(script, "@rbxts-ui", "theme").dist).defaultTheme
|
|
9
|
+
local _react = TS.import(script, TS.getModule(script, "@rbxts", "react"))
|
|
10
|
+
local React = _react
|
|
11
|
+
local useState = _react.useState
|
|
12
|
+
local ReactRoblox = TS.import(script, TS.getModule(script, "@rbxts", "react-roblox"))
|
|
13
|
+
local SegmentedToggle = TS.import(script, script.Parent, "SegmentedToggle").SegmentedToggle
|
|
14
|
+
local controls = {}
|
|
15
|
+
local SegmentedToggleStory = function()
|
|
16
|
+
local rem = useRem()
|
|
17
|
+
local demoOptions = { {
|
|
18
|
+
id = "Folder",
|
|
19
|
+
label = "Folder",
|
|
20
|
+
}, {
|
|
21
|
+
id = "Model",
|
|
22
|
+
label = "Model",
|
|
23
|
+
}, {
|
|
24
|
+
id = "Asset",
|
|
25
|
+
label = "Asset",
|
|
26
|
+
} }
|
|
27
|
+
local selection, setSelection = useState(demoOptions[1].id)
|
|
28
|
+
return React.createElement(RemProvider, {
|
|
29
|
+
baseRem = 16,
|
|
30
|
+
maximumRem = 32,
|
|
31
|
+
}, React.createElement(VStack, {
|
|
32
|
+
size = UDim2.new(1, 0, 1, 0),
|
|
33
|
+
spacing = rem(2),
|
|
34
|
+
horizontalAlignment = Enum.HorizontalAlignment.Center,
|
|
35
|
+
verticalAlignment = Enum.VerticalAlignment.Center,
|
|
36
|
+
}, React.createElement(SegmentedToggle, {
|
|
37
|
+
label = "Output Type",
|
|
38
|
+
options = demoOptions,
|
|
39
|
+
value = selection,
|
|
40
|
+
onChange = setSelection,
|
|
41
|
+
}), React.createElement(Text, {
|
|
42
|
+
text = `Selected: {selection}`,
|
|
43
|
+
textSize = rem(3),
|
|
44
|
+
textScaled = true,
|
|
45
|
+
textColor = defaultTheme.palette.text,
|
|
46
|
+
size = UDim2.new(0, rem(50), 0, rem(4)),
|
|
47
|
+
textXAlignment = "Center",
|
|
48
|
+
}), React.createElement(SegmentedToggle, {
|
|
49
|
+
label = "Disabled Example",
|
|
50
|
+
options = { {
|
|
51
|
+
id = "DisabledFolder",
|
|
52
|
+
label = "Folder",
|
|
53
|
+
disabled = true,
|
|
54
|
+
}, {
|
|
55
|
+
id = "DisabledModel",
|
|
56
|
+
label = "Model",
|
|
57
|
+
} },
|
|
58
|
+
value = "DisabledModel",
|
|
59
|
+
onChange = function() end,
|
|
60
|
+
disabled = true,
|
|
61
|
+
size = "small",
|
|
62
|
+
})))
|
|
63
|
+
end
|
|
64
|
+
local story = {
|
|
65
|
+
react = React,
|
|
66
|
+
reactRoblox = ReactRoblox,
|
|
67
|
+
controls = controls,
|
|
68
|
+
story = function()
|
|
69
|
+
return React.createElement(SegmentedToggleStory)
|
|
70
|
+
end,
|
|
71
|
+
}
|
|
72
|
+
return story
|
|
@@ -0,0 +1,46 @@
|
|
|
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 Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
5
|
+
local Table = TS.import(script, script.Parent, "Table").Table
|
|
6
|
+
local TableCell = TS.import(script, script.Parent, "TableCell").TableCell
|
|
7
|
+
local TableHeader = TS.import(script, script.Parent, "TableHeader").TableHeader
|
|
8
|
+
local TableRow = TS.import(script, script.Parent, "TableRow").TableRow
|
|
9
|
+
local function ExampleTable()
|
|
10
|
+
return React.createElement(Table, {
|
|
11
|
+
size = UDim2.new(0.8, 0, 0, 200),
|
|
12
|
+
backgroundTransparency = 1,
|
|
13
|
+
position = UDim2.new(0.1, 0, 0.1, 0),
|
|
14
|
+
}, React.createElement(TableHeader, {
|
|
15
|
+
size = UDim2.new(1, 0, 0, 30),
|
|
16
|
+
}, React.createElement(TableCell, {
|
|
17
|
+
size = UDim2.new(0.2, 0, 1, 0),
|
|
18
|
+
}, React.createElement(Text, {
|
|
19
|
+
text = "ID",
|
|
20
|
+
})), React.createElement(TableCell, {
|
|
21
|
+
size = UDim2.new(0.4, 0, 1, 0),
|
|
22
|
+
}, React.createElement(Text, {
|
|
23
|
+
text = "Name",
|
|
24
|
+
})), React.createElement(TableCell, {
|
|
25
|
+
size = UDim2.new(0.4, 0, 1, 0),
|
|
26
|
+
}, React.createElement(Text, {
|
|
27
|
+
text = "Score",
|
|
28
|
+
}))), React.createElement(TableRow, {
|
|
29
|
+
size = UDim2.new(1, 0, 0, 30),
|
|
30
|
+
}, React.createElement(TableCell, {
|
|
31
|
+
size = UDim2.new(0.2, 0, 1, 0),
|
|
32
|
+
}, React.createElement(Text, {
|
|
33
|
+
text = "1",
|
|
34
|
+
})), React.createElement(TableCell, {
|
|
35
|
+
size = UDim2.new(0.4, 0, 1, 0),
|
|
36
|
+
}, React.createElement(Text, {
|
|
37
|
+
text = "Alice",
|
|
38
|
+
})), React.createElement(TableCell, {
|
|
39
|
+
size = UDim2.new(0.4, 0, 1, 0),
|
|
40
|
+
}, React.createElement(Text, {
|
|
41
|
+
text = "95",
|
|
42
|
+
}))))
|
|
43
|
+
end
|
|
44
|
+
return {
|
|
45
|
+
ExampleTable = ExampleTable,
|
|
46
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { PropsWithChildren } from "@rbxts/react";
|
|
2
|
+
interface TableProps extends PropsWithChildren {
|
|
3
|
+
readonly size: UDim2;
|
|
4
|
+
readonly position?: UDim2;
|
|
5
|
+
readonly layoutOrder?: number;
|
|
6
|
+
readonly backgroundTransparency?: number;
|
|
7
|
+
}
|
|
8
|
+
export declare function Table({ children, size, position, layoutOrder, backgroundTransparency }: TableProps): JSX.Element;
|
|
9
|
+
export type { TableProps };
|
|
10
|
+
//# sourceMappingURL=Table.d.ts.map
|
|
@@ -0,0 +1,26 @@
|
|
|
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 VStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).VStack
|
|
5
|
+
local function Table(_param)
|
|
6
|
+
local children = _param.children
|
|
7
|
+
local size = _param.size
|
|
8
|
+
local position = _param.position
|
|
9
|
+
local layoutOrder = _param.layoutOrder
|
|
10
|
+
if layoutOrder == nil then
|
|
11
|
+
layoutOrder = 0
|
|
12
|
+
end
|
|
13
|
+
local backgroundTransparency = _param.backgroundTransparency
|
|
14
|
+
if backgroundTransparency == nil then
|
|
15
|
+
backgroundTransparency = 1
|
|
16
|
+
end
|
|
17
|
+
return React.createElement(VStack, {
|
|
18
|
+
size = size,
|
|
19
|
+
position = position,
|
|
20
|
+
layoutOrder = layoutOrder,
|
|
21
|
+
backgroundTransparency = backgroundTransparency,
|
|
22
|
+
}, children)
|
|
23
|
+
end
|
|
24
|
+
return {
|
|
25
|
+
Table = Table,
|
|
26
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PropsWithChildren } from "@rbxts/react";
|
|
2
|
+
interface TableCellProps extends PropsWithChildren {
|
|
3
|
+
readonly size: UDim2;
|
|
4
|
+
readonly layoutOrder?: number;
|
|
5
|
+
readonly backgroundTransparency?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function TableCell({ children, size, layoutOrder, backgroundTransparency }: TableCellProps): JSX.Element;
|
|
8
|
+
export type { TableCellProps };
|
|
9
|
+
//# sourceMappingURL=TableCell.d.ts.map
|
|
@@ -0,0 +1,26 @@
|
|
|
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 Frame = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Frame
|
|
5
|
+
local useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
6
|
+
local function TableCell(_param)
|
|
7
|
+
local children = _param.children
|
|
8
|
+
local size = _param.size
|
|
9
|
+
local layoutOrder = _param.layoutOrder
|
|
10
|
+
if layoutOrder == nil then
|
|
11
|
+
layoutOrder = 0
|
|
12
|
+
end
|
|
13
|
+
local backgroundTransparency = _param.backgroundTransparency
|
|
14
|
+
if backgroundTransparency == nil then
|
|
15
|
+
backgroundTransparency = 1
|
|
16
|
+
end
|
|
17
|
+
local rem = useRem()
|
|
18
|
+
return React.createElement(Frame, {
|
|
19
|
+
size = size,
|
|
20
|
+
layoutOrder = layoutOrder,
|
|
21
|
+
backgroundTransparency = backgroundTransparency,
|
|
22
|
+
}, children)
|
|
23
|
+
end
|
|
24
|
+
return {
|
|
25
|
+
TableCell = TableCell,
|
|
26
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type HStackProps as StackProps } from "@rbxts-ui/layout";
|
|
2
|
+
interface TableFooterProps extends StackProps {
|
|
3
|
+
readonly size: UDim2;
|
|
4
|
+
readonly layoutOrder?: number;
|
|
5
|
+
readonly backgroundTransparency?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function TableFooter(props: TableFooterProps): JSX.Element;
|
|
8
|
+
export type { TableFooterProps };
|
|
9
|
+
//# sourceMappingURL=TableFooter.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
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 HStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).HStack
|
|
5
|
+
local function TableFooter(props)
|
|
6
|
+
local _attributes = table.clone(props)
|
|
7
|
+
setmetatable(_attributes, nil)
|
|
8
|
+
return React.createElement(HStack, _attributes, props.children)
|
|
9
|
+
end
|
|
10
|
+
return {
|
|
11
|
+
TableFooter = TableFooter,
|
|
12
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type HStackProps as StackProps } from "@rbxts-ui/layout";
|
|
2
|
+
interface TableHeaderProps extends StackProps {
|
|
3
|
+
readonly size: UDim2;
|
|
4
|
+
readonly layoutOrder?: number;
|
|
5
|
+
readonly backgroundTransparency?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function TableHeader(props: TableHeaderProps): JSX.Element;
|
|
8
|
+
export type { TableHeaderProps };
|
|
9
|
+
//# sourceMappingURL=TableHeader.d.ts.map
|
|
@@ -0,0 +1,12 @@
|
|
|
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 HStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).HStack
|
|
5
|
+
local function TableHeader(props)
|
|
6
|
+
local _attributes = table.clone(props)
|
|
7
|
+
setmetatable(_attributes, nil)
|
|
8
|
+
return React.createElement(HStack, _attributes, props.children)
|
|
9
|
+
end
|
|
10
|
+
return {
|
|
11
|
+
TableHeader = TableHeader,
|
|
12
|
+
}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { PropsWithChildren } from "@rbxts/react";
|
|
2
|
+
interface TableRowProps extends PropsWithChildren {
|
|
3
|
+
readonly size: UDim2;
|
|
4
|
+
readonly layoutOrder?: number;
|
|
5
|
+
readonly backgroundTransparency?: number;
|
|
6
|
+
}
|
|
7
|
+
export declare function TableRow({ children, size, layoutOrder, backgroundTransparency }: TableRowProps): JSX.Element;
|
|
8
|
+
export type { TableRowProps };
|
|
9
|
+
//# sourceMappingURL=TableRow.d.ts.map
|
|
@@ -0,0 +1,24 @@
|
|
|
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 HStack = TS.import(script, TS.getModule(script, "@rbxts-ui", "layout").dist).HStack
|
|
5
|
+
local function TableRow(_param)
|
|
6
|
+
local children = _param.children
|
|
7
|
+
local size = _param.size
|
|
8
|
+
local layoutOrder = _param.layoutOrder
|
|
9
|
+
if layoutOrder == nil then
|
|
10
|
+
layoutOrder = 0
|
|
11
|
+
end
|
|
12
|
+
local backgroundTransparency = _param.backgroundTransparency
|
|
13
|
+
if backgroundTransparency == nil then
|
|
14
|
+
backgroundTransparency = 1
|
|
15
|
+
end
|
|
16
|
+
return React.createElement(HStack, {
|
|
17
|
+
size = size,
|
|
18
|
+
layoutOrder = layoutOrder,
|
|
19
|
+
backgroundTransparency = backgroundTransparency,
|
|
20
|
+
}, children)
|
|
21
|
+
end
|
|
22
|
+
return {
|
|
23
|
+
TableRow = TableRow,
|
|
24
|
+
}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
interface TooltipProps {
|
|
2
|
+
text: string;
|
|
3
|
+
visible: boolean;
|
|
4
|
+
position?: UDim2;
|
|
5
|
+
offsetX?: number;
|
|
6
|
+
offsetY?: number;
|
|
7
|
+
backgroundColor?: Color3;
|
|
8
|
+
textColor?: Color3;
|
|
9
|
+
maxWidth?: number;
|
|
10
|
+
anchorPoint?: Vector2;
|
|
11
|
+
}
|
|
12
|
+
export declare function Tooltip({ text, visible, position, backgroundColor, textColor, anchorPoint, maxWidth, offsetX, offsetY, }: TooltipProps): JSX.Element | undefined;
|
|
13
|
+
export type { TooltipProps };
|
|
14
|
+
//# sourceMappingURL=Tooltip.d.ts.map
|
|
@@ -0,0 +1,65 @@
|
|
|
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 useRem = TS.import(script, TS.getModule(script, "@rbxts-ui", "@rbxts-ui/rem")).useRem
|
|
5
|
+
local Padding = TS.import(script, script.Parent.Parent, "layout", "Padding").Padding
|
|
6
|
+
local Text = TS.import(script, TS.getModule(script, "@rbxts-ui", "primitives").dist).Text
|
|
7
|
+
local defaultTheme = TS.import(script, TS.getModule(script, "@rbxts-ui", "theme").dist).defaultTheme
|
|
8
|
+
local function Tooltip(_param)
|
|
9
|
+
local text = _param.text
|
|
10
|
+
local visible = _param.visible
|
|
11
|
+
local position = _param.position
|
|
12
|
+
local backgroundColor = _param.backgroundColor
|
|
13
|
+
if backgroundColor == nil then
|
|
14
|
+
backgroundColor = defaultTheme.palette.black
|
|
15
|
+
end
|
|
16
|
+
local textColor = _param.textColor
|
|
17
|
+
if textColor == nil then
|
|
18
|
+
textColor = defaultTheme.palette.white
|
|
19
|
+
end
|
|
20
|
+
local anchorPoint = _param.anchorPoint
|
|
21
|
+
if anchorPoint == nil then
|
|
22
|
+
anchorPoint = Vector2.new(0.5, 0.5)
|
|
23
|
+
end
|
|
24
|
+
local maxWidth = _param.maxWidth
|
|
25
|
+
if maxWidth == nil then
|
|
26
|
+
maxWidth = 200
|
|
27
|
+
end
|
|
28
|
+
local offsetX = _param.offsetX
|
|
29
|
+
if offsetX == nil then
|
|
30
|
+
offsetX = 0
|
|
31
|
+
end
|
|
32
|
+
local offsetY = _param.offsetY
|
|
33
|
+
if offsetY == nil then
|
|
34
|
+
offsetY = 0
|
|
35
|
+
end
|
|
36
|
+
local rem = useRem()
|
|
37
|
+
local theme = defaultTheme
|
|
38
|
+
if not visible or not position then
|
|
39
|
+
return nil
|
|
40
|
+
end
|
|
41
|
+
local cornerRadius = UDim.new(0, rem(2))
|
|
42
|
+
return React.createElement(Text, {
|
|
43
|
+
backgroundColor = backgroundColor,
|
|
44
|
+
backgroundTransparency = 0.2,
|
|
45
|
+
text = text,
|
|
46
|
+
textSize = rem(2),
|
|
47
|
+
lineHeight = 1.5,
|
|
48
|
+
textColor = textColor,
|
|
49
|
+
font = theme.fonts.inter.medium,
|
|
50
|
+
position = UDim2.new(0, position.X.Offset + offsetX, 0, position.Y.Offset + offsetY),
|
|
51
|
+
size = UDim2.new(0, rem(maxWidth), 0, 0),
|
|
52
|
+
textYAlignment = "Center",
|
|
53
|
+
textXAlignment = "Left",
|
|
54
|
+
automaticSize = Enum.AutomaticSize.Y,
|
|
55
|
+
textWrapped = true,
|
|
56
|
+
cornerRadius = cornerRadius,
|
|
57
|
+
anchorPoint = anchorPoint,
|
|
58
|
+
}, React.createElement(Padding, {
|
|
59
|
+
paddingX = rem(2),
|
|
60
|
+
paddingY = rem(1.5),
|
|
61
|
+
}))
|
|
62
|
+
end
|
|
63
|
+
return {
|
|
64
|
+
Tooltip = Tooltip,
|
|
65
|
+
}
|