Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add markdown element #239

Merged

Conversation

maximehuran
Copy link
Member

@maximehuran maximehuran commented Sep 5, 2024

Add markdown UI Element

This version will require twig/extra-bundle which will generate an error with Sylius Standard setup :

    Twig\Extra\Intl\IntlExtension: ~

The recipe will run a script which comment this line :

https://github.com/monsieurbiz/symfony-recipes/blob/master/monsieurbiz/sylius-rich-editor-plugin/2.9/manifest.json#L10

See Sylius/Sylius-Standard#1021 for more information

The Ui Element

image

image

Add highlight JS in shop

image

You can enable or disable and change highlight JS theme :

MONSIEURBIZ_SYLIUS_RICH_EDITOR_ENABLED_HIGHLIGHT_JS_SHOP=true
MONSIEURBIZ_SYLIUS_RICH_EDITOR_ENABLED_HIGHLIGHT_JS_THEME=atom-one-dark

No higlight in admin for now.
We have to manage the load after the AJAX call to render elements.

Custom theme

The default theme is loaded in local.
Another themes are loaded via CDN.

Example with atom-one-dark

image

@maximehuran maximehuran force-pushed the feature/add-markdown-element branch from 84c386f to f887e11 Compare September 5, 2024 15:19
@maximehuran maximehuran force-pushed the feature/add-markdown-element branch from c52fea8 to 95a58db Compare September 5, 2024 16:08
@madamebiz madamebiz added the Status: needs review Status: needs review label Sep 5, 2024
assets/js/highlight.js Outdated Show resolved Hide resolved
src/Resources/views/Shop/UiElement/markdown.html.twig Outdated Show resolved Hide resolved
@madamebiz madamebiz added Status: needs update This Issue/PR needs update and removed Status: needs review Status: needs review labels Sep 5, 2024
@madamebiz madamebiz added Status: needs review Status: needs review and removed Status: needs update This Issue/PR needs update labels Sep 5, 2024
README.md Outdated Show resolved Hide resolved
scripts/replace_intl_extension.php Outdated Show resolved Hide resolved
src/Resources/views/Shop/app.html.twig Show resolved Hide resolved
@maximehuran maximehuran merged commit ebb67aa into monsieurbiz:master Sep 6, 2024
10 checks passed
@maximehuran maximehuran deleted the feature/add-markdown-element branch September 6, 2024 08:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Status: needs review Status: needs review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants