Skip to content

Commit

Permalink
feat: add paragon theme condition
Browse files Browse the repository at this point in the history
If the PARAGON_THEME_URLS has been set the primary colors wont' be set on runtime
  • Loading branch information
andrey-canon committed Jan 18, 2024
1 parent fea0345 commit 8a3c344
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/initialize.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,9 +204,10 @@ export function loadExternalScripts(externalScripts, data) {
*/
export function setCustomPrimaryColors() {
const { CUSTOM_PRIMARY_COLORS } = getConfig();
const { PARAGON_THEME_URLS } = getConfig();
const primary = CUSTOM_PRIMARY_COLORS['pgn-color-primary-base'];

if (!primary) {
if (!primary || PARAGON_THEME_URLS != null) {
return;
}
document.documentElement.style.setProperty('--pgn-color-primary-base', primary);
Expand Down

0 comments on commit 8a3c344

Please sign in to comment.