nav/template stuff

This commit is contained in:
Adam Bradley
2013-08-25 22:54:18 -05:00
parent ae871c1613
commit a0ceba83d5
12 changed files with 254 additions and 246 deletions

View File

@ -8,22 +8,8 @@
// trigger that the DOM is ready
framework.trigger("ready");
// ensure that the start page has an id
var mainElement = document.querySelector("main");
if(mainElement) {
if(!mainElement.id || mainElement.id === "") {
mainElement.id = "pg" + Math.floor( Math.random() * 999999 );
}
// remember what the active page's id is
framework.activePageId = mainElement.id;
// inform the framework that the start page has been added to the DOM
framework.trigger("pagecreate", {id: mainElement.id, url: location.href});
// trigger that the start page is in view
framework.trigger("pageview");
}
// trigger that the start page is in view
framework.trigger("pageview");
}
// When the DOM is ready, initalize the webapp