@muibook/components 2.0.0 → 3.1.0
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/esm/agent/keywords/index.js +104 -4
- package/dist/esm/agent/prompts/index.js +518 -162
- package/dist/esm/components/mui-accordion/block/index.js +2 -6
- package/dist/esm/components/mui-accordion/group/index.js +1 -1
- package/dist/esm/components/mui-accordion/inline/index.js +2 -6
- package/dist/esm/components/mui-addon/index.js +1 -1
- package/dist/esm/components/mui-alert/index.js +10 -5
- package/dist/esm/components/mui-badge/index.js +4 -4
- package/dist/esm/components/mui-body/index.js +4 -4
- package/dist/esm/components/mui-button/index.js +5 -7
- package/dist/esm/components/mui-button-group/index.js +1 -1
- package/dist/esm/components/mui-card/body/index.js +22 -18
- package/dist/esm/components/mui-card/card/index.js +1 -1
- package/dist/esm/components/mui-card/footer/index.js +1 -1
- package/dist/esm/components/mui-card/header/index.js +1 -1
- package/dist/esm/components/mui-carousel/controller/index.js +1 -1
- package/dist/esm/components/mui-carousel/panel/index.js +2 -2
- package/dist/esm/components/mui-checkbox/index.js +186 -0
- package/dist/esm/components/mui-code/index.js +9 -6
- package/dist/esm/components/mui-container/index.js +1 -1
- package/dist/esm/components/mui-field/index.js +14 -7
- package/dist/esm/components/mui-file-upload/index.js +5 -4
- package/dist/esm/components/mui-grid/index.js +1 -1
- package/dist/esm/components/mui-heading/index.js +1 -1
- package/dist/esm/components/mui-icons/accessibility/index.js +4 -4
- package/dist/esm/components/mui-icons/add/index.js +5 -5
- package/dist/esm/components/mui-icons/attention/index.js +5 -5
- package/dist/esm/components/mui-icons/check/index.js +6 -6
- package/dist/esm/components/mui-icons/close/index.js +2 -2
- package/dist/esm/components/mui-icons/down-arrow-circle/index.js +55 -0
- package/dist/esm/components/mui-icons/down-chevron/index.js +2 -2
- package/dist/esm/components/mui-icons/ellipsis/index.js +55 -0
- package/dist/esm/components/mui-icons/globe/index.js +5 -5
- package/dist/esm/components/mui-icons/grid/index.js +1 -1
- package/dist/esm/components/mui-icons/index.js +2 -0
- package/dist/esm/components/mui-icons/info/index.js +2 -2
- package/dist/esm/components/mui-icons/left-arrow/index.js +1 -1
- package/dist/esm/components/mui-icons/left-chevron/index.js +1 -1
- package/dist/esm/components/mui-icons/left-sidebar/index.js +6 -6
- package/dist/esm/components/mui-icons/menu/index.js +6 -6
- package/dist/esm/components/mui-icons/message/index.js +6 -6
- package/dist/esm/components/mui-icons/moon/index.js +2 -2
- package/dist/esm/components/mui-icons/notification/index.js +2 -2
- package/dist/esm/components/mui-icons/right-chevron/index.js +5 -5
- package/dist/esm/components/mui-icons/stop/index.js +2 -2
- package/dist/esm/components/mui-icons/subtract/index.js +7 -7
- package/dist/esm/components/mui-icons/sun/index.js +6 -6
- package/dist/esm/components/mui-icons/toggle/index.js +1 -1
- package/dist/esm/components/mui-icons/up-arrow/index.js +4 -4
- package/dist/esm/components/mui-icons/up-chevron/index.js +1 -1
- package/dist/esm/components/mui-icons/warning/index.js +2 -2
- package/dist/esm/components/mui-image/index.js +1 -1
- package/dist/esm/components/mui-input/index.js +21 -27
- package/dist/esm/components/mui-link/index.js +13 -17
- package/dist/esm/components/mui-list/item/index.js +1 -1
- package/dist/esm/components/mui-list/list/index.js +1 -1
- package/dist/esm/components/mui-message/index.js +14 -9
- package/dist/esm/components/mui-quote/index.js +1 -1
- package/dist/esm/components/mui-responsive/index.js +1 -1
- package/dist/esm/components/mui-rule/index.js +5 -5
- package/dist/esm/components/mui-select/index.js +28 -27
- package/dist/esm/components/mui-slat/accessory/index.js +29 -0
- package/dist/esm/components/mui-slat/index.js +2 -21
- package/dist/esm/components/mui-slat/slat/index.js +139 -0
- package/dist/esm/components/mui-smart-card/index.js +14 -15
- package/dist/esm/components/mui-stack/hstack/index.js +1 -1
- package/dist/esm/components/mui-stack/vstack/index.js +1 -1
- package/dist/esm/components/mui-switch/index.js +3 -9
- package/dist/esm/components/mui-table/cell/index.js +1 -1
- package/dist/esm/components/mui-table/row/index.js +1 -1
- package/dist/esm/components/mui-table/row-group/index.js +1 -1
- package/dist/esm/components/mui-table/table/index.js +1 -1
- package/dist/esm/components/mui-tabs/controller/index.js +1 -1
- package/dist/esm/components/mui-tabs/item/index.js +2 -2
- package/dist/esm/components/mui-tabs/panel/index.js +1 -1
- package/dist/esm/components/mui-tabs/tab-bar/index.js +1 -1
- package/dist/esm/css/mui-base.css +27 -27
- package/dist/esm/css/mui-tokens.css +38 -1
- package/dist/esm/index.js +9 -5
- package/dist/types/components/mui-accordion/block/index.d.ts +1 -1
- package/dist/types/components/mui-accordion/inline/index.d.ts +1 -1
- package/dist/types/components/mui-alert/index.d.ts +5 -1
- package/dist/types/components/mui-checkbox/index.d.ts +1 -0
- package/dist/types/components/mui-field/index.d.ts +3 -1
- package/dist/types/components/mui-file-upload/index.d.ts +1 -1
- package/dist/types/components/mui-icons/down-arrow-circle.d.ts +1 -0
- package/dist/types/components/mui-icons/ellipsis.d.ts +1 -0
- package/dist/types/components/mui-icons/index.d.ts +2 -0
- package/dist/types/components/mui-message/index.d.ts +6 -1
- package/dist/types/components/mui-select/index.d.ts +1 -1
- package/dist/types/components/mui-slat/accessory/index.d.ts +1 -0
- package/dist/types/components/mui-slat/index.d.ts +2 -1
- package/dist/types/components/mui-slat/slat/index.d.ts +3 -0
- package/dist/types/components/mui-smart-card/index.d.ts +2 -1
- package/dist/types/index.d.ts +5 -1
- package/package.json +21 -1
- package/readme.md +19 -0
|
@@ -1,4 +1,6 @@
|
|
|
1
|
-
|
|
1
|
+
import "../mui-body/index.js";
|
|
2
|
+
import "../mui-badge/index.js";
|
|
3
|
+
class u extends HTMLElement {
|
|
2
4
|
static get observedAttributes() {
|
|
3
5
|
return [
|
|
4
6
|
"state",
|
|
@@ -24,18 +26,15 @@ class b extends HTMLElement {
|
|
|
24
26
|
this.render();
|
|
25
27
|
}
|
|
26
28
|
render() {
|
|
27
|
-
const p = this.getAttribute("state") || "default", l = this.getAttribute("number") || "0000", n = this.getAttribute("bg-color"), o = this.getAttribute("bg-image"),
|
|
28
|
-
t && t > 126 && console.warn(
|
|
29
|
-
`[mui-smart-card] The logo height (${t}px) exceeds the recommended maximum of 126px. This may affect vertical alignment or visual consistency.`
|
|
30
|
-
);
|
|
29
|
+
const p = this.getAttribute("state") || "default", l = this.getAttribute("number") || "0000", n = this.getAttribute("bg-color"), o = this.getAttribute("bg-image"), b = this.getAttribute("variant") || "plain", t = this.hasAttribute("inverted"), s = this.getAttribute("type") || "", d = p === "frozen", c = this.getAttribute("logo") || "", g = this.getAttribute("partner") || "", a = this.getAttribute("logo-height"), e = a && !isNaN(parseInt(a, 10)) ? parseInt(a, 10) : void 0;
|
|
31
30
|
let r = "card", i = "";
|
|
32
|
-
|
|
31
|
+
b === "animated" ? r += " animated" : r += " plain", o ? i = `
|
|
33
32
|
background-image: url(${o});
|
|
34
33
|
background-size: cover;
|
|
35
34
|
background-position: center;
|
|
36
35
|
background-repeat: no-repeat;
|
|
37
36
|
` : n ? i = `background: ${n};` : i = `
|
|
38
|
-
background: ${
|
|
37
|
+
background: ${t ? "linear-gradient(180deg, var(--grey-900) 0%, var(--black) 100%)" : "linear-gradient(180deg, var(--grey-200) 0%, var(--white) 100%)"};
|
|
39
38
|
`, this.shadowRoot && (this.shadowRoot.innerHTML = /*html*/
|
|
40
39
|
`
|
|
41
40
|
<style>
|
|
@@ -110,13 +109,13 @@ class b extends HTMLElement {
|
|
|
110
109
|
object-fit: contain;
|
|
111
110
|
display: block;
|
|
112
111
|
width: auto;
|
|
113
|
-
height: ${
|
|
112
|
+
height: ${e ? `calc(${e}px / 1.5)` : "auto"};
|
|
114
113
|
}
|
|
115
114
|
|
|
116
115
|
@media (min-width: 500px) {
|
|
117
116
|
.logo img {
|
|
118
117
|
width: auto;
|
|
119
|
-
height: ${
|
|
118
|
+
height: ${e ? `${e}px` : "auto"};
|
|
120
119
|
}
|
|
121
120
|
}
|
|
122
121
|
|
|
@@ -124,21 +123,21 @@ class b extends HTMLElement {
|
|
|
124
123
|
/* =========================================== */
|
|
125
124
|
.type,
|
|
126
125
|
.card-number::part(display) {
|
|
127
|
-
color: ${
|
|
128
|
-
text-shadow: ${
|
|
126
|
+
color: ${t ? "var(--white)" : "var(--black)"};
|
|
127
|
+
text-shadow: ${t ? "0 0px 8px rgb(0 0 0 / 12%);" : "0 0px 8px rgb(255 255 255 / 12%);"};
|
|
129
128
|
}
|
|
130
129
|
|
|
131
130
|
img {
|
|
132
|
-
filter: ${
|
|
131
|
+
filter: ${t ? "drop-shadow(0px 1px 0px var(--black-opacity-60))" : "drop-shadow(0px 1px 0px var(--white-opacity-60))"};
|
|
133
132
|
}
|
|
134
133
|
|
|
135
134
|
|
|
136
135
|
.inner {
|
|
137
|
-
box-shadow: ${
|
|
136
|
+
box-shadow: ${t ? "inset 0 1px 0 0 rgb(255 255 255 / 20%), 0 1px 0 0 rgb(0 0 0 / 10%)" : "inset 0 1px 0 0 rgb(255 255 255 / 60%), 0 1px 0 0 rgb(0 0 0 / 40%)"};
|
|
138
137
|
}
|
|
139
138
|
|
|
140
139
|
.card.animated .inner::after {
|
|
141
|
-
background: linear-gradient(${
|
|
140
|
+
background: linear-gradient(${t ? "120deg, rgb(255 255 255 / 2%) 30%, rgb(255 255 255 / 8%) 40%, rgb(255 255 255 / 4%) 40%" : "120deg, rgb(255 255 255 / 2%) 30%, rgb(255 255 255 / 25%) 40%, rgb(255 255 255 / 8%) 40%"});
|
|
142
141
|
}
|
|
143
142
|
|
|
144
143
|
/* Type */
|
|
@@ -332,4 +331,4 @@ class b extends HTMLElement {
|
|
|
332
331
|
`);
|
|
333
332
|
}
|
|
334
333
|
}
|
|
335
|
-
customElements.define("mui-smart-card",
|
|
334
|
+
customElements.get("mui-smart-card") || customElements.define("mui-smart-card", u);
|
|
@@ -35,11 +35,7 @@ class h extends HTMLElement {
|
|
|
35
35
|
this.hasAttribute("disabled") ? (this.shadowRoot.host.classList.add("disabled"), (e = this._checkbox) == null || e.setAttribute("aria-disabled", "true"), (i = this._checkbox) == null || i.setAttribute("tabindex", "-1")) : (this.shadowRoot.host.classList.remove("disabled"), (s = this._checkbox) == null || s.removeAttribute("aria-disabled"), (c = this._checkbox) == null || c.removeAttribute("tabindex"));
|
|
36
36
|
}
|
|
37
37
|
_updateIcons() {
|
|
38
|
-
const t = this.shadowRoot.querySelector(
|
|
39
|
-
'slot[name="on-icon"]'
|
|
40
|
-
), e = this.shadowRoot.querySelector(
|
|
41
|
-
'slot[name="off-icon"]'
|
|
42
|
-
);
|
|
38
|
+
const t = this.shadowRoot.querySelector('slot[name="on-icon"]'), e = this.shadowRoot.querySelector('slot[name="off-icon"]');
|
|
43
39
|
t && t.assignedElements().forEach((i) => {
|
|
44
40
|
i.style.display = this._checked ? "inline" : "none";
|
|
45
41
|
}), e && e.assignedElements().forEach((i) => {
|
|
@@ -48,9 +44,7 @@ class h extends HTMLElement {
|
|
|
48
44
|
}
|
|
49
45
|
render() {
|
|
50
46
|
const t = this.getAttribute("label");
|
|
51
|
-
|
|
52
|
-
"mui-switch Accessibility warning: Provide a 'label' to ensure the switch is described for assistive technologies."
|
|
53
|
-
), this.shadowRoot.innerHTML = /*html*/
|
|
47
|
+
this.shadowRoot.innerHTML = /*html*/
|
|
54
48
|
`
|
|
55
49
|
<style>
|
|
56
50
|
:host { display: inline-block; }
|
|
@@ -140,4 +134,4 @@ class h extends HTMLElement {
|
|
|
140
134
|
`;
|
|
141
135
|
}
|
|
142
136
|
}
|
|
143
|
-
customElements.define("mui-switch", h);
|
|
137
|
+
customElements.get("mui-switch") || customElements.define("mui-switch", h);
|
|
@@ -13,7 +13,7 @@ class s extends HTMLElement {
|
|
|
13
13
|
const t = this.getAttribute("icon");
|
|
14
14
|
this.setAttribute("tabindex", this.hasAttribute("active") ? "0" : "-1"), this.shadowRoot.innerHTML = "";
|
|
15
15
|
const i = document.createElement("style");
|
|
16
|
-
if (i.textContent = /*
|
|
16
|
+
if (i.textContent = /*css*/
|
|
17
17
|
`
|
|
18
18
|
:host {
|
|
19
19
|
user-select: none;
|
|
@@ -58,4 +58,4 @@ class s extends HTMLElement {
|
|
|
58
58
|
this.classList.toggle("active", t), this.setAttribute("role", "tab"), this.setAttribute("aria-selected", t ? "true" : "false"), this.setAttribute("tabindex", t ? "0" : "-1"), this.iconEl && this.iconEl.setAttribute("color", t ? "var(--tab-icon-active)" : "var(--tab-icon)");
|
|
59
59
|
}
|
|
60
60
|
}
|
|
61
|
-
customElements.define("mui-tab-item", s);
|
|
61
|
+
customElements.get("mui-tab-item") || customElements.define("mui-tab-item", s);
|
|
@@ -40,39 +40,39 @@ textarea {
|
|
|
40
40
|
border-radius: var(--radius-000);
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
-
input[type=
|
|
44
|
-
input[type=
|
|
45
|
-
input[type=
|
|
46
|
-
input[type=
|
|
47
|
-
input[type=
|
|
48
|
-
input[type=
|
|
49
|
-
input[type=
|
|
50
|
-
input[type=
|
|
51
|
-
input[type=
|
|
52
|
-
input[type=
|
|
43
|
+
input[type="text"],
|
|
44
|
+
input[type="email"],
|
|
45
|
+
input[type="number"],
|
|
46
|
+
input[type="password"],
|
|
47
|
+
input[type="file"],
|
|
48
|
+
input[type="search"],
|
|
49
|
+
input[type="range"],
|
|
50
|
+
input[type="button"],
|
|
51
|
+
input[type="submit"],
|
|
52
|
+
input[type="reset"],
|
|
53
53
|
button,
|
|
54
54
|
textarea,
|
|
55
55
|
fieldset {
|
|
56
56
|
border: none;
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
-
input[type=
|
|
60
|
-
input[type=
|
|
61
|
-
input[type=
|
|
62
|
-
input[type=
|
|
63
|
-
input[type=
|
|
64
|
-
input[type=
|
|
59
|
+
input[type="text"],
|
|
60
|
+
input[type="email"],
|
|
61
|
+
input[type="number"],
|
|
62
|
+
input[type="password"],
|
|
63
|
+
input[type="search"],
|
|
64
|
+
input[type="range"] {
|
|
65
65
|
height: 4.2rem;
|
|
66
66
|
padding: var(--space-000) var(--space-400);
|
|
67
67
|
}
|
|
68
68
|
|
|
69
|
-
input[type=
|
|
70
|
-
input[type=
|
|
71
|
-
input[type=
|
|
72
|
-
input[type=
|
|
73
|
-
input[type=
|
|
74
|
-
input[type=
|
|
75
|
-
input[type=
|
|
69
|
+
input[type="text"],
|
|
70
|
+
input[type="email"],
|
|
71
|
+
input[type="number"],
|
|
72
|
+
input[type="password"],
|
|
73
|
+
input[type="file"],
|
|
74
|
+
input[type="search"],
|
|
75
|
+
input[type="range"],
|
|
76
76
|
textarea,
|
|
77
77
|
fieldset {
|
|
78
78
|
box-shadow: inset 0 0 0 2px #e0e0e0;
|
|
@@ -113,18 +113,18 @@ select {
|
|
|
113
113
|
}
|
|
114
114
|
|
|
115
115
|
/* Radio & Checklist Styles */
|
|
116
|
-
input[type=
|
|
117
|
-
input[type=
|
|
116
|
+
input[type="checkbox"],
|
|
117
|
+
input[type="radio"] {
|
|
118
118
|
margin: 0 var(--space-200) 0 0;
|
|
119
119
|
}
|
|
120
120
|
|
|
121
|
-
input[type=
|
|
121
|
+
input[type="file"] {
|
|
122
122
|
font-size: var(--text-font-size-xs);
|
|
123
123
|
padding: var(--space-400);
|
|
124
124
|
margin-bottom: var(--space-500);
|
|
125
125
|
}
|
|
126
126
|
|
|
127
127
|
button:focus,
|
|
128
|
-
input[type=
|
|
128
|
+
input[type="submit"]:focus {
|
|
129
129
|
box-shadow: inset 0 0 0 1px white;
|
|
130
130
|
}
|
|
@@ -354,6 +354,16 @@ html[data-theme="light"] {
|
|
|
354
354
|
/* Input */
|
|
355
355
|
--input-background: var(--white);
|
|
356
356
|
--input-background-disabled: var(--grey-100);
|
|
357
|
+
|
|
358
|
+
/* Checkbox */
|
|
359
|
+
--checkbox-background: var(--white);
|
|
360
|
+
--checkbox-background-checked: var(--grey-900);
|
|
361
|
+
--checkbox-icon-color-checked: var(--grey-200);
|
|
362
|
+
|
|
363
|
+
--checkbox-background-disabled: var(--grey-100);
|
|
364
|
+
--checkbox-background-checked-disabled: var(--grey-800);
|
|
365
|
+
--checkbox-icon-color-checked-disabled: var(--grey-100);
|
|
366
|
+
|
|
357
367
|
/* Addon */
|
|
358
368
|
--addon-background: var(--grey-100);
|
|
359
369
|
/* Tabs */
|
|
@@ -370,6 +380,13 @@ html[data-theme="light"] {
|
|
|
370
380
|
|
|
371
381
|
/* Carousel */
|
|
372
382
|
--carousel-background: var(--white);
|
|
383
|
+
|
|
384
|
+
/* Slat */
|
|
385
|
+
--slat-background: var(--white-opacity-60);
|
|
386
|
+
--slat-background-hover: var(--white-opacity-90);
|
|
387
|
+
--slat-card-background: var(--surface-elevated-100);
|
|
388
|
+
--slat-card-background-hover: var(--surface-elevated-200);
|
|
389
|
+
--slat-accessory-background: var(--black-opacity-10);
|
|
373
390
|
}
|
|
374
391
|
|
|
375
392
|
/* ==================================================================================================== */
|
|
@@ -524,6 +541,13 @@ html[data-theme="dark"] {
|
|
|
524
541
|
/* Input */
|
|
525
542
|
--input-background: var(--grey-900);
|
|
526
543
|
--input-background-disabled: var(--grey-800);
|
|
544
|
+
/* Checkbox */
|
|
545
|
+
--checkbox-background: var(--grey-900);
|
|
546
|
+
--checkbox-background-checked: var(--grey-200);
|
|
547
|
+
--checkbox-icon-color-checked: var(--grey-900);
|
|
548
|
+
--checkbox-background-disabled: var(--grey-800);
|
|
549
|
+
--checkbox-background-checked-disabled: var(--grey-500);
|
|
550
|
+
--checkbox-icon-color-checked-disabled: var(--grey-900);
|
|
527
551
|
/* Addon */
|
|
528
552
|
--addon-background: var(--grey-1000);
|
|
529
553
|
/* Tabs */
|
|
@@ -540,6 +564,13 @@ html[data-theme="dark"] {
|
|
|
540
564
|
|
|
541
565
|
/* Carousel */
|
|
542
566
|
--carousel-background: var(--grey-700);
|
|
567
|
+
|
|
568
|
+
/* Slat */
|
|
569
|
+
--slat-background: var(--black-opacity-20);
|
|
570
|
+
--slat-background-hover: var(--black-opacity-50);
|
|
571
|
+
--slat-card-background: var(--surface-elevated-100);
|
|
572
|
+
--slat-card-background-hover: var(--surface-elevated-200);
|
|
573
|
+
--slat-accessory-background: var(--white-opacity-10);
|
|
543
574
|
}
|
|
544
575
|
|
|
545
576
|
/* ==================================================================================================== */
|
|
@@ -576,7 +607,9 @@ html[data-theme="dark"] {
|
|
|
576
607
|
--action-attention-border-focus: var(--stroke-size-200) var(--stroke-solid) var(--action-attention-border-color-focus);
|
|
577
608
|
--action-attention-border-disabled: var(--stroke-size-200) var(--stroke-solid)
|
|
578
609
|
var(--action-attention-border-color-disabled);
|
|
579
|
-
--action-padding: var(--space-200) var(--space-
|
|
610
|
+
--action-padding: var(--space-200) calc(var(--space-300) + var(--space-100));
|
|
611
|
+
--action-before-slot-padding: var(--space-300);
|
|
612
|
+
--action-after-slot-padding: var(--space-300);
|
|
580
613
|
--action-icon-only-padding: var(--space-000);
|
|
581
614
|
--action-radius: var(--radius-100);
|
|
582
615
|
--action-font-size: var(--text-font-size);
|
|
@@ -651,4 +684,8 @@ html[data-theme="dark"] {
|
|
|
651
684
|
--carousel-radius: var(--radius-300);
|
|
652
685
|
--carousel-tab-position: var(--space-400);
|
|
653
686
|
--carousel-tab-offset: calc(4.4rem + var(--carousel-tab-position)); /* Tab Height */
|
|
687
|
+
/* Slat [Action] */
|
|
688
|
+
--slat-radius: var(--radius-200);
|
|
689
|
+
/* Checkbox */
|
|
690
|
+
--checkbox-radius: var(--radius-100);
|
|
654
691
|
}
|
package/dist/esm/index.js
CHANGED
|
@@ -1,15 +1,17 @@
|
|
|
1
|
-
import { PartTypes as
|
|
1
|
+
import { PartTypes as jr, Parts as kr, getPartMap as lr } from "./utils/part-map/index.js";
|
|
2
2
|
import "./components/mui-field/index.js";
|
|
3
3
|
import "./components/mui-file-upload/index.js";
|
|
4
4
|
import "./components/mui-addon/index.js";
|
|
5
5
|
import "./components/mui-input/index.js";
|
|
6
|
+
import "./components/mui-checkbox/index.js";
|
|
6
7
|
import "./components/mui-select/index.js";
|
|
7
8
|
import "./components/mui-switch/index.js";
|
|
8
9
|
import "./components/mui-table/table/index.js";
|
|
9
10
|
import "./components/mui-table/cell/index.js";
|
|
10
11
|
import "./components/mui-table/row/index.js";
|
|
11
12
|
import "./components/mui-table/row-group/index.js";
|
|
12
|
-
import "./components/mui-slat/index.js";
|
|
13
|
+
import "./components/mui-slat/slat/index.js";
|
|
14
|
+
import "./components/mui-slat/accessory/index.js";
|
|
13
15
|
import "./components/mui-accordion/group/index.js";
|
|
14
16
|
import "./components/mui-accordion/inline/index.js";
|
|
15
17
|
import "./components/mui-accordion/block/index.js";
|
|
@@ -45,6 +47,8 @@ import "./components/mui-icons/toggle/index.js";
|
|
|
45
47
|
import "./components/mui-icons/up-arrow/index.js";
|
|
46
48
|
import "./components/mui-icons/up-chevron/index.js";
|
|
47
49
|
import "./components/mui-icons/warning/index.js";
|
|
50
|
+
import "./components/mui-icons/down-arrow-circle/index.js";
|
|
51
|
+
import "./components/mui-icons/ellipsis/index.js";
|
|
48
52
|
import "./components/mui-stack/hstack/index.js";
|
|
49
53
|
import "./components/mui-stack/vstack/index.js";
|
|
50
54
|
import "./components/mui-grid/index.js";
|
|
@@ -68,7 +72,7 @@ import "./components/mui-tabs/tab-bar/index.js";
|
|
|
68
72
|
import "./components/mui-carousel/controller/index.js";
|
|
69
73
|
import "./components/mui-carousel/panel/index.js";
|
|
70
74
|
export {
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
75
|
+
jr as PartTypes,
|
|
76
|
+
kr as Parts,
|
|
77
|
+
lr as getPartMap
|
|
74
78
|
};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import "../../mui-icons/down-chevron";
|
|
2
|
-
import "
|
|
2
|
+
import "../../mui-heading";
|
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import "../../mui-icons/right-chevron";
|
|
2
|
-
import "
|
|
2
|
+
import "../../mui-heading";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import "../mui-body";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import "../mui-button";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
|
|
1
|
+
import "../mui-icons/down-chevron";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import "./slat";
|
|
2
|
+
import "./accessory";
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
import "../mui-body";
|
|
2
|
+
import "../mui-badge";
|
package/dist/types/index.d.ts
CHANGED
|
@@ -3,13 +3,15 @@ export * from "./components/mui-field";
|
|
|
3
3
|
export * from "./components/mui-file-upload";
|
|
4
4
|
export * from "./components/mui-addon";
|
|
5
5
|
export * from "./components/mui-input";
|
|
6
|
+
export * from "./components/mui-checkbox";
|
|
6
7
|
export * from "./components/mui-select";
|
|
7
8
|
export * from "./components/mui-switch";
|
|
8
9
|
export * from "./components/mui-table/table";
|
|
9
10
|
export * from "./components/mui-table/cell";
|
|
10
11
|
export * from "./components/mui-table/row";
|
|
11
12
|
export * from "./components/mui-table/row-group";
|
|
12
|
-
export * from "./components/mui-slat";
|
|
13
|
+
export * from "./components/mui-slat/slat";
|
|
14
|
+
export * from "./components/mui-slat/accessory";
|
|
13
15
|
export * from "./components/mui-accordion/group";
|
|
14
16
|
export * from "./components/mui-accordion/inline";
|
|
15
17
|
export * from "./components/mui-accordion/block";
|
|
@@ -45,6 +47,8 @@ export * from "./components/mui-icons/toggle";
|
|
|
45
47
|
export * from "./components/mui-icons/up-arrow";
|
|
46
48
|
export * from "./components/mui-icons/up-chevron";
|
|
47
49
|
export * from "./components/mui-icons/warning";
|
|
50
|
+
export * from "./components/mui-icons/down-arrow-circle";
|
|
51
|
+
export * from "./components/mui-icons/ellipsis";
|
|
48
52
|
export * from "./components/mui-stack/hstack";
|
|
49
53
|
export * from "./components/mui-stack/vstack";
|
|
50
54
|
export * from "./components/mui-grid";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@muibook/components",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "A library of MUI-based design system components.",
|
|
6
6
|
"author": "Michael Trilford",
|
|
@@ -216,6 +216,14 @@
|
|
|
216
216
|
"import": "./dist/esm/components/mui-icons/warning/index.js",
|
|
217
217
|
"types": "./dist/types/components/mui-icons/warning/index.d.ts"
|
|
218
218
|
},
|
|
219
|
+
"./mui-icons/down-arrow-circle": {
|
|
220
|
+
"import": "./dist/esm/components/mui-icons/down-arrow-circle/index.js",
|
|
221
|
+
"types": "./dist/types/components/mui-icons/down-arrow-circle/index.d.ts"
|
|
222
|
+
},
|
|
223
|
+
"./mui-icons/ellipsis": {
|
|
224
|
+
"import": "./dist/esm/components/mui-icons/ellipsis/index.js",
|
|
225
|
+
"types": "./dist/types/components/mui-icons/ellipsis/index.d.ts"
|
|
226
|
+
},
|
|
219
227
|
"./mui-image": {
|
|
220
228
|
"import": "./dist/esm/components/mui-image/index.js",
|
|
221
229
|
"types": "./dist/types/components/mui-image/index.d.ts"
|
|
@@ -224,6 +232,10 @@
|
|
|
224
232
|
"import": "./dist/esm/components/mui-input/index.js",
|
|
225
233
|
"types": "./dist/types/components/mui-input/index.d.ts"
|
|
226
234
|
},
|
|
235
|
+
"./mui-checkbox": {
|
|
236
|
+
"import": "./dist/esm/components/mui-checkbox/index.js",
|
|
237
|
+
"types": "./dist/types/components/mui-checkbox/index.d.ts"
|
|
238
|
+
},
|
|
227
239
|
"./mui-link": {
|
|
228
240
|
"import": "./dist/esm/components/mui-link/index.js",
|
|
229
241
|
"types": "./dist/types/components/mui-link/index.d.ts"
|
|
@@ -264,6 +276,14 @@
|
|
|
264
276
|
"import": "./dist/esm/components/mui-slat/index.js",
|
|
265
277
|
"types": "./dist/types/components/mui-slat/index.d.ts"
|
|
266
278
|
},
|
|
279
|
+
"./mui-slat/slat": {
|
|
280
|
+
"import": "./dist/esm/components/mui-slat/slat/index.js",
|
|
281
|
+
"types": "./dist/types/components/mui-slat/slat/index.d.ts"
|
|
282
|
+
},
|
|
283
|
+
"./mui-slat/accessory": {
|
|
284
|
+
"import": "./dist/esm/components/mui-slat/accessory/index.js",
|
|
285
|
+
"types": "./dist/types/components/mui-slat/accessory/index.d.ts"
|
|
286
|
+
},
|
|
267
287
|
"./mui-smart-card": {
|
|
268
288
|
"import": "./dist/esm/components/mui-smart-card/index.js",
|
|
269
289
|
"types": "./dist/types/components/mui-smart-card/index.d.ts"
|
package/readme.md
CHANGED
|
@@ -183,6 +183,25 @@ npm publish
|
|
|
183
183
|
- Use the preview scripts to verify production builds before deployment
|
|
184
184
|
- Follow semantic versioning for releases
|
|
185
185
|
|
|
186
|
+
#### Adding new components
|
|
187
|
+
|
|
188
|
+
When adding new components, there are a couple of areas in the build we need to update.
|
|
189
|
+
|
|
190
|
+
1. vite.config.ts
|
|
191
|
+
Add the new component’s entry point to the build configuration so it’s bundled into the final output.
|
|
192
|
+
|
|
193
|
+
2. package.json
|
|
194
|
+
Ensure the new component is added to the exports field so it can be imported by consumers. If you’re using a files field, include the component path there too.
|
|
195
|
+
|
|
196
|
+
3. src/index.ts (Central export file)
|
|
197
|
+
Add an export \* from "./components/..."; line pointing to your new component’s file or directory. This makes it available through your library’s main entry point.
|
|
198
|
+
|
|
199
|
+
4. src/muibook/index.ts: (Demo Site)
|
|
200
|
+
If the component relies on global styles or JS utilities for behavior or preview (e.g., for documentation or dev environments), make sure relevant styles or setup files are imported here.
|
|
201
|
+
|
|
202
|
+
🔍 Note:
|
|
203
|
+
If the component uses an internal index.ts to re-export multiple parts (e.g., mui-icons/index.ts), you only need to reference the directory in your central export:
|
|
204
|
+
|
|
186
205
|
### Slot Implementation Approach (MUI Design System)
|
|
187
206
|
|
|
188
207
|
When implementing slots in MUI components, we use a consistent approach for styling and interaction:
|