Better light theme support

This commit is contained in:
boatbomber 2023-01-05 11:07:03 -05:00
parent 3b1aca2958
commit e24657ca4d

View file

@ -37,8 +37,6 @@ end
function Listing:render() function Listing:render()
return Theme.with(function(theme) return Theme.with(function(theme)
theme = theme.Settings
return e("Frame", { return e("Frame", {
Size = self.contentSize:map(function(value) Size = self.contentSize:map(function(value)
return UDim2.new(1, 0, 0, 20 + value.Y + 20) return UDim2.new(1, 0, 0, 20 + value.Y + 20)
@ -62,17 +60,15 @@ function Listing:render()
self.props.onClick() self.props.onClick()
end, end,
}, { }, {
Button = Theme.with(function(theme) Button = e(SlicedImage, {
theme = theme.Checkbox
return e(SlicedImage, {
slice = Assets.Slices.RoundedBorder, slice = Assets.Slices.RoundedBorder,
color = theme.Inactive.BorderColor, color = theme.Checkbox.Inactive.BorderColor,
transparency = self.props.transparency, transparency = self.props.transparency,
size = UDim2.new(1, 0, 1, 0), size = UDim2.new(1, 0, 1, 0),
}, { }, {
Icon = e("ImageLabel", { Icon = e("ImageLabel", {
Image = Assets.Images.Icons.Settings, Image = Assets.Images.Icons.Settings,
ImageColor3 = theme.Active.IconColor, ImageColor3 = theme.Notification.InfoColor,
ImageTransparency = self.props.transparency, ImageTransparency = self.props.transparency,
Size = UDim2.new(0, 16, 0, 16), Size = UDim2.new(0, 16, 0, 16),
@ -81,8 +77,7 @@ function Listing:render()
BackgroundTransparency = 1, BackgroundTransparency = 1,
}), }),
}) }),
end),
}), }),
Text = e("Frame", { Text = e("Frame", {
@ -93,7 +88,7 @@ function Listing:render()
Text = self.props.name, Text = self.props.name,
Font = Enum.Font.GothamBold, Font = Enum.Font.GothamBold,
TextSize = 17, TextSize = 17,
TextColor3 = theme.Setting.NameColor, TextColor3 = theme.Settings.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left, TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency, TextTransparency = self.props.transparency,
@ -108,7 +103,7 @@ function Listing:render()
Font = Enum.Font.Gotham, Font = Enum.Font.Gotham,
LineHeight = 1.2, LineHeight = 1.2,
TextSize = 14, TextSize = 14,
TextColor3 = theme.Setting.DescriptionColor, TextColor3 = theme.Settings.Setting.DescriptionColor,
TextXAlignment = Enum.TextXAlignment.Left, TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency, TextTransparency = self.props.transparency,
TextWrapped = true, TextWrapped = true,
@ -143,7 +138,7 @@ function Listing:render()
}), }),
Divider = e("Frame", { Divider = e("Frame", {
BackgroundColor3 = theme.DividerColor, BackgroundColor3 = theme.Settings.DividerColor,
BackgroundTransparency = self.props.transparency, BackgroundTransparency = self.props.transparency,
Size = UDim2.new(1, 0, 0, 1), Size = UDim2.new(1, 0, 0, 1),
BorderSizePixel = 0, BorderSizePixel = 0,