{"YANDEX_Disk|yadi.sk-h":{"link":"^(yadi\\.sk|disk\\.yandex\\.(?:com|ru))/\\w/\\w+","res":":\ndebugger;\nlet m = $._.match(/id=\"store-prefetch\">({.+?})<\\/script/)?.[1];\nif (m) m = JSON.parse(m);\n\nlet res = m.resources?.[m.overlays?.sliderResourceId];\nif (res?.meta?.original) {\n return [[res.meta.original, res.name]];\n} else if (m?.resources) {\n m = Object.values(m.resources)?.[0]?.videoStreams?.videos?.pop()?.url;\n}\nif (m) return { loop: m };\n\nvar re = /<meta property=\"og:image\" content=\"([^\"]+)\">/gi;\nvar a = re.exec($._);\nlet meta = document.querySelector('head > meta[name=\"referrer\"]');\nif (!meta) {\n meta = document.createElement('meta');\n meta.name = 'referrer';\n meta.content = 'same-origin';\n document.getElementsByTagName('head')[0].appendChild(meta);\n} else if (meta.attributes.content.value !== 'same-origin') {\n meta.attributes.content.value = 'same-origin';\n}\nreturn a[1].replace('&', '&').replace(/size=[^&]+/, 'size=10000x10000').replace(/logo=[^&]*/, 'logo=0');\n","img":"^\\d\\.downloader\\.disk\\.yandex\\.(?:com|ru)/preview/[\\da-f]{64}/inf/[^?]+\\?(?:[^&]+&)*?(?:content_type=image).+","to":":\nreturn $[0].replace(/&crop=[^&]*/, '').replace(/(&size=)[^&]+/, '$110000x10000')","note":"Imagus_fan\nhttps://www.reddit.com/r/imagus/comments/z0zyox/comment/lfbh47p\nOLD\nhttp://forum.ru-board.com/topic.cgi?forum=5&topic=48222&start=3540#20\nhttp://forum.ru-board.com/topic.cgi?forum=5&topic=48222&start=1160#6\n\n\n!!!\nSometimes got a gray spinner but it was caused by redirection to a captcha page.\n\n\nПРИМЕРЫ\nhttp://forum.ru-board.com/topic.cgi?forum=5&topic=50874&start=1360#11"}} |