local g="\078\101\120\117\115\083\116\117\100\105\111\084\104\101\109\101"local A=(require(script.Parent.Parent:WaitForChild("\078\101\120\117\115\080\108\117\103\105\110\070\114\097\109\101\119\111\114\107\080\114\111\106\101\099\116"))):GetContext(script)local I=A:GetResource("\066\097\115\101\046\078\101\120\117\115\067\111\110\116\097\105\110\101\114")local O=A:GetResource("\068\097\116\097\046\084\104\101\109\101\067\111\108\111\114\115")local Y=I:Extend()Y:SetClassName(g)A:SetContextResource(Y)local z function Y.FromThemeEnum()if not z then z=Y.new()end return z end function Y.__new(g)g:InitializeSuper()g.Name="\070\097\108\108\098\097\099\107"end function Y.GetColor(I,g,A)if typeof(g)=="\069\110\117\109\073\116\101\109"then g=string.sub(tostring(g),28)end if not A then A=Enum.StudioStyleGuideModifier.Default elseif type(A)=="\115\116\114\105\110\103"then A=Enum.StudioStyleGuideModifier[A]end return O[g][A]end function Y.GetPath(I,g,A)warn("\085\110\105\109\112\108\101\109\101\110\116\101\100\058 \078\101\120\117\115\083\116\117\100\105\111\084\104\101\109\101\058\071\101\116\080\097\116\104\040\065\115\115\101\116\073\100\044\077\111\100\105\102\105\101\114\041")return"\085\110\105\109\112\108\101\109\101\110\116\101\100"end return Y
--[[
TheNexusAvenger

Mirrors the API of Roblox's StudioTheme class.
--]]

local CLASS_NAME = "NexusStudioTheme"



local NexusPluginFramework = require(script.Parent.Parent:WaitForChild("NexusPluginFrameworkProject")):GetContext(script)
local NexusContainer = NexusPluginFramework:GetResource("Base.NexusContainer")
local ThemeColors = NexusPluginFramework:GetResource("Data.ThemeColors")

local NexusStudioTheme = NexusContainer:Extend()
NexusStudioTheme:SetClassName(CLASS_NAME)
NexusPluginFramework:SetContextResource(NexusStudioTheme)

local CachedTheme



--[[
Creates a theme class from an enum.
--]]
function NexusStudioTheme.FromThemeEnum()
	--Create the cached theme.
	if not CachedTheme then
		CachedTheme = NexusStudioTheme.new()
	end
	
	--Return the cached theme.
	return CachedTheme
end

--[[
Creates a Studio Theme object.
--]]
function NexusStudioTheme:__new()
	self:InitializeSuper()
	
	--Store the theme and set the name.
	self.Name = "Fallback"
end

--[[
Returns the color corresponding to the arguments provided.
--]]
function NexusStudioTheme:GetColor(StyleGuideColor,Modifier)
	--Correct the input.
	if typeof(StyleGuideColor) == "EnumItem" then
		StyleGuideColor = string.sub(tostring(StyleGuideColor),28)
	end
	
	if not Modifier then
		Modifier = Enum.StudioStyleGuideModifier.Default
	elseif type(Modifier) == "string" then
		Modifier = Enum.StudioStyleGuideModifier[Modifier]
	end
	
	--Return the color.
	return ThemeColors[StyleGuideColor][Modifier]
end

--[[
Returns the path of an asset (or image) for the Id and Modifier.
--]]
function NexusStudioTheme:GetPath(AssetId,Modifier)
	warn("Unimplemented: NexusStudioTheme:GetPath(AssetId,Modifier)")
	return "Unimplemented"
end



return NexusStudioTheme