Parcourir la source

Merge pull request #789 from paidge/master

add canal-u.tv service
Amauri CHAMPEAUX il y a 3 ans
Parent
commit
d0063b5b82
1 fichiers modifiés avec 30 ajouts et 0 suppressions
  1. 30 0
      tarteaucitron.services.js

+ 30 - 0
tarteaucitron.services.js

@@ -4808,3 +4808,33 @@ tarteaucitron.services.affilae = {
     }
 };
 
+tarteaucitron.services.canalu = {
+    "key": "canalu",
+    "type": "video",
+    "name": "Canal-U.tv",
+    "uri": "https://www.canal-u.tv/utilisation-des-cookies/",
+    "needConsent": true,
+    "cookies": [],
+    "js": function () {
+        "use strict";
+        tarteaucitron.fallback(['canalu_player'], function (x) {
+            var video_title = tarteaucitron.fixSelfXSS(x.getAttribute("videoTitle")),
+                frame_url = 'https://www.canal-u.tv/video/embed_code_plugin.1/' + video_title;
+
+            return '<div style="position:relative;padding-bottom:56.25%;padding-top:10px;height:0;overflow:hidden;">' +
+                   '<iframe src="' + frame_url + '?width=100%&amp;height=100%" ' +
+                        'style="position:absolute;top:0;left:0;width:100%;height: 100%;" ' +
+                        'frameborder="0" ' +
+                        'allowfullscreen ' +
+                        'scrolling="no">' +
+                   '</iframe>' +
+                   '</div>';
+        });
+    },
+    "fallback": function () {
+        "use strict";
+        tarteaucitron.fallback(['canalu_player'], function (elem) {
+            return tarteaucitron.engage('canalu');
+        });
+    }
+};