Skip to content

🐛 [Bug]: 在vite 构建工具开发环境下,如果项目里使用fullscreen类名,会被opentiny里的fluent-editor文件夹下全局.fullscreen覆盖,导致样式错乱的问题 #3234

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

Open
vuuuue opened this issue Apr 2, 2025 · 1 comment
Labels
bug Something isn't working

Comments

@vuuuue
Copy link

vuuuue commented Apr 2, 2025

Version

latest

Vue Version

latest

Link to minimal reproduction

none

Step to reproduce

Image

What is expected

No response

What is actually happening

No response

What is your project name

Tiny

Any additional comments (optional)

No response

@github-actions github-actions bot added the bug Something isn't working label Apr 2, 2025
Copy link

感谢您报告这个问题。根据您的描述,问题出现在使用 Vite 构建工具的开发环境中,当项目中使用 fullscreen 类名时,会被 opentiny 中的 fluent-editor 文件夹下的全局 .fullscreen 样式覆盖,导致样式错乱。

为了解决这个问题,您可以尝试以下几种方法:

  1. 命名空间样式:为您的 fullscreen 类名添加一个特定的命名空间,以避免与 opentiny 的全局样式冲突。例如,将 fullscreen 改为 myproject-fullscreen

  2. 提高样式优先级:在您的样式中使用更高优先级的选择器,或者使用 !important 来覆盖 opentiny 的样式。

  3. 修改 opentiny 样式:如果您有权限修改 opentiny 的源代码,可以考虑将 .fullscreen 样式的作用范围限制在特定组件内,而不是全局。

如果您需要进一步的帮助或有其他问题,请随时告诉我。

🪧 Tips For further assistance, please describe your question in the comments and @petercat-assistant to start a conversation with me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant