GithubHelp home page GithubHelp logo

avocode-email-tagsinput's Issues

Refactor monorepo to have meaningful scripts

When I was creating this library, I didn't know a lot about monorepos. I still don't know how it should be done correctly as everyone seems to be doing it a bit different. However according to this answer on SO I should

  • specify the dependencies that the package needs in its own package.json instead of moving the common ones to root package.json
  • be able to run those scripts from within package directories

The only thing I don't know how to do is how to share config files, such as webpack configs, jest, eslint. Might have to do more research.

Make padding and margin between tag components configurable

A lot of time I spend on finnicky CSS work involving adjusting the spacing between tag nodes. This also changes how the input behaves (in collapsed / regular mode). Maybe it'd be a good idea to have some set of constants that'd translate into CSS (perhaps by using preprocessor) so a developer could only specify:

  • gutter width between tag nodes
  • padding between tag nodes and input

And default styles would be recalculated accordingly. This of course adjusts only the default styles but at least when somebody would be implementing their own stuff in their own custom stylesheet, they could look into source code and figure it out more easily.

"Query" should be its own inline block

If you type into the input, the block that the cursor is not its own inline block. Due to time constraints I did not wrap it in its own block even though it probably should be.

For now, this makes it kinda hard to style that part of the input (since we have to target some kind of span inside the editor container like this .tagsinput > div > div > span:last-child) and I had to resort to some ugly hacks (see #8 ).

Improve performance when adding / removing tags on large data sets

Currently the UpdateValue plugin deals with updating the value. The problem is when you remove / add a tag somewhere in the beginning of the input, it treats all the other tags as changed. So the operation takes some time.

This is noticeable for inputs with 50+ tags in them, you can use Performance page in playground app to see this in action. Preferrably I should do a research on some efficient algorithm on how to deal with this. We could perhaps sacrifice accuracy for performance but I'm not sure if this is the right step.

Remove CSS hacks for Firefox

For some reason, Firefox adds space to created tag nodes by adding line-height: 11 property to tag node, it adds it to parent span element (that is contenteditable=false). Not sure if this is bug with slate or by some other CSS added the editor itself.

Add "placeholder" example to playground

The input is missing example for input when used with placeholder prop (which is a prop used by SlateJS that's why it's not mentioned in docs).
It'd be nice to have it, useful for testing if everything is styled properly.

Left arrow tag navigation not working in Firefox

When pressing LEFT key, it skips tags. Using RIGHT works OK. This problem happens only in Firefox.
This logic is implemented in KeyboardNavigationPlugin.

EDIT: It seems to be something in Slate I think. The key properties are same for all browsers but for some reason the methods editor.moveFocusTo and editor.moveAnchorTo are different in Firefox.

Fix scroll to tag node

Sometime when using collapsible option, the input is scrolled to position of cursor instead of last tag.

image (1)

Fix E2E counter spec for CollapsibleTagsInput

The skipped spec in packages/better-react-tagsinput/test/e2e/collapsible-tagsinput.spec.js fails.

It's spec named should update count when tags are added. This one occurs randomly, sometimes it passes in CI and sometimes not. It's possible it's some kind of timing issue.

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.