Update video player embedded (#1161)

This commit is contained in:
Graham Steffaniak authored and GitHub committed 2025-08-29 18:51:48 -05:00
1 parent a933d7ecbf
commit 5967422335
36 files changed
+338 -96

No files matched your search

+2 -2
View File
@@ -6,13 +6,13 @@ All notable changes to this project will be documented in this file. For commit
**New Features**:
- added embeded video subtitle support. @maxbin123 #1072 #1157
- added new default media player (can be disabled in user profile settings) @Kurami32 #1160
**Notes**:
- access management: specific folders/files with access are shown instead permission denied for parent folder
**BugFixes**:
- fixed search bar style bug in mobile #1147
- access management delay showing rule changes in the list fixed.
- access management: delay showing rule changes in the list fixed.
## v0.8.3-beta
+1
View File
@@ -49,6 +49,7 @@ type Preview struct {
Office bool `json:"office"` // show preview image for office files
PopUp bool `json:"popup"` // show larger popup preview when hovering
AutoplayMedia bool `json:"autoplayMedia"` // autoplay media files in preview
DefaultMediaPlayer bool `json:"defaultMediaPlayer"` // disable html5 media player and use the default media player
}
// User describes a user.
+3 -3
View File
@@ -96,7 +96,7 @@ require (
github.com/firefart/nonamedreturns v1.0.6 // indirect
github.com/fsnotify/fsnotify v1.9.0 // indirect
github.com/fzipp/gocyclo v0.6.0 // indirect
github.com/gabriel-vasile/mimetype v1.4.9 // indirect
github.com/gabriel-vasile/mimetype v1.4.10 // indirect
github.com/ghostiam/protogetter v0.3.15 // indirect
github.com/go-critic/go-critic v0.13.0 // indirect
github.com/go-errors/errors v1.5.1 // indirect
@@ -119,7 +119,7 @@ require (
github.com/gobwas/glob v0.2.3 // indirect
github.com/gofrs/flock v0.12.1 // indirect
github.com/gohugoio/hugo v0.147.6 // indirect
github.com/golang/geo v0.0.0-20250821133510-ecfc33a939ac // indirect
github.com/golang/geo v0.0.0-20250825151631-54d70cc7cb31 // indirect
github.com/golang/protobuf v1.5.3 // indirect
github.com/golangci/dupl v0.0.0-20250308024227-f665c8d69b32 // indirect
github.com/golangci/go-printf-func-name v0.1.0 // indirect
@@ -243,7 +243,7 @@ require (
go-simpler.org/sloglint v0.11.1 // indirect
go.augendre.info/arangolint v0.2.0 // indirect
go.augendre.info/fatcontext v0.8.0 // indirect
go.etcd.io/bbolt v1.4.2 // indirect
go.etcd.io/bbolt v1.4.3 // indirect
go.uber.org/automaxprocs v1.6.0 // indirect
go.uber.org/multierr v1.10.0 // indirect
go.uber.org/zap v1.27.0 // indirect
+6 -6
View File
@@ -251,8 +251,8 @@ github.com/fsnotify/fsnotify v1.9.0 h1:2Ml+OJNzbYCTzsxtv8vKSFD9PbJjmhYF14k/jKC7S
github.com/fsnotify/fsnotify v1.9.0/go.mod h1:8jBTzvmWwFyi3Pb8djgCCO5IBqzKJ/Jwo8TRcHyHii0=
github.com/fzipp/gocyclo v0.6.0 h1:lsblElZG7d3ALtGMx9fmxeTKZaLLpU8mET09yN4BBLo=
github.com/fzipp/gocyclo v0.6.0/go.mod h1:rXPyn8fnlpa0R2csP/31uerbiVBugk5whMdlyaLkLoA=
github.com/gabriel-vasile/mimetype v1.4.9 h1:5k+WDwEsD9eTLL8Tz3L0VnmVh9QxGjRmjBvAG7U/oYY=
github.com/gabriel-vasile/mimetype v1.4.9/go.mod h1:WnSQhFKJuBlRyLiKohA/2DtIlPFAbguNaG7QCHcyGok=
github.com/gabriel-vasile/mimetype v1.4.10 h1:zyueNbySn/z8mJZHLt6IPw0KoZsiQNszIpU+bX4+ZK0=
github.com/gabriel-vasile/mimetype v1.4.10/go.mod h1:d+9Oxyo1wTzWdyVUPMmXFvp4F9tea18J8ufA774AB3s=
github.com/gen2brain/go-fitz v1.24.15 h1:sJNB1MOWkqnzzENPHggFpgxTwW0+S5WF/rM5wUBpJWo=
github.com/gen2brain/go-fitz v1.24.15/go.mod h1:SftkiVbTHqF141DuiLwBBM65zP7ig6AVDQpf2WlHamo=
github.com/getkin/kin-openapi v0.132.0 h1:3ISeLMsQzcb5v26yeJrBcdTCEQTag36ZjaGk7MIRUwk=
@@ -356,8 +356,8 @@ github.com/golang-jwt/jwt/v4 v4.5.2/go.mod h1:m21LjoU+eqJr34lmDMbreY2eSTRJ1cv77w
github.com/golang/geo v0.0.0-20190916061304-5b978397cfec/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI=
github.com/golang/geo v0.0.0-20200319012246-673a6f80352d/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI=
github.com/golang/geo v0.0.0-20210211234256-740aa86cb551/go.mod h1:QZ0nwyI2jOfgRAoBvP+ab5aRr7c9x7lhGEJrKvBwjWI=
github.com/golang/geo v0.0.0-20250821133510-ecfc33a939ac h1:gBtvd74wZT02fkOyoG651Sx2imv5lKdVvDwpUjKPFnw=
github.com/golang/geo v0.0.0-20250821133510-ecfc33a939ac/go.mod h1:AN0OjM34c3PbjAsX+QNma1nYtJtRxl+s9MZNV7S+efw=
github.com/golang/geo v0.0.0-20250825151631-54d70cc7cb31 h1:226lwSa0uZO7sd7QU88n43nDIqGoc+bOh0vSO3Q/byU=
github.com/golang/geo v0.0.0-20250825151631-54d70cc7cb31/go.mod h1:AN0OjM34c3PbjAsX+QNma1nYtJtRxl+s9MZNV7S+efw=
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b/go.mod h1:SBH7ygxi8pfUlaOkMMuAQtPIUF8ecWP5IEl/CR7VP2Q=
github.com/golang/groupcache v0.0.0-20190702054246-869f871628b6/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
github.com/golang/groupcache v0.0.0-20191227052852-215e87163ea7/go.mod h1:cIg4eruTrX1D+g88fzRXU5OdNfaM+9IcxsU14FzY7Hc=
@@ -823,8 +823,8 @@ go.augendre.info/arangolint v0.2.0/go.mod h1:Vx4KSJwu48tkE+8uxuf0cbBnAPgnt8O1KWi
go.augendre.info/fatcontext v0.8.0 h1:2dfk6CQbDGeu1YocF59Za5Pia7ULeAM6friJ3LP7lmk=
go.augendre.info/fatcontext v0.8.0/go.mod h1:oVJfMgwngMsHO+KB2MdgzcO+RvtNdiCEOlWvSFtax/s=
go.etcd.io/bbolt v1.3.4/go.mod h1:G5EMThwa9y8QZGBClrRx5EY+Yw9kAhnjy3bSjsnlVTQ=
go.etcd.io/bbolt v1.4.2 h1:IrUHp260R8c+zYx/Tm8QZr04CX+qWS5PGfPdevhdm1I=
go.etcd.io/bbolt v1.4.2/go.mod h1:Is8rSHO/b4f3XigBC0lL0+4FwAQv3HXEEIgFMuKHceM=
go.etcd.io/bbolt v1.4.3 h1:dEadXpI6G79deX5prL3QRNP6JB8UxVkqo4UPnHaNXJo=
go.etcd.io/bbolt v1.4.3/go.mod h1:tKQlpPaYCVFctUIgFKFnAlvbmB3tpy1vkTnDWohtc0E=
go.opencensus.io v0.21.0/go.mod h1:mSImk1erAIZhrmZN+AvHh14ztQfjbGwt4TtuofqLduU=
go.opencensus.io v0.22.0/go.mod h1:+kGneAE2xo2IficOXnaByMWTGM9T73dGwxeWcUqIpI8=
go.opencensus.io v0.22.2/go.mod h1:yxeiOL68Rb0Xd1ddK5vPZ/oVn4vY4Ynel7k9FzqtOIw=
+4
View File
@@ -3515,6 +3515,10 @@ const docTemplate = `{
"description": "autoplay media files in preview",
"type": "boolean"
},
"defaultMediaPlayer": {
"description": "disable html5 media player and use the default media player",
"type": "boolean"
},
"disableHideSidebar": {
"description": "disable the hide sidebar preview for previews and editors",
"type": "boolean"
+4
View File
@@ -3504,6 +3504,10 @@
"description": "autoplay media files in preview",
"type": "boolean"
},
"defaultMediaPlayer": {
"description": "disable html5 media player and use the default media player",
"type": "boolean"
},
"disableHideSidebar": {
"description": "disable the hide sidebar preview for previews and editors",
"type": "boolean"
+3
View File
@@ -839,6 +839,9 @@ definitions:
autoplayMedia:
description: autoplay media files in preview
type: boolean
defaultMediaPlayer:
description: disable html5 media player and use the default media player
type: boolean
disableHideSidebar:
description: disable the hide sidebar preview for previews and editors
type: boolean
+1
View File
@@ -132,6 +132,7 @@ userDefaults:
office: false
popup: false
autoplayMedia: false
defaultMediaPlayer: false
permissions:
api: false
admin: false
@@ -406,6 +406,7 @@ button.action {
.quick-toggles .active {
background-color: var(--primaryColor) !important;
border-radius: 10em;
color: white;
}
.inner-card {
+30 -5
View File
@@ -17,10 +17,8 @@
--plyr-tooltip-background: rgba(0, 0, 0, 0.8);
--plyr-tooltip-color: #ffffff;
--plyr-audio-controls-background: transparent;
--plyr-video-controls-background: linear-gradient(
transparent,
rgba(0, 0, 0, 0.7)
);
--plyr-video-controls-background: linear-gradient(transparent,
rgba(0, 0, 0, 0.7));
border-radius: 12px;
overflow: visible;
}
@@ -60,6 +58,10 @@
.plyr .plyr__control {
transition: all 0.2s ease;
flex-shrink: 0;
display: flex;
min-width: 2em;
justify-content: center;
align-items: center;
}
.plyr .plyr__control:hover {
@@ -88,6 +90,29 @@
transform: translateX(-50%);
}
.plyr--full-ui.plyr--video .plyr__control--overlaid {
display: flex;
justify-content: center;
align-items: center;
}
.plyr__control--overlaid {
/* background: #00b2ff; */
background: var(--plyr-video-control-background-hover, var(--plyr-color-main, var(--plyr-color-main, #00b2ff)));
border: 0;
display: none;
position: fixed;
transition: .3s;
z-index: 2;
height: 4em;
transform: none;
padding: unset;
left: unset;
right: unset;
bottom: unset;
width: 4em !important;
}
/* Mobile */
@media (max-width: 768px) {
.plyr.plyr--audio {
@@ -194,4 +219,4 @@
.status-off {
background: #f44336;
}
}
+7 -1
View File
@@ -506,7 +506,9 @@
"defaultThemeDescription": "افتراضي - السمة الافتراضية",
"customTheme": "اختر المظهر الخاص بك",
"showSelectMultiple": "إظهار تحديد متعدد في قائمة السياق على سطح المكتب",
"showSelectMultipleDescription": "بشكل افتراضي، لا تحتوي قائمة سياق سطح المكتب على خيار \"تحديد متعدد\" مثل الهاتف المحمول. يظهر هذا الخيار دائمًا في قائمة السياق."
"showSelectMultipleDescription": "بشكل افتراضي، لا تحتوي قائمة سياق سطح المكتب على خيار \"تحديد متعدد\" مثل الهاتف المحمول. يظهر هذا الخيار دائمًا في قائمة السياق.",
"defaultMediaPlayer": "استخدم مشغل الوسائط الافتراضي للمتصفح",
"defaultMediaPlayerDescription": "استخدم مشغل الوسائط الافتراضي للمتصفح لملفات الفيديو والصوت بدلاً من مشغل وسائط html5."
},
"colors": {
"red": "أحمر",
@@ -523,5 +525,9 @@
"saveDisabled": "حفظ الملفات المشتركة غير مدعوم.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "تم تمكين الحلقة",
"LoopDisabled": "حلقة معطلة"
}
}
+7 -1
View File
@@ -289,7 +289,9 @@
"defaultThemeDescription": "default - Výchozí téma",
"customTheme": "Vyberte si téma",
"showSelectMultiple": "Zobrazení výběru více položek v kontextové nabídce na ploše",
"showSelectMultipleDescription": "Ve výchozím nastavení nemá kontextová nabídka na ploše možnost \"vybrat více\" jako v mobilním telefonu. Tato možnost se v kontextové nabídce zobrazuje vždy."
"showSelectMultipleDescription": "Ve výchozím nastavení nemá kontextová nabídka na ploše možnost \"vybrat více\" jako v mobilním telefonu. Tato možnost se v kontextové nabídce zobrazuje vždy.",
"defaultMediaPlayer": "Použití výchozího přehrávače médií v prohlížeči",
"defaultMediaPlayerDescription": "Pro video a zvukové soubory používejte výchozí přehrávač médií prohlížeče, nikoli přehrávač médií html5."
},
"settings": {
"enterPassword": "Zadejte heslo",
@@ -523,5 +525,9 @@
"saveDisabled": "Ukládání sdílených souborů není podporováno.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Povolená smyčka",
"LoopDisabled": "Vypnutá smyčka"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Das Standardthema",
"customTheme": "Wählen Sie Ihr Thema",
"showSelectMultiple": "Mehrfachauswahl im Kontextmenü auf dem Desktop anzeigen",
"showSelectMultipleDescription": "Standardmäßig verfügt das Desktop-Kontextmenü nicht über die Option \"Mehrere auswählen\" wie bei mobilen Geräten. Diese Option wird immer im Kontextmenü angezeigt."
"showSelectMultipleDescription": "Standardmäßig verfügt das Desktop-Kontextmenü nicht über die Option \"Mehrere auswählen\" wie bei mobilen Geräten. Diese Option wird immer im Kontextmenü angezeigt.",
"defaultMediaPlayer": "Verwenden Sie den Standard-Medienplayer des Browsers",
"defaultMediaPlayerDescription": "Verwenden Sie für Video- und Audiodateien den Standard-Media-Player des Browsers und nicht den html5-Media-Player."
},
"editor": {
"uninitialized": "Der Editor konnte nicht initialisiert werden. Bitte neu laden.",
@@ -523,5 +525,9 @@
"saveDisabled": "Das Speichern von gemeinsam genutzten Dateien wird nicht unterstützt.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Schleife Aktiviert",
"LoopDisabled": "Schleife Deaktiviert"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Το προεπιλεγμένο θέμα",
"customTheme": "Επιλέξτε το θέμα σας",
"showSelectMultiple": "Εμφάνιση πολλαπλών επιλογών στο μενού περιβάλλοντος στην επιφάνεια εργασίας",
"showSelectMultipleDescription": "Από προεπιλογή, το μενού περιβάλλοντος της επιφάνειας εργασίας δεν διαθέτει την επιλογή \"επιλογή πολλαπλών\" όπως το κινητό. Αυτή η επιλογή εμφανίζεται πάντα στο μενού περιβάλλοντος."
"showSelectMultipleDescription": "Από προεπιλογή, το μενού περιβάλλοντος της επιφάνειας εργασίας δεν διαθέτει την επιλογή \"επιλογή πολλαπλών\" όπως το κινητό. Αυτή η επιλογή εμφανίζεται πάντα στο μενού περιβάλλοντος.",
"defaultMediaPlayer": "Χρήση του προεπιλεγμένου προγράμματος αναπαραγωγής πολυμέσων του προγράμματος περιήγησης",
"defaultMediaPlayerDescription": "Χρησιμοποιήστε το προεπιλεγμένο πρόγραμμα αναπαραγωγής πολυμέσων του προγράμματος περιήγησης για αρχεία βίντεο και ήχου αντί για το πρόγραμμα αναπαραγωγής πολυμέσων html5."
},
"editor": {
"uninitialized": "Απέτυχε η αρχικοποίηση του συντάκτη. Παρακαλούμε επαναφορτώστε.",
@@ -523,5 +525,9 @@
"saveDisabled": "Δεν υποστηρίζεται η αποθήκευση κοινόχρηστων αρχείων.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Ενεργοποίηση βρόχου",
"LoopDisabled": "Βρόχος απενεργοποιημένος"
}
}
+2
View File
@@ -241,6 +241,8 @@
"helpText2": "The index: Search utilizes the index which automatically gets updated on the configured interval (default: 5 minutes). Searching when the program has just started may result in incomplete results."
},
"profileSettings": {
"defaultMediaPlayer": "Use browser's default media player",
"defaultMediaPlayerDescription": "Use the browser's default media player for video and audio files rather than the html5 media player.",
"showSelectMultiple": "Show select multiple in context menu on desktop",
"showSelectMultipleDescription": "By default, desktop context menu does not have \"select multiple\" option like mobile. This option always shows it in the context menu.",
"customTheme": "Choose your theme",
+7 -1
View File
@@ -514,7 +514,9 @@
"disableSearchOptionsDescription": "Desactivar las opciones de búsqueda que aparecen en la barra lateral.",
"hideSidebarFileActions": "Ocultar el botón de acciones de archivo en la barra lateral",
"deleteWithoutConfirming": "Eliminar archivos sin mensaje de confirmación",
"deleteWithoutConfirmingDescription": "Eliminar archivos sin mensaje de confirmación. Esto sólo funcionará si el archivo es un archivo multimedia."
"deleteWithoutConfirmingDescription": "Eliminar archivos sin mensaje de confirmación. Esto sólo funcionará si el archivo es un archivo multimedia.",
"defaultMediaPlayer": "Utilizar el reproductor multimedia predeterminado del navegador",
"defaultMediaPlayerDescription": "Utilice el reproductor multimedia predeterminado del navegador para los archivos de vídeo y audio en lugar del reproductor multimedia html5."
},
"editor": {
"uninitialized": "Error al inicializar el editor. Por favor, vuelva a cargar.",
@@ -523,5 +525,9 @@
"saveDisabled": "No es posible guardar archivos compartidos.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Bucle activado",
"LoopDisabled": "Bucle desactivado"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Le thème par défaut",
"customTheme": "Choisissez votre thème",
"showSelectMultiple": "Afficher la sélection multiple dans le menu contextuel sur le bureau",
"showSelectMultipleDescription": "Par défaut, le menu contextuel de l'ordinateur de bureau n'a pas l'option \"sélectionner plusieurs\" comme celui de l'ordinateur mobile. Cette option apparaît toujours dans le menu contextuel."
"showSelectMultipleDescription": "Par défaut, le menu contextuel de l'ordinateur de bureau n'a pas l'option \"sélectionner plusieurs\" comme celui de l'ordinateur mobile. Cette option apparaît toujours dans le menu contextuel.",
"defaultMediaPlayer": "Utiliser le lecteur multimédia par défaut du navigateur",
"defaultMediaPlayerDescription": "Utilisez le lecteur multimédia par défaut du navigateur pour les fichiers vidéo et audio plutôt que le lecteur multimédia html5."
},
"editor": {
"uninitialized": "Échec de l'initialisation de l'éditeur. Veuillez recharger.",
@@ -523,5 +525,9 @@
"saveDisabled": "L'enregistrement de fichiers partagés n'est pas possible.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Boucle activée",
"LoopDisabled": "Boucle désactivée"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "ברירת מחדל - ערכת הנושא המוגדרת כברירת מחדל",
"customTheme": "בחר את הנושא שלך",
"showSelectMultiple": "הצג בחירה מרובה בתפריט ההקשר בשולחן העבודה",
"showSelectMultipleDescription": "כברירת מחדל, בתפריט ההקשר של שולחן העבודה אין אפשרות \"בחר מספר פריטים\" כמו במכשירים ניידים. אפשרות זו תמיד מוצגת בתפריט ההקשר."
"showSelectMultipleDescription": "כברירת מחדל, בתפריט ההקשר של שולחן העבודה אין אפשרות \"בחר מספר פריטים\" כמו במכשירים ניידים. אפשרות זו תמיד מוצגת בתפריט ההקשר.",
"defaultMediaPlayer": "השתמש בנגן המדיה המוגדר כברירת מחדל בדפדפן",
"defaultMediaPlayerDescription": "השתמש בנגן המדיה המוגדר כברירת מחדל בדפדפן עבור קבצי וידאו ואודיו, במקום בנגן המדיה html5."
},
"editor": {
"uninitialized": "לא ניתן לאתחל את העורך. אנא טען מחדש.",
@@ -523,5 +525,9 @@
"saveDisabled": "שמירת קבצים משותפים אינה נתמכת.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "לולאה מופעלת",
"LoopDisabled": "לולאה מושבתת"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Az alapértelmezett téma",
"customTheme": "Válasszon témát",
"showSelectMultiple": "Többszörös kijelölés megjelenítése az asztali kontextusmenüben",
"showSelectMultipleDescription": "Alapértelmezés szerint az asztali kontextusmenü nem rendelkezik a \"többszörös kiválasztás\" opcióval, mint a mobilon. Ez az opció mindig megjelenik a kontextusmenüben."
"showSelectMultipleDescription": "Alapértelmezés szerint az asztali kontextusmenü nem rendelkezik a \"többszörös kiválasztás\" opcióval, mint a mobilon. Ez az opció mindig megjelenik a kontextusmenüben.",
"defaultMediaPlayer": "A böngésző alapértelmezett médialejátszójának használata",
"defaultMediaPlayerDescription": "Használja a böngésző alapértelmezett médialejátszóját a videó- és hangfájlokhoz a html5 médialejátszó helyett."
},
"editor": {
"uninitialized": "Nem sikerült inicializálni a szerkesztőt. Kérjük, töltse újra.",
@@ -523,5 +525,9 @@
"saveDisabled": "A megosztott fájlok mentése nem támogatott.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Hurok engedélyezve",
"LoopDisabled": "Hurok letiltva"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Il tema predefinito",
"customTheme": "Scegliete il vostro tema",
"showSelectMultiple": "Mostra selezione multipla nel menu contestuale sul desktop",
"showSelectMultipleDescription": "Per impostazione predefinita, il menu contestuale del desktop non dispone dell'opzione \"seleziona più\" come quello del cellulare. Questa opzione viene sempre visualizzata nel menu contestuale."
"showSelectMultipleDescription": "Per impostazione predefinita, il menu contestuale del desktop non dispone dell'opzione \"seleziona più\" come quello del cellulare. Questa opzione viene sempre visualizzata nel menu contestuale.",
"defaultMediaPlayer": "Utilizzare il lettore multimediale predefinito del browser",
"defaultMediaPlayerDescription": "Utilizzate il lettore multimediale predefinito del browser per i file video e audio piuttosto che il lettore multimediale html5."
},
"editor": {
"uninitialized": "Impossibile inizializzare l'editor. Ricaricare.",
@@ -523,5 +525,9 @@
"saveDisabled": "Il salvataggio di file condivisi non è supportato.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Loop abilitato",
"LoopDisabled": "Loop disabilitato"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - デフォルトのテーマ",
"customTheme": "テーマを選ぶ",
"showSelectMultiple": "デスクトップのコンテキストメニューに複数選択を表示する",
"showSelectMultipleDescription": "デフォルトでは、デスクトップのコンテキストメニューには、モバイルのような「複数選択」オプションはありません。このオプションは常にコンテキストメニューに表示されます。"
"showSelectMultipleDescription": "デフォルトでは、デスクトップのコンテキストメニューには、モバイルのような「複数選択」オプションはありません。このオプションは常にコンテキストメニューに表示されます。",
"defaultMediaPlayer": "ブラウザーのデフォルトのメディアプレーヤーを使用する",
"defaultMediaPlayerDescription": "動画や音声ファイルには、html5メディアプレーヤーではなく、ブラウザーのデフォルトのメディアプレーヤーを使用してください。"
},
"editor": {
"uninitialized": "エディタの初期化に失敗しました。再読み込みしてください。",
@@ -523,5 +525,9 @@
"saveDisabled": "共有ファイルの保存はサポートされていません。",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "ループ有効",
"LoopDisabled": "ループ無効"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - 기본 테마",
"customTheme": "테마 선택",
"showSelectMultiple": "데스크톱의 컨텍스트 메뉴에서 여러 개 선택 표시",
"showSelectMultipleDescription": "기본적으로 데스크톱 컨텍스트 메뉴에는 모바일처럼 '여러 개 선택' 옵션이 없습니다. 이 옵션은 항상 컨텍스트 메뉴에 표시됩니다."
"showSelectMultipleDescription": "기본적으로 데스크톱 컨텍스트 메뉴에는 모바일처럼 '여러 개 선택' 옵션이 없습니다. 이 옵션은 항상 컨텍스트 메뉴에 표시됩니다.",
"defaultMediaPlayer": "브라우저의 기본 미디어 플레이어 사용",
"defaultMediaPlayerDescription": "비디오 및 오디오 파일에는 HTML5 미디어 플레이어 대신 브라우저의 기본 미디어 플레이어를 사용하세요."
},
"editor": {
"uninitialized": "편집기를 초기화하지 못했습니다. 다시 로드하세요.",
@@ -523,5 +525,9 @@
"saveDisabled": "공유 파일 저장은 지원되지 않습니다.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "루프 사용",
"LoopDisabled": "루프 비활성화"
}
}
+7 -1
View File
@@ -478,7 +478,9 @@
"defaultThemeDescription": "standaard - Het standaardthema",
"customTheme": "Kies je thema",
"showSelectMultiple": "Meerdere selecteren tonen in contextmenu op bureaublad",
"showSelectMultipleDescription": "Standaard heeft het contextmenu op de desktop geen optie \"meerdere selecteren\" zoals mobiel. Deze optie wordt altijd weergegeven in het contextmenu."
"showSelectMultipleDescription": "Standaard heeft het contextmenu op de desktop geen optie \"meerdere selecteren\" zoals mobiel. Deze optie wordt altijd weergegeven in het contextmenu.",
"defaultMediaPlayer": "Gebruik de standaard mediaspeler van de browser",
"defaultMediaPlayerDescription": "Gebruik de standaard mediaspeler van de browser voor video- en audiobestanden in plaats van de html5 mediaspeler."
},
"general": {
"name": "Naam",
@@ -523,5 +525,9 @@
"saveDisabled": "Het opslaan van gedeelde bestanden wordt niet ondersteund.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Lus ingeschakeld",
"LoopDisabled": "Lus uitgeschakeld"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - domyślny motyw",
"customTheme": "Wybierz motyw",
"showSelectMultiple": "Wyświetlanie wyboru wielokrotnego w menu kontekstowym na pulpicie",
"showSelectMultipleDescription": "Domyślnie menu kontekstowe pulpitu nie ma opcji \"wybierz wiele\", tak jak w przypadku urządzeń mobilnych. Opcja ta jest zawsze widoczna w menu kontekstowym."
"showSelectMultipleDescription": "Domyślnie menu kontekstowe pulpitu nie ma opcji \"wybierz wiele\", tak jak w przypadku urządzeń mobilnych. Opcja ta jest zawsze widoczna w menu kontekstowym.",
"defaultMediaPlayer": "Użyj domyślnego odtwarzacza multimediów przeglądarki",
"defaultMediaPlayerDescription": "Do odtwarzania plików wideo i audio należy używać domyślnego odtwarzacza multimediów przeglądarki, a nie odtwarzacza multimediów html5."
},
"editor": {
"uninitialized": "Nie udało się zainicjować edytora. Przeładuj ponownie.",
@@ -523,5 +525,9 @@
"saveDisabled": "Zapisywanie udostępnionych plików nie jest obsługiwane.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Włączona pętla",
"LoopDisabled": "Pętla wyłączona"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - O tema padrão",
"customTheme": "Escolha seu tema",
"showSelectMultiple": "Mostrar seleção múltipla no menu de contexto na área de trabalho",
"showSelectMultipleDescription": "Por padrão, o menu de contexto do desktop não tem a opção \"selecionar vários\" como no celular. Essa opção sempre a mostra no menu de contexto."
"showSelectMultipleDescription": "Por padrão, o menu de contexto do desktop não tem a opção \"selecionar vários\" como no celular. Essa opção sempre a mostra no menu de contexto.",
"defaultMediaPlayer": "Use o reprodutor de mídia padrão do navegador",
"defaultMediaPlayerDescription": "Use o reprodutor de mídia padrão do navegador para arquivos de vídeo e áudio em vez do reprodutor de mídia html5."
},
"editor": {
"uninitialized": "Falha ao inicializar o editor. Favor recarregar.",
@@ -523,5 +525,9 @@
"saveDisabled": "Não há suporte para o salvamento de arquivos compartilhados.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Loop ativado",
"LoopDisabled": "Loop desativado"
}
}
+7 -1
View File
@@ -478,7 +478,9 @@
"defaultThemeDescription": "default - O tema predefinido",
"customTheme": "Escolha o seu tema",
"showSelectMultiple": "Mostrar seleção múltipla no menu de contexto no ambiente de trabalho",
"showSelectMultipleDescription": "Por predefinição, o menu de contexto do ambiente de trabalho não tem a opção \"selecionar vários\" como no telemóvel. Esta opção mostra-a sempre no menu de contexto."
"showSelectMultipleDescription": "Por predefinição, o menu de contexto do ambiente de trabalho não tem a opção \"selecionar vários\" como no telemóvel. Esta opção mostra-a sempre no menu de contexto.",
"defaultMediaPlayer": "Utilizar o leitor multimédia predefinido do navegador",
"defaultMediaPlayerDescription": "Utilize o leitor multimédia predefinido do navegador para ficheiros de vídeo e áudio em vez do leitor multimédia html5."
},
"general": {
"name": "Nome",
@@ -523,5 +525,9 @@
"saveDisabled": "A gravação de ficheiros partilhados não é suportada.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Loop ativado",
"LoopDisabled": "Loop desativado"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Tema implicită",
"customTheme": "Alege-ți tema",
"showSelectMultiple": "Afișarea selecției multiple în meniul contextual de pe desktop",
"showSelectMultipleDescription": "În mod implicit, meniul contextual de pe desktop nu are opțiunea \"select multiple\", ca pe mobil. Această opțiune se afișează întotdeauna în meniul contextual."
"showSelectMultipleDescription": "În mod implicit, meniul contextual de pe desktop nu are opțiunea \"select multiple\", ca pe mobil. Această opțiune se afișează întotdeauna în meniul contextual.",
"defaultMediaPlayer": "Utilizați playerul media implicit al browserului",
"defaultMediaPlayerDescription": "Utilizați playerul media implicit al browserului pentru fișierele video și audio, mai degrabă decât playerul media html5."
},
"editor": {
"uninitialized": "Nu s-a reușit inițializarea editorului. Vă rugăm să reîncărcați.",
@@ -523,5 +525,9 @@
"saveDisabled": "Salvarea fișierelor partajate nu este acceptată.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Bucla activată",
"LoopDisabled": "Bucla dezactivată"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Тема по умолчанию",
"customTheme": "Выберите тему",
"showSelectMultiple": "Отображение выбора нескольких в контекстном меню на рабочем столе",
"showSelectMultipleDescription": "По умолчанию в контекстном меню рабочего стола нет опции \"выбрать несколько\", как в мобильном. Эта опция всегда отображается в контекстном меню."
"showSelectMultipleDescription": "По умолчанию в контекстном меню рабочего стола нет опции \"выбрать несколько\", как в мобильном. Эта опция всегда отображается в контекстном меню.",
"defaultMediaPlayer": "Используйте медиаплеер браузера по умолчанию",
"defaultMediaPlayerDescription": "Для воспроизведения видео- и аудиофайлов используйте медиаплеер браузера по умолчанию, а не медиаплеер html5."
},
"editor": {
"uninitialized": "Не удалось инициализировать редактор. Пожалуйста, перезагрузитесь.",
@@ -523,5 +525,9 @@
"saveDisabled": "Сохранение общих файлов не поддерживается.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Петля включена",
"LoopDisabled": "Петля отключена"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Predvolená téma",
"customTheme": "Vyberte si tému",
"showSelectMultiple": "Zobrazenie výberu viacerých v kontextovom menu na ploche",
"showSelectMultipleDescription": "V predvolenom nastavení kontextová ponuka na ploche nemá možnosť \"vybrať viacero\" ako v mobilných zariadeniach. Táto možnosť sa v kontextovej ponuke zobrazuje vždy."
"showSelectMultipleDescription": "V predvolenom nastavení kontextová ponuka na ploche nemá možnosť \"vybrať viacero\" ako v mobilných zariadeniach. Táto možnosť sa v kontextovej ponuke zobrazuje vždy.",
"defaultMediaPlayer": "Použitie predvoleného prehrávača médií v prehliadači",
"defaultMediaPlayerDescription": "Pre video a audio súbory použite predvolený prehrávač médií prehliadača a nie prehrávač médií html5."
},
"editor": {
"uninitialized": "Nepodarilo sa inicializovať editor. Prosím, načítajte ho znova.",
@@ -523,5 +525,9 @@
"saveDisabled": "Ukladanie zdieľaných súborov nie je podporované.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Povolená slučka",
"LoopDisabled": "Vypnutá slučka"
}
}
+7 -1
View File
@@ -478,7 +478,9 @@
"defaultThemeDescription": "default - Standardtema",
"customTheme": "Välj ditt tema",
"showSelectMultiple": "Visa markera flera i snabbmenyn på skrivbordet",
"showSelectMultipleDescription": "Som standard har snabbmenyn på skrivbordet inte alternativet \"välj flera\" som på mobilen. Det här alternativet visas alltid i snabbmenyn."
"showSelectMultipleDescription": "Som standard har snabbmenyn på skrivbordet inte alternativet \"välj flera\" som på mobilen. Det här alternativet visas alltid i snabbmenyn.",
"defaultMediaPlayer": "Använd webbläsarens standardmediaspelare",
"defaultMediaPlayerDescription": "Använd webbläsarens standardmediaspelare för video- och ljudfiler i stället för html5-mediaspelaren."
},
"general": {
"name": "Namn",
@@ -523,5 +525,9 @@
"saveDisabled": "Sparande av delade filer stöds inte.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Slinga aktiverad",
"LoopDisabled": "Slinga avaktiverad"
}
}
+7 -1
View File
@@ -514,7 +514,9 @@
"defaultThemeDescription": "default - Varsayılan tema",
"customTheme": "Temanızı seçin",
"showSelectMultiple": "Masaüstündeki bağlam menüsünde çoklu seçmeyi göster",
"showSelectMultipleDescription": "Varsayılan olarak, masaüstü içerik menüsünde mobil cihazlardaki gibi \"çoklu seç\" seçeneği yoktur. Bu seçenek her zaman içerik menüsünde gösterilir."
"showSelectMultipleDescription": "Varsayılan olarak, masaüstü içerik menüsünde mobil cihazlardaki gibi \"çoklu seç\" seçeneği yoktur. Bu seçenek her zaman içerik menüsünde gösterilir.",
"defaultMediaPlayer": "Tarayıcının varsayılan medya oynatıcısını kullanma",
"defaultMediaPlayerDescription": "Video ve ses dosyaları için html5 medya oynatıcı yerine tarayıcının varsayılan medya oynatıcısını kullanın."
},
"editor": {
"uninitialized": "Düzenleyici başlatılamadı. Lütfen yeniden yükleyin.",
@@ -523,5 +525,9 @@
"saveDisabled": "Paylaşılan dosyaların kaydedilmesi desteklenmez.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Döngü Etkin",
"LoopDisabled": "Döngü Devre Dışı"
}
}
+7 -1
View File
@@ -478,7 +478,9 @@
"defaultThemeDescription": "default - тема за замовчуванням",
"customTheme": "Виберіть свою тему",
"showSelectMultiple": "Показувати вибране кілька в контекстному меню на робочому столі",
"showSelectMultipleDescription": "За замовчуванням, контекстне меню десктопа не має опції \"вибрати декілька\", як у мобільному. Ця опція завжди відображається у контекстному меню."
"showSelectMultipleDescription": "За замовчуванням, контекстне меню десктопа не має опції \"вибрати декілька\", як у мобільному. Ця опція завжди відображається у контекстному меню.",
"defaultMediaPlayer": "Використовуйте медіаплеєр за замовчуванням у браузері",
"defaultMediaPlayerDescription": "Використовуйте медіаплеєр браузера за замовчуванням для відео- та аудіофайлів, а не медіаплеєр html5."
},
"general": {
"name": "Ім'я",
@@ -523,5 +525,9 @@
"saveDisabled": "Збереження спільних файлів не підтримується.",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "Цикл увімкнено",
"LoopDisabled": "Цикл вимкнено"
}
}
+7 -1
View File
@@ -478,7 +478,9 @@
"defaultThemeDescription": "default - 默认主题",
"customTheme": "选择主题",
"showSelectMultiple": "在桌面右键菜单中显示多个选择",
"showSelectMultipleDescription": "默认情况下,桌面右键菜单不像手机那样有 \"选择多个 \"选项。该选项始终显示在右键菜单中。"
"showSelectMultipleDescription": "默认情况下,桌面右键菜单不像手机那样有 \"选择多个 \"选项。该选项始终显示在右键菜单中。",
"defaultMediaPlayer": "使用浏览器的默认媒体播放器",
"defaultMediaPlayerDescription": "使用浏览器的默认媒体播放器播放视频和音频文件,而不是 html5 媒体播放器。"
},
"general": {
"name": "名称",
@@ -523,5 +525,9 @@
"saveDisabled": "不支持保存共享文件。",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "启用环路",
"LoopDisabled": "环路禁用"
}
}
+7 -1
View File
@@ -452,7 +452,9 @@
"defaultThemeDescription": "default - 預設主題",
"customTheme": "選擇您的主題",
"showSelectMultiple": "在桌面的上下文功能表中顯示多重選擇",
"showSelectMultipleDescription": "預設情況下,桌上型電腦的上下文功能表不像行動裝置一樣有「選取多個」選項。此選項總是在上下文功能表中顯示。"
"showSelectMultipleDescription": "預設情況下,桌上型電腦的上下文功能表不像行動裝置一樣有「選取多個」選項。此選項總是在上下文功能表中顯示。",
"defaultMediaPlayer": "使用瀏覽器的預設媒體播放器",
"defaultMediaPlayerDescription": "使用瀏覽器的預設媒體播放器來播放視訊和音訊檔案,而不是使用 html5 媒體播放器。"
},
"otp": {
"name": "雙因素驗證",
@@ -523,5 +525,9 @@
"saveDisabled": "不支援儲存共用檔案。",
"saveAbortedMessage": "Save operation aborted. The application's active file ({activeFile}) does not match the file you are trying to save ({tryingToSave}).",
"syncFailed": "failed to sync state with the route for \"{filename}\" after 5 attempts. Aborting editor setup to prevent data corruption."
},
"player": {
"LoopEnabled": "啟用循環",
"LoopDisabled": "迴路停用"
}
}
+113 -57
View File
@@ -15,7 +15,7 @@
<!-- Audio with plyr -->
<vue-plyr
v-else-if="previewType == 'audio'"
v-else-if="previewType == 'audio' && !useDefaultMediaPlayer"
ref="audioPlayer"
:options="plyrOptions"
>
@@ -28,7 +28,7 @@
<!-- Video with plyr -->
<vue-plyr
v-else-if="previewType == 'video'"
v-else-if="previewType == 'video' && !useDefaultMediaPlayer"
ref="videoPlayer"
:options="plyrOptions"
>
@@ -44,6 +44,35 @@
</video>
</vue-plyr>
<!-- Default HTML5 Audio -->
<audio
v-else-if="previewType == 'audio' && useDefaultMediaPlayer"
ref="defaultAudioPlayer"
:src="raw"
controls
:autoplay="autoPlay"
@play="autoPlay = true"
></audio>
<!-- Default HTML5 Video -->
<video
v-else-if="previewType == 'video' && useDefaultMediaPlayer"
ref="defaultVideoPlayer"
:src="raw"
controls
:autoplay="autoPlay"
@play="autoPlay = true"
>
<track
kind="captions"
v-for="(sub, index) in subtitlesList"
:key="index"
:src="sub.src"
:label="'Subtitle ' + sub.name"
:default="index === 0"
/>
</video>
<div v-else-if="previewType == 'pdf'" class="pdf-wrapper">
<iframe class="pdf" :src="raw"></iframe>
<a
@@ -209,6 +238,9 @@ export default {
autoPlay() {
return state.user.preview.autoplayMedia;
},
useDefaultMediaPlayer() {
return state.user.preview.defaultMediaPlayer === true;
},
isMobileSafari() {
const userAgent = window.navigator.userAgent;
const isIOS =
@@ -370,43 +402,33 @@ export default {
},
methods: {
async subtitles() {
if (!state.req.subtitles || state.req.subtitles.length === 0) {
if (!state.req?.subtitles?.length) {
return [];
}
let subs = [];
for (const subtitleFile of state.req.subtitles) {
const ext = getFileExtension(subtitleFile);
const path =
url.removeLastDir(state.req.path) + "/" + subtitleFile;
let resp;
if (getters.isShare()) {
// Use public API for shared files
resp = await publicApi.fetchPub(
path,
state.share.hash,
"",
true,
);
} else {
// Use regular files API for authenticated users
resp = await filesApi.fetchFiles(
state.req.source,
path,
true,
);
for (const subtitleTrack of state.req.subtitles) {
// All subtitle content is now pre-loaded when content=true
// Simply use the content that's already available
if (!subtitleTrack.content || subtitleTrack.content.length === 0) {
console.warn("Subtitle track has no content:", subtitleTrack.name);
continue;
}
let vttContent = subtitleTrack.content;
if (!subtitleTrack.content.startsWith('WEBVTT')) {
const ext = getFileExtension(subtitleTrack.name);
vttContent = convertToVTT(ext, subtitleTrack.content);
}
if (vttContent.startsWith('WEBVTT')) {
// Create a virtual file (Blob) and get a URL for it
const blob = new Blob([vttContent], { type: "text/vtt" });
const vttURL = URL.createObjectURL(blob);
subs.push({
name: subtitleTrack.name,
src: vttURL,
});
} else {
console.warn("Skipping subtitle track because it has no WEBVTT header:", subtitleTrack.name);
}
let vttContent = resp.content;
// Convert SRT to VTT (assuming srt2vtt() does this)
vttContent = convertToVTT(ext, resp.content);
// Create a virtual file (Blob) and get a URL for it
const blob = new Blob([vttContent], { type: "text/vtt" });
const vttURL = URL.createObjectURL(blob);
subs.push({
name: ext,
src: vttURL,
});
}
return subs;
},
@@ -457,18 +479,31 @@ export default {
}
},
toggleLoop() {
// Get the appropriate player reference
let playerRef =
this.previewType === "video"
? this.$refs.videoPlayer
: this.$refs.audioPlayer;
if (this.useDefaultMediaPlayer) {
// Handle default HTML5 players
let playerRef =
this.previewType === "video"
? this.$refs.defaultVideoPlayer
: this.$refs.defaultAudioPlayer;
if (playerRef && playerRef.player) {
// Toggle loop mode
this.loopEnabled = !this.loopEnabled;
playerRef.player.loop = this.loopEnabled;
if (playerRef) {
this.loopEnabled = !this.loopEnabled;
playerRef.loop = this.loopEnabled;
this.showToast();
}
} else {
// Handle vue-plyr players
let playerRef =
this.previewType === "video"
? this.$refs.videoPlayer
: this.$refs.audioPlayer;
this.showToast();
if (playerRef && playerRef.player) {
// Toggle loop mode
this.loopEnabled = !this.loopEnabled;
playerRef.player.loop = this.loopEnabled;
this.showToast();
}
}
},
showToast() {
@@ -487,19 +522,39 @@ export default {
(this.previewType === "video" || this.previewType === "audio")
) {
this.$nextTick(() => {
let playerRef =
this.previewType === "video"
? this.$refs.videoPlayer
: this.$refs.audioPlayer;
if (this.useDefaultMediaPlayer) {
// Handle default HTML5 players
let playerRef =
this.previewType === "video"
? this.$refs.defaultVideoPlayer
: this.$refs.defaultAudioPlayer;
if (playerRef && playerRef.player) {
const playPromise = playerRef.player.play();
if (playPromise !== undefined) {
playPromise.catch((error) => {
console.log("autoplay failed", error);
playerRef.player.muted = true;
playerRef.player.play();
});
if (playerRef) {
const playPromise = playerRef.play();
if (playPromise !== undefined) {
playPromise.catch((error) => {
console.log("autoplay failed", error);
playerRef.muted = true;
playerRef.play();
});
}
}
} else {
// Handle vue-plyr players
let playerRef =
this.previewType === "video"
? this.$refs.videoPlayer
: this.$refs.audioPlayer;
if (playerRef && playerRef.player) {
const playPromise = playerRef.player.play();
if (playPromise !== undefined) {
playPromise.catch((error) => {
console.log("autoplay failed", error);
playerRef.player.muted = true;
playerRef.player.play();
});
}
}
}
});
@@ -520,6 +575,7 @@ export default {
directoryPath,
);
}
this.listing = res.items
}
if (!this.listing) {
this.listing = [state.req];
+7
View File
@@ -33,6 +33,13 @@
<div class="card-content">
<h3>{{ $t("settings.listingOptions") }}</h3>
<div class="settings-items">
<ToggleSwitch
class="item"
v-model="localuser.preview.defaultMediaPlayer"
@change="updateSettings"
:name="$t('profileSettings.defaultMediaPlayer')"
:description="$t('profileSettings.defaultMediaPlayerDescription')"
/>
<ToggleSwitch
class="item"
v-model="localuser.deleteWithoutConfirming"