Jump to content

Template talk:Infobox nutritional value

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia

Needs to be collapsible

[edit]

The template clearly has a useful function but it can take up a very large amount of screen space, and in particular it occupies a great length on the right hand side, making image, diagram and table placement difficult. It would be very helpful if the template could have a parameter to allow it to be collapsed where necessary. Chiswick Chap (talk) 08:10, 21 April 2017 (UTC)[reply]

Agree...is there any good workaround to hide/collapse it? —Hyperik talk 21:59, 4 August 2019 (UTC)[reply]
Infoboxes are not collasible. There are widgets that hide IBs (and they don't show on mobile) but you'd need an RFC to change how infoboxes display. Primefac (talk) 23:33, 4 August 2019 (UTC)[reply]
Popping in here to agree that this needs to be collapsible, since it takes up an enormous amount of space. Why specifically are they not collapsible? And, where could a request be made to suggest making this kind of change to infoboxes so they allow flexibility of use? Cheers —Kittycataclysm (talk) 23:26, 28 April 2024 (UTC)[reply]

Empty niacin %DV

[edit]

There are several articles where the %DV of niacin is not calculated by the template, such as spinach and cantaloupe. Zefr (talk) 20:29, 18 March 2024 (UTC)[reply]

Revisions were made today by Waddie96 - please review the subsequent edit. Zefr (talk) 21:32, 18 March 2024 (UTC)[reply]
Good day Zefr, I was called for by your ping. Thanks for your feedback. I hope you appreciate. waddie96 ★ (talk) 21:36, 18 March 2024 (UTC)[reply]
Thanks for the quick work and resolution, Waddie96. The niacin %DV values are now displayed on all the tables I had checked for its absence. I don't understand why this edit was made - is it correct? Zefr (talk) 21:43, 18 March 2024 (UTC)[reply]
It is correct, see also here. Sorry, I somehow made an error. waddie96 ★ (talk) 13:22, 19 March 2024 (UTC)[reply]

Semi-protected edit request on 11 August 2024

[edit]

I request the broken section link, Manganese § Biological role, be changed to point to the working section link Manganese § Human health and nutrition.

Change:

        | label6 = [[Manganese#Biological role|Manganese]]

To:

        | label6 = [[Manganese#Human health and nutrition|Manganese]]

73.37.211.177 (talk) 00:54, 11 August 2024 (UTC)[reply]

 Done CloakedFerret (talk) 07:31, 11 August 2024 (UTC)[reply]
CloakedFerret - for uniformity, nearly all of the dietary minerals have an article entitled 'x in biology', allowing links in the nutrition table to be directed there; this would put iron, potassium, etc. (see raw link format) in the same context for users clicking on the mineral names. An exception is the phosphorus article, which has a section entitled biological role. Sodium and selenium are not always included in nutrition tables for foods, but can be changed to the 'x in biology' format. Examples of improved wikilinks are here. Zefr (talk) 17:33, 24 September 2024 (UTC)[reply]

Centre-aligned labels on mobile view appear haphazard

[edit]
Chia seeds, dried, raw
Nutritional value per 100 g (3.5 oz)
Energy486 kcal (2,030 kJ)
42.1 g
Dietary fiber34.4 g
30.7 g
Saturated3.3 g
Monounsaturated2.3 g
Polyunsaturated23.7 g
17.8 g
5.8 g
16.5 g
Vitamins and minerals
VitaminsQuantity
%DV
Vitamin A equiv.
6%
54 μg
Thiamine (B1)
52%
0.62 mg
Riboflavin (B2)
13%
0.17 mg
Niacin (B3)
55%
8.83 mg
Folate (B9)
12%
49 μg
Vitamin C
2%
1.6 mg
Vitamin E
3%
0.5 mg
MineralsQuantity
%DV
Calcium
49%
631 mg
Iron
43%
7.7 mg
Magnesium
80%
335 mg
Manganese
118%
2.72 mg
Phosphorus
69%
860 mg
Potassium
14%
407 mg
Zinc
42%
4.6 mg
Other constituentsQuantity
Water5.8 g

Percentages estimated using US recommendations for adults,[1] except for potassium, which is estimated based on expert recommendation from the National Academies.[2]

On my Android Chrome's Mobile view (but not Desktop view), header cells are centre-aligned, as in this table from chia seed..

As the left column is made of header cells, and the labels are whitespace-padded to fake indentation, they appear haphazardly aligned.

Can these cells be explicitly left-justified? cmɢʟeeτaʟκ 09:19, 24 September 2024 (UTC)[reply]

P.S. A remedy is to wrap the arguments of label# (where # is an integer) with

<div style="text-align:left;">

and

</div>

(or add text-align:left; to its style if it's already a div) e.g.

Before (see in Mobile view):
30.7 g
Saturated3.3 g
Monounsaturated2.3 g
Polyunsaturated23.7 g
17.8 g
5.8 g
After (see in Mobile view):
30.7 g
3.3 g
2.3 g
23.7 g
17.8 g
5.8 g

cmɢʟeeτaʟκ 14:15, 24 September 2024 (UTC)[reply]

This is because the relevant style (text alignment) isn't loaded on mobile. It should be Soon. Izno (talk) 15:20, 24 September 2024 (UTC)[reply]
And soon is defined more or less by the resolution of phab:T375538. Izno (talk) 17:31, 24 September 2024 (UTC)[reply]
Thanks for explaining, @Izno: I'll leave it as is and await a solution then. Cheers, cmɢʟeeτaʟκ 19:21, 25 September 2024 (UTC)[reply]

References

  1. ^ United States Food and Drug Administration (2024). "Daily Value on the Nutrition and Supplement Facts Labels". FDA. Archived from the original on 2024-03-27. Retrieved 2024-03-28.
  2. ^ National Academies of Sciences, Engineering, and Medicine; Health and Medicine Division; Food and Nutrition Board; Committee to Review the Dietary Reference Intakes for Sodium and Potassium (2019). Oria, Maria; Harrison, Meghan; Stallings, Virginia A. (eds.). Dietary Reference Intakes for Sodium and Potassium. The National Academies Collection: Reports funded by National Institutes of Health. Washington, DC: National Academies Press (US). ISBN 978-0-309-48834-1. PMID 30844154. Archived from the original on 2024-05-09. Retrieved 2024-06-21.