Greasy Fork 支持简体中文。

Fix Twitter Share Link

Replace `twitter` to `vxtwitter` when sharing links

< 腳本Fix Twitter Share Link的回應

評論:OK - script works, but has bugs

§
發表於:2023-10-12

Made a few tweaks for current twitter urls: added to header

// @match https://x.com/*

and adjusted lines 22 and 23 to the following:

        if (selected.match(/^https+:\/\/((.+)\.)?x\.com\/(.+)\/status\/(\d+)(\?.+)?$/)) {
            const newUrl = selected.replace(/^https+:\/\/((.+)\.)?x\.com\/(.+)\/status\/(\d+)(\?.+)?$/, 'https://vxtwitter.com/$3/status/$4');
solstice23作者
§
發表於:2023-10-18

Updated, thank you

發表回覆

登入以回復