diff --git a/dist/xrfragment.aframe.all.js b/dist/xrfragment.aframe.all.js index 2ac2697..152e177 100644 --- a/dist/xrfragment.aframe.all.js +++ b/dist/xrfragment.aframe.all.js @@ -1,5 +1,5 @@ /* - * v0.5.1 generated at Thu Feb 29 01:34:17 PM UTC 2024 + * v0.5.1 generated at Thu Feb 29 01:43:17 PM UTC 2024 * https://xrfragment.org * SPDX-License-Identifier: MPL-2.0 */ diff --git a/dist/xrfragment.aframe.js b/dist/xrfragment.aframe.js index c07c7a6..6edc79b 100644 --- a/dist/xrfragment.aframe.js +++ b/dist/xrfragment.aframe.js @@ -1,5 +1,5 @@ /* - * v0.5.1 generated at Thu Feb 29 01:34:17 PM UTC 2024 + * v0.5.1 generated at Thu Feb 29 01:43:17 PM UTC 2024 * https://xrfragment.org * SPDX-License-Identifier: MPL-2.0 */ diff --git a/dist/xrfragment.module.js b/dist/xrfragment.module.js index ed0f33b..99d0320 100644 --- a/dist/xrfragment.module.js +++ b/dist/xrfragment.module.js @@ -1,3 +1,13 @@ +/* + * v0.5.1 generated at Thu Feb 29 01:43:17 PM UTC 2024 + * https://xrfragment.org + * SPDX-License-Identifier: MPL-2.0 + */ +/* + * v0.5.1 generated at Thu Feb 29 01:42:39 PM UTC 2024 + * https://xrfragment.org + * SPDX-License-Identifier: MPL-2.0 + */ /* * v0.5.1 generated at Thu Feb 29 01:34:17 PM UTC 2024 * https://xrfragment.org @@ -84418,3 +84428,2673 @@ xrfragment_XRF.isXRFScheme = new EReg("^xrf://",""); })(typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : this); var xrfragment = $hx_exports["xrfragment"]; export default xrfragment; +var $hx_exports = typeof exports != "undefined" ? exports : typeof window != "undefined" ? window : typeof self != "undefined" ? self : this; +(function ($global) { "use strict"; +$hx_exports["xrfragment"] = $hx_exports["xrfragment"] || {}; +var $estr = function() { return js_Boot.__string_rec(this,''); },$hxEnums = $hxEnums || {},$_; +function $extend(from, fields) { + var proto = Object.create(from); + for (var name in fields) proto[name] = fields[name]; + if( fields.toString !== Object.prototype.toString ) proto.toString = fields.toString; + return proto; +} +var EReg = function(r,opt) { + this.r = new RegExp(r,opt.split("u").join("")); +}; +EReg.__name__ = true; +EReg.prototype = { + match: function(s) { + if(this.r.global) { + this.r.lastIndex = 0; + } + this.r.m = this.r.exec(s); + this.r.s = s; + return this.r.m != null; + } + ,matched: function(n) { + if(this.r.m != null && n >= 0 && n < this.r.m.length) { + return this.r.m[n]; + } else { + throw haxe_Exception.thrown("EReg::matched"); + } + } + ,matchedRight: function() { + if(this.r.m == null) { + throw haxe_Exception.thrown("No string matched"); + } + var sz = this.r.m.index + this.r.m[0].length; + return HxOverrides.substr(this.r.s,sz,this.r.s.length - sz); + } + ,matchedPos: function() { + if(this.r.m == null) { + throw haxe_Exception.thrown("No string matched"); + } + return { pos : this.r.m.index, len : this.r.m[0].length}; + } + ,split: function(s) { + var d = "#__delim__#"; + return s.replace(this.r,d).split(d); + } +}; +var HxOverrides = function() { }; +HxOverrides.__name__ = true; +HxOverrides.cca = function(s,index) { + var x = s.charCodeAt(index); + if(x != x) { + return undefined; + } + return x; +}; +HxOverrides.substr = function(s,pos,len) { + if(len == null) { + len = s.length; + } else if(len < 0) { + if(pos == 0) { + len = s.length + len; + } else { + return ""; + } + } + return s.substr(pos,len); +}; +HxOverrides.now = function() { + return Date.now(); +}; +Math.__name__ = true; +var Reflect = function() { }; +Reflect.__name__ = true; +Reflect.field = function(o,field) { + try { + return o[field]; + } catch( _g ) { + return null; + } +}; +Reflect.getProperty = function(o,field) { + var tmp; + if(o == null) { + return null; + } else { + var tmp1; + if(o.__properties__) { + tmp = o.__properties__["get_" + field]; + tmp1 = tmp; + } else { + tmp1 = false; + } + if(tmp1) { + return o[tmp](); + } else { + return o[field]; + } + } +}; +Reflect.fields = function(o) { + var a = []; + if(o != null) { + var hasOwnProperty = Object.prototype.hasOwnProperty; + for( var f in o ) { + if(f != "__id__" && f != "hx__closures__" && hasOwnProperty.call(o,f)) { + a.push(f); + } + } + } + return a; +}; +Reflect.isObject = function(v) { + if(v == null) { + return false; + } + var t = typeof(v); + if(!(t == "string" || t == "object" && v.__enum__ == null)) { + if(t == "function") { + return (v.__name__ || v.__ename__) != null; + } else { + return false; + } + } else { + return true; + } +}; +Reflect.deleteField = function(o,field) { + if(!Object.prototype.hasOwnProperty.call(o,field)) { + return false; + } + delete(o[field]); + return true; +}; +Reflect.copy = function(o) { + if(o == null) { + return null; + } + var o2 = { }; + var _g = 0; + var _g1 = Reflect.fields(o); + while(_g < _g1.length) { + var f = _g1[_g]; + ++_g; + o2[f] = Reflect.field(o,f); + } + return o2; +}; +var Std = function() { }; +Std.__name__ = true; +Std.string = function(s) { + return js_Boot.__string_rec(s,""); +}; +Std.parseInt = function(x) { + if(x != null) { + var _g = 0; + var _g1 = x.length; + while(_g < _g1) { + var i = _g++; + var c = x.charCodeAt(i); + if(c <= 8 || c >= 14 && c != 32 && c != 45) { + var nc = x.charCodeAt(i + 1); + var v = parseInt(x,nc == 120 || nc == 88 ? 16 : 10); + if(isNaN(v)) { + return null; + } else { + return v; + } + } + } + } + return null; +}; +var StringBuf = function() { + this.b = ""; +}; +StringBuf.__name__ = true; +var StringTools = function() { }; +StringTools.__name__ = true; +StringTools.isSpace = function(s,pos) { + var c = HxOverrides.cca(s,pos); + if(!(c > 8 && c < 14)) { + return c == 32; + } else { + return true; + } +}; +StringTools.ltrim = function(s) { + var l = s.length; + var r = 0; + while(r < l && StringTools.isSpace(s,r)) ++r; + if(r > 0) { + return HxOverrides.substr(s,r,l - r); + } else { + return s; + } +}; +StringTools.rtrim = function(s) { + var l = s.length; + var r = 0; + while(r < l && StringTools.isSpace(s,l - r - 1)) ++r; + if(r > 0) { + return HxOverrides.substr(s,0,l - r); + } else { + return s; + } +}; +StringTools.trim = function(s) { + return StringTools.ltrim(StringTools.rtrim(s)); +}; +StringTools.replace = function(s,sub,by) { + return s.split(sub).join(by); +}; +var haxe_Exception = function(message,previous,native) { + Error.call(this,message); + this.message = message; + this.__previousException = previous; + this.__nativeException = native != null ? native : this; +}; +haxe_Exception.__name__ = true; +haxe_Exception.caught = function(value) { + if(((value) instanceof haxe_Exception)) { + return value; + } else if(((value) instanceof Error)) { + return new haxe_Exception(value.message,null,value); + } else { + return new haxe_ValueException(value,null,value); + } +}; +haxe_Exception.thrown = function(value) { + if(((value) instanceof haxe_Exception)) { + return value.get_native(); + } else if(((value) instanceof Error)) { + return value; + } else { + var e = new haxe_ValueException(value); + return e; + } +}; +haxe_Exception.__super__ = Error; +haxe_Exception.prototype = $extend(Error.prototype,{ + unwrap: function() { + return this.__nativeException; + } + ,get_native: function() { + return this.__nativeException; + } + ,__properties__: {get_native:"get_native"} +}); +var haxe__$Template_TemplateExpr = $hxEnums["haxe._Template.TemplateExpr"] = { __ename__:true,__constructs__:null + ,OpVar: ($_=function(v) { return {_hx_index:0,v:v,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpVar",$_.__params__ = ["v"],$_) + ,OpExpr: ($_=function(expr) { return {_hx_index:1,expr:expr,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpExpr",$_.__params__ = ["expr"],$_) + ,OpIf: ($_=function(expr,eif,eelse) { return {_hx_index:2,expr:expr,eif:eif,eelse:eelse,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpIf",$_.__params__ = ["expr","eif","eelse"],$_) + ,OpStr: ($_=function(str) { return {_hx_index:3,str:str,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpStr",$_.__params__ = ["str"],$_) + ,OpBlock: ($_=function(l) { return {_hx_index:4,l:l,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpBlock",$_.__params__ = ["l"],$_) + ,OpForeach: ($_=function(expr,loop) { return {_hx_index:5,expr:expr,loop:loop,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpForeach",$_.__params__ = ["expr","loop"],$_) + ,OpMacro: ($_=function(name,params) { return {_hx_index:6,name:name,params:params,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpMacro",$_.__params__ = ["name","params"],$_) +}; +haxe__$Template_TemplateExpr.__constructs__ = [haxe__$Template_TemplateExpr.OpVar,haxe__$Template_TemplateExpr.OpExpr,haxe__$Template_TemplateExpr.OpIf,haxe__$Template_TemplateExpr.OpStr,haxe__$Template_TemplateExpr.OpBlock,haxe__$Template_TemplateExpr.OpForeach,haxe__$Template_TemplateExpr.OpMacro]; +var haxe_iterators_ArrayIterator = function(array) { + this.current = 0; + this.array = array; +}; +haxe_iterators_ArrayIterator.__name__ = true; +haxe_iterators_ArrayIterator.prototype = { + hasNext: function() { + return this.current < this.array.length; + } + ,next: function() { + return this.array[this.current++]; + } +}; +var haxe_Template = function(str) { + var tokens = this.parseTokens(str); + this.expr = this.parseBlock(tokens); + if(!tokens.isEmpty()) { + throw haxe_Exception.thrown("Unexpected '" + Std.string(tokens.first().s) + "'"); + } +}; +haxe_Template.__name__ = true; +haxe_Template.prototype = { + execute: function(context,macros) { + this.macros = macros == null ? { } : macros; + this.context = context; + this.stack = new haxe_ds_List(); + this.buf = new StringBuf(); + this.run(this.expr); + return this.buf.b; + } + ,resolve: function(v) { + if(v == "__current__") { + return this.context; + } + if(Reflect.isObject(this.context)) { + var value = Reflect.getProperty(this.context,v); + if(value != null || Object.prototype.hasOwnProperty.call(this.context,v)) { + return value; + } + } + var _g_head = this.stack.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var ctx = val; + var value = Reflect.getProperty(ctx,v); + if(value != null || Object.prototype.hasOwnProperty.call(ctx,v)) { + return value; + } + } + return Reflect.field(haxe_Template.globals,v); + } + ,parseTokens: function(data) { + var tokens = new haxe_ds_List(); + while(haxe_Template.splitter.match(data)) { + var p = haxe_Template.splitter.matchedPos(); + if(p.pos > 0) { + tokens.add({ p : HxOverrides.substr(data,0,p.pos), s : true, l : null}); + } + if(HxOverrides.cca(data,p.pos) == 58) { + tokens.add({ p : HxOverrides.substr(data,p.pos + 2,p.len - 4), s : false, l : null}); + data = haxe_Template.splitter.matchedRight(); + continue; + } + var parp = p.pos + p.len; + var npar = 1; + var params = []; + var part = ""; + while(true) { + var c = HxOverrides.cca(data,parp); + ++parp; + if(c == 40) { + ++npar; + } else if(c == 41) { + --npar; + if(npar <= 0) { + break; + } + } else if(c == null) { + throw haxe_Exception.thrown("Unclosed macro parenthesis"); + } + if(c == 44 && npar == 1) { + params.push(part); + part = ""; + } else { + part += String.fromCodePoint(c); + } + } + params.push(part); + tokens.add({ p : haxe_Template.splitter.matched(2), s : false, l : params}); + data = HxOverrides.substr(data,parp,data.length - parp); + } + if(data.length > 0) { + tokens.add({ p : data, s : true, l : null}); + } + return tokens; + } + ,parseBlock: function(tokens) { + var l = new haxe_ds_List(); + while(true) { + var t = tokens.first(); + if(t == null) { + break; + } + if(!t.s && (t.p == "end" || t.p == "else" || HxOverrides.substr(t.p,0,7) == "elseif ")) { + break; + } + l.add(this.parse(tokens)); + } + if(l.length == 1) { + return l.first(); + } + return haxe__$Template_TemplateExpr.OpBlock(l); + } + ,parse: function(tokens) { + var t = tokens.pop(); + var p = t.p; + if(t.s) { + return haxe__$Template_TemplateExpr.OpStr(p); + } + if(t.l != null) { + var pe = new haxe_ds_List(); + var _g = 0; + var _g1 = t.l; + while(_g < _g1.length) { + var p1 = _g1[_g]; + ++_g; + pe.add(this.parseBlock(this.parseTokens(p1))); + } + return haxe__$Template_TemplateExpr.OpMacro(p,pe); + } + var kwdEnd = function(kwd) { + var pos = -1; + var length = kwd.length; + if(HxOverrides.substr(p,0,length) == kwd) { + pos = length; + var _g_offset = 0; + var _g_s = HxOverrides.substr(p,length,null); + while(_g_offset < _g_s.length) { + var c = _g_s.charCodeAt(_g_offset++); + if(c == 32) { + ++pos; + } else { + break; + } + } + } + return pos; + }; + var pos = kwdEnd("if"); + if(pos > 0) { + p = HxOverrides.substr(p,pos,p.length - pos); + var e = this.parseExpr(p); + var eif = this.parseBlock(tokens); + var t = tokens.first(); + var eelse; + if(t == null) { + throw haxe_Exception.thrown("Unclosed 'if'"); + } + if(t.p == "end") { + tokens.pop(); + eelse = null; + } else if(t.p == "else") { + tokens.pop(); + eelse = this.parseBlock(tokens); + t = tokens.pop(); + if(t == null || t.p != "end") { + throw haxe_Exception.thrown("Unclosed 'else'"); + } + } else { + t.p = HxOverrides.substr(t.p,4,t.p.length - 4); + eelse = this.parse(tokens); + } + return haxe__$Template_TemplateExpr.OpIf(e,eif,eelse); + } + var pos = kwdEnd("foreach"); + if(pos >= 0) { + p = HxOverrides.substr(p,pos,p.length - pos); + var e = this.parseExpr(p); + var efor = this.parseBlock(tokens); + var t = tokens.pop(); + if(t == null || t.p != "end") { + throw haxe_Exception.thrown("Unclosed 'foreach'"); + } + return haxe__$Template_TemplateExpr.OpForeach(e,efor); + } + if(haxe_Template.expr_splitter.match(p)) { + return haxe__$Template_TemplateExpr.OpExpr(this.parseExpr(p)); + } + return haxe__$Template_TemplateExpr.OpVar(p); + } + ,parseExpr: function(data) { + var l = new haxe_ds_List(); + var expr = data; + while(haxe_Template.expr_splitter.match(data)) { + var p = haxe_Template.expr_splitter.matchedPos(); + var k = p.pos + p.len; + if(p.pos != 0) { + l.add({ p : HxOverrides.substr(data,0,p.pos), s : true}); + } + var p1 = haxe_Template.expr_splitter.matched(0); + l.add({ p : p1, s : p1.indexOf("\"") >= 0}); + data = haxe_Template.expr_splitter.matchedRight(); + } + if(data.length != 0) { + var _g_offset = 0; + var _g_s = data; + while(_g_offset < _g_s.length) { + var _g1_key = _g_offset; + var _g1_value = _g_s.charCodeAt(_g_offset++); + var i = _g1_key; + var c = _g1_value; + if(c != 32) { + l.add({ p : HxOverrides.substr(data,i,null), s : true}); + break; + } + } + } + var e; + try { + e = this.makeExpr(l); + if(!l.isEmpty()) { + throw haxe_Exception.thrown(l.first().p); + } + } catch( _g ) { + var _g1 = haxe_Exception.caught(_g).unwrap(); + if(typeof(_g1) == "string") { + var s = _g1; + throw haxe_Exception.thrown("Unexpected '" + s + "' in " + expr); + } else { + throw _g; + } + } + return function() { + try { + return e(); + } catch( _g ) { + var exc = haxe_Exception.caught(_g).unwrap(); + throw haxe_Exception.thrown("Error : " + Std.string(exc) + " in " + expr); + } + }; + } + ,makeConst: function(v) { + haxe_Template.expr_trim.match(v); + v = haxe_Template.expr_trim.matched(1); + if(HxOverrides.cca(v,0) == 34) { + var str = HxOverrides.substr(v,1,v.length - 2); + return function() { + return str; + }; + } + if(haxe_Template.expr_int.match(v)) { + var i = Std.parseInt(v); + return function() { + return i; + }; + } + if(haxe_Template.expr_float.match(v)) { + var f = parseFloat(v); + return function() { + return f; + }; + } + var me = this; + return function() { + return me.resolve(v); + }; + } + ,makePath: function(e,l) { + var p = l.first(); + if(p == null || p.p != ".") { + return e; + } + l.pop(); + var field = l.pop(); + if(field == null || !field.s) { + throw haxe_Exception.thrown(field.p); + } + var f = field.p; + haxe_Template.expr_trim.match(f); + f = haxe_Template.expr_trim.matched(1); + return this.makePath(function() { + return Reflect.field(e(),f); + },l); + } + ,makeExpr: function(l) { + return this.makePath(this.makeExpr2(l),l); + } + ,skipSpaces: function(l) { + var p = l.first(); + while(p != null) { + var _g_offset = 0; + var _g_s = p.p; + while(_g_offset < _g_s.length) { + var c = _g_s.charCodeAt(_g_offset++); + if(c != 32) { + return; + } + } + l.pop(); + p = l.first(); + } + } + ,makeExpr2: function(l) { + this.skipSpaces(l); + var p = l.pop(); + this.skipSpaces(l); + if(p == null) { + throw haxe_Exception.thrown(""); + } + if(p.s) { + return this.makeConst(p.p); + } + switch(p.p) { + case "!": + var e = this.makeExpr(l); + return function() { + var v = e(); + if(v != null) { + return v == false; + } else { + return true; + } + }; + case "(": + this.skipSpaces(l); + var e1 = this.makeExpr(l); + this.skipSpaces(l); + var p1 = l.pop(); + if(p1 == null || p1.s) { + throw haxe_Exception.thrown(p1); + } + if(p1.p == ")") { + return e1; + } + this.skipSpaces(l); + var e2 = this.makeExpr(l); + this.skipSpaces(l); + var p2 = l.pop(); + this.skipSpaces(l); + if(p2 == null || p2.p != ")") { + throw haxe_Exception.thrown(p2); + } + switch(p1.p) { + case "!=": + return function() { + return e1() != e2(); + }; + case "&&": + return function() { + return e1() && e2(); + }; + case "*": + return function() { + return e1() * e2(); + }; + case "+": + return function() { + return e1() + e2(); + }; + case "-": + return function() { + return e1() - e2(); + }; + case "/": + return function() { + return e1() / e2(); + }; + case "<": + return function() { + return e1() < e2(); + }; + case "<=": + return function() { + return e1() <= e2(); + }; + case "==": + return function() { + return e1() == e2(); + }; + case ">": + return function() { + return e1() > e2(); + }; + case ">=": + return function() { + return e1() >= e2(); + }; + case "||": + return function() { + return e1() || e2(); + }; + default: + throw haxe_Exception.thrown("Unknown operation " + p1.p); + } + break; + case "-": + var e3 = this.makeExpr(l); + return function() { + return -e3(); + }; + } + throw haxe_Exception.thrown(p.p); + } + ,run: function(e) { + switch(e._hx_index) { + case 0: + var v = e.v; + var _this = this.buf; + var x = Std.string(this.resolve(v)); + _this.b += Std.string(x); + break; + case 1: + var e1 = e.expr; + var _this = this.buf; + var x = Std.string(e1()); + _this.b += Std.string(x); + break; + case 2: + var e1 = e.expr; + var eif = e.eif; + var eelse = e.eelse; + var v = e1(); + if(v == null || v == false) { + if(eelse != null) { + this.run(eelse); + } + } else { + this.run(eif); + } + break; + case 3: + var str = e.str; + this.buf.b += str == null ? "null" : "" + str; + break; + case 4: + var l = e.l; + var _g_head = l.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var e1 = val; + this.run(e1); + } + break; + case 5: + var e1 = e.expr; + var loop = e.loop; + var v = e1(); + try { + var x = $getIterator(v); + if(x.hasNext == null) { + throw haxe_Exception.thrown(null); + } + v = x; + } catch( _g ) { + try { + if(v.hasNext == null) { + throw haxe_Exception.thrown(null); + } + } catch( _g1 ) { + throw haxe_Exception.thrown("Cannot iter on " + Std.string(v)); + } + } + this.stack.push(this.context); + var v1 = v; + var ctx = v1; + while(ctx.hasNext()) { + var ctx1 = ctx.next(); + this.context = ctx1; + this.run(loop); + } + this.context = this.stack.pop(); + break; + case 6: + var m = e.name; + var params = e.params; + var v = Reflect.field(this.macros,m); + var pl = []; + var old = this.buf; + pl.push($bind(this,this.resolve)); + var _g_head = params.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var p = val; + if(p._hx_index == 0) { + var v1 = p.v; + pl.push(this.resolve(v1)); + } else { + this.buf = new StringBuf(); + this.run(p); + pl.push(this.buf.b); + } + } + this.buf = old; + try { + var _this = this.buf; + var x = Std.string(v.apply(this.macros,pl)); + _this.b += Std.string(x); + } catch( _g ) { + var e = haxe_Exception.caught(_g).unwrap(); + var plstr; + try { + plstr = pl.join(","); + } catch( _g1 ) { + plstr = "???"; + } + var msg = "Macro call " + m + "(" + plstr + ") failed (" + Std.string(e) + ")"; + throw haxe_Exception.thrown(msg); + } + break; + } + } +}; +var haxe_ValueException = function(value,previous,native) { + haxe_Exception.call(this,String(value),previous,native); + this.value = value; +}; +haxe_ValueException.__name__ = true; +haxe_ValueException.__super__ = haxe_Exception; +haxe_ValueException.prototype = $extend(haxe_Exception.prototype,{ + unwrap: function() { + return this.value; + } +}); +var haxe_ds_List = function() { + this.length = 0; +}; +haxe_ds_List.__name__ = true; +haxe_ds_List.prototype = { + add: function(item) { + var x = new haxe_ds__$List_ListNode(item,null); + if(this.h == null) { + this.h = x; + } else { + this.q.next = x; + } + this.q = x; + this.length++; + } + ,push: function(item) { + var x = new haxe_ds__$List_ListNode(item,this.h); + this.h = x; + if(this.q == null) { + this.q = x; + } + this.length++; + } + ,first: function() { + if(this.h == null) { + return null; + } else { + return this.h.item; + } + } + ,pop: function() { + if(this.h == null) { + return null; + } + var x = this.h.item; + this.h = this.h.next; + if(this.h == null) { + this.q = null; + } + this.length--; + return x; + } + ,isEmpty: function() { + return this.h == null; + } + ,toString: function() { + var s_b = ""; + var first = true; + var l = this.h; + s_b += "{"; + while(l != null) { + if(first) { + first = false; + } else { + s_b += ", "; + } + s_b += Std.string(Std.string(l.item)); + l = l.next; + } + s_b += "}"; + return s_b; + } +}; +var haxe_ds__$List_ListNode = function(item,next) { + this.item = item; + this.next = next; +}; +haxe_ds__$List_ListNode.__name__ = true; +var js_Boot = function() { }; +js_Boot.__name__ = true; +js_Boot.__string_rec = function(o,s) { + if(o == null) { + return "null"; + } + if(s.length >= 5) { + return "<...>"; + } + var t = typeof(o); + if(t == "function" && (o.__name__ || o.__ename__)) { + t = "object"; + } + switch(t) { + case "function": + return ""; + case "object": + if(o.__enum__) { + var e = $hxEnums[o.__enum__]; + var con = e.__constructs__[o._hx_index]; + var n = con._hx_name; + if(con.__params__) { + s = s + "\t"; + return n + "(" + ((function($this) { + var $r; + var _g = []; + { + var _g1 = 0; + var _g2 = con.__params__; + while(true) { + if(!(_g1 < _g2.length)) { + break; + } + var p = _g2[_g1]; + _g1 = _g1 + 1; + _g.push(js_Boot.__string_rec(o[p],s)); + } + } + $r = _g; + return $r; + }(this))).join(",") + ")"; + } else { + return n; + } + } + if(((o) instanceof Array)) { + var str = "["; + s += "\t"; + var _g = 0; + var _g1 = o.length; + while(_g < _g1) { + var i = _g++; + str += (i > 0 ? "," : "") + js_Boot.__string_rec(o[i],s); + } + str += "]"; + return str; + } + var tostr; + try { + tostr = o.toString; + } catch( _g ) { + return "???"; + } + if(tostr != null && tostr != Object.toString && typeof(tostr) == "function") { + var s2 = o.toString(); + if(s2 != "[object Object]") { + return s2; + } + } + var str = "{\n"; + s += "\t"; + var hasp = o.hasOwnProperty != null; + var k = null; + for( k in o ) { + if(hasp && !o.hasOwnProperty(k)) { + continue; + } + if(k == "prototype" || k == "__class__" || k == "__super__" || k == "__interfaces__" || k == "__properties__") { + continue; + } + if(str.length != 2) { + str += ", \n"; + } + str += s + k + " : " + js_Boot.__string_rec(o[k],s); + } + s = s.substring(1); + str += "\n" + s + "}"; + return str; + case "string": + return o; + default: + return String(o); + } +}; +var xrfragment_Filter = $hx_exports["xrfragment"]["Filter"] = function(str) { + this.q = { }; + this.str = ""; + if(str != null) { + this.parse(str); + } +}; +xrfragment_Filter.__name__ = true; +xrfragment_Filter.prototype = { + toObject: function() { + return Reflect.copy(this.q); + } + ,get: function() { + return Reflect.copy(this.q); + } + ,parse: function(str) { + var token = str.split(" "); + var q = { }; + var process = function(str,prefix) { + if(prefix == null) { + prefix = ""; + } + str = StringTools.trim(str); + var k = str.split("=")[0]; + var v = str.split("=")[1]; + var filter = { }; + if(q[prefix + k]) { + filter = q[prefix + k]; + } + if(xrfragment_XRF.isProp.match(str)) { + var oper = ""; + if(str.indexOf(">") != -1) { + oper = ">"; + } + if(str.indexOf("<") != -1) { + oper = "<"; + } + if(xrfragment_XRF.isExclude.match(k)) { + k = HxOverrides.substr(k,1,null); + } + v = HxOverrides.substr(v,oper.length,null); + if(oper.length == 0) { + oper = "="; + } + var rule = { }; + if(xrfragment_XRF.isNumber.match(v)) { + rule[oper] = parseFloat(v); + } else { + rule[oper] = v; + } + q["expr"] = rule; + } + var value = xrfragment_XRF.isDeep.match(str) ? k.split("*").length - 1 : 0; + q["deep"] = value; + var value = xrfragment_XRF.isExclude.match(str) ? false : true; + q["show"] = value; + var value = k.replace(xrfragment_XRF.operators.r,""); + q["key"] = value; + q["value"] = v; + }; + var _g = 0; + var _g1 = token.length; + while(_g < _g1) { + var i = _g++; + process(token[i]); + } + return this.q = q; + } + ,test: function(obj) { + var qualify = false; + var _g = 0; + var _g1 = Reflect.fields(obj); + while(_g < _g1.length) { + var k = _g1[_g]; + ++_g; + var v = Std.string(Reflect.field(obj,k)); + if(this.testProperty(k,v)) { + qualify = true; + } + } + var _g = 0; + var _g1 = Reflect.fields(obj); + while(_g < _g1.length) { + var k = _g1[_g]; + ++_g; + var v = Std.string(Reflect.field(obj,k)); + if(this.testProperty(k,v,true)) { + qualify = false; + } + } + return qualify; + } + ,testProperty: function(property,value,exclude) { + var conds = 0; + var fails = 0; + var qualify = 0; + var testprop = function(expr) { + conds += 1; + fails += expr ? 0 : 1; + return expr; + }; + if(this.q[value] != null) { + var v = this.q[value]; + if(v[property] != null) { + return v[property]; + } + } + if(Reflect.field(this.q,"expr")) { + var f = Reflect.field(this.q,"expr"); + if(!Reflect.field(this.q,"show")) { + if(Reflect.field(f,"!=") != null && testprop((value == null ? "null" : "" + value) == Std.string(Reflect.field(f,"!="))) && exclude) { + ++qualify; + } + } else { + if(Reflect.field(f,"*") != null && testprop(parseFloat(value) != null)) { + ++qualify; + } + if(Reflect.field(f,">") != null && testprop(parseFloat(value) >= parseFloat(Reflect.field(f,">")))) { + ++qualify; + } + if(Reflect.field(f,"<") != null && testprop(parseFloat(value) <= parseFloat(Reflect.field(f,"<")))) { + ++qualify; + } + if(Reflect.field(f,"=") != null && (testprop(value == Reflect.field(f,"=")) || testprop(parseFloat(value) == parseFloat(Reflect.field(f,"="))))) { + ++qualify; + } + } + } + return qualify > 0; + } +}; +var xrfragment_Parser = $hx_exports["xrfragment"]["Parser"] = function() { }; +xrfragment_Parser.__name__ = true; +xrfragment_Parser.parse = function(key,value,store,index) { + var Frag_h = Object.create(null); + Frag_h["#"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_PREDEFINED_VIEW | xrfragment_XRF.PV_EXECUTE; + Frag_h["src"] = xrfragment_XRF.T_URL; + Frag_h["href"] = xrfragment_XRF.T_URL | xrfragment_XRF.T_PREDEFINED_VIEW; + Frag_h["tag"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["pos"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_VECTOR3 | xrfragment_XRF.T_STRING | xrfragment_XRF.METADATA | xrfragment_XRF.NAVIGATOR; + Frag_h["rot"] = xrfragment_XRF.QUERY_OPERATOR | xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_VECTOR3 | xrfragment_XRF.METADATA | xrfragment_XRF.NAVIGATOR; + Frag_h["t"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_FLOAT | xrfragment_XRF.T_VECTOR2 | xrfragment_XRF.NAVIGATOR | xrfragment_XRF.METADATA; + Frag_h["s"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_MEDIAFRAG; + Frag_h["loop"] = xrfragment_XRF.PV_OVERRIDE; + Frag_h["uv"] = xrfragment_XRF.T_VECTOR2 | xrfragment_XRF.T_MEDIAFRAG; + Frag_h["namespace"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["SPDX"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["unit"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["description"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + var keyStripped = key.replace(xrfragment_XRF.operators.r,""); + var isPVDynamic = key.length > 0 && !Object.prototype.hasOwnProperty.call(Frag_h,key); + if(isPVDynamic) { + var v = new xrfragment_XRF(key,xrfragment_XRF.PV_EXECUTE | xrfragment_XRF.NAVIGATOR,index); + v.validate(value); + v.flags = xrfragment_XRF.set(xrfragment_XRF.T_DYNAMICKEY,v.flags); + if(!Object.prototype.hasOwnProperty.call(Frag_h,key)) { + v.flags = xrfragment_XRF.set(xrfragment_XRF.CUSTOMFRAG,v.flags); + } + if(value.length == 0) { + v.flags = xrfragment_XRF.set(xrfragment_XRF.T_DYNAMICKEYVALUE,v.flags); + } + store[keyStripped] = v; + return true; + } + var v = new xrfragment_XRF(key,Frag_h[key],index); + if(Object.prototype.hasOwnProperty.call(Frag_h,key)) { + if(!v.validate(value)) { + console.log("src/xrfragment/Parser.hx:67:","⚠ fragment '" + key + "' has incompatible value (" + value + ")"); + return false; + } + store[keyStripped] = v; + if(xrfragment_Parser.debug) { + console.log("src/xrfragment/Parser.hx:71:","✔ " + key + ": " + v.string); + } + } else { + if(typeof(value) == "string") { + v.guessType(v,value); + } + v.flags = xrfragment_XRF.set(xrfragment_XRF.CUSTOMFRAG,v.flags); + store[keyStripped] = v; + } + return true; +}; +xrfragment_Parser.getMetaData = function() { + var meta = { title : ["title","og:title","dc.title"], description : ["aria-description","og:description","dc.description"], author : ["author","dc.creator"], publisher : ["publisher","dc.publisher"], website : ["og:site_name","og:url","dc.publisher"], license : ["SPDX","dc.rights"]}; + return meta; +}; +var xrfragment_URI = $hx_exports["xrfragment"]["URI"] = function() { }; +xrfragment_URI.__name__ = true; +xrfragment_URI.parse = function(url,filter) { + var store = { }; + if(url == null || url.indexOf("#") == -1) { + return store; + } + var fragment = url.split("#"); + var splitArray = fragment[1].split("&"); + var _g = 0; + var _g1 = splitArray.length; + while(_g < _g1) { + var i = _g++; + var splitByEqual = splitArray[i].split("="); + var regexPlus = new EReg("\\+","g"); + var key = splitByEqual[0]; + var value = ""; + if(splitByEqual.length > 1) { + if(xrfragment_XRF.isVector.match(splitByEqual[1])) { + value = splitByEqual[1]; + } else { + var s = regexPlus.split(splitByEqual[1]).join(" "); + value = decodeURIComponent(s.split("+").join(" ")); + } + } + var ok = xrfragment_Parser.parse(key,value,store,i); + } + if(filter != null && filter != 0) { + var _g = 0; + var _g1 = Reflect.fields(store); + while(_g < _g1.length) { + var key = _g1[_g]; + ++_g; + var xrf = store[key]; + if(!xrf.is(filter)) { + Reflect.deleteField(store,key); + } + } + } + return store; +}; +xrfragment_URI.template = function(uri,vars) { + var parts = uri.split("#"); + if(parts.length == 1) { + return uri; + } + var frag = parts[1]; + frag = StringTools.replace(frag,"{","::"); + frag = StringTools.replace(frag,"}","::"); + frag = new haxe_Template(frag).execute(vars); + frag = StringTools.replace(frag,"null",""); + parts[1] = frag; + return parts.join("#"); +}; +var xrfragment_XRF = $hx_exports["xrfragment"]["XRF"] = function(_fragment,_flags,_index) { + this.floats = []; + this.shift = []; + this.fragment = _fragment; + this.flags = _flags; + this.index = _index; +}; +xrfragment_XRF.__name__ = true; +xrfragment_XRF.set = function(flag,flags) { + return flags | flag; +}; +xrfragment_XRF.unset = function(flag,flags) { + return flags & ~flag; +}; +xrfragment_XRF.prototype = { + is: function(flag) { + var v = this.flags; + if(!(typeof(v) == "number" && ((v | 0) === v))) { + this.flags = 0; + } + return (this.flags & flag) != 0; + } + ,validate: function(value) { + this.guessType(this,value); + var ok = true; + if(!this.is(xrfragment_XRF.T_FLOAT) && this.is(xrfragment_XRF.T_VECTOR2) && !(typeof(this.x) == "number" && typeof(this.y) == "number")) { + ok = false; + } + if(!(this.is(xrfragment_XRF.T_VECTOR2) || this.is(xrfragment_XRF.T_STRING)) && this.is(xrfragment_XRF.T_VECTOR3) && !(typeof(this.x) == "number" && typeof(this.y) == "number" && typeof(this.z) == "number")) { + ok = false; + } + return ok; + } + ,guessType: function(v,str) { + v.string = str; + if(xrfragment_XRF.isReset.match(v.fragment)) { + v.reset = true; + } + if(v.fragment == "loop") { + v.loop = true; + } + if(typeof(str) != "string") { + return; + } + if(str.length > 0) { + if(xrfragment_XRF.isXRFScheme.match(str)) { + v.xrfScheme = true; + str = str.replace(xrfragment_XRF.isXRFScheme.r,""); + v.string = str; + } + if(str.split(",").length > 1) { + var xyzn = str.split(","); + if(xyzn.length > 0) { + v.x = parseFloat(xyzn[0]); + } + if(xyzn.length > 1) { + v.y = parseFloat(xyzn[1]); + } + if(xyzn.length > 2) { + v.z = parseFloat(xyzn[2]); + } + var _g = 0; + var _g1 = xyzn.length; + while(_g < _g1) { + var i = _g++; + v.shift.push(xrfragment_XRF.isShift.match(xyzn[i])); + v.floats.push(parseFloat(xyzn[i].replace(xrfragment_XRF.isShift.r,""))); + } + } + if(xrfragment_XRF.isColor.match(str)) { + v.color = str; + } + if(xrfragment_XRF.isFloat.match(str)) { + v.x = parseFloat(str); + v.float = v.x; + } + if(xrfragment_XRF.isInt.match(str)) { + v.int = Std.parseInt(str); + v.x = v.int; + v.floats.push(v.x); + } + v.filter = new xrfragment_Filter(v.fragment + "=" + v.string); + } else { + v.filter = new xrfragment_Filter(v.fragment); + } + } +}; +function $getIterator(o) { if( o instanceof Array ) return new haxe_iterators_ArrayIterator(o); else return o.iterator(); } +function $bind(o,m) { if( m == null ) return null; if( m.__id__ == null ) m.__id__ = $global.$haxeUID++; var f; if( o.hx__closures__ == null ) o.hx__closures__ = {}; else f = o.hx__closures__[m.__id__]; if( f == null ) { f = m.bind(o); o.hx__closures__[m.__id__] = f; } return f; } +$global.$haxeUID |= 0; +if(typeof(performance) != "undefined" ? typeof(performance.now) == "function" : false) { + HxOverrides.now = performance.now.bind(performance); +} +if( String.fromCodePoint == null ) String.fromCodePoint = function(c) { return c < 0x10000 ? String.fromCharCode(c) : String.fromCharCode((c>>10)+0xD7C0)+String.fromCharCode((c&0x3FF)+0xDC00); } +String.__name__ = true; +Array.__name__ = true; +js_Boot.__toStr = ({ }).toString; +haxe_Template.splitter = new EReg("(::[A-Za-z0-9_ ()&|!+=/><*.\"-]+::|\\$\\$([A-Za-z0-9_-]+)\\()",""); +haxe_Template.expr_splitter = new EReg("(\\(|\\)|[ \r\n\t]*\"[^\"]*\"[ \r\n\t]*|[!+=/><*.&|-]+)",""); +haxe_Template.expr_trim = new EReg("^[ ]*([^ ]+)[ ]*$",""); +haxe_Template.expr_int = new EReg("^[0-9]+$",""); +haxe_Template.expr_float = new EReg("^([+-]?)(?=\\d|,\\d)\\d*(,\\d*)?([Ee]([+-]?\\d+))?$",""); +haxe_Template.globals = { }; +haxe_Template.hxKeepArrayIterator = new haxe_iterators_ArrayIterator([]); +xrfragment_Parser.error = ""; +xrfragment_Parser.debug = false; +xrfragment_URI.__meta__ = { statics : { template : { keep : null}}}; +xrfragment_XRF.IMMUTABLE = 1; +xrfragment_XRF.PROP_BIND = 2; +xrfragment_XRF.QUERY_OPERATOR = 4; +xrfragment_XRF.PROMPT = 8; +xrfragment_XRF.CUSTOMFRAG = 16; +xrfragment_XRF.NAVIGATOR = 32; +xrfragment_XRF.METADATA = 64; +xrfragment_XRF.PV_OVERRIDE = 128; +xrfragment_XRF.PV_EXECUTE = 256; +xrfragment_XRF.T_COLOR = 8192; +xrfragment_XRF.T_INT = 16384; +xrfragment_XRF.T_FLOAT = 32768; +xrfragment_XRF.T_VECTOR2 = 65536; +xrfragment_XRF.T_VECTOR3 = 131072; +xrfragment_XRF.T_URL = 262144; +xrfragment_XRF.T_PREDEFINED_VIEW = 524288; +xrfragment_XRF.T_STRING = 1048576; +xrfragment_XRF.T_MEDIAFRAG = 2097152; +xrfragment_XRF.T_DYNAMICKEY = 4194304; +xrfragment_XRF.T_DYNAMICKEYVALUE = 8388608; +xrfragment_XRF.isColor = new EReg("^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$",""); +xrfragment_XRF.isInt = new EReg("^[-0-9]+$",""); +xrfragment_XRF.isFloat = new EReg("^[-0-9]+\\.[0-9]+$",""); +xrfragment_XRF.isVector = new EReg("([,]+|\\w)",""); +xrfragment_XRF.isUrl = new EReg("(://)?\\..*",""); +xrfragment_XRF.isUrlOrPretypedView = new EReg("(^#|://)?\\..*",""); +xrfragment_XRF.isString = new EReg(".*",""); +xrfragment_XRF.operators = new EReg("(^[-]|^[!]|[\\*]$)","g"); +xrfragment_XRF.isProp = new EReg("^.*=[><=]?",""); +xrfragment_XRF.isExclude = new EReg("^-",""); +xrfragment_XRF.isDeep = new EReg("\\*",""); +xrfragment_XRF.isNumber = new EReg("^[0-9\\.]+$",""); +xrfragment_XRF.isMediaFrag = new EReg("^([0-9\\.,\\*+-]+)$",""); +xrfragment_XRF.isReset = new EReg("^!",""); +xrfragment_XRF.isShift = new EReg("^(\\+|--)",""); +xrfragment_XRF.isXRFScheme = new EReg("^xrf://",""); +})(typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : this); +var xrfragment = $hx_exports["xrfragment"]; +export default xrfragment; +var $hx_exports = typeof exports != "undefined" ? exports : typeof window != "undefined" ? window : typeof self != "undefined" ? self : this; +(function ($global) { "use strict"; +$hx_exports["xrfragment"] = $hx_exports["xrfragment"] || {}; +var $estr = function() { return js_Boot.__string_rec(this,''); },$hxEnums = $hxEnums || {},$_; +function $extend(from, fields) { + var proto = Object.create(from); + for (var name in fields) proto[name] = fields[name]; + if( fields.toString !== Object.prototype.toString ) proto.toString = fields.toString; + return proto; +} +var EReg = function(r,opt) { + this.r = new RegExp(r,opt.split("u").join("")); +}; +EReg.__name__ = true; +EReg.prototype = { + match: function(s) { + if(this.r.global) { + this.r.lastIndex = 0; + } + this.r.m = this.r.exec(s); + this.r.s = s; + return this.r.m != null; + } + ,matched: function(n) { + if(this.r.m != null && n >= 0 && n < this.r.m.length) { + return this.r.m[n]; + } else { + throw haxe_Exception.thrown("EReg::matched"); + } + } + ,matchedRight: function() { + if(this.r.m == null) { + throw haxe_Exception.thrown("No string matched"); + } + var sz = this.r.m.index + this.r.m[0].length; + return HxOverrides.substr(this.r.s,sz,this.r.s.length - sz); + } + ,matchedPos: function() { + if(this.r.m == null) { + throw haxe_Exception.thrown("No string matched"); + } + return { pos : this.r.m.index, len : this.r.m[0].length}; + } + ,split: function(s) { + var d = "#__delim__#"; + return s.replace(this.r,d).split(d); + } +}; +var HxOverrides = function() { }; +HxOverrides.__name__ = true; +HxOverrides.cca = function(s,index) { + var x = s.charCodeAt(index); + if(x != x) { + return undefined; + } + return x; +}; +HxOverrides.substr = function(s,pos,len) { + if(len == null) { + len = s.length; + } else if(len < 0) { + if(pos == 0) { + len = s.length + len; + } else { + return ""; + } + } + return s.substr(pos,len); +}; +HxOverrides.now = function() { + return Date.now(); +}; +Math.__name__ = true; +var Reflect = function() { }; +Reflect.__name__ = true; +Reflect.field = function(o,field) { + try { + return o[field]; + } catch( _g ) { + return null; + } +}; +Reflect.getProperty = function(o,field) { + var tmp; + if(o == null) { + return null; + } else { + var tmp1; + if(o.__properties__) { + tmp = o.__properties__["get_" + field]; + tmp1 = tmp; + } else { + tmp1 = false; + } + if(tmp1) { + return o[tmp](); + } else { + return o[field]; + } + } +}; +Reflect.fields = function(o) { + var a = []; + if(o != null) { + var hasOwnProperty = Object.prototype.hasOwnProperty; + for( var f in o ) { + if(f != "__id__" && f != "hx__closures__" && hasOwnProperty.call(o,f)) { + a.push(f); + } + } + } + return a; +}; +Reflect.isObject = function(v) { + if(v == null) { + return false; + } + var t = typeof(v); + if(!(t == "string" || t == "object" && v.__enum__ == null)) { + if(t == "function") { + return (v.__name__ || v.__ename__) != null; + } else { + return false; + } + } else { + return true; + } +}; +Reflect.deleteField = function(o,field) { + if(!Object.prototype.hasOwnProperty.call(o,field)) { + return false; + } + delete(o[field]); + return true; +}; +Reflect.copy = function(o) { + if(o == null) { + return null; + } + var o2 = { }; + var _g = 0; + var _g1 = Reflect.fields(o); + while(_g < _g1.length) { + var f = _g1[_g]; + ++_g; + o2[f] = Reflect.field(o,f); + } + return o2; +}; +var Std = function() { }; +Std.__name__ = true; +Std.string = function(s) { + return js_Boot.__string_rec(s,""); +}; +Std.parseInt = function(x) { + if(x != null) { + var _g = 0; + var _g1 = x.length; + while(_g < _g1) { + var i = _g++; + var c = x.charCodeAt(i); + if(c <= 8 || c >= 14 && c != 32 && c != 45) { + var nc = x.charCodeAt(i + 1); + var v = parseInt(x,nc == 120 || nc == 88 ? 16 : 10); + if(isNaN(v)) { + return null; + } else { + return v; + } + } + } + } + return null; +}; +var StringBuf = function() { + this.b = ""; +}; +StringBuf.__name__ = true; +var StringTools = function() { }; +StringTools.__name__ = true; +StringTools.isSpace = function(s,pos) { + var c = HxOverrides.cca(s,pos); + if(!(c > 8 && c < 14)) { + return c == 32; + } else { + return true; + } +}; +StringTools.ltrim = function(s) { + var l = s.length; + var r = 0; + while(r < l && StringTools.isSpace(s,r)) ++r; + if(r > 0) { + return HxOverrides.substr(s,r,l - r); + } else { + return s; + } +}; +StringTools.rtrim = function(s) { + var l = s.length; + var r = 0; + while(r < l && StringTools.isSpace(s,l - r - 1)) ++r; + if(r > 0) { + return HxOverrides.substr(s,0,l - r); + } else { + return s; + } +}; +StringTools.trim = function(s) { + return StringTools.ltrim(StringTools.rtrim(s)); +}; +StringTools.replace = function(s,sub,by) { + return s.split(sub).join(by); +}; +var haxe_Exception = function(message,previous,native) { + Error.call(this,message); + this.message = message; + this.__previousException = previous; + this.__nativeException = native != null ? native : this; +}; +haxe_Exception.__name__ = true; +haxe_Exception.caught = function(value) { + if(((value) instanceof haxe_Exception)) { + return value; + } else if(((value) instanceof Error)) { + return new haxe_Exception(value.message,null,value); + } else { + return new haxe_ValueException(value,null,value); + } +}; +haxe_Exception.thrown = function(value) { + if(((value) instanceof haxe_Exception)) { + return value.get_native(); + } else if(((value) instanceof Error)) { + return value; + } else { + var e = new haxe_ValueException(value); + return e; + } +}; +haxe_Exception.__super__ = Error; +haxe_Exception.prototype = $extend(Error.prototype,{ + unwrap: function() { + return this.__nativeException; + } + ,get_native: function() { + return this.__nativeException; + } + ,__properties__: {get_native:"get_native"} +}); +var haxe__$Template_TemplateExpr = $hxEnums["haxe._Template.TemplateExpr"] = { __ename__:true,__constructs__:null + ,OpVar: ($_=function(v) { return {_hx_index:0,v:v,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpVar",$_.__params__ = ["v"],$_) + ,OpExpr: ($_=function(expr) { return {_hx_index:1,expr:expr,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpExpr",$_.__params__ = ["expr"],$_) + ,OpIf: ($_=function(expr,eif,eelse) { return {_hx_index:2,expr:expr,eif:eif,eelse:eelse,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpIf",$_.__params__ = ["expr","eif","eelse"],$_) + ,OpStr: ($_=function(str) { return {_hx_index:3,str:str,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpStr",$_.__params__ = ["str"],$_) + ,OpBlock: ($_=function(l) { return {_hx_index:4,l:l,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpBlock",$_.__params__ = ["l"],$_) + ,OpForeach: ($_=function(expr,loop) { return {_hx_index:5,expr:expr,loop:loop,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpForeach",$_.__params__ = ["expr","loop"],$_) + ,OpMacro: ($_=function(name,params) { return {_hx_index:6,name:name,params:params,__enum__:"haxe._Template.TemplateExpr",toString:$estr}; },$_._hx_name="OpMacro",$_.__params__ = ["name","params"],$_) +}; +haxe__$Template_TemplateExpr.__constructs__ = [haxe__$Template_TemplateExpr.OpVar,haxe__$Template_TemplateExpr.OpExpr,haxe__$Template_TemplateExpr.OpIf,haxe__$Template_TemplateExpr.OpStr,haxe__$Template_TemplateExpr.OpBlock,haxe__$Template_TemplateExpr.OpForeach,haxe__$Template_TemplateExpr.OpMacro]; +var haxe_iterators_ArrayIterator = function(array) { + this.current = 0; + this.array = array; +}; +haxe_iterators_ArrayIterator.__name__ = true; +haxe_iterators_ArrayIterator.prototype = { + hasNext: function() { + return this.current < this.array.length; + } + ,next: function() { + return this.array[this.current++]; + } +}; +var haxe_Template = function(str) { + var tokens = this.parseTokens(str); + this.expr = this.parseBlock(tokens); + if(!tokens.isEmpty()) { + throw haxe_Exception.thrown("Unexpected '" + Std.string(tokens.first().s) + "'"); + } +}; +haxe_Template.__name__ = true; +haxe_Template.prototype = { + execute: function(context,macros) { + this.macros = macros == null ? { } : macros; + this.context = context; + this.stack = new haxe_ds_List(); + this.buf = new StringBuf(); + this.run(this.expr); + return this.buf.b; + } + ,resolve: function(v) { + if(v == "__current__") { + return this.context; + } + if(Reflect.isObject(this.context)) { + var value = Reflect.getProperty(this.context,v); + if(value != null || Object.prototype.hasOwnProperty.call(this.context,v)) { + return value; + } + } + var _g_head = this.stack.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var ctx = val; + var value = Reflect.getProperty(ctx,v); + if(value != null || Object.prototype.hasOwnProperty.call(ctx,v)) { + return value; + } + } + return Reflect.field(haxe_Template.globals,v); + } + ,parseTokens: function(data) { + var tokens = new haxe_ds_List(); + while(haxe_Template.splitter.match(data)) { + var p = haxe_Template.splitter.matchedPos(); + if(p.pos > 0) { + tokens.add({ p : HxOverrides.substr(data,0,p.pos), s : true, l : null}); + } + if(HxOverrides.cca(data,p.pos) == 58) { + tokens.add({ p : HxOverrides.substr(data,p.pos + 2,p.len - 4), s : false, l : null}); + data = haxe_Template.splitter.matchedRight(); + continue; + } + var parp = p.pos + p.len; + var npar = 1; + var params = []; + var part = ""; + while(true) { + var c = HxOverrides.cca(data,parp); + ++parp; + if(c == 40) { + ++npar; + } else if(c == 41) { + --npar; + if(npar <= 0) { + break; + } + } else if(c == null) { + throw haxe_Exception.thrown("Unclosed macro parenthesis"); + } + if(c == 44 && npar == 1) { + params.push(part); + part = ""; + } else { + part += String.fromCodePoint(c); + } + } + params.push(part); + tokens.add({ p : haxe_Template.splitter.matched(2), s : false, l : params}); + data = HxOverrides.substr(data,parp,data.length - parp); + } + if(data.length > 0) { + tokens.add({ p : data, s : true, l : null}); + } + return tokens; + } + ,parseBlock: function(tokens) { + var l = new haxe_ds_List(); + while(true) { + var t = tokens.first(); + if(t == null) { + break; + } + if(!t.s && (t.p == "end" || t.p == "else" || HxOverrides.substr(t.p,0,7) == "elseif ")) { + break; + } + l.add(this.parse(tokens)); + } + if(l.length == 1) { + return l.first(); + } + return haxe__$Template_TemplateExpr.OpBlock(l); + } + ,parse: function(tokens) { + var t = tokens.pop(); + var p = t.p; + if(t.s) { + return haxe__$Template_TemplateExpr.OpStr(p); + } + if(t.l != null) { + var pe = new haxe_ds_List(); + var _g = 0; + var _g1 = t.l; + while(_g < _g1.length) { + var p1 = _g1[_g]; + ++_g; + pe.add(this.parseBlock(this.parseTokens(p1))); + } + return haxe__$Template_TemplateExpr.OpMacro(p,pe); + } + var kwdEnd = function(kwd) { + var pos = -1; + var length = kwd.length; + if(HxOverrides.substr(p,0,length) == kwd) { + pos = length; + var _g_offset = 0; + var _g_s = HxOverrides.substr(p,length,null); + while(_g_offset < _g_s.length) { + var c = _g_s.charCodeAt(_g_offset++); + if(c == 32) { + ++pos; + } else { + break; + } + } + } + return pos; + }; + var pos = kwdEnd("if"); + if(pos > 0) { + p = HxOverrides.substr(p,pos,p.length - pos); + var e = this.parseExpr(p); + var eif = this.parseBlock(tokens); + var t = tokens.first(); + var eelse; + if(t == null) { + throw haxe_Exception.thrown("Unclosed 'if'"); + } + if(t.p == "end") { + tokens.pop(); + eelse = null; + } else if(t.p == "else") { + tokens.pop(); + eelse = this.parseBlock(tokens); + t = tokens.pop(); + if(t == null || t.p != "end") { + throw haxe_Exception.thrown("Unclosed 'else'"); + } + } else { + t.p = HxOverrides.substr(t.p,4,t.p.length - 4); + eelse = this.parse(tokens); + } + return haxe__$Template_TemplateExpr.OpIf(e,eif,eelse); + } + var pos = kwdEnd("foreach"); + if(pos >= 0) { + p = HxOverrides.substr(p,pos,p.length - pos); + var e = this.parseExpr(p); + var efor = this.parseBlock(tokens); + var t = tokens.pop(); + if(t == null || t.p != "end") { + throw haxe_Exception.thrown("Unclosed 'foreach'"); + } + return haxe__$Template_TemplateExpr.OpForeach(e,efor); + } + if(haxe_Template.expr_splitter.match(p)) { + return haxe__$Template_TemplateExpr.OpExpr(this.parseExpr(p)); + } + return haxe__$Template_TemplateExpr.OpVar(p); + } + ,parseExpr: function(data) { + var l = new haxe_ds_List(); + var expr = data; + while(haxe_Template.expr_splitter.match(data)) { + var p = haxe_Template.expr_splitter.matchedPos(); + var k = p.pos + p.len; + if(p.pos != 0) { + l.add({ p : HxOverrides.substr(data,0,p.pos), s : true}); + } + var p1 = haxe_Template.expr_splitter.matched(0); + l.add({ p : p1, s : p1.indexOf("\"") >= 0}); + data = haxe_Template.expr_splitter.matchedRight(); + } + if(data.length != 0) { + var _g_offset = 0; + var _g_s = data; + while(_g_offset < _g_s.length) { + var _g1_key = _g_offset; + var _g1_value = _g_s.charCodeAt(_g_offset++); + var i = _g1_key; + var c = _g1_value; + if(c != 32) { + l.add({ p : HxOverrides.substr(data,i,null), s : true}); + break; + } + } + } + var e; + try { + e = this.makeExpr(l); + if(!l.isEmpty()) { + throw haxe_Exception.thrown(l.first().p); + } + } catch( _g ) { + var _g1 = haxe_Exception.caught(_g).unwrap(); + if(typeof(_g1) == "string") { + var s = _g1; + throw haxe_Exception.thrown("Unexpected '" + s + "' in " + expr); + } else { + throw _g; + } + } + return function() { + try { + return e(); + } catch( _g ) { + var exc = haxe_Exception.caught(_g).unwrap(); + throw haxe_Exception.thrown("Error : " + Std.string(exc) + " in " + expr); + } + }; + } + ,makeConst: function(v) { + haxe_Template.expr_trim.match(v); + v = haxe_Template.expr_trim.matched(1); + if(HxOverrides.cca(v,0) == 34) { + var str = HxOverrides.substr(v,1,v.length - 2); + return function() { + return str; + }; + } + if(haxe_Template.expr_int.match(v)) { + var i = Std.parseInt(v); + return function() { + return i; + }; + } + if(haxe_Template.expr_float.match(v)) { + var f = parseFloat(v); + return function() { + return f; + }; + } + var me = this; + return function() { + return me.resolve(v); + }; + } + ,makePath: function(e,l) { + var p = l.first(); + if(p == null || p.p != ".") { + return e; + } + l.pop(); + var field = l.pop(); + if(field == null || !field.s) { + throw haxe_Exception.thrown(field.p); + } + var f = field.p; + haxe_Template.expr_trim.match(f); + f = haxe_Template.expr_trim.matched(1); + return this.makePath(function() { + return Reflect.field(e(),f); + },l); + } + ,makeExpr: function(l) { + return this.makePath(this.makeExpr2(l),l); + } + ,skipSpaces: function(l) { + var p = l.first(); + while(p != null) { + var _g_offset = 0; + var _g_s = p.p; + while(_g_offset < _g_s.length) { + var c = _g_s.charCodeAt(_g_offset++); + if(c != 32) { + return; + } + } + l.pop(); + p = l.first(); + } + } + ,makeExpr2: function(l) { + this.skipSpaces(l); + var p = l.pop(); + this.skipSpaces(l); + if(p == null) { + throw haxe_Exception.thrown(""); + } + if(p.s) { + return this.makeConst(p.p); + } + switch(p.p) { + case "!": + var e = this.makeExpr(l); + return function() { + var v = e(); + if(v != null) { + return v == false; + } else { + return true; + } + }; + case "(": + this.skipSpaces(l); + var e1 = this.makeExpr(l); + this.skipSpaces(l); + var p1 = l.pop(); + if(p1 == null || p1.s) { + throw haxe_Exception.thrown(p1); + } + if(p1.p == ")") { + return e1; + } + this.skipSpaces(l); + var e2 = this.makeExpr(l); + this.skipSpaces(l); + var p2 = l.pop(); + this.skipSpaces(l); + if(p2 == null || p2.p != ")") { + throw haxe_Exception.thrown(p2); + } + switch(p1.p) { + case "!=": + return function() { + return e1() != e2(); + }; + case "&&": + return function() { + return e1() && e2(); + }; + case "*": + return function() { + return e1() * e2(); + }; + case "+": + return function() { + return e1() + e2(); + }; + case "-": + return function() { + return e1() - e2(); + }; + case "/": + return function() { + return e1() / e2(); + }; + case "<": + return function() { + return e1() < e2(); + }; + case "<=": + return function() { + return e1() <= e2(); + }; + case "==": + return function() { + return e1() == e2(); + }; + case ">": + return function() { + return e1() > e2(); + }; + case ">=": + return function() { + return e1() >= e2(); + }; + case "||": + return function() { + return e1() || e2(); + }; + default: + throw haxe_Exception.thrown("Unknown operation " + p1.p); + } + break; + case "-": + var e3 = this.makeExpr(l); + return function() { + return -e3(); + }; + } + throw haxe_Exception.thrown(p.p); + } + ,run: function(e) { + switch(e._hx_index) { + case 0: + var v = e.v; + var _this = this.buf; + var x = Std.string(this.resolve(v)); + _this.b += Std.string(x); + break; + case 1: + var e1 = e.expr; + var _this = this.buf; + var x = Std.string(e1()); + _this.b += Std.string(x); + break; + case 2: + var e1 = e.expr; + var eif = e.eif; + var eelse = e.eelse; + var v = e1(); + if(v == null || v == false) { + if(eelse != null) { + this.run(eelse); + } + } else { + this.run(eif); + } + break; + case 3: + var str = e.str; + this.buf.b += str == null ? "null" : "" + str; + break; + case 4: + var l = e.l; + var _g_head = l.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var e1 = val; + this.run(e1); + } + break; + case 5: + var e1 = e.expr; + var loop = e.loop; + var v = e1(); + try { + var x = $getIterator(v); + if(x.hasNext == null) { + throw haxe_Exception.thrown(null); + } + v = x; + } catch( _g ) { + try { + if(v.hasNext == null) { + throw haxe_Exception.thrown(null); + } + } catch( _g1 ) { + throw haxe_Exception.thrown("Cannot iter on " + Std.string(v)); + } + } + this.stack.push(this.context); + var v1 = v; + var ctx = v1; + while(ctx.hasNext()) { + var ctx1 = ctx.next(); + this.context = ctx1; + this.run(loop); + } + this.context = this.stack.pop(); + break; + case 6: + var m = e.name; + var params = e.params; + var v = Reflect.field(this.macros,m); + var pl = []; + var old = this.buf; + pl.push($bind(this,this.resolve)); + var _g_head = params.h; + while(_g_head != null) { + var val = _g_head.item; + _g_head = _g_head.next; + var p = val; + if(p._hx_index == 0) { + var v1 = p.v; + pl.push(this.resolve(v1)); + } else { + this.buf = new StringBuf(); + this.run(p); + pl.push(this.buf.b); + } + } + this.buf = old; + try { + var _this = this.buf; + var x = Std.string(v.apply(this.macros,pl)); + _this.b += Std.string(x); + } catch( _g ) { + var e = haxe_Exception.caught(_g).unwrap(); + var plstr; + try { + plstr = pl.join(","); + } catch( _g1 ) { + plstr = "???"; + } + var msg = "Macro call " + m + "(" + plstr + ") failed (" + Std.string(e) + ")"; + throw haxe_Exception.thrown(msg); + } + break; + } + } +}; +var haxe_ValueException = function(value,previous,native) { + haxe_Exception.call(this,String(value),previous,native); + this.value = value; +}; +haxe_ValueException.__name__ = true; +haxe_ValueException.__super__ = haxe_Exception; +haxe_ValueException.prototype = $extend(haxe_Exception.prototype,{ + unwrap: function() { + return this.value; + } +}); +var haxe_ds_List = function() { + this.length = 0; +}; +haxe_ds_List.__name__ = true; +haxe_ds_List.prototype = { + add: function(item) { + var x = new haxe_ds__$List_ListNode(item,null); + if(this.h == null) { + this.h = x; + } else { + this.q.next = x; + } + this.q = x; + this.length++; + } + ,push: function(item) { + var x = new haxe_ds__$List_ListNode(item,this.h); + this.h = x; + if(this.q == null) { + this.q = x; + } + this.length++; + } + ,first: function() { + if(this.h == null) { + return null; + } else { + return this.h.item; + } + } + ,pop: function() { + if(this.h == null) { + return null; + } + var x = this.h.item; + this.h = this.h.next; + if(this.h == null) { + this.q = null; + } + this.length--; + return x; + } + ,isEmpty: function() { + return this.h == null; + } + ,toString: function() { + var s_b = ""; + var first = true; + var l = this.h; + s_b += "{"; + while(l != null) { + if(first) { + first = false; + } else { + s_b += ", "; + } + s_b += Std.string(Std.string(l.item)); + l = l.next; + } + s_b += "}"; + return s_b; + } +}; +var haxe_ds__$List_ListNode = function(item,next) { + this.item = item; + this.next = next; +}; +haxe_ds__$List_ListNode.__name__ = true; +var js_Boot = function() { }; +js_Boot.__name__ = true; +js_Boot.__string_rec = function(o,s) { + if(o == null) { + return "null"; + } + if(s.length >= 5) { + return "<...>"; + } + var t = typeof(o); + if(t == "function" && (o.__name__ || o.__ename__)) { + t = "object"; + } + switch(t) { + case "function": + return ""; + case "object": + if(o.__enum__) { + var e = $hxEnums[o.__enum__]; + var con = e.__constructs__[o._hx_index]; + var n = con._hx_name; + if(con.__params__) { + s = s + "\t"; + return n + "(" + ((function($this) { + var $r; + var _g = []; + { + var _g1 = 0; + var _g2 = con.__params__; + while(true) { + if(!(_g1 < _g2.length)) { + break; + } + var p = _g2[_g1]; + _g1 = _g1 + 1; + _g.push(js_Boot.__string_rec(o[p],s)); + } + } + $r = _g; + return $r; + }(this))).join(",") + ")"; + } else { + return n; + } + } + if(((o) instanceof Array)) { + var str = "["; + s += "\t"; + var _g = 0; + var _g1 = o.length; + while(_g < _g1) { + var i = _g++; + str += (i > 0 ? "," : "") + js_Boot.__string_rec(o[i],s); + } + str += "]"; + return str; + } + var tostr; + try { + tostr = o.toString; + } catch( _g ) { + return "???"; + } + if(tostr != null && tostr != Object.toString && typeof(tostr) == "function") { + var s2 = o.toString(); + if(s2 != "[object Object]") { + return s2; + } + } + var str = "{\n"; + s += "\t"; + var hasp = o.hasOwnProperty != null; + var k = null; + for( k in o ) { + if(hasp && !o.hasOwnProperty(k)) { + continue; + } + if(k == "prototype" || k == "__class__" || k == "__super__" || k == "__interfaces__" || k == "__properties__") { + continue; + } + if(str.length != 2) { + str += ", \n"; + } + str += s + k + " : " + js_Boot.__string_rec(o[k],s); + } + s = s.substring(1); + str += "\n" + s + "}"; + return str; + case "string": + return o; + default: + return String(o); + } +}; +var xrfragment_Filter = $hx_exports["xrfragment"]["Filter"] = function(str) { + this.q = { }; + this.str = ""; + if(str != null) { + this.parse(str); + } +}; +xrfragment_Filter.__name__ = true; +xrfragment_Filter.prototype = { + toObject: function() { + return Reflect.copy(this.q); + } + ,get: function() { + return Reflect.copy(this.q); + } + ,parse: function(str) { + var token = str.split(" "); + var q = { }; + var process = function(str,prefix) { + if(prefix == null) { + prefix = ""; + } + str = StringTools.trim(str); + var k = str.split("=")[0]; + var v = str.split("=")[1]; + var filter = { }; + if(q[prefix + k]) { + filter = q[prefix + k]; + } + if(xrfragment_XRF.isProp.match(str)) { + var oper = ""; + if(str.indexOf(">") != -1) { + oper = ">"; + } + if(str.indexOf("<") != -1) { + oper = "<"; + } + if(xrfragment_XRF.isExclude.match(k)) { + k = HxOverrides.substr(k,1,null); + } + v = HxOverrides.substr(v,oper.length,null); + if(oper.length == 0) { + oper = "="; + } + var rule = { }; + if(xrfragment_XRF.isNumber.match(v)) { + rule[oper] = parseFloat(v); + } else { + rule[oper] = v; + } + q["expr"] = rule; + } + var value = xrfragment_XRF.isDeep.match(str) ? k.split("*").length - 1 : 0; + q["deep"] = value; + var value = xrfragment_XRF.isExclude.match(str) ? false : true; + q["show"] = value; + var value = k.replace(xrfragment_XRF.operators.r,""); + q["key"] = value; + q["value"] = v; + }; + var _g = 0; + var _g1 = token.length; + while(_g < _g1) { + var i = _g++; + process(token[i]); + } + return this.q = q; + } + ,test: function(obj) { + var qualify = false; + var _g = 0; + var _g1 = Reflect.fields(obj); + while(_g < _g1.length) { + var k = _g1[_g]; + ++_g; + var v = Std.string(Reflect.field(obj,k)); + if(this.testProperty(k,v)) { + qualify = true; + } + } + var _g = 0; + var _g1 = Reflect.fields(obj); + while(_g < _g1.length) { + var k = _g1[_g]; + ++_g; + var v = Std.string(Reflect.field(obj,k)); + if(this.testProperty(k,v,true)) { + qualify = false; + } + } + return qualify; + } + ,testProperty: function(property,value,exclude) { + var conds = 0; + var fails = 0; + var qualify = 0; + var testprop = function(expr) { + conds += 1; + fails += expr ? 0 : 1; + return expr; + }; + if(this.q[value] != null) { + var v = this.q[value]; + if(v[property] != null) { + return v[property]; + } + } + if(Reflect.field(this.q,"expr")) { + var f = Reflect.field(this.q,"expr"); + if(!Reflect.field(this.q,"show")) { + if(Reflect.field(f,"!=") != null && testprop((value == null ? "null" : "" + value) == Std.string(Reflect.field(f,"!="))) && exclude) { + ++qualify; + } + } else { + if(Reflect.field(f,"*") != null && testprop(parseFloat(value) != null)) { + ++qualify; + } + if(Reflect.field(f,">") != null && testprop(parseFloat(value) >= parseFloat(Reflect.field(f,">")))) { + ++qualify; + } + if(Reflect.field(f,"<") != null && testprop(parseFloat(value) <= parseFloat(Reflect.field(f,"<")))) { + ++qualify; + } + if(Reflect.field(f,"=") != null && (testprop(value == Reflect.field(f,"=")) || testprop(parseFloat(value) == parseFloat(Reflect.field(f,"="))))) { + ++qualify; + } + } + } + return qualify > 0; + } +}; +var xrfragment_Parser = $hx_exports["xrfragment"]["Parser"] = function() { }; +xrfragment_Parser.__name__ = true; +xrfragment_Parser.parse = function(key,value,store,index) { + var Frag_h = Object.create(null); + Frag_h["#"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_PREDEFINED_VIEW | xrfragment_XRF.PV_EXECUTE; + Frag_h["src"] = xrfragment_XRF.T_URL; + Frag_h["href"] = xrfragment_XRF.T_URL | xrfragment_XRF.T_PREDEFINED_VIEW; + Frag_h["tag"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["pos"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_VECTOR3 | xrfragment_XRF.T_STRING | xrfragment_XRF.METADATA | xrfragment_XRF.NAVIGATOR; + Frag_h["rot"] = xrfragment_XRF.QUERY_OPERATOR | xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_VECTOR3 | xrfragment_XRF.METADATA | xrfragment_XRF.NAVIGATOR; + Frag_h["t"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_FLOAT | xrfragment_XRF.T_VECTOR2 | xrfragment_XRF.NAVIGATOR | xrfragment_XRF.METADATA; + Frag_h["s"] = xrfragment_XRF.PV_OVERRIDE | xrfragment_XRF.T_MEDIAFRAG; + Frag_h["loop"] = xrfragment_XRF.PV_OVERRIDE; + Frag_h["uv"] = xrfragment_XRF.T_VECTOR2 | xrfragment_XRF.T_MEDIAFRAG; + Frag_h["namespace"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["SPDX"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["unit"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + Frag_h["description"] = xrfragment_XRF.IMMUTABLE | xrfragment_XRF.T_STRING; + var keyStripped = key.replace(xrfragment_XRF.operators.r,""); + var isPVDynamic = key.length > 0 && !Object.prototype.hasOwnProperty.call(Frag_h,key); + if(isPVDynamic) { + var v = new xrfragment_XRF(key,xrfragment_XRF.PV_EXECUTE | xrfragment_XRF.NAVIGATOR,index); + v.validate(value); + v.flags = xrfragment_XRF.set(xrfragment_XRF.T_DYNAMICKEY,v.flags); + if(!Object.prototype.hasOwnProperty.call(Frag_h,key)) { + v.flags = xrfragment_XRF.set(xrfragment_XRF.CUSTOMFRAG,v.flags); + } + if(value.length == 0) { + v.flags = xrfragment_XRF.set(xrfragment_XRF.T_DYNAMICKEYVALUE,v.flags); + } + store[keyStripped] = v; + return true; + } + var v = new xrfragment_XRF(key,Frag_h[key],index); + if(Object.prototype.hasOwnProperty.call(Frag_h,key)) { + if(!v.validate(value)) { + console.log("src/xrfragment/Parser.hx:67:","⚠ fragment '" + key + "' has incompatible value (" + value + ")"); + return false; + } + store[keyStripped] = v; + if(xrfragment_Parser.debug) { + console.log("src/xrfragment/Parser.hx:71:","✔ " + key + ": " + v.string); + } + } else { + if(typeof(value) == "string") { + v.guessType(v,value); + } + v.flags = xrfragment_XRF.set(xrfragment_XRF.CUSTOMFRAG,v.flags); + store[keyStripped] = v; + } + return true; +}; +xrfragment_Parser.getMetaData = function() { + var meta = { title : ["title","og:title","dc.title"], description : ["aria-description","og:description","dc.description"], author : ["author","dc.creator"], publisher : ["publisher","dc.publisher"], website : ["og:site_name","og:url","dc.publisher"], license : ["SPDX","dc.rights"]}; + return meta; +}; +var xrfragment_URI = $hx_exports["xrfragment"]["URI"] = function() { }; +xrfragment_URI.__name__ = true; +xrfragment_URI.parse = function(url,filter) { + var store = { }; + if(url == null || url.indexOf("#") == -1) { + return store; + } + var fragment = url.split("#"); + var splitArray = fragment[1].split("&"); + var _g = 0; + var _g1 = splitArray.length; + while(_g < _g1) { + var i = _g++; + var splitByEqual = splitArray[i].split("="); + var regexPlus = new EReg("\\+","g"); + var key = splitByEqual[0]; + var value = ""; + if(splitByEqual.length > 1) { + if(xrfragment_XRF.isVector.match(splitByEqual[1])) { + value = splitByEqual[1]; + } else { + var s = regexPlus.split(splitByEqual[1]).join(" "); + value = decodeURIComponent(s.split("+").join(" ")); + } + } + var ok = xrfragment_Parser.parse(key,value,store,i); + } + if(filter != null && filter != 0) { + var _g = 0; + var _g1 = Reflect.fields(store); + while(_g < _g1.length) { + var key = _g1[_g]; + ++_g; + var xrf = store[key]; + if(!xrf.is(filter)) { + Reflect.deleteField(store,key); + } + } + } + return store; +}; +xrfragment_URI.template = function(uri,vars) { + var parts = uri.split("#"); + if(parts.length == 1) { + return uri; + } + var frag = parts[1]; + frag = StringTools.replace(frag,"{","::"); + frag = StringTools.replace(frag,"}","::"); + frag = new haxe_Template(frag).execute(vars); + frag = StringTools.replace(frag,"null",""); + parts[1] = frag; + return parts.join("#"); +}; +var xrfragment_XRF = $hx_exports["xrfragment"]["XRF"] = function(_fragment,_flags,_index) { + this.floats = []; + this.shift = []; + this.fragment = _fragment; + this.flags = _flags; + this.index = _index; +}; +xrfragment_XRF.__name__ = true; +xrfragment_XRF.set = function(flag,flags) { + return flags | flag; +}; +xrfragment_XRF.unset = function(flag,flags) { + return flags & ~flag; +}; +xrfragment_XRF.prototype = { + is: function(flag) { + var v = this.flags; + if(!(typeof(v) == "number" && ((v | 0) === v))) { + this.flags = 0; + } + return (this.flags & flag) != 0; + } + ,validate: function(value) { + this.guessType(this,value); + var ok = true; + if(!this.is(xrfragment_XRF.T_FLOAT) && this.is(xrfragment_XRF.T_VECTOR2) && !(typeof(this.x) == "number" && typeof(this.y) == "number")) { + ok = false; + } + if(!(this.is(xrfragment_XRF.T_VECTOR2) || this.is(xrfragment_XRF.T_STRING)) && this.is(xrfragment_XRF.T_VECTOR3) && !(typeof(this.x) == "number" && typeof(this.y) == "number" && typeof(this.z) == "number")) { + ok = false; + } + return ok; + } + ,guessType: function(v,str) { + v.string = str; + if(xrfragment_XRF.isReset.match(v.fragment)) { + v.reset = true; + } + if(v.fragment == "loop") { + v.loop = true; + } + if(typeof(str) != "string") { + return; + } + if(str.length > 0) { + if(xrfragment_XRF.isXRFScheme.match(str)) { + v.xrfScheme = true; + str = str.replace(xrfragment_XRF.isXRFScheme.r,""); + v.string = str; + } + if(str.split(",").length > 1) { + var xyzn = str.split(","); + if(xyzn.length > 0) { + v.x = parseFloat(xyzn[0]); + } + if(xyzn.length > 1) { + v.y = parseFloat(xyzn[1]); + } + if(xyzn.length > 2) { + v.z = parseFloat(xyzn[2]); + } + var _g = 0; + var _g1 = xyzn.length; + while(_g < _g1) { + var i = _g++; + v.shift.push(xrfragment_XRF.isShift.match(xyzn[i])); + v.floats.push(parseFloat(xyzn[i].replace(xrfragment_XRF.isShift.r,""))); + } + } + if(xrfragment_XRF.isColor.match(str)) { + v.color = str; + } + if(xrfragment_XRF.isFloat.match(str)) { + v.x = parseFloat(str); + v.float = v.x; + } + if(xrfragment_XRF.isInt.match(str)) { + v.int = Std.parseInt(str); + v.x = v.int; + v.floats.push(v.x); + } + v.filter = new xrfragment_Filter(v.fragment + "=" + v.string); + } else { + v.filter = new xrfragment_Filter(v.fragment); + } + } +}; +function $getIterator(o) { if( o instanceof Array ) return new haxe_iterators_ArrayIterator(o); else return o.iterator(); } +function $bind(o,m) { if( m == null ) return null; if( m.__id__ == null ) m.__id__ = $global.$haxeUID++; var f; if( o.hx__closures__ == null ) o.hx__closures__ = {}; else f = o.hx__closures__[m.__id__]; if( f == null ) { f = m.bind(o); o.hx__closures__[m.__id__] = f; } return f; } +$global.$haxeUID |= 0; +if(typeof(performance) != "undefined" ? typeof(performance.now) == "function" : false) { + HxOverrides.now = performance.now.bind(performance); +} +if( String.fromCodePoint == null ) String.fromCodePoint = function(c) { return c < 0x10000 ? String.fromCharCode(c) : String.fromCharCode((c>>10)+0xD7C0)+String.fromCharCode((c&0x3FF)+0xDC00); } +String.__name__ = true; +Array.__name__ = true; +js_Boot.__toStr = ({ }).toString; +haxe_Template.splitter = new EReg("(::[A-Za-z0-9_ ()&|!+=/><*.\"-]+::|\\$\\$([A-Za-z0-9_-]+)\\()",""); +haxe_Template.expr_splitter = new EReg("(\\(|\\)|[ \r\n\t]*\"[^\"]*\"[ \r\n\t]*|[!+=/><*.&|-]+)",""); +haxe_Template.expr_trim = new EReg("^[ ]*([^ ]+)[ ]*$",""); +haxe_Template.expr_int = new EReg("^[0-9]+$",""); +haxe_Template.expr_float = new EReg("^([+-]?)(?=\\d|,\\d)\\d*(,\\d*)?([Ee]([+-]?\\d+))?$",""); +haxe_Template.globals = { }; +haxe_Template.hxKeepArrayIterator = new haxe_iterators_ArrayIterator([]); +xrfragment_Parser.error = ""; +xrfragment_Parser.debug = false; +xrfragment_URI.__meta__ = { statics : { template : { keep : null}}}; +xrfragment_XRF.IMMUTABLE = 1; +xrfragment_XRF.PROP_BIND = 2; +xrfragment_XRF.QUERY_OPERATOR = 4; +xrfragment_XRF.PROMPT = 8; +xrfragment_XRF.CUSTOMFRAG = 16; +xrfragment_XRF.NAVIGATOR = 32; +xrfragment_XRF.METADATA = 64; +xrfragment_XRF.PV_OVERRIDE = 128; +xrfragment_XRF.PV_EXECUTE = 256; +xrfragment_XRF.T_COLOR = 8192; +xrfragment_XRF.T_INT = 16384; +xrfragment_XRF.T_FLOAT = 32768; +xrfragment_XRF.T_VECTOR2 = 65536; +xrfragment_XRF.T_VECTOR3 = 131072; +xrfragment_XRF.T_URL = 262144; +xrfragment_XRF.T_PREDEFINED_VIEW = 524288; +xrfragment_XRF.T_STRING = 1048576; +xrfragment_XRF.T_MEDIAFRAG = 2097152; +xrfragment_XRF.T_DYNAMICKEY = 4194304; +xrfragment_XRF.T_DYNAMICKEYVALUE = 8388608; +xrfragment_XRF.isColor = new EReg("^#([A-Fa-f0-9]{6}|[A-Fa-f0-9]{3})$",""); +xrfragment_XRF.isInt = new EReg("^[-0-9]+$",""); +xrfragment_XRF.isFloat = new EReg("^[-0-9]+\\.[0-9]+$",""); +xrfragment_XRF.isVector = new EReg("([,]+|\\w)",""); +xrfragment_XRF.isUrl = new EReg("(://)?\\..*",""); +xrfragment_XRF.isUrlOrPretypedView = new EReg("(^#|://)?\\..*",""); +xrfragment_XRF.isString = new EReg(".*",""); +xrfragment_XRF.operators = new EReg("(^[-]|^[!]|[\\*]$)","g"); +xrfragment_XRF.isProp = new EReg("^.*=[><=]?",""); +xrfragment_XRF.isExclude = new EReg("^-",""); +xrfragment_XRF.isDeep = new EReg("\\*",""); +xrfragment_XRF.isNumber = new EReg("^[0-9\\.]+$",""); +xrfragment_XRF.isMediaFrag = new EReg("^([0-9\\.,\\*+-]+)$",""); +xrfragment_XRF.isReset = new EReg("^!",""); +xrfragment_XRF.isShift = new EReg("^(\\+|--)",""); +xrfragment_XRF.isXRFScheme = new EReg("^xrf://",""); +})(typeof window != "undefined" ? window : typeof global != "undefined" ? global : typeof self != "undefined" ? self : this); +var xrfragment = $hx_exports["xrfragment"]; +export default xrfragment; diff --git a/dist/xrfragment.plugin.frontend.js b/dist/xrfragment.plugin.frontend.js index cdfc07f..d0bd18d 100644 --- a/dist/xrfragment.plugin.frontend.js +++ b/dist/xrfragment.plugin.frontend.js @@ -1738,7 +1738,7 @@ window.frontend = (opts) => new Proxy({ - + `, el: null, @@ -1824,10 +1824,10 @@ window.frontend = (opts) => new Proxy({ },2000 ) xrf.addEventListener('href', (data) => { - if( !data.selected ) return + if( !data.selected ) return let html = `${data.mesh.isSRC && !data.mesh.portal ? 'src' : 'href'}${ data.xrf ? data.xrf.string : data.mesh.userData.src}
` - let metadata = data.mesh.userData + let metadata = data.mesh.userData let meta = xrf.Parser.getMetaData() let hasMeta = false @@ -1863,18 +1863,18 @@ window.frontend = (opts) => new Proxy({ document.addEventListener('network.connect', (e) => { console.log("network.connect") - window.notify("🪐 connecting to awesomeness..") + window.notify("🪐 connecting to awesomeness..") $chat.send({message:`🪐 connecting to awesomeness..`,class:['info'], timeout:5000}) }) document.addEventListener('network.connected', (e) => { - window.notify("🪐 connected to awesomeness..") + window.notify("🪐 connected to awesomeness..") $chat.visibleChatbar = true $chat.send({message:`🎉 ${e.detail.plugin.profile.name||''} connected!`,class:['info'], timeout:5000}) }) document.addEventListener('network.disconnect', () => { - window.notify("🪐 disconnecting..") + window.notify("🪐 disconnecting..") }) document.addEventListener('network.info', (e) => { @@ -1908,7 +1908,7 @@ window.frontend = (opts) => new Proxy({ if( show ){ $chat.visible = true }else{ - $chat.visible = false + $chat.visible = false $menu.toggle(false) } return true @@ -1928,7 +1928,7 @@ window.frontend = (opts) => new Proxy({ input.accept = Object.keys(contentLoaders).join(","); input.onchange = () => { let files = Array.from(input.files); - let file = files.slice ? files[0] : files + let file = files.slice ? files[0] : files for( var i in contentLoaders ){ let r = new RegExp('\\'+i+'$') if( file.name.match(r) ) return contentLoaders[i](file) @@ -1942,12 +1942,12 @@ window.frontend = (opts) => new Proxy({ notify(_str,opts){ if( window.outerWidth < 800 ) return if( window.accessibility && window.accessibility.enabled ) return $chat.send({message:_str,class:['info']}) - opts = opts || {status:'info'} + opts = opts || {status:'info'} opts = Object.assign({ status, timeout:4000 },opts) opts.message = _str if( typeof str == 'string' ){ - str = _str.replace(/(^\w+):/,"
\$1
") - if( !opts.status ){ + str = _str.replace(/(^\w+):/,"
\$1
") + if( !opts.status ){ if( str.match(/error/g) ) opts.status = "danger" if( str.match(/warning/g) ) opts.status = "warning" } @@ -1972,7 +1972,7 @@ window.frontend = (opts) => new Proxy({ updateHashPosition(randomize){ // *TODO* this should be part of the XRF Threejs framework - if( typeof THREE == 'undefined' ) THREE = xrf.THREE + if( typeof THREE == 'undefined' ) THREE = xrf.THREE let radToDeg = THREE.MathUtils.radToDeg let toDeg = (x) => x / (Math.PI / 180) let camera = document.querySelector('[camera]').object3D.parent // *TODO* fix for threejs @@ -1996,13 +1996,13 @@ window.frontend = (opts) => new Proxy({ }, copyToClipboard(text){ - // copy url to clipboard + // copy url to clipboard var dummy = document.createElement('input') document.body.appendChild(dummy); dummy.value = text; dummy.select(); document.execCommand('copy'); - document.body.removeChild(dummy); + document.body.removeChild(dummy); }, share(opts){ @@ -2014,9 +2014,9 @@ window.frontend = (opts) => new Proxy({ document.location.hash += `&pos=${ network.posName || network.pos }` } let url = window.location.href - if( opts.linkonly ) return url + if( opts.linkonly ) return url this.copyToClipboard( url ) - // End of *TODO* + // End of *TODO* if( opts.notify ){ window.notify(`

${ network.connected ? 'Meeting link ' : 'Link'} copied to clipboard!

Now share it with your friends ❤️
@@ -2045,12 +2045,12 @@ window.frontend = (opts) => new Proxy({ title: 'your meeting link' }) } - $menu.collapse = true + $menu.collapse = true } }, -{ - // auto-trigger events on changes +{ + // auto-trigger events on changes get(me,k,receiver){ return me[k] }, set(me,k,v){ let from = me[k] @@ -2061,7 +2061,7 @@ window.frontend = (opts) => new Proxy({ } } }) - + frontend = frontend({xrf,document}).init() // this orchestrates multiplayer events from the scene graph diff --git a/dist/xrfragment.three.js b/dist/xrfragment.three.js index 0d0096f..a4653e6 100644 --- a/dist/xrfragment.three.js +++ b/dist/xrfragment.three.js @@ -1,5 +1,5 @@ /* - * v0.5.1 generated at Thu Feb 29 01:34:17 PM UTC 2024 + * v0.5.1 generated at Thu Feb 29 01:43:17 PM UTC 2024 * https://xrfragment.org * SPDX-License-Identifier: MPL-2.0 */ diff --git a/dist/xrfragment.three.module.js b/dist/xrfragment.three.module.js index 901925e..14c7196 100644 --- a/dist/xrfragment.three.module.js +++ b/dist/xrfragment.three.module.js @@ -1,5 +1,5 @@ /* - * v0.5.1 generated at Thu Feb 29 01:34:17 PM UTC 2024 + * v0.5.1 generated at Thu Feb 29 01:43:17 PM UTC 2024 * https://xrfragment.org * SPDX-License-Identifier: MPL-2.0 */ diff --git a/doc/RFC_XR_Fragments.html b/doc/RFC_XR_Fragments.html index 5293a2d..f5e921a 100644 --- a/doc/RFC_XR_Fragments.html +++ b/doc/RFC_XR_Fragments.html @@ -104,6 +104,7 @@ XR Fragments exploits the fact that all 3D models already contain such metadata:
  • Interlinking text & spatial objects by collapsing space into a Word Graph (XRWG) to show visible links
  • unlocking spatial potential of the (originally 2D) hashtag (which jumps to a chapter) for navigating XR documents
  • refraining from introducing scripting-engines for mundane tasks (and preventing its inevitable security-headaches)
  • +
  • the gap between text an 3d objects: object-names directly map to hashtags (=fragments), which allows 3D to text transcription.
  • @@ -174,6 +175,8 @@ Instead of forcing authors to combine 3D/2D objects programmatically (publishing

    ?-linked and #-linked navigation are JUST one possible way to implement XR Fragments: the essential goal is to allow a Hypermediatic FeedbackLoop (HFL) between external and internal 4D navigation.

    +

    Traditional webbrowsers can become 4D document-ready by:

    +

    Hypermediatic FeedbackLoop for XR browsers

    href metadata traditionally implies click AND navigate, however XR Fragments adds click (xrf://#....) or navigate (xrf://#pos=...)
    @@ -1534,6 +1537,93 @@ The following demonstrates a simple video player:

    +

    Additional scene metadata

    + +

    XR Fragments does not aim to redefine the metadata-space by introducing its own cataloging-metadata fields. +Instead, it encourages browsers to scan nodes for the following custom properties:

    + +
      +
    • SPDX license information
    • +
    • ARIA attributes (aria-*: .....)
    • +
    • Open Graph attributes (og:*: .....)
    • +
    • Dublin-Core attributes(dc:*: .....)
    • +
    • BibTex when known bibtex-keys exist with values enclosed in { and },
    • +
    + +

    ARIA (aria-description) is the most important to support, as it promotes accessibility and allows scene transcripts. Please start aria-description with a verb to aid transcripts.

    + +
    +

    Example: object ‘tryceratops’ with aria-description: is a huge dinosaurus standing on a #mountain generates transcript #tryceratops is a huge dinosaurus standing on a #mountain, where the hashtags are clickable XR Fragments (activating the visible-links in the XR browser).

    +
    + +

    Individual nodes can be enriched with such metadata, but most importantly the scene node:

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    metadata keyexample value
    aria-description, og:description, dc:descriptionAn immersive experience about Triceratops (*)
    SPDXCC0-1.0
    dc:creatorJohn Doe
    dc:title, og:title‘Triceratops` (*)
    og:site_namehttps://xrfragment.org
    dc.publisherNLNET
    dc.date2024-01-01
    dc.identifierXRFRAGMENT-001
    journal (bibTeX){Future Of Text Vol 3},
    + +
    +

    * = these are interchangable (only one needs to be defined)

    +
    + +

    There’s no silver bullet when it comes to metadata, so one should support where the metadata is/goes.

    + +
    +

    These attributes can be scanned and presented during an href or src eye/mouse-over.

    +
    +

    Security Considerations

    The only dynamic parts are W3C Media Fragments and URI Templates (RFC6570).
    diff --git a/doc/RFC_XR_Fragments.md b/doc/RFC_XR_Fragments.md index ea84b34..26fc6ff 100644 --- a/doc/RFC_XR_Fragments.md +++ b/doc/RFC_XR_Fragments.md @@ -1049,9 +1049,10 @@ Instead, it encourages browsers to scan nodes for the following custom propertie * [Open Graph](https://ogp.me) attributes (`og:*: .....`) * [Dublin-Core](https://www.dublincore.org/specifications/dublin-core/application-profile-guidelines/) attributes(`dc:*: .....`) * [BibTex](https://bibtex.eu/fields) when known bibtex-keys exist with values enclosed in `{` and `},` -* [JSON-LD](https://json-ld.org/) when key matches `@type` JSON-value -> ARIA (`aria-description`) is the most important to support (as it promotes accessibility) +**ARIA** (`aria-description`) is the most important to support, as it promotes accessibility and allows scene transcripts. Please start `aria-description` with a verb to aid transcripts. + +> Example: object 'tryceratops' with `aria-description: is a huge dinosaurus standing on a #mountain` generates transcript `#tryceratops is a huge dinosaurus standing on a #mountain`, where the hashtags are clickable XR Fragments (activating the visible-links in the XR browser). Individual nodes can be enriched with such metadata, but most importantly the scene node: @@ -1066,12 +1067,12 @@ Individual nodes can be enriched with such metadata, but most importantly the sc | `dc.date` | `2024-01-01` | | `dc.identifier` | `XRFRAGMENT-001` | | `journal` (bibTeX) | `{Future Of Text Vol 3},` | -| `Person` (JSON-LD) | `{"@type":"Person",................}` | > \* = these are interchangable (only one needs to be defined) There's no silver bullet when it comes to metadata, so one should support where the metadata is/goes. -For future formats it's absolutely fine to follow the same heuristics as used with JSON-LD (key matches `@type` value) or bibtex (value matches field-delimiter). + +> These attributes can be scanned and presented during an `href` or `src` eye/mouse-over. # Security Considerations diff --git a/doc/RFC_XR_Fragments.txt b/doc/RFC_XR_Fragments.txt index 3de769e..74219f4 100644 --- a/doc/RFC_XR_Fragments.txt +++ b/doc/RFC_XR_Fragments.txt @@ -3,7 +3,7 @@ Jens & Leon Internet Engineering Task Force L.R. van Kammen -Internet-Draft 26 February 2024 +Internet-Draft 29 February 2024 Intended status: Informational @@ -43,7 +43,7 @@ Status of This Memo time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." - This Internet-Draft will expire on 29 August 2024. + This Internet-Draft will expire on 1 September 2024. Copyright Notice @@ -53,7 +53,7 @@ Copyright Notice -van Kammen Expires 29 August 2024 [Page 1] +van Kammen Expires 1 September 2024 [Page 1] Internet-Draft XR Fragments February 2024 @@ -72,49 +72,50 @@ Table of Contents 1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . 3 2. Core principle . . . . . . . . . . . . . . . . . . . . . . . 3 3. Hypermediatic FeedbackLoop for XR browsers . . . . . . . . . 5 - 4. Conventions and Definitions . . . . . . . . . . . . . . . . . 7 - 4.1. XR Fragment URL Grammar . . . . . . . . . . . . . . . . . 7 + 4. Conventions and Definitions . . . . . . . . . . . . . . . . . 8 + 4.1. XR Fragment URL Grammar . . . . . . . . . . . . . . . . . 8 5. List of URI Fragments . . . . . . . . . . . . . . . . . . . . 8 - 5.1. List of metadata for 3D nodes . . . . . . . . . . . . . . 8 - 5.2. Fragment-to-metadata mapping . . . . . . . . . . . . . . 9 - 5.3. media fragments and datatypes . . . . . . . . . . . . . . 10 - 6. Spatial Referencing 3D . . . . . . . . . . . . . . . . . . . 13 - 7. Navigating 3D . . . . . . . . . . . . . . . . . . . . . . . . 14 - 8. Top-level URL processing . . . . . . . . . . . . . . . . . . 15 - 9. Embedding XR content using src . . . . . . . . . . . . . . . 15 - 10. Navigating content href portals . . . . . . . . . . . . . . . 18 - 10.1. Walking surfaces . . . . . . . . . . . . . . . . . . . . 19 - 10.2. UX spec . . . . . . . . . . . . . . . . . . . . . . . . 19 - 10.3. Scaling instanced content . . . . . . . . . . . . . . . 20 - 11. XR Fragment: pos . . . . . . . . . . . . . . . . . . . . . . 20 - 12. XR Fragment: rot . . . . . . . . . . . . . . . . . . . . . . 20 - 13. XR Fragment: t . . . . . . . . . . . . . . . . . . . . . . . 20 - 14. XR audio/video integration . . . . . . . . . . . . . . . . . 21 - 15. XR Fragment filters . . . . . . . . . . . . . . . . . . . . . 21 - 15.1. including/excluding . . . . . . . . . . . . . . . . . . 22 - 15.2. Filter Parser . . . . . . . . . . . . . . . . . . . . . 23 - 16. Visible links . . . . . . . . . . . . . . . . . . . . . . . . 23 - 17. Text in XR (tagging,linking to spatial objects) . . . . . . . 24 - 17.1. Default Data URI mimetype . . . . . . . . . . . . . . . 28 - 17.2. URL and Data URI . . . . . . . . . . . . . . . . . . . . 29 - 17.3. XR Text example parser . . . . . . . . . . . . . . . . . 30 - 18. Transclusion (broken link) resolution . . . . . . . . . . . . 32 - 19. Topic-based index-less Webrings . . . . . . . . . . . . . . . 33 - 20. URI Templates (RFC6570) . . . . . . . . . . . . . . . . . . . 34 - 21. Security Considerations . . . . . . . . . . . . . . . . . . . 34 - 22. FAQ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 - 23. authors . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 - 24. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 35 - 25. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 35 + 5.1. List of metadata for 3D nodes . . . . . . . . . . . . . . 9 + 5.2. Fragment-to-metadata mapping . . . . . . . . . . . . . . 10 + 5.3. media fragments and datatypes . . . . . . . . . . . . . . 11 + 6. Spatial Referencing 3D . . . . . . . . . . . . . . . . . . . 14 + 7. Navigating 3D . . . . . . . . . . . . . . . . . . . . . . . . 15 + 8. Top-level URL processing . . . . . . . . . . . . . . . . . . 16 + 9. Embedding XR content using src . . . . . . . . . . . . . . . 16 + 10. Navigating content href portals . . . . . . . . . . . . . . . 19 + 10.1. Walking surfaces . . . . . . . . . . . . . . . . . . . . 20 + 10.2. UX spec . . . . . . . . . . . . . . . . . . . . . . . . 20 + 10.3. Scaling instanced content . . . . . . . . . . . . . . . 21 + 11. XR Fragment: pos . . . . . . . . . . . . . . . . . . . . . . 21 + 12. XR Fragment: rot . . . . . . . . . . . . . . . . . . . . . . 21 + 13. XR Fragment: t . . . . . . . . . . . . . . . . . . . . . . . 21 + 14. XR audio/video integration . . . . . . . . . . . . . . . . . 22 + 15. XR Fragment filters . . . . . . . . . . . . . . . . . . . . . 22 + 15.1. including/excluding . . . . . . . . . . . . . . . . . . 23 + 15.2. Filter Parser . . . . . . . . . . . . . . . . . . . . . 24 + 16. Visible links . . . . . . . . . . . . . . . . . . . . . . . . 24 + 17. Text in XR (tagging,linking to spatial objects) . . . . . . . 25 + 17.1. Default Data URI mimetype . . . . . . . . . . . . . . . 29 + 17.2. URL and Data URI . . . . . . . . . . . . . . . . . . . . 30 + 17.3. XR Text example parser . . . . . . . . . . . . . . . . . 31 + 18. Transclusion (broken link) resolution . . . . . . . . . . . . 33 + 19. Topic-based index-less Webrings . . . . . . . . . . . . . . . 34 + 20. URI Templates (RFC6570) . . . . . . . . . . . . . . . . . . . 35 + 21. Additional scene metadata . . . . . . . . . . . . . . . . . . 35 + 22. Security Considerations . . . . . . . . . . . . . . . . . . . 37 + 23. FAQ . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 + 24. authors . . . . . . . . . . . . . . . . . . . . . . . . . . . 37 + 25. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 38 -van Kammen Expires 29 August 2024 [Page 2] +van Kammen Expires 1 September 2024 [Page 2] Internet-Draft XR Fragments February 2024 - 26. Appendix: Definitions . . . . . . . . . . . . . . . . . . . . 36 + 26. Acknowledgments . . . . . . . . . . . . . . . . . . . . . . . 38 + 27. Appendix: Definitions . . . . . . . . . . . . . . . . . . . . 38 1. Introduction @@ -142,6 +143,8 @@ Internet-Draft XR Fragments February 2024 jumps to a chapter) for navigating XR documents 4. refraining from introducing scripting-engines for mundane tasks (and preventing its inevitable security-headaches) + 5. the gap between text an 3d objects: object-names directly map to + hashtags (=fragments), which allows 3D to text transcription. | NOTE: The chapters in this document are ordered from highlevel to | lowlevel (technical) as much as possible @@ -162,10 +165,7 @@ Internet-Draft XR Fragments February 2024 - - - -van Kammen Expires 29 August 2024 [Page 3] +van Kammen Expires 1 September 2024 [Page 3] Internet-Draft XR Fragments February 2024 @@ -221,7 +221,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 4] +van Kammen Expires 1 September 2024 [Page 4] Internet-Draft XR Fragments February 2024 @@ -252,6 +252,8 @@ Internet-Draft XR Fragments February 2024 | Hypermediatic FeedbackLoop (HFL) between external and internal 4D | navigation. + Traditional webbrowsers can become 4D document-ready by: + 3. Hypermediatic FeedbackLoop for XR browsers href metadata traditionally implies *click* AND *navigate*, however @@ -272,16 +274,16 @@ Internet-Draft XR Fragments February 2024 * hypermediatic (https://github.com/coderofsalvation/hypermediatic) loading/clicking 3D assets (gltf/fbx e.g.) natively (with or without using HTML). - * allowing 3D assets/nodes to publish XR Fragments to themselves/ - eachother using the xrf:// hashbus -van Kammen Expires 29 August 2024 [Page 5] +van Kammen Expires 1 September 2024 [Page 5] Internet-Draft XR Fragments February 2024 + * allowing 3D assets/nodes to publish XR Fragments to themselves/ + eachother using the xrf:// hashbus * collapsing the 3D scene to an wordgraph (for essential navigation purposes) controllable thru a hash(tag)bus * completely bypassing the security-trap of loading external scripts @@ -292,6 +294,50 @@ Internet-Draft XR Fragments February 2024 agnostic, though pseudo-XR Fragment browsers *can* be implemented on top of HTML/Javascript. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +van Kammen Expires 1 September 2024 [Page 6] + +Internet-Draft XR Fragments February 2024 + + +=========+======================+=====================================+ |principle|XR 4D URL |HTML 2D URL | +=========+======================+=====================================+ @@ -331,19 +377,23 @@ Internet-Draft XR Fragments February 2024 Table 1 - - -van Kammen Expires 29 August 2024 [Page 6] - -Internet-Draft XR Fragments February 2024 - - | An important aspect of HFL is that URI Fragments can be triggered | without updating the top-level URI (default href-behaviour) thru | their own 'bus' (xrf://#.....). This decoupling between | navigation and interaction prevents non-standard things like | (href:javascript:dosomething()). + + + + + + +van Kammen Expires 1 September 2024 [Page 7] + +Internet-Draft XR Fragments February 2024 + + 4. Conventions and Definitions See appendix below in case certain terms are not clear. @@ -380,20 +430,6 @@ Internet-Draft XR Fragments February 2024 https://me.com can load the latter (and still indicates which XR Fragments entrypoint-experience/client was used). - - - - - - - - - -van Kammen Expires 29 August 2024 [Page 7] - -Internet-Draft XR Fragments February 2024 - - 5. List of URI Fragments +=======================+======================================+============+============+ @@ -406,6 +442,14 @@ Internet-Draft XR Fragments February 2024 | | | |0.5,0,0, | +-----------------------+--------------------------------------+------------+------------+ |#rot |vector3 |#rot=0,90,0 |rotates | + + + +van Kammen Expires 1 September 2024 [Page 8] + +Internet-Draft XR Fragments February 2024 + + | | | |camera to | | | | |xyz-coord | | | | |0.5,0,0 | @@ -442,14 +486,6 @@ Internet-Draft XR Fragments February 2024 | src | string | "src": | XR embed / | custom | | | | "#cube" | teleport | property in 3D | | | | | | fileformats | - - - -van Kammen Expires 29 August 2024 [Page 8] - -Internet-Draft XR Fragments February 2024 - - +------+--------+------------+-------------------+----------------+ | tag | string | "tag": | tag object (for | custom | | | | "cubes | filter-use / XRWG | property in 3D | @@ -462,6 +498,14 @@ Internet-Draft XR Fragments February 2024 Table 4 + + + +van Kammen Expires 1 September 2024 [Page 9] + +Internet-Draft XR Fragments February 2024 + + | Supported popular compatible 3D fileformats: .gltf, .obj, .fbx, | .usdz, .json (THREE.js), .dae and so on. @@ -498,14 +542,6 @@ Internet-Draft XR Fragments February 2024 | | | | |cam01 as active camera | +----------------+--------------------------------------+-------------+---------------------+-----------------------+ |*MATERIALUPDATE*|#[*]=|string=string|#car=metallic |sets material of car to| - - - -van Kammen Expires 29 August 2024 [Page 9] - -Internet-Draft XR Fragments February 2024 - - | | | | |material with name | | | | | |metallic (*=including | | | | | |children) | @@ -518,6 +554,14 @@ Internet-Draft XR Fragments February 2024 |*VARIABLE |#= |string=string|#foo=bar |sets URI Template | |UPDATE* | | | |(https://www.rfc- | | | | | |editor.org/rfc/rfc6570)| + + + +van Kammen Expires 1 September 2024 [Page 10] + +Internet-Draft XR Fragments February 2024 + + | | | | |variable foo to the | | | | | |value #t=0 from | | | | | |*existing* object | @@ -550,18 +594,6 @@ Internet-Draft XR Fragments February 2024 | the 3D scene(file) *but also* media defined in src-metadata like | audio/video-files (mp3/mp4 e.g.) - - - - - - - -van Kammen Expires 29 August 2024 [Page 10] - -Internet-Draft XR Fragments February 2024 - - +==========+======================+===============+================+ | type | syntax | example | info | +==========+======================+===============+================+ @@ -578,6 +610,14 @@ Internet-Draft XR Fragments February 2024 +----------+----------------------+---------------+----------------+ | temporal | t=x,y | 0,2 | play from 0 | | W3C | | | seconds till 2 | + + + +van Kammen Expires 1 September 2024 [Page 11] + +Internet-Draft XR Fragments February 2024 + + | media | | | seconds (and | | fragment | | | stop) | +----------+----------------------+---------------+----------------+ @@ -610,14 +650,6 @@ Internet-Draft XR Fragments February 2024 | | | | the current uv | | | | | coordinates | +----------+----------------------+---------------+----------------+ - - - -van Kammen Expires 29 August 2024 [Page 11] - -Internet-Draft XR Fragments February 2024 - - | | | 0.2,1,0.1,0.1 | scroll (lerp) | | | | | to uv | | | | | coordinate | @@ -634,6 +666,14 @@ Internet-Draft XR Fragments February 2024 | | | +0.5,+0.5 | scroll | | | | | instantly by | | | | | adding 0.5 to | + + + +van Kammen Expires 1 September 2024 [Page 12] + +Internet-Draft XR Fragments February 2024 + + | | | | the current uv | | | | | coordinates | +----------+----------------------+---------------+----------------+ @@ -669,7 +709,23 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 12] + + + + + + + + + + + + + + + + +van Kammen Expires 1 September 2024 [Page 13] Internet-Draft XR Fragments February 2024 @@ -725,7 +781,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 13] +van Kammen Expires 1 September 2024 [Page 14] Internet-Draft XR Fragments February 2024 @@ -759,10 +815,10 @@ Internet-Draft XR Fragments February 2024 Table 7 - » example implementation + » example implementation (https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/ three/xrf/pos.js) - » discussion (https://github.com/coderofsalvation/xrfragment/ + » discussion (https://github.com/coderofsalvation/xrfragment/ issues/5) 1. the Y-coordinate of pos identifies the floorposition. This means @@ -777,11 +833,11 @@ Internet-Draft XR Fragments February 2024 coordinate, pos=0,0,0 will be assumed Here's an ascii representation of a 3D scene-graph which contains 3D - objects ◻ and their metadata: + objects ◻ and their metadata: -van Kammen Expires 29 August 2024 [Page 14] +van Kammen Expires 1 September 2024 [Page 15] Internet-Draft XR Fragments February 2024 @@ -837,7 +893,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 15] +van Kammen Expires 1 September 2024 [Page 16] Internet-Draft XR Fragments February 2024 @@ -859,9 +915,8 @@ Internet-Draft XR Fragments February 2024 Table 8 - Here's an ascii representation of a 3D scene-graph with 3D objects - ◻ which embeds remote & local 3D objects ◻ with/out using - filters: + Here's an ascii representation of a 3D scene-graph with 3D objects ◻ + which embeds remote & local 3D objects ◻ with/out using filters: +────────────────────────────────────────────────────────+ +─────────────────────────+ │ │ │ │ @@ -893,7 +948,8 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 16] + +van Kammen Expires 1 September 2024 [Page 17] Internet-Draft XR Fragments February 2024 @@ -949,7 +1005,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 17] +van Kammen Expires 1 September 2024 [Page 18] Internet-Draft XR Fragments February 2024 @@ -957,13 +1013,13 @@ Internet-Draft XR Fragments February 2024 * image/jpg * text/plain;charset=utf-8 - » example implementation + » example implementation (https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/ three/xrf/src.js) - » example 3D asset + » example 3D asset (https://github.com/coderofsalvation/xrfragment/blob/main/example/ assets/src.gltf#L192) - » discussion (https://github.com/coderofsalvation/xrfragment/ + » discussion (https://github.com/coderofsalvation/xrfragment/ issues/4) 10. Navigating content href portals @@ -1005,7 +1061,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 18] +van Kammen Expires 1 September 2024 [Page 19] Internet-Draft XR Fragments February 2024 @@ -1026,13 +1082,13 @@ Internet-Draft XR Fragments February 2024 forward action until a pos=... primitive is found (the inbetween interaction URI's are only for UX research purposes) - » example implementation + » example implementation (https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/ three/xrf/href.js) - » example 3D asset + » example 3D asset (https://github.com/coderofsalvation/xrfragment/blob/main/example/ assets/href.gltf#L192) - » discussion (https://github.com/coderofsalvation/xrfragment/ + » discussion (https://github.com/coderofsalvation/xrfragment/ issues/1) 10.1. Walking surfaces @@ -1061,7 +1117,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 19] +van Kammen Expires 1 September 2024 [Page 20] Internet-Draft XR Fragments February 2024 @@ -1117,7 +1173,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 20] +van Kammen Expires 1 September 2024 [Page 21] Internet-Draft XR Fragments February 2024 @@ -1173,7 +1229,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 21] +van Kammen Expires 1 September 2024 [Page 22] Internet-Draft XR Fragments February 2024 @@ -1229,7 +1285,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 22] +van Kammen Expires 1 September 2024 [Page 23] Internet-Draft XR Fragments February 2024 @@ -1244,11 +1300,11 @@ Internet-Draft XR Fragments February 2024 | colorbuffer (to allow children being still visible while their | parents are invisible). - » example implementation + » example implementation (https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/ - three/xrf/q.js) » example 3D asset + three/xrf/q.js) » example 3D asset (https://github.com/coderofsalvation/xrfragment/blob/main/example/ - assets/filter.gltf#L192) » discussion + assets/filter.gltf#L192) » discussion (https://github.com/coderofsalvation/xrfragment/issues/3) 15.2. Filter Parser @@ -1285,7 +1341,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 23] +van Kammen Expires 1 September 2024 [Page 24] Internet-Draft XR Fragments February 2024 @@ -1341,7 +1397,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 24] +van Kammen Expires 1 September 2024 [Page 25] Internet-Draft XR Fragments February 2024 @@ -1397,7 +1453,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 25] +van Kammen Expires 1 September 2024 [Page 26] Internet-Draft XR Fragments February 2024 @@ -1453,7 +1509,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 26] +van Kammen Expires 1 September 2024 [Page 27] Internet-Draft XR Fragments February 2024 @@ -1509,7 +1565,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 27] +van Kammen Expires 1 September 2024 [Page 28] Internet-Draft XR Fragments February 2024 @@ -1565,7 +1621,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 28] +van Kammen Expires 1 September 2024 [Page 29] Internet-Draft XR Fragments February 2024 @@ -1621,7 +1677,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 29] +van Kammen Expires 1 September 2024 [Page 30] Internet-Draft XR Fragments February 2024 @@ -1677,7 +1733,7 @@ xrtext = { -van Kammen Expires 29 August 2024 [Page 30] +van Kammen Expires 1 September 2024 [Page 31] Internet-Draft XR Fragments February 2024 @@ -1733,7 +1789,7 @@ console.log( xrtext.encode(text,tags) ) // multiplex text & bibtex back to -van Kammen Expires 29 August 2024 [Page 31] +van Kammen Expires 1 September 2024 [Page 32] Internet-Draft XR Fragments February 2024 @@ -1789,7 +1845,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 32] +van Kammen Expires 1 September 2024 [Page 33] Internet-Draft XR Fragments February 2024 @@ -1845,7 +1901,7 @@ Internet-Draft XR Fragments February 2024 -van Kammen Expires 29 August 2024 [Page 33] +van Kammen Expires 1 September 2024 [Page 34] Internet-Draft XR Fragments February 2024 @@ -1874,7 +1930,95 @@ Internet-Draft XR Fragments February 2024 │ │ +─────────────────────────────────────────────+ -21. Security Considerations +21. Additional scene metadata + + XR Fragments does not aim to redefine the metadata-space by + introducing its own cataloging-metadata fields. Instead, it + encourages browsers to scan nodes for the following custom + properties: + + * SPDX (https://spdx.dev/) license information + * ARIA (https://www.w3.org/WAI/standards-guidelines/aria/) + attributes (aria-*: .....) + * Open Graph (https://ogp.me) attributes (og:*: .....) + * Dublin-Core (https://www.dublincore.org/specifications/dublin- + core/application-profile-guidelines/) attributes(dc:*: .....) + * BibTex (https://bibtex.eu/fields) when known bibtex-keys exist + with values enclosed in { and }, + + *ARIA* (aria-description) is the most important to support, as it + promotes accessibility and allows scene transcripts. Please start + aria-description with a verb to aid transcripts. + + + + + + + + +van Kammen Expires 1 September 2024 [Page 35] + +Internet-Draft XR Fragments February 2024 + + + | Example: object 'tryceratops' with aria-description: is a huge + | dinosaurus standing on a #mountain generates transcript + | #tryceratops is a huge dinosaurus standing on a #mountain, where + | the hashtags are clickable XR Fragments (activating the visible- + | links in the XR browser). + + Individual nodes can be enriched with such metadata, but most + importantly the scene node: + + +================================+=========================+ + | metadata key | example value | + +================================+=========================+ + | aria-description, | An immersive experience | + | og:description, dc:description | about Triceratops (*) | + +--------------------------------+-------------------------+ + | SPDX | CC0-1.0 | + +--------------------------------+-------------------------+ + | dc:creator | John Doe | + +--------------------------------+-------------------------+ + | dc:title, og:title | 'Triceratops` (*) | + +--------------------------------+-------------------------+ + | og:site_name | https://xrfragment.org | + +--------------------------------+-------------------------+ + | dc.publisher | NLNET | + +--------------------------------+-------------------------+ + | dc.date | 2024-01-01 | + +--------------------------------+-------------------------+ + | dc.identifier | XRFRAGMENT-001 | + +--------------------------------+-------------------------+ + | journal (bibTeX) | {Future Of Text Vol 3}, | + +--------------------------------+-------------------------+ + + Table 13 + + | * = these are interchangable (only one needs to be defined) + + There's no silver bullet when it comes to metadata, so one should + support where the metadata is/goes. + + | These attributes can be scanned and presented during an href or + | src eye/mouse-over. + + + + + + + + + + +van Kammen Expires 1 September 2024 [Page 36] + +Internet-Draft XR Fragments February 2024 + + +22. Security Considerations The only dynamic parts are W3C Media Fragments (https://www.w3.org/TR/media-frags/) and URI Templates (RFC6570) @@ -1884,7 +2028,7 @@ Internet-Draft XR Fragments February 2024 In fact, it is much safer than relying on a scripting language (javascript) which can change URN too. -22. FAQ +23. FAQ *Q:* Why is everything HTTP GET-based, what about POST/PUT/DELETE HATEOS @@ -1898,14 +2042,6 @@ Internet-Draft XR Fragments February 2024 scope as it unhyperifies hypermedia, and this is up to XR hypermedia browser-extensions. Historically scripting/Javascript seems to been able to turn webpages - - - -van Kammen Expires 29 August 2024 [Page 34] - -Internet-Draft XR Fragments February 2024 - - from hypermedia documents into its opposite (hyperscripted nonhypermedia documents). In order to prevent this backward-movement (hypermedia tends to @@ -1925,16 +2061,24 @@ Internet-Draft XR Fragments February 2024 place, to 'extend' experiences, in contrast to code/javascript inside hypermedia documents (this turned out as a hypermedia antipattern). -23. authors +24. authors * Leon van Kammen (@lvk@mastodon.online) - * Jens Finkhäuser (@jens@social.finkhaeuser.de) + * Jens Finkhäuser (@jens@social.finkhaeuser.de) -24. IANA Considerations + + + +van Kammen Expires 1 September 2024 [Page 37] + +Internet-Draft XR Fragments February 2024 + + +25. IANA Considerations This document has no IANA actions. -25. Acknowledgments +26. Acknowledgments * NLNET (https://nlnet.nl) * Future of Text (https://futureoftext.org) @@ -1942,27 +2086,14 @@ Internet-Draft XR Fragments February 2024 * Michiel Leenaars * Gerben van der Broeke * Mauve - * Jens Finkhäuser + * Jens Finkhäuser * Marc Belmont * Tim Gerritsen * Frode Hegland * Brandel Zackernuk * Mark Anderson - - - - - - - - -van Kammen Expires 29 August 2024 [Page 35] - -Internet-Draft XR Fragments February 2024 - - -26. Appendix: Definitions +27. Appendix: Definitions +=================+=============================================+ | definition | explanation | @@ -1991,6 +2122,14 @@ Internet-Draft XR Fragments February 2024 | | Object(nodes), relevant to machines and a | | | human minority (academics/developers) | +-----------------+---------------------------------------------+ + + + +van Kammen Expires 1 September 2024 [Page 38] + +Internet-Draft XR Fragments February 2024 + + | XR fragment | URI Fragment with spatial hints like | | | #pos=0,0,0&t=1,100 e.g. | +-----------------+---------------------------------------------+ @@ -2010,14 +2149,6 @@ Internet-Draft XR Fragments February 2024 | placeholder | a 3D object which with src-metadata (which | | object | will be replaced by the src-data.) | +-----------------+---------------------------------------------+ - - - -van Kammen Expires 29 August 2024 [Page 36] - -Internet-Draft XR Fragments February 2024 - - | src | (HTML-piggybacked) metadata of a 3D object | | | which instances content | +-----------------+---------------------------------------------+ @@ -2047,7 +2178,15 @@ Internet-Draft XR Fragments February 2024 | extrospective | outward sensemaking ("I'm fairly sure John | | | is a person who lives in oklahoma") | +-----------------+---------------------------------------------+ - | ◻ | ascii representation of an 3D object/mesh | + + + +van Kammen Expires 1 September 2024 [Page 39] + +Internet-Draft XR Fragments February 2024 + + + | ◻ | ascii representation of an 3D object/mesh | +-----------------+---------------------------------------------+ | (un)obtrusive | obtrusive: wrapping human text/thought in | | | XML/HTML/JSON obfuscates human text into a | @@ -2067,14 +2206,7 @@ Internet-Draft XR Fragments February 2024 | | XML | +-----------------+---------------------------------------------+ - - -van Kammen Expires 29 August 2024 [Page 37] - -Internet-Draft XR Fragments February 2024 - - - Table 13 + Table 14 @@ -2105,24 +2237,4 @@ Internet-Draft XR Fragments February 2024 - - - - - - - - - - - - - - - - - - - - -van Kammen Expires 29 August 2024 [Page 38] +van Kammen Expires 1 September 2024 [Page 40] diff --git a/doc/RFC_XR_Fragments.xml b/doc/RFC_XR_Fragments.xml index 75edd9b..ec942fc 100644 --- a/doc/RFC_XR_Fragments.xml +++ b/doc/RFC_XR_Fragments.xml @@ -38,6 +38,7 @@ XR Fragments exploits the fact that all 3D models already contain such metadata:

  • Interlinking text & spatial objects by collapsing space into a Word Graph (XRWG) to show visible links
  • unlocking spatial potential of the (originally 2D) hashtag (which jumps to a chapter) for navigating XR documents
  • refraining from introducing scripting-engines for mundane tasks (and preventing its inevitable security-headaches)
  • +
  • the gap between text an 3d objects: object-names directly map to hashtags (=fragments), which allows 3D to text transcription.
  • NOTE: The chapters in this document are ordered from highlevel to lowlevel (technical) as much as possible
    @@ -49,18 +50,18 @@ XR Fragments exploits the fact that all 3D models already contain such metadata: Instead of forcing authors to combine 3D/2D objects programmatically (publishing thru a game-editor e.g.), XR Fragments integrates all which allows a universal viewing experience.
    - +───────────────────────────────────────────────────────────────────────────────────────────────+ + Fact: our typical browser URL's are just a possible implementation of URI's (for untapped humancentric potential of URI's see interpeer.io)
    XR Fragments does not look at XR (or the web) thru the lens of HTML or URLs.
    But approaches things from a higherlevel feedbackloop/hypermedia browser-perspective.
    Below you can see how this translates back into good-old URLs: - +───────────────────────────────────────────────────────────────────────────────────────────────+ + ?other.glb ─> #view ───> hashbus │ │ │ #filter │ │ │ │ #tag │ │ │ │ (hypermediatic) #material │ │ @@ -89,16 +91,18 @@ But approaches things from a higherlevel feedbackloop/hypermedia browser-perspec │ │ ( loop ) #texture │ │ │ │ #variable │ │ │ │ │ │ - │ XRWG <─────────────────────<─────────────+ │ + │ XRWG <─────────────────────<─────────────+ │ │ │ │ │ - │ └─ objects ──────────────>─────────────+ │ + │ └─ objects ──────────────>─────────────+ │ │ │ │ │ +───────────────────────────────────────────────────────────────────────────────────────────────+ +]]>
    ?-linked and #-linked navigation are JUST one possible way to implement XR Fragments: the essential goal is to allow a Hypermediatic FeedbackLoop (HFL) between external and internal 4D navigation. -
    +Traditional webbrowsers can become 4D document-ready by: +
    Hypermediatic FeedbackLoop for XR browsers href metadata traditionally implies click AND navigate, however XR Fragments adds click (xrf://#....) or navigate (xrf://#pos=...)
    @@ -192,9 +196,10 @@ But approaches things from a higherlevel feedbackloop/hypermedia browser-perspec
    XR Fragment URL Grammar For typical HTTP-like browsers/applications: -reserved = gen-delims / sub-delims -gen-delims = "#" / "&" -sub-delims = "," / "=" +
    Example: ://foo.com/my3d.gltf#pos=1,0,0&prio=-5&t=0,100
    @@ -502,11 +507,11 @@ That way, if the link gets shared, the XR Fragments implementation at https:
  • https://shaders.org/plasma.glsl#t=0&u:col2=0,1,0 (red-green shader plasma starts playing from time-offset 0)
  • - +──────────────────────────────────────────────────────────+ +https: │ │ └ src: foo.jpg#uv=0,0,0,+0.1 │ infinite texturescroll `v` of uv·coordinates with 0.1/fps │ │ │ │ ├── ◻ media │ - │ │ └ src: cat.mp4#t=l:2,10&uv=0.5,0.5 │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds (uv's shifted with 0.5,0.5) + │ │ └ src: cat.mp4#t=l:2,10&uv=0.5,0.5 │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds (uv's shifted with 0.5,0.5) │ │ │ │ └── ◻ wall │ │ ├ href: #color=blue │ updates uniform values (IFS shader e.g.) - │ ├ blue: t=0&u:col=0,0,1 │ variable for [Level1 URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570) - │ └ src: ://a.com/art.glsl#{color}&{shared} │ .fs/.vs/.glsl/.wgsl etc shader [Level1 URI Template (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570) + │ ├ blue: t=0&u:col=0,0,1 │ variable for [Level1 URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570) + │ └ src: ://a.com/art.glsl#{color}&{shared} │ .fs/.vs/.glsl/.wgsl etc shader [Level1 URI Template (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570) │ │ │ │ +──────────────────────────────────────────────────────────+ -> NOTE: URI Template variables are immutable and respect scope: in other words, the end-user cannot modify `blue` by entering an URL like `#blue=.....` in the browser URL, and `blue` is not accessible by the plane/media-object (however `{play}` would work). +> NOTE: URI Template variables are immutable and respect scope: in other words, the end-user cannot modify `blue` by entering an URL like `#blue=.....` in the browser URL, and `blue` is not accessible by the plane/media-object (however `{play}` would work). +]]> @@ -535,7 +541,7 @@ That way, if the link gets shared, the XR Fragments implementation at https:
    Spatial Referencing 3D XR Fragments assume the following objectname-to-URIFragment mapping: - +https: │ +─────────────────────────+ │ +─────────────────────────────+ +]]>
    Every 3D fileformat supports named 3D object, and this name allows URLs (fragments) to reference them (and their children objects).
    Clever nested design of 3D scenes allow great ways for re-using content, and/or previewing scenes.
    @@ -601,18 +608,19 @@ For example, to render a portal with a preview-version of the scene, create an 3 Here's an ascii representation of a 3D scene-graph which contains 3D objects and their metadata: - +────────────────────────────────────────────────────────+ + An XR Fragment-compatible browser viewing this scene, allows the end-user to interact with the buttonA and buttonB.
    @@ -660,7 +668,7 @@ It instances content (in objects) in the current scene/asset.
    Here's an ascii representation of a 3D scene-graph with 3D objects which embeds remote & local 3D objects with/out using filters: - +────────────────────────────────────────────────────────+ +─────────────────────────+ + │ └ src: #canvas │ │ │ +────────────────────────────────────────────────────────+ +]]> An XR Fragment-compatible browser viewing this scene, lazy-loads and projects painting.png onto the (plane) object called canvas (which is copy-instanced in the bed and livingroom).
    @@ -997,7 +1006,7 @@ XR Fragments does this by detecting Bib(s)Tex, without introducing a new languag Example: - http://y.io/z.fbx | Derived XRWG (expressed as BibTex) +
    the #john@baroque-bib associates both text John and objectname john, with tag baroque
    Another example: - http://y.io/z.fbx | Derived XRWG (expressed as BibTex) +
    both #john@baroque-bib and BibTex @baroque{john} result in the same XRWG, however on top of that 2 tages (house and todo) are now associated with text/objectname/tag 'baroque'.
    As seen above, the XRWG can expand bibs (and the whole scene) to BibTeX.
    @@ -1090,21 +1101,22 @@ Some pointers for good UX (but not necessary to be XR Fragment compatible):
    The simplicity of appending metadata (and leveling the metadata-playfield between humans and machines) is also demonstrated by visual-meta in greater detail.
    Fictional chat: -<John> Hey what about this: https://my.com/station.gltf#pos=0,0,1&rot=90,2,0&t=500,1000 -<Sarah> I'm checking it right now -<Sarah> I don't see everything..where's our text from yesterday? -<John> Ah wait, that's tagged with tag 'draft' (and hidden)..hold on, try this: -<John> https://my.com/station.gltf#.draft&pos=0,0,1&rot=90,2,0&t=500,1000 -<Sarah> how about we link the draft to the upcoming YELLO-event? -<John> ok I'm adding #draft@YELLO -<Sarah> Yesterday I also came up with other usefull assocations between other texts in the scene: + Hey what about this: https://my.com/station.gltf#pos=0,0,1&rot=90,2,0&t=500,1000 + I'm checking it right now + I don't see everything..where's our text from yesterday? + Ah wait, that's tagged with tag 'draft' (and hidden)..hold on, try this: + https://my.com/station.gltf#.draft&pos=0,0,1&rot=90,2,0&t=500,1000 + how about we link the draft to the upcoming YELLO-event? + ok I'm adding #draft@YELLO + Yesterday I also came up with other usefull assocations between other texts in the scene: #event#YELLO #2025@YELLO -<John> thanks, added. -<Sarah> Btw. I stumbled upon this spatial book which references station.gltf in some chapters: -<Sarah> https://thecommunity.org/forum/foo/mytrainstory.txt -<John> interesting, I'm importing mytrainstory.txt into station.gltf -<John> ah yes, chapter three points to trainterminal_2A in the scene, cool + thanks, added. + Btw. I stumbled upon this spatial book which references station.gltf in some chapters: + https://thecommunity.org/forum/foo/mytrainstory.txt + interesting, I'm importing mytrainstory.txt into station.gltf + ah yes, chapter three points to trainterminal_2A in the scene, cool +]]>
    Default Data URI mimetype @@ -1140,7 +1152,7 @@ to connect text further with its environment ( setup links between textual/spati
    URL and Data URI - +--------------------------------------------------------------+ +------------------------+ + The enduser will only see welcome human and Hello friends rendered verbatim (see mimetype). The beauty is that text in Data URI automatically promotes rich copy-paste (retaining metadata). @@ -1163,14 +1176,14 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
    XR Text example parser To prime the XRWG with text from plain text src-values, here's an example XR Text (de)multiplexer in javascript (which supports inline bibs & bibtex): -xrtext = { + { let bibs = { regex: /(#[a-zA-Z0-9_+@\-]+(#)?)/g, tags: {}} - text.replace( bibs.regex , (m,k,v) => { - tok = m.substr(1).split("@") + text.replace( bibs.regex , (m,k,v) => { + tok = m.substr(1).split("@") match = tok.shift() - if( tok.length ) tok.map( (t) => bibs.tags[t] = `@${t}{${match},\n}` ) + if( tok.length ) tok.map( (t) => bibs.tags[t] = `@${t}{${match},\n}` ) else if( match.substr(-1) == '#' ) bibs.tags[match] = `@{${match.replace(/#/,'')}}` else bibs.tags[match] = `@${match}{${match},\n}` @@ -1178,16 +1191,16 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)- return text.replace( bibs.regex, '') + Object.values(bibs.tags).join('\n') }, - decode: (str) => { - // bibtex: ↓@ ↓<tag|tag{phrase,|{ruler}> ↓property ↓end + decode: (str) => { + // bibtex: ↓@ ↓ ↓property ↓end let pat = [ /@/, /^\S+[,{}]/, /},/, /}/ ] let tags = [], text='', i=0, prop='' let lines = xrtext.expandBibs(str).replace(/\r?\n/g,'\n').split(/\n/) - for( let i = 0; i < lines.length && !String(lines[i]).match( /^@/ ); i++ ) + for( let i = 0; i < lines.length && !String(lines[i]).match( /^@/ ); i++ ) text += lines[i]+'\n' bibtex = lines.join('\n').substr( text.length ) - bibtex.split( pat[0] ).map( (t) => { + bibtex.split( pat[0] ).map( (t) => { try{ let v = {} if( !(t = t.trim()) ) return @@ -1196,9 +1209,9 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)- if( tag.match( /}$/ ) ) return tags.push({k: tag.replace(/}$/,''), v: {}}) t = t.substr( tag.length ) t.split( pat[2] ) - .map( kv => { - if( !(kv = kv.trim()) || kv == "}" ) return - v[ kv.match(/\s?(\S+)\s?=/)[1] ] = kv.substr( kv.indexOf("{")+1 ) + .map( kv => { + if( !(kv = kv.trim()) || kv == "}" ) return + v[ kv.match(/\s?(\S+)\s?=/)[1] ] = kv.substr( kv.indexOf("{")+1 ) }) tags.push( { k:tag, v } ) }catch(e){ console.error(e) } @@ -1206,8 +1219,8 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)- return {text, tags} }, - encode: (text,tags) => { - let str = text+"\n" + encode: (text,tags) => { + let str = text+"\n" for( let i in tags ){ let item = tags[i] if( item.ruler ){ @@ -1221,11 +1234,12 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)- return str } } +]]> The above functions (de)multiplexe text/metadata, expands bibs, (de)serialize bibtex and vice versa
    above can be used as a startingpoint for LLVM's to translate/steelman to a more formal form/language.
    -str = ` + t.k == 'flap{' ).v.asdf = 1 // edit tag tags.push({ k:'bar{', v:{abc:123} }) // add tag -console.log( xrtext.encode(text,tags) ) // multiplex text & bibtex back together +console.log( xrtext.encode(text,tags) ) // multiplex text & bibtex back together +]]> This expands to the following (hidden by default) BibTex appendix: -hello world +
    when an XR browser updates the human text, a quick scan for nonmatching tags (@book{nonmatchingbook e.g.) should be performed and prompt the enduser for deleting them.
    @@ -1276,7 +1292,7 @@ here are some hashtagbibs followed by bibtex:
    due to the popularity, maturity and extensiveness of HTTP codes for client/server communication, non-HTTP protocols easily map to HTTP codes (ipfs ERR_NOT_FOUND maps to 404 e.g.)
    For example: - +────────────────────────────────────────────────────────+ +
    @@ -1326,7 +1343,7 @@ To filter out non-related objects one could take it a step further using filters The following demonstrates a simple video player: - + │ │ │ │ ├── ◻ stopbutton │ │ │ ├ #: #-stopbutton │ - │ │ └ href: #player=stop&-stopbutton │ (stop and hide stop-button) + │ │ └ href: #player=stop&-stopbutton │ (stop and hide stop-button) │ │ │ │ └── ◻ plane │ │ ├ play: #t=l:0,10 │ │ ├ stop: #t=0,0 │ - │ ├ href: #player=play&stopbutton │ (play and show stop-button) + │ ├ href: #player=play&stopbutton │ (play and show stop-button) │ └ src: cat.mp4#{player} │ │ │ │ │ +─────────────────────────────────────────────+ +]]>
    +
    Additional scene metadata +XR Fragments does not aim to redefine the metadata-space by introducing its own cataloging-metadata fields. +Instead, it encourages browsers to scan nodes for the following custom properties: + +
      +
    • SPDX license information
    • +
    • ARIA attributes (aria-*: .....)
    • +
    • Open Graph attributes (og:*: .....)
    • +
    • Dublin-Core attributes(dc:*: .....)
    • +
    • BibTex when known bibtex-keys exist with values enclosed in { and },
    • +
    +ARIA (aria-description) is the most important to support, as it promotes accessibility and allows scene transcripts. Please start aria-description with a verb to aid transcripts. +
    Example: object 'tryceratops' with aria-description: is a huge dinosaurus standing on a #mountain generates transcript #tryceratops is a huge dinosaurus standing on a #mountain, where the hashtags are clickable XR Fragments (activating the visible-links in the XR browser). +
    Individual nodes can be enriched with such metadata, but most importantly the scene node: + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    metadata keyexample value
    aria-description, og:description, dc:descriptionAn immersive experience about Triceratops (*)
    SPDXCC0-1.0
    dc:creatorJohn Doe
    dc:title, og:title'Triceratops` (*)
    og:site_namehttps://xrfragment.org
    dc.publisherNLNET
    dc.date2024-01-01
    dc.identifierXRFRAGMENT-001
    journal (bibTeX){Future Of Text Vol 3},
    * = these are interchangable (only one needs to be defined) +
    There's no silver bullet when it comes to metadata, so one should support where the metadata is/goes. +
    These attributes can be scanned and presented during an href or src eye/mouse-over. +
    +
    Security Considerations The only dynamic parts are W3C Media Fragments and URI Templates (RFC6570).
    diff --git a/index.html b/index.html index b7a96b9..a325198 100644 --- a/index.html +++ b/index.html @@ -902,7 +902,7 @@ Error message and password prompt {"created":"20240130111558609","text":"\nfeature heuristics are basically features which can be inferred from absense or presence of certain metadata.\n\u003Cbr>\u003Cbr>\n\nFor example, 3D objects always have a name, and are (not) children of certain 3D objects.\nAll this indirect information can be used to activate certain viewer-features.\n\u003Cbr>\u003Cbr>\nAll feature heuristics have been with care, to ensure they can be extracted from both new/legacy 3D fileformats.\n\u003Cbr>\u003Cbr>\nThanks to this, the XR Fragment specs stays small (just `src` + `href` + `href` metadata, controlled by URI Fragments)\n","tags":"Reference","title":"📡 by feature (heuristics)","modified":"20240206124341480"}, {"created":"20230622104423767","text":"The parser is the heart ❤ of XR Fragments, and used by XR Fragment browsers.\u003Cbr>\nIt's available as:\n\n| language | link |\n|-|-|\n| python | \u003Ca href=\"./dist/xrfragment.py\" target=\"_blank\">xrfragment.py\u003C/a> |\n| lua | \u003Ca href=\"./dist/xrfragment.lua\" target=\"_blank\">xrfragment.lua\u003C/a> |\n| javascript | \u003Ca href=\"./dist/xrfragment.js\" target=\"_blank\">xrfragment.js\u003C/a> |\n| javascript | \u003Ca href=\"./dist/xrfragment.module.js\" target=\"_blank\">xrfragment.module.js\u003C/a> |\n| any language | \u003Ca href=\"https://github.com/coderofsalvation/xrfragment/blob/main/build.hxml\" target=\"_blank\">using HaXe\u003C/a> |\n| spec | you can literally write a parser yourself, the spec is kept very easy intentionally |\n\n\u003Cbr>\nWith that, you can immediately add 4D \u003Cb>addressibility\u003C/b> to your app like this:\n\u003Cbr>\u003Cbr>\n\n\u003Cdiv>\n \u003Ctextarea spellcheck=\"false\" autofocus class=\"sandboxify noresult\" style=\"min-height:205px;width:100%;max-width:800px;\">import xrfragment from './dist/xrfragment.module.js';\n// read URL\nlet url = `mysite.com/#pos=0,0,1&rot=0,90,34&t=500,100&mycustom=123` // replace with document.location.href\nlet spatialAddress = xrfragment.URI.parse(url)\n \n// share URL\nlet player = {pos:[0,0,1],rot:[0,90,45],t:[500,100]} // position 0,0,1 rot 0,90,45 animationrange frame 500-100\nlet {protocol,host,path,search} = document.location\nalert(`${protocol}//${host}${path}${search}#pos=${player.pos.join(',')}&rot=${player.rot.join(',')}&t=${player.t.join(',')}`)\n\u003C/textarea>\n\u003C/div> \n\n> Congrats! After connecting `pos` and `rot` to your camera, and providing back/forward navigation, you have a \u003Cb>XR Fragments navigator\u003C/b>-compliant client.\n\n\u003Cbr>\n\nFor example, the [AFRAME](#AFRAME) / [THREE.js](#THREE.js) client-libraries use it like this:\n\u003Cbr>\n\n\u003Cdiv>\n \u003Ctextarea style=\"min-height:130px\" spellcheck=\"false\" autofocus class=\"sandboxify\">let out = {}\nxrfragment.Parser.parse(\"pos\",\"0,0,1\", out)\nout.uri = xrfragment.URI.parse(\"#pos=0,0,1&nonspec=1\")\nout.query = new xrfragment.Query(\"foo -bar\")\nconsole.log(out)\n\u003C/textarea>\n\t\u003Cpre class=\"result\" style=\"min-height:300px\">\u003C/pre>\n\u003C/div>\n\n> If you want to build your own client/browser, see the documentation for these functions in the sidemenu\n\n| function | info |\n|-|-|\n| `xrfragment.Query( query )` | see [Query](#↪%20Query(query)) |\n| `xrfragment.URI.parse( str, flag )` | see [URI.parse](#↪%20URI.parse(url%2Cfilter)) |\n| `xrfragment.Parser.parse(k,v,store)` | see [Parser.parse](#↪%20Parser.parse(k%2Cv%2Cstore)) |\n","tags":"[[🧰 Libaries & Tools]] [[🧰 libraries]]","title":"🔨 XR Fragments parser","modified":"20240105120217923","type":"text/markdown"}, {"created":"20240208102607476","text":"There are only 2 **static** XR Fragments (`#pos` and `#rot`) and the rest are **auto-generated scene-specific** fragments.\u003Cbr>\nThese are inferred at runtime from the 3D scene-nodes (object names, object metadata etc).\u003Cbr>\u003Cbr>\nFree fragments and features generated for you..How great is that? 🎉\n\u003Cbr>\n\n> For more examples see \u003Ca href=\"#📡 by feature (heuristics)\">the reference-menu (by feature)\u003C/a>\n\n> Below is the related section of the spec (full spec here: \u003Ca href=\"doc/RFC_XR_Fragments.html\" target=\"_blank\">HTML\u003C/a>, \u003Ca href=\"doc/RFC_XR_Fragments.txt\" target=\"_blank\">TXT\u003C/a>)\n\n\u003Cbr>\n\u003Ciframe src=\"doc/RFC_XR_Fragments.html#fragment-to-metadata-mapping\" frameborder=\"0\" class=\"spec\">\u003C/iframe>\n","tags":"[[📜 XR Fragments]]","title":"🖇 auto-generated fragments","modified":"20240208120851990","type":"text/markdown"}, -{"created":"20240206123412197","text":"All modern 3D editors allow embedding metadata in objects of an exported 3D file.\u003Cbr>\n\n> An Easy **nocode** way to add metadata is [by adding custom properties in blender e.g.](https://docs.blender.org/manual/en/2.79/data_system/custom_properties.html). Basically:\n\u003Cbr>\u003Cbr>\n\n* [href](#href) for clickable links\n* [src](#src) for embedding content\n* [tag](#tag) to tag things\n\n\u003Cbr>\n\n| custom property | type | functionality |\n|----------|------|--------------|\n| [href](#href) | string (uri or [predefined view](#predefined_view)) | href navigation / portals / teleporting to other XR documents|\n| [src](#src) |string (uri or [predefined view](#predefined_view) or [query](#queries)) | lazyloading of (partial) local/external assets/scenes (3D iframes) |\n| [tag](#tag) |string|space-separated tagging of objects (like CSS class) for XRWG and or queries|\n\n\u003Cbr>\n> In Editors like \u003Ca href=\"https://blender.org\" target=\"_blank\">blender.org\u003C/a> these are called ''custom properties''.\n\u003Cbr>\u003Cbr>\n\n\u003Cb>Object metadata\u003C/b> can also be added programmatically, for example in \u003Ca href=\"https://threejs.org\" target=\"_blank\">AFRAME/THREE.js\u003C/a> can export GLB/USDZ/OBJ/COLLADA-files with them, after setting `myobject.userData.href = \"#pos=nameofplane\"` e.g.","tags":"[[📜 XR Fragments]]","title":"🧩 Object metadata","modified":"20240208102145983","type":"text/markdown"}, +{"created":"20240206123412197","text":"All modern 3D editors allow embedding metadata in objects of an exported 3D file.\u003Cbr>\n\n> An Easy **nocode** way to add metadata is [by adding custom properties in blender e.g.](https://docs.blender.org/manual/en/2.79/data_system/custom_properties.html). Basically:\n\u003Cbr>\u003Cbr>\n\n* [href](#href) for clickable links\n* [src](#src) for embedding content\n* [tag](#tag) to tag things\n\n\u003Cbr>\n\n| custom property | type | functionality |\n|----------|------|--------------|\n| [href](#href) | string (uri or [predefined view](#predefined_view)) | href navigation / portals / teleporting to other XR documents|\n| [src](#src) |string (uri or [predefined view](#predefined_view) or [query](#queries)) | lazyloading of (partial) local/external assets/scenes (3D iframes) |\n| [tag](#tag) |string|space-separated tagging of objects (like CSS class) for XRWG and or queries|\n\n\u003Cbr>\n> In Editors like \u003Ca href=\"https://blender.org\" target=\"_blank\">blender.org\u003C/a> these are called ''custom properties''.\n\u003Cbr>\u003Cbr>\n\n\u003Cb>Object metadata\u003C/b> can also be added programmatically, for example in \u003Ca href=\"https://threejs.org\" target=\"_blank\">AFRAME/THREE.js\u003C/a> can export GLB/USDZ/OBJ/COLLADA-files with them, after setting `myobject.userData.href = \"#pos=nameofplane\"` e.g.\n\n## Descriptive Metadata\n\nXR Fragments does not re-invent **descriptive metadata**, but encourages adding existing standards to 3D nodes, most notably:\n\n* [ARIA](https://www.w3.org/WAI/standards-guidelines/aria/) attributes (`aria-*: .....`)\n\n> **ARIA** (`aria-description`) is the most important to support, as it promotes accessibility and allows scene transcripts. Please start `aria-description` with a verb to aid transcripts.\n \nExample: object 'tryceratops' with `aria-description: is a huge dinosaurus standing on a #mountain` generates transcript `#tryceratops is a huge dinosaurus standing on a #mountain`.\u003Cbr>\nThese hashtags are clickable XR Fragments (activating the visible-\n\u003Cbr>\nbut also the following attributes are encouraged:\n\n* [SPDX](https://spdx.dev/) license information\n* [Open Graph](https://ogp.me) attributes (`og:*: .....`)\n* [Dublin-Core](https://www.dublincore.org/specifications/dublin-core/application-profile-guidelines/) attributes(`dc:*: .....`)\n* [BibTex](https://bibtex.eu/fields) when known bibtex-keys exist with values enclosed in `{` and `},`\n\nThese attributes can be scanned and presented during an `href` or `src` eye/mouse-over.\n\n## Spec\n\nBelow is the related section of the spec (full spec here: \u003Ca href=\"doc/RFC_XR_Fragments.html\" target=\"_blank\">HTML\u003C/a>, \u003Ca href=\"doc/RFC_XR_Fragments.txt\" target=\"_blank\">TXT\u003C/a>)\n\n\u003Ciframe src=\"doc/RFC_XR_Fragments.html#additional-scene-metadata\" frameborder=\"0\" class=\"spec\">\u003C/iframe>\n","tags":"[[📜 XR Fragments]]","title":"🧩 Object metadata","modified":"20240229140538420","type":"text/markdown"}, {"created":"20230427124155325","text":"\u003Ciframe class=\"border\" src=\"./example/explorer.html#t=1,100\" frameborder=\"0\" style=\"width:100%; height:70%; min-height:1000px;\"/>\n\n","tags":"[[🧰 Libaries & Tools]]","title":"🧪 XR Fragment Parser playground","modified":"20240105112235682"}, {"created":"20230602135111711","text":"The \u003Ca href=\"https://aframe.io\">AFRAME\u003C/a> wraps the THREE.js library, to enable a hypermedia browser-experience in just 2 lines:\n\n\u003Cdiv>\n \u003Ctextarea class=\"sandboxify\"><script src=\"https://xrfragment.org/dist/xrfragment.aframe.js\"></script>\n<a-entity xrf=\"https://xrfragment.org/index.glb\"></a-entity>\n \u003C/textarea>\n\u003C/div>\n\n> for realtime fiddling try [this codepen](https://codepen.io/coderofsalvation/pen/yLwedvX)\n\nIt enables:\n\n* linking together of space, time & (text)objects\n* with- or without a network-connection.\n* discover, share, link, navigate & query 4D experiences using URLs\n\n## Getting started\n\n1. Download \u003Ca href=\"./dist/xrfragment.aframe.js\" target=\"_blank\">xrfragment.aframe.js\u003C/a> (parser+navigator) OR \u003Ca href=\"./dist/xrfragment.aframe.all.js\" target=\"_blank\">xrfragment.aframe.all.js\u003C/a> (+video/chat-ui)\u003Cbr>\n2. then include below to empower your [AFRAME app](https:/aframe.io) with XR Fragments:\n\u003Cbr>\u003Cbr>\n\u003Cdiv>\n \u003Ctextarea spellcheck=\"false\" autofocus class=\"sandboxify noresult\" style=\"min-height:325px;width:100%;max-width:800px;\"><script src=\"./dist/xrfragment.aframe.js\"></script>\n \n...\n \n<a-scene> <a-entity id="player" wasd-controls look-controls> <a-entity id="left-hand" laser-controls="hand: left" raycaster="objects:.ray;far:5500" oculus-touch-controls="hand: left"> <a-entity rotation="-90 0 0" position="0 0.1 0"> <a-entity id="back" xrf-button="label: <; width:0.05; action: history.back()" position="-0.025 0 0" class="ray"></a-entity> <a-entity id="next" xrf-button="label: >; width:0.05; action: history.forward()" position=" 0.025 0 0" class="ray"></a-entity> </a-entity> </a-entity> <a-entity id="right-hand" laser-controls="hand: right" raycaster="objects:.ray;far:5500" oculus-touch-controls="hand: right" ></a-entity> <a-entity camera="fov:90" position="0 1.6 0" id="camera"></a-entity> </a-entity> <a-entity id="home" xrf="your.gltf#pos=0,0,0"></a-entity> <a-entity id="myobj" xrf-get="myobj"></a-entity> </a-scene>\n\u003C/textarea>\n\u003C/div> \n\n> This setup automatically launches the (THREE.js) `xrf.init()` which injects xrf-capabilities into THREE.js loaders. It'll automatically detect any XR Fragments in 3D assets (loaded afterwards). \u003Cbr>On top of that, it'll reflect changes in the URL-bar.\n\nAlso note that `xrf-get` allows converting objects inside assets into AFRAME `\u003Ca-entity>`, and `xrf-button` allows for simple interactions.\n\u003Cbr>\u003Cbr>\nSee the above in action below:\n\u003Cbr>\u003Cbr>\n\u003Ciframe class=\"border\" src=\"./example/aframe/sandbox?index.gltf#pos=0,0,0\" frameborder=\"0\" style=\"width:100%; height:70%; min-height:500px;\"/>\n\nThe xrfragment library lives at `window.AFRAME.XRF` so you can call `AFRAME.XRF.navigator.to('foo.hltf#pos=1,1,2')` e.g.\n\u003Cbr>\u003Cbr>\nEverything else works the same as [js/THREE.js](#js/THREE.js) (see for more info)","title":"🧰 AFRAME","modified":"20240105120746665","type":"text/markdown","tags":"[[🧰 libraries]] [[🧰 Libaries & Tools]]"}, {"created":"20230427151153103","text":"\u003C\u003Ctoc-selective-expandable '🧰 Libaries & Tools' sort[title]>>","tags":"$:/tags/SideBar","title":"🧰 Libaries & Tools","modified":"20240105110230440","list-after":"Reference"}, @@ -968,15 +968,15 @@ Error message and password prompt {"created":"20230425164931250","title":"$:/state/folded/AFRAME template","text":"show","modified":"20230425164935940"}, {"created":"20230425164931250","title":"$:/state/folded/GLSL shader template","text":"show","modified":"20230425164939576"}, {"created":"20230424142403302","text":"checked","title":"$:/state/import/select-all","modified":"20230424142404392"}, -{"created":"20230423163640468","title":"$:/state/notebook-sidebar","text":"yes","modified":"20240228121135736"}, -{"created":"20230423163641722","title":"$:/state/notebook-sidebar-section","text":"Reference","modified":"20240226113210303"}, +{"created":"20230423163640468","title":"$:/state/notebook-sidebar","text":"no","modified":"20240229140634712"}, +{"created":"20230423163641722","title":"$:/state/notebook-sidebar-section","text":"Reference","modified":"20240229135025988"}, {"created":"20230427102758222","title":"$:/state/plugin-info--1887569658-$:/plugins/ihm/tidgraph--50210113","text":"documentation","modified":"20230427102759911"}, {"created":"20230427092525294","title":"$:/state/plugin-info--391242618-$:/plugins/tiddlywiki/browser-storage","text":"yes","modified":"20230427092525375"}, {"created":"20230427093219686","title":"$:/state/plugin-info--391242618-$:/plugins/tiddlywiki/browser-storage--605768392","text":"settings","modified":"20230427094141558"}, {"created":"20230424092949812","title":"$:/state/plugin-info-1024395336-$:/plugins/tiddlywiki/codemirror--1574138004","text":"contents","modified":"20230425143706081"}, {"created":"20230424093627704","title":"$:/state/plugin-info-833095967-Draft of '$:/core'---1604322978","text":"readme","modified":"20230424093629208"}, {"created":"20230423163649566","title":"$:/state/showeditpreview","text":"no","modified":"20231202160010251"}, -{"created":"20230504174435745","title":"$:/state/sidebar","text":"no","modified":"20240228121122764"}, +{"created":"20230504174435745","title":"$:/state/sidebar","text":"no","modified":"20240229134433000"}, {"created":"20230423163453188","title":"$:/state/tab--1963855381","text":"$:/themes/nico/notebook/themetweaks","modified":"20230523124919651"}, {"created":"20230427092954391","title":"$:/state/tab--2112689675","text":"$:/core/ui/ControlPanel/Basics","modified":"20230523124903522"}, {"created":"20230424093058379","title":"$:/state/tab--697582678","text":"$:/core/ui/ControlPanel/Settings/TiddlyWiki","modified":"20230427093030201"}, @@ -998,17 +998,17 @@ Error message and password prompt {"created":"20230602141817951","title":"$:/state/toc/Reference-js/THREE.js--403145756","text":"open","modified":"20230622104317372"}, {"created":"20230830155416228","title":"$:/state/toc/Reference-The Future--403145756","text":"open","modified":"20230921092402656"}, {"created":"20230622111757807","title":"$:/state/toc/Reference-The parser--403145756","text":"close","modified":"20240105115930125"}, -{"created":"20240207130427889","title":"$:/state/toc/Reference/📜 XR Fragments-🎞 Media Fragments--403145756","text":"close","modified":"20240228122308040"}, +{"created":"20240207130427889","title":"$:/state/toc/Reference/📜 XR Fragments-🎞 Media Fragments--403145756","text":"close","modified":"20240229140628220"}, {"created":"20240207122831738","title":"$:/state/toc/Reference/📜 XR Fragments-🎞 W3C media fragments--403145756","text":"close","modified":"20240207122851711"}, {"created":"20240207131218249","title":"$:/state/toc/Reference/📜 XR Fragments-🎞 W3C Media Fragments--403145756","text":"close","modified":"20240209162544478"}, {"created":"20240130111742002","title":"$:/state/toc/Reference/📜 XR Fragments-📡 feature heuristics--403145756","text":"open","modified":"20240130112521075"}, {"created":"20240206123632130","title":"$:/state/toc/Reference/📜 XR Fragments-🧩 object metadata--403145756","text":"close","modified":"20240207122940234"}, -{"created":"20240207130143587","title":"$:/state/toc/Reference/📜 XR Fragments-🧩 Object metadata--403145756","text":"open","modified":"20240223091957156"}, +{"created":"20240207130143587","title":"$:/state/toc/Reference/📜 XR Fragments-🧩 Object metadata--403145756","text":"open","modified":"20240229140629191"}, {"created":"20240105120105242","title":"$:/state/toc/Reference/🧰 libraries-XR Fragment parser--403145756","text":"open","modified":"20240105120105242"}, {"created":"20230622104329622","title":"$:/state/toc/Reference/js/AFRAME-THREE.js--403145756","text":"open","modified":"20230622104329622"}, {"created":"20230622111759784","title":"$:/state/toc/Reference/The parser-THREE.js--403145756","text":"open","modified":"20230622111759784"}, {"title":"$:/status/RequireReloadDueToPluginChange","text":"no"}, -{"title":"$:/StoryList","created":"20240228121205123","text":"","list":"[[XR Fragments]]","modified":"20240228122237826"}, +{"title":"$:/StoryList","created":"20240229134442812","text":"","list":"[[XR Fragments]]","modified":"20240229140220606"}, {"created":"20230423163445948","title":"$:/theme","text":"$:/themes/nico/notebook","modified":"20230423163445948"}, {"text":"{\n \"tiddlers\": {\n \"$:/themes/nico/notebook/LICENSE\": {\n \"title\": \"$:/themes/nico/notebook/LICENSE\",\n \"created\": \"20200419141443144\",\n \"modified\": \"20210118213330307\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\nMIT License Copyright (c) 2020 [[Nicolas Petton|https://nicolas.petton.fr]] nicolas@petton.fr\\n\\nPermission is hereby granted, free of charge, to any person obtaining a copy\\nof this software and associated documentation files (the \\\"Software\\\"), to deal\\nin the Software without restriction, including without limitation the rights\\nto use, copy, modify, merge, publish, distribute, sublicense, and/or sell\\ncopies of the Software, and to permit persons to whom the Software is furnished\\nto do so, subject to the following conditions:\\n\\nThe above copyright notice and this permission notice (including the next\\nparagraph) shall be included in all copies or substantial portions of the\\nSoftware.\\n\\nTHE SOFTWARE IS PROVIDED \\\"AS IS\\\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR\\nIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS\\nFOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS\\nOR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,\\nWHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF\\nOR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\\n\"\n },\n \"$:/themes/nico/notebook/themetweaks\": {\n \"title\": \"$:/themes/nico/notebook/themetweaks\",\n \"created\": \"20201217172915960\",\n \"modified\": \"20210123211851680\",\n \"tags\": \"$:/tags/ControlPanel/Appearance\",\n \"caption\": \"{{$:/language/ThemeTweaks/ThemeTweaks}}\",\n \"text\": \"\\\\define lingo-base() $:/language/ThemeTweaks/\\n\\nYou can tweak certain aspects of the ''Notebook'' theme.\\n\\n! \u003C\u003Clingo Options>>\\n\\n|\u003C$link to=\\\"$:/themes/nico/notebook/options/stickytitles\\\">\u003C\u003Clingo Options/StickyTitles>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Options/StickyTitles/Hint>>// |\u003C$select tiddler=\\\"$:/themes/nico/notebook/options/stickytitles\\\">\u003Coption value=\\\"no\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"yes\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003C\u003Clingo Options/CodeWrapping>>\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/tiddlywiki/vanilla/options/codewrapping\\\">\u003Coption value=\\\"pre\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"pre-wrap\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\\\">Reveal tiddler controls on mouseover\u003C/$link> |\u003C$select tiddler=\\\"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\\\">\u003Coption value=\\\"no\\\">{{$:/language/No}}\u003C/option>\u003Coption value=\\\"yes\\\">{{$:/language/Yes}}\u003C/option>\u003C/$select> |\\n\\n! \u003C\u003Clingo Settings>>\\n\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/fontfamily\\\">\u003C\u003Clingo Settings/FontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/fontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/codefontfamily\\\">\u003C\u003Clingo Settings/CodeFontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/codefontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/settings/editorfontfamily\\\">\u003C\u003Clingo Settings/EditorFontFamily>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/settings/editorfontfamily\\\" default=\\\"\\\" tag=\\\"input\\\"/> | |\\n\\n! \u003C\u003Clingo Metrics>>\\n\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/metrics/fontsize\\\">\u003C\u003Clingo Metrics/FontSize>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/tiddlywiki/vanilla/metrics/fontsize\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/metrics/lineheight\\\">\u003C\u003Clingo Metrics/LineHeight>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/tiddlywiki/vanilla/metrics/lineheight\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/metrics/bodyfontsize\\\">\u003C\u003Clingo Metrics/BodyFontSize>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/metrics/bodyfontsize\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/metrics/bodylineheight\\\">\u003C\u003Clingo Metrics/BodyLineHeight>>\u003C/$link> |\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/metrics/bodylineheight\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint\\\">\u003C\u003Clingo Metrics/SidebarBreakpoint>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Metrics/SidebarBreakpoint/Hint>>// |^\u003C$edit-text tiddler=\\\"$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/metrics/sidebar-width\\\">\u003C\u003Clingo Metrics/SidebarWidth>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Metrics/SidebarWidth/Hint>>// |^\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/metrics/sidebar-width\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n|\u003C$link to=\\\"$:/themes/nico/notebook/metrics/story-width\\\">\u003C\u003Clingo Metrics/StoryWidth>>\u003C/$link>\u003Cbr>//\u003C\u003Clingo Metrics/StoryWidth/Hint>>// |^\u003C$edit-text tiddler=\\\"$:/themes/nico/notebook/metrics/story-width\\\" default=\\\"\\\" tag=\\\"input\\\"/> |\\n\\n\"\n },\n \"$:/themes/nico/notebook/base\": {\n \"title\": \"$:/themes/nico/notebook/base\",\n \"created\": \"20200419141443144\",\n \"modified\": \"20210120224227503\",\n \"tags\": \"$:/tags/Stylesheet\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\rules only filteredtranscludeinline transcludeinline macrodef macrocallinline\\n\\n\\\\define if-sidebar(text)\\n \u003C$reveal state=\\\"$:/state/notebook-sidebar\\\" type=\\\"match\\\" text=\\\"yes\\\">\\n $text$\\n \u003C/$reveal>\\n\\\\end\\n\\n\\\\define if-reveal-tiddler-controls-on-hover(text)\\n \u003C$reveal state=\\\"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\\\" type=\\\"match\\\" text=\\\"yes\\\">\\n $text$\\n \u003C/$reveal>\\n\\\\end\\n \\n/* Top and bottom bars */\\n\\n/* Hide the top-right bar */\\n.tc-topbar.tc-topbar-right {\\n display: none;\\n}\\n\\ndiv.tc-sidebar-header {\\n padding: 0;\\n min-height: 0;\\n}\\n\\n.tc-story-river {\\n padding: 6px 0 !important;\\n width: 100% !important;\\n max-width: {{$:/themes/nico/notebook/metrics/story-width}} !important;\\n margin: 0 auto !important;\\n margin-top: 34px !important;\\n}\\n\\ndiv.tc-tiddler-frame {\\n width: 100%;\\n margin: 20px 0;\\n background: \u003C\u003Ccolour tiddler-background>>;\\n box-shadow: 0 5px 20px rgba(0,0,0, 0.12);\\n border-radius: 6px;\\n padding: 42px 60px 60px 60px;\\n}\\n\\nh1.tc-site-title {\\n margin-top: 14px;\\n font-size: 1.5em !important;\\n}\\n\\n.nc-bar {\\n padding: 10px;\\n height: {{$:/themes/nico/notebook/metrics/topbar-height}};\\n background: \u003C\u003Ccolour page-background>>;\\n display: flex;\\n justify-content: space-between;\\n}\\n\\n.nc-topbar-wrapper {\\n position: fixed;\\n top: 0;\\n left: 0;\\n right: 0;\\n /* The z-index needs to be above the z-index used in tiddlers in zoomin view */\\n z-index: 501;\\n}\\n\\n.nc-bar.nc-topbar {\\n top: 0;\\n background: \u003C\u003Ccolour page-background>>ee;\\n max-width: calc({{$:/themes/nico/notebook/metrics/story-width}} + 40px);\\n padding: 10px 20px;\\n margin: 0 auto;\\n}\\n\\n.nc-bar.nc-bottombar {\\n position: fixed;\\n bottom: 0;\\n left: 0;\\n right: 0;\\n /* The z-index needs to be above the z-index used in tiddlers in zoomin view */\\n z-index: 501;\\n}\\n\\n.nc-bar .left svg {\\n fill: \u003C\u003Ccolour sidebar-controls-foreground>>;\\n}\\n\\n.nc-bar input[type=\\\"search\\\"] {\\n width: 200px;\\n padding: .6em 1em;\\n margin-top: -.2em;\\n background: \u003C\u003Ccolour sidebar-button-foreground>>44;\\n color: \u003C\u003Ccolour foreground>>cc;\\n transition: all ease-in .2s;\\n border: 1px solid transparent;\\n outline: 0;\\n}\\n\\n.nc-bar input[type=\\\"search\\\"]:focus {\\n width: 300px;\\n background: \u003C\u003Ccolour tiddler-background>>;\\n color: \u003C\u003Ccolour foreground>>;\\n border: 1px solid \u003C\u003Ccolour primary>>;\\n box-shadow: 0 0 .2rem 0 \u003C\u003Ccolour primary>>;\\n}\\n\\ninput[type=\\\"search\\\"]::-webkit-search-cancel-button {\\n -webkit-appearance: auto;\\n}\\n\\n.nc-bar .tc-block-dropdown.tc-search-drop-down {\\n margin-left: 0;\\n width: 400px;\\n border: 0;\\n box-shadow: 0 0 6px 0 rgba(0,0,0,.2);\\n border-radius: 6px;\\n padding: 20px 0;\\n}\\n\\n.nc-bar p {\\n margin: 0;\\n}\\n\\n.nc-bar .tc-page-controls {\\n margin-top: 0;\\n}\\n\\n.nc-bar .tc-page-controls button {\\n margin-right: .8em;\\n}\\n\\n.nc-bar .tc-page-controls button .tc-btn-text {\\n font-size: 14px;\\n}\\n\\n.nc-bar .tc-block-dropdown {\\n max-height: 70vh;\\n overflow: auto;\\n}\\n\\n@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .nc-topbar {\\n display: none;\\n }\\n\\n .tc-story-river {\\n padding: 0 !important;\\n margin-top: 0 !important;\\n margin-bottom: 60px !important;\\n }\\n\\n div.tc-tiddler-frame {\\n margin: 0;\\n box-shadow: none;\\n border-radius: 0;\\n border-top: 0;\\n }\\n}\\n\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .nc-bottombar {\\n display: none;\\n }\\n}\\n\\n@media(max-width: 1100px) {\\n .nc-bar input[type=\\\"search\\\"] {\\n width: 200px;\\n }\\n}\\n\\n/* Sidebar */\\n\\n@keyframes sidebar-appear {\\n 0% {\\n left: -{{$:/themes/nico/notebook/metrics/sidebar-width}};\\n }\\n 100% {\\n left: 0;\\n }\\n}\\n\\n\u003C\u003Cif-sidebar \\\"\\\"\\\"\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .nc-sidebar {\\n animation: sidebar-appear .14s;\\n padding-top: 10px;\\n }\\n}\\n\\\"\\\"\\\">>\\n\\n.nc-sidebar {\\n background: \u003C\u003Ccolour tiddler-background>>;\\n border-right: 1px solid \u003C\u003Ccolour tiddler-border>>;\\n width: {{$:/themes/nico/notebook/metrics/sidebar-width}};\\n overflow-y: auto;\\n overflow-x: hidden;\\n z-index: 500;\\n}\\n\\n.nc-sidebar .segment {\\n border-bottom: 1px solid rgba(0,0,0,.1);\\n}\\n\\n.nc-sidebar ol {\\n margin: 0;\\n padding: 0;\\n list-style: none;\\n line-height: 1.8em;\\n}\\n\\n.nc-sidebar ol ol {\\n padding-left: 18px;\\n}\\n\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .mobile-only {\\n display: none;\\n }\\n}\\n\\n@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .desktop-only {\\n display: none;\\n }\\n}\\n\\n.nc-sidebar h1.tc-site-title {\\n margin: 0;\\n}\\n\\n.nc-sidebar p {\\n margin: 6px 0;\\n}\\n\\n.nc-sidebar .tc-site-subtitle {\\n color: \u003C\u003Ccolour site-title-foreground>>;\\n}\\n\\n.nc-sidebar .section .label {\\n padding: 2px 0;\\n color: \u003C\u003Ccolour site-title-foreground>>;\\n fill: \u003C\u003Ccolour site-title-foreground>>;\\n font-weight: bold;\\n line-height: 1.6em;\\n display: block;\\n width: 100%;\\n text-align: left;\\n padding: 8px 15px;\\n border-radius: 0;\\n}\\n\\n.nc-sidebar .section:not(.open) .label:hover {\\n background: rgba(0,0,0,.06);\\n}\\n\\n.nc-sidebar .section.open .label {\\n color: \u003C\u003Ccolour tiddler-background>>;\\n fill: \u003C\u003Ccolour tiddler-background>>;\\n background: \u003C\u003Ccolour primary>>;\\n border-bottom: 1px solid rgba(0,0,0,.1);\\n}\\n\\n.nc-sidebar .section .label .caret {\\n display: inline-block;\\n width: 15px;\\n float: right;\\n}\\n\\n.nc-sidebar .content {\\n padding: 6px 15px;\\n font-size: 1em;\\n}\\n\\n.nc-sidebar .tc-tiddlylink {\\n color: \u003C\u003Ccolour primary>>;\\n}\\n\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .nc-sidebar {\\n position: fixed;\\n left: 0;\\n top: 0;\\n bottom: 0;\\n }\\n}\\n\\n\u003C\u003Cif-sidebar \\\"\\\"\\\"\\n@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n @keyframes sidebar-slide {\\n 0% {\\n left: -100vw;\\n }\\n 100% {\\n left: 0;\\n }\\n }\\n .nc-sidebar {\\n overflow: auto;\\n position: fixed;\\n width: 100%;\\n left: 0;\\n top: 0;\\n bottom: 48px;\\n z-index: 3000;\\n animation: sidebar-slide ease-in .2s;\\n animation-fill-mode: forwards;\\n }\\n}\\n\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .tc-page-container {\\n margin-left: {{$:/themes/nico/notebook/metrics/sidebar-width}} !important;\\n }\\n\\n .nc-topbar-wrapper {\\n left: {{$:/themes/nico/notebook/metrics/sidebar-width}};\\n }\\n}\\n\\\"\\\"\\\">>\\n\\n/* Animate the hamburger button */\\n\\n@keyframes menu-bars-1 {\\n 0% {}\\n 100% {\\n transform: rotate(-45deg) translateY(-10px) translateX(-6px);\\n fill: \u003C\u003Ccolour foreground>>;\\n }\\n}\\n\\n@keyframes menu-bars-2 {\\n 0% {}\\n 100% { opacity: 0; }\\n}\\n\\n@keyframes menu-bars-3 {\\n 0% {}\\n 100% {\\n transform: rotate(45deg) translateY(6px) translateX(2px);\\n fill: \u003C\u003Ccolour foreground>>;\\n }\\n}\\n\\n.sidebar-toggle {\\n /* position: fixed; */\\n /* top: 6px; */\\n /* left: 6px; */\\n /* z-index: 600; */\\n /* padding: 4px; */\\n /* border-radius: 8px; */\\n margin-right: 10px;\\n transition: all ease-in-out .2s;\\n fill: \u003C\u003Ccolour sidebar-controls-foreground>>;\\n}\\n\\n.sidebar-toggle:hover,\\n.sidebar-toggle.open {\\n fill: \u003C\u003Ccolour sidebar-controls-foreground-hover>>;\\n}\\n\\n/* @media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) { */\\n/* .sidebar-toggle { */\\n/* top: auto; */\\n/* bottom: 10px; */\\n/* left: 10px; */\\n/* } */\\n/* } */\\n\\n.sidebar-toggle .bars .bar {\\n transform: rotate(0) translateY(0) translateX(0);\\n opacity: 1;\\n transform-origin: 20px 10px;\\n transition: transform 0.4s ease-in-out, opacity 0.2s ease-in-out, fill .4s ease-in-out;\\n}\\n\\n.sidebar-toggle .bars .bar:nth-of-type(3) {\\n transform-origin: 20px 20px;\\n}\\n\\n.sidebar-toggle.open .bars .bar:nth-of-type(1) {\\n animation: menu-bars-1 .6s;\\n animation-fill-mode: forwards;\\n}\\n.sidebar-toggle.open .bars .bar:nth-of-type(2) {\\n animation: menu-bars-2 .6s;\\n animation-fill-mode: forwards;\\n}\\n.sidebar-toggle.open .bars .bar:nth-of-type(3) {\\n animation: menu-bars-3 .6s;\\n animation-fill-mode: forwards;\\n}\\n\\n@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n div.tc-tiddler-frame {\\n padding: 14px;\\n }\\n}\\n\\n/* Inputs */\\n\\ninput, textarea {\\n transition: border .14s ease-in-out;\\n background: \u003C\u003Ccolour tiddler-editor-background>>;\\n border: 1px solid \u003C\u003Ccolour tiddler-editor-border>>;\\n padding: .5em;\\n border-radius: 4px;\\n}\\n\\ninput:focus, textarea:focus {\\n box-shadow: 0 0 0.2rem 0 \u003C\u003Ccolour primary>>;\\n outline: 0;\\n border-color: \u003C\u003Ccolour primary>>;\\n}\\n\\nbutton {\\n border-radius: 1.5em;\\n border: 1px solid #ccc;\\n background: \u003C\u003Ccolour tiddler-background>>;\\n padding: .3em 1em;\\n cursor: pointer;\\n transition: box-shadow ease-in .1s;\\n color: \u003C\u003Ccolor foreground>>;\\n}\\n\\nbutton:focus, button:active {\\n outline: 0 none;\\n}\\n\\nbutton.tc-btn-invisible {\\n border-radius: 0;\\n}\\n\\n.tc-editor-toolbar button,\\n.tc-editor-toolbar button.tc-btn-invisible {\\n border-radius: 3px;\\n background: \u003C\u003Ccolour tiddler-editor-background>>;\\n color: \u003C\u003Ccolour foreground>>;\\n fill: \u003C\u003Ccolour foreground>>;\\n border: 1px solid \u003C\u003Ccolour tiddler-editor-border>>;\\n}\\n\\n.tc-editor-toolbar button:hover,\\n.tc-editor-toolbar button:active {\\n border-color: \u003C\u003Ccolour primary>>;\\n background: \u003C\u003Ccolour primary>>;\\n color: \u003C\u003Ccolour background>>;\\n fill: \u003C\u003Ccolour background>>;\\n}\\n\\n.tc-tiddler-frame input.tc-edit-texteditor,\\n.tc-tiddler-frame textarea.tc-edit-texteditor,\\n.tc-tiddler-frame iframe.tc-edit-texteditor {\\n transition: border .14s ease-in-out;\\n border: 1px solid \u003C\u003Ccolour tiddler-editor-border>>;\\n background: \u003C\u003Ccolour tiddler-editor-background>>;\\n padding: 4px;\\n border-radius: 4px;\\n}\\n\\n.tc-tiddler-frame input.tc-edit-texteditor:focus,\\n.tc-tiddler-frame textarea.tc-edit-texteditor:focus,\\n.tc-tiddler-frame iframe.tc-edit-texteditor:focus {\\n box-shadow: 0 0 0.2rem 0 \u003C\u003Ccolour primary>>;\\n outline: 0;\\n border-color: \u003C\u003Ccolour primary>>;\\n}\\n\\n.tc-tiddler-controls .tc-btn-text {\\n font-size: 16px;\\n}\\n\\n\u003C\u003Cif-reveal-tiddler-controls-on-hover \\\"\\\"\\\"\\n@media (min-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .tc-tiddler-frame .tc-tiddler-controls svg {\\n opacity: 0;\\n transition: all .2s ease-in;\\n }\\n\\n .tc-tiddler-controls svg.tc-image-close-button,\\n .tc-tiddler-controls .py-toggle-todo-button svg,\\n .tc-tiddler-controls svg.tc-image-done-button,\\n .tc-tiddler-frame .tc-tiddler-controls:hover svg {\\n opacity: 1;\\n }\\n\\n .tc-tiddler-controls .py-toggle-todo-button .done svg {\\n fill: #2da562;\\n }\\n}\\n\\\"\\\"\\\">>\\n\\nbutton.tc-tag-label, span.tc-tag-label {\\n padding: 0.3em 1em !important;\\n}\\n\\n/* Fonts */\\n\\nhtml, body {\\n font-family: {{$:/themes/nico/notebook/settings/fontfamily}};\\n}\\n\\n.tc-tiddler-frame input.tc-edit-texteditor,\\n.tc-tiddler-frame textarea.tc-edit-texteditor,\\n.tc-tiddler-frame iframe.tc-edit-texteditor {\\n font-family: {{$:/themes/nico/notebook/settings/editorfontfamily}};\\n}\\n\\npre, code {\\n font-family: {{$:/themes/nico/notebook/settings/codefontfamily}};\\n}\\n\\n.tc-titlebar, .tc-site-title {\\n font-size: 28px !important;\\n line-height: 34px !important;\\n font-weight: 600 !important;\\n letter-spacing: -0.5px !important;\\n}\\n\\nh1, h2, h3, h4, h5, h6 {\\n font-weight: 600;\\n}\\n\\n.tc-tiddler-body h1,\\n.tc-tiddler-body h2,\\n.tc-tiddler-preview-preview h1,\\n.tc-tiddler-preview-preview h2 {\\n font-weight: bold;\\n}\\n\\ndiv.tc-tiddler-frame .tc-tiddler-body {\\n font-size: {{$:/themes/nico/notebook/metrics/bodyfontsize}};\\n line-height: {{$:/themes/nico/notebook/metrics/bodylineheight}};\\n}\\n\\n/* Tabs */\\n\\ndiv.tc-tab-buttons {\\n margin-bottom: -4px;\\n}\\n\\ndiv.tc-tab-buttons button {\\n font-weight: bold;\\n font-size: 1.2em;\\n line-height: 1em;\\n padding: .6em .8em .4em .8em;\\n border: 0;\\n border-radius: 0;\\n background: transparent;\\n cursor: pointer;\\n transition: background ease-in .2s;\\n}\\n\\ndiv.tc-tab-buttons button:hover {\\n background: rgba(0,0,0,.03);\\n}\\n\\ndiv.tc-tab-buttons button.tc-tab-selected {\\n border: 0;\\n background: transparent;\\n border-bottom: 4px solid \u003C\u003Ccolour primary>>;\\n}\\n\\n/* Dropdowns */\\n\\n@keyframes pop {\\n 0% {\\n transform: scale(0.8);\\n opacity: 0;\\n }\\n\\n 80% {\\n transform: scale(1.03);\\n opacity: 1;\\n }\\n\\n 100% {\\n transform: scale(1);\\n opacity: 1;\\n }\\n}\\n\\n.tc-drop-down {\\n box-shadow: 0 0 10px rgba(0,0,0,.2);\\n border-radius: 6px;\\n padding: 10px 0 !important;\\n animation: pop .15s ease-in forwards;\\n}\\n\\n.tc-drop-down a, .tc-drop-down button {\\n padding: 3px 15px !important;\\n}\\n\\n.tc-search-results {\\n line-height: 2em;\\n}\\n\\n.tc-search-results em {\\n font-weight: bold;\\n font-style: normal;\\n}\\n\\n/* Draft list */\\n\\n.tc-drafts-list {\\n font-size: .9em;\\n left: auto;\\n right: 0;\\n}\\n\\n.tc-drafts-list a {\\n padding: 6px 12px;\\n font-weight: bold;\\n border-top-left-radius: 6px;\\n border-top-right-radius: 6px;\\n display: inline-block;\\n}\\n\\n.nc-refs {\\n color: #888;\\n font-size: .9em;\\n}\\n\\n.nc-refs h4 {\\n margin-bottom: 4px;\\n}\\n\\n.nc-post-created {\\n color: #acacac;\\n font-size: .8em;\\n}\\n\"\n },\n \"$:/themes/nico/notebook/changelog\": {\n \"title\": \"$:/themes/nico/notebook/changelog\",\n \"caption\": \"ChangeLog\",\n \"created\": \"20201217180707912\",\n \"modified\": \"20210202214001915\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"! 1.4.1\\n\\n!! Fixes\\n\\n* Fix the transclusion mode of sidebar sections\\n* Fix section title rendering for tiddlers without a caption field\\n* Fix the colour of links in the sidebar when using Notebook palettes with Vanilla\\n\\n! 1.4.0\\n\\n!! Features\\n\\n* New redesigned topbar layout\\n* Add a configuration setting for the story width\\n* Add support for keyboard navigation in the search dropdown\\n\\n! 1.3.6\\n\\n!! Improvements\\n\\n* Improve the style of tabs\\n* New animation for drop-downs\\n* Use a lighter page background colour in the beige palette\\n\\n!! Fixes\\n\\n* Fix the default ctrl+shift+F shortcut for focusing the search input\\n\\n! 1.3.5\\n\\n!! Features\\n\\n* Add an option to reveal tiddler controls on mouseover\\n\\n! 1.3.4\\n\\n!! Improvements\\n\\n* Add a keyboard shortcut (alt+shift+s) to toggle Notebook sidebar\\n* Add missing colours to tiddler editor fields in the dark palette\\n\\n!! Fixes\\n\\n* Fix the size of toolbar button labels when the $:/config/Toolbar/Text is set to yes\\n\\n! 1.3.3\\n\\n!! Improvements\\n\\n* Make the sidebar more generic by using the default sidebar sections\\n\\n! 1.3.2\\n\\n!! Improvements\\n\\n* Add colours for messages in the dark palette\\n* Add colours for notification in the dark palette\\n* Set colours for messages in the beige palette\\n\\n! 1.3.1\\n\\n!! Features\\n\\n* New font family settings distinct from the Vanilla theme\\n\\n!! Improvements\\n\\n* Use a slightly lighter colour as the search input background\\n* Improve contrast of sidebar buttons in the dark palette\\n\\n!! Fixes\\n\\n* Fix tiddler control button colours in all three palettes\\n* Fix tab colours in palette-dark\\n\\n! 1.3.0\\n\\n!! Improvements\\n\\n* New dark colour palette\\n* Use a darker color for tiddler subtitles\\n* Add back the WebKit search cancel button in search inputs\\n\\n!! Fixes\\n\\n* Fix the z-index of the topbar for the zoomin story view\\n* Fix the font weight of tiddler titles in edit mode\\n\\n! 1.2.0\\n\\n!! Improvements\\n\\n* Better support for dark colour palettes\\n\\n!! Fixes\\n\\n* Fix rendering of overflowing/wrapping text in the sidebar\\n\\n! 1.1.0\\n\\n!! Features\\n\\n* New theme tweaks tab dedicated to Notebook in the control panel\\n* Inputs in the edit template are now styled consistently with other inputs\\n\\n!! Fixes\\n\\n* Fixes the position of sticky tiddler titles when the option is turned on\\n\"\n },\n \"$:/config/ShortcutInfo/notebook-focus-search\": {\n \"title\": \"$:/config/ShortcutInfo/notebook-focus-search\",\n \"text\": \"Focus on the topbar search field\"\n },\n \"$:/config/shortcuts/notebook-focus-search\": {\n \"title\": \"$:/config/shortcuts/notebook-focus-search\",\n \"text\": \"ctrl+shift+F\"\n },\n \"$:/config/Search/AutoFocus\": {\n \"title\": \"$:/config/Search/AutoFocus\",\n \"text\": \"false\"\n },\n \"$:/config/shortcuts/sidebar-search\": {\n \"title\": \"$:/config/shortcuts/sidebar-search\",\n \"text\": \"\"\n },\n \"$:/themes/nico/notebook/images/bars\": {\n \"title\": \"$:/themes/nico/notebook/images/bars\",\n \"created\": \"20200428212322206\",\n \"modified\": \"20201210210231235\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Csvg class=\\\"bars\\\" height=\\\"21pt\\\" viewBox=\\\"0 0 42 42\\\" enable-background=\\\"new 0 0 32 22.5\\\" version=\\\"1.1\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\">\\n \u003Cg class=\\\"svg-menu-toggle\\\" sketch:type=\\\"MSLayerGroup\\\">\\n \u003Crect class=\\\"bar\\\" x=\\\"8\\\" y=\\\"28\\\" width=\\\"26\\\" height=\\\"4\\\">\u003C/rect>\\n \u003Crect class=\\\"bar\\\" x=\\\"8\\\" y=\\\"19\\\" width=\\\"26\\\" height=\\\"4\\\">\u003C/rect>\\n \u003Crect class=\\\"bar\\\" x=\\\"8\\\" y=\\\"10\\\" width=\\\"26\\\" height=\\\"4\\\">\u003C/rect>\\n \u003C/g>\\n\u003C/svg>\\n\"\n },\n \"$:/themes/nico/notebook/images/caret-down\": {\n \"title\": \"$:/themes/nico/notebook/images/caret-down\",\n \"created\": \"20200429194348688\",\n \"modified\": \"20201210210230919\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Csvg width=\\\"6pt\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" viewBox=\\\"0 0 320 512\\\">\u003Cpath d=\\\"M31.3 192h257.3c17.8 0 26.7 21.5 14.1 34.1L174.1 354.8c-7.8 7.8-20.5 7.8-28.3 0L17.2 226.1C4.6 213.5 13.5 192 31.3 192z\\\"/>\u003C/svg>\\n\"\n },\n \"$:/themes/nico/notebook/images/caret-right\": {\n \"title\": \"$:/themes/nico/notebook/images/caret-right\",\n \"created\": \"20200429194305719\",\n \"modified\": \"20201210210230909\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Csvg width=\\\"4pt\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" viewBox=\\\"0 0 192 512\\\">\u003Cpath d=\\\"M0 384.662V127.338c0-17.818 21.543-26.741 34.142-14.142l128.662 128.662c7.81 7.81 7.81 20.474 0 28.284L34.142 398.804C21.543 411.404 0 402.48 0 384.662z\\\"/>\u003C/svg>\\n\"\n },\n \"$:/themes/nico/notebook/images/color-switch\": {\n \"title\": \"$:/themes/nico/notebook/images/color-switch\",\n \"created\": \"20201210170859810\",\n \"creator\": \"nico\",\n \"modified\": \"20201210205606403\",\n \"modifier\": \"nico\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Csvg width=\\\"20px\\\" height=\\\"20px\\\" viewBox=\\\"0 0 16 16\\\" class=\\\"bi bi-circle-half\\\" fill=\\\"currentColor\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\">\\n \u003Cpath fill-rule=\\\"evenodd\\\" d=\\\"M8 15V1a7 7 0 1 1 0 14zm0 1A8 8 0 1 1 8 0a8 8 0 0 1 0 16z\\\"/>\\n\u003C/svg\\n\"\n },\n \"$:/themes/nico/notebook/metrics/bodyfontsize\": {\n \"title\": \"$:/themes/nico/notebook/metrics/bodyfontsize\",\n \"created\": \"20200428203454207\",\n \"modified\": \"20201210205606363\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"15px\\n\"\n },\n \"$:/themes/nico/notebook/metrics/bodylineheight\": {\n \"title\": \"$:/themes/nico/notebook/metrics/bodylineheight\",\n \"created\": \"20200428203454207\",\n \"modified\": \"20201210205606363\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"22px\"\n },\n \"$:/themes/nico/notebook/metrics/sidebar-width\": {\n \"title\": \"$:/themes/nico/notebook/metrics/sidebar-width\",\n \"created\": \"20200429144554294\",\n \"modified\": \"20201210210231246\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"350px\\n\"\n },\n \"$:/themes/nico/notebook/metrics/story-width\": {\n \"title\": \"$:/themes/nico/notebook/metrics/story-width\",\n \"created\": \"20210123210054185\",\n \"modified\": \"20210123211911688\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"800px\\n\"\n },\n \"$:/themes/nico/notebook/metrics/topbar-height\": {\n \"title\": \"$:/themes/nico/notebook/metrics/topbar-height\",\n \"created\": \"20200428203454207\",\n \"modified\": \"20201210205606363\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"52px\\n\"\n },\n \"$:/themes/nico/notebook/options/stickytitles\": {\n \"title\": \"$:/themes/nico/notebook/options/stickytitles\",\n \"text\": \"no\"\n },\n \"$:/themes/nico/notebook/options/codewrapping\": {\n \"title\": \"$:/themes/nico/notebook/options/codewrapping\",\n \"text\": \"pre-wrap\"\n },\n \"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\": {\n \"title\": \"$:/themes/nico/notebook/options/reveal-tiddler-controls-on-hover\",\n \"text\": \"no\"\n },\n \"$:/core/ui/PageTemplate/sidebar\": {\n \"title\": \"$:/core/ui/PageTemplate/sidebar\",\n \"created\": \"20200430072116835\",\n \"modified\": \"20201217174129501\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\whitespace trim\\n\\\\define config-title()\\n$:/config/SideBarSegments/Visibility/$(listItem)$\\n\\\\end\\n\\nOverwritten by $:/themes/nico/notebook so that the default sidebar does not get rendered.\\n\"\n },\n \"$:/themes/tiddlywiki/vanilla/themetweaks\": {\n \"title\": \"$:/themes/tiddlywiki/vanilla/themetweaks\",\n \"caption\": \"{{$:/language/ThemeTweaks/ThemeTweaks}}\",\n \"created\": \"20201217163834291\",\n \"modified\": \"20201217163914434\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"Overwritten by $:/themes/nico/notebook so that the Vanilla theme tweaks do not appear in the control panel. \"\n },\n \"$:/themes/nico/notebook/palettes/palette-beige\": {\n \"title\": \"$:/themes/nico/notebook/palettes/palette-beige\",\n \"text\": \"alert-background: #ffe476\\nalert-border: #b99e2f\\nalert-highlight: #881122\\nalert-muted-foreground: #b99e2f\\nbackground: #ffffff\\nblockquote-bar: \u003C\u003Ccolour muted-foreground>>\\nbutton-background:\\nbutton-foreground:\\nbutton-border:\\ncode-background: #f7f7f9\\ncode-border: #e1e1e8\\ncode-foreground: #dd1144\\ndirty-indicator: #c63636\\ndownload-background: #66cccc\\ndownload-foreground: \u003C\u003Ccolour background>>\\ndragger-background: \u003C\u003Ccolour foreground>>\\ndragger-foreground: \u003C\u003Ccolour background>>\\ndropdown-background: \u003C\u003Ccolour background>>\\ndropdown-border: #ddd\\ndropdown-tab-background-selected: #fff\\ndropdown-tab-background: #ececec\\ndropzone-background: #da8548\\nexternal-link-background-hover: inherit\\nexternal-link-background-visited: inherit\\nexternal-link-background: inherit\\nexternal-link-foreground-hover: inherit\\nexternal-link-foreground-visited: #0000aa\\nexternal-link-foreground: #0000ee\\nforeground: #3F3B3B\\nmessage-background: #e6f5e8\\nmessage-border: #2b5532\\nmessage-foreground: #2b5532\\nmodal-backdrop: \u003C\u003Ccolour foreground>>\\nmodal-background: \u003C\u003Ccolour background>>\\nmodal-border: #999999\\nmodal-footer-background: #f5f5f5\\nmodal-footer-border: #dddddd\\nmodal-header-border: #eeeeee\\nmuted-foreground: #999999\\nnotification-background: #ffffdd\\nnotification-border: #999999\\npage-background: #f5f5ee\\npre-background: #f6f6f6\\npre-border: #cccccc\\nprimary: #7f4bca\\nselect-tag-background:\\nselect-tag-foreground:\\nsidebar-button-foreground: #a6a69c\\nsidebar-controls-foreground-hover: #000000\\nsidebar-controls-foreground: \u003C\u003Ccolour sidebar-button-foreground>>\\nsidebar-foreground-shadow: rgba(255,255,255, 0.8)\\nsidebar-foreground: #acacac\\nsidebar-muted-foreground-hover: #444444\\nsidebar-muted-foreground: #c0c0c0\\nsidebar-tab-background-selected: #ffffff\\nsidebar-tab-background: \u003C\u003Ccolour tab-background>>\\nsidebar-tab-border-selected: \u003C\u003Ccolour tab-border-selected>>\\nsidebar-tab-border: \u003C\u003Ccolour tab-border>>\\nsidebar-tab-divider: \u003C\u003Ccolour tab-divider>>\\nsidebar-tab-foreground-selected: \u003C\u003Ccolour tab-foreground-selected>>\\nsidebar-tab-foreground: \u003C\u003Ccolour tab-foreground>>\\nsidebar-tiddler-link-foreground-hover: \u003C\u003Ccolour primary>>\\nsidebar-tiddler-link-foreground: \u003C\u003Ccolour tab-foreground>>\\nsite-title-foreground: #353748\\nstatic-alert-foreground: #aaaaaa\\ntab-background-selected: #ffffff\\ntab-background: #eeeeee\\ntab-border-selected: #cccccc\\ntab-border: #cccccc\\ntab-divider: #d8d8d8\\ntab-foreground-selected: \u003C\u003Ccolour foreground>>\\ntab-foreground: #888888\\ntable-border: #dddddd\\ntable-footer-background: #a8a8a8\\ntable-header-background: #f0f0f0\\ntag-background: #ffeedd\\ntag-foreground: #000\\ntiddler-background: \u003C\u003Ccolour background>>\\ntiddler-border: #dbdbc7;\\ntiddler-controls-foreground-hover: #888888;\\ntiddler-controls-foreground-selected: #888888;\\ntiddler-controls-foreground: #cccccc\\ntiddler-editor-background: \u003C\u003Ccolour background>>\\ntiddler-editor-border-image: #ffffff\\ntiddler-editor-border: rgba(0,0,0,.2)\\ntiddler-editor-fields-even: #e0e8e0\\ntiddler-editor-fields-odd: #f0f4f0\\ntiddler-info-background: #f8f8f8\\ntiddler-info-border: #dddddd\\ntiddler-info-tab-background: #f8f8f8\\ntiddler-link-background: \u003C\u003Ccolour background>>\\ntiddler-link-foreground: \u003C\u003Ccolour primary>>\\ntiddler-subtitle-foreground: #aaaaaa\\ntiddler-title-foreground: #333\\ntoolbar-new-button:\\ntoolbar-options-button:\\ntoolbar-save-button:\\ntoolbar-info-button:\\ntoolbar-edit-button:\\ntoolbar-close-button:\\ntoolbar-delete-button:\\ntoolbar-cancel-button:\\ntoolbar-done-button:\\nuntagged-background: #999999\\nvery-muted-foreground: #888888\\n\",\n \"type\": \"application/x-tiddler-dictionary\",\n \"description\": \"A beige colour palette for Notebook\",\n \"name\": \"Notebook Beige\",\n \"tags\": \"$:/tags/Palette $:/tags/notebook/Palette\"\n },\n \"$:/themes/nico/notebook/palettes/palette-dark\": {\n \"title\": \"$:/themes/nico/notebook/palettes/palette-dark\",\n \"text\": \"alert-background: #643b43\\nalert-border: #3f181f\\nalert-highlight: #881122\\nalert-muted-foreground: #bc8b94\\nbackground: #383e49\\nblockquote-bar: \u003C\u003Ccolour muted-foreground>>\\nbutton-background:\\nbutton-border:\\nbutton-foreground:\\ncode-background: #2c323b\\ncode-border: #111\\ncode-foreground: #dd1144\\ndirty-indicator: #c63636\\ndownload-background: #98be65\\ndownload-foreground: \u003C\u003Ccolour background>>\\ndragger-background: \u003C\u003Ccolour foreground>>\\ndragger-foreground: \u003C\u003Ccolour background>>\\ndropdown-background: \u003C\u003Ccolour background>>\\ndropdown-border: #111\\ndropdown-tab-background-selected: #fff\\ndropdown-tab-background: #ececec\\ndropzone-background: #da8548\\nexternal-link-background-hover: inherit\\nexternal-link-background-visited: inherit\\nexternal-link-background: inherit\\nexternal-link-foreground-hover: inherit\\nexternal-link-foreground-visited: #61afef\\nexternal-link-foreground: #c678dd\\nforeground: #c8ced8\\nmessage-background: #2c323e\\nmessage-border: #111\\nmessage-foreground: #d5e2f1\\nmodal-backdrop: \u003C\u003Ccolour foreground>>\\nmodal-background: \u003C\u003Ccolour background>>\\nmodal-border: #999999\\nmodal-footer-background: #f5f5f5\\nmodal-footer-border: #dddddd\\nmodal-header-border: #eeeeee\\nmuted-foreground: #999999\\nnotification-background: #3a5e39\\nnotification-border: #192c19\\npage-background: #262b33\\npre-background: \u003C\u003Ccolour page-background>>\\npre-border: \u003C\u003Ccolour tiddler-border>>\\nprimary: #bf93ff\\nselect-tag-background:\\nselect-tag-foreground:\\nsidebar-button-foreground: #5e646f\\nsidebar-controls-foreground-hover: #cad2e5\\nsidebar-controls-foreground: \u003C\u003Ccolour sidebar-button-foreground>>\\nsidebar-foreground-shadow: rgba(255,255,255, 0.8)\\nsidebar-foreground: #cad2e5\\nsidebar-muted-foreground-hover: #444444\\nsidebar-muted-foreground: #c0c0c0\\nsidebar-tab-background-selected: \u003C\u003Ccolour tab-background-selected>>\\nsidebar-tab-background: \u003C\u003Ccolour tab-background>>\\nsidebar-tab-border-selected: \u003C\u003Ccolour tab-border-selected>>\\nsidebar-tab-border: \u003C\u003Ccolour tab-border>>\\nsidebar-tab-divider: \u003C\u003Ccolour tab-divider>>\\nsidebar-tab-foreground-selected: \u003C\u003Ccolour tab-foreground-selected>>\\nsidebar-tab-foreground: \u003C\u003Ccolour tab-foreground>>\\nsidebar-tiddler-link-foreground-hover: \u003C\u003Ccolour primary>>\\nsidebar-tiddler-link-foreground: \u003C\u003Ccolour tab-foreground>>\\nsite-title-foreground: \u003C\u003Ccolour foreground>>\\nstatic-alert-foreground: #aaaaaa\\ntab-background-selected: \u003C\u003Ccolour background>>\\ntab-background: \u003C\u003Ccolour page-background>>\\ntab-border-selected: \u003C\u003Ccolour foreground>>\\ntab-border: #cad2e5\\ntab-divider: #cad2e5\\ntab-foreground-selected: #ecf2ff\\ntab-foreground: #cad2e5\\ntable-border: #aaaaaa\\ntable-footer-background: #a8a8a8\\ntable-header-background: #262b33\\ntag-background: #fcb671\\ntag-foreground: #000\\ntiddler-background: \u003C\u003Ccolour background>>\\ntiddler-border: #111\\ntiddler-controls-foreground-hover: #cad2e5\\ntiddler-controls-foreground-selected: #cad2e5\\ntiddler-controls-foreground: #5e646f\\ntiddler-editor-background: \u003C\u003Ccolour background>>\\ntiddler-editor-border-image: #ffffff\\ntiddler-editor-border: rgba(255, 255, 255, 0.3)\\ntiddler-editor-fields-even: \u003C\u003Ccolour background>>\\ntiddler-editor-fields-odd: #2c323b\\ntiddler-info-background: #f8f8f8\\ntiddler-info-border: #dddddd\\ntiddler-info-tab-background: #f8f8f8\\ntiddler-link-background: \u003C\u003Ccolour background>>\\ntiddler-link-foreground: \u003C\u003Ccolour primary>>\\ntiddler-subtitle-foreground: #aaaaaa\\ntiddler-title-foreground: \u003C\u003Ccolour foreground>>\\ntoolbar-cancel-button:\\ntoolbar-close-button:\\ntoolbar-delete-button:\\ntoolbar-done-button:\\ntoolbar-edit-button:\\ntoolbar-info-button:\\ntoolbar-new-button:\\ntoolbar-options-button:\\ntoolbar-save-button:\\nuntagged-background: #999999\\nvery-muted-foreground: #888888\\n\",\n \"type\": \"application/x-tiddler-dictionary\",\n \"description\": \"A dark colour palette for Notebook\",\n \"name\": \"Notebook Dark\",\n \"tags\": \"$:/tags/Palette $:/tags/notebook/Palette\"\n },\n \"$:/themes/nico/notebook/palettes/palette-grey\": {\n \"title\": \"$:/themes/nico/notebook/palettes/palette-grey\",\n \"text\": \"alert-background: #ffe476\\nalert-border: #b99e2f\\nalert-highlight: #881122\\nalert-muted-foreground: #b99e2f\\nbackground: #ffffff\\nblockquote-bar: \u003C\u003Ccolour muted-foreground>>\\nbutton-background:\\nbutton-foreground:\\nbutton-border:\\ncode-background: #f7f7f9\\ncode-border: #e1e1e8\\ncode-foreground: #dd1144\\ndirty-indicator: #c63636\\ndownload-background: #66cccc\\ndownload-foreground: \u003C\u003Ccolour background>>\\ndragger-background: \u003C\u003Ccolour foreground>>\\ndragger-foreground: \u003C\u003Ccolour background>>\\ndropdown-background: \u003C\u003Ccolour background>>\\ndropdown-border: #ddd\\ndropdown-tab-background-selected: #fff\\ndropdown-tab-background: #ececec\\ndropzone-background: #da8548\\nexternal-link-background-hover: inherit\\nexternal-link-background-visited: inherit\\nexternal-link-background: inherit\\nexternal-link-foreground-hover: inherit\\nexternal-link-foreground-visited: #0000aa\\nexternal-link-foreground: #0000ee\\nforeground: #283c46\\nmessage-background: #ecf2ff\\nmessage-border: #cfd6e6\\nmessage-foreground: #547599\\nmodal-backdrop: \u003C\u003Ccolour foreground>>\\nmodal-background: \u003C\u003Ccolour background>>\\nmodal-border: #999999\\nmodal-footer-background: #f5f5f5\\nmodal-footer-border: #dddddd\\nmodal-header-border: #eeeeee\\nmuted-foreground: #999999\\nnotification-background: #ffffdd\\nnotification-border: #999999\\npage-background: #f4f4f4\\npre-background: #f6f6f6\\npre-border: #cccccc\\nprimary: #127edd\\nselect-tag-background:\\nselect-tag-foreground:\\nsidebar-button-foreground: #a6a69c\\nsidebar-controls-foreground-hover: #000000\\nsidebar-controls-foreground: \u003C\u003Ccolour sidebar-button-foreground>>\\nsidebar-foreground-shadow: rgba(255,255,255, 0.8)\\nsidebar-foreground: #acacac\\nsidebar-muted-foreground-hover: #444444\\nsidebar-muted-foreground: #c0c0c0\\nsidebar-tab-background-selected: #ffffff\\nsidebar-tab-background: \u003C\u003Ccolour tab-background>>\\nsidebar-tab-border-selected: \u003C\u003Ccolour tab-border-selected>>\\nsidebar-tab-border: \u003C\u003Ccolour tab-border>>\\nsidebar-tab-divider: \u003C\u003Ccolour tab-divider>>\\nsidebar-tab-foreground-selected: \u003C\u003Ccolour tab-foreground-selected>>\\nsidebar-tab-foreground: \u003C\u003Ccolour tab-foreground>>\\nsidebar-tiddler-link-foreground-hover: \u003C\u003Ccolour primary>>\\nsidebar-tiddler-link-foreground: \u003C\u003Ccolour tab-foreground>>\\nsite-title-foreground: #353748\\nstatic-alert-foreground: #aaaaaa\\ntab-background-selected: #ffffff\\ntab-background: #eeeeee\\ntab-border-selected: #cccccc\\ntab-border: #cccccc\\ntab-divider: #d8d8d8\\ntab-foreground-selected: \u003C\u003Ccolour foreground>>\\ntab-foreground: #888888\\ntable-border: #dddddd\\ntable-footer-background: #a8a8a8\\ntable-header-background: #f0f0f0\\ntag-background: #ffeedd\\ntag-foreground: #000\\ntiddler-background: \u003C\u003Ccolour background>>\\ntiddler-border: #ddd\\ntiddler-controls-foreground-hover: #888888;\\ntiddler-controls-foreground-selected: #888888;\\ntiddler-controls-foreground: #cccccc\\ntiddler-editor-background: \u003C\u003Ccolour background>>\\ntiddler-editor-border-image: #ffffff\\ntiddler-editor-border: rgba(0,0,0,.2)\\ntiddler-editor-fields-even: #e0e8e0\\ntiddler-editor-fields-odd: #f0f4f0\\ntiddler-info-background: #f8f8f8\\ntiddler-info-border: #dddddd\\ntiddler-info-tab-background: #f8f8f8\\ntiddler-link-background: \u003C\u003Ccolour background>>\\ntiddler-link-foreground: \u003C\u003Ccolour primary>>\\ntiddler-subtitle-foreground: #aaaaaa\\ntiddler-title-foreground: #333\\ntoolbar-new-button:\\ntoolbar-options-button:\\ntoolbar-save-button:\\ntoolbar-info-button:\\ntoolbar-edit-button:\\ntoolbar-close-button:\\ntoolbar-delete-button:\\ntoolbar-cancel-button:\\ntoolbar-done-button:\\nuntagged-background: #999999\\nvery-muted-foreground: #888888\\n\",\n \"type\": \"application/x-tiddler-dictionary\",\n \"description\": \"A grey color palette for Notebook\",\n \"name\": \"Notebook Grey\",\n \"tags\": \"$:/tags/Palette $:/tags/notebook/Palette\"\n },\n \"$:/themes/nico/notebook/settings/codefontfamily\": {\n \"title\": \"$:/themes/nico/notebook/settings/codefontfamily\",\n \"created\": \"20210101213404232\",\n \"modified\": \"20210101214210227\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\"Fira Mono\\\",\\\"Liberation Mono\\\",Menlo,Courier,monospace\\n\"\n },\n \"$:/themes/nico/notebook/settings/fontfamily\": {\n \"title\": \"$:/themes/nico/notebook/settings/fontfamily\",\n \"created\": \"20210101213404232\",\n \"modified\": \"20210101213411800\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\"Segoe UI\\\",Helvetica,Arial,sans-serif,\\\"Apple Color Emoji\\\",\\\"Segoe UI Emoji\\\",\\\"Segoe UI Symbol\\\"\\n\"\n },\n \"$:/themes/nico/notebook/shortcuts/notebook-focus-search\": {\n \"title\": \"$:/themes/nico/notebook/shortcuts/notebook-focus-search\",\n \"created\": \"20201210122048919\",\n \"key\": \"((notebook-focus-search))\",\n \"modified\": \"20210115130024907\",\n \"tags\": \"$:/tags/KeyboardShortcut\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$action-sendmessage $message=\\\"tm-focus-selector\\\" $param=\\\".nc-topbar input\\\"/>\\n\"\n },\n \"$:/themes/nico/notebook/shortcuts/toggle-sidebar\": {\n \"title\": \"$:/themes/nico/notebook/shortcuts/toggle-sidebar\",\n \"created\": \"20210115130000707\",\n \"key\": \"((toggle-sidebar))\",\n \"modified\": \"20210115130021883\",\n \"tags\": \"$:/tags/KeyboardShortcut\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$list\\n filter=\\\"[[$:/state/notebook-sidebar]is[missing]] [{$:/state/notebook-sidebar}removeprefix[yes]]\\\"\\n emptyMessage=\\\"\\\"\\\"\u003C$action-setfield $tiddler=\\\"$:/state/notebook-sidebar\\\" text=\\\"yes\\\"/>\\\"\\\"\\\"\\n>\\n \u003C$action-setfield $tiddler=\\\"$:/state/notebook-sidebar\\\" text=\\\"no\\\"/>\\n\u003C/$list>\\n\"\n },\n \"$:/themes/nico/notebook/stickytitles\": {\n \"title\": \"$:/themes/nico/notebook/stickytitles\",\n \"created\": \"20201217172915960\",\n \"modified\": \"20201217180034682\",\n \"tags\": \"$:/tags/Stylesheet\",\n \"text\": \"\u003C$reveal state=\\\"$:/themes/nico/notebook/options/stickytitles\\\" type=\\\"match\\\" text=\\\"yes\\\">\\n\\n.tc-tiddler-title {\\n position: -webkit-sticky;\\n position: -moz-sticky;\\n position: -o-sticky;\\n position: -ms-sticky;\\n position: sticky;\\n top: {{$:/themes/nico/notebook/metrics/topbar-height}};\\n background: \u003C\u003Ccolour tiddler-background>>;\\n z-index: 500;\\n}\\n\\n@media (max-width: {{$:/themes/tiddlywiki/vanilla/metrics/sidebarbreakpoint}}) {\\n .tc-tiddler-title {\\n top: 0;\\n }\\n}\\n\\n\u003C$list filter=\\\"[range[100]]\\\">\\n`.tc-story-river .tc-tiddler-frame:nth-child(100n+`\u003C$text text=\u003C\u003CcurrentTiddler>>/>`) {\\nz-index: `\u003C$text text={{{ [[200]subtract\u003CcurrentTiddler>] }}}/>`;\\n}\\n`\\n\u003C/$list>\\n\u003C/$reveal>\\n\"\n },\n \"$:/themes/nico/notebook/tags/Sidebar\": {\n \"title\": \"$:/themes/nico/notebook/tags/Sidebar\",\n \"created\": \"20200429164516951\",\n \"list\": \"$:/themes/nico/notebook/ui/Buttons/menu $:/themes/nico/notebook/ui/Sidebar/Headings $:/themes/nico/notebook/ui/Sidebar/Search $:/themes/nico/notebook/Sidebar/Sections\",\n \"modified\": \"20201210205606504\",\n \"type\": \"text/vnd.tiddlywiki\"\n },\n \"$:/themes/nico/notebook/tags/SidebarSection\": {\n \"title\": \"$:/themes/nico/notebook/tags/SidebarSection\",\n \"created\": \"20200429201017275\",\n \"list\": \"$:/themes/nico/notebook/ui/Sidebar/Open $:/themes/nico/notebook/ui/Sidebar/Recent $:/themes/nico/notebook/ui/Sidebar/Tools $:/themes/nico/notebook/ui/Sidebar/More\",\n \"modified\": \"20201210215658901\",\n \"type\": \"text/vnd.tiddlywiki\"\n },\n \"$:/themes/nico/notebook/ui/Bottombar\": {\n \"title\": \"$:/themes/nico/notebook/ui/Bottombar\",\n \"created\": \"20200429113453340\",\n \"modified\": \"20201210210230886\",\n \"tags\": \"$:/tags/PageTemplate\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$reveal state=\\\"$:/state/notebook-bottombar\\\" type=\\\"match\\\" text=\\\"yes\\\" default=\\\"yes\\\" retain=\\\"yes\\\" animate=\\\"yes\\\">\\n \u003Cdiv class=\\\"nc-bar nc-bottombar\\\">\\n \u003C$list filter=\\\"[all[shadows+tiddlers]tag[$:/tags/NotebookTopbar]!has[draft.of]]\\\" variable=\\\"listItem\\\">\\n \u003C$reveal type=\\\"nomatch\\\" state=\u003C\u003Cconfig-title>> text=\\\"hide\\\" tag=\\\"div\\\">\\n \u003C$transclude tiddler=\u003C\u003ClistItem>> mode=\\\"block\\\"/>\\n \u003C/$reveal>\\n \u003C/$list>\\n \u003Cdiv class=\\\"left\\\">\\n {{$:/themes/nico/notebook/ui/Buttons/menu}}\\n \u003C/div>\\n \u003Cdiv class=\\\"right\\\">\\n {{$:/core/ui/SideBarSegments/page-controls}}\\n \u003C/div>\\n \u003C/div>\\n\u003C/$reveal>\\n\\n\"\n },\n \"$:/themes/nico/notebook/ui/Buttons/SwitchPalette\": {\n \"title\": \"$:/themes/nico/notebook/ui/Buttons/SwitchPalette\",\n \"created\": \"20201210171047824\",\n \"description\": \"Toggle between grey/beige colour palette\",\n \"modified\": \"20210118213335643\",\n \"tags\": \"$:/tags/PageControls\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Cspan class=\\\"desktop-only\\\">\\n \u003C$vars\\n palettes=\\\"[all[tiddlers+shadows]tag[$:/tags/notebook/Palette]]\\\"\\n popupTiddler=\u003C\u003Cqualify \\\"$:/state/notebook/palette-dropdown\\\">>\\n >\\n \u003C$button\\n popup=\u003C\u003CpopupTiddler>>\\n tooltip=\\\"Switch colours\\\"\\n aria-label=\\\"Switch colours\\\"\\n class=\u003C\u003Ctv-config-toolbar-class>>\\n >\\n \u003C$list filter=\\\"[\u003Ctv-config-toolbar-icons>match[yes]]\\\">\\n\\t{{$:/themes/nico/notebook/images/color-switch}}\\n \u003C/$list>\\n\\n \u003C$list filter=\\\"[\u003Ctv-config-toolbar-text>match[yes]]\\\">\\n\\t\u003Cspan class=\\\"tc-btn-text\\\">Switch colours\u003C/span>\\n \u003C/$list>\\n\\n \u003C$reveal state=\u003C\u003CpopupTiddler>> type=\\\"popup\\\" position=\\\"belowleft\\\" class=\\\"tc-drop-down\\\">\\n\\t\u003C$list filter=\u003C\u003Cpalettes>>>\\n\\t \u003C$button class=\\\"tc-btn-invisible\\\">\\n\\t {{!!name}}\\n\\t \u003C$action-setfield $tiddler=\\\"$:/palette\\\" text={{!!title}}/>\\n\\t \u003C/$button>\\n\\t\u003C/$list>\\n \u003C/$reveal>\\n\\n \u003C/$button>\\n \u003C/$vars>\\n\u003C/span>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Buttons/menu\": {\n \"title\": \"$:/themes/nico/notebook/ui/Buttons/menu\",\n \"created\": \"20200429115248943\",\n \"modified\": \"20210124211756417\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$reveal state=\\\"$:/state/notebook-sidebar\\\" type=\\\"match\\\" text=\\\"yes\\\" default=\\\"no\\\" retain=\\\"yes\\\" animate=\\\"no\\\">\\n \u003C$button set=\\\"$:/state/notebook-sidebar\\\" setTo=\\\"no\\\" tooltip=\\\"Toggle menu\\\" class=\\\"tc-btn-invisible sidebar-toggle open\\\">\\n {{$:/themes/nico/notebook/images/bars}}\\n \u003C/$button>\\n\u003C/$reveal>\\n\\n\u003C$reveal type=\\\"nomatch\\\" state=\\\"$:/state/notebook-sidebar\\\" text=\\\"yes\\\">\\n \u003C$button set=\\\"$:/state/notebook-sidebar\\\" setTo=\\\"yes\\\" tooltip=\\\"Toggle menu\\\" class=\\\"tc-btn-invisible sidebar-toggle\\\">\\n {{$:/themes/nico/notebook/images/bars}}\\n \u003C/$button>\\n\u003C/$reveal>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Search\": {\n \"title\": \"$:/themes/nico/notebook/ui/Search\",\n \"created\": \"20200429191943257\",\n \"modified\": \"20210126170723413\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\define advanced-search-actions()\\n\u003C$action-setfield $tiddler=\\\"$:/temp/advancedsearch/input\\\" text={{$:/temp/notebook-search}}/>\\n\u003C$action-setfield $tiddler=\\\"$:/temp/advancedsearch/refresh\\\" text=\\\"yes\\\"/>\\n\u003C$action-navigate $to=\\\"$:/AdvancedSearch\\\"/>\\n\\\\end\\n\\n\\\\define input-accept-actions()\\n\u003C$list filter=\\\"[\u003C__tiddler__>get[text]!is[missing]] ~[\u003C__tiddler__>get[text]is[shadow]]\\\">\\n \u003C$action-navigate $to={{{ [\u003C__tiddler__>get[text]] }}}/>\\n \u003C$action-deletetiddler $filter=\\\"[[$:/temp/search]] [\u003CsearchTiddler>] [\u003CsearchListState>]\\\"/>\\n\u003C/$list>\\n\\\\end\\n\\n\\\\define cancel-search-actions()\\n\u003C$list filter=\\\"[\u003CsearchTiddler>get[text]!match{$:/temp/search}]\\\" emptyMessage=\\\"\\\"\\\"\u003C$action-deletetiddler $filter=\\\"[[$:/temp/search]] [\u003CsearchTiddler>] [\u003CsearchListState>]\\\"/>\\\"\\\"\\\">\\n \u003C$action-setfield $tiddler=\\\"$:/temp/search\\\" text={{{ [\u003CsearchTiddler>get[text]] }}}/>\\n \u003C$action-setfield $tiddler=\\\"$:/temp/search/refresh\\\" text=\\\"yes\\\"/>\u003C/$list>\\n\\\\end\\n\\n\u003C$vars editTiddler=\\\"$:/temp/search\\\"\\n searchTiddler=\\\"$:/temp/search/input\\\"\\n searchListState=\u003C\u003Cqualify \\\"$:/state/search-list/selected-item\\\">>>\\n \u003C$macrocall $name=\\\"keyboard-driven-input\\\"\\n\\t tiddler=\u003C\u003CeditTiddler>>\\n\\t storeTitle=\u003C\u003CsearchTiddler>>\\n\\t selectionStateTitle=\u003C\u003CsearchListState>>\\n\\t refreshTitle=\\\"$:/temp/search/refresh\\\"\\n\\t type=\\\"search\\\"\\n\\t tag=\\\"input\\\"\\n\\t focus={{$:/config/Search/AutoFocus}}\\n\\t focusPopup=\\\"$:/state/popup/notebook-search\\\"\\n\\t class=\\\"tc-popup-handle\\\"\\n\\t filterMinLength={{$:/config/Search/MinLength}}\\n\\t placeholder=\\\"Search...\\\"\\n\\t inputAcceptActions=\u003C\u003Cinput-accept-actions>>\\n\\t inputCancelActions=\u003C\u003Ccancel-search-actions>>\\n\\t cancelPopups=\\\"yes\\\"\\n\\t configTiddlerFilter=\\\"[[$:/state/search/currentTab]!is[missing]get[text]] ~[{$:/config/SearchResults/Default}]\\\"\\n\\t />\\n \u003C$button\\n tooltip={{$:/language/Buttons/AdvancedSearch/Hint}}\\n aria-label={{$:/language/Buttons/AdvancedSearch/Caption}}\\n class=\\\"tc-btn-invisible tc-page-controls\\\"\\n >\\n {{$:/core/images/advanced-search-button}}\\n \u003C\u003Cadvanced-search-actions>>\\n \u003C/$button>\\n \u003C$reveal tag=\\\"div\\\" class=\\\"tc-block-dropdown-wrapper\\\" state=\\\"$:/state/popup/notebook-search\\\" type=\\\"nomatch\\\" text=\\\"\\\" default=\\\"\\\">\\n \u003C$list filter=\\\"[\u003CsearchTiddler>get[text]minlength{$:/config/Search/MinLength}limit[1]]\\\" emptyMessage=\\\"\\\" variable=\\\"listItem\\\">\\n \u003Cdiv class=\\\"tc-block-dropdown tc-search-drop-down\\\">\\n \u003C$tiddler tiddler=\u003C\u003CconfigTiddler>>>\\n {{$:/themes/nico/notebook/ui/Sidebar/SearchResults}}\\n \u003C/$tiddler>\\n \u003C/div>\\n \u003C/$list>\\n \u003C/$reveal>\\n\u003C/$vars>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar/Headings\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar/Headings\",\n \"created\": \"20200429160014174\",\n \"modified\": \"20201210210231267\",\n \"tags\": \"$:/themes/nico/notebook/tags/Sidebar\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Cdiv class=\\\"segment\\\">\\n \u003Cdiv class=\\\"content\\\">\\n \u003Ch1 class=\\\"tc-site-title\\\">\\n {{$:/SiteTitle}}\\n \u003C/h1>\\n \u003Cdiv class=\\\"tc-site-subtitle\\\">\\n {{$:/SiteSubtitle}}\\n \u003C/div>\\n \u003C/div>\\n\u003C/div>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar/Search\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar/Search\",\n \"created\": \"20200429191943257\",\n \"modified\": \"20210124220152702\",\n \"tags\": \"$:/themes/nico/notebook/tags/Sidebar\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003Cdiv class=\\\"mobile-only\\\">\\n \u003Cdiv class=\\\"segment\\\">\\n \u003Cdiv class=\\\"content search\\\">\\n {{$:/themes/nico/notebook/ui/Search}}\\n \u003C/div>\\n \u003C/div>\\n\u003C/div>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar/SearchResults\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar/SearchResults\",\n \"created\": \"20200429191943257\",\n \"modified\": \"20210126164631418\",\n \"tags\": \"\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\define searchResultList()\\n \u003Csmall>{{$:/language/Search/Matches/Title}}\u003C/small>\\n\\n \u003C$list filter=\\\"[!is[system]search:title{$(searchTiddler)$}sort[title]limit[250]]\\\">\\n \u003Cspan class={{{[\u003CcurrentTiddler>addsuffix[-primaryList]] -[\u003CsearchListState>get[text]] +[then[]else[tc-list-item-selected]] }}}>\\n \u003C$transclude tiddler=\\\"$:/core/ui/ListItemTemplate\\\"/>\\n \u003C/span>\\n \u003C/$list>\\n\\n \u003Csmall>{{$:/language/Search/Matches/All}}\u003C/small>\\n\\n \u003C$list filter=\\\"[!is[system]search{$(searchTiddler)$}sort[title]limit[250]]\\\">\\n \u003Cspan class={{{[\u003CcurrentTiddler>addsuffix[-secondaryList]] -[\u003CsearchListState>get[text]] +[then[]else[tc-list-item-selected]] }}}>\\n \u003C$transclude tiddler=\\\"$:/core/ui/ListItemTemplate\\\"/>\\n \u003C/span>\\n \u003C/$list>\\n\\\\end\\n\\n\u003Cdiv class=\\\"tc-search-results\\\">\\n \u003C\u003CsearchResultList>>\\n\u003C/div>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar/SectionTemplate\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar/SectionTemplate\",\n \"created\": \"20200429161226897\",\n \"modified\": \"20210202213859460\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\define sidebarHeading()\\n\u003C$vars tv-wikilinks=\\\"no\\\">\\n \u003C$transclude field=\\\"caption\\\">\\n \u003C$view field=\\\"title\\\"/>\\n \u003C/$transclude>\\n\u003C/$vars>\\n\\\\end\\n\\n\u003C$reveal state=\\\"$:/state/notebook-sidebar-section\\\" type=\\\"match\\\" text=\u003C\u003CcurrentTiddler>> default=\\\"no\\\" animate=\\\"no\\\">\\n \u003Cdiv class=\\\"segment section open\\\">\\n \u003C$button set=\\\"$:/state/notebook-sidebar-section\\\" setTo=\\\"\\\" class=\\\"tc-btn-invisible label\\\">\\n \u003C\u003CsidebarHeading>>\\n \u003Cspan class=\\\"caret\\\">{{$:/themes/nico/notebook/images/caret-down}}\u003C/span>\\n \u003C/$button>\\n \u003Cdiv class=\\\"content\\\">\\n \u003C$transclude $tiddler=\u003C\u003CcurrentTiddler>> mode=\\\"block\\\"/>\\n \u003C/div>\\n \u003C/div>\\n\u003C/$reveal>\\n\u003C$reveal state=\\\"$:/state/notebook-sidebar-section\\\" type=\\\"nomatch\\\" text=\u003C\u003CcurrentTiddler>> default=\\\"yes\\\" animate=\\\"no\\\">\\n \u003Cdiv class=\\\"segment section\\\">\\n \u003C$button set=\\\"$:/state/notebook-sidebar-section\\\" setTo=\u003C\u003CcurrentTiddler>> class=\\\"tc-btn-invisible label\\\">\\n \u003C\u003CsidebarHeading>>\\n \u003Cspan class=\\\"caret\\\">{{$:/themes/nico/notebook/images/caret-right}}\u003C/span>\\n \u003C/$button>\\n \u003C/div>\\n\u003C/$reveal>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar/Sections\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar/Sections\",\n \"created\": \"20200429163239707\",\n \"modified\": \"20210112213620486\",\n \"tags\": \"$:/themes/nico/notebook/tags/Sidebar\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$list filter=\\\"[all[shadows+tiddlers]!has[draft.of]tag[$:/tags/SideBar]]\\\">\\n {{||$:/themes/nico/notebook/ui/Sidebar/SectionTemplate}}\\n\u003C/$list>\\n\"\n },\n \"$:/themes/nico/notebook/ui/Sidebar\": {\n \"title\": \"$:/themes/nico/notebook/ui/Sidebar\",\n \"created\": \"20200428201218885\",\n \"modified\": \"20210112213605486\",\n \"tags\": \"$:/tags/PageTemplate\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\\\\whitespace trim\\n\\\\define config-title()\\n$:/config/SideBarSegments/Visibility/$(listItem)$\\n\\\\end\\n\\n\u003C$reveal state=\\\"$:/state/notebook-sidebar\\\" type=\\\"match\\\" text=\\\"yes\\\" default=\\\"no\\\" retain=\\\"yes\\\" animate=\\\"no\\\">\\n \u003C$scrollable fallthrough=\\\"no\\\">\\n \u003Cdiv class=\\\"nc-sidebar\\\">\\n \u003C$list filter=\\\"[all[shadows+tiddlers]tag[$:/themes/nico/notebook/tags/Sidebar]!has[draft.of]]\\\" variable=\\\"listItem\\\">\\n \u003C$reveal type=\\\"nomatch\\\" state=\u003C\u003Cconfig-title>> text=\\\"hide\\\" tag=\\\"div\\\">\\n \u003C$transclude tiddler=\u003C\u003ClistItem>> mode=\\\"inline\\\"/>\\n \u003C/$reveal>\\n \u003C/$list>\\n \u003C/div>\\n \u003C/$scrollable>\\n\u003C/$reveal>\\n\\n\"\n },\n \"$:/themes/nico/notebook/ui/Topbar\": {\n \"title\": \"$:/themes/nico/notebook/ui/Topbar\",\n \"created\": \"20200428203101797\",\n \"modified\": \"20210124213834458\",\n \"tags\": \"$:/tags/PageTemplate\",\n \"type\": \"text/vnd.tiddlywiki\",\n \"text\": \"\u003C$reveal state=\\\"$:/state/notebook-topbar\\\" type=\\\"match\\\" text=\\\"yes\\\" default=\\\"yes\\\" retain=\\\"yes\\\" animate=\\\"yes\\\">\\n \u003Cdiv class=\\\"nc-topbar-wrapper\\\">\\n \u003Cdiv class=\\\"nc-bar nc-topbar tc-adjust-top-of-scroll\\\">\\n \u003C$list filter=\\\"[all[shadows+tiddlers]tag[$:/tags/NotebookTopbar]!has[draft.of]]\\\" variable=\\\"listItem\\\">\\n \u003C$reveal type=\\\"nomatch\\\" state=\u003C\u003Cconfig-title>> text=\\\"hide\\\" tag=\\\"div\\\">\\n \u003C$transclude tiddler=\u003C\u003ClistItem>> mode=\\\"block\\\"/>\\n \u003C/$reveal>\\n \u003C/$list>\\n \u003Cdiv class=\\\"left\\\">\\n\\t{{$:/themes/nico/notebook/ui/Buttons/menu}}\\n {{$:/themes/nico/notebook/ui/Search}}\\n \u003C/div>\\n \u003Cdiv class=\\\"right\\\">\\n {{$:/core/ui/SideBarSegments/page-controls}}\\n \u003C/div>\\n \u003C/div>\\n \u003C/div>\\n\u003C/$reveal>\\n\\n\"\n }\n }\n}","bag":"default","revision":"0","version":"1.4.1","type":"application/json","title":"$:/themes/nico/notebook","source":"https://github.com/NicolasPetton/Notebook","plugin-type":"theme","name":"Notebook theme","list":"LICENSE changelog","description":"A clean, uncluttered TiddlyWiki theme","dependents":"$:/themes/tiddlywiki/vanilla $:/plugins/nico/notebook-mobile","core-version":">=5.1.22","author":"NicolasPetton"}, {"created":"20200429144554294","title":"$:/themes/nico/notebook/metrics/sidebar-width","modified":"20230423163514560","tags":"","type":"text/vnd.tiddlywiki","text":"300px"}, diff --git a/src/3rd/js/plugin/frontend/frontend.js b/src/3rd/js/plugin/frontend/frontend.js index 06e03cd..2e16b58 100644 --- a/src/3rd/js/plugin/frontend/frontend.js +++ b/src/3rd/js/plugin/frontend/frontend.js @@ -9,7 +9,7 @@ window.frontend = (opts) => new Proxy({ - + `, el: null, @@ -95,10 +95,10 @@ window.frontend = (opts) => new Proxy({ },2000 ) xrf.addEventListener('href', (data) => { - if( !data.selected ) return + if( !data.selected ) return let html = `${data.mesh.isSRC && !data.mesh.portal ? 'src' : 'href'}${ data.xrf ? data.xrf.string : data.mesh.userData.src}
    ` - let metadata = data.mesh.userData + let metadata = data.mesh.userData let meta = xrf.Parser.getMetaData() let hasMeta = false @@ -134,18 +134,18 @@ window.frontend = (opts) => new Proxy({ document.addEventListener('network.connect', (e) => { console.log("network.connect") - window.notify("🪐 connecting to awesomeness..") + window.notify("🪐 connecting to awesomeness..") $chat.send({message:`🪐 connecting to awesomeness..`,class:['info'], timeout:5000}) }) document.addEventListener('network.connected', (e) => { - window.notify("🪐 connected to awesomeness..") + window.notify("🪐 connected to awesomeness..") $chat.visibleChatbar = true $chat.send({message:`🎉 ${e.detail.plugin.profile.name||''} connected!`,class:['info'], timeout:5000}) }) document.addEventListener('network.disconnect', () => { - window.notify("🪐 disconnecting..") + window.notify("🪐 disconnecting..") }) document.addEventListener('network.info', (e) => { @@ -179,7 +179,7 @@ window.frontend = (opts) => new Proxy({ if( show ){ $chat.visible = true }else{ - $chat.visible = false + $chat.visible = false $menu.toggle(false) } return true @@ -199,7 +199,7 @@ window.frontend = (opts) => new Proxy({ input.accept = Object.keys(contentLoaders).join(","); input.onchange = () => { let files = Array.from(input.files); - let file = files.slice ? files[0] : files + let file = files.slice ? files[0] : files for( var i in contentLoaders ){ let r = new RegExp('\\'+i+'$') if( file.name.match(r) ) return contentLoaders[i](file) @@ -213,12 +213,12 @@ window.frontend = (opts) => new Proxy({ notify(_str,opts){ if( window.outerWidth < 800 ) return if( window.accessibility && window.accessibility.enabled ) return $chat.send({message:_str,class:['info']}) - opts = opts || {status:'info'} + opts = opts || {status:'info'} opts = Object.assign({ status, timeout:4000 },opts) opts.message = _str if( typeof str == 'string' ){ - str = _str.replace(/(^\w+):/,"
    \$1
    ") - if( !opts.status ){ + str = _str.replace(/(^\w+):/,"
    \$1
    ") + if( !opts.status ){ if( str.match(/error/g) ) opts.status = "danger" if( str.match(/warning/g) ) opts.status = "warning" } @@ -243,7 +243,7 @@ window.frontend = (opts) => new Proxy({ updateHashPosition(randomize){ // *TODO* this should be part of the XRF Threejs framework - if( typeof THREE == 'undefined' ) THREE = xrf.THREE + if( typeof THREE == 'undefined' ) THREE = xrf.THREE let radToDeg = THREE.MathUtils.radToDeg let toDeg = (x) => x / (Math.PI / 180) let camera = document.querySelector('[camera]').object3D.parent // *TODO* fix for threejs @@ -267,13 +267,13 @@ window.frontend = (opts) => new Proxy({ }, copyToClipboard(text){ - // copy url to clipboard + // copy url to clipboard var dummy = document.createElement('input') document.body.appendChild(dummy); dummy.value = text; dummy.select(); document.execCommand('copy'); - document.body.removeChild(dummy); + document.body.removeChild(dummy); }, share(opts){ @@ -285,9 +285,9 @@ window.frontend = (opts) => new Proxy({ document.location.hash += `&pos=${ network.posName || network.pos }` } let url = window.location.href - if( opts.linkonly ) return url + if( opts.linkonly ) return url this.copyToClipboard( url ) - // End of *TODO* + // End of *TODO* if( opts.notify ){ window.notify(`

    ${ network.connected ? 'Meeting link ' : 'Link'} copied to clipboard!

    Now share it with your friends ❤️
    @@ -316,12 +316,12 @@ window.frontend = (opts) => new Proxy({ title: 'your meeting link' }) } - $menu.collapse = true + $menu.collapse = true } }, -{ - // auto-trigger events on changes +{ + // auto-trigger events on changes get(me,k,receiver){ return me[k] }, set(me,k,v){ let from = me[k] @@ -332,5 +332,5 @@ window.frontend = (opts) => new Proxy({ } } }) - + frontend = frontend({xrf,document}).init()