@ndla/ui 56.0.15-alpha.0 → 56.0.16-alpha.0
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/dist/panda.buildinfo.json +18 -20
- package/dist/styles.css +62 -67
- package/es/Article/Article.js +22 -94
- package/es/Article/index.js +1 -1
- package/es/CampaignBlock/CampaignBlock.js +33 -5
- package/es/index.js +1 -1
- package/es/locale/messages-en.js +2 -2
- package/es/locale/messages-nb.js +2 -2
- package/es/locale/messages-nn.js +2 -2
- package/es/locale/messages-se.js +2 -2
- package/es/locale/messages-sma.js +2 -2
- package/es/styles.css +62 -67
- package/lib/Article/Article.d.ts +3 -18
- package/lib/Article/Article.js +22 -94
- package/lib/Article/index.d.ts +1 -1
- package/lib/Article/index.js +0 -12
- package/lib/CampaignBlock/CampaignBlock.js +33 -5
- package/lib/index.d.ts +1 -1
- package/lib/index.js +0 -12
- package/lib/locale/messages-en.js +2 -2
- package/lib/locale/messages-nb.js +2 -2
- package/lib/locale/messages-nn.js +2 -2
- package/lib/locale/messages-se.js +2 -2
- package/lib/locale/messages-sma.js +2 -2
- package/lib/styles.css +62 -67
- package/package.json +7 -7
- package/src/Article/Article.tsx +22 -107
- package/src/Article/index.ts +0 -2
- package/src/CampaignBlock/CampaignBlock.tsx +35 -4
- package/src/index.ts +0 -2
- package/src/locale/messages-en.ts +2 -2
- package/src/locale/messages-nb.ts +2 -2
- package/src/locale/messages-nn.ts +2 -2
- package/src/locale/messages-se.ts +2 -2
- package/src/locale/messages-sma.ts +2 -2
package/es/locale/messages-se.js
CHANGED
|
@@ -1068,9 +1068,9 @@ const messages = {
|
|
|
1068
1068
|
},
|
|
1069
1069
|
fetchMore: "Hent flere svar",
|
|
1070
1070
|
deleted: "Dette innlegget er slettet av forfatteren.",
|
|
1071
|
-
upvote: "
|
|
1071
|
+
upvote: "Liker",
|
|
1072
1072
|
numberOfUpvotes: "{{ count }} personer har stemt opp denne.",
|
|
1073
|
-
removeUpvote: "
|
|
1073
|
+
removeUpvote: "Slutt å like",
|
|
1074
1074
|
reply: "Skriv et svar til {{ name }}"
|
|
1075
1075
|
},
|
|
1076
1076
|
flag: {
|
|
@@ -1068,9 +1068,9 @@ const messages = {
|
|
|
1068
1068
|
},
|
|
1069
1069
|
fetchMore: "Hent flere svar",
|
|
1070
1070
|
deleted: "Dette innlegget er slettet av forfatteren.",
|
|
1071
|
-
upvote: "
|
|
1071
|
+
upvote: "Liker",
|
|
1072
1072
|
numberOfUpvotes: "{{ count }} personer har stemt opp denne.",
|
|
1073
|
-
removeUpvote: "
|
|
1073
|
+
removeUpvote: "Slutt å like",
|
|
1074
1074
|
reply: "Skriv et svar til {{ name }}"
|
|
1075
1075
|
},
|
|
1076
1076
|
flag: {
|
package/es/styles.css
CHANGED
|
@@ -85,34 +85,26 @@
|
|
|
85
85
|
}
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
.
|
|
89
|
-
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.w_100\% {
|
|
93
|
-
width: 100%;
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.pbs_xsmall {
|
|
97
|
-
padding-block-start: var(--spacing-xsmall);
|
|
98
|
-
}
|
|
99
|
-
|
|
100
|
-
.pbe_xsmall {
|
|
101
|
-
padding-block-end: var(--spacing-xsmall);
|
|
102
|
-
}
|
|
103
|
-
|
|
104
|
-
.bg_surface\.default {
|
|
105
|
-
background: var(--colors-surface-default);
|
|
88
|
+
.bg_background\.default {
|
|
89
|
+
background: var(--colors-background-default);
|
|
106
90
|
}
|
|
107
91
|
|
|
108
92
|
.d_flex {
|
|
109
93
|
display: flex;
|
|
110
94
|
}
|
|
111
95
|
|
|
96
|
+
.gap_xxlarge {
|
|
97
|
+
gap: var(--spacing-xxlarge);
|
|
98
|
+
}
|
|
99
|
+
|
|
112
100
|
.c_text\.default {
|
|
113
101
|
color: var(--colors-text-default);
|
|
114
102
|
}
|
|
115
103
|
|
|
104
|
+
.w_100\% {
|
|
105
|
+
width: 100%;
|
|
106
|
+
}
|
|
107
|
+
|
|
116
108
|
.ov-wrap_break-word {
|
|
117
109
|
overflow-wrap: break-word;
|
|
118
110
|
}
|
|
@@ -121,26 +113,22 @@
|
|
|
121
113
|
position: relative;
|
|
122
114
|
}
|
|
123
115
|
|
|
124
|
-
.gap_xsmall {
|
|
125
|
-
gap: var(--spacing-xsmall);
|
|
126
|
-
}
|
|
127
|
-
|
|
128
|
-
.pos_absolute {
|
|
129
|
-
position: absolute;
|
|
130
|
-
}
|
|
131
|
-
|
|
132
116
|
.gap_medium {
|
|
133
117
|
gap: var(--spacing-medium);
|
|
134
118
|
}
|
|
135
119
|
|
|
136
|
-
.
|
|
137
|
-
|
|
120
|
+
.pbs_xxlarge {
|
|
121
|
+
padding-block-start: var(--spacing-xxlarge);
|
|
138
122
|
}
|
|
139
123
|
|
|
140
124
|
.mbs_medium {
|
|
141
125
|
margin-block-start: var(--spacing-medium);
|
|
142
126
|
}
|
|
143
127
|
|
|
128
|
+
.pbs_xsmall {
|
|
129
|
+
padding-block-start: var(--spacing-xsmall);
|
|
130
|
+
}
|
|
131
|
+
|
|
144
132
|
.bd-t_1px_solid {
|
|
145
133
|
border-top: 1px solid;
|
|
146
134
|
}
|
|
@@ -153,8 +141,8 @@
|
|
|
153
141
|
padding-block: var(--spacing-xsmall);
|
|
154
142
|
}
|
|
155
143
|
|
|
156
|
-
.
|
|
157
|
-
|
|
144
|
+
.gap_xsmall {
|
|
145
|
+
gap: var(--spacing-xsmall);
|
|
158
146
|
}
|
|
159
147
|
|
|
160
148
|
.li-s_none {
|
|
@@ -218,10 +206,6 @@
|
|
|
218
206
|
border-bottom-right-radius: var(--radii-xsmall);
|
|
219
207
|
}
|
|
220
208
|
|
|
221
|
-
.bg_background\.default {
|
|
222
|
-
background: var(--colors-background-default);
|
|
223
|
-
}
|
|
224
|
-
|
|
225
209
|
.px_medium {
|
|
226
210
|
padding-inline: var(--spacing-medium);
|
|
227
211
|
}
|
|
@@ -374,6 +358,10 @@
|
|
|
374
358
|
padding: var(--spacing-medium);
|
|
375
359
|
}
|
|
376
360
|
|
|
361
|
+
.bg_surface\.default {
|
|
362
|
+
background: var(--colors-surface-default);
|
|
363
|
+
}
|
|
364
|
+
|
|
377
365
|
.z_base {
|
|
378
366
|
z-index: var(--z-index-base);
|
|
379
367
|
}
|
|
@@ -426,6 +414,10 @@
|
|
|
426
414
|
border: 2px solid;
|
|
427
415
|
}
|
|
428
416
|
|
|
417
|
+
.pos_absolute {
|
|
418
|
+
position: absolute;
|
|
419
|
+
}
|
|
420
|
+
|
|
429
421
|
.op_0 {
|
|
430
422
|
opacity: 0;
|
|
431
423
|
}
|
|
@@ -635,14 +627,6 @@
|
|
|
635
627
|
align-items: flex-start;
|
|
636
628
|
}
|
|
637
629
|
|
|
638
|
-
.right_8\% {
|
|
639
|
-
right: 8%;
|
|
640
|
-
}
|
|
641
|
-
|
|
642
|
-
.top_xsmall {
|
|
643
|
-
top: var(--spacing-xsmall);
|
|
644
|
-
}
|
|
645
|
-
|
|
646
630
|
.bd-c_stroke\.subtle {
|
|
647
631
|
border-color: var(--colors-stroke-subtle);
|
|
648
632
|
}
|
|
@@ -694,6 +678,10 @@
|
|
|
694
678
|
align-items: flex-end;
|
|
695
679
|
}
|
|
696
680
|
|
|
681
|
+
.fw_bold {
|
|
682
|
+
font-weight: var(--font-weights-bold);
|
|
683
|
+
}
|
|
684
|
+
|
|
697
685
|
.as_center {
|
|
698
686
|
align-self: center;
|
|
699
687
|
}
|
|
@@ -734,10 +722,6 @@
|
|
|
734
722
|
top: calc(var(--spacing-4xsmall) * -1);
|
|
735
723
|
}
|
|
736
724
|
|
|
737
|
-
.fw_bold {
|
|
738
|
-
font-weight: var(--font-weights-bold);
|
|
739
|
-
}
|
|
740
|
-
|
|
741
725
|
.bg-c_surface\.disabled {
|
|
742
726
|
background-color: var(--colors-surface-disabled);
|
|
743
727
|
}
|
|
@@ -773,6 +757,10 @@
|
|
|
773
757
|
transition-timing-function: ease-out;
|
|
774
758
|
}
|
|
775
759
|
|
|
760
|
+
.top_xsmall {
|
|
761
|
+
top: var(--spacing-xsmall);
|
|
762
|
+
}
|
|
763
|
+
|
|
776
764
|
.right_xsmall {
|
|
777
765
|
right: var(--spacing-xsmall);
|
|
778
766
|
}
|
|
@@ -908,6 +896,10 @@
|
|
|
908
896
|
overflow-wrap: anywhere;
|
|
909
897
|
}
|
|
910
898
|
|
|
899
|
+
.\[\&_\>_\:is\(\:last-child\)\]\:pbe_5xlarge > :is(:last-child) {
|
|
900
|
+
padding-block-end: var(--spacing-5xlarge);
|
|
901
|
+
}
|
|
902
|
+
|
|
911
903
|
.\[\&\[data-align\=\"center\"\]\]\:ta_center[data-align="center"] {
|
|
912
904
|
text-align: center;
|
|
913
905
|
}
|
|
@@ -1456,6 +1448,9 @@
|
|
|
1456
1448
|
}
|
|
1457
1449
|
|
|
1458
1450
|
@media screen and (min-width: 29.75rem) {
|
|
1451
|
+
.mobileWide\:h_340px {
|
|
1452
|
+
height: 340px;
|
|
1453
|
+
}
|
|
1459
1454
|
.mobileWide\:d_none {
|
|
1460
1455
|
display: none;
|
|
1461
1456
|
}
|
|
@@ -1468,12 +1463,6 @@
|
|
|
1468
1463
|
}
|
|
1469
1464
|
|
|
1470
1465
|
@media screen and (min-width: 37.5625rem) {
|
|
1471
|
-
.tablet\:pbs_medium {
|
|
1472
|
-
padding-block-start: var(--spacing-medium);
|
|
1473
|
-
}
|
|
1474
|
-
.tablet\:pbe_medium {
|
|
1475
|
-
padding-block-end: var(--spacing-medium);
|
|
1476
|
-
}
|
|
1477
1466
|
.tablet\:px_medium {
|
|
1478
1467
|
padding-inline: var(--spacing-medium);
|
|
1479
1468
|
}
|
|
@@ -1488,9 +1477,6 @@
|
|
|
1488
1477
|
}
|
|
1489
1478
|
.tablet\:w_83\.333\% {
|
|
1490
1479
|
width: 83.333%;
|
|
1491
|
-
}
|
|
1492
|
-
.tablet\:top_medium {
|
|
1493
|
-
top: var(--spacing-medium);
|
|
1494
1480
|
}
|
|
1495
1481
|
.tablet\:ai_unset {
|
|
1496
1482
|
align-items: unset;
|
|
@@ -1557,6 +1543,27 @@
|
|
|
1557
1543
|
}
|
|
1558
1544
|
.tabletWide\:max-w_532px {
|
|
1559
1545
|
max-width: 532px;
|
|
1546
|
+
}
|
|
1547
|
+
.tabletWide\:w_auto {
|
|
1548
|
+
width: auto;
|
|
1549
|
+
}
|
|
1550
|
+
.tabletWide\:d_block {
|
|
1551
|
+
display: block;
|
|
1552
|
+
}
|
|
1553
|
+
.tabletWide\:ov_hidden {
|
|
1554
|
+
overflow: hidden;
|
|
1555
|
+
}
|
|
1556
|
+
.tabletWide\:pos_relative {
|
|
1557
|
+
position: relative;
|
|
1558
|
+
}
|
|
1559
|
+
.tabletWide\:lc_4 {
|
|
1560
|
+
overflow: hidden;
|
|
1561
|
+
display: -webkit-box;
|
|
1562
|
+
-webkit-line-clamp: 4;
|
|
1563
|
+
-webkit-box-orient: vertical;
|
|
1564
|
+
}
|
|
1565
|
+
.tabletWide\:box-orient_vertical {
|
|
1566
|
+
box-orient: vertical;
|
|
1560
1567
|
}
|
|
1561
1568
|
.tabletWide\:flex-d_row {
|
|
1562
1569
|
flex-direction: row;
|
|
@@ -1567,23 +1574,11 @@
|
|
|
1567
1574
|
}
|
|
1568
1575
|
|
|
1569
1576
|
@media screen and (min-width: 61.3125rem) {
|
|
1570
|
-
.desktop\:pbs_xxlarge {
|
|
1571
|
-
padding-block-start: var(--spacing-xxlarge);
|
|
1572
|
-
}
|
|
1573
|
-
.desktop\:pbe_xxlarge {
|
|
1574
|
-
padding-block-end: var(--spacing-xxlarge);
|
|
1575
|
-
}
|
|
1576
1577
|
.desktop\:w_260px {
|
|
1577
1578
|
width: 260px;
|
|
1578
1579
|
}
|
|
1579
1580
|
.desktop\:h_260px {
|
|
1580
1581
|
height: 260px;
|
|
1581
|
-
}
|
|
1582
|
-
.desktop\:h_340px {
|
|
1583
|
-
height: 340px;
|
|
1584
|
-
}
|
|
1585
|
-
.desktop\:top_xxlarge {
|
|
1586
|
-
top: var(--spacing-xxlarge);
|
|
1587
1582
|
}
|
|
1588
1583
|
.desktop\:grid-tc_repeat\(3\,_minmax\(0\,_1fr\)\) {
|
|
1589
1584
|
grid-template-columns: repeat(3, minmax(0, 1fr));
|
package/lib/Article/Article.d.ts
CHANGED
|
@@ -8,17 +8,9 @@
|
|
|
8
8
|
import { ReactNode } from "react";
|
|
9
9
|
import { ContentType } from "../ContentTypeBadge/ContentTypeBadgeNew";
|
|
10
10
|
import { Article as ArticleType } from "../types";
|
|
11
|
-
export declare const ArticlePadding: import("@ndla/styled-system/types").StyledComponent<import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
12
|
-
ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
13
|
-
} & import("@ark-ui/react").PolymorphicProps>, {
|
|
14
|
-
padStart?: boolean | undefined;
|
|
15
|
-
padEnd?: boolean | undefined;
|
|
16
|
-
}>;
|
|
17
11
|
export declare const ArticleContent: import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & import("@ark-ui/react").PolymorphicProps & {
|
|
18
12
|
consumeCss?: boolean | undefined;
|
|
19
|
-
} & import("@ndla/styled-system/types").WithCss &
|
|
20
|
-
padded?: boolean | undefined;
|
|
21
|
-
} & import("react").RefAttributes<HTMLElement>>;
|
|
13
|
+
} & import("@ndla/styled-system/types").WithCss & import("react").RefAttributes<HTMLElement>>;
|
|
22
14
|
export declare const ArticleWrapper: import("react").ForwardRefExoticComponent<Omit<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
23
15
|
ref?: ((instance: HTMLElement | null) => void) | import("react").RefObject<HTMLElement> | null | undefined;
|
|
24
16
|
} & {
|
|
@@ -27,19 +19,12 @@ export declare const ArticleWrapper: import("react").ForwardRefExoticComponent<O
|
|
|
27
19
|
export declare const ArticleHGroup: import("@ndla/styled-system/types").StyledComponent<import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
28
20
|
ref?: ((instance: HTMLElement | null) => void) | import("react").RefObject<HTMLElement> | null | undefined;
|
|
29
21
|
} & import("@ark-ui/react").PolymorphicProps>, {}>;
|
|
30
|
-
export declare const ArticleActionWrapper: import("@ndla/styled-system/types").StyledComponent<import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, "ref"> & {
|
|
31
|
-
ref?: ((instance: HTMLDivElement | null) => void) | import("react").RefObject<HTMLDivElement> | null | undefined;
|
|
32
|
-
} & import("@ark-ui/react").PolymorphicProps>, {}>;
|
|
33
22
|
export declare const ArticleHeader: import("@ndla/styled-system/types").StyledComponent<import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
34
23
|
ref?: ((instance: HTMLElement | null) => void) | import("react").RefObject<HTMLElement> | null | undefined;
|
|
35
|
-
} & import("@ark-ui/react").PolymorphicProps>, {
|
|
36
|
-
padded?: boolean | undefined;
|
|
37
|
-
}>;
|
|
24
|
+
} & import("@ark-ui/react").PolymorphicProps>, {}>;
|
|
38
25
|
export declare const ArticleFooter: import("@ndla/styled-system/types").StyledComponent<import("react").ForwardRefExoticComponent<Omit<import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, "ref"> & {
|
|
39
26
|
ref?: ((instance: HTMLElement | null) => void) | import("react").RefObject<HTMLElement> | null | undefined;
|
|
40
|
-
} & import("@ark-ui/react").PolymorphicProps>, {
|
|
41
|
-
padded?: boolean | undefined;
|
|
42
|
-
}>;
|
|
27
|
+
} & import("@ark-ui/react").PolymorphicProps>, {}>;
|
|
43
28
|
interface ArticleTitleProps {
|
|
44
29
|
heartButton?: ReactNode;
|
|
45
30
|
contentType?: ContentType;
|
package/lib/Article/Article.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", {
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
|
-
exports.ArticleWrapper = exports.ArticleTitle = exports.
|
|
6
|
+
exports.ArticleWrapper = exports.ArticleTitle = exports.ArticleHeader = exports.ArticleHGroup = exports.ArticleFooter = exports.ArticleContent = exports.Article = void 0;
|
|
7
7
|
var _react = require("react");
|
|
8
8
|
var _react2 = require("@ark-ui/react");
|
|
9
9
|
var _primitives = require("@ndla/primitives");
|
|
@@ -20,57 +20,7 @@ var _jsxRuntime = require("react/jsx-runtime");
|
|
|
20
20
|
*
|
|
21
21
|
*/
|
|
22
22
|
|
|
23
|
-
const
|
|
24
|
-
paddingInline: "8%"
|
|
25
|
-
};
|
|
26
|
-
const paddingBlockEnd = {
|
|
27
|
-
paddingBlockEnd: "xsmall",
|
|
28
|
-
tablet: {
|
|
29
|
-
paddingBlockEnd: "medium"
|
|
30
|
-
},
|
|
31
|
-
desktop: {
|
|
32
|
-
paddingBlockEnd: "xxlarge"
|
|
33
|
-
}
|
|
34
|
-
};
|
|
35
|
-
const paddingBlockStart = {
|
|
36
|
-
paddingBlockStart: "xsmall",
|
|
37
|
-
tablet: {
|
|
38
|
-
paddingBlockStart: "medium"
|
|
39
|
-
},
|
|
40
|
-
desktop: {
|
|
41
|
-
paddingBlockStart: "xxlarge"
|
|
42
|
-
}
|
|
43
|
-
};
|
|
44
|
-
const ArticlePadding = exports.ArticlePadding = (0, _jsx2.styled)(_react2.ark.div, {
|
|
45
|
-
base: {
|
|
46
|
-
...articlePadding,
|
|
47
|
-
width: "100%"
|
|
48
|
-
},
|
|
49
|
-
variants: {
|
|
50
|
-
padStart: {
|
|
51
|
-
true: paddingBlockStart
|
|
52
|
-
},
|
|
53
|
-
padEnd: {
|
|
54
|
-
true: paddingBlockEnd
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
}, {
|
|
58
|
-
baseComponent: true
|
|
59
|
-
});
|
|
60
|
-
const StyledArticleContent = (0, _jsx2.styled)(_react2.ark.section, {
|
|
61
|
-
base: {
|
|
62
|
-
background: "surface.default"
|
|
63
|
-
},
|
|
64
|
-
variants: {
|
|
65
|
-
padded: {
|
|
66
|
-
true: {
|
|
67
|
-
...articlePadding,
|
|
68
|
-
...paddingBlockStart,
|
|
69
|
-
...paddingBlockEnd
|
|
70
|
-
}
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
}, {
|
|
23
|
+
const StyledArticleContent = (0, _jsx2.styled)(_react2.ark.section, {}, {
|
|
74
24
|
baseComponent: true
|
|
75
25
|
});
|
|
76
26
|
const ArticleContent = exports.ArticleContent = /*#__PURE__*/(0, _react.forwardRef)((_ref, ref) => {
|
|
@@ -86,8 +36,10 @@ const ArticleContent = exports.ArticleContent = /*#__PURE__*/(0, _react.forwardR
|
|
|
86
36
|
});
|
|
87
37
|
const StyledArticleWrapper = (0, _jsx2.styled)(_react2.ark.article, {
|
|
88
38
|
base: {
|
|
39
|
+
background: "background.default",
|
|
89
40
|
display: "flex",
|
|
90
41
|
flexDirection: "column",
|
|
42
|
+
gap: "xxlarge",
|
|
91
43
|
color: "text.default",
|
|
92
44
|
alignItems: "center",
|
|
93
45
|
width: "100%",
|
|
@@ -116,7 +68,6 @@ const ArticleHGroup = exports.ArticleHGroup = (0, _jsx2.styled)(_react2.ark.hgro
|
|
|
116
68
|
width: "100%",
|
|
117
69
|
flexDirection: "column",
|
|
118
70
|
alignItems: "flex-start",
|
|
119
|
-
gap: "xsmall",
|
|
120
71
|
"& h1": {
|
|
121
72
|
overflowWrap: "anywhere"
|
|
122
73
|
}
|
|
@@ -124,37 +75,14 @@ const ArticleHGroup = exports.ArticleHGroup = (0, _jsx2.styled)(_react2.ark.hgro
|
|
|
124
75
|
}, {
|
|
125
76
|
baseComponent: true
|
|
126
77
|
});
|
|
127
|
-
const ArticleActionWrapper = exports.ArticleActionWrapper = (0, _jsx2.styled)(_react2.ark.div, {
|
|
128
|
-
base: {
|
|
129
|
-
position: "absolute",
|
|
130
|
-
right: "8%",
|
|
131
|
-
top: "xsmall",
|
|
132
|
-
tablet: {
|
|
133
|
-
top: "medium"
|
|
134
|
-
},
|
|
135
|
-
desktop: {
|
|
136
|
-
top: "xxlarge"
|
|
137
|
-
}
|
|
138
|
-
}
|
|
139
|
-
}, {
|
|
140
|
-
baseComponent: true
|
|
141
|
-
});
|
|
142
78
|
const ArticleHeader = exports.ArticleHeader = (0, _jsx2.styled)(_react2.ark.header, {
|
|
143
79
|
base: {
|
|
144
80
|
display: "flex",
|
|
145
81
|
flexDirection: "column",
|
|
146
|
-
background: "surface.default",
|
|
147
82
|
gap: "medium",
|
|
148
83
|
alignItems: "flex-start",
|
|
149
|
-
width: "100%"
|
|
150
|
-
|
|
151
|
-
variants: {
|
|
152
|
-
padded: {
|
|
153
|
-
true: {
|
|
154
|
-
...articlePadding,
|
|
155
|
-
...paddingBlockStart
|
|
156
|
-
}
|
|
157
|
-
}
|
|
84
|
+
width: "100%",
|
|
85
|
+
paddingBlockStart: "xxlarge"
|
|
158
86
|
}
|
|
159
87
|
}, {
|
|
160
88
|
baseComponent: true
|
|
@@ -163,21 +91,20 @@ const ArticleFooter = exports.ArticleFooter = (0, _jsx2.styled)(_react2.ark.foot
|
|
|
163
91
|
base: {
|
|
164
92
|
display: "flex",
|
|
165
93
|
flexDirection: "column",
|
|
166
|
-
background: "surface.default",
|
|
167
94
|
gap: "xxlarge",
|
|
168
|
-
width: "100%"
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
padded: {
|
|
172
|
-
true: {
|
|
173
|
-
...articlePadding,
|
|
174
|
-
...paddingBlockEnd
|
|
175
|
-
}
|
|
95
|
+
width: "100%",
|
|
96
|
+
"& > :is(:last-child)": {
|
|
97
|
+
paddingBlockEnd: "5xlarge"
|
|
176
98
|
}
|
|
177
99
|
}
|
|
178
100
|
}, {
|
|
179
101
|
baseComponent: true
|
|
180
102
|
});
|
|
103
|
+
const StyledStack = (0, _jsx2.styled)(_jsx2.Stack, {
|
|
104
|
+
base: {
|
|
105
|
+
width: "100%"
|
|
106
|
+
}
|
|
107
|
+
});
|
|
181
108
|
const ArticleTitle = _ref2 => {
|
|
182
109
|
let {
|
|
183
110
|
contentType,
|
|
@@ -189,12 +116,15 @@ const ArticleTitle = _ref2 => {
|
|
|
189
116
|
competenceGoals
|
|
190
117
|
} = _ref2;
|
|
191
118
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(ArticleHeader, {
|
|
192
|
-
padded: true,
|
|
193
119
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(ArticleHGroup, {
|
|
194
|
-
children: [
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
120
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsxs)(StyledStack, {
|
|
121
|
+
justify: "space-between",
|
|
122
|
+
align: "center",
|
|
123
|
+
direction: "row",
|
|
124
|
+
gap: "small",
|
|
125
|
+
children: [!!contentType && /*#__PURE__*/(0, _jsxRuntime.jsx)(_.ContentTypeBadgeNew, {
|
|
126
|
+
contentType: contentType
|
|
127
|
+
}), heartButton]
|
|
198
128
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_primitives.Heading, {
|
|
199
129
|
textStyle: "heading.large",
|
|
200
130
|
id: id,
|
|
@@ -243,10 +173,8 @@ const Article = _ref3 => {
|
|
|
243
173
|
competenceGoals: competenceGoals,
|
|
244
174
|
lang: lang
|
|
245
175
|
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(ArticleContent, {
|
|
246
|
-
padded: true,
|
|
247
176
|
children: content
|
|
248
177
|
}), /*#__PURE__*/(0, _jsxRuntime.jsxs)(ArticleFooter, {
|
|
249
|
-
padded: true,
|
|
250
178
|
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_ArticleByline.ArticleByline, {
|
|
251
179
|
footnotes: footNotes,
|
|
252
180
|
authors: authors,
|
package/lib/Article/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
* LICENSE file in the root directory of this source tree.
|
|
6
6
|
*
|
|
7
7
|
*/
|
|
8
|
-
export { Article, ArticleWrapper, ArticleHeader, ArticleFooter, ArticleTitle,
|
|
8
|
+
export { Article, ArticleWrapper, ArticleHeader, ArticleFooter, ArticleTitle, ArticleHGroup, ArticleContent, } from "./Article";
|
|
9
9
|
export { ArticleByline, ArticleBylineAccordionItem } from "./ArticleByline";
|
|
10
10
|
export { ArticleFootNotes } from "./ArticleFootNotes";
|
|
11
11
|
export { ArticleParagraph } from "./ArticleParagraph";
|
package/lib/Article/index.js
CHANGED
|
@@ -9,12 +9,6 @@ Object.defineProperty(exports, "Article", {
|
|
|
9
9
|
return _Article.Article;
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
Object.defineProperty(exports, "ArticleActionWrapper", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _Article.ArticleActionWrapper;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
12
|
Object.defineProperty(exports, "ArticleByline", {
|
|
19
13
|
enumerable: true,
|
|
20
14
|
get: function () {
|
|
@@ -57,12 +51,6 @@ Object.defineProperty(exports, "ArticleHeader", {
|
|
|
57
51
|
return _Article.ArticleHeader;
|
|
58
52
|
}
|
|
59
53
|
});
|
|
60
|
-
Object.defineProperty(exports, "ArticlePadding", {
|
|
61
|
-
enumerable: true,
|
|
62
|
-
get: function () {
|
|
63
|
-
return _Article.ArticlePadding;
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
54
|
Object.defineProperty(exports, "ArticleParagraph", {
|
|
67
55
|
enumerable: true,
|
|
68
56
|
get: function () {
|
|
@@ -22,7 +22,9 @@ function _interopRequireDefault(e) { return e && e.__esModule ? e : { default: e
|
|
|
22
22
|
|
|
23
23
|
const Container = (0, _jsx2.styled)("div", {
|
|
24
24
|
base: {
|
|
25
|
+
width: "100%",
|
|
25
26
|
display: "flex",
|
|
27
|
+
gap: "medium",
|
|
26
28
|
flexDirection: "column",
|
|
27
29
|
border: "1px solid",
|
|
28
30
|
borderColor: "stroke.default",
|
|
@@ -41,6 +43,17 @@ const LinkText = (0, _jsx2.styled)(_primitives.Text, {
|
|
|
41
43
|
display: "flex",
|
|
42
44
|
gap: "xxsmall",
|
|
43
45
|
textDecoration: "underline",
|
|
46
|
+
_hover: {
|
|
47
|
+
textDecoration: "none"
|
|
48
|
+
},
|
|
49
|
+
paddingBlock: "xsmall",
|
|
50
|
+
fontWeight: "bold"
|
|
51
|
+
}
|
|
52
|
+
});
|
|
53
|
+
const LinkHeader = (0, _jsx2.styled)(_primitives.Text, {
|
|
54
|
+
base: {
|
|
55
|
+
display: "flex",
|
|
56
|
+
textDecoration: "underline",
|
|
44
57
|
_hover: {
|
|
45
58
|
textDecoration: "none"
|
|
46
59
|
}
|
|
@@ -52,8 +65,11 @@ const StyledImg = (0, _jsx2.styled)("img", {
|
|
|
52
65
|
objectFit: "cover",
|
|
53
66
|
width: "100%",
|
|
54
67
|
height: "215px",
|
|
55
|
-
|
|
68
|
+
mobileWide: {
|
|
56
69
|
height: "340px"
|
|
70
|
+
},
|
|
71
|
+
tabletWide: {
|
|
72
|
+
width: "auto"
|
|
57
73
|
}
|
|
58
74
|
}
|
|
59
75
|
});
|
|
@@ -63,12 +79,24 @@ const ContentWrapper = (0, _jsx2.styled)("div", {
|
|
|
63
79
|
position: "relative",
|
|
64
80
|
display: "flex",
|
|
65
81
|
flexDirection: "column",
|
|
66
|
-
gap: "
|
|
82
|
+
gap: "medium",
|
|
67
83
|
alignItems: "flex-start",
|
|
84
|
+
justifyContent: "center",
|
|
68
85
|
paddingBlock: "medium",
|
|
69
86
|
paddingInline: "medium"
|
|
70
87
|
}
|
|
71
88
|
});
|
|
89
|
+
const StyledText = (0, _jsx2.styled)(_primitives.Text, {
|
|
90
|
+
base: {
|
|
91
|
+
tabletWide: {
|
|
92
|
+
display: "block",
|
|
93
|
+
overflow: "hidden",
|
|
94
|
+
position: "relative",
|
|
95
|
+
lineClamp: 4,
|
|
96
|
+
boxOrient: "vertical"
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
});
|
|
72
100
|
const StyledSafeLink = (0, _jsx2.styled)(_safelink.SafeLink, {
|
|
73
101
|
base: {
|
|
74
102
|
color: "inherit"
|
|
@@ -103,7 +131,7 @@ const CampaignBlock = _ref2 => {
|
|
|
103
131
|
width: 455,
|
|
104
132
|
alt: image.alt
|
|
105
133
|
});
|
|
106
|
-
const HeaderComponent = url?.url ?
|
|
134
|
+
const HeaderComponent = url?.url ? LinkHeader : _primitives.Text;
|
|
107
135
|
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(Container, {
|
|
108
136
|
className: className,
|
|
109
137
|
"data-embed-type": "campaign-block",
|
|
@@ -119,8 +147,8 @@ const CampaignBlock = _ref2 => {
|
|
|
119
147
|
children: (0, _htmlReactParser.default)(title)
|
|
120
148
|
})
|
|
121
149
|
})
|
|
122
|
-
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(
|
|
123
|
-
textStyle: "body.
|
|
150
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(StyledText, {
|
|
151
|
+
textStyle: "body.xlarge",
|
|
124
152
|
children: (0, _htmlReactParser.default)(description)
|
|
125
153
|
}), !!url?.url && /*#__PURE__*/(0, _jsxRuntime.jsx)(MaybeLinkText, {
|
|
126
154
|
url: url.url,
|
package/lib/index.d.ts
CHANGED
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
*/
|
|
8
8
|
export { ImageEmbed, getCrop, getFocalPoint, AudioEmbed, H5pEmbed, ExternalEmbed, IframeEmbed, FootnoteEmbed, BrightcoveEmbed, ContentLinkEmbed, RelatedContentEmbed, ConceptEmbed, ConceptListEmbed, UnknownEmbed, InlineConcept, BlockConcept, UuDisclaimerEmbed, CopyrightEmbed, CodeEmbed, } from "./Embed";
|
|
9
9
|
export { LicenseLink, EmbedByline } from "./LicenseByline";
|
|
10
|
-
export { ArticleByline, ArticleBylineAccordionItem, ArticleFootNotes, ArticleWrapper, Article, ArticleParagraph, ArticleFooter, ArticleHeader, ArticleContent, ArticleHGroup,
|
|
10
|
+
export { ArticleByline, ArticleBylineAccordionItem, ArticleFootNotes, ArticleWrapper, Article, ArticleParagraph, ArticleFooter, ArticleHeader, ArticleContent, ArticleHGroup, ArticleTitle, } from "./Article";
|
|
11
11
|
export { getPossiblyRelativeUrl } from "./utils/relativeUrl";
|
|
12
12
|
export { default as ContentLoader } from "./ContentLoader";
|
|
13
13
|
export { default as RelatedArticleList, RelatedArticle } from "./RelatedArticleList";
|
package/lib/index.js
CHANGED
|
@@ -9,12 +9,6 @@ Object.defineProperty(exports, "Article", {
|
|
|
9
9
|
return _Article.Article;
|
|
10
10
|
}
|
|
11
11
|
});
|
|
12
|
-
Object.defineProperty(exports, "ArticleActionWrapper", {
|
|
13
|
-
enumerable: true,
|
|
14
|
-
get: function () {
|
|
15
|
-
return _Article.ArticleActionWrapper;
|
|
16
|
-
}
|
|
17
|
-
});
|
|
18
12
|
Object.defineProperty(exports, "ArticleByline", {
|
|
19
13
|
enumerable: true,
|
|
20
14
|
get: function () {
|
|
@@ -57,12 +51,6 @@ Object.defineProperty(exports, "ArticleHeader", {
|
|
|
57
51
|
return _Article.ArticleHeader;
|
|
58
52
|
}
|
|
59
53
|
});
|
|
60
|
-
Object.defineProperty(exports, "ArticlePadding", {
|
|
61
|
-
enumerable: true,
|
|
62
|
-
get: function () {
|
|
63
|
-
return _Article.ArticlePadding;
|
|
64
|
-
}
|
|
65
|
-
});
|
|
66
54
|
Object.defineProperty(exports, "ArticleParagraph", {
|
|
67
55
|
enumerable: true,
|
|
68
56
|
get: function () {
|
|
@@ -1075,9 +1075,9 @@ const messages = {
|
|
|
1075
1075
|
},
|
|
1076
1076
|
fetchMore: "Fetch more answers",
|
|
1077
1077
|
deleted: "This post has been deleted by the author.",
|
|
1078
|
-
upvote: "
|
|
1078
|
+
upvote: "Like",
|
|
1079
1079
|
numberOfUpvotes: "{{ count }} people have upvoted this.",
|
|
1080
|
-
removeUpvote: "
|
|
1080
|
+
removeUpvote: "Stop liking",
|
|
1081
1081
|
reply: "Write a reply to {{ name }}"
|
|
1082
1082
|
},
|
|
1083
1083
|
flag: {
|