User talk:Nardog/CopySectLink

Thanks
Thanks again for making this. I use it daily, saves a lot of hand moves from mouse to keyboard. Green C  16:22, 24 December 2021 (UTC)

Conflicts with "Add an [edit] link for the lead section of a page"
Love this script but sometimes (on page load), the script interferes with the "Add an [edit] link for the lead section of a page" gadget, and the spot next to the lead header reads as  rather than. When it's messed up, clicking on the first "copy" runs this CopySectLink and copies to clipboard, and clicking the second "copy" reloads the page. Hard refreshing the page resolves the issue, but it happens pretty often—anyone else getting the same thing and any easy fixes? czar 01:20, 18 January 2022 (UTC)
 * I'm aware of this issue. It occurs when this script is run before the edittop gadget. It can be fixed by making sure the script is loaded after the gadget, as in: I'll update the documentation. Nardog (talk) 01:59, 18 January 2022 (UTC)
 * Seeing how popular the gadget seems to be across wikis, I've decided to make the script automatically avoid the conflict. You no longer have to use the above code. Nardog (talk) 08:34, 19 January 2022 (UTC)

Thanks & Request?
I love this script! Could the "copy" button be renamed to "link", though? I get that users who install this script know what they expect, but it could be slightly confusing- in screenshots, I guess? Aaron Liu (talk) 02:21, 20 December 2023 (UTC)


 * I don't know how that could be the case. "edit" initiates the process of editing the section, and "copy" initiates the process of copying the section path. It's pretty self-explanatory, more so than "link". Anyway, you can always fork a script yourself if you don't like something about it. Nardog (talk) 14:15, 20 December 2023 (UTC)

Request #2
Could the script perhaps make the "copy" link's href be something like just "#" so it doesn't look like it's been visited? Aaron Liu (talk) 21:51, 12 January 2024 (UTC)


 * As the documentation says, it's deliberately linked to the section itself so you can also copy the full URL by right-clicking it and selecting the browser's native "Copy link". Nardog (talk) 21:57, 12 January 2024 (UTC)
 * Ah, that makes sense, I'll have to read better next time :p Should this thing have a style that removes the purple (or even better, only show purple when you've copied) then? Aaron Liu  (talk) 22:03, 12 January 2024 (UTC)

Copy link not displaying on Firefox
Nardog, I have been using your tool for a while now, but recently it stopped displaying on desktop firefox, for no reason. It works fine on Chrome and desktop mode on mobile. I use the legacy vector skin. I reinstalled and still nothing. Do you know why it would stop working? Qwerty284651 (talk) 21:19, 30 May 2024 (UTC)


 * No idea, it's working for me on Firefox/Vector legacy. Do you see any console error? Nardog (talk) 22:49, 30 May 2024 (UTC)
 * I only see the copy link in the lead section, does not show up elsewhere. 2 errors popped up. Qwerty284651 (talk) 22:59, 30 May 2024 (UTC)
 * What version of Firefox are you using? Nardog (talk) 23:10, 30 May 2024 (UTC)
 * An old one. Qwerty284651 (talk) 23:19, 30 May 2024 (UTC)
 * Well, there's your reason. Nardog (talk) 23:27, 30 May 2024 (UTC)
 * It worked normally for several months. Not sure why it suddenly stopped working. Qwerty284651 (talk) 23:41, 30 May 2024 (UTC)
 * It's because I used something that has been supported by all major browsers for more than three years now when I updated the script in preparation for the Heading HTML changes. Why can't you just update it? Nardog (talk) 23:46, 30 May 2024 (UTC)
 * Have an old pc. Qwerty284651 (talk) 23:55, 30 May 2024 (UTC)

Bug report
CopySectLink is currently showing up twice (that is, I see  above each section. I am guessing that it is a result of T13555 (see also the thread at VPT); I am using Vector 2010 and it started yesterday (i.e. the WP:THURSDAY the change was deployed to that skin). Best, House Blaster  (talk · he/they) 02:20, 8 June 2024 (UTC)


 * Fixed. Nardog (talk) 06:45, 8 June 2024 (UTC)