@jfrader/ui 0.7.0 → 0.7.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/README.md +1 -0
- package/dist/avatar-BuM1zB_f.js +164 -0
- package/dist/{avatar-group-BlMLNw4J.js → avatar-group-D1UEihvh.js} +1 -1
- package/dist/avatar-group.js +1 -1
- package/dist/avatar.js +1 -1
- package/dist/card-frame-CcLa6NQ4.js +13 -0
- package/dist/{chat-thread-DkB-WMWJ.js → chat-thread-CMhwxhoA.js} +1 -1
- package/dist/chat-thread.js +1 -1
- package/dist/{comment-thread-DXfqgRNI.js → comment-thread-DbOzYr0q.js} +1 -1
- package/dist/comment-thread.js +1 -1
- package/dist/flip-game-card-xmcR_QSq.js +100 -0
- package/dist/flip-game-card.js +2 -0
- package/dist/{game-card-Oeu74giK.js → game-card-Bnhpz78f.js} +42 -49
- package/dist/game-card.js +1 -1
- package/dist/{hover-card-Dgu2CwMD.js → hover-card--ijYr1cd.js} +1 -1
- package/dist/hover-card.js +1 -1
- package/dist/index.js +61 -60
- package/dist/{thread-parts-Cpktor6D.js → thread-parts-DbKhuwVU.js} +1 -1
- package/dist/{timeline-BcF46lG9.js → timeline-BPKY94mT.js} +1 -1
- package/dist/timeline.js +1 -1
- package/dist/types/components/avatar/avatar.d.ts +3 -1
- package/dist/types/components/flip-game-card/flip-game-card.d.ts +22 -0
- package/dist/types/components/flip-game-card/index.d.ts +2 -0
- package/dist/types/index.d.ts +1 -0
- package/dist/types/styling/theme.d.ts +3 -0
- package/dist/{user-menu-MctRu_Lh.js → user-menu-Czrrk93A.js} +1 -1
- package/dist/user-menu.js +1 -1
- package/package.json +6 -2
- package/dist/avatar-sPxDqFiZ.js +0 -133
package/README.md
CHANGED
|
@@ -24,6 +24,7 @@ React components styled with Emotion and themed through the CSS custom propertie
|
|
|
24
24
|
| `@jfrader/ui/divider` | `Divider` |
|
|
25
25
|
| `@jfrader/ui/emblem` | `Emblem` |
|
|
26
26
|
| `@jfrader/ui/flex` | `Flex` |
|
|
27
|
+
| `@jfrader/ui/flip-game-card` | `FlipGameCard` |
|
|
27
28
|
| `@jfrader/ui/game-card` | `GameCard` |
|
|
28
29
|
| `@jfrader/ui/kbd` | `Kbd` |
|
|
29
30
|
| `@jfrader/ui/menu` | `Menu` |
|
|
@@ -0,0 +1,164 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { a as e, i as t } from "./css-BYJhdGh-.js";
|
|
3
|
+
import { n, r } from "./media-8yrN85VT.js";
|
|
4
|
+
import { t as i } from "./sx-BJXJ2xJK.js";
|
|
5
|
+
import { t as a } from "./initials-DEdwNe9_.js";
|
|
6
|
+
import { useState as o } from "react";
|
|
7
|
+
import { vars as s } from "@jfrader/tokens/vars";
|
|
8
|
+
import { jsx as c, jsxs as l } from "@emotion/react/jsx-runtime";
|
|
9
|
+
//#region src/components/avatar/avatar.tsx
|
|
10
|
+
var u = 2, d = t({
|
|
11
|
+
position: "relative",
|
|
12
|
+
display: "inline-flex",
|
|
13
|
+
alignItems: "center",
|
|
14
|
+
justifyContent: "center",
|
|
15
|
+
flexShrink: 0,
|
|
16
|
+
boxSizing: "border-box",
|
|
17
|
+
borderRadius: s.radius.full,
|
|
18
|
+
backgroundColor: s.color.surfaceHover,
|
|
19
|
+
color: s.color.text,
|
|
20
|
+
fontWeight: s.fontWeight.medium,
|
|
21
|
+
lineHeight: 1,
|
|
22
|
+
userSelect: "none",
|
|
23
|
+
verticalAlign: "middle",
|
|
24
|
+
[n]: { outline: "1px solid CanvasText" }
|
|
25
|
+
}), f = {
|
|
26
|
+
sm: t({
|
|
27
|
+
inlineSize: s.space[6],
|
|
28
|
+
blockSize: s.space[6],
|
|
29
|
+
fontSize: s.textSize.xs
|
|
30
|
+
}),
|
|
31
|
+
md: t({
|
|
32
|
+
inlineSize: s.space[8],
|
|
33
|
+
blockSize: s.space[8],
|
|
34
|
+
fontSize: s.textSize.sm
|
|
35
|
+
}),
|
|
36
|
+
lg: t({
|
|
37
|
+
inlineSize: s.space[10],
|
|
38
|
+
blockSize: s.space[10],
|
|
39
|
+
fontSize: s.textSize.md
|
|
40
|
+
})
|
|
41
|
+
}, p = t({
|
|
42
|
+
display: "block",
|
|
43
|
+
inlineSize: "100%",
|
|
44
|
+
blockSize: "100%",
|
|
45
|
+
borderRadius: s.radius.full,
|
|
46
|
+
objectFit: "cover"
|
|
47
|
+
}), m = t({
|
|
48
|
+
position: "absolute",
|
|
49
|
+
insetBlockEnd: 0,
|
|
50
|
+
insetInlineEnd: 0,
|
|
51
|
+
inlineSize: "25%",
|
|
52
|
+
blockSize: "25%",
|
|
53
|
+
pointerEvents: "none",
|
|
54
|
+
"&::before": {
|
|
55
|
+
content: "\"\"",
|
|
56
|
+
position: "absolute",
|
|
57
|
+
insetBlockStart: 0,
|
|
58
|
+
insetInlineStart: 0,
|
|
59
|
+
inlineSize: "100%",
|
|
60
|
+
blockSize: "100%",
|
|
61
|
+
boxSizing: "border-box",
|
|
62
|
+
borderRadius: s.radius.full,
|
|
63
|
+
boxShadow: `0 0 0 2px ${s.color.bg}`
|
|
64
|
+
}
|
|
65
|
+
}), h = {
|
|
66
|
+
online: t({ "&::before": { backgroundColor: s.color.success } }),
|
|
67
|
+
away: t({ "&::before": {
|
|
68
|
+
border: `2px solid ${s.color.warning}`,
|
|
69
|
+
backgroundColor: "transparent"
|
|
70
|
+
} }),
|
|
71
|
+
busy: t({ "&::before": {
|
|
72
|
+
backgroundColor: s.color.danger,
|
|
73
|
+
blockSize: "30%",
|
|
74
|
+
insetBlockStart: "35%"
|
|
75
|
+
} }),
|
|
76
|
+
offline: t({ "&::before": {
|
|
77
|
+
backgroundColor: s.color.textSubtle,
|
|
78
|
+
inlineSize: "60%",
|
|
79
|
+
blockSize: "60%",
|
|
80
|
+
insetBlockStart: "20%",
|
|
81
|
+
insetInlineStart: "20%"
|
|
82
|
+
} })
|
|
83
|
+
}, g = t({ [n]: {
|
|
84
|
+
"&::before": {
|
|
85
|
+
forcedColorAdjust: "none",
|
|
86
|
+
backgroundColor: "CanvasText",
|
|
87
|
+
outline: "2px solid Canvas"
|
|
88
|
+
},
|
|
89
|
+
"&[data-status=\"away\"]::before": {
|
|
90
|
+
borderColor: "CanvasText",
|
|
91
|
+
backgroundColor: "Canvas"
|
|
92
|
+
}
|
|
93
|
+
} }), _ = e({
|
|
94
|
+
from: {
|
|
95
|
+
transform: "scale(.8)",
|
|
96
|
+
opacity: 1
|
|
97
|
+
},
|
|
98
|
+
to: {
|
|
99
|
+
transform: "scale(2.4)",
|
|
100
|
+
opacity: 0
|
|
101
|
+
}
|
|
102
|
+
}), v = { "&[data-status=\"online\"][data-pulse]::after": {
|
|
103
|
+
content: "none",
|
|
104
|
+
display: "none",
|
|
105
|
+
animation: "none"
|
|
106
|
+
} }, y = t({
|
|
107
|
+
"&[data-status=\"online\"][data-pulse]::after": {
|
|
108
|
+
content: "\"\"",
|
|
109
|
+
position: "absolute",
|
|
110
|
+
insetBlockStart: 0,
|
|
111
|
+
insetInlineStart: 0,
|
|
112
|
+
inlineSize: "100%",
|
|
113
|
+
blockSize: "100%",
|
|
114
|
+
borderRadius: s.radius.full,
|
|
115
|
+
color: s.color.success,
|
|
116
|
+
border: "1px solid currentColor",
|
|
117
|
+
animation: `${_} ${s.motion.duration.presence} infinite ${s.motion.easePresence}`
|
|
118
|
+
},
|
|
119
|
+
[r]: v,
|
|
120
|
+
[n]: v
|
|
121
|
+
});
|
|
122
|
+
function b({ ref: e, name: t, src: n, size: r = "md", status: s, pulse: _ = !1, statusLabel: v, slotProps: b, className: x, sx: S, ...C }) {
|
|
123
|
+
let [w, T] = o(), E = n !== void 0 && n !== "" && n !== w, D = s === void 0 ? t : `${t}, ${v ?? s}`;
|
|
124
|
+
return /* @__PURE__ */ c(i, {
|
|
125
|
+
className: x,
|
|
126
|
+
styles: [d, f[r]],
|
|
127
|
+
sx: S,
|
|
128
|
+
children: (r) => /* @__PURE__ */ l("span", {
|
|
129
|
+
...C,
|
|
130
|
+
ref: e,
|
|
131
|
+
"data-ui": "avatar",
|
|
132
|
+
role: "img",
|
|
133
|
+
"aria-label": D,
|
|
134
|
+
className: r,
|
|
135
|
+
children: [E ? /* @__PURE__ */ c("img", {
|
|
136
|
+
src: n,
|
|
137
|
+
alt: "",
|
|
138
|
+
onError: () => T(n),
|
|
139
|
+
className: b?.image?.className,
|
|
140
|
+
css: [p, b?.image?.css]
|
|
141
|
+
}) : /* @__PURE__ */ c("span", {
|
|
142
|
+
"aria-hidden": "true",
|
|
143
|
+
className: b?.fallback?.className,
|
|
144
|
+
css: b?.fallback?.css,
|
|
145
|
+
children: a(t, u)
|
|
146
|
+
}), s !== void 0 && /* @__PURE__ */ c("span", {
|
|
147
|
+
"aria-hidden": "true",
|
|
148
|
+
"data-status": s,
|
|
149
|
+
"data-pulse": _ && s === "online" ? "" : void 0,
|
|
150
|
+
className: b?.status?.className,
|
|
151
|
+
css: [
|
|
152
|
+
m,
|
|
153
|
+
h[s],
|
|
154
|
+
g,
|
|
155
|
+
y,
|
|
156
|
+
b?.status?.css
|
|
157
|
+
]
|
|
158
|
+
})]
|
|
159
|
+
})
|
|
160
|
+
});
|
|
161
|
+
}
|
|
162
|
+
b.displayName = "Avatar";
|
|
163
|
+
//#endregion
|
|
164
|
+
export { b as t };
|
|
@@ -3,7 +3,7 @@ import { i as e } from "./css-BYJhdGh-.js";
|
|
|
3
3
|
import { n as t } from "./media-8yrN85VT.js";
|
|
4
4
|
import { t as n } from "./sx-BJXJ2xJK.js";
|
|
5
5
|
import { t as r } from "./visually-hidden-DgVO3NaB.js";
|
|
6
|
-
import { t as i } from "./avatar-
|
|
6
|
+
import { t as i } from "./avatar-BuM1zB_f.js";
|
|
7
7
|
import { useId as a } from "react";
|
|
8
8
|
import { vars as o } from "@jfrader/tokens/vars";
|
|
9
9
|
import { jsx as s, jsxs as c } from "@emotion/react/jsx-runtime";
|
package/dist/avatar-group.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as AvatarGroup } from "./avatar-group-
|
|
2
|
+
export { t as AvatarGroup } from "./avatar-group-D1UEihvh.js";
|
package/dist/avatar.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as Avatar } from "./avatar-
|
|
2
|
+
export { t as Avatar } from "./avatar-BuM1zB_f.js";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
//#region src/components/game-card/card-frame.ts
|
|
3
|
+
var e = {
|
|
4
|
+
ratio: 1.48,
|
|
5
|
+
cornerDivisor: 13
|
|
6
|
+
}, t = {
|
|
7
|
+
markWidthRatio: .35,
|
|
8
|
+
watermarkInsetPercent: 3,
|
|
9
|
+
watermarkOpacity: .15,
|
|
10
|
+
contentPaddingPercent: 4
|
|
11
|
+
};
|
|
12
|
+
//#endregion
|
|
13
|
+
export { e as n, t };
|
|
@@ -8,7 +8,7 @@ import { t as s } from "./visually-hidden-DgVO3NaB.js";
|
|
|
8
8
|
import { t as c } from "./button-C6OV0C7J.js";
|
|
9
9
|
import { t as ee } from "./part-id-D0zksy32.js";
|
|
10
10
|
import { t as te } from "./card-C008OQCp.js";
|
|
11
|
-
import { c as l, d as ne, g as re, h as u, i as ie, m as ae, n as d, p as oe, r as se, t as f } from "./thread-parts-
|
|
11
|
+
import { c as l, d as ne, g as re, h as u, i as ie, m as ae, n as d, p as oe, r as se, t as f } from "./thread-parts-DbKhuwVU.js";
|
|
12
12
|
import { useEffect as ce, useId as le, useLayoutEffect as p, useMemo as m, useRef as h, useState as g } from "react";
|
|
13
13
|
import { vars as _ } from "@jfrader/tokens/vars";
|
|
14
14
|
import { Fragment as v, jsx as y, jsxs as b } from "@emotion/react/jsx-runtime";
|
package/dist/chat-thread.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as ChatThread } from "./chat-thread-
|
|
2
|
+
export { t as ChatThread } from "./chat-thread-CMhwxhoA.js";
|
|
@@ -8,7 +8,7 @@ import { t as ee } from "./renderable-DzcIj1Lo.js";
|
|
|
8
8
|
import { t as s } from "./button-C6OV0C7J.js";
|
|
9
9
|
import { t as c } from "./part-id-D0zksy32.js";
|
|
10
10
|
import { t as l } from "./card-C008OQCp.js";
|
|
11
|
-
import { a as u, c as d, d as f, f as te, g as p, h as m, i as ne, l as re, n as ie, o as ae, p as oe, r as se, s as ce, t as le, u as ue } from "./thread-parts-
|
|
11
|
+
import { a as u, c as d, d as f, f as te, g as p, h as m, i as ne, l as re, n as ie, o as ae, p as oe, r as se, s as ce, t as le, u as ue } from "./thread-parts-DbKhuwVU.js";
|
|
12
12
|
import { useEffect as de, useId as fe, useLayoutEffect as h, useMemo as g, useRef as _, useState as v } from "react";
|
|
13
13
|
import { vars as y } from "@jfrader/tokens/vars";
|
|
14
14
|
import { Fragment as pe, jsx as b, jsxs as x } from "@emotion/react/jsx-runtime";
|
package/dist/comment-thread.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as CommentThread } from "./comment-thread-
|
|
2
|
+
export { t as CommentThread } from "./comment-thread-DbOzYr0q.js";
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { i as e } from "./css-BYJhdGh-.js";
|
|
3
|
+
import { r as t } from "./media-8yrN85VT.js";
|
|
4
|
+
import { t as n } from "./sx-BJXJ2xJK.js";
|
|
5
|
+
import { n as r } from "./card-frame-CcLa6NQ4.js";
|
|
6
|
+
import { useEffect as i, useState as a } from "react";
|
|
7
|
+
import { vars as o } from "@jfrader/tokens/vars";
|
|
8
|
+
import { jsx as s, jsxs as c } from "@emotion/react/jsx-runtime";
|
|
9
|
+
import { MotionConfig as l, useReducedMotion as u } from "motion/react";
|
|
10
|
+
//#region src/components/flip-game-card/flip-game-card.tsx
|
|
11
|
+
var d = e({
|
|
12
|
+
label: "flip-game-card",
|
|
13
|
+
position: "relative",
|
|
14
|
+
flexShrink: 0,
|
|
15
|
+
inlineSize: "var(--flip-game-card-width)",
|
|
16
|
+
blockSize: `calc(var(--flip-game-card-width) * ${r.ratio})`,
|
|
17
|
+
perspective: o.size.gameCardPerspective
|
|
18
|
+
}), f = {
|
|
19
|
+
sm: e({ "--flip-game-card-width": o.size.gameCardSm }),
|
|
20
|
+
md: e({ "--flip-game-card-width": o.size.gameCardMd }),
|
|
21
|
+
lg: e({ "--flip-game-card-width": o.size.gameCardLg })
|
|
22
|
+
}, p = e({ "& > [data-ui=\"flip-game-card-rotator\"]": {
|
|
23
|
+
transform: "none",
|
|
24
|
+
transition: "none",
|
|
25
|
+
"& > [data-ui=\"flip-game-card-back\"]": { transform: "none" }
|
|
26
|
+
} }), m = e({
|
|
27
|
+
"&[data-reduced-motion=\"true\"]": p,
|
|
28
|
+
[t]: p
|
|
29
|
+
}), h = e({
|
|
30
|
+
position: "relative",
|
|
31
|
+
inlineSize: "100%",
|
|
32
|
+
blockSize: "100%",
|
|
33
|
+
transformStyle: "preserve-3d",
|
|
34
|
+
transform: "rotateY(0deg)",
|
|
35
|
+
transition: `transform ${o.motion.duration.slow} ${o.motion.easeStandard}`,
|
|
36
|
+
"&[data-state=\"back\"]": { transform: "rotateY(180deg)" }
|
|
37
|
+
}), g = e({
|
|
38
|
+
position: "absolute",
|
|
39
|
+
inset: 0,
|
|
40
|
+
backfaceVisibility: "hidden",
|
|
41
|
+
"&[aria-hidden=\"true\"]": { visibility: "hidden" },
|
|
42
|
+
"& > [data-ui=\"game-card\"]": {
|
|
43
|
+
inlineSize: "100%",
|
|
44
|
+
blockSize: "100%"
|
|
45
|
+
}
|
|
46
|
+
}), _ = e({ transform: "rotateY(180deg)" });
|
|
47
|
+
function v({ ref: e, flipped: t, front: r, back: o, size: p = "md", slotProps: v, className: y, sx: b, ...x }) {
|
|
48
|
+
let S = u(), [C, w] = a(!1);
|
|
49
|
+
i(() => w(!0), []);
|
|
50
|
+
let T = t ? "back" : "front";
|
|
51
|
+
return /* @__PURE__ */ s(l, {
|
|
52
|
+
reducedMotion: "user",
|
|
53
|
+
children: /* @__PURE__ */ s(n, {
|
|
54
|
+
className: y,
|
|
55
|
+
styles: [
|
|
56
|
+
d,
|
|
57
|
+
f[p],
|
|
58
|
+
m
|
|
59
|
+
],
|
|
60
|
+
sx: b,
|
|
61
|
+
children: (n) => /* @__PURE__ */ s("div", {
|
|
62
|
+
...x,
|
|
63
|
+
ref: e,
|
|
64
|
+
className: n,
|
|
65
|
+
"data-ui": "flip-game-card",
|
|
66
|
+
"data-state": T,
|
|
67
|
+
"data-size": p,
|
|
68
|
+
"data-reduced-motion": C && S || void 0,
|
|
69
|
+
children: /* @__PURE__ */ c("div", {
|
|
70
|
+
"data-ui": "flip-game-card-rotator",
|
|
71
|
+
"data-state": T,
|
|
72
|
+
className: v?.rotator?.className,
|
|
73
|
+
css: [h, v?.rotator?.css],
|
|
74
|
+
children: [/* @__PURE__ */ s("div", {
|
|
75
|
+
"data-ui": "flip-game-card-front",
|
|
76
|
+
inert: t,
|
|
77
|
+
"aria-hidden": t || void 0,
|
|
78
|
+
className: v?.front?.className,
|
|
79
|
+
css: [g, v?.front?.css],
|
|
80
|
+
children: r
|
|
81
|
+
}), /* @__PURE__ */ s("div", {
|
|
82
|
+
"data-ui": "flip-game-card-back",
|
|
83
|
+
inert: !t,
|
|
84
|
+
"aria-hidden": !t || void 0,
|
|
85
|
+
className: v?.back?.className,
|
|
86
|
+
css: [
|
|
87
|
+
g,
|
|
88
|
+
_,
|
|
89
|
+
v?.back?.css
|
|
90
|
+
],
|
|
91
|
+
children: o
|
|
92
|
+
})]
|
|
93
|
+
})
|
|
94
|
+
})
|
|
95
|
+
})
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
v.displayName = "FlipGameCard";
|
|
99
|
+
//#endregion
|
|
100
|
+
export { v as t };
|
|
@@ -2,18 +2,11 @@
|
|
|
2
2
|
import { i as e } from "./css-BYJhdGh-.js";
|
|
3
3
|
import { t } from "./sx-BJXJ2xJK.js";
|
|
4
4
|
import { t as n } from "./renderable-DzcIj1Lo.js";
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
cornerDivisor: 13
|
|
11
|
-
}, s = {
|
|
12
|
-
markWidthRatio: .35,
|
|
13
|
-
watermarkInsetPercent: 3,
|
|
14
|
-
watermarkOpacity: .15,
|
|
15
|
-
contentPaddingPercent: 4
|
|
16
|
-
}, c = {
|
|
5
|
+
import { n as r, t as i } from "./card-frame-CcLa6NQ4.js";
|
|
6
|
+
import { vars as a } from "@jfrader/tokens/vars";
|
|
7
|
+
import { jsx as o, jsxs as s } from "@emotion/react/jsx-runtime";
|
|
8
|
+
//#region src/components/game-card/decks.ts
|
|
9
|
+
var c = {
|
|
17
10
|
oros: "💰",
|
|
18
11
|
copas: "🍷",
|
|
19
12
|
espadas: "🗡️",
|
|
@@ -45,31 +38,31 @@ var o = {
|
|
|
45
38
|
Q: "Q",
|
|
46
39
|
K: "K"
|
|
47
40
|
}, d = e({
|
|
48
|
-
"--game-card-width":
|
|
41
|
+
"--game-card-width": a.size.gameCardMd,
|
|
49
42
|
position: "relative",
|
|
50
43
|
display: "block",
|
|
51
44
|
flexShrink: 0,
|
|
52
45
|
boxSizing: "border-box",
|
|
53
46
|
inlineSize: "var(--game-card-width)",
|
|
54
|
-
blockSize: `calc(var(--game-card-width) * ${
|
|
55
|
-
borderRadius: `calc(var(--game-card-width) / ${
|
|
47
|
+
blockSize: `calc(var(--game-card-width) * ${r.ratio})`,
|
|
48
|
+
borderRadius: `calc(var(--game-card-width) / ${r.cornerDivisor})`,
|
|
56
49
|
overflow: "hidden",
|
|
57
50
|
containerType: "inline-size",
|
|
58
51
|
userSelect: "none",
|
|
59
52
|
verticalAlign: "middle"
|
|
60
53
|
}), f = e({
|
|
61
|
-
backgroundColor:
|
|
62
|
-
color:
|
|
63
|
-
border: `1px solid ${
|
|
54
|
+
backgroundColor: a.color.cardFace,
|
|
55
|
+
color: a.color.cardInk,
|
|
56
|
+
border: `1px solid ${a.color.cardInk}`
|
|
64
57
|
}), p = e({ opacity: .55 }), m = e({
|
|
65
58
|
position: "absolute",
|
|
66
59
|
inset: 0
|
|
67
60
|
}), h = e({
|
|
68
61
|
display: "grid",
|
|
69
62
|
placeItems: "center",
|
|
70
|
-
paddingInline: `${
|
|
71
|
-
fontSize: `${
|
|
72
|
-
fontWeight:
|
|
63
|
+
paddingInline: `${i.contentPaddingPercent}%`,
|
|
64
|
+
fontSize: `${i.markWidthRatio * 100}cqw`,
|
|
65
|
+
fontWeight: a.fontWeight.semibold,
|
|
73
66
|
lineHeight: 1,
|
|
74
67
|
whiteSpace: "nowrap"
|
|
75
68
|
}), g = e({
|
|
@@ -87,36 +80,36 @@ var o = {
|
|
|
87
80
|
gap: "0.1em"
|
|
88
81
|
}), v = e({
|
|
89
82
|
position: "absolute",
|
|
90
|
-
fontSize: `${
|
|
83
|
+
fontSize: `${i.markWidthRatio * 100}cqw`,
|
|
91
84
|
lineHeight: 1,
|
|
92
|
-
opacity:
|
|
85
|
+
opacity: i.watermarkOpacity
|
|
93
86
|
}), y = e({
|
|
94
|
-
insetBlockStart: `${
|
|
87
|
+
insetBlockStart: `${i.watermarkInsetPercent}%`,
|
|
95
88
|
insetInlineEnd: 0
|
|
96
89
|
}), b = e({
|
|
97
|
-
insetBlockEnd: `${
|
|
90
|
+
insetBlockEnd: `${i.watermarkInsetPercent}%`,
|
|
98
91
|
insetInlineStart: 0
|
|
99
92
|
}), x = {
|
|
100
|
-
red: e({ color:
|
|
101
|
-
ink: e({ color:
|
|
93
|
+
red: e({ color: a.color.cardRed }),
|
|
94
|
+
ink: e({ color: a.color.cardInk })
|
|
102
95
|
}, S = e({
|
|
103
|
-
backgroundColor:
|
|
104
|
-
backgroundImage: `repeating-linear-gradient(45deg, ${
|
|
96
|
+
backgroundColor: a.color.surfaceRaised,
|
|
97
|
+
backgroundImage: `repeating-linear-gradient(45deg, ${a.color.surfaceHover} 0 2px, transparent 2px 6px), repeating-linear-gradient(-45deg, ${a.color.surfaceHover} 0 2px, transparent 2px 6px)`,
|
|
105
98
|
"&::after": {
|
|
106
99
|
content: "\"\"",
|
|
107
100
|
position: "absolute",
|
|
108
101
|
inset: "8%",
|
|
109
|
-
border: `1px solid ${
|
|
102
|
+
border: `1px solid ${a.color.borderControl}`,
|
|
110
103
|
borderRadius: "inherit"
|
|
111
104
|
}
|
|
112
105
|
}), C = {
|
|
113
|
-
sm: e({ "--game-card-width":
|
|
114
|
-
md: e({ "--game-card-width":
|
|
115
|
-
lg: e({ "--game-card-width":
|
|
106
|
+
sm: e({ "--game-card-width": a.size.gameCardSm }),
|
|
107
|
+
md: e({ "--game-card-width": a.size.gameCardMd }),
|
|
108
|
+
lg: e({ "--game-card-width": a.size.gameCardLg })
|
|
116
109
|
};
|
|
117
|
-
function w({ ref: e, label: r, value:
|
|
118
|
-
let b =
|
|
119
|
-
return /* @__PURE__ */
|
|
110
|
+
function w({ ref: e, label: r, value: i, face: a, size: s = "md", rankLabel: c, dimmed: l = !1, children: u, slotProps: h, className: _, sx: v, ...y }) {
|
|
111
|
+
let b = a ?? (i === void 0 ? "back" : "emoji"), x = b === "back" || i === void 0;
|
|
112
|
+
return /* @__PURE__ */ o(t, {
|
|
120
113
|
className: _,
|
|
121
114
|
styles: [
|
|
122
115
|
d,
|
|
@@ -125,16 +118,16 @@ function w({ ref: e, label: r, value: a, face: o, size: s = "md", rankLabel: c,
|
|
|
125
118
|
l && p
|
|
126
119
|
],
|
|
127
120
|
sx: v,
|
|
128
|
-
children: (t) => /* @__PURE__ */
|
|
121
|
+
children: (t) => /* @__PURE__ */ o("div", {
|
|
129
122
|
...y,
|
|
130
123
|
ref: e,
|
|
131
124
|
role: "img",
|
|
132
125
|
"aria-label": r,
|
|
133
126
|
"data-ui": "game-card",
|
|
134
127
|
"data-face": b,
|
|
135
|
-
"data-deck": x ? void 0 :
|
|
128
|
+
"data-deck": x ? void 0 : i.deck,
|
|
136
129
|
className: t,
|
|
137
|
-
children: x ? /* @__PURE__ */
|
|
130
|
+
children: x ? /* @__PURE__ */ o("span", {
|
|
138
131
|
"data-ui": "game-card-back",
|
|
139
132
|
"aria-hidden": "true",
|
|
140
133
|
className: h?.back?.className,
|
|
@@ -143,7 +136,7 @@ function w({ ref: e, label: r, value: a, face: o, size: s = "md", rankLabel: c,
|
|
|
143
136
|
S,
|
|
144
137
|
h?.back?.css
|
|
145
138
|
]
|
|
146
|
-
}) : n(u) ? /* @__PURE__ */
|
|
139
|
+
}) : n(u) ? /* @__PURE__ */ o("span", {
|
|
147
140
|
"data-ui": "game-card-art",
|
|
148
141
|
"aria-hidden": "true",
|
|
149
142
|
className: h?.face?.className,
|
|
@@ -153,8 +146,8 @@ function w({ ref: e, label: r, value: a, face: o, size: s = "md", rankLabel: c,
|
|
|
153
146
|
h?.face?.css
|
|
154
147
|
],
|
|
155
148
|
children: u
|
|
156
|
-
}) : /* @__PURE__ */
|
|
157
|
-
value:
|
|
149
|
+
}) : /* @__PURE__ */ o(T, {
|
|
150
|
+
value: i,
|
|
158
151
|
rankLabel: c,
|
|
159
152
|
slotProps: h
|
|
160
153
|
})
|
|
@@ -163,27 +156,27 @@ function w({ ref: e, label: r, value: a, face: o, size: s = "md", rankLabel: c,
|
|
|
163
156
|
}
|
|
164
157
|
w.displayName = "GameCard";
|
|
165
158
|
function T({ value: e, rankLabel: t, slotProps: n }) {
|
|
166
|
-
let r = c[e.suit],
|
|
167
|
-
return /* @__PURE__ */
|
|
159
|
+
let r = c[e.suit], i = t ?? u[e.rank], a = l[e.suit];
|
|
160
|
+
return /* @__PURE__ */ s("span", {
|
|
168
161
|
"data-ui": "game-card-print",
|
|
169
162
|
"aria-hidden": "true",
|
|
170
163
|
className: n?.face?.className,
|
|
171
164
|
css: [
|
|
172
165
|
m,
|
|
173
166
|
h,
|
|
174
|
-
|
|
167
|
+
a !== void 0 && x[a],
|
|
175
168
|
n?.face?.css
|
|
176
169
|
],
|
|
177
170
|
children: [
|
|
178
|
-
/* @__PURE__ */
|
|
171
|
+
/* @__PURE__ */ o("span", {
|
|
179
172
|
css: [v, y],
|
|
180
173
|
children: r
|
|
181
174
|
}),
|
|
182
|
-
/* @__PURE__ */
|
|
175
|
+
/* @__PURE__ */ s("span", {
|
|
183
176
|
css: _,
|
|
184
|
-
children: [/* @__PURE__ */
|
|
177
|
+
children: [/* @__PURE__ */ o("span", { children: i }), /* @__PURE__ */ o("span", { children: r })]
|
|
185
178
|
}),
|
|
186
|
-
/* @__PURE__ */
|
|
179
|
+
/* @__PURE__ */ o("span", {
|
|
187
180
|
css: [v, b],
|
|
188
181
|
children: r
|
|
189
182
|
})
|
package/dist/game-card.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as GameCard, n as RANK_MARKS, r as SUIT_GLYPHS, i as SUIT_INK } from "./game-card-
|
|
2
|
+
export { t as GameCard, n as RANK_MARKS, r as SUIT_GLYPHS, i as SUIT_INK } from "./game-card-Bnhpz78f.js";
|
|
@@ -4,7 +4,7 @@ import { r as n } from "./media-8yrN85VT.js";
|
|
|
4
4
|
import { t as r } from "./sx-BJXJ2xJK.js";
|
|
5
5
|
import { t as i } from "./use-controlled-state-DpeVQZNR.js";
|
|
6
6
|
import { t as a } from "./renderable-DzcIj1Lo.js";
|
|
7
|
-
import { t as o } from "./avatar-
|
|
7
|
+
import { t as o } from "./avatar-BuM1zB_f.js";
|
|
8
8
|
import { n as s } from "./surface-C69kwSuk.js";
|
|
9
9
|
import { t as c } from "./trigger-style-CtOrdPk4.js";
|
|
10
10
|
import { a as l, i as u } from "./overlay-layer-qEbpEtb8.js";
|
package/dist/hover-card.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as HoverCard } from "./hover-card
|
|
2
|
+
export { t as HoverCard } from "./hover-card--ijYr1cd.js";
|
package/dist/index.js
CHANGED
|
@@ -5,8 +5,8 @@ import { t as n } from "./alert-Bhj-qSMs.js";
|
|
|
5
5
|
import { t as r } from "./button-C6OV0C7J.js";
|
|
6
6
|
import { t as i } from "./countdown-EcpV6rXy.js";
|
|
7
7
|
import { t as a } from "./announcement-bar-B5J33QUh.js";
|
|
8
|
-
import { t as o } from "./avatar-
|
|
9
|
-
import { t as s } from "./avatar-group-
|
|
8
|
+
import { t as o } from "./avatar-BuM1zB_f.js";
|
|
9
|
+
import { t as s } from "./avatar-group-D1UEihvh.js";
|
|
10
10
|
import { t as c } from "./badge-CfhTcA-Z.js";
|
|
11
11
|
import { t as l } from "./segmented-control-DCh-4ca-.js";
|
|
12
12
|
import { t as u } from "./billing-toggle-CgC7yxxo.js";
|
|
@@ -19,7 +19,7 @@ import { t as g } from "./calendar-Bg6D2sul.js";
|
|
|
19
19
|
import { t as _ } from "./card-C008OQCp.js";
|
|
20
20
|
import { t as v } from "./carousel-lTH4Foke.js";
|
|
21
21
|
import { t as y } from "./textarea-D1YwEPmn.js";
|
|
22
|
-
import { t as b } from "./chat-thread-
|
|
22
|
+
import { t as b } from "./chat-thread-CMhwxhoA.js";
|
|
23
23
|
import { t as x } from "./checkbox-CClE61GV.js";
|
|
24
24
|
import { t as S } from "./chip-group-BZUX9KPF.js";
|
|
25
25
|
import { t as C } from "./copy-button-C0p_qrgf.js";
|
|
@@ -27,7 +27,7 @@ import { t as w } from "./code-block-CYP89_6h.js";
|
|
|
27
27
|
import { t as T } from "./command-palette-BrT1n9bb.js";
|
|
28
28
|
import { t as E } from "./text-field-D0VP7b4P.js";
|
|
29
29
|
import { t as D } from "./combobox-D2Oc-co7.js";
|
|
30
|
-
import { t as O } from "./comment-thread-
|
|
30
|
+
import { t as O } from "./comment-thread-DbOzYr0q.js";
|
|
31
31
|
import { t as k } from "./container-BxtwJSSD.js";
|
|
32
32
|
import { t as A } from "./context-menu-I4i0LRpm.js";
|
|
33
33
|
import { t as j } from "./date-picker-D-bn-iHs.js";
|
|
@@ -44,61 +44,62 @@ import { t as V } from "./progress-Bcuz3Ob4.js";
|
|
|
44
44
|
import { t as H } from "./file-dropzone-Bi5ikRIz.js";
|
|
45
45
|
import { t as U } from "./filter-toolbar-QRnC4S_H.js";
|
|
46
46
|
import { t as W } from "./flex-CS7eMRcK.js";
|
|
47
|
-
import {
|
|
48
|
-
import { t as Y } from "./
|
|
49
|
-
import { t as X } from "./
|
|
50
|
-
import { t as Z } from "./
|
|
51
|
-
import { t as Q } from "./
|
|
52
|
-
import { t as $ } from "./
|
|
53
|
-
import { t as ee } from "./
|
|
54
|
-
import { t as te } from "./
|
|
55
|
-
import { t as ne } from "./
|
|
56
|
-
import { t as re } from "./
|
|
57
|
-
import { t as ie } from "./
|
|
58
|
-
import { t as ae } from "./
|
|
59
|
-
import {
|
|
60
|
-
import { t as le } from "./
|
|
61
|
-
import { t as ue } from "./
|
|
62
|
-
import { t as de } from "./
|
|
63
|
-
import { t as fe } from "./
|
|
64
|
-
import { t as pe } from "./
|
|
65
|
-
import {
|
|
66
|
-
import { t as ge } from "./
|
|
67
|
-
import { t as _e } from "./
|
|
68
|
-
import { t as ve } from "./
|
|
69
|
-
import { t as ye } from "./
|
|
70
|
-
import { t as be } from "./
|
|
71
|
-
import { t as xe } from "./radio-
|
|
72
|
-
import { t as Se } from "./
|
|
73
|
-
import { t as Ce } from "./
|
|
74
|
-
import { t as we } from "./
|
|
75
|
-
import {
|
|
76
|
-
import {
|
|
77
|
-
import { i as
|
|
78
|
-
import { t as Re } from "./
|
|
79
|
-
import { t as ze } from "./
|
|
80
|
-
import { t as Be } from "./
|
|
81
|
-
import { t as Ve } from "./
|
|
82
|
-
import { t as He } from "./
|
|
83
|
-
import { t as Ue } from "./
|
|
84
|
-
import { t as We } from "./
|
|
85
|
-
import { t as Ge } from "./
|
|
86
|
-
import { t as Ke } from "./
|
|
87
|
-
import { t as qe } from "./
|
|
88
|
-
import { t as Je } from "./
|
|
89
|
-
import {
|
|
90
|
-
import { n as
|
|
91
|
-
import { t as tt } from "./theme-
|
|
92
|
-
import { t as nt } from "./
|
|
93
|
-
import { t as rt } from "./
|
|
94
|
-
import {
|
|
47
|
+
import { t as G } from "./flip-game-card-xmcR_QSq.js";
|
|
48
|
+
import { i as K, n as q, r as J, t as Y } from "./game-card-Bnhpz78f.js";
|
|
49
|
+
import { t as X } from "./hold-to-confirm-CVBA0wNT.js";
|
|
50
|
+
import { t as Z } from "./image-compare-Ln2UUqTU.js";
|
|
51
|
+
import { t as Q } from "./in-view-title-BUZCMqge.js";
|
|
52
|
+
import { t as $ } from "./inline-edit-D-pR2RPC.js";
|
|
53
|
+
import { t as ee } from "./hover-card--ijYr1cd.js";
|
|
54
|
+
import { t as te } from "./json-viewer-Dro3WrjS.js";
|
|
55
|
+
import { t as ne } from "./kbd-BI_9qzYr.js";
|
|
56
|
+
import { t as re } from "./keycap-keyboard-Cdx-OAS1.js";
|
|
57
|
+
import { t as ie } from "./lightbox-gallery-D0YaSTut.js";
|
|
58
|
+
import { t as ae } from "./link-unfurl-CReyIjyy.js";
|
|
59
|
+
import { t as oe } from "./locale-switcher-DTkySKsM.js";
|
|
60
|
+
import { n as se, r as ce, t as le } from "./mention-input-BjjAbJCf.js";
|
|
61
|
+
import { t as ue } from "./pill-Dd7pog19.js";
|
|
62
|
+
import { t as de } from "./metric-card-BnFssTXj.js";
|
|
63
|
+
import { t as fe } from "./multi-select-B3puEVo0.js";
|
|
64
|
+
import { t as pe } from "./navigation-C_JD43gA.js";
|
|
65
|
+
import { t as me } from "./slider-DjAnGmlC.js";
|
|
66
|
+
import { n as he, t as ge } from "./now-playing-DjVm1Phm.js";
|
|
67
|
+
import { t as _e } from "./pagination-Dkh4bJQh.js";
|
|
68
|
+
import { t as ve } from "./password-field-Da58GP1g.js";
|
|
69
|
+
import { t as ye } from "./photo-grid-Dtl17D74.js";
|
|
70
|
+
import { t as be } from "./popover-CUMOcMtj.js";
|
|
71
|
+
import { t as xe } from "./radio-cards-FkAhESb5.js";
|
|
72
|
+
import { t as Se } from "./radio-group-DItMf2YM.js";
|
|
73
|
+
import { t as Ce } from "./resizable-panels-61h9hA3B.js";
|
|
74
|
+
import { t as we } from "./scroll-area-B8KkCPOM.js";
|
|
75
|
+
import { t as Te } from "./select-SrcQqZjo.js";
|
|
76
|
+
import { n as Ee, t as De } from "./sheet-stack-DYX1SGSB.js";
|
|
77
|
+
import { a as Oe, i as ke, n as Ae, o as je, r as Me, s as Ne, t as Pe } from "./shortcut-recorder-VgTQdjjn.js";
|
|
78
|
+
import { i as Fe, n as Ie, r as Le, t as Re } from "./signature-pad-khL2yhQI.js";
|
|
79
|
+
import { t as ze } from "./skeleton-LJsQsveI.js";
|
|
80
|
+
import { t as Be } from "./sortable-data-table-Bpitup_d.js";
|
|
81
|
+
import { t as Ve } from "./spinner-CvzajSg9.js";
|
|
82
|
+
import { t as He } from "./split-button-Bu41f2AY.js";
|
|
83
|
+
import { t as Ue } from "./stack-Bac4sJeI.js";
|
|
84
|
+
import { t as We } from "./stepper-C8Ncavbr.js";
|
|
85
|
+
import { t as Ge } from "./stretch-refresh-OrnTEj7P.js";
|
|
86
|
+
import { t as Ke } from "./swipe-actions-1H5UOZKE.js";
|
|
87
|
+
import { t as qe } from "./switch-79-hkQqg.js";
|
|
88
|
+
import { t as Je } from "./tabs-Bb5-noYE.js";
|
|
89
|
+
import { t as Ye } from "./tag-input-BQaueKEb.js";
|
|
90
|
+
import { n as Xe, r as Ze, t as Qe } from "./theme-provider-BvcY-iJu.js";
|
|
91
|
+
import { n as $e, r as et, t as tt } from "./theme-root-BrYVcTzt.js";
|
|
92
|
+
import { t as nt } from "./theme-switch-CP42mVDb.js";
|
|
93
|
+
import { t as rt } from "./time-picker-Tnd-JBLC.js";
|
|
94
|
+
import { t as it } from "./timeline-BPKY94mT.js";
|
|
95
|
+
import { a as at, n as ot } from "./toast-CSAbl5yK.js";
|
|
95
96
|
import "./toast.js";
|
|
96
|
-
import { t as
|
|
97
|
-
import { t as
|
|
97
|
+
import { t as st } from "./toast-stack-BCR4Cu7V.js";
|
|
98
|
+
import { t as ct } from "./toggle-group-C7ye1v4s.js";
|
|
98
99
|
import "./tooltip.js";
|
|
99
|
-
import { t as
|
|
100
|
-
import { t as
|
|
101
|
-
import { t as
|
|
102
|
-
import { t as
|
|
103
|
-
import
|
|
104
|
-
export { e as Accordion, t as ActivityRings, n as Alert, a as AnnouncementBar, o as Avatar, s as AvatarGroup, c as Badge, u as BillingToggle, d as BottomSheet, f as Breadcrumbs, r as Button, h as ButtonGroup, g as Calendar, _ as Card, v as Carousel, b as ChatThread, x as Checkbox, S as ChipGroup, w as CodeBlock, D as Combobox, T as CommandPalette, O as CommentThread, k as Container, A as ContextMenu, C as CopyButton, i as Countdown, j as DatePicker, M as DateRangePicker, N as Dialog, P as Divider, F as Drawer, I as Emblem, L as EmptyState, R as ExpandableCard, B as ExpandingSearch, H as FileDropzone, U as FilterToolbar, W as Flex,
|
|
100
|
+
import { t as lt } from "./tree-view-CoW4oJIZ.js";
|
|
101
|
+
import { t as ut } from "./typewriter-terminal-BUEsMzo3.js";
|
|
102
|
+
import { t as dt } from "./usage-meter-CYvlB6l3.js";
|
|
103
|
+
import { t as ft } from "./user-menu-Czrrk93A.js";
|
|
104
|
+
import pt from "@emotion/styled";
|
|
105
|
+
export { e as Accordion, t as ActivityRings, n as Alert, a as AnnouncementBar, o as Avatar, s as AvatarGroup, c as Badge, u as BillingToggle, d as BottomSheet, f as Breadcrumbs, r as Button, h as ButtonGroup, g as Calendar, _ as Card, v as Carousel, b as ChatThread, x as Checkbox, S as ChipGroup, w as CodeBlock, D as Combobox, T as CommandPalette, O as CommentThread, k as Container, A as ContextMenu, C as CopyButton, i as Countdown, j as DatePicker, M as DateRangePicker, N as Dialog, P as Divider, F as Drawer, I as Emblem, L as EmptyState, R as ExpandableCard, B as ExpandingSearch, H as FileDropzone, U as FilterToolbar, W as Flex, G as FlipGameCard, Y as GameCard, X as HoldToConfirm, ee as HoverCard, Z as ImageCompare, Q as InViewTitle, $ as InlineEdit, te as JsonViewer, ne as Kbd, re as KeycapKeyboard, ie as LightboxGallery, ae as LinkUnfurl, oe as LocaleSwitcher, le as MentionInput, p as Menu, de as MetricCard, fe as MultiSelect, pe as Navigation, ge as NowPlaying, he as NowPlayingLevels, _e as Pagination, ve as PasswordField, ye as PhotoGrid, ue as Pill, be as Popover, V as Progress, q as RANK_MARKS, xe as RadioCards, Se as RadioGroup, Ce as ResizablePanels, J as SUIT_GLYPHS, K as SUIT_INK, we as ScrollArea, z as SearchField, l as SegmentedControl, Te as Select, De as SheetStack, Pe as ShortcutRecorder, Re as SignatureExportError, Ie as SignaturePad, ze as Skeleton, me as Slider, Be as SortableDataTable, Ve as Spinner, He as SplitButton, Ue as Stack, We as Stepper, Ge as StretchRefresh, Ke as SwipeActions, qe as Switch, Je as Tabs, Ye as TagInput, E as TextField, y as Textarea, Qe as ThemeProvider, tt as ThemeRoot, nt as ThemeSwitch, rt as TimePicker, it as Timeline, ot as Toast, st as ToastStack, ct as ToggleGroup, m as Tooltip, lt as TreeView, ut as TypewriterTerminal, dt as UsageMeter, ft as UserMenu, $e as createTheme, Ae as defaultShortcutMessages, Me as formatShortcut, ke as matchesShortcut, se as mentionText, Oe as normalizeShortcut, ce as serializeMentions, Le as signatureToPng, Fe as signatureToSvg, pt as styled, Ze as theme, et as themeTokenStyle, je as usePressedShortcutKeys, Ee as useSheetStack, Ne as useShortcutPlatform, Xe as useTheme, at as useToast };
|
|
@@ -4,7 +4,7 @@ import { n as t } from "./media-8yrN85VT.js";
|
|
|
4
4
|
import { n } from "./roving-focus-CYlo_Kf8.js";
|
|
5
5
|
import { t as r } from "./visually-hidden-DgVO3NaB.js";
|
|
6
6
|
import { t as i } from "./button-C6OV0C7J.js";
|
|
7
|
-
import { t as a } from "./avatar-
|
|
7
|
+
import { t as a } from "./avatar-BuM1zB_f.js";
|
|
8
8
|
import { n as o, o as s, s as c, t as l } from "./listbox-style-DNOxAulu.js";
|
|
9
9
|
import { t as u } from "./overlay-portal-C9igMHnC.js";
|
|
10
10
|
import { t as d } from "./part-id-D0zksy32.js";
|
|
@@ -9,7 +9,7 @@ import { t as c } from "./use-controlled-state-DpeVQZNR.js";
|
|
|
9
9
|
import { t as l } from "./visually-hidden-DgVO3NaB.js";
|
|
10
10
|
import { t as u } from "./renderable-DzcIj1Lo.js";
|
|
11
11
|
import { t as d } from "./icon-wrapper-C-zMD0uL.js";
|
|
12
|
-
import { t as f } from "./avatar-
|
|
12
|
+
import { t as f } from "./avatar-BuM1zB_f.js";
|
|
13
13
|
import { t as p } from "./part-id-D0zksy32.js";
|
|
14
14
|
import { useEffect as ee, useId as te, useLayoutEffect as ne, useMemo as m, useRef as h, useState as re } from "react";
|
|
15
15
|
import { vars as g } from "@jfrader/tokens/vars";
|
package/dist/timeline.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as Timeline } from "./timeline-
|
|
2
|
+
export { t as Timeline } from "./timeline-BPKY94mT.js";
|
|
@@ -13,6 +13,8 @@ export interface AvatarProps extends Omit<ComponentPropsWithRef<'span'>, 'childr
|
|
|
13
13
|
src?: string;
|
|
14
14
|
size?: AvatarSize;
|
|
15
15
|
status?: AvatarStatus;
|
|
16
|
+
/** Pulse the presence ring only when `status="online"`. Defaults to `false`. */
|
|
17
|
+
pulse?: boolean;
|
|
16
18
|
/** Spoken status word; defaults to the `status` value. Pass a translated word for other locales. */
|
|
17
19
|
statusLabel?: string;
|
|
18
20
|
slotProps?: {
|
|
@@ -21,7 +23,7 @@ export interface AvatarProps extends Omit<ComponentPropsWithRef<'span'>, 'childr
|
|
|
21
23
|
status?: AvatarPartProps;
|
|
22
24
|
};
|
|
23
25
|
}
|
|
24
|
-
export declare function Avatar({ ref, name, src, size, status, statusLabel, slotProps, className, sx, ...rest }: AvatarProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
26
|
+
export declare function Avatar({ ref, name, src, size, status, pulse, statusLabel, slotProps, className, sx, ...rest }: AvatarProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
25
27
|
export declare namespace Avatar {
|
|
26
28
|
var displayName: string;
|
|
27
29
|
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { type ComponentPropsWithRef, type ReactNode } from 'react';
|
|
2
|
+
import { type SxProps } from '../../styling/sx';
|
|
3
|
+
import type { GameCardPartProps, GameCardSize } from '../game-card';
|
|
4
|
+
export interface FlipGameCardProps extends Omit<ComponentPropsWithRef<'div'>, 'children'>, SxProps {
|
|
5
|
+
/** Shows `back` when true and `front` when false. No interaction changes this prop. */
|
|
6
|
+
flipped: boolean;
|
|
7
|
+
/** Content shown when `flipped` is false. */
|
|
8
|
+
front: ReactNode;
|
|
9
|
+
/** Content shown when `flipped` is true. Both faces stay mounted. */
|
|
10
|
+
back: ReactNode;
|
|
11
|
+
/** Card width, using the GameCard scale. Defaults to `md`. */
|
|
12
|
+
size?: GameCardSize;
|
|
13
|
+
slotProps?: {
|
|
14
|
+
rotator?: GameCardPartProps;
|
|
15
|
+
front?: GameCardPartProps;
|
|
16
|
+
back?: GameCardPartProps;
|
|
17
|
+
};
|
|
18
|
+
}
|
|
19
|
+
export declare function FlipGameCard({ ref, flipped, front, back, size, slotProps, className, sx, ...rest }: FlipGameCardProps): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
20
|
+
export declare namespace FlipGameCard {
|
|
21
|
+
var displayName: string;
|
|
22
|
+
}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -36,6 +36,7 @@ export * from './components/expanding-search';
|
|
|
36
36
|
export * from './components/file-dropzone';
|
|
37
37
|
export * from './components/filter-toolbar';
|
|
38
38
|
export * from './components/flex';
|
|
39
|
+
export * from './components/flip-game-card';
|
|
39
40
|
export * from './components/game-card';
|
|
40
41
|
export * from './components/hold-to-confirm';
|
|
41
42
|
export * from './components/image-compare';
|
|
@@ -102,8 +102,10 @@ export declare const theme: {
|
|
|
102
102
|
readonly fast: "var(--ui-motion-duration-fast)";
|
|
103
103
|
readonly base: "var(--ui-motion-duration-base)";
|
|
104
104
|
readonly slow: "var(--ui-motion-duration-slow)";
|
|
105
|
+
readonly presence: "var(--ui-motion-duration-presence)";
|
|
105
106
|
};
|
|
106
107
|
readonly easeStandard: "var(--ui-motion-ease-standard)";
|
|
108
|
+
readonly easePresence: "var(--ui-motion-ease-presence)";
|
|
107
109
|
};
|
|
108
110
|
readonly size: {
|
|
109
111
|
readonly emblemSm: "var(--ui-size-emblem-sm)";
|
|
@@ -113,6 +115,7 @@ export declare const theme: {
|
|
|
113
115
|
readonly gameCardSm: "var(--ui-size-game-card-sm)";
|
|
114
116
|
readonly gameCardMd: "var(--ui-size-game-card-md)";
|
|
115
117
|
readonly gameCardLg: "var(--ui-size-game-card-lg)";
|
|
118
|
+
readonly gameCardPerspective: "var(--ui-size-game-card-perspective)";
|
|
116
119
|
readonly sheetStackBreakpoint: "var(--ui-size-sheet-stack-breakpoint)";
|
|
117
120
|
readonly sheetStackSheetPeek: "var(--ui-size-sheet-stack-sheet-peek)";
|
|
118
121
|
readonly sheetStackDialogPeek: "var(--ui-size-sheet-stack-dialog-peek)";
|
|
@@ -8,7 +8,7 @@ import { t as c } from "./use-controlled-state-DpeVQZNR.js";
|
|
|
8
8
|
import { t as l } from "./visually-hidden-DgVO3NaB.js";
|
|
9
9
|
import { t as u } from "./renderable-DzcIj1Lo.js";
|
|
10
10
|
import { t as d } from "./icon-wrapper-C-zMD0uL.js";
|
|
11
|
-
import { t as f } from "./avatar-
|
|
11
|
+
import { t as f } from "./avatar-BuM1zB_f.js";
|
|
12
12
|
import { t as p } from "./use-scroll-lock-40gXwwAy.js";
|
|
13
13
|
import { s as m } from "./listbox-style-DNOxAulu.js";
|
|
14
14
|
import { t as h } from "./overlay-portal-C9igMHnC.js";
|
package/dist/user-menu.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
'use client';
|
|
2
|
-
export { t as UserMenu } from "./user-menu-
|
|
2
|
+
export { t as UserMenu } from "./user-menu-Czrrk93A.js";
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@jfrader/ui",
|
|
3
|
-
"version": "0.7.
|
|
3
|
+
"version": "0.7.1",
|
|
4
4
|
"description": "React components styled with Emotion and themed through CSS custom properties.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"react",
|
|
@@ -182,6 +182,10 @@
|
|
|
182
182
|
"types": "./dist/types/components/flex/index.d.ts",
|
|
183
183
|
"import": "./dist/flex.js"
|
|
184
184
|
},
|
|
185
|
+
"./flip-game-card": {
|
|
186
|
+
"types": "./dist/types/components/flip-game-card/index.d.ts",
|
|
187
|
+
"import": "./dist/flip-game-card.js"
|
|
188
|
+
},
|
|
185
189
|
"./game-card": {
|
|
186
190
|
"types": "./dist/types/components/game-card/index.d.ts",
|
|
187
191
|
"import": "./dist/game-card.js"
|
|
@@ -435,7 +439,7 @@
|
|
|
435
439
|
"@emotion/styled": "^11.14.0",
|
|
436
440
|
"@floating-ui/react": "^0.27.20",
|
|
437
441
|
"motion": "^14.1.0",
|
|
438
|
-
"@jfrader/tokens": "0.7.
|
|
442
|
+
"@jfrader/tokens": "0.7.1"
|
|
439
443
|
},
|
|
440
444
|
"peerDependencies": {
|
|
441
445
|
"@emotion/cache": "^11.14.0",
|
package/dist/avatar-sPxDqFiZ.js
DELETED
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
'use client';
|
|
2
|
-
import { i as e } from "./css-BYJhdGh-.js";
|
|
3
|
-
import { n as t } from "./media-8yrN85VT.js";
|
|
4
|
-
import { t as n } from "./sx-BJXJ2xJK.js";
|
|
5
|
-
import { t as r } from "./initials-DEdwNe9_.js";
|
|
6
|
-
import { useState as i } from "react";
|
|
7
|
-
import { vars as a } from "@jfrader/tokens/vars";
|
|
8
|
-
import { jsx as o, jsxs as s } from "@emotion/react/jsx-runtime";
|
|
9
|
-
//#region src/components/avatar/avatar.tsx
|
|
10
|
-
var c = 2, l = e({
|
|
11
|
-
position: "relative",
|
|
12
|
-
display: "inline-flex",
|
|
13
|
-
alignItems: "center",
|
|
14
|
-
justifyContent: "center",
|
|
15
|
-
flexShrink: 0,
|
|
16
|
-
boxSizing: "border-box",
|
|
17
|
-
borderRadius: a.radius.full,
|
|
18
|
-
backgroundColor: a.color.surfaceHover,
|
|
19
|
-
color: a.color.text,
|
|
20
|
-
fontWeight: a.fontWeight.medium,
|
|
21
|
-
lineHeight: 1,
|
|
22
|
-
userSelect: "none",
|
|
23
|
-
verticalAlign: "middle",
|
|
24
|
-
[t]: { outline: "1px solid CanvasText" }
|
|
25
|
-
}), u = {
|
|
26
|
-
sm: e({
|
|
27
|
-
inlineSize: a.space[6],
|
|
28
|
-
blockSize: a.space[6],
|
|
29
|
-
fontSize: a.textSize.xs
|
|
30
|
-
}),
|
|
31
|
-
md: e({
|
|
32
|
-
inlineSize: a.space[8],
|
|
33
|
-
blockSize: a.space[8],
|
|
34
|
-
fontSize: a.textSize.sm
|
|
35
|
-
}),
|
|
36
|
-
lg: e({
|
|
37
|
-
inlineSize: a.space[10],
|
|
38
|
-
blockSize: a.space[10],
|
|
39
|
-
fontSize: a.textSize.md
|
|
40
|
-
})
|
|
41
|
-
}, d = e({
|
|
42
|
-
display: "block",
|
|
43
|
-
inlineSize: "100%",
|
|
44
|
-
blockSize: "100%",
|
|
45
|
-
borderRadius: a.radius.full,
|
|
46
|
-
objectFit: "cover"
|
|
47
|
-
}), f = e({
|
|
48
|
-
position: "absolute",
|
|
49
|
-
insetBlockEnd: 0,
|
|
50
|
-
insetInlineEnd: 0,
|
|
51
|
-
inlineSize: "25%",
|
|
52
|
-
blockSize: "25%",
|
|
53
|
-
"&::before": {
|
|
54
|
-
content: "\"\"",
|
|
55
|
-
position: "absolute",
|
|
56
|
-
insetBlockStart: 0,
|
|
57
|
-
insetInlineStart: 0,
|
|
58
|
-
inlineSize: "100%",
|
|
59
|
-
blockSize: "100%",
|
|
60
|
-
boxSizing: "border-box",
|
|
61
|
-
borderRadius: a.radius.full,
|
|
62
|
-
boxShadow: `0 0 0 2px ${a.color.bg}`
|
|
63
|
-
}
|
|
64
|
-
}), p = {
|
|
65
|
-
online: e({ "&::before": { backgroundColor: a.color.success } }),
|
|
66
|
-
away: e({ "&::before": {
|
|
67
|
-
border: `2px solid ${a.color.warning}`,
|
|
68
|
-
backgroundColor: "transparent"
|
|
69
|
-
} }),
|
|
70
|
-
busy: e({ "&::before": {
|
|
71
|
-
backgroundColor: a.color.danger,
|
|
72
|
-
blockSize: "30%",
|
|
73
|
-
insetBlockStart: "35%"
|
|
74
|
-
} }),
|
|
75
|
-
offline: e({ "&::before": {
|
|
76
|
-
backgroundColor: a.color.textSubtle,
|
|
77
|
-
inlineSize: "60%",
|
|
78
|
-
blockSize: "60%",
|
|
79
|
-
insetBlockStart: "20%",
|
|
80
|
-
insetInlineStart: "20%"
|
|
81
|
-
} })
|
|
82
|
-
}, m = e({ [t]: {
|
|
83
|
-
"&::before": {
|
|
84
|
-
forcedColorAdjust: "none",
|
|
85
|
-
backgroundColor: "CanvasText",
|
|
86
|
-
outline: "2px solid Canvas"
|
|
87
|
-
},
|
|
88
|
-
"&[data-status=\"away\"]::before": {
|
|
89
|
-
borderColor: "CanvasText",
|
|
90
|
-
backgroundColor: "Canvas"
|
|
91
|
-
}
|
|
92
|
-
} });
|
|
93
|
-
function h({ ref: e, name: t, src: a, size: h = "md", status: g, statusLabel: _, slotProps: v, className: y, sx: b, ...x }) {
|
|
94
|
-
let [S, C] = i(), w = a !== void 0 && a !== "" && a !== S, T = g === void 0 ? t : `${t}, ${_ ?? g}`;
|
|
95
|
-
return /* @__PURE__ */ o(n, {
|
|
96
|
-
className: y,
|
|
97
|
-
styles: [l, u[h]],
|
|
98
|
-
sx: b,
|
|
99
|
-
children: (n) => /* @__PURE__ */ s("span", {
|
|
100
|
-
...x,
|
|
101
|
-
ref: e,
|
|
102
|
-
"data-ui": "avatar",
|
|
103
|
-
role: "img",
|
|
104
|
-
"aria-label": T,
|
|
105
|
-
className: n,
|
|
106
|
-
children: [w ? /* @__PURE__ */ o("img", {
|
|
107
|
-
src: a,
|
|
108
|
-
alt: "",
|
|
109
|
-
onError: () => C(a),
|
|
110
|
-
className: v?.image?.className,
|
|
111
|
-
css: [d, v?.image?.css]
|
|
112
|
-
}) : /* @__PURE__ */ o("span", {
|
|
113
|
-
"aria-hidden": "true",
|
|
114
|
-
className: v?.fallback?.className,
|
|
115
|
-
css: v?.fallback?.css,
|
|
116
|
-
children: r(t, c)
|
|
117
|
-
}), g !== void 0 && /* @__PURE__ */ o("span", {
|
|
118
|
-
"aria-hidden": "true",
|
|
119
|
-
"data-status": g,
|
|
120
|
-
className: v?.status?.className,
|
|
121
|
-
css: [
|
|
122
|
-
f,
|
|
123
|
-
p[g],
|
|
124
|
-
m,
|
|
125
|
-
v?.status?.css
|
|
126
|
-
]
|
|
127
|
-
})]
|
|
128
|
-
})
|
|
129
|
-
});
|
|
130
|
-
}
|
|
131
|
-
h.displayName = "Avatar";
|
|
132
|
-
//#endregion
|
|
133
|
-
export { h as t };
|