diff --git a/docs/components/grapesjs.rst b/docs/components/grapesjs.rst new file mode 100644 index 00000000..48254953 --- /dev/null +++ b/docs/components/grapesjs.rst @@ -0,0 +1,74 @@ +GrapesJS Builder +################ + +Currently, Mautic uses the GrapesJS Builder for Emails and Landing pages. + +Setup +***** + +.. code-block:: BASH + + npm install + +.. vale off + +Configure Babel, ESLint, Prettier +================================= + +.. vale on + +Use the template files provided. For example .eslintrc.temp + +How to test standalone +********************** + +.. code-block:: BASH + + npm run start-helloWorld + or + npm run start-mautic + +In order for ``start-mautic`` to work, a running DDEV container has to be present. + +If you are using another development environment you need to update some paths in ``Demo/mautic/index.html``. + +How to build for production +*************************** + +.. code-block:: BASH + + npm run build + +Code architecture +***************** + +There is PHP and the JavaScript code. + +All the JavaScript code lives in the Assets/library folder. This handles the UI of the builder. + +In addition to the code in this repository, there is also the :xref:`GrapesJS Preset`. + +This repository handles the basic Mautic specific code. The general idea is that this preset repository is a base for various Mautic builder Plugins. + +E.g one where the Rich Text Editor is CKEditor, or where there is some very customer or industry specific features. + +``` +- It's a pack of configurable feautures: +- Adds the function to edit source code +- Extends the original image and add a confirm dialog before removing it +- Add the option to hide/show the Layers Manager +- Add the option to enable/disable the import code button +- Moves the Settings panel inside Style Manager panel +- Opens the Block Manager at launch +- Add Dynamic Content Block for HTML used in Mautic +``` + +Issues +****** + +Report issues in the main Mautic repository, labelled as :xref:`GrapesJS issue queue` + +PRs +*** + +Contributions to improve the GrapesJS Plugin happen in the main Mautic repository as :xref:`GitHub PRs` \ No newline at end of file diff --git a/docs/links/github_mautic_prs.py b/docs/links/github_mautic_prs.py new file mode 100644 index 00000000..3347f122 --- /dev/null +++ b/docs/links/github_mautic_prs.py @@ -0,0 +1,7 @@ +from . import link + +link_name = "GitHub PRs" +link_text = "GitHub PRs" +link_url = "https://github.com/mautic/mautic/pulls" + +link.xref_links.update({link_name: (link_text, link_url)}) diff --git a/docs/links/grapesjs_issues.py b/docs/links/grapesjs_issues.py new file mode 100644 index 00000000..443403d7 --- /dev/null +++ b/docs/links/grapesjs_issues.py @@ -0,0 +1,7 @@ +from . import link + +link_name = "GrapesJS issue queue" +link_text = "GrapesJS builder issues" +link_url = "https://github.com/mautic/mautic/issues?q=is%3Aopen+is%3Aissue+label%3Abuilder-grapesjs" + +link.xref_links.update({link_name: (link_text, link_url)}) diff --git a/docs/links/grapesjs_preset.py b/docs/links/grapesjs_preset.py new file mode 100644 index 00000000..6aa1c5a2 --- /dev/null +++ b/docs/links/grapesjs_preset.py @@ -0,0 +1,7 @@ +from . import link + +link_name = "GrapesJS Preset" +link_text = "GrapesJS Preset" +link_url = "https://github.com/mautic/grapesjs-preset-mautic" + +link.xref_links.update({link_name: (link_text, link_url)})