Project talk:Terminology gadget/Archive/1
Disabled
@Nike: Why did you disable the gadget? —Tacsipacsi (talk) 17:17, 9 April 2023 (UTC)
- It was a mistake. Nike (talk) 09:53, 11 April 2023 (UTC)
Link from terminology.json to Project:Terminology gadget
The message on terminology.json has a link to "Project:Terminology Gadget" (G in upper case) which dosen't exist. Existing page name is "Project:Terminology gadget" (g in lower case). Kokage si (talk) 11:04, 31 May 2023 (UTC)
- @Kokage si: Thanks for the heads-up! It was a mistake in the Japanese translation, which I just fixed. Jon Harald Søby (talk) 13:47, 31 May 2023 (UTC)
Extension
This is super neat! Any plans for turning it into a proper extension? Or at least enabling the gadget for all users? Tgr (talk) 17:02, 9 July 2023 (UTC)
- @Tgr: Thanks! It is already enabled by default for everyone here on TWN. No plans for making it into an extension at the moment, I don't have the time for that any time soon I think (as long as it works as it should here, that's the most important thing I think.) Jon Harald Søby (talk) 21:27, 9 July 2023 (UTC)
- In the Language team we are thinking of bringing glossary support, at least partially, to the Translate extension. No concrete plans yet. Nike (talk) 13:24, 12 July 2023 (UTC)
Categorization
Previously, we used this table for Hungarian. I think there is some value in being able to say which extension a given translation is for. Both because in very rare cases there might be conflicts (e.g. FlaggedRevs uses "editor" in a non-intuitive way) and because it helps with maintainability in general. Tgr (talk) 17:36, 9 July 2023 (UTC)
- @Tgr: Yes, in my initial idea I wanted to be able to specify what "domain" a certain translation is valid for. But that would add a lot of complexity, not only in the gadget code, but also for end users in how they would enter/add terms. So I think it is better to annotate such things in "free-form", e.g. by noting in the usage notes field if a translation is only meant to be for a certain domain. Does that make sense? Jon Harald Søby (talk) 21:30, 9 July 2023 (UTC)
- It's certainly much simpler, so I can understand that choice. In some cases it would be nice to avoid showing bogus/irrelevant annotations. It's probably an uncommon problem though.
- I guess it also depends on how much you expect the tool to be used - e.g. if people start using it for non-Wikimedia software, those definitely need separate dictionaries. Tgr (talk) 22:03, 9 July 2023 (UTC)
Not working in action=edit?
IIRC, it used to work in action=edit, but now it no longer works. Diskdance (talk) 05:08, 29 May 2024 (UTC)
- @Diskdance: Do you have an example of a place where that should work but doesn't? Jon Harald Søby (talk) 13:25, 29 May 2024 (UTC)
- @Jon Harald Søby: For instance, in https://translatewiki.net/w/i.php?title=Wikimedia:Wikipedia-ios-aaald-single-reference-added-description/zh-hans&action=edit, the "Message definition" area should highlight "added" like the one in Special:Translate, but it doesn't. Diskdance (talk) 13:30, 29 May 2024 (UTC)
- I never made it work for those types of pages, but I could try to fix that. But it might take some time. Jon Harald Søby (talk) 13:40, 29 May 2024 (UTC)
- @Diskdance: I've added this now, please test. Jon Harald Søby (talk) 07:31, 30 May 2024 (UTC)
- It works. Thank you! Diskdance (talk) 10:57, 30 May 2024 (UTC)
- @Diskdance: I've added this now, please test. Jon Harald Søby (talk) 07:31, 30 May 2024 (UTC)
- I never made it work for those types of pages, but I could try to fix that. But it might take some time. Jon Harald Søby (talk) 13:40, 29 May 2024 (UTC)
- @Jon Harald Søby: For instance, in https://translatewiki.net/w/i.php?title=Wikimedia:Wikipedia-ios-aaald-single-reference-added-description/zh-hans&action=edit, the "Message definition" area should highlight "added" like the one in Special:Translate, but it doesn't. Diskdance (talk) 13:30, 29 May 2024 (UTC)
German localization broken because of FORMAL
@Jon Harald Søby: While I was working with the interface today I noticed that the "Add term" dialog shows the German translation MediaWiki:Gadget-term-dialog-footnote/de raw, unparsed. I believe this revert was done for this reason, and undoing it was not correct. But I don't want to get involved in an edit-war. It looks like messages that are parsed in the frontend really can't use the FORMAL feature as long as phab:T366602 is not fixed (and deployed here). The responsible jqueryMsg and mw.language modules don't contain any code for FORMAL and apparently break and stop working when curly braces are nested in a way the code can't understand. TMg (talk) 11:00, 6 August 2024 (UTC)
- @TMg: That's not the reason the revert was made, that user just really doesn't like this feature. But yeah, I've just reverted it now until gerrit:1038812 (or an alternative) is merged. Jon Harald Søby (talk) 11:26, 6 August 2024 (UTC)
Newlines eaten on the legacy interface
Please take a look at https://translatewiki.net/w/i.php?title=MediaWiki:Blockedtext-partial/hu&action=edit. Before the gadget loads (or if it’s disabled), the English message contains several line breaks. Once the gadget loads, they disappear. The same message appears as expected on Special:Translate; the newlines are kept there. Could you please fix the legacy interface? Thanks in advance! —Tacsipacsi (talk) 16:33, 13 August 2024 (UTC)
- @Tacsipacsi: Thanks for the report! It should be fixed with this and this edit. Please verify. :-) Jon Harald Søby (talk) 11:05, 14 August 2024 (UTC)
- @Jon Harald Søby: Thanks, looks good! However, the JS change looks a bit scary: what if the line break is formatted differently (
<br />
,<br style="">
etc.)? Maybe the Translate code should be changed so that it also useswhite-space:pre-wrap
instead of HTML line breaks. —Tacsipacsi (talk) 11:16, 14 August 2024 (UTC)- Created phab:T372463. —Tacsipacsi (talk) 11:38, 14 August 2024 (UTC)
- @Tacsipacsi: I think it should be safe, because the
<br />
tags are inserted by the extension (converting line breaks into<br \>
), and I don't see any reason why that would change to something different in the foreseeable future. But yeah, changing it in the extension would also solve the problem, but I'll leave that to someone else for the moment. :-) Jon Harald Søby (talk) 11:41, 14 August 2024 (UTC)
- @Jon Harald Søby: Thanks, looks good! However, the JS change looks a bit scary: what if the line break is formatted differently (