@shibui-ui/ui 1.24.1 → 1.25.1
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/components/atoms/index.d.ts +45 -16
- package/dist/components/atoms/index.d.ts.map +1 -1
- package/dist/components/molecules/index.d.ts +20 -1
- package/dist/components/molecules/index.d.ts.map +1 -1
- package/dist/components/organisms/index.d.ts +17 -1
- package/dist/components/organisms/index.d.ts.map +1 -1
- package/dist/index.d.ts +3 -82
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +79 -80
- package/dist/index.js.map +1 -1
- package/dist/index10.js +82 -18
- package/dist/index10.js.map +1 -1
- package/dist/index11.js +84 -69
- package/dist/index11.js.map +1 -1
- package/dist/index12.js +40 -26
- package/dist/index12.js.map +1 -1
- package/dist/index13.js +16 -39
- package/dist/index13.js.map +1 -1
- package/dist/index14.js +29 -44
- package/dist/index14.js.map +1 -1
- package/dist/index15.js +16 -117
- package/dist/index15.js.map +1 -1
- package/dist/index16.js +48 -40
- package/dist/index16.js.map +1 -1
- package/dist/index17.js +41 -25
- package/dist/index17.js.map +1 -1
- package/dist/index18.js +76 -49
- package/dist/index18.js.map +1 -1
- package/dist/index19.js +19 -39
- package/dist/index19.js.map +1 -1
- package/dist/index194.js +94 -24
- package/dist/index194.js.map +1 -1
- package/dist/index195.js +2 -2
- package/dist/index197.js +2 -24
- package/dist/index197.js.map +1 -1
- package/dist/index198.js +74 -2
- package/dist/index198.js.map +1 -1
- package/dist/index199.js +64 -35
- package/dist/index199.js.map +1 -1
- package/dist/index20.js +21 -41
- package/dist/index20.js.map +1 -1
- package/dist/index200.js +2 -2
- package/dist/index201.js +54 -13
- package/dist/index201.js.map +1 -1
- package/dist/index202.js +2 -2
- package/dist/index203.js +2 -2
- package/dist/index204.js +143 -157
- package/dist/index204.js.map +1 -1
- package/dist/index205.js +43 -24
- package/dist/index205.js.map +1 -1
- package/dist/index206.js +51 -2
- package/dist/index206.js.map +1 -1
- package/dist/index207.js +2 -11
- package/dist/index207.js.map +1 -1
- package/dist/index208.js +33 -2
- package/dist/index208.js.map +1 -1
- package/dist/index209.js +2 -91
- package/dist/index209.js.map +1 -1
- package/dist/index21.js +90 -26
- package/dist/index21.js.map +1 -1
- package/dist/index210.js +6 -2
- package/dist/index210.js.map +1 -1
- package/dist/index211.js +2 -41
- package/dist/index211.js.map +1 -1
- package/dist/index212.js +260 -2
- package/dist/index212.js.map +1 -1
- package/dist/index213.js +16 -5
- package/dist/index213.js.map +1 -1
- package/dist/index214.js +2 -2
- package/dist/index215.js +2 -35
- package/dist/index215.js.map +1 -1
- package/dist/index216.js +59 -42
- package/dist/index216.js.map +1 -1
- package/dist/index217.js +32 -2
- package/dist/index217.js.map +1 -1
- package/dist/index218.js +2 -85
- package/dist/index218.js.map +1 -1
- package/dist/index219.js +2 -2
- package/dist/index22.js +41 -48
- package/dist/index22.js.map +1 -1
- package/dist/index220.js +73 -65
- package/dist/index220.js.map +1 -1
- package/dist/index221.js +81 -2
- package/dist/index221.js.map +1 -1
- package/dist/index222.js +2 -10
- package/dist/index222.js.map +1 -1
- package/dist/index223.js +133 -2
- package/dist/index223.js.map +1 -1
- package/dist/index224.js +2 -26
- package/dist/index224.js.map +1 -1
- package/dist/index225.js +2 -2
- package/dist/index226.js +66 -12
- package/dist/index226.js.map +1 -1
- package/dist/index227.js +97 -2
- package/dist/index227.js.map +1 -1
- package/dist/index228.js +2 -2
- package/dist/index229.js +62 -24
- package/dist/index229.js.map +1 -1
- package/dist/index23.js +50 -94
- package/dist/index23.js.map +1 -1
- package/dist/index230.js +2 -2
- package/dist/index231.js +2 -2
- package/dist/index232.js +12 -2
- package/dist/index232.js.map +1 -1
- package/dist/index233.js +5 -16
- package/dist/index233.js.map +1 -1
- package/dist/index234.js +2 -2
- package/dist/index235.js +11 -9
- package/dist/index235.js.map +1 -1
- package/dist/index236.js +2 -2
- package/dist/index237.js +76 -34
- package/dist/index237.js.map +1 -1
- package/dist/index238.js +2 -2
- package/dist/index239.js +2 -27
- package/dist/index239.js.map +1 -1
- package/dist/index24.js +37 -34
- package/dist/index24.js.map +1 -1
- package/dist/index240.js +39 -2
- package/dist/index240.js.map +1 -1
- package/dist/index241.js +2 -34
- package/dist/index241.js.map +1 -1
- package/dist/index242.js +235 -12
- package/dist/index242.js.map +1 -1
- package/dist/index243.js +82 -2
- package/dist/index243.js.map +1 -1
- package/dist/index244.js +2 -9
- package/dist/index244.js.map +1 -1
- package/dist/index245.js +94 -2
- package/dist/index245.js.map +1 -1
- package/dist/index246.js +2 -5
- package/dist/index246.js.map +1 -1
- package/dist/index247.js +268 -2
- package/dist/index247.js.map +1 -1
- package/dist/index248.js +2 -36
- package/dist/index248.js.map +1 -1
- package/dist/index249.js +21 -2
- package/dist/index249.js.map +1 -1
- package/dist/index25.js +51 -32
- package/dist/index25.js.map +1 -1
- package/dist/index250.js +2 -31
- package/dist/index250.js.map +1 -1
- package/dist/index251.js +9 -2
- package/dist/index251.js.map +1 -1
- package/dist/index252.js +2 -19
- package/dist/index252.js.map +1 -1
- package/dist/index253.js +15 -2
- package/dist/index253.js.map +1 -1
- package/dist/index254.js +2 -2
- package/dist/index255.js +135 -69
- package/dist/index255.js.map +1 -1
- package/dist/index256.js +2 -11
- package/dist/index256.js.map +1 -1
- package/dist/index257.js +5 -2
- package/dist/index257.js.map +1 -1
- package/dist/index258.js +2 -78
- package/dist/index258.js.map +1 -1
- package/dist/index259.js +9 -2
- package/dist/index259.js.map +1 -1
- package/dist/index26.js +31 -236
- package/dist/index26.js.map +1 -1
- package/dist/index260.js +2 -32
- package/dist/index260.js.map +1 -1
- package/dist/index261.js +2 -2
- package/dist/index262.js +92 -9
- package/dist/index262.js.map +1 -1
- package/dist/index263.js +59 -2
- package/dist/index263.js.map +1 -1
- package/dist/index264.js +2 -16
- package/dist/index264.js.map +1 -1
- package/dist/index265.js +41 -2
- package/dist/index265.js.map +1 -1
- package/dist/index266.js +2 -16
- package/dist/index266.js.map +1 -1
- package/dist/index267.js +34 -9
- package/dist/index267.js.map +1 -1
- package/dist/index268.js +8 -54
- package/dist/index268.js.map +1 -1
- package/dist/index269.js +2 -2
- package/dist/index27.js +27 -58
- package/dist/index27.js.map +1 -1
- package/dist/index270.js +42 -7
- package/dist/index270.js.map +1 -1
- package/dist/index271.js +2 -2
- package/dist/index272.js +2 -34
- package/dist/index272.js.map +1 -1
- package/dist/index273.js +16 -2
- package/dist/index273.js.map +1 -1
- package/dist/index274.js +9 -2
- package/dist/index274.js.map +1 -1
- package/dist/index275.js +6 -13
- package/dist/index275.js.map +1 -1
- package/dist/index276.js +2 -2
- package/dist/index277.js +8 -15
- package/dist/index277.js.map +1 -1
- package/dist/index278.js +2 -2
- package/dist/index279.js +55 -2
- package/dist/index279.js.map +1 -1
- package/dist/index28.js +247 -24
- package/dist/index28.js.map +1 -1
- package/dist/index280.js +2 -42
- package/dist/index280.js.map +1 -1
- package/dist/index281.js +2 -100
- package/dist/index281.js.map +1 -1
- package/dist/index282.js +20 -2
- package/dist/index282.js.map +1 -1
- package/dist/index283.js +2 -97
- package/dist/index283.js.map +1 -1
- package/dist/index284.js +33 -2
- package/dist/index284.js.map +1 -1
- package/dist/index285.js +6 -27
- package/dist/index285.js.map +1 -1
- package/dist/index286.js +2 -2
- package/dist/index287.js +9 -44
- package/dist/index287.js.map +1 -1
- package/dist/index288.js +2 -2
- package/dist/index289.js +2 -33
- package/dist/index289.js.map +1 -1
- package/dist/index29.js +249 -39
- package/dist/index29.js.map +1 -1
- package/dist/index290.js +36 -2
- package/dist/index290.js.map +1 -1
- package/dist/index291.js +2 -57
- package/dist/index291.js.map +1 -1
- package/dist/index292.js +24 -2
- package/dist/index292.js.map +1 -1
- package/dist/index293.js +2 -2
- package/dist/index294.js +26 -247
- package/dist/index294.js.map +1 -1
- package/dist/index295.js +2 -2
- package/dist/index296.js +2 -72
- package/dist/index296.js.map +1 -1
- package/dist/index297.js +42 -2
- package/dist/index297.js.map +1 -1
- package/dist/index298.js +7 -56
- package/dist/index298.js.map +1 -1
- package/dist/index299.js +2 -133
- package/dist/index299.js.map +1 -1
- package/dist/index30.js +32 -19
- package/dist/index30.js.map +1 -1
- package/dist/index300.js +30 -2
- package/dist/index300.js.map +1 -1
- package/dist/index301.js +2 -12
- package/dist/index301.js.map +1 -1
- package/dist/index302.js +34 -2
- package/dist/index302.js.map +1 -1
- package/dist/index303.js +2 -162
- package/dist/index303.js.map +1 -1
- package/dist/index304.js +26 -42
- package/dist/index304.js.map +1 -1
- package/dist/index305.js +2 -81
- package/dist/index305.js.map +1 -1
- package/dist/index306.js +10 -2
- package/dist/index306.js.map +1 -1
- package/dist/index307.js +2 -71
- package/dist/index307.js.map +1 -1
- package/dist/index308.js +2 -2
- package/dist/index309.js +19 -2
- package/dist/index309.js.map +1 -1
- package/dist/index31.js +96 -11
- package/dist/index31.js.map +1 -1
- package/dist/index310.js +2 -81
- package/dist/index310.js.map +1 -1
- package/dist/index311.js +2 -2
- package/dist/index312.js +42 -2
- package/dist/index312.js.map +1 -1
- package/dist/index313.js +2 -74
- package/dist/index313.js.map +1 -1
- package/dist/index314.js +25 -67
- package/dist/index314.js.map +1 -1
- package/dist/index315.js +2 -2
- package/dist/index316.js +9 -17
- package/dist/index316.js.map +1 -1
- package/dist/index317.js +2 -2
- package/dist/index318.js +84 -32
- package/dist/index318.js.map +1 -1
- package/dist/index319.js +2 -2
- package/dist/index32.js +40 -48
- package/dist/index32.js.map +1 -1
- package/dist/index320.js +68 -77
- package/dist/index320.js.map +1 -1
- package/dist/index321.js +2 -2
- package/dist/index322.js +12 -148
- package/dist/index322.js.map +1 -1
- package/dist/index323.js +1 -1
- package/dist/index324.js +28 -6
- package/dist/index324.js.map +1 -1
- package/dist/index325.js +2 -2
- package/dist/index326.js +78 -87
- package/dist/index326.js.map +1 -1
- package/dist/index327.js +2 -2
- package/dist/index328.js +78 -2
- package/dist/index328.js.map +1 -1
- package/dist/index329.js +2 -237
- package/dist/index329.js.map +1 -1
- package/dist/index33.js +20 -56
- package/dist/index33.js.map +1 -1
- package/dist/index330.js +11 -6
- package/dist/index330.js.map +1 -1
- package/dist/index331.js +2 -2
- package/dist/index332.js +18 -59
- package/dist/index332.js.map +1 -1
- package/dist/index333.js +2 -2
- package/dist/index334.js +12 -5
- package/dist/index334.js.map +1 -1
- package/dist/index335.js +2 -2
- package/dist/index336.js +2 -15
- package/dist/index336.js.map +1 -1
- package/dist/index337.js +88 -2
- package/dist/index337.js.map +1 -1
- package/dist/index338.js +24 -2
- package/dist/index338.js.map +1 -1
- package/dist/index339.js +2 -92
- package/dist/index339.js.map +1 -1
- package/dist/index34.js +59 -35
- package/dist/index34.js.map +1 -1
- package/dist/index340.js +42 -14
- package/dist/index340.js.map +1 -1
- package/dist/index341.js +2 -2
- package/dist/index342.js +22 -80
- package/dist/index342.js.map +1 -1
- package/dist/index343.js +2 -2
- package/dist/index344.js +2 -18
- package/dist/index344.js.map +1 -1
- package/dist/index345.js +16 -2
- package/dist/index345.js.map +1 -1
- package/dist/index346.js +2 -268
- package/dist/index346.js.map +1 -1
- package/dist/index347.js +176 -2
- package/dist/index347.js.map +1 -1
- package/dist/index348.js +2 -2
- package/dist/index349.js +35 -39
- package/dist/index349.js.map +1 -1
- package/dist/index35.js +101 -28
- package/dist/index35.js.map +1 -1
- package/dist/index350.js +3 -3
- package/dist/index350.js.map +1 -1
- package/dist/index351.js +2 -2
- package/dist/index352.js +19 -26
- package/dist/index352.js.map +1 -1
- package/dist/index357.js +26 -19
- package/dist/index357.js.map +1 -1
- package/dist/index36.js +115 -33
- package/dist/index36.js.map +1 -1
- package/dist/index37.js +41 -115
- package/dist/index37.js.map +1 -1
- package/dist/index38.js +34 -246
- package/dist/index38.js.map +1 -1
- package/dist/index39.js +30 -137
- package/dist/index39.js.map +1 -1
- package/dist/index4.js +26 -84
- package/dist/index4.js.map +1 -1
- package/dist/index40.js +26 -400
- package/dist/index40.js.map +1 -1
- package/dist/index41.js +28 -77
- package/dist/index41.js.map +1 -1
- package/dist/index42.js +23 -26
- package/dist/index42.js.map +1 -1
- package/dist/index43.js +36 -33
- package/dist/index43.js.map +1 -1
- package/dist/index44.js +62 -16
- package/dist/index44.js.map +1 -1
- package/dist/index45.js +138 -21
- package/dist/index45.js.map +1 -1
- package/dist/index46.js +129 -22
- package/dist/index46.js.map +1 -1
- package/dist/index47.js +41 -19
- package/dist/index47.js.map +1 -1
- package/dist/index48.js +11 -82
- package/dist/index48.js.map +1 -1
- package/dist/index49.js +56 -279
- package/dist/index49.js.map +1 -1
- package/dist/index5.js +21 -34
- package/dist/index5.js.map +1 -1
- package/dist/index50.js +280 -33
- package/dist/index50.js.map +1 -1
- package/dist/index51.js +74 -94
- package/dist/index51.js.map +1 -1
- package/dist/index52.js +66 -41
- package/dist/index52.js.map +1 -1
- package/dist/index53.js +333 -62
- package/dist/index53.js.map +1 -1
- package/dist/index54.js +96 -256
- package/dist/index54.js.map +1 -1
- package/dist/index55.js +38 -130
- package/dist/index55.js.map +1 -1
- package/dist/index56.js +251 -50
- package/dist/index56.js.map +1 -1
- package/dist/index57.js +144 -115
- package/dist/index57.js.map +1 -1
- package/dist/index58.js +93 -183
- package/dist/index58.js.map +1 -1
- package/dist/index59.js +33 -339
- package/dist/index59.js.map +1 -1
- package/dist/index6.js +2 -2
- package/dist/index60.js +102 -66
- package/dist/index60.js.map +1 -1
- package/dist/index61.js +73 -179
- package/dist/index61.js.map +1 -1
- package/dist/index62.js +117 -97
- package/dist/index62.js.map +1 -1
- package/dist/index63.js +113 -263
- package/dist/index63.js.map +1 -1
- package/dist/index64.js +258 -251
- package/dist/index64.js.map +1 -1
- package/dist/index65.js +177 -79
- package/dist/index65.js.map +1 -1
- package/dist/index66.js +261 -140
- package/dist/index66.js.map +1 -1
- package/dist/index67.js +183 -100
- package/dist/index67.js.map +1 -1
- package/dist/index68.js +28 -89
- package/dist/index68.js.map +1 -1
- package/dist/index69.js +20 -161
- package/dist/index69.js.map +1 -1
- package/dist/index7.js +394 -32
- package/dist/index7.js.map +1 -1
- package/dist/index70.js +190 -53
- package/dist/index70.js.map +1 -1
- package/dist/index71.js +204 -112
- package/dist/index71.js.map +1 -1
- package/dist/index72.js +2 -2
- package/dist/index73.js +89 -28
- package/dist/index73.js.map +1 -1
- package/dist/index74.js +126 -63
- package/dist/index74.js.map +1 -1
- package/dist/index75.js +122 -111
- package/dist/index75.js.map +1 -1
- package/dist/index76.js +67 -64
- package/dist/index76.js.map +1 -1
- package/dist/index77.js +112 -88
- package/dist/index77.js.map +1 -1
- package/dist/index78.js +87 -16
- package/dist/index78.js.map +1 -1
- package/dist/index79.js +151 -79
- package/dist/index79.js.map +1 -1
- package/dist/index8.js +25 -127
- package/dist/index8.js.map +1 -1
- package/dist/index80.js +104 -186
- package/dist/index80.js.map +1 -1
- package/dist/index81.js +59 -20
- package/dist/index81.js.map +1 -1
- package/dist/index82.js +17 -129
- package/dist/index82.js.map +1 -1
- package/dist/index83.js +88 -217
- package/dist/index83.js.map +1 -1
- package/dist/index84.js +64 -112
- package/dist/index84.js.map +1 -1
- package/dist/index9.js +30 -45
- package/dist/index9.js.map +1 -1
- package/dist/src/components/atoms/index.d.ts +45 -16
- package/dist/src/components/atoms/index.d.ts.map +1 -1
- package/dist/src/components/molecules/index.d.ts +20 -1
- package/dist/src/components/molecules/index.d.ts.map +1 -1
- package/dist/src/components/organisms/index.d.ts +17 -1
- package/dist/src/components/organisms/index.d.ts.map +1 -1
- package/dist/src/index.d.ts +3 -82
- package/dist/src/index.d.ts.map +1 -1
- package/dist/tokens.css +353 -7
- package/dist/vite.config.d.ts.map +1 -1
- package/package.json +4 -4
package/dist/index208.js
CHANGED
|
@@ -1,5 +1,36 @@
|
|
|
1
|
-
|
|
1
|
+
import { html, nothing } from "lit";
|
|
2
|
+
function emptyStateTemplate(props) {
|
|
3
|
+
const illustrationZone = props.kanji ? html`
|
|
4
|
+
<div class="es-illustration">
|
|
5
|
+
<span class="es-kanji">${props.kanji}</span>
|
|
6
|
+
</div>
|
|
7
|
+
` : html`
|
|
8
|
+
<div class="es-illustration">
|
|
9
|
+
<div class="es-icon-wrap">
|
|
10
|
+
<slot name="illustration"></slot>
|
|
11
|
+
</div>
|
|
12
|
+
</div>
|
|
13
|
+
`;
|
|
14
|
+
return html`
|
|
15
|
+
<div class="es
|
|
16
|
+
${props.layout === "inline" ? "es-inline" : ""}
|
|
17
|
+
${props.size === "sm" ? "es-sm" : ""}
|
|
18
|
+
${props.tone !== "neutral" ? `es-${props.tone}` : ""}
|
|
19
|
+
${props.bordered ? "es-bordered" : ""}
|
|
20
|
+
${props.ghost ? "es-ghost" : ""}
|
|
21
|
+
">
|
|
22
|
+
${illustrationZone}
|
|
23
|
+
<div class="es-body">
|
|
24
|
+
${props.heading ? html`<h3 class="es-title">${props.heading}</h3>` : nothing}
|
|
25
|
+
${props.description ? html`<p class="es-desc">${props.description}</p>` : nothing}
|
|
26
|
+
<div class="es-actions">
|
|
27
|
+
<slot name="actions"></slot>
|
|
28
|
+
</div>
|
|
29
|
+
</div>
|
|
30
|
+
</div>
|
|
31
|
+
`;
|
|
32
|
+
}
|
|
2
33
|
export {
|
|
3
|
-
|
|
34
|
+
emptyStateTemplate
|
|
4
35
|
};
|
|
5
36
|
//# sourceMappingURL=index208.js.map
|
package/dist/index208.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index208.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
1
|
+
{"version":3,"file":"index208.js","sources":["../src/components/molecules/empty-state/lib-empty-state.html.ts"],"sourcesContent":["import { html, nothing, TemplateResult } from 'lit';\n\nexport type LibEmptyStateTone = 'neutral' | 'kaki' | 'celadon' | 'error';\nexport type LibEmptyStateLayout = 'default' | 'inline';\nexport type LibEmptyStateSize = 'sm' | 'md';\n\nexport interface EmptyStateTemplateProps {\n heading: string;\n description: string;\n kanji: string;\n tone: LibEmptyStateTone;\n layout: LibEmptyStateLayout;\n size: LibEmptyStateSize;\n bordered: boolean;\n ghost: boolean;\n}\n\n/**\n * Template para lib-empty-state.\n *\n * Estructura (ambos layouts):\n * div.es\n * div.es-illustration ← kanji | icon-wrap[slot=illustration]\n * div.es-body\n * h3.es-title\n * p.es-desc\n * div.es-actions\n * slot[name=actions]\n *\n * La zona de ilustración se omite si no hay kanji ni slot.\n * El CSS diferencia .es-inline (row) de .es (column).\n */\nexport function emptyStateTemplate(props: EmptyStateTemplateProps): TemplateResult {\n const illustrationZone = props.kanji\n ? html`\n <div class=\"es-illustration\">\n <span class=\"es-kanji\">${props.kanji}</span>\n </div>\n `\n : html`\n <div class=\"es-illustration\">\n <div class=\"es-icon-wrap\">\n <slot name=\"illustration\"></slot>\n </div>\n </div>\n `;\n\n return html`\n <div class=\"es\n ${props.layout === 'inline' ? 'es-inline' : ''}\n ${props.size === 'sm' ? 'es-sm' : ''}\n ${props.tone !== 'neutral' ? `es-${props.tone}` : ''}\n ${props.bordered ? 'es-bordered' : ''}\n ${props.ghost ? 'es-ghost' : ''}\n \">\n ${illustrationZone}\n <div class=\"es-body\">\n ${props.heading\n ? html`<h3 class=\"es-title\">${props.heading}</h3>`\n : nothing}\n ${props.description\n ? html`<p class=\"es-desc\">${props.description}</p>`\n : nothing}\n <div class=\"es-actions\">\n <slot name=\"actions\"></slot>\n </div>\n </div>\n </div>\n `;\n}"],"names":[],"mappings":";AAgCO,SAAS,mBAAmB,OAAgD;AACjF,QAAM,mBAAmB,MAAM,QAC3B;AAAA;AAAA,mCAE6B,MAAM,KAAK;AAAA;AAAA,UAGxC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAQJ,SAAO;AAAA;AAAA,QAED,MAAM,WAAY,WAAY,cAAe,EAAE;AAAA,QAC/C,MAAM,SAAY,OAAY,UAAe,EAAE;AAAA,QAC/C,MAAM,SAAY,YAAY,MAAM,MAAM,IAAI,KAAK,EAAE;AAAA,QACrD,MAAM,WAAwB,gBAAgB,EAAE;AAAA,QAChD,MAAM,QAAwB,aAAe,EAAE;AAAA;AAAA,QAE/C,gBAAgB;AAAA;AAAA,UAEd,MAAM,UACJ,4BAA4B,MAAM,OAAO,UACzC,OAAO;AAAA,UACT,MAAM,cACJ,0BAA0B,MAAM,WAAW,SAC3C,OAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOnB;"}
|
package/dist/index209.js
CHANGED
|
@@ -1,94 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
const SEGMENT_TONE_CLASS = {
|
|
3
|
-
default: "seg-default",
|
|
4
|
-
kaki: "seg-kaki",
|
|
5
|
-
celadon: "seg-celadon",
|
|
6
|
-
error: "seg-error",
|
|
7
|
-
muted: "seg-muted"
|
|
8
|
-
};
|
|
9
|
-
const SEGMENT_TONE_VAR = {
|
|
10
|
-
default: "var(--color-washi-900)",
|
|
11
|
-
kaki: "var(--color-kaki-500)",
|
|
12
|
-
celadon: "var(--color-celadon-500)",
|
|
13
|
-
error: "var(--color-error)",
|
|
14
|
-
muted: "var(--color-washi-300)"
|
|
15
|
-
};
|
|
16
|
-
function segmentColor(seg) {
|
|
17
|
-
if (seg.color) return seg.color;
|
|
18
|
-
const tone = seg.tone ?? "default";
|
|
19
|
-
return SEGMENT_TONE_VAR[tone];
|
|
20
|
-
}
|
|
21
|
-
function segmentClass(seg) {
|
|
22
|
-
if (seg.color) return "";
|
|
23
|
-
return SEGMENT_TONE_CLASS[seg.tone ?? "default"];
|
|
24
|
-
}
|
|
25
|
-
function multiBarTpl(props) {
|
|
26
|
-
const hasLegend = props.segments.some((s) => s.label);
|
|
27
|
-
return html`
|
|
28
|
-
<div class="pb-multi">
|
|
29
|
-
${props.segments.map((seg) => html`
|
|
30
|
-
<div
|
|
31
|
-
class="pb-segment ${segmentClass(seg)}"
|
|
32
|
-
style="
|
|
33
|
-
width: ${seg.percent}%;
|
|
34
|
-
${seg.color ? `background: ${seg.color};` : ""}
|
|
35
|
-
"
|
|
36
|
-
></div>
|
|
37
|
-
`)}
|
|
38
|
-
</div>
|
|
39
|
-
|
|
40
|
-
${hasLegend ? html`
|
|
41
|
-
<div class="pb-legend">
|
|
42
|
-
${props.segments.filter((s) => s.label).map((seg) => html`
|
|
43
|
-
<div class="pb-legend-item">
|
|
44
|
-
<div
|
|
45
|
-
class="pb-legend-dot"
|
|
46
|
-
style="background: ${segmentColor(seg)};"
|
|
47
|
-
></div>
|
|
48
|
-
<span class="pb-legend-text">${seg.label}</span>
|
|
49
|
-
</div>
|
|
50
|
-
`)}
|
|
51
|
-
</div>` : nothing}
|
|
52
|
-
`;
|
|
53
|
-
}
|
|
54
|
-
function singleBarTpl(props) {
|
|
55
|
-
const showInnerValue = props.size === "xl" && props.showValue && !props.indeterminate;
|
|
56
|
-
return html`
|
|
57
|
-
<div
|
|
58
|
-
class="pb"
|
|
59
|
-
role="progressbar"
|
|
60
|
-
aria-valuemin="0"
|
|
61
|
-
aria-valuemax="${props.max}"
|
|
62
|
-
aria-valuenow="${props.indeterminate ? nothing : props.rawValue}"
|
|
63
|
-
aria-label="${props.ariaLabel || nothing}"
|
|
64
|
-
>
|
|
65
|
-
<div class="pb-fill" style="width: ${props.indeterminate ? 100 : props.percent}%">
|
|
66
|
-
${showInnerValue ? html`<span class="pb-inner-value">${Math.round(props.percent)}%</span>` : nothing}
|
|
67
|
-
</div>
|
|
68
|
-
</div>
|
|
69
|
-
`;
|
|
70
|
-
}
|
|
71
|
-
function progressTemplate(props) {
|
|
72
|
-
const isMulti = props.segments.length > 0;
|
|
73
|
-
const hasMeta = !!(props.label || props.valueLabel);
|
|
74
|
-
const showPercent = !isMulti && props.showValue && !props.indeterminate && props.size !== "xl";
|
|
75
|
-
const displayValue = props.valueLabel ? props.valueLabel : showPercent ? `${Math.round(props.percent)}%` : nothing;
|
|
76
|
-
const barTpl = isMulti ? multiBarTpl(props) : singleBarTpl(props);
|
|
77
|
-
if (hasMeta) {
|
|
78
|
-
return html`
|
|
79
|
-
<div class="pb-wrap">
|
|
80
|
-
<div class="pb-header">
|
|
81
|
-
<span class="pb-label">${props.label}</span>
|
|
82
|
-
${displayValue !== nothing ? html`<span class="pb-value">${displayValue}</span>` : nothing}
|
|
83
|
-
</div>
|
|
84
|
-
${barTpl}
|
|
85
|
-
${props.sub ? html`<span class="pb-sub">${props.sub}</span>` : nothing}
|
|
86
|
-
</div>
|
|
87
|
-
`;
|
|
88
|
-
}
|
|
89
|
-
return html`${barTpl}`;
|
|
90
|
-
}
|
|
1
|
+
const emptyStateCss = '@layer tokens,reset,components;@layer reset{:host{display:flex;width:100%;justify-content:center;align-items:center}*,*:before,*:after{box-sizing:border-box}}@layer components{.es{display:flex;flex-direction:column;align-items:center;justify-content:center;text-align:center;padding:var(--lib-space-xl) var(--lib-space-lg);gap:0;width:100%}.es-illustration{margin-bottom:var(--lib-space-lg);display:flex;align-items:center;justify-content:center;position:relative}.es-icon-wrap{width:72px;height:72px;border-radius:var(--radius-full);background:var(--color-washi-100);border:1px solid var(--border-subtle);display:flex;align-items:center;justify-content:center;color:var(--color-washi-400);font-size:28px;flex-shrink:0}.es-kanji{font-family:var(--lib-font-display);font-size:6rem;line-height:1;color:var(--color-washi-200);-webkit-user-select:none;user-select:none;letter-spacing:var(--tracking-tight)}.es-body{display:flex;flex-direction:column;align-items:center;gap:0}.es-title{font-family:var(--lib-font-display);font-size:var(--text-2xl);font-weight:var(--weight-light);letter-spacing:var(--tracking-tight);color:var(--text-primary);margin-bottom:var(--lib-space-sm);line-height:var(--leading-snug)}.es-title em{font-style:italic;color:var(--text-muted)}.es-desc{font-family:var(--lib-font-body);font-size:var(--text-sm);color:var(--text-muted);line-height:var(--leading-relaxed);max-width:320px;margin:0 auto var(--lib-space-lg)}.es-actions{display:flex;align-items:center;justify-content:center;gap:var(--lib-space-sm);flex-wrap:wrap}::slotted([slot="actions"]){flex-shrink:0}:host([size="sm"]) .es{padding:var(--lib-space-lg) var(--lib-space-md)}:host([size="sm"]) .es-icon-wrap{width:48px;height:48px;font-size:20px}:host([size="sm"]) .es-illustration{margin-bottom:var(--lib-space-md)}:host([size="sm"]) .es-title{font-size:var(--text-xl);margin-bottom:var(--lib-space-xs)}:host([size="sm"]) .es-desc{font-size:var(--text-xs);margin-bottom:var(--lib-space-md)}:host([layout="inline"]) .es{flex-direction:row;text-align:left;padding:var(--lib-space-md) var(--lib-space-lg);gap:var(--lib-space-lg);align-items:center;justify-content:flex-start}:host([layout="inline"]) .es-illustration{margin-bottom:0;flex-shrink:0}:host([layout="inline"]) .es-body{align-items:flex-start;gap:var(--lib-space-xs)}:host([layout="inline"]) .es-title{font-size:var(--text-xl);margin-bottom:0}:host([layout="inline"]) .es-desc{margin:0;max-width:400px}:host([layout="inline"]) .es-actions{justify-content:flex-start;margin-top:var(--lib-space-sm)}:host([bordered]) .es{border:1px dashed var(--border-default);background:var(--bg-surface)}:host([ghost]) .es-icon-wrap{background:transparent;border:none;color:var(--color-washi-300);font-size:40px}:host([tone="kaki"]) .es-icon-wrap{background:var(--color-kaki-50);color:var(--color-kaki-500);border-color:var(--color-kaki-100)}:host([tone="celadon"]) .es-icon-wrap{background:var(--color-celadon-100);color:var(--color-celadon-500);border-color:var(--color-celadon-100)}:host([tone="error"]) .es-icon-wrap{background:#f5ddd9;color:var(--color-error);border-color:#f5ddd9}@media(max-width:640px){:host([layout="inline"]) .es{flex-direction:column;text-align:center}:host([layout="inline"]) .es-body{align-items:center}:host([layout="inline"]) .es-actions{justify-content:center}}}';
|
|
91
2
|
export {
|
|
92
|
-
|
|
3
|
+
emptyStateCss as default
|
|
93
4
|
};
|
|
94
5
|
//# sourceMappingURL=index209.js.map
|
package/dist/index209.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index209.js","sources":[
|
|
1
|
+
{"version":3,"file":"index209.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
package/dist/index21.js
CHANGED
|
@@ -1,7 +1,9 @@
|
|
|
1
|
-
import { unsafeCSS, css, LitElement
|
|
2
|
-
import { property, customElement } from "lit/decorators.js";
|
|
1
|
+
import { unsafeCSS, css, LitElement } from "lit";
|
|
2
|
+
import { property, state, customElement } from "lit/decorators.js";
|
|
3
|
+
import "./index25.js";
|
|
4
|
+
import { copyButtonTemplate } from "./index300.js";
|
|
5
|
+
import copyButtonCss from "./index301.js";
|
|
3
6
|
import sharedTokens from "./index196.js";
|
|
4
|
-
import labelStyles from "./index230.js";
|
|
5
7
|
var __defProp = Object.defineProperty;
|
|
6
8
|
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
7
9
|
var __decorateClass = (decorators, target, key, kind) => {
|
|
@@ -12,39 +14,101 @@ var __decorateClass = (decorators, target, key, kind) => {
|
|
|
12
14
|
if (kind && result) __defProp(target, key, result);
|
|
13
15
|
return result;
|
|
14
16
|
};
|
|
15
|
-
|
|
17
|
+
const COPIED_DURATION = 1800;
|
|
18
|
+
let LibCopyButton = class extends LitElement {
|
|
16
19
|
constructor() {
|
|
17
20
|
super(...arguments);
|
|
18
|
-
this.
|
|
19
|
-
this.
|
|
21
|
+
this._resetTimer = null;
|
|
22
|
+
this.value = "";
|
|
23
|
+
this.variant = "ghost";
|
|
24
|
+
this.size = "md";
|
|
25
|
+
this.iconOnly = false;
|
|
26
|
+
this.label = "Copiar";
|
|
27
|
+
this.successLabel = "Copiado";
|
|
28
|
+
this.tooltip = false;
|
|
29
|
+
this.disabled = false;
|
|
30
|
+
this._copied = false;
|
|
31
|
+
}
|
|
32
|
+
/** Refleja _copied como atributo para que los selectores CSS :host([copied]) funcionen */
|
|
33
|
+
updated(changed) {
|
|
34
|
+
if (changed.has("_copied")) {
|
|
35
|
+
this.toggleAttribute("copied", this._copied);
|
|
36
|
+
}
|
|
37
|
+
}
|
|
38
|
+
disconnectedCallback() {
|
|
39
|
+
super.disconnectedCallback();
|
|
40
|
+
if (this._resetTimer) clearTimeout(this._resetTimer);
|
|
41
|
+
}
|
|
42
|
+
async _handleClick() {
|
|
43
|
+
if (!this.value || this.disabled || this._copied) return;
|
|
44
|
+
try {
|
|
45
|
+
await navigator.clipboard.writeText(this.value);
|
|
46
|
+
this._copied = true;
|
|
47
|
+
this.dispatchEvent(
|
|
48
|
+
new CustomEvent("lib-copy", {
|
|
49
|
+
detail: { value: this.value },
|
|
50
|
+
bubbles: true,
|
|
51
|
+
composed: true
|
|
52
|
+
})
|
|
53
|
+
);
|
|
54
|
+
if (this._resetTimer) clearTimeout(this._resetTimer);
|
|
55
|
+
this._resetTimer = setTimeout(() => {
|
|
56
|
+
this._copied = false;
|
|
57
|
+
}, COPIED_DURATION);
|
|
58
|
+
} catch (err) {
|
|
59
|
+
console.error("[lib-copy-button] Error al copiar:", err);
|
|
60
|
+
}
|
|
20
61
|
}
|
|
21
62
|
render() {
|
|
22
|
-
return
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
63
|
+
return copyButtonTemplate({
|
|
64
|
+
value: this.value,
|
|
65
|
+
variant: this.variant,
|
|
66
|
+
size: this.size,
|
|
67
|
+
iconOnly: this.iconOnly,
|
|
68
|
+
label: this.label,
|
|
69
|
+
successLabel: this.successLabel,
|
|
70
|
+
tooltip: this.tooltip,
|
|
71
|
+
copied: this._copied,
|
|
72
|
+
disabled: this.disabled,
|
|
73
|
+
onClick: this._handleClick.bind(this)
|
|
74
|
+
});
|
|
28
75
|
}
|
|
29
76
|
};
|
|
30
|
-
|
|
31
|
-
css
|
|
32
|
-
|
|
33
|
-
`,
|
|
34
|
-
css`
|
|
35
|
-
${unsafeCSS(labelStyles)}
|
|
36
|
-
`
|
|
77
|
+
LibCopyButton.styles = [
|
|
78
|
+
css`${unsafeCSS(sharedTokens)}`,
|
|
79
|
+
css`${unsafeCSS(copyButtonCss)}`
|
|
37
80
|
];
|
|
38
81
|
__decorateClass([
|
|
39
82
|
property({ type: String })
|
|
40
|
-
],
|
|
83
|
+
], LibCopyButton.prototype, "value", 2);
|
|
84
|
+
__decorateClass([
|
|
85
|
+
property({ type: String, reflect: true })
|
|
86
|
+
], LibCopyButton.prototype, "variant", 2);
|
|
87
|
+
__decorateClass([
|
|
88
|
+
property({ type: String, reflect: true })
|
|
89
|
+
], LibCopyButton.prototype, "size", 2);
|
|
90
|
+
__decorateClass([
|
|
91
|
+
property({ type: Boolean, reflect: true, attribute: "icon-only" })
|
|
92
|
+
], LibCopyButton.prototype, "iconOnly", 2);
|
|
93
|
+
__decorateClass([
|
|
94
|
+
property({ type: String })
|
|
95
|
+
], LibCopyButton.prototype, "label", 2);
|
|
96
|
+
__decorateClass([
|
|
97
|
+
property({ type: String, attribute: "success-label" })
|
|
98
|
+
], LibCopyButton.prototype, "successLabel", 2);
|
|
99
|
+
__decorateClass([
|
|
100
|
+
property({ type: Boolean, reflect: true })
|
|
101
|
+
], LibCopyButton.prototype, "tooltip", 2);
|
|
102
|
+
__decorateClass([
|
|
103
|
+
property({ type: Boolean, reflect: true })
|
|
104
|
+
], LibCopyButton.prototype, "disabled", 2);
|
|
41
105
|
__decorateClass([
|
|
42
|
-
|
|
43
|
-
],
|
|
44
|
-
|
|
45
|
-
customElement("lib-
|
|
46
|
-
],
|
|
106
|
+
state()
|
|
107
|
+
], LibCopyButton.prototype, "_copied", 2);
|
|
108
|
+
LibCopyButton = __decorateClass([
|
|
109
|
+
customElement("lib-copy-button")
|
|
110
|
+
], LibCopyButton);
|
|
47
111
|
export {
|
|
48
|
-
|
|
112
|
+
LibCopyButton
|
|
49
113
|
};
|
|
50
114
|
//# sourceMappingURL=index21.js.map
|
package/dist/index21.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index21.js","sources":["../src/components/atoms/
|
|
1
|
+
{"version":3,"file":"index21.js","sources":["../src/components/atoms/copy-button/lib-copy-button.component.ts"],"sourcesContent":["import { LitElement, css, unsafeCSS, TemplateResult } from 'lit';\nimport { customElement, property, state } from 'lit/decorators.js';\nimport '../../atoms/icon/lib-icon.component';\nimport type { LibCopyVariant, LibCopySize } from './lib-copy-button.html';\nimport { copyButtonTemplate } from './lib-copy-button.html';\nimport copyButtonCss from './lib-copy-button.css?inline';\nimport sharedTokens from '../../../styles/shared/tokens.css?inline';\n\n/** Tiempo en ms que el estado copiado permanece activo */\nconst COPIED_DURATION = 1800;\n\n/**\n * @element lib-copy-button\n *\n * Boton que copia texto al portapapeles y confirma la accion\n * con un checkmark animado (crossfade idle/copied con ease-bounce).\n *\n * @fires lib-copy - Emitido al copiar con exito. detail: { value: string }\n *\n * @example\n * <lib-copy-button value=\"npm install @shibui-ui/ui\"></lib-copy-button>\n * <lib-copy-button value=\"sk-ant-api03-xyz\" variant=\"outlined\" tooltip></lib-copy-button>\n * <lib-copy-button value=\"copy me\" variant=\"ghost\" icon-only size=\"sm\"></lib-copy-button>\n */\n@customElement('lib-copy-button')\nexport class LibCopyButton extends LitElement {\n static override styles = [\n css`${unsafeCSS(sharedTokens)}`,\n css`${unsafeCSS(copyButtonCss)}`,\n ];\n\n private _resetTimer: ReturnType<typeof setTimeout> | null = null;\n\n /** Texto que se copia al portapapeles */\n @property({ type: String })\n value = '';\n\n /** Variante visual */\n @property({ type: String, reflect: true })\n variant: LibCopyVariant = 'ghost';\n\n /** Tamaño */\n @property({ type: String, reflect: true })\n size: LibCopySize = 'md';\n\n /** Modo icono-solo (sin label, cuadrado) */\n @property({ type: Boolean, reflect: true, attribute: 'icon-only' })\n iconOnly = false;\n\n /** Label en estado idle */\n @property({ type: String })\n label = 'Copiar';\n\n /** Label en estado copiado */\n @property({ type: String, attribute: 'success-label' })\n successLabel = 'Copiado';\n\n /** Muestra un tooltip \"Copiado\" al copiar */\n @property({ type: Boolean, reflect: true })\n tooltip = false;\n\n /** Estado deshabilitado */\n @property({ type: Boolean, reflect: true })\n disabled = false;\n\n /** Estado interno — activa el crossfade y el tooltip */\n @state()\n private _copied = false;\n\n /** Refleja _copied como atributo para que los selectores CSS :host([copied]) funcionen */\n override updated(changed: Map<string, unknown>): void {\n if (changed.has('_copied')) {\n this.toggleAttribute('copied', this._copied);\n }\n }\n\n override disconnectedCallback(): void {\n super.disconnectedCallback();\n if (this._resetTimer) clearTimeout(this._resetTimer);\n }\n\n private async _handleClick(): Promise<void> {\n if (!this.value || this.disabled || this._copied) return;\n\n try {\n await navigator.clipboard.writeText(this.value);\n this._copied = true;\n\n this.dispatchEvent(\n new CustomEvent('lib-copy', {\n detail: { value: this.value },\n bubbles: true,\n composed: true,\n })\n );\n\n if (this._resetTimer) clearTimeout(this._resetTimer);\n this._resetTimer = setTimeout(() => {\n this._copied = false;\n }, COPIED_DURATION);\n\n } catch (err) {\n console.error('[lib-copy-button] Error al copiar:', err);\n }\n }\n\n override render(): TemplateResult {\n return copyButtonTemplate({\n value: this.value,\n variant: this.variant,\n size: this.size,\n iconOnly: this.iconOnly,\n label: this.label,\n successLabel: this.successLabel,\n tooltip: this.tooltip,\n copied: this._copied,\n disabled: this.disabled,\n onClick: this._handleClick.bind(this),\n });\n }\n}\n\ndeclare global {\n interface HTMLElementTagNameMap {\n 'lib-copy-button': LibCopyButton;\n }\n}"],"names":[],"mappings":";;;;;;;;;;;;;;;;AASA,MAAM,kBAAkB;AAgBjB,IAAM,gBAAN,cAA4B,WAAW;AAAA,EAAvC,cAAA;AAAA,UAAA,GAAA,SAAA;AAML,SAAQ,cAAoD;AAI5D,SAAA,QAAQ;AAIR,SAAA,UAA0B;AAI1B,SAAA,OAAoB;AAIpB,SAAA,WAAW;AAIX,SAAA,QAAQ;AAIR,SAAA,eAAe;AAIf,SAAA,UAAU;AAIV,SAAA,WAAW;AAIX,SAAQ,UAAU;AAAA,EAAA;AAAA;AAAA,EAGT,QAAQ,SAAqC;AACpD,QAAI,QAAQ,IAAI,SAAS,GAAG;AAC1B,WAAK,gBAAgB,UAAU,KAAK,OAAO;AAAA,IAC7C;AAAA,EACF;AAAA,EAES,uBAA6B;AACpC,UAAM,qBAAA;AACN,QAAI,KAAK,YAAa,cAAa,KAAK,WAAW;AAAA,EACrD;AAAA,EAEA,MAAc,eAA8B;AAC1C,QAAI,CAAC,KAAK,SAAS,KAAK,YAAY,KAAK,QAAS;AAElD,QAAI;AACF,YAAM,UAAU,UAAU,UAAU,KAAK,KAAK;AAC9C,WAAK,UAAU;AAEf,WAAK;AAAA,QACH,IAAI,YAAY,YAAY;AAAA,UAC1B,QAAQ,EAAE,OAAO,KAAK,MAAA;AAAA,UACtB,SAAS;AAAA,UACT,UAAU;AAAA,QAAA,CACX;AAAA,MAAA;AAGH,UAAI,KAAK,YAAa,cAAa,KAAK,WAAW;AACnD,WAAK,cAAc,WAAW,MAAM;AAClC,aAAK,UAAU;AAAA,MACjB,GAAG,eAAe;AAAA,IAEpB,SAAS,KAAK;AACZ,cAAQ,MAAM,sCAAsC,GAAG;AAAA,IACzD;AAAA,EACF;AAAA,EAES,SAAyB;AAChC,WAAO,mBAAmB;AAAA,MACxB,OAAO,KAAK;AAAA,MACZ,SAAS,KAAK;AAAA,MACd,MAAM,KAAK;AAAA,MACX,UAAU,KAAK;AAAA,MACf,OAAO,KAAK;AAAA,MACZ,cAAc,KAAK;AAAA,MACnB,SAAS,KAAK;AAAA,MACd,QAAQ,KAAK;AAAA,MACb,UAAU,KAAK;AAAA,MACf,SAAS,KAAK,aAAa,KAAK,IAAI;AAAA,IAAA,CACrC;AAAA,EACH;AACF;AA/Fa,cACK,SAAS;AAAA,EACvB,MAAM,UAAU,YAAY,CAAC;AAAA,EAC7B,MAAM,UAAU,aAAa,CAAC;AAChC;AAMA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,OAAA,CAAQ;AAAA,GATf,cAUX,WAAA,SAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,QAAQ,SAAS,MAAM;AAAA,GAb9B,cAcX,WAAA,WAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,QAAQ,SAAS,MAAM;AAAA,GAjB9B,cAkBX,WAAA,QAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,SAAS,SAAS,MAAM,WAAW,aAAa;AAAA,GArBvD,cAsBX,WAAA,YAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,OAAA,CAAQ;AAAA,GAzBf,cA0BX,WAAA,SAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,QAAQ,WAAW,iBAAiB;AAAA,GA7B3C,cA8BX,WAAA,gBAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,SAAS,SAAS,MAAM;AAAA,GAjC/B,cAkCX,WAAA,WAAA,CAAA;AAIA,gBAAA;AAAA,EADC,SAAS,EAAE,MAAM,SAAS,SAAS,MAAM;AAAA,GArC/B,cAsCX,WAAA,YAAA,CAAA;AAIQ,gBAAA;AAAA,EADP,MAAA;AAAM,GAzCI,cA0CH,WAAA,WAAA,CAAA;AA1CG,gBAAN,gBAAA;AAAA,EADN,cAAc,iBAAiB;AAAA,GACnB,aAAA;"}
|
package/dist/index210.js
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
|
-
|
|
1
|
+
let uniqueIdCounter = 0;
|
|
2
|
+
function generateUniqueId(prefix = "lib-id-") {
|
|
3
|
+
uniqueIdCounter++;
|
|
4
|
+
return `${prefix}${uniqueIdCounter}`;
|
|
5
|
+
}
|
|
2
6
|
export {
|
|
3
|
-
|
|
7
|
+
generateUniqueId
|
|
4
8
|
};
|
|
5
9
|
//# sourceMappingURL=index210.js.map
|
package/dist/index210.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index210.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|
|
1
|
+
{"version":3,"file":"index210.js","sources":["../src/core/a11y.ts"],"sourcesContent":["/**\n * Accessibility (a11y) Utilities - Pillar 5\n *\n * This module provides utility functions to help ensure accessibility\n * for UI components. It includes helpers for generating unique IDs\n * and retrieving ARIA attributes.\n *\n * All functions here are pure TypeScript logic, with no direct DOM manipulation\n * beyond reading attributes, and are framework-agnostic.\n */\n\nlet uniqueIdCounter = 0;\n\n/**\n * Generates a unique ID for a component or element.\n * Useful for associating elements via ARIA attributes (e.g., `aria-labelledby`, `aria-describedby`).\n * @param prefix An optional prefix for the ID. Defaults to 'lib-id-'.\n * @returns A unique ID string.\n */\nexport function generateUniqueId(prefix: string = 'lib-id-'): string {\n uniqueIdCounter++;\n return `${prefix}${uniqueIdCounter}`;\n}\n\n/**\n * Retrieves the `aria-label` attribute from an HTMLElement.\n * Provides a default fallback if `aria-label` is not explicitly set.\n * This function is meant to be used in conjunction with components that may not always have a visual label.\n * @param element The HTMLElement to check for `aria-label`.\n * @param defaultValue A fallback value to use if `aria-label` is not found.\n * @returns The value of `aria-label` or the `defaultValue`.\n */\nexport function getAriaLabel(element: HTMLElement, defaultValue: string = ''): string {\n return element.getAttribute('aria-label') || defaultValue;\n}\n"],"names":[],"mappings":"AAWA,IAAI,kBAAkB;AAQf,SAAS,iBAAiB,SAAiB,WAAmB;AACnE;AACA,SAAO,GAAG,MAAM,GAAG,eAAe;AACpC;"}
|
package/dist/index211.js
CHANGED
|
@@ -1,44 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
const chevronSvg = html`
|
|
3
|
-
<svg
|
|
4
|
-
class="accordion-item__icon"
|
|
5
|
-
viewBox="0 0 16 16"
|
|
6
|
-
fill="none"
|
|
7
|
-
stroke="currentColor"
|
|
8
|
-
stroke-width="1.5"
|
|
9
|
-
stroke-linecap="round"
|
|
10
|
-
stroke-linejoin="round"
|
|
11
|
-
aria-hidden="true"
|
|
12
|
-
>
|
|
13
|
-
<polyline points="3,5 8,11 13,5"/>
|
|
14
|
-
</svg>
|
|
15
|
-
`;
|
|
16
|
-
function accordionItemTemplate(props) {
|
|
17
|
-
return html`
|
|
18
|
-
<div class="accordion-item__root">
|
|
19
|
-
|
|
20
|
-
<button
|
|
21
|
-
class="accordion-item__trigger"
|
|
22
|
-
type="button"
|
|
23
|
-
aria-expanded="${props.open ? "true" : "false"}"
|
|
24
|
-
@click=${props.onToggle}
|
|
25
|
-
>
|
|
26
|
-
<span class="accordion-item__label">${props.label}</span>
|
|
27
|
-
${chevronSvg}
|
|
28
|
-
</button>
|
|
29
|
-
|
|
30
|
-
<div class="accordion-item__body">
|
|
31
|
-
<div class="accordion-item__body-inner">
|
|
32
|
-
<div class="accordion-item__content">
|
|
33
|
-
<slot></slot>
|
|
34
|
-
</div>
|
|
35
|
-
</div>
|
|
36
|
-
</div>
|
|
37
|
-
|
|
38
|
-
</div>
|
|
39
|
-
`;
|
|
40
|
-
}
|
|
1
|
+
const uploaderCss = "@layer tokens,reset,components;@layer reset{*,*:before,*:after{box-sizing:border-box}:host{display:block}}@layer components{.fu-root{display:flex;flex-direction:column;width:100%}.fu-zone{position:relative;border:1.5px dashed var(--border-default);background:var(--bg-elevated);padding:var(--lib-space-xl) var(--lib-space-lg);display:flex;flex-direction:column;align-items:center;justify-content:center;gap:var(--lib-space-md);text-align:center;cursor:pointer;transition:border-color var(--duration-base) var(--ease-out),background var(--duration-base) var(--ease-out),transform var(--duration-fast);width:100%}.fu-zone input[type=file]{position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;cursor:pointer;width:100%;height:100%}.fu-zone:hover{border-color:var(--border-strong);background:var(--bg-surface)}.fu-zone.is-dragover{border-color:var(--color-kaki-400);background:var(--color-kaki-50);transform:scale(1.005)}.fu-zone.is-disabled{opacity:.45;cursor:not-allowed;pointer-events:none}.fu-zone-icon{font-size:40px;color:var(--text-muted);line-height:1;display:flex;transition:color var(--duration-base),transform var(--duration-slow) var(--ease-bounce)}.fu-zone:hover .fu-zone-icon,.fu-zone.is-dragover .fu-zone-icon{color:var(--color-kaki-400);transform:translateY(-3px) scale(1.08)}.fu-zone-title{font-family:var(--lib-font-display);font-size:var(--text-xl);font-weight:var(--weight-light);letter-spacing:var(--tracking-tight);color:var(--text-primary)}.fu-zone-sub{font-family:var(--lib-font-mono);font-size:var(--text-xs);letter-spacing:var(--tracking-wider);color:var(--text-muted);text-transform:uppercase}.fu-zone-sub span{color:var(--color-kaki-500);text-decoration:underline;text-underline-offset:2px}.fu-zone-hint{font-family:var(--lib-font-mono);font-size:10px;letter-spacing:var(--tracking-wide);color:var(--text-muted);margin-top:var(--lib-space-xs)}.fu-zone-sm{position:relative;border:1px dashed var(--border-default);background:var(--bg-elevated);padding:var(--lib-space-md) var(--lib-space-md);display:flex;align-items:center;gap:var(--lib-space-md);cursor:pointer;transition:border-color var(--duration-base) var(--ease-out),background var(--duration-base) var(--ease-out);width:100%}.fu-zone-sm input[type=file]{position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;cursor:pointer;width:100%;height:100%}.fu-zone-sm:hover,.fu-zone-sm.is-dragover{border-color:var(--color-kaki-400);background:var(--color-kaki-50)}.fu-zone-sm.is-disabled{opacity:.45;cursor:not-allowed;pointer-events:none}.fu-zone-sm-icon{font-size:22px;color:var(--text-muted);flex-shrink:0;display:flex;transition:color var(--duration-base)}.fu-zone-sm:hover .fu-zone-sm-icon,.fu-zone-sm.is-dragover .fu-zone-sm-icon{color:var(--color-kaki-400)}.fu-zone-sm-text{display:flex;flex-direction:column;gap:2px}.fu-zone-sm-title{font-family:var(--lib-font-mono);font-size:var(--text-xs);letter-spacing:var(--tracking-wider);color:var(--text-secondary);text-transform:uppercase}.fu-zone-sm-sub{font-family:var(--lib-font-mono);font-size:10px;color:var(--text-muted);letter-spacing:var(--tracking-wide)}.fu-zone-img{position:relative;border:1.5px dashed var(--border-default);background:var(--bg-surface);width:100%;aspect-ratio:16 / 7;overflow:hidden;cursor:pointer;transition:border-color var(--duration-base) var(--ease-out),background var(--duration-base) var(--ease-out);display:flex;align-items:center;justify-content:center;flex-direction:column;gap:var(--lib-space-sm)}.fu-zone-img input[type=file]{position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;cursor:pointer;width:100%;height:100%}.fu-zone-img:hover{border-color:var(--border-strong)}.fu-zone-img.is-dragover{border-color:var(--color-kaki-400);background:var(--color-kaki-50)}.fu-zone-img.is-disabled{opacity:.45;cursor:not-allowed;pointer-events:none}.fu-zone-img-placeholder{display:flex;flex-direction:column;align-items:center;gap:var(--lib-space-sm);pointer-events:none}.fu-zone-img-preview{position:absolute;top:0;right:0;bottom:0;left:0;object-fit:cover;width:100%;height:100%;display:none}.fu-zone-img.has-preview .fu-zone-img-preview{display:block}.fu-zone-img.has-preview .fu-zone-img-placeholder{display:none}.fu-zone-img-overlay{position:absolute;top:0;right:0;bottom:0;left:0;background:#221c1680;display:flex;align-items:center;justify-content:center;gap:var(--lib-space-sm);opacity:0;transition:opacity var(--duration-base);pointer-events:none}.fu-zone-img.has-preview:hover .fu-zone-img-overlay{opacity:1}.fu-zone-img-overlay-text{font-family:var(--lib-font-mono);font-size:var(--text-xs);letter-spacing:var(--tracking-wider);text-transform:uppercase;color:var(--color-white)}.fu-progress-bar{height:2px;background:var(--border-subtle);width:100%;overflow:hidden;margin-top:-1px}.fu-progress-fill{height:100%;background:var(--color-kaki-400);transition:width 80ms linear}.fu-list{display:flex;flex-direction:column;gap:1px;width:100%}.fu-file{display:grid;grid-template-columns:auto 1fr auto;align-items:center;gap:var(--lib-space-md);padding:var(--lib-space-md) var(--lib-space-md);background:var(--bg-elevated);border:1px solid var(--border-subtle);position:relative;overflow:hidden;transition:background var(--duration-base);animation:fu-slide-in .25s var(--ease-out)}.fu-file:hover{background:var(--bg-surface)}.fu-file-prog-bg{position:absolute;left:0;top:0;bottom:0;background:var(--color-kaki-50);transition:width 80ms linear;pointer-events:none;z-index:0}.fu-file>*{position:relative;z-index:1}.fu-file-icon{width:36px;height:36px;display:flex;align-items:center;justify-content:center;font-size:20px;color:var(--text-muted);background:var(--bg-surface);border:1px solid var(--border-subtle);flex-shrink:0;transition:color var(--duration-base),background var(--duration-base)}.fu-file.is-done .fu-file-icon{color:var(--color-celadon-500);background:var(--color-celadon-50);border-color:var(--color-celadon-100)}.fu-file.is-error .fu-file-icon{color:var(--color-error);background:#fff8f7;border-color:#f5c4bc}.fu-ext{font-family:var(--lib-font-mono);font-size:8px;letter-spacing:.04em;text-transform:uppercase;font-weight:600}.fu-file-thumb{width:36px;height:36px;object-fit:cover;flex-shrink:0;border:1px solid var(--border-subtle);display:block}.fu-file-meta{display:flex;flex-direction:column;gap:2px;min-width:0}.fu-file-name{font-family:var(--lib-font-mono);font-size:var(--text-xs);letter-spacing:var(--tracking-wide);color:var(--text-primary);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.fu-file-info{font-family:var(--lib-font-mono);font-size:10px;letter-spacing:var(--tracking-wide);color:var(--text-muted);display:flex;align-items:center;gap:var(--lib-space-sm)}.fu-file-info-sep{width:3px;height:3px;border-radius:var(--radius-full);background:var(--color-washi-300);flex-shrink:0}.fu-file-actions{display:flex;align-items:center;gap:var(--lib-space-sm);flex-shrink:0}.fu-file-pct{font-family:var(--lib-font-mono);font-size:10px;letter-spacing:var(--tracking-wide);color:var(--color-kaki-500);min-width:28px;text-align:right}.fu-status-done{color:var(--color-celadon-500);font-size:18px;display:flex}.fu-status-error{color:var(--color-error);font-size:18px;display:flex}.fu-file-remove{width:28px;height:28px;display:flex;align-items:center;justify-content:center;font-size:14px;color:var(--text-muted);background:transparent;border:none;cursor:pointer;border-radius:var(--radius-full);transition:background var(--duration-fast),color var(--duration-fast);flex-shrink:0}.fu-file-remove:hover{background:var(--color-washi-200);color:var(--text-primary)}.fu-file.is-error .fu-file-remove:hover{background:#fff8f7;color:var(--color-error)}.fu-summary{display:flex;align-items:center;justify-content:space-between;padding:var(--lib-space-sm) var(--lib-space-md);background:var(--bg-surface);border:1px solid var(--border-subtle);border-top:none}.fu-summary-text{font-family:var(--lib-font-mono);font-size:10px;letter-spacing:var(--tracking-wide);color:var(--text-muted)}.fu-summary-btn{font-family:var(--lib-font-mono);font-size:10px;letter-spacing:var(--tracking-wider);text-transform:uppercase;background:var(--color-washi-900);color:var(--color-washi-50);border:none;padding:var(--lib-space-sm) var(--lib-space-md);cursor:pointer;transition:background var(--duration-base)}.fu-summary-btn:hover{background:var(--color-washi-800)}.fu-summary-btn:disabled{opacity:.38;cursor:not-allowed}.fu-spinner{width:16px;height:16px;border:2px solid var(--color-washi-200);border-top-color:var(--color-kaki-400);border-radius:var(--radius-full);animation:fu-spin .7s linear infinite;flex-shrink:0}@keyframes fu-slide-in{0%{opacity:0;transform:translateY(-6px)}to{opacity:1;transform:translateY(0)}}@keyframes fu-spin{to{transform:rotate(360deg)}}}";
|
|
41
2
|
export {
|
|
42
|
-
|
|
3
|
+
uploaderCss as default
|
|
43
4
|
};
|
|
44
5
|
//# sourceMappingURL=index211.js.map
|
package/dist/index211.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index211.js","sources":[
|
|
1
|
+
{"version":3,"file":"index211.js","sources":[],"sourcesContent":[],"names":[],"mappings":";"}
|