diff --git a/build/jqm.editable.listview.js b/build/jqm.editable.listview.js index 4ed6a93..f69402c 100644 --- a/build/jqm.editable.listview.js +++ b/build/jqm.editable.listview.js @@ -97,6 +97,10 @@ ui.header = ui.wrapper.find('.ui-collapsible-heading') ui.button = ui.header.find('a a, a button') ui.content = ui.wrapper.find('.ui-collapsible-content') + + // add anchor so I can attach identifying class + ui.anchor = ui.header.find('.ui-collapsible-heading-toggle'); + ui.form = this._getForm(); $.extend(this, { @@ -316,7 +320,10 @@ .children("a")[0] .childNodes[0] .data = (isListEmpty) ? opts.emptyTitle : opts.title; - + + // attached header title as class to enable custom styling to added later + ui.anchor.addClass(opts.title.replace(/\s+/g, '')); + // changing "Edit" button state, icon and label ui.button.removeClass('ui-icon-minus ui-icon-' + opts.doneIcon + ' ui-icon-' + opts.addIcon + ' ui-icon-' + opts.editIcon) .addClass('ui-icon-' + (this._editMode ? opts.doneIcon : isListEmpty ? opts.addIcon : opts.editIcon)) diff --git a/demo/demo.css b/demo/demo.css index e69de29..8331d86 100644 --- a/demo/demo.css +++ b/demo/demo.css @@ -0,0 +1,3 @@ +.Fruits { + background-color:#F29968 !important; +} \ No newline at end of file diff --git a/demo/index.html b/demo/index.html index 9ddfe11..9e045ea 100644 --- a/demo/index.html +++ b/demo/index.html @@ -15,9 +15,9 @@ - + --> - +
@@ -44,7 +44,7 @@Delete "Orange" from the following list of "Fruits"
-