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

fix(tabs): fix content adaptive problem when direction is rtl #3415

Closed
wants to merge 1 commit into from

Conversation

jadelike-wine
Copy link
Contributor

Types of changes

  • 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

#3280
image
image

Solution

How is the change tested?

  <a-tabs default-active-key="2" style="direction: rtl;" >
    <a-tab-pane key="1" title="Tab 1">
      Content of Tab Panel 1
    </a-tab-pane>
    <a-tab-pane key="2" title="Tab 2">
      Content of Tab Panel 2
    </a-tab-pane>
    <a-tab-pane key="3">
      <template #title>Tab 3</template>
      Content of Tab Panel 3
    </a-tab-pane>
  </a-tabs>

Changelog

Component Changelog(CN) Changelog(EN) Related issues
tabs 解决 direction为 rtl 时内容自适应问题 fix content adaptive problem when direction is rtl #3280

Checklist:

  • Test suite passes (npm run test)
  • Provide changelog for relevant changes (e.g. bug fixes and new features) if applicable.
  • 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

Copy link

codesandbox bot commented Jan 9, 2025

Review or Edit in CodeSandbox

Open the branch in Web EditorVS CodeInsiders

Open Preview

@oljc
Copy link
Member

oljc commented Jan 9, 2025

@jadelike-wine 感谢你的贡献!该 PR 解决了部分 issues 中提到的问题,但仍存在一些不足,尚未完全解决 RTL 模式下的样式问题。由于 TabsRTL 模式下需要处理的样式变动较多,建议参考 ReactRTL 进一步完善。或者交由 Maintainer 后续优化。

@jadelike-wine
Copy link
Contributor Author

@jadelike-wine 感谢你的贡献!该 PR 解决了部分 issues 中提到的问题,但仍存在一些不足,尚未完全解决 RTL 模式下的样式问题。由于 TabsRTL 模式下需要处理的样式变动较多,建议参考 ReactRTL 进一步完善。或者交由 Maintainer 后续优化。

@oljc ok,我去看下react那边的源码吧先

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

Successfully merging this pull request may close these issues.

2 participants