mirror of
https://github.com/Sagit-chu/flvx.git
synced 2026-10-08 18:56:37 +08:00
修复部分浏览器判定为app的bug
This commit is contained in:
@@ -38,6 +38,16 @@ export async function deletePanelAddress(name: string){
|
||||
}
|
||||
}
|
||||
|
||||
export function isWebViewFunc(){
|
||||
if((window as any).JsInterface !== undefined && (window as any).JsInterface.getPanelAddresses !== undefined) {
|
||||
return true;
|
||||
}else if((window as any).webkit && (window as any).webkit.messageHandlers && (window as any).webkit.messageHandlers.getPanelAddresses !== undefined) {
|
||||
return true;
|
||||
}else {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
// 验证面板地址格式
|
||||
export function validatePanelAddress(address: string): boolean {
|
||||
try {
|
||||
|
||||
Reference in New Issue
Block a user