Socket
Socket
Sign inDemoInstall

@techandsoftware/teletext-service

Package Overview
Dependencies
1
Maintainers
1
Versions
9
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.1.2 to 0.2.1

10

package.json
{
"name": "@techandsoftware/teletext-service",
"version": "0.1.2",
"version": "0.2.1",
"description": "Teletext service API and web application to view pages and navigate between them",

@@ -8,4 +8,4 @@ "module": "public/dist/teletext-service.min.js",

"scripts": {
"prestart": "npm run copyfonts",
"start": "rollup -c -w",
"predev": "npm run copyfonts",
"dev": "rollup -c -w",
"build": "rollup -c rollup.prod.config.js",

@@ -27,3 +27,3 @@ "copyfonts": "cp -nr node_modules/@techandsoftware/teletext-fonts/* public/fonts",

"@techandsoftware/teletext": "^0.12.0",
"@techandsoftware/teletext-caster": "^0.10.0",
"@techandsoftware/teletext-caster": "^0.10.1",
"eslint": "^7.25.0",

@@ -37,3 +37,3 @@ "rollup": "^2.47.0",

"public/index.html",
"public/dist",
"public/dist/teletext-service.min.*",
"package.json.license"

@@ -40,0 +40,0 @@ ],

// SPDX-FileCopyrightText: (c) 2021 Tech and Software Ltd.
// SPDX-FileCopyrightText: (c) 2017 dosaygo
// SPDX-License-Identifier: AGPL-3.0-only OR LicenseRef-uk.ltd.TechAndSoftware-1.0
// LicenseRef-uk.ltd.TechAndSoftware-1.0 refers to https://techandsoftware.robdev.org.uk/LICENSES/LicenseRef-uk.ltd.TechAndSoftware-1.0.txt
const t=new Set(["Uint1Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","UInt32Array","Float32Array","Float64Array"]),s=Uint8Array,i=Symbol();class e{constructor(t,{length:i=null,buffer:e=null,byteOffset:n=0,byteLength:r=null}={}){let h;e?i=8*(r||e.byteLength):i||(i=0);const o=s.BYTES_PER_ELEMENT,a=8*o,c=a-1,l=(t=>{let s=0;for(;t>>=1;)s++;return s})(a),A=Math.max(1,i+c>>l);e?h=new s(e,n,A):(e=new ArrayBuffer(o*A),h=new s(e)),Object.assign(this,{buffer:e,byteOffset:n,length:i,wordSize:a,wordCount:A,wordSizeMask:c,wordSizeShift:l,internal:h})}toArray(){const t=new Uint8Array(this.length);for(let s=0;s<this.wordCount;s++){const i=this.internal[s];for(let e=s*this.wordSize;e<(s+1)*this.wordSize;e++)t[e]=this.getBit(e,i)}return t}getBit(t,s){if(!(t>=this.length))return null==s&&(s=this.internal[t>>this.wordSizeShift]),s>>(t&this.wordSizeMask)&1}setBit(t,s){if(t>=this.length)return;const i=t>>this.wordSizeShift,e=t&this.wordSizeMask,n=this.internal[i];let r=n;return r|=s<<e,r&=~((1&~s)<<e),n!==r&&(this.internal[i]=r),s}}class n{constructor(t,s=0,n=null){let h,l,A;switch(c(t)){case"Number":h=t=~~t,l=new e(this,{length:h});break;case"ArrayBuffer":l=new e(this,{buffer:t,byteOffset:s,byteLength:n});break;case"Undefined":case"Null":case"RegExp":case"Infinity":h=0,l=new e(this,{length:h});break;case"Array":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"UInt32Array":case"Float32Array":case"Float64Array":case"Uint1Array":case"Object":default:A=o(t),l=new e(this,{length:A.length}),A.forEach(((t,s)=>l.setBit(s,a(t))))}return this[i]=l,new r(this)}static get BYTES_PER_ELEMENT(){return.125}static get name(){return"Uint1Array"}static get length(){return 0}static get[Symbol.species](){return this}static[Symbol.hasInstance](t){return t.__proto__=this}static from(t){const s=o(t);return new n(s)}static of(...t){return n.from(t)}get buffer(){return this[i].buffer}get byteLength(){return this.length+7>>3}get byteOffset(){return this[i].byteOffset}get length(){return this[i].length}get[Symbol.toStringTag](){return"Uint1Array"}copyWithin(t,s=0,i=this.length){if(!Number.isInteger(t))return this;const e=new Uint8Array(i-s);for(let t=s;t<i;t++)e[t-s]=this[t];return this.set(e,t),this}entries(){return this[i].toArray().entries()}every(...t){return this[i].toArray().every(...t)}fill(t,s=0,i=this.length){for(let e=s;e<i;e++)this[e]=t;return this}filter(...t){return new n(this[i].toArray().filter(...t))}find(...t){return this[i].toArray().find(...t)}findIndex(...t){return this[i].toArray().findIndex(...t)}forEach(...t){this[i].toArray().forEach(...t)}includes(...t){return this[i].toArray().includes(...t)}indexOf(...t){return this[i].toArray().indexOf(...t)}join(...t){return this[i].toArray().join(...t)}keys(...t){return this[i].toArray().keys(...t)}lastIndexOf(...t){return this[i].toArray().lastIndexOf(...t)}map(...t){return new n(this[i].toArray().map(...t))}reduce(...t){return this[i].toArray().reduce(...t)}reduceRight(...t){return this[i].toArray().reduceRight(...t)}reverse(){const t=this[i].toArray().reverse();return this.set(t),this}set(s,i=0){if(!Number.isInteger(i))return;const e=c(s);if("Array"!==e&&!t.has(e))return;const n=Math.min(s.length+i,this.length);s=s.map((t=>a(t)));for(let t=i;t<n;t++)this[t]=s[t-i]}slice(...t){return new n(this[i].toArray().slice(...t))}sort(...t){const s=this[i].toArray().sort(...t);return this.set(s),this}subarray(...t){return new n(this[i].toArray().subarray(...t))}values(...t){return this[i].toArray().values(...t)}toLocaleString(...t){return Array.from(this).toLocaleString()}toString(){return""+Array.from(this)}[Symbol.iterator](){return this[i].toArray()[Symbol.iterator]()}valueOf(){return this}toJSON(){return Array.from(this)}}function r(t){const s=t[i];return new Proxy(t,{get(i,e,n){const r="string"==typeof e?parseInt(e):e;return Number.isInteger(r)?s.getBit(r):Reflect.get(t,e)},set(i,e,n,r){const h="string"==typeof e?parseInt(e):e;return Number.isInteger(h)?(s.setBit(h,a(n)),!0):Reflect.set(t,e,n)}})}const h=/\[object (\w+)]/;function o(t){const s=[];for(let i of t){const t=a(i);s.push(t)}return s}function a(t){return"number"!=typeof t||Number.isNaN(t)?new Boolean(t).valueOf():t%2}function c(t){const s=t&&t.constructor?t.constructor.name:null,i=h.exec(Object.prototype.toString.call(t))[1];return i!==s&&s?s:i}class l{static tt(t,s){const i=(t=t.replace(/-/g,"+").replace(/_/g,"/")).length%4;if(i){if(1===i)throw Error("Utils.decodeBase64URLEncoded E16: Input base64url string is the wrong length to determine padding");t+=Array(5-i).join("=")}const e=[...s(t)].map((t=>(t=>{if(t in A)return A[t];const s=[...t.charCodeAt(0).toString(2).padStart(8,"0")].reverse();return A[t]=Number.parseInt(s.join(""),2),A[t]})(t))),r=new ArrayBuffer(e.length);return new Uint8Array(r).set(e),(t=>{const s=[];for(let i=0;i<25;i++){const e=[];for(let s=0;s<40;s++){let n=6,r=0;const h=280*i+7*s;for(let s=h;s<h+7;s++)r+=t[s]*Math.pow(2,n),n--;e.push(String.fromCharCode(r))}s.push(e.join(""))}return s})(new n(r))}static st(t){const s=[];let i=!1;for(const e of[...t]){const t=e.charCodeAt(0);27==t?i=!0:t>=128?s.push(String.fromCharCode(t-128)):i?(s.push(String.fromCharCode(t-64)),i=!1):s.push(e)}return s}static it(t){const s=[],i=/^OL,(\d{1,2}),(.+)/;for(const e of[...t]){const t=e.match(i);null!=t&&(s[t[1]]=l.st(t[2]))}return s}static et(t){return-1!="ﻰﺋﺊﭼﭽﭘﭙﮔﻎﻼﻬﻪﻊﺔﺒﺘﺎﺑﺗﺛﺟﺣﺧﺳﺷﺻﺿﻃﻇﻋﻏﺜﺠﺤﺨـﻓﻗﻛﻟﻣﻧﻫﻰﻳﻴﻌﻐﻔﻘﻠﻤﻨ".indexOf(t)}}const A={},g={ENGINEERING:"QIECBAgQIIcWLGg2EDdy3QIKnXKgYtUE7f2QA2TB0wYr2DECAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAYMS54fzJmix4-YCDToOLOjyZ0WLSkzo6AkcGHuZUcRHlB4dgyAAQAEABAAQAEABAAQAEABAAQAEABAAQAEABAAQAEABAAWDP9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_YNCho9zImSoAqBGoAp0FUy8-iChhz5UCA4MPEuZYgTAFyAFg1_f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f2DYCAAoACACeQHkBdYTJlixIkSKlSJEoUKIEBQABAAQAEABYN_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_39g4AgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgGDn9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_YsAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIBix_f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f2LICAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAYs_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_39i0AgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgGLX9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_Ytq-jT0yg7OXZs39w0Pzh3Ao_LLl3BZuHPl3dMIGllyBIWzrlLmkKJGTSJUycsoUqlZJYtXLzLBiyZlWjVs3IuHLp2UePXz9AgQokaBIlTJ0ChSqVoFi1cvQMGLJmgaNWzdA4cunaB49fP0ECDChoIkWNHQSJMqWgmTZ09BQo0qaCpVrV0FizatoLl29fQYMOLGgyZc2dBo06taDZt3b0HDjy5oOnXt3QePPr2g-ff38pgw4sZHJlzZyujTq1ktm3dvNcOPLmW6de3cn48-vZf59_fwZiHv3Y8uHYIjbMPPQDVCxcLf4E0-mXDk8mI-_dlFCn5a9_DKr6q-qvqr6q-qvqr6AFS390DJoGQKr6q-qvqr6q-qvqr6o",ADVERT:"QIECBAgQIJ9KDDmRUDZi3QU8PRk1QQeHIHDaIEDJiwYumDACdDwcnbLy6aeeXbl3dECBAgQIECBAgQIECBAgQIHwZkvcoCx0og8LNGjYwQPEjzpoWaNjBA82YHnTQwabEjTpowPEiBAgLHSiBbs1atjFA9SPe2pZqQNUHX1qQatSlrqQNW-5UsaIECAsdKIFidUqQJUCVAlVKlipchQJUCJanVIEqpAlSqlC5CgQIEB0ogQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQHSKBAgQYEH7ogQaGCApw_fEm54R3PCm5JuSKHoFUEVIECAudIoECBB6-___TB-_v0JTU_WqkZHFyQKHmjYgYBECpAqQIC50igQIEH___3_-iD__6FFSAig-IP6JCg26lzRr3avEgFUgLnSKBAg1f1X9lv_9NSBAgI6G-HX1V_EqBUqQJUqXBzagVSAudIoECD9_Qa2qL__6IMDzoq682qdAgQIEARAgQIECBAgVIC50igQIP_9AiaoFX__0VfV_1kjQIECBAgQBECBAgAoECpAgLnSKBBq__0CBCgQa___oreokCBAgQIECBAgQBECBAgVIECAudIoEHr__QIECBAg3_36FAgQIECBAgQIECAIgQIFSBAgQIAZ0igQf_7dAgKIECAinKf9bTR9QIv-N6i_ofzNagQIECBAgJnSKDR__tUBRAoe6NiBB_XYf_rqg_q2iD-gRb-iBAgQIECAmdIoNX_-1QFECDrq9IMH9h664P_D-w34P7DZ4ToECBAgQICZ0ig___5TQ8SfEHzQ82MPCzpoedEHzA82MPjDQ0-LNDSk0JnSOD___lNXVh_Qf9T3cx_oP-prqa_1S3Y0_q_zX-s1NdTUmdI6v_9-U1NUH9B_1NdTX-g_6mvpL_wMNTX-g1Nf6DAz1tSZ0j-_v0JREjQokaFEhRIUSNCiRoUCNAjRoEaBEhRo0CNGgBnSP9OgQFECCNPpIIVKfDkVaUWmggzoiCFPny5M6PTQIECAGdIjUAGlJnR0DBu5coGrFm0YMEE-kgpxYqChBjxUDNuwQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAy92np007s6AFSy9tOXvzQA7O_ryQTd-7L5DQVtpBJ3ZMvg",UK:"QIECBAgQIIcWLGg2EDFy2QIJu_cgZNUETLjQA2TN0xYr2DAodJIECBAgQIEGDB4_PUCBAgQIECBAgQIECBAgQIEANkvaMih0kgQIECDA1Qfv__OgQYGCBAgQIECBAgQIECBAgQIECBAgKHSSBAgQIH6FR-__-v7___oECBAgQIEAORPmxUE6LXpoECAodJIECBAoQKum7______9-gQIECBAgQA82_Zs39-aB8-QIAh0kgQIECBAgSev_____v06BAgQIECBAgQIECBAgQIECBAgKHSSBAgQIECBR00____-_w9GCBAgQIECBAgQIECBAgQIECAodJIECBAgQIECD8rx________ECBAgQIECBAgQIECBAgQICh0kgQIECBAgQLETRlv_______6oECBAgQIECBAgQIECBAgKHSyBAgQIHGQlwYIEH_-_x_____9-dECBAgQIECBAgQIECAIdLIECDAmJbfz_-0RJ0qBV________7sECBAgQIECBAgQIAh0sgQIMzAl-__fX5Sg0JECvX______586IECBAgQIECBAgCHSyBAgwJiW9OjX_0qBAgQIEX________-l8fPjBAgQIECAIdLIEHBYhQIECBQxQICWDhg5fv____________tUCBAgQIAh0sgzIECBAgQIEGlAgQEtP_______________-lQIECBAgCHSyBUwQIECBAgQakCBASQqv_____________-6FAgQIECAIdLIECJygQIECBAgaoEBJBg______________5-OiBAgQIAh0sgQKGKBAgQIEHBKgJIMH7____8v__________QoECBAgCHSyBRmQIECBA4RoECAkgVoVaNel________r16FAgQIECAIdLINCFAgwOEyBAgQICSBAgQePn7___r06RAgQIECBAgQIAh0sgQLeKxCgQIECBAgJIECDR__v0aNGhQIECBAgQIECBAgCHSSBAgQIECBAgQIECBAgQYP3_-1QIECBAgQIECBAgQIECAIdJIECBAgQIECBAgQIECBB6boUSBAgQIECBAgQIECBAgQIAh0kgQIECBAgQIECBAgQIFStAgQIECBAgQIECBAgQIECBAgAzsvjognZe_MFIy4cmzTuy8wdTfwQU-G_l0DVKy-lhyad6A",SPLASH:"QIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECAsaMIEGDx8YIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQICxowg0N2bdmgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgLGjCBFvz9_6BAZQIECBAgQIECAig0NECBAgQIECBAgQIECAsaMcOD5tjyoGCBAgQIECBAgQICLhCgQIECBAgQIECBAgQICxowoTod79ArSEcHBAgQIECBAg0ITKBAgQcGCBAgQIECBAgLGjCBBgXIUCAyRXmlLBAgQIECBuZ4fPn___aoECBAgQIECBAaQIECBAgQIEBFAgQaTPDh8-f___-vXo9f9qgQIECBAgQIECBAgQIEBFAgQcOHz5____69ejRoECBAg__0CBAgQIECBAgQIECBAgQEUCL___r16NGXQIOHDh8-NCOD-3QIECBAgQIECBAgQIECBARQINf0ug-fPi9evRo0aBAgI6v6VAgQIECBAgQIECBAgQIEBFAgRf2hfBw4cOHD58-fPiAj-_oECBAgQIECBAgQIECBAgQEUCBBr-l0SNGjRo0CBAgQEcH9qgQIECBAgQIECBAgQIECBARQIECL-0Lr169ev-fPnxAR1f0KBAgQIECBAgQIAiBAgQIEBFAgQINf3hw4cOCBAgQIEBH-_QIECBAgQIECBAgCIECBAgQIEB1ARRL1-_____________7VAgOIECBAgQIECAIgQIECBAgQHUBNAgQf26BAgQIN_8ijRoECA4gQIECBAgQIAiBAgQIECA6gQE0CDV_QoECBAgRf2iBAgQIEBxAgQIECBAgCIECBAgQIDqBAgQE0aFAgQIECBAgQIECBAgQHECBAgQIECAIgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIBp0Kg3cNqDSggdMuPRh3ZOe_N074eWVf0y7MvTL46IECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQKMalAyYMmKCplx6ECZBT35unfDyyoJnTIuQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA"},_="http://www.w3.org/2000/svg";let u,E,C=0;class I{constructor(){}rt(){return this.nt}ht(){this.nt=null}_t(t,s){if("object"==typeof t)for(const s in t)null==t[s]?this.nt.removeAttribute(s):this.nt.setAttribute(s,t[s]);else{if(void 0===s)return this.nt.getAttribute(t);null==s?this.nt.removeAttribute(t):this.nt.setAttribute(t,s)}return this}ot(t){if(!this.at(t)){const s=this.lt();s.push(t),this.nt.setAttribute("class",s.join(" "))}return this}at(t){return-1!==this.lt().indexOf(t)}lt(){const t=this.nt.getAttribute("class");return null==t?[]:t.split(" ")}At(t){return this.at(t)&&this.nt.setAttribute("class",this.lt().filter((s=>s!==t)).join(" ")),this}ct(t){return this.at(t)?this.At(t):this.ot(t),this}gt(t,s){if("object"==typeof t)for(const s in t)null==t[s]?delete this.nt.dataset[s]:this.nt.dataset[s]=t[s];else{if(void 0===s)return this.nt.dataset[t];null==s?delete this.nt.dataset[t]:this.nt.dataset[t]=s}return this}}class f extends I{constructor(t){return super(),u=t,E=u.document,this.nt=E.createElementNS(_,"svg"),this.nt.setAttribute("xmlns",_),this}ut(t){const s=E.querySelector(t);if(!s)throw Error("@techandsoftware/teletext: E117: addTo failed to match provided selector");return s.appendChild(this.nt),this}Ct(t){return this.nt.setAttribute("viewBox",t),this}ft(t,s){return this.nt.setAttribute("width",t),this.nt.setAttribute("height",s),this}It(t){const s=E.createElementNS(_,"style");return s.append(t),this.nt.append(s),this}Et(){const t=new B;return this.nt.append(t.rt()),t}Bt(){return this.nt.clientWidth}dt(){return this.nt.clientHeight}Qt(t){const s=new b(t);return this.nt.append(s.rt()),s}}class B extends I{constructor(){return super(),this.nt=E.createElementNS(_,"g"),this.yt=[],this}Et(){const t=new B;return this.nt.append(t.rt()),this.yt.push(t),t}bt(t){const s=new y(t);return this.nt.append(s.rt()),this.yt.push(s),s}wt(){const t=new m;return this.nt.append(t.rt()),t}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),this.yt.push(i),i}xt(){return this.yt[this.yt.length-1]}Ut(){return this.yt}vt(t){return this.nt.setAttribute("clip-path",`url("#${t.rt().id}")`),this}kt(){return this.nt.removeAttribute("clip-path"),this}Rt(){this.nt.parentNode&&this.nt.parentNode.removeChild(this.nt),this.nt=null,this.yt.forEach((t=>t.ht())),this.yt=[]}Ft(t,s,i,e){const n=new S(t,s,i,e);return this.nt.append(n.rt()),this.yt.push(n),n}Lt(t){const s=new d(t);return this.nt.append(s.rt()),this.yt.push(s),s}Dt(t,s){const i=new Q(t,s);return this.nt.append(i.rt()),this.yt.push(i),i}}class Q extends I{constructor(t,s){return super(),this.nt=E.createElementNS(_,"image"),this.nt.setAttribute("width",parseInt(t)),this.nt.setAttribute("height",parseInt(s)),this}attr(...t){return this._t(...t)}}class d extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"use"),this.nt.setAttribute("href","#"+t),this}Nt(t){return this.nt.setAttribute("fill",t),this}Gt(t,s){return this.nt.setAttribute("x",t),this.nt.setAttribute("y",s),this}}class b extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"symbol"),this.nt.setAttribute("id",t),this}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),i}}class y extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"text"),this.nt.append(t),this}bt(t){return this.nt.textContent=t,this}Nt(t){return this.nt.setAttribute("fill",t),this}}class m extends I{constructor(){return super(),this.nt=E.createElementNS(_,"defs"),this}Ht(){const t=new w;return this.nt.append(t.rt()),t}jt(t){return[...this.nt.querySelectorAll(t)].map(v)}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),i}}class w extends I{constructor(){return super(),this.nt=E.createElementNS(_,"clipPath"),this.nt.setAttribute("id","clipPath-"+C),C++,this}Ut(){return[...this.nt.children].map(v)}Ot(t){this.nt.appendChild(t.rt())}}class p extends I{constructor(t,s){if(super(),t instanceof u.SVGElement)return this.nt=t,this;const i=t;return this.nt=E.createElementNS(_,"rect"),this.nt.setAttribute("width",parseInt(i)),this.nt.setAttribute("height",parseInt(s)),this}Nt(t){return this.nt.setAttribute("fill",t),this}Gt(t,s){return this.nt.setAttribute("x",t),this.nt.setAttribute("y",s),this}Bt(t){return void 0===t?parseInt(this.nt.getAttribute("width")):(this.nt.setAttribute("width",parseInt(t)),this)}dt(t){return void 0===t?parseInt(this.nt.getAttribute("height")):(this.nt.setAttribute("height",parseInt(t)),this)}Rt(){this.nt.parentNode&&this.nt.parentNode.removeChild(this.nt),this.nt=null}}class S extends I{constructor(t,s,i,e){return super(),this.nt=E.createElementNS(_,"line"),this.nt.setAttribute("x1",t),this.nt.setAttribute("y1",s),this.nt.setAttribute("x2",i),this.nt.setAttribute("y2",e),this}}function v(t){let s;switch(t.constructor.name){case"SVGRectElement":s=new p(t);break;default:throw Error("SVG:wrapSVGElement Unable to wrap SVG element of type "+t.constructor.name)}return s}const x={BLACK:Symbol(),RED:Symbol(),GREEN:Symbol(),YELLOW:Symbol(),BLUE:Symbol(),MAGENTA:Symbol(),CYAN:Symbol(),WHITE:Symbol()};Object.freeze(x);const k={Pt:Symbol(),Mt:Symbol(),qt:Symbol(),Tt:Symbol()};Object.freeze(k);const U={zt:Symbol(),Jt:Symbol(),Yt:Symbol(),Vt:Symbol()};Object.freeze(U);class N{static charFromTextColour(t){if(t in G)return G[t];throw Error("Attributes.charFromTextColour: bad colour: "+t)}static charFromGraphicColour(t){if(t in L)return L[t];throw Error("Attributes.charFromGraphicColour: bad colour")}static charFromAttribute(t){if(t in P)return P[t];throw Error("Attributes.charFromAttribute: bad attribute")}}function D(t){return O[t]}N.TEXT_COLOUR=k.Pt,N.MOSAIC_COLOUR=Symbol(),N.NEW_BACKGROUND=Symbol(),N.BLACK_BACKGROUND=Symbol(),N.CONTIGUOUS_GRAPHICS=k.Mt,N.SEPARATED_GRAPHICS=k.qt,N.ESC=Symbol(),N.FLASH=Symbol(),N.STEADY=Symbol(),N.NORMAL_SIZE=U.zt,N.DOUBLE_HEIGHT=U.Jt,N.DOUBLE_WIDTH=U.Yt,N.DOUBLE_SIZE=U.Vt,N.CONCEAL=Symbol(),N.HOLD_MOSAICS=Symbol(),N.RELEASE_MOSAICS=Symbol(),N.START_BOX=Symbol(),N.END_BOX=Symbol(),N.Kt=Symbol();const O={[x.BLACK]:"#000",[x.RED]:"#f00",[x.GREEN]:"#0f0",[x.YELLOW]:"#ff0",[x.BLUE]:"#00f",[x.MAGENTA]:"#f0f",[x.CYAN]:"#0ff",[x.WHITE]:"#fff"};Object.freeze(O);const j={"\0":x.BLACK,"":x.RED,"":x.GREEN,"":x.YELLOW,"":x.BLUE,"":x.MAGENTA,"":x.CYAN,"":x.WHITE};Object.freeze(j);const F={"":x.BLACK,"":x.RED,"":x.GREEN,"":x.YELLOW,"":x.BLUE,"":x.MAGENTA,"":x.CYAN,"":x.WHITE};Object.freeze(F);const R={"\b":N.FLASH,"\t":N.STEADY,"\n":N.END_BOX,"\v":N.START_BOX,"\f":N.NORMAL_SIZE,"\r":N.DOUBLE_HEIGHT,"":N.DOUBLE_WIDTH,"":N.DOUBLE_SIZE,"":N.CONCEAL,"":N.CONTIGUOUS_GRAPHICS,"":N.SEPARATED_GRAPHICS,"":N.ESC,"":N.BLACK_BACKGROUND,"":N.NEW_BACKGROUND,"":N.HOLD_MOSAICS,"":N.RELEASE_MOSAICS},G={};for(const t in j)G[j[t]]=t,R[t]=j[t];Object.freeze(G);const L={};for(const t in F)L[F[t]]=t,R[t]=F[t];Object.freeze(L),Object.freeze(R);const P={};for(const t in R)P[R[t]]=t;Object.freeze(P);const H={0:Symbol(),1:Symbol(),1.5:Symbol(),2.5:Symbol()};Object.freeze(H);const M={};M[H[0]]=[1,2,3,4,5,6,7,8,9,17,18,19,20,21,22,23],M[H[1]]=[...M[H[0]]].concat([10,11,12,13,24,25,26,27,28,29,30,31]),M[H[1.5]]=[...M[H[1]]].concat([0,16]),M[H[2.5]]=[...M[H[1.5]]].concat([14,15]),Object.freeze(M);const q={Zt:{Xt:10.4,Wt:-5.2},$t:{Xt:10,Wt:-4.5}};Object.freeze(q);class T{constructor(t,s){this.ts=new f(s).Ct("0 0 399 249").ft(800,666.6666666666666)._t({preserveAspectRatio:"none",style:"font-family: sans-serif"}).It("@font-face {\nfont-family: 'Unscii';\nsrc: url('fonts/unscii-16.woff') format('woff'), \nurl('fonts/unscii-16.ttf') format('truetype'),\nurl('fonts/unscii-16.otf') format('opentype');\nunicode-range: U+0000-00FF, U+2022, U+2500, U+2502, U+250C, U+2510, U+2514, U+2518, U+251C, U+251D, U+2524, U+2525, U+252C, U+252F, U+2534, U+2537, U+253C, U+253F, U+2588, U+258C, U+2590, U+2592, U+25CB, U+25CF, U+25E2-25E5, U+2B60-2B63, U+E0C0-E0FF, U+1FB00-1FB70, U+1FB75, U+1FBA0-1FBA7;\n-webkit-font-smoothing: none;\nfont-smooth: never;\n}\n@font-face {\nfont-family: 'Bedstead';\nsrc: url('fonts/bedstead.otf') format('opentype');\nunicode-range: U+0000-00FF;\n}\n@keyframes blink {\nto {\nvisibility: hidden;\n}\n}\n@keyframes fancyblink {\nfrom {\nfilter: none;\nopacity: 0.7;\n}\n33% {\nfilter: none;\nopacity: 1;\n}\n66% {\nfilter: blur(0px);\nopacity: 1;\n}\n95% {\nfilter: blur(4px);\nopacity: 0;\n}\nto {\nfilter: blur(0px);\nopacity: 0;\n}\n}\n#textlayer {\nfont-size: 10px;\n}\n.mosaic {\nfont-family: 'Unscii';\nfont-size: 10.3px;\n}\n.mosaic_separated {\nfont-family: 'Unscii';\nfont-size: 10px;\n}\n.flash_flashing .flash {\n/* animation: blink 2s steps(3, start) infinite; */\nanimation: fancyblink 2s linear infinite;\n}\n.conceal_concealed .conceal {\nvisibility: hidden;\n}\nsvg #background {\ntransition-property: opacity;\ntransition-duration: 0.25s;\n}\nsvg {\nbackground-color: transparent;\n}\nsvg use {\nshape-rendering: crispEdges;\n}\nrect { color: orange; }\n"),this.d=this.ts.Et()._t("class","conceal_concealed flash_flashing"),this.ss=1.2,this.es(),this.rs(),this.ns=null,this.hs=t,this._s=this.hs.ls.os((()=>this.As())),this.cs=!1,this.gs=!1,this.us=!1,this.Cs={}}ut(t){this.ts.ut(t)}fs(){this.hs.ls.fs(this._s),this._s=null}As(){let t=!1,s=!1;this.us=!1,this.d.At("flash_flashing"),this.Is.forEach(((i,e)=>{let n=!1;if(this.Es(e),t)return t=!1,void this.Bs(i,e);const r=this.hs.ds(e);let h,o;i.forEach(((t,i)=>{if(n)return n=!1,this.Qs(t),this.ys(e),void(o&&this.bs());const a=r.ps(i),c=D(a.ws),l=a.Ss(),A=D(a.xs),g=this.Us(a.vs,l,a.et);this.ks(t,a,g,A,i,e,l),a.Rs&&(o?this.bs():this.Fs(e,i),this.us=!0),h==c?this.ys(e):this.Ls(e,i,c),a.ft!=U.Yt&&a.ft!=U.Vt||(n=!0),h=c,o=a.Rs,a.Ds&&(s=!0)})),r.Ns?(this.Gs(e),this.Hs(),t=!0):t=!1,this.js(e)})),"Os"in this.Cs&&this.Cs.Os(this.ts.Bt(),this.ts.dt()),this.d.ot("conceal_concealed"),s&&setTimeout((()=>this.d.ot("flash_flashing")),100),this.Ps()}Es(t){this.Ms(t),this.qs(t)}Bs(t,s){"Ts"in this.Cs&&this.Cs.Ts(t.length,s),t.forEach((t=>this.Qs(t)))}Qs(t){t.bt(" ")._t({dx:null,dy:null,textLength:null,lengthAdjust:null,"text-anchor":null,transform:null,class:null})}ks(t,s,i,e,n,r,h){this.zs(t,s,i,e,n,r),s.vs==k.Mt&&h||s.vs==k.Tt?t.ot("mosaic"):s.vs==k.qt&&h&&t.ot("mosaic_separated")}zs(t,s,i,e,n,r){t.bt(s.Js)._t(i).Nt(e),s.ft==U.Jt?t._t("transform",`translate(0 ${Z(r)}) scale(1 2)`):s.ft==U.Yt?t._t("transform",`translate(${K(n)} 0) scale(2 1)`):s.ft==U.Vt&&t._t("transform",`translate(${K(n)} ${Z(r)}) scale(2 2)`),s.Ds&&t.ot("flash"),s.Ys&&t.ot("conceal")}Vs(){this.d.ct("conceal_concealed")}Ks(t){let s=t;"native"==t?s='-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif':"default"==t&&(s="sans-serif"),this.ts._t("style","font-family: "+s)}Zs(){this.ns?(this.ns.Rt(),this.ns=null):this.Xs()}Ws(){this.gs?(this.gs=!1,this.$s._t("opacity",null).kt()):(this.gs=!0,this.ti())}si(t){this.ss=t,this.ii(this.ts.dt())}ii(t){this.ts.ft("natural"==this.ss?1.6*t:t*this.ss,t)}ti(){this.cs&&this.us?this.$s._t("opacity",.3):this.us?this.$s.vt(this.ei)._t("opacity",.3):this.$s._t("opacity",0)}Ps(){this.gs&&this.ti()}ri(){this.cs?(this.d.kt(),this.cs=!1):(this.d.vt(this.ei),this.cs=!0),this.Ps()}Xs(){this.ns=this.d.Et();for(let t=0;t<25;t++)this.ns.Ft(0,10*t,399,10*t)._t({stroke:"#555","stroke-width":.5});for(let t=0;t<40;t++)this.ns.Ft(10*t,0,10*t,249)._t({stroke:"#555","stroke-width":.5})}rs(){this.ni=this.d.wt(),this.hi=null,this.ei=this.ni.Ht()}es(){this._i(),this.oi()}_i(){const t=this.d.Et();t._t({"shape-rendering":"crispEdges",id:"background"}),this.ai=[],this.$s=t}oi(){const t=[],s=this.d.Et()._t({"text-anchor":"middle",fill:"#fff"})._t("id","textlayer");for(let i=0;i<25;i++){const e=[];for(let t=0;t<40;t++)e.push(s.bt(String.fromCharCode(32+95*Math.random()))._t({x:10*t+5,y:10*i+8}));t.push(e)}this.Is=t,this.li=s}qs(t){this.ei.Ut().filter((s=>s.gt("r")==t)).forEach((t=>t.Rt()))}Ms(t){this.ai[t]&&this.ai[t].Rt(),this.ai[t]=this.$s.Et()}ys(t){const s=this.ai[t].xt(),i=s.Bt();s.Bt(i+10)}Ls(t,s,i){const e=10*s,n=10*t;this.ai[t].St(10,10).Nt(i).Gt(e,n)}bs(){const t=this.hi.Bt();this.hi.Bt(t+10)}Gs(t){this.ai[t].Ut().forEach((t=>t._t("height",20)))}Hs(){this.ni.jt("[data-boxbuffer]").forEach((t=>t.dt(20)))}Fs(t,s){const i=10*s,e=10*t;this.hi=this.ni.St(10,10).gt("boxbuffer",!0).Gt(i,e)}js(t){this.ni.jt("[data-boxbuffer]").forEach((s=>{s.gt({r:t,boxbuffer:null}),this.ei.Ot(s)}))}Us(t,s,i){return t==k.Mt&&s||t==k.Tt?{dx:q.Zt.Wt,dy:-.15,textLength:q.Zt.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:t==k.qt&&s?{dx:q.$t.Wt,dy:null,textLength:q.$t.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:{dx:null,dy:null,textLength:i?10:null,lengthAdjust:i?"spacingAndGlyphs":null,"text-anchor":null,transform:null,class:null}}registerPlugin(t,s){return"renderBackground"in s&&(this.Cs.Ai=s.renderBackground),"renderMosaic"in s&&(this.Cs.ci=s.renderMosaic),"endOfPageUpdate"in s&&(this.Cs.Os=s.endOfPageUpdate),"clearCellsForRow"in s&&(this.Cs.Ts=s.clearCellsForRow),{lookupColour:J,isDoubleHeight:X,isDoubleWidth:z,isDoubleSize:Y,isSeparatedMosaic:V,createImageOverlay:this.gi.bind(this)}}gi(){const t=this.d.Dt(400,250);return t._t("preserveAspectRatio","none"),t}}T.ui=10,T.Ci=10,T.fi=20,T.Ii=20,T.Ei=400,T.Bi=250,T.di=q,T.ROWS=25,T.COLS=40;const J=t=>D(t),X=t=>t==U.Jt,z=t=>t==U.Yt,Y=t=>t==U.Vt,V=t=>t==k.qt,Z=t=>0-10*t,K=t=>0-10*t,W={g0_latin:{$:"¤","":"■"},g0_latin__czech_slovak:{"#":"#",$:"ů","@":"č","[":"ť","\\":"ž","]":"ý","^":"í",_:"ř","`":"é","{":"á","|":"|","}":"ú","~":"š"},g0_latin__english:{"#":"£",$:"$","@":"@","[":"←","\\":"½","]":"→","^":"↑",_:"#","`":"—","{":"¼","|":"‖","}":"¾","~":"÷"},g0_latin__estonian:{"#":"#",$:"õ","@":"Š","[":"Ä","\\":"Ö","]":"Ž","^":"Ü",_:"Õ","`":"š","{":"ä","|":"ö","}":"ž","~":"ü"},g0_latin__french:{"#":"é",$:"ï","@":"à","[":"ë","\\":"ê","]":"ù","^":"î",_:"#","`":"è","{":"â","|":"ô","}":"û","~":"ç"},g0_latin__german:{"#":"#",$:"$","@":"§","[":"Ä","\\":"Ö","]":"Ü","^":"^",_:"_","`":"°","{":"ä","|":"ö","}":"ü","~":"ß"},g0_latin__italian:{"#":"£",$:"$","@":"é","[":"°","\\":"ç","]":"→","^":"↑",_:"#","`":"ù","{":"à","|":"ò","}":"è","~":"ì"},g0_latin__latvian_lithuanian:{"#":"#",$:"$","@":"Š","[":"ė","\\":"ę","]":"Ž","^":"č",_:"ū","`":"š","{":"ą","|":"ų","}":"ž","~":"į"},g0_latin__polish:{"#":"#",$:"ń","@":"ą","[":"Ƶ","\\":"Ś","]":"Ł","^":"ć",_:"ó","`":"ę","{":"ż","|":"ś","}":"ł","~":"ź"},g0_latin__portuguese_spanish:{"#":"ç",$:"$","@":"¡","[":"á","\\":"é","]":"í","^":"ó",_:"ú","`":"¿","{":"ü","|":"ñ","}":"è","~":"à"},g0_latin__romanian:{"#":"#",$:"¤","@":"Ț","[":"Â","\\":"Ș","]":"Ă","^":"Î",_:"ı","`":"ț","{":"â","|":"ș","}":"ă","~":"î"},g0_latin__serbian_croatian_slovenian:{"#":"#",$:"Ë","@":"Č","[":"Ć","\\":"Ž","]":"Đ","^":"Š",_:"ë","`":"č","{":"ć","|":"ž","}":"đ","~":"š"},g0_latin__swedish_finnish_hungarian:{"#":"#",$:"¤","@":"É","[":"Ä","\\":"Ö","]":"Å","^":"Ü",_:"_","`":"é","{":"ä","|":"ö","}":"å","~":"ü"},g0_latin__turkish:{"#":"₺",$:"ğ","@":"İ","[":"Ş","\\":"Ö","]":"Ç","^":"Ü",_:"Ğ","`":"ı","{":"ş","|":"ö","}":"ç","~":"ü"},g2_latin:{0:"°",1:"±",2:"²",3:"³",4:"×",5:"µ",6:"¶",7:"·",8:"÷",9:"’","!":"¡",'"':"¢","#":"£","%":"¥","&":"#","'":"§","(":"¤",")":"‘","*":"“","+":"«",",":"←","-":"↑",".":"→","/":"↓",":":"”",";":"»","<":"¼","=":"½",">":"¾","?":"¿","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"—",Q:"¹",R:"®",S:"©",T:"™",U:"♪",V:"₠",W:"‰",X:"α",Y:null,Z:null,"[":null,"\\":"⅛","]":"⅜","^":"⅝",_:"⅞","`":"Ω",a:"Æ",b:"Ð",c:"ª",d:"Ħ",e:null,f:"IJ",g:"Ŀ",h:"Ł",i:"Ø",j:"Œ",k:"º",l:"Þ",m:"Ŧ",n:"Ŋ",o:"ʼn",p:"ĸ",q:"æ",r:"đ",s:"ð",t:"ħ",u:"ı",v:"ij",w:"ŀ",x:"ł",y:"ø",z:"œ","{":"ß","|":"þ","}":"ŧ","~":"ŋ","":"■"},g0_greek:{"<":"«",">":"»","@":"ΐ",A:"Α",B:"Β",C:"Γ",D:"Δ",E:"Ε",F:"Ζ",G:"Η",H:"Θ",I:"Ι",J:"Κ",K:"Λ",L:"Μ",M:"Ν",N:"Ξ",O:"Ο",P:"Π",Q:"Ρ",R:"ʹ",S:"Σ",T:"Τ",U:"Υ",V:"Φ",W:"Χ",X:"Ψ",Y:"Ω",Z:"Ϊ","[":"Ϋ","\\":"ά","]":"έ","^":"ή",_:"ί","`":"ΰ",a:"α",b:"β",c:"γ",d:"δ",e:"ε",f:"ζ",g:"η",h:"θ",i:"ι",j:"κ",k:"λ",l:"μ",m:"ν",n:"ξ",o:"ο",p:"π",q:"ρ",r:"ς",s:"σ",t:"τ",u:"υ",v:"φ",w:"χ",x:"ψ",y:"ω",z:"ϊ","{":"ϋ","|":"ό","}":"ύ","~":"ώ","":"■"},g2_greek:{0:"°",1:"±",2:"²",3:"³",4:"×",5:"m",6:"n",7:"p",8:"÷",9:"’","!":"a",'"':"b","#":"£",$:"e","%":"h","&":"i","'":"§","(":":",")":"‘","*":"“","+":"k",",":"←","-":"↑",".":"→","/":"↓",":":"”",";":"t","<":"¼","=":"½",">":"¾","?":"x","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"?",Q:"¹",R:"®",S:"©",T:"™",U:"♪",V:"₠",W:"‰",X:"ɑ",Y:"Ί",Z:"Ύ","[":"Ώ","\\":"⅛","]":"⅜","^":"⅝",_:"⅞","`":"C",a:"D",b:"F",c:"G",d:"J",e:"L",f:"Q",g:"R",h:"S",i:"U",j:"V",k:"W",l:"Y",m:"Z",n:"Ά",o:"Ή",p:"c",q:"d",r:"f",s:"g",t:"j",u:"l",v:"q",w:"r",x:"s",y:"u",z:"v","{":"w","|":"y","}":"z","~":"Έ","":"■"},g0_cyrillic:{"@":"Ю",A:"А",B:"Б",C:"Ц",D:"Д",E:"Е",F:"Ф",G:"Г",H:"Х",I:"И",J:"Ѝ",K:"К",L:"Л",M:"М",N:"Н",O:"О",P:"П",Q:"Я",R:"Р",S:"С",T:"Т",U:"У",V:"Ж",W:"В",X:"Ь",Z:"З","[":"Ш","]":"Щ","^":"Ч","`":"ю",a:"а",b:"б",c:"ц",d:"д",e:"е",f:"ф",g:"г",h:"х",i:"и",j:"ѝ",k:"к",l:"л",m:"м",n:"н",o:"о",p:"п",q:"я",r:"р",s:"с",t:"т",u:"у",v:"ж",w:"в",x:"ь",z:"з","{":"ш","}":"щ","~":"ч","":"■"},g0_cyrillic__russian_bulgarian:{"&":"ы",Y:"Ъ","\\":"Э",_:"Ы",y:"ъ","|":"э"},g0_cyrillic__serbian_croatian:{"@":"Ч",J:"Ј",Q:"Ќ",V:"В",W:"Ѓ",X:"Љ",Y:"Њ","[":"Ћ","\\":"Ж","]":"Ђ","^":"Ш",_:"Џ","`":"ч",j:"ј",q:"ќ",v:"в",w:"ѓ",x:"љ",y:"њ","{":"ћ","|":"ж","}":"ђ","~":"ш"},g0_cyrillic__ukranian:{"&":"ї",Y:"І","\\":"Є",_:"Ї",y:"і","|":"є"},g2_cyrillic:{0:"m",1:"n",2:"p",3:"t",4:"x",5:"x",6:"°",7:"±",8:"²",9:"³","!":"a",'"':"b","#":"£",$:"e","%":"h","&":"i","'":"§","(":":",")":"‘","*":"“","+":"k",",":"←","-":"↑",".":"→","/":"↓",":":"¼",";":"½","<":"¾","=":"÷",">":"’","?":"”","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"?",Q:"©",R:"®",S:"¹",T:"ɑ",U:"Ί",V:"Ύ",W:"Ώ",X:"‰",Y:"₠",Z:"™","[":"⅛","\\":"⅜","]":"⅝","^":"⅞",_:"♪","`":"C",a:"D",b:"F",c:"G",d:"J",e:"L",f:"Q",g:"R",h:"S",i:"U",j:"V",k:"W",l:"Y",m:"Z",n:"Ά",o:"Ή",p:"c",q:"d",r:"f",s:"g",t:"j",u:"l",v:"q",w:"r",x:"s",y:"u",z:"v","{":"w","|":"y","}":"z","~":"Έ","":"■"},g0_arabic:{"#":"£","&":"ﻰ","'":"ﻱ","(":")",")":"(",";":"؛","<":">",">":"<","?":"؟","@":"ﺔ",A:"ﺀ",B:"ﺒ",C:"ﺏ",D:"ﺘ",E:"ﺕ",F:"ﺎ",G:"ﺍ",H:"ﺑ",I:"ﺓ",J:"ﺗ",K:"ﺛ",L:"ﺟ",M:"ﺣ",N:"ﺧ",O:"ﺩ",P:"ﺫ",Q:"ﺭ",R:"ﺯ",S:"ﺳ",T:"ﺷ",U:"ﺻ",V:"ﺿ",W:"ﻃ",X:"ﻇ",Y:"ﻋ",Z:"ﻏ","[":"ﺜ","\\":"ﺠ","]":"ﺤ","^":"ﺨ",_:"#","`":"ـ",a:"ﻓ",b:"ﻗ",c:"ﻛ",d:"ﻟ",e:"ﻣ",f:"ﻧ",g:"ﻫ",h:"ﻭ",i:"ﻰ",j:"ﻳ",k:"ﺙ",l:"ﺝ",m:"ﺡ",n:"ﺥ",o:"ﻴ",p:"ﻯ",q:"ﻌ",r:"ﻐ",s:"ﻔ",t:"ﻑ",u:"ﻘ",v:"ﻕ",w:"ﻙ",x:"ﻠ",y:"ﻝ",z:"ﻤ","{":"ﻡ","|":"ﻨ","}":"ﻥ","~":"ﻻ","":"■"},g2_arabic:{0:"٠",1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩","!":"ﻉ",'"':"ﺁ","#":"ﺃ",$:"ﺅ","%":"ﺇ","&":"ﺋ","'":"ﺊ","(":"ﭼ",")":"ﭽ","*":"ﭺ","+":"ﭘ",",":"ﭙ","-":"ﭖ",".":"ﮊ","/":"ﮔ",":":"ﻎ",";":"ﻍ","<":"ﻼ","=":"ﻬ",">":"ﻪ","?":"ﻩ","@":"à","[":"ë","\\":"ê","]":"ù","^":"î",_:"ﻊ","`":"é","{":"â","|":"ô","}":"û","~":"ç","":"■"},g0_hebrew:{"#":"£","[":"←","\\":"½","]":"→","^":"↑",_:"#","`":"א",a:"ב",b:"ג",c:"ד",d:"ה",e:"ו",f:"ז",g:"ח",h:"ט",i:"י",j:"ך",k:"כ",l:"ל",m:"ם",n:"מ",o:"ן",p:"נ",q:"ס",r:"ע",s:"ף",t:"פ",u:"ץ",v:"צ",w:"ק",x:"ר",y:"ש",z:"ת","{":"₪","|":"‖","}":"¾","~":"÷","":"■"},g1_block_mosaic_to_unicode__legacy_computing:{0:"🬏",1:"🬐",2:"🬑",3:"🬒",4:"🬓",5:"▌",6:"🬔",7:"🬕",8:"🬖",9:"🬗"," ":" ","!":"🬀",'"':"🬁","#":"🬂",$:"🬃","%":"🬄","&":"🬅","'":"🬆","(":"🬇",")":"🬈","*":"🬉","+":"🬊",",":"🬋","-":"🬌",".":"🬍","/":"🬎",":":"🬘",";":"🬙","<":"🬚","=":"🬛",">":"🬜","?":"🬝","`":"🬞",a:"🬟",b:"🬠",c:"🬡",d:"🬢",e:"🬣",f:"🬤",g:"🬥",h:"🬦",i:"🬧",j:"▐",k:"🬨",l:"🬩",m:"🬪",n:"🬫",o:"🬬",p:"🬭",q:"🬮",r:"🬯",s:"🬰",t:"🬱",u:"🬲",v:"🬳",w:"🬴",x:"🬵",y:"🬶",z:"🬷","{":"🬸","|":"🬹","}":"🬺","~":"🬻","":"█"},g1_block_mosaic_to_unicode__unscii_separated:{0:"",1:"",2:"",3:"",4:"",5:"",6:"",7:"",8:"",9:""," ":" ","!":"",'"':"","#":"",$:"","%":"","&":"","'":"","(":"",")":"","*":"","+":"",",":"","-":"",".":"","/":"",":":"",";":"","<":"","=":"",">":"","?":"","`":"",a:"",b:"",c:"",d:"",e:"",f:"",g:"",h:"",i:"",j:"",k:"",l:"",m:"",n:"",o:"",p:"",q:"",r:"",s:"",t:"",u:"",v:"",w:"",x:"",y:"",z:"","{":"","|":"","}":"","~":"","":""},g3:{0:"🭇",1:"🭈",2:"🭉",3:"🭊",4:"🭋",5:"◢",6:"🭌",7:"🭍",8:"🭎",9:"🭏"," ":"🬼","!":"🬽",'"':"🬾","#":"🬿",$:"🭀","%":"◣","&":"🭁","'":"🭂","(":"🭃",")":"🭄","*":"🭅","+":"🭆",",":"🭨","-":"🭩",".":"🭰","/":"▒",":":"🭐",";":"🭑","<":"🭪","=":"🭫",">":"🭵","?":"█","@":"┷",A:"┯",B:"┝",C:"┥",D:"🮤",E:"🮥",F:"🮦",G:"🮧",H:"🮠",I:"🮡",J:"🮢",K:"🮣",L:"┿",M:"•",N:"●",O:"○",P:"│",Q:"─",R:"┌",S:"┐",T:"└",U:"┘",V:"├",W:"┤",X:"┬",Y:"┴",Z:"┼","[":"→","\\":"←","]":"↑","^":"↓",_:" ","`":"🭒",a:"🭓",b:"🭔",c:"🭕",d:"🭖",e:"◥",f:"🭗",g:"🭘",h:"🭙",i:"🭚",j:"🭛",k:"🭜",l:"🭬",m:"🭭",n:null,o:null,p:"🭝",q:"🭞",r:"🭟",s:"🭠",t:"🭡",u:"◤",v:"🭢",w:"🭣",x:"🭤",y:"🭥",z:"🭦","{":"🭧","|":"🭮","}":"🭯","~":null,"":null}},$={};class tt{constructor(t){this.type=t.vs,this.flashing=t.Ds,this.concealed=t.Ys,this.size=t.ft,this.sextants=t.Qi()}}class st{constructor(){this.yi=" ",this.bi=" ",this.pi=x.WHITE,this.mi=x.BLACK,this.wi=k.Pt,this.Si=!1,this.xi=U.zt,this.Ui=!1,this.vi=!1,this.ki=null,this.Ri=!1,this.Fi=null,this.Li=null}set Di(t){this.yi=t}get Di(){return this.yi}set xs(t){this.pi=t}get xs(){return this.pi}set ws(t){this.mi=t}get ws(){return this.mi}get et(){return this.Ri}Ni(t){const s=this.wi==k.Mt||this.wi==k.qt;this.wi==k.Pt||0==(32&this.yi.charCodeAt(0))&&s?(this.bi=et(this.yi,t),this.Fi>0&&(this.bi+=W.g2_latin[String.fromCharCode(this.Fi+64)]),this.Ri=!1,"g0_arabic"!=t&&"g2_arabic"!=t||(this.Ri=l.et(this.bi))):this.wi==k.Mt?this.bi=et(this.yi,"g1_block_mosaic_to_unicode__legacy_computing"):this.wi==k.qt?this.bi=et(this.yi,"g1_block_mosaic_to_unicode__unscii_separated"):this.wi==k.Tt&&(this.bi=et(this.yi,"g3")),this.ki=null}Gi(t){if(this.wi!=k.Mt&&this.wi!=k.qt||!t.Hi)this.ki=null,this.bi=" ";else{this.ki=t.Js,this.wi=t.vs;let s="g1_block_mosaic_to_unicode__legacy_computing";this.wi==k.qt&&(s="g1_block_mosaic_to_unicode__unscii_separated"),this.bi=et(t.Js,s)}}get Js(){return this.bi}get vs(){return this.wi}set vs(t){this.wi=t}set Ds(t){this.Si=t}get Ds(){return this.Si}get ft(){return this.xi}set ft(t){this.xi=t}set Ys(t){this.Ui=t}get Ys(){return this.Ui}set Rs(t){this.vi=t}get Rs(){return this.vi}Ss(){const t=null!=this.ki?this.ki.charCodeAt(0):this.yi.charCodeAt(0);return t<=127&&32==(32&t)}ji(){const t=this.yi.charCodeAt(0);return(this.wi==k.Mt||this.wi==k.qt)&&t<=127&&32==(32&t)}Qi(){const t=null!=this.ki?this.ki.charCodeAt(0):this.yi.charCodeAt(0);if(t>127)return null;if(t in $)return $[t];let s=t-32;return s>=64&&(s-=32),$[t]=[...s.toString(2).padStart(6,"0")].reverse(),$[t]}}class it extends st{constructor(t){super(),Object.assign(this,t)}set Oi(t){this.Fi=t}get Oi(){return this.Fi}set Pi(t){this.Li=t}get Js(){return null==this.Li?this.bi:this.Li}}function et(t,s){if(!(s in W))throw Error("Cell getCharWithEncoding: bad encoding: "+s);if(t in W[s])return W[s][t];const i=s.match(/^(.+)__/);if(null!=i){const e=i[1];if(t in W[e])return W[s][t]=W[e][t],W[e][t]}return t}class nt extends T{constructor(t,s,i){super(t,i),this.Mi=s,this.qi=new Set}es(){super.es(),this.Ti=[],this.zi=this.d.Et()}Es(t){super.Es(t),this.Ji(t)}ks(t,s,i,e,n,r,h){"Ai"in this.Cs&&this.Cs.Ai(r,n,s.ft,s.ws),s.vs!=k.Pt&&s.vs!=k.Tt&&h?h&&(t.bt(" ")._t(i),this.Yi(r,n,s,e)):(this.zs(t,s,i,e,n,r),s.vs==k.Tt&&t.ot("mosaic"))}Yi(t,s,i,e){if("ci"in this.Cs){const n=new tt(i);if(this.Cs.ci(t,s,n,e))return}const n=i.Qi();if(!n.includes("1"))return;let r=i.vs==k.Mt?"c":"s";r+=n.join("");let h,o=T.ui,a=T.Ci;if(i.vs==k.Mt&&(o=T.ui+.3,a=T.Ci+.2),!this.qi.has(r)){this.qi.add(r);const t=this.ts.Qt(r);if(i.vs==k.Mt){t._t({preserveAspectRatio:"none",width:o,height:a,viewBox:"0 0 12 18"});for(let s=0;s<6;s++)"1"==n[s]&&t.St(6,6).Gt(s%2*6,6*Math.floor(s/2))}else{t._t({preserveAspectRatio:"none",width:o,height:a,viewBox:"0 0 12 18"});for(let s=0;s<6;s++)"1"==n[s]&&t.St(4,4).Gt(s%2*6+1,6*Math.floor(s/2)+2)}}h=i.vs==k.Mt?this.Ti[t].Lt(r).Gt(s*T.ui-.15,t*T.Ci-.1).Nt(e):this.Ti[t].Lt(r).Gt(s*T.ui,t*T.Ci).Nt(e),this.Mi&&h._t({width:o,height:a}),i.ft!=U.Jt&&i.ft!=U.Vt||h._t("height",T.Ii),i.ft!=U.Yt&&i.ft!=U.Vt||h._t("width",T.fi),i.Ds&&h.ot("flash"),i.Ys&&h.ot("conceal")}Ji(t){this.Ti[t]&&this.Ti[t].Rt(),this.Ti[t]=this.zi.Et()}Us(t,s,i){return t==k.Tt?{dx:T.di.Zt.Wt,dy:-.15,textLength:T.di.Zt.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:{dx:null,dy:null,textLength:i?T.ui:null,lengthAdjust:i?"spacingAndGlyphs":null,"text-anchor":null,transform:null,class:null}}}class rt{constructor(t){this.hs=t,this.Vi=0,this.Ki=0,this.Zi=[]}pos(t,s){return(t=parseInt(t))<0||t>39||(s=parseInt(s))<0||s>24||(this.Vi=t,this.Ki=s),this}putG0(t,s){let i=null;if(void 0!==s){const t=parseInt(s);t>=0&&t<=15&&(i=t)}const e=t.charCodeAt(0);return e<32||e>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g0",Js:t,Oi:i}),this}putG1(t){const s=t.charCodeAt(0);return s<32||s>127||s>=64&&s<=95||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g1",Js:t}),this}putG2(t){const s=t.charCodeAt(0);return s<32||s>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g2",Js:t}),this}putG3(t){const s=t.charCodeAt(0);return s<32||s>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g3",Js:t}),this}putAt(){return this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"char",Js:"@"}),this}end(){return this.hs.$i(this.Zi),this.hs.te(),this}}class ht extends T{}const ot=["SPLASH","ENGINEERING","ADVERT","UK"];class at{constructor(t,s){if(this.se=null,"object"==typeof window&&(this.se=window),this.ie={ee:!0},"object"==typeof s&&("webkitCompat"in s&&!s.webkitCompat&&(this.ie.ee=!1),"dom"in s&&(this.se=s.dom)),null==this.se)throw Error("TeletextController E24: No window dom object available");this.re=new nt(t,this.ie.ee,this.se),this.hs=t,this.ne=1,this.he=0,this._e(),this.oe=null,this.ae=null,this.le=0,this.Ae=0}setRowFromOutputLine(t,s){const i=l.st(s);this.hs.ce(t,i)}setRow(t,s){this.hs.ce(t,s)}setPageFromOutputLines(t,s){const i=l.it(t);void 0!==s&&(i[0]=this.ge(s)),this.setPageRows(i)}setPageRows(t){this.hs.ue(),this.hs.Ce(t)}ge(t){return(t=l.st(t)).join("").substring(0,32).padStart(40," ")}showTestPage(){this.loadPageFromEncodedString(g[ot[this.he]]),this.he++,4==this.he&&(this.he=0)}showRandomisedPage(){const t=[];for(let s=0;s<25;s++){const s=[];for(let t=0;t<40;t++)s.push(String.fromCharCode(127*Math.random()));t.push(s.join(""))}this.setPageRows(t)}loadPageFromEncodedString(t,s){const i=l.tt(t,this.se.atob);void 0!==s&&(i[0]=this.ge(s)),this.setPageRows(i)}_e(){this.se.addEventListener("ttx.reveal",(()=>this.re.Vs())),this.se.addEventListener("ttx.mix",(()=>this.re.Ws())),this.se.addEventListener("ttx.subtitlemode",(()=>this.re.ri()))}toggleReveal(){this.re.Vs()}toggleMixMode(){this.re.Ws()}toggleBoxMode(){this.re.ri()}toggleGrid(){this.re.Zs()}setLevel(t){this.hs.fe(t)}addTo(t){this.Ie=t,this.re.ut(t)}setFont(t){this.re.Ks(t)}clearScreen(t){this.hs.ue(),this.hs.Ee(t)}setAspectRatio(t){if("natural"==t)return void this.re.si(t);const s=parseFloat(t);if(Number.isNaN(s))throw Error("E80 setAspectRatio: bad number");this.re.si(s)}setHeight(t){const s=parseFloat(t);if(Number.isNaN(s))throw Error("E98 setHeight: bad number");this.re.ii(s),this.ae=s}setDefaultG0Charset(t,s){if(null==t.match(/g0_/))throw Error("E130 setDefaultG0Charset: Bad g0 set");this.hs.Be(t,s)}setSecondG0Charset(t,s){if(null==t.match(/g0_/))throw Error("E136 setSecondG0Charset: Bad g0 set");this.hs.de(t,s)}setG2Charset(t,s){if(null==t.match(/g2_/))throw Error("E142 setG2Charset: Bad g2 set");this.hs.Qe(t,s)}remove(){if(this.re.fs(),this.Ie){const t=document.querySelector(this.Ie);t&&t.removeChild(t.firstChild)}this.re=null}setView(t){switch(this.remove(),t){case"classic__font-for-mosaic":this.re=new ht(this.hs,this.se);break;case"classic__graphic-for-mosaic":this.re=new nt(this.hs,this.ie.ee,this.se);break;default:throw Error("setView E126: bad view name:"+t)}this.ae&&this.re.ii(this.ae),this.Ie&&this.re.ut(this.Ie),this.hs.te()}registerViewPlugin(t){t.registerWithView(this.re),this.hs.te()}enhance(){return new rt(this.hs)}}class ct{constructor(t){this.ye=t,this.be=[]}os(t){return this.be.push(t),this.be.length-1}te(t){this.be.forEach((s=>null!=s&&s(this.ye,t)))}fs(t){this.be[t]=null}}class lt{constructor(){this.pe=!1,this.me=[]}get Ns(){return this.pe}set Ns(t){this.pe=t}we(t){this.me.push(t)}ps(t){if(t>=this.me.length)throw Error("RowModel.getCell E20 bad cell index");return this.me[t]}}const At=[H[1.5],H[2.5]],gt=new class{constructor(){this.Se=[];for(let t=0;t<25;t++){const t=[];for(let s=0;s<40;s++)t.push(new st);this.Se.push(t)}this.xe="g0_latin",this.Ue=null,this.ve="g2_latin",this.ke=N.charFromAttribute(N.START_BOX),this.Re=H[1],this.Fe=[],this.ls=new ct(this)}te(){this.ls.te()}ce(t,s){if(t>=25)throw Error("PageModel E29 bad row number");this.Le(t,s),this.ls.te()}Ce(t){(t=t.slice(0,25)).forEach(((t,s)=>{this.Le(s,t)})),this.ls.te()}Le(t,s){let i=[...s];if(i=i.slice(0,40),i.forEach(((s,i)=>{const e=s.charCodeAt(0);if(Number.isNaN(e)||e>127)throw Error(`PageModel E51 failed to write row: bad character code (${e}) at row ${t} col ${i}`);this.Se[t][i].Di=s})),i.length<40)for(let s=i.length;s<40;s++)this.Se[t][s].Di=" "}fe(t){this.Re=t,this.ls.te()}Ee(t){if(void 0===t||t){const t=[];for(let s=0;s<25;s++)t.push("");this.Ce(t)}else for(let t=0;t<25;t++)this.Le(t,"")}Be(t,s){this.xe=t;const i=t.match(/^g0_([a-z]+)/);if(null!=i){const t="g2_"+i[1];t in W?this.ve=t:"hebrew"==i[1]&&(this.ve="g2_arabic")}s&&this.ls.te()}de(t,s){this.Ue=t,s&&this.ls.te()}Qe(t,s){this.ve=t,s&&this.ls.te()}ds(t){if(t>=25)throw Error("PageModel.getRow E42 bad rowNum");const s=new lt;let i,e,n=k.Pt,r=x.WHITE,h=!1,o=U.zt,a=!1,c=!1,l=!1,A=!1,g=x.BLACK,_=k.Mt,u={Hi:!1,Js:" ",vs:k.Mt},E=[];return At.includes(this.Re)&&(E=this.Fe.filter((s=>s.Wi==t))),this.Se[t].forEach(((C,I)=>{const f=C.Di,B=((t,s)=>{let i=null,e=null;return s in R&&M[this.Re].includes(s.charCodeAt(0))?s in j?(i=N.TEXT_COLOUR,e=R[s]):s in F?(i=N.MOSAIC_COLOUR,e=R[s]):i=R[s]:s.charCodeAt(0)<=31&&(i=N.Kt),{De:i,Ne:e}})(0,f);switch(i=r,C.vs=n,C.Rs=A,e=a,B.De!=N.STEADY&&(C.Ds=h),B.De!=N.NORMAL_SIZE&&(C.ft=o),B.De!=N.CONCEAL&&(C.Ys=c),l&&(B.De!=N.HOLD_MOSAICS&&(u.Hi=!1,u.Js=" "),l=!1),B.De){case N.TEXT_COLOUR:n=k.Pt,r=B.Ne,c=!1,C.Gi(u);break;case N.MOSAIC_COLOUR:n=_,r=B.Ne,c=!1,C.Gi(u);break;case N.NEW_BACKGROUND:g=i,C.Gi(u);break;case N.BLACK_BACKGROUND:g=x.BLACK,C.Gi(u);break;case N.CONTIGUOUS_GRAPHICS:_=k.Mt,C.vs==k.qt&&(C.vs=k.Mt),n==k.qt&&(n=k.Mt),C.Gi(u);break;case N.SEPARATED_GRAPHICS:_=k.qt,C.vs==k.Mt&&(C.vs=k.qt),n==k.Mt&&(n=k.qt),C.Gi(u);break;case N.ESC:this.Ue&&(a=!e),C.Gi(u);break;case N.FLASH:h=!0,C.Gi(u);break;case N.STEADY:C.Ds=!1,h=!1,C.Gi(u);break;case N.NORMAL_SIZE:C.ft=U.zt,o=U.zt,C.Gi(u);break;case N.DOUBLE_HEIGHT:o=U.Jt,s.Ns=!0,C.Gi(u);break;case N.DOUBLE_WIDTH:o=U.Yt,C.Gi(u);break;case N.DOUBLE_SIZE:o=U.Vt,s.Ns=!0,C.Gi(u);break;case N.CONCEAL:C.Ys=!0,c=!0,C.Gi(u);break;case N.HOLD_MOSAICS:u.Hi=!0,C.Gi(u);break;case N.RELEASE_MOSAICS:l=!0,C.Gi(u);break;case N.START_BOX:I>=1&&this.Se[t][I-1].Di==this.ke&&(C.Rs=!0,A=!0),C.Gi(u);break;case N.END_BOX:A=!1,C.Gi(u);break;case N.Kt:C.Gi(u);break;default:C.Ni(e?this.Ue:this.xe),C.ji()&&(u.Js=f,u.vs=C.vs)}C.xs=i,C.ws=g,E.filter((t=>t.Xi==I)).forEach((t=>{const s=new it(C);C=s,"g0"==t.vs?(C.Di=t.Js,C.Oi=t.Oi,C.vs=k.Pt,C.Ni(e?this.Ue:this.xe)):"g1"==t.vs?this.Re==H[2.5]&&(C.Di=t.Js,C.vs=_,C.Ni()):"g2"==t.vs?(C.Di=t.Js,C.vs=k.Pt,C.Ni(this.ve)):"g3"==t.vs?(this.Re!=H[1.5]||-1!="Q[\\]".indexOf(t.Js))&&(C.Di=t.Js,C.vs=k.Tt,C.Ni()):"char"==t.vs&&(C.Pi=t.Js,C.vs=k.Pt)})),s.we(C)})),s}$i(t){this.Fe=t}ue(){this.Fe=[]}};class _t{constructor(){this.Oe=null,this.je=null}async fetchPage(t){const s=t.match(/([1-8])[0-9A-Fa-f]{2}/)[1];if(this.Oe!=s)try{const t=await fetch(s+".json");t.ok&&(this.je=await t.json(),this.Oe=s)}catch(t){}return this.Oe==s&&t in this.je.pages?this.je.pages[t]:null}}class ut{constructor(t){this.Ge=t,this.Pe=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],this.He=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]}Me(){const t=new Date;return{"%%a":this.Pe[t.getDay()],"%%b":this.He[t.getMonth()],"%d":(t.getDate()+"").padStart(2,0),"%e":(t.getDate()+"").padStart(2," "),"%m":(t.getMonth()+1+"").padStart(2," "),"%y":(t.getFullYear()+"").substring(2,2),"%H":(t.getHours()+"").padStart(2,0),"%M":(t.getMinutes()+"").padStart(2,0),"%S":(t.getSeconds()+"").padStart(2,0)}}qe(t){const s=this.Me();let i=this.Ge;for(const t of Object.keys(s))i=i.replace(t,s[t]);return void 0!==t&&(i=i.replace("%%#",t)),i}}class Et{constructor(t){if("object"!=typeof t)throw Error("E8 Service.constructor: options object required");if(!("DOMSelector"in t))throw Error("E9 Service.constructor DOMSelector property required");this.Te="caster"in t?t.caster:null,this.Je="defaultG0Charset"in t?t.defaultG0Charset:"g0_latin",this.Xe=new ut("header"in t?t.header:" %%# %%a %e %%b C%H:%M/%S"),this.ze="fetcher"in t?t.fetcher:new _t,this.Ye=new at(gt,void 0),this.Ye.setDefaultG0Charset(this.Je),this.Ye.setLevel(H[1.5]),this.Ye.addTo(t.DOMSelector),this.Ve=null,this.Ze=null,this.Ke=0,this.We=null}get teletextInstance(){return this.Ye}async showPage(t){if("number"==typeof t&&(t+=""),null==t.match(/^[1-8][0-9A-Fa-f]{2}$/))return null;const s=await this.ze.fetchPage(t);if(null!=s){const i=this.$e(s);if(null!=i)return this.Ve=s,this.Ze=t,this.Ke=i,this.tn(),this.sn()}return null}showLink(t){return null!=this.We&&t in this.We?this.showPage(this.We[t]):Promise.resolve(null)}$e(t){const s=t.subpages;for(let t=0;t<s.length;t++)if(null!=s[t])return t;return null}nextSubPage(){const t=this.Ve.subpages;let s=this.Ke,i=!1;for(;!i&&(s++,s==t.length&&(s=0),s!=this.Ke);)null!=t[s]&&(i=!0);return i&&(this.Ke=s,this.tn()),this.sn()}previousSubPage(){const t=this.Ve.subpages;let s=this.Ke,i=!1;for(;!i&&(s--,-1==s&&(s=t.length-1),s!=this.Ke);)null!=t[s]&&(i=!0);return i&&(this.Ke=s,this.tn()),this.sn()}sn(){return{pageNumber:this.Ze,subPage:this.Ke,numSubPages:this.Ve.subpages.filter((t=>null!=t)).length,fastext:this.We}}tn(){const t=this.Ve.subpages[this.Ke],s="encoding"in t?t.encoding:this.Je,i=this.Xe.qe(this.Ze);let e={defaultG0Charset:s,header:i};if(this.Ye.clearScreen(!1),this.Ye.setDefaultG0Charset(s,!1),"ouputLines"in t){const s=t.outputLines.split("\n");this.Ye.setPageFromOutputLines(s,i),e.outputLines=s}else if("packed"in t){const s=t.packed;this.Ye.loadPageFromEncodedString(s,i),e.packed=s}else e=null;e&&this.Te&&this.Te.display(e),this.We="fastext"in t?t.fastext:null}}class Ct{constructor(t){this.t=t,this.i=[]}attach(t){this.i.push(t)}notify(t){this.i.forEach(((s,i)=>this.i[i](this.t,t)))}}const It=new class{constructor(){this.available=new Ct(this),this.castStateChanged=new Ct(this)}o(){if("undefined"==typeof cast)return;const t={receiverApplicationId:"000F65B3",autoJoinPolicy:chrome.cast.AutoJoinPolicy.ORIGIN_SCOPED};this.h=cast.framework.CastContext.getInstance(),this.h.setOptions(t),this.l=new cast.framework.RemotePlayer,this.u=new cast.framework.RemotePlayerController(this.l),this.h.addEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,(()=>this.castStateChanged.notify())),this.available.notify(),this.castStateChanged.notify()}async display(t){if(!this.m())return;const s=this.g();this.u.stop();const i=new chrome.cast.media.MediaInfo("https://teletextforchromecast.robdev.org.uk/250-milliseconds-of-silence.mp3","audio/mpeg3");i.entity=t;const e=new chrome.cast.media.LoadRequest(i);try{await s.loadMedia(e)}catch(t){}}getCastState(){return this.h.getCastState()}clearScreen(){this.p("clear")}toggleGrid(){this.p("grid")}toggleReveal(){this.p("reveal")}toggleMixMode(){this.p("mix")}toggleBoxMode(){this.p("box")}setSmoothMosaics(){this.p("smoothmosaic")}setBlockMosaics(){this.p("blockmosaic")}async p(t){if(!this.m())return;const s=this.g();try{await s.sendMessage("urn:x-cast:uk.ltd.techandsoftware.teletext",`"${t}"`)}catch(t){}}m(){return"object"==typeof this.l&&this.l.isConnected}g(){return this.h.getCurrentSession()}};let ft=0;function Bt(){window.setTimeout((()=>{"undefined"==typeof cast?(ft++,ft<10&&Bt()):It.o()}),500)}window.__onGCastApiAvailable=t=>{t&&("undefined"==typeof cast?Bt():It.o())};const Qt=["sans-serif","Bedstead","native","serif","Unscii","monospace","cursive"],dt=["classic__graphic-for-mosaic","classic__font-for-mosaic"];class bt{constructor(t){const s={defaultG0Charset:"g0_latin__english",header:"FAXFAX %%# %%a %e %%b C%H:%M/%S",caster:It,DOMSelector:"#teletextscreen"};let i="",e=!1;if("object"==typeof t){for(const i of["defaultG0Charset","header","DOMSelector"])i in t&&(s[i]=t[i]);"frontPage"in t&&("number"==typeof t.frontPage?i=t.frontPage+"":"string"==typeof t.frontPage&&(i=t.frontPage)),"smoothMosaics"in t&&t.smoothMosaics&&(e=!0)}""==i&&(i="100"),this.en=new Et(s),this.Ze=3==i.length?i:"XXX",this.nn=0,this.rn=0,It.available.attach((()=>this.hn.call(this))),It.castStateChanged.attach((()=>this.on.call(this))),this.an(),e&&this.cn(),this.ln()}on(){const t=It.getCastState(),s=document.querySelector("#castOuter");switch(t){case"NO_DEVICES_AVAILABLE":s.title="Cast to Chromecast - no devices available",s.style.cursor="default";break;case"NOT_CONNECTED":s.title="Cast to Chromecast",s.style.cursor="pointer";break;case"CONNECTING":break;case"CONNECTED":this.ln(),this.An&&It.setSmoothMosaics()}}hn(){document.querySelector("#castOuter").style.display="inline-block"}an(){window.addEventListener("keydown",(t=>yt.call(this,t))),window.addEventListener("DOMContentLoaded",(()=>{document.querySelector("#revealButton").addEventListener("click",(()=>this.gn())),document.querySelector("#mixButton").addEventListener("click",(()=>this._n()));for(const t of["red","green","yellow","blue","index"])document.querySelector("#"+t).addEventListener("click",(()=>this.un(t)));document.querySelectorAll("[data-num]").forEach((t=>t.addEventListener("click",(()=>this.En(t.dataset.num))))),document.querySelector("#left").addEventListener("click",(()=>this.Cn())),document.querySelector("#right").addEventListener("click",(()=>this.In())),document.querySelector("#helpicon").addEventListener("click",(()=>this.fn()))}))}gn(){window.dispatchEvent(new Event("ttx.reveal")),It.toggleReveal()}_n(){window.dispatchEvent(new Event("ttx.mix")),It.toggleMixMode()}En(t){this.Ze=3==(this.Ze+"").length?t:this.Ze+""+t,this.Bn(),3==(this.Ze+"").length&&this.ln()}Bn(){document.querySelector("#pageNumber").innerHTML=this.Ze}Qn(){this.Ze="XXX",document.querySelector("#pageNumber").innerHTML="- - -",document.querySelector("#subpage").style.visibility="hidden"}async ln(){if(null!=this.Ze.match(/[1-8][0-9A-Fa-f]{2}/)){const t=await this.en.showPage(this.Ze);this.tn(t)}}In(){const t=this.en.nextSubPage();this.tn(t)}Cn(){const t=this.en.previousSubPage();this.tn(t)}tn(t){null!=t&&(this.Ze=t.pageNumber,this.Bn(),this.dn(t),this.bn(t),this.yn())}yn(){document.activeElement.disabled&&document.activeElement.blur()}dn(t){const s=document.querySelector("#subpage");null!=t&&t.numSubPages>1?(s.innerHTML=`${t.subPage} of ${t.numSubPages}`,s.style.visibility="visible",document.querySelectorAll("#lrnav button").forEach((t=>t.disabled=!1))):(s.style.visibility="hidden",document.querySelectorAll("#lrnav button").forEach((t=>t.disabled=!0)))}bn(t){const s=null!=t?t.fastext:{};for(const t of["red","green","yellow","blue","index"]){let i=!0;null!=s&&t in s&&(i=!1),document.querySelector("#"+t).disabled=i}}async un(t){const s=await this.en.showLink(t);this.tn(s)}mn(){for(const t of["red","green","yellow","blue","index","left","right"])document.querySelector("#"+t).disabled=!0}fn(){this.Qn(),this.mn();const t=this.en.teletextInstance;t.setDefaultG0Charset("g0_latin__english",!1),t.loadPageFromEncodedString("OoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA6RQIECBAgQYOHDhw4cOHDhw4cOHDhw4cOHBAgQIECBAgQIDo0igQIECBBqAy8vnFvw8siDHv3dOW_ZzI_2qBAgQIECBAgQIECBAgQIEHdAgQIECBAgQIECDjz9IECBAgQIECBAgQIECA6RQIECBAgQIl69evXr169evXr169evXr169KgQIECBAgQIDqBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOhECCTmQed_VBow9sqDCg15fOLfh5ZFiDrzyoOmjKgQIECA6EQIN3Xbiy8kGvL55oMO7Ig6aMqDXl880GLLs390CBAgQIDoFAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOlNSNGjRo0aNGjRo0aNGjRo0aNGjRo0aNGjRo0aNGjR_2iA6U1BECBA_QIECCll7ZcOxAgQIECBAgQIECBAUQIECBB_aoDpTUEQIEG1AgQIJunwgQIECBAgQIECBAgQIEBRAgQIEH9qgOlNQRAgQW0CBAgocsvbTv680HPri4Yc-VAgQFECBAgQf2qA6U1BECBBdQIECCdl8dEHPri4Yc-VAgQIECAogQIECBB_aoDpTUE5L86_yvxIIe_Zv68kGLr06b93NAgQIEBRAgQIEH9qgOlNQRAgQaUCBAgk7smXwgxdenTfuQIECBAgQFECBAgQf2qA6U1BECBB0QIECCpl5ctObTjQZ-WHho04-aDfuX782Yp_aoDpTUEQIEGZAgQII2_d0Qc--npj0IECBAgQIEBRAgQIEH9qgOlNSBAgQIECBAgQIECBAgQIECBAgQIECBAgQFECBAgQf2qA6URL169evXr169evXr169evXr169evXr169evXr169evSoDqBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA6gQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIDqBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA")}wn(){const t=Math.floor(360*Math.random()),s=Math.floor(360*Math.random());document.body.style.background=`linear-gradient(${s}deg, hsl(${t} 100% 7%) 0%, hsl(${t} 83% 52%) 86%, hsl(${t} 100% 85%) 100%)`}async cn(){if(this.An)this.en.teletextInstance.setView(dt[this.rn]),this.An=!1,It.setBlockMosaics();else if(0==this.rn)try{const t=await import("https://cdn.jsdelivr.net/npm/@techandsoftware/teletext-plugin-smooth-mosaic@latest/dist/teletext-plugin-smooth-mosaic.min.js");this.en.teletextInstance.registerViewPlugin(t.SmoothMosaicPlugin),this.An=!0,It.setSmoothMosaics()}catch(t){}}}function yt(t){if(!(t.altKey||t.metaKey||t.ctrlKey))switch(t.key){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"0":document.querySelector("#b"+t.key).focus({preventScroll:!0}),this.En(t.key);break;case"?":this.gn();break;case"m":this._n();break;case"f":this.nn++,this.nn==Qt.length&&(this.nn=0),this.en.teletextInstance.setFont(Qt[this.nn]);break;case"w":this.en.teletextInstance.clearScreen();break;case"h":this.fn();break;case"v":this.rn++,this.rn==dt.length&&(this.rn=0),this.en.teletextInstance.setView(dt[this.rn]),this.An=!1;break;case"t":this.cn();break;case"r":this.un("red");break;case"g":this.un("green");break;case"y":this.un("yellow");break;case"b":this.un("blue");break;case"i":this.un("index");break;case"=":case"+":case">":case"ArrowRight":this.In();break;case"-":case"<":case"ArrowLeft":this.Cn();break;case"c":this.wn()}}export{Et as TeletextService,bt as TeletextServiceViewer};//# sourceMappingURL=teletext-service.min.js.map
// LicenseRef-uk.ltd.TechAndSoftware-1.0 refers to https://tech-and-software.ltd.uk/LICENSES/LicenseRef-uk.ltd.TechAndSoftware-1.0.txt
const t=new Set(["Uint1Array","Int8Array","Uint8Array","Uint8ClampedArray","Int16Array","Uint16Array","Int32Array","UInt32Array","Float32Array","Float64Array"]),s=Uint8Array,i=Symbol();class e{constructor(t,{length:i=null,buffer:e=null,byteOffset:n=0,byteLength:r=null}={}){let h;e?i=8*(r||e.byteLength):i||(i=0);const o=s.BYTES_PER_ELEMENT,a=8*o,c=a-1,l=(t=>{let s=0;for(;t>>=1;)s++;return s})(a),g=Math.max(1,i+c>>l);e?h=new s(e,n,g):(e=new ArrayBuffer(o*g),h=new s(e)),Object.assign(this,{buffer:e,byteOffset:n,length:i,wordSize:a,wordCount:g,wordSizeMask:c,wordSizeShift:l,internal:h})}toArray(){const t=new Uint8Array(this.length);for(let s=0;s<this.wordCount;s++){const i=this.internal[s];for(let e=s*this.wordSize;e<(s+1)*this.wordSize;e++)t[e]=this.getBit(e,i)}return t}getBit(t,s){if(!(t>=this.length))return null==s&&(s=this.internal[t>>this.wordSizeShift]),s>>(t&this.wordSizeMask)&1}setBit(t,s){if(t>=this.length)return;const i=t>>this.wordSizeShift,e=t&this.wordSizeMask,n=this.internal[i];let r=n;return r|=s<<e,r&=~((1&~s)<<e),n!==r&&(this.internal[i]=r),s}}class n{constructor(t,s=0,n=null){let h,l,g;switch(c(t)){case"Number":h=t=~~t,l=new e(this,{length:h});break;case"ArrayBuffer":l=new e(this,{buffer:t,byteOffset:s,byteLength:n});break;case"Undefined":case"Null":case"RegExp":case"Infinity":h=0,l=new e(this,{length:h});break;case"Array":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"UInt32Array":case"Float32Array":case"Float64Array":case"Uint1Array":case"Object":default:g=o(t),l=new e(this,{length:g.length}),g.forEach(((t,s)=>l.setBit(s,a(t))))}return this[i]=l,new r(this)}static get BYTES_PER_ELEMENT(){return.125}static get name(){return"Uint1Array"}static get length(){return 0}static get[Symbol.species](){return this}static[Symbol.hasInstance](t){return t.__proto__=this}static from(t){const s=o(t);return new n(s)}static of(...t){return n.from(t)}get buffer(){return this[i].buffer}get byteLength(){return this.length+7>>3}get byteOffset(){return this[i].byteOffset}get length(){return this[i].length}get[Symbol.toStringTag](){return"Uint1Array"}copyWithin(t,s=0,i=this.length){if(!Number.isInteger(t))return this;const e=new Uint8Array(i-s);for(let t=s;t<i;t++)e[t-s]=this[t];return this.set(e,t),this}entries(){return this[i].toArray().entries()}every(...t){return this[i].toArray().every(...t)}fill(t,s=0,i=this.length){for(let e=s;e<i;e++)this[e]=t;return this}filter(...t){return new n(this[i].toArray().filter(...t))}find(...t){return this[i].toArray().find(...t)}findIndex(...t){return this[i].toArray().findIndex(...t)}forEach(...t){this[i].toArray().forEach(...t)}includes(...t){return this[i].toArray().includes(...t)}indexOf(...t){return this[i].toArray().indexOf(...t)}join(...t){return this[i].toArray().join(...t)}keys(...t){return this[i].toArray().keys(...t)}lastIndexOf(...t){return this[i].toArray().lastIndexOf(...t)}map(...t){return new n(this[i].toArray().map(...t))}reduce(...t){return this[i].toArray().reduce(...t)}reduceRight(...t){return this[i].toArray().reduceRight(...t)}reverse(){const t=this[i].toArray().reverse();return this.set(t),this}set(s,i=0){if(!Number.isInteger(i))return;const e=c(s);if("Array"!==e&&!t.has(e))return;const n=Math.min(s.length+i,this.length);s=s.map((t=>a(t)));for(let t=i;t<n;t++)this[t]=s[t-i]}slice(...t){return new n(this[i].toArray().slice(...t))}sort(...t){const s=this[i].toArray().sort(...t);return this.set(s),this}subarray(...t){return new n(this[i].toArray().subarray(...t))}values(...t){return this[i].toArray().values(...t)}toLocaleString(...t){return Array.from(this).toLocaleString()}toString(){return""+Array.from(this)}[Symbol.iterator](){return this[i].toArray()[Symbol.iterator]()}valueOf(){return this}toJSON(){return Array.from(this)}}function r(t){const s=t[i];return new Proxy(t,{get(i,e,n){const r="string"==typeof e?parseInt(e):e;return Number.isInteger(r)?s.getBit(r):Reflect.get(t,e)},set(i,e,n,r){const h="string"==typeof e?parseInt(e):e;return Number.isInteger(h)?(s.setBit(h,a(n)),!0):Reflect.set(t,e,n)}})}const h=/\[object (\w+)]/;function o(t){const s=[];for(let i of t){const t=a(i);s.push(t)}return s}function a(t){return"number"!=typeof t||Number.isNaN(t)?new Boolean(t).valueOf():t%2}function c(t){const s=t&&t.constructor?t.constructor.name:null,i=h.exec(Object.prototype.toString.call(t))[1];return i!==s&&s?s:i}class l{static tt(t,s){const i=(t=t.replace(/-/g,"+").replace(/_/g,"/")).length%4;if(i){if(1===i)throw Error("Utils.decodeBase64URLEncoded E16: Input base64url string is the wrong length to determine padding");t+=Array(5-i).join("=")}const e=[...s(t)].map((t=>(t=>{if(t in g)return g[t];const s=[...t.charCodeAt(0).toString(2).padStart(8,"0")].reverse();return g[t]=Number.parseInt(s.join(""),2),g[t]})(t))),r=new ArrayBuffer(e.length);return new Uint8Array(r).set(e),(t=>{const s=[];for(let i=0;i<25;i++){const e=[];for(let s=0;s<40;s++){let n=6,r=0;const h=280*i+7*s;for(let s=h;s<h+7;s++)r+=t[s]*Math.pow(2,n),n--;e.push(String.fromCharCode(r))}s.push(e.join(""))}return s})(new n(r))}static st(t){const s=[];let i=!1;for(const e of[...t]){const t=e.charCodeAt(0);27==t?i=!0:t>=128?s.push(String.fromCharCode(t-128)):i?(s.push(String.fromCharCode(t-64)),i=!1):s.push(e)}return s}static it(t){const s=[],i=/^OL,(\d{1,2}),(.+)/;for(const e of[...t]){const t=e.match(i);null!=t&&(s[t[1]]=l.st(t[2]))}return s}static et(t){return-1!="ﻰﺋﺊﭼﭽﭘﭙﮔﻎﻼﻬﻪﻊﺔﺒﺘﺎﺑﺗﺛﺟﺣﺧﺳﺷﺻﺿﻃﻇﻋﻏﺜﺠﺤﺨـﻓﻗﻛﻟﻣﻧﻫﻰﻳﻴﻌﻐﻔﻘﻠﻤﻨ".indexOf(t)}}const g={},A={ENGINEERING:"QIECBAgQIIcWLGg2EDdy3QIKnXKgYtUE7f2QA2TB0wYr2DECAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAYMS54fzJmix4-YCDToOLOjyZ0WLSkzo6AkcGHuZUcRHlB4dgyAAQAEABAAQAEABAAQAEABAAQAEABAAQAEABAAQAEABAAWDP9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_YNCho9zImSoAqBGoAp0FUy8-iChhz5UCA4MPEuZYgTAFyAFg1_f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f2DYCAAoACACeQHkBdYTJlixIkSKlSJEoUKIEBQABAAQAEABYN_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_39g4AgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgGDn9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_YsAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIBix_f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f2LICAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAYs_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_39i0AgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgAIACAAgGLX9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9__f_3_9_Ytq-jT0yg7OXZs39w0Pzh3Ao_LLl3BZuHPl3dMIGllyBIWzrlLmkKJGTSJUycsoUqlZJYtXLzLBiyZlWjVs3IuHLp2UePXz9AgQokaBIlTJ0ChSqVoFi1cvQMGLJmgaNWzdA4cunaB49fP0ECDChoIkWNHQSJMqWgmTZ09BQo0qaCpVrV0FizatoLl29fQYMOLGgyZc2dBo06taDZt3b0HDjy5oOnXt3QePPr2g-ff38pgw4sZHJlzZyujTq1ktm3dvNcOPLmW6de3cn48-vZf59_fwZiHv3Y8uHYIjbMPPQDVCxcLf4E0-mXDk8mI-_dlFCn5a9_DKr6q-qvqr6q-qvqr6AFS390DJoGQKr6q-qvqr6q-qvqr6o",ADVERT:"QIECBAgQIJ9KDDmRUDZi3QU8PRk1QQeHIHDaIEDJiwYumDACdDwcnbLy6aeeXbl3dECBAgQIECBAgQIECBAgQIHwZkvcoCx0og8LNGjYwQPEjzpoWaNjBA82YHnTQwabEjTpowPEiBAgLHSiBbs1atjFA9SPe2pZqQNUHX1qQatSlrqQNW-5UsaIECAsdKIFidUqQJUCVAlVKlipchQJUCJanVIEqpAlSqlC5CgQIEB0ogQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQHSKBAgQYEH7ogQaGCApw_fEm54R3PCm5JuSKHoFUEVIECAudIoECBB6-___TB-_v0JTU_WqkZHFyQKHmjYgYBECpAqQIC50igQIEH___3_-iD__6FFSAig-IP6JCg26lzRr3avEgFUgLnSKBAg1f1X9lv_9NSBAgI6G-HX1V_EqBUqQJUqXBzagVSAudIoECD9_Qa2qL__6IMDzoq682qdAgQIEARAgQIECBAgVIC50igQIP_9AiaoFX__0VfV_1kjQIECBAgQBECBAgAoECpAgLnSKBBq__0CBCgQa___oreokCBAgQIECBAgQBECBAgVIECAudIoEHr__QIECBAg3_36FAgQIECBAgQIECAIgQIFSBAgQIAZ0igQf_7dAgKIECAinKf9bTR9QIv-N6i_ofzNagQIECBAgJnSKDR__tUBRAoe6NiBB_XYf_rqg_q2iD-gRb-iBAgQIECAmdIoNX_-1QFECDrq9IMH9h664P_D-w34P7DZ4ToECBAgQICZ0ig___5TQ8SfEHzQ82MPCzpoedEHzA82MPjDQ0-LNDSk0JnSOD___lNXVh_Qf9T3cx_oP-prqa_1S3Y0_q_zX-s1NdTUmdI6v_9-U1NUH9B_1NdTX-g_6mvpL_wMNTX-g1Nf6DAz1tSZ0j-_v0JREjQokaFEhRIUSNCiRoUCNAjRoEaBEhRo0CNGgBnSP9OgQFECCNPpIIVKfDkVaUWmggzoiCFPny5M6PTQIECAGdIjUAGlJnR0DBu5coGrFm0YMEE-kgpxYqChBjxUDNuwQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAy92np007s6AFSy9tOXvzQA7O_ryQTd-7L5DQVtpBJ3ZMvg",UK:"QIECBAgQIIcWLGg2EDFy2QIJu_cgZNUETLjQA2TN0xYr2DAodJIECBAgQIEGDB4_PUCBAgQIECBAgQIECBAgQIEANkvaMih0kgQIECDA1Qfv__OgQYGCBAgQIECBAgQIECBAgQIECBAgKHSSBAgQIH6FR-__-v7___oECBAgQIEAORPmxUE6LXpoECAodJIECBAoQKum7______9-gQIECBAgQA82_Zs39-aB8-QIAh0kgQIECBAgSev_____v06BAgQIECBAgQIECBAgQIECBAgKHSSBAgQIECBR00____-_w9GCBAgQIECBAgQIECBAgQIECAodJIECBAgQIECD8rx________ECBAgQIECBAgQIECBAgQICh0kgQIECBAgQLETRlv_______6oECBAgQIECBAgQIECBAgKHSyBAgQIHGQlwYIEH_-_x_____9-dECBAgQIECBAgQIECAIdLIECDAmJbfz_-0RJ0qBV________7sECBAgQIECBAgQIAh0sgQIMzAl-__fX5Sg0JECvX______586IECBAgQIECBAgCHSyBAgwJiW9OjX_0qBAgQIEX________-l8fPjBAgQIECAIdLIEHBYhQIECBQxQICWDhg5fv____________tUCBAgQIAh0sgzIECBAgQIEGlAgQEtP_______________-lQIECBAgCHSyBUwQIECBAgQakCBASQqv_____________-6FAgQIECAIdLIECJygQIECBAgaoEBJBg______________5-OiBAgQIAh0sgQKGKBAgQIEHBKgJIMH7____8v__________QoECBAgCHSyBRmQIECBA4RoECAkgVoVaNel________r16FAgQIECAIdLINCFAgwOEyBAgQICSBAgQePn7___r06RAgQIECBAgQIAh0sgQLeKxCgQIECBAgJIECDR__v0aNGhQIECBAgQIECBAgCHSSBAgQIECBAgQIECBAgQYP3_-1QIECBAgQIECBAgQIECAIdJIECBAgQIECBAgQIECBB6boUSBAgQIECBAgQIECBAgQIAh0kgQIECBAgQIECBAgQIFStAgQIECBAgQIECBAgQIECBAgAzsvjognZe_MFIy4cmzTuy8wdTfwQU-G_l0DVKy-lhyad6A",SPLASH:"QIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECAsaMIEGDx8YIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQICxowg0N2bdmgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgLGjCBFvz9_6BAZQIECBAgQIECAig0NECBAgQIECBAgQIECAsaMcOD5tjyoGCBAgQIECBAgQICLhCgQIECBAgQIECBAgQICxowoTod79ArSEcHBAgQIECBAg0ITKBAgQcGCBAgQIECBAgLGjCBBgXIUCAyRXmlLBAgQIECBuZ4fPn___aoECBAgQIECBAaQIECBAgQIEBFAgQaTPDh8-f___-vXo9f9qgQIECBAgQIECBAgQIEBFAgQcOHz5____69ejRoECBAg__0CBAgQIECBAgQIECBAgQEUCL___r16NGXQIOHDh8-NCOD-3QIECBAgQIECBAgQIECBARQINf0ug-fPi9evRo0aBAgI6v6VAgQIECBAgQIECBAgQIEBFAgRf2hfBw4cOHD58-fPiAj-_oECBAgQIECBAgQIECBAgQEUCBBr-l0SNGjRo0CBAgQEcH9qgQIECBAgQIECBAgQIECBARQIECL-0Lr169ev-fPnxAR1f0KBAgQIECBAgQIAiBAgQIEBFAgQINf3hw4cOCBAgQIEBH-_QIECBAgQIECBAgCIECBAgQIEB1ARRL1-_____________7VAgOIECBAgQIECAIgQIECBAgQHUBNAgQf26BAgQIN_8ijRoECA4gQIECBAgQIAiBAgQIECA6gQE0CDV_QoECBAgRf2iBAgQIEBxAgQIECBAgCIECBAgQIDqBAgQE0aFAgQIECBAgQIECBAgQHECBAgQIECAIgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIBp0Kg3cNqDSggdMuPRh3ZOe_N074eWVf0y7MvTL46IECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQKMalAyYMmKCplx6ECZBT35unfDyyoJnTIuQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA"},_="http://www.w3.org/2000/svg";let u,E,C=0;class I{constructor(){}rt(){return this.nt}ht(){this.nt=null}_t(t,s){if("object"==typeof t)for(const s in t)null==t[s]?this.nt.removeAttribute(s):this.nt.setAttribute(s,t[s]);else{if(void 0===s)return this.nt.getAttribute(t);null==s?this.nt.removeAttribute(t):this.nt.setAttribute(t,s)}return this}ot(t){if(!this.at(t)){const s=this.lt();s.push(t),this.nt.setAttribute("class",s.join(" "))}return this}at(t){return-1!==this.lt().indexOf(t)}lt(){const t=this.nt.getAttribute("class");return null==t?[]:t.split(" ")}At(t){return this.at(t)&&this.nt.setAttribute("class",this.lt().filter((s=>s!==t)).join(" ")),this}ct(t){return this.at(t)?this.At(t):this.ot(t),this}gt(t,s){if("object"==typeof t)for(const s in t)null==t[s]?delete this.nt.dataset[s]:this.nt.dataset[s]=t[s];else{if(void 0===s)return this.nt.dataset[t];null==s?delete this.nt.dataset[t]:this.nt.dataset[t]=s}return this}}class f extends I{constructor(t){return super(),u=t,E=u.document,this.nt=E.createElementNS(_,"svg"),this.nt.setAttribute("xmlns",_),this}ut(t){const s=E.querySelector(t);if(!s)throw Error("@techandsoftware/teletext: E117: addTo failed to match provided selector");return s.appendChild(this.nt),this}Ct(t){return this.nt.setAttribute("viewBox",t),this}ft(t,s){return this.nt.setAttribute("width",t),this.nt.setAttribute("height",s),this}It(t){const s=E.createElementNS(_,"style");return s.append(t),this.nt.append(s),this}Et(){const t=new B;return this.nt.append(t.rt()),t}Bt(){return this.nt.clientWidth}dt(){return this.nt.clientHeight}Qt(t){const s=new b(t);return this.nt.append(s.rt()),s}}class B extends I{constructor(){return super(),this.nt=E.createElementNS(_,"g"),this.yt=[],this}Et(){const t=new B;return this.nt.append(t.rt()),this.yt.push(t),t}bt(t){const s=new y(t);return this.nt.append(s.rt()),this.yt.push(s),s}wt(){const t=new m;return this.nt.append(t.rt()),t}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),this.yt.push(i),i}xt(){return this.yt[this.yt.length-1]}Ut(){return this.yt}vt(t){return this.nt.setAttribute("clip-path",`url("#${t.rt().id}")`),this}kt(){return this.nt.removeAttribute("clip-path"),this}Rt(){this.nt.parentNode&&this.nt.parentNode.removeChild(this.nt),this.nt=null,this.yt.forEach((t=>t.ht())),this.yt=[]}Ft(t,s,i,e){const n=new S(t,s,i,e);return this.nt.append(n.rt()),this.yt.push(n),n}Lt(t){const s=new d(t);return this.nt.append(s.rt()),this.yt.push(s),s}Dt(t,s){const i=new Q(t,s);return this.nt.append(i.rt()),this.yt.push(i),i}}class Q extends I{constructor(t,s){return super(),this.nt=E.createElementNS(_,"image"),this.nt.setAttribute("width",parseInt(t)),this.nt.setAttribute("height",parseInt(s)),this}attr(...t){return this._t(...t)}}class d extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"use"),this.nt.setAttribute("href","#"+t),this}Nt(t){return this.nt.setAttribute("fill",t),this}Gt(t,s){return this.nt.setAttribute("x",t),this.nt.setAttribute("y",s),this}}class b extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"symbol"),this.nt.setAttribute("id",t),this}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),i}}class y extends I{constructor(t){return super(),this.nt=E.createElementNS(_,"text"),this.nt.append(t),this}bt(t){return this.nt.textContent=t,this}Nt(t){return this.nt.setAttribute("fill",t),this}}class m extends I{constructor(){return super(),this.nt=E.createElementNS(_,"defs"),this}Ht(){const t=new w;return this.nt.append(t.rt()),t}jt(t){return[...this.nt.querySelectorAll(t)].map(v)}St(t,s){const i=new p(t,s);return this.nt.append(i.rt()),i}}class w extends I{constructor(){return super(),this.nt=E.createElementNS(_,"clipPath"),this.nt.setAttribute("id","clipPath-"+C),C++,this}Ut(){return[...this.nt.children].map(v)}Ot(t){this.nt.appendChild(t.rt())}}class p extends I{constructor(t,s){if(super(),t instanceof u.SVGElement)return this.nt=t,this;const i=t;return this.nt=E.createElementNS(_,"rect"),this.nt.setAttribute("width",parseInt(i)),this.nt.setAttribute("height",parseInt(s)),this}Nt(t){return this.nt.setAttribute("fill",t),this}Gt(t,s){return this.nt.setAttribute("x",t),this.nt.setAttribute("y",s),this}Bt(t){return void 0===t?parseInt(this.nt.getAttribute("width")):(this.nt.setAttribute("width",parseInt(t)),this)}dt(t){return void 0===t?parseInt(this.nt.getAttribute("height")):(this.nt.setAttribute("height",parseInt(t)),this)}Rt(){this.nt.parentNode&&this.nt.parentNode.removeChild(this.nt),this.nt=null}}class S extends I{constructor(t,s,i,e){return super(),this.nt=E.createElementNS(_,"line"),this.nt.setAttribute("x1",t),this.nt.setAttribute("y1",s),this.nt.setAttribute("x2",i),this.nt.setAttribute("y2",e),this}}function v(t){let s;switch(t.constructor.name){case"SVGRectElement":s=new p(t);break;default:throw Error("SVG:wrapSVGElement Unable to wrap SVG element of type "+t.constructor.name)}return s}const x={BLACK:Symbol(),RED:Symbol(),GREEN:Symbol(),YELLOW:Symbol(),BLUE:Symbol(),MAGENTA:Symbol(),CYAN:Symbol(),WHITE:Symbol()};Object.freeze(x);const k={Pt:Symbol(),Mt:Symbol(),qt:Symbol(),Tt:Symbol()};Object.freeze(k);const U={zt:Symbol(),Jt:Symbol(),Yt:Symbol(),Vt:Symbol()};Object.freeze(U);class N{static charFromTextColour(t){if(t in G)return G[t];throw Error("Attributes.charFromTextColour: bad colour: "+t)}static charFromGraphicColour(t){if(t in L)return L[t];throw Error("Attributes.charFromGraphicColour: bad colour")}static charFromAttribute(t){if(t in P)return P[t];throw Error("Attributes.charFromAttribute: bad attribute")}}function D(t){return O[t]}N.TEXT_COLOUR=k.Pt,N.MOSAIC_COLOUR=Symbol(),N.NEW_BACKGROUND=Symbol(),N.BLACK_BACKGROUND=Symbol(),N.CONTIGUOUS_GRAPHICS=k.Mt,N.SEPARATED_GRAPHICS=k.qt,N.ESC=Symbol(),N.FLASH=Symbol(),N.STEADY=Symbol(),N.NORMAL_SIZE=U.zt,N.DOUBLE_HEIGHT=U.Jt,N.DOUBLE_WIDTH=U.Yt,N.DOUBLE_SIZE=U.Vt,N.CONCEAL=Symbol(),N.HOLD_MOSAICS=Symbol(),N.RELEASE_MOSAICS=Symbol(),N.START_BOX=Symbol(),N.END_BOX=Symbol(),N.Kt=Symbol();const O={[x.BLACK]:"#000",[x.RED]:"#f00",[x.GREEN]:"#0f0",[x.YELLOW]:"#ff0",[x.BLUE]:"#00f",[x.MAGENTA]:"#f0f",[x.CYAN]:"#0ff",[x.WHITE]:"#fff"};Object.freeze(O);const R={"\0":x.BLACK,"":x.RED,"":x.GREEN,"":x.YELLOW,"":x.BLUE,"":x.MAGENTA,"":x.CYAN,"":x.WHITE};Object.freeze(R);const j={"":x.BLACK,"":x.RED,"":x.GREEN,"":x.YELLOW,"":x.BLUE,"":x.MAGENTA,"":x.CYAN,"":x.WHITE};Object.freeze(j);const F={"\b":N.FLASH,"\t":N.STEADY,"\n":N.END_BOX,"\v":N.START_BOX,"\f":N.NORMAL_SIZE,"\r":N.DOUBLE_HEIGHT,"":N.DOUBLE_WIDTH,"":N.DOUBLE_SIZE,"":N.CONCEAL,"":N.CONTIGUOUS_GRAPHICS,"":N.SEPARATED_GRAPHICS,"":N.ESC,"":N.BLACK_BACKGROUND,"":N.NEW_BACKGROUND,"":N.HOLD_MOSAICS,"":N.RELEASE_MOSAICS},G={};for(const t in R)G[R[t]]=t,F[t]=R[t];Object.freeze(G);const L={};for(const t in j)L[j[t]]=t,F[t]=j[t];Object.freeze(L),Object.freeze(F);const P={};for(const t in F)P[F[t]]=t;Object.freeze(P);const H={0:Symbol(),1:Symbol(),1.5:Symbol(),2.5:Symbol()};Object.freeze(H);const M={};M[H[0]]=[1,2,3,4,5,6,7,8,9,17,18,19,20,21,22,23],M[H[1]]=[...M[H[0]]].concat([10,11,12,13,24,25,26,27,28,29,30,31]),M[H[1.5]]=[...M[H[1]]].concat([0,16]),M[H[2.5]]=[...M[H[1.5]]].concat([14,15]),Object.freeze(M);const q={Zt:{Xt:10.4,Wt:-5.2},$t:{Xt:10,Wt:-4.5}};Object.freeze(q);class T{constructor(t,s){this.ts=new f(s).Ct("0 0 399 249").ft(800,666.6666666666666)._t({preserveAspectRatio:"none",style:"font-family: sans-serif"}).It("@font-face {\nfont-family: 'Unscii';\nsrc: url('fonts/unscii-16.woff') format('woff'), \nurl('fonts/unscii-16.ttf') format('truetype'),\nurl('fonts/unscii-16.otf') format('opentype');\nunicode-range: U+0000-00FF, U+2022, U+2500, U+2502, U+250C, U+2510, U+2514, U+2518, U+251C, U+251D, U+2524, U+2525, U+252C, U+252F, U+2534, U+2537, U+253C, U+253F, U+2588, U+258C, U+2590, U+2592, U+25CB, U+25CF, U+25E2-25E5, U+2B60-2B63, U+E0C0-E0FF, U+1FB00-1FB70, U+1FB75, U+1FBA0-1FBA7;\n-webkit-font-smoothing: none;\nfont-smooth: never;\n}\n@font-face {\nfont-family: 'Bedstead';\nsrc: url('fonts/bedstead.otf') format('opentype');\nunicode-range: U+0000-00FF;\n}\n@keyframes blink {\nto {\nvisibility: hidden;\n}\n}\n@keyframes fancyblink {\nfrom {\nfilter: none;\nopacity: 0.7;\n}\n33% {\nfilter: none;\nopacity: 1;\n}\n66% {\nfilter: blur(0px);\nopacity: 1;\n}\n95% {\nfilter: blur(4px);\nopacity: 0;\n}\nto {\nfilter: blur(0px);\nopacity: 0;\n}\n}\n#textlayer {\nfont-size: 10px;\n}\n.mosaic {\nfont-family: 'Unscii';\nfont-size: 10.3px;\n}\n.mosaic_separated {\nfont-family: 'Unscii';\nfont-size: 10px;\n}\n.flash_flashing .flash {\n/* animation: blink 2s steps(3, start) infinite; */\nanimation: fancyblink 2s linear infinite;\n}\n.conceal_concealed .conceal {\nvisibility: hidden;\n}\nsvg #background {\ntransition-property: opacity;\ntransition-duration: 0.25s;\n}\nsvg {\nbackground-color: transparent;\n}\nsvg use {\nshape-rendering: crispEdges;\n}\nrect { color: orange; }\n"),this.d=this.ts.Et()._t("class","conceal_concealed flash_flashing"),this.ss=1.2,this.es(),this.rs(),this.ns=null,this.hs=t,this._s=this.hs.ls.os((()=>this.As())),this.cs=!1,this.gs=!1,this.us=!1,this.Cs={}}ut(t){this.ts.ut(t)}fs(){this.hs.ls.fs(this._s),this._s=null}As(){let t=!1,s=!1;this.us=!1,this.d.At("flash_flashing"),this.Is.forEach(((i,e)=>{let n=!1;if(this.Es(e),t)return t=!1,void this.Bs(i,e);const r=this.hs.ds(e);let h,o;i.forEach(((t,i)=>{if(n)return n=!1,this.Qs(t),this.ys(e),void(o&&this.bs());const a=r.ps(i),c=D(a.ws),l=a.Ss(),g=D(a.xs),A=this.Us(a.vs,l,a.et);this.ks(t,a,A,g,i,e,l),a.Rs&&(o?this.bs():this.Fs(e,i),this.us=!0),h==c?this.ys(e):this.Ls(e,i,c),a.ft!=U.Yt&&a.ft!=U.Vt||(n=!0),h=c,o=a.Rs,a.Ds&&(s=!0)})),r.Ns?(this.Gs(e),this.Hs(),t=!0):t=!1,this.js(e)})),"Os"in this.Cs&&this.Cs.Os(this.ts.Bt(),this.ts.dt()),this.d.ot("conceal_concealed"),s&&setTimeout((()=>this.d.ot("flash_flashing")),100),this.Ps()}Es(t){this.Ms(t),this.qs(t)}Bs(t,s){"Ts"in this.Cs&&this.Cs.Ts(t.length,s),t.forEach((t=>this.Qs(t)))}Qs(t){t.bt(" ")._t({dx:null,dy:null,textLength:null,lengthAdjust:null,"text-anchor":null,transform:null,class:null})}ks(t,s,i,e,n,r,h){this.zs(t,s,i,e,n,r),s.vs==k.Mt&&h||s.vs==k.Tt?t.ot("mosaic"):s.vs==k.qt&&h&&t.ot("mosaic_separated")}zs(t,s,i,e,n,r){t.bt(s.Js)._t(i).Nt(e),s.ft==U.Jt?t._t("transform",`translate(0 ${Z(r)}) scale(1 2)`):s.ft==U.Yt?t._t("transform",`translate(${K(n)} 0) scale(2 1)`):s.ft==U.Vt&&t._t("transform",`translate(${K(n)} ${Z(r)}) scale(2 2)`),s.Ds&&t.ot("flash"),s.Ys&&t.ot("conceal")}Vs(){this.d.ct("conceal_concealed")}Ks(t){let s=t;"native"==t?s='-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans",sans-serif':"default"==t&&(s="sans-serif"),this.ts._t("style","font-family: "+s)}Zs(){this.ns?(this.ns.Rt(),this.ns=null):this.Xs()}Ws(){this.gs?(this.gs=!1,this.$s._t("opacity",null).kt()):(this.gs=!0,this.ti())}si(t){this.ss=t,this.ii(this.ts.dt())}ii(t){this.ts.ft("natural"==this.ss?1.6*t:t*this.ss,t)}ti(){this.cs&&this.us?this.$s._t("opacity",.3):this.us?this.$s.vt(this.ei)._t("opacity",.3):this.$s._t("opacity",0)}Ps(){this.gs&&this.ti()}ri(){this.cs?(this.d.kt(),this.cs=!1):(this.d.vt(this.ei),this.cs=!0),this.Ps()}Xs(){this.ns=this.d.Et();for(let t=0;t<25;t++)this.ns.Ft(0,10*t,399,10*t)._t({stroke:"#555","stroke-width":.5});for(let t=0;t<40;t++)this.ns.Ft(10*t,0,10*t,249)._t({stroke:"#555","stroke-width":.5})}rs(){this.ni=this.d.wt(),this.hi=null,this.ei=this.ni.Ht()}es(){this._i(),this.oi()}_i(){const t=this.d.Et();t._t({"shape-rendering":"crispEdges",id:"background"}),this.ai=[],this.$s=t}oi(){const t=[],s=this.d.Et()._t({"text-anchor":"middle",fill:"#fff"})._t("id","textlayer");for(let i=0;i<25;i++){const e=[];for(let t=0;t<40;t++)e.push(s.bt(String.fromCharCode(32+95*Math.random()))._t({x:10*t+5,y:10*i+8}));t.push(e)}this.Is=t,this.li=s}qs(t){this.ei.Ut().filter((s=>s.gt("r")==t)).forEach((t=>t.Rt()))}Ms(t){this.ai[t]&&this.ai[t].Rt(),this.ai[t]=this.$s.Et()}ys(t){const s=this.ai[t].xt(),i=s.Bt();s.Bt(i+10)}Ls(t,s,i){const e=10*s,n=10*t;this.ai[t].St(10,10).Nt(i).Gt(e,n)}bs(){const t=this.hi.Bt();this.hi.Bt(t+10)}Gs(t){this.ai[t].Ut().forEach((t=>t._t("height",20)))}Hs(){this.ni.jt("[data-boxbuffer]").forEach((t=>t.dt(20)))}Fs(t,s){const i=10*s,e=10*t;this.hi=this.ni.St(10,10).gt("boxbuffer",!0).Gt(i,e)}js(t){this.ni.jt("[data-boxbuffer]").forEach((s=>{s.gt({r:t,boxbuffer:null}),this.ei.Ot(s)}))}Us(t,s,i){return t==k.Mt&&s||t==k.Tt?{dx:q.Zt.Wt,dy:-.15,textLength:q.Zt.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:t==k.qt&&s?{dx:q.$t.Wt,dy:null,textLength:q.$t.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:{dx:null,dy:null,textLength:i?10:null,lengthAdjust:i?"spacingAndGlyphs":null,"text-anchor":null,transform:null,class:null}}registerPlugin(t,s){return"renderBackground"in s&&(this.Cs.Ai=s.renderBackground),"renderMosaic"in s&&(this.Cs.ci=s.renderMosaic),"endOfPageUpdate"in s&&(this.Cs.Os=s.endOfPageUpdate),"clearCellsForRow"in s&&(this.Cs.Ts=s.clearCellsForRow),{lookupColour:X,isDoubleHeight:J,isDoubleWidth:z,isDoubleSize:Y,isSeparatedMosaic:V,createImageOverlay:this.gi.bind(this)}}gi(){const t=this.d.Dt(400,250);return t._t("preserveAspectRatio","none"),t}}T.ui=10,T.Ci=10,T.fi=20,T.Ii=20,T.Ei=400,T.Bi=250,T.di=q,T.ROWS=25,T.COLS=40;const X=t=>D(t),J=t=>t==U.Jt,z=t=>t==U.Yt,Y=t=>t==U.Vt,V=t=>t==k.qt,Z=t=>0-10*t,K=t=>0-10*t,W={g0_latin:{$:"¤","":"■"},g0_latin__czech_slovak:{"#":"#",$:"ů","@":"č","[":"ť","\\":"ž","]":"ý","^":"í",_:"ř","`":"é","{":"á","|":"|","}":"ú","~":"š"},g0_latin__english:{"#":"£",$:"$","@":"@","[":"←","\\":"½","]":"→","^":"↑",_:"#","`":"—","{":"¼","|":"‖","}":"¾","~":"÷"},g0_latin__estonian:{"#":"#",$:"õ","@":"Š","[":"Ä","\\":"Ö","]":"Ž","^":"Ü",_:"Õ","`":"š","{":"ä","|":"ö","}":"ž","~":"ü"},g0_latin__french:{"#":"é",$:"ï","@":"à","[":"ë","\\":"ê","]":"ù","^":"î",_:"#","`":"è","{":"â","|":"ô","}":"û","~":"ç"},g0_latin__german:{"#":"#",$:"$","@":"§","[":"Ä","\\":"Ö","]":"Ü","^":"^",_:"_","`":"°","{":"ä","|":"ö","}":"ü","~":"ß"},g0_latin__italian:{"#":"£",$:"$","@":"é","[":"°","\\":"ç","]":"→","^":"↑",_:"#","`":"ù","{":"à","|":"ò","}":"è","~":"ì"},g0_latin__latvian_lithuanian:{"#":"#",$:"$","@":"Š","[":"ė","\\":"ę","]":"Ž","^":"č",_:"ū","`":"š","{":"ą","|":"ų","}":"ž","~":"į"},g0_latin__polish:{"#":"#",$:"ń","@":"ą","[":"Ƶ","\\":"Ś","]":"Ł","^":"ć",_:"ó","`":"ę","{":"ż","|":"ś","}":"ł","~":"ź"},g0_latin__portuguese_spanish:{"#":"ç",$:"$","@":"¡","[":"á","\\":"é","]":"í","^":"ó",_:"ú","`":"¿","{":"ü","|":"ñ","}":"è","~":"à"},g0_latin__romanian:{"#":"#",$:"¤","@":"Ț","[":"Â","\\":"Ș","]":"Ă","^":"Î",_:"ı","`":"ț","{":"â","|":"ș","}":"ă","~":"î"},g0_latin__serbian_croatian_slovenian:{"#":"#",$:"Ë","@":"Č","[":"Ć","\\":"Ž","]":"Đ","^":"Š",_:"ë","`":"č","{":"ć","|":"ž","}":"đ","~":"š"},g0_latin__swedish_finnish_hungarian:{"#":"#",$:"¤","@":"É","[":"Ä","\\":"Ö","]":"Å","^":"Ü",_:"_","`":"é","{":"ä","|":"ö","}":"å","~":"ü"},g0_latin__turkish:{"#":"₺",$:"ğ","@":"İ","[":"Ş","\\":"Ö","]":"Ç","^":"Ü",_:"Ğ","`":"ı","{":"ş","|":"ö","}":"ç","~":"ü"},g2_latin:{0:"°",1:"±",2:"²",3:"³",4:"×",5:"µ",6:"¶",7:"·",8:"÷",9:"’","!":"¡",'"':"¢","#":"£","%":"¥","&":"#","'":"§","(":"¤",")":"‘","*":"“","+":"«",",":"←","-":"↑",".":"→","/":"↓",":":"”",";":"»","<":"¼","=":"½",">":"¾","?":"¿","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"—",Q:"¹",R:"®",S:"©",T:"™",U:"♪",V:"₠",W:"‰",X:"α",Y:null,Z:null,"[":null,"\\":"⅛","]":"⅜","^":"⅝",_:"⅞","`":"Ω",a:"Æ",b:"Ð",c:"ª",d:"Ħ",e:null,f:"IJ",g:"Ŀ",h:"Ł",i:"Ø",j:"Œ",k:"º",l:"Þ",m:"Ŧ",n:"Ŋ",o:"ʼn",p:"ĸ",q:"æ",r:"đ",s:"ð",t:"ħ",u:"ı",v:"ij",w:"ŀ",x:"ł",y:"ø",z:"œ","{":"ß","|":"þ","}":"ŧ","~":"ŋ","":"■"},g0_greek:{"<":"«",">":"»","@":"ΐ",A:"Α",B:"Β",C:"Γ",D:"Δ",E:"Ε",F:"Ζ",G:"Η",H:"Θ",I:"Ι",J:"Κ",K:"Λ",L:"Μ",M:"Ν",N:"Ξ",O:"Ο",P:"Π",Q:"Ρ",R:"ʹ",S:"Σ",T:"Τ",U:"Υ",V:"Φ",W:"Χ",X:"Ψ",Y:"Ω",Z:"Ϊ","[":"Ϋ","\\":"ά","]":"έ","^":"ή",_:"ί","`":"ΰ",a:"α",b:"β",c:"γ",d:"δ",e:"ε",f:"ζ",g:"η",h:"θ",i:"ι",j:"κ",k:"λ",l:"μ",m:"ν",n:"ξ",o:"ο",p:"π",q:"ρ",r:"ς",s:"σ",t:"τ",u:"υ",v:"φ",w:"χ",x:"ψ",y:"ω",z:"ϊ","{":"ϋ","|":"ό","}":"ύ","~":"ώ","":"■"},g2_greek:{0:"°",1:"±",2:"²",3:"³",4:"×",5:"m",6:"n",7:"p",8:"÷",9:"’","!":"a",'"':"b","#":"£",$:"e","%":"h","&":"i","'":"§","(":":",")":"‘","*":"“","+":"k",",":"←","-":"↑",".":"→","/":"↓",":":"”",";":"t","<":"¼","=":"½",">":"¾","?":"x","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"?",Q:"¹",R:"®",S:"©",T:"™",U:"♪",V:"₠",W:"‰",X:"ɑ",Y:"Ί",Z:"Ύ","[":"Ώ","\\":"⅛","]":"⅜","^":"⅝",_:"⅞","`":"C",a:"D",b:"F",c:"G",d:"J",e:"L",f:"Q",g:"R",h:"S",i:"U",j:"V",k:"W",l:"Y",m:"Z",n:"Ά",o:"Ή",p:"c",q:"d",r:"f",s:"g",t:"j",u:"l",v:"q",w:"r",x:"s",y:"u",z:"v","{":"w","|":"y","}":"z","~":"Έ","":"■"},g0_cyrillic:{"@":"Ю",A:"А",B:"Б",C:"Ц",D:"Д",E:"Е",F:"Ф",G:"Г",H:"Х",I:"И",J:"Ѝ",K:"К",L:"Л",M:"М",N:"Н",O:"О",P:"П",Q:"Я",R:"Р",S:"С",T:"Т",U:"У",V:"Ж",W:"В",X:"Ь",Z:"З","[":"Ш","]":"Щ","^":"Ч","`":"ю",a:"а",b:"б",c:"ц",d:"д",e:"е",f:"ф",g:"г",h:"х",i:"и",j:"ѝ",k:"к",l:"л",m:"м",n:"н",o:"о",p:"п",q:"я",r:"р",s:"с",t:"т",u:"у",v:"ж",w:"в",x:"ь",z:"з","{":"ш","}":"щ","~":"ч","":"■"},g0_cyrillic__russian_bulgarian:{"&":"ы",Y:"Ъ","\\":"Э",_:"Ы",y:"ъ","|":"э"},g0_cyrillic__serbian_croatian:{"@":"Ч",J:"Ј",Q:"Ќ",V:"В",W:"Ѓ",X:"Љ",Y:"Њ","[":"Ћ","\\":"Ж","]":"Ђ","^":"Ш",_:"Џ","`":"ч",j:"ј",q:"ќ",v:"в",w:"ѓ",x:"љ",y:"њ","{":"ћ","|":"ж","}":"ђ","~":"ш"},g0_cyrillic__ukranian:{"&":"ї",Y:"І","\\":"Є",_:"Ї",y:"і","|":"є"},g2_cyrillic:{0:"m",1:"n",2:"p",3:"t",4:"x",5:"x",6:"°",7:"±",8:"²",9:"³","!":"a",'"':"b","#":"£",$:"e","%":"h","&":"i","'":"§","(":":",")":"‘","*":"“","+":"k",",":"←","-":"↑",".":"→","/":"↓",":":"¼",";":"½","<":"¾","=":"÷",">":"’","?":"”","@":" ",A:"̀",B:"́",C:"̂",D:"̃",E:"̄",F:"̆",G:"̇",H:"̈",I:"̣",J:"̊",K:"̧",L:"̲",M:"̋",N:"̨",O:"̌",P:"?",Q:"©",R:"®",S:"¹",T:"ɑ",U:"Ί",V:"Ύ",W:"Ώ",X:"‰",Y:"₠",Z:"™","[":"⅛","\\":"⅜","]":"⅝","^":"⅞",_:"♪","`":"C",a:"D",b:"F",c:"G",d:"J",e:"L",f:"Q",g:"R",h:"S",i:"U",j:"V",k:"W",l:"Y",m:"Z",n:"Ά",o:"Ή",p:"c",q:"d",r:"f",s:"g",t:"j",u:"l",v:"q",w:"r",x:"s",y:"u",z:"v","{":"w","|":"y","}":"z","~":"Έ","":"■"},g0_arabic:{"#":"£","&":"ﻰ","'":"ﻱ","(":")",")":"(",";":"؛","<":">",">":"<","?":"؟","@":"ﺔ",A:"ﺀ",B:"ﺒ",C:"ﺏ",D:"ﺘ",E:"ﺕ",F:"ﺎ",G:"ﺍ",H:"ﺑ",I:"ﺓ",J:"ﺗ",K:"ﺛ",L:"ﺟ",M:"ﺣ",N:"ﺧ",O:"ﺩ",P:"ﺫ",Q:"ﺭ",R:"ﺯ",S:"ﺳ",T:"ﺷ",U:"ﺻ",V:"ﺿ",W:"ﻃ",X:"ﻇ",Y:"ﻋ",Z:"ﻏ","[":"ﺜ","\\":"ﺠ","]":"ﺤ","^":"ﺨ",_:"#","`":"ـ",a:"ﻓ",b:"ﻗ",c:"ﻛ",d:"ﻟ",e:"ﻣ",f:"ﻧ",g:"ﻫ",h:"ﻭ",i:"ﻰ",j:"ﻳ",k:"ﺙ",l:"ﺝ",m:"ﺡ",n:"ﺥ",o:"ﻴ",p:"ﻯ",q:"ﻌ",r:"ﻐ",s:"ﻔ",t:"ﻑ",u:"ﻘ",v:"ﻕ",w:"ﻙ",x:"ﻠ",y:"ﻝ",z:"ﻤ","{":"ﻡ","|":"ﻨ","}":"ﻥ","~":"ﻻ","":"■"},g2_arabic:{0:"٠",1:"١",2:"٢",3:"٣",4:"٤",5:"٥",6:"٦",7:"٧",8:"٨",9:"٩","!":"ﻉ",'"':"ﺁ","#":"ﺃ",$:"ﺅ","%":"ﺇ","&":"ﺋ","'":"ﺊ","(":"ﭼ",")":"ﭽ","*":"ﭺ","+":"ﭘ",",":"ﭙ","-":"ﭖ",".":"ﮊ","/":"ﮔ",":":"ﻎ",";":"ﻍ","<":"ﻼ","=":"ﻬ",">":"ﻪ","?":"ﻩ","@":"à","[":"ë","\\":"ê","]":"ù","^":"î",_:"ﻊ","`":"é","{":"â","|":"ô","}":"û","~":"ç","":"■"},g0_hebrew:{"#":"£","[":"←","\\":"½","]":"→","^":"↑",_:"#","`":"א",a:"ב",b:"ג",c:"ד",d:"ה",e:"ו",f:"ז",g:"ח",h:"ט",i:"י",j:"ך",k:"כ",l:"ל",m:"ם",n:"מ",o:"ן",p:"נ",q:"ס",r:"ע",s:"ף",t:"פ",u:"ץ",v:"צ",w:"ק",x:"ר",y:"ש",z:"ת","{":"₪","|":"‖","}":"¾","~":"÷","":"■"},g1_block_mosaic_to_unicode__legacy_computing:{0:"🬏",1:"🬐",2:"🬑",3:"🬒",4:"🬓",5:"▌",6:"🬔",7:"🬕",8:"🬖",9:"🬗"," ":" ","!":"🬀",'"':"🬁","#":"🬂",$:"🬃","%":"🬄","&":"🬅","'":"🬆","(":"🬇",")":"🬈","*":"🬉","+":"🬊",",":"🬋","-":"🬌",".":"🬍","/":"🬎",":":"🬘",";":"🬙","<":"🬚","=":"🬛",">":"🬜","?":"🬝","`":"🬞",a:"🬟",b:"🬠",c:"🬡",d:"🬢",e:"🬣",f:"🬤",g:"🬥",h:"🬦",i:"🬧",j:"▐",k:"🬨",l:"🬩",m:"🬪",n:"🬫",o:"🬬",p:"🬭",q:"🬮",r:"🬯",s:"🬰",t:"🬱",u:"🬲",v:"🬳",w:"🬴",x:"🬵",y:"🬶",z:"🬷","{":"🬸","|":"🬹","}":"🬺","~":"🬻","":"█"},g1_block_mosaic_to_unicode__unscii_separated:{0:"",1:"",2:"",3:"",4:"",5:"",6:"",7:"",8:"",9:""," ":" ","!":"",'"':"","#":"",$:"","%":"","&":"","'":"","(":"",")":"","*":"","+":"",",":"","-":"",".":"","/":"",":":"",";":"","<":"","=":"",">":"","?":"","`":"",a:"",b:"",c:"",d:"",e:"",f:"",g:"",h:"",i:"",j:"",k:"",l:"",m:"",n:"",o:"",p:"",q:"",r:"",s:"",t:"",u:"",v:"",w:"",x:"",y:"",z:"","{":"","|":"","}":"","~":"","":""},g3:{0:"🭇",1:"🭈",2:"🭉",3:"🭊",4:"🭋",5:"◢",6:"🭌",7:"🭍",8:"🭎",9:"🭏"," ":"🬼","!":"🬽",'"':"🬾","#":"🬿",$:"🭀","%":"◣","&":"🭁","'":"🭂","(":"🭃",")":"🭄","*":"🭅","+":"🭆",",":"🭨","-":"🭩",".":"🭰","/":"▒",":":"🭐",";":"🭑","<":"🭪","=":"🭫",">":"🭵","?":"█","@":"┷",A:"┯",B:"┝",C:"┥",D:"🮤",E:"🮥",F:"🮦",G:"🮧",H:"🮠",I:"🮡",J:"🮢",K:"🮣",L:"┿",M:"•",N:"●",O:"○",P:"│",Q:"─",R:"┌",S:"┐",T:"└",U:"┘",V:"├",W:"┤",X:"┬",Y:"┴",Z:"┼","[":"→","\\":"←","]":"↑","^":"↓",_:" ","`":"🭒",a:"🭓",b:"🭔",c:"🭕",d:"🭖",e:"◥",f:"🭗",g:"🭘",h:"🭙",i:"🭚",j:"🭛",k:"🭜",l:"🭬",m:"🭭",n:null,o:null,p:"🭝",q:"🭞",r:"🭟",s:"🭠",t:"🭡",u:"◤",v:"🭢",w:"🭣",x:"🭤",y:"🭥",z:"🭦","{":"🭧","|":"🭮","}":"🭯","~":null,"":null}},$={};class tt{constructor(t){this.type=t.vs,this.flashing=t.Ds,this.concealed=t.Ys,this.size=t.ft,this.sextants=t.Qi()}}class st{constructor(){this.yi=" ",this.bi=" ",this.pi=x.WHITE,this.mi=x.BLACK,this.wi=k.Pt,this.Si=!1,this.xi=U.zt,this.Ui=!1,this.vi=!1,this.ki=null,this.Ri=!1,this.Fi=null,this.Li=null}set Di(t){this.yi=t}get Di(){return this.yi}set xs(t){this.pi=t}get xs(){return this.pi}set ws(t){this.mi=t}get ws(){return this.mi}get et(){return this.Ri}Ni(t){const s=this.wi==k.Mt||this.wi==k.qt;this.wi==k.Pt||0==(32&this.yi.charCodeAt(0))&&s?(this.bi=et(this.yi,t),this.Fi>0&&(this.bi+=W.g2_latin[String.fromCharCode(this.Fi+64)]),this.Ri=!1,"g0_arabic"!=t&&"g2_arabic"!=t||(this.Ri=l.et(this.bi))):this.wi==k.Mt?this.bi=et(this.yi,"g1_block_mosaic_to_unicode__legacy_computing"):this.wi==k.qt?this.bi=et(this.yi,"g1_block_mosaic_to_unicode__unscii_separated"):this.wi==k.Tt&&(this.bi=et(this.yi,"g3")),this.ki=null}Gi(t){if(this.wi!=k.Mt&&this.wi!=k.qt||!t.Hi)this.ki=null,this.bi=" ";else{this.ki=t.Js,this.wi=t.vs;let s="g1_block_mosaic_to_unicode__legacy_computing";this.wi==k.qt&&(s="g1_block_mosaic_to_unicode__unscii_separated"),this.bi=et(t.Js,s)}}get Js(){return this.bi}get vs(){return this.wi}set vs(t){this.wi=t}set Ds(t){this.Si=t}get Ds(){return this.Si}get ft(){return this.xi}set ft(t){this.xi=t}set Ys(t){this.Ui=t}get Ys(){return this.Ui}set Rs(t){this.vi=t}get Rs(){return this.vi}Ss(){const t=null!=this.ki?this.ki.charCodeAt(0):this.yi.charCodeAt(0);return t<=127&&32==(32&t)}ji(){const t=this.yi.charCodeAt(0);return(this.wi==k.Mt||this.wi==k.qt)&&t<=127&&32==(32&t)}Qi(){const t=null!=this.ki?this.ki.charCodeAt(0):this.yi.charCodeAt(0);if(t>127)return null;if(t in $)return $[t];let s=t-32;return s>=64&&(s-=32),$[t]=[...s.toString(2).padStart(6,"0")].reverse(),$[t]}}class it extends st{constructor(t){super(),Object.assign(this,t)}set Oi(t){this.Fi=t}get Oi(){return this.Fi}set Pi(t){this.Li=t}get Js(){return null==this.Li?this.bi:this.Li}}function et(t,s){if(!(s in W))throw Error("Cell getCharWithEncoding: bad encoding: "+s);if(t in W[s])return W[s][t];const i=s.match(/^(.+)__/);if(null!=i){const e=i[1];if(t in W[e])return W[s][t]=W[e][t],W[e][t]}return t}class nt extends T{constructor(t,s,i){super(t,i),this.Mi=s,this.qi=new Set}es(){super.es(),this.Ti=[],this.zi=this.d.Et()}Es(t){super.Es(t),this.Ji(t)}ks(t,s,i,e,n,r,h){"Ai"in this.Cs&&this.Cs.Ai(r,n,s.ft,s.ws),s.vs!=k.Pt&&s.vs!=k.Tt&&h?h&&(t.bt(" ")._t(i),this.Yi(r,n,s,e)):(this.zs(t,s,i,e,n,r),s.vs==k.Tt&&t.ot("mosaic"))}Yi(t,s,i,e){if("ci"in this.Cs){const n=new tt(i);if(this.Cs.ci(t,s,n,e))return}const n=i.Qi();if(!n.includes("1"))return;let r=i.vs==k.Mt?"c":"s";r+=n.join("");let h,o=T.ui,a=T.Ci;if(i.vs==k.Mt&&(o=T.ui+.3,a=T.Ci+.2),!this.qi.has(r)){this.qi.add(r);const t=this.ts.Qt(r);if(i.vs==k.Mt){t._t({preserveAspectRatio:"none",width:o,height:a,viewBox:"0 0 12 18"});for(let s=0;s<6;s++)"1"==n[s]&&t.St(6,6).Gt(s%2*6,6*Math.floor(s/2))}else{t._t({preserveAspectRatio:"none",width:o,height:a,viewBox:"0 0 12 18"});for(let s=0;s<6;s++)"1"==n[s]&&t.St(4,4).Gt(s%2*6+1,6*Math.floor(s/2)+2)}}h=i.vs==k.Mt?this.Ti[t].Lt(r).Gt(s*T.ui-.15,t*T.Ci-.1).Nt(e):this.Ti[t].Lt(r).Gt(s*T.ui,t*T.Ci).Nt(e),this.Mi&&h._t({width:o,height:a}),i.ft!=U.Jt&&i.ft!=U.Vt||h._t("height",T.Ii),i.ft!=U.Yt&&i.ft!=U.Vt||h._t("width",T.fi),i.Ds&&h.ot("flash"),i.Ys&&h.ot("conceal")}Ji(t){this.Ti[t]&&this.Ti[t].Rt(),this.Ti[t]=this.zi.Et()}Us(t,s,i){return t==k.Tt?{dx:T.di.Zt.Wt,dy:-.15,textLength:T.di.Zt.Xt,lengthAdjust:"spacingAndGlyphs","text-anchor":"start",transform:null,class:null}:{dx:null,dy:null,textLength:i?T.ui:null,lengthAdjust:i?"spacingAndGlyphs":null,"text-anchor":null,transform:null,class:null}}}class rt{constructor(t){this.hs=t,this.Vi=0,this.Ki=0,this.Zi=[]}pos(t,s){return(t=parseInt(t))<0||t>39||(s=parseInt(s))<0||s>24||(this.Vi=t,this.Ki=s),this}putG0(t,s){let i=null;if(void 0!==s){const t=parseInt(s);t>=0&&t<=15&&(i=t)}const e=t.charCodeAt(0);return e<32||e>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g0",Js:t,Oi:i}),this}putG1(t){const s=t.charCodeAt(0);return s<32||s>127||s>=64&&s<=95||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g1",Js:t}),this}putG2(t){const s=t.charCodeAt(0);return s<32||s>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g2",Js:t}),this}putG3(t){const s=t.charCodeAt(0);return s<32||s>127||this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"g3",Js:t}),this}putAt(){return this.Zi.push({Xi:this.Vi,Wi:this.Ki,vs:"char",Js:"@"}),this}end(){return this.hs.$i(this.Zi),this.hs.te(),this}}class ht extends T{}const ot=["SPLASH","ENGINEERING","ADVERT","UK"];class at{constructor(t,s){if(this.se=null,"object"==typeof window&&(this.se=window),this.ie={ee:!0},"object"==typeof s&&("webkitCompat"in s&&!s.webkitCompat&&(this.ie.ee=!1),"dom"in s&&(this.se=s.dom)),null==this.se)throw Error("TeletextController E24: No window dom object available");this.re=new nt(t,this.ie.ee,this.se),this.hs=t,this.ne=1,this.he=0,this._e(),this.oe=null,this.ae=null,this.le=0,this.Ae=0}setRowFromOutputLine(t,s){const i=l.st(s);this.hs.ce(t,i)}setRow(t,s){this.hs.ce(t,s)}setPageFromOutputLines(t,s){const i=l.it(t);void 0!==s&&(i[0]=this.ge(s)),this.setPageRows(i)}setPageRows(t){this.hs.ue(),this.hs.Ce(t)}ge(t){return(t=l.st(t)).join("").substring(0,32).padStart(40," ")}showTestPage(){this.loadPageFromEncodedString(A[ot[this.he]]),this.he++,4==this.he&&(this.he=0)}showRandomisedPage(){const t=[];for(let s=0;s<25;s++){const s=[];for(let t=0;t<40;t++)s.push(String.fromCharCode(127*Math.random()));t.push(s.join(""))}this.setPageRows(t)}loadPageFromEncodedString(t,s){const i=l.tt(t,this.se.atob);void 0!==s&&(i[0]=this.ge(s)),this.setPageRows(i)}_e(){this.se.addEventListener("ttx.reveal",(()=>this.re.Vs())),this.se.addEventListener("ttx.mix",(()=>this.re.Ws())),this.se.addEventListener("ttx.subtitlemode",(()=>this.re.ri()))}toggleReveal(){this.re.Vs()}toggleMixMode(){this.re.Ws()}toggleBoxMode(){this.re.ri()}toggleGrid(){this.re.Zs()}setLevel(t){this.hs.fe(t)}addTo(t){this.Ie=t,this.re.ut(t)}setFont(t){this.re.Ks(t)}clearScreen(t){this.hs.ue(),this.hs.Ee(t)}setAspectRatio(t){if("natural"==t)return void this.re.si(t);const s=parseFloat(t);if(Number.isNaN(s))throw Error("E80 setAspectRatio: bad number");this.re.si(s)}setHeight(t){const s=parseFloat(t);if(Number.isNaN(s))throw Error("E98 setHeight: bad number");this.re.ii(s),this.ae=s}setDefaultG0Charset(t,s){if(null==t.match(/g0_/))throw Error("E130 setDefaultG0Charset: Bad g0 set");this.hs.Be(t,s)}setSecondG0Charset(t,s){if(null==t.match(/g0_/))throw Error("E136 setSecondG0Charset: Bad g0 set");this.hs.de(t,s)}setG2Charset(t,s){if(null==t.match(/g2_/))throw Error("E142 setG2Charset: Bad g2 set");this.hs.Qe(t,s)}remove(){if(this.re.fs(),this.Ie){const t=document.querySelector(this.Ie);t&&t.removeChild(t.firstChild)}this.re=null}setView(t){switch(this.remove(),t){case"classic__font-for-mosaic":this.re=new ht(this.hs,this.se);break;case"classic__graphic-for-mosaic":this.re=new nt(this.hs,this.ie.ee,this.se);break;default:throw Error("setView E126: bad view name:"+t)}this.ae&&this.re.ii(this.ae),this.Ie&&this.re.ut(this.Ie),this.hs.te()}registerViewPlugin(t){t.registerWithView(this.re),this.hs.te()}enhance(){return new rt(this.hs)}}class ct{constructor(t){this.ye=t,this.be=[]}os(t){return this.be.push(t),this.be.length-1}te(t){this.be.forEach((s=>null!=s&&s(this.ye,t)))}fs(t){this.be[t]=null}}class lt{constructor(){this.pe=!1,this.me=[]}get Ns(){return this.pe}set Ns(t){this.pe=t}we(t){this.me.push(t)}ps(t){if(t>=this.me.length)throw Error("RowModel.getCell E20 bad cell index");return this.me[t]}}const gt=[H[1.5],H[2.5]],At=new class{constructor(){this.Se=[];for(let t=0;t<25;t++){const t=[];for(let s=0;s<40;s++)t.push(new st);this.Se.push(t)}this.xe="g0_latin",this.Ue=null,this.ve="g2_latin",this.ke=N.charFromAttribute(N.START_BOX),this.Re=H[1],this.Fe=[],this.ls=new ct(this)}te(){this.ls.te()}ce(t,s){if(t>=25)throw Error("PageModel E29 bad row number");this.Le(t,s),this.ls.te()}Ce(t){(t=t.slice(0,25)).forEach(((t,s)=>{this.Le(s,t)})),this.ls.te()}Le(t,s){let i=[...s];if(i=i.slice(0,40),i.forEach(((s,i)=>{const e=s.charCodeAt(0);if(Number.isNaN(e)||e>127)throw Error(`PageModel E51 failed to write row: bad character code (${e}) at row ${t} col ${i}`);this.Se[t][i].Di=s})),i.length<40)for(let s=i.length;s<40;s++)this.Se[t][s].Di=" "}fe(t){this.Re=t,this.ls.te()}Ee(t){if(void 0===t||t){const t=[];for(let s=0;s<25;s++)t.push("");this.Ce(t)}else for(let t=0;t<25;t++)this.Le(t,"")}Be(t,s){this.xe=t;const i=t.match(/^g0_([a-z]+)/);if(null!=i){const t="g2_"+i[1];t in W?this.ve=t:"hebrew"==i[1]&&(this.ve="g2_arabic")}s&&this.ls.te()}de(t,s){this.Ue=t,s&&this.ls.te()}Qe(t,s){this.ve=t,s&&this.ls.te()}ds(t){if(t>=25)throw Error("PageModel.getRow E42 bad rowNum");const s=new lt;let i,e,n=k.Pt,r=x.WHITE,h=!1,o=U.zt,a=!1,c=!1,l=!1,g=!1,A=x.BLACK,_=k.Mt,u={Hi:!1,Js:" ",vs:k.Mt},E=[];return gt.includes(this.Re)&&(E=this.Fe.filter((s=>s.Wi==t))),this.Se[t].forEach(((C,I)=>{const f=C.Di,B=((t,s)=>{let i=null,e=null;return s in F&&M[this.Re].includes(s.charCodeAt(0))?s in R?(i=N.TEXT_COLOUR,e=F[s]):s in j?(i=N.MOSAIC_COLOUR,e=F[s]):i=F[s]:s.charCodeAt(0)<=31&&(i=N.Kt),{De:i,Ne:e}})(0,f);switch(i=r,C.vs=n,C.Rs=g,e=a,B.De!=N.STEADY&&(C.Ds=h),B.De!=N.NORMAL_SIZE&&(C.ft=o),B.De!=N.CONCEAL&&(C.Ys=c),l&&(B.De!=N.HOLD_MOSAICS&&(u.Hi=!1,u.Js=" "),l=!1),B.De){case N.TEXT_COLOUR:n=k.Pt,r=B.Ne,c=!1,C.Gi(u);break;case N.MOSAIC_COLOUR:n=_,r=B.Ne,c=!1,C.Gi(u);break;case N.NEW_BACKGROUND:A=i,C.Gi(u);break;case N.BLACK_BACKGROUND:A=x.BLACK,C.Gi(u);break;case N.CONTIGUOUS_GRAPHICS:_=k.Mt,C.vs==k.qt&&(C.vs=k.Mt),n==k.qt&&(n=k.Mt),C.Gi(u);break;case N.SEPARATED_GRAPHICS:_=k.qt,C.vs==k.Mt&&(C.vs=k.qt),n==k.Mt&&(n=k.qt),C.Gi(u);break;case N.ESC:this.Ue&&(a=!e),C.Gi(u);break;case N.FLASH:h=!0,C.Gi(u);break;case N.STEADY:C.Ds=!1,h=!1,C.Gi(u);break;case N.NORMAL_SIZE:C.ft=U.zt,o=U.zt,C.Gi(u);break;case N.DOUBLE_HEIGHT:o=U.Jt,s.Ns=!0,C.Gi(u);break;case N.DOUBLE_WIDTH:o=U.Yt,C.Gi(u);break;case N.DOUBLE_SIZE:o=U.Vt,s.Ns=!0,C.Gi(u);break;case N.CONCEAL:C.Ys=!0,c=!0,C.Gi(u);break;case N.HOLD_MOSAICS:u.Hi=!0,C.Gi(u);break;case N.RELEASE_MOSAICS:l=!0,C.Gi(u);break;case N.START_BOX:I>=1&&this.Se[t][I-1].Di==this.ke&&(C.Rs=!0,g=!0),C.Gi(u);break;case N.END_BOX:g=!1,C.Gi(u);break;case N.Kt:C.Gi(u);break;default:C.Ni(e?this.Ue:this.xe),C.ji()&&(u.Js=f,u.vs=C.vs)}C.xs=i,C.ws=A,E.filter((t=>t.Xi==I)).forEach((t=>{const s=new it(C);C=s,"g0"==t.vs?(C.Di=t.Js,C.Oi=t.Oi,C.vs=k.Pt,C.Ni(e?this.Ue:this.xe)):"g1"==t.vs?this.Re==H[2.5]&&(C.Di=t.Js,C.vs=_,C.Ni()):"g2"==t.vs?(C.Di=t.Js,C.vs=k.Pt,C.Ni(this.ve)):"g3"==t.vs?(this.Re!=H[1.5]||-1!="Q[\\]".indexOf(t.Js))&&(C.Di=t.Js,C.vs=k.Tt,C.Ni()):"char"==t.vs&&(C.Pi=t.Js,C.vs=k.Pt)})),s.we(C)})),s}$i(t){this.Fe=t}ue(){this.Fe=[]}};class _t{constructor(){this.Oe=null,this.je=null}async fetchPage(t){const s=t.match(/([1-8])[0-9A-Fa-f]{2}/);if(null==s)return null;const i=s[1];if(this.Oe!=i)try{const t=await fetch(i+".json");if(t.ok){const s=await t.json();"pages"in s&&(this.je=s,this.Oe=i)}}catch(t){}return this.Oe==i&&t in this.je.pages?this.je.pages[t]:null}}const ut=["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],Et=["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"];class Ct{constructor(t){this.Ge=t}Pe(){const t=new Date;return{"%%a":ut[t.getDay()],"%%b":Et[t.getMonth()],"%d":(t.getDate()+"").padStart(2,0),"%e":(t.getDate()+"").padStart(2," "),"%m":(t.getMonth()+1+"").padStart(2," "),"%y":(t.getFullYear()+"").substring(2,2),"%H":(t.getHours()+"").padStart(2,0),"%M":(t.getMinutes()+"").padStart(2,0),"%S":(t.getSeconds()+"").padStart(2,0)}}He(t){const s=this.Pe();let i=this.Ge;for(const t of Object.keys(s))i=i.replace(t,s[t]);return void 0!==t&&(i=i.replace("%%#",t)),i}}class It{constructor(t){if("object"!=typeof t)throw Error("E8 Service.constructor: options object required");if(!("DOMSelector"in t))throw Error("E9 Service.constructor DOMSelector property required");this.Me="caster"in t?t.caster:null,this.qe="defaultG0Charset"in t?t.defaultG0Charset:"g0_latin",this.Te=new Ct("header"in t?t.header:" %%# %%a %e %%b C%H:%M/%S"),this.Xe="fetcher"in t?t.fetcher:new _t,this.Je=new at(At,void 0),this.Je.setDefaultG0Charset(this.qe),this.Je.setLevel(H[1.5]),this.Je.addTo(t.DOMSelector),this.ze=null,this.Ye=null,this.Ve=0,this.Ze=null}get teletextInstance(){return this.Je}async showPage(t){if("number"==typeof t&&(t+=""),null==t.match(/^[1-8][0-9A-Fa-f]{2}$/))return null;const s=await this.Xe.fetchPage(t);if(null!=s){const i=this.Ke(s);if(null!=i)return this.ze=s,this.Ye=t,this.Ve=i,this.We(),this.$e()}return null}showLink(t){return null!=this.Ze&&t in this.Ze?this.showPage(this.Ze[t]):Promise.resolve(null)}Ke(t){const s=t.subpages;for(let t=0;t<s.length;t++)if(null!=s[t])return t;return null}nextSubPage(){const t=this.ze.subpages;let s=this.Ve,i=!1;for(;!i&&(s++,s==t.length&&(s=0),s!=this.Ve);)null!=t[s]&&(i=!0);return i&&(this.Ve=s,this.We()),this.$e()}previousSubPage(){const t=this.ze.subpages;let s=this.Ve,i=!1;for(;!i&&(s--,-1==s&&(s=t.length-1),s!=this.Ve);)null!=t[s]&&(i=!0);return i&&(this.Ve=s,this.We()),this.$e()}$e(){return{pageNumber:this.Ye,subPage:this.Ve,numSubPages:this.ze.subpages.filter((t=>null!=t)).length,fastext:this.Ze}}We(){const t=this.ze.subpages[this.Ve],s="encoding"in t?t.encoding:this.qe,i=this.Te.He(this.Ye);let e={defaultG0Charset:s,header:i};if(this.Je.clearScreen(!1),this.Je.setDefaultG0Charset(s,!1),"ouputLines"in t){const s=t.outputLines.split("\n");this.Je.setPageFromOutputLines(s,i),e.outputLines=s}else if("packed"in t){const s=t.packed;this.Je.loadPageFromEncodedString(s,i),e.packed=s}else e=null;e&&this.Me&&this.Me.display(e),this.Ze="fastext"in t?t.fastext:null}}class ft{constructor(t){this.t=t,this.i=[]}attach(t){this.i.push(t)}notify(t){this.i.forEach(((s,i)=>this.i[i](this.t,t)))}}const Bt=new class{constructor(){this.available=new ft(this),this.castStateChanged=new ft(this)}o(){if("undefined"==typeof cast)return;const t={receiverApplicationId:"000F65B3",autoJoinPolicy:chrome.cast.AutoJoinPolicy.ORIGIN_SCOPED};this.h=cast.framework.CastContext.getInstance(),this.h.setOptions(t),this.l=new cast.framework.RemotePlayer,this.u=new cast.framework.RemotePlayerController(this.l),this.h.addEventListener(cast.framework.CastContextEventType.CAST_STATE_CHANGED,(()=>this.castStateChanged.notify())),this.available.notify(),this.castStateChanged.notify()}async display(t){if(!this.m())return;const s=this.g();this.u.stop();const i=new chrome.cast.media.MediaInfo("https://teletextforchromecast.tech-and-software.ltd.uk/250-milliseconds-of-silence.mp3","audio/mpeg3");i.entity=t;const e=new chrome.cast.media.LoadRequest(i);try{await s.loadMedia(e)}catch(t){}}getCastState(){return this.h.getCastState()}clearScreen(){this.p("clear")}toggleGrid(){this.p("grid")}toggleReveal(){this.p("reveal")}toggleMixMode(){this.p("mix")}toggleBoxMode(){this.p("box")}setSmoothMosaics(){this.p("smoothmosaic")}setBlockMosaics(){this.p("blockmosaic")}async p(t){if(!this.m())return;const s=this.g();try{await s.sendMessage("urn:x-cast:uk.ltd.techandsoftware.teletext",`"${t}"`)}catch(t){}}m(){return"object"==typeof this.l&&this.l.isConnected}g(){return this.h.getCurrentSession()}};let Qt=0;function dt(){window.setTimeout((()=>{"undefined"==typeof cast?(Qt++,Qt<10&&dt()):Bt.o()}),500)}window.__onGCastApiAvailable=t=>{t&&("undefined"==typeof cast?dt():Bt.o())};const bt=["sans-serif","Bedstead","native","serif","Unscii","monospace","cursive"],yt=["classic__graphic-for-mosaic","classic__font-for-mosaic"];class mt{constructor(t){const s={defaultG0Charset:"g0_latin__english",header:"FAXFAX %%# %%a %e %%b C%H:%M/%S",caster:Bt,DOMSelector:"#teletextscreen"};let i="",e=!1;if("object"==typeof t){for(const i of["defaultG0Charset","header","DOMSelector"])i in t&&(s[i]=t[i]);"frontPage"in t&&("number"==typeof t.frontPage?i=t.frontPage+"":"string"==typeof t.frontPage&&(i=t.frontPage)),"smoothMosaics"in t&&t.smoothMosaics&&(e=!0)}""==i&&(i="100"),this.tn=new It(s),this.Ye=3==i.length?i:"XXX",this.sn=0,this.en=0,Bt.available.attach((()=>this.nn.call(this))),Bt.castStateChanged.attach((()=>this.rn.call(this))),this.hn(),e&&this.on(),this.an()}rn(){const t=Bt.getCastState(),s=document.querySelector("#castOuter");switch(t){case"NO_DEVICES_AVAILABLE":s.title="Cast to Chromecast - no devices available",s.style.cursor="default";break;case"NOT_CONNECTED":s.title="Cast to Chromecast",s.style.cursor="pointer";break;case"CONNECTING":break;case"CONNECTED":this.an(),this.cn&&Bt.setSmoothMosaics()}}nn(){document.querySelector("#castOuter").style.display="inline-block"}hn(){window.addEventListener("keydown",(t=>wt.call(this,t))),window.addEventListener("DOMContentLoaded",(()=>{document.querySelector("#revealButton").addEventListener("click",(()=>this.ln())),document.querySelector("#mixButton").addEventListener("click",(()=>this.gn()));for(const t of["red","green","yellow","blue","index"])document.querySelector("#"+t).addEventListener("click",(()=>this.An(t)));document.querySelectorAll("[data-num]").forEach((t=>t.addEventListener("click",(()=>this._n(t.dataset.num))))),document.querySelector("#left").addEventListener("click",(()=>this.un())),document.querySelector("#right").addEventListener("click",(()=>this.En())),document.querySelector("#helpicon").addEventListener("click",(()=>this.Cn()))}))}ln(){window.dispatchEvent(new Event("ttx.reveal")),Bt.toggleReveal()}gn(){window.dispatchEvent(new Event("ttx.mix")),Bt.toggleMixMode()}_n(t){this.Ye=3==(this.Ye+"").length?t:this.Ye+""+t,this.In(),3==(this.Ye+"").length&&this.an()}In(){document.querySelector("#pageNumber").innerHTML=this.Ye}fn(){this.Ye="XXX",document.querySelector("#pageNumber").innerHTML="- - -",document.querySelector("#subpage").style.visibility="hidden"}async an(){if(null!=this.Ye.match(/[1-8][0-9A-Fa-f]{2}/)){const t=await this.tn.showPage(this.Ye);this.We(t)}}En(){const t=this.tn.nextSubPage();this.We(t)}un(){const t=this.tn.previousSubPage();this.We(t)}We(t){null!=t&&(this.Ye=t.pageNumber,this.In(),this.Bn(t),this.Qn(t),this.dn())}dn(){document.activeElement.disabled&&document.activeElement.blur()}Bn(t){const s=document.querySelector("#subpage");null!=t&&t.numSubPages>1?(s.innerHTML=`${t.subPage} of ${t.numSubPages}`,s.style.visibility="visible",document.querySelectorAll("#lrnav button").forEach((t=>t.disabled=!1))):(s.style.visibility="hidden",document.querySelectorAll("#lrnav button").forEach((t=>t.disabled=!0)))}Qn(t){const s=null!=t?t.fastext:{};for(const t of["red","green","yellow","blue","index"]){let i=!0;null!=s&&t in s&&(i=!1),document.querySelector("#"+t).disabled=i}}async An(t){const s=await this.tn.showLink(t);this.We(s)}bn(){for(const t of["red","green","yellow","blue","index","left","right"])document.querySelector("#"+t).disabled=!0}Cn(){this.fn(),this.bn();const t=this.tn.teletextInstance;t.setDefaultG0Charset("g0_latin__english",!1),t.loadPageFromEncodedString("OoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA6RQIECBAgQYOHDhw4cOHDhw4cOHDhw4cOHBAgQIECBAgQIDo0igQIECBBqAy8vnFvw8siDHv3dOW_ZzI_2qBAgQIECBAgQIECBAgQIEHdAgQIECBAgQIECDjz9IECBAgQIECBAgQIECA6RQIECBAgQIl69evXr169evXr169evXr169KgQIECBAgQIDqBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOhECCTmQed_VBow9sqDCg15fOLfh5ZFiDrzyoOmjKgQIECA6EQIN3Xbiy8kGvL55oMO7Ig6aMqDXl880GLLs390CBAgQIDoFAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOlNSNGjRo0aNGjRo0aNGjRo0aNGjRo0aNGjRo0aNGjR_2iA6U1BECBA_QIECCll7ZcOxAgQIECBAgQIECBAUQIECBB_aoDpTUEQIEG1AgQIJunwgQIECBAgQIECBAgQIEBRAgQIEH9qgOlNQRAgQW0CBAgocsvbTv680HPri4Yc-VAgQFECBAgQf2qA6U1BECBBdQIECCdl8dEHPri4Yc-VAgQIECAogQIECBB_aoDpTUE5L86_yvxIIe_Zv68kGLr06b93NAgQIEBRAgQIEH9qgOlNQRAgQaUCBAgk7smXwgxdenTfuQIECBAgQFECBAgQf2qA6U1BECBB0QIECCpl5ctObTjQZ-WHho04-aDfuX782Yp_aoDpTUEQIEGZAgQII2_d0Qc--npj0IECBAgQIEBRAgQIEH9qgOlNQRAgQekCBAgtZdyDbvyZUG_cv35syBAgQFECBAgQf2qA6U1IECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBB_aoDpREvXr169evXr169evXr169evXr169evXr169evXr169KgOoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA6gQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIDqBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgOoECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECBAgQIECA")}yn(){const t=Math.floor(360*Math.random()),s=Math.floor(360*Math.random());document.body.style.background=`linear-gradient(${s}deg, hsl(${t} 100% 7%) 0%, hsl(${t} 83% 52%) 86%, hsl(${t} 100% 85%) 100%)`}async on(){if(this.cn)this.tn.teletextInstance.setView(yt[this.en]),this.cn=!1,Bt.setBlockMosaics();else if(0==this.en)try{const t=await import("https://cdn.jsdelivr.net/npm/@techandsoftware/teletext-plugin-smooth-mosaic@latest/dist/teletext-plugin-smooth-mosaic.min.js");this.tn.teletextInstance.registerViewPlugin(t.SmoothMosaicPlugin),this.cn=!0,Bt.setSmoothMosaics()}catch(t){}}mn(){document.body.classList.toggle("zen")}}function wt(t){if(!(t.altKey||t.metaKey||t.ctrlKey))switch(t.key){case"1":case"2":case"3":case"4":case"5":case"6":case"7":case"8":case"9":case"0":document.querySelector("#b"+t.key).focus({preventScroll:!0}),this._n(t.key);break;case"?":this.ln();break;case"m":this.gn();break;case"f":this.sn++,this.sn==bt.length&&(this.sn=0),this.tn.teletextInstance.setFont(bt[this.sn]);break;case"w":this.tn.teletextInstance.clearScreen();break;case"h":this.Cn();break;case"v":this.en++,this.en==yt.length&&(this.en=0),this.tn.teletextInstance.setView(yt[this.en]),this.cn=!1;break;case"t":this.on();break;case"r":this.An("red");break;case"g":this.An("green");break;case"y":this.An("yellow");break;case"b":this.An("blue");break;case"i":this.An("index");break;case"=":case"+":case">":case"ArrowRight":this.En();break;case"-":case"<":case"ArrowLeft":this.un();break;case"c":this.yn();break;case"z":this.mn()}}export{It as TeletextService,mt as TeletextServiceViewer};//# sourceMappingURL=teletext-service.min.js.map

@@ -10,11 +10,11 @@ <!-- SPDX-FileCopyrightText: © 2021 Tech and Software Ltd. -->

See https://teletext-service.netlify.app/
See https://teletextmoduledemo.tech-and-software.ltd.uk/teletext-service-demo.html
# Usage
`TeletextService` handles page retrieval and display. `TeletextServiceViewer` is higher level with support for page numbers, subpages and fastext (coloured button links).
The `TeletextService` class handles page retrieval and display. The `TeletextServiceViewer` class is higher level with support for page numbers, subpages and fastext (coloured button links), and is tightly coupled to the provided HTML UI.
## TeletextService module
## TeletextService class
Minimum code needed to use the `TeletextService` module:
Minimum code needed to use the `TeletextService` class:

@@ -37,7 +37,9 @@ ```html

You will need to supply your own page number entry method.
The JSON structure needed is described below.
## TeletextServiceViewer module
## TeletextServiceViewer class
`TeletextServiceViewer` is a web app wrapper around `TeletextService`. It handles page number entry, subpage nav, fastext button state changes and entry, reveal and mix, with control using the webapp UI or keyboard shortcuts. It's tightly-coupled to the HTML so it's not really an API but it does support some options. It's most likely you'll use the code as it is or fork it. The module also incorporates [teletext-caster](https://www.npmjs.com/package/@techandsoftware/teletext-caster) so that pages can be viewed on a Chromecast in supporting browsers.
`TeletextServiceViewer` is a web app wrapper around `TeletextService`. It handles page number entry, subpage nav, fastext button state changes and entry, reveal and mix, with control using the webapp UI or keyboard shortcuts. It's tightly-coupled to the HTML so it's not really an API but it does support some options. It's most likely you'll use the code as it is or fork it. The class also incorporates [teletext-caster](https://www.npmjs.com/package/@techandsoftware/teletext-caster) so that pages can be viewed on a Chromecast in supporting browsers.

@@ -54,5 +56,5 @@ The Javascript code is invoked with:

For the rest of HTML needed, see `public/viewer.html` in the repo.
For the rest of HTML needed, see `public/index.html` in the repo.
To run locally, clone the project then run `npm install` and `npm start` .
To run locally, clone the project then run `npm install` and `npm run dev` .

@@ -84,3 +86,3 @@ Use `scripts/tti2json.js` to generate the JSON files needed as the page data source, or create your own. The JSON structure needed is documented below in the 'Default page data source' section.

The core project is licensed under GNU Affero General Public License 3 ([AGPL-3.0-only](https://www.gnu.org/licenses/agpl-3.0.en.html)), or under a commercial software license ([LicenseRef-uk.ltd.TechAndSoftware-1.0](https://techandsoftware.robdev.org.uk/LICENSES/LicenseRef-uk.ltd.TechAndSoftware-1.0.txt)) if you have paid a licensing fee to Tech and Software Ltd. If you combine your own software with this package and distribute publically (whether via network access or not), the AGPL requires that your software is covered by AGPL; the commercial license does not have that requirement. In order to pay the fee for the commercial license, contact <techandsoftwareltd@outlook.com> for enquiries. The text of the licenses is in the `LICENSES` directory.
The core project is licensed under GNU Affero General Public License 3 ([AGPL-3.0-only](https://www.gnu.org/licenses/agpl-3.0.en.html)), or under a commercial software license ([LicenseRef-uk.ltd.TechAndSoftware-1.0](https://tech-and-software.ltd.uk/LICENSES/LicenseRef-uk.ltd.TechAndSoftware-1.0.txt)) if you have paid a licensing fee to Tech and Software Ltd. If you combine your own software with this package and distribute publically (whether via network access or not), the AGPL requires that your software is covered by AGPL; the commercial license does not have that requirement. In order to pay the fee for the commercial license, contact <techandsoftwareltd@outlook.com> for enquiries. The text of the licenses is in the `LICENSES` directory.

@@ -202,3 +204,3 @@ Dependencies:

* `frontPage` is the front page number, which will be shown automatically. Defaults to page 100. Pass in null to not show the front page automatically
* `smoothMosaics` - if true will use a pixel-art scaling algorithm to generate smoother mosaic graphics when the service starts
* `smoothMosaics` - if true will use a pixel-art scaling algorithm to generate smoother mosaic graphics when the service starts. Default is false

@@ -289,3 +291,3 @@ # Default page data source

String. The contents is a base64-encoded string of 7-bit characters for the 25 rows x 40 characters concatenated together. The encoded string uses the character repertoire defined in the [base64url encoding](https://tools.ietf.org/html/rfc4648#section-5). This format is taken from the edit.tf editor URL hash segment - see further details here: https://github.com/rawles/edit.tf
String. The contents is a base64-encoded string of 7-bit characters for the 25 rows x 40 characters concatenated together. The encoded string uses the character repertoire defined in the [base64url encoding](https://tools.ietf.org/html/rfc4648#section-5). This format is taken from the edit.tf editor URL hash fragment - see further details here: https://github.com/rawles/edit.tf

@@ -292,0 +294,0 @@ An example is in `public/1.json`, or see the URL hash at https://edit.tf (the part after the colon)

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc