Project:Village Pump/Flow/2023/07
This page used the Structured Discussions extension to give structured discussions. It has since been converted to wikitext, so the content and history here are only an approximation of what was actually displayed at the time these comments were made. |
![]() Archives
|
---|
|
Block needed
RESOLVED | |
blocked |
The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
Please block @S666nl, spammer. FlyingAce (talk) 04:42, 7 July 2023 (UTC)
Enable TemplateScripts on MediaWiki.org
Hi! For some time now, I've been slowly developing c:Help:TemplateScripts, a method for extending the functionality of templates with JavaScript. For obvious reasons, template scripts must be located at the MediaWiki namespace (and have the "TemplateScript-" prefix, see the code below) so they require community consensus and an authorized user to get there. Template scripts are currently available at the Spanish Wikipedia, Commons, and the Spanish and English Wikiversity. I'd like to propose enabling them here at MediaWiki.org too, for the following reasons:
- I'd like to turn the Synchronizer tool into a template script so that it loads automatically.
- I'd like to migrate and centralize here at MediaWiki.org the existing template scripts and documentation, per being more adequate than Commons.
- To attract more interest and developers, since MediaWiki.org is probably the most technically oriented of the Wikimedia wikis.
To enable TemplateScripts, the following code should be added to MediaWiki:Common.js and MediaWiki:Mobile.js:
// TemplateScripts are JavaScript scripts that extend the functionality of templates
var templatescripts = [];
$( '[data-templatescript]' ).each( function () {
var script = $( this ).data( 'templatescript' );
if ( script && !templatescripts.includes( script ) && /^[^&<>=%#]*\.js$/.test( script ) ) {
templatescripts.push( script );
script = encodeURIComponent( script );
mw.loader.load( '/wiki/MediaWiki:TemplateScript-' + script + '?action=raw&ctype=text/javascript' );
}
} );
Thoughts? Support? Objections? Cheers! Sophivorus (talk) 01:27, 12 July 2023 (UTC)
- I’d like to rather have an official solution, e.g. phab:T241524. I’m not strongly opposed to using this script in the meantime, but I have the feeling that the more temporary solutions we have, the less likely is that someone takes the time and effort to create an official one.
- By the way, I couldn’t find traces of this on Commons except for the help page, are you sure it works there? Tacsipacsi (talk) 09:53, 13 July 2023 (UTC)
- Hi! You're right, it's not enabled in Commons (I think at some point it was). As to an official solution, I'd love to see one too! However, that may still require several years (or never come to be, like with global modules and now graphs). Also, by the looks of it, migrating from TemplateScripts to an official solution with a parser function that loads gadgets (as suggested by phab:T241524) seems rather easy. Finally, enabling and developing TemplateScripts now may actually help an official solution come about, by building a small community of involved developers and giving WMF developers some real world examples of its potential. Cheers! Sophivorus (talk) 13:03, 13 July 2023 (UTC)
- If you want to pave the path for the official solution (and also in order to make template scripts more efficient by taking advantage of minifying), it’d be helpful if TemplateScript was also based on gadgets rather than random JS pages:
$( '[data-templatescript]' ).each( function () { var script = $( this ).data( 'templatescript' ); if ( script ) { mw.loader.load( 'ext.gadget.templatescript.' + script ); } } );
- Also, to make it compatible with VisualEditor, live preview etc., it should use the
wikipage.content
hook: mw.hook( 'wikipage.content' ).add( function ( $content ) { $content.find( '[data-templatescript]' ).each( function () { var script = $( this ).data( 'templatescript' ); if ( script ) { mw.loader.load( 'ext.gadget.templatescript.' + script ); } } ); } );
- (This doesn’t unload no longer necessary template scripts, but at least loads those that become necessary after the initial page load.) Tacsipacsi (talk) 11:10, 15 July 2023 (UTC)
- Excellent ideas! I just implemented them at the Spanish Wikiversity to test them out, see es:v:Special:Gadgets, es:v:MediaWiki:Common.js and the [add objection] buttons at es:v:Wikidebate/Cannabis
- for the end result. I'll implement them at the English Wikiversity and Spanish Wikipedia soon, if no issues, concerns or further changes follow. These are exactly the kind of ideas for which I think bringing TemplateScripts to MediaWiki.org is the way to go. Sophivorus (talk) 23:05, 15 July 2023 (UTC)
- @Legoktm @Bawolff @Pppery @Shirayuki @Ciencia Al Poder As some of the most active users here at the Village Pump, may I ask for your thoughts, objections or support on this? Kind regards, Sophivorus (talk) 23:31, 1 August 2023 (UTC)
- Not involved enough here to have an opinion, so if nobody else objects then feel free to go ahead. * Pppery * it has begun 23:32, 1 August 2023 (UTC)
- No objections.
- I'd prefer using tracking categories for those templates. However, category information in JavaScript is missing from Minerva due to phab:T206337, and it's going to be removed from core too (phab:T206250), which means we're left with using inefficient DOM searches... Ciencia Al Poder (talk) 16:17, 2 August 2023 (UTC)
- Done, see MediaWiki:Common.js, MediaWiki:Mobile.js and Synchronizer!
- As to the idea suggested by Tacsipacsi, I implemented it at the Spanish Wikiversity but found it a bit cumbersome, since it requires the addition of each script to MediaWiki:Gadgets-definition, an extra prefix to each script (MediaWiki:Gadget-TemplateScript-Example.js) and an extra description page per script (MediaWiki:Gadget-TemplateScript-Example). Furthermore, it makes explaining the whole idea more complicated: "TemplateScripts are gadgets that can be loaded from templates"? Perhaps they should be renamed to TemplateGadgets then? Despite these difficulties, Tacsipacsi's idea may still be the way forward, but I'd like to hear some thoughts on these difficulties before fully committing. Cheers! Sophivorus (talk) 16:43, 6 January 2024 (UTC)
Gadget CleanDeleteReasons doesn't work anymore
RESOLVED | |
![]() |
The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
MediaWiki:Gadget-CleanDeleteReasons.js appears to use the div wrapper instead of the input field, meaning it doesn't actually clear anything anymore. —Mainframe98 talk 09:43, 13 July 2023 (UTC)
- The software has offered a built-in way to blank delete reasons for many years, via MediaWiki:Exbeforeblank, MediaWiki:Excontent, and MediaWiki:Excontentauthor; I've blanked these so that the gadget will no longer be needed (whether they should instead be replaced with some other content, that doesn't include part of the deleted page's contents, is a question for a community discussion to decide). 「ディノ奴千?!」☎ Dinoguy1000 11:03, 13 July 2023 (UTC)
- Did this really need to be done? I actually liked the default deletion summary, and the system where admins who don't can disable it via a gadget seems preferable to forcibly disabling it on everyone. * Pppery * it has begun 14:48, 13 July 2023 (UTC)
- I would agree with Pppery Bawolff (talk) 16:01, 13 July 2023 (UTC)
- Fixing the gadget seems straightforward---just add the
.firstChild
selector in front of both of the.value
accesses. Clump (talk) 16:02, 13 July 2023 (UTC) - I didn't actually check if the gadget was enabled by default, just assumed that it was. If people prefer the default summaries be left in, I have no objections to the MediaWiki: pages being reverted. 「ディノ奴千?!」☎ Dinoguy1000 06:53, 14 July 2023 (UTC)
- It would be helpful if an interface admin (or someone else with gadgets-edit rights) could fix the gadget first. Clump (talk) 11:01, 14 July 2023 (UTC)
- Agreed in principle. But we also shouldn't leave challenged admin actions in place forever simply because nobody has the will to do the right thing. I note that Bawolff, who's already commented here, is an interface admin so could fix it themselves. * Pppery * it has begun 17:41, 19 July 2023 (UTC)
- What do you mean nobody has the will to do the right thing? I had to delete .js/.css pages from old pages as I couldn’t redirect them to those that were renamed. Tropicalkitty (talk) 18:15, 20 July 2023 (UTC)
- I see Tropicalkitty has gone on wikibreak so won't respond to this, but for the record "willingness and ability to do the right thing" would have been a better way of articulating my message - you have the willingness but lack the ability. * Pppery * it has begun 19:04, 20 July 2023 (UTC)
Done Bawolff (talk) 20:28, 21 July 2023 (UTC)
Template:Excerpt: subpage
There is the user who is persistently insisting on replacing "subpage" with either "child page" or something else. Shirayuki (talk) 00:50, 15 July 2023 (UTC)
- I see they've opened a discussion on the talkpage. I think it's better if you both discuss there rather than reverting each other. – Ammarpad (talk) 09:22, 16 July 2023 (UTC)
Edit request
RESOLVED | |
done |
The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
Could an interface admin please handle the edit request at MediaWiki_talk:Gadget-UTCLiveClock.js? Thanks. * Pppery * it has begun 19:02, 19 July 2023 (UTC)
- Bawolff, could you take a look into this please? Tropicalkitty (talk) 08:41, 20 July 2023 (UTC)
Project:Requests backlogged
RESOLVED | |
![]() |
The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
Could I get some crat attention at Project:Requests? There are several entries there than have languished for months. * Pppery * it has begun 21:38, 22 July 2023 (UTC)
Can't make a new password
Last year, I established a new e-mail address. I am trying to make a new password but when I send the request to my new e-mail address I don't get any response.
What is going on? How do I get someone to send me the e-mail to make up a new password? This is very frustrating, to say the least.
Please help. KramdenII (talk) 21:26, 23 July 2023 (UTC)
- Is this related to the Project:Support desk/Flow/2023/07#h-problem_changing_password_for_closing_logos-20230723214700 you opened later?
- You don't need an email address to change your password if you're logged in (like you are logged in right now). Simply go to Special:Preferences and update the password there (first you'll be prompted to insert your current password, as a security measure). Ciencia Al Poder (talk) 11:13, 24 July 2023 (UTC)
Deploying the Phonos in-line audio player to your Wiki
Hello!
Apologies if this message is not in your language, ⧼Please help translate⧽ to your language.
This wiki will soon be able to use the inline audio player implemented by the Phonos extension. This is part of fulfilling a wishlist proposal of providing audio links that play on click.
With the inline audio player, you can add text-to-speech audio snippets to wiki pages by simply using a tag:
<phonos file="audio file" label="Listen"/>
The above tag will show the text next to a speaker icon, and clicking on it will play the audio instantly without taking you to another page. A common example where you can use this feature is in adding pronunciation to words as illustrated on the English Wiktionary below.
{{audio|en|En-uk-English.oga|Audio (UK)}}
Could become:
<phonos file="En-uk-English.oga" label="Audio (UK)"/>
The inline audio player will be available in your wiki in 2 weeks time; in the meantime, we would like you to read about the features and give us feedback or ask questions about it in this talk page.
Thank you!UOzurumba (WMF), on behalf of the Foundation's Language team
02:26, 27 July 2023 (UTC) MediaWiki message delivery (talk) 02:26, 27 July 2023 (UTC)
rename request
The following discussion is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.
I want to rename my username to "DanSchlosser",I added an extra s during registration DanSchlosser (talk) 06:13, 28 July 2023 (UTC)
- @DanSchlossser: please make a request through Special:GlobalRenameRequest. Legoktm (talk) 06:18, 28 July 2023 (UTC)