Skip to content

Commit

Permalink
SimpleMDE ➔ EasyMDE
Browse files Browse the repository at this point in the history
SimpleMDE is no longer maintained: sparksuite/simplemde-markdown-editor#829
➔ Switch to [EasyMDE](https://github.com/Ionaru/easy-markdown-editor), a fork.

readonly mode: `EasyMDE.prototype.markdown` is no longer as simple as
`SimpleMDE.prototype.markdown` used to be (now requires an EasyMDE
instance) so this cset instead adds the `marked` lib to call it
directly, without relying on EasyMDE's wrapper.
  • Loading branch information
houzefa-abba committed Feb 7, 2023
1 parent 08b79b0 commit bd21976
Show file tree
Hide file tree
Showing 10 changed files with 57 additions and 50 deletions.
10 changes: 7 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
This widget add a markdown Editor to Text field. In Edit mode the Editor is fuly usable
and in readonly mode the widget shows a naive transformation of markdown to HTML as a preview.

This module uses the JavaScript library [SimpleMDE](https://simplemde.com/) as a Markdown Editor for the client.
This module uses the JavaScript library [EasyMDE](https://github.com/Ionaru/easy-markdown-editor) as a Markdown Editor for the client.

And the python [Markdown library](https://github.com/Python-Markdown/markdown) for backend usage.

Expand Down Expand Up @@ -31,7 +31,7 @@ In your xml view, add `widget="markdown"` to any Text field.

### Options

In the options attribute, pass any options of [SimpleMDE](https://github.com/sparksuite/simplemde-markdown-editor#configuration) configuration.
In the options attribute, pass any options of [EasyMDE](https://github.com/Ionaru/easy-markdown-editor#configuration) configuration.

## Usage in report / Website templates

Expand All @@ -49,8 +49,12 @@ Do not contact contributors directly about support or help with technical issues

## Credits

Big thanks to the authors of [SimpleMDE](https://github.com/sparksuite/simplemde-markdown-editor).
Big thanks to the authors of [EasyMDE](https://github.com/Ionaru/easy-markdown-editor), which is based on [SimpleMDE](https://github.com/sparksuite/simplemde-markdown-editor).

### Widget Author

[![Coding Dodo](https://res.cloudinary.com/phildl-cloudinary/image/upload/w_300/v1617638212/codingdodo/Coding_Dodo_rplksw.png)](https://codingdodo.com)

### Widget Contributors

* [XCG](https://xcg-consulting.fr/)
4 changes: 2 additions & 2 deletions __manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
""",
"description": """
Allow the use of the widget markdown to display markdown content into Odoo views
in render mode and a markdown Editor in edit mode thanks to SimpleMDE Javascript library
in render mode and a markdown Editor in edit mode thanks to EasyMDE Javascript library
""",
"author": "Coding Dodo",
"website": "https://codingdodo.com",
Expand All @@ -20,7 +20,7 @@
"assets": {
"web.assets_backend": [
"/web_widget_markdown/static/src/js/field_widget.js",
"/web_widget_markdown/static/lib/simplemde.min.css",
"/web_widget_markdown/static/lib/easymde.min.css",
],
"web.assets_qweb": [
"/web_widget_markdown/static/src/xml/qweb_template.xml",
Expand Down
7 changes: 7 additions & 0 deletions static/lib/easymde.min.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 7 additions & 0 deletions static/lib/easymde.min.js

Large diffs are not rendered by default.

6 changes: 6 additions & 0 deletions static/lib/marked.min.js

Large diffs are not rendered by default.

Loading

0 comments on commit bd21976

Please sign in to comment.