CSS class for buttons without icons.
A new CSS class has been added for buttons without icons. The IPA.button() has been modified to use this class if there is no icons specified.
This commit is contained in:
1 parent
aa48d3b72e
commit
066cf79365
2 files changed
+15
-2
No files matched your search
@@ -699,12 +699,18 @@ IPA.button = function(spec) {
|
||||
id: spec.id,
|
||||
html: spec.label,
|
||||
title: spec.title || spec.label,
|
||||
'class': 'ui-state-default ui-corner-all input_link'
|
||||
'class': 'ui-state-default ui-corner-all'
|
||||
});
|
||||
|
||||
if (spec.click) button.click(spec.click);
|
||||
if (spec['class']) button.addClass(spec['class']);
|
||||
if (spec.icon) button.append('<span class="ui-icon '+spec.icon+'" ></span> ');
|
||||
|
||||
if (spec.icon) {
|
||||
button.addClass('input_link');
|
||||
button.append('<span class="ui-icon '+spec.icon+'" ></span> ');
|
||||
} else {
|
||||
button.addClass('button-without-icon');
|
||||
}
|
||||
|
||||
return button;
|
||||
};
|
||||
|
||||
@@ -52,6 +52,13 @@ body{
|
||||
top: 50%;
|
||||
}
|
||||
|
||||
.button-without-icon {
|
||||
padding: .4em 1em .4em 1em;
|
||||
text-decoration: none;
|
||||
position: relative;
|
||||
cursor: pointer;
|
||||
}
|
||||
|
||||
/* ---- Header ---- */
|
||||
div.header {
|
||||
background-color:#0C3B00;
|
||||
|
||||
Reference in new issue
Block a user