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

[joy-ui] Unexpected behavior of some components, RTL #38939

Open
2 tasks done
xcode-it opened this issue Sep 12, 2023 · 2 comments
Open
2 tasks done

[joy-ui] Unexpected behavior of some components, RTL #38939

xcode-it opened this issue Sep 12, 2023 · 2 comments
Assignees
Labels
docs Improvements or additions to the documentation package: joy-ui Specific to @mui/joy

Comments

@xcode-it
Copy link
Contributor

Duplicates

  • I have searched the existing issues

Latest version

  • I have tested the latest version

Steps to reproduce 🕹

Link to live example:
codesandbox

Current behavior 😯

Tested on RadioButton, Select, and CheckBox

position is set to absolute by default is causing un-expected behavior when used in RTL. as shown in codesandbox demo.

Expected behavior 🤔

position is set to unset fixed the issue...

Context 🔦

No response

Your environment 🌎

npx @mui/envinfo
  System:
    OS: Windows 10 10.0.22621
  Binaries:
    Node: 18.6.0 - C:\kernal\nodejs\node.EXE
    Yarn: 1.22.19 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 9.7.2 - C:\kernal\nodejs\npm.CMD
  Browsers:
    Chrome: 116.0.5845.180
    Edge: Spartan (44.22621.2215.0), Chromium (116.0.1938.76)
  npmPackages:
    @emotion/react: ^11.11.1 => 11.11.1
    @emotion/styled: ^11.11.0 => 11.11.0
    @mui/base:  5.0.0-beta.12
    @mui/core-downloads-tracker:  5.14.8
    @mui/icons-material: ^5.14.3 => 5.14.6
    @mui/joy: 5.0.0-beta.5 => 5.0.0-beta.5
    @mui/material: ^5.14.8 => 5.14.8
    @mui/system: ^5.14.8 => 5.14.8
    @mui/types:  7.2.4
    @mui/utils: ^5.14.7 => 5.14.8
    @types/react:  18.2.21
    react: ^18.2.0 => 18.2.0
    react-dom: ^18.2.0 => 18.2.0
    styled-components: ^5.3.11 => 5.3.11
@xcode-it xcode-it added the status: waiting for maintainer These issues haven't been looked at yet by a maintainer label Sep 12, 2023
@danilo-leal danilo-leal added the package: joy-ui Specific to @mui/joy label Sep 12, 2023
@SafaAlfulaij
Copy link

SafaAlfulaij commented Sep 23, 2023

As documented in https://mui.com/material-ui/guides/right-to-left/, you need to apply the CSS post processor on theme provider for RTL to work as expected.

Forked your sandbox with a demo: https://codesandbox.io/s/rtl-position-unset-forked-q4rt23?file=/src/App.js

Notice how ThemeProvider accepts a locale (unused) prop. You can use it to switch between LTR and RTL layouts.

@siriwatknp siriwatknp added docs Improvements or additions to the documentation and removed status: waiting for maintainer These issues haven't been looked at yet by a maintainer labels Sep 24, 2023
@siriwatknp
Copy link
Member

Mark this as docs improvement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
docs Improvements or additions to the documentation package: joy-ui Specific to @mui/joy
Projects
None yet
Development

No branches or pull requests

4 participants