Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buttons locks its attribute on click or after use one time #691

Closed
SabirHossain opened this issue Jan 14, 2018 · 14 comments
Closed

Buttons locks its attribute on click or after use one time #691

SabirHossain opened this issue Jan 14, 2018 · 14 comments
Milestone

Comments

@SabirHossain
Copy link

SabirHossain commented Jan 14, 2018

I'm new to Trumbowyg editor, I'm Trumbowyg with ASP.NET Core everything's working fine but once I click the "Bold" button then the "Bold" button locked it's state and don't go away even I double click, also some other buttons like backgroundColor, Italic button sometimes don't work..

Browser: Firefox 57.0.4 (64-bit), Chrome, IE.
Windows 10

@Alex-D
Copy link
Owner

Alex-D commented Jan 16, 2018

Did you make a selection before click/re-click on bold?

Trumbowyg does not support simple clic to enable/disable bold. So, you always should write the text, then select the part you want format, then click on buttons you want.

@hfrid
Copy link

hfrid commented Jan 31, 2018

I too have this problem.. once you click the bold button its "locked" in its active state. Clicking "remove format" clears it. Using v2.9.4. Made a quick video to demonstrate the problem here:

http://youtu.be/MnV9fRFNLMI?hd=1

Probably a conflict with some other script. My page has the following loaded:

<script src="https://code.jquery.com/jquery-2.1.3.min.js"></script>
<script src="https://code.jquery.com/ui/1.11.4/jquery-ui.min.js"></script>
<script src="https://cdn.jsdelivr.net/ddslick/2.0/jquery.ddslick.min.js"></script>
<link rel="stylesheet" href="https://code.jquery.com/ui/1.11.4/themes/smoothness/jquery-ui.css">
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.96.1/css/materialize.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/materialize/0.96.1/js/materialize.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery.tablesorter/2.21.5/js/jquery.tablesorter.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/typeahead.js/0.11.1/typeahead.bundle.min.js"></script>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.9.4/trumbowyg.min.js"></script>
<link href="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.9.4/ui/trumbowyg.min.css" rel="stylesheet">
<link href="https://fonts.googleapis.com/icon?family=Material+Icons" rel="stylesheet">
<link rel="stylesheet" href="css/materialize-tags.min.css">
<script src="js/materialize-tags.min.js"></script>
<script src="Trumbowyg/dist/trumbowyg.min.js"></script>
<link rel="stylesheet" href="Trumbowyg/dist/ui/trumbowyg.min.css">
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery-sparklines/2.1.2/jquery.sparkline.min.js"></script>

@Alex-D
Copy link
Owner

Alex-D commented Jan 31, 2018

<script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.9.4/trumbowyg.min.js"></script>
<!-- ... -->
<script src="Trumbowyg/dist/trumbowyg.min.js"></script>

Why??? Same for the CSS oO

Are you sure dist files are in 2.9.4?

@hfrid
Copy link

hfrid commented Jan 31, 2018

Sorry forgot to remove them when I switched to local files. Yeah 100% sure they are 2.9.4...

@Alex-D
Copy link
Owner

Alex-D commented Jan 31, 2018

Does it works on the Trumbowyg landing: https://alex-d.github.io/Trumbowyg/ ?

@hfrid
Copy link

hfrid commented Jan 31, 2018 via email

@Alex-D
Copy link
Owner

Alex-D commented Jan 31, 2018

I can't really help you if you can't make a buggy sample code with minimum amount of code :/

@hfrid
Copy link

hfrid commented Feb 2, 2018

Your CSS is conflicting with something in this one (works if I comment it out):
https://cdnjs.cloudflare.com/ajax/libs/materialize/0.96.1/css/materialize.min.css

The strikethrough is present even on your demo page however:
http://youtu.be/SBT7RdbLhtw?hd=1

This is on Chrome 64bit Version 64.0.3282.140

@Alex-D
Copy link
Owner

Alex-D commented Feb 3, 2018

That's the only one button which is like that, no?

@hfrid
Copy link

hfrid commented Feb 3, 2018 via email

@Alex-D Alex-D closed this as completed Feb 25, 2018
@kishorcloudanalogy
Copy link

kishorcloudanalogy commented Sep 17, 2019

<script src="https://cdnjs.cloudflare.com/ajax/libs/Trumbowyg/2.9.4/trumbowyg.min.js"></script>
<!-- ... -->
<script src="Trumbowyg/dist/trumbowyg.min.js"></script>

Why??? Same for the CSS oO

Are you sure dist files are in 2.9.4?

I am facing the same issue in React js.
Can you help me to resolve these issues?
The button is locked and not removed on double click.

@theM1st
Copy link

theM1st commented Oct 30, 2019

The bugs still here...
Look for example https://gifyu.com/image/kAIB
Can you fix it? Thank you..

@Alex-D
Copy link
Owner

Alex-D commented Oct 31, 2019

Nope. Too hard to fix that. But I keep that in mind for v3 #875 :)

@Alex-D Alex-D added this to the v3.0 milestone Oct 31, 2019
@ghost
Copy link

ghost commented Nov 4, 2020

// Text Styles
em { font-style: italic; }
strong { font-weight: 500; }
small { font-size: 75%; }

in _typography.scss of MaterializeCSS those lines are the issue on Editor with Bold / Italic.
If you comments them, it will work normally

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants