Skip to content
This repository was archived by the owner on Feb 18, 2023. It is now read-only.
This repository was archived by the owner on Feb 18, 2023. It is now read-only.

Add a 'selector' options for the preview that permits to put the preview in any user-defined element #14

@allan-simon

Description

@allan-simon

For example being able to do

'preview' : 'selector' ,
'selector' : '#mydiv' 

and being able to have the preview in that div

I already implemented it here's the diff

index 11f41ff..9e6e6a9 100644
--- a/app/resources/skins/responsive/js/external/jquery.markedit.js
+++ b/app/resources/skins/responsive/js/external/jquery.markedit.js
@@ -338,6 +338,9 @@
                     $(this).markeditBindAutoPreview(previewPane);

                 }
+                else if (options.preview === 'selector') {
+                    $(this).markeditBindAutoPreview($(options.selector));
+                }
                 else if (options.preview !== false) {
                     throw "Preview option '" + options.preview + "' is not recognized.";
                 }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions