0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2024-12-16 20:26:19 -05:00

fix(ui): fix preview classname overwrite bug (#4038)

fix(ui): fix preview mode user can interact bug

fix preview mode user can interact bug
This commit is contained in:
simeng-li 2023-06-15 18:56:32 +08:00 committed by GitHub
parent bf0f3e133e
commit c743cef429
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 0 deletions

View file

@ -0,0 +1,7 @@
---
"@logto/ui": patch
---
Bug fix main flow preview mode should not allow user interaction.
- Recover the missing preview classname from the preview mode body element

View file

@ -38,6 +38,8 @@ const AppMeta = () => {
{experienceSettings?.customCss && <style>{experienceSettings.customCss}</style>}
<body
className={classNames(
// Should preserve any existing classNames
conditionalString(document.body.className),
platform === 'mobile' ? 'mobile' : 'desktop',
conditionalString(styles[theme])
)}