Help talk:Extension:TemplateWizard
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. |
This board is for discussing and getting help about the TemplateWizard extension.
Issues can also be reported on Phabricator, using the #mediawiki-extensions-TemplateWizard tag.
Translation
editThe 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 admin tag this page to enable its translation? Djiboun (talk) 09:29, 1 November 2018 (UTC)
- Thanks for raising this @Djiboun. I will add more content to the page and then request an admin to enable translations. NKohli (WMF) (talk) 16:39, 1 November 2018 (UTC)
- Ok, thank you for your reply. I look forward to starting the french translation. Djiboun (talk) 17:13, 1 November 2018 (UTC)
- It is now available to translate. Thank you @Djiboun. NKohli (WMF) (talk) 19:44, 2 November 2018 (UTC)
Need options to change date formatting
editI see that the current default date format for access-date and source date is "YYYY-MM-DD" (as in "year-month-day"). This contrasts the need for consistency per w:en:Wikipedia:Date formattings and w:en:Wikipedia:Manual of Style/Dates and numbers. If you can add more options to allow users to change the date formatting, especially for individual articles, that would be nice. George Ho (talk) 22:52, 1 November 2018 (UTC)
- They would need to change the Extension:TemplateData specifications. It specifically requires that dates be output as the standard ISO format. This is necessary to ensure that the tools like visualeditor can change the value, if it has a weird or ambiguous format then that is downright impossible. For instance, other languages use different calendars.
- Long term, they need to support different calendars as well as output formats. But that's going to be tricky, considering that even html tags like <time> don't support them, and editors wouldn't like typing a complicated <time dateformat=XXX >"YYYY-MM-DD"</time> format anyway. 197.218.92.212 (talk) 19:34, 2 November 2018 (UTC)
- How about an option to manually type dates, similar to that of UploadWizard, i.e. the "Use" portion of UploadWizard? George Ho (talk) 22:15, 2 November 2018 (UTC)
- It wouldn't fix this issue. It needs a feature request to Templatedata to allow different date formats. An alternative would be changing the template to specify that parameter as plain text, that would allow adding it as plain text.
- On English wikipedia it may be a slight annoyance, in non-latin based wikis it may add a completely unintelligible date if it doesn't use arabic numerals at all. 197.218.82.255 (talk) 19:27, 6 November 2018 (UTC)
- I decided to add the "date" parameter(s) without using the TemplateWizard to fill them out. That way, I can fill them out manually.
- For now, until the issue is fixed, or more date options are provided, I don't find the calendar date
formatfeature either sustainable or reliable. George Ho (talk) 19:35, 6 November 2018 (UTC) - As a temporary workaround they could add the same feature as visualeditor that always allows entering plaintext for any given parameter. That way even if someone enters the wrong templatedata for a template, it will still allow the user to enter stuff. Of course that is less of a problem for wikitext editors because they can always insert the whole template call without parameters, and manually enter everything.
- This seems to be yet another disadvantage of not reusing code from VisualEditor, now they need to re-implement everything. On a positive note, if something useful is added to templatewizard that may create pressure for VE developers to add to it too. 197.218.82.255 (talk) 20:18, 6 November 2018 (UTC)
- I made a request at Extension talk:TemplateData. George Ho (talk) 20:20, 6 November 2018 (UTC)
- I commented on the calendar (sub)feature not allowing inserting of just month and year without a day. George Ho (talk) 07:41, 9 November 2018 (UTC)
- I see that someone else created a Phabricator task related to this. George Ho (talk) 08:11, 12 November 2018 (UTC)
- on the calendar (sub)feature not allowing inserting of just month and year without a day.
- http://armstrong-opt.ru/ http://armstrong-opt.ru (talk) 11:49, 27 November 2018 (UTC)
Doesn't seem to address specific issues
editGoing by the screenshots and by the actual wishlist item, it seems obvious that some things were completely missed.
- No menu to filter types of templates (https://phabricator.wikimedia.org/T55590) - The wishlist seems to specifically ask for an infobox wizard and talks about newbies, but there is neither any way to filter only those infoboxes, quote templates, or anything else. This could be implemented by either fetching most used templates in a category or using wikidata to get them in non-english wikis, e.g. https://www.wikidata.org/wiki/Q19887878.
- Date type is not properly supported - It seems that the wizard either has a limited interpretation of the templatedata spec, or simply ignores it. The spec also allows the use of time in addition to dates. But this doesn't seem possible with this tool. Arguably, the templatedata spec should be improved to indicate the expected output format.
- Inability to select from a list of items (https://phabricator.wikimedia.org/T53375) - the wishlist item talks a lot about invalid structures. This doesn't address wrong template input, e.g choosing a country name from a dropdown. 197.218.92.212 (talk) 16:09, 2 November 2018 (UTC)
- Hello. Thanks for taking the time to reply! I will address your points below -
- When we started working on this project, we realized it could be useful for all kinds of templates and restricting it to just infoboxes seemed like a waste. You can still quite easily search for all infobox templates by using the search function. We thought about the idea for showing popular templates for new users but that is actually quite complex to compute, technically. We then settled on the idea of showing recently used templates for each user (https://phabricator.wikimedia.org/T194434) but we haven't implemented that yet.
- For this point, can you give me a specific example where you don't see date type supported correctly? We did test this feature but it seems like we missed some use cases.
- You are actually the first person to bring this to our attention as it was not mentioned in the wishlist proposal or any of the project page discussions I had with users. This seems like a very useful thing to have. I cannot commit to working on this currently as the team has several other projects to go through before the year end but we will definitely keep it on our list of things to do in the long-term.
- Thank you so much. NKohli (WMF) (talk) 19:34, 2 November 2018 (UTC)
- It is certainly useful to be able to insert all templates. But the request stressed newbies, and newbies don't often know what templates even exist. They might as well type random stuff in the search box, remember that wikis in different languages may have named them quite differently. It would only need to list some 10 most used templates within specific categories to give the user a hint. It certainly would not need to list the thousands of templates that wikis have. There's also a lot of free whitespace that could contain that.
- The date parameter isn't supported properly because the widget being used only shows dates, not time. There was also a hint of it here:https://meta.wikimedia.org/wiki/Talk:Community_Tech/Template_wizard#Inserting_dates. So for example, it can only insert stuff like "2014-05-09" but never "2014-05-09T16:01:12Z". See (https://phabricator.wikimedia.org/T100206#2197740). Try pasting that longer date in the templatewizard date input and it will simply be discarded.
- About point 3, maybe they thought it was obvious, but some users make mentions about template parameters being added incorrectly : "On frwiki too template editors ask bot maintainers to change parameters of infoboxes. Here it seems to want to take the problem at the root for page creations. with a tool to directly add the right syntax.".
- Anyway, thanks for the explanations... 197.218.81.214 (talk) 20:30, 2 November 2018 (UTC)
- Also, generally, it might be a good idea to pull in all templates currently on the page, and make it possible to insert them... 197.218.81.214 (talk) 20:47, 2 November 2018 (UTC)
- Sorry about the late reply. This got lost in my inbox. So one of the reasons it's hard to find "popular" templates is because generally the MOST transcluded templates are meta/banner templates. Which aren't meant to be used by themselves. But it's not trivial for the software to be able to recognize that. So the only workaround I see to this is for us to allow every wiki to configure what the list of popular templates would be for their wiki. This isn't exactly straightforward either and is likely to spark some wars on what templates are important enough to be shown in the list.
- I do completely agree that giving a new user a completely empty screen is not a good experience.
- About the dates, I will create a Phabricator to investigate this issue and see if we can find a solution for it. Thanks for raising this. NKohli (WMF) (talk) 00:13, 10 November 2018 (UTC)
This was true. However, end-users have already solved that problem by A) categorizing such templates B) adding it to wikidata . For instance, if I wanted to know what are the most used templates that fit into neat types that are likely useful for the average user:So one of the reasons it's hard to find "popular" templates is because generally the MOST transcluded templates are meta/banner templates.
- Get list of most used templates Special:MostTranscludedPages
- Get specific categories of templates linked through wikidata (https://www.wikidata.org/w/index.php?search=&search=haswbstatement%3AP279%3DQ11266439&title=Special%3ASearch&go=Go)
- Fetch infoboxes, navigation boxes, and other lists from wikidata: [1][2]
- Filter list #1 by lists fetched in #3 using interwiki links, and show about 10 infoboxes, and 10 navboxes, simply excluding anything that doesn't fit into selected categories.
- Probably the most useful templates are utility templates, such as template:date, template:formatdate, quote, etc. Although they currently aren't classified properly in wikidata, this would be trivial for volunteers. This would also make it possible to warn users when they are attempting to insert a template that doesn't belong in a content namespace, e.g. documentation templates ( https://www.wikidata.org/wiki/Q4608595).
- Alternatively, if it is deemed unfeasible, it might be possible to handle tasks https://phabricator.wikimedia.org/T165053 or https://phabricator.wikimedia.org/T166525 . Either the latter or the wikidata solution seems like it should have certainly been part of this project because it specifically asked for an infobox insert tool and it was mutated into something else (for good reasons) with an empty screen.
- For the dates, it seems simple enough to use the date picker used in Special:ApiSandbox#action=query&format=json&list=recentchanges .
- It might generally be a good idea to clarify the exact specifications and limitations of future wishlist requests before perusing them. 197.218.84.40 (talk) 10:57, 11 November 2018 (UTC)
TemplateWizard in VisualEditor
editThe 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.
Hi all, is there a reason why the Insert Template widget in VisualEditor looks and behaves differently than the TemplateWizard in WikiEditor? Is there a plan to update the Insert Template in the way the TemplateWizard looks like? I believe this is quite important from the UX-point of view. Anyway, great update for the WikiEditor, indeed! YjM (talk) 18:50, 2 November 2018 (UTC)
- Hi @YjM. The insert template widget you see in VisualEditor has been there since a few years. The wishlist project was to bring that functionality to the WikiEditor so when we were working on it, we decided to give it a UI update. I don't believe the VisualEditor team (known as Editing team now) has any plans to update the VisualEditor version currently but I do plan to bring this up with them in case they are interested. Thanks for the feedback! NKohli (WMF) (talk) 19:18, 2 November 2018 (UTC)
- It is because developers reinvented the wheel. To put it simply they are different applications. One only works in Wikitext Editor and the other is part of Visualeditor and doesn't work elsewhere. For instance, Visualeditor doesn't have any date input dialog, nor a specific one for adding numbers. Both are currently added as simple text.
- In principle they should be sharing code, in practice chances are that they will diverge more as time goes by. 197.218.92.212 (talk) 19:21, 2 November 2018 (UTC)
- That's correct. The reason we had to split it up is because the template widget you see in VisualEditor is built in such a way that the code cannot be extracted out or reused outside of VE. We had a long discussion about this possibility with the VisualEditor engineers and they advised us to build it from scratch. In an ideal world, the code would be the same (and shared from the same source) between the two applications. NKohli (WMF) (talk) 19:37, 2 November 2018 (UTC)
- Thanks for the answers. Honestly, yours, @NKohli (WMF), made me sad.
- It makes no sense, from the user's POV, why these two things, which serves the very same purpuse, might possibly be different. I hope you will find a common ground with the V|E team and will share as much of the code as possible.
- I will probably propose this in this years' wishlist survey, if it helps in pushing the things forward. YjM (talk) 22:14, 2 November 2018 (UTC)
Wikieditor versions
editIt says in the info not to use 2017 wikieditor. I don't know wht editor I am using and have been having problems. How do I find different versions of wikieditor? Zoeannl (talk) 04:36, 5 November 2018 (UTC)
- Hi Zoeannl, to use the 2010 WikiEditor you should tick 'Enable enhanced editing toolbar' in your preferences under the 'Editing' tab, and have 'New wikitext mode' disabled under 'Beta features'. (And to use the TemplateWizard extension, enable 'TemplateWizard' under 'Beta features'.) For a complete list of all editors, see Editor. Jeroen N (talk) 14:32, 5 November 2018 (UTC)
- hi you guys i need help finding the 2020 wikieditor Alexis.morgan680 (talk) 21:50, 3 March 2020 (UTC)
Sorting parameters of "w:Template:Track listing"
editI appreciate separating the "Suggested parameters" and "Optional parameters" for most templates. However, that makes using w:Template:Track listing via the wizard more awkward to use and edit. By separating its parameters into two categories, the suggested parameters would be above the optional ones when the template is inserted. titlen
and lengthn
are currently the suggested parameters and organized by numerals. However, optional ones, like writern
and extran
, would be below the supposed last/final number of titlen
and lengthn
, e.g. title20
and length20
. The same can be said about other language versions of the template. I had to manually sort reorganize the parameters after the template insertion. Does the sorting issue matter much enough to resolve it, or what else can be done about it? George Ho (talk) 06:23, 9 December 2018 (UTC)
- Hi @George Ho. This is indeed a tricky case. Do you think changing the template to make all the parameters optional is better? I don't know if TemplateWizard can be made smart enough to solve this case. NKohli (WMF) (talk) 03:29, 15 December 2018 (UTC)
- Unless the coding is technically too complicated, I don't mind merging the "suggested" column into the "optional column". Indeed, re-sorting makes parameters easier to use, but the "optional" column would become lengthy. Nevertheless, let's test that out and see whether the change works productively. George Ho (talk) 05:09, 15 December 2018 (UTC)
- To be clear, I was thinking of changing that for this specific template in its TemplateData. I don't think merging "Optional" and "Suggested" parameters into one group for all templates is a good idea. I have heard feedback that users like having those parameters be separate. NKohli (WMF) (talk) 05:21, 15 December 2018 (UTC)
- Oh... I don't mean merging two into one for all, which I agree with you about. You can change the template's TemplateData if you want. George Ho (talk) 06:11, 15 December 2018 (UTC)
Disable bundled TemplateWizard or locate files
editRESOLVED | |
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.
I have a problem where I would like to edit the *.js files that make TemplateWizard work as I need some custom behaviour. The problem is that some version of TemplateWizard came "bundled" with my verison of MediaWiki. I wouldn't think this was a problem except that I have installed the Extension manually also (So that i can edit these files) but it seems to be using the bundled version and its *.js files as i can completely corrupt the ones used by the manually installed extension and the TemplateWizard still works fine. It does show up in Special:Version so i know it is installed.
To solve this problem i would ideally like to disable the bundled version of TemplateWizard unless someone can point me to where its files are located. Hoefsldyla (talk) 01:38, 11 December 2018 (UTC)
- Hi @Hoefsldyla. Are you sure that TemplateWizard was bundled with MediaWiki? It's a fairly new extension. It should not be bundled with MediaWiki. A quick search on the bug tracker didn't show up any results. NKohli (WMF) (talk) 06:46, 11 December 2018 (UTC)
- Hmm that is odd as I didn't install it, however maybe maybe it came with Visual Editor. Either way the same problem still applies. Hoefsldyla (talk) 19:01, 11 December 2018 (UTC)
- @Hoefsldyla Can you share a screenshot of the wizard you are talking about? VisualEditor does not use TemplateWizard but has its own wizard to insert templates. I'll be able to help you more if you can tell me what you want to disable. :) NKohli (WMF) (talk) 19:26, 11 December 2018 (UTC)
- @NKohli (WMF) Really? I thought they must be the same thing as they look identical and have identical functions. In that case maybe TemplateWizard isn't working at all? If I am editing a page in visual editor mode where should the button to using TemplateWizard be situated? Here are screenshots [3] [4] Hoefsldyla (talk) 19:56, 11 December 2018 (UTC)
- I have also noticed that when I have the TemplateWizard extension loaded my WikiEditor dissapears from source mode Hoefsldyla (talk) 20:16, 11 December 2018 (UTC)
- Yup, what you see is VisualEditor's own Template insert wizard. TemplateWizard looks quite different, see screenshots here. The TemplateWizard we made only works with WikiEditor and does not work for VE. That's because VE had its own thing. I am not completely sure if/how to disable it (code probably somewhere here) but TemplateWizard won't work on VE, unfortunately. :( NKohli (WMF) (talk) 20:30, 11 December 2018 (UTC)
- Thanks for all your help :) @NKohli (WMF) Hoefsldyla (talk) 20:53, 11 December 2018 (UTC)
Is there any way to use TemplateData alongside "subst" in TemplateWizard?
editWould like to substitute in the source of a Template instead of transcluding it, I am wondering if this is possible while still using TemplateData to be able to easily fill the Template. Hoefsldyla (talk) 01:28, 12 December 2018 (UTC)
- @Hoefsldyla I'm not entirely sure what you are asking for here. Can you explain with an example perhaps? NKohli (WMF) (talk) 15:10, 14 December 2018 (UTC)
- There are templates which need to be written always as
{{subst:myStuff}}
in order to resolve signatures, current date or other things. - Actually this would require also a TemplateData property. PerfektesChaos (talk) 23:05, 23 June 2019 (UTC)
Create New Page
editRESOLVED | |
Unrelated |
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.
How to create new page about movie? Jaimin26783 (talk) 05:43, 20 December 2018 (UTC)
- Hi @Jaimin26783. This is the wrong venue to discuss page creation. You may contact the help desk on the wiki you need help on. NKohli (WMF) (talk) 14:17, 9 January 2019 (UTC)
TW do not follow parameters order in TemplateData
editI've noticed that TW do not follow parameters order set in TemplateData. I've made an example in it:Special:PermaLink/102712468: as you can see, the template added with VE follows the parameter order set in it:Template:RIAA/TemplateData (1→opera→accesso), but the one added using TW follows the order the parameters have been added to the TemplateData (1→accesso→opera). This template has only 4 parameters, so it can be solved quite easily editing the TemplateData like this, but for more "heavy" templates this can generate a wrong wikicode. It:Special:PermaLink/102712468 It:Special:Diff/102712379 Mannivu · ✉ 13:34, 12 February 2019 (UTC)
- @Fringio TW tries to separate required, suggested and optional parameters. Ideally, that is the order in which they should be added to TemplateData. Is that causing the issue you mention? NKohli (WMF) (talk) 19:09, 12 February 2019 (UTC)
- I understand that, and I find very useful that the template list them in the order Required→Suggested→Optional, but I also think that it should follow the instructions about parameter order, since most of templates structure (i.e. the wikicode required for the template) do not follow the Required→Suggested→Optional order, but the order set by TemplateData. Mannivu · ✉ 19:13, 12 February 2019 (UTC)
- When you say "instructions about parameter order", do you mean the order that's specified in TemplateData? NKohli (WMF) (talk) 20:44, 12 February 2019 (UTC)
- Exactly. Mannivu · ✉ 17:46, 13 February 2019 (UTC)
- There might be reasons of logical structure that the TD order is grouping items of same topic. Imagine the description of a person:
- Family name (required)
- Given name (required)
- Middle name (optional)
- Father name, patronyme (optional)
- Suffix, jr., sr. (optional)
- Pseudonym, artist name, clerical name (optional)
- Name at birth or when married (optional)
- Date of birth (required)
- Place of birth (suggested)
- Date of death (suggested)
- Place of death (suggested)
- Business (required)
- If you are sorting this by required→suggested→optional the outcome is quite confusing. PerfektesChaos (talk) 23:00, 23 June 2019 (UTC)
- The point of the TemplateData is to give the software the ability to insert the template wikicode in a fixed order, so I don't understand why TW shouldn't use this order. I'm not saying TW have to follow required→suggested→optional order, but use the order set in the TemplateData. Mannivu · ✉ 10:37, 22 July 2019 (UTC)
Other manual page at German Wikipedia
editHilfe:Vorlagen/Wizard does provide a different approach of instruction.
Might me mentioned if no translation is available.
That is integrated into project infrastructure and refers to particular issues at German Wikipedia. PerfektesChaos (talk) 23:10, 23 June 2019 (UTC)
Select Pages from a specific category
editIs there a way to limit the auto-suggested pages only to those within a nominated category? Like the way page-forms does auto-complete. FrugalTPH (talk) 17:47, 1 October 2019 (UTC)
Embed slides
editCan I embed slides (.ppt or google slides) into a page?
There are instructions online that make it seem like it's possible, but when I search for Google Presentation in templates, no such option appears. I've experimented on my userpage on mediawiki, wikipedia, and wikimedia commons. No Google Presentation template in any of these.
Further, I tried to post the link to the instructions that explain how to embed a google presentation but I received a warning that my post was marked as spam because it contained a link to an outside page. So I must omit the link to the instructions I'm referencing so that I can post this question.
Thanks Dendelele (talk) 01:35, 10 December 2019 (UTC)
Search suggestions aren't offered (on my wiki)
editAt current, it seems I can only search for a template in TemplateWizard if I already know and type in that template's full name (wikitext editor, mw 1.33) For example, if I have a template "Category Link" I can't search for it by entering "Cat" or "Category", no auto-complete, search suggestions or predicted results come up, I type "Category Link" and nothing comes up. I type "Category_Link" and my category link template comes up as it apparently can't recognize spaces as underscores either. My job queue is empty, the template has valid TemplateData with a valid description viewable via the api. A null edit to the template page itself did nothing to help the template data show up per the TemplateData documentation so it is not that:
Help:TemplateData#Limitations and feedback
I see a "search" icon (magifying glass) and "search for a template" text in the field but no searching is possible. I tried rebuildall.php, and rebuildtextindex.php still won't work. There is nothing on the extension documentation page on search feature config... I'm at a loss.
Am I missing something? Is there some maintenance script that needs to be run every time a template with template data is added? There is nothing on the documentation page that suggests how to get new templates with valid template data recognized.
Product Version
MediaWiki 1.33.0 (We are waiting for 1.35 to drop for upgrade)
PHP 7.3.15 (cgi-fcgi)
MySQL 5.7.28-log
ICU 57.1
Template wizard 0.1.0 (096f34e) 20:17, 24 March 2019 TiltedCerebellum (talk) 04:26, 12 July 2020 (UTC)
Editing existing templates
editI've found that editors tend to create pages by copying existing pages or by using a createbox tool combined with pre-loaded templates. As a result while this extension looks ideal for template editing, it will unfortunately not be useable in most cases unless the ability to edit existing templates is included. Is there a plan to implement this? Thanks Garuda3 (talk) 23:02, 11 January 2021 (UTC)
Need Translation in Bengali
editThe page need translation in Bengali language. জয়শ্রীরাম সরকার (talk) 09:19, 24 June 2022 (UTC)
Mandatory TemplateData
edit>Note: Only templates which have TemplateData will have descriptions. You are encouraged to add TemplateData to templates.
> TemplateData must be mandatory to be allowed to save when creating a template. It can be automatically generated in any case. So, the effort is not very intense. If no template data is include when creating the template, the user would be noticed that "TemplateDate is mandatory to create template. It can be automatically add". The user could utilize a "Automatically create" button to automatically create TemplateDate for the new template. BoldLuis (talk) 09:24, 11 August 2022 (UTC)