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: Markdown 中支持 Tabs 选项卡 #352

Open
AGDholo opened this issue Oct 21, 2020 · 1 comment
Open

feat: Markdown 中支持 Tabs 选项卡 #352

AGDholo opened this issue Oct 21, 2020 · 1 comment
Labels
enhancement New feature or request

Comments

@AGDholo
Copy link

AGDholo commented Oct 21, 2020

Description

如果一种行为存在多种方式可以采用,那么用选项卡的方式可能会更好,例如:

image

Solution

参考:https://v2.docusaurus.io/docs/markdown-features/#tabs

需要注意的是,它的选项卡是全局同步的,例如我点击了图上所述的 yarn,那么在所有文档中存在此 ID 的 Tabs 都会自动切换过去。

@AGDholo AGDholo added the enhancement New feature or request label Oct 21, 2020
@xrkffgg
Copy link
Member

xrkffgg commented Dec 3, 2020

代码显示的时候 使用了Tabs。本地试了一下可以拿过来用。

至于全局同步,我觉得不一定要做成这种。

使用了 Tabs 后,如果要想显示高亮的代码,需要使用 SourceCode ,但感觉这个是不是 对 换行的 不太支持。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants