-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Update import URL for dump.js, refactor asyncHandler in multiple file…
…s, update mocha and chai versions in test files, fix nested key assignment in proxy object, update header level in intro.md, update library introduction and headings, start working on docs, add btc-driver, update uhtml version in imports, update README.md
- Loading branch information
Showing
11 changed files
with
112 additions
and
47 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -42,5 +42,6 @@ export class Db extends Item { | |
} | ||
} | ||
|
||
static isPrimitive() { return false; } | ||
static ChildClass = Table; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
<!DOCTYPE HTML> | ||
<html lang=en> | ||
<head> | ||
<meta charset="utf-8"> | ||
<meta name=viewport content="width=device-width"> | ||
|
||
<link href="https://cdn.jsdelivr.net/gh/u2ui/u2@main/el/tree1/tree1.min.css" rel=stylesheet> | ||
<script src="https://cdn.jsdelivr.net/gh/u2ui/u2@main/el/tree1/tree1.min.js" type=module async></script> | ||
|
||
<body> | ||
|
||
<section class=main> | ||
|
||
<u2-tree1 aria-expanded="false" id=treeEl aria-live=off>localStorage | ||
</u2-tree1> | ||
|
||
</section> | ||
|
||
|
||
<script type=module class=main> | ||
|
||
import {getStore} from "../drivers/localStorage.js"; | ||
|
||
const store = getStore(); | ||
|
||
treeEl.addEventListener('u2-tree1-expand', event => { | ||
if (!event.load) return; | ||
const treeItem = event.target; | ||
|
||
let item = store; | ||
const path = treeItem.path(); | ||
path.shift(); // first is root | ||
|
||
for (const parent of path) { | ||
item = item.item(parent.getAttribute('name')); | ||
} | ||
|
||
event.load(async (treeEl) => { | ||
await item.loadItems(); | ||
for (const child of item) { | ||
treeEl.innerHTML += | ||
`<u2-tree1 aria-expanded=false aria-live=off name="${child.key}"> | ||
${child.key} | ||
</u2-tree1>`; | ||
} | ||
}); | ||
}); | ||
|
||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters