switching to style manager causes permanent (black) border on selecting elements
See original GitHub issueUsing latest stable Grapes + Grapes preset webpage.
Steps to reproduce
- go to https://jsfiddle.net/szLp8h4n/101/
- select the text element
- deselect the text element
- notice the permanent black border appearing:
The expected behavior is that there is no black border when deselecting the element.
Note that this behavior is fixed by removing the logic that automatically opens the style manager when selecting a component:
Therefore there seems to be a bug when changing the active
state of a view.
Issue Analytics
- State:
- Created 5 years ago
- Reactions:1
- Comments:11 (1 by maintainers)
Top Results From Across the Web
How to remove black border effect around select element ...
Try setting the following in your CSS: select { outline: 0 !important; }. However, styling the select element is a notoriously wonky endeavor....
Read more >Modifying selections in Photoshop Elements
Moving a selection border repositions just the border without altering the photo. Using any selection tool, click New Selection in the options ...
Read more >border-style - CSS: Cascading Style Sheets - MDN Web Docs
Displays a border with an extruded appearance. It is the opposite of groove . inset. Displays a border that makes the element appear...
Read more >User interface options | Docs
The element path shows the selected element and the parent elements. Clicking an element on the element path will select the element in...
Read more >Styling in React: 5 ways to style React apps
Learn about styling React components with inline styling, styled-components, CSS modules, Tailwind CSS, and Sass and CSS style sheets.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
@artf I think that this problem is only partially solved. Please, check this screencast, you will see a related rgb border bug in the current grapesjs demo https://screencast-o-matic.com/watch/cFf3DbbiN6
I have created a new issue here
I got working a dirty workaround and this is my current best solution based on @tommedema suggestion.
Just remove the “border” property from the decoration tab and add border-top, bottom, right and left instead.
buildProps: ["opacity", "background-color", "border-radius", "box-shadow", "background", "border-top", "border-bottom", "border-left", "border-right"],
This will completely remove the bugged border property and add 4 new properties.
The bad part of this workaround is that you will need to customize the new border properties by hand:
5px solid rgb(220, 22, 22)
Something like that will appear in every border text field, so your users will not have a color picker.
Maybe I’ll try to code my own color picker for the borders. I am afraid that if I use the default grapesjs one, it can be hard to achieve and that crazy bug may come back.