![]() | 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 15 | ← | Archive 17 | Archive 18 | Archive 19 |
Recently, I've been looking into how well our articles are accessible by screen-reader software such as Voiceover on a mac (command-F5), and for infoboxes it's a little wonky. If you've never used screen-reader software, the idea is that since users can't visually scan to jump to a type of content, the software will list out the elements of a given type that are present, such as tables or links. The Infobox, being a table, is the first one of that type to be listed - but the listing is generally useless and unhelpful.
The docs for Infobox say that "title" and "above" are roughly equivalent, though it notes that "the most recommended alternative" is title. And so, for articles with infobox types that do that, like Lego (Infobox toy), the screen reader software tells you that the first table in the page is named... "Lego". No context for what that means. Many infobox types, however, don't use title- so for those, like Final Fantasy X (Infobox video game), you get... nothing. You just get told that the first table has "2 columns, 16 rows", with absolutely zero context whatsoever.
So, we could of course find the variants that don't use title and fix that, but honestly a table named "Lego" on an article named "Lego" tells me nothing about what's in it, so if I didn't know that it was an infobox with details about the subject I wouldn't be able to tell. So neither is great. The solution, it seems to me, is to add caption text in both cases that specifies what it is- so "Lego summary details" if there is a title, and just "Summary details" if there isn't. Obviously we wouldn't want to display that added text to non-screen-readers, but we have that solved already with e.g. {{
Screen reader-only}} - the "sr-only"
css class from {{
Screen reader-only/styles.css}} lets text be read by screen-reader software without adding visual clutter to visual browsers.
The changes needed would be adding the css class and updating local function renderTitle() (line 165) to a) always have a caption element) and b) append <span class="sronly"> summary details</span>
inside of that caption. I wanted to get consensus for this, however, before I went mucking with the sandbox. Thoughts? --
Pres
N
15:51, 17 October 2022 (UTC)
<div>
from <table>
(because it's not really an HTML table). That's maybe a year or two away. It's currently blocked on getting
infobox over to TemplateStyles.aria-label
which I think we could just set to aria-label="info box"
(I'd prefer to ke. Well, at least as
specced by the W3C;
MDN looks a bit opinionated about the expectation that the element you're giving a label to should be interactive.|title=
/|above=
, but the problem is that those two places can contain other HTML, so then we're looking ripping out that other HTML while parsing (not fun). aria-labelledby
could be used for that case but it would require the introduction of IDs to the infobox elements for title/above, and I can't guarantee unique IDs on a page today (i.e. pages can contain multiple infoboxes).
phab:T200517 would help with that. We could also take the ID from the |name=
for infoboxes with a name (which also adds {{
navbar}}) and a potential |aria-label=
for infoboxes without, which would probably get us most of the way there. But all of those are probably optimmizations on the more general "name the box for screen readers" for which "info box" or some variant probably is Good Enough?
Izno (
talk)
18:16, 17 October 2022 (UTC)
|above=
or one of the other not-caption elements at the top of the infobox).
Izno (
talk)
01:03, 17 December 2022 (UTC)display: block
for <table>
pretty badly, which is what is needed at the uber small res (and which is what mobile does today), and even displaying browsers cough and hack on the difference in display modes (random scrollbars, things extending outside the content width, etc. etc.). I've put some musings together at
user:Izno/Sandbox/Infobox. As you can see there, there's a version of it which is based on definition lists (though IDK if that use is precisely kosher), but there could be a form of infobox which is a series of lists (first of headers and then a list for each header), but that form has issues with integration with CSS grid, which is probably the display technology of interest here (notably that we don't have subgrids widely available yet). It's not an any time soon thing though with TemplateStyles still to go, among the other TableAsPresentationThings we have that would probably make the world better to definitely fix at some point. I know of another wiki that pretty early on (like a decade and a half ago) realized that infoboxes are just unordered lists of info and has marked them up as such also; most others copy-paste us or use wikitext tables.<div>
based rather than table based. Besides Google (and a few other search engines), there aren't really any other web properties doing infoboxes in a sense like ours (or at least the world of MediaWiki), where most other wikis just copy what we do.
Izno (
talk)
00:27, 17 December 2022 (UTC)A few years ago,
Frietjes added tracking for ignored data cells (see
this thread). I just fixed about a dozen of these today. Does anyone object to allowing both |header1=
and |data1=
with the header appearing over the data similar to {{
sidebar}}. I think this would eliminate a lot of confusion. Thanks!
Plastikspork
―Œ(talk)
13:38, 25 April 2023 (UTC)
|datan=
will show, right below |headern=
. Is this sound semantically?
DePiep (
talk)
07:40, 26 April 2023 (UTC)
|autoheaders=true
added:
§ Eccentric styles autoheaders. /sandbox: as expected ("no data -> no header"). Don't know what /sandbox2 is testing. -
DePiep (
talk)
07:55, 26 April 2023 (UTC)
Can someone provide an example of how to populate an infobox from Wikidata?
For example, the Wikipedia article on w:American Civil Liberties Union includes a segment of code that begins "{{Infobox organization". My fantasy is that "{{Infobox Q21637}}" would be enough (because Wikidata:Q21637 is the Q ID for the American Civil Liberties Union). Then if a user wanted to include some information but not others, there would be fairly simple ways to specify information that a person wanted (a) in the article but not in Wikidata and (b) in Wikidata but not in the article.
Does documentation of how to do this exist somewhere? If yes, how can I find it? If no, can someone provide the needed documentation? Thanks, DavidMCEddy ( talk) 19:39, 1 June 2023 (UTC)
<ref>...</ref>
tags.Thanks. I was able to get something.
Now I have another problem: What can I do to get Wikidata: total revenue (P2139) to sort in date sequence in Pregnancy Justice (Q30288051)? When I use it in Wikipedia, the last "Revenue" entered is displayed. I think the most recent should be displayed, but that's not what I'm getting. ?? Thanks again. DavidMCEddy ( talk) 13:48, 2 June 2023 (UTC)
Your input is desired at a new Request for Comment at Template talk:Infobox company#Align the infobox?. ɱ (talk) 14:10, 19 July 2023 (UTC)
Greetings. MOS:COLLAPSE says: "A few infoboxes also use pre-collapsed sections for infrequently accessed details." Could any one help me find those cases, please? fgnievinski ( talk) 19:48, 8 August 2023 (UTC)
{{
Infobox Belgium municipality}}
, {{
Infobox Bible translation}}
, {{
Infobox Greece place}}
, {{
Infobox number system}}
, {{
Infobox OS}}
, {{
Infobox pharaoh}}
, {{
Infobox U.S. federal court}}
, {{
Infobox website}}
. This list is not exhaustive. --
Redrose64 🌹 (
talk)
21:12, 8 August 2023 (UTC)
{{
infobox journal}}
, please? It'd be valuable for an ongoing discussion (
Wikipedia talk:Notability (academic journals)#RfC on notability criteria). I've sandboxed it at
Template:Infobox journal/sandbox2 but the tests at
Template:Infobox_journal/testcases2 didn't seem to hide anything. It'd be used in
Draft:List_of_American_Medical_Association_journals. Thanks!
fgnievinski (
talk)
04:43, 9 August 2023 (UTC)
{{
hidden}}
to make any difference.
fgnievinski (
talk)
23:31, 9 August 2023 (UTC){{
Collapsed infobox section begin}}
instad of plain {{
hidden begin}}
!
fgnievinski (
talk)
23:31, 9 August 2023 (UTC)Hello colleagues! I tried to localize the Module:Infobox into the Kazakh Wikipedia. It seems like everything worked out, but some rows like headers are not aligned in the center, I can’t understand where the problem is, everything seems to be the same as in the English version. kk:Module:Ақпар қорабы for example u can see this template kk:Үлгі:Музыкалық топ, and article kk:Ұлытау тобы -- Amangeldi Mukhamejan ( talk) 13:14, 26 September 2023 (UTC)
I'd like clarification if small text is discouraged in all cases. These two on my watchlist are now making use of small text: [1] [2]. Leave as they are or should I revert? Mac Dreamstate ( talk) 19:12, 26 September 2023 (UTC)
|label12=
or |data9=
contained small tags or templates, and whether it would be worth trying. –
Jonesey95 (
talk)
20:37, 26 September 2023 (UTC)
I've stumbled upon a buggy interaction of
Template:Infobox ethnic group with
Template:Plainlist in article
Ainu people. There, the list after "Religion" has the list markers, despite being generated using template {{
plainlist}}. In the generated HTML, somehow the tags <ul>...</ul>
are missing. Only the outer wrapper <div class="plainlist">...</div>
and list items (<li>...</li>
) are present in the HTML. This makes it so that CSS code list-style: none
from
Template:Plainlist/styles.css#L-5 isn't triggered, because the CSS selector for the rule is .plainlist ol, .plainlist ul
.
I have reduced the reproducing sample to two test cases at
Template:Infobox/testcases#Template:Plainlist. Feel free to rename and/or move it as you see fit. This only happens when there is a list in |label(n)=
and
Template:Plainlist is in the next |data(n+1)=
(or in |data(n+2)=
if there is a |header(n+1)=
). Compare label1 with a list
vs label1 without a list
. —
andrybak (
talk)
21:49, 10 October 2023 (UTC)
label
misses the point of what a label is.fixChildBoxes
in some way. Either it's not covering some remixing, or it's not doing it in the right place, or it's not being called on such and sundry inputs.
Izno (
talk)
18:17, 11 October 2023 (UTC)
<div>
seems to fix it
here?
Frietjes (
talk)
00:11, 12 October 2023 (UTC)I would like to use the infobox template to create a new particular infobox template (an ancient polis infobox template) and employ it in multiple articles for the Ancient Greek Wikipedia.
I've tried to do so; however, I encountered problems, because (apparently) the existent module could only be used in the English Wikipedia. Thus, I re-created (i.e., copy-pasted) the module in the Ancient Greek Wikipedia Incubator. Here is the copy-pasted module: https://incubator.wikimedia.org/wiki/Module:Wp/grc/Infobox
I also had to re-create many modules and templates, necessary to make the infobox template work, in particular this, since I got an error message: https://incubator.wikimedia.org/wiki/Module:Wp/grc/Infobox/styles.css
Here is the "ancient polis" infobox template, the new template I created based on the infobox module: https://incubator.wikimedia.org/wiki/Template:Wp/grc/Πινάκιον_Ἀρχαία_Πόλις
Here is an article in which I use the new template: https://incubator.wikimedia.org/wiki/Wp/grc/Ἀγύριον_(ἀρχαία_πόλις)
As you can see:
1) The style is not right (the infobox should look more or less like this: /info/en/?search=Megara );
2) Furthermore, I'm unable do add images;
3) Lastly, I'm unable to add an interactive map.
Could someone kindly help?
Thank you very much!
- Anaxicrates ( talk) 14:55, 11 November 2023 (UTC)
-
(the
hyphen), that is only wikitext when it is preceded by |
and both appear at the beginning of the line. A similar comment about asking there.
Izno (
talk)
18:36, 12 November 2023 (UTC)
![]() | 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 15 | ← | Archive 17 | Archive 18 | Archive 19 |
Recently, I've been looking into how well our articles are accessible by screen-reader software such as Voiceover on a mac (command-F5), and for infoboxes it's a little wonky. If you've never used screen-reader software, the idea is that since users can't visually scan to jump to a type of content, the software will list out the elements of a given type that are present, such as tables or links. The Infobox, being a table, is the first one of that type to be listed - but the listing is generally useless and unhelpful.
The docs for Infobox say that "title" and "above" are roughly equivalent, though it notes that "the most recommended alternative" is title. And so, for articles with infobox types that do that, like Lego (Infobox toy), the screen reader software tells you that the first table in the page is named... "Lego". No context for what that means. Many infobox types, however, don't use title- so for those, like Final Fantasy X (Infobox video game), you get... nothing. You just get told that the first table has "2 columns, 16 rows", with absolutely zero context whatsoever.
So, we could of course find the variants that don't use title and fix that, but honestly a table named "Lego" on an article named "Lego" tells me nothing about what's in it, so if I didn't know that it was an infobox with details about the subject I wouldn't be able to tell. So neither is great. The solution, it seems to me, is to add caption text in both cases that specifies what it is- so "Lego summary details" if there is a title, and just "Summary details" if there isn't. Obviously we wouldn't want to display that added text to non-screen-readers, but we have that solved already with e.g. {{
Screen reader-only}} - the "sr-only"
css class from {{
Screen reader-only/styles.css}} lets text be read by screen-reader software without adding visual clutter to visual browsers.
The changes needed would be adding the css class and updating local function renderTitle() (line 165) to a) always have a caption element) and b) append <span class="sronly"> summary details</span>
inside of that caption. I wanted to get consensus for this, however, before I went mucking with the sandbox. Thoughts? --
Pres
N
15:51, 17 October 2022 (UTC)
<div>
from <table>
(because it's not really an HTML table). That's maybe a year or two away. It's currently blocked on getting
infobox over to TemplateStyles.aria-label
which I think we could just set to aria-label="info box"
(I'd prefer to ke. Well, at least as
specced by the W3C;
MDN looks a bit opinionated about the expectation that the element you're giving a label to should be interactive.|title=
/|above=
, but the problem is that those two places can contain other HTML, so then we're looking ripping out that other HTML while parsing (not fun). aria-labelledby
could be used for that case but it would require the introduction of IDs to the infobox elements for title/above, and I can't guarantee unique IDs on a page today (i.e. pages can contain multiple infoboxes).
phab:T200517 would help with that. We could also take the ID from the |name=
for infoboxes with a name (which also adds {{
navbar}}) and a potential |aria-label=
for infoboxes without, which would probably get us most of the way there. But all of those are probably optimmizations on the more general "name the box for screen readers" for which "info box" or some variant probably is Good Enough?
Izno (
talk)
18:16, 17 October 2022 (UTC)
|above=
or one of the other not-caption elements at the top of the infobox).
Izno (
talk)
01:03, 17 December 2022 (UTC)display: block
for <table>
pretty badly, which is what is needed at the uber small res (and which is what mobile does today), and even displaying browsers cough and hack on the difference in display modes (random scrollbars, things extending outside the content width, etc. etc.). I've put some musings together at
user:Izno/Sandbox/Infobox. As you can see there, there's a version of it which is based on definition lists (though IDK if that use is precisely kosher), but there could be a form of infobox which is a series of lists (first of headers and then a list for each header), but that form has issues with integration with CSS grid, which is probably the display technology of interest here (notably that we don't have subgrids widely available yet). It's not an any time soon thing though with TemplateStyles still to go, among the other TableAsPresentationThings we have that would probably make the world better to definitely fix at some point. I know of another wiki that pretty early on (like a decade and a half ago) realized that infoboxes are just unordered lists of info and has marked them up as such also; most others copy-paste us or use wikitext tables.<div>
based rather than table based. Besides Google (and a few other search engines), there aren't really any other web properties doing infoboxes in a sense like ours (or at least the world of MediaWiki), where most other wikis just copy what we do.
Izno (
talk)
00:27, 17 December 2022 (UTC)A few years ago,
Frietjes added tracking for ignored data cells (see
this thread). I just fixed about a dozen of these today. Does anyone object to allowing both |header1=
and |data1=
with the header appearing over the data similar to {{
sidebar}}. I think this would eliminate a lot of confusion. Thanks!
Plastikspork
―Œ(talk)
13:38, 25 April 2023 (UTC)
|datan=
will show, right below |headern=
. Is this sound semantically?
DePiep (
talk)
07:40, 26 April 2023 (UTC)
|autoheaders=true
added:
§ Eccentric styles autoheaders. /sandbox: as expected ("no data -> no header"). Don't know what /sandbox2 is testing. -
DePiep (
talk)
07:55, 26 April 2023 (UTC)
Can someone provide an example of how to populate an infobox from Wikidata?
For example, the Wikipedia article on w:American Civil Liberties Union includes a segment of code that begins "{{Infobox organization". My fantasy is that "{{Infobox Q21637}}" would be enough (because Wikidata:Q21637 is the Q ID for the American Civil Liberties Union). Then if a user wanted to include some information but not others, there would be fairly simple ways to specify information that a person wanted (a) in the article but not in Wikidata and (b) in Wikidata but not in the article.
Does documentation of how to do this exist somewhere? If yes, how can I find it? If no, can someone provide the needed documentation? Thanks, DavidMCEddy ( talk) 19:39, 1 June 2023 (UTC)
<ref>...</ref>
tags.Thanks. I was able to get something.
Now I have another problem: What can I do to get Wikidata: total revenue (P2139) to sort in date sequence in Pregnancy Justice (Q30288051)? When I use it in Wikipedia, the last "Revenue" entered is displayed. I think the most recent should be displayed, but that's not what I'm getting. ?? Thanks again. DavidMCEddy ( talk) 13:48, 2 June 2023 (UTC)
Your input is desired at a new Request for Comment at Template talk:Infobox company#Align the infobox?. ɱ (talk) 14:10, 19 July 2023 (UTC)
Greetings. MOS:COLLAPSE says: "A few infoboxes also use pre-collapsed sections for infrequently accessed details." Could any one help me find those cases, please? fgnievinski ( talk) 19:48, 8 August 2023 (UTC)
{{
Infobox Belgium municipality}}
, {{
Infobox Bible translation}}
, {{
Infobox Greece place}}
, {{
Infobox number system}}
, {{
Infobox OS}}
, {{
Infobox pharaoh}}
, {{
Infobox U.S. federal court}}
, {{
Infobox website}}
. This list is not exhaustive. --
Redrose64 🌹 (
talk)
21:12, 8 August 2023 (UTC)
{{
infobox journal}}
, please? It'd be valuable for an ongoing discussion (
Wikipedia talk:Notability (academic journals)#RfC on notability criteria). I've sandboxed it at
Template:Infobox journal/sandbox2 but the tests at
Template:Infobox_journal/testcases2 didn't seem to hide anything. It'd be used in
Draft:List_of_American_Medical_Association_journals. Thanks!
fgnievinski (
talk)
04:43, 9 August 2023 (UTC)
{{
hidden}}
to make any difference.
fgnievinski (
talk)
23:31, 9 August 2023 (UTC){{
Collapsed infobox section begin}}
instad of plain {{
hidden begin}}
!
fgnievinski (
talk)
23:31, 9 August 2023 (UTC)Hello colleagues! I tried to localize the Module:Infobox into the Kazakh Wikipedia. It seems like everything worked out, but some rows like headers are not aligned in the center, I can’t understand where the problem is, everything seems to be the same as in the English version. kk:Module:Ақпар қорабы for example u can see this template kk:Үлгі:Музыкалық топ, and article kk:Ұлытау тобы -- Amangeldi Mukhamejan ( talk) 13:14, 26 September 2023 (UTC)
I'd like clarification if small text is discouraged in all cases. These two on my watchlist are now making use of small text: [1] [2]. Leave as they are or should I revert? Mac Dreamstate ( talk) 19:12, 26 September 2023 (UTC)
|label12=
or |data9=
contained small tags or templates, and whether it would be worth trying. –
Jonesey95 (
talk)
20:37, 26 September 2023 (UTC)
I've stumbled upon a buggy interaction of
Template:Infobox ethnic group with
Template:Plainlist in article
Ainu people. There, the list after "Religion" has the list markers, despite being generated using template {{
plainlist}}. In the generated HTML, somehow the tags <ul>...</ul>
are missing. Only the outer wrapper <div class="plainlist">...</div>
and list items (<li>...</li>
) are present in the HTML. This makes it so that CSS code list-style: none
from
Template:Plainlist/styles.css#L-5 isn't triggered, because the CSS selector for the rule is .plainlist ol, .plainlist ul
.
I have reduced the reproducing sample to two test cases at
Template:Infobox/testcases#Template:Plainlist. Feel free to rename and/or move it as you see fit. This only happens when there is a list in |label(n)=
and
Template:Plainlist is in the next |data(n+1)=
(or in |data(n+2)=
if there is a |header(n+1)=
). Compare label1 with a list
vs label1 without a list
. —
andrybak (
talk)
21:49, 10 October 2023 (UTC)
label
misses the point of what a label is.fixChildBoxes
in some way. Either it's not covering some remixing, or it's not doing it in the right place, or it's not being called on such and sundry inputs.
Izno (
talk)
18:17, 11 October 2023 (UTC)
<div>
seems to fix it
here?
Frietjes (
talk)
00:11, 12 October 2023 (UTC)I would like to use the infobox template to create a new particular infobox template (an ancient polis infobox template) and employ it in multiple articles for the Ancient Greek Wikipedia.
I've tried to do so; however, I encountered problems, because (apparently) the existent module could only be used in the English Wikipedia. Thus, I re-created (i.e., copy-pasted) the module in the Ancient Greek Wikipedia Incubator. Here is the copy-pasted module: https://incubator.wikimedia.org/wiki/Module:Wp/grc/Infobox
I also had to re-create many modules and templates, necessary to make the infobox template work, in particular this, since I got an error message: https://incubator.wikimedia.org/wiki/Module:Wp/grc/Infobox/styles.css
Here is the "ancient polis" infobox template, the new template I created based on the infobox module: https://incubator.wikimedia.org/wiki/Template:Wp/grc/Πινάκιον_Ἀρχαία_Πόλις
Here is an article in which I use the new template: https://incubator.wikimedia.org/wiki/Wp/grc/Ἀγύριον_(ἀρχαία_πόλις)
As you can see:
1) The style is not right (the infobox should look more or less like this: /info/en/?search=Megara );
2) Furthermore, I'm unable do add images;
3) Lastly, I'm unable to add an interactive map.
Could someone kindly help?
Thank you very much!
- Anaxicrates ( talk) 14:55, 11 November 2023 (UTC)
-
(the
hyphen), that is only wikitext when it is preceded by |
and both appear at the beginning of the line. A similar comment about asking there.
Izno (
talk)
18:36, 12 November 2023 (UTC)