// ==UserScript== // @name Auto skip intro on amazon prime videos // @namespace momala // @description No need to manually click // @match https://primevideo.com/region/*/detail/* // @match https://*.primevideo.com/region/*/detail/* // @match https://primevideo.com/detail/* // @match https://*.primevideo.com/detail/* // @match https://amazon.com/Episode-*/dp/* // @match https://*.amazon.com/Episode-*/dp/* // @match https://amazon.co.jp/Episode-*/dp/* // @match https://*.amazon.co.jp/Episode-*/dp/* // @match https://amazon.com/gp/video/detail/* // @match https://*.amazon.com/gp/video/detail/* // @match https://amazon.co.jp/gp/video/detail/* // @match https://*.amazon.co.jp/gp/video/detail/* // @version 1 // @noframes // @downloadURL none // ==/UserScript== (function() { 'use strict'; (new MutationObserver(function (mutationlist) { if (document.querySelector('.webPlayerUIContainer [tabindex="-1"] > div:nth-child(4) > div:nth-child(3)')) { this.disconnect(); (new MutationObserver(function (mutationlist) { Array.from(document.querySelectorAll('.webPlayerUIContainer [tabindex="-1"] > div:nth-child(4) > div:nth-child(3) div')).filter(function(item) { return window.getComputedStyle(item).getPropertyValue('box-shadow').includes('rgba'); }).forEach(function(item) { console.log('Auto skipped intro'); item.click(); }); })).observe(document.querySelector('.webPlayerUIContainer [tabindex="-1"] > div:nth-child(4) > div:nth-child(3)'),{ attributes: false, childList: true, subtree: true }); } })).observe(document.getElementById('dv-web-player'),{ attributes: false, childList: true, subtree: true }); })();