🎨 Improve detect Pad device https://github.com/siyuan-note/siyuan/issues/8497
This commit is contained in:
parent
2b57a21f05
commit
eafed90b76
1 changed files with 3 additions and 2 deletions
|
@ -206,8 +206,9 @@ func serveAppearance(ginServer *gin.Engine) {
|
|||
|
||||
if strings.Contains(userAgentHeader, "Electron") {
|
||||
location.Path = "/stage/build/app/"
|
||||
} else if strings.Contains(userAgentHeader, "Pad") {
|
||||
// Improve detecting Pad device, treat it as desktop device https://github.com/siyuan-note/siyuan/issues/8435
|
||||
} else if strings.Contains(userAgentHeader, "Pad") ||
|
||||
(strings.ContainsAny(userAgentHeader, "Android") && !strings.Contains(userAgentHeader, "Mobile")) {
|
||||
// Improve detecting Pad device, treat it as desktop device https://github.com/siyuan-note/siyuan/issues/8435 https://github.com/siyuan-note/siyuan/issues/8497
|
||||
location.Path = "/stage/build/desktop/"
|
||||
} else {
|
||||
if idx := strings.Index(userAgentHeader, "Mozilla/"); 0 < idx {
|
||||
|
|
Loading…
Add table
Reference in a new issue