Giter VIP home page Giter VIP logo

t-vk / dynamicquilltools Goto Github PK

View Code? Open in Web Editor NEW
46.0 2.0 18.0 560 KB

DynamicQuillTools is a library that allows you to dynamically add or remove new custom elements to/from a Quill Editor's toolbar. For instance a button or a drop down menu.

License: BSD 3-Clause "New" or "Revised" License

JavaScript 72.86% HTML 27.14%
quill quilljs quill-editor toolbar dynamic custom dropdown button

dynamicquilltools's People

Contributors

t-vk avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

dynamicquilltools's Issues

Change Custom Drop Down Menu Options

Hello,

First, thank you for this library.

I would like to know how i can transform options (text representing URL) in the drop down menu to create a link like :
<a href="text from drop down menu">text from drop down menu</a>

I know it is possible to use a blot and I have already suceeded to create a button in Toolbar to add a link with a blot.
It is explained here : https://quilljs.com/guides/cloning-medium-with-parchment/

But I can't see how i can register a blot with QuillToolbarDropDown.

Any clue ?

Custom attach location.

My main toolbar has a sub-toolbar to group and style particular toolbar elements roughly laid out follows:

<div id="editor-container">
    <div id="toolbar">
      <span class="ql-formats">
        <button class="ql-bold"></button>
        <button class="ql-italic"></button>
      </span>
     <div id="sub-toolbar">
          <span class="ql-formats">
                <button id="sub-button">sub-button</button>
         </span>
     </div>
    </div>
    <div id="editor"></div>
</div>

It isn't clear how to add a dynamic drop box to the sub-toolbar in my example. It just adds after the #sub-toolbar div on calling myDropDown.attach(quill) as per your drop down box example.

Is there a way to target where dynamic toolbar element can be added?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.