Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

表单定义中的repeater组件增加最小和最大属性限制要添加或删除的项目数量 #3449

Closed
ttiv opened this issue Mar 3, 2023 · 2 comments · Fixed by #3965
Assignees
Labels
area/console Issues or PRs related to the Halo Console kind/improvement Categorizes issue or PR as related to a improvement.
Milestone

Comments

@ttiv
Copy link

ttiv commented Mar 3, 2023

你当前使用的版本

2.3.0

描述一下此特性

期望表单定义中的repeater组件增加最小和最大属性,使用这些属性来限制要添加或删除的项目数量。

附加信息

image

@ruibaby
Copy link
Member

ruibaby commented Mar 3, 2023

/area console
/kind improvement

@f2c-ci-robot f2c-ci-robot bot added area/console Issues or PRs related to the Halo Console kind/improvement Categorizes issue or PR as related to a improvement. labels Mar 3, 2023
@ruibaby ruibaby added good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. and removed area/console Issues or PRs related to the Halo Console labels Mar 7, 2023
@ruibaby
Copy link
Member

ruibaby commented May 18, 2023

/assign

@ruibaby ruibaby added this to the 2.6.x milestone May 18, 2023
@ruibaby ruibaby added area/console Issues or PRs related to the Halo Console and removed good first issue Denotes an issue ready for a new contributor, according to the "help wanted" guidelines. labels May 18, 2023
f2c-ci-robot bot pushed a commit that referenced this issue May 25, 2023
#### What type of PR is this?

/area console
/kind feature
/milestone 2.6.x

#### What this PR does / why we need it:

Console 端的 FormKit Repeater 输入框支持 min 和 max 参数用于限制项目数量。

<img width="630" alt="image" src="https://github.com/halo-dev/halo/assets/21301288/541da770-0439-4731-a796-a58277c33e05">

#### Which issue(s) this PR fixes:

Fixes #3449 

#### Special notes for your reviewer:

定义方式:

```yaml
- $formkit: repeater
  name: test_repeater
  label: 测试 Repeater
  min: 2
  max: 3
  children:
    - $formkit: text
      name: test_text
      label: 测试 Text
    - $formkit: select
      name: test_select
      label: 测试 Select
      options:
        - value: prose-gray
          label: prose-gray
        - value: prose-slate
          label: prose-slate
        - value: prose-zinc
          label: prose-zinc
        - value: prose-neutral
          label: prose-neutral
        - value: prose-stone
          label: prose-stone
```

#### Does this PR introduce a user-facing change?

```release-note
Console 端的 FormKit Repeater 输入框支持 min 和 max 参数用于限制项目数量。
```
@ruibaby ruibaby modified the milestones: 2.6.x, 2.6.0 May 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/console Issues or PRs related to the Halo Console kind/improvement Categorizes issue or PR as related to a improvement.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants