proto-daisy-ui 0.0.13 → 0.0.16
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/cjs/{index-bd5c74bd.js → index-68d57682.js} +4 -0
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/cjs/proto-daisy-ui.cjs.entry.js +3 -3
- package/dist/cjs/proto-daisy-ui.cjs.js +2 -2
- package/dist/cjs/proto-demo.cjs.entry.js +2 -2
- package/dist/cjs/proto-dial.cjs.entry.js +25 -0
- package/dist/cjs/proto-hero.cjs.entry.js +2 -2
- package/dist/cjs/proto-home.cjs.entry.js +5 -10
- package/dist/cjs/proto-list.cjs.entry.js +2 -2
- package/dist/cjs/proto-shell.cjs.entry.js +10 -10
- package/dist/cjs/{store-27a3de3d.js → store-77878128.js} +1 -1
- package/dist/collection/collection-manifest.json +1 -0
- package/dist/collection/components/proto-daisy-ui/proto-daisy-ui.css +8 -0
- package/dist/collection/components/proto-dial/proto-dial.css +4 -0
- package/dist/collection/components/proto-dial/proto-dial.js +40 -0
- package/dist/collection/components/proto-home/proto-home.css +0 -4
- package/dist/collection/components/proto-home/proto-home.js +4 -11
- package/dist/collection/components/proto-shell/proto-header.js +8 -8
- package/dist/components/index.d.ts +1 -0
- package/dist/components/index.js +1 -0
- package/dist/components/proto-daisy-ui.js +1 -1
- package/dist/components/proto-dial.d.ts +11 -0
- package/dist/components/proto-dial.js +6 -0
- package/dist/components/proto-dial2.js +37 -0
- package/dist/components/proto-home.js +10 -9
- package/dist/components/proto-shell.js +8 -8
- package/dist/esm/{index-26211d93.js → index-bcfd46a8.js} +4 -0
- package/dist/esm/loader.js +2 -2
- package/dist/esm/proto-daisy-ui.entry.js +3 -3
- package/dist/esm/proto-daisy-ui.js +2 -2
- package/dist/esm/proto-demo.entry.js +2 -2
- package/dist/esm/proto-dial.entry.js +21 -0
- package/dist/esm/proto-hero.entry.js +2 -2
- package/dist/esm/proto-home.entry.js +5 -10
- package/dist/esm/proto-list.entry.js +2 -2
- package/dist/esm/proto-shell.entry.js +10 -10
- package/dist/esm/{store-57ec4756.js → store-1d436662.js} +1 -1
- package/dist/proto-daisy-ui/p-09bfc0fe.entry.js +1 -0
- package/dist/proto-daisy-ui/{p-f9b94d4b.js → p-970466aa.js} +1 -1
- package/dist/proto-daisy-ui/{p-01278f45.js → p-a0e57a17.js} +2 -2
- package/dist/proto-daisy-ui/p-aab2d19b.entry.js +1 -0
- package/dist/proto-daisy-ui/p-ad92a9be.entry.js +1 -0
- package/dist/proto-daisy-ui/{p-e2936e82.entry.js → p-b2d96d08.entry.js} +1 -1
- package/dist/proto-daisy-ui/p-b46c3882.entry.js +1 -0
- package/dist/proto-daisy-ui/{p-8b18fc70.entry.js → p-c3aa9b63.entry.js} +1 -1
- package/dist/proto-daisy-ui/p-e099415e.entry.js +1 -0
- package/dist/proto-daisy-ui/proto-daisy-ui.esm.js +1 -1
- package/dist/types/components/proto-dial/proto-dial.d.ts +4 -0
- package/dist/types/components.d.ts +15 -0
- package/dist/types/utils/types.d.ts +5 -1
- package/package.json +1 -1
- package/dist/proto-daisy-ui/p-7edc6199.entry.js +0 -1
- package/dist/proto-daisy-ui/p-c4ee23b0.entry.js +0 -1
- package/dist/proto-daisy-ui/p-cf4ac4ae.entry.js +0 -1
- package/dist/proto-daisy-ui/p-dd60a13a.entry.js +0 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
2
|
-
import { d as dealers, s as state } from './store-
|
|
1
|
+
import { r as registerInstance, h } from './index-bcfd46a8.js';
|
|
2
|
+
import { d as dealers, s as state } from './store-1d436662.js';
|
|
3
3
|
|
|
4
4
|
const protoDemoCss = "";
|
|
5
5
|
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { r as registerInstance, h } from './index-bcfd46a8.js';
|
|
2
|
+
|
|
3
|
+
const protoDialCss = "#proto-dial{--size:12rem;--thickness:2rem}";
|
|
4
|
+
|
|
5
|
+
const updateDial = (num) => {
|
|
6
|
+
return el => {
|
|
7
|
+
const value = num >= 0 && num <= 100 ? num.toString() : '0';
|
|
8
|
+
el.style.setProperty('--value', value);
|
|
9
|
+
};
|
|
10
|
+
};
|
|
11
|
+
const ProtoDial = class {
|
|
12
|
+
constructor(hostRef) {
|
|
13
|
+
registerInstance(this, hostRef);
|
|
14
|
+
}
|
|
15
|
+
render() {
|
|
16
|
+
return (h("div", { id: "proto-dial", class: "radial-progress text-secondary", ref: updateDial(this.value) }, this.value, "%"));
|
|
17
|
+
}
|
|
18
|
+
};
|
|
19
|
+
ProtoDial.style = protoDialCss;
|
|
20
|
+
|
|
21
|
+
export { ProtoDial as proto_dial };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
2
|
-
import { a as actions } from './store-
|
|
1
|
+
import { r as registerInstance, h } from './index-bcfd46a8.js';
|
|
2
|
+
import { a as actions } from './store-1d436662.js';
|
|
3
3
|
|
|
4
4
|
const protoHeroCss = "proto-hero{}";
|
|
5
5
|
|
|
@@ -1,18 +1,12 @@
|
|
|
1
|
-
import { h, r as registerInstance } from './index-
|
|
2
|
-
import { d as dealers, s as state } from './store-
|
|
1
|
+
import { h, r as registerInstance } from './index-bcfd46a8.js';
|
|
2
|
+
import { d as dealers, s as state } from './store-1d436662.js';
|
|
3
3
|
|
|
4
4
|
const ProtoButton = (_props, children) => {
|
|
5
5
|
return h("button", { class: "btn btn-primary" }, children);
|
|
6
6
|
};
|
|
7
7
|
|
|
8
|
-
const protoHomeCss = "
|
|
8
|
+
const protoHomeCss = "";
|
|
9
9
|
|
|
10
|
-
const updateDial = (num) => {
|
|
11
|
-
return el => {
|
|
12
|
-
const value = num >= 0 && num <= 100 ? num.toString() : '0';
|
|
13
|
-
el.style.setProperty('--value', value);
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
10
|
const ProtoHome = class {
|
|
17
11
|
constructor(hostRef) {
|
|
18
12
|
registerInstance(this, hostRef);
|
|
@@ -20,7 +14,8 @@ const ProtoHome = class {
|
|
|
20
14
|
render() {
|
|
21
15
|
const { pick } = state;
|
|
22
16
|
const dealer = dealers[pick];
|
|
23
|
-
|
|
17
|
+
const { name, progress } = dealer;
|
|
18
|
+
return (h("div", { class: "mr-8 flex flex-col flex-nowrap items-start gap-2" }, h("div", { class: "alert alert-info mb-4 shadow-lg" }, h("div", null, h("svg", { fill: "none", viewBox: "0 0 24 24", class: "h-6 w-6 flex-shrink-0 stroke-current" }, h("path", { "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", d: "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" })), h("span", null, "Welcome... [ ", name, " ]"))), h(ProtoButton, null, "Hello"), progress ? (h("proto-dial", { class: "mt-4", value: progress })) : ('')));
|
|
24
19
|
}
|
|
25
20
|
};
|
|
26
21
|
ProtoHome.style = protoHomeCss;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { r as registerInstance, h } from './index-
|
|
2
|
-
import { u as users, s as state } from './store-
|
|
1
|
+
import { r as registerInstance, h } from './index-bcfd46a8.js';
|
|
2
|
+
import { u as users, s as state } from './store-1d436662.js';
|
|
3
3
|
|
|
4
4
|
const protoListCss = "";
|
|
5
5
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { h, r as registerInstance } from './index-
|
|
2
|
-
import { a as actions, s as state, d as dealers } from './store-
|
|
1
|
+
import { h, r as registerInstance } from './index-bcfd46a8.js';
|
|
2
|
+
import { a as actions, s as state, d as dealers } from './store-1d436662.js';
|
|
3
3
|
|
|
4
4
|
const clickHandler = (mfe = undefined) => {
|
|
5
5
|
return _event => {
|
|
@@ -28,10 +28,10 @@ const ProtoHeader = (_props, _children) => {
|
|
|
28
28
|
return (h("div", { class: "navbar m-1 w-auto rounded-md bg-base-100" },
|
|
29
29
|
h("div", { class: "flex-none" },
|
|
30
30
|
h("div", { class: "dropdown" },
|
|
31
|
-
h("
|
|
31
|
+
h("label", { class: "btn btn-ghost btn-square drawer-button", "aria-label": "Navigation", tabindex: "0" },
|
|
32
32
|
h("svg", { fill: "none", viewBox: "0 0 24 24", class: "inline-block h-5 w-5 stroke-current" },
|
|
33
33
|
h("path", { "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", d: "M4 6h16M4 12h16M4 18h16" }))),
|
|
34
|
-
h("ul", { class: "dropdown-content menu mt-1 rounded-md bg-accent p-2 text-accent-content" },
|
|
34
|
+
h("ul", { tabindex: "0", class: "dropdown-content menu mt-1 rounded-md bg-accent p-2 text-accent-content" },
|
|
35
35
|
h("li", null,
|
|
36
36
|
h("button", { class: "btn-ghost", onClick: clickHandler('proto-home'), "aria-label": "Home" },
|
|
37
37
|
h("svg", { class: "h-5 w-5", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor" },
|
|
@@ -48,8 +48,8 @@ const ProtoHeader = (_props, _children) => {
|
|
|
48
48
|
h("a", { class: "btn btn-ghost text-xl normal-case" }, "daisyUI")),
|
|
49
49
|
h("div", { class: "flex-none" },
|
|
50
50
|
h("div", { class: "dropdown dropdown-end" },
|
|
51
|
-
h("
|
|
52
|
-
h("ul", { tabindex: "
|
|
51
|
+
h("label", { class: "btn btn-ghost normal-case", tabindex: "1" }, dealer.name),
|
|
52
|
+
h("ul", { tabindex: "1", class: "dropdown-content menu menu-compact mt-1 w-52 rounded-md bg-secondary p-2 text-secondary-content shadow " }, dealers.map((obj, indx) => {
|
|
53
53
|
const active = indx === pick ? 'active' : undefined;
|
|
54
54
|
return (h("li", null,
|
|
55
55
|
h("a", { class: active, onClick: clickPick(indx) }, obj.name)));
|
|
@@ -57,18 +57,18 @@ const ProtoHeader = (_props, _children) => {
|
|
|
57
57
|
h("div", { class: "divider divider-horizontal flex-none" }),
|
|
58
58
|
h("div", { class: "flex-none" },
|
|
59
59
|
h("div", { class: "dropdown dropdown-end" },
|
|
60
|
-
h("
|
|
61
|
-
h("ul", { tabindex: "
|
|
60
|
+
h("label", { class: "btn btn-ghost normal-case", tabindex: "2" }, state.theme),
|
|
61
|
+
h("ul", { tabindex: "2", class: "dropdown-content menu menu-compact mt-1 w-52 rounded-md bg-secondary p-2 text-secondary-content shadow " }, themes.map(theme => {
|
|
62
62
|
const active = theme === state.theme ? 'active' : undefined;
|
|
63
63
|
return (h("li", null,
|
|
64
64
|
h("a", { class: active, onClick: clickTheme(theme) }, theme)));
|
|
65
65
|
})))),
|
|
66
66
|
h("div", { class: "flex-none" },
|
|
67
67
|
h("div", { class: "dropdown dropdown-end" },
|
|
68
|
-
h("
|
|
68
|
+
h("label", { class: "btn btn-ghost btn-square", "aria-label": "Actions", tabindex: "3" },
|
|
69
69
|
h("svg", { fill: "none", viewBox: "0 0 24 24", class: "inline-block h-5 w-5 stroke-current" },
|
|
70
70
|
h("path", { "stroke-linecap": "round", "stroke-linejoin": "round", "stroke-width": "2", d: "M5 12h.01M12 12h.01M19 12h.01M6 12a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0zm7 0a1 1 0 11-2 0 1 1 0 012 0z" }))),
|
|
71
|
-
h("ul", { tabindex: "
|
|
71
|
+
h("ul", { tabindex: "3", class: "dropdown-content menu menu-compact mt-1 w-52 rounded-md bg-secondary p-2 text-secondary-content shadow " },
|
|
72
72
|
h("li", null,
|
|
73
73
|
h("a", { class: "justify-between" },
|
|
74
74
|
"Profile",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as l,h as o}from"./p-a0e57a17.js";import{u as t,s as a}from"./p-970466aa.js";const r=[{label:"Name",prop:"name"},{label:"Job",prop:"job"},{label:"Favorite Color",prop:"color"}],s=class{constructor(o){l(this,o)}render(){const{pick:l}=a,s=t[l];return o("div",{class:"overflow-x-auto"},o("table",{class:"table-compact table w-full"},o("thead",null,o("tr",null,o("th",null),r.map((({label:l})=>o("th",null,l))))),o("tbody",null,s.map(((l,t)=>o("tr",{class:"hover"},o("th",null,t+1),r.map((({prop:t})=>o("td",null,l[t]))))))),o("tfoot",null,o("tr",null,o("th",null),r.map((({label:l})=>o("th",null,l)))))))}};s.style="";export{s as proto_list}
|