@multiplatform.one/components 9.8.0 → 9.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/Accordion/index.cjs +28 -24
- package/dist/cjs/Accordion/index.native.js +28 -24
- package/dist/cjs/Accordion/index.native.js.map +1 -1
- package/dist/cjs/Diff/index.cjs +3 -1
- package/dist/cjs/Diff/index.native.js +3 -1
- package/dist/cjs/Diff/index.native.js.map +1 -1
- package/dist/cjs/ElapsedProgress/index.cjs +3 -1
- package/dist/cjs/ElapsedProgress/index.native.js +3 -1
- package/dist/cjs/ElapsedProgress/index.native.js.map +1 -1
- package/dist/cjs/SwipeDismissRow/index.cjs +9 -7
- package/dist/cjs/SwipeDismissRow/index.native.js +9 -7
- package/dist/cjs/SwipeDismissRow/index.native.js.map +1 -1
- package/dist/cjs/actions/DestructiveAction.cjs +5 -1
- package/dist/cjs/actions/DestructiveAction.native.js +5 -1
- package/dist/cjs/actions/DestructiveAction.native.js.map +1 -1
- package/dist/esm/Accordion/index.mjs +29 -25
- package/dist/esm/Accordion/index.mjs.map +1 -1
- package/dist/esm/Accordion/index.native.js +29 -25
- package/dist/esm/Accordion/index.native.js.map +1 -1
- package/dist/esm/Diff/index.mjs +3 -1
- package/dist/esm/Diff/index.mjs.map +1 -1
- package/dist/esm/Diff/index.native.js +3 -1
- package/dist/esm/Diff/index.native.js.map +1 -1
- package/dist/esm/ElapsedProgress/index.mjs +4 -2
- package/dist/esm/ElapsedProgress/index.mjs.map +1 -1
- package/dist/esm/ElapsedProgress/index.native.js +4 -2
- package/dist/esm/ElapsedProgress/index.native.js.map +1 -1
- package/dist/esm/SwipeDismissRow/index.mjs +10 -8
- package/dist/esm/SwipeDismissRow/index.mjs.map +1 -1
- package/dist/esm/SwipeDismissRow/index.native.js +10 -8
- package/dist/esm/SwipeDismissRow/index.native.js.map +1 -1
- package/dist/esm/actions/DestructiveAction.mjs +6 -2
- package/dist/esm/actions/DestructiveAction.mjs.map +1 -1
- package/dist/esm/actions/DestructiveAction.native.js +6 -2
- package/dist/esm/actions/DestructiveAction.native.js.map +1 -1
- package/dist/jsx/Accordion/index.mjs +29 -25
- package/dist/jsx/Accordion/index.mjs.map +1 -1
- package/dist/jsx/Accordion/index.native.js +28 -24
- package/dist/jsx/Accordion/index.native.js.map +1 -1
- package/dist/jsx/Diff/index.mjs +3 -1
- package/dist/jsx/Diff/index.mjs.map +1 -1
- package/dist/jsx/Diff/index.native.js +3 -1
- package/dist/jsx/Diff/index.native.js.map +1 -1
- package/dist/jsx/ElapsedProgress/index.mjs +4 -2
- package/dist/jsx/ElapsedProgress/index.mjs.map +1 -1
- package/dist/jsx/ElapsedProgress/index.native.js +3 -1
- package/dist/jsx/ElapsedProgress/index.native.js.map +1 -1
- package/dist/jsx/SwipeDismissRow/index.mjs +10 -8
- package/dist/jsx/SwipeDismissRow/index.mjs.map +1 -1
- package/dist/jsx/SwipeDismissRow/index.native.js +9 -7
- package/dist/jsx/SwipeDismissRow/index.native.js.map +1 -1
- package/dist/jsx/actions/DestructiveAction.mjs +6 -2
- package/dist/jsx/actions/DestructiveAction.mjs.map +1 -1
- package/dist/jsx/actions/DestructiveAction.native.js +5 -1
- package/dist/jsx/actions/DestructiveAction.native.js.map +1 -1
- package/package.json +7 -7
- package/src/Accordion/Accordion.gutter.spec.tsx +19 -20
- package/src/Accordion/Accordion.stories.tsx +1 -1
- package/src/Accordion/Accordion.tamagui.spec.tsx +230 -0
- package/src/Accordion/index.tsx +45 -30
- package/src/Chip/Chip.ink.spec.tsx +12 -1
- package/src/Diff/Diff.spec.tsx +16 -0
- package/src/Diff/index.tsx +1 -1
- package/src/ElapsedProgress/ElapsedProgress.spec.tsx +16 -0
- package/src/ElapsedProgress/index.tsx +2 -2
- package/src/SwipeDismissRow/SwipeDismissRow.spec.tsx +17 -0
- package/src/SwipeDismissRow/index.tsx +11 -7
- package/src/actions/DestructiveAction.spec.tsx +25 -0
- package/src/actions/DestructiveAction.tsx +4 -2
- package/src/appShell/TabBar.stories.tsx +9 -1
- package/types/Accordion/index.d.ts +1 -1
- package/types/Accordion/index.d.ts.map +1 -1
- package/types/ElapsedProgress/index.d.ts.map +1 -1
- package/types/SwipeDismissRow/index.d.ts.map +1 -1
- package/types/actions/DestructiveAction.d.ts.map +1 -1
|
@@ -0,0 +1,230 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* FZ-11423, LC-72 (FZ-7999 amended): Accordion follows tamagui.dev's v3
|
|
3
|
+
* Accordion. The plain variant is one framed group: each trigger is a plate
|
|
4
|
+
* that paints `knobProps.surface`'s fill inside `controlBorderOutlined`'s
|
|
5
|
+
* edge, at least a hairline under every preset, so the frame never vanishes
|
|
6
|
+
* where the borderWidth knob is none. The title
|
|
7
|
+
* leads, the chevron trails and turns 180deg while its item is open, and the
|
|
8
|
+
* open content is a plate under its trigger with no top edge. A plate below
|
|
9
|
+
* the first drops its top edge, so no shared hairline doubles. A card item
|
|
10
|
+
* keeps its own surface and the trailing chevron.
|
|
11
|
+
*
|
|
12
|
+
* happy-dom cascades no Tamagui CSS, so this compares the atomic classes the
|
|
13
|
+
* trigger asks for with a probe that spreads the same fragment.
|
|
14
|
+
*/
|
|
15
|
+
import {
|
|
16
|
+
boldPreset,
|
|
17
|
+
consolePreset,
|
|
18
|
+
createDefaultThemeConfig,
|
|
19
|
+
defaultPreset,
|
|
20
|
+
densePreset,
|
|
21
|
+
heroPreset,
|
|
22
|
+
Preset,
|
|
23
|
+
roomyPreset,
|
|
24
|
+
storefrontPreset,
|
|
25
|
+
useResolvedKnobs,
|
|
26
|
+
} from "@multiplatform.one/theme";
|
|
27
|
+
import { cleanup, fireEvent, render, screen } from "@testing-library/react";
|
|
28
|
+
import type { ReactElement } from "react";
|
|
29
|
+
import { TamaguiProvider, View, YStack } from "tamagui";
|
|
30
|
+
import { afterEach, describe, expect, it } from "vitest";
|
|
31
|
+
import { Accordion, type AccordionVariant } from "./index";
|
|
32
|
+
|
|
33
|
+
afterEach(cleanup);
|
|
34
|
+
|
|
35
|
+
const presets = {
|
|
36
|
+
Default: defaultPreset,
|
|
37
|
+
Bold: boldPreset,
|
|
38
|
+
Hero: heroPreset,
|
|
39
|
+
Dense: densePreset,
|
|
40
|
+
Roomy: roomyPreset,
|
|
41
|
+
Console: consolePreset,
|
|
42
|
+
Storefront: storefrontPreset,
|
|
43
|
+
} as const;
|
|
44
|
+
|
|
45
|
+
const houseConfig = createDefaultThemeConfig();
|
|
46
|
+
const schemes = ["light", "dark"] as const;
|
|
47
|
+
type Scheme = (typeof schemes)[number];
|
|
48
|
+
|
|
49
|
+
const cells = Object.entries(presets).flatMap(([name, preset]) =>
|
|
50
|
+
schemes.map((scheme) => [name, scheme, preset.knobs] as const),
|
|
51
|
+
);
|
|
52
|
+
|
|
53
|
+
function SurfaceProbe() {
|
|
54
|
+
const { knobProps } = useResolvedKnobs({ component: "Accordion" });
|
|
55
|
+
return (
|
|
56
|
+
<View testID="surface-probe" {...knobProps.surface} {...knobProps.controlBorderOutlined} />
|
|
57
|
+
);
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
function houseRender(
|
|
61
|
+
knobs: (typeof presets)[keyof typeof presets]["knobs"],
|
|
62
|
+
scheme: Scheme,
|
|
63
|
+
variant: AccordionVariant = "plain",
|
|
64
|
+
ui?: ReactElement,
|
|
65
|
+
) {
|
|
66
|
+
return render(
|
|
67
|
+
<TamaguiProvider config={houseConfig.tamagui} defaultTheme={scheme} disableInjectCSS>
|
|
68
|
+
<YStack backgroundColor="$background">
|
|
69
|
+
<Preset overrides={knobs}>
|
|
70
|
+
<SurfaceProbe />
|
|
71
|
+
{ui ?? (
|
|
72
|
+
<Accordion variant={variant} defaultValue="a">
|
|
73
|
+
<Accordion.Item value="a">
|
|
74
|
+
<Accordion.Trigger>Section A</Accordion.Trigger>
|
|
75
|
+
<Accordion.Content>Body A</Accordion.Content>
|
|
76
|
+
</Accordion.Item>
|
|
77
|
+
<Accordion.Item value="b">
|
|
78
|
+
<Accordion.Trigger>Section B</Accordion.Trigger>
|
|
79
|
+
<Accordion.Content>Body B</Accordion.Content>
|
|
80
|
+
</Accordion.Item>
|
|
81
|
+
</Accordion>
|
|
82
|
+
)}
|
|
83
|
+
</Preset>
|
|
84
|
+
</YStack>
|
|
85
|
+
</TamaguiProvider>,
|
|
86
|
+
);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
const triggers = () => Array.from(document.querySelectorAll("[aria-expanded]")) as HTMLElement[];
|
|
90
|
+
const dump = (el: Element) => `class="${el.className}"`;
|
|
91
|
+
|
|
92
|
+
const STATE = /\d*(hover|active|focus|press)/;
|
|
93
|
+
|
|
94
|
+
/** Resting classes for one family of atoms (`_bg-`, `_bc-`, `_bw-`, ...). */
|
|
95
|
+
function rest(el: Element, ...prefixes: string[]): string[] {
|
|
96
|
+
return Array.from(el.classList)
|
|
97
|
+
.filter((c) => prefixes.some((p) => c.startsWith(p)))
|
|
98
|
+
.filter((c) => !STATE.test(c))
|
|
99
|
+
.sort();
|
|
100
|
+
}
|
|
101
|
+
|
|
102
|
+
const fill = (el: Element) => rest(el, "_bg-");
|
|
103
|
+
const edgeColour = (el: Element) => rest(el, "_btc-", "_brc-", "_bbc-", "_blc-", "_bc-");
|
|
104
|
+
const edgeWidth = (el: Element) => rest(el, "_btw-", "_brw-", "_bbw-", "_blw-", "_bw-");
|
|
105
|
+
const topWidth = (el: Element) => rest(el, "_btw-");
|
|
106
|
+
const sideWidths = (el: Element) => rest(el, "_brw-", "_bbw-", "_blw-");
|
|
107
|
+
|
|
108
|
+
function chevronOf(trigger: HTMLElement): HTMLElement {
|
|
109
|
+
const chevron = trigger.lastElementChild as HTMLElement | null;
|
|
110
|
+
expect(chevron, dump(trigger)).not.toBeNull();
|
|
111
|
+
return chevron as HTMLElement;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
function rotation(el: Element): string {
|
|
115
|
+
return Array.from(el.classList).find((c) => c.startsWith("_tr-")) ?? dump(el);
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
describe("Accordion anatomy: title leads, the chevron trails and turns (tamagui v3)", () => {
|
|
119
|
+
it.each(["plain", "card"] as const)("%s: the chevron is the trigger's last child", (variant) => {
|
|
120
|
+
houseRender(defaultPreset.knobs, "light", variant);
|
|
121
|
+
const trigger = triggers()[0];
|
|
122
|
+
const chevron = chevronOf(trigger);
|
|
123
|
+
expect(chevron.getAttribute("aria-hidden"), dump(chevron)).toBe("true");
|
|
124
|
+
expect(chevron.querySelector("svg")).not.toBeNull();
|
|
125
|
+
const title = screen.getByText("Section A");
|
|
126
|
+
expect(title.compareDocumentPosition(chevron) & Node.DOCUMENT_POSITION_FOLLOWING).toBeTruthy();
|
|
127
|
+
expect(trigger.firstElementChild?.contains(title)).toBe(true);
|
|
128
|
+
});
|
|
129
|
+
|
|
130
|
+
it.each(["plain", "card"] as const)(
|
|
131
|
+
"%s: the chevron turns 180deg open and 0deg closed",
|
|
132
|
+
(variant) => {
|
|
133
|
+
houseRender(defaultPreset.knobs, "light", variant);
|
|
134
|
+
const [open, closed] = triggers();
|
|
135
|
+
expect(open.getAttribute("aria-expanded")).toBe("true");
|
|
136
|
+
expect(rotation(chevronOf(open))).toMatch(/^_tr-rotate180/);
|
|
137
|
+
expect(rotation(chevronOf(closed))).toMatch(/^_tr-rotate0/);
|
|
138
|
+
fireEvent.click(open);
|
|
139
|
+
expect(open.getAttribute("aria-expanded")).toBe("false");
|
|
140
|
+
expect(rotation(chevronOf(open))).toMatch(/^_tr-rotate0/);
|
|
141
|
+
},
|
|
142
|
+
);
|
|
143
|
+
});
|
|
144
|
+
|
|
145
|
+
describe("plain Accordion: one framed group of trigger plates", () => {
|
|
146
|
+
it.each(cells)(
|
|
147
|
+
"%s, %s: each trigger is a surface plate inside an outlined edge",
|
|
148
|
+
(_name, scheme, knobs) => {
|
|
149
|
+
houseRender(knobs, scheme);
|
|
150
|
+
const probe = screen.getByTestId("surface-probe");
|
|
151
|
+
expect(fill(probe).length, dump(probe)).toBeGreaterThan(0);
|
|
152
|
+
for (const trigger of triggers()) {
|
|
153
|
+
expect(fill(trigger), dump(trigger)).toEqual(fill(probe));
|
|
154
|
+
expect(edgeColour(trigger), dump(trigger)).toEqual(edgeColour(probe));
|
|
155
|
+
}
|
|
156
|
+
expect(edgeWidth(triggers()[0]), dump(triggers()[0])).toEqual(edgeWidth(probe));
|
|
157
|
+
expect(edgeWidth(probe), dump(probe)).not.toContain("_btw-0px");
|
|
158
|
+
},
|
|
159
|
+
);
|
|
160
|
+
|
|
161
|
+
it.each(cells)(
|
|
162
|
+
"%s, %s: a plate below the first drops its top edge, so no hairline doubles",
|
|
163
|
+
(_name, scheme, knobs) => {
|
|
164
|
+
houseRender(knobs, scheme);
|
|
165
|
+
const probe = screen.getByTestId("surface-probe");
|
|
166
|
+
const [first, second] = triggers();
|
|
167
|
+
expect(topWidth(first), dump(first)).not.toContain("_btw-0px");
|
|
168
|
+
expect(topWidth(second), dump(second)).toEqual(["_btw-0px"]);
|
|
169
|
+
expect(
|
|
170
|
+
edgeWidth(second).filter((c) => !c.startsWith("_btw-")),
|
|
171
|
+
dump(second),
|
|
172
|
+
).toEqual(edgeWidth(probe).filter((c) => !c.startsWith("_btw-")));
|
|
173
|
+
expect(sideWidths(first).length + rest(first, "_bw-").length).toBeGreaterThan(0);
|
|
174
|
+
expect(sideWidths(first)).not.toContain("_blw-0px");
|
|
175
|
+
},
|
|
176
|
+
);
|
|
177
|
+
|
|
178
|
+
it.each(cells)(
|
|
179
|
+
"%s, %s: the open content is a plate under its trigger with no top edge",
|
|
180
|
+
(_name, scheme, knobs) => {
|
|
181
|
+
houseRender(knobs, scheme);
|
|
182
|
+
const probe = screen.getByTestId("surface-probe");
|
|
183
|
+
const region = screen.getByRole("region");
|
|
184
|
+
const plate = [region, ...Array.from(region.querySelectorAll("*"))].find(
|
|
185
|
+
(el) => fill(el).length > 0 && topWidth(el).includes("_btw-0px"),
|
|
186
|
+
);
|
|
187
|
+
expect(plate, region.outerHTML.slice(0, 600)).toBeDefined();
|
|
188
|
+
expect(fill(plate as Element)).toEqual(fill(probe));
|
|
189
|
+
expect(edgeColour(plate as Element)).toEqual(edgeColour(probe));
|
|
190
|
+
},
|
|
191
|
+
);
|
|
192
|
+
|
|
193
|
+
it("an open trigger keeps the plate: open is disclosure, not selection (FZ-7999)", () => {
|
|
194
|
+
houseRender(defaultPreset.knobs, "light");
|
|
195
|
+
const [open, closed] = triggers();
|
|
196
|
+
expect(open.getAttribute("aria-expanded")).toBe("true");
|
|
197
|
+
expect(fill(open)).toEqual(fill(closed));
|
|
198
|
+
expect(open.getAttribute("data-selected")).toBeNull();
|
|
199
|
+
});
|
|
200
|
+
});
|
|
201
|
+
|
|
202
|
+
describe("card Accordion: the item is the surface", () => {
|
|
203
|
+
it.each(cells)(
|
|
204
|
+
"%s, %s: the trigger paints no plate or shadow of its own",
|
|
205
|
+
(_name, scheme, knobs) => {
|
|
206
|
+
houseRender(knobs, scheme, "card");
|
|
207
|
+
for (const trigger of triggers()) {
|
|
208
|
+
expect(rest(trigger, "_bg-"), dump(trigger)).toEqual(["_bg-transparent"]);
|
|
209
|
+
expect(rest(trigger, "_boxShadow-", "_shadow"), dump(trigger)).toEqual([]);
|
|
210
|
+
expect(trigger.style.boxShadow).toBe("");
|
|
211
|
+
}
|
|
212
|
+
},
|
|
213
|
+
);
|
|
214
|
+
});
|
|
215
|
+
|
|
216
|
+
describe("Accordion keyboard and a11y semantics hold", () => {
|
|
217
|
+
it("Enter and Space toggle a native button that reports aria-expanded", () => {
|
|
218
|
+
houseRender(defaultPreset.knobs, "light");
|
|
219
|
+
const trigger = triggers()[1];
|
|
220
|
+
expect(trigger.tagName).toBe("BUTTON");
|
|
221
|
+
expect(trigger.getAttribute("aria-expanded")).toBe("false");
|
|
222
|
+
expect(trigger.getAttribute("aria-controls")).toBeTruthy();
|
|
223
|
+
fireEvent.keyDown(trigger, { key: "Enter" });
|
|
224
|
+
fireEvent.click(trigger);
|
|
225
|
+
expect(trigger.getAttribute("aria-expanded")).toBe("true");
|
|
226
|
+
fireEvent.keyDown(trigger, { key: " " });
|
|
227
|
+
fireEvent.click(trigger);
|
|
228
|
+
expect(trigger.getAttribute("aria-expanded")).toBe("false");
|
|
229
|
+
});
|
|
230
|
+
});
|
package/src/Accordion/index.tsx
CHANGED
|
@@ -12,7 +12,6 @@ import {
|
|
|
12
12
|
stackEdgeRadius,
|
|
13
13
|
useGroupPosition,
|
|
14
14
|
useLegibleInkOn,
|
|
15
|
-
usePageGutter,
|
|
16
15
|
useResolvedKnobs,
|
|
17
16
|
wasKeyboardFocus,
|
|
18
17
|
type GroupPosition,
|
|
@@ -45,7 +44,6 @@ import { forwardRef } from "react";
|
|
|
45
44
|
import { AnimateHeight } from "../AnimateHeight";
|
|
46
45
|
import { componentColors } from "../componentColors";
|
|
47
46
|
import { themed } from "../icons/themed";
|
|
48
|
-
import { usePageChromeInset } from "../layouts/pageHeadingScope";
|
|
49
47
|
import { wrapBareTextChildren } from "../shared/textRidesText";
|
|
50
48
|
|
|
51
49
|
// ── Types ─────────────────────────────────────────────────────
|
|
@@ -54,7 +52,7 @@ export type AccordionVariant = "plain" | "card";
|
|
|
54
52
|
export type AccordionType = "single" | "multiple";
|
|
55
53
|
|
|
56
54
|
interface AccordionCommonProps extends Omit<StackProps, "onChange" | "size"> {
|
|
57
|
-
/** Visual variant: "plain" =
|
|
55
|
+
/** Visual variant: "plain" = one framed group of trigger plates, "card" = each item on its own surface */
|
|
58
56
|
variant?: AccordionVariant;
|
|
59
57
|
/** Disable every item */
|
|
60
58
|
disabled?: boolean;
|
|
@@ -273,6 +271,17 @@ function Chevron({
|
|
|
273
271
|
);
|
|
274
272
|
}
|
|
275
273
|
|
|
274
|
+
/**
|
|
275
|
+
* Tamagui's framed accordion draws every trigger as a bordered plate and
|
|
276
|
+
* drops the top edge of each one below the first, so two plates never stack
|
|
277
|
+
* a doubled hairline (FZ-11423). The plate takes `surface`'s fill inside
|
|
278
|
+
* `controlBorderOutlined`'s edge, which stays at least a hairline when the
|
|
279
|
+
* borderWidth knob is none, so the frame holds under every preset.
|
|
280
|
+
*/
|
|
281
|
+
function sharedTopEdge(position: GroupPosition) {
|
|
282
|
+
return position === "first" || position === "only" ? {} : { borderTopWidth: 0 };
|
|
283
|
+
}
|
|
284
|
+
|
|
276
285
|
// ── Stacked-group children ────────────────────────────────────
|
|
277
286
|
|
|
278
287
|
/**
|
|
@@ -430,13 +439,7 @@ const AccordionItem = forwardRef<TamaguiElement, AccordionItemProps>(function Ac
|
|
|
430
439
|
...getCardElevationProps(elevationToken),
|
|
431
440
|
overflow: "hidden" as const,
|
|
432
441
|
}
|
|
433
|
-
: {
|
|
434
|
-
// plain: edge-to-edge divider rows (SP-EDGE); the divider sits
|
|
435
|
-
// BETWEEN items only — a rule under the last item would put a
|
|
436
|
-
// straight edge against the group's rounded bottom highlight.
|
|
437
|
-
borderBottomWidth: position === "last" || position === "only" ? 0 : 1,
|
|
438
|
-
borderColor: componentColors.surface.border,
|
|
439
|
-
};
|
|
442
|
+
: {};
|
|
440
443
|
|
|
441
444
|
return (
|
|
442
445
|
<AccordionItemCtx.Provider value={itemCtx}>
|
|
@@ -461,7 +464,7 @@ const AccordionTrigger = forwardRef<TamaguiElement, AccordionTriggerProps>(
|
|
|
461
464
|
ref,
|
|
462
465
|
) {
|
|
463
466
|
const { knobProps, control, disabledState } = useAccordionKnobs();
|
|
464
|
-
const { headingLevel } = useContext(AccordionCtx);
|
|
467
|
+
const { headingLevel, variant } = useContext(AccordionCtx);
|
|
465
468
|
const item = useContext(AccordionItemCtx);
|
|
466
469
|
const [kbFocus, setKbFocus] = useState(false);
|
|
467
470
|
if (isWeb) ensureKeyboardModalityTracking();
|
|
@@ -477,7 +480,14 @@ const AccordionTrigger = forwardRef<TamaguiElement, AccordionTriggerProps>(
|
|
|
477
480
|
// Open is disclosure, not selection: the chevron says it, and the row
|
|
478
481
|
// keeps its rest look (FZ-7999). A grey open fill read as a hard-edged
|
|
479
482
|
// selected block.
|
|
480
|
-
const restFill =
|
|
483
|
+
const restFill =
|
|
484
|
+
variant === "plain"
|
|
485
|
+
? {
|
|
486
|
+
...knobProps.surface,
|
|
487
|
+
...knobProps.controlBorderOutlined,
|
|
488
|
+
...sharedTopEdge(item.position),
|
|
489
|
+
}
|
|
490
|
+
: { backgroundColor: "transparent" as const, borderWidth: 0 };
|
|
481
491
|
const hoverFill = control.hoverKnobProps ?? {
|
|
482
492
|
backgroundColor: componentColors.interactive.background,
|
|
483
493
|
};
|
|
@@ -518,7 +528,6 @@ const AccordionTrigger = forwardRef<TamaguiElement, AccordionTriggerProps>(
|
|
|
518
528
|
minHeight={knobProps.sizeToken as any}
|
|
519
529
|
hitSlop={pressTargetHitSlop(visualPx)}
|
|
520
530
|
{...knobProps.panelPadding}
|
|
521
|
-
borderWidth={0}
|
|
522
531
|
cursor={item.disabled ? "not-allowed" : "pointer"}
|
|
523
532
|
outlineWidth={0}
|
|
524
533
|
data-group-position={item.position}
|
|
@@ -550,15 +559,6 @@ const AccordionTrigger = forwardRef<TamaguiElement, AccordionTriggerProps>(
|
|
|
550
559
|
{...transitionProps(knobProps.motion.control)}
|
|
551
560
|
{...props}
|
|
552
561
|
>
|
|
553
|
-
<Chevron
|
|
554
|
-
open={item.open}
|
|
555
|
-
size={chevronPx}
|
|
556
|
-
color={
|
|
557
|
-
(item.disabled ? disabledState.textKnobProps.color : knobProps.textAccentColor) ??
|
|
558
|
-
knobProps.textAccentColor
|
|
559
|
-
}
|
|
560
|
-
motion={knobProps.motion.control}
|
|
561
|
-
/>
|
|
562
562
|
{icon ? (
|
|
563
563
|
<View
|
|
564
564
|
alignItems="center"
|
|
@@ -587,6 +587,15 @@ const AccordionTrigger = forwardRef<TamaguiElement, AccordionTriggerProps>(
|
|
|
587
587
|
</Text>
|
|
588
588
|
))}
|
|
589
589
|
</YStack>
|
|
590
|
+
<Chevron
|
|
591
|
+
open={item.open}
|
|
592
|
+
size={chevronPx}
|
|
593
|
+
color={
|
|
594
|
+
(item.disabled ? disabledState.textKnobProps.color : knobProps.textAccentColor) ??
|
|
595
|
+
knobProps.textAccentColor
|
|
596
|
+
}
|
|
597
|
+
motion={knobProps.motion.control}
|
|
598
|
+
/>
|
|
590
599
|
</TamaguiAccordion.Trigger>
|
|
591
600
|
</View>
|
|
592
601
|
);
|
|
@@ -605,14 +614,9 @@ const AccordionContent = forwardRef<TamaguiElement, AccordionContentProps>(
|
|
|
605
614
|
const { knobProps } = useAccordionKnobs();
|
|
606
615
|
const { variant } = useContext(AccordionCtx);
|
|
607
616
|
const item = useContext(AccordionItemCtx);
|
|
608
|
-
const pageGutter = usePageGutter();
|
|
609
|
-
const screenInset = usePageChromeInset();
|
|
610
|
-
// LC-159: a plain accordion on a gutter-inset page is not a surface, so
|
|
611
|
-
// its content sits on the trigger's left edge, the page gutter, and adds
|
|
612
|
-
// no side inset of its own. A card item pads inside its own surface.
|
|
613
617
|
const panelInset =
|
|
614
|
-
variant === "plain"
|
|
615
|
-
?
|
|
618
|
+
variant === "plain"
|
|
619
|
+
? knobProps.panelPadding
|
|
616
620
|
: { ...knobProps.panelPadding, paddingTop: knobProps.gap.gap };
|
|
617
621
|
// Open last/only content owns the group's trailing corners (the trigger
|
|
618
622
|
// above is square where it abuts this region).
|
|
@@ -630,7 +634,18 @@ const AccordionContent = forwardRef<TamaguiElement, AccordionContentProps>(
|
|
|
630
634
|
aria-labelledby={item.triggerId}
|
|
631
635
|
{...cornerProps}
|
|
632
636
|
>
|
|
633
|
-
<YStack
|
|
637
|
+
<YStack
|
|
638
|
+
{...(variant === "plain"
|
|
639
|
+
? {
|
|
640
|
+
...knobProps.surface,
|
|
641
|
+
...knobProps.controlBorderOutlined,
|
|
642
|
+
borderTopWidth: 0,
|
|
643
|
+
...cornerProps,
|
|
644
|
+
}
|
|
645
|
+
: {})}
|
|
646
|
+
{...panelInset}
|
|
647
|
+
{...props}
|
|
648
|
+
>
|
|
634
649
|
{/* LC-82 TEXT-RIDES-TEXT: content is a View slot — bare/array string
|
|
635
650
|
children ride a body Text instead of crashing native. */}
|
|
636
651
|
{wrapBareTextChildren(children, (label, key) => (
|
|
@@ -42,7 +42,18 @@ it.each(["light", "dark"] as const)(
|
|
|
42
42
|
"keeps the selected label readable in every %s colour theme",
|
|
43
43
|
(scheme) => {
|
|
44
44
|
const config = createDefaultThemeConfig({});
|
|
45
|
-
for (const hue of [
|
|
45
|
+
for (const hue of [
|
|
46
|
+
"blue",
|
|
47
|
+
"gray",
|
|
48
|
+
"green",
|
|
49
|
+
"orange",
|
|
50
|
+
"pink",
|
|
51
|
+
"purple",
|
|
52
|
+
"red",
|
|
53
|
+
"yellow",
|
|
54
|
+
"sky",
|
|
55
|
+
"plum",
|
|
56
|
+
]) {
|
|
46
57
|
const view = render(
|
|
47
58
|
<TamaguiProvider config={config.tamagui} defaultTheme={scheme}>
|
|
48
59
|
<Theme name={hue}>
|
package/src/Diff/Diff.spec.tsx
CHANGED
|
@@ -103,3 +103,19 @@ describe("Diff (LC-190)", () => {
|
|
|
103
103
|
);
|
|
104
104
|
});
|
|
105
105
|
});
|
|
106
|
+
|
|
107
|
+
function rnA11yAttributes(root: ParentNode): string[] {
|
|
108
|
+
return [...root.querySelectorAll("*")].flatMap((el) =>
|
|
109
|
+
el.getAttributeNames().filter((name) => name.startsWith("accessibility")),
|
|
110
|
+
);
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
describe("Diff web a11y (FZ-11156)", () => {
|
|
114
|
+
it("names the region with aria-label only, no RN accessibility attributes", () => {
|
|
115
|
+
const { container } = mount(Default.args);
|
|
116
|
+
expect(container.querySelector("[role='region']")?.getAttribute("aria-label")).toBe(
|
|
117
|
+
"nginx.conf: 2 added, 1 removed",
|
|
118
|
+
);
|
|
119
|
+
expect(rnA11yAttributes(container)).toEqual([]);
|
|
120
|
+
});
|
|
121
|
+
});
|
package/src/Diff/index.tsx
CHANGED
|
@@ -125,7 +125,7 @@ export function Diff({ before, after, label, lineNumbers = true, ...frameProps }
|
|
|
125
125
|
<YStack
|
|
126
126
|
role="region"
|
|
127
127
|
aria-label={summary}
|
|
128
|
-
accessibilityLabel
|
|
128
|
+
{...(isWeb ? undefined : { accessibilityLabel: summary })}
|
|
129
129
|
overflow="hidden"
|
|
130
130
|
{...knobProps.borderRadius}
|
|
131
131
|
data-diff-state={state}
|
|
@@ -64,3 +64,19 @@ describe("ElapsedProgress (LC-185)", () => {
|
|
|
64
64
|
expect(elapsedOf(container)).toBe("1:35");
|
|
65
65
|
});
|
|
66
66
|
});
|
|
67
|
+
|
|
68
|
+
function rnA11yAttributes(root: ParentNode): string[] {
|
|
69
|
+
return [...root.querySelectorAll("*")].flatMap((el) =>
|
|
70
|
+
el.getAttributeNames().filter((name) => name.startsWith("accessibility")),
|
|
71
|
+
);
|
|
72
|
+
}
|
|
73
|
+
|
|
74
|
+
describe("ElapsedProgress web a11y (FZ-11156)", () => {
|
|
75
|
+
it("names the row with aria-label, never an RN accessibilityLabel attribute", () => {
|
|
76
|
+
const { container } = renderWithProviders(
|
|
77
|
+
<ElapsedProgress startedAt={Date.now()} label="Sync" />,
|
|
78
|
+
);
|
|
79
|
+
expect(container.querySelector("[aria-label^='Sync']")).toBeTruthy();
|
|
80
|
+
expect(rnA11yAttributes(container)).toEqual([]);
|
|
81
|
+
});
|
|
82
|
+
});
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
import { Progress, Spinner } from "@multiplatform.one/forms";
|
|
8
8
|
import { useResolvedKnobs } from "@multiplatform.one/theme";
|
|
9
9
|
import { useEffect, useState } from "react";
|
|
10
|
-
import { Text, XStack, YStack, type XStackProps } from "tamagui";
|
|
10
|
+
import { Text, XStack, YStack, isWeb, type XStackProps } from "tamagui";
|
|
11
11
|
import { useTranslation } from "../shared/i18n";
|
|
12
12
|
import { withInterp } from "../shared/t";
|
|
13
13
|
|
|
@@ -60,7 +60,7 @@ export function ElapsedProgress({
|
|
|
60
60
|
alignItems="center"
|
|
61
61
|
{...knobProps.gapSm}
|
|
62
62
|
aria-label={name}
|
|
63
|
-
accessibilityLabel
|
|
63
|
+
{...(isWeb ? undefined : { accessibilityLabel: name })}
|
|
64
64
|
data-elapsed-state={determinate ? "determinate" : showElapsed ? "elapsed" : "short"}
|
|
65
65
|
{...rowProps}
|
|
66
66
|
>
|
|
@@ -46,3 +46,20 @@ describe("SwipeDismissRow", () => {
|
|
|
46
46
|
expect(onDismiss).toHaveBeenCalledTimes(1);
|
|
47
47
|
});
|
|
48
48
|
});
|
|
49
|
+
|
|
50
|
+
function rnA11yAttributes(root: ParentNode): string[] {
|
|
51
|
+
return [...root.querySelectorAll("*")].flatMap((el) =>
|
|
52
|
+
el.getAttributeNames().filter((name) => name.startsWith("accessibility")),
|
|
53
|
+
);
|
|
54
|
+
}
|
|
55
|
+
|
|
56
|
+
describe("SwipeDismissRow web a11y (FZ-11156)", () => {
|
|
57
|
+
it("keeps the RN dismiss action off the DOM", () => {
|
|
58
|
+
const result = renderWithProviders(
|
|
59
|
+
<SwipeDismissRow onDismiss={() => {}} dismissLabel="Dismiss item">
|
|
60
|
+
<Text>Row</Text>
|
|
61
|
+
</SwipeDismissRow>,
|
|
62
|
+
);
|
|
63
|
+
expect(rnA11yAttributes(result.container)).toEqual([]);
|
|
64
|
+
});
|
|
65
|
+
});
|
|
@@ -17,7 +17,7 @@ import { XIcon } from "@phosphor-icons/react";
|
|
|
17
17
|
import { useMemo, useRef, useState, type ReactNode } from "react";
|
|
18
18
|
import { PanResponder } from "react-native";
|
|
19
19
|
import { useTranslation } from "react-i18next";
|
|
20
|
-
import { XStack, YStack } from "tamagui";
|
|
20
|
+
import { XStack, YStack, isWeb } from "tamagui";
|
|
21
21
|
|
|
22
22
|
/** Past this share of the row's width a release dismisses; short of it, the row springs back. */
|
|
23
23
|
export const SWIPE_DISMISS_COMMIT = 0.5;
|
|
@@ -103,12 +103,16 @@ export function SwipeDismissRow({
|
|
|
103
103
|
overflow="hidden"
|
|
104
104
|
testID={testID}
|
|
105
105
|
data-swipe-dismiss-row=""
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
106
|
+
{...(isWeb
|
|
107
|
+
? undefined
|
|
108
|
+
: {
|
|
109
|
+
accessibilityActions: disabled
|
|
110
|
+
? undefined
|
|
111
|
+
: [{ name: "dismiss", label: dismissLabel ?? t("Dismiss") }],
|
|
112
|
+
onAccessibilityAction: (e: { nativeEvent: { actionName: string } }) => {
|
|
113
|
+
if (e.nativeEvent.actionName === "dismiss") dismiss();
|
|
114
|
+
},
|
|
115
|
+
})}
|
|
112
116
|
onLayout={(e) => {
|
|
113
117
|
const next = e.nativeEvent.layout.width;
|
|
114
118
|
widthRef.current = next;
|
|
@@ -302,3 +302,28 @@ describe("DestructiveAction", () => {
|
|
|
302
302
|
expect(src).not.toMatch(/<input[\s>]/);
|
|
303
303
|
});
|
|
304
304
|
});
|
|
305
|
+
|
|
306
|
+
function rnA11yAttributes(root: ParentNode): string[] {
|
|
307
|
+
return [...root.querySelectorAll("*")].flatMap((el) =>
|
|
308
|
+
el.getAttributeNames().filter((name) => name.startsWith("accessibility")),
|
|
309
|
+
);
|
|
310
|
+
}
|
|
311
|
+
|
|
312
|
+
describe("DestructiveAction web a11y (FZ-11156)", () => {
|
|
313
|
+
it("labels the typed-confirm field with aria-label, never an RN accessibilityLabel attribute", async () => {
|
|
314
|
+
renderWithProviders(
|
|
315
|
+
<DestructiveAction
|
|
316
|
+
severity="high"
|
|
317
|
+
verb="Delete"
|
|
318
|
+
noun="project"
|
|
319
|
+
confirmationText="my-project"
|
|
320
|
+
onAction={vi.fn()}
|
|
321
|
+
/>,
|
|
322
|
+
);
|
|
323
|
+
fireEvent.click(screen.getByText("Delete project"));
|
|
324
|
+
await waitFor(() => expect(alertdialog()).toBeTruthy());
|
|
325
|
+
const input = alertdialog()?.querySelector("[data-mp-confirm-expected]");
|
|
326
|
+
expect(input?.getAttribute("aria-label")).toBe('Type "my-project" to confirm.');
|
|
327
|
+
expect(rnA11yAttributes(root())).toEqual([]);
|
|
328
|
+
});
|
|
329
|
+
});
|
|
@@ -8,7 +8,7 @@
|
|
|
8
8
|
import { Button, formatActionLabel, type ButtonProps } from "@multiplatform.one/forms";
|
|
9
9
|
import { useCallback, useState, type ReactNode } from "react";
|
|
10
10
|
import { useTranslation } from "../shared/i18n";
|
|
11
|
-
import { Input, YStack } from "tamagui";
|
|
11
|
+
import { Input, YStack, isWeb } from "tamagui";
|
|
12
12
|
import { ConfirmDialog } from "../feedback/ConfirmDialog";
|
|
13
13
|
import { withInterp } from "../shared/t";
|
|
14
14
|
import {
|
|
@@ -223,7 +223,9 @@ export function DestructiveAction({
|
|
|
223
223
|
autoCorrect={false}
|
|
224
224
|
spellCheck={false}
|
|
225
225
|
data-mp-confirm-expected=""
|
|
226
|
-
|
|
226
|
+
{...(isWeb
|
|
227
|
+
? { "aria-label": typedPrompt ?? undefined }
|
|
228
|
+
: { accessibilityLabel: typedPrompt ?? undefined })}
|
|
227
229
|
width="100%"
|
|
228
230
|
/>
|
|
229
231
|
</YStack>
|
|
@@ -8,7 +8,15 @@ import { TabBar } from "./TabBar";
|
|
|
8
8
|
const meta: Meta<typeof TabBar> = {
|
|
9
9
|
title: "Components/TabBar",
|
|
10
10
|
component: TabBar,
|
|
11
|
-
parameters: {
|
|
11
|
+
parameters: {
|
|
12
|
+
status: { type: "beta" },
|
|
13
|
+
layout: "fullscreen",
|
|
14
|
+
nativeGallery: {
|
|
15
|
+
scroll: false,
|
|
16
|
+
note: "On iOS, an app that declares its tabs through TabHost gets the system tab bar in this bar's place (FZ-8105). This is the bar every other platform draws.",
|
|
17
|
+
seeAlso: "Components/TabHost",
|
|
18
|
+
},
|
|
19
|
+
},
|
|
12
20
|
};
|
|
13
21
|
|
|
14
22
|
export default meta;
|
|
@@ -3,7 +3,7 @@ import type { SizeTokens, YStackProps as StackProps, TamaguiElement } from "tama
|
|
|
3
3
|
export type AccordionVariant = "plain" | "card";
|
|
4
4
|
export type AccordionType = "single" | "multiple";
|
|
5
5
|
interface AccordionCommonProps extends Omit<StackProps, "onChange" | "size"> {
|
|
6
|
-
/** Visual variant: "plain" =
|
|
6
|
+
/** Visual variant: "plain" = one framed group of trigger plates, "card" = each item on its own surface */
|
|
7
7
|
variant?: AccordionVariant;
|
|
8
8
|
/** Disable every item */
|
|
9
9
|
disabled?: boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/Accordion/index.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/Accordion/index.tsx"],"names":[],"mappings":"AAmBA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAavC,OAAO,KAAK,EAAE,UAAU,EAAE,WAAW,IAAI,UAAU,EAAE,cAAc,EAAE,MAAM,SAAS,CAAC;AAkBrF,MAAM,MAAM,gBAAgB,GAAG,OAAO,GAAG,MAAM,CAAC;AAChD,MAAM,MAAM,aAAa,GAAG,QAAQ,GAAG,UAAU,CAAC;AAElD,UAAU,oBAAqB,SAAQ,IAAI,CAAC,UAAU,EAAE,UAAU,GAAG,MAAM,CAAC;IAC1E,0GAA0G;IAC1G,OAAO,CAAC,EAAE,gBAAgB,CAAC;IAC3B,yBAAyB;IACzB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB;;;OAGG;IACH,IAAI,CAAC,EAAE,UAAU,CAAC;IAClB,QAAQ,CAAC,EAAE,SAAS,CAAC;CACtB;AAED,MAAM,WAAW,wBAAyB,SAAQ,oBAAoB;IACpE,6CAA6C;IAC7C,IAAI,CAAC,EAAE,QAAQ,CAAC;IAChB,6CAA6C;IAC7C,KAAK,CAAC,EAAE,MAAM,CAAC;IACf,2CAA2C;IAC3C,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,0DAA0D;IAC1D,aAAa,CAAC,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;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1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/ElapsedProgress/index.tsx"],"names":[],"mappings":"AASA,OAAO,EAA+B,KAAK,WAAW,EAAE,MAAM,SAAS,CAAC;AAIxE,MAAM,WAAW,oBAAqB,SAAQ,IAAI,CAAC,WAAW,EAAE,UAAU,CAAC;IACzE,kDAAkD;IAClD,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,oEAAoE;IACpE,QAAQ,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,2FAA2F;IAC3F,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,0DAA0D;IAC1D,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,2CAA2C;AAC3C,wBAAgB,aAAa,CAAC,EAAE,EAAE,MAAM,GAAG,MAAM,CAQhD;AAED,wBAAgB,eAAe,CAAC,EAC9B,SAAS,EACT,QAAQ,EACR,SAAgB,EAChB,KAAK,EACL,GAAG,QAAQ,EACZ,EAAE,oBAAoB,2CA+CtB"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/SwipeDismissRow/index.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAA6B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAKlE,iGAAiG;AACjG,eAAO,MAAM,oBAAoB,MAAM,CAAC;AAOxC,MAAM,MAAM,mBAAmB,GAAG,SAAS,GAAG,MAAM,CAAC;AAErD,4FAA4F;AAC5F,wBAAgB,mBAAmB,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,mBAAmB,CAGlF;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,EAAE,SAAS,CAAC;IACpB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,6DAA6D;IAC7D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,mFAAmF;IACnF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,QAAQ,EACR,aAAa,EACb,MAAM,GACP,EAAE,QAAQ,CAAC,oBAAoB,CAAC,
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/SwipeDismissRow/index.tsx"],"names":[],"mappings":"AAgBA,OAAO,EAA6B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAKlE,iGAAiG;AACjG,eAAO,MAAM,oBAAoB,MAAM,CAAC;AAOxC,MAAM,MAAM,mBAAmB,GAAG,SAAS,GAAG,MAAM,CAAC;AAErD,4FAA4F;AAC5F,wBAAgB,mBAAmB,CAAC,EAAE,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,mBAAmB,CAGlF;AAED,MAAM,WAAW,oBAAoB;IACnC,QAAQ,EAAE,SAAS,CAAC;IACpB,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB,6DAA6D;IAC7D,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,mFAAmF;IACnF,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB;AAED,wBAAgB,eAAe,CAAC,EAC9B,QAAQ,EACR,SAAS,EACT,YAAY,EACZ,QAAQ,EACR,aAAa,EACb,MAAM,GACP,EAAE,QAAQ,CAAC,oBAAoB,CAAC,2CAkGhC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DestructiveAction.d.ts","sourceRoot":"","sources":["../../src/actions/DestructiveAction.tsx"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAA6B,KAAK,WAAW,EAAE,MAAM,0BAA0B,CAAC;AACvF,OAAO,EAAyB,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;A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