This is an archive of past discussions. Do not edit the contents of this page. If you wish to start a new discussion or revive an old one, please do so on the current talk page. |
Archive 1 | Archive 2 | Archive 3 |
I made a Lua version that does vertical or horizontal shortcut lists and added some examples to the testcases page. The main difference is it takes any number of shortcut links and doesn't display them unless they're good. If there are no good links then it displays nothing and leaves the cleanup category. Regular shortcut lists would be called like ((#invoke:Shortcut|shortcut|link 1|link 2|link 3))
and horizontal shortcut lists would be called with ((#invoke:Shortcut|hshortcut|link 1|link 2|link 3))
. — Bility (talk) 00:22, 30 April 2013 (UTC)
Shortcut|vertical
, Shortcut|horizontal
, Shortcut|policy
or Shortcut|left
. — Bility (talk) 17:54, 30 April 2013 (UTC)
The ((shortcut))
template without any parameters, as happens when displyaing the template, produces a spurious
</ul>
(on my Wikipedia fork, but not on Wikipedia itself - don't know why). The offending code should be replaced with something as follows (after removing my comments).
--><small>[[Wikimergic:Shortcut|Shortcut((#if:(({2|))}|s))]]: <!-- should be pluralized also when no shortcuts (if allowed) --> ((#if:(({1|))}|<ul><li> [[(({1))}]]</li> ((#if:(({2|))}|<li> [[(({2))}]]</li>)) ((#if:(({3|))}|<li> [[(({3))}]]</li>)) ((#if:(({4|))}|<li> [[(({4))}]]</li>)) ((#if:(({5|))}|<li> [[(({5))}]]</li>)) </ul> <!-- this was spurious when no shortcuts --> | none <!-- likely could be another error --> ))</small></th></tr></table><!--
Thanks. Dpleibovitz (talk) 13:42, 12 June 2013 (UTC)
This edit request to Template:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Please replace the current version with this sandbox version. The content/function change (starting from a duplicate of the current template) is here; the subsequent changes change nothing other than the code's presentation.
The key content/function change is the removal of whitespace accompanying the parameters. This, for example, releases restrictions on parameter formatting in templates that call ((Shortcut)), such as ((Village pump page header)) (see "Third" shortcut output below):
((Village pump page header | Test | This parameter, the second, carries text... ...that can be quite lengthy. |First |Second |Third ))
Policy | Technical | Proposals | Idea lab | WMF | Miscellaneous |
...that can be quite lengthy.
Daily pageviews of Template:Shortcut/Archive 2
A graph should have been displayed here but graphs are temporarily disabled. Until they are enabled again, visit the interactive graph at pageviews.wmcloud.org |
|
Sardanaphalus (talk) 20:19, 4 December 2014 (UTC)
((edit protected))
template. I also object to this pointless change. I have fully read your request, and that article you link 1) doesn't use this template, so I see no connection and 2) looks horrible as there is way too much whitespace on my screens resolutions. — ((U|Technical 13)) (e • t • c) 16:17, 8 December 2014 (UTC)
I'm having a strange problem with ((Shortcut-l)).
I've tried using it on WP:COI, because I've been adding images or quote boxes that take up the right-hand side. But the template is repeating all but the first shortcut. You can see it in this section, where the second shortcut is repeated, and in this one, where it repeats the second and third.
Any suggestions for how to fix this? SarahSV (talk) 05:21, 9 December 2015 (UTC)
The module builds a layout table containing a single cell, a <th>
. This causes an accessibility error, screen readers treat it as a data table (see WP:LTAB). Changing the <th>
to a bolded <td>
, and adding :attr('role', 'presentation')
to the table would be a quick fix. But would a simple floating div instead of a table be more appropriate? Matt Fitzpatrick (talk) 10:16, 12 April 2016 (UTC)
<div>...</div>
. --Redrose64 (talk) 10:55, 12 April 2016 (UTC)How's this?
Matt Fitzpatrick (talk) 08:56, 15 April 2016 (UTC)
No visual changes, give or take a pixel. But I should explain what's changed under the hood.
Matt Fitzpatrick (talk) 04:02, 19 April 2016 (UTC)
Related, just found these.
Policy shortcut uses a table with a single header cell, and I think it should be similarly changed. I'll drop a note on its talk page. Shortcut-l uses a div already and looks mostly fine to me. Matt Fitzpatrick (talk) 04:12, 19 April 2016 (UTC)
<ul>...</ul>
inside <small>...</small>
is because the former is a block-level element ("flow content" in modern terminology) whereas the latter is an inline element ("phrasing content"). The proper thing to do in HTML 4 (or later) is to add a class attribute to the <ul>
tag, and in the style sheet, assign the declaration font-size:smaller;
to that class. --Redrose64 (talk) 19:47, 19 April 2016 (UTC)
class="shortcutbox"
, and I kept that in the div. If the inline styles are acceptable, should I ask an admin to move them into a .shortcutbox
rule in common.css at the same time as making my sandbox edit? Matt Fitzpatrick (talk) 23:47, 26 April 2016 (UTC)
-- [[User:Edokter]] ((talk))
10:04, 27 April 2016 (UTC)This edit request to Module:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Module:Sandbox/Matt_Fitzpatrick/Shortcut to Module:Sandbox Module:Shortcut (diff)
Includes a margin fix from User:Edokter, thanks! This replaces the layout <table> containing a single <th> (which is an accessibility error) with a <div>. It leaves styles inline for now, per Edokter, with TemplateStyles coming soon. See also Template:Shortcut/testcases. Matt Fitzpatrick (talk) 21:10, 29 April 2016 (UTC)
Edited - typo on module link. Matt Fitzpatrick (talk) 21:13, 29 April 2016 (UTC)
-- [[User:Edokter]] ((talk))
21:58, 29 April 2016 (UTC)Redlinked shortcuts currently populate the cleanup category Category:Wikipedia shortcut box first parameter needs fixing. I don't think this behavior is correct, because redlinked shortcuts are just like any other sort of redlink: sometimes the box is on a userspace draft of a policy that'll eventually be promoted; sometimes the box is meant to illustrate a humorous parallel with an actual shortcut. Either way, I don't think redlinks naturally "need fixing". (Pinging Mr. Stradivarius, who wrote the module.) Enterprisey (talk!) (formerly APerson) 03:12, 18 July 2016 (UTC)
|nocat=true
if that is more desirable. — Mr. Stradivarius ♪ talk ♪ 03:31, 18 July 2016 (UTC)
|category=no
. — Mr. Stradivarius ♪ talk ♪ 03:34, 18 July 2016 (UTC)
This edit request to Module:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
At the moment, the error category for an invalid first parameter is added if the first parameter is a valid interwiki link; apparently, mw.title.exists
is false in this case. Therefore:
if not title or not title.exists then
should be changed to
if not title or (not title.exists and title.interwiki == '') then
in order to catch this case.
Enterprisey (talk!) (formerly APerson) 03:45, 20 August 2016 (UTC)
Since I cleared out CAT:SHORTFIX, the category should be deleted and all code that adds pages to it (as far as I know, such code is present in ((Ombox/shortcut)), ((Policy shortcut)), and ((Shortcut-l)), in addition to Module:Shortcut) should be removed. In the original discussion, it was suggested that this happen as soon as the category was cleared out. Pinging Mr. Stradivarius, with whom I had a related discussion last month. Enterprisey (talk!) (formerly APerson) 20:57, 31 August 2016 (UTC)
Since this is placed on the policy in question, the links displayed do not do anything but make your browser reload the page. I thought it'd be nice to send them directly to the page of the redirect, as that adds a little bit of use to an otherwise useless link--it makes it easier to check the history, etc. and see if it'd be alright to reappropriate the shortcut in question. Red Slash 02:48, 10 January 2014 (UTC)
This edit request has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Hi, could someone please change the bluelinks in this to be "redirect=no" links? I did it on Template:Shortcut-l and the text
<small>[[Wikipedia:Shortcut|Shortcut((#if:(({2|))}|s))]]: ((#if:(({1|))}|* ((no redirect|(({1))} ))((#if:(({2|))}| * ((no redirect|(({2))))} ))((#if:(({3|))}| * ((no redirect|(({3))))} ))((#if:(({4|))}| * ((no redirect|(({4))))} ))((#if:(({5|))}| * ((no redirect|(({5))))} ))((#if:(({6|))}| * ((no redirect|(({6))))} ))((#if:(({7|))}| * ((no redirect|(({7))))} ))((#if:(({8|))}| * ((no redirect|(({8))))} ))((#if:(({9|))}| * ((no redirect|(({9))))} ))((#if:(({10|))}| * ((no redirect|(({10))))} ))((#if:(({11|))}| * ((no redirect|(({11))))} ))((#if:(({12|))}| * ((no redirect|(({12))))} )) ))((#if:(({2|))}| * [[(({2))}]] ))((#if:(({3|))}| * [[(({3))}]] ))((#if:(({4|))}| * [[(({4))}]] ))((#if:(({5|))}| * [[(({5))}]] ))</small>
could be inserted in the corresponding part of the template... Or just copy/paste the content from my test case: ((shortcut/sandbox3))
Thanks! Red Slash 04:15, 7 March 2014 (UTC)
This edit request to Module:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Hi, could the links in the template please be "redirect-only" links? There's really no need for the links to even be there if they're just going to lead you back to the page you're already on; redirect-only links let you check out what's linking to those exact shortcuts, etc. Thanks! Red Slash 03:41, 10 April 2015 (UTC)
((edit template-protected))
template. --Redrose64 (talk) 10:29, 10 April 2015 (UTC)
We should modify this template to emit anchors for the shortcut(s), for the part after FOO:
. This would make the shortcut name work in the page in #QUUX
form, which seems to be desirable given the frequency with which people insert ((Anchor|QUUX))
for any given case of ((Shortcut|Wikipedia:QUUX))
, so that [[WP:Barbaz#QUUX]]
works, as frequently expected to.
This would obviate the need to keep adding ((Anchor))
clutter all over the place; people actually edit-war about that stuff at highly-shortcutted pages like WP:NOT. Just get rid of the whole mess. This would need to be done in Lua, to efficiently parse out strings like "WP:", "WT:", "MOS:". — SMcCandlish ☏ ¢ >ʌⱷ҅ᴥⱷʌ< 20:04, 12 November 2017 (UTC)
((#invoke:String|replace|source=MOS:TEST|pattern=.*:|replace=|plain=false))
→ TEST ? Nihlus 20:21, 12 November 2017 (UTC)
Hello. I see some minor problems with the standard shortcut box. It is oversized. Ideally the shortcuts should be as light and unintrusive as possible, but the current box takes much more space than needed. In some pages (Wikipedia:Talk page guidelines, for example) the shortcut boxes conflict with each other and make the page look messy. In some policy banners, the shortcut list is so long that it pushes the banner out of proportion (see WP:OR, for example). These problems have been addressed in ((policy shortcut)) and ((ombox/shortcut)), where the line spacing is shorter, but not in ((shortcut)). Furthermore, the bold font makes the box look heavy; a normal font weight is enough and would make the template look lighter and more unintrusive.
Current | Proposal |
---|---|
The top and bottom margins would be removed as well. This avoids most conflicts between boxes close to each other, and integrates the box better in the body of text. Here you can see a before and after screenshot of how it would look in Wikipedia:Talk page guidelines. This style can be also applied to ((policy shortcut)) and ((ombox/shortcut)), creating a totally unified style across all shortcut templates. In short, the proposal entails 1) reducing the line spacing; 2) changing the font weight from bold to normal; and 3) removing top and bottom margins
Before making a formal request I would like to know, would anyone object to the proposed change? Thank you. Atón (talk) 07:30, 25 September 2017 (UTC)
<table>...</table>
. In fact, it uses a <div>...</div>
- for instance, at Wikipedia:No original research, the HTML that is served is basically as follows: <div class="shortcutbox plainlist noprint" role="note" style="float:right;border:1px solid #aaa;background:#fff;margin:.3em .3em .3em 1em;padding:.4em .6em;text-align:center;font-size:smaller;line-height:2em;font-weight:bold">
<a href="/wiki/Wikipedia:Shortcut" title="Wikipedia:Shortcut">Shortcuts</a>:
<ul>
<li><span class="plainlinks"><a class="external text" href="//en.wikipedia.org/w/index.php?title=Wikipedia:OR&redirect=no">WP:OR</a></span></li>
<li><span class="plainlinks"><a class="external text" href="//en.wikipedia.org/w/index.php?title=Wikipedia:NOR&redirect=no">WP:NOR</a></span></li>
<li><span class="plainlinks"><a class="external text" href="//en.wikipedia.org/w/index.php?title=Wikipedia:ORIGINAL&redirect=no">WP:ORIGINAL</a></span></li>
<li><span class="plainlinks"><a class="external text" href="//en.wikipedia.org/w/index.php?title=Wikipedia:ISAWIT&redirect=no">WP:ISAWIT</a></span></li>
</ul>
</div>
<div>...</div>
was made over a year ago, see Template talk:Shortcut#Div instead of table? above. If the list of shortcuts is too long, remove some; see WP:2SHORTCUTS. --Redrose64 🌹 (talk) 18:27, 25 September 2017 (UTC)
This edit request to Module:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Please reduce the line spacing, margins, padding and font weight per Template talk:Shortcut#Proposal. Changes are the following:
It would be great if the top 'shortcut' link could be underlined. In wikicode I've done it by placing it in a div block as follows: <div style="display: inline-block; border-bottom: 1px solid #aaa; line-height: 1.5em;">[[Wikipedia:Shortcut|Shortcuts]]</div>. But I don't know how to translate that into Lua code. Thank you. Atón (talk) 12:02, 11 October 2017 (UTC)
Edited sandbox. As I explained above, I would also like to request the separation line between the shortcut heading and the shortcut list, but I don't know how to do it with Lua code. I'd appreciate if someone could do that as well, or explain to me how to do it. Thank you. Atón (talk) 19:21, 11 October 2017 (UTC)
Consensus is not unanimity; no single editor has veto power. Readability was the issue; the new proposal has a larger line spacing, wider margins, and conforms to all accessibility guidelines. Would anyone else object? Atón (talk) 07:54, 16 October 2017 (UTC)
This edit request to Module:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Per discussion above, please change:
To format the heading, please replace line 95 with
if shortcutHeading then shortcutList :tag('div') :css('display','inline-block') :css('border-bottom','1px solid #aaa') :css('margin-bottom', '.2em') :css('font-weight', 'normal') :wikitext(shortcutHeading) end shortcutList
To remove the colon ( : ) from the heading, no longer necessary, please delete it from Module:Shortcut/config. Thank you. Atón (talk) 16:37, 17 November 2017 (UTC)
See discussion at Template_talk:Template_shortcut#Proposed_style_adjustment - Evad37 [talk] 01:41, 23 November 2017 (UTC)
I find the new underline ugly especially when accompanied by shortcuts with comparatively long names. I think it needs to be wider:
((Shortcut)) | ((Shortcut/sandbox)) |
---|---|
|
|
|
|
Wouldn't you agree? Nardog (talk) 05:39, 30 November 2017 (UTC)
@Redrose64, Atón, Nihlus, and SMcCandlish: I would like to hear your opinion. Nardog (talk) 22:19, 14 December 2017 (UTC)
I know that this question doesn't have anything to do with the way this template works on this project, but I figured that this is the best place to ask for help. So, I wanted to use this template on Bosnian Wikipedia, so I copied over the module, its configuration and this template that it uses, but the code doesn't seem to generate properly. Take a look at the shortcut box on the right here. This is the code it generates:
<div class="shortcutbox plainlist noprint" role="note" style="float:right;border:1px solid #aaa;background:#fff;margin:0em 0em 0em 1em;padding:.3em .6em .2em .6em;text-align:center;font-size:85%;font-weight:bold"><div style="display:inline-block;border-bottom:1px solid #aaa;margin-bottom:.2em;font-weight:normal"><a href="/wiki/Wikipedia:Pre%C4%8Dica" title="Wikipedia:Prečica">Prečica</a>
</div><ul></ul><li><span class="plainlinks"><a class="external text" href="//bs.wikipedia.org/w/index.php?title=WP:JL&redirect=no">WP:JL</a></span></li></div>
Notice that the <ul>
tag just opens and then immediately closes instead of opening before <span class="plainlinks">
and closing after </li>
, which would get rid of the preceding bullet. Does anyone know how to fix this? – Srdjan m (talk) 09:57, 15 March 2018 (UTC)
<ul>...</ul>
tag is missing altogether. Here's the English version for comparison. Do you mind taking a look? I think it's to do with the Side box module, which was copied from here, so it's probably going to affect this wiki as well when the Remex switch happens. – Srdjan m (talk) 13:37, 21 March 2018 (UTC)
I am thinking to propose that this template be renamed to "linkbox". I think I have noticed over many years that some people think new shortcuts need the use of this shortcut template, whereas this template is less about shortcuts and more about WP:LINKBOXES. --SmokeyJoe (talk) 01:07, 22 June 2018 (UTC)
We should provide and 'inline' option for multiple shortcuts, e.g. instead of
((Shortcut|WP:V|WP:VERIFY))
giving
we would have
((Shortcut|WP:V|WP:VERIFY|WP:FOOBAR|WP:BOTS|WP:BOTNEWS|WP:BOTN|inline=yes|width=20em))
giving something like
Shortcuts
WP:V · WP:VERIFY · WP:BOTS · WP:BOTSNEWS · WP:BOTN · WP:BOTN |
This is obviously an exaggerated example, but something like
Shortcuts
|
would be perfectly reasonable in many cases. @Johnuniq:, something for you? Headbomb {t · c · p · b} 08:14, 26 August 2018 (UTC)
I don't know what causes this, but can this be dealt with? Going to @Johnuniq: since you can LUA. See e.g. the shortcut box at WP:CRAPWATCH. Headbomb {t · c · p · b} 18:10, 16 February 2019 (UTC)
((Shortcut|WP:How to edit a page/HowDoesOneEditaPage))
give Wikipedia: instead of WP: in the fake shortcut on the right. Headbomb {t · c · p · b} 19:21, 16 February 2019 (UTC)Template talk:Shortcut/Archive 2
which converts the shortcut into the full namespace name. Although this should be pretty rare/temporary and it gives a visual indicator of what shortcuts are not actually a redirect.. Galobtter (pingó mió) 19:32, 16 February 2019 (UTC)
((No redirect))
(lines 39–42 of Module:Shortcut) just needs to provide a second parameter that is also the shortcut. That way, instead of expanding((No redirect|WP:How to edit a page/HowDoesOneEditaPage))
→ Wikipedia:How to edit a page/HowDoesOneEditaPage((No redirect|WP:How to edit a page/HowDoesOneEditaPage|WP:How to edit a page/HowDoesOneEditaPage))
→ WP:How to edit a page/HowDoesOneEditaPage((No redirect|WP:5P|WP:5P))
→ WP:5Pargs
to read args = {shortcut, shortcut}
. I just previewed that and it gives "WP:" in the sample shortcut above, although I haven't thought about any implications. Just try it, I guess. Johnuniq (talk) 03:01, 17 February 2019 (UTC)On my Android-based mobile phone using the Wikipedia app to view Portal:Mathematics, I am seeing 20 copies of the bare wikicode ((#if:(({1|))}|((#tag:span||id="(({1|))}"))))
just before the "P:MAT" shortcut link. These are obviously coming from Template:Shortcut-l, which is called by Portal:Mathematics/Intro. I don't see anything wrong when looking at the portal page in mobile view on my desktop machine, nor when I look at it on my phone through a regular browser window (Google Chrome); it's only a problem when using the Wikipedia app for Android. Does anyone know why the app is not rendering the template correctly? (Figured I'd ask here, since people here are familiar with this particular template, before I try a more general forum.) I'm guessing the error was introduced in this edit by User:Hddty., but I don't know any details about how that added code works. - dcljr (talk) 19:53, 11 February 2019 (UTC)
I'm pretty sure that when I added ((Shortcut|w.wiki/QP))
to my user page, two days ago, it displayed without a link; that's what currently displays for the equivalent on my Wikidata user page. However, It now displays with a red link, as above. I can see no recent edits to the template or main module, so what (if anything) has changed?
In any case, can we change (fix) this template so we can use it with the WMF short URL service? Andy Mabbett (Pigsonthewing); Talk to Andy; Andy's edits 12:09, 13 April 2019 (UTC)
((Shortcut|w.wiki/QP))
has rendered without a link at the English Wikipedia for a long time, if ever. Both Template:Shortcut and wikidata:Template:Shortcut are only meant for redirects which are pages in the wiki and work when they are entered in the search box or written as a wikilink like WP:V. Your use of these templates is wrong. Wikis have different templates and the version on wikidata:User:Pigsonthewing does not make a link but it causes confusion in readers who know what the term "shortcut" means in Wikidata. As far as I know, neither the English Wikipedia nor Wikidata has a template intended to display a box with the short url produced by meta:Special:UrlShortener. I oppose adding it as a feature to Template:Shortcut. It will cause confusion if there is a parameter telling which of two different features the template should use, and there may be opposition to display a short url on any page outside userspace. We do have ((Short URL)) but it has few uses. PrimeHunter (talk) 19:22, 1 May 2019 (UTC)
Right now, this template seems to be outputting a <div class="module-shortcutanchordiv"></div>
with spans inside which take the anchors generated by the template. This causes bad behavior in IE/Edge when the shortcut template is embedded inside an li. See Wikipedia:Manual of Style/Linking#General points on linking style for an example in that browser. (It does not cause an issue in either Firefox or Chrome.)
Locally on my machine in Edge, setting the div to display none, float right, or moving the div inside the normally-displayed box makes the issue go away. I haven't tested any of those solutions on other browsers, nor have I tested what the result would be of being taken to the anchor since-generated after making that change.
Is there any preferred solution here? --Izno (talk) 23:27, 11 August 2019 (UTC)
<div>...</div>
that Edge doesn't like? I see that before the outer div there is a <link rel="mw-deduplicated-inline-style" href="mw-data:TemplateStyles:r886047113" />
element, which I thought was something to be used in the head, not the body. --Redrose64 🌹 (talk) 21:52, 12 August 2019 (UTC)
The vertical list of items inside the box should be more compact (there's unnecessary vertical margins between them). Please add this to the styles (this was tested by editing the CSS generated inside the "DOM Elements" view of browsers, while the page was loaded):
/*.mw-parser-output*/ .module-shortcutboxplain.plainlist ul li {
margin: 0;
text-align: left;
}
This removes the vertical margins (currently there's one at the top of each item) and keeps items left-aligned (without any additional horizontal indentation margin), both are implied by default in the "li" elements.
I see no reason for separating them, even if there's a "msg" item (there's a single one, only at bottom of the list of shortcuts; sometimes this is the only item listed, which may also span several paragraphs adding their own margins!).
Thanks. verdy_p (talk) 02:49, 13 June 2019 (UTC)
It'd be very nice to have a parameter for creating horizontal lists for use in rare circumstances, such as here. Would that be possible to create? ((u|Sdkb)) talk 21:41, 7 April 2020 (UTC)
The ((Shortcut)) template is intended to create anchors using the shortcut name. See Template:Shortcut#Anchors.
((Shortcut|WP:RFCEND|WP:RFCCLOSE))
which creates a div of the form:<div class="module-shortcutanchordiv">
<span id="WP:RFCEND"></span>
<span id="WP:RFCCLOSE"></span>
</div>
The #82 entity is an error that prevents references such as Wikipedia:Requests for comment#RFCCLOSE.
&
to render as wanted. There is significant confusion here and I'm not sure what Redrose64 is testing. The redirect at WP:RFCCLOSE works but that's not what the report is about. The claim is that Wikipedia:Requests for comment#RFCCLOSE doesn't work. But it's not supposed to work. It is Wikipedia:Requests for comment#WP:RFCCLOSE which is supposed to work. It doesn't actually work for me in Firefox. It's claimed that it produces<span id="WP:RFCCLOSE"></span>
<span id="WP:&#82;FCCLOSE"></span>
R
is first encoded as R
but then the whole thing is apparently encoded a second time where &
is encoded as &
, so we end up with the wrong WP:&#82;FCCLOSE
. I don't know Lua but the problem may be in this in Module:Shortcut: local anchor = mw.uri.anchorEncode(shortcut)
anchorDiv:tag('span'):attr('id', anchor)
((anchorencode:))
encodes the first character in RFC, PMID or ISBN, maybe to avoid a potential clash with the magic link feature. For example, ((anchorencode:RFC))
produces RFC
. This seems a bit odd but it would work so far. The problem is a second encoding by Module:Shortcut. I wrote <span id="RFC"></span>
here: . This produces a working anchor for Template talk:Shortcut#RFC. But the anchor breaks after a second encoding. I wrote <span id="&#82;FC2"></span>
here: . Template talk:Shortcut#RFC2 does not work. PrimeHunter (talk) 21:44, 15 May 2020 (UTC)attr('id', anchor)
does. The example Wikipedia:Requests for comment#WP:RFCCLOSE would work if local anchor = mw.uri.anchorEncode(shortcut)
was simply changed to local anchor = shortcut
. But maybe it would break in other cases, or in the future if something changes. PrimeHunter (talk) 10:04, 16 May 2020 (UTC)Pppery I see you added some code for the heading parameter. What's the status on that? ‑‑Trialpears (talk) 20:15, 16 June 2020 (UTC)
WP:RM contains a section that is identified with ((Shortcut|WP:RM#TR)), which generates a navigation shortcut box on the right side of the page. When I click on the link in that nav box, it does not lead me to that section of WP:RM. Instead of linking to WP:RM#TR, which generates a reference to https://en.wikipedia.org/wiki/Wikipedia:RM#TR, it seems to generate a link to https://en.wikipedia.org/w/index.php?title=Wikipedia:RM&redirect=no#TR, which suppresses the redirection and does not lead to the intended destination. Once it takes me to the redirect, if I click again, the section link is missing, so I am just sent to the top of the redirect target's page instead of to the desired section. I think I have seen this happening on other pages as well – perhaps whenever a shortcut to a section leads through a redirect. What is happening? Can it be fixed? —BarrelProof (talk) 13:19, 2 September 2020 (UTC)
&redirect=0
). – Uanfala (talk) 18:18, 2 September 2020 (UTC)
Would be cool if there were |small=yes
that would make this take up less vertical space. Sometimes we need to shortcut a one-liner in a policypage, and if it's immediately followed by a new section, that kind of looks crappy. It could use a slightly smaller font, not have the horizontal line it it, and use less top and bottom padding, maybe even lose the "Shortcuts" text (since it would be apt to be used in proximity to other shortcut boxes). Such a variant might be handy for embedding inside other things (though of course there is already the ombox version). — SMcCandlish ☏ ¢ 😼 07:25, 29 November 2020 (UTC)
This edit request to Template:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Template:Shortcut has been listed at Templates for discussion (nomination), but was protected so could not be tagged. Please add:
((subst:tfm|help=off|type=sidebar|1=Template shortcut))
to the top of the page to complete the nomination. Thank you. JsfasdF252 (talk) 21:19, 1 February 2021 (UTC)
This edit request to Template:Shortcut has been answered. Set the |answered= or |ans= parameter to no to reactivate your request. |
Change
|link=Wikipedia:Templates for discussion/Log/2021 February 2#Template:Shortcut
to
|link=Wikipedia:Templates for discussion/Log/2021 February 1#Template:Shortcut
. --- C&C (Coffeeandcrumbs) 05:22, 2 February 2021 (UTC)