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

Reduce {empty} button width to 0.5em #244

Closed
RashmiSR opened this issue Mar 5, 2014 · 1 comment
Closed

Reduce {empty} button width to 0.5em #244

RashmiSR opened this issue Mar 5, 2014 · 1 comment

Comments

@RashmiSR
Copy link

RashmiSR commented Mar 5, 2014

Hi Mottie,

I downloaded new version of code from your website yesterday.
After that the width of {empty} button got increased in my UI page.
If i tried to reduce the width=2em, to 1em, changes are visisble in UI.
But when tried with 0.5em, changes are not visible.
How is it possible to reduce any button width to 0.5em?

MY code is

$('#keyboard').keyboard({

css:{ buttonDisabled:'ui-keyboard-empty'}

})

In css file

ui-keyboard-empty{height:2em; width:0.5em;opacity:0.0;filter:alpha(opacity=0);}

Thank you
Rashmi

@Mottie
Copy link
Owner

Mottie commented Mar 5, 2014

Hi @RashmiSR!

In the newest version you can use {sp:1.0em} again, or even {sp:0.5em} if you want (demo).

Actually. it looks like the ui.-keyboard-empty class name isn't even applied! =(

I'll fix this in the next update, but it looks like the class name ends up being ui-keyboard-

<button role="button" type="button" aria-disabled="true" tabindex="-1" class="ui-keyboard-button ui-keyboard- ui-keyboard-actionkey ui-state-default ui-corner-all ui-state-disabled" data-value="" name="" data-pos="0,0" title="" data-action="" data-original="" data-curtxt="" data-curnum="0">
    <span></span>
</button>

in any case, I haven't touched the css in a while. Maybe this issue involves setting the css-boxsizing? Try adding this:

/* apply a natural box layout model to all elements */
*, *:before, *:after {
  -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box;
 }

or if you want to reduce the size of all buttons, check out the FAQ

@Mottie Mottie added Bug labels Mar 5, 2014
@Mottie Mottie closed this as completed in 9f9157a Mar 6, 2014
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants