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

[Demo] 示例代码优化 #920

Closed
honkinglin opened this issue Jun 23, 2022 · 6 comments
Closed

[Demo] 示例代码优化 #920

honkinglin opened this issue Jun 23, 2022 · 6 comments
Labels
🙏🏻 help wanted Extra attention is needed

Comments

@honkinglin
Copy link
Collaborator

这个功能解决了什么问题

目前大部分 demo 展示的间距都是通过 tdesign-demo-block-rowtdesign-demo-block-column 公共 style 来控制,虽然在codesanbox 做了支持但是用户复制代码到自己项目中样式丢失容易引起误会。

你建议的方案是什么

现已支持了 Space 组件,可以将 demo 中的间距问题用 Space 来处理,由于工作量较大,欢迎各位开发者协助优化 demo 代码。

@honkinglin honkinglin added the 🙏🏻 help wanted Extra attention is needed label Jun 23, 2022
@github-actions
Copy link
Contributor

👋 @HQ-Lin,感谢给 TDesign 提出了 issue。
请根据 issue 模版确保背景信息的完善,我们将调查并尽快回复你。

@github-actions
Copy link
Contributor

任何人都可以处理此问题。
请务必在您的 pull request 中引用此问题。
感谢你的贡献! ✨

@richerfu
Copy link
Contributor

richerfu commented Jun 23, 2022

image

示例应该尽量保持简洁。后续新增example如果存在以上这种结构,在不影响正常样式的情况下,外部的`div`应该去掉

@honkinglin
Copy link
Collaborator Author

image

示例应该尽量保持简洁。后续新增example如果存在以上这种结构,在不影响正常样式的情况下,外部的div应该去掉

是的,demo代码尽量精简只跟组件有关,部分demo为了美观还有很多定制样式,后面我在想办法精简一下

@richerfu
Copy link
Contributor

  1. 所有组件均已替换,但是项目中还存在部分示例问题。比如部分组件的代码示例为了示例的美观写了特殊的className,后续需要处理。
  2. 部分示例文件多余,未在文档中表现,需要梳理是否需要
  3. 部分文档示例未补全

@honkinglin
Copy link
Collaborator Author

  1. 所有组件均已替换,但是项目中还存在部分示例问题。比如部分组件的代码示例为了示例的美观写了特殊的className,后续需要处理。
  2. 部分示例文件多余,未在文档中表现,需要梳理是否需要
  3. 部分文档示例未补全

感谢老哥支援,辛苦~还有一些细节我看下怎么处理合适吧

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🙏🏻 help wanted Extra attention is needed
Projects
None yet
Development

No branches or pull requests

2 participants