Skip to content

Commit

Permalink
Fix theme usage
Browse files Browse the repository at this point in the history
  • Loading branch information
boatbomber committed Dec 22, 2024
1 parent 03fa1b3 commit a330c12
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 19 deletions.
8 changes: 4 additions & 4 deletions plugin/src/App/ConflictAPIPopup.lua
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ local ConflictAPIPopup = Roact.Component:extend("ConflictAPIPopup")

function ConflictAPIPopup:render()
return Theme.with(function(theme)
theme = theme.Settings
local settingTheme = theme.Settings

return e("Frame", {
BackgroundTransparency = 1,
Expand Down Expand Up @@ -47,7 +47,7 @@ function ConflictAPIPopup:render()
Text = "There is already a Rojo API exposed by a Rojo plugin. Do you want to overwrite it with this one?",
FontFace = theme.Font.Main,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextWrapped = true,
TextTransparency = self.props.transparency,
Expand All @@ -65,7 +65,7 @@ function ConflictAPIPopup:render()
),
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Body,
TextColor3 = theme.Setting.DescriptionColor,
TextColor3 = settingTheme.Setting.DescriptionColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
LayoutOrder = 2,
Expand All @@ -82,7 +82,7 @@ function ConflictAPIPopup:render()
),
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Body,
TextColor3 = theme.Setting.DescriptionColor,
TextColor3 = settingTheme.Setting.DescriptionColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
LayoutOrder = 3,
Expand Down
20 changes: 10 additions & 10 deletions plugin/src/App/PermissionPopup.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ end

function PermissionPopup:render()
return Theme.with(function(theme)
theme = theme.Settings
local settingsTheme = theme.Settings

local thumbnail = Assets.Images.ThirdPartyPlugin
local thumbnailId = string.match(self.props.source, "cloud_(%d+)")
Expand All @@ -46,7 +46,7 @@ function PermissionPopup:render()
AutomaticSize = Enum.AutomaticSize.Y,
}, {
Divider = e("Frame", {
BackgroundColor3 = theme.DividerColor,
BackgroundColor3 = settingsTheme.DividerColor,
BackgroundTransparency = self.props.transparency,
Size = UDim2.new(1, 0, 0, 1),
Position = UDim2.new(0, 0, 0, -2),
Expand All @@ -70,7 +70,7 @@ function PermissionPopup:render()
Text = api,
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingsTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
}),
Expand All @@ -83,7 +83,7 @@ function PermissionPopup:render()
Text = apiDesc.Description,
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Body,
TextColor3 = theme.Setting.DescriptionColor,
TextColor3 = settingsTheme.Setting.DescriptionColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
}),
Expand All @@ -101,7 +101,7 @@ function PermissionPopup:render()
AutomaticSize = Enum.AutomaticSize.Y,
FontFace = theme.Font.Main,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingsTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
}, e("UIPadding", { PaddingBottom = UDim.new(0, 8) }))
Expand All @@ -116,7 +116,7 @@ function PermissionPopup:render()
AutomaticSize = Enum.AutomaticSize.Y,
FontFace = theme.Font.Main,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingsTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
}, e("UIPadding", { PaddingBottom = UDim.new(0, 8) }))
Expand All @@ -131,7 +131,7 @@ function PermissionPopup:render()
AutomaticSize = Enum.AutomaticSize.Y,
FontFace = theme.Font.Main,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingsTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Left,
TextTransparency = self.props.transparency,
}, e("UIPadding", { PaddingBottom = UDim.new(0, 8) }))
Expand Down Expand Up @@ -179,7 +179,7 @@ function PermissionPopup:render()
BackgroundTransparency = 1,
Size = UDim2.new(0, 24, 0, 24),
Image = Assets.Images.Icons.Transact,
ImageColor3 = theme.Setting.DescriptionColor,
ImageColor3 = settingsTheme.Setting.DescriptionColor,
LayoutOrder = 2,
}),

Expand All @@ -198,7 +198,7 @@ function PermissionPopup:render()
Text = string.format("%s is asking to use the Rojo API", self.props.name or "[Unknown]"),
FontFace = theme.Font.Bold,
TextSize = theme.TextSize.Medium,
TextColor3 = theme.Setting.NameColor,
TextColor3 = settingsTheme.Setting.NameColor,
TextXAlignment = Enum.TextXAlignment.Center,
TextWrapped = true,
TextTransparency = self.props.transparency,
Expand All @@ -211,7 +211,7 @@ function PermissionPopup:render()

Divider = e("Frame", {
LayoutOrder = 3,
BackgroundColor3 = theme.DividerColor,
BackgroundColor3 = settingsTheme.DividerColor,
BackgroundTransparency = self.props.transparency,
Size = UDim2.new(1, 0, 0, 1),
Position = UDim2.new(0, 0, 0, -2),
Expand Down
10 changes: 5 additions & 5 deletions plugin/src/App/StatusPages/Permissions/init.lua
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ local e = Roact.createElement

local function Navbar(props)
return Theme.with(function(theme)
theme = theme.Settings.Navbar
local navbarTheme = theme.Settings.Navbar

return e("Frame", {
Size = UDim2.new(1, 0, 0, 46),
Expand All @@ -31,7 +31,7 @@ local function Navbar(props)
Back = e(IconButton, {
icon = Assets.Images.Icons.Back,
iconSize = 24,
color = theme.BackButtonColor,
color = navbarTheme.BackButtonColor,
transparency = props.transparency,

position = UDim2.new(0, 0, 0.5, 0),
Expand All @@ -48,7 +48,7 @@ local function Navbar(props)
Text = "Permissions",
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Large,
TextColor3 = theme.TextColor,
TextColor3 = navbarTheme.TextColor,
TextTransparency = props.transparency,

Size = UDim2.new(1, 0, 1, 0),
Expand Down Expand Up @@ -81,7 +81,7 @@ end

function PermissionsPage:render()
return Theme.with(function(theme)
theme = theme.Settings
local settingsTheme = theme.Settings

local sources = {}
for source, permissions in self.state.permissions do
Expand Down Expand Up @@ -117,7 +117,7 @@ function PermissionsPage:render()
Text = "No third-party plugins have been granted permissions.",
FontFace = theme.Font.Thin,
TextSize = theme.TextSize.Large,
TextColor3 = theme.Setting.DescriptionColor,
TextColor3 = settingsTheme.Setting.DescriptionColor,
TextTransparency = self.props.transparency,
TextWrapped = true,

Expand Down

0 comments on commit a330c12

Please sign in to comment.