jQuery-Knob icon indicating copy to clipboard operation
jQuery-Knob copied to clipboard

display:inline on external div misalign the text in Chrome, Safari and Firefox with Twitter Bootstrap

Open yannikmesserli opened this issue 10 years ago • 6 comments

I have a simple bootstrap template like this:

<div class="row">
        <div class="col-md-2">
                <input type="text" value="0" class="knob" data-min="0" data-max="10000" read-only="true">    
        </div>
       ...
</div>

And the text in the middle end up after the canvas element. The problem seems to be solved by removing the display:inline; style on the external div, line 194 in javascript.

194      // + (this.o.inline ? 'display:inline;' : '')

So I suspect the position-relative style of the parent mess with JQuery-Knob's styles. Maybe a test is necessary before setting this property?

Tested in Chrome 35.0, Firefox 29.0.1, and Safari 7.3 on Mac OSX 10.9.2 and latest stable version of JQuery-knob.

yannikmesserli avatar Jun 15 '14 01:06 yannikmesserli

That's it, folks. Thanks (:

cannibalita avatar Jun 25 '14 20:06 cannibalita

had same issue, thanks for quickfix

charlie-eth avatar Oct 14 '14 12:10 charlie-eth

thank you very much for this solution.......

kapil09karma avatar Jan 27 '15 12:01 kapil09karma

What's the solution? Can't see it. Seems like the post is deleted.

rivf avatar Dec 09 '15 00:12 rivf

Without modifying the source: $(".dial").knob({ 'inline': false });

Kentus avatar Jun 12 '16 06:06 Kentus

For me I can't see it, I wonder. The style class="knob" where and what are these styles?

hutber avatar Aug 22 '16 21:08 hutber