@xsolla/xui-supporting-text 0.95.0 → 0.97.0-pr154.1771807405
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 +29 -0
- package/package.json +4 -4
package/README.md
ADDED
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
# @xsolla/xui-supporting-text
|
|
2
|
+
|
|
3
|
+
Accessible text component for form labels, helper messages, descriptions, and error notifications.
|
|
4
|
+
|
|
5
|
+
## Installation
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
yarn add @xsolla/xui-supporting-text
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## Usage
|
|
12
|
+
|
|
13
|
+
```tsx
|
|
14
|
+
import { SupportingText } from '@xsolla/xui-supporting-text';
|
|
15
|
+
|
|
16
|
+
<SupportingText variant="helper">We will never share your email.</SupportingText>
|
|
17
|
+
<SupportingText variant="error">Please enter a valid email address.</SupportingText>
|
|
18
|
+
```
|
|
19
|
+
|
|
20
|
+
## Props
|
|
21
|
+
|
|
22
|
+
### SupportingText
|
|
23
|
+
|
|
24
|
+
| Prop | Type | Default | Description |
|
|
25
|
+
|------|------|---------|-------------|
|
|
26
|
+
| `variant` | `"label" \| "helper" \| "description" \| "error"` | `"helper"` | Visual and semantic variant; `"error"` renders with `role="alert"` |
|
|
27
|
+
| `size` | `"xl" \| "lg" \| "md" \| "sm" \| "xs"` | `"md"` | Text size |
|
|
28
|
+
| `icon` | `React.ReactNode` | — | Icon displayed after the text |
|
|
29
|
+
| `showIcon` | `boolean` | `false` | Whether to show the icon |
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@xsolla/xui-supporting-text",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.97.0-pr154.1771807405",
|
|
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.97.0-pr154.1771807405",
|
|
14
|
+
"@xsolla/xui-icons": "0.97.0-pr154.1771807405",
|
|
15
|
+
"@xsolla/xui-primitives-core": "0.97.0-pr154.1771807405"
|
|
16
16
|
},
|
|
17
17
|
"peerDependencies": {
|
|
18
18
|
"react": ">=16.8.0",
|