meticulous-ui 3.2.4 → 3.2.5
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.
|
@@ -3,7 +3,7 @@ import { useState as a, useRef as de, useEffect as O } from "react";
|
|
|
3
3
|
import ce from "../Glass/Glass.js";
|
|
4
4
|
import ue from "./components/TimerRing/TimerRing.js";
|
|
5
5
|
import h from "../../colors/white.js";
|
|
6
|
-
import { Wrapper as me,
|
|
6
|
+
import { Wrapper as me, AlarmRing as he, BulletRing as pe, Bullet as ge, VisuallyHidden as be, Dimmer as fe, DotsWrapper as Se, AllDots as Te, Dots as $e, Time as U, TimeTxt as _, HourHand as Ae, MinuteHand as ye, SecondHand as Re, LeftActions as De, ActionBtn as p, MediaStopFilledWrapper as Pe, MediaPauseFilledWrapper as we, MediaPlayFilledWrapper as He, RightActions as Ie, AddWrapper as Me } from "./styles.js";
|
|
7
7
|
import { getSize as ke } from "./helpers.js";
|
|
8
8
|
const c = () => {
|
|
9
9
|
}, Ce = (g) => () => {
|
|
@@ -63,14 +63,43 @@ const c = () => {
|
|
|
63
63
|
const w = S.toLocaleString("en-Us", { hour12: !0, timeZone: o }).split(", ")[1], C = w.split(" ")[0], W = w.split(" ")[1], z = w.split(":").slice(0, 2).join(":"), l = !(Number.isInteger(s) && s > 0), L = `${b ? C : z} ${W}`;
|
|
64
64
|
return /* @__PURE__ */ n(me, { $color: g, role: "region", "aria-label": "Clock", $size: t, ...Q, children: [
|
|
65
65
|
/* @__PURE__ */ e(ce, { borderRadius: `${ke(16.67)({ $size: t })}rem`, "aria-hidden": "true" }),
|
|
66
|
+
(!l || R) && /* @__PURE__ */ n(v, { children: [
|
|
67
|
+
/* @__PURE__ */ e(
|
|
68
|
+
he,
|
|
69
|
+
{
|
|
70
|
+
$dismissing: R,
|
|
71
|
+
onAnimationEnd: te,
|
|
72
|
+
"aria-hidden": "true",
|
|
73
|
+
children: /* @__PURE__ */ e(ue, { progress: s >= 60 ? 1 : s % 60 / 60 })
|
|
74
|
+
}
|
|
75
|
+
),
|
|
76
|
+
/* @__PURE__ */ e(
|
|
77
|
+
pe,
|
|
78
|
+
{
|
|
79
|
+
$size: t,
|
|
80
|
+
style: { "--bullet-rotate": `${Y}deg` },
|
|
81
|
+
$dismissing: R,
|
|
82
|
+
"aria-hidden": "true",
|
|
83
|
+
children: /* @__PURE__ */ e(ge, { $size: t })
|
|
84
|
+
}
|
|
85
|
+
),
|
|
86
|
+
/* @__PURE__ */ e(
|
|
87
|
+
be,
|
|
88
|
+
{
|
|
89
|
+
role: "timer",
|
|
90
|
+
"aria-live": "polite",
|
|
91
|
+
"aria-label": `${s} seconds remaining`
|
|
92
|
+
}
|
|
93
|
+
)
|
|
94
|
+
] }),
|
|
66
95
|
I && /* @__PURE__ */ n(v, { children: [
|
|
67
|
-
/* @__PURE__ */ e(
|
|
96
|
+
/* @__PURE__ */ e(fe, { "aria-hidden": "true", $size: t, children: /* @__PURE__ */ e(Se, { children: /* @__PURE__ */ e(Te, { "aria-hidden": "true", children: [...Array(60)].map((N, d) => /* @__PURE__ */ e($e, { $i: d, $size: t }, d)) }) }) }),
|
|
68
97
|
f ? /* @__PURE__ */ n(U, { as: "time", dateTime: S.toISOString(), "aria-label": L, children: [
|
|
69
98
|
/* @__PURE__ */ e(_, { $size: t, "aria-hidden": "true", children: b ? C : z }),
|
|
70
99
|
/* @__PURE__ */ e(_, { $size: t, "aria-hidden": "true", children: W })
|
|
71
100
|
] }) : /* @__PURE__ */ n(U, { as: "time", dateTime: S.toISOString(), "aria-label": L, children: [
|
|
72
101
|
/* @__PURE__ */ e(
|
|
73
|
-
|
|
102
|
+
Ae,
|
|
74
103
|
{
|
|
75
104
|
$size: t,
|
|
76
105
|
style: { "--hand-rotate": `${A.hour}deg` },
|
|
@@ -78,7 +107,7 @@ const c = () => {
|
|
|
78
107
|
}
|
|
79
108
|
),
|
|
80
109
|
/* @__PURE__ */ e(
|
|
81
|
-
|
|
110
|
+
ye,
|
|
82
111
|
{
|
|
83
112
|
$size: t,
|
|
84
113
|
style: { "--hand-rotate": `${A.minute}deg` },
|
|
@@ -86,7 +115,7 @@ const c = () => {
|
|
|
86
115
|
}
|
|
87
116
|
),
|
|
88
117
|
/* @__PURE__ */ e(
|
|
89
|
-
|
|
118
|
+
Re,
|
|
90
119
|
{
|
|
91
120
|
$size: t,
|
|
92
121
|
style: { "--hand-rotate": `${A.second}deg` },
|
|
@@ -95,35 +124,6 @@ const c = () => {
|
|
|
95
124
|
)
|
|
96
125
|
] })
|
|
97
126
|
] }),
|
|
98
|
-
(!l || R) && /* @__PURE__ */ n(v, { children: [
|
|
99
|
-
/* @__PURE__ */ e(
|
|
100
|
-
$e,
|
|
101
|
-
{
|
|
102
|
-
$dismissing: R,
|
|
103
|
-
onAnimationEnd: te,
|
|
104
|
-
"aria-hidden": "true",
|
|
105
|
-
children: /* @__PURE__ */ e(ue, { progress: s >= 60 ? 1 : s % 60 / 60 })
|
|
106
|
-
}
|
|
107
|
-
),
|
|
108
|
-
/* @__PURE__ */ e(
|
|
109
|
-
Ae,
|
|
110
|
-
{
|
|
111
|
-
$size: t,
|
|
112
|
-
style: { "--bullet-rotate": `${45 + Y}deg` },
|
|
113
|
-
$dismissing: R,
|
|
114
|
-
"aria-hidden": "true",
|
|
115
|
-
children: /* @__PURE__ */ e(ye, { $size: t })
|
|
116
|
-
}
|
|
117
|
-
),
|
|
118
|
-
/* @__PURE__ */ e(
|
|
119
|
-
Re,
|
|
120
|
-
{
|
|
121
|
-
role: "timer",
|
|
122
|
-
"aria-live": "polite",
|
|
123
|
-
"aria-label": `${s} seconds remaining`
|
|
124
|
-
}
|
|
125
|
-
)
|
|
126
|
-
] }),
|
|
127
127
|
r > 0 && /* @__PURE__ */ n(
|
|
128
128
|
De,
|
|
129
129
|
{
|
|
@@ -15,7 +15,7 @@ const r = 33, e = 2 * Math.PI * r, u = ({ progress: o }) => {
|
|
|
15
15
|
cy: 48,
|
|
16
16
|
r,
|
|
17
17
|
stroke: "rgba(255,255,255,.2)",
|
|
18
|
-
strokeWidth:
|
|
18
|
+
strokeWidth: 1,
|
|
19
19
|
fill: "none"
|
|
20
20
|
}
|
|
21
21
|
),
|
|
@@ -27,7 +27,7 @@ const r = 33, e = 2 * Math.PI * r, u = ({ progress: o }) => {
|
|
|
27
27
|
cy: 48,
|
|
28
28
|
r,
|
|
29
29
|
stroke: a,
|
|
30
|
-
strokeWidth: 1,
|
|
30
|
+
strokeWidth: 1.33,
|
|
31
31
|
fill: "none",
|
|
32
32
|
strokeLinecap: "round",
|
|
33
33
|
strokeDasharray: e,
|
|
@@ -8,7 +8,7 @@ import u from "../../colors/black.js";
|
|
|
8
8
|
import b from "../../colors/red.js";
|
|
9
9
|
import { COLOR_MAPPING as $ } from "./constants.js";
|
|
10
10
|
import { getSize as t } from "./helpers.js";
|
|
11
|
-
const s = 1,
|
|
11
|
+
const s = 1, f = 16.67, a = 1.67, g = 3.404, v = ({ $color: e }) => $[e], n = r`
|
|
12
12
|
position: absolute;
|
|
13
13
|
bottom: 50%;
|
|
14
14
|
transform-origin: bottom;
|
|
@@ -19,7 +19,7 @@ const s = 1, g = 16.67, a = 1.67, f = 3.404, v = ({ $color: e }) => $[e], n = r`
|
|
|
19
19
|
position: relative;
|
|
20
20
|
height: ${t(s)}rem;
|
|
21
21
|
width: ${t(s)}rem;
|
|
22
|
-
border-radius: ${t(
|
|
22
|
+
border-radius: ${t(f)}rem;
|
|
23
23
|
background-color: ${v};
|
|
24
24
|
`, W = o.div`
|
|
25
25
|
position: absolute;
|
|
@@ -47,7 +47,7 @@ const s = 1, g = 16.67, a = 1.67, f = 3.404, v = ({ $color: e }) => $[e], n = r`
|
|
|
47
47
|
width: ${t(120)}rem;
|
|
48
48
|
height: ${t(120)}rem;
|
|
49
49
|
background: rgba(255, 255, 255, 0.4);
|
|
50
|
-
transform-origin: ${t(
|
|
50
|
+
transform-origin: ${t(g)}rem;
|
|
51
51
|
border-radius: 2px;
|
|
52
52
|
rotate: ${({ $i: e }) => `${e * 6}deg`};
|
|
53
53
|
|
|
@@ -88,13 +88,13 @@ const s = 1, g = 16.67, a = 1.67, f = 3.404, v = ({ $color: e }) => $[e], n = r`
|
|
|
88
88
|
background: ${b.m800};
|
|
89
89
|
`, d = l`
|
|
90
90
|
from { opacity: 1; transform: scale(1); }
|
|
91
|
-
to { opacity: 0; transform: scale(0.
|
|
91
|
+
to { opacity: 0; transform: scale(0.9); }
|
|
92
92
|
`, E = o.div`
|
|
93
93
|
position: absolute;
|
|
94
94
|
inset: 0;
|
|
95
95
|
pointer-events: none;
|
|
96
96
|
${({ $dismissing: e }) => e && r`
|
|
97
|
-
animation: ${d} 0.
|
|
97
|
+
animation: ${d} 0.6s ease-out forwards;
|
|
98
98
|
`}
|
|
99
99
|
`, z = o.div`
|
|
100
100
|
position: absolute;
|
|
@@ -155,21 +155,24 @@ const s = 1, g = 16.67, a = 1.67, f = 3.404, v = ({ $color: e }) => $[e], n = r`
|
|
|
155
155
|
clip-path: inset(50%);
|
|
156
156
|
white-space: nowrap;
|
|
157
157
|
`, Q = o.div`
|
|
158
|
+
position: absolute;
|
|
158
159
|
width: ${t(35)}rem;
|
|
159
160
|
height: ${t(35)}rem;
|
|
160
161
|
border-radius: 50%;
|
|
161
162
|
background-color: ${i};
|
|
163
|
+
left: calc(-${t(70)}rem);
|
|
164
|
+
top: calc(-${t(100 / 33)}rem - ${t(70)}rem);
|
|
162
165
|
`, U = o.div`
|
|
163
166
|
position: absolute;
|
|
164
|
-
left:
|
|
165
|
-
top:
|
|
167
|
+
left: 50%;
|
|
168
|
+
top: 48%;
|
|
169
|
+
width: 0;
|
|
170
|
+
height: 0;
|
|
166
171
|
rotate: var(--bullet-rotate);
|
|
167
|
-
|
|
168
|
-
width: ${t(2.05)}rem;
|
|
169
|
-
transform-origin: center;
|
|
172
|
+
transform-origin: 0 0;
|
|
170
173
|
transition: rotate 0.3s ease;
|
|
171
174
|
${({ $dismissing: e }) => e && r`
|
|
172
|
-
animation: ${d} 0.
|
|
175
|
+
animation: ${d} 0.6s ease-out forwards;
|
|
173
176
|
`}
|
|
174
177
|
`;
|
|
175
178
|
export {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "meticulous-ui",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.5",
|
|
4
4
|
"license": "ISC",
|
|
5
5
|
"description": "A comprehensive React UI component library with a wide range of customizable components, icons, colors, and utilities for building modern web applications.",
|
|
6
6
|
"main": "./index.js",
|