From 61f90eb1a52e60444b232542dfe66366bb0864e6 Mon Sep 17 00:00:00 2001 From: SRNV Date: Sat, 6 Feb 2021 22:10:27 +0100 Subject: [PATCH 001/143] update readme and egg --- README.md | 2 +- egg.yml | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 8e99ef59..ef68fac1 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@

- +

Ogone

diff --git a/egg.yml b/egg.yml index 2bc6bc4e..b74f209d 100644 --- a/egg.yml +++ b/egg.yml @@ -2,10 +2,11 @@ name: Ogone repository: https://github.com/SRNV/Ogone version: 0.28.0 description: >- - Web-Components compiler to create front-end modern Apps (SPA, PWA) + Advanced Web Composition for Future stable: true files: - ./docs/**/* + - ./deps/**/* - ./classes/**/* - ./enums/**/* - ./workers/**/* From 1344948984e927a8f1cccf48c8a2b5eaaaf70f1e Mon Sep 17 00:00:00 2001 From: Rudy Alula <37340675+SRNV@users.noreply.github.com> Date: Sat, 6 Feb 2021 22:53:25 +0100 Subject: [PATCH 002/143] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 8e99ef59..60102ad7 100644 --- a/README.md +++ b/README.md @@ -23,7 +23,7 @@ license - deno version + deno version denoland From ebc599aacbdf7fa34ff177e7868de3e8cd7fd0da Mon Sep 17 00:00:00 2001 From: SRNV Date: Sun, 7 Feb 2021 00:35:21 +0100 Subject: [PATCH 003/143] prepare fixes --- .gitignore | 1 - README.md | 2 +- egg.yml | 27 +++++++++++---------------- 3 files changed, 12 insertions(+), 18 deletions(-) diff --git a/.gitignore b/.gitignore index e0a50c97..5ecbbeea 100644 --- a/.gitignore +++ b/.gitignore @@ -1,5 +1,4 @@ .deno_plugins/ -dist/ .github/ null/ .susano/ \ No newline at end of file diff --git a/README.md b/README.md index ef68fac1..8797f392 100644 --- a/README.md +++ b/README.md @@ -1,6 +1,6 @@

- +

Ogone

diff --git a/egg.yml b/egg.yml index b74f209d..9e661b38 100644 --- a/egg.yml +++ b/egg.yml @@ -1,26 +1,21 @@ name: Ogone -repository: https://github.com/SRNV/Ogone -version: 0.28.0 -description: >- - Advanced Web Composition for Future -stable: true +repository: 'https://github.com/SRNV/Ogone' +version: 0.28.1 +description: Advanced Web Composition for Future +stable: false files: + - ./cli/**/* - ./docs/**/* - ./deps/**/* - - ./classes/**/* - - ./enums/**/* - - ./workers/**/* - ./examples/**/* - - ./lib/**/* - - ./public/**/* - ./src/**/* - ./tests/**/* - - ./types/**/* - ./utils/**/* - - ./externals/**/* - - .d.ts - - deps.ts - mod.ts - README.md - - tsconfig.json - - yaml-config.ts + - LICENSE +check: false +entry: ./mod.ts +homepage: 'https://github.com/SRNV/Ogone' +ignore: [] +unlisted: false From 557f8c1b3db8dc43470ef44b8ae7e716f89039cc Mon Sep 17 00:00:00 2001 From: SRNV Date: Sun, 7 Feb 2021 00:40:00 +0100 Subject: [PATCH 004/143] fix missing folder --- mod.ts | 2 ++ src/classes/TSXContextCreator.ts | 7 ++++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/mod.ts b/mod.ts index ad3d275c..45b83979 100644 --- a/mod.ts +++ b/mod.ts @@ -18,6 +18,7 @@ import DefinitionProvider from './src/classes/DefinitionProvider.ts'; import { MapPosition } from './src/classes/MapPosition.ts'; import StylesheetBuilder from './src/classes/StylesheetBuilder.ts'; import { Utils } from './src/classes/Utils.ts'; +import TSXContextCreator from './src/classes/TSXContextCreator.ts'; export { Ogone, @@ -40,6 +41,7 @@ export { }; export default { async run(opts: OgoneConfiguration): Promise { + TSXContextCreator.createDistFolder(); Configuration.setConfig(opts); const env = new EnvServer(); await env.run(opts); diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 55bfb447..42113f4a 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -1,5 +1,5 @@ import { Bundle, Component } from '../ogone.main.d.ts'; -import { colors, join } from '../../deps/deps.ts'; +import { colors, existsSync, } from '../../deps/deps.ts'; import { walkSync } from '../../deps/walk.ts'; import { ModuleErrors } from './ModuleErrors.ts'; import { Utils } from "./Utils.ts"; @@ -52,6 +52,11 @@ export default class TSXContextCreator extends Utils { ${err.stack}`); } } + public static createDistFolder() { + if(!existsSync(this.subdistFolderURL.pathname)) { + Deno.mkdir(this.subdistFolderURL); + } + } private static async cleanFiles() { TSXContextCreator.mapCreatedFiles.forEach((file) => { Deno.removeSync(file); From 3b826495998110011b0cb30f681756b5badf016c Mon Sep 17 00:00:00 2001 From: SRNV Date: Sun, 7 Feb 2021 08:32:12 +0100 Subject: [PATCH 005/143] fix make dir sync --- src/classes/TSXContextCreator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 42113f4a..2a5fff22 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -54,7 +54,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdir(this.subdistFolderURL); + Deno.mkdirSync(this.subdistFolderURL); } } private static async cleanFiles() { From 6a7fd81e84c929d3059277a4595b89eac3e00512 Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 10:28:02 +0100 Subject: [PATCH 006/143] fix must be a file URL --- egg.yml | 2 +- src/classes/TSXContextCreator.ts | 2 +- src/main/dist/data-2062272402.tsx | 75 +++++++++++++++++ src/main/dist/data-2276051861.tsx | 81 ++++++++++++++++++ src/main/dist/data-2519344230.tsx | 64 ++++++++++++++ src/main/dist/data-2532431870.tsx | 134 ++++++++++++++++++++++++++++++ src/main/dist/data-2905075436.tsx | 122 +++++++++++++++++++++++++++ src/main/dist/data-3337162496.tsx | 52 ++++++++++++ src/main/dist/tsx_context.ts | 25 ++++++ 9 files changed, 555 insertions(+), 2 deletions(-) create mode 100644 src/main/dist/data-2062272402.tsx create mode 100644 src/main/dist/data-2276051861.tsx create mode 100644 src/main/dist/data-2519344230.tsx create mode 100644 src/main/dist/data-2532431870.tsx create mode 100644 src/main/dist/data-2905075436.tsx create mode 100644 src/main/dist/data-3337162496.tsx create mode 100644 src/main/dist/tsx_context.ts diff --git a/egg.yml b/egg.yml index 9e661b38..08ac13fb 100644 --- a/egg.yml +++ b/egg.yml @@ -1,6 +1,6 @@ name: Ogone repository: 'https://github.com/SRNV/Ogone' -version: 0.28.1 +version: 0.28.2 description: Advanced Web Composition for Future stable: false files: diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 2a5fff22..56b7a6ef 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -54,7 +54,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdirSync(this.subdistFolderURL); + Deno.mkdirSync(this.subdistFolderURL.pathname); } } private static async cleanFiles() { diff --git a/src/main/dist/data-2062272402.tsx b/src/main/dist/data-2062272402.tsx new file mode 100644 index 00000000..2ff77659 --- /dev/null +++ b/src/main/dist/data-2062272402.tsx @@ -0,0 +1,75 @@ + + export default {}; + + + class Protocol { + buttonOpts: { + name: string; + route: string; + status: 'ok' | 'todo' | 'in-progress'; + } = { + name: 'Test', + route: '', + status: 'todo' + }; + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + class Component extends Protocol { + render() { + return ( +); + } + runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + + + switch(_state) { + +default: + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/components/menu/MenuButton.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/data-2276051861.tsx b/src/main/dist/data-2276051861.tsx new file mode 100644 index 00000000..913e3d0b --- /dev/null +++ b/src/main/dist/data-2276051861.tsx @@ -0,0 +1,81 @@ + + export default {}; + + +declare abstract class Store {public static dispatch(ns: string, ctx?: any): any} + class Protocol { + public isOpen: boolean = false; + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + declare function StoreMenu (props: OgoneSTOREComponent<{ + + }>): h.JSX.IntrinsicElements; + class Component extends Protocol { + render() { + return ( +); + } + runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + + + // @ts-ignore + if (typeof _state === "string" && !['click:openMenu'].includes(_state)) { + return; + } + switch(_state) { +case 'click:openMenu': + Store.dispatch('menu/toggle') + Store.dispatch('menu/checkController') + .then((res: any) => { + console.warn(res); + }); + break; + +default: + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/components/Burger.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/data-2519344230.tsx b/src/main/dist/data-2519344230.tsx new file mode 100644 index 00000000..aa9adbe6 --- /dev/null +++ b/src/main/dist/data-2519344230.tsx @@ -0,0 +1,64 @@ + + export default {}; + + + declare const Controllers: { [k: string]: Controller; }; + declare interface Controller { + get(rte: string): Promise; + post(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; + put(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; + patch(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; + delete(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; + }; + + class Protocol { + public isOpen: boolean = false; + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + class Component extends Protocol { + render() { + return ; + } + async runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + const { UserController } = Controllers; + + + // @ts-ignore + if (typeof _state === "string" && !['action:toggle','action:checkController'].includes(_state)) { + return; + } + switch(_state) { +case 'action:toggle': + this.isOpen = !this.isOpen; + break; +case 'action:checkController': + const res = await UserController.get('/'); + return res; + +default: + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/stores/StoreMenu.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/data-2532431870.tsx b/src/main/dist/data-2532431870.tsx new file mode 100644 index 00000000..49072c20 --- /dev/null +++ b/src/main/dist/data-2532431870.tsx @@ -0,0 +1,134 @@ + + export default {}; + + + + class Protocol { + public openTree: boolean = false; + public item: { + route: string; + status?: string; + name?: string; + children: ({ + status?: string; + name: string; + route: string; + children: any[] + })[]; + } = { name: 'no name', route: '', status: 'todo', children: []}; + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + declare function ScrollComponent (props: OgoneCOMPONENTComponent<{ + + }>): h.JSX.IntrinsicElements; + + declare function TreeRecursive (props: OgoneCOMPONENTComponent<{ + +item: { + route: string; + status?: string; + name?: string; + children: ({ + status?: string; + name: string; + route: string; + children: any[] + })[]; + } ; + }>): h.JSX.IntrinsicElements; + class Component extends Protocol { + render() { + return ( +); + } + runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + + + // @ts-ignore + if (typeof _state === "string" && !['click:toggle'].includes(_state)) { + return; + } + switch(_state) { +case 'click:toggle': + this.openTree = !this.openTree + break; + +default: + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/components/menu/TreeRecursiveButton.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/data-2905075436.tsx b/src/main/dist/data-2905075436.tsx new file mode 100644 index 00000000..b14751ed --- /dev/null +++ b/src/main/dist/data-2905075436.tsx @@ -0,0 +1,122 @@ + + export default {}; + + + + + + + declare const Refs: { + [k: string]: HTMLElement[]; + }; + class Protocol { + public scrollY: number = 0; + public setScrollY(n: number) { + this.scrollY = n; + } + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + declare function RightSection (props: OgoneCOMPONENTComponent<{ + +scrollY: unknown; + }>): h.JSX.IntrinsicElements; + + declare function AsyncLogoEl (props: OgoneASYNCComponent<{ + + }>): h.JSX.IntrinsicElements; + + declare function MenuContent (props: OgoneCOMPONENTComponent<{ + + }>): h.JSX.IntrinsicElements; + + declare function MenuMain (props: OgoneCOMPONENTComponent<{ + + }>): h.JSX.IntrinsicElements; + + declare function RouterComponent (props: OgoneROUTERComponent<{ + + }>): h.JSX.IntrinsicElements; + class Component extends Protocol { + render() { + return ( +); + } + runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + + + // @ts-ignore + if (typeof _state === "string" && ![].includes(_state)) { + return; + } + switch(_state) { + +default: + + const [header] = Refs.head; + window.addEventListener('scroll', (ev) => { + if (header) { + if (window.scrollY > this.scrollY) { + header.style.top = '-100px'; + } else { + header.style.top = '0px'; + } + } + this.setScrollY(window.scrollY); + }); + break; + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/Application.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/data-3337162496.tsx b/src/main/dist/data-3337162496.tsx new file mode 100644 index 00000000..daa79c3e --- /dev/null +++ b/src/main/dist/data-3337162496.tsx @@ -0,0 +1,52 @@ + + export default {}; + + + class Protocol { + public name: string = "SRNV"; + } + declare const Deno: any; + type OgoneCOMPONENTComponent = { children?: any; } & T; + type OgoneASYNCComponent = OgoneCOMPONENTComponent; + type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; + + declare function h(...args: unknown[]): unknown; + declare function hf(...args: unknown[]): unknown; + declare namespace h.JSX { + export interface IntrinsicElements { + [k: string]: any; + } + } + + class Component extends Protocol { + render() { + return ; + } + async runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { + try { + + + + + // @ts-ignore + if (typeof _state === "string" && !['GET:/','GET:/2'].includes(_state)) { + return; + } + switch(_state) { +case 'GET:/': + return `Hello ${this.name}`; +case 'GET:/2': + return '

test

'; + +default: + } + } catch(err) { + // @ts-ignore + displayError('Error in the component: \n\t examples/app/controllers/ControllerUser.o3' ,err.message, err); + throw err; + } + } + } + \ No newline at end of file diff --git a/src/main/dist/tsx_context.ts b/src/main/dist/tsx_context.ts new file mode 100644 index 00000000..381929f0 --- /dev/null +++ b/src/main/dist/tsx_context.ts @@ -0,0 +1,25 @@ + + /** + * Context of examples/app/Application.o3 + * */ + import comp0 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2905075436.tsx'; + /** + * Context of examples/app/components/Burger.o3 + * */ + import comp1 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2276051861.tsx'; + /** + * Context of examples/app/stores/StoreMenu.o3 + * */ + import comp2 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2519344230.tsx'; + /** + * Context of examples/app/controllers/ControllerUser.o3 + * */ + import comp3 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-3337162496.tsx'; + /** + * Context of examples/app/components/menu/MenuButton.o3 + * */ + import comp4 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2062272402.tsx'; + /** + * Context of examples/app/components/menu/TreeRecursiveButton.o3 + * */ + import comp5 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2532431870.tsx'; \ No newline at end of file From 09c143907d33a47a6f2d85377c1e7ca317a59e6b Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 10:41:59 +0100 Subject: [PATCH 007/143] fix dir not found --- egg.yml | 2 +- src/classes/TSXContextCreator.ts | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/egg.yml b/egg.yml index 08ac13fb..35c9a20c 100644 --- a/egg.yml +++ b/egg.yml @@ -1,6 +1,6 @@ name: Ogone repository: 'https://github.com/SRNV/Ogone' -version: 0.28.2 +version: 0.28.3 description: Advanced Web Composition for Future stable: false files: diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 56b7a6ef..d3557122 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -10,6 +10,7 @@ import { Utils } from "./Utils.ts"; let i = 0; export default class TSXContextCreator extends Utils { static subdistFolderURL = new URL('../main/dist/', import.meta.url); + static createsubdistFolderURL = new URL('../main/dist', import.meta.url); static globalAppContextURL = new URL('./tsx_context.ts', TSXContextCreator.subdistFolderURL); static globalAppContextFile: string = ''; static mapCreatedFiles: URL[] = []; @@ -54,7 +55,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdirSync(this.subdistFolderURL.pathname); + Deno.mkdirSync(this.createsubdistFolderURL.pathname); } } private static async cleanFiles() { From 35990ef0abac7c045046b6ebbbc37fe035dd3fcd Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 10:49:34 +0100 Subject: [PATCH 008/143] use recursive --- egg.yml | 2 +- src/classes/TSXContextCreator.ts | 2 +- src/main/dist/data-2062272402.tsx | 75 ----------------- src/main/dist/data-2276051861.tsx | 81 ------------------ src/main/dist/data-2519344230.tsx | 64 -------------- src/main/dist/data-2532431870.tsx | 134 ------------------------------ src/main/dist/data-2905075436.tsx | 122 --------------------------- src/main/dist/data-3337162496.tsx | 52 ------------ src/main/dist/tsx_context.ts | 25 ------ 9 files changed, 2 insertions(+), 555 deletions(-) delete mode 100644 src/main/dist/data-2062272402.tsx delete mode 100644 src/main/dist/data-2276051861.tsx delete mode 100644 src/main/dist/data-2519344230.tsx delete mode 100644 src/main/dist/data-2532431870.tsx delete mode 100644 src/main/dist/data-2905075436.tsx delete mode 100644 src/main/dist/data-3337162496.tsx delete mode 100644 src/main/dist/tsx_context.ts diff --git a/egg.yml b/egg.yml index 35c9a20c..04e361ab 100644 --- a/egg.yml +++ b/egg.yml @@ -1,6 +1,6 @@ name: Ogone repository: 'https://github.com/SRNV/Ogone' -version: 0.28.3 +version: 0.28.4 description: Advanced Web Composition for Future stable: false files: diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index d3557122..84303776 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -55,7 +55,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdirSync(this.createsubdistFolderURL.pathname); + Deno.mkdirSync(this.createsubdistFolderURL.pathname, { recursive: true }); } } private static async cleanFiles() { diff --git a/src/main/dist/data-2062272402.tsx b/src/main/dist/data-2062272402.tsx deleted file mode 100644 index 2ff77659..00000000 --- a/src/main/dist/data-2062272402.tsx +++ /dev/null @@ -1,75 +0,0 @@ - - export default {}; - - - class Protocol { - buttonOpts: { - name: string; - route: string; - status: 'ok' | 'todo' | 'in-progress'; - } = { - name: 'Test', - route: '', - status: 'todo' - }; - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - class Component extends Protocol { - render() { - return ( -); - } - runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - - - switch(_state) { - -default: - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/components/menu/MenuButton.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/data-2276051861.tsx b/src/main/dist/data-2276051861.tsx deleted file mode 100644 index 913e3d0b..00000000 --- a/src/main/dist/data-2276051861.tsx +++ /dev/null @@ -1,81 +0,0 @@ - - export default {}; - - -declare abstract class Store {public static dispatch(ns: string, ctx?: any): any} - class Protocol { - public isOpen: boolean = false; - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - declare function StoreMenu (props: OgoneSTOREComponent<{ - - }>): h.JSX.IntrinsicElements; - class Component extends Protocol { - render() { - return ( -); - } - runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - - - // @ts-ignore - if (typeof _state === "string" && !['click:openMenu'].includes(_state)) { - return; - } - switch(_state) { -case 'click:openMenu': - Store.dispatch('menu/toggle') - Store.dispatch('menu/checkController') - .then((res: any) => { - console.warn(res); - }); - break; - -default: - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/components/Burger.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/data-2519344230.tsx b/src/main/dist/data-2519344230.tsx deleted file mode 100644 index aa9adbe6..00000000 --- a/src/main/dist/data-2519344230.tsx +++ /dev/null @@ -1,64 +0,0 @@ - - export default {}; - - - declare const Controllers: { [k: string]: Controller; }; - declare interface Controller { - get(rte: string): Promise; - post(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; - put(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; - patch(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; - delete(rte: string, data: { [k: string]: any }, op: { [k: string]: any }): Promise; - }; - - class Protocol { - public isOpen: boolean = false; - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - class Component extends Protocol { - render() { - return ; - } - async runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - const { UserController } = Controllers; - - - // @ts-ignore - if (typeof _state === "string" && !['action:toggle','action:checkController'].includes(_state)) { - return; - } - switch(_state) { -case 'action:toggle': - this.isOpen = !this.isOpen; - break; -case 'action:checkController': - const res = await UserController.get('/'); - return res; - -default: - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/stores/StoreMenu.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/data-2532431870.tsx b/src/main/dist/data-2532431870.tsx deleted file mode 100644 index 49072c20..00000000 --- a/src/main/dist/data-2532431870.tsx +++ /dev/null @@ -1,134 +0,0 @@ - - export default {}; - - - - class Protocol { - public openTree: boolean = false; - public item: { - route: string; - status?: string; - name?: string; - children: ({ - status?: string; - name: string; - route: string; - children: any[] - })[]; - } = { name: 'no name', route: '', status: 'todo', children: []}; - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - declare function ScrollComponent (props: OgoneCOMPONENTComponent<{ - - }>): h.JSX.IntrinsicElements; - - declare function TreeRecursive (props: OgoneCOMPONENTComponent<{ - -item: { - route: string; - status?: string; - name?: string; - children: ({ - status?: string; - name: string; - route: string; - children: any[] - })[]; - } ; - }>): h.JSX.IntrinsicElements; - class Component extends Protocol { - render() { - return ( -); - } - runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - - - // @ts-ignore - if (typeof _state === "string" && !['click:toggle'].includes(_state)) { - return; - } - switch(_state) { -case 'click:toggle': - this.openTree = !this.openTree - break; - -default: - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/components/menu/TreeRecursiveButton.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/data-2905075436.tsx b/src/main/dist/data-2905075436.tsx deleted file mode 100644 index b14751ed..00000000 --- a/src/main/dist/data-2905075436.tsx +++ /dev/null @@ -1,122 +0,0 @@ - - export default {}; - - - - - - - declare const Refs: { - [k: string]: HTMLElement[]; - }; - class Protocol { - public scrollY: number = 0; - public setScrollY(n: number) { - this.scrollY = n; - } - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - declare function RightSection (props: OgoneCOMPONENTComponent<{ - -scrollY: unknown; - }>): h.JSX.IntrinsicElements; - - declare function AsyncLogoEl (props: OgoneASYNCComponent<{ - - }>): h.JSX.IntrinsicElements; - - declare function MenuContent (props: OgoneCOMPONENTComponent<{ - - }>): h.JSX.IntrinsicElements; - - declare function MenuMain (props: OgoneCOMPONENTComponent<{ - - }>): h.JSX.IntrinsicElements; - - declare function RouterComponent (props: OgoneROUTERComponent<{ - - }>): h.JSX.IntrinsicElements; - class Component extends Protocol { - render() { - return ( -); - } - runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - - - // @ts-ignore - if (typeof _state === "string" && ![].includes(_state)) { - return; - } - switch(_state) { - -default: - - const [header] = Refs.head; - window.addEventListener('scroll', (ev) => { - if (header) { - if (window.scrollY > this.scrollY) { - header.style.top = '-100px'; - } else { - header.style.top = '0px'; - } - } - this.setScrollY(window.scrollY); - }); - break; - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/Application.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/data-3337162496.tsx b/src/main/dist/data-3337162496.tsx deleted file mode 100644 index daa79c3e..00000000 --- a/src/main/dist/data-3337162496.tsx +++ /dev/null @@ -1,52 +0,0 @@ - - export default {}; - - - class Protocol { - public name: string = "SRNV"; - } - declare const Deno: any; - type OgoneCOMPONENTComponent = { children?: any; } & T; - type OgoneASYNCComponent = OgoneCOMPONENTComponent; - type OgoneSTOREComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneROUTERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - type OgoneCONTROLLERComponent = { namespace: string; } & OgoneCOMPONENTComponent; - - declare function h(...args: unknown[]): unknown; - declare function hf(...args: unknown[]): unknown; - declare namespace h.JSX { - export interface IntrinsicElements { - [k: string]: any; - } - } - - class Component extends Protocol { - render() { - return ; - } - async runtime (_state: string | number, ctx: any, event: any, _once: number = 0) { - try { - - - - - // @ts-ignore - if (typeof _state === "string" && !['GET:/','GET:/2'].includes(_state)) { - return; - } - switch(_state) { -case 'GET:/': - return `Hello ${this.name}`; -case 'GET:/2': - return '

test

'; - -default: - } - } catch(err) { - // @ts-ignore - displayError('Error in the component: \n\t examples/app/controllers/ControllerUser.o3' ,err.message, err); - throw err; - } - } - } - \ No newline at end of file diff --git a/src/main/dist/tsx_context.ts b/src/main/dist/tsx_context.ts deleted file mode 100644 index 381929f0..00000000 --- a/src/main/dist/tsx_context.ts +++ /dev/null @@ -1,25 +0,0 @@ - - /** - * Context of examples/app/Application.o3 - * */ - import comp0 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2905075436.tsx'; - /** - * Context of examples/app/components/Burger.o3 - * */ - import comp1 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2276051861.tsx'; - /** - * Context of examples/app/stores/StoreMenu.o3 - * */ - import comp2 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2519344230.tsx'; - /** - * Context of examples/app/controllers/ControllerUser.o3 - * */ - import comp3 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-3337162496.tsx'; - /** - * Context of examples/app/components/menu/MenuButton.o3 - * */ - import comp4 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2062272402.tsx'; - /** - * Context of examples/app/components/menu/TreeRecursiveButton.o3 - * */ - import comp5 from 'file:///home/rudy/Documents/Perso/Ogone/src/main/dist/data-2532431870.tsx'; \ No newline at end of file From 65980b68c70ea5667aedb034d38a1afbc0f093b8 Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 10:53:44 +0100 Subject: [PATCH 009/143] add permission --- src/classes/TSXContextCreator.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 84303776..6e7fc943 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -55,7 +55,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdirSync(this.createsubdistFolderURL.pathname, { recursive: true }); + Deno.mkdirSync(this.createsubdistFolderURL.pathname, { recursive: true, mode: 0o777}); } } private static async cleanFiles() { From a782622a2ac629876e8101ed8a61b73e56c378ab Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 10:58:32 +0100 Subject: [PATCH 010/143] fix permission denied --- src/classes/TSTranspiler.ts | 3 ++- src/classes/TSXContextCreator.ts | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/classes/TSTranspiler.ts b/src/classes/TSTranspiler.ts index 974ce747..da16ce82 100644 --- a/src/classes/TSTranspiler.ts +++ b/src/classes/TSTranspiler.ts @@ -1,12 +1,13 @@ import { Utils } from "./Utils.ts"; import MapOutput from './MapOutput.ts'; import { Bundle } from "../ogone.main.d.ts"; +import TSXContextCreator from "./TSXContextCreator.ts"; export default class TSTranspiler extends Utils { static browserBundlePatternURL = new URL('../bundle/browser_pattern.ts', import.meta.url); static runtimeURL = new URL('../main/Ogone.ts', import.meta.url); static runtimeBaseURL = new URL('../main/OgoneBase.ts', import.meta.url); - static subdistFolderUrl = new URL('../main/dist/', import.meta.url); + static subdistFolderUrl = TSXContextCreator.subdistFolderURL; static outputURL = new URL(`./out.ts`, TSTranspiler.subdistFolderUrl); static transpileCompilerOptions = { sourceMap: false, }; static async transpile(text: string): Promise { diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 6e7fc943..1f066caa 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -9,8 +9,8 @@ import { Utils } from "./Utils.ts"; */ let i = 0; export default class TSXContextCreator extends Utils { - static subdistFolderURL = new URL('../main/dist/', import.meta.url); - static createsubdistFolderURL = new URL('../main/dist', import.meta.url); + static subdistFolderURL = new URL('./.ogone', Deno.cwd()); + static createsubdistFolderURL = new URL('./.ogone', Deno.cwd()); static globalAppContextURL = new URL('./tsx_context.ts', TSXContextCreator.subdistFolderURL); static globalAppContextFile: string = ''; static mapCreatedFiles: URL[] = []; From 936ff7ca01b92bcdebddebbcf448695bd0bd83e2 Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 11:02:23 +0100 Subject: [PATCH 011/143] fix permission denied --- src/classes/TSXContextCreator.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 1f066caa..cbd18894 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -9,8 +9,8 @@ import { Utils } from "./Utils.ts"; */ let i = 0; export default class TSXContextCreator extends Utils { - static subdistFolderURL = new URL('./.ogone', Deno.cwd()); - static createsubdistFolderURL = new URL('./.ogone', Deno.cwd()); + static subdistFolderURL = new URL('./.ogone', `file:/${Deno.cwd()}`); + static createsubdistFolderURL = new URL('./.ogone', `file:/${Deno.cwd()}`); static globalAppContextURL = new URL('./tsx_context.ts', TSXContextCreator.subdistFolderURL); static globalAppContextFile: string = ''; static mapCreatedFiles: URL[] = []; From 84ffd5b9590b746c347959fffbcb241df267f7e9 Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 11:17:56 +0100 Subject: [PATCH 012/143] creating files and folders into the cache isn't allowed --- .gitignore | 3 ++- src/classes/TSTranspiler.ts | 2 +- src/classes/TSXContextCreator.ts | 16 ++++++++-------- 3 files changed, 11 insertions(+), 10 deletions(-) diff --git a/.gitignore b/.gitignore index 5ecbbeea..bc0be388 100644 --- a/.gitignore +++ b/.gitignore @@ -1,4 +1,5 @@ .deno_plugins/ .github/ null/ -.susano/ \ No newline at end of file +.susano/ +.ogone/ \ No newline at end of file diff --git a/src/classes/TSTranspiler.ts b/src/classes/TSTranspiler.ts index da16ce82..3ba47a7d 100644 --- a/src/classes/TSTranspiler.ts +++ b/src/classes/TSTranspiler.ts @@ -8,7 +8,7 @@ export default class TSTranspiler extends Utils { static runtimeURL = new URL('../main/Ogone.ts', import.meta.url); static runtimeBaseURL = new URL('../main/OgoneBase.ts', import.meta.url); static subdistFolderUrl = TSXContextCreator.subdistFolderURL; - static outputURL = new URL(`./out.ts`, TSTranspiler.subdistFolderUrl); + static outputURL = './.ogone/out.ts'; static transpileCompilerOptions = { sourceMap: false, }; static async transpile(text: string): Promise { try { diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index cbd18894..3528bc2a 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -9,13 +9,13 @@ import { Utils } from "./Utils.ts"; */ let i = 0; export default class TSXContextCreator extends Utils { - static subdistFolderURL = new URL('./.ogone', `file:/${Deno.cwd()}`); - static createsubdistFolderURL = new URL('./.ogone', `file:/${Deno.cwd()}`); - static globalAppContextURL = new URL('./tsx_context.ts', TSXContextCreator.subdistFolderURL); + static subdistFolderURL = './.ogone'; + static createsubdistFolderURL = './.ogone'; + static globalAppContextURL = './.ogone/ts_context.ts'; static globalAppContextFile: string = ''; - static mapCreatedFiles: URL[] = []; + static mapCreatedFiles: string[] = []; public static cleanDistFolder() { - const files = walkSync(TSXContextCreator.subdistFolderURL.pathname, { + const files = walkSync(TSXContextCreator.subdistFolderURL, { includeFiles: true, includeDirs: false, }); @@ -54,8 +54,8 @@ ${err.stack}`); } } public static createDistFolder() { - if(!existsSync(this.subdistFolderURL.pathname)) { - Deno.mkdirSync(this.createsubdistFolderURL.pathname, { recursive: true, mode: 0o777}); + if(!existsSync('.ogone')) { + Deno.mkdirSync('.ogone', { recursive: true }); } } private static async cleanFiles() { @@ -67,7 +67,7 @@ ${err.stack}`); const { green, gray } = colors; const baseUrl = new URL(import.meta.url); baseUrl.pathname = component.file; - const newpath = new URL(`./${component.uuid}.tsx`, TSXContextCreator.subdistFolderURL); + const newpath = `.ogone/${component.uuid}.tsx`; const { protocol } = component.context; Deno.writeTextFileSync(newpath, protocol); TSXContextCreator.mapCreatedFiles.push(newpath); From ad6762124c8352d4eb04faa790ffb76289128571 Mon Sep 17 00:00:00 2001 From: SRNV Date: Mon, 8 Feb 2021 12:27:03 +0100 Subject: [PATCH 013/143] fix: recursive import --- egg.yml | 2 +- src/classes/TSTranspiler.ts | 3 +-- src/classes/TSXContextCreator.ts | 5 +---- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/egg.yml b/egg.yml index 04e361ab..a822cfe4 100644 --- a/egg.yml +++ b/egg.yml @@ -1,6 +1,6 @@ name: Ogone repository: 'https://github.com/SRNV/Ogone' -version: 0.28.4 +version: 0.28.8 description: Advanced Web Composition for Future stable: false files: diff --git a/src/classes/TSTranspiler.ts b/src/classes/TSTranspiler.ts index 3ba47a7d..4029bad5 100644 --- a/src/classes/TSTranspiler.ts +++ b/src/classes/TSTranspiler.ts @@ -1,13 +1,12 @@ import { Utils } from "./Utils.ts"; import MapOutput from './MapOutput.ts'; import { Bundle } from "../ogone.main.d.ts"; -import TSXContextCreator from "./TSXContextCreator.ts"; export default class TSTranspiler extends Utils { static browserBundlePatternURL = new URL('../bundle/browser_pattern.ts', import.meta.url); static runtimeURL = new URL('../main/Ogone.ts', import.meta.url); static runtimeBaseURL = new URL('../main/OgoneBase.ts', import.meta.url); - static subdistFolderUrl = TSXContextCreator.subdistFolderURL; + static subdistFolderUrl = './.ogone'; static outputURL = './.ogone/out.ts'; static transpileCompilerOptions = { sourceMap: false, }; static async transpile(text: string): Promise { diff --git a/src/classes/TSXContextCreator.ts b/src/classes/TSXContextCreator.ts index 3528bc2a..748c4834 100755 --- a/src/classes/TSXContextCreator.ts +++ b/src/classes/TSXContextCreator.ts @@ -55,7 +55,7 @@ ${err.stack}`); } public static createDistFolder() { if(!existsSync('.ogone')) { - Deno.mkdirSync('.ogone', { recursive: true }); + Deno.mkdirSync('.ogone'); } } private static async cleanFiles() { @@ -64,9 +64,6 @@ ${err.stack}`); }) } private async createContext(bundle: Bundle, component: Component): Promise { - const { green, gray } = colors; - const baseUrl = new URL(import.meta.url); - baseUrl.pathname = component.file; const newpath = `.ogone/${component.uuid}.tsx`; const { protocol } = component.context; Deno.writeTextFileSync(newpath, protocol); From 42ec9cd2fbad2a3a182d9f0aae2b11962616b6f2 Mon Sep 17 00:00:00 2001 From: Rudy Alula <37340675+SRNV@users.noreply.github.com> Date: Tue, 9 Feb 2021 12:06:45 +0100 Subject: [PATCH 014/143] Update README.md --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 86e01912..97b1fbee 100644 --- a/README.md +++ b/README.md @@ -52,6 +52,11 @@ If you're interested by this project: [please join the Discord here](https://dis deno install -Afq --unstable https://deno.land/x/ogone/cli/ogone.ts ``` +and run your application like following +``` +ogone run path/to/Application.o3 +``` + - [Introduction](https://github.com/SRNV/Ogone/tree/master/docs/introduction.md) - [Examples](https://github.com/SRNV/Ogone/tree/master/docs/examples.md) - [Contributions](https://github.com/SRNV/Ogone/tree/master/docs/contributions.md) From bc0c52d03cc01c2ddf7f4d6b309c9a2c19fa6e07 Mon Sep 17 00:00:00 2001 From: SRNV Date: Tue, 9 Feb 2021 16:20:41 +0100 Subject: [PATCH 015/143] improve docs --- egg.yml | 2 +- examples/app/Application.o3 | 2 +- examples/app/components/ContentPage.o3 | 41 +++++++++---- examples/app/components/RightSection.o3 | 4 +- examples/app/defs/body.proto.yml | 76 ++++++++----------------- src/public/style.css | 2 +- 6 files changed, 59 insertions(+), 68 deletions(-) diff --git a/egg.yml b/egg.yml index a822cfe4..19faf8c3 100644 --- a/egg.yml +++ b/egg.yml @@ -1,6 +1,6 @@ name: Ogone repository: 'https://github.com/SRNV/Ogone' -version: 0.28.8 +version: 0.28.9 description: Advanced Web Composition for Future stable: false files: diff --git a/examples/app/Application.o3 b/examples/app/Application.o3 index 56b4b0f6..d074a5f0 100755 --- a/examples/app/Application.o3 +++ b/examples/app/Application.o3 @@ -75,7 +75,7 @@ import component RouterComponent from '@/examples/app/routers/Router.o3'; .header { background: var(--o-header); padding: 10px; - filter: drop-shadow(0px 10px 5px #00000087); + filter: drop-shadow(0px 10px 5px #00000033); display: flex; position: fixed; width: 99%; diff --git a/examples/app/components/ContentPage.o3 b/examples/app/components/ContentPage.o3 index 0d41b5e9..b426f4db 100755 --- a/examples/app/components/ContentPage.o3 +++ b/examples/app/components/ContentPage.o3 @@ -4,42 +4,54 @@

${this.title}

${this.text}

-
+
+

+ ${this.page} +

-        
+        
           ${this.code}
         
       
- - def: - inherit title: untitled - inherit text: no text - inherit code: "..." + + declare: + inherit title: string = 'untitled'; + inherit text: string = 'no text'; + inherit code: string = "..."; + inherit page: string = ""; \ No newline at end of file diff --git a/examples/app/components/RightSection.o3 b/examples/app/components/RightSection.o3 index cf1dad2f..b1de6269 100755 --- a/examples/app/components/RightSection.o3 +++ b/examples/app/components/RightSection.o3 @@ -1,6 +1,6 @@ - + declare: public isOpen: isOpenType = false; case 'click:openMenu': diff --git a/examples/app/components/ContentPage.o3 b/examples/app/components/ContentPage.o3 index 4f243f07..7812fd96 100755 --- a/examples/app/components/ContentPage.o3 +++ b/examples/app/components/ContentPage.o3 @@ -62,7 +62,7 @@ - + declare: inherit title: string = 'untitled'; inherit text: string = 'no text'; diff --git a/src/classes/Env.ts b/src/classes/Env.ts index 5323f26a..e346a397 100755 --- a/src/classes/Env.ts +++ b/src/classes/Env.ts @@ -358,27 +358,13 @@ ${err.stack}`); } return result; }).join("\n"); - const esm = entries.map(( - entry: any, - ) => entry[1].dynamicImportsExpressions).join("\n"); const style = stylesDev; const rootComponent = bundle.components.get(entrypoint); const dependencies = entries.map(([, component]) => component) .map((component) => { return component.deps.map((dep: Dependency) => dep.structuredOgoneRequire).join('\n'); }).join('\n'); - // TODO fix runtime - // TODO use Deno.emit to bundle Ogone's runtime - // and components if (rootComponent) { - if ( - rootComponent && - ["router", "store", "async"].includes(rootComponent.type) - ) { - this.error( - `the component provided in the entrypoint option has type: ${rootComponent.type}, entrypoint option only supports basic component`, - ); - } const scriptDev = this.template( ` const ___perfData = window.performance.timing; @@ -389,18 +375,9 @@ ${err.stack}`); ${MapOutput.runtime} {% dependencies %} - {% promise %} + {%start%} `, { - promise: esm.trim().length - ? ` - Promise.all([ - ${esm} - ]).then(() => { - {% start %} - }); - ` - : "{%start%}", start: `document.body.append( document.createElement(_ogone_node_) );`, @@ -426,11 +403,68 @@ ${err.stack}`); script, dom: DOMDev, }); + return body; + } else { + return "no root-component found"; + } + } catch (err) { + this.error(`Env: ${err.message} +${err.stack}`); + } + } + public async renderBundleAndBuildForProduction(entrypoint: string, bundle: Bundle): Promise { + try { + const entries = Array.from(bundle.components.entries()); + const globalStyle: string[] = []; + const stylesDev = entries + .map(( + entry: any, + ) => { + let result = ""; + globalStyle.push(entry[1].style.join("\n")); + return result; + }).join("\n"); + const style = ``; + const rootComponent = bundle.components.get(entrypoint); + const dependencies = entries.map(([, component]) => component) + .map((component) => { + return component.deps.map((dep: Dependency) => dep.structuredOgoneRequire).join('\n'); + }).join('\n'); + if (rootComponent) { + const scriptProd = this.template( + ` + const ROOT_UUID = "${rootComponent.uuid}"; + const ROOT_IS_PRIVATE = ${!!rootComponent.elements.template?.attributes.private}; + const ROOT_IS_PROTECTED = ${!!rootComponent.elements.template?.attributes.protected}; + const _ogone_node_ = "o-node"; - // start watching components - // TODO fix HMR - // use websocket - // HCR(this.bundle); + ${MapOutput.runtime} + `, + { + render: {}, + root: bundle.components.get(entrypoint), + destroy: {}, + nodes: {}, + dependencies, + }, + ); + // in production DOM has to be + // + const dom = ``; + let script = ` + `; + let head = ` + ${style} + ${Configuration.head || ""}`; + let body = this.template(HTMLDocument.PAGE_BUILD, { + head, + script, + dom, + }); return body; } else { return "no root-component found"; @@ -447,7 +481,15 @@ ${err.stack}`); "undefined bundle, please use setBundle method before accessing to the application", ); } - let result = await this.renderBundle(Configuration.entrypoint, this.bundle); + let result = ''; + switch(true) { + case this.env === "production": + result = await this.renderBundleAndBuildForProduction(Configuration.entrypoint, this.bundle); + break; + default: + result = await this.renderBundle(Configuration.entrypoint, this.bundle); + break; + } return result; } catch (err) { this.error(`Env: ${err.message} diff --git a/src/classes/EnvServer.ts b/src/classes/EnvServer.ts index df6fecdb..4c179fdf 100755 --- a/src/classes/EnvServer.ts +++ b/src/classes/EnvServer.ts @@ -45,9 +45,8 @@ export default class EnvServer extends Env { this.setDevTool(false); this.compile(Configuration.entrypoint, true) .then(async () => { - /* - TODO use workers for build - */ + let app = await this.getApplication(); + console.warn(app); }) } else { //start compilation of o3 files diff --git a/src/enums/templateDocumentHTML.ts b/src/enums/templateDocumentHTML.ts index 4790bc00..a70ccd84 100644 --- a/src/enums/templateDocumentHTML.ts +++ b/src/enums/templateDocumentHTML.ts @@ -9,6 +9,17 @@ enum HTMLDocument { {% script %} + `, + PAGE_BUILD = ` + + + {% head %} + + + {% dom %} + {% script %} + + ` } export default HTMLDocument; \ No newline at end of file From 7e3ba617e6e191613c8a170ced98cc81e647633e Mon Sep 17 00:00:00 2001 From: SRNV Date: Tue, 23 Mar 2021 22:29:02 +0100 Subject: [PATCH 100/143] wip on ogone build --- examples/tests/dist/app.js | 6218 ++++++++++++++++++++++++++++++++ examples/tests/dist/index.html | 13 + examples/tests/dist/style.css | 15 + src/classes/Dependency.ts | 19 +- src/classes/Env.ts | 134 +- src/classes/EnvServer.ts | 12 +- src/classes/TSTranspiler.ts | 16 +- src/ogone.main.d.ts | 24 +- 8 files changed, 6372 insertions(+), 79 deletions(-) create mode 100644 examples/tests/dist/app.js create mode 100644 examples/tests/dist/index.html create mode 100644 examples/tests/dist/style.css diff --git a/examples/tests/dist/app.js b/examples/tests/dist/app.js new file mode 100644 index 00000000..54792c1d --- /dev/null +++ b/examples/tests/dist/app.js @@ -0,0 +1,6218 @@ +const ROOT_UUID = "o3076301467"; +const ROOT_IS_PRIVATE = false; +const ROOT_IS_PROTECTED = false; +const _ogone_node_ = "o-node"; +const Ogone = { + types: { + }, + root: false, + require: { + }, + stores: { + }, + clients: [], + arrays: { + }, + render: { + }, + protocols: { + }, + contexts: { + }, + components: { + }, + classes: { + }, + errorPanel: null, + warnPanel: null, + successPanel: null, + infosPanel: null, + errors: 0, + firstErrorPerf: null, + mod: { + '*': [] + }, + ComponentCollectionManager: null, + instances: { + }, + routerReactions: [], + actualRoute: null, + displayError (message, errorType, errorObject) { + if (!Ogone.errorPanel) { + const p = document.createElement("div"); + Object.entries({ + zIndex: "5000000", + background: "#00000097", + width: "100vw", + height: "100vh", + position: "fixed", + top: "0px", + left: "0px", + overflowY: "auto", + justifyContent: "center", + display: "grid", + flexDirection: "column" + }).forEach(([key, value])=>{ + p.style[key] = value; + }); + Ogone.errorPanel = p; + } + Ogone.errors++; + const err = document.createElement("div"); + Object.entries({ + zIndex: "5000000", + background: "#000000", + minHeight: "fit-content", + maxWidth: "70%", + padding: "21px", + color: "red", + borderLeft: "3px solid red", + margin: "auto", + display: "inline-flex", + flexDirection: "column" + }).forEach(([key, value])=>err.style[key] = value + ); + const errorId = Ogone.errors; + const code = document.createElement("code"); + const stack = document.createElement("code"); + const h = document.createElement("h4"); + h.innerText = `[Ogone] Error ${errorId}: ${errorType || "Undefined Type"}`; + code.innerText = `${message.trim()}`; + stack.innerText = `${errorObject && errorObject.stack ? errorObject.stack.replace(message, "") : ""}`; + if (!stack.innerText.length && errorObject && errorObject.message) { + stack.innerText = `${errorObject && errorObject.message ? errorObject.message : ""}`; + } + !stack.innerText.length ? stack.innerText = "undefined stack" : ""; + code.style.marginLeft = "20px"; + code.style.whiteSpace = "pre-wrap"; + code.style.wordBreak = "break-word"; + stack.style.marginLeft = "20px"; + stack.style.color = "#dc7373"; + stack.style.padding = "17px"; + stack.style.background = "#462626"; + stack.style.whiteSpace = "pre-wrap"; + stack.style.wordBreak = "break-word"; + stack.style.border = "1px solid"; + stack.style.marginTop = "10px"; + h.style.color = "#8c8c8c"; + if (!Ogone.firstErrorPerf) { + Ogone.firstErrorPerf = performance.now(); + } + if (Ogone.errorPanel) { + Ogone.errorPanel.style.paddingTop = "30px"; + err.style.gridArea = `e${errorId}`; + const m = 2; + let grid = ""; + let i = 0; + let a = 0; + for((i = 0, a = Ogone.errorPanel.childNodes.length + 1); i < a; i++){ + grid += `e${i + 1} `; + } + let b = i; + while(i % 2){ + grid += `e${b} `; + i++; + } + const cells = grid.split(" "); + var o, j, temparray, chunk = 2; + let newgrid = ""; + for((o = 0, j = cells.length - 1); o < j; o += chunk){ + temparray = cells.slice(o, o + chunk); + newgrid += ` "${temparray.join(" ")}"`; + } + Ogone.errorPanel.style.gridGap = "10px"; + Ogone.errorPanel.style.gridAutoRows = "max-content"; + Ogone.errorPanel.style.gridTemplateRows = "masonry"; + Ogone.errorPanel.style.gridTemplateAreas = newgrid; + err.style.animationName = "popup"; + err.style.animationIterationCount = "1"; + err.style.animationDuration = "0.5s"; + err.append(h, code, stack); + Ogone.errorPanel.append(err); + Ogone.errorPanel.style.pointerEvents = "scroll"; + !Ogone.errorPanel.isConnected ? document.body.append(Ogone.errorPanel) : []; + } + }, + files: [], + directories: [], + controllers: { + }, + main: '', + allowedTypes: [ + "app", + "router", + "store", + "controller", + "async", + "component", + ], + router: { + react: [], + actualRoute: null, + go: (...args)=>{ + routerGo(...args); + } + }, + get isDeno () { + return typeof Deno !== "undefined" && !!Deno.chmod; + } +}; +var ClientRole; +(function(ClientRole1) { + ClientRole1[ClientRole1["Standard"] = 0] = "Standard"; + ClientRole1[ClientRole1["Edition"] = 1] = "Edition"; +})(ClientRole || (ClientRole = { +})); +class HMR { + static FIFOMessages = []; + static port = 3434; + static isInErrorState = false; + static isWaitingForServerPort = false; + static heartBeatIntervalTime = 500; + static components = { + }; + static clients = new Map(); + static listeners = new Map(); + static get connect() { + return `ws://0.0.0.0:${this.port}/`; + } + static startHandshake() { + } + static async sendError(error, diagnostics) { + this.postMessage({ + error, + diagnostics + }); + } + static get isInBrowser() { + return typeof document !== 'undefined'; + } + static get panelInformations() { + if (!this.isInBrowser) throw new Error('cannot use panelInformations outside the browser'); + return this._panelInformations || (this._panelInformations = document.createElement('ul')); + } + static useOgone(ogone) { + if (this.isInBrowser) { + this.ogone = ogone; + this.clientSettings(); + } + } + static clientSettings(shouldReload) { + try { + this.client = new WebSocket(this.connect); + } catch (err) { + return; + } + setTimeout(()=>{ + if (this.checkHeartBeat()) { + if (shouldReload) { + this.clearInterval(); + this.showHMRMessage('HMR reconnected, waiting for reload message', 'success'); + this.showHMRMessage(`click here to reload it manually`); + this.isWaitingForServerPort = true; + } + } else { + this.showHMRMessage('heart beat goes on false', 'warn'); + } + }, this.heartBeatIntervalTime); + this.client.onmessage = (evt)=>{ + const payload = JSON.parse(evt.data); + const { uuid , output , error , errorFile , diagnostics , type , pathToModule , uuidReq , port } = payload; + if (type === 'server') { + const { search , pathname } = window.location; + window.location.replace(`http://localhost:${port}${pathname}${search}`); + return; + } + if (type === 'reload') { + window.location.reload(); + return; + } + if (type === 'resolved') { + this.isInErrorState = false; + this.hideHMRMessage(); + return; + } + if (type === 'style') { + let style = document.querySelector(`style#${uuid}`); + if (style) { + if (output !== style.innerHTML) style.innerHTML = output; + } else { + style = document.createElement('style'); + style.id = uuid; + style.innerHTML = output; + document.head.append(style); + } + return; + } + if (type === 'module') { + this.getModule(pathToModule, uuidReq, uuid); + } + if (error) { + this.hideHMRMessage(); + this.isInErrorState = true; + console.error(error); + let errorUuid; + diagnostics.forEach((diag)=>{ + let errorMessage = ''; + const { sourceLine , messageText } = diag; + if (diag) { + errorUuid = diag.fileName && diag.fileName.match(/(?<=\/)(?[\w\d\-]+?)\.tsx$/)?.groups?.uuid || undefined; + } + const start = diag.start && diag.start.character || 0; + const end = diag.end && diag.end.character || 0; + const repeatNumber = end - start - 1; + let sourceline = diag && sourceLine || ''; + sourceline = repeatNumber >= 0 ? sourceline.substring(0, start) + '' + sourceline.substring(start, end) + '' + sourceline.substring(end) : sourceline; + errorMessage = `\nTS${diag && diag.code} [ERROR] ${diag && diag.messageChain && diag.messageChain.messageText || diag && diag.messageText || ''}\n${this.renderChainedDiags(diag && diag.messageChain && diag.messageChain.next || [])}\n${sourceline}\n`; + this.showHMRMessage(`\n${messageText || errorFile || 'Error found in application.'}\n${errorMessage}\n `); + }); + return; + } + this.rerenderComponents(uuid, output); + }; + this.startHearBeat(); + } + static renderChainedDiags(chainedDiags) { + let result = ``; + if (chainedDiags && chainedDiags.length) { + for (const d of chainedDiags){ + const diag = d; + result += `TS${diag.code} [ERROR] `; + result += `${diag && diag.messageText}\n`; + } + } + return result; + } + static rerenderComponents(uuid, output) { + const savedComponents = this.components[uuid]; + if (savedComponents) { + const setComponentToRerender = new Set(); + savedComponents.filter((c)=>c.routerCalling?.isRouter && c.routerCalling.isOriginalNode + ).forEach((c)=>{ + setComponentToRerender.add(c.routerCalling); + }); + savedComponents.forEach((component)=>{ + if (component.isTemplate && component.original) { + setComponentToRerender.add(component.original); + } + }); + if (output) { + const replacement = eval(`((Ogone) => {\n ${output}\n console.warn('[Ogone] references are updated.');\n })`); + replacement(Ogone); + } + console.warn('[Ogone] rendering new components.'); + setComponentToRerender.forEach((component)=>{ + if (component) component.rerender(); + }); + } + } + static async getModule(pathToModule, uuidReq, uuid) { + const iframe = document.createElement('iframe'); + document.body.append(iframe); + iframe.name = 'HMR_IFRAME'; + iframe.srcdoc = `\n < script>\n window.loadModule = async (listener, path) => {\n listener(await import(path));\n };\n window.postMessage('ready');\n \n `.replace(/\<(\/{0,1})\s+script/gi, '<$1script'); + iframe.addEventListener('load', ()=>{ + if (iframe.contentWindow) { + iframe.contentWindow.addEventListener('message', async ()=>{ + const { loadModule } = iframe.contentWindow; + if (this.listeners.has(pathToModule)) { + const { listeners , graph } = this.listeners.get(pathToModule); + for (let listener of listeners){ + await loadModule(listener, pathToModule + `?uuid_req=${uuidReq}`); + } + } else { + const entries = Array.from(this.listeners.entries()); + const candidate = entries.find(([key, moduleGraph])=>{ + return moduleGraph.graph.includes(pathToModule); + }); + if (candidate) { + const [dependencyPath, dependency] = candidate; + for (let listener of dependency.listeners){ + await loadModule(listener, dependencyPath + `?uuid_req=${uuidReq}`); + } + } else { + console.warn('[Ogone] module not found.'); + return; + } + } + iframe.remove(); + this.rerenderComponents(uuid); + }); + } + }); + console.warn('[Ogone] updating module.'); + } + static setServer(server) { + this.server = server; + this.server.on('connection', (ws)=>{ + this.cleanClients(); + const key = `client_${crypto.getRandomValues(new Uint16Array(10)).join('')}`; + HMR.clients.set(key, { + ready: false, + connection: ws, + role: 0 + }); + }); + } + static postMessage(obj) { + this.cleanClients(); + const message = JSON.stringify(obj); + const entries = Array.from(this.clients.entries()); + entries.forEach(([key, client])=>{ + if (client?.connection.state !== 1 && !client.connection.isClosed && !this.FIFOMessages.includes(message)) { + this.FIFOMessages.push(message); + } else if (!client.ready) { + this.sendFIFOMessages(key); + } + if (client && !client.connection.isClosed) { + try { + client.connection.send(message); + } catch (err) { + } + } + }); + } + static cleanClients() { + const entries = Array.from(this.clients.entries()); + entries.forEach(([key, client])=>{ + if (client.connection.isClosed) { + this.clients.delete(key); + } + }); + } + static async sendFIFOMessages(id) { + const entries = Array.from(this.clients.entries()).filter(([key, client])=>!client.ready && key === id + ); + entries.forEach(([key, client])=>{ + this.FIFOMessages.forEach((m)=>{ + client.connection.send(m); + client.ready = client.connection.state === 1 && true; + }); + }); + } + static subscribe(pathToModule, listener) { + if (!this.listeners.has(pathToModule)) this.listeners.set(pathToModule, { + listeners: [ + listener + ], + graph: [] + }); + else { + const candidate = this.listeners.get(pathToModule); + candidate.listeners.push(listener); + } + } + static setGraph(pathToModule, graph) { + if (this.listeners.has(pathToModule)) { + const candidate = this.listeners.get(pathToModule); + if (candidate) candidate.graph = candidate.graph.concat(graph); + } + } + static beforeClosing() { + if (typeof document === 'undefined') { + this.postMessage({ + type: 'close' + }); + } else if (this.client) { + this.clearInterval(); + this.client.send(JSON.stringify({ + type: 'close' + })); + } + } + static clearInterval() { + clearInterval(this.heartBeatInterval); + } + static checkHeartBeat() { + let heartbeat = true; + if (this.client) { + if (this.client.readyState > 1) { + heartbeat = false; + } else { + try { + this.client.send(''); + } catch (err) { + heartbeat = false; + } + } + } + return heartbeat; + } + static startHearBeat() { + this.clearInterval(); + this.heartBeatInterval = setInterval(()=>{ + if (!this.checkHeartBeat()) { + this.showHMRMessage('HMR disconnected - retrying in 1s ...'); + this.clearInterval(); + setTimeout(()=>{ + this.showHMRMessage('HMR disconnected - sending heart beat message'); + this.clientSettings(true); + }, 1000); + } + }, this.heartBeatIntervalTime); + } + static showHMRMessage(message, messageType = '') { + if (this.isInBrowser) { + if (!this.panelInformations.isConnected) { + const style = document.createElement('style'); + style.innerHTML = `\n .hmr--panel {\n display: flex;\n flex-direction: column;\n justify-content: flex-end;\n position: fixed;\n z-index: 50000;\n background: #2a2a2d;\n width: 100vw;\n height: 100vh;\n padding-right: 15px;\n top: 0;\n margin: 0;\n overflow: auto;\n list-style: none;\n }\n .hmr--message {\n padding: 5px;\n margin: 0px 2px;\n color: #9ea0a0;\n font-family: sans-serif;\n }\n .hmr--message .hmr--infos {\n color: #4a4a4d;\n }\n .hmr--message .hmr--title {\n color: #7d7a7d;\n }\n .hmr--message .hmr--message {\n color: inherit;\n white-space: pre-wrap;\n }\n .hmr--message .error {\n color: #fb7191;\n }\n .hmr--message .success {\n color: #91fba1;\n }\n .hmr--message .critic {\n color: #ff7191;\n text-decoration: underline;\n }\n .hmr--message .link {\n text-decoration: underline;\n cursor: pointer;\n }\n .hmr--message .warn {\n color: #fff2ae;\n }\n `; + document.body.append(this.panelInformations); + document.head.append(style); + } + this.addMessageToHMR(message, messageType); + if (!this.panelInformations.classList.contains('hmr--panel')) { + this.panelInformations.classList.add('hmr--panel'); + } + } + } + static addMessageToHMR(message, type = '') { + this.panelInformations.innerHTML += `\n
  • \n ${new Date().toUTCString()} Ogone - ${message}
  • \n `; + } + static hideHMRMessage() { + if (this.isInErrorState) return; + this.panelInformations.classList.remove('hmr--panel'); + this.panelInformations.innerHTML = ''; + } +} +HMR.useOgone(Ogone); +window.addEventListener('unload', ()=>{ + HMR.beforeClosing(); +}); +class OgoneBaseClass extends HTMLElement { + key = null; + data = null; + pluggedWebComponentIsSync = false; + dependencies = null; + state = 0; + activated = true; + namespace = null; + store = { + }; + contexts = { + for: { + } + }; + promises = []; + resolve = null; + async = { + then: null, + catch: null, + finally: null + }; + dispatchAwait = null; + promiseResolved = false; + react = []; + texts = []; + childs = []; + refs = { + }; + type = "component"; + constructor(){ + super(); + if (!Ogone.root) { + let opts = { + props: null, + parentCTXId: '', + dependencies: null, + requirements: null, + routes: null, + isRoot: true, + isTemplate: true, + isTemplatePrivate: ROOT_IS_PRIVATE, + isTemplateProtected: ROOT_IS_PROTECTED, + isAsync: false, + isController: false, + isAsyncNode: false, + isRouter: false, + isStore: false, + isImported: false, + isRemote: false, + index: 0, + level: 0, + position: [ + 0 + ], + flags: null, + isOriginalNode: true, + uuid: ROOT_UUID, + extends: '-nt' + }; + setOgone(this, opts); + opts = null; + Ogone.root = true; + } + } + get firstNode() { + return this.nodes[0]; + } + get lastNode() { + return this.nodes[this.nodes.length - 1]; + } + get extending() { + return `${this.uuid}${this.extends}`; + } + get name() { + return _ogone_node_; + } + set name(v) { + } + get isComponent() { + return this.isTemplate; + } + get isRecursiveConnected() { + return !!(this.nodes?.length && this.firstNode.isConnected && this.lastNode.isConnected); + } + get isConnected() { + if (!this.firstNode) { + return false; + } + return !!this.nodes?.find((n)=>n.isConnected + ); + } + get context() { + const o = this, oc = this.component; + if (!oc) return; + if (!oc.contexts.for[o.key]) { + oc.contexts.for[o.key] = { + list: [ + this + ], + parentNode: this.parentNode, + name: this.name + }; + } + return oc.contexts.for[o.key]; + } + connectedCallback() { + if (this.isController) { + this.remove(); + return; + } + setPosition(this); + setContext(this); + if (this.type === "router") { + setActualRouterTemplate(this); + } + if (this.isTemplate) { + setProps(this); + OnodeUpdateProps(this); + } + renderingProcess(this); + switch(true){ + case this.type === "router": + renderRouter(this); + break; + case this.type === "store": + renderStore(this); + break; + case this.type === "async": + renderAsync(this); + break; + default: + renderNode(this); + break; + } + } + rerender() { + if (this.isRoot) { + Ogone.root = false; + document.body.innerHTML = ''; + document.body.append(document.createElement(_ogone_node_)); + return; + } + if (this.isRouter) { + this.actualRoute = null; + setActualRouterTemplate(this); + renderRouter(this); + return; + } + for(let i = this.context.list.length, a = 0; i > a; i--){ + destroy(this.context.list.pop()); + } + renderContext(this, true); + } +} +window.customElements.define(_ogone_node_, OgoneBaseClass); +window.addEventListener('popstate', (event)=>{ + routerGo(location.pathname, event.state); +}); +const mapProxies = new Map(); +function setReactivity(target, updateFunction, parentKey = '') { + return new Proxy(target, { + get (obj, key, ...args) { + let v; + const id = `${parentKey}.${key.toString()}`.replace(/^[^\w]+/i, ''); + if (key === 'prototype') { + v = Reflect.get(obj, key, ...args); + } else if (mapProxies.get(obj[key])) { + return mapProxies.get(obj[key]); + } else if ((obj[key] instanceof Object || Array.isArray(obj[key])) && !mapProxies.has(obj[key])) { + v = setReactivity(obj[key], updateFunction, id); + mapProxies.set(obj[key], v); + } else { + v = Reflect.get(obj, key, ...args); + } + return v; + }, + set (obj, key, value, ...args) { + if (obj[key] === value) return true; + const id = `${parentKey}.${key.toString()}`.replace(/^[^\w]+/i, ''); + const v = Reflect.set(obj, key, value, ...args); + updateFunction(id); + return v; + }, + deleteProperty (obj, key) { + const id = `${parentKey}.${key.toString()}`.replace(/^[^\w]+/i, ''); + const v = Reflect.deleteProperty(obj, key); + updateFunction(id); + return v; + } + }); +} +function _ap(p, n) { + n.placeholder ? p.append(n, n.placeholder) : p.append(n); +} +function _h(...a) { + return document.createElement(...a); +} +function _at(n, a, b) { + return n.setAttribute(a, b); +} +function construct(Onode) { + const o = Onode; + if (!o.type) return; + Onode.dependencies = o.dependencies; + if (Onode.isComponent) { + const { data , runtime , Refs } = Ogone.components[o.uuid](Onode); + Onode.data = data; + Onode.component = Onode; + Onode.runtime = runtime; + Onode.component.runtime = runtime; + Onode.component.refs = Refs; + Onode.requirements = o.requirements; + Onode.props = o.props; + Onode.type = Ogone.types[Onode.extending]; + } +} +function setOgone(Onode, def) { + const params = { + original: Onode, + isRemote: false, + isRoot: false, + isImported: false, + position: [ + 0 + ], + index: 0, + level: 0, + uuid: '', + extends: '-nt', + positionInParentComponent: [ + 0 + ], + levelInParentComponent: 0, + component: Onode, + parentComponent: def.parentComponent, + render: null, + nodes: [], + replacer: null, + getContext: null, + promise: null, + routes: null, + locationPath: null, + actualTemplate: null, + actualRouteName: null, + actualRoute: null, + key: `n${Math.random()}`, + routeChanged: null, + historyState: null, + methodsCandidate: [] + }; + Object.assign(Onode, params, def); + Onode.renderNodes = Ogone.render[Onode.extending]; + if (Onode.isRouter) { + Onode.locationPath = location.pathname; + Onode.routeChanged = true; + const url = new URL(location.href); + const query = new Map(url.searchParams.entries()); + Onode.historyState = { + query + }; + } + construct(Onode); + if (Onode.isComponent) { + HMR.components[Onode.uuid] = HMR.components[Onode.uuid] || []; + HMR.components[Onode.uuid].push(Onode); + } +} +function setNodeProps(Onode) { + const o = Onode, oc = Onode; + if (!o || !oc || !o.nodes || !o.nodeProps) return; + function r(n, p) { + const vl = o.getContext({ + position: o.position, + getText: `(${p[1]})` + }); + n.setAttribute(p[0], vl); + return n.isConnected; + } + for (let n of o.nodes){ + for (let p of o.nodeProps){ + oc.component.react.push(()=>r(n, p) + ); + r(n, p); + } + } +} +function setPosition(Onode) { + const o = Onode; + if (o.position && typeof o.level === 'number' && typeof o.index === 'number') { + o.position[o.level] = o.index; + } +} +function setProps(Onode) { + const o = Onode, oc = Onode; + if (!o || !oc) return; + if (!o.index) { + o.index = 0; + } + oc.props = o.props; + if (!o.positionInParentComponent || o.levelInParentComponent !== undefined) { + oc.positionInParentComponent = o.positionInParentComponent; + o.positionInParentComponent[o.levelInParentComponent] = o.index; + } + OnodeUpdateProps(Onode); +} +function useSpread(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + const op = oc.parent; + let reaction, parent; + if (o.isTemplate && o.flags && o.flags.spread && op) { + reaction = ()=>{ + const v = o.getContext({ + position: o.positionInParentComponent, + getText: `{${o.flags.spread}}` + }); + Object.entries(v).forEach(([k, value])=>{ + OnodeUpdateService(oc, k, value); + }); + return Onode.component.activated; + }; + parent = oc.parent; + } else if (!o.isTemplate && o.flags && o.flags.spread) { + reaction = ()=>{ + const v = o.getContext({ + position: o.position, + getText: `{${o.flags.spread}}` + }); + Object.entries(v).forEach(([k, value])=>{ + if (o.nodes) { + for (let n of o.nodes){ + n.setAttribute(k, value); + } + } + }); + return Onode.component.activated; + }; + parent = oc.component; + } + reaction && reaction(); + parent && reaction && parent.react.push(reaction); +} +function setNodes(Onode) { + const o = Onode; + if (!o.renderNodes) return; + if (o.isTemplate) { + o.nodes = Array.from(o.renderNodes(Onode.component).childNodes); + } else { + o.nodes = [ + o.renderNodes(Onode.component, o.position, o.index, o.level) + ]; + } + if (o.methodsCandidate && o.methodsCandidate.length) { + o.methodsCandidate.forEach((f, i, arr)=>{ + if (o.nodes) { + for (let n of o.nodes){ + if (n.extending) { + saveUntilRender(n, f); + } else { + f(n); + } + } + } + delete arr[i]; + }); + } +} +function removeNodes(Onode) { + const o = Onode; + if (!o.nodes) return Onode; + function rm(n) { + if (n.extending) { + destroy(n); + } else { + n.remove(); + } + } + if (o.actualTemplate) { + rm(o.actualTemplate); + } + o.nodes.forEach((n)=>{ + rm(n); + }); + return Onode; +} +function destroy(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + Onode.context.list.forEach((n)=>{ + removeNodes(n); + n.remove(); + }); + removeNodes(Onode); + if (o.isTemplate) { + OnodeDestroyPluggedWebcomponent(oc); + oc.component.runtime("destroy"); + o.component.activated = false; + Onode.component.texts.splice(0); + Onode.component.react.splice(0); + } + Onode.context.list.splice(0); + Onode.remove(); +} +function setEvents(Onode) { + const o = Onode, oc = Onode; + if (!o.flags || !o.getContext || !oc || !o.nodes) return; + const position = Onode.isComponent ? oc.positionInParentComponent : o.position; + const c = Onode.isComponent ? Onode.parentComponent : oc; + for (let node of o.nodes){ + for (let flag of o.flags.events){ + if (flag.type === "wheel") { + if (node.extending) { + saveUntilRender(node, (nr)=>{ + nr.hasWheel = true; + nr.addEventListener(flag.type, (ev)=>{ + const foundWheel = ev.path.find((n)=>n && n.hasWheel + ); + if (foundWheel && !foundWheel.isSameNode(node)) return; + if (o.getContext && c) { + const filter = o.getContext({ + getText: `${flag.filter}`, + position + }); + const ctx = o.getContext({ + position + }); + switch(true){ + case filter === "right" && ev.wheelDeltaX < 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "left" && ev.wheelDeltaX > 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "up" && ev.wheelDeltaY > 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "down" && ev.wheelDeltaY < 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === null: + c.component.runtime(flag.case, ctx, ev); + break; + } + } + }); + }); + } else { + node.hasWheel = true; + node.addEventListener(flag.type, (ev)=>{ + const foundWheel = ev.path.find((n)=>n && n.hasWheel + ); + if (foundWheel && !foundWheel.isSameNode(node)) return; + if (o.getContext && c) { + const filter = o.getContext({ + getText: `${flag.filter}`, + position + }); + const ctx = o.getContext({ + position + }); + switch(true){ + case filter === "right" && ev.wheelDeltaX < 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "left" && ev.wheelDeltaX > 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "up" && ev.wheelDeltaY > 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === "down" && ev.wheelDeltaY < 0: + c.component.runtime(flag.case, ctx, ev); + break; + case filter === null: + c.component.runtime(flag.case, ctx, ev); + break; + } + } + }); + } + } else if (flag.type.startsWith("key") && c) { + document.addEventListener(flag.type, (ev)=>{ + const filter = o.getContext({ + getText: `${flag.filter}`, + position + }); + const ctx = o.getContext({ + position + }); + switch(true){ + case ev.charCode === filter: + c.component.runtime(flag.case, ctx, ev); + break; + case ev.key === filter: + c.component.runtime(flag.case, ctx, ev); + break; + case ev.keyCode === filter: + c.component.runtime(flag.case, ctx, ev); + break; + case ev.code.toLowerCase() === filter: + c.component.runtime(flag.case, ctx, ev); + break; + case !filter: + c.component.runtime(flag.case, ctx, ev); + break; + } + }); + } else if (flag.name === "router-go" && flag.eval) { + if (node.extending) { + saveUntilRender(node, (nr)=>{ + nr.addEventListener("click", (ev)=>{ + routerGo(o.getContext({ + getText: `${flag.eval}`, + position + }), history.state); + }); + }); + } else { + node.addEventListener("click", (ev)=>{ + routerGo(o.getContext({ + getText: `${flag.eval}`, + position + }), history.state); + }); + } + } else if (flag.name === 'router-dev-tool' && flag.eval) { + node.addEventListener("click", ()=>{ + }); + } else if (flag.name === "event" && flag.type.startsWith('animation')) { + if (node.extending) { + saveUntilRender(node, (nr)=>{ + nr.addEventListener(flag.type, (ev)=>{ + if (flag.eval !== ev.animationName) return; + const ctx = o.getContext({ + position + }); + if (c) { + c.component.runtime(flag.case, ctx, ev); + } + }); + }); + } else { + node.addEventListener(flag.type, (ev)=>{ + if (flag.eval !== ev.animationName) return; + const ctx = o.getContext({ + position + }); + if (c) { + c.component.runtime(flag.case, ctx, ev); + } + }); + } + } else { + if (node.extending) { + saveUntilRender(node, (nr)=>{ + nr.addEventListener(flag.type, (ev)=>{ + const ctx = o.getContext({ + position + }); + if (c) { + c.component.runtime(flag.case, ctx, ev); + } + }); + }); + } else { + node.addEventListener(flag.type, (ev)=>{ + const ctx = o.getContext({ + position + }); + if (c) { + c.component.runtime(flag.case, ctx, ev); + } + }); + } + } + } + } +} +function routerSearch(Onode, route, locationPath) { + if (typeof locationPath !== "string") return false; + const { path } = route; + const splitted = path.toString().split("/"); + const locationSplit = locationPath.split("/"); + const result = { + }; + if (!splitted.filter((r)=>r.trim().length + ).length !== !locationSplit.filter((r)=>r.trim().length + ).length) { + return false; + } + if (splitted.length !== locationSplit.length) return false; + const error = splitted.find((p, i, arr)=>{ + if (!p.startsWith(":")) { + return locationSplit[i] !== p; + } + }); + if (error) return false; + splitted.forEach((p, i)=>{ + if (p.startsWith(":")) { + const param = p.slice(1, p.length); + result[param] = locationSplit[i]; + } + }); + route.params = result; + return true; +} +function setActualRouterTemplate(Onode) { + const o = Onode, oc = Onode; + oc.routes = o.routes; + oc.locationPath = o.locationPath; + const l = oc.locationPath; + let rendered = oc.routes.find((r)=>r.path === l || routerSearch(Onode, r, l) || r.path === 404 + ); + let preservedParams = rendered && rendered.params; + while(rendered && rendered.redirect){ + rendered = oc.routes.find((r)=>rendered && r.name === rendered.redirect + ); + if (rendered) { + rendered.params = preservedParams; + } + } + if (rendered) { + o.actualRouteName = rendered.name || null; + } + if (!rendered) { + o.actualTemplate = new Text(' '); + o.actualRoute = null; + o.routeChanged = true; + } else if (rendered && !(rendered.once || o.actualRoute === rendered.component)) { + const co = document.createElement(_ogone_node_); + o.actualTemplate = co; + o.actualRoute = rendered.component; + o.routeChanged = true; + let ogoneOpts = { + isTemplate: true, + isTemplatePrivate: rendered.isTemplatePrivate, + isTemplateProtected: rendered.isTemplateProtected, + isRouter: rendered.isRouter, + isStore: false, + isAsync: rendered.isAsync, + isAsyncNode: false, + isController: false, + placeholder: new Text(' '), + requirements: o.requirements, + routes: o.routes, + isOriginalNode: false, + dependencies: [], + extends: "-nt", + uuid: rendered.uuid, + tree: o.tree, + params: rendered.params || null, + props: o.props, + parentComponent: o.parentComponent, + parentCTXId: o.component.parentCTXId, + positionInParentComponent: o.positionInParentComponent.slice(), + levelInParentComponent: o.levelInParentComponent, + index: o.index, + level: o.level, + position: o.position, + flags: o.flags, + isRoot: false, + name: rendered.name || rendered.component, + parentNodeKey: o.key, + routerCalling: o + }; + setOgone(co, ogoneOpts); + ogoneOpts = null; + co.isAsync = co.type === 'async'; + co.isRouter = co.type === 'router'; + co.isStore = co.type === 'store'; + if (rendered.title) { + document.title = rendered.title; + } + } else { + o.routeChanged = false; + } +} +function setNodeAsyncContext(Onode) { + const o = Onode; + if (o.flags && o.flags.await) { + const promise = new Promise((resolve, reject)=>{ + try { + if (typeof o.flags.await === "boolean") { + Onode.firstNode.addEventListener("load", ()=>{ + resolve(false); + }); + } else { + const type = o.getContext({ + getText: o.flags.await, + position: o.position + }); + Onode.firstNode.addEventListener(type, ()=>{ + resolve(false); + }); + } + } catch (err) { + reject(err); + } + }); + o.component.promises.push(promise); + } +} +function setAsyncContext(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + if (o.flags && o.flags.then) { + oc.async.then = o.flags.then; + } + if (o.flags && o.flags.catch) { + oc.async.catch = o.flags.catch; + } + if (o.flags && o.flags.finally) { + oc.async.finally = o.flags.finally; + } + if (o.flags && o.flags.defer) { + const promise = oc.parentContext({ + getText: o.flags.defer, + position: o.positionInParentComponent + }); + oc.component.promises.push(promise); + } +} +function saveUntilRender(Onode, f) { + if (Onode.methodsCandidate) { + Onode.methodsCandidate.push(f); + } +} +function bindValue(Onode) { + const o = Onode, oc = Onode; + if (!o.flags || !o.flags.bind || !oc || !o.nodes) return; + function r(n, dependency) { + const k = o.flags.bind; + const evl = o.getContext({ + position: o.position, + getText: k + }); + if (dependency === true) { + n.value = evl; + } + if (typeof dependency === "string" && k.indexOf(dependency) > -1 && evl !== undefined && n.value !== evl) { + n.value = evl; + } + return n.isConnected; + } + for (let n of o.nodes){ + function bound() { + } + n.addEventListener("keydown", (ev)=>{ + const k = o.flags.bind; + const evl = o.getContext({ + position: o.position, + getText: k + }); + if (evl !== n.value) { + const ctx = o.getContext({ + position: o.position + }); + const values = Object.values(ctx); + const keys = Object.keys(ctx); + const fn = new Function(...keys, "n", `${k} = n.value;`); + fn.bind(oc.component.data)(...values, n); + OnodeUpdate(oc, k); + } + }); + n.addEventListener("keyup", (ev)=>{ + const k = o.flags.bind; + const evl = o.getContext({ + position: o.position, + getText: k + }); + if (evl !== n.value) { + const ctx = o.getContext({ + position: o.position + }); + const values = Object.values(ctx); + const keys = Object.keys(ctx); + const fn = new Function(...keys, "n", `${k} = n.value;`); + fn.bind(oc.component.data)(...values, n); + OnodeUpdate(oc, k); + } + }); + n.addEventListener("change", (ev)=>{ + const k = o.flags.bind; + const evl = o.getContext({ + position: o.position, + getText: k + }); + if (evl !== n.value) { + const ctx = o.getContext({ + position: o.position + }); + const values = Object.values(ctx); + const keys = Object.keys(ctx); + const fn = new Function(...keys, "n", `${k} = n.value;`); + fn.bind(oc.component.data)(...values, n); + OnodeUpdate(oc, k); + } + }); + oc.component.react.push((dependency)=>r(n, dependency) + ); + r(n, true); + } +} +function bindClass(Onode) { + const o = Onode, oc = Onode; + if (!o.flags || !o.flags.class || !oc || !o.nodes) return; + function r(n) { + const vl = o.getContext({ + position: o.position, + getText: o.flags.class + }); + if (typeof vl === "string") { + n.classList.value = vl; + } else if (typeof vl === "object") { + const keys = Object.keys(vl); + n.classList.add(...keys.filter((key)=>vl[key] + )); + n.classList.remove(...keys.filter((key)=>!vl[key] + )); + } else if (Array.isArray(vl)) { + n.classList.value = vl.join(" "); + } + return n.isConnected; + } + for (let node of o.nodes){ + oc.component.react.push(()=>r(node) + ); + r(node); + } +} +function bindHTML(Onode) { + const o = Onode, oc = Onode; + if (!o.flags || !o.flags.html || !oc || !o.nodes || o.isTemplate) return; + function r(n) { + const vl = o.getContext({ + position: o.position, + getText: o.flags.html + }); + if (typeof vl === "string") { + n.innerHTML = ''; + n.insertAdjacentHTML('beforeend', vl); + } + return n.isConnected; + } + for (let node of o.nodes){ + oc.component.react.push(()=>r(node) + ); + r(node); + } +} +function bindStyle(Onode) { + const o = Onode, oc = Onode; + if (!o.flags || !o.flags.style || !oc || !o.nodes) return; + function r(n) { + const vl = o.getContext({ + position: o.position, + getText: o.flags.style + }); + if (typeof vl === "string") { + Object.keys(n.style).forEach((key)=>{ + n.style[key] = vl[key]; + }); + } else if (typeof vl === "object") { + Object.entries(vl).forEach(([k, v])=>n.style[k] = v + ); + } + return n.isConnected; + } + for (let n of o.nodes){ + oc.component.react.push(()=>r(n) + ); + r(n); + } +} +function setContext(Onode) { + const o = Onode; + if (!o.key) return; + if (o.isTemplate) { + if (o.parentComponent) { + o.parent = o.parentComponent; + o.parent.childs.push(o); + } + if (Ogone.contexts[o.component.parentCTXId] && o.parentComponent) { + const gct = Ogone.contexts[o.component.parentCTXId].bind(o.parentComponent.data); + o.parentContext = gct; + o.getContext = gct; + } + } else if (Ogone.contexts[Onode.extending] && o && o.component) { + o.getContext = Ogone.contexts[Onode.extending].bind(o.component.data); + } + if (o.type === "store" && o.parent) { + o.namespace = Onode.getAttribute("namespace") || undefined; + o.parent.store[o.namespace] = o; + } +} +function displayError(message, errorType, errorObject) { + HMR.showHMRMessage(`\n ${message}\n ${errorType}\n ${errorObject && errorObject.message ? errorObject.message : ''}\n `); +} +function renderSlots(Onode) { + const o = Onode; + if (!o.nodes) return; + const slots = Array.from(Onode.querySelectorAll("[slot]")); + for (let node of o.nodes.filter((n)=>n.nodeType === 1 + )){ + const d = node.querySelector("slot:not([name])"); + if (d) { + d.replaceWith(...Array.from(Onode.childNodes)); + } + } + for (let slotted of slots){ + const sn = slotted.getAttribute("slot"); + for (let n of o.nodes){ + const s = n.querySelector(`slot[name="${sn}"]`); + if (s) { + slotted.removeAttribute("slot"); + s.replaceWith(slotted); + } + } + } +} +function renderNode(Onode) { + const o = Onode, oc = Onode; + if (!Onode) return; + if (o.isTemplate) { + OnodeUpdateProps(Onode); + if (o.isTemplatePrivate || o.isTemplateProtected) { + const shadow = Onode.attachShadow({ + mode: o.isTemplatePrivate ? 'closed' : 'open' + }); + shadow.append(...o.nodes); + } else { + if (Onode.childNodes.length) { + renderSlots(Onode); + } + if (o.type === "async") { + Onode.placeholder.replaceWith(...o.nodes, Onode.placeholder); + } else { + Onode.replaceWith(...o.nodes); + } + } + OnodeRenderTexts(Onode, true); + if (o.type !== "async") { + OnodeTriggerDefault(oc, { + router: { + params: o.params, + state: history.state, + path: location.pathname + } + }); + } + } else { + if (Onode.childNodes.length) { + renderSlots(Onode); + } + Onode.replaceWith(...o.nodes); + } +} +function renderStore(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + if (oc.namespace !== o.namespace) { + const error = "the attribute namespace is not the same provided in the component store"; + const BadNamspaceException = new Error(`[Ogone] ${error}`); + displayError(error, "Store Module: Bad Namsepace Exception", new Error(`\n store namespace: ${o.namespace}\n attribute namespace: ${oc.namespace}\n `)); + throw BadNamspaceException; + } + OnodeTriggerDefault(oc); + removeNodes(Onode); + Onode.remove(); +} +function renderRouter(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + OnodeUpdateProps(Onode); + if (!o.replacer) { + o.replacer = document.createElement('section'); + } + if (Onode.parentNode) { + Onode.replaceWith(o.replacer); + } + if (o.routeChanged) { + o.replacer.innerHTML = ""; + o.replacer.append(o.actualTemplate, o.actualTemplate.placeholder); + } + oc.component.runtime(`router:${o.actualRouteName || o.locationPath}`, history.state); +} +function renderAsyncRouter(Onode) { + const o = Onode; + if (!o.nodes) return; + const filter = (t)=>t.isComponent && t.isRouter + ; + const s = o.nodes.filter(filter); + for (let n of o.nodes.filter((n1)=>n1.nodeType === 1 + )){ + const arrayOfTemplates = Array.from(n.querySelectorAll(_ogone_node_)).filter(filter); + for (let template of arrayOfTemplates){ + s.push(template); + } + } + for (let t of s){ + t.connectedCallback(); + } +} +function renderAsyncStores(Onode) { + const o = Onode; + if (!o.nodes) return; + const filter = (t)=>t.isComponent && t.component && t.isStore + ; + const asyncStores = o.nodes.filter(filter); + for (let n of o.nodes.filter((n1)=>n1.nodeType === 1 + )){ + const arrayOfTemplates = Array.from(n.querySelectorAll(_ogone_node_)).filter(filter); + for (let template of arrayOfTemplates){ + asyncStores.push(template); + } + } + for (let t of asyncStores){ + t.connectedCallback(); + removeNodes(t); + t.remove(); + } +} +function renderAsyncComponent(Onode) { + const o = Onode, oc = Onode; + if (!oc || !o || !o.nodes) return; + const filter = (t)=>t.isComponent && t.isAsync && t.flags && t.flags.await + ; + for (let node of o.nodes.filter((n)=>n.nodeType === 1 + )){ + const awaitingNodes = Array.from(node.querySelectorAll(_ogone_node_)).filter(filter); + if (node.isComponent && node && node.component && node.component.type === "async") { + awaitingNodes.push(node); + } + for (let awaitingNode of awaitingNodes){ + if (awaitingNode.component) { + const ev = new CustomEvent(`${o.key}:${awaitingNode.key}:resolve`); + awaitingNode.component.dispatchAwait = ()=>{ + awaitingNode.dispatchEvent(ev); + }; + const promise = new Promise((resolve)=>{ + if (awaitingNode && awaitingNode.component.promiseResolved) { + resolve(true); + } else { + awaitingNode.addEventListener(`${o.key}:${awaitingNode.key}:resolve`, ()=>{ + resolve(true); + }); + } + }); + oc.component.promises.push(promise); + } + } + } +} +function renderComponent(Onode) { + const o = Onode; + if (!o.nodes) return; + const filter = (t)=>t.component && t.component.type === "component" + ; + for (let node of o.nodes.filter((n)=>n.nodeType === 1 + )){ + const components = Array.from(node.querySelectorAll(_ogone_node_)).filter(filter); + let n = node; + if (n.isComponent && n.extending && n.component && n.component.type === "component") { + components.push(n); + } + for (let onode of components){ + renderingProcess(onode); + } + } +} +function renderAsync(Onode, shouldReportToParentComponent) { + const o = Onode, oc = Onode; + if (!oc) return; + renderAsyncStores(Onode); + renderAsyncRouter(Onode); + renderComponent(Onode); + renderAsyncComponent(Onode); + const chs = Array.from(Onode.childNodes); + const placeholder = Onode.placeholder; + if (chs.length) { + } else if (!Onode.isTemplatePrivate && !Onode.isTemplateProtected) { + Onode.replaceWith(placeholder); + } + oc.component.resolve = (...args)=>{ + return new Promise((resolve)=>{ + setTimeout(()=>{ + setAsyncContext(Onode); + resolve(true); + }, 0); + }).then(()=>{ + Promise.all(oc.component.promises).then((p)=>{ + renderNode(Onode); + if (oc.async.then && shouldReportToParentComponent && oc.parent) { + oc.parent.runtime(oc.async.then, { + value: args, + await: p + }); + } + }).catch((err)=>{ + if (oc.async.catch && shouldReportToParentComponent && oc.parent) { + oc.parent.runtime(oc.async.catch, err); + } + displayError(err.message, `Error in Async component. component: ${o.name}`, err); + }).finally(()=>{ + if (oc.async.finally && shouldReportToParentComponent && oc.parent) { + oc.parent.runtime(oc.async.finally); + } + }); + }); + }; + OnodeTriggerDefault(oc, o.params, o.historyState); +} +function renderingProcess(Onode) { + const o = Onode; + setNodes(Onode); + if (o.isAsyncNode) { + setNodeAsyncContext(Onode); + } + if (o.isOriginalNode) setDeps(Onode); + if (!o.isTemplate && o.nodeProps) { + setNodeProps(Onode); + } + setEvents(Onode); + bindClass(Onode); + bindStyle(Onode); + bindValue(Onode); + bindHTML(Onode); + useSpread(Onode); + if (o.type === "router") { + triggerLoad(Onode); + } +} +function renderContext(Onode, force) { + const o = Onode, oc = Onode; + if (!force && (!oc || !o.getContext || !o.isOriginalNode)) return false; + if (!o.getContext) return false; + const length = o.getContext({ + getLength: true, + position: o.position + }); + OnodeListRendering(Onode, { + callingNewComponent: o.isTemplate, + length + }); + return true; +} +function triggerLoad(Onode) { + const o = Onode, oc = Onode; + if (!oc) return; + const rr = Ogone.routerReactions; + oc.component.runtime(0, o.historyState); + rr.push((path)=>{ + o.locationPath = path; + setActualRouterTemplate(Onode); + renderRouter(Onode); + return oc.component.activated; + }); +} +function setDeps(Onode) { + const o = Onode; + if (o.isOriginalNode && o.getContext && o.original) { + (o.isComponent && o.parentComponent ? o.parentComponent : o.component).react.push(()=>renderContext(o) + ); + renderContext(o); + } +} +function routerGo(url, state) { + if (Ogone.actualRoute === url) return; + Ogone.actualRoute = url; + Ogone.routerReactions.forEach((r, i, arr)=>{ + if (r && !r(url, state)) delete arr[i]; + }); + history.pushState(state || { + }, "", url || "/"); +} +function OnodeTriggerDefault(Onode, params, event) { + if (!Onode.component.activated) return; + if (Onode.type === "store") { + initStore(Onode); + } + OnodeUpdateProps(Onode); + Onode.component.runtime(0, params, event); +} +function OnodeUpdate(Onode, dependency) { + if (Onode.type === "store") { + OnodeUpdateStore(Onode, dependency); + return; + } + Onode.component.runtime(`update:${dependency}`); + OnodeReactions(Onode, dependency); + OnodeRenderTexts(Onode, dependency); + Onode.component.childs.filter((c)=>c.type !== "store" + ).forEach((c)=>{ + OnodeUpdateProps(c, dependency); + }); +} +function OnodeRenderTexts(Onode, dependency, opts = { +}) { + Onode.component.texts.forEach((t, i, arr)=>{ + const { code , position , dependencies , getContext } = t; + if (dependencies && !dependencies.includes(dependency)) return; + if (Onode.component.activated) { + if (!getContext) return delete arr[i]; + if (typeof dependency === 'string' && code.indexOf(dependency) < 0) return; + const v = getContext({ + getText: code, + position + }); + if (t.data !== v) t.data = v.length ? v : ' '; + } else { + delete arr[i]; + } + }); +} +function OnodeReactions(Onode, dependency) { + Onode.component.react.forEach((t, i, arr)=>{ + if (t && !t(dependency)) delete arr[i]; + }); +} +function initStore(Onode) { + if (!Ogone.stores[Onode.namespace]) { + Ogone.stores[Onode.namespace] = { + ...Onode.component.data + }; + } + Ogone.clients.push([ + Onode.key, + (namespace, key, overwrite)=>{ + const parent = Onode.parentComponent; + const { data } = Onode.component; + if (namespace === Onode.namespace && data && parent && parent.data) { + if (!overwrite) { + data[key] = Ogone.stores[Onode.namespace][key]; + } else { + Ogone.stores[Onode.namespace][key] = data[key]; + } + if (parent.data[key] !== data[key]) { + parent.data[key] = data[key]; + OnodeUpdate(parent, key); + } + } + return Onode.component.activated; + } + ]); +} +function OnodeUpdateStore(Onode, dependency) { + const [key, client] = Ogone.clients.find(([key1])=>key1 === Onode.key + ); + if (client) { + client(Onode.component.namespace, dependency, true); + Ogone.clients.filter(([key1])=>key1 !== Onode.key + ).forEach(([key1, f], i, arr)=>{ + if (f && !f(Onode.component.namespace, dependency, false)) { + delete arr[i]; + } + }); + } +} +function OnodeUpdateService(Onode, key, value, force) { + const { data } = Onode.component; + if (data && value !== data[key] || force && data) { + const previous = data[key]; + data[key] = value; + if (Onode.pluggedWebComponentIsSync) { + if (Onode.pluggedWebComponent && typeof Onode.pluggedWebComponent.beforeUpdate === 'function') { + Onode.pluggedWebComponent.beforeUpdate(key, data[key], value); + } + if (Onode.pluggedWebComponent && value !== Onode.pluggedWebComponent[key]) { + Onode.pluggedWebComponent[key] = value; + } + } + if (Onode.pluggedWebComponent && typeof Onode.pluggedWebComponent.attributeChangedCallback === 'function') { + Onode.pluggedWebComponent.attributeChangedCallback(key, previous, value); + } + OnodeUpdate(Onode, key); + if (Onode.type === "async") { + if (!Onode.dependencies) return; + if (key && Onode.dependencies.find((d)=>d.indexOf(key) > -1 + )) { + Onode.component.runtime("async:update", { + updatedParentProp: key + }); + } + } + } +} +function OnodeUpdateProps(Onode, dependency) { + if (!Onode.component.activated) return; + if (Onode.type === "store") return; + if (!Onode?.component?.requirements || !Onode.props) return; + Onode.component.requirements.forEach(([key])=>{ + const prop = Onode.props.find((prop1)=>prop1[0] === key + ); + if (!prop) return; + const value = Onode.parentContext({ + getText: `${prop[1]}`, + position: Onode.positionInParentComponent + }); + OnodeUpdateService(Onode, key, value, !!dependency); + }); +} +function OnodeDestroyPluggedWebcomponent(Onode) { + if (Onode.pluggedWebComponent && typeof Onode.pluggedWebComponent.beforeDestroy === 'function') { + Onode.pluggedWebComponent.beforeDestroy(); + } + if (Onode.pluggedWebComponent) { + Onode.pluggedWebComponent = false; + Onode.pluggedWebComponentIsSync = false; + } +} +function OnodeListRendering(Onode, opts) { + if (!Onode || !opts) return; + let { callingNewComponent , length: dataLength } = opts; + typeof dataLength === "object" ? dataLength = 1 : []; + const context = Onode.context; + if (!context) return; + if (context.list.length === dataLength) return; + for(let i = context.list.length, a = dataLength; i < a; i++){ + let node; + node = document.createElement(context.name, { + is: Onode.extending + }); + let ogoneOpts = { + type: Onode.type, + index: i, + isOriginalNode: false, + level: Onode.level, + placeholder: new Text(' '), + position: Onode.position.slice(), + flags: Onode.flags, + original: Onode, + isRoot: false, + name: Onode.name, + tree: Onode.tree, + namespace: Onode.namespace, + isTemplate: Onode.isTemplate, + isTemplatePrivate: Onode.isTemplatePrivate, + isTemplateProtected: Onode.isTemplateProtected, + isImported: Onode.isImported, + isAsync: Onode.isAsync, + isAsyncNode: Onode.isAsyncNode, + isRouter: Onode.isRouter, + isStore: Onode.isStore, + isRemote: Onode.isRemote, + extends: Onode.extends, + uuid: Onode.uuid, + routes: Onode.routes, + parentNodeKey: Onode.parentNodeKey + }; + Object.assign(ogoneOpts, !callingNewComponent ? { + component: Onode.component, + nodeProps: Onode.nodeProps + } : { + props: Onode.props, + dependencies: Onode.dependencies, + requirements: Onode.requirements, + params: Onode.params, + parentComponent: Onode.parentComponent, + parentCTXId: Onode.parentCTXId, + positionInParentComponent: Onode.positionInParentComponent ? Onode.positionInParentComponent.slice() : [], + levelInParentComponent: Onode.levelInParentComponent + }); + setOgone(node, ogoneOpts); + ogoneOpts = null; + Onode.placeholder.replaceWith(node, Onode.placeholder); + context.list.push(node); + } + if (context.list.length === dataLength) return; + for(let i1 = context.list.length, a1 = dataLength; i1 > a1; i1--){ + destroy(context.list.pop()); + } + return true; +} +const ogone_types_component = "component"; +const ogone_types_store = "store"; +const ogone_types_async = "async"; +const ogone_types_router = "router"; +const ogone_types_controller = "controller"; +const ___template_ = 'template'; +const ___style_ = 'style'; +const ___div_ = 'div'; +const ___img_ = 'img'; +const ___span_ = 'span'; +const ___slot_ = 'slot'; +const ___h2_ = 'h2'; +const ___p_ = 'p'; +const ___pre_ = 'pre'; +const ___code_ = 'code'; +const o3076301467 = 'o3076301467'; +const o3076301467_nt = 'o3076301467-nt'; +const o3076301467_n12 = 'o3076301467-n12'; +const o3076301467_n13 = 'o3076301467-n13'; +const o3076301467_nd14 = 'o3076301467-nd14'; +const o3076301467_nd17 = 'o3076301467-nd17'; +const o3076301467_t37 = 'o3076301467-t37'; +const o3076301467_n19 = 'o3076301467-n19'; +const o3076301467_n21 = 'o3076301467-n21'; +const o3076301467_n22 = 'o3076301467-n22'; +const o3076301467_nd23 = 'o3076301467-nd23'; +const o4032646903 = 'o4032646903'; +const o4032646903_nt = 'o4032646903-nt'; +const o4032646903_n3 = 'o4032646903-n3'; +const o4032646903_t7 = 'o4032646903-t7'; +const o4032646903_n5 = 'o4032646903-n5'; +const o4032646903_t12 = 'o4032646903-t12'; +const o1384895395 = 'o1384895395'; +const o1384895395_nt = 'o1384895395-nt'; +const o1384895395_n3 = 'o1384895395-n3'; +const o1384895395_t8 = 'o1384895395-t8'; +const o1384895395_n5 = 'o1384895395-n5'; +const o1384895395_nd6 = 'o1384895395-nd6'; +const o2465295184 = 'o2465295184'; +const o2465295184_nt = 'o2465295184-nt'; +const o2465295184_n5 = 'o2465295184-n5'; +const o2465295184_n6 = 'o2465295184-n6'; +const o2465295184_nd7 = 'o2465295184-nd7'; +const o2465295184_n9 = 'o2465295184-n9'; +const o2465295184_n10 = 'o2465295184-n10'; +const o3104095500 = 'o3104095500'; +const o3104095500_nt = 'o3104095500-nt'; +const o3104095500_n5 = 'o3104095500-n5'; +const o3104095500_nd6 = 'o3104095500-nd6'; +const o3104095500_nd7 = 'o3104095500-nd7'; +const o3104095500_n9 = 'o3104095500-n9'; +const o3104095500_n11 = 'o3104095500-n11'; +const o1710946592 = 'o1710946592'; +const o1710946592_nt = 'o1710946592-nt'; +const o1710946592_t3 = 'o1710946592-t3'; +const o1710946592_2 = 'o1710946592-2'; +const o1710946592_t6 = 'o1710946592-t6'; +const o2010234397 = 'o2010234397'; +const o2010234397_nt = 'o2010234397-nt'; +const o2010234397_2 = 'o2010234397-2'; +const o2010234397_t5 = 'o2010234397-t5'; +const o2010234397_n3 = 'o2010234397-n3'; +const o2010234397_t8 = 'o2010234397-t8'; +const o2010234397_t11 = 'o2010234397-t11'; +const o2384155165 = 'o2384155165'; +const o2384155165_nt = 'o2384155165-nt'; +const o2384155165_nd5 = 'o2384155165-nd5'; +const o2384155165_t13 = 'o2384155165-t13'; +const o2384155165_nd6 = 'o2384155165-nd6'; +const o2384155165_nd8 = 'o2384155165-nd8'; +const o2384155165_nd10 = 'o2384155165-nd10'; +const o325165413 = 'o325165413'; +const o325165413_nt = 'o325165413-nt'; +const o325165413_n5 = 'o325165413-n5'; +const o325165413_nd6 = 'o325165413-nd6'; +const o325165413_n7 = 'o325165413-n7'; +const o325165413_nd8 = 'o325165413-nd8'; +const o325165413_n10 = 'o325165413-n10'; +const o325165413_t23 = 'o325165413-t23'; +const o325165413_n13 = 'o325165413-n13'; +const o325165413_nd14 = 'o325165413-nd14'; +const o325165413_nd17 = 'o325165413-nd17'; +const o1561345583 = 'o1561345583'; +const o1561345583_nt = 'o1561345583-nt'; +const o1561345583_n5 = 'o1561345583-n5'; +const o1561345583_nd6 = 'o1561345583-nd6'; +const o1561345583_n7 = 'o1561345583-n7'; +const o1561345583_t17 = 'o1561345583-t17'; +const o1561345583_nd9 = 'o1561345583-nd9'; +const o1561345583_t22 = 'o1561345583-t22'; +const o1561345583_nd11 = 'o1561345583-nd11'; +const o1561345583_t27 = 'o1561345583-t27'; +const o1561345583_nd13 = 'o1561345583-nd13'; +const o1561345583_t32 = 'o1561345583-t32'; +const o1561345583_nd16 = 'o1561345583-nd16'; +const o1561345583_n17 = 'o1561345583-n17'; +const o1561345583_nd18 = 'o1561345583-nd18'; +const o3474491051 = 'o3474491051'; +const o3474491051_nt = 'o3474491051-nt'; +const o3474491051_n5 = 'o3474491051-n5'; +const o3474491051_n6 = 'o3474491051-n6'; +const o3474491051_n7 = 'o3474491051-n7'; +const o3474491051_n8 = 'o3474491051-n8'; +const o1145023862 = 'o1145023862'; +const o1145023862_nt = 'o1145023862-nt'; +const o1145023862_n3 = 'o1145023862-n3'; +const o1145023862_t7 = 'o1145023862-t7'; +const o1145023862_n5 = 'o1145023862-n5'; +const o1145023862_n6 = 'o1145023862-n6'; +const o2443722130 = 'o2443722130'; +const o2443722130_nt = 'o2443722130-nt'; +const o2443722130_t3 = 'o2443722130-t3'; +const o2443722130_2 = 'o2443722130-2'; +const o2443722130_t6 = 'o2443722130-t6'; +const o171290282 = 'o171290282'; +const o171290282_nt = 'o171290282-nt'; +const o171290282_n5 = 'o171290282-n5'; +const o171290282_nd6 = 'o171290282-nd6'; +const o1517538778 = 'o1517538778'; +const o1517538778_nt = 'o1517538778-nt'; +const o1517538778_n5 = 'o1517538778-n5'; +const o1517538778_n6 = 'o1517538778-n6'; +const o1517538778_n7 = 'o1517538778-n7'; +const o1517538778_t16 = 'o1517538778-t16'; +const o1517538778_n9 = 'o1517538778-n9'; +const o1517538778_t21 = 'o1517538778-t21'; +const o1517538778_nd12 = 'o1517538778-nd12'; +const o1517538778_nd13 = 'o1517538778-nd13'; +const o1517538778_t30 = 'o1517538778-t30'; +const o1517538778_n15 = 'o1517538778-n15'; +const o1517538778_n16 = 'o1517538778-n16'; +const o1517538778_t37 = 'o1517538778-t37'; +const o3725575239 = 'o3725575239'; +const o3725575239_nt = 'o3725575239-nt'; +const o3725575239_n3 = 'o3725575239-n3'; +const o3725575239_t8 = 'o3725575239-t8'; +const o3725575239_n5 = 'o3725575239-n5'; +const o3725575239_n6 = 'o3725575239-n6'; +const o3725575239_n7 = 'o3725575239-n7'; +const o3725575239_n9 = 'o3725575239-n9'; +const o3725575239_t21 = 'o3725575239-t21'; +Ogone.types[o3076301467_nd17] = ogone_types_component; +Ogone.types[o3076301467_nt] = ogone_types_component; +Ogone.types[o4032646903_nt] = ogone_types_component; +Ogone.types[o1384895395_nd6] = ogone_types_async; +Ogone.types[o1384895395_nt] = ogone_types_async; +Ogone.types[o2465295184_nt] = ogone_types_component; +Ogone.types[o3104095500_nd7] = ogone_types_component; +Ogone.types[o3104095500_nd6] = ogone_types_component; +Ogone.types[o3104095500_nt] = ogone_types_component; +Ogone.types[o1710946592_nt] = ogone_types_store; +Ogone.types[o2010234397_nt] = ogone_types_controller; +Ogone.types[o2384155165_nd6] = ogone_types_component; +Ogone.types[o2384155165_nd8] = ogone_types_component; +Ogone.types[o2384155165_nd10] = ogone_types_component; +Ogone.types[o2384155165_nd5] = ogone_types_component; +Ogone.types[o2384155165_nt] = ogone_types_component; +Ogone.types[o325165413_nd6] = ogone_types_component; +Ogone.types[o325165413_nd17] = ogone_types_component; +Ogone.types[o325165413_nt] = ogone_types_component; +Ogone.types[o1561345583_nd9] = ogone_types_component; +Ogone.types[o1561345583_nd11] = ogone_types_component; +Ogone.types[o1561345583_nd13] = ogone_types_component; +Ogone.types[o1561345583_nd6] = ogone_types_component; +Ogone.types[o1561345583_nd16] = ogone_types_component; +Ogone.types[o1561345583_nt] = ogone_types_component; +Ogone.types[o3474491051_nt] = ogone_types_component; +Ogone.types[o1145023862_nt] = ogone_types_component; +Ogone.types[o2443722130_nt] = ogone_types_router; +Ogone.types[o171290282_nt] = ogone_types_component; +Ogone.types[o1517538778_nd13] = ogone_types_component; +Ogone.types[o1517538778_nd12] = ogone_types_component; +Ogone.types[o1517538778_nt] = ogone_types_component; +Ogone.types[o3725575239_nt] = ogone_types_component; +Ogone.components[o3076301467] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o3076301467] = Ogone.protocols[o3076301467] || class Protocol { + test = Obj; + scrollY = 0; + setScrollY(n) { + this.scrollY = n; + } + }; + const data = setReactivity(new Ogone.protocols[o3076301467], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![].includes(_state)) { + return; + } + switch(_state){ + default: + const [header] = Refs.head; + this.setScrollY(window.scrollY); + window.addEventListener('scroll', (ev)=>{ + if (header) { + if (window.scrollY > this.scrollY) { + header.style.top = '-100px'; + } else { + header.style.top = '0px'; + } + } + this.setScrollY(window.scrollY); + }); + break; + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/Application.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o4032646903] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + "scrollY": 0 + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/RightSection.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o1384895395] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + const Async = { + resolve: (...args)=>{ + if (Onode.component.resolve) { + const promise = Onode.component.resolve(...args); + if (Onode.component.dispatchAwait) { + Onode.component.dispatchAwait(); + Onode.component.dispatchAwait = false; + Onode.component.promiseResolved = true; + } + Onode.component.resolve = null; + return promise; + } else if (Onode.component.resolve === null) { + const DoubleUseOfResolveException = new Error('Double use of resolution in async component'); + displayError(DoubleUseOfResolveException.message, 'Double Resolution of Promise', { + message: `component: examples/app/asyncs/AsyncLogo.o3` + }); + throw DoubleUseOfResolveException; + } + } + }; + Object.freeze(Async); + const data = { + }; + return { + data, + Refs, + runtime: (async function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![].includes(_state)) { + return; + } + switch(_state){ + default: + Async.resolve(); + break; + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/asyncs/AsyncLogo.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o2465295184] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + "menu": [ + { + "name": "Docs", + "route": "/doc", + "status": "in-progress" + }, + { + "name": "Api", + "route": "/api", + "status": "todo" + }, + { + "name": "todos", + "route": "/todos/testParams", + "status": "todo" + }, + { + "name": "project", + "route": "/project", + "status": "todo" + }, + { + "name": "support", + "route": "/support", + "status": "todo" + } + ] + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/menu/MenuContent.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o3104095500] = function(Onode) { + let Controllers; + const Store = { + dispatch: (id, ctx)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, action] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.runtime) { + return mod.runtime(`action:${action}`, ctx).catch((err)=>displayError(err.message, `Error in dispatch. action: ${action} component: examples/app/components/Burger.o3`, err) + ); + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.runtime) { + return mod.runtime(`action:${id}`, ctx).catch((err)=>displayError(err.message, `Error in dispatch. action: ${action} component: examples/app/components/Burger.o3`, err) + ); + } + } + }, + commit: (id, ctx)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, mutation] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.runtime) { + return mod.runtime(`mutation:${mutation}`, ctx).catch((err)=>displayError(err.message, `Error in commit. mutation: ${mutation} component: examples/app/components/Burger.o3`, err) + ); + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.runtime) { + return mod.runtime(`mutation:${id}`, ctx).catch((err)=>displayError(err.message, `Error in commit. mutation: ${id} component: examples/app/components/Burger.o3`, err) + ); + } + } + }, + get: (id)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, get] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.data) { + return mod.data[get]; + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.data) { + return mod.data[id]; + } + } + } + }; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o3104095500] = Ogone.protocols[o3104095500] || class Protocol { + isOpen = false; + }; + const data = setReactivity(new Ogone.protocols[o3104095500], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![ + 'click:openMenu' + ].includes(_state)) { + return; + } + switch(_state){ + case 'click:openMenu': + print(10, 'this is a test for modules'); + Store.dispatch('menu/toggle'); + Store.dispatch('menu/checkController').then((res)=>{ + console.warn(res); + }); + break; + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/Burger.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o1710946592] = function(Onode) { + const Controllers = { + }; + Controllers["UserController"] = { + async get (rte) { + return await (await (await fetch(`test${rte}`)).blob()).text(); + }, + async post (rte, data = { + }, op = { + }) { + return await (await (await fetch(`test${rte}`, { + ...op, + body: JSON.stringify(data || { + }), + method: 'POST' + })).blob()).text(); + }, + async put (rte, data = { + }, op = { + }) { + return await (await (await fetch(`test${rte}`, { + ...op, + body: JSON.stringify(data || { + }), + method: 'PUT' + })).blob()).text(); + }, + async delete (rte, data = { + }, op = { + }) { + return await (await (await fetch(`test${rte}`, { + ...op, + body: JSON.stringify(data || { + }), + method: 'DELETE' + })).blob()).text(); + }, + async patch (rte, data = { + }, op = { + }) { + return await (await (await fetch(`test${rte}`, { + ...op, + body: JSON.stringify(data || { + }), + method: 'PATCH' + })).blob()).text(); + } + }; + Object.seal(Controllers); + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o1710946592] = Ogone.protocols[o1710946592] || class Protocol { + isOpen = false; + }; + const data = setReactivity(new Ogone.protocols[o1710946592], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (async function runtime(_state, ctx, event, _once = 0) { + try { + const { UserController } = Controllers; + if (typeof _state === "string" && ![ + 'action:toggle', + 'action:checkController' + ].includes(_state)) { + return; + } + switch(_state){ + case 'action:toggle': + this.isOpen = !this.isOpen; + break; + case 'action:checkController': + const res = await UserController.get('/'); + return res; + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/stores/StoreMenu.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o2010234397] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o2010234397] = Ogone.protocols[o2010234397] || class Protocol { + name = "SRNV"; + }; + const data = setReactivity(new Ogone.protocols[o2010234397], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (async function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![ + 'GET:/', + 'GET:/2' + ].includes(_state)) { + return; + } + switch(_state){ + case 'GET:/': + return `Hello ${this.name}`; + case 'GET:/2': + return '

    test

    '; + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/controllers/ControllerUser.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o2384155165] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o2384155165] = Ogone.protocols[o2384155165] || class Protocol { + buttonOpts = { + name: 'Test', + route: '', + status: 'todo' + }; + }; + const data = setReactivity(new Ogone.protocols[o2384155165], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/menu/MenuButton.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o325165413] = function(Onode) { + let Controllers; + const Store = { + dispatch: (id, ctx)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, action] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.runtime) { + return mod.runtime(`action:${action}`, ctx).catch((err)=>displayError(err.message, `Error in dispatch. action: ${action} component: examples/app/components/menu/MenuMain.o3`, err) + ); + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.runtime) { + return mod.runtime(`action:${id}`, ctx).catch((err)=>displayError(err.message, `Error in dispatch. action: ${action} component: examples/app/components/menu/MenuMain.o3`, err) + ); + } + } + }, + commit: (id, ctx)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, mutation] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.runtime) { + return mod.runtime(`mutation:${mutation}`, ctx).catch((err)=>displayError(err.message, `Error in commit. mutation: ${mutation} component: examples/app/components/menu/MenuMain.o3`, err) + ); + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.runtime) { + return mod.runtime(`mutation:${id}`, ctx).catch((err)=>displayError(err.message, `Error in commit. mutation: ${id} component: examples/app/components/menu/MenuMain.o3`, err) + ); + } + } + }, + get: (id)=>{ + const path = id.split('/'); + if (path.length > 1) { + const [namespace, get] = path; + const mod = Onode.component.store[namespace]; + if (mod && mod.data) { + return mod.data[get]; + } + } else { + const mod = Onode.component.store[null]; + if (mod && mod.data) { + return mod.data[id]; + } + } + } + }; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + "menu": [ + { + "name": "Introduction", + "route": "/intro" + }, + { + "name": "Ogone theory", + "route": "/theory" + }, + { + "name": "Documentation", + "route": "/doc", + "children": [ + { + "name": "Install", + "route": "/doc/install" + }, + { + "name": "Get Started", + "route": "/doc/get-started" + }, + { + "name": "Flags", + "route": "/flags", + "children": [ + { + "name": "--if --else --else-if", + "status": "ok" + }, + { + "name": "--for", + "status": "ok" + }, + { + "name": "--await --defer", + "status": "ok" + }, + { + "name": "--then:...", + "status": "ok" + }, + { + "name": "--catch:...", + "status": "ok" + }, + { + "name": "--finally:...", + "status": "ok" + }, + { + "name": "--class --style", + "status": "ok" + }, + { + "name": "--anim", + "status": "todo" + }, + { + "name": "--router-go", + "status": "ok" + }, + { + "name": "--:..", + "status": "ok" + }, + { + "name": "--drag:...", + "status": "todo" + }, + { + "name": "--dragstart:...", + "status": "todo" + }, + { + "name": "--dragend:...", + "status": "todo" + }, + { + "name": "--event:animationstart:...", + "status": "ok" + }, + { + "name": "--event:animationend:...", + "status": "ok" + }, + { + "name": "--spread", + "status": "ok" + } + ] + }, + { + "name": "Components", + "route": "/doc/components", + "status": "ok", + "children": [ + { + "name": "Components Anatomy", + "route": "/doc/components/components-anatomy" + }, + { + "name": "Counter", + "route": "/doc/components/counter" + }, + { + "name": "Greeting App", + "route": "/doc/components/cgc" + }, + { + "name": "Recursive Tree Button", + "route": "/doc/components/rtb" + } + ] + }, + { + "name": "Async Components", + "status": "ok", + "route": "/doc/async-components" + }, + { + "name": "Router", + "route": "/doc/router", + "status": "in-progress", + "children": [ + { + "name": "Router anatomy", + "route": "/doc/router/router-anatomy" + } + ] + }, + { + "name": "Store", + "status": "in-progress", + "route": "/doc/store", + "children": [ + { + "name": "Store anatomy", + "route": "/doc/store/store-anatomy" + } + ] + }, + { + "name": "Controllers", + "status": "in-progress", + "route": "/doc/controllers", + "children": [ + { + "name": "Controllers anatomy", + "route": "/doc/controllers/controllers-anatomy" + } + ] + }, + { + "name": "Api", + "route": "/api", + "children": [ + { + "name": "Refs", + "status": "in-progress" + }, + { + "name": "Store", + "status": "in-progress" + }, + { + "name": "Async", + "status": "in-progress" + }, + { + "name": "Tests Cases", + "status": "todo" + } + ] + } + ] + }, + { + "name": "Project", + "route": "/project" + }, + { + "name": "Todos", + "route": "/todos" + }, + { + "name": "Support", + "route": "/support" + } + ] + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![ + 'click:toggle-menu' + ].includes(_state)) { + return; + } + switch(_state){ + case 'click:toggle-menu': + Store.dispatch('menu/toggle'); + break; + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/menu/MenuMain.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o1561345583] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o1561345583] = Ogone.protocols[o1561345583] || class Protocol { + openTree = false; + inp = this.openTree ? 'open' : 'closed'; + item = { + name: 'no name', + route: '', + status: 'todo', + children: [] + }; + }; + const data = setReactivity(new Ogone.protocols[o1561345583], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + if (typeof _state === "string" && ![ + 'click:toggle' + ].includes(_state)) { + return; + } + switch(_state){ + case 'click:toggle': + this.openTree = !this.openTree; + this.inp = this.openTree ? 'open' : 'closed'; + break; + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/menu/TreeRecursiveButton.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o3474491051] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/Scroll.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o1145023862] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/Logo.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o2443722130] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/routers/Router.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o171290282] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + "articles": [ + { + "title": "Experimental tool for a fullstack use.", + "text": "Ogone for Front-end fields using Deno. Designed differently, start creating differently.\nEverything is a component because everything is a part of the composition.\nActually Ogone is too young to be used for production, expect breaking chnages until the 1.0.0.\nOgone has it own extension *.o3 which allow some new features.\n", + "code": null + }, + { + "title": "Install Ogone", + "text": "install ogone by using the command: deno install\nDeno will print the next instruction that you will need to follow to use Ogone\n", + "code": "deno install -Afq --unstable https://deno.land/x/ogone@0.28.0/cli/ogone.ts\n" + }, + { + "title": "Start the development of your application", + "text": "keeping ogone minimalist is one of it's main goal.\nto run the server of development use the command:\n\n ogone run ...\n", + "code": "ogone run path/to/Application.o3\n", + "page": "terminal" + } + ] + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/pages/Body.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o1517538778] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + Ogone.protocols[o1517538778] = Ogone.protocols[o1517538778] || class Protocol { + title = 'untitled'; + text = 'no text'; + code = "..."; + page = ""; + }; + const data = setReactivity(new Ogone.protocols[o1517538778], (prop)=>OnodeUpdate(Onode, prop) + ); + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/ContentPage.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.components[o3725575239] = function(Onode) { + let Controllers; + let Store; + const ___ = (prop, inst, value)=>{ + OnodeUpdate(Onode, prop); + return value; + }; + const ____r = (name, use, once)=>{ + Onode.component.runtime(name, use[0], use[1], once); + }; + const Refs = { + }; + let Async; + const data = { + }; + return { + data, + Refs, + runtime: (function runtime(_state, ctx, event, _once = 0) { + try { + switch(_state){ + default: + } + } catch (err) { + displayError('Error in the component: \n\t examples/app/components/404.o3', err.message, err); + throw err; + } + }).bind(data) + }; +}; +Ogone.contexts[o3725575239_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/404.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3725575239_n5] = Ogone.contexts[o3725575239_nt]; +Ogone.contexts[o3725575239_n9] = Ogone.contexts[o3725575239_n5]; +Ogone.contexts[o3725575239_t21] = Ogone.contexts[o3725575239_n9]; +Ogone.contexts[o3725575239_n6] = Ogone.contexts[o3725575239_n5]; +Ogone.contexts[o3725575239_n7] = Ogone.contexts[o3725575239_n6]; +Ogone.contexts[o3725575239_n3] = Ogone.contexts[o3725575239_nt]; +Ogone.contexts[o3725575239_t8] = Ogone.contexts[o3725575239_n3]; +Ogone.contexts[o1517538778_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/ContentPage.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1517538778_n5] = Ogone.contexts[o1517538778_nt]; +Ogone.contexts[o1517538778_nd12] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !this.code) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/ContentPage.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1517538778_n15] = Ogone.contexts[o1517538778_nd12]; +Ogone.contexts[o1517538778_n16] = Ogone.contexts[o1517538778_n15]; +Ogone.contexts[o1517538778_t37] = Ogone.contexts[o1517538778_n16]; +Ogone.contexts[o1517538778_nd13] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !this.page) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/ContentPage.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1517538778_t30] = Ogone.contexts[o1517538778_nd13]; +Ogone.contexts[o1517538778_n6] = Ogone.contexts[o1517538778_n5]; +Ogone.contexts[o1517538778_n9] = Ogone.contexts[o1517538778_n6]; +Ogone.contexts[o1517538778_t21] = Ogone.contexts[o1517538778_n9]; +Ogone.contexts[o1517538778_n7] = Ogone.contexts[o1517538778_n6]; +Ogone.contexts[o1517538778_t16] = Ogone.contexts[o1517538778_n7]; +Ogone.contexts[o171290282_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/pages/Body.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o171290282_n5] = Ogone.contexts[o171290282_nt]; +Ogone.contexts[o171290282_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + const _____a_7 = Ogone.arrays[o171290282_nd6] || !!this.articles && this.articles || []; + let i6 = POSITION[2], article = _____a_7[i6]; + if (Ogone.arrays[o171290282_nd6] !== _____a_7) Ogone.arrays[o171290282_nd6] = _____a_7; + if (GET_LENGTH) { + if (!_____a_7) { + return 0; + } + return _____a_7.length; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + i6, + article + }; + } catch (err) { + if (typeof article === 'undefined' || !article) { + return undefined; + } + displayError('Error in component:\n\t examples/app/pages/Body.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2443722130_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/routers/Router.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2443722130_t6] = Ogone.contexts[o2443722130_2]; +Ogone.contexts[o2443722130_t3] = Ogone.contexts[o2443722130_nt]; +Ogone.contexts[o2443722130_2] = Ogone.contexts[o2443722130_nt]; +Ogone.contexts[o1145023862_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/Logo.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1145023862_n5] = Ogone.contexts[o1145023862_nt]; +Ogone.contexts[o1145023862_n6] = Ogone.contexts[o1145023862_n5]; +Ogone.contexts[o1145023862_n3] = Ogone.contexts[o1145023862_nt]; +Ogone.contexts[o1145023862_t7] = Ogone.contexts[o1145023862_n3]; +Ogone.contexts[o3474491051_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/Scroll.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3474491051_n5] = Ogone.contexts[o3474491051_nt]; +Ogone.contexts[o3474491051_n6] = Ogone.contexts[o3474491051_n5]; +Ogone.contexts[o3474491051_n7] = Ogone.contexts[o3474491051_n6]; +Ogone.contexts[o3474491051_n8] = Ogone.contexts[o3474491051_n7]; +Ogone.contexts[o1561345583_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_n5] = Ogone.contexts[o1561345583_nt]; +Ogone.contexts[o1561345583_nd16] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !this.item.children) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_n17] = Ogone.contexts[o1561345583_nd16]; +Ogone.contexts[o1561345583_nd18] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + const _____a_5 = !!this.item && this.item.children || []; + let i4 = POSITION[4], child = _____a_5[i4]; + if (GET_LENGTH) { + if (!_____a_5) { + return 0; + } + return _____a_5.length; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + i4, + child + }; + } catch (err) { + if (typeof child === 'undefined' || !child) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_nd13] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && this.item.children && !this.openTree) { + return 0; + } else if (GET_LENGTH && !(this.item.children && this.openTree)) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_t32] = Ogone.contexts[o1561345583_nd13]; +Ogone.contexts[o1561345583_nd11] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !(this.item.children && !this.openTree)) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_t27] = Ogone.contexts[o1561345583_nd11]; +Ogone.contexts[o1561345583_nd9] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/TreeRecursiveButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1561345583_t22] = Ogone.contexts[o1561345583_nd9]; +Ogone.contexts[o1561345583_n7] = Ogone.contexts[o1561345583_nd6]; +Ogone.contexts[o1561345583_t17] = Ogone.contexts[o1561345583_n7]; +Ogone.contexts[o325165413_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuMain.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o325165413_nd17] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuMain.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o325165413_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuMain.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o325165413_n13] = Ogone.contexts[o325165413_nd6]; +Ogone.contexts[o325165413_nd14] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + const _____a_3 = Ogone.arrays[o325165413_nd14] || !!this.menu && this.menu || []; + let i2 = POSITION[3], item = _____a_3[i2]; + if (Ogone.arrays[o325165413_nd14] !== _____a_3) Ogone.arrays[o325165413_nd14] = _____a_3; + if (GET_LENGTH) { + if (!_____a_3) { + return 0; + } + return _____a_3.length; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + i2, + item + }; + } catch (err) { + if (typeof item === 'undefined' || !item) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuMain.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o325165413_n7] = Ogone.contexts[o325165413_nd6]; +Ogone.contexts[o325165413_n10] = Ogone.contexts[o325165413_n7]; +Ogone.contexts[o325165413_t23] = Ogone.contexts[o325165413_n10]; +Ogone.contexts[o325165413_nd8] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuMain.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o325165413_n5] = Ogone.contexts[o325165413_nt]; +Ogone.contexts[o2384155165_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2384155165_nd5] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2384155165_nd10] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !(this.buttonOpts.status === 'in-progress')) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2384155165_nd8] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !(this.buttonOpts.status === 'todo')) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2384155165_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH && !(this.buttonOpts.status === 'ok')) { + return 0; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuButton.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2384155165_t13] = Ogone.contexts[o2384155165_nd5]; +Ogone.contexts[o2010234397_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/controllers/ControllerUser.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2010234397_t11] = Ogone.contexts[o2010234397_2]; +Ogone.contexts[o2010234397_n3] = Ogone.contexts[o2010234397_2]; +Ogone.contexts[o2010234397_t8] = Ogone.contexts[o2010234397_n3]; +Ogone.contexts[o2010234397_t5] = Ogone.contexts[o2010234397_2]; +Ogone.contexts[o2010234397_2] = Ogone.contexts[o2010234397_nt]; +Ogone.contexts[o1710946592_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/stores/StoreMenu.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1710946592_t6] = Ogone.contexts[o1710946592_2]; +Ogone.contexts[o1710946592_t3] = Ogone.contexts[o1710946592_nt]; +Ogone.contexts[o1710946592_2] = Ogone.contexts[o1710946592_nt]; +Ogone.contexts[o3104095500_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/Burger.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3104095500_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/Burger.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3104095500_n11] = Ogone.contexts[o3104095500_nd6]; +Ogone.contexts[o3104095500_n9] = Ogone.contexts[o3104095500_nd6]; +Ogone.contexts[o3104095500_nd7] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + if (GET_LENGTH) { + return 1; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/Burger.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3104095500_n5] = Ogone.contexts[o3104095500_nt]; +Ogone.contexts[o2465295184_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuContent.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o2465295184_n5] = Ogone.contexts[o2465295184_nt]; +Ogone.contexts[o2465295184_n9] = Ogone.contexts[o2465295184_n5]; +Ogone.contexts[o2465295184_n10] = Ogone.contexts[o2465295184_n9]; +Ogone.contexts[o2465295184_n6] = Ogone.contexts[o2465295184_n5]; +Ogone.contexts[o2465295184_nd7] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + const _____a_1 = Ogone.arrays[o2465295184_nd7] || !!this.menu && this.menu || []; + let i0 = POSITION[3], t = _____a_1[i0]; + if (Ogone.arrays[o2465295184_nd7] !== _____a_1) Ogone.arrays[o2465295184_nd7] = _____a_1; + if (GET_LENGTH) { + if (!_____a_1) { + return 0; + } + return _____a_1.length; + } + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + i0, + t + }; + } catch (err) { + if (typeof t === 'undefined' || !t) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/menu/MenuContent.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1384895395_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/asyncs/AsyncLogo.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1384895395_n5] = Ogone.contexts[o1384895395_nt]; +Ogone.contexts[o1384895395_nd6] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/asyncs/AsyncLogo.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o1384895395_n3] = Ogone.contexts[o1384895395_nt]; +Ogone.contexts[o1384895395_t8] = Ogone.contexts[o1384895395_n3]; +Ogone.contexts[o4032646903_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/components/RightSection.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o4032646903_n5] = Ogone.contexts[o4032646903_nt]; +Ogone.contexts[o4032646903_t12] = Ogone.contexts[o4032646903_n5]; +Ogone.contexts[o4032646903_n3] = Ogone.contexts[o4032646903_nt]; +Ogone.contexts[o4032646903_t7] = Ogone.contexts[o4032646903_n3]; +Ogone.contexts[o3076301467_nt] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/Application.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3076301467_nd23] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/Application.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3076301467_n22] = Ogone.contexts[o3076301467_nt]; +Ogone.contexts[o3076301467_n21] = Ogone.contexts[o3076301467_nt]; +Ogone.contexts[o3076301467_n12] = Ogone.contexts[o3076301467_nt]; +Ogone.contexts[o3076301467_n19] = Ogone.contexts[o3076301467_n12]; +Ogone.contexts[o3076301467_nd17] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/Application.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.contexts[o3076301467_t37] = Ogone.contexts[o3076301467_nd17]; +Ogone.contexts[o3076301467_n13] = Ogone.contexts[o3076301467_n12]; +Ogone.contexts[o3076301467_nd14] = function(opts) { + const GET_TEXT = opts.getText; + const GET_LENGTH = opts.getLength; + const POSITION = opts.position; + try { + if (GET_TEXT) { + return eval('(' + GET_TEXT + ')'); + } + return { + }; + } catch (err) { + if (typeof undefined === 'undefined' || !undefined) { + return undefined; + } + displayError('Error in component:\n\t examples/app/Application.o3 ' + `${GET_TEXT}`, err.message, err); + throw err; + } +}; +Ogone.render[o3076301467_nd17] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd17 = _h(___div_), t37 = `Dev`; + _at(nd17, o3076301467, ''); + _at(nd17, 'class', 'open-dev-tool'); + _ap(nd17, t37); + return nd17; +}; +Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n12 = _h(___div_), n13 = _h(___div_), nd14 = _h(_ogone_node_), nd17 = _h(_ogone_node_), t37 = `Dev`, n19 = _h(_ogone_node_), n21 = _h(_ogone_node_), n22 = _h(_ogone_node_), nd23 = _h(_ogone_node_); + _at(nt, o3076301467, ''); + l++; + _at(n12, o3076301467, ''); + ctx.refs['head'] = ctx.refs['head'] || []; + ctx.refs['head'][i] = n12; + _at(n12, 'class', 'header'); + l++; + _at(n13, o3076301467, ''); + _at(n13, 'class', 'logo'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd14, + placeholder: new Text(' '), + name: "AsyncLogoEl", + tree: "null>div>div>AsyncLogoEl", + flags: { + "events": [ + { + "type": "click", + "name": "router-go", + "eval": "'/'" + } + ], + "else": false + }, + isTemplate: true, + isTemplatePrivate: true, + isTemplateProtected: false, + isAsync: true, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3076301467', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3076301467-nd14', + props: [], + uuid: 'o1384895395', + routes: null, + namespace: '', + requirements: [], + dependencies: [] + }; + nd14.placeholder = o.placeholder; + setOgone(nd14, o); + o = null; + _at(nd14, o3076301467, ''); + l--; + _ap(n13, nd14); + o = { + isRoot: false, + isOriginalNode: true, + original: nd17, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [ + { + "type": "click", + "name": "router-dev-tool", + "eval": true + } + ], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd17', + uuid: 'o3076301467' + }; + nd17.placeholder = o.placeholder; + setOgone(nd17, o); + o = null; + _at(nd17, o3076301467, ''); + _ap(nd17, t37); + o = { + isRoot: false, + isOriginalNode: true, + original: n19, + placeholder: new Text(' '), + name: "MenuContent", + tree: "null>div>MenuContent", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3076301467', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3076301467-n19', + props: [], + uuid: 'o2465295184', + routes: null, + namespace: '', + requirements: [], + dependencies: [] + }; + n19.placeholder = o.placeholder; + setOgone(n19, o); + o = null; + _at(n19, o3076301467, ''); + l--; + _ap(n12, n13); + _ap(n12, nd17); + _ap(n12, n19); + o = { + isRoot: false, + isOriginalNode: true, + original: n21, + placeholder: new Text(' '), + name: "RouterComponent", + tree: "null>RouterComponent", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: true, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3076301467', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3076301467-n21', + props: [], + uuid: 'o2443722130', + routes: [ + { + "path": "/doc", + "name": "documentation", + "component": "o171290282-nt", + "title": "Ogone - documentation", + "uuid": "o171290282", + "isAsync": false, + "isRouter": false, + "isTemplatePrivate": false, + "isTemplateProtected": false + }, + { + "path": "/todos/:id", + "component": "o3725575239-nt", + "name": "todo", + "uuid": "o3725575239", + "isAsync": false, + "isRouter": false, + "isTemplatePrivate": true, + "isTemplateProtected": false + }, + { + "path": 404, + "name": 404, + "component": "o3725575239-nt", + "title": "404 route not found", + "uuid": "o3725575239", + "isAsync": false, + "isRouter": false, + "isTemplatePrivate": true, + "isTemplateProtected": false + } + ], + namespace: '', + requirements: [], + dependencies: [] + }; + n21.placeholder = o.placeholder; + setOgone(n21, o); + o = null; + _at(n21, o3076301467, ''); + _at(n21, 'namespace', 'new'); + o = { + isRoot: false, + isOriginalNode: true, + original: n22, + placeholder: new Text(' '), + name: "MenuMain", + tree: "null>MenuMain", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3076301467', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3076301467-n22', + props: [], + uuid: 'o325165413', + routes: null, + namespace: '', + requirements: [], + dependencies: [] + }; + n22.placeholder = o.placeholder; + setOgone(n22, o); + o = null; + _at(n22, o3076301467, ''); + o = { + isRoot: false, + isOriginalNode: true, + original: nd23, + placeholder: new Text(' '), + name: "RightSection", + tree: "null>RightSection", + flags: { + "events": [], + "spread": "...this", + "else": false + }, + isTemplate: true, + isTemplatePrivate: true, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3076301467', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3076301467-nd23', + props: [], + uuid: 'o4032646903', + routes: null, + namespace: '', + requirements: [ + [ + "scrollY", + "unknown" + ] + ], + dependencies: [] + }; + nd23.placeholder = o.placeholder; + setOgone(nd23, o); + o = null; + _at(nd23, o3076301467, ''); + l--; + _ap(nt, n12); + _ap(nt, n21); + _ap(nt, n22); + _ap(nt, nd23); + return nt; +}; +Ogone.render[o4032646903_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n3 = _h(___style_), t7 = `.container { position: fixed;top: 35%;width: 40px;height: 300px;right: 0;background: #2f3035;border-radius: 5px 0 0 5px;filter: drop-shadow(0px 2px 4px #00000086);; }`, n5 = _h(___div_), t12 = new Text(' '); + l++; + _ap(n3, t7); + _at(n5, 'class', 'container'); + l++; + t12.getContext = Ogone.contexts[o4032646903_t12] ? Ogone.contexts[o4032646903_t12].bind(ctx.data) : null; + t12.code = '`${this.scrollY}`'; + const ptt12 = p.slice(); + ptt12[l - 2] = i; + t12.position = ptt12; + ctx.texts.push(t12); + l--; + _ap(n5, t12); + l--; + _ap(nt, n3); + _ap(nt, n5); + return nt; +}; +Ogone.render[o1384895395_nd6] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd6 = _h(___img_); + _at(nd6, 'class', 'img'); + _at(nd6, 'src', 'src/public/ogone.svg'); + return nd6; +}; +Ogone.render[o1384895395_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n3 = _h(___style_), t8 = `.img, .container { width: 60px;height: auto;; }`, n5 = _h(___div_), nd6 = _h(_ogone_node_); + l++; + _ap(n3, t8); + _at(n5, 'class', 'container'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div>img", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "await": true, + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: true, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o1384895395' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + ctx.promises.push(new Promise((rs)=>{ + nd6.connectedCallback(); + for (let n of nd6.nodes){ + n.addEventListener('load', ()=>{ + rs(); + }); + } + })); + l--; + _ap(n5, nd6); + l--; + _ap(nt, n3); + _ap(nt, n5); + return nt; +}; +Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n10 = _h(_ogone_node_); + _at(nt, o2465295184, ''); + l++; + _at(n5, o2465295184, ''); + _at(n5, 'id', 'test'); + _at(n5, 'class', 'menu'); + l++; + _at(n6, o2465295184, ''); + _at(n6, 'class', 'displayButtons'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd7, + placeholder: new Text(' '), + name: "MenuButton", + tree: "null>div>div>MenuButton", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o2465295184', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o2465295184-nd7', + props: [ + [ + "buttonOpts", + "t" + ] + ], + uuid: 'o2384155165', + routes: null, + namespace: '', + requirements: [ + [ + "buttonOpts", + " ButtonInterface " + ] + ], + dependencies: [] + }; + nd7.placeholder = o.placeholder; + setOgone(nd7, o); + o = null; + _at(nd7, o2465295184, ''); + l--; + _ap(n6, nd7); + _at(n9, o2465295184, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: n10, + placeholder: new Text(' '), + name: "Burger", + tree: "null>div>div>Burger", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o2465295184', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o2465295184-n10', + props: [], + uuid: 'o3104095500', + routes: null, + namespace: '', + requirements: [], + dependencies: [] + }; + n10.placeholder = o.placeholder; + setOgone(n10, o); + o = null; + _at(n10, o2465295184, ''); + l--; + _ap(n9, n10); + l--; + _ap(n5, n6); + _ap(n5, n9); + l--; + _ap(nt, n5); + return nt; +}; +Ogone.render[o3104095500_nd7] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd7 = _h(___div_); + _at(nd7, o3104095500, ''); + _at(nd7, 'class', 'line'); + return nd7; +}; +Ogone.render[o3104095500_nd6] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd6 = _h(___div_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n11 = _h(___div_); + _at(nd6, o3104095500, ''); + _at(nd6, 'class', 'container'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd7, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd7', + uuid: 'o3104095500', + nodeProps: [ + [ + "attr", + "attr(20) + '' + this.isOpen" + ] + ] + }; + nd7.placeholder = o.placeholder; + setOgone(nd7, o); + o = null; + _at(nd7, o3104095500, ''); + _at(n9, o3104095500, ''); + _at(n9, 'class', 'line'); + _at(n11, o3104095500, ''); + _at(n11, 'class', 'line'); + l--; + _ap(nd6, nd7); + _ap(nd6, n9); + _ap(nd6, n11); + return nd6; +}; +Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(_ogone_node_), nd6 = _h(_ogone_node_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n11 = _h(___div_); + _at(nt, o3104095500, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: n5, + placeholder: new Text(' '), + name: "StoreMenu", + tree: "null>StoreMenu", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: true, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o3104095500', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o3104095500-n5', + props: [], + uuid: 'o1710946592', + routes: null, + namespace: 'menu', + requirements: [], + dependencies: [] + }; + n5.placeholder = o.placeholder; + setOgone(n5, o); + o = null; + _at(n5, o3104095500, ''); + _at(n5, 'namespace', 'menu'); + n5.connectedCallback(); + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [ + { + "type": "click", + "case": "click:openMenu", + "filter": null, + "target": null + } + ], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o3104095500' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o3104095500, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd7, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd7', + uuid: 'o3104095500', + nodeProps: [ + [ + "attr", + "attr(20) + '' + this.isOpen" + ] + ] + }; + nd7.placeholder = o.placeholder; + setOgone(nd7, o); + o = null; + _at(nd7, o3104095500, ''); + _at(n9, o3104095500, ''); + _at(n9, 'class', 'line'); + _at(n11, o3104095500, ''); + _at(n11, 'class', 'line'); + l--; + _ap(nd6, nd7); + _ap(nd6, n9); + _ap(nd6, n11); + l--; + _ap(nt, n5); + _ap(nt, nd6); + return nt; +}; +Ogone.render[o1710946592_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), t3 = ``; + _at(nt, o1710946592, ''); + _ap(nt, t3); + return nt; +}; +Ogone.render[o2010234397_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_); + _at(nt, o2010234397, ''); + return nt; +}; +Ogone.render[o2384155165_nd6] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd6 = _h(___span_); + _at(nd6, o2384155165, ''); + _at(nd6, 'class', 'ok'); + return nd6; +}; +Ogone.render[o2384155165_nd8] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd8 = _h(___span_); + _at(nd8, o2384155165, ''); + _at(nd8, 'class', 'todo'); + return nd8; +}; +Ogone.render[o2384155165_nd10] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd10 = _h(___span_); + _at(nd10, o2384155165, ''); + _at(nd10, 'class', 'in-progress'); + return nd10; +}; +Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd5 = _h(___div_), t13 = new Text(' '), nd6 = _h(_ogone_node_), nd8 = _h(_ogone_node_), nd10 = _h(_ogone_node_); + _at(nd5, o2384155165, ''); + _at(nd5, 'class', 'container'); + l++; + t13.getContext = Ogone.contexts[o2384155165_t13] ? Ogone.contexts[o2384155165_t13].bind(ctx.data) : null; + t13.code = '`${this.buttonOpts.name}`'; + const ptt13 = p.slice(); + ptt13[l - 2] = i; + t13.position = ptt13; + ctx.texts.push(t13); + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'ok'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o2384155165' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o2384155165, ''); + o = { + isRoot: false, + isOriginalNode: true, + original: nd8, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'todo'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd8', + uuid: 'o2384155165' + }; + nd8.placeholder = o.placeholder; + setOgone(nd8, o); + o = null; + _at(nd8, o2384155165, ''); + o = { + isRoot: false, + isOriginalNode: true, + original: nd10, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'in-progress'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd10', + uuid: 'o2384155165' + }; + nd10.placeholder = o.placeholder; + setOgone(nd10, o); + o = null; + _at(nd10, o2384155165, ''); + l--; + _ap(nd5, t13); + _ap(nd5, nd6); + _ap(nd5, nd8); + _ap(nd5, nd10); + return nd5; +}; +Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), nd5 = _h(_ogone_node_), t13 = new Text(' '), nd6 = _h(_ogone_node_), nd8 = _h(_ogone_node_), nd10 = _h(_ogone_node_); + _at(nt, o2384155165, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd5, + placeholder: new Text(' '), + tree: "null>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [ + { + "type": "click", + "name": "router-go", + "eval": "this.buttonOpts.route" + } + ], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd5', + uuid: 'o2384155165' + }; + nd5.placeholder = o.placeholder; + setOgone(nd5, o); + o = null; + _at(nd5, o2384155165, ''); + l++; + t13.getContext = Ogone.contexts[o2384155165_t13] ? Ogone.contexts[o2384155165_t13].bind(ctx.data) : null; + t13.code = '`${this.buttonOpts.name}`'; + const ptt13 = p.slice(); + ptt13[l - 2] = i; + t13.position = ptt13; + ctx.texts.push(t13); + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'ok'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o2384155165' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o2384155165, ''); + o = { + isRoot: false, + isOriginalNode: true, + original: nd8, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'todo'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd8', + uuid: 'o2384155165' + }; + nd8.placeholder = o.placeholder; + setOgone(nd8, o); + o = null; + _at(nd8, o2384155165, ''); + o = { + isRoot: false, + isOriginalNode: true, + original: nd10, + placeholder: new Text(' '), + tree: "null>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.buttonOpts.status === 'in-progress'", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd10', + uuid: 'o2384155165' + }; + nd10.placeholder = o.placeholder; + setOgone(nd10, o); + o = null; + _at(nd10, o2384155165, ''); + l--; + _ap(nd5, t13); + _ap(nd5, nd6); + _ap(nd5, nd8); + _ap(nd5, nd10); + l--; + _ap(nt, nd5); + return nt; +}; +Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd6 = _h(___div_), n7 = _h(___div_), nd8 = _h(_ogone_node_), n10 = _h(___div_), t23 = `0.1.0`, n13 = _h(___div_), nd14 = _h(_ogone_node_); + _at(nd6, o325165413, ''); + _at(nd6, 'class', 'left-menu'); + l++; + _at(n7, o325165413, ''); + _at(n7, 'class', 'header'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd8, + placeholder: new Text(' '), + name: "LogoEl", + tree: "null>div>div>LogoEl", + flags: { + "events": [ + { + "type": "click", + "case": "click:toggle-menu", + "filter": null, + "target": null + } + ], + "else": false + }, + isTemplate: true, + isTemplatePrivate: true, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o325165413', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o325165413-nd8', + props: [], + uuid: 'o1145023862', + routes: null, + namespace: '', + requirements: null, + dependencies: [] + }; + nd8.placeholder = o.placeholder; + setOgone(nd8, o); + o = null; + _at(nd8, o325165413, ''); + _at(n10, o325165413, ''); + _ap(n10, t23); + l--; + _ap(n7, nd8); + _ap(n7, n10); + _at(n13, o325165413, ''); + _at(n13, 'class', 'tree'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd14, + placeholder: new Text(' '), + name: "TreeRecursive", + tree: "null>div>div>TreeRecursive", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o325165413', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o325165413-nd14', + props: [ + [ + "item", + "item" + ] + ], + uuid: 'o1561345583', + routes: null, + namespace: '', + requirements: [ + [ + "item", + " TreeRecursive " + ] + ], + dependencies: [] + }; + nd14.placeholder = o.placeholder; + setOgone(nd14, o); + o = null; + _at(nd14, o325165413, ''); + l--; + _ap(n13, nd14); + l--; + _ap(nd6, n7); + _ap(nd6, n13); + return nd6; +}; +Ogone.render[o325165413_nd17] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd17 = _h(___div_); + _at(nd17, o325165413, ''); + return nd17; +}; +Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(_ogone_node_), nd6 = _h(_ogone_node_), n7 = _h(___div_), nd8 = _h(_ogone_node_), n10 = _h(___div_), t23 = `0.1.0`, n13 = _h(___div_), nd14 = _h(_ogone_node_), nd17 = _h(_ogone_node_); + _at(nt, o325165413, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: n5, + placeholder: new Text(' '), + name: "StoreMenu", + tree: "null>StoreMenu", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: true, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o325165413', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o325165413-n5', + props: [], + uuid: 'o1710946592', + routes: null, + namespace: 'menu', + requirements: [], + dependencies: [] + }; + n5.placeholder = o.placeholder; + setOgone(n5, o); + o = null; + _at(n5, o325165413, ''); + _at(n5, 'namespace', 'menu'); + n5.connectedCallback(); + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "class": "{ close: !this.isOpen }", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o325165413' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o325165413, ''); + l++; + _at(n7, o325165413, ''); + _at(n7, 'class', 'header'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd8, + placeholder: new Text(' '), + name: "LogoEl", + tree: "null>div>div>LogoEl", + flags: { + "events": [ + { + "type": "click", + "case": "click:toggle-menu", + "filter": null, + "target": null + } + ], + "else": false + }, + isTemplate: true, + isTemplatePrivate: true, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o325165413', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o325165413-nd8', + props: [], + uuid: 'o1145023862', + routes: null, + namespace: '', + requirements: null, + dependencies: [] + }; + nd8.placeholder = o.placeholder; + setOgone(nd8, o); + o = null; + _at(nd8, o325165413, ''); + _at(n10, o325165413, ''); + _ap(n10, t23); + l--; + _ap(n7, nd8); + _ap(n7, n10); + _at(n13, o325165413, ''); + _at(n13, 'class', 'tree'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd14, + placeholder: new Text(' '), + name: "TreeRecursive", + tree: "null>div>div>TreeRecursive", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o325165413', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o325165413-nd14', + props: [ + [ + "item", + "item" + ] + ], + uuid: 'o1561345583', + routes: null, + namespace: '', + requirements: [ + [ + "item", + " TreeRecursive " + ] + ], + dependencies: [] + }; + nd14.placeholder = o.placeholder; + setOgone(nd14, o); + o = null; + _at(nd14, o325165413, ''); + l--; + _ap(n13, nd14); + l--; + _ap(nd6, n7); + _ap(nd6, n13); + o = { + isRoot: false, + isOriginalNode: true, + original: nd17, + placeholder: new Text(' '), + tree: "null>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "class": "{ darken: this.isOpen }", + "events": [ + { + "type": "click", + "case": "click:toggle-menu", + "filter": null, + "target": null + } + ], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd17', + uuid: 'o325165413' + }; + nd17.placeholder = o.placeholder; + setOgone(nd17, o); + o = null; + _at(nd17, o325165413, ''); + l--; + _ap(nt, n5); + _ap(nt, nd6); + _ap(nt, nd17); + return nt; +}; +Ogone.render[o1561345583_nd9] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd9 = _h(___span_), t22 = new Text(' '); + _at(nd9, o1561345583, ''); + l++; + t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; + const ptt22 = p.slice(); + ptt22[l - 2] = i; + t22.position = ptt22; + ctx.texts.push(t22); + l--; + _ap(nd9, t22); + return nd9; +}; +Ogone.render[o1561345583_nd11] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd11 = _h(___span_), t27 = `>`; + _at(nd11, o1561345583, ''); + _ap(nd11, t27); + return nd11; +}; +Ogone.render[o1561345583_nd13] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd13 = _h(___span_), t32 = `<`; + _at(nd13, o1561345583, ''); + _ap(nd13, t32); + return nd13; +}; +Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd6 = _h(___div_), n7 = _h(___span_), t17 = new Text(' '), nd9 = _h(_ogone_node_), t22 = new Text(' '), nd11 = _h(_ogone_node_), t27 = `>`, nd13 = _h(_ogone_node_), t32 = `<`; + _at(nd6, o1561345583, ''); + _at(nd6, 'class', 'title'); + l++; + _at(n7, o1561345583, ''); + l++; + t17.getContext = Ogone.contexts[o1561345583_t17] ? Ogone.contexts[o1561345583_t17].bind(ctx.data) : null; + t17.code = '`${this.item.name}`'; + const ptt17 = p.slice(); + ptt17[l - 2] = i; + t17.position = ptt17; + ctx.texts.push(t17); + l--; + _ap(n7, t17); + o = { + isRoot: false, + isOriginalNode: true, + original: nd9, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "class": "!this.item.children && this.item.status ? `status ${this.item.status}` : ''", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd9', + uuid: 'o1561345583' + }; + nd9.placeholder = o.placeholder; + setOgone(nd9, o); + o = null; + _at(nd9, o1561345583, ''); + l++; + t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; + const ptt22 = p.slice(); + ptt22[l - 2] = i; + t22.position = ptt22; + ctx.texts.push(t22); + l--; + _ap(nd9, t22); + o = { + isRoot: false, + isOriginalNode: true, + original: nd11, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.item.children && !this.openTree", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd11', + uuid: 'o1561345583' + }; + nd11.placeholder = o.placeholder; + setOgone(nd11, o); + o = null; + _at(nd11, o1561345583, ''); + _ap(nd11, t27); + o = { + isRoot: false, + isOriginalNode: true, + original: nd13, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [], + "elseIf": "this.item.children && this.openTree", + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd13', + uuid: 'o1561345583' + }; + nd13.placeholder = o.placeholder; + setOgone(nd13, o); + o = null; + _at(nd13, o1561345583, ''); + _ap(nd13, t32); + l--; + _ap(nd6, n7); + _ap(nd6, nd9); + _ap(nd6, nd11); + _ap(nd6, nd13); + return nd6; +}; +Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd16 = _h(___div_), n17 = _h(_ogone_node_), nd18 = _h(_ogone_node_); + _at(nd16, o1561345583, ''); + _at(nd16, 'class', 'child'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: n17, + placeholder: new Text(' '), + name: "ScrollComponent", + tree: "null>div>div>ScrollComponent", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o1561345583', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o1561345583-n17', + props: [], + uuid: 'o3474491051', + routes: null, + namespace: '', + requirements: null, + dependencies: [] + }; + n17.placeholder = o.placeholder; + setOgone(n17, o); + o = null; + _at(n17, o1561345583, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd18, + placeholder: new Text(' '), + name: "Self", + tree: "null>div>div>ScrollComponent>Self", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o1561345583', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o1561345583-nd18', + props: [ + [ + "item", + "child" + ] + ], + uuid: 'o1561345583', + routes: null, + namespace: '', + requirements: [ + [ + "item", + " TreeRecursive " + ] + ], + dependencies: [] + }; + nd18.placeholder = o.placeholder; + setOgone(nd18, o); + o = null; + _at(nd18, o1561345583, ''); + l--; + _ap(n17, nd18); + l--; + _ap(nd16, n17); + return nd16; +}; +Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(___div_), nd6 = _h(_ogone_node_), n7 = _h(___span_), t17 = new Text(' '), nd9 = _h(_ogone_node_), t22 = new Text(' '), nd11 = _h(_ogone_node_), t27 = `>`, nd13 = _h(_ogone_node_), t32 = `<`, nd16 = _h(_ogone_node_), n17 = _h(_ogone_node_), nd18 = _h(_ogone_node_); + _at(nt, o1561345583, ''); + l++; + _at(n5, o1561345583, ''); + _at(n5, 'class', 'container'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [ + { + "type": "click", + "case": "click:toggle", + "filter": null, + "target": null + }, + { + "type": "click", + "name": "router-go", + "eval": "this.item.route" + } + ], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd6', + uuid: 'o1561345583' + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o1561345583, ''); + l++; + _at(n7, o1561345583, ''); + l++; + t17.getContext = Ogone.contexts[o1561345583_t17] ? Ogone.contexts[o1561345583_t17].bind(ctx.data) : null; + t17.code = '`${this.item.name}`'; + const ptt17 = p.slice(); + ptt17[l - 2] = i; + t17.position = ptt17; + ctx.texts.push(t17); + l--; + _ap(n7, t17); + o = { + isRoot: false, + isOriginalNode: true, + original: nd9, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "class": "!this.item.children && this.item.status ? `status ${this.item.status}` : ''", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd9', + uuid: 'o1561345583' + }; + nd9.placeholder = o.placeholder; + setOgone(nd9, o); + o = null; + _at(nd9, o1561345583, ''); + l++; + t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; + const ptt22 = p.slice(); + ptt22[l - 2] = i; + t22.position = ptt22; + ctx.texts.push(t22); + l--; + _ap(nd9, t22); + o = { + isRoot: false, + isOriginalNode: true, + original: nd11, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.item.children && !this.openTree", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd11', + uuid: 'o1561345583' + }; + nd11.placeholder = o.placeholder; + setOgone(nd11, o); + o = null; + _at(nd11, o1561345583, ''); + _ap(nd11, t27); + o = { + isRoot: false, + isOriginalNode: true, + original: nd13, + placeholder: new Text(' '), + tree: "null>div>div>span", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "events": [], + "elseIf": "this.item.children && this.openTree", + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd13', + uuid: 'o1561345583' + }; + nd13.placeholder = o.placeholder; + setOgone(nd13, o); + o = null; + _at(nd13, o1561345583, ''); + _ap(nd13, t32); + l--; + _ap(nd6, n7); + _ap(nd6, nd9); + _ap(nd6, nd11); + _ap(nd6, nd13); + o = { + isRoot: false, + isOriginalNode: true, + original: nd16, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.item.children", + "class": "{ 'child-open': this.openTree }", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd16', + uuid: 'o1561345583' + }; + nd16.placeholder = o.placeholder; + setOgone(nd16, o); + o = null; + _at(nd16, o1561345583, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: n17, + placeholder: new Text(' '), + name: "ScrollComponent", + tree: "null>div>div>ScrollComponent", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o1561345583', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o1561345583-n17', + props: [], + uuid: 'o3474491051', + routes: null, + namespace: '', + requirements: null, + dependencies: [] + }; + n17.placeholder = o.placeholder; + setOgone(n17, o); + o = null; + _at(n17, o1561345583, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd18, + placeholder: new Text(' '), + name: "Self", + tree: "null>div>div>ScrollComponent>Self", + flags: { + "events": [], + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o1561345583', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o1561345583-nd18', + props: [ + [ + "item", + "child" + ] + ], + uuid: 'o1561345583', + routes: null, + namespace: '', + requirements: [ + [ + "item", + " TreeRecursive " + ] + ], + dependencies: [] + }; + nd18.placeholder = o.placeholder; + setOgone(nd18, o); + o = null; + _at(nd18, o1561345583, ''); + l--; + _ap(n17, nd18); + l--; + _ap(nd16, n17); + l--; + _ap(n5, nd6); + _ap(n5, nd16); + l--; + _ap(nt, n5); + return nt; +}; +Ogone.render[o3474491051_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___div_), n8 = _h(___slot_); + _at(nt, o3474491051, ''); + l++; + _at(n5, o3474491051, ''); + _at(n5, 'class', 'container'); + l++; + _at(n6, o3474491051, ''); + ctx.refs['view'] = ctx.refs['view'] || []; + ctx.refs['view'][i] = n6; + _at(n6, 'class', 'view'); + l++; + _at(n7, o3474491051, ''); + ctx.refs['content'] = ctx.refs['content'] || []; + ctx.refs['content'][i] = n7; + _at(n7, 'class', 'content'); + l++; + _at(n8, o3474491051, ''); + l--; + _ap(n7, n8); + l--; + _ap(n6, n7); + l--; + _ap(n5, n6); + l--; + _ap(nt, n5); + return nt; +}; +Ogone.render[o1145023862_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n3 = _h(___style_), t7 = `.container { width: 60px;height: auto; } .container .img { width: 60px;height: auto;; }`, n5 = _h(___div_), n6 = _h(___img_); + l++; + _ap(n3, t7); + _at(n5, 'class', 'container'); + l++; + _at(n6, 'class', 'img'); + _at(n6, 'src', '/src/public/ogone.svg'); + l--; + _ap(n5, n6); + l--; + _ap(nt, n3); + _ap(nt, n5); + return nt; +}; +Ogone.render[o2443722130_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), t3 = ``; + _at(nt, o2443722130, ''); + _ap(nt, t3); + return nt; +}; +Ogone.render[o171290282_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(___div_), nd6 = _h(_ogone_node_); + _at(nt, o171290282, ''); + l++; + _at(n5, o171290282, ''); + _at(n5, 'class', 'container'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd6, + placeholder: new Text(' '), + name: "ContentPage", + tree: "null>div>ContentPage", + flags: { + "events": [], + "spread": "...article", + "else": false + }, + isTemplate: true, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: true, + isRemote: false, + extends: '-nt', + uuid: 'o171290282', + positionInParentComponent: p, + levelInParentComponent: l, + parentComponent: ctx, + parentCTXId: 'o171290282-nd6', + props: [], + uuid: 'o1517538778', + routes: null, + namespace: '', + requirements: [ + [ + "title", + " string " + ], + [ + "text", + " string " + ], + [ + "code", + " string " + ], + [ + "page", + " string " + ] + ], + dependencies: [] + }; + nd6.placeholder = o.placeholder; + setOgone(nd6, o); + o = null; + _at(nd6, o171290282, ''); + l--; + _ap(n5, nd6); + l--; + _ap(nt, n5); + return nt; +}; +Ogone.render[o1517538778_nd13] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd13 = _h(___p_), t30 = new Text(' '); + _at(nd13, o1517538778, ''); + _at(nd13, 'class', 'page'); + l++; + t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.code = '`${this.page}`'; + const ptt30 = p.slice(); + ptt30[l - 2] = i; + t30.position = ptt30; + ctx.texts.push(t30); + l--; + _ap(nd13, t30); + return nd13; +}; +Ogone.render[o1517538778_nd12] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nd12 = _h(___div_), nd13 = _h(_ogone_node_), t30 = new Text(' '), n15 = _h(___pre_), n16 = _h(___code_), t37 = new Text(' '); + _at(nd12, o1517538778, ''); + _at(nd12, 'class', 'right'); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd13, + placeholder: new Text(' '), + tree: "null>div>div>p", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.page", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd13', + uuid: 'o1517538778' + }; + nd13.placeholder = o.placeholder; + setOgone(nd13, o); + o = null; + _at(nd13, o1517538778, ''); + l++; + t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.code = '`${this.page}`'; + const ptt30 = p.slice(); + ptt30[l - 2] = i; + t30.position = ptt30; + ctx.texts.push(t30); + l--; + _ap(nd13, t30); + _at(n15, o1517538778, ''); + l++; + _at(n16, o1517538778, ''); + _at(n16, 'class', 'javascript'); + l++; + t37.getContext = Ogone.contexts[o1517538778_t37] ? Ogone.contexts[o1517538778_t37].bind(ctx.data) : null; + t37.code = '`${this.code}`'; + const ptt37 = p.slice(); + ptt37[l - 2] = i; + t37.position = ptt37; + ctx.texts.push(t37); + l--; + _ap(n16, t37); + l--; + _ap(n15, n16); + l--; + _ap(nd12, nd13); + _ap(nd12, n15); + return nd12; +}; +Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___h2_), t16 = new Text(' '), n9 = _h(___p_), t21 = new Text(' '), nd12 = _h(_ogone_node_), nd13 = _h(_ogone_node_), t30 = new Text(' '), n15 = _h(___pre_), n16 = _h(___code_), t37 = new Text(' '); + _at(nt, o1517538778, ''); + l++; + _at(n5, o1517538778, ''); + _at(n5, 'class', 'container'); + l++; + _at(n6, o1517538778, ''); + _at(n6, 'class', 'left'); + l++; + _at(n7, o1517538778, ''); + _at(n7, 'class', 'title'); + l++; + t16.getContext = Ogone.contexts[o1517538778_t16] ? Ogone.contexts[o1517538778_t16].bind(ctx.data) : null; + t16.code = '`${this.title}`'; + const ptt16 = p.slice(); + ptt16[l - 2] = i; + t16.position = ptt16; + ctx.texts.push(t16); + l--; + _ap(n7, t16); + _at(n9, o1517538778, ''); + _at(n9, 'class', 'text'); + l++; + t21.getContext = Ogone.contexts[o1517538778_t21] ? Ogone.contexts[o1517538778_t21].bind(ctx.data) : null; + t21.code = '`${this.text}`'; + const ptt21 = p.slice(); + ptt21[l - 2] = i; + t21.position = ptt21; + ctx.texts.push(t21); + l--; + _ap(n9, t21); + l--; + _ap(n6, n7); + _ap(n6, n9); + o = { + isRoot: false, + isOriginalNode: true, + original: nd12, + placeholder: new Text(' '), + tree: "null>div>div", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.code", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd12', + uuid: 'o1517538778' + }; + nd12.placeholder = o.placeholder; + setOgone(nd12, o); + o = null; + _at(nd12, o1517538778, ''); + l++; + o = { + isRoot: false, + isOriginalNode: true, + original: nd13, + placeholder: new Text(' '), + tree: "null>div>div>p", + position: p, + level: l, + index: i, + component: ctx, + flags: { + "if": "this.page", + "events": [], + "else": false + }, + isTemplate: false, + isTemplatePrivate: false, + isTemplateProtected: false, + isAsync: false, + isRouter: false, + isStore: false, + isController: false, + isAsyncNode: false, + isImported: false, + isRemote: false, + extends: '-nd13', + uuid: 'o1517538778' + }; + nd13.placeholder = o.placeholder; + setOgone(nd13, o); + o = null; + _at(nd13, o1517538778, ''); + l++; + t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.code = '`${this.page}`'; + const ptt30 = p.slice(); + ptt30[l - 2] = i; + t30.position = ptt30; + ctx.texts.push(t30); + l--; + _ap(nd13, t30); + _at(n15, o1517538778, ''); + l++; + _at(n16, o1517538778, ''); + _at(n16, 'class', 'javascript'); + l++; + t37.getContext = Ogone.contexts[o1517538778_t37] ? Ogone.contexts[o1517538778_t37].bind(ctx.data) : null; + t37.code = '`${this.code}`'; + const ptt37 = p.slice(); + ptt37[l - 2] = i; + t37.position = ptt37; + ctx.texts.push(t37); + l--; + _ap(n16, t37); + l--; + _ap(n15, n16); + l--; + _ap(nd12, nd13); + _ap(nd12, n15); + l--; + _ap(n5, n6); + _ap(n5, nd12); + l--; + _ap(nt, n5); + return nt; +}; +Ogone.render[o3725575239_nt] = function(ctx, pos = [], i = 0, l = 0) { + let p = pos.slice(); + let o = null; + const nt = _h(___template_), n3 = _h(___style_), t8 = `.container { display: flex;justify-content: center;margin: auto;flex-direction: column;height: 100vh; } .container .text { font-weight: 400;font-size: 24pt;text-align: center;color: #9e9e9e;margin: 40px;; } .logo-back { filter: drop-shadow(2px 4px 6px var(--o-primary));border-radius: 100%;padding: 56px;animation-name: popup;animation-duration: 0.5s;animation-timing-function: cubic-bezier(0.1, -0.6, 0.2, 0);max-width: 500px;margin: auto; } .logo-back img.logo { width: 500px;height: auto;animation-name: rotate;animation-duration: 5s;animation-timing-function: ease;animation-iteration-count: infinite;animation-direction: alternate;; }`, n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___img_), n9 = _h(___div_), t21 = `404 route not found.`; + l++; + _ap(n3, t8); + _at(n5, 'class', 'container'); + l++; + _at(n6, 'class', 'logo-back'); + l++; + _at(n7, 'class', 'logo'); + _at(n7, 'src', '/src/public/ogone.svg'); + l--; + _ap(n6, n7); + _at(n9, 'class', 'text'); + _ap(n9, t21); + l--; + _ap(n5, n6); + _ap(n5, n9); + l--; + _ap(nt, n3); + _ap(nt, n5); + return nt; +}; +/** + * struct import for examples/app/Application.o3 + * */ import { Obj } from 'https://deno.land/x/obj@0.0.1/mod.ts'; +/** + * save imports for examples/app/Application.o3 +*/ Ogone.require['/x/obj@0.0.1/mod.ts'] = Ogone.require['/x/obj@0.0.1/mod.ts'] || { +}; +/** member */ Ogone.require['/x/obj@0.0.1/mod.ts'].Obj = Obj; +/** + * struct import for examples/app/components/Burger.o3 + * */ import print from '/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'; +/** + * save imports for examples/app/components/Burger.o3 +*/ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'] = Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'] || { +}; +/** default */ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'].print = print; +/** + * struct import for examples/app/components/Burger.o3 + * */ import attr from '/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'; +/** + * save imports for examples/app/components/Burger.o3 +*/ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'] = Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'] || { +}; +/** default */ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'].attr = attr; diff --git a/examples/tests/dist/index.html b/examples/tests/dist/index.html new file mode 100644 index 00000000..f8aab1aa --- /dev/null +++ b/examples/tests/dist/index.html @@ -0,0 +1,13 @@ + + + + + + + + + + + + + \ No newline at end of file diff --git a/examples/tests/dist/style.css b/examples/tests/dist/style.css new file mode 100644 index 00000000..8c7a42da --- /dev/null +++ b/examples/tests/dist/style.css @@ -0,0 +1,15 @@ + h1[o3076301467], h2[o3076301467], h3[o3076301467], h4[o3076301467] { color: #193b48;; } .open-dev-tool[o3076301467] { display: inline-flex;background: var(--o-header);height: 100%;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none;; } .logo[o3076301467] { flex: 2;display: inline-flex;flex-direction: row;max-width: 124px;min-width: 124px;min-height: 65px;cursor: pointer;; } .header[o3076301467] { background: var(--o-header);padding: 10px;filter: drop-shadow(0px 10px 5px #00000033);display: flex;position: fixed;width: 99%;top: 0px;left: 0px;transition: top 0.5s ease;overflow: hidden;z-index: 500;; } .title[o3076301467] { margin: auto;letter-spacing: 3px;; } + + + .menu[o2465295184] { flex: 8;display: flex;flex-direction: row;vertical-align: middle;align-items: center;justify-content: flex-end;; } @media screen and (max-width: 900px) { div.displayButtons[o2465295184] { display: none;; } } + .container[o3104095500] { padding: 9px;width: 28px;height: auto;background: var(--o-header);display: flex;flex-direction: column;filter: drop-shadow(0px 0px 0px #00000045); } .container[o3104095500]:hover[o3104095500] { filter: drop-shadow(0px 5px 3px #00000045);; } .container[o3104095500]:hover[o3104095500] .line[o3104095500] { background: var(--o-primary);; } .container[o3104095500] .line[o3104095500] { background: #848181;margin-top: 2px;margin-bottom: 2px;height: 4px;; } .line[o3104095500], .container[o3104095500] { border-radius: 5px;transition: filter 0.2s ease;cursor: pointer;; } + + + .container[o2384155165] { display: inline-flex;background: var(--o-header);height: 100%;width: min-content;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none; } .container[o2384155165]:hover[o2384155165] { background: var(--o-primary);color: var(--o-background);; } .ok[o2384155165], .in-progress[o2384155165], .todo[o2384155165] { height: 3px;width: 3px;padding: 3px;border-radius: 20px;margin: 5px;; } .ok[o2384155165] { background: var(--o-success); } .todo[o2384155165] { background: var(--o-error); } .in-progress[o2384155165] { background: var(--o-info); } + .left-menu[o325165413] { height: 100vh;width: 300px;min-width: 300px;max-width: 300px;position: fixed;top: 0px;transition: left 0.5s ease;left: 0px;background: var(--o-header);z-index: 2000;display: flex;filter: drop-shadow(0px 0px 10px #000000);flex-direction: column;; } .close[o325165413] { left: -100%;; } .darken[o325165413] { background: #00000090;width: 100vw;height: 100vh;top: 0px;left: 0px;position: fixed;z-index: 1999;; } .header[o325165413] { padding: 10px;display: flex;vertical-align: middle;align-items: center;justify-content: space-between;border-bottom: 1px solid #4e4e4e;; } .tree[o325165413] { overflow-x: hidden;overflow-y: auto;; } + .container[o1561345583] { color: var(--o-grey);display: flex;flex-direction: column;flex: 1;; } .child[o1561345583] { padding-left: 30px;height: 0;overflow: hidden;transition: flex 0.5s ease;; } .child-open[o1561345583] { flex: 1;; } .title[o1561345583] { padding-bottom: 10px;padding: 5px;cursor: pointer;flex: 1;display: flex;justify-content: space-between; } .title[o1561345583]:hover[o1561345583] { background: var(--o-primary);color: white;; } .child[o1561345583] .title[o1561345583] { border-left: 1px solid #555;; } .status[o1561345583] { display: list-item;; } .ok[o1561345583] { color: var(--o-success); } .todo[o1561345583] { color: var(--o-error); } .in-progress[o1561345583] { color: var(--o-info); } + .container[o3474491051] { overflow: hidden;display: flex;flex-direction: row-reverse; } .container[o3474491051] .view[o3474491051] { flex: 18;overflow: auto; } .container[o3474491051] .view[o3474491051] .content[o3474491051] { flex: 18;; } + + + .container[o171290282] { height: auto;width: auto;background: black;margin-top: 45px;animation-name: fade-in-right;animation-iteration-count: 1;animation-duration: 0.5s;; } + .container[o1517538778] { min-height: 400px;width: 100%;display: flex;flex-direction: column;; } .left[o1517538778] { background: var(--o-background);flex: 6;padding: 98px;padding-left: 326px; } .right[o1517538778] { flex: 5;padding: 53px;padding-top: 135px;padding-bottom: 135px;border-left: 1px solid #d8d8d8;background: #f1f1f1;color: var(--o-grey);padding-left: 326px; } .code[o1517538778] { white-space: pre;; } .text[o1517538778] { color: var(--o-grey);margin-left: 30px;white-space: pre;; } .title[o1517538778] { color: var(--o-dark-blue);; } .page[o1517538778] { opacity: 0.3;color: cadetblue;; } @media screen and (max-width: $screen) { .left[o1517538778] { padding-left: 77px;; } } @media screen and (max-width: $screen) { .right[o1517538778] { padding-left: 77px;; } } diff --git a/src/classes/Dependency.ts b/src/classes/Dependency.ts index dfd5470f..67d713c3 100644 --- a/src/classes/Dependency.ts +++ b/src/classes/Dependency.ts @@ -100,7 +100,8 @@ export default class Dependency extends Utils { */ get importStatementAbsolutePath(): string { if (this.isRemote) return this.input; - return this.input.replace(this.data.path, `${this.absolutePathURL.pathname}?uuid=${this.component.uuid}`); + if (Env._env !== 'production') return this.input.replace(this.data.path, `${this.absolutePathURL.pathname}?uuid=${this.component.uuid}`); + return this.input.replace(this.data.path, this.absolutePathURL.pathname); } /** * exposes the import statement with the dependency's url in parameter @@ -122,13 +123,17 @@ export default class Dependency extends Utils { function getStructure(pathToModule: string, memberName: string, opts: { isDefault: boolean, isAllAs: boolean, isMember: boolean }): string { const { isDefault, isMember, isAllAs } = opts; if (isRemote) `Ogone.require[${pathToModule}].${memberName} = ${memberName}`; - return ` + let result = ` Ogone.require[${pathToModule}].${memberName} = ${memberName} - HMR.subscribe(${pathToModule}, (mod) => { - Ogone.require[${pathToModule}].${memberName} = mod${isDefault ? '.default' : isAllAs ? '' : memberName} - }); - HMR.setGraph(${pathToModule}, ${JSON.stringify(graph)}); - ` + `; + if (Env._env !== 'production') { + result += ` + HMR.subscribe(${pathToModule}, (mod) => { + Ogone.require[${pathToModule}].${memberName} = mod${isDefault ? '.default' : isAllAs ? '' : memberName} + }); + HMR.setGraph(${pathToModule}, ${JSON.stringify(graph)});`; + } + return result } let importStatement = ` /** diff --git a/src/classes/Env.ts b/src/classes/Env.ts index e346a397..81b89b96 100755 --- a/src/classes/Env.ts +++ b/src/classes/Env.ts @@ -1,9 +1,12 @@ import HTMLDocument from '../enums/templateDocumentHTML.ts'; import { BoilerPlate } from '../enums/templateComponent.ts'; -// TODO fix HMR -// use std websocket instead of deno.x one -// import { HCR } from "../../lib/hmr/index.ts"; -import type { Bundle, Environment, Component } from "./../ogone.main.d.ts"; +import type { + Bundle, + Environment, + Component, + ProductionFiles, + ProductionFile, +} from "./../ogone.main.d.ts"; import { existsSync } from "../../utils/exists.ts"; import { join } from "../../deps/deps.ts"; import Constructor from "./Constructor.ts"; @@ -412,62 +415,72 @@ ${err.stack}`); ${err.stack}`); } } - public async renderBundleAndBuildForProduction(entrypoint: string, bundle: Bundle): Promise { + /*** + * get production files + */ + public async renderBundleAndBuildForProduction( + entrypoint: string, + bundle: Bundle, + buildPath: string): Promise { try { const entries = Array.from(bundle.components.entries()); - const globalStyle: string[] = []; - const stylesDev = entries - .map(( - entry: any, - ) => { - let result = ""; - globalStyle.push(entry[1].style.join("\n")); - return result; - }).join("\n"); - const style = ``; const rootComponent = bundle.components.get(entrypoint); - const dependencies = entries.map(([, component]) => component) + if (rootComponent) { + /** + * CSS File for production + */ + const css: ProductionFile = { + path: join(buildPath, './style.css'), + source: entries.map(([, component]: [string, Component],) => component.style.join("\n")).join("\n"), + }; + const dependencies = entries.map(([, component]) => component) .map((component) => { return component.deps.map((dep: Dependency) => dep.structuredOgoneRequire).join('\n'); }).join('\n'); - if (rootComponent) { - const scriptProd = this.template( - ` - const ROOT_UUID = "${rootComponent.uuid}"; - const ROOT_IS_PRIVATE = ${!!rootComponent.elements.template?.attributes.private}; - const ROOT_IS_PROTECTED = ${!!rootComponent.elements.template?.attributes.protected}; - const _ogone_node_ = "o-node"; + /** + * Javascript File for production + */ + const js: ProductionFile = { + path: join(buildPath, './app.js'), + source: await TSTranspiler.transpile(this.template(` + const ROOT_UUID = "${rootComponent.uuid}"; + const ROOT_IS_PRIVATE = ${!!rootComponent.elements.template?.attributes.private}; + const ROOT_IS_PROTECTED = ${!!rootComponent.elements.template?.attributes.protected}; + const _ogone_node_ = "o-node"; + ${MapOutput.runtime} + {% dependencies %} + `, + { + render: {}, + root: bundle.components.get(entrypoint), + destroy: {}, + nodes: {}, + dependencies, + }, + ).trim()), + }; + /** + * HTML File for production + */ + const html: ProductionFile = { + path: join(buildPath, './index.html'), + source: this.template(HTMLDocument.PAGE_BUILD, { + head: ` + + ${Configuration.head || ""}`, + script: ``, + dom: ``, + }), + }; - ${MapOutput.runtime} - `, - { - render: {}, - root: bundle.components.get(entrypoint), - destroy: {}, - nodes: {}, - dependencies, - }, - ); - // in production DOM has to be - // - const dom = ``; - let script = ` - `; - let head = ` - ${style} - ${Configuration.head || ""}`; - let body = this.template(HTMLDocument.PAGE_BUILD, { - head, - script, - dom, - }); - return body; + return { + css, + html, + js, + ressources: [], + }; } else { - return "no root-component found"; + Deno.exit(1); } } catch (err) { this.error(`Env: ${err.message} @@ -481,20 +494,17 @@ ${err.stack}`); "undefined bundle, please use setBundle method before accessing to the application", ); } - let result = ''; - switch(true) { - case this.env === "production": - result = await this.renderBundleAndBuildForProduction(Configuration.entrypoint, this.bundle); - break; - default: - result = await this.renderBundle(Configuration.entrypoint, this.bundle); - break; - } + let result = await this.renderBundle(Configuration.entrypoint, this.bundle); return result; } catch (err) { this.error(`Env: ${err.message} ${err.stack}`); } } - + public async build(app: ProductionFiles): Promise { + const { css, html, js, ressources } = app; + await Deno.writeTextFile(html.path, html.source, { create: true }); + await Deno.writeTextFile(css.path, css.source, { create: true }); + await Deno.writeTextFile(js.path, js.source, { create: true }); + } } diff --git a/src/classes/EnvServer.ts b/src/classes/EnvServer.ts index 4c179fdf..5a7a72d8 100755 --- a/src/classes/EnvServer.ts +++ b/src/classes/EnvServer.ts @@ -44,9 +44,15 @@ export default class EnvServer extends Env { this.setEnv("production"); this.setDevTool(false); this.compile(Configuration.entrypoint, true) - .then(async () => { - let app = await this.getApplication(); - console.warn(app); + .then(async (bundle) => { + let app = await this.renderBundleAndBuildForProduction( + Configuration.entrypoint, + bundle, + opts.build! + ); + await this.build(app); + this.success(`Application built for production: ${opts.build}`); + Deno.exit(0); }) } else { //start compilation of o3 files diff --git a/src/classes/TSTranspiler.ts b/src/classes/TSTranspiler.ts index 7cd95e61..ae5889dc 100644 --- a/src/classes/TSTranspiler.ts +++ b/src/classes/TSTranspiler.ts @@ -28,12 +28,16 @@ export default class TSTranspiler extends Utils { } } static async bundle(url: URL | string): Promise { - let result = (await Deno.emit(url, { - bundle: 'esm', - check: false, - })); - const file = result.files['deno:///bundle.js']; - return file; + try { + let result = (await Deno.emit(url, { + bundle: 'esm', + check: false, + })); + const file = result.files['deno:///bundle.js']; + return file; + } catch(err) { + this.error(`TSTranspiler: ${err.message}`); + } } /** * saves Ogone's runtime, which is bundled, into MapOutput.runtime diff --git a/src/ogone.main.d.ts b/src/ogone.main.d.ts index 8f8dfe33..39bce298 100644 --- a/src/ogone.main.d.ts +++ b/src/ogone.main.d.ts @@ -857,4 +857,26 @@ interface FileBundle { } } -type SusanoOptions = { path: string; parent?: FileBundle } | { code: string, path: string; parent?: FileBundle }; \ No newline at end of file +type SusanoOptions = { path: string; parent?: FileBundle } | { code: string, path: string; parent?: FileBundle }; +export interface ProductionFile { + path: string; + source: string; +} +export interface ProductionFiles { + /** + * All the styles + */ + css: ProductionFile; + /** + * the html of the index.html file + */ + html: ProductionFile; + /** + * the script of the application + */ + js: ProductionFile; + /** + * all ressources needed + */ + ressources: string[]; +} \ No newline at end of file From f1c75b0b1028963451de240050603adeccf6de6a Mon Sep 17 00:00:00 2001 From: SRNV Date: Thu, 25 Mar 2021 17:43:37 +0100 Subject: [PATCH 101/143] wip improve and fix build cmd --- examples/tests/build/App.o3 | 15 + examples/tests/dist/app.js | 1572 ++++++++++++++++++----------- examples/tests/dist/index.html | 2 +- examples/tests/dist/style.css | 16 +- src/classes/ComponentCompiler.ts | 1 + src/classes/Dependency.ts | 6 +- src/classes/Env.ts | 20 +- src/classes/TSTranspiler.ts | 19 + src/classes/Utils.ts | 3 + src/enums/templateDocumentHTML.ts | 3 +- 10 files changed, 1033 insertions(+), 624 deletions(-) create mode 100755 examples/tests/build/App.o3 diff --git a/examples/tests/build/App.o3 b/examples/tests/build/App.o3 new file mode 100755 index 00000000..4d9f1cdc --- /dev/null +++ b/examples/tests/build/App.o3 @@ -0,0 +1,15 @@ +import { Obj } from 'https://deno.land/x/obj@0.0.1/mod.ts' + +/** + * @name Application + * @description + * test for build + */ + + + default: + // initialization + break; + \ No newline at end of file diff --git a/examples/tests/dist/app.js b/examples/tests/dist/app.js index 54792c1d..fe4e7950 100644 --- a/examples/tests/dist/app.js +++ b/examples/tests/dist/app.js @@ -1,6 +1,379 @@ -const ROOT_UUID = "o3076301467"; -const ROOT_IS_PRIVATE = false; -const ROOT_IS_PROTECTED = false; +class Obj { + position = []; + texture = []; + normal = []; + objects = []; + materialLibs = []; + static parse(text, options = { + strict: false + }) { + const dat = new Obj(); + let obj = { + name: "default", + groups: [] + }; + let group; + for (const line of text.split("\n")){ + if (line.length === 0 || line.startsWith("#")) { + continue; + } + const parts = line.split(/\s+/); + const keyword = parts.shift(); + switch(keyword){ + case "v": + dat.position.push([ + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + ]); + break; + case "vt": + dat.texture.push([ + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + ]); + break; + case "vn": + dat.normal.push([ + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + ]); + break; + case "f": + { + const poly = dat.parseFace(parts); + if (group === undefined) { + group = { + name: "default", + index: 0, + polys: [ + poly + ] + }; + } else { + group.polys.push(poly); + } + } + break; + case "o": + if (group !== undefined) { + obj.groups.push(group); + dat.objects.push(obj); + group = undefined; + } + obj = line.length > 2 ? { + name: line.slice(keyword.length).trim(), + groups: [] + } : { + name: "default", + groups: [] + }; + break; + case "g": + if (group !== undefined) { + obj.groups.push(group); + } + if (line.length > 2) { + group = { + name: line.slice(keyword.length).trim(), + index: 0, + polys: [] + }; + } + break; + case "mtllib": + dat.materialLibs.push(new Mtl(line.slice(keyword.length).trim())); + break; + case "usemtl": + { + const g = otherwise(group, (g1)=>g1 + , ()=>({ + name: "default", + index: 0, + polys: [] + }) + ); + if (g.material !== undefined) { + obj.groups.push(g); + g.index += 1; + g.polys = []; + } + g.material = otherwise(parts.shift(), (ref)=>({ + ref + }) + , ()=>{ + throw IncorrectArguments; + }); + group = g; + } + break; + case "s": break; + case "l": break; + default: + if (options.unhandled) { + options.unhandled(keyword, parts); + } + if (options.strict) { + throw new SyntaxError(`Unhandled keyword ${keyword} on line ${line + 1}`); + } + break; + } + } + if (group !== undefined) { + obj.groups.push(group); + } + dat.objects.push(obj); + return dat; + } + parseFace(items) { + const ret = []; + if (items.length < 3) { + throw new RangeError("Face command has less than 3 vertices"); + } + for (const item of items){ + ret.push(this.parseGroup(item)); + } + return ret; + } + parseGroup(group) { + const groupSplit = group.split("/"); + const p = then(groupSplit.shift(), parseFloat); + const t = then(groupSplit.shift(), (idx)=>{ + if (idx !== "") { + return parseFloat(idx); + } + }); + const n = then(groupSplit.shift(), parseFloat); + if (p !== undefined) { + const normalized = normalize(p, this.position.length); + if (normalized === undefined) { + throw new SyntaxError("Zero vertex numbers are invalid"); + } + return [ + normalized, + then(t, (t1)=>normalize(t1, this.texture.length) + ), + then(n, (n1)=>normalize(n1, this.normal.length) + ), + ]; + } + throw new SyntaxError("Malformed face group"); + } +} +class Mtl { + constructor(name1){ + this.name = name1; + this.materials = []; + } + static parse(name, text, options = { + strict: false + }) { + const mtl = new Mtl(name); + let material = undefined; + for (const line of text.split("\n")){ + if (line.length === 0 || line.startsWith("#")) { + continue; + } + const parts = line.split(/\s+/); + const keyword = parts.shift(); + switch(keyword){ + case "newmtl": + if (material !== undefined) { + mtl.materials.push(material); + } + material = { + name: otherwise(parts.shift(), (n)=>n + , ()=>{ + throw new SyntaxError("Missing material name"); + }) + }; + break; + case "Ka": + if (material !== undefined) { + material.ka = mtl.parseVec(parts); + } + break; + case "Kd": + if (material !== undefined) { + material.kd = mtl.parseVec(parts); + } + break; + case "Ks": + if (material !== undefined) { + material.ks = mtl.parseVec(parts); + } + break; + case "Ke": + if (material !== undefined) { + material.ke = mtl.parseVec(parts); + } + break; + case "Ns": + if (material !== undefined) { + material.ns = otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "Ni": + if (material !== undefined) { + material.ni = otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "Km": + if (material !== undefined) { + material.km = otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "d": + if (material !== undefined) { + material.d = otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "Tr": + if (material !== undefined) { + material.tr = otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "Tf": + if (material !== undefined) { + material.tf = mtl.parseVec(parts); + } + break; + case "illum": + if (material !== undefined) { + material.illum = otherwise(parts.shift(), parseInt, ()=>{ + throw IncorrectArguments; + }); + } + break; + case "map_Ka": + if (material !== undefined) { + material.mapKa = line.slice(keyword.length).trim(); + } + break; + case "map_Kd": + if (material !== undefined) { + material.mapKd = line.slice(keyword.length).trim(); + } + break; + case "map_Ks": + if (material !== undefined) { + material.mapKs = line.slice(keyword.length).trim(); + } + break; + case "map_Ns": + if (material !== undefined) { + material.mapNs = line.slice(keyword.length).trim(); + } + break; + case "map_d": + if (material !== undefined) { + material.mapD = line.slice(keyword.length).trim(); + } + break; + case "map_refl": + case "refl": + if (material !== undefined) { + material.mapD = line.slice(keyword.length).trim(); + } + break; + case "map_bump": + case "map_Bump": + case "bump": + if (material !== undefined) { + material.mapBump = line.slice(keyword.length).trim(); + } + break; + case "map_disp": + case "map_Disp": + case "dip": + if (material !== undefined) { + material.mapDisp = line.slice(keyword.length).trim(); + } + break; + default: + if (options.unhandled) { + options.unhandled(keyword, parts); + } + if (options.strict) { + throw new SyntaxError(`Unhandled keyword ${keyword} on line ${line + 1}`); + } + break; + } + } + return mtl; + } + parseVec(parts) { + return [ + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + otherwise(parts.shift(), parseFloat, ()=>{ + throw IncorrectArguments; + }), + ]; + } +} +const IncorrectArguments = new SyntaxError("An argument list either has unparsable arguments or is missing arguments"); +function then(v, f) { + if (v !== undefined) { + return f(v); + } +} +function otherwise(v, f, o) { + if (v !== undefined) { + return f(v); + } + return o(); +} +function normalize(idx, len) { + if (idx < 0) { + return len + idx; + } + if (idx > 0) { + return idx - 1; + } +} +const __default = (n)=>n * 7 + 75 +; +const __default1 = (...args)=>{ + console.warn('second print changed avv', __default(19), ...args); +}; +const __default2 = (...args)=>{ + console.warn('printed from a module', ...args); + __default1('test importing files aa baaaa'); + return 'print works well'; +}; +const ROOT_UUID = "o1370160080"; const _ogone_node_ = "o-node"; const Ogone = { types: { @@ -518,8 +891,8 @@ class OgoneBaseClass extends HTMLElement { routes: null, isRoot: true, isTemplate: true, - isTemplatePrivate: ROOT_IS_PRIVATE, - isTemplateProtected: ROOT_IS_PROTECTED, + isTemplatePrivate: false, + isTemplateProtected: false, isAsync: false, isController: false, isAsyncNode: false, @@ -1866,192 +2239,194 @@ const ___h2_ = 'h2'; const ___p_ = 'p'; const ___pre_ = 'pre'; const ___code_ = 'code'; -const o3076301467 = 'o3076301467'; -const o3076301467_nt = 'o3076301467-nt'; -const o3076301467_n12 = 'o3076301467-n12'; -const o3076301467_n13 = 'o3076301467-n13'; -const o3076301467_nd14 = 'o3076301467-nd14'; -const o3076301467_nd17 = 'o3076301467-nd17'; -const o3076301467_t37 = 'o3076301467-t37'; -const o3076301467_n19 = 'o3076301467-n19'; -const o3076301467_n21 = 'o3076301467-n21'; -const o3076301467_n22 = 'o3076301467-n22'; -const o3076301467_nd23 = 'o3076301467-nd23'; -const o4032646903 = 'o4032646903'; -const o4032646903_nt = 'o4032646903-nt'; -const o4032646903_n3 = 'o4032646903-n3'; -const o4032646903_t7 = 'o4032646903-t7'; -const o4032646903_n5 = 'o4032646903-n5'; -const o4032646903_t12 = 'o4032646903-t12'; -const o1384895395 = 'o1384895395'; -const o1384895395_nt = 'o1384895395-nt'; -const o1384895395_n3 = 'o1384895395-n3'; -const o1384895395_t8 = 'o1384895395-t8'; -const o1384895395_n5 = 'o1384895395-n5'; -const o1384895395_nd6 = 'o1384895395-nd6'; -const o2465295184 = 'o2465295184'; -const o2465295184_nt = 'o2465295184-nt'; -const o2465295184_n5 = 'o2465295184-n5'; -const o2465295184_n6 = 'o2465295184-n6'; -const o2465295184_nd7 = 'o2465295184-nd7'; -const o2465295184_n9 = 'o2465295184-n9'; -const o2465295184_n10 = 'o2465295184-n10'; -const o3104095500 = 'o3104095500'; -const o3104095500_nt = 'o3104095500-nt'; -const o3104095500_n5 = 'o3104095500-n5'; -const o3104095500_nd6 = 'o3104095500-nd6'; -const o3104095500_nd7 = 'o3104095500-nd7'; -const o3104095500_n9 = 'o3104095500-n9'; -const o3104095500_n11 = 'o3104095500-n11'; -const o1710946592 = 'o1710946592'; -const o1710946592_nt = 'o1710946592-nt'; -const o1710946592_t3 = 'o1710946592-t3'; -const o1710946592_2 = 'o1710946592-2'; -const o1710946592_t6 = 'o1710946592-t6'; -const o2010234397 = 'o2010234397'; -const o2010234397_nt = 'o2010234397-nt'; -const o2010234397_2 = 'o2010234397-2'; -const o2010234397_t5 = 'o2010234397-t5'; -const o2010234397_n3 = 'o2010234397-n3'; -const o2010234397_t8 = 'o2010234397-t8'; -const o2010234397_t11 = 'o2010234397-t11'; -const o2384155165 = 'o2384155165'; -const o2384155165_nt = 'o2384155165-nt'; -const o2384155165_nd5 = 'o2384155165-nd5'; -const o2384155165_t13 = 'o2384155165-t13'; -const o2384155165_nd6 = 'o2384155165-nd6'; -const o2384155165_nd8 = 'o2384155165-nd8'; -const o2384155165_nd10 = 'o2384155165-nd10'; -const o325165413 = 'o325165413'; -const o325165413_nt = 'o325165413-nt'; -const o325165413_n5 = 'o325165413-n5'; -const o325165413_nd6 = 'o325165413-nd6'; -const o325165413_n7 = 'o325165413-n7'; -const o325165413_nd8 = 'o325165413-nd8'; -const o325165413_n10 = 'o325165413-n10'; -const o325165413_t23 = 'o325165413-t23'; -const o325165413_n13 = 'o325165413-n13'; -const o325165413_nd14 = 'o325165413-nd14'; -const o325165413_nd17 = 'o325165413-nd17'; -const o1561345583 = 'o1561345583'; -const o1561345583_nt = 'o1561345583-nt'; -const o1561345583_n5 = 'o1561345583-n5'; -const o1561345583_nd6 = 'o1561345583-nd6'; -const o1561345583_n7 = 'o1561345583-n7'; -const o1561345583_t17 = 'o1561345583-t17'; -const o1561345583_nd9 = 'o1561345583-nd9'; -const o1561345583_t22 = 'o1561345583-t22'; -const o1561345583_nd11 = 'o1561345583-nd11'; -const o1561345583_t27 = 'o1561345583-t27'; -const o1561345583_nd13 = 'o1561345583-nd13'; -const o1561345583_t32 = 'o1561345583-t32'; -const o1561345583_nd16 = 'o1561345583-nd16'; -const o1561345583_n17 = 'o1561345583-n17'; -const o1561345583_nd18 = 'o1561345583-nd18'; -const o3474491051 = 'o3474491051'; -const o3474491051_nt = 'o3474491051-nt'; -const o3474491051_n5 = 'o3474491051-n5'; -const o3474491051_n6 = 'o3474491051-n6'; -const o3474491051_n7 = 'o3474491051-n7'; -const o3474491051_n8 = 'o3474491051-n8'; -const o1145023862 = 'o1145023862'; -const o1145023862_nt = 'o1145023862-nt'; -const o1145023862_n3 = 'o1145023862-n3'; -const o1145023862_t7 = 'o1145023862-t7'; -const o1145023862_n5 = 'o1145023862-n5'; -const o1145023862_n6 = 'o1145023862-n6'; -const o2443722130 = 'o2443722130'; -const o2443722130_nt = 'o2443722130-nt'; -const o2443722130_t3 = 'o2443722130-t3'; -const o2443722130_2 = 'o2443722130-2'; -const o2443722130_t6 = 'o2443722130-t6'; -const o171290282 = 'o171290282'; -const o171290282_nt = 'o171290282-nt'; -const o171290282_n5 = 'o171290282-n5'; -const o171290282_nd6 = 'o171290282-nd6'; -const o1517538778 = 'o1517538778'; -const o1517538778_nt = 'o1517538778-nt'; -const o1517538778_n5 = 'o1517538778-n5'; -const o1517538778_n6 = 'o1517538778-n6'; -const o1517538778_n7 = 'o1517538778-n7'; -const o1517538778_t16 = 'o1517538778-t16'; -const o1517538778_n9 = 'o1517538778-n9'; -const o1517538778_t21 = 'o1517538778-t21'; -const o1517538778_nd12 = 'o1517538778-nd12'; -const o1517538778_nd13 = 'o1517538778-nd13'; -const o1517538778_t30 = 'o1517538778-t30'; -const o1517538778_n15 = 'o1517538778-n15'; -const o1517538778_n16 = 'o1517538778-n16'; -const o1517538778_t37 = 'o1517538778-t37'; -const o3725575239 = 'o3725575239'; -const o3725575239_nt = 'o3725575239-nt'; -const o3725575239_n3 = 'o3725575239-n3'; -const o3725575239_t8 = 'o3725575239-t8'; -const o3725575239_n5 = 'o3725575239-n5'; -const o3725575239_n6 = 'o3725575239-n6'; -const o3725575239_n7 = 'o3725575239-n7'; -const o3725575239_n9 = 'o3725575239-n9'; -const o3725575239_t21 = 'o3725575239-t21'; -Ogone.types[o3076301467_nd17] = ogone_types_component; -Ogone.types[o3076301467_nt] = ogone_types_component; -Ogone.types[o4032646903_nt] = ogone_types_component; -Ogone.types[o1384895395_nd6] = ogone_types_async; -Ogone.types[o1384895395_nt] = ogone_types_async; -Ogone.types[o2465295184_nt] = ogone_types_component; -Ogone.types[o3104095500_nd7] = ogone_types_component; -Ogone.types[o3104095500_nd6] = ogone_types_component; -Ogone.types[o3104095500_nt] = ogone_types_component; -Ogone.types[o1710946592_nt] = ogone_types_store; -Ogone.types[o2010234397_nt] = ogone_types_controller; -Ogone.types[o2384155165_nd6] = ogone_types_component; -Ogone.types[o2384155165_nd8] = ogone_types_component; -Ogone.types[o2384155165_nd10] = ogone_types_component; -Ogone.types[o2384155165_nd5] = ogone_types_component; -Ogone.types[o2384155165_nt] = ogone_types_component; -Ogone.types[o325165413_nd6] = ogone_types_component; -Ogone.types[o325165413_nd17] = ogone_types_component; -Ogone.types[o325165413_nt] = ogone_types_component; -Ogone.types[o1561345583_nd9] = ogone_types_component; -Ogone.types[o1561345583_nd11] = ogone_types_component; -Ogone.types[o1561345583_nd13] = ogone_types_component; -Ogone.types[o1561345583_nd6] = ogone_types_component; -Ogone.types[o1561345583_nd16] = ogone_types_component; -Ogone.types[o1561345583_nt] = ogone_types_component; -Ogone.types[o3474491051_nt] = ogone_types_component; -Ogone.types[o1145023862_nt] = ogone_types_component; -Ogone.types[o2443722130_nt] = ogone_types_router; -Ogone.types[o171290282_nt] = ogone_types_component; -Ogone.types[o1517538778_nd13] = ogone_types_component; -Ogone.types[o1517538778_nd12] = ogone_types_component; -Ogone.types[o1517538778_nt] = ogone_types_component; -Ogone.types[o3725575239_nt] = ogone_types_component; -Ogone.components[o3076301467] = function(Onode) { +const o1370160080 = 'o1370160080'; +const o1370160080_nt = 'o1370160080-nt'; +const o1370160080_n12 = 'o1370160080-n12'; +const o1370160080_n13 = 'o1370160080-n13'; +const o1370160080_nd14 = 'o1370160080-nd14'; +const o1370160080_nd17 = 'o1370160080-nd17'; +const o1370160080_t37 = 'o1370160080-t37'; +const o1370160080_n19 = 'o1370160080-n19'; +const o1370160080_n21 = 'o1370160080-n21'; +const o1370160080_n22 = 'o1370160080-n22'; +const o1370160080_nd23 = 'o1370160080-nd23'; +const o262107635 = 'o262107635'; +const o262107635_nt = 'o262107635-nt'; +const o262107635_n3 = 'o262107635-n3'; +const o262107635_t7 = 'o262107635-t7'; +const o262107635_n5 = 'o262107635-n5'; +const o262107635_t12 = 'o262107635-t12'; +const o1580687313 = 'o1580687313'; +const o1580687313_nt = 'o1580687313-nt'; +const o1580687313_n3 = 'o1580687313-n3'; +const o1580687313_t8 = 'o1580687313-t8'; +const o1580687313_n5 = 'o1580687313-n5'; +const o1580687313_nd6 = 'o1580687313-nd6'; +const o918636327 = 'o918636327'; +const o918636327_nt = 'o918636327-nt'; +const o918636327_n5 = 'o918636327-n5'; +const o918636327_n6 = 'o918636327-n6'; +const o918636327_nd7 = 'o918636327-nd7'; +const o918636327_n9 = 'o918636327-n9'; +const o918636327_n10 = 'o918636327-n10'; +const o841766682 = 'o841766682'; +const o841766682_nt = 'o841766682-nt'; +const o841766682_n5 = 'o841766682-n5'; +const o841766682_nd6 = 'o841766682-nd6'; +const o841766682_nd7 = 'o841766682-nd7'; +const o841766682_n9 = 'o841766682-n9'; +const o841766682_n11 = 'o841766682-n11'; +const o44758046 = 'o44758046'; +const o44758046_nt = 'o44758046-nt'; +const o44758046_t3 = 'o44758046-t3'; +const o44758046_2 = 'o44758046-2'; +const o44758046_t6 = 'o44758046-t6'; +const o776663872 = 'o776663872'; +const o776663872_nt = 'o776663872-nt'; +const o776663872_2 = 'o776663872-2'; +const o776663872_t5 = 'o776663872-t5'; +const o776663872_n3 = 'o776663872-n3'; +const o776663872_t8 = 'o776663872-t8'; +const o776663872_t11 = 'o776663872-t11'; +const o2164776294 = 'o2164776294'; +const o2164776294_nt = 'o2164776294-nt'; +const o2164776294_nd5 = 'o2164776294-nd5'; +const o2164776294_t13 = 'o2164776294-t13'; +const o2164776294_nd6 = 'o2164776294-nd6'; +const o2164776294_nd8 = 'o2164776294-nd8'; +const o2164776294_nd10 = 'o2164776294-nd10'; +const o3575752143 = 'o3575752143'; +const o3575752143_nt = 'o3575752143-nt'; +const o3575752143_n5 = 'o3575752143-n5'; +const o3575752143_nd6 = 'o3575752143-nd6'; +const o3575752143_n7 = 'o3575752143-n7'; +const o3575752143_nd8 = 'o3575752143-nd8'; +const o3575752143_n10 = 'o3575752143-n10'; +const o3575752143_t23 = 'o3575752143-t23'; +const o3575752143_n13 = 'o3575752143-n13'; +const o3575752143_nd14 = 'o3575752143-nd14'; +const o3575752143_nd17 = 'o3575752143-nd17'; +const o1304491614 = 'o1304491614'; +const o1304491614_nt = 'o1304491614-nt'; +const o1304491614_n5 = 'o1304491614-n5'; +const o1304491614_nd6 = 'o1304491614-nd6'; +const o1304491614_n7 = 'o1304491614-n7'; +const o1304491614_t17 = 'o1304491614-t17'; +const o1304491614_nd9 = 'o1304491614-nd9'; +const o1304491614_t22 = 'o1304491614-t22'; +const o1304491614_nd11 = 'o1304491614-nd11'; +const o1304491614_t27 = 'o1304491614-t27'; +const o1304491614_nd13 = 'o1304491614-nd13'; +const o1304491614_t32 = 'o1304491614-t32'; +const o1304491614_nd16 = 'o1304491614-nd16'; +const o1304491614_n17 = 'o1304491614-n17'; +const o1304491614_nd18 = 'o1304491614-nd18'; +const o246739052 = 'o246739052'; +const o246739052_nt = 'o246739052-nt'; +const o246739052_n5 = 'o246739052-n5'; +const o246739052_n6 = 'o246739052-n6'; +const o246739052_n7 = 'o246739052-n7'; +const o246739052_n8 = 'o246739052-n8'; +const o3244593960 = 'o3244593960'; +const o3244593960_nt = 'o3244593960-nt'; +const o3244593960_n3 = 'o3244593960-n3'; +const o3244593960_t7 = 'o3244593960-t7'; +const o3244593960_n5 = 'o3244593960-n5'; +const o3244593960_n6 = 'o3244593960-n6'; +const o402642107 = 'o402642107'; +const o402642107_nt = 'o402642107-nt'; +const o402642107_t3 = 'o402642107-t3'; +const o402642107_2 = 'o402642107-2'; +const o402642107_t6 = 'o402642107-t6'; +const o2509604044 = 'o2509604044'; +const o2509604044_nt = 'o2509604044-nt'; +const o2509604044_n5 = 'o2509604044-n5'; +const o2509604044_nd6 = 'o2509604044-nd6'; +const o1177399929 = 'o1177399929'; +const o1177399929_nt = 'o1177399929-nt'; +const o1177399929_n5 = 'o1177399929-n5'; +const o1177399929_n6 = 'o1177399929-n6'; +const o1177399929_n7 = 'o1177399929-n7'; +const o1177399929_t16 = 'o1177399929-t16'; +const o1177399929_n9 = 'o1177399929-n9'; +const o1177399929_t21 = 'o1177399929-t21'; +const o1177399929_nd12 = 'o1177399929-nd12'; +const o1177399929_nd13 = 'o1177399929-nd13'; +const o1177399929_t30 = 'o1177399929-t30'; +const o1177399929_n15 = 'o1177399929-n15'; +const o1177399929_n16 = 'o1177399929-n16'; +const o1177399929_t37 = 'o1177399929-t37'; +const o3498884249 = 'o3498884249'; +const o3498884249_nt = 'o3498884249-nt'; +const o3498884249_n3 = 'o3498884249-n3'; +const o3498884249_t8 = 'o3498884249-t8'; +const o3498884249_n5 = 'o3498884249-n5'; +const o3498884249_n6 = 'o3498884249-n6'; +const o3498884249_n7 = 'o3498884249-n7'; +const o3498884249_n9 = 'o3498884249-n9'; +const o3498884249_t21 = 'o3498884249-t21'; +Ogone.types[o1370160080_nd17] = ogone_types_component; +Ogone.types[o1370160080_nt] = ogone_types_component; +Ogone.types[o262107635_nt] = ogone_types_component; +Ogone.types[o1580687313_nd6] = ogone_types_async; +Ogone.types[o1580687313_nt] = ogone_types_async; +Ogone.types[o918636327_nt] = ogone_types_component; +Ogone.types[o841766682_nd7] = ogone_types_component; +Ogone.types[o841766682_nd6] = ogone_types_component; +Ogone.types[o841766682_nt] = ogone_types_component; +Ogone.types[o44758046_nt] = ogone_types_store; +Ogone.types[o776663872_nt] = ogone_types_controller; +Ogone.types[o2164776294_nd6] = ogone_types_component; +Ogone.types[o2164776294_nd8] = ogone_types_component; +Ogone.types[o2164776294_nd10] = ogone_types_component; +Ogone.types[o2164776294_nd5] = ogone_types_component; +Ogone.types[o2164776294_nt] = ogone_types_component; +Ogone.types[o3575752143_nd6] = ogone_types_component; +Ogone.types[o3575752143_nd17] = ogone_types_component; +Ogone.types[o3575752143_nt] = ogone_types_component; +Ogone.types[o1304491614_nd9] = ogone_types_component; +Ogone.types[o1304491614_nd11] = ogone_types_component; +Ogone.types[o1304491614_nd13] = ogone_types_component; +Ogone.types[o1304491614_nd6] = ogone_types_component; +Ogone.types[o1304491614_nd16] = ogone_types_component; +Ogone.types[o1304491614_nt] = ogone_types_component; +Ogone.types[o246739052_nt] = ogone_types_component; +Ogone.types[o3244593960_nt] = ogone_types_component; +Ogone.types[o402642107_nt] = ogone_types_router; +Ogone.types[o2509604044_nt] = ogone_types_component; +Ogone.types[o1177399929_nd13] = ogone_types_component; +Ogone.types[o1177399929_nd12] = ogone_types_component; +Ogone.types[o1177399929_nt] = ogone_types_component; +Ogone.types[o3498884249_nt] = ogone_types_component; +Ogone.components[o1370160080] = function(Onode) { + const { Obj: Obj1 } = Ogone.require['dep_6426190445621257115']; let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o3076301467] = Ogone.protocols[o3076301467] || class Protocol { - test = Obj; + Ogone.protocols[o1370160080] = Ogone.protocols[o1370160080] || class Protocol { + test = Obj1; scrollY = 0; setScrollY(n) { this.scrollY = n; } }; - const data = setReactivity(new Ogone.protocols[o3076301467], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o1370160080], (prop)=>OnodeUpdate(Onode, prop) ); return { data, Refs, runtime: (function runtime(_state, ctx, event, _once = 0) { try { + const { Obj: Obj11 } = Ogone.require['dep_6426190445621257115']; if (typeof _state === "string" && ![].includes(_state)) { return; } @@ -2078,15 +2453,15 @@ Ogone.components[o3076301467] = function(Onode) { }).bind(data) }; }; -Ogone.components[o4032646903] = function(Onode) { +Ogone.components[o262107635] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2109,15 +2484,15 @@ Ogone.components[o4032646903] = function(Onode) { }).bind(data) }; }; -Ogone.components[o1384895395] = function(Onode) { +Ogone.components[o1580687313] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2164,15 +2539,15 @@ Ogone.components[o1384895395] = function(Onode) { }).bind(data) }; }; -Ogone.components[o2465295184] = function(Onode) { +Ogone.components[o918636327] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2221,7 +2596,9 @@ Ogone.components[o2465295184] = function(Onode) { }).bind(data) }; }; -Ogone.components[o3104095500] = function(Onode) { +Ogone.components[o841766682] = function(Onode) { + const { print , } = Ogone.require['dep_51506147711985763655']; + const { attr , } = Ogone.require['dep_58806555621990634570']; let Controllers; const Store = { dispatch: (id, ctx)=>{ @@ -2278,22 +2655,24 @@ Ogone.components[o3104095500] = function(Onode) { OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o3104095500] = Ogone.protocols[o3104095500] || class Protocol { + Ogone.protocols[o841766682] = Ogone.protocols[o841766682] || class Protocol { isOpen = false; }; - const data = setReactivity(new Ogone.protocols[o3104095500], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o841766682], (prop)=>OnodeUpdate(Onode, prop) ); return { data, Refs, runtime: (function runtime(_state, ctx, event, _once = 0) { try { + const { print: print1 , } = Ogone.require['dep_51506147711985763655']; + const { attr: attr1 , } = Ogone.require['dep_58806555621990634570']; if (typeof _state === "string" && ![ 'click:openMenu' ].includes(_state)) { @@ -2301,7 +2680,7 @@ Ogone.components[o3104095500] = function(Onode) { } switch(_state){ case 'click:openMenu': - print(10, 'this is a test for modules'); + print1(10, 'this is a test for modules'); Store.dispatch('menu/toggle'); Store.dispatch('menu/checkController').then((res)=>{ console.warn(res); @@ -2316,7 +2695,7 @@ Ogone.components[o3104095500] = function(Onode) { }).bind(data) }; }; -Ogone.components[o1710946592] = function(Onode) { +Ogone.components[o44758046] = function(Onode) { const Controllers = { }; Controllers["UserController"] = { @@ -2370,16 +2749,16 @@ Ogone.components[o1710946592] = function(Onode) { OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o1710946592] = Ogone.protocols[o1710946592] || class Protocol { + Ogone.protocols[o44758046] = Ogone.protocols[o44758046] || class Protocol { isOpen = false; }; - const data = setReactivity(new Ogone.protocols[o1710946592], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o44758046], (prop)=>OnodeUpdate(Onode, prop) ); return { data, @@ -2409,23 +2788,23 @@ Ogone.components[o1710946592] = function(Onode) { }).bind(data) }; }; -Ogone.components[o2010234397] = function(Onode) { +Ogone.components[o776663872] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o2010234397] = Ogone.protocols[o2010234397] || class Protocol { + Ogone.protocols[o776663872] = Ogone.protocols[o776663872] || class Protocol { name = "SRNV"; }; - const data = setReactivity(new Ogone.protocols[o2010234397], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o776663872], (prop)=>OnodeUpdate(Onode, prop) ); return { data, @@ -2452,27 +2831,27 @@ Ogone.components[o2010234397] = function(Onode) { }).bind(data) }; }; -Ogone.components[o2384155165] = function(Onode) { +Ogone.components[o2164776294] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o2384155165] = Ogone.protocols[o2384155165] || class Protocol { + Ogone.protocols[o2164776294] = Ogone.protocols[o2164776294] || class Protocol { buttonOpts = { name: 'Test', route: '', status: 'todo' }; }; - const data = setReactivity(new Ogone.protocols[o2384155165], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o2164776294], (prop)=>OnodeUpdate(Onode, prop) ); return { data, @@ -2489,7 +2868,7 @@ Ogone.components[o2384155165] = function(Onode) { }).bind(data) }; }; -Ogone.components[o325165413] = function(Onode) { +Ogone.components[o3575752143] = function(Onode) { let Controllers; const Store = { dispatch: (id, ctx)=>{ @@ -2546,8 +2925,8 @@ Ogone.components[o325165413] = function(Onode) { OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2766,20 +3145,20 @@ Ogone.components[o325165413] = function(Onode) { }).bind(data) }; }; -Ogone.components[o1561345583] = function(Onode) { +Ogone.components[o1304491614] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o1561345583] = Ogone.protocols[o1561345583] || class Protocol { + Ogone.protocols[o1304491614] = Ogone.protocols[o1304491614] || class Protocol { openTree = false; inp = this.openTree ? 'open' : 'closed'; item = { @@ -2789,7 +3168,7 @@ Ogone.components[o1561345583] = function(Onode) { children: [] }; }; - const data = setReactivity(new Ogone.protocols[o1561345583], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o1304491614], (prop)=>OnodeUpdate(Onode, prop) ); return { data, @@ -2815,15 +3194,15 @@ Ogone.components[o1561345583] = function(Onode) { }).bind(data) }; }; -Ogone.components[o3474491051] = function(Onode) { +Ogone.components[o246739052] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2845,15 +3224,15 @@ Ogone.components[o3474491051] = function(Onode) { }).bind(data) }; }; -Ogone.components[o1145023862] = function(Onode) { +Ogone.components[o3244593960] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2875,15 +3254,15 @@ Ogone.components[o1145023862] = function(Onode) { }).bind(data) }; }; -Ogone.components[o2443722130] = function(Onode) { +Ogone.components[o402642107] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2905,15 +3284,15 @@ Ogone.components[o2443722130] = function(Onode) { }).bind(data) }; }; -Ogone.components[o171290282] = function(Onode) { +Ogone.components[o2509604044] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -2953,26 +3332,26 @@ Ogone.components[o171290282] = function(Onode) { }).bind(data) }; }; -Ogone.components[o1517538778] = function(Onode) { +Ogone.components[o1177399929] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; let Async; - Ogone.protocols[o1517538778] = Ogone.protocols[o1517538778] || class Protocol { + Ogone.protocols[o1177399929] = Ogone.protocols[o1177399929] || class Protocol { title = 'untitled'; text = 'no text'; code = "..."; page = ""; }; - const data = setReactivity(new Ogone.protocols[o1517538778], (prop)=>OnodeUpdate(Onode, prop) + const data = setReactivity(new Ogone.protocols[o1177399929], (prop)=>OnodeUpdate(Onode, prop) ); return { data, @@ -2989,15 +3368,15 @@ Ogone.components[o1517538778] = function(Onode) { }).bind(data) }; }; -Ogone.components[o3725575239] = function(Onode) { +Ogone.components[o3498884249] = function(Onode) { let Controllers; let Store; const ___ = (prop, inst, value)=>{ OnodeUpdate(Onode, prop); return value; }; - const ____r = (name, use, once)=>{ - Onode.component.runtime(name, use[0], use[1], once); + const ____r = (name2, use, once)=>{ + Onode.component.runtime(name2, use[0], use[1], once); }; const Refs = { }; @@ -3019,7 +3398,7 @@ Ogone.components[o3725575239] = function(Onode) { }).bind(data) }; }; -Ogone.contexts[o3725575239_nt] = function(opts) { +Ogone.contexts[o3498884249_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3037,14 +3416,14 @@ Ogone.contexts[o3725575239_nt] = function(opts) { throw err; } }; -Ogone.contexts[o3725575239_n5] = Ogone.contexts[o3725575239_nt]; -Ogone.contexts[o3725575239_n9] = Ogone.contexts[o3725575239_n5]; -Ogone.contexts[o3725575239_t21] = Ogone.contexts[o3725575239_n9]; -Ogone.contexts[o3725575239_n6] = Ogone.contexts[o3725575239_n5]; -Ogone.contexts[o3725575239_n7] = Ogone.contexts[o3725575239_n6]; -Ogone.contexts[o3725575239_n3] = Ogone.contexts[o3725575239_nt]; -Ogone.contexts[o3725575239_t8] = Ogone.contexts[o3725575239_n3]; -Ogone.contexts[o1517538778_nt] = function(opts) { +Ogone.contexts[o3498884249_n5] = Ogone.contexts[o3498884249_nt]; +Ogone.contexts[o3498884249_n9] = Ogone.contexts[o3498884249_n5]; +Ogone.contexts[o3498884249_t21] = Ogone.contexts[o3498884249_n9]; +Ogone.contexts[o3498884249_n6] = Ogone.contexts[o3498884249_n5]; +Ogone.contexts[o3498884249_n7] = Ogone.contexts[o3498884249_n6]; +Ogone.contexts[o3498884249_n3] = Ogone.contexts[o3498884249_nt]; +Ogone.contexts[o3498884249_t8] = Ogone.contexts[o3498884249_n3]; +Ogone.contexts[o1177399929_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3062,8 +3441,8 @@ Ogone.contexts[o1517538778_nt] = function(opts) { throw err; } }; -Ogone.contexts[o1517538778_n5] = Ogone.contexts[o1517538778_nt]; -Ogone.contexts[o1517538778_nd12] = function(opts) { +Ogone.contexts[o1177399929_n5] = Ogone.contexts[o1177399929_nt]; +Ogone.contexts[o1177399929_nd12] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3084,10 +3463,10 @@ Ogone.contexts[o1517538778_nd12] = function(opts) { throw err; } }; -Ogone.contexts[o1517538778_n15] = Ogone.contexts[o1517538778_nd12]; -Ogone.contexts[o1517538778_n16] = Ogone.contexts[o1517538778_n15]; -Ogone.contexts[o1517538778_t37] = Ogone.contexts[o1517538778_n16]; -Ogone.contexts[o1517538778_nd13] = function(opts) { +Ogone.contexts[o1177399929_n15] = Ogone.contexts[o1177399929_nd12]; +Ogone.contexts[o1177399929_n16] = Ogone.contexts[o1177399929_n15]; +Ogone.contexts[o1177399929_t37] = Ogone.contexts[o1177399929_n16]; +Ogone.contexts[o1177399929_nd13] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3108,13 +3487,13 @@ Ogone.contexts[o1517538778_nd13] = function(opts) { throw err; } }; -Ogone.contexts[o1517538778_t30] = Ogone.contexts[o1517538778_nd13]; -Ogone.contexts[o1517538778_n6] = Ogone.contexts[o1517538778_n5]; -Ogone.contexts[o1517538778_n9] = Ogone.contexts[o1517538778_n6]; -Ogone.contexts[o1517538778_t21] = Ogone.contexts[o1517538778_n9]; -Ogone.contexts[o1517538778_n7] = Ogone.contexts[o1517538778_n6]; -Ogone.contexts[o1517538778_t16] = Ogone.contexts[o1517538778_n7]; -Ogone.contexts[o171290282_nt] = function(opts) { +Ogone.contexts[o1177399929_t30] = Ogone.contexts[o1177399929_nd13]; +Ogone.contexts[o1177399929_n6] = Ogone.contexts[o1177399929_n5]; +Ogone.contexts[o1177399929_n9] = Ogone.contexts[o1177399929_n6]; +Ogone.contexts[o1177399929_t21] = Ogone.contexts[o1177399929_n9]; +Ogone.contexts[o1177399929_n7] = Ogone.contexts[o1177399929_n6]; +Ogone.contexts[o1177399929_t16] = Ogone.contexts[o1177399929_n7]; +Ogone.contexts[o2509604044_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3132,14 +3511,14 @@ Ogone.contexts[o171290282_nt] = function(opts) { throw err; } }; -Ogone.contexts[o171290282_n5] = Ogone.contexts[o171290282_nt]; -Ogone.contexts[o171290282_nd6] = function(opts) { +Ogone.contexts[o2509604044_n5] = Ogone.contexts[o2509604044_nt]; +Ogone.contexts[o2509604044_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; - const _____a_7 = Ogone.arrays[o171290282_nd6] || !!this.articles && this.articles || []; + const _____a_7 = Ogone.arrays[o2509604044_nd6] || !!this.articles && this.articles || []; let i6 = POSITION[2], article = _____a_7[i6]; - if (Ogone.arrays[o171290282_nd6] !== _____a_7) Ogone.arrays[o171290282_nd6] = _____a_7; + if (Ogone.arrays[o2509604044_nd6] !== _____a_7) Ogone.arrays[o2509604044_nd6] = _____a_7; if (GET_LENGTH) { if (!_____a_7) { return 0; @@ -3162,7 +3541,7 @@ Ogone.contexts[o171290282_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o2443722130_nt] = function(opts) { +Ogone.contexts[o402642107_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3180,10 +3559,10 @@ Ogone.contexts[o2443722130_nt] = function(opts) { throw err; } }; -Ogone.contexts[o2443722130_t6] = Ogone.contexts[o2443722130_2]; -Ogone.contexts[o2443722130_t3] = Ogone.contexts[o2443722130_nt]; -Ogone.contexts[o2443722130_2] = Ogone.contexts[o2443722130_nt]; -Ogone.contexts[o1145023862_nt] = function(opts) { +Ogone.contexts[o402642107_t6] = Ogone.contexts[o402642107_2]; +Ogone.contexts[o402642107_t3] = Ogone.contexts[o402642107_nt]; +Ogone.contexts[o402642107_2] = Ogone.contexts[o402642107_nt]; +Ogone.contexts[o3244593960_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3201,11 +3580,11 @@ Ogone.contexts[o1145023862_nt] = function(opts) { throw err; } }; -Ogone.contexts[o1145023862_n5] = Ogone.contexts[o1145023862_nt]; -Ogone.contexts[o1145023862_n6] = Ogone.contexts[o1145023862_n5]; -Ogone.contexts[o1145023862_n3] = Ogone.contexts[o1145023862_nt]; -Ogone.contexts[o1145023862_t7] = Ogone.contexts[o1145023862_n3]; -Ogone.contexts[o3474491051_nt] = function(opts) { +Ogone.contexts[o3244593960_n5] = Ogone.contexts[o3244593960_nt]; +Ogone.contexts[o3244593960_n6] = Ogone.contexts[o3244593960_n5]; +Ogone.contexts[o3244593960_n3] = Ogone.contexts[o3244593960_nt]; +Ogone.contexts[o3244593960_t7] = Ogone.contexts[o3244593960_n3]; +Ogone.contexts[o246739052_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3223,11 +3602,11 @@ Ogone.contexts[o3474491051_nt] = function(opts) { throw err; } }; -Ogone.contexts[o3474491051_n5] = Ogone.contexts[o3474491051_nt]; -Ogone.contexts[o3474491051_n6] = Ogone.contexts[o3474491051_n5]; -Ogone.contexts[o3474491051_n7] = Ogone.contexts[o3474491051_n6]; -Ogone.contexts[o3474491051_n8] = Ogone.contexts[o3474491051_n7]; -Ogone.contexts[o1561345583_nt] = function(opts) { +Ogone.contexts[o246739052_n5] = Ogone.contexts[o246739052_nt]; +Ogone.contexts[o246739052_n6] = Ogone.contexts[o246739052_n5]; +Ogone.contexts[o246739052_n7] = Ogone.contexts[o246739052_n6]; +Ogone.contexts[o246739052_n8] = Ogone.contexts[o246739052_n7]; +Ogone.contexts[o1304491614_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3245,8 +3624,8 @@ Ogone.contexts[o1561345583_nt] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_n5] = Ogone.contexts[o1561345583_nt]; -Ogone.contexts[o1561345583_nd16] = function(opts) { +Ogone.contexts[o1304491614_n5] = Ogone.contexts[o1304491614_nt]; +Ogone.contexts[o1304491614_nd16] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3267,8 +3646,8 @@ Ogone.contexts[o1561345583_nd16] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_n17] = Ogone.contexts[o1561345583_nd16]; -Ogone.contexts[o1561345583_nd18] = function(opts) { +Ogone.contexts[o1304491614_n17] = Ogone.contexts[o1304491614_nd16]; +Ogone.contexts[o1304491614_nd18] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3296,7 +3675,7 @@ Ogone.contexts[o1561345583_nd18] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_nd6] = function(opts) { +Ogone.contexts[o1304491614_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3314,7 +3693,7 @@ Ogone.contexts[o1561345583_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_nd13] = function(opts) { +Ogone.contexts[o1304491614_nd13] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3337,8 +3716,8 @@ Ogone.contexts[o1561345583_nd13] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_t32] = Ogone.contexts[o1561345583_nd13]; -Ogone.contexts[o1561345583_nd11] = function(opts) { +Ogone.contexts[o1304491614_t32] = Ogone.contexts[o1304491614_nd13]; +Ogone.contexts[o1304491614_nd11] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3359,8 +3738,8 @@ Ogone.contexts[o1561345583_nd11] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_t27] = Ogone.contexts[o1561345583_nd11]; -Ogone.contexts[o1561345583_nd9] = function(opts) { +Ogone.contexts[o1304491614_t27] = Ogone.contexts[o1304491614_nd11]; +Ogone.contexts[o1304491614_nd9] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3378,10 +3757,10 @@ Ogone.contexts[o1561345583_nd9] = function(opts) { throw err; } }; -Ogone.contexts[o1561345583_t22] = Ogone.contexts[o1561345583_nd9]; -Ogone.contexts[o1561345583_n7] = Ogone.contexts[o1561345583_nd6]; -Ogone.contexts[o1561345583_t17] = Ogone.contexts[o1561345583_n7]; -Ogone.contexts[o325165413_nt] = function(opts) { +Ogone.contexts[o1304491614_t22] = Ogone.contexts[o1304491614_nd9]; +Ogone.contexts[o1304491614_n7] = Ogone.contexts[o1304491614_nd6]; +Ogone.contexts[o1304491614_t17] = Ogone.contexts[o1304491614_n7]; +Ogone.contexts[o3575752143_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3399,7 +3778,7 @@ Ogone.contexts[o325165413_nt] = function(opts) { throw err; } }; -Ogone.contexts[o325165413_nd17] = function(opts) { +Ogone.contexts[o3575752143_nd17] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3417,7 +3796,7 @@ Ogone.contexts[o325165413_nd17] = function(opts) { throw err; } }; -Ogone.contexts[o325165413_nd6] = function(opts) { +Ogone.contexts[o3575752143_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3435,14 +3814,14 @@ Ogone.contexts[o325165413_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o325165413_n13] = Ogone.contexts[o325165413_nd6]; -Ogone.contexts[o325165413_nd14] = function(opts) { +Ogone.contexts[o3575752143_n13] = Ogone.contexts[o3575752143_nd6]; +Ogone.contexts[o3575752143_nd14] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; - const _____a_3 = Ogone.arrays[o325165413_nd14] || !!this.menu && this.menu || []; + const _____a_3 = Ogone.arrays[o3575752143_nd14] || !!this.menu && this.menu || []; let i2 = POSITION[3], item = _____a_3[i2]; - if (Ogone.arrays[o325165413_nd14] !== _____a_3) Ogone.arrays[o325165413_nd14] = _____a_3; + if (Ogone.arrays[o3575752143_nd14] !== _____a_3) Ogone.arrays[o3575752143_nd14] = _____a_3; if (GET_LENGTH) { if (!_____a_3) { return 0; @@ -3465,10 +3844,10 @@ Ogone.contexts[o325165413_nd14] = function(opts) { throw err; } }; -Ogone.contexts[o325165413_n7] = Ogone.contexts[o325165413_nd6]; -Ogone.contexts[o325165413_n10] = Ogone.contexts[o325165413_n7]; -Ogone.contexts[o325165413_t23] = Ogone.contexts[o325165413_n10]; -Ogone.contexts[o325165413_nd8] = function(opts) { +Ogone.contexts[o3575752143_n7] = Ogone.contexts[o3575752143_nd6]; +Ogone.contexts[o3575752143_n10] = Ogone.contexts[o3575752143_n7]; +Ogone.contexts[o3575752143_t23] = Ogone.contexts[o3575752143_n10]; +Ogone.contexts[o3575752143_nd8] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3486,8 +3865,8 @@ Ogone.contexts[o325165413_nd8] = function(opts) { throw err; } }; -Ogone.contexts[o325165413_n5] = Ogone.contexts[o325165413_nt]; -Ogone.contexts[o2384155165_nt] = function(opts) { +Ogone.contexts[o3575752143_n5] = Ogone.contexts[o3575752143_nt]; +Ogone.contexts[o2164776294_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3505,7 +3884,7 @@ Ogone.contexts[o2384155165_nt] = function(opts) { throw err; } }; -Ogone.contexts[o2384155165_nd5] = function(opts) { +Ogone.contexts[o2164776294_nd5] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3523,7 +3902,7 @@ Ogone.contexts[o2384155165_nd5] = function(opts) { throw err; } }; -Ogone.contexts[o2384155165_nd10] = function(opts) { +Ogone.contexts[o2164776294_nd10] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3544,7 +3923,7 @@ Ogone.contexts[o2384155165_nd10] = function(opts) { throw err; } }; -Ogone.contexts[o2384155165_nd8] = function(opts) { +Ogone.contexts[o2164776294_nd8] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3565,7 +3944,7 @@ Ogone.contexts[o2384155165_nd8] = function(opts) { throw err; } }; -Ogone.contexts[o2384155165_nd6] = function(opts) { +Ogone.contexts[o2164776294_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3586,8 +3965,8 @@ Ogone.contexts[o2384155165_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o2384155165_t13] = Ogone.contexts[o2384155165_nd5]; -Ogone.contexts[o2010234397_nt] = function(opts) { +Ogone.contexts[o2164776294_t13] = Ogone.contexts[o2164776294_nd5]; +Ogone.contexts[o776663872_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3605,12 +3984,12 @@ Ogone.contexts[o2010234397_nt] = function(opts) { throw err; } }; -Ogone.contexts[o2010234397_t11] = Ogone.contexts[o2010234397_2]; -Ogone.contexts[o2010234397_n3] = Ogone.contexts[o2010234397_2]; -Ogone.contexts[o2010234397_t8] = Ogone.contexts[o2010234397_n3]; -Ogone.contexts[o2010234397_t5] = Ogone.contexts[o2010234397_2]; -Ogone.contexts[o2010234397_2] = Ogone.contexts[o2010234397_nt]; -Ogone.contexts[o1710946592_nt] = function(opts) { +Ogone.contexts[o776663872_t11] = Ogone.contexts[o776663872_2]; +Ogone.contexts[o776663872_n3] = Ogone.contexts[o776663872_2]; +Ogone.contexts[o776663872_t8] = Ogone.contexts[o776663872_n3]; +Ogone.contexts[o776663872_t5] = Ogone.contexts[o776663872_2]; +Ogone.contexts[o776663872_2] = Ogone.contexts[o776663872_nt]; +Ogone.contexts[o44758046_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3628,13 +4007,15 @@ Ogone.contexts[o1710946592_nt] = function(opts) { throw err; } }; -Ogone.contexts[o1710946592_t6] = Ogone.contexts[o1710946592_2]; -Ogone.contexts[o1710946592_t3] = Ogone.contexts[o1710946592_nt]; -Ogone.contexts[o1710946592_2] = Ogone.contexts[o1710946592_nt]; -Ogone.contexts[o3104095500_nt] = function(opts) { +Ogone.contexts[o44758046_t6] = Ogone.contexts[o44758046_2]; +Ogone.contexts[o44758046_t3] = Ogone.contexts[o44758046_nt]; +Ogone.contexts[o44758046_2] = Ogone.contexts[o44758046_nt]; +Ogone.contexts[o841766682_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { print , } = Ogone.require['dep_51506147711985763655']; + const { attr , } = Ogone.require['dep_58806555621990634570']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3649,10 +4030,12 @@ Ogone.contexts[o3104095500_nt] = function(opts) { throw err; } }; -Ogone.contexts[o3104095500_nd6] = function(opts) { +Ogone.contexts[o841766682_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { print , } = Ogone.require['dep_51506147711985763655']; + const { attr , } = Ogone.require['dep_58806555621990634570']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3667,12 +4050,14 @@ Ogone.contexts[o3104095500_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o3104095500_n11] = Ogone.contexts[o3104095500_nd6]; -Ogone.contexts[o3104095500_n9] = Ogone.contexts[o3104095500_nd6]; -Ogone.contexts[o3104095500_nd7] = function(opts) { +Ogone.contexts[o841766682_n11] = Ogone.contexts[o841766682_nd6]; +Ogone.contexts[o841766682_n9] = Ogone.contexts[o841766682_nd6]; +Ogone.contexts[o841766682_nd7] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { print , } = Ogone.require['dep_51506147711985763655']; + const { attr , } = Ogone.require['dep_58806555621990634570']; if (GET_LENGTH) { return 1; } @@ -3690,8 +4075,8 @@ Ogone.contexts[o3104095500_nd7] = function(opts) { throw err; } }; -Ogone.contexts[o3104095500_n5] = Ogone.contexts[o3104095500_nt]; -Ogone.contexts[o2465295184_nt] = function(opts) { +Ogone.contexts[o841766682_n5] = Ogone.contexts[o841766682_nt]; +Ogone.contexts[o918636327_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3709,17 +4094,17 @@ Ogone.contexts[o2465295184_nt] = function(opts) { throw err; } }; -Ogone.contexts[o2465295184_n5] = Ogone.contexts[o2465295184_nt]; -Ogone.contexts[o2465295184_n9] = Ogone.contexts[o2465295184_n5]; -Ogone.contexts[o2465295184_n10] = Ogone.contexts[o2465295184_n9]; -Ogone.contexts[o2465295184_n6] = Ogone.contexts[o2465295184_n5]; -Ogone.contexts[o2465295184_nd7] = function(opts) { +Ogone.contexts[o918636327_n5] = Ogone.contexts[o918636327_nt]; +Ogone.contexts[o918636327_n9] = Ogone.contexts[o918636327_n5]; +Ogone.contexts[o918636327_n10] = Ogone.contexts[o918636327_n9]; +Ogone.contexts[o918636327_n6] = Ogone.contexts[o918636327_n5]; +Ogone.contexts[o918636327_nd7] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; - const _____a_1 = Ogone.arrays[o2465295184_nd7] || !!this.menu && this.menu || []; + const _____a_1 = Ogone.arrays[o918636327_nd7] || !!this.menu && this.menu || []; let i0 = POSITION[3], t = _____a_1[i0]; - if (Ogone.arrays[o2465295184_nd7] !== _____a_1) Ogone.arrays[o2465295184_nd7] = _____a_1; + if (Ogone.arrays[o918636327_nd7] !== _____a_1) Ogone.arrays[o918636327_nd7] = _____a_1; if (GET_LENGTH) { if (!_____a_1) { return 0; @@ -3742,7 +4127,7 @@ Ogone.contexts[o2465295184_nd7] = function(opts) { throw err; } }; -Ogone.contexts[o1384895395_nt] = function(opts) { +Ogone.contexts[o1580687313_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3760,8 +4145,8 @@ Ogone.contexts[o1384895395_nt] = function(opts) { throw err; } }; -Ogone.contexts[o1384895395_n5] = Ogone.contexts[o1384895395_nt]; -Ogone.contexts[o1384895395_nd6] = function(opts) { +Ogone.contexts[o1580687313_n5] = Ogone.contexts[o1580687313_nt]; +Ogone.contexts[o1580687313_nd6] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3779,9 +4164,9 @@ Ogone.contexts[o1384895395_nd6] = function(opts) { throw err; } }; -Ogone.contexts[o1384895395_n3] = Ogone.contexts[o1384895395_nt]; -Ogone.contexts[o1384895395_t8] = Ogone.contexts[o1384895395_n3]; -Ogone.contexts[o4032646903_nt] = function(opts) { +Ogone.contexts[o1580687313_n3] = Ogone.contexts[o1580687313_nt]; +Ogone.contexts[o1580687313_t8] = Ogone.contexts[o1580687313_n3]; +Ogone.contexts[o262107635_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; @@ -3799,14 +4184,15 @@ Ogone.contexts[o4032646903_nt] = function(opts) { throw err; } }; -Ogone.contexts[o4032646903_n5] = Ogone.contexts[o4032646903_nt]; -Ogone.contexts[o4032646903_t12] = Ogone.contexts[o4032646903_n5]; -Ogone.contexts[o4032646903_n3] = Ogone.contexts[o4032646903_nt]; -Ogone.contexts[o4032646903_t7] = Ogone.contexts[o4032646903_n3]; -Ogone.contexts[o3076301467_nt] = function(opts) { +Ogone.contexts[o262107635_n5] = Ogone.contexts[o262107635_nt]; +Ogone.contexts[o262107635_t12] = Ogone.contexts[o262107635_n5]; +Ogone.contexts[o262107635_n3] = Ogone.contexts[o262107635_nt]; +Ogone.contexts[o262107635_t7] = Ogone.contexts[o262107635_n3]; +Ogone.contexts[o1370160080_nt] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { Obj: Obj1 } = Ogone.require['dep_6426190445621257115']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3821,10 +4207,11 @@ Ogone.contexts[o3076301467_nt] = function(opts) { throw err; } }; -Ogone.contexts[o3076301467_nd23] = function(opts) { +Ogone.contexts[o1370160080_nd23] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { Obj: Obj1 } = Ogone.require['dep_6426190445621257115']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3839,14 +4226,15 @@ Ogone.contexts[o3076301467_nd23] = function(opts) { throw err; } }; -Ogone.contexts[o3076301467_n22] = Ogone.contexts[o3076301467_nt]; -Ogone.contexts[o3076301467_n21] = Ogone.contexts[o3076301467_nt]; -Ogone.contexts[o3076301467_n12] = Ogone.contexts[o3076301467_nt]; -Ogone.contexts[o3076301467_n19] = Ogone.contexts[o3076301467_n12]; -Ogone.contexts[o3076301467_nd17] = function(opts) { +Ogone.contexts[o1370160080_n22] = Ogone.contexts[o1370160080_nt]; +Ogone.contexts[o1370160080_n21] = Ogone.contexts[o1370160080_nt]; +Ogone.contexts[o1370160080_n12] = Ogone.contexts[o1370160080_nt]; +Ogone.contexts[o1370160080_n19] = Ogone.contexts[o1370160080_n12]; +Ogone.contexts[o1370160080_nd17] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { Obj: Obj1 } = Ogone.require['dep_6426190445621257115']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3861,12 +4249,13 @@ Ogone.contexts[o3076301467_nd17] = function(opts) { throw err; } }; -Ogone.contexts[o3076301467_t37] = Ogone.contexts[o3076301467_nd17]; -Ogone.contexts[o3076301467_n13] = Ogone.contexts[o3076301467_n12]; -Ogone.contexts[o3076301467_nd14] = function(opts) { +Ogone.contexts[o1370160080_t37] = Ogone.contexts[o1370160080_nd17]; +Ogone.contexts[o1370160080_n13] = Ogone.contexts[o1370160080_n12]; +Ogone.contexts[o1370160080_nd14] = function(opts) { const GET_TEXT = opts.getText; const GET_LENGTH = opts.getLength; const POSITION = opts.position; + const { Obj: Obj1 } = Ogone.require['dep_6426190445621257115']; try { if (GET_TEXT) { return eval('(' + GET_TEXT + ')'); @@ -3881,27 +4270,27 @@ Ogone.contexts[o3076301467_nd14] = function(opts) { throw err; } }; -Ogone.render[o3076301467_nd17] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1370160080_nd17] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd17 = _h(___div_), t37 = `Dev`; - _at(nd17, o3076301467, ''); + _at(nd17, o1370160080, ''); _at(nd17, 'class', 'open-dev-tool'); _ap(nd17, t37); return nd17; }; -Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1370160080_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n12 = _h(___div_), n13 = _h(___div_), nd14 = _h(_ogone_node_), nd17 = _h(_ogone_node_), t37 = `Dev`, n19 = _h(_ogone_node_), n21 = _h(_ogone_node_), n22 = _h(_ogone_node_), nd23 = _h(_ogone_node_); - _at(nt, o3076301467, ''); + _at(nt, o1370160080, ''); l++; - _at(n12, o3076301467, ''); + _at(n12, o1370160080, ''); ctx.refs['head'] = ctx.refs['head'] || []; ctx.refs['head'][i] = n12; _at(n12, 'class', 'header'); l++; - _at(n13, o3076301467, ''); + _at(n13, o1370160080, ''); _at(n13, 'class', 'logo'); l++; o = { @@ -3932,13 +4321,13 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3076301467', + uuid: 'o1370160080', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3076301467-nd14', + parentCTXId: 'o1370160080-nd14', props: [], - uuid: 'o1384895395', + uuid: 'o1580687313', routes: null, namespace: '', requirements: [], @@ -3947,7 +4336,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { nd14.placeholder = o.placeholder; setOgone(nd14, o); o = null; - _at(nd14, o3076301467, ''); + _at(nd14, o1370160080, ''); l--; _ap(n13, nd14); o = { @@ -3981,12 +4370,12 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd17', - uuid: 'o3076301467' + uuid: 'o1370160080' }; nd17.placeholder = o.placeholder; setOgone(nd17, o); o = null; - _at(nd17, o3076301467, ''); + _at(nd17, o1370160080, ''); _ap(nd17, t37); o = { isRoot: false, @@ -4010,13 +4399,13 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3076301467', + uuid: 'o1370160080', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3076301467-n19', + parentCTXId: 'o1370160080-n19', props: [], - uuid: 'o2465295184', + uuid: 'o918636327', routes: null, namespace: '', requirements: [], @@ -4025,7 +4414,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { n19.placeholder = o.placeholder; setOgone(n19, o); o = null; - _at(n19, o3076301467, ''); + _at(n19, o1370160080, ''); l--; _ap(n12, n13); _ap(n12, nd17); @@ -4052,20 +4441,20 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3076301467', + uuid: 'o1370160080', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3076301467-n21', + parentCTXId: 'o1370160080-n21', props: [], - uuid: 'o2443722130', + uuid: 'o402642107', routes: [ { "path": "/doc", "name": "documentation", - "component": "o171290282-nt", + "component": "o2509604044-nt", "title": "Ogone - documentation", - "uuid": "o171290282", + "uuid": "o2509604044", "isAsync": false, "isRouter": false, "isTemplatePrivate": false, @@ -4073,9 +4462,9 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { }, { "path": "/todos/:id", - "component": "o3725575239-nt", + "component": "o3498884249-nt", "name": "todo", - "uuid": "o3725575239", + "uuid": "o3498884249", "isAsync": false, "isRouter": false, "isTemplatePrivate": true, @@ -4084,9 +4473,9 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { { "path": 404, "name": 404, - "component": "o3725575239-nt", + "component": "o3498884249-nt", "title": "404 route not found", - "uuid": "o3725575239", + "uuid": "o3498884249", "isAsync": false, "isRouter": false, "isTemplatePrivate": true, @@ -4100,7 +4489,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { n21.placeholder = o.placeholder; setOgone(n21, o); o = null; - _at(n21, o3076301467, ''); + _at(n21, o1370160080, ''); _at(n21, 'namespace', 'new'); o = { isRoot: false, @@ -4124,13 +4513,13 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3076301467', + uuid: 'o1370160080', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3076301467-n22', + parentCTXId: 'o1370160080-n22', props: [], - uuid: 'o325165413', + uuid: 'o3575752143', routes: null, namespace: '', requirements: [], @@ -4139,7 +4528,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { n22.placeholder = o.placeholder; setOgone(n22, o); o = null; - _at(n22, o3076301467, ''); + _at(n22, o1370160080, ''); o = { isRoot: false, isOriginalNode: true, @@ -4163,13 +4552,13 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3076301467', + uuid: 'o1370160080', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3076301467-nd23', + parentCTXId: 'o1370160080-nd23', props: [], - uuid: 'o4032646903', + uuid: 'o262107635', routes: null, namespace: '', requirements: [ @@ -4183,7 +4572,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { nd23.placeholder = o.placeholder; setOgone(nd23, o); o = null; - _at(nd23, o3076301467, ''); + _at(nd23, o1370160080, ''); l--; _ap(nt, n12); _ap(nt, n21); @@ -4191,7 +4580,7 @@ Ogone.render[o3076301467_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, nd23); return nt; }; -Ogone.render[o4032646903_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o262107635_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n3 = _h(___style_), t7 = `.container { position: fixed;top: 35%;width: 40px;height: 300px;right: 0;background: #2f3035;border-radius: 5px 0 0 5px;filter: drop-shadow(0px 2px 4px #00000086);; }`, n5 = _h(___div_), t12 = new Text(' '); @@ -4199,7 +4588,7 @@ Ogone.render[o4032646903_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(n3, t7); _at(n5, 'class', 'container'); l++; - t12.getContext = Ogone.contexts[o4032646903_t12] ? Ogone.contexts[o4032646903_t12].bind(ctx.data) : null; + t12.getContext = Ogone.contexts[o262107635_t12] ? Ogone.contexts[o262107635_t12].bind(ctx.data) : null; t12.code = '`${this.scrollY}`'; const ptt12 = p.slice(); ptt12[l - 2] = i; @@ -4212,7 +4601,7 @@ Ogone.render[o4032646903_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o1384895395_nd6] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1580687313_nd6] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd6 = _h(___img_); @@ -4220,7 +4609,7 @@ Ogone.render[o1384895395_nd6] = function(ctx, pos = [], i = 0, l = 0) { _at(nd6, 'src', 'src/public/ogone.svg'); return nd6; }; -Ogone.render[o1384895395_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1580687313_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n3 = _h(___style_), t8 = `.img, .container { width: 60px;height: auto;; }`, n5 = _h(___div_), nd6 = _h(_ogone_node_); @@ -4254,7 +4643,7 @@ Ogone.render[o1384895395_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o1384895395' + uuid: 'o1580687313' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); @@ -4274,17 +4663,17 @@ Ogone.render[o1384895395_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o918636327_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n10 = _h(_ogone_node_); - _at(nt, o2465295184, ''); + _at(nt, o918636327, ''); l++; - _at(n5, o2465295184, ''); + _at(n5, o918636327, ''); _at(n5, 'id', 'test'); _at(n5, 'class', 'menu'); l++; - _at(n6, o2465295184, ''); + _at(n6, o918636327, ''); _at(n6, 'class', 'displayButtons'); l++; o = { @@ -4309,18 +4698,18 @@ Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o2465295184', + uuid: 'o918636327', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o2465295184-nd7', + parentCTXId: 'o918636327-nd7', props: [ [ "buttonOpts", "t" ] ], - uuid: 'o2384155165', + uuid: 'o2164776294', routes: null, namespace: '', requirements: [ @@ -4334,10 +4723,10 @@ Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { nd7.placeholder = o.placeholder; setOgone(nd7, o); o = null; - _at(nd7, o2465295184, ''); + _at(nd7, o918636327, ''); l--; _ap(n6, nd7); - _at(n9, o2465295184, ''); + _at(n9, o918636327, ''); l++; o = { isRoot: false, @@ -4361,13 +4750,13 @@ Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o2465295184', + uuid: 'o918636327', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o2465295184-n10', + parentCTXId: 'o918636327-n10', props: [], - uuid: 'o3104095500', + uuid: 'o841766682', routes: null, namespace: '', requirements: [], @@ -4376,7 +4765,7 @@ Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { n10.placeholder = o.placeholder; setOgone(n10, o); o = null; - _at(n10, o2465295184, ''); + _at(n10, o918636327, ''); l--; _ap(n9, n10); l--; @@ -4386,19 +4775,19 @@ Ogone.render[o2465295184_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o3104095500_nd7] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o841766682_nd7] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd7 = _h(___div_); - _at(nd7, o3104095500, ''); + _at(nd7, o841766682, ''); _at(nd7, 'class', 'line'); return nd7; }; -Ogone.render[o3104095500_nd6] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o841766682_nd6] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd6 = _h(___div_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n11 = _h(___div_); - _at(nd6, o3104095500, ''); + _at(nd6, o841766682, ''); _at(nd6, 'class', 'container'); l++; o = { @@ -4426,7 +4815,7 @@ Ogone.render[o3104095500_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd7', - uuid: 'o3104095500', + uuid: 'o841766682', nodeProps: [ [ "attr", @@ -4437,10 +4826,10 @@ Ogone.render[o3104095500_nd6] = function(ctx, pos = [], i = 0, l = 0) { nd7.placeholder = o.placeholder; setOgone(nd7, o); o = null; - _at(nd7, o3104095500, ''); - _at(n9, o3104095500, ''); + _at(nd7, o841766682, ''); + _at(n9, o841766682, ''); _at(n9, 'class', 'line'); - _at(n11, o3104095500, ''); + _at(n11, o841766682, ''); _at(n11, 'class', 'line'); l--; _ap(nd6, nd7); @@ -4448,11 +4837,11 @@ Ogone.render[o3104095500_nd6] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd6, n11); return nd6; }; -Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o841766682_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(_ogone_node_), nd6 = _h(_ogone_node_), nd7 = _h(_ogone_node_), n9 = _h(___div_), n11 = _h(___div_); - _at(nt, o3104095500, ''); + _at(nt, o841766682, ''); l++; o = { isRoot: false, @@ -4476,13 +4865,13 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o3104095500', + uuid: 'o841766682', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o3104095500-n5', + parentCTXId: 'o841766682-n5', props: [], - uuid: 'o1710946592', + uuid: 'o44758046', routes: null, namespace: 'menu', requirements: [], @@ -4491,7 +4880,7 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { n5.placeholder = o.placeholder; setOgone(n5, o); o = null; - _at(n5, o3104095500, ''); + _at(n5, o841766682, ''); _at(n5, 'namespace', 'menu'); n5.connectedCallback(); o = { @@ -4526,12 +4915,12 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o3104095500' + uuid: 'o841766682' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o3104095500, ''); + _at(nd6, o841766682, ''); l++; o = { isRoot: false, @@ -4558,7 +4947,7 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd7', - uuid: 'o3104095500', + uuid: 'o841766682', nodeProps: [ [ "attr", @@ -4569,10 +4958,10 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { nd7.placeholder = o.placeholder; setOgone(nd7, o); o = null; - _at(nd7, o3104095500, ''); - _at(n9, o3104095500, ''); + _at(nd7, o841766682, ''); + _at(n9, o841766682, ''); _at(n9, 'class', 'line'); - _at(n11, o3104095500, ''); + _at(n11, o841766682, ''); _at(n11, 'class', 'line'); l--; _ap(nd6, nd7); @@ -4583,53 +4972,53 @@ Ogone.render[o3104095500_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, nd6); return nt; }; -Ogone.render[o1710946592_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o44758046_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), t3 = ``; - _at(nt, o1710946592, ''); + _at(nt, o44758046, ''); _ap(nt, t3); return nt; }; -Ogone.render[o2010234397_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o776663872_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_); - _at(nt, o2010234397, ''); + _at(nt, o776663872, ''); return nt; }; -Ogone.render[o2384155165_nd6] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2164776294_nd6] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd6 = _h(___span_); - _at(nd6, o2384155165, ''); + _at(nd6, o2164776294, ''); _at(nd6, 'class', 'ok'); return nd6; }; -Ogone.render[o2384155165_nd8] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2164776294_nd8] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd8 = _h(___span_); - _at(nd8, o2384155165, ''); + _at(nd8, o2164776294, ''); _at(nd8, 'class', 'todo'); return nd8; }; -Ogone.render[o2384155165_nd10] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2164776294_nd10] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd10 = _h(___span_); - _at(nd10, o2384155165, ''); + _at(nd10, o2164776294, ''); _at(nd10, 'class', 'in-progress'); return nd10; }; -Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2164776294_nd5] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd5 = _h(___div_), t13 = new Text(' '), nd6 = _h(_ogone_node_), nd8 = _h(_ogone_node_), nd10 = _h(_ogone_node_); - _at(nd5, o2384155165, ''); + _at(nd5, o2164776294, ''); _at(nd5, 'class', 'container'); l++; - t13.getContext = Ogone.contexts[o2384155165_t13] ? Ogone.contexts[o2384155165_t13].bind(ctx.data) : null; + t13.getContext = Ogone.contexts[o2164776294_t13] ? Ogone.contexts[o2164776294_t13].bind(ctx.data) : null; t13.code = '`${this.buttonOpts.name}`'; const ptt13 = p.slice(); ptt13[l - 2] = i; @@ -4661,12 +5050,12 @@ Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o2384155165, ''); + _at(nd6, o2164776294, ''); o = { isRoot: false, isOriginalNode: true, @@ -4693,12 +5082,12 @@ Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd8', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd8.placeholder = o.placeholder; setOgone(nd8, o); o = null; - _at(nd8, o2384155165, ''); + _at(nd8, o2164776294, ''); o = { isRoot: false, isOriginalNode: true, @@ -4725,12 +5114,12 @@ Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd10', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd10.placeholder = o.placeholder; setOgone(nd10, o); o = null; - _at(nd10, o2384155165, ''); + _at(nd10, o2164776294, ''); l--; _ap(nd5, t13); _ap(nd5, nd6); @@ -4738,11 +5127,11 @@ Ogone.render[o2384155165_nd5] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd5, nd10); return nd5; }; -Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2164776294_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), nd5 = _h(_ogone_node_), t13 = new Text(' '), nd6 = _h(_ogone_node_), nd8 = _h(_ogone_node_), nd10 = _h(_ogone_node_); - _at(nt, o2384155165, ''); + _at(nt, o2164776294, ''); l++; o = { isRoot: false, @@ -4775,14 +5164,14 @@ Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd5', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd5.placeholder = o.placeholder; setOgone(nd5, o); o = null; - _at(nd5, o2384155165, ''); + _at(nd5, o2164776294, ''); l++; - t13.getContext = Ogone.contexts[o2384155165_t13] ? Ogone.contexts[o2384155165_t13].bind(ctx.data) : null; + t13.getContext = Ogone.contexts[o2164776294_t13] ? Ogone.contexts[o2164776294_t13].bind(ctx.data) : null; t13.code = '`${this.buttonOpts.name}`'; const ptt13 = p.slice(); ptt13[l - 2] = i; @@ -4814,12 +5203,12 @@ Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o2384155165, ''); + _at(nd6, o2164776294, ''); o = { isRoot: false, isOriginalNode: true, @@ -4846,12 +5235,12 @@ Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd8', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd8.placeholder = o.placeholder; setOgone(nd8, o); o = null; - _at(nd8, o2384155165, ''); + _at(nd8, o2164776294, ''); o = { isRoot: false, isOriginalNode: true, @@ -4878,12 +5267,12 @@ Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd10', - uuid: 'o2384155165' + uuid: 'o2164776294' }; nd10.placeholder = o.placeholder; setOgone(nd10, o); o = null; - _at(nd10, o2384155165, ''); + _at(nd10, o2164776294, ''); l--; _ap(nd5, t13); _ap(nd5, nd6); @@ -4893,14 +5282,14 @@ Ogone.render[o2384155165_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, nd5); return nt; }; -Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o3575752143_nd6] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd6 = _h(___div_), n7 = _h(___div_), nd8 = _h(_ogone_node_), n10 = _h(___div_), t23 = `0.1.0`, n13 = _h(___div_), nd14 = _h(_ogone_node_); - _at(nd6, o325165413, ''); + _at(nd6, o3575752143, ''); _at(nd6, 'class', 'left-menu'); l++; - _at(n7, o325165413, ''); + _at(n7, o3575752143, ''); _at(n7, 'class', 'header'); l++; o = { @@ -4932,13 +5321,13 @@ Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o325165413', + uuid: 'o3575752143', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o325165413-nd8', + parentCTXId: 'o3575752143-nd8', props: [], - uuid: 'o1145023862', + uuid: 'o3244593960', routes: null, namespace: '', requirements: null, @@ -4947,13 +5336,13 @@ Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { nd8.placeholder = o.placeholder; setOgone(nd8, o); o = null; - _at(nd8, o325165413, ''); - _at(n10, o325165413, ''); + _at(nd8, o3575752143, ''); + _at(n10, o3575752143, ''); _ap(n10, t23); l--; _ap(n7, nd8); _ap(n7, n10); - _at(n13, o325165413, ''); + _at(n13, o3575752143, ''); _at(n13, 'class', 'tree'); l++; o = { @@ -4978,18 +5367,18 @@ Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o325165413', + uuid: 'o3575752143', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o325165413-nd14', + parentCTXId: 'o3575752143-nd14', props: [ [ "item", "item" ] ], - uuid: 'o1561345583', + uuid: 'o1304491614', routes: null, namespace: '', requirements: [ @@ -5003,7 +5392,7 @@ Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { nd14.placeholder = o.placeholder; setOgone(nd14, o); o = null; - _at(nd14, o325165413, ''); + _at(nd14, o3575752143, ''); l--; _ap(n13, nd14); l--; @@ -5011,18 +5400,18 @@ Ogone.render[o325165413_nd6] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd6, n13); return nd6; }; -Ogone.render[o325165413_nd17] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o3575752143_nd17] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd17 = _h(___div_); - _at(nd17, o325165413, ''); + _at(nd17, o3575752143, ''); return nd17; }; -Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o3575752143_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(_ogone_node_), nd6 = _h(_ogone_node_), n7 = _h(___div_), nd8 = _h(_ogone_node_), n10 = _h(___div_), t23 = `0.1.0`, n13 = _h(___div_), nd14 = _h(_ogone_node_), nd17 = _h(_ogone_node_); - _at(nt, o325165413, ''); + _at(nt, o3575752143, ''); l++; o = { isRoot: false, @@ -5046,13 +5435,13 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o325165413', + uuid: 'o3575752143', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o325165413-n5', + parentCTXId: 'o3575752143-n5', props: [], - uuid: 'o1710946592', + uuid: 'o44758046', routes: null, namespace: 'menu', requirements: [], @@ -5061,7 +5450,7 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { n5.placeholder = o.placeholder; setOgone(n5, o); o = null; - _at(n5, o325165413, ''); + _at(n5, o3575752143, ''); _at(n5, 'namespace', 'menu'); n5.connectedCallback(); o = { @@ -5090,14 +5479,14 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o325165413' + uuid: 'o3575752143' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o325165413, ''); + _at(nd6, o3575752143, ''); l++; - _at(n7, o325165413, ''); + _at(n7, o3575752143, ''); _at(n7, 'class', 'header'); l++; o = { @@ -5129,13 +5518,13 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o325165413', + uuid: 'o3575752143', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o325165413-nd8', + parentCTXId: 'o3575752143-nd8', props: [], - uuid: 'o1145023862', + uuid: 'o3244593960', routes: null, namespace: '', requirements: null, @@ -5144,13 +5533,13 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { nd8.placeholder = o.placeholder; setOgone(nd8, o); o = null; - _at(nd8, o325165413, ''); - _at(n10, o325165413, ''); + _at(nd8, o3575752143, ''); + _at(n10, o3575752143, ''); _ap(n10, t23); l--; _ap(n7, nd8); _ap(n7, n10); - _at(n13, o325165413, ''); + _at(n13, o3575752143, ''); _at(n13, 'class', 'tree'); l++; o = { @@ -5175,18 +5564,18 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o325165413', + uuid: 'o3575752143', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o325165413-nd14', + parentCTXId: 'o3575752143-nd14', props: [ [ "item", "item" ] ], - uuid: 'o1561345583', + uuid: 'o1304491614', routes: null, namespace: '', requirements: [ @@ -5200,7 +5589,7 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { nd14.placeholder = o.placeholder; setOgone(nd14, o); o = null; - _at(nd14, o325165413, ''); + _at(nd14, o3575752143, ''); l--; _ap(n13, nd14); l--; @@ -5239,25 +5628,25 @@ Ogone.render[o325165413_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd17', - uuid: 'o325165413' + uuid: 'o3575752143' }; nd17.placeholder = o.placeholder; setOgone(nd17, o); o = null; - _at(nd17, o325165413, ''); + _at(nd17, o3575752143, ''); l--; _ap(nt, n5); _ap(nt, nd6); _ap(nt, nd17); return nt; }; -Ogone.render[o1561345583_nd9] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nd9] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd9 = _h(___span_), t22 = new Text(' '); - _at(nd9, o1561345583, ''); + _at(nd9, o1304491614, ''); l++; - t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.getContext = Ogone.contexts[o1304491614_t22] ? Ogone.contexts[o1304491614_t22].bind(ctx.data) : null; t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; const ptt22 = p.slice(); ptt22[l - 2] = i; @@ -5267,32 +5656,32 @@ Ogone.render[o1561345583_nd9] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd9, t22); return nd9; }; -Ogone.render[o1561345583_nd11] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nd11] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd11 = _h(___span_), t27 = `>`; - _at(nd11, o1561345583, ''); + _at(nd11, o1304491614, ''); _ap(nd11, t27); return nd11; }; -Ogone.render[o1561345583_nd13] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nd13] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd13 = _h(___span_), t32 = `<`; - _at(nd13, o1561345583, ''); + _at(nd13, o1304491614, ''); _ap(nd13, t32); return nd13; }; -Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nd6] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd6 = _h(___div_), n7 = _h(___span_), t17 = new Text(' '), nd9 = _h(_ogone_node_), t22 = new Text(' '), nd11 = _h(_ogone_node_), t27 = `>`, nd13 = _h(_ogone_node_), t32 = `<`; - _at(nd6, o1561345583, ''); + _at(nd6, o1304491614, ''); _at(nd6, 'class', 'title'); l++; - _at(n7, o1561345583, ''); + _at(n7, o1304491614, ''); l++; - t17.getContext = Ogone.contexts[o1561345583_t17] ? Ogone.contexts[o1561345583_t17].bind(ctx.data) : null; + t17.getContext = Ogone.contexts[o1304491614_t17] ? Ogone.contexts[o1304491614_t17].bind(ctx.data) : null; t17.code = '`${this.item.name}`'; const ptt17 = p.slice(); ptt17[l - 2] = i; @@ -5326,14 +5715,14 @@ Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd9', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd9.placeholder = o.placeholder; setOgone(nd9, o); o = null; - _at(nd9, o1561345583, ''); + _at(nd9, o1304491614, ''); l++; - t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.getContext = Ogone.contexts[o1304491614_t22] ? Ogone.contexts[o1304491614_t22].bind(ctx.data) : null; t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; const ptt22 = p.slice(); ptt22[l - 2] = i; @@ -5367,12 +5756,12 @@ Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd11', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd11.placeholder = o.placeholder; setOgone(nd11, o); o = null; - _at(nd11, o1561345583, ''); + _at(nd11, o1304491614, ''); _ap(nd11, t27); o = { isRoot: false, @@ -5400,12 +5789,12 @@ Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd13', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd13.placeholder = o.placeholder; setOgone(nd13, o); o = null; - _at(nd13, o1561345583, ''); + _at(nd13, o1304491614, ''); _ap(nd13, t32); l--; _ap(nd6, n7); @@ -5414,11 +5803,11 @@ Ogone.render[o1561345583_nd6] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd6, nd13); return nd6; }; -Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nd16] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd16 = _h(___div_), n17 = _h(_ogone_node_), nd18 = _h(_ogone_node_); - _at(nd16, o1561345583, ''); + _at(nd16, o1304491614, ''); _at(nd16, 'class', 'child'); l++; o = { @@ -5443,13 +5832,13 @@ Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o1561345583', + uuid: 'o1304491614', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o1561345583-n17', + parentCTXId: 'o1304491614-n17', props: [], - uuid: 'o3474491051', + uuid: 'o246739052', routes: null, namespace: '', requirements: null, @@ -5458,7 +5847,7 @@ Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { n17.placeholder = o.placeholder; setOgone(n17, o); o = null; - _at(n17, o1561345583, ''); + _at(n17, o1304491614, ''); l++; o = { isRoot: false, @@ -5482,18 +5871,18 @@ Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o1561345583', + uuid: 'o1304491614', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o1561345583-nd18', + parentCTXId: 'o1304491614-nd18', props: [ [ "item", "child" ] ], - uuid: 'o1561345583', + uuid: 'o1304491614', routes: null, namespace: '', requirements: [ @@ -5507,20 +5896,20 @@ Ogone.render[o1561345583_nd16] = function(ctx, pos = [], i = 0, l = 0) { nd18.placeholder = o.placeholder; setOgone(nd18, o); o = null; - _at(nd18, o1561345583, ''); + _at(nd18, o1304491614, ''); l--; _ap(n17, nd18); l--; _ap(nd16, n17); return nd16; }; -Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1304491614_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(___div_), nd6 = _h(_ogone_node_), n7 = _h(___span_), t17 = new Text(' '), nd9 = _h(_ogone_node_), t22 = new Text(' '), nd11 = _h(_ogone_node_), t27 = `>`, nd13 = _h(_ogone_node_), t32 = `<`, nd16 = _h(_ogone_node_), n17 = _h(_ogone_node_), nd18 = _h(_ogone_node_); - _at(nt, o1561345583, ''); + _at(nt, o1304491614, ''); l++; - _at(n5, o1561345583, ''); + _at(n5, o1304491614, ''); _at(n5, 'class', 'container'); l++; o = { @@ -5560,16 +5949,16 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd6', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o1561345583, ''); + _at(nd6, o1304491614, ''); l++; - _at(n7, o1561345583, ''); + _at(n7, o1304491614, ''); l++; - t17.getContext = Ogone.contexts[o1561345583_t17] ? Ogone.contexts[o1561345583_t17].bind(ctx.data) : null; + t17.getContext = Ogone.contexts[o1304491614_t17] ? Ogone.contexts[o1304491614_t17].bind(ctx.data) : null; t17.code = '`${this.item.name}`'; const ptt17 = p.slice(); ptt17[l - 2] = i; @@ -5603,14 +5992,14 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd9', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd9.placeholder = o.placeholder; setOgone(nd9, o); o = null; - _at(nd9, o1561345583, ''); + _at(nd9, o1304491614, ''); l++; - t22.getContext = Ogone.contexts[o1561345583_t22] ? Ogone.contexts[o1561345583_t22].bind(ctx.data) : null; + t22.getContext = Ogone.contexts[o1304491614_t22] ? Ogone.contexts[o1304491614_t22].bind(ctx.data) : null; t22.code = '`${!this.item.children && this.item.status ? this.item.status : \'\'}`'; const ptt22 = p.slice(); ptt22[l - 2] = i; @@ -5644,12 +6033,12 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd11', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd11.placeholder = o.placeholder; setOgone(nd11, o); o = null; - _at(nd11, o1561345583, ''); + _at(nd11, o1304491614, ''); _ap(nd11, t27); o = { isRoot: false, @@ -5677,12 +6066,12 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd13', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd13.placeholder = o.placeholder; setOgone(nd13, o); o = null; - _at(nd13, o1561345583, ''); + _at(nd13, o1304491614, ''); _ap(nd13, t32); l--; _ap(nd6, n7); @@ -5716,12 +6105,12 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd16', - uuid: 'o1561345583' + uuid: 'o1304491614' }; nd16.placeholder = o.placeholder; setOgone(nd16, o); o = null; - _at(nd16, o1561345583, ''); + _at(nd16, o1304491614, ''); l++; o = { isRoot: false, @@ -5745,13 +6134,13 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o1561345583', + uuid: 'o1304491614', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o1561345583-n17', + parentCTXId: 'o1304491614-n17', props: [], - uuid: 'o3474491051', + uuid: 'o246739052', routes: null, namespace: '', requirements: null, @@ -5760,7 +6149,7 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { n17.placeholder = o.placeholder; setOgone(n17, o); o = null; - _at(n17, o1561345583, ''); + _at(n17, o1304491614, ''); l++; o = { isRoot: false, @@ -5784,18 +6173,18 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o1561345583', + uuid: 'o1304491614', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o1561345583-nd18', + parentCTXId: 'o1304491614-nd18', props: [ [ "item", "child" ] ], - uuid: 'o1561345583', + uuid: 'o1304491614', routes: null, namespace: '', requirements: [ @@ -5809,7 +6198,7 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { nd18.placeholder = o.placeholder; setOgone(nd18, o); o = null; - _at(nd18, o1561345583, ''); + _at(nd18, o1304491614, ''); l--; _ap(n17, nd18); l--; @@ -5821,26 +6210,26 @@ Ogone.render[o1561345583_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o3474491051_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o246739052_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___div_), n8 = _h(___slot_); - _at(nt, o3474491051, ''); + _at(nt, o246739052, ''); l++; - _at(n5, o3474491051, ''); + _at(n5, o246739052, ''); _at(n5, 'class', 'container'); l++; - _at(n6, o3474491051, ''); + _at(n6, o246739052, ''); ctx.refs['view'] = ctx.refs['view'] || []; ctx.refs['view'][i] = n6; _at(n6, 'class', 'view'); l++; - _at(n7, o3474491051, ''); + _at(n7, o246739052, ''); ctx.refs['content'] = ctx.refs['content'] || []; ctx.refs['content'][i] = n7; _at(n7, 'class', 'content'); l++; - _at(n8, o3474491051, ''); + _at(n8, o246739052, ''); l--; _ap(n7, n8); l--; @@ -5851,7 +6240,7 @@ Ogone.render[o3474491051_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o1145023862_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o3244593960_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n3 = _h(___style_), t7 = `.container { width: 60px;height: auto; } .container .img { width: 60px;height: auto;; }`, n5 = _h(___div_), n6 = _h(___img_); @@ -5868,21 +6257,21 @@ Ogone.render[o1145023862_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o2443722130_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o402642107_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), t3 = ``; - _at(nt, o2443722130, ''); + _at(nt, o402642107, ''); _ap(nt, t3); return nt; }; -Ogone.render[o171290282_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o2509604044_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(___div_), nd6 = _h(_ogone_node_); - _at(nt, o171290282, ''); + _at(nt, o2509604044, ''); l++; - _at(n5, o171290282, ''); + _at(n5, o2509604044, ''); _at(n5, 'class', 'container'); l++; o = { @@ -5908,13 +6297,13 @@ Ogone.render[o171290282_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: true, isRemote: false, extends: '-nt', - uuid: 'o171290282', + uuid: 'o2509604044', positionInParentComponent: p, levelInParentComponent: l, parentComponent: ctx, - parentCTXId: 'o171290282-nd6', + parentCTXId: 'o2509604044-nd6', props: [], - uuid: 'o1517538778', + uuid: 'o1177399929', routes: null, namespace: '', requirements: [ @@ -5940,21 +6329,21 @@ Ogone.render[o171290282_nt] = function(ctx, pos = [], i = 0, l = 0) { nd6.placeholder = o.placeholder; setOgone(nd6, o); o = null; - _at(nd6, o171290282, ''); + _at(nd6, o2509604044, ''); l--; _ap(n5, nd6); l--; _ap(nt, n5); return nt; }; -Ogone.render[o1517538778_nd13] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1177399929_nd13] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd13 = _h(___p_), t30 = new Text(' '); - _at(nd13, o1517538778, ''); + _at(nd13, o1177399929, ''); _at(nd13, 'class', 'page'); l++; - t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.getContext = Ogone.contexts[o1177399929_t30] ? Ogone.contexts[o1177399929_t30].bind(ctx.data) : null; t30.code = '`${this.page}`'; const ptt30 = p.slice(); ptt30[l - 2] = i; @@ -5964,11 +6353,11 @@ Ogone.render[o1517538778_nd13] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd13, t30); return nd13; }; -Ogone.render[o1517538778_nd12] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1177399929_nd12] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nd12 = _h(___div_), nd13 = _h(_ogone_node_), t30 = new Text(' '), n15 = _h(___pre_), n16 = _h(___code_), t37 = new Text(' '); - _at(nd12, o1517538778, ''); + _at(nd12, o1177399929, ''); _at(nd12, 'class', 'right'); l++; o = { @@ -5997,14 +6386,14 @@ Ogone.render[o1517538778_nd12] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd13', - uuid: 'o1517538778' + uuid: 'o1177399929' }; nd13.placeholder = o.placeholder; setOgone(nd13, o); o = null; - _at(nd13, o1517538778, ''); + _at(nd13, o1177399929, ''); l++; - t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.getContext = Ogone.contexts[o1177399929_t30] ? Ogone.contexts[o1177399929_t30].bind(ctx.data) : null; t30.code = '`${this.page}`'; const ptt30 = p.slice(); ptt30[l - 2] = i; @@ -6012,12 +6401,12 @@ Ogone.render[o1517538778_nd12] = function(ctx, pos = [], i = 0, l = 0) { ctx.texts.push(t30); l--; _ap(nd13, t30); - _at(n15, o1517538778, ''); + _at(n15, o1177399929, ''); l++; - _at(n16, o1517538778, ''); + _at(n16, o1177399929, ''); _at(n16, 'class', 'javascript'); l++; - t37.getContext = Ogone.contexts[o1517538778_t37] ? Ogone.contexts[o1517538778_t37].bind(ctx.data) : null; + t37.getContext = Ogone.contexts[o1177399929_t37] ? Ogone.contexts[o1177399929_t37].bind(ctx.data) : null; t37.code = '`${this.code}`'; const ptt37 = p.slice(); ptt37[l - 2] = i; @@ -6032,22 +6421,22 @@ Ogone.render[o1517538778_nd12] = function(ctx, pos = [], i = 0, l = 0) { _ap(nd12, n15); return nd12; }; -Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o1177399929_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___h2_), t16 = new Text(' '), n9 = _h(___p_), t21 = new Text(' '), nd12 = _h(_ogone_node_), nd13 = _h(_ogone_node_), t30 = new Text(' '), n15 = _h(___pre_), n16 = _h(___code_), t37 = new Text(' '); - _at(nt, o1517538778, ''); + _at(nt, o1177399929, ''); l++; - _at(n5, o1517538778, ''); + _at(n5, o1177399929, ''); _at(n5, 'class', 'container'); l++; - _at(n6, o1517538778, ''); + _at(n6, o1177399929, ''); _at(n6, 'class', 'left'); l++; - _at(n7, o1517538778, ''); + _at(n7, o1177399929, ''); _at(n7, 'class', 'title'); l++; - t16.getContext = Ogone.contexts[o1517538778_t16] ? Ogone.contexts[o1517538778_t16].bind(ctx.data) : null; + t16.getContext = Ogone.contexts[o1177399929_t16] ? Ogone.contexts[o1177399929_t16].bind(ctx.data) : null; t16.code = '`${this.title}`'; const ptt16 = p.slice(); ptt16[l - 2] = i; @@ -6055,10 +6444,10 @@ Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { ctx.texts.push(t16); l--; _ap(n7, t16); - _at(n9, o1517538778, ''); + _at(n9, o1177399929, ''); _at(n9, 'class', 'text'); l++; - t21.getContext = Ogone.contexts[o1517538778_t21] ? Ogone.contexts[o1517538778_t21].bind(ctx.data) : null; + t21.getContext = Ogone.contexts[o1177399929_t21] ? Ogone.contexts[o1177399929_t21].bind(ctx.data) : null; t21.code = '`${this.text}`'; const ptt21 = p.slice(); ptt21[l - 2] = i; @@ -6095,12 +6484,12 @@ Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd12', - uuid: 'o1517538778' + uuid: 'o1177399929' }; nd12.placeholder = o.placeholder; setOgone(nd12, o); o = null; - _at(nd12, o1517538778, ''); + _at(nd12, o1177399929, ''); l++; o = { isRoot: false, @@ -6128,14 +6517,14 @@ Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { isImported: false, isRemote: false, extends: '-nd13', - uuid: 'o1517538778' + uuid: 'o1177399929' }; nd13.placeholder = o.placeholder; setOgone(nd13, o); o = null; - _at(nd13, o1517538778, ''); + _at(nd13, o1177399929, ''); l++; - t30.getContext = Ogone.contexts[o1517538778_t30] ? Ogone.contexts[o1517538778_t30].bind(ctx.data) : null; + t30.getContext = Ogone.contexts[o1177399929_t30] ? Ogone.contexts[o1177399929_t30].bind(ctx.data) : null; t30.code = '`${this.page}`'; const ptt30 = p.slice(); ptt30[l - 2] = i; @@ -6143,12 +6532,12 @@ Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { ctx.texts.push(t30); l--; _ap(nd13, t30); - _at(n15, o1517538778, ''); + _at(n15, o1177399929, ''); l++; - _at(n16, o1517538778, ''); + _at(n16, o1177399929, ''); _at(n16, 'class', 'javascript'); l++; - t37.getContext = Ogone.contexts[o1517538778_t37] ? Ogone.contexts[o1517538778_t37].bind(ctx.data) : null; + t37.getContext = Ogone.contexts[o1177399929_t37] ? Ogone.contexts[o1177399929_t37].bind(ctx.data) : null; t37.code = '`${this.code}`'; const ptt37 = p.slice(); ptt37[l - 2] = i; @@ -6168,7 +6557,7 @@ Ogone.render[o1517538778_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -Ogone.render[o3725575239_nt] = function(ctx, pos = [], i = 0, l = 0) { +Ogone.render[o3498884249_nt] = function(ctx, pos = [], i = 0, l = 0) { let p = pos.slice(); let o = null; const nt = _h(___template_), n3 = _h(___style_), t8 = `.container { display: flex;justify-content: center;margin: auto;flex-direction: column;height: 100vh; } .container .text { font-weight: 400;font-size: 24pt;text-align: center;color: #9e9e9e;margin: 40px;; } .logo-back { filter: drop-shadow(2px 4px 6px var(--o-primary));border-radius: 100%;padding: 56px;animation-name: popup;animation-duration: 0.5s;animation-timing-function: cubic-bezier(0.1, -0.6, 0.2, 0);max-width: 500px;margin: auto; } .logo-back img.logo { width: 500px;height: auto;animation-name: rotate;animation-duration: 5s;animation-timing-function: ease;animation-iteration-count: infinite;animation-direction: alternate;; }`, n5 = _h(___div_), n6 = _h(___div_), n7 = _h(___img_), n9 = _h(___div_), t21 = `404 route not found.`; @@ -6192,27 +6581,12 @@ Ogone.render[o3725575239_nt] = function(ctx, pos = [], i = 0, l = 0) { _ap(nt, n5); return nt; }; -/** - * struct import for examples/app/Application.o3 - * */ import { Obj } from 'https://deno.land/x/obj@0.0.1/mod.ts'; -/** - * save imports for examples/app/Application.o3 -*/ Ogone.require['/x/obj@0.0.1/mod.ts'] = Ogone.require['/x/obj@0.0.1/mod.ts'] || { +Ogone.require['dep_6426190445621257115'] = Ogone.require['dep_6426190445621257115'] || { }; -/** member */ Ogone.require['/x/obj@0.0.1/mod.ts'].Obj = Obj; -/** - * struct import for examples/app/components/Burger.o3 - * */ import print from '/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'; -/** - * save imports for examples/app/components/Burger.o3 -*/ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'] = Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'] || { +Ogone.require['dep_6426190445621257115'].Obj = Obj; +Ogone.require['dep_51506147711985763655'] = Ogone.require['dep_51506147711985763655'] || { }; -/** default */ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/print.ts'].print = print; -/** - * struct import for examples/app/components/Burger.o3 - * */ import attr from '/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'; -/** - * save imports for examples/app/components/Burger.o3 -*/ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'] = Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'] || { +Ogone.require['dep_51506147711985763655'].print = __default2; +Ogone.require['dep_58806555621990634570'] = Ogone.require['dep_58806555621990634570'] || { }; -/** default */ Ogone.require['/home/rudy/Documents/Perso/Ogone/examples/app/lib/attr.ts'].attr = attr; +Ogone.require['dep_58806555621990634570'].attr = __default; diff --git a/examples/tests/dist/index.html b/examples/tests/dist/index.html index f8aab1aa..ba3fe22c 100644 --- a/examples/tests/dist/index.html +++ b/examples/tests/dist/index.html @@ -4,10 +4,10 @@ + - \ No newline at end of file diff --git a/examples/tests/dist/style.css b/examples/tests/dist/style.css index 8c7a42da..64f3314c 100644 --- a/examples/tests/dist/style.css +++ b/examples/tests/dist/style.css @@ -1,15 +1 @@ - h1[o3076301467], h2[o3076301467], h3[o3076301467], h4[o3076301467] { color: #193b48;; } .open-dev-tool[o3076301467] { display: inline-flex;background: var(--o-header);height: 100%;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none;; } .logo[o3076301467] { flex: 2;display: inline-flex;flex-direction: row;max-width: 124px;min-width: 124px;min-height: 65px;cursor: pointer;; } .header[o3076301467] { background: var(--o-header);padding: 10px;filter: drop-shadow(0px 10px 5px #00000033);display: flex;position: fixed;width: 99%;top: 0px;left: 0px;transition: top 0.5s ease;overflow: hidden;z-index: 500;; } .title[o3076301467] { margin: auto;letter-spacing: 3px;; } - - - .menu[o2465295184] { flex: 8;display: flex;flex-direction: row;vertical-align: middle;align-items: center;justify-content: flex-end;; } @media screen and (max-width: 900px) { div.displayButtons[o2465295184] { display: none;; } } - .container[o3104095500] { padding: 9px;width: 28px;height: auto;background: var(--o-header);display: flex;flex-direction: column;filter: drop-shadow(0px 0px 0px #00000045); } .container[o3104095500]:hover[o3104095500] { filter: drop-shadow(0px 5px 3px #00000045);; } .container[o3104095500]:hover[o3104095500] .line[o3104095500] { background: var(--o-primary);; } .container[o3104095500] .line[o3104095500] { background: #848181;margin-top: 2px;margin-bottom: 2px;height: 4px;; } .line[o3104095500], .container[o3104095500] { border-radius: 5px;transition: filter 0.2s ease;cursor: pointer;; } - - - .container[o2384155165] { display: inline-flex;background: var(--o-header);height: 100%;width: min-content;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none; } .container[o2384155165]:hover[o2384155165] { background: var(--o-primary);color: var(--o-background);; } .ok[o2384155165], .in-progress[o2384155165], .todo[o2384155165] { height: 3px;width: 3px;padding: 3px;border-radius: 20px;margin: 5px;; } .ok[o2384155165] { background: var(--o-success); } .todo[o2384155165] { background: var(--o-error); } .in-progress[o2384155165] { background: var(--o-info); } - .left-menu[o325165413] { height: 100vh;width: 300px;min-width: 300px;max-width: 300px;position: fixed;top: 0px;transition: left 0.5s ease;left: 0px;background: var(--o-header);z-index: 2000;display: flex;filter: drop-shadow(0px 0px 10px #000000);flex-direction: column;; } .close[o325165413] { left: -100%;; } .darken[o325165413] { background: #00000090;width: 100vw;height: 100vh;top: 0px;left: 0px;position: fixed;z-index: 1999;; } .header[o325165413] { padding: 10px;display: flex;vertical-align: middle;align-items: center;justify-content: space-between;border-bottom: 1px solid #4e4e4e;; } .tree[o325165413] { overflow-x: hidden;overflow-y: auto;; } - .container[o1561345583] { color: var(--o-grey);display: flex;flex-direction: column;flex: 1;; } .child[o1561345583] { padding-left: 30px;height: 0;overflow: hidden;transition: flex 0.5s ease;; } .child-open[o1561345583] { flex: 1;; } .title[o1561345583] { padding-bottom: 10px;padding: 5px;cursor: pointer;flex: 1;display: flex;justify-content: space-between; } .title[o1561345583]:hover[o1561345583] { background: var(--o-primary);color: white;; } .child[o1561345583] .title[o1561345583] { border-left: 1px solid #555;; } .status[o1561345583] { display: list-item;; } .ok[o1561345583] { color: var(--o-success); } .todo[o1561345583] { color: var(--o-error); } .in-progress[o1561345583] { color: var(--o-info); } - .container[o3474491051] { overflow: hidden;display: flex;flex-direction: row-reverse; } .container[o3474491051] .view[o3474491051] { flex: 18;overflow: auto; } .container[o3474491051] .view[o3474491051] .content[o3474491051] { flex: 18;; } - - - .container[o171290282] { height: auto;width: auto;background: black;margin-top: 45px;animation-name: fade-in-right;animation-iteration-count: 1;animation-duration: 0.5s;; } - .container[o1517538778] { min-height: 400px;width: 100%;display: flex;flex-direction: column;; } .left[o1517538778] { background: var(--o-background);flex: 6;padding: 98px;padding-left: 326px; } .right[o1517538778] { flex: 5;padding: 53px;padding-top: 135px;padding-bottom: 135px;border-left: 1px solid #d8d8d8;background: #f1f1f1;color: var(--o-grey);padding-left: 326px; } .code[o1517538778] { white-space: pre;; } .text[o1517538778] { color: var(--o-grey);margin-left: 30px;white-space: pre;; } .title[o1517538778] { color: var(--o-dark-blue);; } .page[o1517538778] { opacity: 0.3;color: cadetblue;; } @media screen and (max-width: $screen) { .left[o1517538778] { padding-left: 77px;; } } @media screen and (max-width: $screen) { .right[o1517538778] { padding-left: 77px;; } } + h1[o1370160080], h2[o1370160080], h3[o1370160080], h4[o1370160080] { color: #193b48;; } .open-dev-tool[o1370160080] { display: inline-flex;background: var(--o-header);height: 100%;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none;; } .logo[o1370160080] { flex: 2;display: inline-flex;flex-direction: row;max-width: 124px;min-width: 124px;min-height: 65px;cursor: pointer;; } .header[o1370160080] { background: var(--o-header);padding: 10px;filter: drop-shadow(0px 10px 5px #00000033);display: flex;position: fixed;width: 99%;top: 0px;left: 0px;transition: top 0.5s ease;overflow: hidden;z-index: 500;; } .title[o1370160080] { margin: auto;letter-spacing: 3px;; } .menu[o918636327] { flex: 8;display: flex;flex-direction: row;vertical-align: middle;align-items: center;justify-content: flex-end;; } @media screen and (max-width: 900px) { div.displayButtons[o918636327] { display: none;; } } .container[o841766682] { padding: 9px;width: 28px;height: auto;background: var(--o-header);display: flex;flex-direction: column;filter: drop-shadow(0px 0px 0px #00000045); } .container[o841766682]:hover[o841766682] { filter: drop-shadow(0px 5px 3px #00000045);; } .container[o841766682]:hover[o841766682] .line[o841766682] { background: var(--o-primary);; } .container[o841766682] .line[o841766682] { background: #848181;margin-top: 2px;margin-bottom: 2px;height: 4px;; } .line[o841766682], .container[o841766682] { border-radius: 5px;transition: filter 0.2s ease;cursor: pointer;; } .container[o2164776294] { display: inline-flex;background: var(--o-header);height: 100%;width: min-content;vertical-align: middle;align-items: center;padding: 23px;text-transform: capitalize;color: #afafaf;cursor: pointer;user-select: none; } .container[o2164776294]:hover[o2164776294] { background: var(--o-primary);color: var(--o-background);; } .ok[o2164776294], .in-progress[o2164776294], .todo[o2164776294] { height: 3px;width: 3px;padding: 3px;border-radius: 20px;margin: 5px;; } .ok[o2164776294] { background: var(--o-success); } .todo[o2164776294] { background: var(--o-error); } .in-progress[o2164776294] { background: var(--o-info); } .left-menu[o3575752143] { height: 100vh;width: 300px;min-width: 300px;max-width: 300px;position: fixed;top: 0px;transition: left 0.5s ease;left: 0px;background: var(--o-header);z-index: 2000;display: flex;filter: drop-shadow(0px 0px 10px #000000);flex-direction: column;; } .close[o3575752143] { left: -100%;; } .darken[o3575752143] { background: #00000090;width: 100vw;height: 100vh;top: 0px;left: 0px;position: fixed;z-index: 1999;; } .header[o3575752143] { padding: 10px;display: flex;vertical-align: middle;align-items: center;justify-content: space-between;border-bottom: 1px solid #4e4e4e;; } .tree[o3575752143] { overflow-x: hidden;overflow-y: auto;; } .container[o1304491614] { color: var(--o-grey);display: flex;flex-direction: column;flex: 1;; } .child[o1304491614] { padding-left: 30px;height: 0;overflow: hidden;transition: flex 0.5s ease;; } .child-open[o1304491614] { flex: 1;; } .title[o1304491614] { padding-bottom: 10px;padding: 5px;cursor: pointer;flex: 1;display: flex;justify-content: space-between; } .title[o1304491614]:hover[o1304491614] { background: var(--o-primary);color: white;; } .child[o1304491614] .title[o1304491614] { border-left: 1px solid #555;; } .status[o1304491614] { display: list-item;; } .ok[o1304491614] { color: var(--o-success); } .todo[o1304491614] { color: var(--o-error); } .in-progress[o1304491614] { color: var(--o-info); } .container[o246739052] { overflow: hidden;display: flex;flex-direction: row-reverse; } .container[o246739052] .view[o246739052] { flex: 18;overflow: auto; } .container[o246739052] .view[o246739052] .content[o246739052] { flex: 18;; } .container[o2509604044] { height: auto;width: auto;background: black;margin-top: 45px;animation-name: fade-in-right;animation-iteration-count: 1;animation-duration: 0.5s;; } .container[o1177399929] { min-height: 400px;width: 100%;display: flex;flex-direction: column;; } .left[o1177399929] { background: var(--o-background);flex: 6;padding: 98px;padding-left: 326px; } .right[o1177399929] { flex: 5;padding: 53px;padding-top: 135px;padding-bottom: 135px;border-left: 1px solid #d8d8d8;background: #f1f1f1;color: var(--o-grey);padding-left: 326px; } .code[o1177399929] { white-space: pre;; } .text[o1177399929] { color: var(--o-grey);margin-left: 30px;white-space: pre;; } .title[o1177399929] { color: var(--o-dark-blue);; } .page[o1177399929] { opacity: 0.3;color: cadetblue;; } @media screen and (max-width: $screen) { .left[o1177399929] { padding-left: 77px;; } } @media screen and (max-width: $screen) { .right[o1177399929] { padding-left: 77px;; } } \ No newline at end of file diff --git a/src/classes/ComponentCompiler.ts b/src/classes/ComponentCompiler.ts index 2f7b3c94..3ad88b9e 100644 --- a/src/classes/ComponentCompiler.ts +++ b/src/classes/ComponentCompiler.ts @@ -151,6 +151,7 @@ ${err.stack}`); Object.freeze(Async); `; let result: string = `function (Onode) { + {% modules %} {% ControllersAPI %} {% StoreAPI %} const ___ = (prop, inst, value) => { diff --git a/src/classes/Dependency.ts b/src/classes/Dependency.ts index 67d713c3..ba45b30e 100644 --- a/src/classes/Dependency.ts +++ b/src/classes/Dependency.ts @@ -17,6 +17,7 @@ export default class Dependency extends Utils { private AssetsParser: AssetsParser = new AssetsParser(); private children: Dependency[] = []; public file: string = ''; + public uuid: string = `dep_${crypto.getRandomValues(new Uint16Array(4)).join('')}`; constructor( public component: Component, /** @@ -183,7 +184,7 @@ ${getStructure("'{% absolute %}'", allAsName, { `; } return this.template(importStatement, { - absolute: this.absolutePathURL.pathname + absolute: this.uuid, }); } /** @@ -192,7 +193,6 @@ ${getStructure("'{% absolute %}'", allAsName, { * returns an empty string if the environment isn't development */ get destructuredOgoneRequire(): string { - if (Env._env === 'production') return ''; const { defaultName, allAsName, members, path, isType } = this.data; if (isType) return ''; let destructured = ` @@ -203,7 +203,7 @@ ${getStructure("'{% absolute %}'", allAsName, { return this.template(`const { {% destructured %} } = Ogone.require['{% absolute %}']; `, { destructured, - absolute: this.absolutePathURL.pathname + absolute: this.uuid }); } /** diff --git a/src/classes/Env.ts b/src/classes/Env.ts index 81b89b96..2206ec5c 100755 --- a/src/classes/Env.ts +++ b/src/classes/Env.ts @@ -431,7 +431,7 @@ ${err.stack}`); */ const css: ProductionFile = { path: join(buildPath, './style.css'), - source: entries.map(([, component]: [string, Component],) => component.style.join("\n")).join("\n"), + source: entries.map(([, component]: [string, Component],) => component.style.join("\n")).join(""), }; const dependencies = entries.map(([, component]) => component) .map((component) => { @@ -442,7 +442,7 @@ ${err.stack}`); */ const js: ProductionFile = { path: join(buildPath, './app.js'), - source: await TSTranspiler.transpile(this.template(` + source: await TSTranspiler.bundleText(this.template(` const ROOT_UUID = "${rootComponent.uuid}"; const ROOT_IS_PRIVATE = ${!!rootComponent.elements.template?.attributes.private}; const ROOT_IS_PROTECTED = ${!!rootComponent.elements.template?.attributes.protected}; @@ -467,8 +467,9 @@ ${err.stack}`); source: this.template(HTMLDocument.PAGE_BUILD, { head: ` - ${Configuration.head || ""}`, - script: ``, + ${Configuration.head || ""} + `, + script: ``, dom: ``, }), }; @@ -503,8 +504,19 @@ ${err.stack}`); } public async build(app: ProductionFiles): Promise { const { css, html, js, ressources } = app; + let perf = performance.now(); + const start = perf; await Deno.writeTextFile(html.path, html.source, { create: true }); await Deno.writeTextFile(css.path, css.source, { create: true }); await Deno.writeTextFile(js.path, js.source, { create: true }); + perf = performance.now() - perf; + this.success(`App built in ${(performance.now() - start).toFixed(4)} ms +\t\t\thtml:\t\t${html.path} +\t\t\tjs:\t\t${js.path} +\t\t\tcss:\t\t${css.path} + +\t\t\tdeno:\t\t${Deno.version.deno} +\t\t\ttypescript:\t${Deno.version.typescript} +`); } } diff --git a/src/classes/TSTranspiler.ts b/src/classes/TSTranspiler.ts index ae5889dc..bb6de4ea 100644 --- a/src/classes/TSTranspiler.ts +++ b/src/classes/TSTranspiler.ts @@ -39,6 +39,25 @@ export default class TSTranspiler extends Utils { this.error(`TSTranspiler: ${err.message}`); } } + static async bundleText(text: string): Promise { + const url = Deno.makeTempFileSync({ + prefix: 'ogone_production', + suffix: '.ts', + }); + try { + Deno.writeTextFileSync(url, text); + let result = (await Deno.emit(url, { + bundle: 'esm', + check: false, + })); + const file = result.files['deno:///bundle.js']; + Deno.removeSync(url); + return file; + } catch(err) { + Deno.removeSync(url); + this.error(`TSTranspiler: ${err.message}`); + } + } /** * saves Ogone's runtime, which is bundled, into MapOutput.runtime */ diff --git a/src/classes/Utils.ts b/src/classes/Utils.ts index 4492aa0f..480439c9 100644 --- a/src/classes/Utils.ts +++ b/src/classes/Utils.ts @@ -168,6 +168,9 @@ export abstract class Utils { - Releases: ${cyan(`https://github.com/SRNV/Ogone/releases`)} - Github: ${cyan(`https://github.com/SRNV/Ogone`)} - Projects: ${cyan(`https://github.com/SRNV/Ogone/projects`)} + + deno:\t\t${Deno.version.deno} + typescript:\t${Deno.version.typescript} `); } public exposeSession = Utils.exposeSession.bind(this); diff --git a/src/enums/templateDocumentHTML.ts b/src/enums/templateDocumentHTML.ts index a70ccd84..f43bb7ae 100644 --- a/src/enums/templateDocumentHTML.ts +++ b/src/enums/templateDocumentHTML.ts @@ -16,8 +16,7 @@ enum HTMLDocument { {% head %} - {% dom %} - {% script %} + {% dom %}{% script %} ` From 4fe2c5b081efe74356892060ceeebd5ce976d85a Mon Sep 17 00:00:00 2001 From: SRNV Date: Fri, 26 Mar 2021 16:58:19 +0100 Subject: [PATCH 102/143] feat(wip): start setting static folder by using base attribute --- src/classes/ComponentTypeGetter.ts | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/classes/ComponentTypeGetter.ts b/src/classes/ComponentTypeGetter.ts index 61c58442..983aa06d 100644 --- a/src/classes/ComponentTypeGetter.ts +++ b/src/classes/ComponentTypeGetter.ts @@ -5,6 +5,7 @@ import Ogone from "../main/OgoneBase.ts"; import RouterAnalyzer from "./RouterAnalyzer.ts"; import { Utils } from "./Utils.ts"; import HMR from './HMR.ts'; +import { absolute, existsSync } from '../../deps/deps.ts'; const registry: { [k: string]: { [c: string]: boolean } } = {}; /** @@ -52,6 +53,7 @@ ${err.stack}`); ); } } + this.setApplicationConfiguration(rootComponent); rootComponent.type = "component"; } // change all the sub component that are typed as app @@ -175,4 +177,23 @@ ${err.stack}`); ${err.stack}`); } } + setApplicationConfiguration(component: Component) { + let result; + if (component.elements.proto) { + const [proto] = component.elements.proto; + result = proto.attributes.base as string; + if (result) { + result = absolute(component.file, result); + const position = MapPosition.mapNodes.get(proto)!; + if (!existsSync(result)) { + this.error(`${component.file}:${position.line}:${position.column}\n\t base folder does not exist.`); + } + const info = Deno.statSync(result); + if (info.isFile) { + this.error(`${component.file}:${position.line}:${position.column}\n\t a folder is required for proto's base attribute.`); + } + } + } + Configuration.static = result || Configuration.static; + } } From 2de21db731e6e51c021b4510eedc7f4a1b3a658b Mon Sep 17 00:00:00 2001 From: SRNV Date: Fri, 26 Mar 2021 18:34:46 +0100 Subject: [PATCH 103/143] base required to fech ressources --- examples/app/Application.o3 | 9 +- examples/app/asyncs/AsyncLogo.o3 | 2 +- examples/app/components/404.o3 | 2 +- examples/app/components/Burger.o3 | 6 +- examples/app/components/Logo.o3 | 2 +- examples/app/components/menu/MenuButton.o3 | 2 +- examples/app/components/menu/MenuMain.o3 | 2 +- .../components/menu/TreeRecursiveButton.o3 | 2 +- examples/app/public/animations.css | 1074 +++++++++++++++++ examples/app/public/async-example.png | Bin 0 -> 52794 bytes examples/app/public/favicon.ico | Bin 0 -> 36144 bytes examples/app/{lib => public/modules}/attr.ts | 0 .../modules}/menu-button-types.ts | 0 examples/app/{lib => public/modules}/print.ts | 0 .../app/{lib => public/modules}/print2.ts | 0 .../modules}/tree-recursive-types.ts | 0 examples/app/{lib => public/modules}/type.ts | 0 examples/app/public/neum-ogone-1.png | Bin 0 -> 14457 bytes examples/app/public/neum-ogone-2.png | Bin 0 -> 13053 bytes examples/app/public/ogone-svg.png | Bin 0 -> 82454 bytes examples/app/public/ogone-svg.svg | 62 + examples/app/public/ogone.svg | 62 + examples/app/public/ogone_small.svg | 8 + examples/app/public/store-example.png | Bin 0 -> 70976 bytes examples/app/public/style.css | 65 + src/classes/ComponentTypeGetter.ts | 2 +- src/classes/Configuration.ts | 2 +- src/classes/Dependency.ts | 4 +- src/classes/Env.ts | 4 +- src/ogone.main.d.ts | 2 - src/workers/server-dev.ts | 34 +- utils/esm-imports.ts | 25 - 32 files changed, 1312 insertions(+), 59 deletions(-) create mode 100755 examples/app/public/animations.css create mode 100644 examples/app/public/async-example.png create mode 100755 examples/app/public/favicon.ico rename examples/app/{lib => public/modules}/attr.ts (100%) rename examples/app/{lib => public/modules}/menu-button-types.ts (100%) rename examples/app/{lib => public/modules}/print.ts (100%) rename examples/app/{lib => public/modules}/print2.ts (100%) rename examples/app/{lib => public/modules}/tree-recursive-types.ts (100%) rename examples/app/{lib => public/modules}/type.ts (100%) create mode 100644 examples/app/public/neum-ogone-1.png create mode 100644 examples/app/public/neum-ogone-2.png create mode 100644 examples/app/public/ogone-svg.png create mode 100755 examples/app/public/ogone-svg.svg create mode 100755 examples/app/public/ogone.svg create mode 100644 examples/app/public/ogone_small.svg create mode 100644 examples/app/public/store-example.png create mode 100755 examples/app/public/style.css diff --git a/examples/app/Application.o3 b/examples/app/Application.o3 index d337270b..8f0f9997 100755 --- a/examples/app/Application.o3 +++ b/examples/app/Application.o3 @@ -12,8 +12,9 @@ import { Obj } from 'https://deno.land/x/obj@0.0.1/mod.ts' */ - + declare: public readonly test: any = Obj; public scrollY: number = 0; diff --git a/examples/app/asyncs/AsyncLogo.o3 b/examples/app/asyncs/AsyncLogo.o3 index 09c90ab6..ecba2b18 100755 --- a/examples/app/asyncs/AsyncLogo.o3 +++ b/examples/app/asyncs/AsyncLogo.o3 @@ -14,7 +14,7 @@ }
    - +
    diff --git a/examples/app/components/404.o3 b/examples/app/components/404.o3 index 4cf0722c..07e1f045 100755 --- a/examples/app/components/404.o3 +++ b/examples/app/components/404.o3 @@ -45,7 +45,7 @@
    - +
    404 route not found.
    diff --git a/examples/app/components/Burger.o3 b/examples/app/components/Burger.o3 index 12b29ae1..96ef11ef 100755 --- a/examples/app/components/Burger.o3 +++ b/examples/app/components/Burger.o3 @@ -1,7 +1,7 @@ import component StoreMenu from '@/examples/app/stores/StoreMenu.o3'; -import print from '../lib/print.ts'; -import attr from '../lib/attr.ts'; -import type { isOpenType } from '../lib/type.ts'; +import print from '../public/modules/print.ts'; +import attr from '../public/modules/attr.ts'; +import type { isOpenType } from '../public/modules/type.ts'; \ No newline at end of file diff --git a/examples/app/components/menu/MenuButton.o3 b/examples/app/components/menu/MenuButton.o3 index 639036b2..34cb487e 100755 --- a/examples/app/components/menu/MenuButton.o3 +++ b/examples/app/components/menu/MenuButton.o3 @@ -1,4 +1,4 @@ -import type { ButtonInterface } from '../../lib/menu-button-types.ts'; +import type { ButtonInterface } from '../../public/modules/menu-button-types.ts';