Simple Single Page Application Functionality
Navigating between pages is easy:
<app-page class="default-page" id="home">
<h1>Home page</h1>
<a data-goto="new">go to new page</a>| function uploadAndConvertToBase64DataURL(callback) { | |
| if (!document.getElementById("B64DURL_UL")) { | |
| var input = document.createElement("input"); | |
| input.id = "B64DURL_UL"; | |
| input.style.display = "none"; | |
| input.type = "file"; | |
| document.body.appendChild(input); | |
| } | |
| var input = document.getElementById("B64DURL_UL"); | |
| input.addEventListener("change", function (e){ |
| function Model(name, OBJ) { | |
| function model(obj) { | |
| var PUBLIC = this; | |
| var PRIVATE = {}; | |
| PUBLIC.MODEL_TYPE = name; | |
| for (let key in obj) { | |
| let value = obj[key]; | |
| // Ensure property is set correctly |
| function DotSequence(seq) { | |
| var self = this; | |
| seq = seq || []; | |
| self.commands = {}; | |
| self.addCommand = function (name,operation) { | |
| self.commands[name] = operation; | |
| self[name] = function (...params) { | |
| seq.push({ | |
| command: name, | |
| params |
| function compress(z) { | |
| z = z.toString(); | |
| var a = []; | |
| z.split("").forEach((e,i)=>{a[i] = parseInt(e);}); | |
| var u = "0123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM!?"; | |
| var x = u.substring(0,Math.max(...a)+1); | |
| var s = x.length; | |
| var d = u.length; | |
| var v = 0; | |
| var n = z.length; |
| function StateMapper(subjects,states) { | |
| var self = this; | |
| self.states = states || []; | |
| self.subjects = subjects || []; | |
| self.encode = function(z) { | |
| z = z.toString(); | |
| var x = "0123456789"; | |
| var u = "0123456789qwertyuiopasdfghjklzxcvbnmQWERTYUIOPASDFGHJKLZXCVBNM!?"; | |
| var s = x.length; |
| function processJSin(target) { | |
| var html = target.innerHTML; | |
| var temp = html.match(/\{\{.*\}\}/); | |
| if (temp !== null) { | |
| temp.forEach(function(item){ | |
| var e = item.replace("{{","").replace("}}",""); | |
| html = html.replace(item,eval(e)); | |
| }); | |
| target.innerHTML = html; | |
| } |
| var Observable = function(v){ | |
| var d, l = [], t = () => { | |
| for (var i = 0; i < l.length; i++) { | |
| if (typeof l[i] == "function") { | |
| l[i](d); | |
| } | |
| } | |
| }; | |
| var observable = function (v) { |
| function TDROM() { | |
| var THIS = this; | |
| THIS.data = []; | |
| THIS.props = {}; | |
| THIS.vals = {}; | |
| THIS.map = []; | |
| THIS.add = function(obj) { | |
| var index = THIS.data.push(obj) - 1, p, v, k; | |
| for (k in obj) { |
| <head> | |
| <title>HTA Test</title> | |
| <HTA:APPLICATION | |
| APPLICATIONNAME="Application" | |
| SCROLL="no" | |
| SINGLEINSTANCE="yes" | |
| > | |
| </head> |