Skip to content

Commit

Permalink
Added ability to add user defined classes to slides. closes #302
Browse files Browse the repository at this point in the history
add `"classname": "myuniqueclassnamegoeshere"` to the date item and it will add that class to the slide created for that data.
  • Loading branch information
zachwise committed Feb 13, 2013
1 parent 6c41ba6 commit 1ac5d1e
Show file tree
Hide file tree
Showing 5 changed files with 64 additions and 49 deletions.
90 changes: 45 additions & 45 deletions codekit-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -200,16 +200,18 @@
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 2048
},
"\/source\/js\/Core\/Language\/locale\/fo.js" : {
"\/source\/less\/Core\/Font\/AbrilFatface-Average.less" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 1,
"inputAbbreviatedPath" : "\/source\/js\/Core\/Language\/locale\/fo.js",
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/source\/less\/Core\/Font\/AbrilFatface-Average.less",
"outputStyle" : 1,
"syntaxCheckerStyle" : 0,
"outputAbbreviatedPath" : "\/compiled\/js\/locale\/fo.js",
"fileType" : 64
"shouldRunBless" : 0,
"outputAbbreviatedPath" : "\/source\/less\/Core\/css\/AbrilFatface-Average.css",
"strictImports" : 0,
"fileType" : 1,
"debugStyle" : 0
},
"\/source\/jade\/sections\/example-head.jade" : {
"ignoreWasSetByUser" : 0,
Expand Down Expand Up @@ -253,18 +255,16 @@
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 2048
},
"\/source\/less\/Core\/Font\/AbrilFatface-Average.less" : {
"\/source\/js\/Core\/Language\/locale\/fo.js" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/source\/less\/Core\/Font\/AbrilFatface-Average.less",
"outputPathIsSetByUser" : 1,
"inputAbbreviatedPath" : "\/source\/js\/Core\/Language\/locale\/fo.js",
"outputStyle" : 1,
"shouldRunBless" : 0,
"outputAbbreviatedPath" : "\/source\/less\/Core\/css\/AbrilFatface-Average.css",
"strictImports" : 0,
"fileType" : 1,
"debugStyle" : 0
"syntaxCheckerStyle" : 0,
"outputAbbreviatedPath" : "\/compiled\/js\/locale\/fo.js",
"fileType" : 64
},
"\/dev_examples\/taylor\/fisher.jpg" : {
"ignoreWasSetByUser" : 0,
Expand Down Expand Up @@ -727,16 +727,14 @@
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 16
},
"\/dev_examples\/taylor\/sun.jpg" : {
"\/dev_examples\/embed_wide.html" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"ignore" : 1,
"hidden" : 1,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/dev_examples\/taylor\/sun.jpg",
"processed" : 0,
"outputAbbreviatedPath" : "\/dev_examples\/taylor\/sun.jpg",
"initialSize" : 47058,
"fileType" : 4096
"inputAbbreviatedPath" : "\/dev_examples\/embed_wide.html",
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 2048
},
"\/compiled\/js\/storyjs-embed.js" : {
"ignoreWasSetByUser" : 0,
Expand All @@ -749,14 +747,16 @@
"outputAbbreviatedPath" : "\/compiled\/js\/storyjs-embed-min.js",
"fileType" : 64
},
"\/dev_examples\/embed_wide.html" : {
"\/dev_examples\/taylor\/sun.jpg" : {
"ignoreWasSetByUser" : 0,
"ignore" : 1,
"hidden" : 1,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/dev_examples\/embed_wide.html",
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 2048
"inputAbbreviatedPath" : "\/dev_examples\/taylor\/sun.jpg",
"processed" : 0,
"outputAbbreviatedPath" : "\/dev_examples\/taylor\/sun.jpg",
"initialSize" : 47058,
"fileType" : 4096
},
"\/source\/js\/Core\/Language\/locale\/it.js" : {
"ignoreWasSetByUser" : 0,
Expand Down Expand Up @@ -1596,26 +1596,26 @@
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 16
},
"\/dev_examples\/taylor\/velvet.jpg" : {
"\/dev_examples\/houston\/whlead.jpg" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/dev_examples\/taylor\/velvet.jpg",
"inputAbbreviatedPath" : "\/dev_examples\/houston\/whlead.jpg",
"processed" : 0,
"outputAbbreviatedPath" : "\/dev_examples\/taylor\/velvet.jpg",
"initialSize" : 77001,
"outputAbbreviatedPath" : "\/dev_examples\/houston\/whlead.jpg",
"initialSize" : 97988,
"fileType" : 4096
},
"\/dev_examples\/houston\/whlead.jpg" : {
"\/dev_examples\/taylor\/velvet.jpg" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/dev_examples\/houston\/whlead.jpg",
"inputAbbreviatedPath" : "\/dev_examples\/taylor\/velvet.jpg",
"processed" : 0,
"outputAbbreviatedPath" : "\/dev_examples\/houston\/whlead.jpg",
"initialSize" : 97988,
"outputAbbreviatedPath" : "\/dev_examples\/taylor\/velvet.jpg",
"initialSize" : 77001,
"fileType" : 4096
},
"\/source\/js\/Core\/Library\/bootstrap-tooltip.js" : {
Expand Down Expand Up @@ -1812,15 +1812,6 @@
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 16
},
"\/compiled\/css\/themes\/font\/Bevan-PotanoSans.css" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/compiled\/css\/themes\/font\/Bevan-PotanoSans.css",
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 16
},
"\/compiled\/js\/locale\/nl.js" : {
"ignoreWasSetByUser" : 0,
"ignore" : 1,
Expand All @@ -1832,6 +1823,15 @@
"outputAbbreviatedPath" : "\/compiled\/js\/locale\/nl-min.js",
"fileType" : 64
},
"\/compiled\/css\/themes\/font\/Bevan-PotanoSans.css" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
"hidden" : 0,
"outputPathIsSetByUser" : 0,
"inputAbbreviatedPath" : "\/compiled\/css\/themes\/font\/Bevan-PotanoSans.css",
"outputAbbreviatedPath" : "No Output Path",
"fileType" : 16
},
"\/source\/js\/Core\/Language\/locale\/ko.js" : {
"ignoreWasSetByUser" : 0,
"ignore" : 0,
Expand Down
6 changes: 3 additions & 3 deletions compiled/js/timeline-min.js

Large diffs are not rendered by default.

13 changes: 13 additions & 0 deletions compiled/js/timeline.js
Original file line number Diff line number Diff line change
Expand Up @@ -5697,14 +5697,25 @@ if (typeof VMM.Slider != 'undefined') {
_enqueue = true,
_removeque = false,
_id = "slide_",
_class = 0,
timer = {pushque:"", render:"", relayout:"", remove:"", skinny:false},
times = {pushque:500, render:100, relayout:100, remove:30000};

_id = _id + data.uniqueid;
this.enqueue = _enqueue;
this.id = _id;


element = VMM.appendAndGetElement(_parent, "<div>", "slider-item");

if (typeof data.classname != 'undefined') {
trace("HAS CLASSNAME");
VMM.Lib.addClass(element, data.classname);
} else {
trace("NO CLASSNAME");
trace(data);
}

c = {slide:"", text: "", media: "", media_element: "", layout: "content-container layout", has: { headline: false, text: false, media: false }};

/* PUBLIC
Expand Down Expand Up @@ -7370,6 +7381,8 @@ if(typeof VMM != 'undefined' && typeof VMM.Timeline == 'undefined') {
_date.tag = data.date[i].tag;
_date.slug = data.date[i].slug;
_date.uniqueid = VMM.Util.unique_ID(7);
_date.classname = data.date[i].classname;


_dates.push(_date);
}
Expand Down
2 changes: 1 addition & 1 deletion source/js/Core
Submodule Core updated from c8d198 to a962f9
2 changes: 2 additions & 0 deletions source/js/VMM.Timeline.js
Original file line number Diff line number Diff line change
Expand Up @@ -632,6 +632,8 @@ if(typeof VMM != 'undefined' && typeof VMM.Timeline == 'undefined') {
_date.tag = data.date[i].tag;
_date.slug = data.date[i].slug;
_date.uniqueid = VMM.Util.unique_ID(7);
_date.classname = data.date[i].classname;


_dates.push(_date);
}
Expand Down

0 comments on commit 1ac5d1e

Please sign in to comment.