REDROOM
PHP 8.2.31
Path:
Logout
Edit File
Size: 1.60 KB
Close
/home/nshryvcy/radiantskinclinics.org/wp-content/plugins/extendify_old/src/Launch/lib/preview-helpers.js
Text
Base64
const FONT_VAR_PREFIX = '--wp--preset--font-family'; const HEADING_FONT_VAR_KEY = '--wp--preset--font-family--heading'; const BODY_FONT_VAR_KEY = '--wp--preset--font-family--body'; // Generates font links and styles from custom variations to override fonts in `theme-processed.json` export const getFontOverrides = (variation) => { let customFontLinks = ''; let fontOverrides = ''; if (!variation?.title) { return { customFontLinks, fontOverrides }; } // These values look like `var(--wp--preset--font-family--${fontFamilySlug})` const headingFontVarValue = variation.styles?.elements?.heading?.typography?.fontFamily; const bodyFontVarValue = variation.styles?.typography?.fontFamily; const customFonts = variation.settings?.typography?.fontFamilies?.custom ?? []; if (headingFontVarValue) { fontOverrides += `:root { ${HEADING_FONT_VAR_KEY}: ${headingFontVarValue}; }`; fontOverrides += `h1, h2, h3, h4, h5, h6 { font-family: ${headingFontVarValue} !important; }`; } if (bodyFontVarValue) { fontOverrides += `:root { ${BODY_FONT_VAR_KEY}: ${bodyFontVarValue}; }`; fontOverrides += `body { font-family: ${bodyFontVarValue} !important; }`; } for (const font of customFonts) { const customFontLink = `<link id="ext-custom-font-${font.slug}" rel="stylesheet" href="${font.css}">`; if (!customFontLinks.includes(customFontLink)) { customFontLinks += customFontLink; } const fontOverride = `:root { ${FONT_VAR_PREFIX}--${font.slug}: "${font.fontFamily}"; }`; if (!fontOverrides.includes(fontOverride)) { fontOverrides += fontOverride; } } return { customFontLinks, fontOverrides }; };
Save
Close
Exit & Reset
Text mode: syntax highlighting auto-detects file type.
Directory Contents
Dirs: 1 × Files: 8
Delete Selected
Select All
Select None
Sort:
Name
Size
Modified
Enable drag-to-move
Name
Size
Perms
Modified
Actions
__tests__
DIR
-
drwxr-xr-x
2026-04-28 02:40:02
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
blocks.js
154 B
lrw-r--r--
2025-08-27 17:47:28
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
fonts-helpers.js
1.91 KB
lrw-r--r--
2025-08-04 19:41:52
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
linkPages.js
6.71 KB
lrw-r--r--
2026-03-19 23:35:18
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
logo.js
1.30 KB
lrw-r--r--
2026-02-19 03:27:14
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
pages.js
2.23 KB
lrw-r--r--
2025-07-16 19:39:24
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
preview-helpers.js
1.60 KB
lrw-r--r--
2025-02-04 00:18:34
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
util.js
1.92 KB
lrw-r--r--
2026-02-19 03:27:14
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
wp.js
12.71 KB
lrw-r--r--
2026-02-27 04:48:52
Edit
Download
Rename
Chmod
Change Date
Delete
OK
Cancel
recursive
OK
Cancel
recursive
OK
Cancel
Zip Selected
If ZipArchive is unavailable, a
.tar
will be created (no compression).