arco-design-vue icon indicating copy to clipboard operation
arco-design-vue copied to clipboard

feat(calendar): add content slot to render schedule

Open Juzisuan965 opened this issue 7 months ago • 2 comments
trafficstars

Types of changes

  • [x] New feature
  • [ ] Bug fix
  • [ ] Enhancement
  • [ ] Component style change
  • [ ] Typescript definition change
  • [ ] Documentation change
  • [ ] Coding style change
  • [ ] Refactoring
  • [ ] Test cases
  • [ ] Continuous integration
  • [ ] Breaking change
  • [ ] Others

Background and context

Calendar组件如果通过default 插槽来实现日程(比如国定假日、节气、备注)的展示,会失去默认的日期点击事件。 https://github.com/arco-design/arco-design-vue/issues/3464

Solution

新增content插槽,实现日程展示,保留默认的日期展示与点击事件。

How is the change tested?

人工测试来保证新增的slot正常工作,不影响其他内容。

Changelog

Component Changelog(CN) Changelog(EN) Related issues
Calendar 新增 content 插槽 Added content slot Close https://github.com/arco-design/arco-design-vue/issues/3464

Checklist:

  • [x] Test suite passes (npm run test)
  • [x] Provide changelog for relevant changes (e.g. bug fixes and new features) if applicable.
  • [x] Changes are submitted to the appropriate branch (e.g. features should be submitted to feature branch and others should be submitted to main branch)

Other information

这个PR能够让Calendar提供类似日程的功能,而保留默认的日期展示、事件点击,便于开发者使用

Juzisuan965 avatar Mar 28 '25 08:03 Juzisuan965

Review or Edit in CodeSandbox

Open the branch in Web EditorVS CodeInsiders
Open Preview

codesandbox[bot] avatar Mar 28 '25 08:03 codesandbox[bot]

@oljc review下不?

Juzisuan965 avatar May 06 '25 02:05 Juzisuan965