Confirmed to work on patchdemo :-)
https://patchdemo.wmflabs.org/wikis/745f82bb2b/w/index.php?title=1886_in_Chile&oldid=154&diff=cur
- Queries
- All Stories
- Search
- Advanced Search
- Transactions
- Transaction Logs
Advanced Search
Mon, Apr 8
Sat, Apr 6
Not ideal but there is a gadget that at least adds whitespace:
// [[MediaWiki:Gadgets-definition]] formatter (links and stuff) if (mw.config.get("wgCanonicalNamespace") == "MediaWiki" && mw.config.get("wgTitle") === "Gadgets-definition" && document.querySelector(".mw-parser-output") ) { mw.loader.load("https://meta.wikimedia.org/w/index.php?title=User:Nux/gadgets-definition-ux.js&action=raw&ctype=text/javascript"); }
You can add this in:
https://meta.wikimedia.org/wiki/Special:MyPage/global.js
and it will fix scrolling on:
https://commons.wikimedia.org/wiki/MediaWiki:Gadgets-definition
Mon, Apr 1
I'm with Izno on that (especially with point 1). That particular template feels like even/odd modules in npm [:
Wed, Mar 20
I should mention is that what I would love to have is <section> or any kind of parent/wrapper of the elements in the section. That would make many such things as nominations easier (del requests, good article, dyk article etc).
Hi. I specifically moved buttons away from section headers recently and into a template we can control locally (on wiki). This has drawbacks -- I needed to add section names to the template... but also again something we can control locally, not something that might change with a skin or MW update.
Mar 14 2024
Mar 9 2024
In T334940#9617644, @NorthernMoonlight wrote:it has become clear that there isn’t a safe shortcut here and that the path forward will require a substantial investment – one that we have not yet started given the other priorities we’ve been working on.
Am I reading this right? A year after a major feature was broken they haven’t even started working on it?
Mar 1 2024
Feb 29 2024
In T357197#9582720, @SD0001 wrote:In T357197#9531264, @Krinkle wrote:It's not that simple I'm afraid. To diverge browser support in Gadgets from the rest of MediaWiki in this way you'd need customisation for mw.loader, for startup.js,
No customisation is required when gadgets are in a separate group. If any of them contain an ES8 feature which is not supported in the browser, the bundle doesn't work – which at the maximum can only cause other gadgets to not load, which seems like a reasonable tradeoff considering that no one so far has brought up a single example of a Grade A browser that doesn't support ES8. Even if one exists, gadgets are optional enhancements without which the site still works. Quoting from the frontend best practises: "Embrace that every page starts with basic HTML and CSS, and that JavaScript adds optional layers that may or may not arrive. Its eventual arrival depends on numerous factors, and may vary over time even for the same person"
Feb 25 2024
Fixed by moving style out of text element, so there seem to be some problem with the render possibly related to style cascade.
Feb 13 2024
As someone who spent years maintaining user scripts and gadget on en.wp and providing support for users on WP:VP/T..... There is some truth to that, but I'd argue that a significant amount of the userscripts and gadgets are continuously broken. They cause issues for people where their javascript sometimes doesn't load. They cause errors to show up in the WMF logging.
Feb 10 2024
[…] I've tested building my DYK tool with Babel. The build is significantly slower. […]
This is an excellent argument against such build step! We generally don't use one for MediaWiki. Do you still need it? For many devs, they mainly did this in ~2013 as a way to get "Package files" and ES6 syntax. These are supported natively now. Build tools now mostly a left-over trend from the 2010s era of frontend development, involving needless complexity for largely unproven and misunderstood benefits.
I just want to add a few things to those already quoted by @SD0001 (thanks).
Feb 9 2024
@Nux Standardisation is not in question. Unlike new Web APIs (such as fetch), which can be polyfilled, or used via a conditional "if" statement, new syntax, if allowed even once, immediately breaks all code in many browsers that we still support. You can complain to upstream TC39 for having introducing features in ES2017 in a way that is backwards-incompatible. When MediaWiki raises its minimum requirement to ES8/ES2017, we will on the same day, raise the ESLint and site script validator to also allow this syntax.
In T350181#9527187, @Izno wrote:Diff colors: see T90948: Identify the best diff style (mobile or desktop) and use it on both mobile and desktop, which has related links and rationale for why blue and yellow exist. The short answer is red-green color blindness, especially in the context of inline diffs. That task has already been linked here and is the correct place to discuss further if at all.
Hi. I was forwarded here from another task :). I did a colour change for myself as I had problems remembering on mobile which colour is which. Changing to red-green helped with that.
Feb 8 2024
Sorry, I forgot I have a much smaller request. Could you flip the legend in HTML? I think "removed" belongs on the left side, and this is where inline diff puts "removed".
I was hoping I wasn't too late to make all of them red-green (so changing mobile/wikitext, not VE)... I think I agree with Sam here:
There are no plans currently to raise browser requirements to ES8/ES2017 or ES2020 etc. Not likely until browser engines, browser vendors/apps, audience usage thereof catch up.
Feb 2 2024
In T334940#9510646, @Lockal wrote:
Jan 30 2024
Just BTW, but it is weird that visual is red-green and wikitext (inline) diff is yellow-blue. Shouldn't they both be red-green?
Jan 29 2024
In T334940#9480339, @TheDJ wrote:
Separate domain to serve iframes from, so that we can have interactive and cacheable content (pretty complex)
Jan 20 2024
Jan 14 2024
In T178356#9458411, @SD0001 wrote:In T178356#9458355, @Nux wrote:(ES2018) for await - Firefox 58+, Safari 11.1+, Chrome 63+, Opera 50+, Edge 18+
For the record: This is incorrect. Both async and await comes with ES2017/ES8. See e.g.: https://flaviocopes.com/es2017/#async-functions and also https://262.ecma-international.org/8.0/
It's not incorrect. for await is for asynchronous iteration which appeared only in ES2018. https://caniuse.com/?search=for%20await
(ES2018) for await - Firefox 58+, Safari 11.1+, Chrome 63+, Opera 50+, Edge 18+
Note that async allows you to do much, much more readable code. E.g. by using await in HTML dialogs:
https://github.com/Eccenux/wiki-DYKCzyWiesz/blob/59d3b9ed4d93b6c42a59a9e7ce85b327d4bd9d64/src/DoneHandling.js#L80
I did not mean to argue that using requiresES6 for ES8+ should be supported, only that if that parameter is dropped or people are directed to remove it, Tech News should make it clear that that isn't a no-op change. I don't think it's that unlikely that someone did use for ES8+ code, either because they did not realize the code is ES8+, or because they didn't know requiresES6 means "ES6 and ES7 but not ES8". If a gadget breaking is the gadget developer's fault, it is still helpful to point them to the cause of the breakage.
Jan 8 2024
Jan 4 2024
You need to change comments moving them out of list items. https://ar.wikipedia.org/w/index.php?title=%D9%85%D9%8A%D8%AF%D9%8A%D8%A7%D9%88%D9%8A%D9%83%D9%8A:Gadgets-definition&action=edit
Dec 27 2023
Oh, so all of that leads to an article. I assumed it was for a script :)... So that is not blocking removal of the Gadget namespace from enwiki too.
Dec 26 2023
Dec 11 2023
Nov 28 2023
Nov 25 2023
So if I understand it correctly, when sandbox'ing is applied, it always gets a transient origin, which means that upon each request the origin effectively changes and thus there is no caching right ? And the only way around it is using a separate domain without sandboxing ?
I think the message should be modified. This is not a very friendly message. Especially with that "localhost" which might freak out a dev 😉 (my initial thought: why is Wikipedia trying to connect to my localhost). Jokes aside, the message does suggest there is problem on my side but – as I understand – this is mostly a backend problem. So maybe log some details to JS console or a tooltip or something...
Nov 20 2023
I also found this in whatwg spec:
<iframe sandbox src="https://usercontent.example.net/getusercontent.cgi?id=12193"></iframe>
[Warning!] It is important to use a separate domain so that if the attacker convinces the user to visit that page directly, the page doesn't run in the context of the site's origin, which would make the user vulnerable to any attack found in the page.
Use a separate but unsandboxed domain (en.wikipedia.wikimedia-usercontent.org or something like that) that internally resolves to the same wiki (with similar effects to the "sandbox mode" mentioned above, except it wouldn't do sandboxing, just relying on the origin / registrable domain being different). This would of course vastly increase the effort required (buying the domain, setting up DNS rules, certificates, a bunch of changes to site configuration...).
Nov 10 2023
The quick fix for this particular case is to update the URL in Toolhub to the un-encoded value of https://commons.wikimedia.org/wiki/File:Logo_Dzień_Nowego_Artykułu_Orem_version.svg. I have done this at https://toolhub.wikimedia.org/tools/dna/history/revision/46196/diff/48064 and the desired icon is now rendering.
Nov 3 2023
Oct 31 2023
Thanks for the fix. That seems like a less invasive way then I wanted to do it.
Oct 30 2023
Oct 29 2023
Ci/cd configuration can be separated. For example I have a Jenkins installation of which configuration is not accessible to anyone. Jenkins pools GitHub and runs Wikiploy. That Wikiploy script can be in a separate repo if I need to. There is no problem in that.
Oct 26 2023
So I kind of actually implemented this myself 🙂
Oct 19 2023
Oct 11 2023
Does that mean you cannot reach non-mobile https://pl.wikipedia.org/wiki/Specjalna:Różnica_mobilna/71469982 anymore? Because I can.
Oct 8 2023
Sep 26 2023
I assume modules and templates using the classes are also affected, right?
https://pl.wikipedia.org/w/index.php?search=insource%3A%2Fmw-ui%2F&title=Specjalna:Szukaj&profile=advanced&fulltext=1&ns8=1&ns10=1&ns828=1
Petscan also depends on this. Or to be more exact it assumes calback parameter is available to avoid CORS issues.
Sep 23 2023
Hi. @Aklapper this shows that Wikipedia:Portal wikipedystów also triggers the switch of skin from monobook (prefered by Cuku New) to default (V'22).
If supporting negation perhaps it should be thought about more broadly and apply to all options (see also T342532)
Hm... I guess the parser part can be more universal. But I think having gadgets not in main namespace would help with budgets etc more. I assume most people, most of the time, probably visit only the main namespace.
Sep 22 2023
For the performance sake could you support namespace!=0 syntax?
Sep 20 2023
@Jdlrobson done. Didn't help, but I guess maybe cache? (purge didn't help though)
Sep 18 2023
For Polish Wikipedia all disambiguation pages have {{Ujednoznacznienie}} on top and the page preview fails for them.
Sep 16 2023
Sep 14 2023
Seems like tags with explicit display:none are removed. So the problem was not the span with class (like I assumed). I've modified our template and it should work now.
I think .noexcerpt should be added explicitly to templates (rather then implicit, default class for Phonos).
Sep 13 2023
Did you ever thought of using NodeJS?
Sep 12 2023
@AlexisJazz Seems I found a way, if that helps. They have some rules for addresses/page title as seems.
wgPageContentModel:"sanitized-css" wgRelevantPageName:"Template:Legend/Style.css"
@Izno Actually NavFrame is used on all year pages for collapsing navigation in a nice and more accessible way (both for sighted users and for users using screen readers and for mobile UX). But if you think you can do it with the default then we can discuss that. We can discuss that on WP:BAR:TE or on the template's page. In general default collapsing is visibly slower to load though.
A table with all this data would be great too. I mean something like:
{| |- ! gadget !! size [KiB] !! zipped [KiB] |- ... |}
login.toolforge.org is not working too (even after flushing local dns). So no way to ssh into TS.
Sep 11 2023
In T111565#9149907, @AlexisJazz wrote:In T111565#9141090, @Msz2001 wrote:In T111565#9141088, @matmarex wrote:In T111565#9139046, @Msz2001 wrote:It's worth noting that mobile MediaWiki already supports collapsible class, which is almost the same as mw-collapsible in appearance.
That doesn't work for me. I don't think it's a MediaWiki feature, but it's a fairly common on-wiki customization (older than mw-collapsible).
Ah, appears that you're right. I must have missed the on-wiki code that supports it.
On English Wikipedia it's part of https://en.wikipedia.org/wiki/MediaWiki:Common.js but Common.js doesn't load on mobile.
Curiously, plwiki (which appears to be your home wiki?) has https://pl.wikipedia.org/wiki/MediaWiki:Mobile.js to enable collapsible elements on mobile. While shorter, it's less efficient than the gadget proposed on enwiki and won't work when the page content is refreshed e.g. after editing a page.
[edit]
Oh, you created that page! I'd actually suggest you install https://en.wikipedia.org/wiki/Wikipedia:MakeMobileCollapsible#Installation_on_other_projects as it's more efficient than loading the module unconditionally on every page load.
Sep 9 2023
Sep 2 2023
This code is used on wikisource:
var mwskin = mw.config.get('skin'); var parentId = mwskin === "vector-2022" ? 'p-associated-pages' : 'p-namespaces'; var item = mw.util.addPortletLink( parentId, '#', "Lorem ipsum"); if (item && mwskin === "vector-2022") { item.classList.add('vector-tab-noicon'); // v22 }
I think you're looking for https://toolhub.wikimedia.org/tools/patchdemo ?
Isn't this what the Beta-Cluster is for?
Sep 1 2023
Aug 28 2023
The example book looks terrible on my monitor in Vector '22:
https://fr.wikisource.org/wiki/Criton_(trad._Cousin)?match=en
Aug 15 2023
Aug 14 2023
Aug 13 2023
I believe that code is more likely to have a valid maintainer name. The same applies to documentation within code, as you might have noticed. This has been my experience at least. Documentation in comments tends to be more up-to-date in general, not just in the context of Wikipedia scripts.
The goal of this task was really to encourage someone who had never edited before to try editing for the very first time. We tried to design the task in a way that was extremely simple and really limited user options / limited decision fatigue. The good news is it really does help more new account holders try editing for the first time: Add a link Experiment analysis. And the good news is that although the task is fairly limited, newcomers do seem to progress on and try new types of editing: Newcomer task edit type analysis.
Aug 6 2023
Aug 5 2023
Two more things missing (worse then Quarry):
Is there any tutorial on how to use the Superset? I tried to run a simple query on plwiki but initially failed to find a database. It would be helpful to have a welcome page that explains how to find databases or add the same links Quarry has in the menu.
Aug 4 2023
Changed hideSidebar upstream. You can update uk.wiki.
https://pl.wikipedia.org/wiki/Wikipedysta:Nux/hideSidebar.js
Jul 30 2023
This could be extended for all types of edit tasks I think. Like when you want to add a picture, but maybe not as just image in the body, but in the infobox. Or I want to add an image and add an alt text and some links.
Jul 26 2023
Sorry, I wasn't able to test it before the review. I will need to install the latest MW, but not sure when will I have enough time to do so as I am on and off from home...