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

feat: add extension point for extend data list operation items #4452

Merged

Conversation

ruibaby
Copy link
Member

@ruibaby ruibaby commented Aug 21, 2023

What type of PR is this?

/area console
/kind feature
/milestone 2.9.x

What this PR does / why we need it:

添加扩展数据列表中操作按钮列表的基础能力,并为文章和插件管理列表的操作按钮列表添加扩展点以测试此扩展能力。

todo:

  • 场景测试
  • 文档

Which issue(s) this PR fixes:

Ref #4177

Special notes for your reviewer:

可以使用以下插件(仅用于测试)进行测试:

安装之后可以在文章列表的操作按钮列表中新增一个 导出为 Markdown 文档 的按钮,点击之后会导出一个 Markdown 文档。

image

Does this PR introduce a user-facing change?

Console 端的文章和插件列表的操作按钮列表支持扩展。

@f2c-ci-robot f2c-ci-robot bot added area/console Issues or PRs related to the Halo Console do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Aug 21, 2023
@f2c-ci-robot f2c-ci-robot bot added this to the 2.9.x milestone Aug 21, 2023
@f2c-ci-robot f2c-ci-robot bot added the kind/feature Categorizes issue or PR as related to a new feature. label Aug 21, 2023
@codecov
Copy link

codecov bot commented Aug 21, 2023

Codecov Report

Merging #4452 (a402a13) into main (5c11556) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main    #4452   +/-   ##
=========================================
  Coverage     60.84%   60.84%           
  Complexity     2525     2525           
=========================================
  Files           372      372           
  Lines         13015    13015           
  Branches        935      935           
=========================================
  Hits           7919     7919           
  Misses         4645     4645           
  Partials        451      451           

@f2c-ci-robot f2c-ci-robot bot added the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 22, 2023
@f2c-ci-robot f2c-ci-robot bot removed the needs-rebase Indicates a PR cannot be merged because it has merge conflicts with HEAD. label Aug 25, 2023
Signed-off-by: Ryan Wang <i@ryanc.cc>
Signed-off-by: Ryan Wang <i@ryanc.cc>
@ruibaby
Copy link
Member Author

ruibaby commented Aug 25, 2023

/retitle feat: add extension point for extend data list operation items

Ready for code review

@f2c-ci-robot f2c-ci-robot bot changed the title WIP: feat: add extension point for extend data list operation items feat: add extension point for extend data list operation items Aug 25, 2023
@f2c-ci-robot f2c-ci-robot bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Aug 25, 2023
Signed-off-by: Ryan Wang <i@ryanc.cc>
Copy link
Member

@guqing guqing left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/lgtm

测试正常

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Aug 25, 2023
Copy link
Member

@JohnNiang JohnNiang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

/approve

@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Aug 25, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JohnNiang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@f2c-ci-robot f2c-ci-robot bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 25, 2023
@f2c-ci-robot f2c-ci-robot bot merged commit 70eb039 into halo-dev:main Aug 25, 2023
4 checks passed
@ruibaby ruibaby deleted the feat/entity-dropdown-items-extension-points branch August 25, 2023 09:22
@ruibaby ruibaby removed this from the 2.9.x milestone Aug 25, 2023
@ruibaby ruibaby added this to the 2.9.0 milestone Aug 25, 2023
f2c-ci-robot bot pushed a commit that referenced this pull request Aug 31, 2023
#### What type of PR is this?

/area console
/kind improvement
/milestone 2.9.x

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

禁用 Dropdown 组件的自动销毁 dom 节点功能,以适配 #4452 中拓展操作选项的场景。

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

```release-note
None
```
f2c-ci-robot bot pushed a commit that referenced this pull request Aug 31, 2023
#### What type of PR is this?

/area console
/kind feature
/milestone 2.9.x

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

Halo 在 #4452 中为数据列表的操作选项添加了拓展点,用于通过插件扩展操作选项。但忽略了操作选项的组件需要自定义并且自行处理点击事件,这个时候组件应该比较难拿到数据列表项的数据。

此 PR 对此进行优化,在扩展点方法传入了需要的数据。

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

```release-note
None
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/console Issues or PRs related to the Halo Console kind/feature Categorizes issue or PR as related to a new feature. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants