Template:Lang-sh-Latn-Cyrl is permanently protected from editing because it is a heavily used or highly visible template. Substantial changes should first be proposed and discussed here on this page. If the proposal is uncontroversial or has been discussed and is supported by consensus, editors may use {{edit template-protected}} to notify an administrator or template editor to make the requested edit. This template does not have a documentation subpage. You can create the documentation subpage here. If the template page contains categories or usage notes, move these to the documentation subpage. If the template does not require documentation, add |doc=no to this template ({{permanently protected}}).
Any contributor may edit the template's sandbox. Functionality of the template can be checked using test cases.
Lang-sh-Latn-Cyrl is part of the WikiProject Bosnia and Herzegovina, a collaborative effort to improve the coverage of articles related to Bosnia and Herzegovina on Wikipedia. If you would like to participate, please visit the project page, where you can join the project and see a list of open tasks.Bosnia and HerzegovinaWikipedia:WikiProject Bosnia and HerzegovinaTemplate:WikiProject Bosnia and HerzegovinaBosnia and Herzegovina articles
This template is within the scope of WikiProject Croatia, a collaborative effort to improve the coverage of Croatia on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.CroatiaWikipedia:WikiProject CroatiaTemplate:WikiProject CroatiaCroatia articles
This template is within the scope of WikiProject Montenegro, a collaborative effort to improve the coverage of Montenegro on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.MontenegroWikipedia:WikiProject MontenegroTemplate:WikiProject MontenegroMontenegro articles
This template is within the scope of WikiProject Serbia, a collaborative effort to improve the coverage of Serbia on Wikipedia. If you would like to participate, please visit the project page, where you can join the discussion and see a list of open tasks.SerbiaWikipedia:WikiProject SerbiaTemplate:WikiProject SerbiaSerbia articles
Template:Lang-sh-Latn-Cyrl is within the scope of WikiProject Yugoslavia, a collaborative effort to improve the Wikipedia coverage of articles related to Yugoslavia and its nations. If you would like to participate, please visit the project page, where you can join the project and see a list of open tasks.YugoslaviaWikipedia:WikiProject YugoslaviaTemplate:WikiProject YugoslaviaYugoslavia articles
The documentation for this template should not be a clone of the {{lang-x2}} template. For the uninitiated editor, seeing the {{lang-x2}} documentation when the editor is looking at the {{Lang-sh-Latn-Cyrl}} template doc is bound to cause unnecessary confusion. This template's documentation should document this template using its parameters and describing its functionality and its error messaging. Note that the error messaging for this template is a bit different from the error messaging emitted by {{lang-sh-Cyrl-Latn}}; see the error tests at Template:Lang-sh-Latn-Cyrl/testcases and Template:Lang-sh-Cyrl-Latn/testcases.
Aha, so we shouldn't transclude that /doc but instead link it for reference? Easy enough to do, it's just that it's different from the base use case so I defaulted to that. --Joy [shallot] (talk) 19:08, 22 October 2022 (UTC)[reply]
Yes and no. Yes, this template should link to {{lang-x2}} because this template is a wrapper template around {{lang-x2}}. But, no, because this template's documentation, as it stands at this writing, does not document this template using its parameters and describing its functionality and its error messaging. For example, an editor writes this, which causes an error message:
{{lang-sh-Latn-Cyrl|Савез комуниста Југославије (CKJ)|Savez komunista Jugoslavije (SKJ)}}
Error: {{lang-sh-Cyrl-Latn}}: <text2> is not Latin script (help)
So, the editor clicks on the help link and ends up at the top of that template's documentation. But where is the help? The is some at {{lang-x2}} but that documentation says nothing about what has gone wrong with the broken {{lang-sh-Cyrl-Latn}} template because {{lang-sh-Cyrl-Latn}} uses a subset of the {{lang-x2}} template's available parameters. The above error message is specific to {{lang-sh-Cyrl-Latn}}, and is wholly wrong for {{lang-x2}}.
This template, and the others that I mentioned require proper documentation. Certainly you can edit a copy of the {{lang-x2}} documentation, but the original clone and the current documentation is not adequate.
And despite my oftimes claims to the contrary, there are editors out there who do actually read template documentation.
If this edit is all that you intended to do as far as documentation, that is wholly inadequate. The documentation does not document these templates using their parameters and describing their functionality and their error messaging. I suggested how you might create adequate documentation: you can edit a copy of the {{lang-x2}} documentation. You should do that. As the creator of these templates, it is incumbent upon you to provide documentation for future editors who aren't privy to the inner workings of your templates. Please do the right thing for them.
Why would we duplicate the entire documentation, and fork the effort in maintaining it? I don't see the point of this, we should point people to click the fine link without needing to read the source, but wholesale duplication seems utterly pointless to me. Let's see if we can find a user who is actually sufficiently confused by this phrasing and needs more help before we assume that they exist... One thing that does stand out as needing to be fixed is the fact that these highly visible templates are protection material, so they should have documentation split off into a subpage that can be edited by anyone. --Joy [shallot] (talk) 16:45, 23 October 2022 (UTC)[reply]
This and the other two-script templates do not support:
{{{4}}} for translation text as {{lang-x2}} does; the two-script templates use {{{3}}} for the translation text
|swap=; {{lang-x2}} does
|size=; {{lang-x2}} does
The {{lang-xx-Latn-Cyrl}} templates require {{{1}}} to use Latn script and {{{2}}} to use Cyrl script. The {{lang-xx-Cyrl-Latn}} templates require {{{1}}} to use the Cyrl script and {{{2}}} to use Latn script. That is not (and should not be) explained at {{lang-x2}}.
The documentation at Template:Lang-x2/doc is for {{lang-x2}} and explains the workings and purpose of that template; some of it applies to these templates without modification; some of it does not.
Editor confusion due to inadequate documentation is not something that I am making up; it is a real thing even when a template has the best of documentation. There is no need to find a user who is actually sufficiently confused. We write template documentation for the avoidance of confusion.
Appropriately constructed, a single doc page will support all four of the two-script templates so no forking and no duplication.
Yes, a separate doc page is desirable.
we should point people to click the fine link I don't know what you mean by fine link.
I thought you had criticized my earlier docs as too much of a intricate pseudo code to be readable by laymen, but most of what you described is like that in turn :) Like, of course you can't pass the first parameter into any of these four templates as language code. That is precluded by the fact that their documentation says that they mark text as a specific language, hence, it's not supporting use cases beyond that. If we start spelling out these kinds of basic things with even more verbiage, we run the risk of folks just saying "TLDR!" Anyway, I don't think it's useful to further argue about this on a theoretical basis, let's just spend the time and effort working on improving these docs through normal editorial process. --Joy [shallot] (talk) 17:39, 23 October 2022 (UTC)[reply]
What? Where did you get that idea? My criticism was about the blind cloning of the {{lang-x2}} documentation into {{lang-sh-Latn-Cyrl}} and {{lang-sh-Cyrl-Latn}}. I don't think that I have mentioned intricate pseudo code anywhere in this discussion. If I have, show me where.
Nice, thanks. I appreciate that a fair amount of effort went into creating the abstraction, and for just 4 use cases to date :) Now, I did notice that the more specific categories are gone. Is it safe to copy the category parameter implementation from the bottom of Template:Lang-x/doc? I'm also not sure if we need a separate category from Category:Lang-x templates. --Joy [shallot] (talk) 07:48, 24 October 2022 (UTC)[reply]
Template-specific categories can be, as they already are, in {{lang-xx-two-script documentation}}. Given that {{lang-xx-two-script documentation}} is used on four templates, without good reason (persistent vandalism or what-have-you), {{lang-xx-two-script documentation}} is not likely to be protected. There is no need for these extra, unused, ~/doc pages.
That's the problem I'm telling you - they're not the same for all cases necessarily. The Serbo-Croatian ones might be in one set of categories, the Serbian ones in another. The applications do not necessarily overlap 100%. If you want to distinguish those cases within the same page, that sounds like more complicated syntax that few will understand... --Joy [shallot] (talk) 15:30, 24 October 2022 (UTC)[reply]
Did you look? Edit {{lang-xx-two-script documentation}} and scroll to the bottom. The specific categories from this version of Template:Lang-sh-Cyrl-Latn/doc and this version of Template:Lang-sh-Latn-Cyrl/doc are the same. The specific categories from this version of Template:Lang-sr-Latn-Cyrl/doc and this version of Template:Lang-sr-Cyrl-Latn/doc are the same. In {{lang-xx-two-script documentation}}, these two sets of categories are segregated so that the Serbo-Croatian categories apply to the Serbo-Croatian templates and the Serbian categories apply to the Serbian templates.
Look at the listed categories there. Are they correct?
There is hidden text in {{lang-xx-two-script documentation}} that identifies the two separate language category areas. Anyone wanting to add a new category should be able to place the new category into the proper section without difficulty.
There is no need for these extra, unused, ~/doc pages.
Oh, I see now, you made that change shortly before posting "Template-specific categories can be, as they already are, in {{lang-xx-two-script documentation}}", so that phrase didn't convey to me "I just made it happen" but merely that you were talking about some already existing, common set of categories. --Joy [shallot] (talk) 16:48, 24 October 2022 (UTC)[reply]
From personal usage and reading, more articles seem to opt for a slash / instead of a comma , to separate Latin and Cyrillic in case of Serbo-Croatian. Sometimes it's because a comma is much more likely to be part of the actual text inside lang tags, but the vast majority of articles I've seen to date favor a slash (probably out of preference). An argument in favor of a comma could be the fact it resembles other dual-script lang templates, just without saying "romanized" after it. Not proposing either, just seeking opinions on the default separator. -Vipz (talk) 23:05, 29 October 2022 (UTC)[reply]
I did a lot of the conversion so far and didn't change the separator because I didn't want to mix 2 separate migrations. However, a lot of this usage was additions of slash unformatted Cyrillic text, so I don't think it's really a truly informed stylistic choice. We could just as well just choose to remove them. I don't think we convey anything truly informative to a typical English reader by changing the default separator, and in lists of multiple foreign languages this makes it stand out for no reason. --Joy [shallot] (talk) 10:34, 30 October 2022 (UTC)[reply]
@Pppery I keep going through invocations of {{lang-sh}} and {{lang-sr}} and converting, because there's a lot of them out there, so I just copied the protection level. Since there's 4 variants for each and sh and sr, the total number will be divided among them and go relatively low per template, but the reason why I felt it was automatically appropriate is because the most common usage pattern is in the lead sections of articles. --Joy [shallot] (talk) 17:31, 25 December 2022 (UTC)[reply]