@ndla/ui 8.1.2 → 8.2.2
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/Topic/Topic.js +25 -21
- package/es/all.css +1 -1
- package/es/locale/messages-nb.js +1 -1
- package/es/locale/messages-nn.js +1 -1
- package/lib/Topic/Topic.d.ts +2 -1
- package/lib/Topic/Topic.js +26 -21
- package/lib/all.css +1 -1
- package/lib/locale/messages-nb.js +1 -1
- package/lib/locale/messages-nn.js +1 -1
- package/package.json +13 -13
- package/src/Topic/Topic.tsx +4 -0
- package/src/locale/messages-nb.ts +1 -1
- package/src/locale/messages-nn.ts +1 -1
|
@@ -488,7 +488,7 @@ var messages = _objectSpread(_objectSpread({
|
|
|
488
488
|
footerInfo: 'Nettstedet er utarbeidet av NDLA med åpen kildekode.',
|
|
489
489
|
footerEditiorInChief: 'Ansvarlig redaktør: ',
|
|
490
490
|
footerManagingEditor: 'Utgaveansvarlig: ',
|
|
491
|
-
footerPrivacyLink: 'Personvernerklæring',
|
|
491
|
+
footerPrivacyLink: 'Personvernerklæring og cookies',
|
|
492
492
|
socialMediaLinks: {
|
|
493
493
|
facebook: 'NDLA på Facebook',
|
|
494
494
|
facebookAria: 'Besøk NDLA på Facebook',
|
|
@@ -488,7 +488,7 @@ var messages = _objectSpread(_objectSpread({
|
|
|
488
488
|
footerInfo: 'Nettstaden er utarbeida av NDLA med open kjeldekode.',
|
|
489
489
|
footerEditiorInChief: 'Ansvarleg redaktør: ',
|
|
490
490
|
footerManagingEditor: 'Utgåveansvarleg: ',
|
|
491
|
-
footerPrivacyLink: 'Personvernerklæring',
|
|
491
|
+
footerPrivacyLink: 'Personvernerklæring og cookies',
|
|
492
492
|
socialMediaLinks: {
|
|
493
493
|
facebook: 'NDLA på Facebook',
|
|
494
494
|
facebookAria: 'Besøk NDLA på Facebook',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ndla/ui",
|
|
3
|
-
"version": "8.
|
|
3
|
+
"version": "8.2.2",
|
|
4
4
|
"description": "UI component library for NDLA.",
|
|
5
5
|
"license": "GPL-3.0",
|
|
6
6
|
"main": "lib/index.js",
|
|
@@ -31,18 +31,18 @@
|
|
|
31
31
|
"types"
|
|
32
32
|
],
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@ndla/button": "^2.1.
|
|
35
|
-
"@ndla/carousel": "^1.2.
|
|
36
|
-
"@ndla/core": "^2.0
|
|
37
|
-
"@ndla/hooks": "^1.1.
|
|
34
|
+
"@ndla/button": "^2.1.4",
|
|
35
|
+
"@ndla/carousel": "^1.2.4",
|
|
36
|
+
"@ndla/core": "^2.1.0",
|
|
37
|
+
"@ndla/hooks": "^1.1.3",
|
|
38
38
|
"@ndla/icons": "^1.6.1",
|
|
39
|
-
"@ndla/licenses": "^4.0.
|
|
40
|
-
"@ndla/modal": "^1.2.
|
|
41
|
-
"@ndla/safelink": "^1.1.
|
|
42
|
-
"@ndla/switch": "^0.1.
|
|
43
|
-
"@ndla/tabs": "^1.1.
|
|
44
|
-
"@ndla/tooltip": "^0.3.
|
|
45
|
-
"@ndla/util": "^2.0.
|
|
39
|
+
"@ndla/licenses": "^4.0.4",
|
|
40
|
+
"@ndla/modal": "^1.2.4",
|
|
41
|
+
"@ndla/safelink": "^1.1.5",
|
|
42
|
+
"@ndla/switch": "^0.1.4",
|
|
43
|
+
"@ndla/tabs": "^1.1.3",
|
|
44
|
+
"@ndla/tooltip": "^0.3.4",
|
|
45
|
+
"@ndla/util": "^2.0.5",
|
|
46
46
|
"@reach/menu-button": "^0.16.2",
|
|
47
47
|
"@reach/slider": "^0.16.0",
|
|
48
48
|
"focus-trap-react": "^8.9.2",
|
|
@@ -80,5 +80,5 @@
|
|
|
80
80
|
"publishConfig": {
|
|
81
81
|
"access": "public"
|
|
82
82
|
},
|
|
83
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "6df959ff51e98a78f73ef3140bf39174b5bf2221"
|
|
84
84
|
}
|
package/src/Topic/Topic.tsx
CHANGED
|
@@ -21,6 +21,7 @@ import Loader from './Loader';
|
|
|
21
21
|
import { ItemProps } from '../Navigation/NavigationBox';
|
|
22
22
|
import { NavigationBox } from '../Navigation';
|
|
23
23
|
import { makeSrcQueryString, ImageCrop, ImageFocalPoint } from '../Image';
|
|
24
|
+
import { MessageBox, MessageBoxType } from '../MessageBox';
|
|
24
25
|
|
|
25
26
|
type InvertItProps = {
|
|
26
27
|
invertedStyle?: boolean;
|
|
@@ -235,6 +236,7 @@ export type TopicProps = {
|
|
|
235
236
|
showContent?: boolean;
|
|
236
237
|
isAdditionalTopic?: boolean;
|
|
237
238
|
frame?: boolean;
|
|
239
|
+
messageBox?: string;
|
|
238
240
|
children?: ReactNode;
|
|
239
241
|
};
|
|
240
242
|
|
|
@@ -249,6 +251,7 @@ const Topic = ({
|
|
|
249
251
|
showContent,
|
|
250
252
|
isAdditionalTopic,
|
|
251
253
|
frame,
|
|
254
|
+
messageBox,
|
|
252
255
|
children,
|
|
253
256
|
}: TopicProps) => {
|
|
254
257
|
const { t } = useTranslation();
|
|
@@ -328,6 +331,7 @@ const Topic = ({
|
|
|
328
331
|
</StyledAdditionalResource>
|
|
329
332
|
)}
|
|
330
333
|
</TopicHeading>
|
|
334
|
+
{messageBox && <MessageBox type={MessageBoxType.medium}>{messageBox}</MessageBox>}
|
|
331
335
|
<TopicIntroduction invertedStyle={invertedStyle}>
|
|
332
336
|
{renderMarkdown ? parse(renderMarkdown(topic.introduction)) : topic.introduction}
|
|
333
337
|
</TopicIntroduction>
|
|
@@ -518,7 +518,7 @@ const messages = {
|
|
|
518
518
|
footerInfo: 'Nettstedet er utarbeidet av NDLA med åpen kildekode.',
|
|
519
519
|
footerEditiorInChief: 'Ansvarlig redaktør: ',
|
|
520
520
|
footerManagingEditor: 'Utgaveansvarlig: ',
|
|
521
|
-
footerPrivacyLink: 'Personvernerklæring',
|
|
521
|
+
footerPrivacyLink: 'Personvernerklæring og cookies',
|
|
522
522
|
socialMediaLinks: {
|
|
523
523
|
facebook: 'NDLA på Facebook',
|
|
524
524
|
facebookAria: 'Besøk NDLA på Facebook',
|
|
@@ -519,7 +519,7 @@ const messages = {
|
|
|
519
519
|
footerInfo: 'Nettstaden er utarbeida av NDLA med open kjeldekode.',
|
|
520
520
|
footerEditiorInChief: 'Ansvarleg redaktør: ',
|
|
521
521
|
footerManagingEditor: 'Utgåveansvarleg: ',
|
|
522
|
-
footerPrivacyLink: 'Personvernerklæring',
|
|
522
|
+
footerPrivacyLink: 'Personvernerklæring og cookies',
|
|
523
523
|
socialMediaLinks: {
|
|
524
524
|
facebook: 'NDLA på Facebook',
|
|
525
525
|
facebookAria: 'Besøk NDLA på Facebook',
|