@lynx-js/lynx-ui-button 3.130.0 → 3.133.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/CHANGELOG.md +14 -0
- package/dist/types/index.docs.d.ts +33 -0
- package/dist/types/index.docs.d.ts.map +1 -1
- package/package.json +3 -3
- package/src/types/index.docs.ts +37 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @lynx-js/lynx-ui-button
|
|
2
2
|
|
|
3
|
+
## 3.133.0
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies [[`85d2e9d`](https://github.com/lynx-family/lynx-ui/commit/85d2e9d12e9aeee3256856f1be0076524ddb7d8a)]:
|
|
8
|
+
- @lynx-js/lynx-ui-common@3.133.0
|
|
9
|
+
|
|
10
|
+
## 3.131.0
|
|
11
|
+
|
|
12
|
+
### Patch Changes
|
|
13
|
+
|
|
14
|
+
- Updated dependencies [[`bc167c5`](https://github.com/lynx-family/lynx-ui/commit/bc167c5d03cdb344156e897c4d2d69f95bf7d29b)]:
|
|
15
|
+
- @lynx-js/lynx-ui-common@3.131.0
|
|
16
|
+
|
|
3
17
|
## 3.130.0
|
|
4
18
|
|
|
5
19
|
### Patch Changes
|
|
@@ -59,4 +59,37 @@ export interface ButtonProps {
|
|
|
59
59
|
*/
|
|
60
60
|
onClick?: () => void;
|
|
61
61
|
}
|
|
62
|
+
/**
|
|
63
|
+
* The interactive status passed to Button's render-prop children.
|
|
64
|
+
* @zh 传入 Button render-prop children 的交互状态。
|
|
65
|
+
*/
|
|
66
|
+
export interface ButtonRenderProps {
|
|
67
|
+
/**
|
|
68
|
+
* Whether the button is currently being pressed (and not disabled).
|
|
69
|
+
* @zh 按钮当前是否处于按下态(且未被禁用)。
|
|
70
|
+
*/
|
|
71
|
+
active?: boolean;
|
|
72
|
+
/**
|
|
73
|
+
* Whether the button is disabled.
|
|
74
|
+
* @zh 按钮是否处于禁用态。
|
|
75
|
+
*/
|
|
76
|
+
disabled?: boolean;
|
|
77
|
+
}
|
|
78
|
+
/**
|
|
79
|
+
* UI variants applied by Button based on its interactive status.
|
|
80
|
+
* Use them as CSS selectors to style different states.
|
|
81
|
+
* @zh Button 根据交互状态注入的 ui-variants,可用于 CSS selector 按状态定制样式。
|
|
82
|
+
*/
|
|
83
|
+
export interface ButtonUiVariants {
|
|
84
|
+
/**
|
|
85
|
+
* Applied when `status.active` is true.
|
|
86
|
+
* @zh 当 status.active 为 true 时生效,可用于 `.ui-active { ... }`。
|
|
87
|
+
*/
|
|
88
|
+
'ui-active'?: boolean;
|
|
89
|
+
/**
|
|
90
|
+
* Applied when `status.disabled` is true.
|
|
91
|
+
* @zh 当 status.disabled 为 true 时生效,可用于 `.ui-disabled { ... }`。
|
|
92
|
+
*/
|
|
93
|
+
'ui-disabled'?: boolean;
|
|
94
|
+
}
|
|
62
95
|
//# sourceMappingURL=index.docs.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.docs.d.ts","sourceRoot":"","sources":["../../src/types/index.docs.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE/C,OAAO,KAAK,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE9D;;;GAGG;AACH,MAAM,WAAW,WAAW;IAC1B;;;;;;;OAOG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;;;;;;OAOG;IACH,QAAQ,CAAC,EACL,SAAS,GACT,CAAC,CACD,KAAK,EAAE;QACL,MAAM,EAAE,OAAO,CAAA;QACf,QAAQ,EAAE,OAAO,CAAA;KAClB,KACE,SAAS,CAAC,CAAA;IACjB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,aAAa,CAAA;IACrB;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB"}
|
|
1
|
+
{"version":3,"file":"index.docs.d.ts","sourceRoot":"","sources":["../../src/types/index.docs.ts"],"names":[],"mappings":"AAIA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE/C,OAAO,KAAK,EAAE,aAAa,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAE9D;;;GAGG;AACH,MAAM,WAAW,WAAW;IAC1B;;;;;;;OAOG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;;;;;;OAOG;IACH,QAAQ,CAAC,EACL,SAAS,GACT,CAAC,CACD,KAAK,EAAE;QACL,MAAM,EAAE,OAAO,CAAA;QACf,QAAQ,EAAE,OAAO,CAAA;KAClB,KACE,SAAS,CAAC,CAAA;IACjB;;;;;;OAMG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAClB;;;;;;OAMG;IACH,KAAK,CAAC,EAAE,aAAa,CAAA;IACrB;;;;;;OAMG;IACH,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACrB;AAED;;;GAGG;AACH,MAAM,WAAW,iBAAiB;IAChC;;;OAGG;IACH,MAAM,CAAC,EAAE,OAAO,CAAA;IAEhB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED;;;;GAIG;AACH,MAAM,WAAW,gBAAgB;IAC/B;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAA;IAErB;;;OAGG;IACH,aAAa,CAAC,EAAE,OAAO,CAAA;CACxB"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lynx-js/lynx-ui-button",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.133.0",
|
|
4
4
|
"repository": {
|
|
5
5
|
"type": "git",
|
|
6
6
|
"url": "git+https://github.com/lynx-family/lynx-ui.git",
|
|
@@ -26,10 +26,10 @@
|
|
|
26
26
|
],
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"clsx": "^2.1.1",
|
|
29
|
-
"@lynx-js/lynx-ui-common": "3.
|
|
29
|
+
"@lynx-js/lynx-ui-common": "3.133.0"
|
|
30
30
|
},
|
|
31
31
|
"devDependencies": {
|
|
32
|
-
"@lynx-js/react": "0.
|
|
32
|
+
"@lynx-js/react": "0.114.0",
|
|
33
33
|
"@lynx-js/types": "3.6.0",
|
|
34
34
|
"@rslib/core": "^0.16.0",
|
|
35
35
|
"@types/react": "^18.3.8",
|
package/src/types/index.docs.ts
CHANGED
|
@@ -69,3 +69,40 @@ export interface ButtonProps {
|
|
|
69
69
|
*/
|
|
70
70
|
onClick?: () => void
|
|
71
71
|
}
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* The interactive status passed to Button's render-prop children.
|
|
75
|
+
* @zh 传入 Button render-prop children 的交互状态。
|
|
76
|
+
*/
|
|
77
|
+
export interface ButtonRenderProps {
|
|
78
|
+
/**
|
|
79
|
+
* Whether the button is currently being pressed (and not disabled).
|
|
80
|
+
* @zh 按钮当前是否处于按下态(且未被禁用)。
|
|
81
|
+
*/
|
|
82
|
+
active?: boolean
|
|
83
|
+
|
|
84
|
+
/**
|
|
85
|
+
* Whether the button is disabled.
|
|
86
|
+
* @zh 按钮是否处于禁用态。
|
|
87
|
+
*/
|
|
88
|
+
disabled?: boolean
|
|
89
|
+
}
|
|
90
|
+
|
|
91
|
+
/**
|
|
92
|
+
* UI variants applied by Button based on its interactive status.
|
|
93
|
+
* Use them as CSS selectors to style different states.
|
|
94
|
+
* @zh Button 根据交互状态注入的 ui-variants,可用于 CSS selector 按状态定制样式。
|
|
95
|
+
*/
|
|
96
|
+
export interface ButtonUiVariants {
|
|
97
|
+
/**
|
|
98
|
+
* Applied when `status.active` is true.
|
|
99
|
+
* @zh 当 status.active 为 true 时生效,可用于 `.ui-active { ... }`。
|
|
100
|
+
*/
|
|
101
|
+
'ui-active'?: boolean
|
|
102
|
+
|
|
103
|
+
/**
|
|
104
|
+
* Applied when `status.disabled` is true.
|
|
105
|
+
* @zh 当 status.disabled 为 true 时生效,可用于 `.ui-disabled { ... }`。
|
|
106
|
+
*/
|
|
107
|
+
'ui-disabled'?: boolean
|
|
108
|
+
}
|