Skip to content
Snippets Groups Projects
Verified Commit ba4ce5b9 authored by Volker Schukai's avatar Volker Schukai :alien:
Browse files

fix: move from devenv to flake.nix (wip)

parent f67212aa
No related branches found
No related tags found
No related merge requests found
Showing
with 1478 additions and 1342 deletions
<h2>Monster</h2>
<div id="container">11</div>
<monster-datasource-dom id="data1">
<script id="data" type="application/json">
{
"dataset": [
{
"cid": 1,
"parentCID": null,
"localeLabel": {
"en": "Root"
}
},
{
"cid": 2,
"parentCID": 1,
"localeLabel": {
"en": "Child 1"
}
},
{
"cid": 3,
"parentCID": 1,
"localeLabel": {
"en": "Child 2"
}
},
{
"cid": 4,
"parentCID": 2,
"localeLabel": {
"en": "Child 1.1"
}
},
{
"cid": 5,
"parentCID": 2,
"localeLabel": {
"en": "Child 1.2"
}
},
{
"cid": 6,
"parentCID": 3,
"localeLabel": {
"en": "Child 2.1"
}
},
{
"cid": 7,
"parentCID": 3,
"localeLabel": {
"en": "Child 2.2"
}
}
]
}
</script>
</monster-datasource-dom>
<script>
const treeMenu = document.createElement('monster-tree-menu');
const datasource = document.getElementById('data1');
treeMenu.setOption('mapping.selector', 'dataset.*');
treeMenu.setOption('mapping.labelTemplate', '${localeLabel | index:en}');
treeMenu.setOption('mapping.valueTemplate', '${cid | tostring }');
treeMenu.setOption('mapping.parentTemplate', 'parentCID');
treeMenu.setOption('mapping.idTemplate', 'cid');
treeMenu.setOption('datasource', datasource);
// treeMenu.addEventListener('monster-change', (e) => console.log('1', e))
// treeMenu.addEventListener('monster-changed', (e) => console.log('2', e))
document.getElementById('container').appendChild(treeMenu);
</script>
\ No newline at end of file
...@@ -12,37 +12,11 @@ import "../../../source/monster.mjs"; ...@@ -12,37 +12,11 @@ import "../../../source/monster.mjs";
import "../styles/monster.pcss"; import "../styles/monster.pcss";
import {domReady} from "../../../source/dom/ready.mjs"; import {domReady} from "../../../source/dom/ready.mjs";
// import hljs from 'highlight.js/lib/core';
// import javascript from 'highlight.js/lib/languages/javascript';
// import html from 'highlight.js/lib/languages/xml';
// import css from 'highlight.js/lib/languages/css';
//
// // import css
// import 'highlight.js/styles/default.css';
import 'prismjs'; import 'prismjs';
//import 'prismjs/themes/prism.css';
// import {loadLanguages} from 'prismjs';
//
// loadLanguages(['js', 'css', 'html',"pcss"]);
//
domReady.then(()=> { domReady.then(()=> {
let codeBlocks = document.querySelectorAll('pre code'); let codeBlocks = document.querySelectorAll('pre code');
console.log(codeBlocks);
codeBlocks.forEach((block) => { codeBlocks.forEach((block) => {
Prism.highlightElement(block); Prism.highlightElement(block);
}); });
} ); } );
// hljs.registerLanguage('javascript', javascript);
// hljs.registerLanguage('html', html);
// hljs.registerLanguage('css', css);
//
//
// hljs.highlightAll();
\ No newline at end of file
This diff is collapsed.
/** /**
* Copyright schukai GmbH and contributors 2022. All Rights Reserved. * Copyright © schukai GmbH and all contributing authors, {{copyRightYear}}. All rights reserved.
* Node module: @schukai/monster * Node module: @schukai/monster
* This file is licensed under the AGPLv3 License. *
* License text available at https://www.gnu.org/licenses/agpl-3.0.en.html * This source code is licensed under the GNU Affero General Public License version 3 (AGPLv3).
* The full text of the license can be found at: https://www.gnu.org/licenses/agpl-3.0.en.html
*
* For those who do not wish to adhere to the AGPLv3, a commercial license is available.
* Acquiring a commercial license allows you to use this software without complying with the AGPLv3 terms.
* For more information about purchasing a commercial license, please contact schukai GmbH.
*/ */
import { ATTRIBUTE_PREFIX } from "../dom/constants.mjs"; import { ATTRIBUTE_PREFIX } from "../dom/constants.mjs";
......
...@@ -36,8 +36,6 @@ const datasetLinkedElementSymbol = Symbol("datasetLinkedElement"); ...@@ -36,8 +36,6 @@ const datasetLinkedElementSymbol = Symbol("datasetLinkedElement");
*/ */
const overlayLinkedElementSymbol = Symbol("overlayLinkedElement"); const overlayLinkedElementSymbol = Symbol("overlayLinkedElement");
/** /**
* The ColumnBar component is used to show and configure the columns of a datatable. * The ColumnBar component is used to show and configure the columns of a datatable.
* *
......
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
This diff is collapsed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment