Giter VIP home page Giter VIP logo

list's People

Contributors

chouglesaud avatar dependabot[bot] avatar dimensi avatar eduphp avatar gohabereg avatar goldenjaden avatar hata6502 avatar khaydarov avatar nespecc avatar polinashneider avatar robonetphy avatar sozialarchiv avatar talyguryn avatar tatianafomina 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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

list's Issues

Pressing ENTER to get out of list is not working

Currently pressing enter to get out of the list into a new block is not working.
The current behaviour creates a new block, the last (empty) list element is removed but the caret remains on the list block (although not functioning to write).
If enter is pressed again, a second new block is created and it moves to that one (now having an empty block before).

bug demo

I have tested this in Safari, Chrome and Firefox on MacOS

Issue leaving unordered list

Create a new list (order default)
Tune to an unordered list.
=> user cannot leave the list. Any newline will add a new bullet but there is no way to leave it.

This does not appear before switching ordered/unordered.
This does not appear when changing a text bloc to a list block

That's what makes me think this is a bug.

How to make unordered list as default?

I am using the following editorjs config:

tools: {
     list: { 
          class: require('@editorjs/list'),
          shortcut: 'CMD+SHIFT+L' 
     }
},
inlineToolbar: true

Now when I use shortcut CMD+SHIFT+L on the app, it generates an ordered list block. The same behavior is when I add a list block.

But when I manually use "Convert To", it changes block to an unordered list. I want to default the behavior of previous two methods to generate an unordered list. Is is possible?

Maybe some parameter like defaultStyle: "unordered" similar to defaultLevel in @editorjs/header?

Convert To (Text/Heading) Collapses <li> into a single line

When a user highlights text in a list and selects the "convert to text" or "convert to heading" options, the list collapses into a single line.

Expected behavior in most text editors would retain each </li> as a <br> or convert <li> to <p>/<h2> and </li> to </p>/</h2>, etc.

Here is a GIF replicating this on EditorJS homepage on Dec 16, 2022. Homepage says it is still using "version" : "2.26.0" but I'm seeing it on our local updated 2.26.4 version (1.8.0 on the list plugin) as well:
editorjs-list-collapse-on-convert-to2022-12-16 09-18-03 2022-12-16 09_19_16

How to format text inside a list block?

I want to add bold/italics styling in the list. I'm able to do so by using the shortcuts Ctrl+B/I. But when I save the data <b> or <i> tags are automatically removed. Is there a way by which I can keep them?

PS: I looked through the whole source code here, but I found that everywhere innerHTML is used (not innerText or textContent), which should return the complete HTML including the tags. Can someone tell me where are they being actually removed, so that I can modify the source according to my needs?

Use of formatted content inside list

Hi. I could not find a way to enable or to allow the use of the paragraph like toolbar with html components while in the list items.
Case: My user wants to add links inside list items, but the toolbar for link creation wont popup (or exist, fo that matter) like it does for the paragraph.

Could not find a declaration file

Could not find a declaration file for module '@editorjs/list'. '' implicitly has an 'any' type.
  Try `npm i --save-dev @types/editorjs__list` if it exists or add a new declaration (.d.ts) file containing `declare module '@editorjs/list';`ts(7016)

while editorjs/header had a @types I could install, I cannot find one for lists.

List vs NestedList

hi,
as per features, is List a subset of NestedList?
may i replace List with NestedList?

thanks

Sometime lists doesn't work

Hi, some time hitting enter make a new list item and sometime it stuck. Most of the time it stuck after adding some contents such image etc. Sometime, when hit enter nothing happens. Any reason why?

404 installing from yarn

Getting this error suddenly when trying to install from yarn: An unexpected error occurred: "https://registry.yarnpkg.com/@editorjs/list/-/list-1.8.0.tgz: Request failed \"404 Not Found\"".

Any idea what’s going on here?

Translation Doesn't apply

i added the below code section inside the tools section (i18n/messages/tools) and it Doesn't Apply!
"list": {
"Ordered": "Нумерованный",
"Unordered": "Маркированный"
},

Does not display on an iphone 12

Hello,

For information, it seems that the list does not display on an iphone 12.
But the addon @editorjs/nested-list works well on the same device.

Best regards,

How to invoke list manually?

One feature I like about Notion is that when you type - and hit space, it will automatically add a list item.

If I wanted to add this feature- what's the best approach? Can I hook into the class somehow to manually add a list?

Is there a way to set the first number of an ordered list?

Im thinking in some way to set the first element in an ordered list, this is the current behaviour:

  1. first element
  2. second element
  3. third element
    (I want an image, code block or whatever and continue my list with number 4 however if I insert a new list Im forced to continue with number 1)
  4. fourth element
  5. fith element
    ....
    ....

I think will be a good idea to have an input in the Block Settings box where will be possible to type the first element of the list so the following will be possible:

  1. first element
  2. second element
  3. third element
    (I want an image, code block or whatever and continue my list with number 4 however if I insert a new list Im forced to continue with number 1)
  4. fourth element
  5. fith element
    (another image or something)
  6. ....
  7. .....

If is possible right now forget about this, however after reading documentation and viewing some examples "first element of an ordered list" is not supported, I was thinking to extend this class (List component) and have this behaviour in some way only for me but at the last page of the official documentation I see that is possible contribute and commit the changes, I think this last option will be much better. what do you think?

Nested list support

It is quite common to have nested list in a document. For example, github would convert

1. item1
    - test
       1. test1
       2. test2
    - test
1. item2
    This is some text for item2  

into

  1. item1
    • test
      1. test1
      2. test2
    • test
  2. item2
    This is some text for item2

I really hope that it would be supported in a block-styled editor.

Converted List cant create new line

Great job with this editor!
Falling in love with it every minute.
Kudos to the whole community!!!!
I have a rather thrival question:
When I convert a paragraph to a List, I find that when I press Enter, instead of a new line to showup and the List increment (if Numbered List), it just stays on that page.
Nothing happens.
No new line is created and the list is not incremented.

I think this is a bug.
Thanks for helping me take a look!

Unable to delete a list item

When I try to delete a list item it doesn't work. I'm able to delete the text of the item, but the bullet remains.

list_problem.mov

Output format: Which properties (if any) can be null omitted?

For a valid list block, can any of the style or items properties under any circumstances (now or in the future) be null or omitted, and can any array element in items be null (or will it always be at least an empty string)? Or are they guaranteed to always be present and non-null for this block to be valid?

Context: I'm a back-end .NET developer needing to parse Editor.js documents. The readme lists all of the aforementioned properties but does not explicitly guarantee that they will always be present and non-null. Back-end deserialization/parsing in strongly typed languages would be easier with some guarantees about which properties can and can not be null/omitted. (Ideally, any such guarantees should be added to the readme to ensure they are formalized and kept in the future.)

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.