aboutsummaryrefslogtreecommitdiffstats
path: root/src/client/players/Iframe.hx
diff options
context:
space:
mode:
authorRblSb <msrblsb@gmail.com>2025-01-16 03:07:31 +0300
committerRblSb <msrblsb@gmail.com>2025-01-17 01:00:09 +0300
commitd9ca7beaa9494cf34590853901cf8be44e243775 (patch)
treef09ce979460bdf28363a922298283dfee0c506fb /src/client/players/Iframe.hx
parentf84fdc40ba817b6a2d907484b1e1500197ceeafe (diff)
Cache on server feature
Server will download video from supported players and add as raw video to playlist (only youtube is supported for now). Cache for YT player is available after installing optional dependencies, see readme. For cache size see `cacheStorageLimitGiB ` in config. There is also minor ux improvement, latest checkbox states will be keeped in local storage now.
Diffstat (limited to 'src/client/players/Iframe.hx')
-rw-r--r--src/client/players/Iframe.hx7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/client/players/Iframe.hx b/src/client/players/Iframe.hx
index 56cf319..8a2e06e 100644
--- a/src/client/players/Iframe.hx
+++ b/src/client/players/Iframe.hx
@@ -1,5 +1,6 @@
package client.players;
+import Types.PlayerType;
import Types.VideoData;
import Types.VideoDataRequest;
import Types.VideoItem;
@@ -18,13 +19,17 @@ class Iframe implements IPlayer {
this.player = player;
}
+ public function getPlayerType():PlayerType {
+ return IframeType;
+ }
+
public function isSupportedLink(url:String):Bool {
return true;
}
public function getVideoData(data:VideoDataRequest, callback:(data:VideoData) -> Void):Void {
final iframe = document.createDivElement();
- iframe.innerHTML = data.url;
+ iframe.innerHTML = data.url.trim();
if (isValidIframe(iframe)) {
callback({duration: 99 * 60 * 60});
} else {
send patches to the email below
yukais@pinapelz.com
include the subject [PATCH repo_name]
pinapelz.com
homepage