Fix: Forzar window.open() en desktop para bypassear capture_links
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 1m0s
All checks were successful
build-and-deploy / build-and-deploy (push) Successful in 1m0s
- Agregar handler @click en app-items - En desktop, prevenir default y usar window.open() directamente - Esto bypasea completamente el sistema capture_links del manifest - Mantener enlaces nativos como fallback para móvil
This commit is contained in:
@@ -73,6 +73,7 @@
|
||||
:href="app.launchUrl"
|
||||
:target="shouldOpenInNewTab(app) ? '_blank' : '_self'"
|
||||
class="app-card"
|
||||
@click="handleAppClick($event, app)"
|
||||
>
|
||||
<div class="app-card-content">
|
||||
<div class="app-icon">
|
||||
@@ -321,6 +322,21 @@ const shouldOpenInNewTab = (app: Application): boolean => {
|
||||
return result
|
||||
}
|
||||
|
||||
// Manejar click en app-items
|
||||
// En desktop, forzar apertura con window.open() para bypassear capture_links
|
||||
const handleAppClick = (event: MouseEvent, app: Application) => {
|
||||
if (shouldOpenInNewTab(app)) {
|
||||
// Prevenir comportamiento por defecto del enlace
|
||||
event.preventDefault()
|
||||
|
||||
console.log('[ApplicationsList] Abriendo en nueva ventana con window.open():', app.launchUrl)
|
||||
|
||||
// Forzar apertura con window.open() para bypassear el manifest
|
||||
window.open(app.launchUrl, '_blank')
|
||||
}
|
||||
// Si no debe abrir en nueva tab, dejar que el enlace funcione normalmente
|
||||
}
|
||||
|
||||
// Limpiar interval cuando el componente se desmonte
|
||||
onUnmounted(() => {
|
||||
clearInterval(refreshInterval)
|
||||
|
||||
Reference in New Issue
Block a user