diff --git a/src/userscript.ts b/src/userscript.ts index e130c6ef..feb74eee 100644 --- a/src/userscript.ts +++ b/src/userscript.ts @@ -56895,13 +56895,16 @@ var $$IMU_EXPORT$$; if (domain_nowww === "instagram.com") { newsrc = website_query({ - website_regex: /^[a-z]+:\/\/[^/]+\/+p\/+([^/]+)(?:\/+(?:(?:media|embed).*)?)?(?:[?#].*)?$/, - id: "post:${id}", + website_regex: { + regex: /^[a-z]+:\/\/[^/]+\/+(p|tv|reel)\/+([^/]+)(?:\/+(?:(?:media|embed).*)?)?(?:[?#].*)?$/, + groups: ["type", "id"] + }, + id: "post:${type}:${id}", run: function(cb, match) { var info:any = [{ type: "post", subtype: "link", - url: "https://www.instagram.com/p/" + match[1] + "/", + url: "https://www.instagram.com/" + match[1] + "/" + match[2] + "/", element: options.element }]; diff --git a/userscript.user.js b/userscript.user.js index 211aa02f..21a46833 100644 --- a/userscript.user.js +++ b/userscript.user.js @@ -51665,13 +51665,16 @@ var $$IMU_EXPORT$$; } if (domain_nowww === "instagram.com") { newsrc = website_query({ - website_regex: /^[a-z]+:\/\/[^/]+\/+p\/+([^/]+)(?:\/+(?:(?:media|embed).*)?)?(?:[?#].*)?$/, - id: "post:${id}", + website_regex: { + regex: /^[a-z]+:\/\/[^/]+\/+(p|tv|reel)\/+([^/]+)(?:\/+(?:(?:media|embed).*)?)?(?:[?#].*)?$/, + groups: ["type", "id"] + }, + id: "post:${type}:${id}", run: function(cb, match) { var info = [{ type: "post", subtype: "link", - url: "https://www.instagram.com/p/" + match[1] + "/", + url: "https://www.instagram.com/" + match[1] + "/" + match[2] + "/", element: options.element }]; var queries = common_functions["parse_imu_hash"](src);