Merge pull request #5024 from sbwalker/dev

add ThemeState property to ThemeBase
This commit is contained in:
Shaun Walker 2025-01-28 08:27:25 -05:00 committed by GitHub
commit 3de44c0335
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -84,6 +84,16 @@ namespace Oqtane.Themes
}
}
// property for obtaining theme information about this theme component
public Theme ThemeState
{
get
{
var type = GetType().Namespace + ", " + GetType().Assembly.GetName().Name;
return PageState?.Site.Themes.FirstOrDefault(item => item.ThemeName == type);
}
}
// path method
public string ThemePath()