@ndla/ui 50.9.18 → 50.9.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/es/Embed/ImageEmbed.js +3 -2
- package/es/Gloss/Gloss.js +50 -42
- package/es/Gloss/GlossExample.js +7 -7
- package/es/LicenseByline/EmbedByline.js +9 -5
- package/es/locale/messages-en.js +3 -1
- package/es/locale/messages-nb.js +3 -1
- package/es/locale/messages-nn.js +3 -1
- package/es/locale/messages-se.js +3 -1
- package/es/locale/messages-sma.js +3 -1
- package/lib/Embed/ImageEmbed.js +3 -2
- package/lib/Gloss/Gloss.js +49 -41
- package/lib/Gloss/GlossExample.d.ts +2 -2
- package/lib/Gloss/GlossExample.js +6 -6
- package/lib/LicenseByline/EmbedByline.d.ts +2 -1
- package/lib/LicenseByline/EmbedByline.js +9 -5
- package/lib/locale/messages-en.d.ts +2 -0
- package/lib/locale/messages-en.js +3 -1
- package/lib/locale/messages-nb.d.ts +2 -0
- package/lib/locale/messages-nb.js +3 -1
- package/lib/locale/messages-nn.d.ts +2 -0
- package/lib/locale/messages-nn.js +3 -1
- package/lib/locale/messages-se.d.ts +2 -0
- package/lib/locale/messages-se.js +3 -1
- package/lib/locale/messages-sma.d.ts +2 -0
- package/lib/locale/messages-sma.js +3 -1
- package/package.json +4 -4
- package/src/Embed/ImageEmbed.tsx +2 -1
- package/src/Gloss/Gloss.tsx +62 -27
- package/src/Gloss/GlossExample.tsx +23 -17
- package/src/LicenseByline/EmbedByline.tsx +13 -1
- package/src/locale/messages-en.ts +2 -0
- package/src/locale/messages-nb.ts +2 -0
- package/src/locale/messages-nn.ts +2 -0
- package/src/locale/messages-se.ts +2 -0
- package/src/locale/messages-sma.ts +2 -0
|
@@ -27,6 +27,7 @@ interface BaseProps {
|
|
|
27
27
|
children?: ReactNode;
|
|
28
28
|
visibleAlt?: string;
|
|
29
29
|
error?: true | false;
|
|
30
|
+
hideOnLargeScreens?: boolean;
|
|
30
31
|
first?: boolean;
|
|
31
32
|
inGrid?: boolean;
|
|
32
33
|
}
|
|
@@ -95,6 +96,11 @@ const BylineWrapper = styled.div`
|
|
|
95
96
|
&[data-first="true"] {
|
|
96
97
|
border-top: 1px solid ${colors.brand.light};
|
|
97
98
|
}
|
|
99
|
+
&[data-hide-on-large-screens="true"] {
|
|
100
|
+
${mq.range({ from: breakpoints.tablet })} {
|
|
101
|
+
display: none;
|
|
102
|
+
}
|
|
103
|
+
}
|
|
98
104
|
`;
|
|
99
105
|
|
|
100
106
|
const mobileStyling = css`
|
|
@@ -135,6 +141,7 @@ const EmbedByline = ({
|
|
|
135
141
|
description,
|
|
136
142
|
children,
|
|
137
143
|
visibleAlt,
|
|
144
|
+
hideOnLargeScreens,
|
|
138
145
|
first = true,
|
|
139
146
|
inGrid = false,
|
|
140
147
|
...props
|
|
@@ -157,7 +164,12 @@ const EmbedByline = ({
|
|
|
157
164
|
const captionAuthors = Object.values(authors).find((i) => i.length > 0) ?? [];
|
|
158
165
|
|
|
159
166
|
return (
|
|
160
|
-
<BylineWrapper
|
|
167
|
+
<BylineWrapper
|
|
168
|
+
data-top-rounded={topRounded}
|
|
169
|
+
data-hide-on-large-screens={hideOnLargeScreens}
|
|
170
|
+
data-bottom-rounded={bottomRounded}
|
|
171
|
+
data-first={first}
|
|
172
|
+
>
|
|
161
173
|
{description && <LicenseDescription description={description} />}
|
|
162
174
|
{visibleAlt ? <StyledSpan>{`Alt: ${visibleAlt}`}</StyledSpan> : null}
|
|
163
175
|
<RightsWrapper data-grid={inGrid}>
|
|
@@ -1110,6 +1110,8 @@ const messages = {
|
|
|
1110
1110
|
enableArena: "Give {{user}} access to the arena.",
|
|
1111
1111
|
noUsers: "No users found.",
|
|
1112
1112
|
search: "Search for users",
|
|
1113
|
+
becameAdmin: "User '{{user}}' was elevated to administrator",
|
|
1114
|
+
becameNormalUser: "User '{{user}}' no longer has administrator access",
|
|
1113
1115
|
},
|
|
1114
1116
|
flags: {
|
|
1115
1117
|
title: "Flag",
|
|
@@ -1110,6 +1110,8 @@ const messages = {
|
|
|
1110
1110
|
enableArena: 'Gi "{{user}}" tilgang til arena.',
|
|
1111
1111
|
noUsers: "Ingen brukere funnet.",
|
|
1112
1112
|
search: "Søk etter brukere",
|
|
1113
|
+
becameAdmin: "Bruker '{{user}}' har fått administrator tilgang",
|
|
1114
|
+
becameNormalUser: "Bruker '{{user}}' har ikke lenger administrator tilgang",
|
|
1113
1115
|
},
|
|
1114
1116
|
flags: {
|
|
1115
1117
|
title: "Flagg",
|
|
@@ -1110,6 +1110,8 @@ const messages = {
|
|
|
1110
1110
|
enableArena: 'Gi "{{user}}" tilgang til arena.',
|
|
1111
1111
|
noUsers: "Ingen brukarar funne.",
|
|
1112
1112
|
search: "Søk etter brukarar",
|
|
1113
|
+
becameAdmin: "Brukar '{{user}}' har fått administrator tilgong",
|
|
1114
|
+
becameNormalUser: "Brukar '{{user}}' har ikkje lenger administrator tilgong",
|
|
1113
1115
|
},
|
|
1114
1116
|
flags: {
|
|
1115
1117
|
title: "Flagg",
|
|
@@ -1112,6 +1112,8 @@ const messages = {
|
|
|
1112
1112
|
enableArena: 'Gi "{{user}}" tilgang til arena.',
|
|
1113
1113
|
noUsers: "Ingen brukere funnet.",
|
|
1114
1114
|
search: "Søk etter brukere",
|
|
1115
|
+
becameAdmin: "Bruker '{{user}}' har fått administrator tilgang",
|
|
1116
|
+
becameNormalUser: "Bruker '{{user}}' har ikke lenger administrator tilgang",
|
|
1115
1117
|
},
|
|
1116
1118
|
flags: {
|
|
1117
1119
|
title: "Flagg",
|
|
@@ -1114,6 +1114,8 @@ const messages = {
|
|
|
1114
1114
|
enableArena: 'Gi "{{user}}" tilgang til arena.',
|
|
1115
1115
|
noUsers: "Ingen brukere funnet.",
|
|
1116
1116
|
search: "Søk etter brukere",
|
|
1117
|
+
becameAdmin: "Bruker '{{user}}' har fått administrator tilgang",
|
|
1118
|
+
becameNormalUser: "Bruker '{{user}}' har ikke lenger administrator tilgang",
|
|
1117
1119
|
},
|
|
1118
1120
|
flags: {
|
|
1119
1121
|
title: "Flagg",
|