@xsolla/xui-tag 0.158.0 → 0.159.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/README.md +109 -87
- package/native/index.d.mts +2 -0
- package/native/index.d.ts +2 -0
- package/native/index.js +13 -3
- package/native/index.js.map +1 -1
- package/native/index.mjs +13 -3
- package/native/index.mjs.map +1 -1
- package/package.json +4 -4
- package/web/index.d.mts +2 -0
- package/web/index.d.ts +2 -0
- package/web/index.js +13 -3
- package/web/index.js.map +1 -1
- package/web/index.mjs +13 -3
- package/web/index.mjs.map +1 -1
package/README.md
CHANGED
|
@@ -13,12 +13,12 @@ npm install @xsolla/xui-tag
|
|
|
13
13
|
### Basic Tag
|
|
14
14
|
|
|
15
15
|
```tsx
|
|
16
|
-
import * as React from
|
|
17
|
-
import { Tag } from
|
|
16
|
+
import * as React from "react";
|
|
17
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
18
18
|
|
|
19
19
|
export default function BasicTag() {
|
|
20
20
|
return (
|
|
21
|
-
<div style={{ display:
|
|
21
|
+
<div style={{ display: "flex", gap: 8 }}>
|
|
22
22
|
<Tag>Default</Tag>
|
|
23
23
|
<Tag tone="brand">Brand</Tag>
|
|
24
24
|
<Tag tone="success">Success</Tag>
|
|
@@ -30,12 +30,12 @@ export default function BasicTag() {
|
|
|
30
30
|
### Tag Tones
|
|
31
31
|
|
|
32
32
|
```tsx
|
|
33
|
-
import * as React from
|
|
34
|
-
import { Tag } from
|
|
33
|
+
import * as React from "react";
|
|
34
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
35
35
|
|
|
36
36
|
export default function TagTones() {
|
|
37
37
|
return (
|
|
38
|
-
<div style={{ display:
|
|
38
|
+
<div style={{ display: "flex", gap: 8, flexWrap: "wrap" }}>
|
|
39
39
|
<Tag tone="primary">Primary</Tag>
|
|
40
40
|
<Tag tone="brand">Brand</Tag>
|
|
41
41
|
<Tag tone="brandExtra">Brand Extra</Tag>
|
|
@@ -51,12 +51,12 @@ export default function TagTones() {
|
|
|
51
51
|
### Tag Sizes
|
|
52
52
|
|
|
53
53
|
```tsx
|
|
54
|
-
import * as React from
|
|
55
|
-
import { Tag } from
|
|
54
|
+
import * as React from "react";
|
|
55
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
56
56
|
|
|
57
57
|
export default function TagSizes() {
|
|
58
58
|
return (
|
|
59
|
-
<div style={{ display:
|
|
59
|
+
<div style={{ display: "flex", gap: 8, alignItems: "center" }}>
|
|
60
60
|
<Tag size="xs">Extra Small</Tag>
|
|
61
61
|
<Tag size="sm">Small</Tag>
|
|
62
62
|
<Tag size="md">Medium</Tag>
|
|
@@ -70,14 +70,18 @@ export default function TagSizes() {
|
|
|
70
70
|
### Solid vs Outlined
|
|
71
71
|
|
|
72
72
|
```tsx
|
|
73
|
-
import * as React from
|
|
74
|
-
import { Tag } from
|
|
73
|
+
import * as React from "react";
|
|
74
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
75
75
|
|
|
76
76
|
export default function TagTypes() {
|
|
77
77
|
return (
|
|
78
|
-
<div style={{ display:
|
|
79
|
-
<Tag tone="brand" type="solid">
|
|
80
|
-
|
|
78
|
+
<div style={{ display: "flex", gap: 8 }}>
|
|
79
|
+
<Tag tone="brand" type="solid">
|
|
80
|
+
Solid
|
|
81
|
+
</Tag>
|
|
82
|
+
<Tag tone="brand" type="outlined">
|
|
83
|
+
Outlined
|
|
84
|
+
</Tag>
|
|
81
85
|
</div>
|
|
82
86
|
);
|
|
83
87
|
}
|
|
@@ -86,17 +90,27 @@ export default function TagTypes() {
|
|
|
86
90
|
### Tag with Icons
|
|
87
91
|
|
|
88
92
|
```tsx
|
|
89
|
-
import * as React from
|
|
90
|
-
import { Tag } from
|
|
91
|
-
import { Check } from
|
|
92
|
-
import { Star, Clock } from
|
|
93
|
+
import * as React from "react";
|
|
94
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
95
|
+
import { Check } from "@xsolla/xui-icons";
|
|
96
|
+
import { Star, Clock } from "@xsolla/xui-icons-base";
|
|
93
97
|
|
|
94
98
|
export default function TagWithIcon() {
|
|
95
99
|
return (
|
|
96
|
-
<div style={{ display:
|
|
97
|
-
<Tag iconLeft={<Star size={12} />} tone="warning">
|
|
98
|
-
|
|
99
|
-
|
|
100
|
+
<div style={{ display: "flex", gap: 8 }}>
|
|
101
|
+
<Tag iconLeft={<Star size={12} />} tone="warning">
|
|
102
|
+
Featured
|
|
103
|
+
</Tag>
|
|
104
|
+
<Tag iconLeft={<Check size={12} />} tone="success">
|
|
105
|
+
Verified
|
|
106
|
+
</Tag>
|
|
107
|
+
<Tag
|
|
108
|
+
iconLeft={<Clock size={12} />}
|
|
109
|
+
iconRight={<Star size={12} />}
|
|
110
|
+
tone="neutral"
|
|
111
|
+
>
|
|
112
|
+
Pending
|
|
113
|
+
</Tag>
|
|
100
114
|
</div>
|
|
101
115
|
);
|
|
102
116
|
}
|
|
@@ -105,9 +119,9 @@ export default function TagWithIcon() {
|
|
|
105
119
|
### Icon-Only Tag
|
|
106
120
|
|
|
107
121
|
```tsx
|
|
108
|
-
import * as React from
|
|
109
|
-
import { Tag } from
|
|
110
|
-
import { Check } from
|
|
122
|
+
import * as React from "react";
|
|
123
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
124
|
+
import { Check } from "@xsolla/xui-icons";
|
|
111
125
|
|
|
112
126
|
export default function IconOnlyTag() {
|
|
113
127
|
return <Tag iconLeft={<Check size={12} />} tone="success" />;
|
|
@@ -117,19 +131,24 @@ export default function IconOnlyTag() {
|
|
|
117
131
|
### Removable Tag
|
|
118
132
|
|
|
119
133
|
```tsx
|
|
120
|
-
import * as React from
|
|
121
|
-
import { Tag } from
|
|
134
|
+
import * as React from "react";
|
|
135
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
122
136
|
|
|
123
137
|
export default function RemovableTag() {
|
|
124
|
-
const [tags, setTags] = React.useState([
|
|
138
|
+
const [tags, setTags] = React.useState([
|
|
139
|
+
"React",
|
|
140
|
+
"TypeScript",
|
|
141
|
+
"Node.js",
|
|
142
|
+
"GraphQL",
|
|
143
|
+
]);
|
|
125
144
|
|
|
126
145
|
const removeTag = (tagToRemove: string) => {
|
|
127
|
-
setTags(tags.filter(tag => tag !== tagToRemove));
|
|
146
|
+
setTags(tags.filter((tag) => tag !== tagToRemove));
|
|
128
147
|
};
|
|
129
148
|
|
|
130
149
|
return (
|
|
131
|
-
<div style={{ display:
|
|
132
|
-
{tags.map(tag => (
|
|
150
|
+
<div style={{ display: "flex", gap: 8, flexWrap: "wrap" }}>
|
|
151
|
+
{tags.map((tag) => (
|
|
133
152
|
<Tag key={tag} tone="brand" onRemove={() => removeTag(tag)}>
|
|
134
153
|
{tag}
|
|
135
154
|
</Tag>
|
|
@@ -144,18 +163,18 @@ export default function RemovableTag() {
|
|
|
144
163
|
Import the component and use it directly:
|
|
145
164
|
|
|
146
165
|
```jsx
|
|
147
|
-
import { Tag } from
|
|
166
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
148
167
|
|
|
149
168
|
<Tag
|
|
150
|
-
size="md"
|
|
151
|
-
tone="brand"
|
|
152
|
-
type="solid"
|
|
153
|
-
iconLeft={<Icon />}
|
|
154
|
-
iconRight={<Icon />}
|
|
155
|
-
onRemove={handleRemove}
|
|
169
|
+
size="md" // Size variant
|
|
170
|
+
tone="brand" // Color tone
|
|
171
|
+
type="solid" // Solid or outlined
|
|
172
|
+
iconLeft={<Icon />} // Optional leading icon
|
|
173
|
+
iconRight={<Icon />} // Optional trailing icon
|
|
174
|
+
onRemove={handleRemove} // Makes tag removable (renders X icon)
|
|
156
175
|
>
|
|
157
176
|
Tag Label
|
|
158
|
-
</Tag
|
|
177
|
+
</Tag>;
|
|
159
178
|
```
|
|
160
179
|
|
|
161
180
|
## Examples
|
|
@@ -163,20 +182,20 @@ import { Tag } from '@xsolla/xui-tag';
|
|
|
163
182
|
### Category Tags
|
|
164
183
|
|
|
165
184
|
```tsx
|
|
166
|
-
import * as React from
|
|
167
|
-
import { Tag } from
|
|
185
|
+
import * as React from "react";
|
|
186
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
168
187
|
|
|
169
188
|
export default function CategoryTags() {
|
|
170
189
|
const categories = [
|
|
171
|
-
{ name:
|
|
172
|
-
{ name:
|
|
173
|
-
{ name:
|
|
174
|
-
{ name:
|
|
190
|
+
{ name: "Technology", tone: "brand" as const },
|
|
191
|
+
{ name: "Design", tone: "brandExtra" as const },
|
|
192
|
+
{ name: "Marketing", tone: "success" as const },
|
|
193
|
+
{ name: "Sales", tone: "warning" as const },
|
|
175
194
|
];
|
|
176
195
|
|
|
177
196
|
return (
|
|
178
|
-
<div style={{ display:
|
|
179
|
-
{categories.map(cat => (
|
|
197
|
+
<div style={{ display: "flex", gap: 8 }}>
|
|
198
|
+
{categories.map((cat) => (
|
|
180
199
|
<Tag key={cat.name} tone={cat.tone} size="sm">
|
|
181
200
|
{cat.name}
|
|
182
201
|
</Tag>
|
|
@@ -189,13 +208,13 @@ export default function CategoryTags() {
|
|
|
189
208
|
### Status Tags
|
|
190
209
|
|
|
191
210
|
```tsx
|
|
192
|
-
import * as React from
|
|
193
|
-
import { Tag } from
|
|
194
|
-
import { CheckCircle, Clock, XCircle } from
|
|
211
|
+
import * as React from "react";
|
|
212
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
213
|
+
import { CheckCircle, Clock, XCircle } from "@xsolla/xui-icons-base";
|
|
195
214
|
|
|
196
215
|
export default function StatusTags() {
|
|
197
216
|
return (
|
|
198
|
-
<div style={{ display:
|
|
217
|
+
<div style={{ display: "flex", gap: 8 }}>
|
|
199
218
|
<Tag iconLeft={<CheckCircle size={12} />} tone="success">
|
|
200
219
|
Completed
|
|
201
220
|
</Tag>
|
|
@@ -213,29 +232,31 @@ export default function StatusTags() {
|
|
|
213
232
|
### Tag Input
|
|
214
233
|
|
|
215
234
|
```tsx
|
|
216
|
-
import * as React from
|
|
217
|
-
import { Tag } from
|
|
218
|
-
import { Input } from
|
|
235
|
+
import * as React from "react";
|
|
236
|
+
import { Tag } from "@xsolla/xui-tag";
|
|
237
|
+
import { Input } from "@xsolla/xui-input";
|
|
219
238
|
|
|
220
239
|
export default function TagInput() {
|
|
221
|
-
const [tags, setTags] = React.useState([
|
|
222
|
-
const [inputValue, setInputValue] = React.useState(
|
|
240
|
+
const [tags, setTags] = React.useState(["react", "typescript"]);
|
|
241
|
+
const [inputValue, setInputValue] = React.useState("");
|
|
223
242
|
|
|
224
243
|
const addTag = () => {
|
|
225
244
|
if (inputValue.trim() && !tags.includes(inputValue.trim())) {
|
|
226
245
|
setTags([...tags, inputValue.trim()]);
|
|
227
|
-
setInputValue(
|
|
246
|
+
setInputValue("");
|
|
228
247
|
}
|
|
229
248
|
};
|
|
230
249
|
|
|
231
250
|
return (
|
|
232
251
|
<div>
|
|
233
|
-
<div
|
|
234
|
-
{
|
|
252
|
+
<div
|
|
253
|
+
style={{ display: "flex", gap: 8, flexWrap: "wrap", marginBottom: 8 }}
|
|
254
|
+
>
|
|
255
|
+
{tags.map((tag) => (
|
|
235
256
|
<Tag
|
|
236
257
|
key={tag}
|
|
237
258
|
tone="primary"
|
|
238
|
-
onRemove={() => setTags(tags.filter(t => t !== tag))}
|
|
259
|
+
onRemove={() => setTags(tags.filter((t) => t !== tag))}
|
|
239
260
|
>
|
|
240
261
|
{tag}
|
|
241
262
|
</Tag>
|
|
@@ -245,7 +266,7 @@ export default function TagInput() {
|
|
|
245
266
|
value={inputValue}
|
|
246
267
|
onChangeText={setInputValue}
|
|
247
268
|
placeholder="Add a tag..."
|
|
248
|
-
onKeyDown={(e) => e.key ===
|
|
269
|
+
onKeyDown={(e) => e.key === "Enter" && addTag()}
|
|
249
270
|
/>
|
|
250
271
|
</div>
|
|
251
272
|
);
|
|
@@ -260,39 +281,40 @@ A tag/chip component.
|
|
|
260
281
|
|
|
261
282
|
**Tag Props:**
|
|
262
283
|
|
|
263
|
-
| Prop
|
|
264
|
-
|
|
|
265
|
-
|
|
|
266
|
-
|
|
|
267
|
-
|
|
|
268
|
-
|
|
|
269
|
-
|
|
|
270
|
-
|
|
|
271
|
-
|
|
|
284
|
+
| Prop | Type | Default | Description |
|
|
285
|
+
| :-------- | :--------------------------------------------------------------------------------------- | :---------- | :------------------------------------------------------------------------------------------------------------ |
|
|
286
|
+
| `testID` | `string` | — | Test ID for testing frameworks. On web this renders as `data-testid`; on React Native it renders as `testID`. |
|
|
287
|
+
| children | `ReactNode` | - | Tag content. Optional for icon-only tags. |
|
|
288
|
+
| size | `"xl" \| "lg" \| "md" \| "sm" \| "xs"` | `"md"` | Size of the tag. |
|
|
289
|
+
| tone | `"primary" \| "brand" \| "brandExtra" \| "success" \| "warning" \| "alert" \| "neutral"` | `"primary"` | Color tone. |
|
|
290
|
+
| type | `"solid" \| "outlined"` | `"solid"` | Visual type. Solid fills background; outlined uses a border with lighter background. |
|
|
291
|
+
| iconLeft | `ReactNode` | - | Leading icon. |
|
|
292
|
+
| iconRight | `ReactNode` | - | Trailing icon. |
|
|
293
|
+
| onRemove | `() => void` | - | Callback for remove button. Renders an X icon in the trailing position. |
|
|
272
294
|
|
|
273
295
|
**Solid Tone Color Mapping:**
|
|
274
296
|
|
|
275
|
-
| Tone
|
|
276
|
-
|
|
|
277
|
-
| primary
|
|
278
|
-
| brand
|
|
279
|
-
| brandExtra | BrandExtra primary | On brandExtra
|
|
280
|
-
| success
|
|
281
|
-
| warning
|
|
282
|
-
| alert
|
|
283
|
-
| neutral
|
|
297
|
+
| Tone | Background | Text |
|
|
298
|
+
| :--------- | :----------------- | :-------------- |
|
|
299
|
+
| primary | Background primary | Content primary |
|
|
300
|
+
| brand | Brand primary | On brand |
|
|
301
|
+
| brandExtra | BrandExtra primary | On brandExtra |
|
|
302
|
+
| success | Success primary | On success |
|
|
303
|
+
| warning | Warning primary | On warning |
|
|
304
|
+
| alert | Alert primary | On alert |
|
|
305
|
+
| neutral | Neutral primary | On neutral |
|
|
284
306
|
|
|
285
307
|
**Outlined Tone Color Mapping:**
|
|
286
308
|
|
|
287
|
-
| Tone
|
|
288
|
-
|
|
|
289
|
-
| primary
|
|
290
|
-
| brand
|
|
309
|
+
| Tone | Background | Border | Text |
|
|
310
|
+
| :--------- | :------------------- | :---------------- | :------------------------- |
|
|
311
|
+
| primary | Background primary | Border secondary | Content primary |
|
|
312
|
+
| brand | Brand secondary | Border brand | Content brand primary |
|
|
291
313
|
| brandExtra | BrandExtra secondary | Border brandExtra | Content brandExtra primary |
|
|
292
|
-
| success
|
|
293
|
-
| warning
|
|
294
|
-
| alert
|
|
295
|
-
| neutral
|
|
314
|
+
| success | Success secondary | Border success | Content success primary |
|
|
315
|
+
| warning | Warning secondary | Border warning | Content warning primary |
|
|
316
|
+
| alert | Alert secondary | Border alert | Content alert primary |
|
|
317
|
+
| neutral | Neutral secondary | Border neutral | Content neutral primary |
|
|
296
318
|
|
|
297
319
|
## Accessibility
|
|
298
320
|
|
package/native/index.d.mts
CHANGED
|
@@ -16,6 +16,8 @@ interface TagProps extends ThemeOverrideProps {
|
|
|
16
16
|
iconRight?: ReactNode;
|
|
17
17
|
/** Callback when the remove (X) icon is clicked */
|
|
18
18
|
onRemove?: () => void;
|
|
19
|
+
/** Test ID for testing frameworks */
|
|
20
|
+
testID?: string;
|
|
19
21
|
}
|
|
20
22
|
declare const Tag: React.FC<TagProps>;
|
|
21
23
|
|
package/native/index.d.ts
CHANGED
|
@@ -16,6 +16,8 @@ interface TagProps extends ThemeOverrideProps {
|
|
|
16
16
|
iconRight?: ReactNode;
|
|
17
17
|
/** Callback when the remove (X) icon is clicked */
|
|
18
18
|
onRemove?: () => void;
|
|
19
|
+
/** Test ID for testing frameworks */
|
|
20
|
+
testID?: string;
|
|
19
21
|
}
|
|
20
22
|
declare const Tag: React.FC<TagProps>;
|
|
21
23
|
|
package/native/index.js
CHANGED
|
@@ -235,6 +235,8 @@ var Text = ({
|
|
|
235
235
|
numberOfLines,
|
|
236
236
|
id,
|
|
237
237
|
role,
|
|
238
|
+
testID,
|
|
239
|
+
"data-testid": dataTestId,
|
|
238
240
|
style: styleProp,
|
|
239
241
|
...props
|
|
240
242
|
}) => {
|
|
@@ -264,7 +266,7 @@ var Text = ({
|
|
|
264
266
|
{
|
|
265
267
|
style: baseStyle,
|
|
266
268
|
numberOfLines,
|
|
267
|
-
testID: id,
|
|
269
|
+
testID: dataTestId || testID || id,
|
|
268
270
|
accessibilityRole,
|
|
269
271
|
children
|
|
270
272
|
}
|
|
@@ -275,7 +277,13 @@ var Text = ({
|
|
|
275
277
|
var import_react = __toESM(require("react"));
|
|
276
278
|
var import_react_native3 = require("react-native");
|
|
277
279
|
var import_jsx_runtime3 = require("react/jsx-runtime");
|
|
278
|
-
var Icon = ({
|
|
280
|
+
var Icon = ({
|
|
281
|
+
children,
|
|
282
|
+
color,
|
|
283
|
+
size,
|
|
284
|
+
testID,
|
|
285
|
+
"data-testid": dataTestId
|
|
286
|
+
}) => {
|
|
279
287
|
const style = {
|
|
280
288
|
width: typeof size === "number" ? size : void 0,
|
|
281
289
|
height: typeof size === "number" ? size : void 0,
|
|
@@ -292,7 +300,7 @@ var Icon = ({ children, color, size }) => {
|
|
|
292
300
|
}
|
|
293
301
|
return child;
|
|
294
302
|
});
|
|
295
|
-
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native3.View, { style, children: childrenWithProps });
|
|
303
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(import_react_native3.View, { style, testID: dataTestId || testID, children: childrenWithProps });
|
|
296
304
|
};
|
|
297
305
|
|
|
298
306
|
// src/Tag.tsx
|
|
@@ -307,6 +315,7 @@ var Tag = ({
|
|
|
307
315
|
iconLeft,
|
|
308
316
|
iconRight,
|
|
309
317
|
onRemove,
|
|
318
|
+
testID,
|
|
310
319
|
themeMode,
|
|
311
320
|
themeProductContext
|
|
312
321
|
}) => {
|
|
@@ -370,6 +379,7 @@ var Tag = ({
|
|
|
370
379
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
371
380
|
Box,
|
|
372
381
|
{
|
|
382
|
+
testID,
|
|
373
383
|
backgroundColor: bg,
|
|
374
384
|
borderRadius: sizeStyles.radius,
|
|
375
385
|
height: sizeStyles.height,
|
package/native/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.tsx","../../../../foundation/primitives-native/src/Box.tsx","../../../../foundation/primitives-native/src/Text.tsx","../../../../foundation/primitives-native/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["export * from \"./Tag\";\n","import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n minWidth: minWidth as DimensionValue,\n minHeight: minHeight as DimensionValue,\n maxWidth: maxWidth as DimensionValue,\n maxHeight: maxHeight as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color: color ?? incomingStyle?.color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React from \"react\";\nimport { View, ViewStyle } from \"react-native\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Icon: React.FC<IconProps> = ({ children, color, size }) => {\n const style: ViewStyle = {\n width: typeof size === \"number\" ? size : undefined,\n height: typeof size === \"number\" ? size : undefined,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n\n // On native, we try to pass the color down to children (like Text primitives)\n // to mimic the CSS inheritance behavior of the web version.\n const childrenWithProps = React.Children.map(children, (child) => {\n if (React.isValidElement(child)) {\n return React.cloneElement(child, {\n color: child.props.color || color,\n // Also pass size if child seems to be an icon that needs it\n size: child.props.size || size,\n });\n }\n return child;\n });\n\n return <View style={style}>{childrenWithProps}</View>;\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACCA,0BAQO;AA2ID;AAxIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,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A,MACX,gBAAe;AAAA,MACf,KAAK,WAAW;AAAA,MAChB,aAAa,WAAW;AAAA,MACxB,aAAa;AAAA,MACb,aAAY;AAAA,MACZ,OAAO;AAAA,QACL,UAAU;AAAA,QACV,cAAc;AAAA,QACd,YAAY;AAAA,MACd;AAAA,MAEC;AAAA,oBACC,6CAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,oBACH;AAAA,QAGD,YACC;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,UAAU,WAAW;AAAA,YACrB,YAAW;AAAA,YACX,YAAW;AAAA,YACX,OAAO;AAAA,cACL,UAAU;AAAA,cACV,cAAc;AAAA,YAChB;AAAA,YAEC;AAAA;AAAA,QACH;AAAA,QAGD,aACC,6CAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,qBACH;AAAA,QAGD,YACC,6CAAC,OAAI,SAAS,UACZ,uDAAC,sBAAE,MAAM,WAAW,UAAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["import_react_native","import_jsx_runtime","RNText","import_react_native","import_jsx_runtime","React","import_jsx_runtime"]}
|
|
1
|
+
{"version":3,"sources":["../../src/index.tsx","../../../../foundation/primitives-native/src/Box.tsx","../../../../foundation/primitives-native/src/Text.tsx","../../../../foundation/primitives-native/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["export * from \"./Tag\";\n","import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n minWidth: minWidth as DimensionValue,\n minHeight: minHeight as DimensionValue,\n maxWidth: maxWidth as DimensionValue,\n maxHeight: maxHeight as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color: color ?? incomingStyle?.color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={dataTestId || testID || id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React from \"react\";\nimport { View, ViewStyle } from \"react-native\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Icon: React.FC<IconProps> = ({\n children,\n color,\n size,\n testID,\n \"data-testid\": dataTestId,\n}) => {\n const style: ViewStyle = {\n width: typeof size === \"number\" ? size : undefined,\n height: typeof size === \"number\" ? size : undefined,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n\n // On native, we try to pass the color down to children (like Text primitives)\n // to mimic the CSS inheritance behavior of the web version.\n const childrenWithProps = React.Children.map(children, (child) => {\n if (React.isValidElement(child)) {\n return React.cloneElement(child, {\n color: child.props.color || color,\n // Also pass size if child seems to be an icon that needs it\n size: child.props.size || size,\n });\n }\n return child;\n });\n\n return (\n <View style={style} testID={dataTestId || testID}>\n {childrenWithProps}\n </View>\n );\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n /** Test ID for testing frameworks */\n testID?: string;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n testID={testID}\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACCA,0BAQO;AA2ID;AAxIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,eAAe;AAAA,EACf;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,oBAAoB,CAAC,aAAkC;AAAA,IAC3D,iBACE,WAAW,YAAY,kBACnB,WAAW,kBACX;AAAA,IACN;AAAA,IACA;AAAA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A,YAEC;AAAA;AAAA,QACH;AAAA,QAGD,aACC,6CAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,qBACH;AAAA,QAGD,YACC,6CAAC,OAAI,SAAS,UACZ,uDAAC,sBAAE,MAAM,WAAW,UAAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["import_react_native","import_jsx_runtime","RNText","import_react_native","import_jsx_runtime","React","import_jsx_runtime"]}
|
package/native/index.mjs
CHANGED
|
@@ -206,6 +206,8 @@ var Text = ({
|
|
|
206
206
|
numberOfLines,
|
|
207
207
|
id,
|
|
208
208
|
role,
|
|
209
|
+
testID,
|
|
210
|
+
"data-testid": dataTestId,
|
|
209
211
|
style: styleProp,
|
|
210
212
|
...props
|
|
211
213
|
}) => {
|
|
@@ -235,7 +237,7 @@ var Text = ({
|
|
|
235
237
|
{
|
|
236
238
|
style: baseStyle,
|
|
237
239
|
numberOfLines,
|
|
238
|
-
testID: id,
|
|
240
|
+
testID: dataTestId || testID || id,
|
|
239
241
|
accessibilityRole,
|
|
240
242
|
children
|
|
241
243
|
}
|
|
@@ -246,7 +248,13 @@ var Text = ({
|
|
|
246
248
|
import React from "react";
|
|
247
249
|
import { View as View2 } from "react-native";
|
|
248
250
|
import { jsx as jsx3 } from "react/jsx-runtime";
|
|
249
|
-
var Icon = ({
|
|
251
|
+
var Icon = ({
|
|
252
|
+
children,
|
|
253
|
+
color,
|
|
254
|
+
size,
|
|
255
|
+
testID,
|
|
256
|
+
"data-testid": dataTestId
|
|
257
|
+
}) => {
|
|
250
258
|
const style = {
|
|
251
259
|
width: typeof size === "number" ? size : void 0,
|
|
252
260
|
height: typeof size === "number" ? size : void 0,
|
|
@@ -263,7 +271,7 @@ var Icon = ({ children, color, size }) => {
|
|
|
263
271
|
}
|
|
264
272
|
return child;
|
|
265
273
|
});
|
|
266
|
-
return /* @__PURE__ */ jsx3(View2, { style, children: childrenWithProps });
|
|
274
|
+
return /* @__PURE__ */ jsx3(View2, { style, testID: dataTestId || testID, children: childrenWithProps });
|
|
267
275
|
};
|
|
268
276
|
|
|
269
277
|
// src/Tag.tsx
|
|
@@ -278,6 +286,7 @@ var Tag = ({
|
|
|
278
286
|
iconLeft,
|
|
279
287
|
iconRight,
|
|
280
288
|
onRemove,
|
|
289
|
+
testID,
|
|
281
290
|
themeMode,
|
|
282
291
|
themeProductContext
|
|
283
292
|
}) => {
|
|
@@ -341,6 +350,7 @@ var Tag = ({
|
|
|
341
350
|
return /* @__PURE__ */ jsxs(
|
|
342
351
|
Box,
|
|
343
352
|
{
|
|
353
|
+
testID,
|
|
344
354
|
backgroundColor: bg,
|
|
345
355
|
borderRadius: sizeStyles.radius,
|
|
346
356
|
height: sizeStyles.height,
|
package/native/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../foundation/primitives-native/src/Box.tsx","../../../../foundation/primitives-native/src/Text.tsx","../../../../foundation/primitives-native/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n minWidth: minWidth as DimensionValue,\n minHeight: minHeight as DimensionValue,\n maxWidth: maxWidth as DimensionValue,\n maxHeight: maxHeight as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color: color ?? incomingStyle?.color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React from \"react\";\nimport { View, ViewStyle } from \"react-native\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Icon: React.FC<IconProps> = ({ children, color, size }) => {\n const style: ViewStyle = {\n width: typeof size === \"number\" ? size : undefined,\n height: typeof size === \"number\" ? size : undefined,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n\n // On native, we try to pass the color down to children (like Text primitives)\n // to mimic the CSS inheritance behavior of the web version.\n const childrenWithProps = React.Children.map(children, (child) => {\n if (React.isValidElement(child)) {\n return React.cloneElement(child, {\n color: child.props.color || color,\n // Also pass size if child seems to be an icon that needs it\n size: child.props.size || size,\n });\n }\n return child;\n });\n\n return <View style={style}>{childrenWithProps}</View>;\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";AACA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OAKK;AA2ID;AAxIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,eAAe;AAAA,EACf;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA,GAAG;AACL,MAAM;AACJ,QAAM,oBAAoB,CAAC,aAAkC;AAAA,IAC3D,iBACE,WAAW,YAAY,kBACnB,WAAW,kBACX;AAAA,IACN;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA,GAAI;AAAA,EACN;AAEA,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AAE,IAAI,MAAM,OAAO,IAAI,cAAc;AAC3C,QAAM,aAAa,CAAC,aAAa,CAAC,CAAC,YAAY,CAAC,CAAC;AAEjD,SACE;AAAA,IAAC;AAAA;AAAA,MACC,iBAAiB;AAAA,MACjB,cAAc,WAAW;AAAA,MACzB,QAAQ,WAAW;AAAA,MACnB,OAAO,aAAa,WAAW,SAAS;AAAA,MACxC,mBAAmB,aAAa,IAAI,WAAW;AAAA,MAC/C,eAAc;AAAA,MACd,YAAW;AAAA,MACX,gBAAe;AAAA,MACf,KAAK,WAAW;AAAA,MAChB,aAAa,WAAW;AAAA,MACxB,aAAa;AAAA,MACb,aAAY;AAAA,MACZ,OAAO;AAAA,QACL,UAAU;AAAA,QACV,cAAc;AAAA,QACd,YAAY;AAAA,MACd;AAAA,MAEC;AAAA,oBACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,oBACH;AAAA,QAGD,YACC,gBAAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,UAAU,WAAW;AAAA,YACrB,YAAW;AAAA,YACX,YAAW;AAAA,YACX,OAAO;AAAA,cACL,UAAU;AAAA,cACV,cAAc;AAAA,YAChB;AAAA,YAEC;AAAA;AAAA,QACH;AAAA,QAGD,aACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,qBACH;AAAA,QAGD,YACC,gBAAAA,KAAC,OAAI,SAAS,UACZ,0BAAAA,KAAC,KAAE,MAAM,WAAW,UAAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["jsx","View","jsx","jsx"]}
|
|
1
|
+
{"version":3,"sources":["../../../../foundation/primitives-native/src/Box.tsx","../../../../foundation/primitives-native/src/Text.tsx","../../../../foundation/primitives-native/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["import React from \"react\";\nimport {\n View,\n Pressable,\n Image,\n ViewStyle,\n ImageStyle,\n DimensionValue,\n AnimatableNumericValue,\n} from \"react-native\";\nimport { BoxProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Box: React.FC<BoxProps> = ({\n children,\n onPress,\n onLayout,\n onMoveShouldSetResponder,\n onResponderGrant,\n onResponderMove,\n onResponderRelease,\n onResponderTerminate,\n backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius,\n borderStyle,\n height,\n padding,\n paddingHorizontal,\n paddingVertical,\n margin,\n marginTop,\n marginBottom,\n marginLeft,\n marginRight,\n flexDirection,\n alignItems,\n justifyContent,\n position,\n top,\n bottom,\n left,\n right,\n width,\n minWidth,\n minHeight,\n maxWidth,\n maxHeight,\n flex,\n overflow,\n zIndex,\n hoverStyle,\n pressStyle,\n style,\n \"data-testid\": dataTestId,\n testID,\n as,\n src,\n alt,\n ...rest\n}) => {\n const getContainerStyle = (pressed?: boolean): ViewStyle => ({\n backgroundColor:\n pressed && pressStyle?.backgroundColor\n ? pressStyle.backgroundColor\n : backgroundColor,\n borderColor,\n borderWidth,\n borderBottomWidth,\n borderBottomColor,\n borderTopWidth,\n borderTopColor,\n borderLeftWidth,\n borderLeftColor,\n borderRightWidth,\n borderRightColor,\n borderRadius: borderRadius as AnimatableNumericValue,\n borderStyle: borderStyle as ViewStyle[\"borderStyle\"],\n overflow,\n zIndex,\n height: height as DimensionValue,\n width: width as DimensionValue,\n minWidth: minWidth as DimensionValue,\n minHeight: minHeight as DimensionValue,\n maxWidth: maxWidth as DimensionValue,\n maxHeight: maxHeight as DimensionValue,\n padding: padding as DimensionValue,\n paddingHorizontal: paddingHorizontal as DimensionValue,\n paddingVertical: paddingVertical as DimensionValue,\n margin: margin as DimensionValue,\n marginTop: marginTop as DimensionValue,\n marginBottom: marginBottom as DimensionValue,\n marginLeft: marginLeft as DimensionValue,\n marginRight: marginRight as DimensionValue,\n flexDirection,\n alignItems,\n justifyContent,\n position: position as ViewStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n flex,\n ...(style as ViewStyle),\n });\n\n const finalTestID = dataTestId || testID;\n\n // Destructure and drop web-only props from rest before passing to RN components\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n const {\n role,\n tabIndex,\n onKeyDown,\n onKeyUp,\n \"aria-label\": _ariaLabel,\n \"aria-labelledby\": _ariaLabelledBy,\n \"aria-current\": _ariaCurrent,\n \"aria-disabled\": _ariaDisabled,\n \"aria-live\": _ariaLive,\n className,\n \"data-testid\": _dataTestId,\n ...nativeRest\n } = rest as Record<string, unknown>;\n\n // Handle as=\"img\" for React Native\n if (as === \"img\" && src) {\n const imageStyle: ImageStyle = {\n width: width as DimensionValue,\n height: height as DimensionValue,\n borderRadius: borderRadius as number,\n position: position as ImageStyle[\"position\"],\n top: top as DimensionValue,\n bottom: bottom as DimensionValue,\n left: left as DimensionValue,\n right: right as DimensionValue,\n ...(style as ImageStyle),\n };\n\n return (\n <Image\n source={{ uri: src }}\n style={imageStyle}\n testID={finalTestID}\n resizeMode=\"cover\"\n {...nativeRest}\n />\n );\n }\n\n if (onPress) {\n return (\n <Pressable\n onPress={onPress}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n style={({ pressed }) => getContainerStyle(pressed)}\n testID={finalTestID}\n {...nativeRest}\n >\n {children}\n </Pressable>\n );\n }\n\n return (\n <View\n style={getContainerStyle()}\n testID={finalTestID}\n onLayout={onLayout}\n onMoveShouldSetResponder={onMoveShouldSetResponder}\n onResponderGrant={onResponderGrant}\n onResponderMove={onResponderMove}\n onResponderRelease={onResponderRelease}\n onResponderTerminate={onResponderTerminate}\n {...nativeRest}\n >\n {children}\n </View>\n );\n};\n","import React from \"react\";\nimport {\n Text as RNText,\n TextStyle,\n AccessibilityRole,\n StyleSheet,\n} from \"react-native\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\n\nconst roleMap: Record<string, AccessibilityRole> = {\n alert: \"alert\",\n heading: \"header\",\n button: \"button\",\n link: \"link\",\n text: \"text\",\n};\n\nconst parseNumericValue = (\n value: string | number | undefined\n): number | undefined => {\n if (value === undefined) return undefined;\n if (typeof value === \"number\") return value;\n const parsed = parseFloat(value);\n return isNaN(parsed) ? undefined : parsed;\n};\n\nexport const Text: React.FC<TextProps> = ({\n children,\n color,\n fontSize,\n fontWeight,\n fontFamily,\n textAlign,\n lineHeight,\n numberOfLines,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n style: styleProp,\n ...props\n}) => {\n let resolvedFontFamily = fontFamily\n ? fontFamily.split(\",\")[0].replace(/['\"]/g, \"\").trim()\n : undefined;\n\n if (\n resolvedFontFamily === \"Pilat Wide\" ||\n resolvedFontFamily === \"Pilat Wide Bold\" ||\n resolvedFontFamily === \"Aktiv Grotesk\"\n ) {\n resolvedFontFamily = undefined;\n }\n\n const incomingStyle = StyleSheet.flatten(styleProp) as TextStyle | undefined;\n\n const baseStyle: TextStyle = {\n color: color ?? incomingStyle?.color,\n fontSize: typeof fontSize === \"number\" ? fontSize : undefined,\n fontWeight: fontWeight as TextStyle[\"fontWeight\"],\n fontFamily: resolvedFontFamily,\n textDecorationLine: props.textDecoration as TextStyle[\"textDecorationLine\"],\n textAlign: textAlign ?? incomingStyle?.textAlign,\n lineHeight: parseNumericValue(lineHeight ?? incomingStyle?.lineHeight),\n marginTop: parseNumericValue(\n incomingStyle?.marginTop as number | string | undefined\n ),\n marginBottom: parseNumericValue(\n incomingStyle?.marginBottom as number | string | undefined\n ),\n };\n\n const accessibilityRole = role ? roleMap[role] : undefined;\n\n return (\n <RNText\n style={baseStyle}\n numberOfLines={numberOfLines}\n testID={dataTestId || testID || id}\n accessibilityRole={accessibilityRole}\n >\n {children}\n </RNText>\n );\n};\n","import React from \"react\";\nimport { View, ViewStyle } from \"react-native\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\n\nexport const Icon: React.FC<IconProps> = ({\n children,\n color,\n size,\n testID,\n \"data-testid\": dataTestId,\n}) => {\n const style: ViewStyle = {\n width: typeof size === \"number\" ? size : undefined,\n height: typeof size === \"number\" ? size : undefined,\n alignItems: \"center\",\n justifyContent: \"center\",\n };\n\n // On native, we try to pass the color down to children (like Text primitives)\n // to mimic the CSS inheritance behavior of the web version.\n const childrenWithProps = React.Children.map(children, (child) => {\n if (React.isValidElement(child)) {\n return React.cloneElement(child, {\n color: child.props.color || color,\n // Also pass size if child seems to be an icon that needs it\n size: child.props.size || size,\n });\n }\n return child;\n });\n\n return (\n <View style={style} testID={dataTestId || testID}>\n {childrenWithProps}\n </View>\n );\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n /** Test ID for testing frameworks */\n testID?: string;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n testID={testID}\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";AACA;AAAA,EACE;AAAA,EACA;AAAA,EACA;AAAA,OAKK;AA2ID;AAxIC,IAAM,MAA0B,CAAC;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EAC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c;AAAA,QACd,YAAY;AAAA,MACd;AAAA,MAEC;AAAA,oBACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,oBACH;AAAA,QAGD,YACC,gBAAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,UAAU,WAAW;AAAA,YACrB,YAAW;AAAA,YACX,YAAW;AAAA,YACX,OAAO;AAAA,cACL,UAAU;AAAA,cACV,cAAc;AAAA,YAChB;AAAA,YAEC;AAAA;AAAA,QACH;AAAA,QAGD,aACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,qBACH;AAAA,QAGD,YACC,gBAAAA,KAAC,OAAI,SAAS,UACZ,0BAAAA,KAAC,KAAE,MAAM,WAAW,UAAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["jsx","View","jsx","jsx"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xsolla/xui-tag",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.159.0",
|
|
4
4
|
"main": "./web/index.js",
|
|
5
5
|
"module": "./web/index.mjs",
|
|
6
6
|
"types": "./web/index.d.ts",
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
"build:native": "PLATFORM=native tsup"
|
|
11
11
|
},
|
|
12
12
|
"dependencies": {
|
|
13
|
-
"@xsolla/xui-core": "0.
|
|
14
|
-
"@xsolla/xui-icons": "0.
|
|
15
|
-
"@xsolla/xui-primitives-core": "0.
|
|
13
|
+
"@xsolla/xui-core": "0.159.0",
|
|
14
|
+
"@xsolla/xui-icons": "0.159.0",
|
|
15
|
+
"@xsolla/xui-primitives-core": "0.159.0"
|
|
16
16
|
},
|
|
17
17
|
"peerDependencies": {
|
|
18
18
|
"react": ">=16.8.0",
|
package/web/index.d.mts
CHANGED
|
@@ -16,6 +16,8 @@ interface TagProps extends ThemeOverrideProps {
|
|
|
16
16
|
iconRight?: ReactNode;
|
|
17
17
|
/** Callback when the remove (X) icon is clicked */
|
|
18
18
|
onRemove?: () => void;
|
|
19
|
+
/** Test ID for testing frameworks */
|
|
20
|
+
testID?: string;
|
|
19
21
|
}
|
|
20
22
|
declare const Tag: React.FC<TagProps>;
|
|
21
23
|
|
package/web/index.d.ts
CHANGED
|
@@ -16,6 +16,8 @@ interface TagProps extends ThemeOverrideProps {
|
|
|
16
16
|
iconRight?: ReactNode;
|
|
17
17
|
/** Callback when the remove (X) icon is clicked */
|
|
18
18
|
onRemove?: () => void;
|
|
19
|
+
/** Test ID for testing frameworks */
|
|
20
|
+
testID?: string;
|
|
19
21
|
}
|
|
20
22
|
declare const Tag: React.FC<TagProps>;
|
|
21
23
|
|
package/web/index.js
CHANGED
|
@@ -304,6 +304,8 @@ var Text = ({
|
|
|
304
304
|
className,
|
|
305
305
|
id,
|
|
306
306
|
role,
|
|
307
|
+
testID,
|
|
308
|
+
"data-testid": dataTestId,
|
|
307
309
|
numberOfLines: _numberOfLines,
|
|
308
310
|
...props
|
|
309
311
|
}) => {
|
|
@@ -314,7 +316,8 @@ var Text = ({
|
|
|
314
316
|
style,
|
|
315
317
|
className,
|
|
316
318
|
id,
|
|
317
|
-
role
|
|
319
|
+
role,
|
|
320
|
+
"data-testid": dataTestId || testID
|
|
318
321
|
}
|
|
319
322
|
);
|
|
320
323
|
};
|
|
@@ -338,8 +341,13 @@ var StyledIcon = (0, import_styled_components3.default)(FilteredDiv2)`
|
|
|
338
341
|
stroke: currentColor;
|
|
339
342
|
}
|
|
340
343
|
`;
|
|
341
|
-
var Icon = ({
|
|
342
|
-
|
|
344
|
+
var Icon = ({
|
|
345
|
+
children,
|
|
346
|
+
testID,
|
|
347
|
+
"data-testid": dataTestId,
|
|
348
|
+
...props
|
|
349
|
+
}) => {
|
|
350
|
+
return /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(StyledIcon, { "data-testid": dataTestId || testID, ...props, children });
|
|
343
351
|
};
|
|
344
352
|
|
|
345
353
|
// src/Tag.tsx
|
|
@@ -354,6 +362,7 @@ var Tag = ({
|
|
|
354
362
|
iconLeft,
|
|
355
363
|
iconRight,
|
|
356
364
|
onRemove,
|
|
365
|
+
testID,
|
|
357
366
|
themeMode,
|
|
358
367
|
themeProductContext
|
|
359
368
|
}) => {
|
|
@@ -417,6 +426,7 @@ var Tag = ({
|
|
|
417
426
|
return /* @__PURE__ */ (0, import_jsx_runtime4.jsxs)(
|
|
418
427
|
Box,
|
|
419
428
|
{
|
|
429
|
+
testID,
|
|
420
430
|
backgroundColor: bg,
|
|
421
431
|
borderRadius: sizeStyles.radius,
|
|
422
432
|
height: sizeStyles.height,
|
package/web/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../src/index.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["export * from \"./Tag\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n />\n );\n};\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledIcon = styled(FilteredDiv)<IconProps>`\n display: flex;\n align-items: center;\n justify-content: center;\n width: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n height: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n color: ${(props) => props.color || \"currentColor\"};\n\n svg {\n width: 100%;\n height: 100%;\n fill: none;\n stroke: currentColor;\n }\n`;\n\nexport const Icon: React.FC<IconProps> = ({ children, ...props }) => {\n return <StyledIcon {...props}>{children}</StyledIcon>;\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACAA,IAAAA,gBAAkB;AAClB,+BAAmB;;;ACDnB,mBAAkB;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GAAG;AAAA,EAClB;AACF;AAEA,IAAO,sBAAQ;;;ACNf,IAAI,kBAAkB;AAEtB,IAAI,QAAQ;AAAA,EAAQ,SAAU,MAAM;AAClC,WAAO,gBAAgB,KAAK,IAAI,KAAK,KAAK,WAAW,CAAC,MAAM,OAEzD,KAAK,WAAW,CAAC,MAAM,OAEvB,KAAK,WAAW,CAAC,IAAI;AAAA,EAC1B;AAAA;AAEA;AAEA,IAAO,4BAAQ;;;AFRR,IAAM,2BAA2B,oBAAI,IAAI;AAAA;AAAA,EAE9C;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA;AAAA,EAEA;AAAA;AAAA,EAEA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF,CAAC;AAED,SAAS,kBAAkB,KAAsB;AAC/C,MAAI,yBAAyB,IAAI,GAAG,EAAG,QAAO;AAC9C,SAAO,0BAAY,GAAG;AACxB;AAgBO,SAAS,sBAAsB,YAAoB;AACxD,QAAM,YAAY,aAAAC,QAAM;AAAA,IACtB,CAAC,EAAE,UAAU,aAAa,GAAG,MAAM,GAAG,QAAQ;AAC5C,YAA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AAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["import_react","React","Tag","styled","React","import_styled_components","import_jsx_runtime","styled","import_styled_components","import_jsx_runtime","FilteredDiv","styled","import_jsx_runtime"]}
|
|
1
|
+
{"version":3,"sources":["../../src/index.tsx","../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["export * from \"./Tag\";\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledIcon = styled(FilteredDiv)<IconProps>`\n display: flex;\n align-items: center;\n justify-content: center;\n width: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n height: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n color: ${(props) => props.color || \"currentColor\"};\n\n svg {\n width: 100%;\n height: 100%;\n fill: none;\n stroke: currentColor;\n }\n`;\n\nexport const Icon: React.FC<IconProps> = ({\n children,\n testID,\n \"data-testid\": dataTestId,\n ...props\n}) => {\n return (\n <StyledIcon data-testid={dataTestId || testID} {...props}>\n {children}\n </StyledIcon>\n );\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n /** Test ID for testing frameworks */\n testID?: string;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n testID={testID}\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box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;AAAA,EAEJ;AAEJ;","names":["import_react","React","Tag","styled","React","import_styled_components","import_jsx_runtime","styled","import_styled_components","import_jsx_runtime","FilteredDiv","styled","import_jsx_runtime"]}
|
package/web/index.mjs
CHANGED
|
@@ -268,6 +268,8 @@ var Text = ({
|
|
|
268
268
|
className,
|
|
269
269
|
id,
|
|
270
270
|
role,
|
|
271
|
+
testID,
|
|
272
|
+
"data-testid": dataTestId,
|
|
271
273
|
numberOfLines: _numberOfLines,
|
|
272
274
|
...props
|
|
273
275
|
}) => {
|
|
@@ -278,7 +280,8 @@ var Text = ({
|
|
|
278
280
|
style,
|
|
279
281
|
className,
|
|
280
282
|
id,
|
|
281
|
-
role
|
|
283
|
+
role,
|
|
284
|
+
"data-testid": dataTestId || testID
|
|
282
285
|
}
|
|
283
286
|
);
|
|
284
287
|
};
|
|
@@ -302,8 +305,13 @@ var StyledIcon = styled3(FilteredDiv2)`
|
|
|
302
305
|
stroke: currentColor;
|
|
303
306
|
}
|
|
304
307
|
`;
|
|
305
|
-
var Icon = ({
|
|
306
|
-
|
|
308
|
+
var Icon = ({
|
|
309
|
+
children,
|
|
310
|
+
testID,
|
|
311
|
+
"data-testid": dataTestId,
|
|
312
|
+
...props
|
|
313
|
+
}) => {
|
|
314
|
+
return /* @__PURE__ */ jsx3(StyledIcon, { "data-testid": dataTestId || testID, ...props, children });
|
|
307
315
|
};
|
|
308
316
|
|
|
309
317
|
// src/Tag.tsx
|
|
@@ -318,6 +326,7 @@ var Tag = ({
|
|
|
318
326
|
iconLeft,
|
|
319
327
|
iconRight,
|
|
320
328
|
onRemove,
|
|
329
|
+
testID,
|
|
321
330
|
themeMode,
|
|
322
331
|
themeProductContext
|
|
323
332
|
}) => {
|
|
@@ -381,6 +390,7 @@ var Tag = ({
|
|
|
381
390
|
return /* @__PURE__ */ jsxs(
|
|
382
391
|
Box,
|
|
383
392
|
{
|
|
393
|
+
testID,
|
|
384
394
|
backgroundColor: bg,
|
|
385
395
|
borderRadius: sizeStyles.radius,
|
|
386
396
|
height: sizeStyles.height,
|
package/web/index.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"sources":["../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n />\n );\n};\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledIcon = styled(FilteredDiv)<IconProps>`\n display: flex;\n align-items: center;\n justify-content: center;\n width: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n height: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n color: ${(props) => props.color || \"currentColor\"};\n\n svg {\n width: 100%;\n height: 100%;\n fill: none;\n stroke: currentColor;\n }\n`;\n\nexport const Icon: React.FC<IconProps> = ({ children, ...props }) => {\n return <StyledIcon {...props}>{children}</StyledIcon>;\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";AAAA,OAAOA,YAAW;AAClB,OAAO,YAAY;;;ACDnB,OAAO,WAAW;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GA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AAW;AAAA,MACzB,QAAQ,WAAW;AAAA,MACnB,OAAO,aAAa,WAAW,SAAS;AAAA,MACxC,mBAAmB,aAAa,IAAI,WAAW;AAAA,MAC/C,eAAc;AAAA,MACd,YAAW;AAAA,MACX,gBAAe;AAAA,MACf,KAAK,WAAW;AAAA,MAChB,aAAa,WAAW;AAAA,MACxB,aAAa;AAAA,MACb,aAAY;AAAA,MACZ,OAAO;AAAA,QACL,UAAU;AAAA,QACV,cAAc;AAAA,QACd,YAAY;AAAA,MACd;AAAA,MAEC;AAAA,oBACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,oBACH;AAAA,QAGD,YACC,gBAAAA;AAAA,UAAC;AAAA;AAAA,YACC,OAAO;AAAA,YACP,UAAU,WAAW;AAAA,YACrB,YAAW;AAAA,YACX,YAAW;AAAA,YACX,OAAO;AAAA,cACL,UAAU;AAAA,cACV,cAAc;AAAA,YAChB;AAAA,YAEC;AAAA;AAAA,QACH;AAAA,QAGD,aACC,gBAAAA,KAAC,QAAK,MAAM,WAAW,UAAU,OAAO,MACrC,qBACH;AAAA,QAGD,YACC,gBAAAA,KAAC,OAAI,SAAS,UACZ,0BAAAA,KAAC,KAAE,MAAM,WAAW,UAAU,OAAO,MAAM,GAC7C;AAAA;AAAA;AAAA,EAEJ;AAEJ;","names":["React","Tag","React","styled","jsx","styled","styled","jsx","FilteredDiv","styled","jsx"]}
|
|
1
|
+
{"version":3,"sources":["../../../../foundation/primitives-web/src/Box.tsx","../../../../foundation/primitives-web/src/filterDOMProps.ts","../../../../../node_modules/@emotion/memoize/dist/memoize.esm.js","../../../../../node_modules/@emotion/is-prop-valid/dist/is-prop-valid.esm.js","../../../../foundation/primitives-web/src/Text.tsx","../../../../foundation/primitives-web/src/Icon.tsx","../../src/Tag.tsx"],"sourcesContent":["import React from \"react\";\nimport styled from \"styled-components\";\nimport type { BoxProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledBox = styled(FilteredDiv)<BoxProps>`\n display: flex;\n box-sizing: border-box;\n background-color: ${(props) => props.backgroundColor || \"transparent\"};\n border-color: ${(props) => props.borderColor || \"transparent\"};\n border-width: ${(props) =>\n typeof props.borderWidth === \"number\"\n ? `${props.borderWidth}px`\n : props.borderWidth || 0};\n\n ${(props) =>\n props.borderBottomWidth !== undefined &&\n `\n border-bottom-width: ${typeof props.borderBottomWidth === \"number\" ? `${props.borderBottomWidth}px` : props.borderBottomWidth};\n border-bottom-color: ${props.borderBottomColor || props.borderColor || \"transparent\"};\n border-bottom-style: solid;\n `}\n ${(props) =>\n props.borderTopWidth !== undefined &&\n `\n border-top-width: ${typeof props.borderTopWidth === \"number\" ? `${props.borderTopWidth}px` : props.borderTopWidth};\n border-top-color: ${props.borderTopColor || props.borderColor || \"transparent\"};\n border-top-style: solid;\n `}\n ${(props) =>\n props.borderLeftWidth !== undefined &&\n `\n border-left-width: ${typeof props.borderLeftWidth === \"number\" ? `${props.borderLeftWidth}px` : props.borderLeftWidth};\n border-left-color: ${props.borderLeftColor || props.borderColor || \"transparent\"};\n border-left-style: solid;\n `}\n ${(props) =>\n props.borderRightWidth !== undefined &&\n `\n border-right-width: ${typeof props.borderRightWidth === \"number\" ? `${props.borderRightWidth}px` : props.borderRightWidth};\n border-right-color: ${props.borderRightColor || props.borderColor || \"transparent\"};\n border-right-style: solid;\n `}\n\n border-style: ${(props) =>\n props.borderStyle ||\n (props.borderWidth ||\n props.borderBottomWidth ||\n props.borderTopWidth ||\n props.borderLeftWidth ||\n props.borderRightWidth\n ? \"solid\"\n : \"none\")};\n border-radius: ${(props) =>\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius || 0};\n height: ${(props) =>\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height || \"auto\"};\n width: ${(props) =>\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width || \"auto\"};\n min-width: ${(props) =>\n typeof props.minWidth === \"number\"\n ? `${props.minWidth}px`\n : props.minWidth || \"auto\"};\n min-height: ${(props) =>\n typeof props.minHeight === \"number\"\n ? `${props.minHeight}px`\n : props.minHeight || \"auto\"};\n max-width: ${(props) =>\n typeof props.maxWidth === \"number\"\n ? `${props.maxWidth}px`\n : props.maxWidth || \"none\"};\n max-height: ${(props) =>\n typeof props.maxHeight === \"number\"\n ? `${props.maxHeight}px`\n : props.maxHeight || \"none\"};\n\n padding: ${(props) =>\n typeof props.padding === \"number\"\n ? `${props.padding}px`\n : props.padding || 0};\n ${(props) =>\n props.paddingHorizontal &&\n `\n padding-left: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n padding-right: ${typeof props.paddingHorizontal === \"number\" ? `${props.paddingHorizontal}px` : props.paddingHorizontal};\n `}\n ${(props) =>\n props.paddingVertical &&\n `\n padding-top: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n padding-bottom: ${typeof props.paddingVertical === \"number\" ? `${props.paddingVertical}px` : props.paddingVertical};\n `}\n ${(props) =>\n props.paddingTop !== undefined &&\n `padding-top: ${typeof props.paddingTop === \"number\" ? `${props.paddingTop}px` : props.paddingTop};`}\n ${(props) =>\n props.paddingBottom !== undefined &&\n `padding-bottom: ${typeof props.paddingBottom === \"number\" ? `${props.paddingBottom}px` : props.paddingBottom};`}\n ${(props) =>\n props.paddingLeft !== undefined &&\n `padding-left: ${typeof props.paddingLeft === \"number\" ? `${props.paddingLeft}px` : props.paddingLeft};`}\n ${(props) =>\n props.paddingRight !== undefined &&\n `padding-right: ${typeof props.paddingRight === \"number\" ? `${props.paddingRight}px` : props.paddingRight};`}\n\n margin: ${(props) =>\n typeof props.margin === \"number\" ? `${props.margin}px` : props.margin || 0};\n ${(props) =>\n props.marginTop !== undefined &&\n `margin-top: ${typeof props.marginTop === \"number\" ? `${props.marginTop}px` : props.marginTop};`}\n ${(props) =>\n props.marginBottom !== undefined &&\n `margin-bottom: ${typeof props.marginBottom === \"number\" ? `${props.marginBottom}px` : props.marginBottom};`}\n ${(props) =>\n props.marginLeft !== undefined &&\n `margin-left: ${typeof props.marginLeft === \"number\" ? `${props.marginLeft}px` : props.marginLeft};`}\n ${(props) =>\n props.marginRight !== undefined &&\n `margin-right: ${typeof props.marginRight === \"number\" ? `${props.marginRight}px` : props.marginRight};`}\n\n flex-direction: ${(props) => props.flexDirection || \"column\"};\n flex-wrap: ${(props) => props.flexWrap || \"nowrap\"};\n align-items: ${(props) => props.alignItems || \"stretch\"};\n justify-content: ${(props) => props.justifyContent || \"flex-start\"};\n cursor: ${(props) =>\n props.cursor\n ? props.cursor\n : props.onClick || props.onPress\n ? \"pointer\"\n : \"inherit\"};\n position: ${(props) => props.position || \"static\"};\n top: ${(props) =>\n typeof props.top === \"number\" ? `${props.top}px` : props.top};\n bottom: ${(props) =>\n typeof props.bottom === \"number\" ? `${props.bottom}px` : props.bottom};\n left: ${(props) =>\n typeof props.left === \"number\" ? `${props.left}px` : props.left};\n right: ${(props) =>\n typeof props.right === \"number\" ? `${props.right}px` : props.right};\n flex: ${(props) => props.flex};\n flex-shrink: ${(props) => props.flexShrink ?? 1};\n gap: ${(props) =>\n typeof props.gap === \"number\" ? `${props.gap}px` : props.gap || 0};\n align-self: ${(props) => props.alignSelf || \"auto\"};\n overflow: ${(props) => props.overflow || \"visible\"};\n overflow-x: ${(props) => props.overflowX || \"visible\"};\n overflow-y: ${(props) => props.overflowY || \"visible\"};\n z-index: ${(props) => props.zIndex};\n opacity: ${(props) => (props.disabled ? 0.5 : 1)};\n pointer-events: ${(props) => (props.disabled ? \"none\" : \"auto\")};\n\n &:hover {\n ${(props) =>\n props.hoverStyle?.backgroundColor &&\n `background-color: ${props.hoverStyle.backgroundColor};`}\n ${(props) =>\n props.hoverStyle?.borderColor &&\n `border-color: ${props.hoverStyle.borderColor};`}\n }\n\n &:active {\n ${(props) =>\n props.pressStyle?.backgroundColor &&\n `background-color: ${props.pressStyle.backgroundColor};`}\n }\n`;\n\nexport const Box = React.forwardRef<\n HTMLDivElement | HTMLButtonElement,\n BoxProps\n>(\n (\n {\n children,\n onPress,\n onKeyDown,\n onKeyUp,\n role,\n \"aria-label\": ariaLabel,\n \"aria-labelledby\": ariaLabelledBy,\n \"aria-current\": ariaCurrent,\n \"aria-disabled\": ariaDisabled,\n \"aria-live\": ariaLive,\n \"aria-busy\": ariaBusy,\n \"aria-describedby\": ariaDescribedBy,\n \"aria-expanded\": ariaExpanded,\n \"aria-haspopup\": ariaHasPopup,\n \"aria-pressed\": ariaPressed,\n \"aria-controls\": ariaControls,\n tabIndex,\n as,\n src,\n alt,\n onError,\n onLoad,\n type,\n disabled,\n id,\n testID,\n \"data-testid\": dataTestId,\n ...props\n },\n ref\n ) => {\n // Handle as=\"img\" for rendering images with proper border-radius\n if (as === \"img\" && src) {\n return (\n <img\n src={src}\n alt={alt || \"\"}\n onError={onError}\n onLoad={onLoad}\n style={{\n display: \"block\",\n objectFit: \"cover\",\n width:\n typeof props.width === \"number\"\n ? `${props.width}px`\n : props.width,\n height:\n typeof props.height === \"number\"\n ? `${props.height}px`\n : props.height,\n borderRadius:\n typeof props.borderRadius === \"number\"\n ? `${props.borderRadius}px`\n : props.borderRadius,\n position: props.position,\n top: typeof props.top === \"number\" ? `${props.top}px` : props.top,\n left:\n typeof props.left === \"number\" ? `${props.left}px` : props.left,\n right:\n typeof props.right === \"number\"\n ? `${props.right}px`\n : props.right,\n bottom:\n typeof props.bottom === \"number\"\n ? `${props.bottom}px`\n : props.bottom,\n ...props.style,\n }}\n />\n );\n }\n\n return (\n <StyledBox\n ref={ref}\n elementType={as}\n id={id}\n type={as === \"button\" ? type || \"button\" : undefined}\n disabled={as === \"button\" ? disabled : undefined}\n onClick={onPress}\n onKeyDown={onKeyDown}\n onKeyUp={onKeyUp}\n role={role}\n aria-label={ariaLabel}\n aria-labelledby={ariaLabelledBy}\n aria-current={ariaCurrent}\n aria-disabled={ariaDisabled}\n aria-busy={ariaBusy}\n aria-describedby={ariaDescribedBy}\n aria-expanded={ariaExpanded}\n aria-haspopup={ariaHasPopup}\n aria-pressed={ariaPressed}\n aria-controls={ariaControls}\n aria-live={ariaLive}\n tabIndex={tabIndex !== undefined ? tabIndex : undefined}\n data-testid={dataTestId || testID}\n {...props}\n >\n {children}\n </StyledBox>\n );\n }\n);\n\nBox.displayName = \"Box\";\n","import React from \"react\";\nimport isPropValid from \"@emotion/is-prop-valid\";\n\n// Props that @emotion/is-prop-valid incorrectly treats as valid HTML.\n// These are React Native or component-specific props that match\n// valid HTML patterns (on* event handlers, SVG attributes).\nexport const ADDITIONAL_BLOCKED_PROPS = new Set([\n // RN-only event handlers (pass isPropValid's on* pattern)\n \"onPress\",\n \"onChangeText\",\n \"onLayout\",\n \"onMoveShouldSetResponder\",\n \"onResponderGrant\",\n \"onResponderMove\",\n \"onResponderRelease\",\n \"onResponderTerminate\",\n // SVG attributes that pass isPropValid\n \"strokeWidth\",\n // CSS properties that pass isPropValid but are used as component props\n \"overflow\",\n \"cursor\",\n \"fontSize\",\n \"fontWeight\",\n \"fontFamily\",\n \"textDecoration\",\n]);\n\nfunction shouldForwardProp(key: string): boolean {\n if (ADDITIONAL_BLOCKED_PROPS.has(key)) return false;\n return isPropValid(key);\n}\n\n/**\n * Creates a React component that renders the given HTML tag\n * but filters out non-HTML props before they reach the DOM.\n *\n * Uses @emotion/is-prop-valid (same library styled-components v4\n * uses internally) to automatically block invalid HTML attributes,\n * plus a small blocklist for false positives (RN on* handlers, SVG attrs).\n *\n * Usage: `const FilteredDiv = createFilteredElement(\"div\");`\n * Then: `const StyledBox = styled(FilteredDiv)<BoxProps>\\`...\\`;`\n *\n * styled-components can still read ALL props for CSS interpolation,\n * but only valid HTML attributes are forwarded to the DOM element.\n */\nexport function createFilteredElement(defaultTag: string) {\n const Component = React.forwardRef<HTMLElement, Record<string, unknown>>(\n ({ children, elementType, ...props }, ref) => {\n const Tag = (elementType as string) || defaultTag;\n const htmlProps: Record<string, unknown> = {};\n for (const key of Object.keys(props)) {\n if (shouldForwardProp(key)) {\n htmlProps[key] = props[key];\n }\n }\n return React.createElement(\n Tag,\n { ref, ...htmlProps },\n children as React.ReactNode\n );\n }\n );\n Component.displayName = `Filtered(${defaultTag})`;\n return Component;\n}\n","function memoize(fn) {\n var cache = {};\n return function (arg) {\n if (cache[arg] === undefined) cache[arg] = fn(arg);\n return cache[arg];\n };\n}\n\nexport default memoize;\n","import memoize from '@emotion/memoize';\n\nvar reactPropsRegex = /^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|download|draggable|encType|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|inert|itemProp|itemScope|itemType|itemID|itemRef|on|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/; // https://esbench.com/bench/5bfee68a4cd7e6009ef61d23\n\nvar index = memoize(function (prop) {\n return reactPropsRegex.test(prop) || prop.charCodeAt(0) === 111\n /* o */\n && prop.charCodeAt(1) === 110\n /* n */\n && prop.charCodeAt(2) < 91;\n}\n/* Z+1 */\n);\n\nexport default index;\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { TextProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredSpan = createFilteredElement(\"span\");\n\nconst StyledText = styled(FilteredSpan)<TextProps>`\n color: ${(props) => props.color || \"inherit\"};\n font-size: ${(props) =>\n typeof props.fontSize === \"number\"\n ? `${props.fontSize}px`\n : props.fontSize || \"inherit\"};\n font-weight: ${(props) => props.fontWeight || \"normal\"};\n font-family: ${(props) =>\n props.fontFamily ||\n '\"Aktiv Grotesk\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif'};\n line-height: ${(props) =>\n typeof props.lineHeight === \"number\"\n ? `${props.lineHeight}px`\n : props.lineHeight || \"inherit\"};\n white-space: ${(props) => props.whiteSpace || \"normal\"};\n text-align: ${(props) => props.textAlign || \"inherit\"};\n text-decoration: ${(props) => props.textDecoration || \"none\"};\n`;\n\nexport const Text: React.FC<TextProps> = ({\n style,\n className,\n id,\n role,\n testID,\n \"data-testid\": dataTestId,\n numberOfLines: _numberOfLines,\n ...props\n}) => {\n return (\n <StyledText\n {...props}\n style={style}\n className={className}\n id={id}\n role={role}\n data-testid={dataTestId || testID}\n />\n );\n};\n","import React from \"react\";\nimport styled from \"styled-components\";\nimport { IconProps } from \"@xsolla/xui-primitives-core\";\nimport { createFilteredElement } from \"./filterDOMProps\";\n\nconst FilteredDiv = createFilteredElement(\"div\");\n\nconst StyledIcon = styled(FilteredDiv)<IconProps>`\n display: flex;\n align-items: center;\n justify-content: center;\n width: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n height: ${(props) =>\n typeof props.size === \"number\" ? `${props.size}px` : props.size || \"24px\"};\n color: ${(props) => props.color || \"currentColor\"};\n\n svg {\n width: 100%;\n height: 100%;\n fill: none;\n stroke: currentColor;\n }\n`;\n\nexport const Icon: React.FC<IconProps> = ({\n children,\n testID,\n \"data-testid\": dataTestId,\n ...props\n}) => {\n return (\n <StyledIcon data-testid={dataTestId || testID} {...props}>\n {children}\n </StyledIcon>\n );\n};\n","import React, { type ReactNode } from \"react\";\n// @ts-expect-error - this will be resolved at build time\nimport { Box, Text, Icon } from \"@xsolla/xui-primitives\";\nimport { useResolvedTheme, type ThemeOverrideProps } from \"@xsolla/xui-core\";\nimport { X } from \"@xsolla/xui-icons\";\n\nexport interface TagProps extends ThemeOverrideProps {\n /** Size of the tag */\n size?: \"xl\" | \"lg\" | \"md\" | \"sm\" | \"xs\";\n /** Colour tone of the tag */\n tone?:\n | \"primary\"\n | \"brand\"\n | \"brandExtra\"\n | \"success\"\n | \"warning\"\n | \"alert\"\n | \"neutral\";\n /** Visual style: solid (filled background) or outlined (border only) */\n type?: \"solid\" | \"outlined\";\n /** Label text. When omitted with an icon, the tag collapses to a square. */\n children?: ReactNode;\n /** Icon displayed on the left side of the label */\n iconLeft?: ReactNode;\n /** Icon displayed on the right side of the label */\n iconRight?: ReactNode;\n /** Callback when the remove (X) icon is clicked */\n onRemove?: () => void;\n /** Test ID for testing frameworks */\n testID?: string;\n}\n\nexport const Tag: React.FC<TagProps> = ({\n size = \"md\",\n tone = \"primary\",\n type = \"solid\",\n children,\n iconLeft,\n iconRight,\n onRemove,\n testID,\n themeMode,\n themeProductContext,\n}) => {\n const { theme } = useResolvedTheme({ themeMode, themeProductContext });\n const sizeStyles = theme.sizing.tag(size);\n\n const resolveColors = () => {\n const isOutlined = type === \"outlined\";\n\n switch (tone) {\n case \"primary\":\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n case \"brand\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brand.primary,\n text: isOutlined\n ? theme.colors.content.brand.primary\n : theme.colors.content.on.brand,\n border: theme.colors.border.brand,\n };\n case \"brandExtra\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.brandExtra.primary,\n text: isOutlined\n ? theme.colors.content.brandExtra.primary\n : theme.colors.content.on.brandExtra,\n border: theme.colors.border.brandExtra,\n };\n case \"success\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.success.primary,\n text: isOutlined\n ? theme.colors.content.success.primary\n : theme.colors.content.on.success,\n border: theme.colors.border.success,\n };\n case \"warning\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.warning.primary,\n text: isOutlined\n ? theme.colors.content.warning.primary\n : theme.colors.content.on.warning,\n border: theme.colors.border.warning,\n };\n case \"alert\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.alert.primary,\n text: isOutlined\n ? theme.colors.content.alert.primary\n : theme.colors.content.on.alert,\n border: theme.colors.border.alert,\n };\n case \"neutral\":\n return {\n bg: isOutlined\n ? \"transparent\"\n : theme.colors.background.neutral.primary,\n text: isOutlined\n ? theme.colors.content.neutral.primary\n : theme.colors.content.on.neutral,\n border: theme.colors.border.neutral,\n };\n default:\n return {\n bg: isOutlined ? \"transparent\" : theme.colors.background.primary,\n text: theme.colors.content.primary,\n border: theme.colors.border.secondary,\n };\n }\n };\n\n const { bg, text, border } = resolveColors();\n const isIconOnly = !children && (!!iconLeft || !!iconRight);\n\n return (\n <Box\n testID={testID}\n backgroundColor={bg}\n borderRadius={sizeStyles.radius}\n height={sizeStyles.height}\n width={isIconOnly ? sizeStyles.height : undefined}\n paddingHorizontal={isIconOnly ? 0 : sizeStyles.padding}\n flexDirection=\"row\"\n alignItems=\"center\"\n justifyContent=\"center\"\n gap={sizeStyles.gap}\n borderWidth={sizeStyles.borderWidth}\n borderColor={border}\n borderStyle=\"solid\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n whiteSpace: \"nowrap\",\n }}\n >\n {iconLeft && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconLeft}\n </Icon>\n )}\n\n {children && (\n <Text\n color={text}\n fontSize={sizeStyles.fontSize}\n fontWeight=\"500\"\n whiteSpace=\"nowrap\"\n style={{\n overflow: \"hidden\",\n textOverflow: \"ellipsis\",\n }}\n >\n {children}\n </Text>\n )}\n\n {iconRight && (\n <Icon size={sizeStyles.iconSize} color={text}>\n {iconRight}\n </Icon>\n )}\n\n {onRemove && (\n <Box onPress={onRemove}>\n <X size={sizeStyles.iconSize} color={text} />\n </Box>\n )}\n </Box>\n );\n};\n"],"mappings":";AAAA,OAAOA,YAAW;AAClB,OAAO,YAAY;;;ACDnB,OAAO,WAAW;;;ACAlB,SAAS,QAAQ,IAAI;AACnB,MAAI,QAAQ,CAAC;AACb,SAAO,SAAU,KAAK;AACpB,QAAI,MAAM,GAAG,MAAM,OAAW,OAAM,GAAG,IAAI,GAAG,GAAG;AACjD,WAAO,MAAM,GAAG;AAAA,EAClB;AACF;AAEA,IAAO,sBAAQ;;;ACNf,IAAI,kBAAkB;AAEtB,IAAI,QAAQ;AAAA,EAAQ,SAAU,MAAM;AAClC,WAAO,gBAAgB,KAAK,IAAI,KAAK,KAAK,WAAW,CAAC,MAAM,OAEzD,KAAK,WAAW,CAAC,MAAM,OAEvB,KAAK,WAAW,CAAC,IAAI;AAAA,EAC1B;AAAA;AAEA;AAEA,IAAO,4BAAQ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