Skip to content

Commit 99e82ae

Browse files
authored
docs: Update annotations-form.md with checkbox details (#526)
* docs: Update annotations-form.md with checkbox details Clarified that 'checkbox' input components should use 'on-value' and 'off-value' for string values. * docs: Update annotations form documentation for checkbox input (#1)
1 parent 44ad38c commit 99e82ae

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

docs/developer-guide/annotations-form.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ title: 元数据表单定义
77
定义元数据编辑表单同样使用 `FormKit Schema`,但和主题或插件的定义方式稍有不同,其中输入组件类型可参考 [表单定义](./form-schema.md)
88

99
:::info 提示
10-
因为 `metadata.annotations` 是一个键值都为字符串类型的对象,所以表单项的值必须为字符串类型。这就意味着,FormKit 的 `number``group``repeater` 等类型的输入组件都不能使用。
10+
因为 `metadata.annotations` 是一个键值都为字符串类型的对象,所以表单项的值必须为字符串类型。这就意味着,FormKit 的 `number``group``repeater` 等类型的输入组件都不能使用。`checkbox` 类型的输入组件应通过 `on-value``off-value` 指定字符串值,以替代默认的布尔值。
1111
:::
1212

1313
## AnnotationSetting 资源定义方式

versioned_docs/version-2.21/developer-guide/annotations-form.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ title: 元数据表单定义
77
定义元数据编辑表单同样使用 `FormKit Schema`,但和主题或插件的定义方式稍有不同,其中输入组件类型可参考 [表单定义](./form-schema.md)
88

99
:::info 提示
10-
因为 `metadata.annotations` 是一个键值都为字符串类型的对象,所以表单项的值必须为字符串类型。这就意味着,FormKit 的 `number``group``repeater` 等类型的输入组件都不能使用。
10+
因为 `metadata.annotations` 是一个键值都为字符串类型的对象,所以表单项的值必须为字符串类型。这就意味着,FormKit 的 `number``group``repeater` 等类型的输入组件都不能使用。`checkbox` 类型的输入组件应通过 `on-value``off-value` 指定字符串值,以替代默认的布尔值。
1111
:::
1212

1313
## AnnotationSetting 资源定义方式

0 commit comments

Comments
 (0)