Skip to content
Browse files

Various fixes

  • Loading branch information...
1 parent 202f99f commit 46b4adb3d6e60363dfb82a83bec58351870d367f @tbassetto tbassetto committed Jun 8, 2012
Showing with 18 additions and 35 deletions.
  1. +2 −2 index.html
  2. +11 −11 js/app.js
  3. +5 −22 package.json
View
4 index.html
@@ -10,7 +10,7 @@
<!-- Soon with a hook to jQuery Mobile Themeroller -->
<link rel="stylesheet" href="css/jquery.mobile.theme-1.1.0.css">
<link rel="stylesheet" href="css/app.css">
- <script data-joshfire-bootstrap src="http://127.0.0.1:40021/bootstrap/4fd0d89c1fa50e42f400083c/4fd0e33e1fa50e42f4000bbf/phone/"></script>
+ <script data-joshfire-bootstrap src="http://127.0.0.1:40021/bootstrap/4fd1e5331fa50e42f4000e24/4fd1e54b1fa50e42f4000ed1/phone/"></script>
<script src="js/jquery.js"></script>
<script src="js/jsrender.js"></script>
<script src="js/mediaplayerlib.js"></script>
@@ -82,7 +82,7 @@
</script>
<script id="videoObjectTemplate" type="text/x-jsrender">
- <h1>{{:name}}</h1>
+ <h3>{{:name}}</h3>
<div id="video-player" style="max-width:100%"></div>
<p>{{:description}}</p>
<p>Posted by <em>{{:author[0].name}}</em></p>
View
22 js/app.js
@@ -75,8 +75,8 @@ function createPage( dataSourceId, data, urlObj, articleId ) {
// Generate a navbar item for each datasources and add it to our markup.
for ( var i = 0; i < tabs.length; i++ ) {
- var name = ( tabs[i] && tabs[i].name ) || dataSources[i].name;
- var icon = ( tabs[i] && tabs[i].icon ) || "grid"; // TODO: depends of data source type instead
+ var name = ( tabs[ i ] && tabs[ i ].name ) || dataSources[ i ].name;
+ var icon = ( tabs[ i ] && tabs[ i ].icon ) || "grid"; // TODO: depends of data source type instead
footerMarkup += "<li><a href='#datasource=" + i + "' data-icon='" + icon + "'>" + name + "</a></li>";
}
@@ -146,27 +146,27 @@ function createPage( dataSourceId, data, urlObj, articleId ) {
for ( var i = 0; i < data.entries.length; i++ ) {
// Our item need to be extended to transmit useful information to the template
- data.entries[i].i = i;
- data.entries[i].dataSourceId = dataSourceId;
+ data.entries[ i ].i = i;
+ data.entries[ i ].dataSourceId = dataSourceId;
- var extractedDay = extractDay( data.entries[i].datePublished );
+ var extractedDay = extractDay( data.entries[ i ].datePublished );
- if ( data.entries[i].datePublished ) {
+ if ( data.entries[ i ].datePublished ) {
if ( previousDate !== extractedDay && outputType == "BlogPosting" ) {
contentMarkup += "<li data-role='list-divider'>" + extractedDay + "</li>";
previousDate = extractedDay;
}
- data.entries[i].datePublished = extractTime(data.entries[i].datePublished);
+ data.entries[ i ].datePublished = extractTime(data.entries[ i ].datePublished);
}
if ( outputType == "BlogPosting" ) {
- contentMarkup += $( "#blogPostingListTemplate" ).render( data.entries[i] );
+ contentMarkup += $( "#blogPostingListTemplate" ).render( data.entries[ i ] );
} else if ( outputType == "ImageObject" || outputType == "VideoObject" ) {
- contentMarkup += $( "#mediaObjectListTemplate" ).render( data.entries[i] );
+ contentMarkup += $( "#mediaObjectListTemplate" ).render( data.entries[ i ] );
} else if ( outputType == "Article/Status" ) {
- contentMarkup += $( "#statusListTemplate" ).render( data.entries[i] );
+ contentMarkup += $( "#statusListTemplate" ).render( data.entries[ i ] );
} else {
- contentMarkup += $( "#genericListTemplate" ).render( data.entries[i] );
+ contentMarkup += $( "#genericListTemplate" ).render( data.entries[ i ] );
}
}
contentMarkup += "</ul>";
View
27 package.json
@@ -161,36 +161,19 @@
]
},
{
- "name": "Klass",
- "homepage": "https://github.com/ded/klass",
- "description": "An expressive, cross platform JavaScript Class provider with a classical interface to prototypal inheritance.",
+ "name": "JsRender",
+ "homepage": "https://github.com/BorisMoore/jsrender",
+ "description": "Next-generation jQuery Templates",
"repositories": [
{
"type": "git",
- "url": "https://github.com/ded/klass.git"
+ "url": "https://github.com/BorisMoore/jsrender.git"
}
],
"licenses": [
{
"type": "MIT",
- "url": "license-klass.txt"
- }
- ]
- },
- {
- "name": "Photoswipe",
- "homepage": "http://www.photoswipe.com/",
- "description": "Inspired by the iOS photo viewer and Google images for mobile, PhotoSwipe is a HTML/CSS/JavaScript based image gallery specifically targeting mobile devices.",
- "repositories": [
- {
- "type": "git",
- "url": "https://github.com/codecomputerlove/PhotoSwipe.git"
- }
- ],
- "licenses": [
- {
- "type": "MIT",
- "url": "license-photoswipe.txt"
+ "url": "https://raw.github.com/BorisMoore/jsrender/master/MIT-LICENSE.txt"
}
]
}

0 comments on commit 46b4adb

Please sign in to comment.
Something went wrong with that request. Please try again.