kempo-ui 0.0.13 → 0.0.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/kempo-vars.css +1 -0
- package/docs/dev.config.json +5 -9
- package/docs/kempo-ui/components/accordion.html +236 -0
- package/docs/{components → kempo-ui/components}/card.html +8 -7
- package/docs/{components → kempo-ui/components}/content-slider.html +8 -7
- package/docs/kempo-ui/components/dialog.html +339 -0
- package/docs/{components → kempo-ui/components}/focus-capture.html +9 -8
- package/docs/{components → kempo-ui/components}/hybrid-component.html +7 -6
- package/docs/{components → kempo-ui/components}/icon.html +9 -8
- package/docs/{components → kempo-ui/components}/import.html +8 -7
- package/docs/{components → kempo-ui/components}/light-component.html +7 -6
- package/docs/{components → kempo-ui/components}/photo-viewer.html +8 -7
- package/docs/{components → kempo-ui/components}/resize.html +8 -7
- package/docs/{components → kempo-ui/components}/shadow-component.html +7 -6
- package/docs/{components → kempo-ui/components}/show-more.html +8 -7
- package/docs/{components → kempo-ui/components}/side-menu.html +8 -8
- package/docs/{components → kempo-ui/components}/sortable.html +8 -7
- package/docs/{components → kempo-ui/components}/split.html +9 -8
- package/docs/{components → kempo-ui/components}/table.html +32 -32
- package/docs/{components → kempo-ui/components}/tableControls.html +12 -12
- package/docs/{components → kempo-ui/components}/tableCustomFields.html +9 -9
- package/docs/{components → kempo-ui/components}/tableFetchRecords.html +16 -16
- package/docs/{components → kempo-ui/components}/tableFieldSortHide.html +11 -11
- package/docs/{components → kempo-ui/components}/tablePagination.html +17 -17
- package/docs/{components → kempo-ui/components}/tableRecordEditing.html +12 -12
- package/docs/{components → kempo-ui/components}/tableRecordFiltering.html +11 -11
- package/docs/{components → kempo-ui/components}/tableRecordHiding.html +13 -13
- package/docs/{components → kempo-ui/components}/tableRecordSearching.html +11 -11
- package/docs/{components → kempo-ui/components}/tableRecordSelection.html +11 -11
- package/docs/{components → kempo-ui/components}/tableRowControls.html +12 -12
- package/docs/{components → kempo-ui/components}/tableSorting.html +9 -9
- package/docs/{components → kempo-ui/components}/tabs.html +8 -7
- package/docs/{components → kempo-ui/components}/tags.html +8 -7
- package/docs/{components → kempo-ui/components}/theme-switcher.html +8 -7
- package/docs/{components → kempo-ui/components}/timestamp.html +8 -7
- package/docs/kempo-ui/components/toast.html +315 -0
- package/docs/{components → kempo-ui/components}/toggle.html +8 -7
- package/docs/{components → kempo-ui/components}/tree.html +16 -14
- package/docs/{index.html → kempo-ui/index.html} +7 -18
- package/docs/kempo-ui/kempo-vars.css +1 -0
- package/docs/kempo-ui/nav.inc.html +67 -0
- package/docs/kempo-ui/utils/debounce.html +56 -0
- package/docs/{utils → kempo-ui/utils}/drag.html +8 -17
- package/docs/{utils → kempo-ui/utils}/formatTimestamp.html +12 -29
- package/docs/kempo-ui/utils/propConverters.html +90 -0
- package/docs/{utils → kempo-ui/utils}/toTitleCase.html +7 -6
- package/docs/kempo-ui/utils/watchWindowSize.html +72 -0
- package/docs/prod.config.json +0 -8
- package/package.json +2 -2
- package/scripts/build.js +8 -8
- package/scripts/docs.js +3 -0
- package/src/components/Accordion.js +145 -57
- package/src/components/Tabs.js +14 -23
- package/src/kempo-vars.css +1 -0
- package/docs/components/accordion.html +0 -161
- package/docs/components/collapsible.html +0 -193
- package/docs/components/dialog.html +0 -105
- package/docs/components/init.js +0 -7
- package/docs/components/persistant-collapsible.html +0 -117
- package/docs/components/toast.html +0 -52
- package/docs/init.js +0 -7
- package/docs/kempo-vars.css +0 -0
- package/docs/kempo.css +0 -1
- package/docs/nav.inc.html +0 -69
- package/docs/utils/debounce.html +0 -74
- package/docs/utils/init.js +0 -8
- package/docs/utils/propConverters.html +0 -128
- package/docs/utils/watchWindowSize.html +0 -162
- package/src/components/Collapsible.js +0 -109
- package/src/components/PersistantCollapsible.js +0 -69
- /package/docs/{icons → kempo-ui/icons}/add.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-back.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-down-double.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-down.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-forward.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-up-double.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/arrow-up.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/cards.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/check.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/chevron-left.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/chevron-right.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/close.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/compare.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/delete.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/drag-handle.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/drawing2.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/edit.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/error.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/export-file.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/file-text.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/file.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/filter-off.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/filter.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/first.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/folder-clear.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/folder-create.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/folder-open.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/folder.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/hide.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/image.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/label-add.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/label.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/last.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/menu.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/mode-auto.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/mode-dark.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/mode-light.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/open-in-browser.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/pause.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/play.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/refresh.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/remove.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/save.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/search.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/settings.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/show.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/storage.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/table-visibility.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/tag.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/tools.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/trash-x.svg +0 -0
- /package/docs/{icons → kempo-ui/icons}/warning.svg +0 -0
- /package/docs/{kempo-hljs.css → kempo-ui/kempo-hljs.css} +0 -0
- /package/docs/{kempo.min.css → kempo-ui/kempo.min.css} +0 -0
- /package/docs/{media → kempo-ui/media}/civic.jpg +0 -0
- /package/docs/{media → kempo-ui/media}/corvette.jpg +0 -0
- /package/docs/{media → kempo-ui/media}/evo.jpg +0 -0
- /package/docs/{media → kempo-ui/media}/gtr.jpg +0 -0
- /package/docs/{media → kempo-ui/media}/nsx.jpg +0 -0
- /package/docs/{nav.inc.js → kempo-ui/nav.inc.js} +0 -0
- /package/docs/{src → kempo-ui/src}/components/Accordion.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Card.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Collapsible.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/ContentSlider.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Dialog.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/FocusCapture.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/HybridComponent.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Icon.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Import.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/LightComponent.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/PersistantCollapsible.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/PhotoViewer.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Resize.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/ShadowComponent.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/ShowMore.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/SideMenu.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Sortable.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Split.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Table.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Tabs.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Tags.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/ThemeSwitcher.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Timestamp.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Toast.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Toggle.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/Tree.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/DeleteRecord.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/Edit.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/ExportCSV.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/ExportJson.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/FieldSortHide.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/Filters.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/FirstPage.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/HiddenCount.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/Hide.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/LastPage.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/NextPage.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/PageSelect.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/PageSize.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/PrevPage.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/Search.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/ShowAll.js +0 -0
- /package/docs/{src → kempo-ui/src}/components/tableControls/TableControl.js +0 -0
- /package/docs/{src → kempo-ui/src}/lit-all.min.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/debounce.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/drag.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/formatTimestamp.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/propConverters.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/toTitleCase.js +0 -0
- /package/docs/{src → kempo-ui/src}/utils/watchWindowSize.js +0 -0
- /package/docs/{styles.css → kempo-ui/styles.css} +0 -0
|
@@ -0,0 +1,339 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
5
|
+
<meta charset="UTF-8">
|
|
6
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
7
|
+
<title>Dialog - Components - Kempo Docs - A Web Components Solution</title>
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
12
|
+
<script>window.litDisableBundleWarning = true;</script>
|
|
13
|
+
</head>
|
|
14
|
+
<body>
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
16
|
+
<main>
|
|
17
|
+
<h1 class="ta-center">Dialog</h1>
|
|
18
|
+
|
|
19
|
+
<details class="b r mb">
|
|
20
|
+
<summary class="p">Table of Contents</summary>
|
|
21
|
+
<div class="m mt0 pl">
|
|
22
|
+
<h6>Examples</h6>
|
|
23
|
+
<a href="#basicUsage">Basic Usage</a><br />
|
|
24
|
+
<a href="#titles">Titles</a><br />
|
|
25
|
+
<a href="#actionButtons">Action Buttons</a><br />
|
|
26
|
+
<a href="#jsUsage">JavaScript Usage</a><br />
|
|
27
|
+
<a href="#confirmDialog">Confirm Dialog</a><br />
|
|
28
|
+
|
|
29
|
+
<h6 class="mt">JavaScript Reference</h6>
|
|
30
|
+
<a href="#constructor">Constructor</a><br />
|
|
31
|
+
<a href="#requirements">Requirements</a><br />
|
|
32
|
+
<a href="#attributes">Attributes</a><br />
|
|
33
|
+
<a href="#properties">Properties</a><br />
|
|
34
|
+
<a href="#methods">Methods</a><br />
|
|
35
|
+
<a href="#staticMethods">Static Methods</a><br />
|
|
36
|
+
</div>
|
|
37
|
+
</details>
|
|
38
|
+
|
|
39
|
+
<h3 id="basicUsage"><a href="#basicUsage" class="no-link">Basic Usage</a></h3>
|
|
40
|
+
<p>Create dialogs using the <code>k-dialog</code> component. Open the dialog by calling the <code>open()</code> method, and close it by calling the <code>close()</code> method. Or it can be closed using the dialog's GUI (clicking the overlay, clicking the close button, or the cancel or confirm action buttons).</p>
|
|
41
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-dialog</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d1"</span>></span><br /> <span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"p"</span>></span>Hello World<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br /><span class="hljs-tag"></<span class="hljs-name">k-dialog</span>></span><br /><span class="hljs-tag"><<span class="hljs-name">button</span> <span class="hljs-attr">onclick</span>=<span class="hljs-string">"document.getElementById('d1').open()"</span>></span>Open Dialog<span class="hljs-tag"></<span class="hljs-name">button</span>></span></code></pre>
|
|
42
|
+
<button class="openDialog mb" data-dialog="d1" slot="right">Open Dialog</button>
|
|
43
|
+
<k-dialog id="d1">
|
|
44
|
+
<p class="p">Hello World</p>
|
|
45
|
+
</k-dialog>
|
|
46
|
+
|
|
47
|
+
<h3 id="titles"><a href="#titles" class="no-link">Titles</a></h3>
|
|
48
|
+
<p>Assign an element to the <code>title</code> slot to have it appear as the dialog title.</p>
|
|
49
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-dialog</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d2"</span>></span><br /> <span class="hljs-tag"><<span class="hljs-name">h6</span><br /> <span class="hljs-attr">class</span>=<span class="hljs-string">"m0 px"</span><br /> <span class="hljs-attr">slot</span>=<span class="hljs-string">"title"</span><br /> ></span>This is a fact<span class="hljs-tag"></<span class="hljs-name">h6</span>></span><br /> <span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"p"</span>></span>A hotdog is a sandwhich<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br /><span class="hljs-tag"></<span class="hljs-name">k-dialog</span>></span></code></pre>
|
|
50
|
+
<button class="openDialog mb" data-dialog="d2" slot="right">Open Dialog</button>
|
|
51
|
+
<k-dialog
|
|
52
|
+
id="d2"
|
|
53
|
+
>
|
|
54
|
+
<h6
|
|
55
|
+
class="m0 px"
|
|
56
|
+
slot="title"
|
|
57
|
+
>This is a fact</h6>
|
|
58
|
+
<p class="p">A hotdog is a sandwhich</p>
|
|
59
|
+
</k-dialog>
|
|
60
|
+
|
|
61
|
+
<h3 id="actionButtons"><a href="#actionButtons" class="no-link">Action Buttons</a></h3>
|
|
62
|
+
<p>Add a cancel button using the <code>cancel-text</code> attribute.</p>
|
|
63
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-dialog</span><br /> <span class="hljs-attr">id</span>=<span class="hljs-string">"d4"</span><br /> <span class="hljs-attr">cancel-text</span>=<span class="hljs-string">"Absolutly Not"</span><br />></span><br /> <span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"p"</span>></span>Mint and Chocolate belong together<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br /><span class="hljs-tag"></<span class="hljs-name">k-dialog</span>></span></code></pre>
|
|
64
|
+
<button class="openDialog mb" data-dialog="d4" slot="right">Open Dialog</button>
|
|
65
|
+
<k-dialog
|
|
66
|
+
id="d4"
|
|
67
|
+
cancel-text="Absolutly Not"
|
|
68
|
+
>
|
|
69
|
+
<p class="p">Mint and Chocolate belong together</p>
|
|
70
|
+
</k-dialog>
|
|
71
|
+
|
|
72
|
+
<p>Add a confirm button using the <code>confirm-text</code> attribute.</p>
|
|
73
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-dialog</span><br /> <span class="hljs-attr">id</span>=<span class="hljs-string">"d5"</span><br /> <span class="hljs-attr">confirm-text</span>=<span class="hljs-string">"Confirm"</span><br />></span><br /> <span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"p"</span>></span>Spaghetti is the greatest food<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br /><span class="hljs-tag"></<span class="hljs-name">k-dialog</span>></span></code></pre>
|
|
74
|
+
<button class="openDialog mb" data-dialog="d5" slot="right">Open Dialog</button>
|
|
75
|
+
<k-dialog
|
|
76
|
+
id="d5"
|
|
77
|
+
confirm-text="Confirm"
|
|
78
|
+
>
|
|
79
|
+
<p class="p">Spaghetti is the greatest food</p>
|
|
80
|
+
</k-dialog>
|
|
81
|
+
|
|
82
|
+
<p>Try it with both a cancel and confirm button.</p>
|
|
83
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">k-dialog</span><br /> <span class="hljs-attr">id</span>=<span class="hljs-string">"d6"</span><br /> <span class="hljs-attr">cancel-text</span>=<span class="hljs-string">"It should be outlawed"</span><br /> <span class="hljs-attr">confirm-text</span>=<span class="hljs-string">"Of course it is"</span><br />></span><br /> <span class="hljs-tag"><<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">"p"</span>></span>Ranch is gross<span class="hljs-tag"></<span class="hljs-name">p</span>></span><br /><span class="hljs-tag"></<span class="hljs-name">k-dialog</span>></span></code></pre>
|
|
84
|
+
<button class="openDialog mb" data-dialog="d6" slot="right">Open Dialog</button>
|
|
85
|
+
<k-dialog
|
|
86
|
+
id="d6"
|
|
87
|
+
cancel-text="It should be outlawed"
|
|
88
|
+
confirm-text="Of course it is"
|
|
89
|
+
>
|
|
90
|
+
<p class="p">Ranch is gross</p>
|
|
91
|
+
</k-dialog>
|
|
92
|
+
|
|
93
|
+
<h3 id="jsUsage"><a href="#jsUsage" class="no-link">JavaScript Usage</a></h3>
|
|
94
|
+
<h5>Create Dialog</h5>
|
|
95
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">button</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d7"</span>></span>Open Dialog<span class="hljs-tag"></<span class="hljs-name">button</span>></span><br /><span class="hljs-tag"><<span class="hljs-name">script</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"module"</span>></span><span class="javascript"><br /> <span class="hljs-keyword">import</span> Dialog <span class="hljs-keyword">from</span> <span class="hljs-string">'/kempo-ui/src/components/Dialog.js'</span>;<br /> <span class="hljs-built_in">document</span>.getElementById(<span class="hljs-string">'d7'</span>).addEventListener(<span class="hljs-string">'click'</span>, () => {<br /> Dialog.create(<span class="hljs-string">'Hello World'</span>);<br /> });<br /></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
96
|
+
<button id="d7" class="mb">Open Dialog</button>
|
|
97
|
+
<script type="module">
|
|
98
|
+
import Dialog from '/kempo-ui/src/components/Dialog.js';
|
|
99
|
+
document.getElementById('d7').addEventListener('click', () => {
|
|
100
|
+
Dialog.create('Hello World');
|
|
101
|
+
});
|
|
102
|
+
</script>
|
|
103
|
+
|
|
104
|
+
<h5>Dialog with Title</h5>
|
|
105
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">button</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d7b"</span>></span>Open Dialog with Title<span class="hljs-tag"></<span class="hljs-name">button</span>></span><br /><span class="hljs-tag"><<span class="hljs-name">script</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"module"</span>></span><span class="javascript"><br /> <span class="hljs-keyword">import</span> Dialog <span class="hljs-keyword">from</span> <span class="hljs-string">'/kempo-ui/src/components/Dialog.js'</span>;<br /> <span class="hljs-built_in">document</span>.getElementById(<span class="hljs-string">'d7b'</span>).addEventListener(<span class="hljs-string">'click'</span>, () => {<br /> Dialog.create(<span class="hljs-string">'This is the dialog content'</span>, {<br /> <span class="hljs-attr">title</span>: <span class="hljs-string">'My Dialog Title'</span><br /> });<br /> });<br /></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
106
|
+
<button id="d7b" class="mb">Open Dialog with Title</button>
|
|
107
|
+
<script type="module">
|
|
108
|
+
import Dialog from '/kempo-ui/src/components/Dialog.js';
|
|
109
|
+
document.getElementById('d7b').addEventListener('click', () => {
|
|
110
|
+
Dialog.create('This is the dialog content', {
|
|
111
|
+
title: 'My Dialog Title'
|
|
112
|
+
});
|
|
113
|
+
});
|
|
114
|
+
</script>
|
|
115
|
+
|
|
116
|
+
<h5>Error Dialog</h5>
|
|
117
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">button</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d8"</span>></span>Open Dialog<span class="hljs-tag"></<span class="hljs-name">button</span>></span><br /><span class="hljs-tag"><<span class="hljs-name">script</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"module"</span>></span><span class="javascript"><br /> <span class="hljs-keyword">import</span> Dialog <span class="hljs-keyword">from</span> <span class="hljs-string">'/kempo-ui/src/components/Dialog.js'</span>;<br /> <span class="hljs-built_in">document</span>.getElementById(<span class="hljs-string">'d8'</span>).addEventListener(<span class="hljs-string">'click'</span>, () => {<br /> Dialog.error(<span class="hljs-string">"Oh no, don't do that!"</span>);<br /> });<br /></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
118
|
+
<button id="d8" class="mb">Open Dialog</button>
|
|
119
|
+
<script type="module">
|
|
120
|
+
import Dialog from '/kempo-ui/src/components/Dialog.js';
|
|
121
|
+
document.getElementById('d8').addEventListener('click', () => {
|
|
122
|
+
Dialog.error("Oh no, don't do that!");
|
|
123
|
+
});
|
|
124
|
+
</script>
|
|
125
|
+
|
|
126
|
+
<h3 id="confirmDialog"><a href="#confirmDialog" class="no-link">Confirm Dialog</a></h3>
|
|
127
|
+
<p>Use the <code>Dialog.confirm</code> static method to create a confirmation dialog. This method takes a text message, a response callback, and an options object.</p>
|
|
128
|
+
<pre><code class="hljs xml"><span class="hljs-tag"><<span class="hljs-name">button</span> <span class="hljs-attr">id</span>=<span class="hljs-string">"d9"</span>></span>Open Confirm Dialog<span class="hljs-tag"></<span class="hljs-name">button</span>></span><br /><span class="hljs-tag"><<span class="hljs-name">script</span> <span class="hljs-attr">type</span>=<span class="hljs-string">"module"</span>></span><span class="javascript"><br /> <span class="hljs-keyword">import</span> Dialog <span class="hljs-keyword">from</span> <span class="hljs-string">'/kempo-ui/src/components/Dialog.js'</span>;<br /> <span class="hljs-built_in">document</span>.getElementById(<span class="hljs-string">'d9'</span>).addEventListener(<span class="hljs-string">'click'</span>, () => {<br /> Dialog.confirm(<span class="hljs-string">"Are you sure you want to proceed?"</span>, <span class="hljs-function"><span class="hljs-params">response</span> =></span> {<br /> <span class="hljs-built_in">console</span>.log(<span class="hljs-string">"User response:"</span>, response);<br /> });<br /> });<br /></span><span class="hljs-tag"></<span class="hljs-name">script</span>></span></code></pre>
|
|
129
|
+
<button id="d9" class="mb">Open Confirm Dialog</button>
|
|
130
|
+
<script type="module">
|
|
131
|
+
import Dialog from '/kempo-ui/src/components/Dialog.js';
|
|
132
|
+
document.getElementById('d9').addEventListener('click', () => {
|
|
133
|
+
Dialog.confirm("Are you sure you want to proceed?", response => {
|
|
134
|
+
console.log("User response:", response);
|
|
135
|
+
});
|
|
136
|
+
});
|
|
137
|
+
</script>
|
|
138
|
+
|
|
139
|
+
<h2 id="jsRef">JavaScript Reference</h2>
|
|
140
|
+
|
|
141
|
+
<h3 id="constructor"><a href="#constructor" class="no-link">Constructor</a></h3>
|
|
142
|
+
<h6>Extends <a href="/kempo-ui/components/shadow-component.html">ShadowComponent</a></h6>
|
|
143
|
+
<h5>
|
|
144
|
+
<code>new Dialog()</code><br />
|
|
145
|
+
<code>new Dialog(<i>object</i> options)</code>
|
|
146
|
+
</h5>
|
|
147
|
+
|
|
148
|
+
<h4>Parameters</h4>
|
|
149
|
+
<h5><code>options<i>: object</i></code></h5>
|
|
150
|
+
<p>An object containing the initial configuration for the dialog. The options object can contain the following properties:</p>
|
|
151
|
+
<ul>
|
|
152
|
+
<li><code>opened</code>: <i>boolean</i> - Whether the dialog is initially opened.</li>
|
|
153
|
+
<li><code>closeBtn</code>: <i>boolean</i> - Whether to show the close button.</li>
|
|
154
|
+
<li><code>overlayClose</code>: <i>boolean</i> - Whether clicking the overlay closes the dialog.</li>
|
|
155
|
+
<li><code>confirmText</code>: <i>string</i> - Text for the confirm button.</li>
|
|
156
|
+
<li><code>confirmClasses</code>: <i>string</i> - Classes for the confirm button.</li>
|
|
157
|
+
<li><code>confirmAction</code>: <i>function</i> - Action to perform on confirm.</li>
|
|
158
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the cancel button.</li>
|
|
159
|
+
<li><code>cancelClasses</code>: <i>string</i> - Classes for the cancel button.</li>
|
|
160
|
+
<li><code>cancelAction</code>: <i>function</i> - Action to perform on cancel.</li>
|
|
161
|
+
<li><code>closeCallback</code>: <i>function</i> - Callback to execute when the dialog is closed.</li>
|
|
162
|
+
</ul>
|
|
163
|
+
|
|
164
|
+
<h3 id="requirements"><a href="#requirements" class="no-link">Requirements</a></h3>
|
|
165
|
+
<ul>
|
|
166
|
+
<li><a href="/kempo-ui/components/shadow-component.html">ShadowComponent</a></li>
|
|
167
|
+
<li><a href="/kempo-ui/components/icon.html">Icon</a></li>
|
|
168
|
+
<li><a href="/kempo-ui/components/focus-capture.html">FocusCapture</a></li>
|
|
169
|
+
</ul>
|
|
170
|
+
|
|
171
|
+
<h3 id="attributes"><a href="#attributes" class="no-link">Attributes</a></h3>
|
|
172
|
+
<h5><code>opened<i>: boolean</i></code></h5>
|
|
173
|
+
<p>Whether the dialog is opened.</p>
|
|
174
|
+
|
|
175
|
+
<h5><code>close-btn<i>: boolean</i></code></h5>
|
|
176
|
+
<p>Whether to show the close button. Default is <code>true</code>.</p>
|
|
177
|
+
|
|
178
|
+
<h5><code>overlay-close<i>: boolean</i></code></h5>
|
|
179
|
+
<p>Whether clicking the overlay closes the dialog. Default is <code>true</code>.</p>
|
|
180
|
+
|
|
181
|
+
<h5><code>confirm-text<i>: string</i></code></h5>
|
|
182
|
+
<p>Text for the confirm button.</p>
|
|
183
|
+
|
|
184
|
+
<h5><code>confirm-classes<i>: string</i></code></h5>
|
|
185
|
+
<p>Classes for the confirm button. Default is <code>'success ml'</code>.</p>
|
|
186
|
+
|
|
187
|
+
<h5><code>cancel-text<i>: string</i></code></h5>
|
|
188
|
+
<p>Text for the cancel button.</p>
|
|
189
|
+
|
|
190
|
+
<h5><code>cancel-classes<i>: string</i></code></h5>
|
|
191
|
+
<p>Classes for the cancel button.</p>
|
|
192
|
+
|
|
193
|
+
<h3 id="properties"><a href="#properties" class="no-link">Properties</a></h3>
|
|
194
|
+
<h5><code>confirmAction<i>: function</i></code></h5>
|
|
195
|
+
<p>Action to perform on confirm. If the function calls <code>event.preventDefault()</code>, the dialog will not close automatically.</p>
|
|
196
|
+
|
|
197
|
+
<h5><code>cancelAction<i>: function</i></code></h5>
|
|
198
|
+
<p>Action to perform on cancel. If the function calls <code>event.preventDefault()</code>, the dialog will not close automatically.</p>
|
|
199
|
+
|
|
200
|
+
<h5><code>closeCallback<i>: function</i></code></h5>
|
|
201
|
+
<p>Callback to execute when the dialog is closed.</p>
|
|
202
|
+
|
|
203
|
+
<h5><code>previousFocus<i>: HTMLElement</i></code></h5>
|
|
204
|
+
<p>Reference to the element that had focus before the dialog was opened.</p>
|
|
205
|
+
|
|
206
|
+
<h3 id="methods"><a href="#methods" class="no-link">Methods</a></h3>
|
|
207
|
+
<h5><code>open()<i>: void</i></code></h5>
|
|
208
|
+
<p>Opens the dialog and sets focus to the first focusable element or an element with the <code>autofocus</code> attribute.</p>
|
|
209
|
+
|
|
210
|
+
<h5><code>close()<i>: void</i></code></h5>
|
|
211
|
+
<p>Closes the dialog and calls the <code>closeCallback</code>.</p>
|
|
212
|
+
|
|
213
|
+
<h5><code>toggle()<i>: void</i></code></h5>
|
|
214
|
+
<p>Toggles the dialog open or closed.</p>
|
|
215
|
+
|
|
216
|
+
<h5><code>focus()<i>: void</i></code></h5>
|
|
217
|
+
<p>Focuses the first focusable element in the dialog and saves the previously focused element.</p>
|
|
218
|
+
|
|
219
|
+
<h5><code>blur()<i>: void</i></code></h5>
|
|
220
|
+
<p>Returns focus to the element that had focus before the dialog was opened.</p>
|
|
221
|
+
|
|
222
|
+
<h3 id="staticMethods"><a href="#staticMethods" class="no-link">Static Methods</a></h3>
|
|
223
|
+
<h5><code>Dialog.create(contents, options)<i>: Dialog</i></code></h5>
|
|
224
|
+
<p>Creates and opens a new dialog with the specified contents and options. Returns the created Dialog instance.</p>
|
|
225
|
+
<p>If <code>contents</code> is plain text (no HTML tags), it will automatically be wrapped in a <code><p class="p"></code> tag. If it contains HTML, it will be inserted as-is. If it's an HTMLElement or DocumentFragment, it will be appended directly.</p>
|
|
226
|
+
|
|
227
|
+
<h6>Parameters</h6>
|
|
228
|
+
<ul>
|
|
229
|
+
<li><code>contents<i>: string | HTMLElement | DocumentFragment</i></code> - The content to display in the dialog. Plain text will be wrapped in a paragraph tag automatically.</li>
|
|
230
|
+
<li><code>options<i>: object</i></code> - Configuration options for the dialog.</li>
|
|
231
|
+
</ul>
|
|
232
|
+
|
|
233
|
+
<h6>Options</h6>
|
|
234
|
+
<ul>
|
|
235
|
+
<li><code>title</code>: <i>string | HTMLElement</i> - The title to display in the dialog header. Will be wrapped in an <code><h5></code> tag with the <code>title</code> slot.</li>
|
|
236
|
+
<li><code>titleClasses</code>: <i>string</i> - CSS classes for the title element. Default is <code>'pyh px m0'</code>.</li>
|
|
237
|
+
<li><code>opened</code>: <i>boolean</i> - Whether the dialog is initially opened. Default is <code>true</code>.</li>
|
|
238
|
+
<li><code>closeBtn</code>: <i>boolean</i> - Whether to show the close button.</li>
|
|
239
|
+
<li><code>overlayClose</code>: <i>boolean</i> - Whether clicking the overlay closes the dialog.</li>
|
|
240
|
+
<li><code>confirmText</code>: <i>string</i> - Text for the confirm button.</li>
|
|
241
|
+
<li><code>confirmClasses</code>: <i>string</i> - Classes for the confirm button.</li>
|
|
242
|
+
<li><code>confirmAction</code>: <i>function</i> - Action to perform on confirm.</li>
|
|
243
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the cancel button.</li>
|
|
244
|
+
<li><code>cancelClasses</code>: <i>string</i> - Classes for the cancel button.</li>
|
|
245
|
+
<li><code>cancelAction</code>: <i>function</i> - Action to perform on cancel.</li>
|
|
246
|
+
<li><code>closeCallback</code>: <i>function</i> - Callback to execute when the dialog is closed.</li>
|
|
247
|
+
<li><code>removeOnClose</code>: <i>boolean</i> - Whether to remove the dialog from the DOM when closed. Default is <code>true</code>.</li>
|
|
248
|
+
<li><code>closeExisting</code>: <i>boolean</i> - Whether to close existing dialogs before opening this one. Default is <code>true</code>.</li>
|
|
249
|
+
<li><code>width</code>: <i>string</i> - CSS width value for the dialog.</li>
|
|
250
|
+
<li><code>minWidth</code>: <i>string</i> - CSS min-width value for the dialog.</li>
|
|
251
|
+
<li><code>maxWidth</code>: <i>string</i> - CSS max-width value for the dialog.</li>
|
|
252
|
+
<li><code>height</code>: <i>string</i> - CSS height value for the dialog.</li>
|
|
253
|
+
<li><code>minHeight</code>: <i>string</i> - CSS min-height value for the dialog.</li>
|
|
254
|
+
<li><code>maxHeight</code>: <i>string</i> - CSS max-height value for the dialog.</li>
|
|
255
|
+
</ul>
|
|
256
|
+
|
|
257
|
+
<h5><code>Dialog.confirm(text, responseCallback, options)<i>: Dialog</i></code></h5>
|
|
258
|
+
<p>Creates and opens a confirmation dialog with the specified text and options. The response callback receives a boolean value indicating whether the user confirmed (<code>true</code>) or canceled (<code>false</code>).</p>
|
|
259
|
+
|
|
260
|
+
<h6>Parameters</h6>
|
|
261
|
+
<ul>
|
|
262
|
+
<li><code>text<i>: string</i></code> - The message to display in the dialog.</li>
|
|
263
|
+
<li><code>responseCallback<i>: function</i></code> - Function called with the user's response (<code>true</code> for confirm, <code>false</code> for cancel).</li>
|
|
264
|
+
<li><code>options<i>: object</i></code> - Configuration options.</li>
|
|
265
|
+
</ul>
|
|
266
|
+
|
|
267
|
+
<h6>Options</h6>
|
|
268
|
+
<ul>
|
|
269
|
+
<li><code>title</code>: <i>string</i> - The title of the dialog. Default is <code>'Confirm'</code>.</li>
|
|
270
|
+
<li><code>confirmText</code>: <i>string</i> - Text for the confirm button. Default is <code>'Yes'</code>.</li>
|
|
271
|
+
<li><code>confirmClasses</code>: <i>string</i> - Classes for the confirm button. Default is <code>'success ml'</code>.</li>
|
|
272
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the cancel button. Default is <code>'No'</code>.</li>
|
|
273
|
+
<li><code>cancelClasses</code>: <i>string</i> - Classes for the cancel button. Default is <code>'danger'</code>.</li>
|
|
274
|
+
<li><code>closeBtn</code>: <i>boolean</i> - Whether to show the close button. Default is <code>false</code>.</li>
|
|
275
|
+
<li><code>overlayClose</code>: <i>boolean</i> - Whether clicking the overlay closes the dialog. Default is <code>false</code>.</li>
|
|
276
|
+
</ul>
|
|
277
|
+
|
|
278
|
+
<h5><code>Dialog.alert(text, responseCallback, options)<i>: Dialog</i></code></h5>
|
|
279
|
+
<p>Creates and opens an alert dialog with the specified text and options.</p>
|
|
280
|
+
|
|
281
|
+
<h6>Parameters</h6>
|
|
282
|
+
<ul>
|
|
283
|
+
<li><code>text<i>: string</i></code> - The message to display in the dialog.</li>
|
|
284
|
+
<li><code>responseCallback<i>: function</i></code> - Function called when the dialog is closed.</li>
|
|
285
|
+
<li><code>options<i>: object</i></code> - Configuration options.</li>
|
|
286
|
+
</ul>
|
|
287
|
+
|
|
288
|
+
<h6>Options</h6>
|
|
289
|
+
<ul>
|
|
290
|
+
<li><code>title</code>: <i>string</i> - The title of the dialog. Default is <code>'Alert'</code>.</li>
|
|
291
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the OK button. Default is <code>'Ok'</code>.</li>
|
|
292
|
+
</ul>
|
|
293
|
+
|
|
294
|
+
<h5><code>Dialog.error(text, responseCallback, options)<i>: Dialog</i></code></h5>
|
|
295
|
+
<p>Creates and opens an error dialog with the specified text and options. The title is displayed in red.</p>
|
|
296
|
+
|
|
297
|
+
<h6>Parameters</h6>
|
|
298
|
+
<ul>
|
|
299
|
+
<li><code>text<i>: string</i></code> - The error message to display in the dialog.</li>
|
|
300
|
+
<li><code>responseCallback<i>: function</i></code> - Function called when the dialog is closed.</li>
|
|
301
|
+
<li><code>options<i>: object</i></code> - Configuration options.</li>
|
|
302
|
+
</ul>
|
|
303
|
+
|
|
304
|
+
<h6>Options</h6>
|
|
305
|
+
<ul>
|
|
306
|
+
<li><code>title</code>: <i>string</i> - The title of the dialog. Default is <code>'Error'</code>.</li>
|
|
307
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the OK button. Default is <code>'Ok'</code>.</li>
|
|
308
|
+
</ul>
|
|
309
|
+
|
|
310
|
+
<h5><code>Dialog.success(text, responseCallback, options)<i>: Dialog</i></code></h5>
|
|
311
|
+
<p>Creates and opens a success dialog with the specified text and options. The title is displayed in green.</p>
|
|
312
|
+
|
|
313
|
+
<h6>Parameters</h6>
|
|
314
|
+
<ul>
|
|
315
|
+
<li><code>text<i>: string</i></code> - The success message to display in the dialog.</li>
|
|
316
|
+
<li><code>responseCallback<i>: function</i></code> - Function called when the dialog is closed.</li>
|
|
317
|
+
<li><code>options<i>: object</i></code> - Configuration options.</li>
|
|
318
|
+
</ul>
|
|
319
|
+
|
|
320
|
+
<h6>Options</h6>
|
|
321
|
+
<ul>
|
|
322
|
+
<li><code>title</code>: <i>string</i> - The title of the dialog. Default is <code>'Success'</code>.</li>
|
|
323
|
+
<li><code>cancelText</code>: <i>string</i> - Text for the OK button. Default is <code>'Ok'</code>.</li>
|
|
324
|
+
</ul>
|
|
325
|
+
|
|
326
|
+
</main>
|
|
327
|
+
<div style="height:33vh"></div>
|
|
328
|
+
<script type="module" src="/kempo-ui/src/components/Dialog.js"></script>
|
|
329
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
330
|
+
<script>
|
|
331
|
+
document.querySelectorAll('.openDialog').forEach( $btn => {
|
|
332
|
+
$btn.addEventListener('click', () => {
|
|
333
|
+
const $dialog = document.getElementById($btn.dataset.dialog);
|
|
334
|
+
if($dialog) $dialog.open();
|
|
335
|
+
});
|
|
336
|
+
});
|
|
337
|
+
</script>
|
|
338
|
+
</body>
|
|
339
|
+
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>FocusCapture - Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">FocusCapture</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -102,8 +103,8 @@
|
|
|
102
103
|
|
|
103
104
|
</main>
|
|
104
105
|
<div style="height:33vh"></div>
|
|
105
|
-
<script type="module" src="
|
|
106
|
-
<script type="module" src="
|
|
107
|
-
<script type="module" src="
|
|
106
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
107
|
+
<script type="module" src="/kempo-ui/src/components/FocusCapture.js"></script>
|
|
108
|
+
<script type="module" src="/kempo-ui/src/components/Dialog.js"></script>
|
|
108
109
|
</body>
|
|
109
110
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>HybridComponent - Base Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">HybridComponent</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -104,6 +105,6 @@
|
|
|
104
105
|
|
|
105
106
|
</main>
|
|
106
107
|
<div style="height:33vh"></div>
|
|
107
|
-
<script type="module" src="
|
|
108
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
108
109
|
</body>
|
|
109
110
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>Icon - Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="/kempo-ui/kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="/kempo-ui/kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="/kempo-ui/kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="/kempo-ui/styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">Icon</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -145,8 +146,8 @@
|
|
|
145
146
|
|
|
146
147
|
</main>
|
|
147
148
|
<div style="height:33vh"></div>
|
|
148
|
-
<script type="module" src="
|
|
149
|
-
<script type="module" src="
|
|
150
|
-
<script type="module" src="
|
|
149
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
150
|
+
<script type="module" src="/kempo-ui/src/components/Card.js"></script>
|
|
151
|
+
<script type="module" src="/kempo-ui/src/components/Icon.js"></script>
|
|
151
152
|
</body>
|
|
152
153
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>Import - Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">Import</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -63,7 +64,7 @@
|
|
|
63
64
|
|
|
64
65
|
</main>
|
|
65
66
|
<div style="height:33vh"></div>
|
|
66
|
-
<script type="module" src="
|
|
67
|
-
<script type="module" src="
|
|
67
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
68
|
+
<script type="module" src="/kempo-ui/src/components/Card.js"></script>
|
|
68
69
|
</body>
|
|
69
70
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>LightComponent - Base Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">LightComponent</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -91,6 +92,6 @@
|
|
|
91
92
|
|
|
92
93
|
</main>
|
|
93
94
|
<div style="height:33vh"></div>
|
|
94
|
-
<script type="module" src="
|
|
95
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
95
96
|
</body>
|
|
96
97
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>PhotoViewer - Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<main>
|
|
16
17
|
<h1 class="ta-center">PhotoViewer</h1>
|
|
17
18
|
|
|
@@ -214,7 +215,7 @@
|
|
|
214
215
|
|
|
215
216
|
</main>
|
|
216
217
|
<div style="height:33vh"></div>
|
|
217
|
-
<script type="module" src="
|
|
218
|
-
<script type="module" src="
|
|
218
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
219
|
+
<script type="module" src="/kempo-ui/src/components/PhotoViewer.js"></script>
|
|
219
220
|
</body>
|
|
220
221
|
</html>
|
|
@@ -1,17 +1,18 @@
|
|
|
1
1
|
<!DOCTYPE html>
|
|
2
2
|
<html lang="en">
|
|
3
3
|
<head>
|
|
4
|
+
<base href="/kempo-ui/">
|
|
4
5
|
<meta charset="UTF-8">
|
|
5
6
|
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
|
6
7
|
<title>Resize - Components - Kempo Docs - A Web Components Solution</title>
|
|
7
|
-
<link rel="stylesheet" href="
|
|
8
|
-
<link rel="stylesheet" href="
|
|
9
|
-
<link rel="stylesheet" href="
|
|
8
|
+
<link rel="stylesheet" href="kempo-vars.css" />
|
|
9
|
+
<link rel="stylesheet" href="kempo.min.css" />
|
|
10
|
+
<link rel="stylesheet" href="kempo-hljs.css" />
|
|
11
|
+
<link rel="stylesheet" href="styles.css" />
|
|
10
12
|
<script>window.litDisableBundleWarning = true;</script>
|
|
11
|
-
<script type="module" src="./init.js"></script>
|
|
12
13
|
</head>
|
|
13
14
|
<body>
|
|
14
|
-
<k-import src="
|
|
15
|
+
<k-import src="/kempo-ui/nav.inc.html"></k-import>
|
|
15
16
|
<h1 class="ta-center">Resize</h1>
|
|
16
17
|
<main>
|
|
17
18
|
<details class="b r mb">
|
|
@@ -167,7 +168,7 @@
|
|
|
167
168
|
|
|
168
169
|
</main>
|
|
169
170
|
<div style="height:33vh"></div>
|
|
170
|
-
<script type="module" src="
|
|
171
|
-
<script type="module" src="
|
|
171
|
+
<script type="module" src="/kempo-ui/src/components/Import.js"></script>
|
|
172
|
+
<script type="module" src="/kempo-ui/src/components/Resize.js"></script>
|
|
172
173
|
</body>
|
|
173
174
|
</html>
|