First, here is what the simplified accordion looks like using the Redmond theme.
I'm using the following Javascript code to create the widget.
$(function() {
// Use custom section icons, and collapse all sections
// by default.
$( "#accordion" ).accordion({
icons: {
header: "ui-icon-circle-plus",
activeHeader: "ui-icon-circle-minus"
},
collapsible: true,
active: false
});
});
And here is the CSS used to hide the parts of the accordion I don't care about. Be sure to include it after including your theme so you can override it.
/*
* Get rid of the accordion header border and background.
* Also make the font a little bigger so it stands out.
*
*/
.ui-accordion .ui-accordion-header {
border: none;
background: none;
font-size: 1.1em;
}
/*
* Fix the icon position, it looks a little off with the
* default value of 50%.
*
*/
.ui-accordion .ui-accordion-header .ui-accordion-header-icon {
top: 48%;
}
/*
* Git rid of the accordion section content border and
* background.
*
*/
.ui-accordion .ui-accordion-content {
border: none;
background: none;
}
No comments :
Post a Comment