lite-questionnaire 1.0.0 → 1.0.2
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 +22 -0
- package/image/logo.png +0 -0
- package/image//345/217/214/351/200/211/345/261/225/347/244/272.gif +0 -0
- package/image//345/244/232/351/200/211/345/256/232/344/271/211.gif +0 -0
- package/image//346/226/207/346/234/254/350/276/223/345/205/245/345/261/225/347/244/272.gif +0 -0
- package/image//350/257/204/345/210/206/351/207/217/350/241/250.gif +0 -0
- package/image//351/200/211/346/213/251/345/261/225/347/244/272.gif +0 -0
- package/index.ts +2 -2
- package/package.json +6 -3
package/README.md
CHANGED
|
@@ -31,6 +31,28 @@
|
|
|
31
31
|
|
|
32
32
|
> **注意**:所有问题均为必答。`confirm` 和 `rating` 具有默认值(是 / 3),无需进入编辑态即可直接 Enter 提交。`text` 类型留空按 Enter 会显示错误提示,不可跳过。←/→ 切换问题时自动提交当前草稿(有值则保存,无值则标红)。
|
|
33
33
|
|
|
34
|
+
## 视觉演示
|
|
35
|
+
|
|
36
|
+
### 单选
|
|
37
|
+
|
|
38
|
+
<img src="https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/%E9%80%89%E6%8B%A9%E5%B1%95%E7%A4%BA.gif" width="600" alt="单选展示" />
|
|
39
|
+
|
|
40
|
+
### 多选
|
|
41
|
+
|
|
42
|
+
<img src="https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/%E5%A4%9A%E9%80%89%E5%AE%9A%E4%B9%89.gif" width="600" alt="多选定义" />
|
|
43
|
+
|
|
44
|
+
### 文本输入
|
|
45
|
+
|
|
46
|
+
<img src="https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/%E6%96%87%E6%9C%AC%E8%BE%93%E5%85%A5%E5%B1%95%E7%A4%BA.gif" width="600" alt="文本输入展示" />
|
|
47
|
+
|
|
48
|
+
### 确认
|
|
49
|
+
|
|
50
|
+
<img src="https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/%E5%8F%8C%E9%80%89%E5%B1%95%E7%A4%BA.gif" width="600" alt="双选展示" />
|
|
51
|
+
|
|
52
|
+
### 评分
|
|
53
|
+
|
|
54
|
+
<img src="https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/%E8%AF%84%E5%88%86%E9%87%8F%E8%A1%A8.gif" width="600" alt="评分量表" />
|
|
55
|
+
|
|
34
56
|
## 参数与字段说明
|
|
35
57
|
|
|
36
58
|
顶层参数:
|
package/image/logo.png
ADDED
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
|
Binary file
|
package/index.ts
CHANGED
|
@@ -140,8 +140,8 @@ function questionnaireKey(questions: QuestionnaireParams["questions"]): string {
|
|
|
140
140
|
|
|
141
141
|
export default function questionnaire(pi: ExtensionAPI) {
|
|
142
142
|
pi.registerTool({
|
|
143
|
-
name: "questionnaire",
|
|
144
|
-
label: "Questionnaire",
|
|
143
|
+
name: "lite-questionnaire",
|
|
144
|
+
label: "Lite Questionnaire",
|
|
145
145
|
description:
|
|
146
146
|
"向用户展示交互式问卷。支持单选、多选、文本输入、确认、评分五种问题类型。" +
|
|
147
147
|
"支持条件子问题、约束校验、自定义选项和会话持久化。",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "lite-questionnaire",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.2",
|
|
4
4
|
"description": "轻量级交互式问卷工具 — 单选、多选、文本、确认、评分,带条件子问题和声明式校验",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi-package",
|
|
@@ -11,13 +11,15 @@
|
|
|
11
11
|
"tui"
|
|
12
12
|
],
|
|
13
13
|
"license": "MIT",
|
|
14
|
-
"author": "
|
|
14
|
+
"author": "yunwuhai",
|
|
15
15
|
"repository": {
|
|
16
16
|
"type": "git",
|
|
17
17
|
"url": "git+https://github.com/yunwuhai/lite-questionnaire.git"
|
|
18
18
|
},
|
|
19
19
|
"pi": {
|
|
20
|
-
"extensions": ["./index.ts"]
|
|
20
|
+
"extensions": ["./index.ts"],
|
|
21
|
+
"skills": ["./skills"],
|
|
22
|
+
"image": "https://raw.githubusercontent.com/yunwuhai/lite-questionnaire/main/image/logo.png"
|
|
21
23
|
},
|
|
22
24
|
"peerDependencies": {
|
|
23
25
|
"@earendil-works/pi-coding-agent": "*",
|
|
@@ -33,6 +35,7 @@
|
|
|
33
35
|
"types.ts",
|
|
34
36
|
"modules/",
|
|
35
37
|
"design/",
|
|
38
|
+
"image/",
|
|
36
39
|
"skills/",
|
|
37
40
|
"README.md"
|
|
38
41
|
]
|