Automatically opens the preview slider for all items.
目前為
// ==UserScript==
// @id FeedlyautopreviewmodMod
// @name Feedly Autopreview All Items
// @version 1.0.1
// @grant GM_addStyle
// @description Automatically opens the preview slider for all items.
// @include http://feedly.com/*
// @include https://feedly.com/*
// @run-at document-end
// @namespace https://greasyfork.org/users/4819
// ==/UserScript==
var autopreviewmod = function () {
this.initialize.apply(this, arguments);
}
autopreviewmod.prototype = {
initialize:function () {
}
,autopreview:function (item) {
item.setAttribute("data-page-entry-action", "previewEntry");
}
};
mo = new MutationObserver(function (mutations) {
var autopreviewmodObj = new autopreviewmod();
mutations.forEach(function (mutation) {
Array.prototype.slice.call(mutation.addedNodes).forEach(function (node) {
if (node.tagName=="DIV" && (node.className=="u0Entry " || node.className=="u1Entry " || node.className=="u2Entry " || node.className=="u3Entry " || node.className=="u4Entry " || node.className=="u5Entry " || node.className=="u5Entry quicklisted")) {
if(!node.getAttribute("data-alternate-link").contains("youtube.com")) {
if(!node.getAttribute("data-alternate-link").contains("plurk.com")) {
autopreviewmodObj.autopreview(node);
};
};
};
});
});
});
mo.observe(document.getElementById("box"), {childList:true, subtree:true});