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

安卓Pad端异常 #75

Closed
Soltus opened this issue Jun 16, 2024 · 14 comments
Closed

安卓Pad端异常 #75

Soltus opened this issue Jun 16, 2024 · 14 comments
Labels
mobile Related to mobile devices

Comments

@Soltus
Copy link

Soltus commented Jun 16, 2024

右下角的元素跑到左上角了,在电脑上是正常的
9f5a95d266a794e93e7ba22d18aff19c

@mustakshif
Copy link
Owner

mustakshif commented Jun 16, 2024

感谢反馈。我手边没有安卓平板设备,但尝试修复了一下,麻烦下载一下 theme.js 替换本地主题文件夹下的同名文件,然后重进思源看是否还有问题。

不对 这好像是华为平板,能去替换本地文件吗 😂

@mustakshif
Copy link
Owner

如果不方便的话,可以等明天更新主题后再看一下

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

试了一下没有解决问题。我对右下角进行了魔改,应该是冲突了。

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

但是桌面端没有问题,会不会是webview版本问题?平板系统不更新了,内核版本是99,桌面端早就110+了

@mustakshif
Copy link
Owner

应该是主题的原因,我在电脑上给 body 元素添加 body--mobile 类名就可以复现。可能是主题 js 设备判断没写好,把安卓平板当手机设备了。。可以给我看一下你的设备的 userAgent 信息吗

@mustakshif mustakshif added bug Something isn't working mobile Related to mobile devices labels Jun 16, 2024
@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

body class="branch--Sillot body--desktop fn__flex-column body--mobile"
16868654554631ab6d3e3001299781d8

@mustakshif
Copy link
Owner

image

我用你的 ua 按我最新的 js 写法测试了一下,设备判断是没问题的,可是为什么你的 body 上还是有 body--mobile 呢 😂。替换过程是否成功了呢,还是说其他的插件添加了这个类名

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

你是通过 body--mobile 判断是手机端吗,通过 and not body--desktop 判断应该可以吧。我这里 body--mobile 就是移动端App的意思,平板手机都一样,伺服就不会有

@mustakshif
Copy link
Owner

我没有写 desktop 端的逻辑,因为默认就是,其他端的设备才需要判断一下,如果是移动设备主题 js 会添加一个 body--mobile 类名,平板端用的是浏览器 body--browser 类型

我这里 body--mobile 就是移动端App的意思,平板手机都一样,伺服就不会有

意思是这个 body--mobile 类名是你自己加上去的吗

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

意思是这个 body--mobile 类名是你自己加上去的吗

应该没错

@mustakshif
Copy link
Owner

那好吧 我把主题添加的类名再添加一个 asri 前缀,避免潜在冲突

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

🤍

@mustakshif
Copy link
Owner

改好了,麻烦替换下最新的 theme.css 和 theme.js 看看是否还有问题~

@Soltus
Copy link
Author

Soltus commented Jun 16, 2024

fa8d6ec90dc22d7b66b227146449ff29

@Soltus Soltus closed this as completed Jun 16, 2024
@mustakshif mustakshif removed the bug Something isn't working label Jun 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mobile Related to mobile devices
Projects
None yet
Development

No branches or pull requests

2 participants