iter(g206): rate 支持再次点击清除评分

This commit is contained in:
HIsheR
2026-10-26 19:16:48 +08:00
parent dae6353b58
commit f763f635d1
5 changed files with 18 additions and 6 deletions
+6 -1
View File
@@ -1,6 +1,6 @@
{
"$schema": "ui-arch-registry-index/0.1",
"generatedAt": "2026-10-26T11:15:10.295Z",
"generatedAt": "2026-10-26T11:16:26.554Z",
"repoRoot": ".",
"packages": [
{
@@ -1547,6 +1547,11 @@
"t": "(value: number) => void",
"k": 1,
"d": "评分变化回调"
},
{
"n": "allowClear",
"t": "boolean",
"d": "允许清除:再次点击当前分值(半星须精确相等)清零;缺省不可清"
}
],
"example": "const score = signal(0); rate({ value: score, max: 5, onChange: (v) => console.log(v) })",