@entur/typography 1.9.12 → 1.9.13-beta.1
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/index.d.ts +426 -22
- package/dist/styles.css +2 -24
- package/dist/typography.cjs.js +416 -0
- package/dist/typography.cjs.js.map +1 -0
- package/dist/typography.esm.js +393 -345
- package/dist/typography.esm.js.map +1 -1
- package/package.json +31 -13
- package/dist/BaseHeading.d.ts +0 -18
- package/dist/Blockquote.d.ts +0 -12
- package/dist/CodeText.d.ts +0 -16
- package/dist/EmphasizedText.d.ts +0 -20
- package/dist/Heading1.d.ts +0 -20
- package/dist/Heading2.d.ts +0 -20
- package/dist/Heading3.d.ts +0 -20
- package/dist/Heading4.d.ts +0 -20
- package/dist/Heading5.d.ts +0 -20
- package/dist/Heading6.d.ts +0 -20
- package/dist/Label.d.ts +0 -20
- package/dist/LeadParagraph.d.ts +0 -20
- package/dist/Link.d.ts +0 -22
- package/dist/ListItem.d.ts +0 -11
- package/dist/NumberedList.d.ts +0 -8
- package/dist/Paragraph.d.ts +0 -20
- package/dist/PreformattedText.d.ts +0 -16
- package/dist/SmallText.d.ts +0 -20
- package/dist/StrongText.d.ts +0 -20
- package/dist/SubLabel.d.ts +0 -20
- package/dist/SubParagraph.d.ts +0 -20
- package/dist/UnorderedList.d.ts +0 -8
- package/dist/index.js +0 -8
- package/dist/typography.cjs.development.js +0 -393
- package/dist/typography.cjs.development.js.map +0 -1
- package/dist/typography.cjs.production.min.js +0 -2
- package/dist/typography.cjs.production.min.js.map +0 -1
package/dist/typography.esm.js
CHANGED
|
@@ -1,368 +1,416 @@
|
|
|
1
|
-
import { warnAboutMissingStyles } from
|
|
2
|
-
import
|
|
3
|
-
import classNames from
|
|
4
|
-
import { ExternalIcon } from
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
1
|
+
import { warnAboutMissingStyles } from "@entur/utils";
|
|
2
|
+
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
3
|
+
import classNames from "classnames";
|
|
4
|
+
import { ExternalIcon } from "@entur/icons";
|
|
5
|
+
const Blockquote = ({ className, ref, ...rest }) => {
|
|
6
|
+
return /* @__PURE__ */ jsx(
|
|
7
|
+
"blockquote",
|
|
8
|
+
{
|
|
9
|
+
className: classNames("eds-blockquote", className),
|
|
10
|
+
ref,
|
|
11
|
+
...rest
|
|
11
12
|
}
|
|
12
|
-
|
|
13
|
-
}, _extends.apply(null, arguments);
|
|
14
|
-
}
|
|
15
|
-
function _objectWithoutPropertiesLoose(r, e) {
|
|
16
|
-
if (null == r) return {};
|
|
17
|
-
var t = {};
|
|
18
|
-
for (var n in r) if ({}.hasOwnProperty.call(r, n)) {
|
|
19
|
-
if (e.includes(n)) continue;
|
|
20
|
-
t[n] = r[n];
|
|
21
|
-
}
|
|
22
|
-
return t;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
var _excluded$l = ["className", "ref"],
|
|
26
|
-
_excluded2 = ["className"];
|
|
27
|
-
var Blockquote = function Blockquote(_ref) {
|
|
28
|
-
var className = _ref.className,
|
|
29
|
-
ref = _ref.ref,
|
|
30
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$l);
|
|
31
|
-
return React.createElement("blockquote", _extends({
|
|
32
|
-
className: classNames('eds-blockquote', className),
|
|
33
|
-
ref: ref
|
|
34
|
-
}, rest));
|
|
35
|
-
};
|
|
36
|
-
var BlockquoteFooter = function BlockquoteFooter(_ref2) {
|
|
37
|
-
var className = _ref2.className,
|
|
38
|
-
rest = _objectWithoutPropertiesLoose(_ref2, _excluded2);
|
|
39
|
-
return React.createElement("footer", _extends({
|
|
40
|
-
className: classNames('eds-blockquote__footer', className)
|
|
41
|
-
}, rest));
|
|
13
|
+
);
|
|
42
14
|
};
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
return React.createElement(Element, _extends({
|
|
52
|
-
className: classNames('eds-code-text', className)
|
|
53
|
-
}, rest));
|
|
54
|
-
};
|
|
55
|
-
|
|
56
|
-
var _excluded$j = ["className", "margin", "as"];
|
|
57
|
-
var defaultElement$g = 'em';
|
|
58
|
-
var EmphasizedText = function EmphasizedText(_ref) {
|
|
59
|
-
var _classNames;
|
|
60
|
-
var className = _ref.className,
|
|
61
|
-
_ref$margin = _ref.margin,
|
|
62
|
-
margin = _ref$margin === void 0 ? 'both' : _ref$margin,
|
|
63
|
-
as = _ref.as,
|
|
64
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$j);
|
|
65
|
-
var Element = as || defaultElement$g;
|
|
66
|
-
return React.createElement(Element, _extends({
|
|
67
|
-
className: classNames('eds-emphasized-text', (_classNames = {}, _classNames["eds-emphasized-text--margin-top"] = margin === 'top', _classNames["eds-emphasized-text--margin-bottom"] = margin === 'bottom', _classNames["eds-emphasized-text--margin-none"] = margin === 'none', _classNames), className)
|
|
68
|
-
}, rest));
|
|
15
|
+
const BlockquoteFooter = ({ className, ...rest }) => {
|
|
16
|
+
return /* @__PURE__ */ jsx(
|
|
17
|
+
"footer",
|
|
18
|
+
{
|
|
19
|
+
className: classNames("eds-blockquote__footer", className),
|
|
20
|
+
...rest
|
|
21
|
+
}
|
|
22
|
+
);
|
|
69
23
|
};
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
as = _ref.as,
|
|
79
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$i);
|
|
80
|
-
var Element = as || defaultElement$f;
|
|
81
|
-
var baseClass = "eds-h" + level;
|
|
82
|
-
return React.createElement(Element, _extends({
|
|
83
|
-
className: classNames(baseClass, (_classNames = {}, _classNames[baseClass + "--margin-top"] = margin === 'top', _classNames[baseClass + "--margin-bottom"] = margin === 'bottom', _classNames[baseClass + "--margin-none"] = margin === 'none', _classNames), className)
|
|
84
|
-
}, rest));
|
|
24
|
+
const defaultElement$h = "code";
|
|
25
|
+
const CodeText = ({
|
|
26
|
+
className,
|
|
27
|
+
as,
|
|
28
|
+
...rest
|
|
29
|
+
}) => {
|
|
30
|
+
const Element = as || defaultElement$h;
|
|
31
|
+
return /* @__PURE__ */ jsx(Element, { className: classNames("eds-code-text", className), ...rest });
|
|
85
32
|
};
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
33
|
+
const defaultElement$g = "em";
|
|
34
|
+
const EmphasizedText = ({
|
|
35
|
+
className,
|
|
36
|
+
margin = "both",
|
|
37
|
+
as,
|
|
38
|
+
...rest
|
|
39
|
+
}) => {
|
|
40
|
+
const Element = as || defaultElement$g;
|
|
41
|
+
return /* @__PURE__ */ jsx(
|
|
42
|
+
Element,
|
|
43
|
+
{
|
|
44
|
+
className: classNames(
|
|
45
|
+
"eds-emphasized-text",
|
|
46
|
+
{
|
|
47
|
+
[`eds-emphasized-text--margin-top`]: margin === "top",
|
|
48
|
+
[`eds-emphasized-text--margin-bottom`]: margin === "bottom",
|
|
49
|
+
[`eds-emphasized-text--margin-none`]: margin === "none"
|
|
50
|
+
},
|
|
51
|
+
className
|
|
52
|
+
),
|
|
53
|
+
...rest
|
|
54
|
+
}
|
|
55
|
+
);
|
|
102
56
|
};
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
return
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
57
|
+
const defaultElement$f = "h1";
|
|
58
|
+
const BaseHeading = ({
|
|
59
|
+
className,
|
|
60
|
+
level,
|
|
61
|
+
margin,
|
|
62
|
+
as,
|
|
63
|
+
...rest
|
|
64
|
+
}) => {
|
|
65
|
+
const Element = as || defaultElement$f;
|
|
66
|
+
const baseClass = `eds-h${level}`;
|
|
67
|
+
return /* @__PURE__ */ jsx(
|
|
68
|
+
Element,
|
|
69
|
+
{
|
|
70
|
+
className: classNames(
|
|
71
|
+
baseClass,
|
|
72
|
+
{
|
|
73
|
+
[`${baseClass}--margin-top`]: margin === "top",
|
|
74
|
+
[`${baseClass}--margin-bottom`]: margin === "bottom",
|
|
75
|
+
[`${baseClass}--margin-none`]: margin === "none"
|
|
76
|
+
},
|
|
77
|
+
className
|
|
78
|
+
),
|
|
79
|
+
...rest
|
|
80
|
+
}
|
|
81
|
+
);
|
|
119
82
|
};
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
var Element = as || defaultElement$c;
|
|
130
|
-
return React.createElement(BaseHeading, _extends({
|
|
131
|
-
as: Element,
|
|
132
|
-
margin: margin
|
|
133
|
-
}, rest, {
|
|
134
|
-
level: 3
|
|
135
|
-
}), children);
|
|
83
|
+
const defaultElement$e = "h1";
|
|
84
|
+
const Heading1 = ({
|
|
85
|
+
margin = "both",
|
|
86
|
+
children,
|
|
87
|
+
as,
|
|
88
|
+
...rest
|
|
89
|
+
}) => {
|
|
90
|
+
const Element = as || defaultElement$e;
|
|
91
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 1, children });
|
|
136
92
|
};
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
var Element = as || defaultElement$b;
|
|
147
|
-
return React.createElement(BaseHeading, _extends({
|
|
148
|
-
as: Element,
|
|
149
|
-
margin: margin
|
|
150
|
-
}, rest, {
|
|
151
|
-
level: 4
|
|
152
|
-
}), children);
|
|
93
|
+
const defaultElement$d = "h2";
|
|
94
|
+
const Heading2 = ({
|
|
95
|
+
margin = "both",
|
|
96
|
+
children,
|
|
97
|
+
as,
|
|
98
|
+
...rest
|
|
99
|
+
}) => {
|
|
100
|
+
const Element = as || defaultElement$d;
|
|
101
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 2, children });
|
|
153
102
|
};
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
var Element = as || defaultElement$a;
|
|
164
|
-
return React.createElement(BaseHeading, _extends({
|
|
165
|
-
as: Element,
|
|
166
|
-
margin: margin
|
|
167
|
-
}, rest, {
|
|
168
|
-
level: 5
|
|
169
|
-
}), children);
|
|
103
|
+
const defaultElement$c = "h3";
|
|
104
|
+
const Heading3 = ({
|
|
105
|
+
margin = "both",
|
|
106
|
+
children,
|
|
107
|
+
as,
|
|
108
|
+
...rest
|
|
109
|
+
}) => {
|
|
110
|
+
const Element = as || defaultElement$c;
|
|
111
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 3, children });
|
|
170
112
|
};
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
var Element = as || defaultElement$9;
|
|
181
|
-
return React.createElement(BaseHeading, _extends({
|
|
182
|
-
as: Element,
|
|
183
|
-
margin: margin
|
|
184
|
-
}, rest, {
|
|
185
|
-
level: 6
|
|
186
|
-
}), children);
|
|
113
|
+
const defaultElement$b = "h4";
|
|
114
|
+
const Heading4 = ({
|
|
115
|
+
margin = "both",
|
|
116
|
+
children,
|
|
117
|
+
as,
|
|
118
|
+
...rest
|
|
119
|
+
}) => {
|
|
120
|
+
const Element = as || defaultElement$b;
|
|
121
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 4, children });
|
|
187
122
|
};
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$b);
|
|
198
|
-
var Element = as || defaultElement$8;
|
|
199
|
-
return React.createElement(Element, _extends({
|
|
200
|
-
className: classNames('eds-label', (_classNames = {}, _classNames["eds-label--margin-top"] = margin === 'top', _classNames["eds-label--margin-bottom"] = margin === 'bottom', _classNames["eds-label--margin-none"] = margin === 'none', _classNames), className)
|
|
201
|
-
}, rest));
|
|
123
|
+
const defaultElement$a = "h5";
|
|
124
|
+
const Heading5 = ({
|
|
125
|
+
margin = "both",
|
|
126
|
+
children,
|
|
127
|
+
as,
|
|
128
|
+
...rest
|
|
129
|
+
}) => {
|
|
130
|
+
const Element = as || defaultElement$a;
|
|
131
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 5, children });
|
|
202
132
|
};
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
rest = _objectWithoutPropertiesLoose(_ref, _excluded$a);
|
|
213
|
-
var Element = as || defaultElement$7;
|
|
214
|
-
return React.createElement(Element, _extends({
|
|
215
|
-
className: classNames('eds-lead-paragraph', (_classNames = {}, _classNames["eds-lead-paragraph--margin-top"] = margin === 'top', _classNames["eds-lead-paragraph--margin-bottom"] = margin === 'bottom', _classNames["eds-lead-paragraph--margin-none"] = margin === 'none', _classNames), className)
|
|
216
|
-
}, rest));
|
|
133
|
+
const defaultElement$9 = "h6";
|
|
134
|
+
const Heading6 = ({
|
|
135
|
+
margin = "both",
|
|
136
|
+
children,
|
|
137
|
+
as,
|
|
138
|
+
...rest
|
|
139
|
+
}) => {
|
|
140
|
+
const Element = as || defaultElement$9;
|
|
141
|
+
return /* @__PURE__ */ jsx(BaseHeading, { as: Element, margin, ...rest, level: 6, children });
|
|
217
142
|
};
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
143
|
+
const defaultElement$8 = "label";
|
|
144
|
+
const Label = ({
|
|
145
|
+
className,
|
|
146
|
+
margin = "both",
|
|
147
|
+
as,
|
|
148
|
+
...rest
|
|
149
|
+
}) => {
|
|
150
|
+
const Element = as || defaultElement$8;
|
|
151
|
+
return /* @__PURE__ */ jsx(
|
|
152
|
+
Element,
|
|
153
|
+
{
|
|
154
|
+
className: classNames(
|
|
155
|
+
"eds-label",
|
|
156
|
+
{
|
|
157
|
+
[`eds-label--margin-top`]: margin === "top",
|
|
158
|
+
[`eds-label--margin-bottom`]: margin === "bottom",
|
|
159
|
+
[`eds-label--margin-none`]: margin === "none"
|
|
160
|
+
},
|
|
161
|
+
className
|
|
162
|
+
),
|
|
163
|
+
...rest
|
|
164
|
+
}
|
|
165
|
+
);
|
|
240
166
|
};
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
167
|
+
const defaultElement$7 = "p";
|
|
168
|
+
const LeadParagraph = ({
|
|
169
|
+
className,
|
|
170
|
+
margin = "both",
|
|
171
|
+
as,
|
|
172
|
+
...rest
|
|
173
|
+
}) => {
|
|
174
|
+
const Element = as || defaultElement$7;
|
|
175
|
+
return /* @__PURE__ */ jsx(
|
|
176
|
+
Element,
|
|
177
|
+
{
|
|
178
|
+
className: classNames(
|
|
179
|
+
"eds-lead-paragraph",
|
|
180
|
+
{
|
|
181
|
+
[`eds-lead-paragraph--margin-top`]: margin === "top",
|
|
182
|
+
[`eds-lead-paragraph--margin-bottom`]: margin === "bottom",
|
|
183
|
+
[`eds-lead-paragraph--margin-none`]: margin === "none"
|
|
184
|
+
},
|
|
185
|
+
className
|
|
186
|
+
),
|
|
187
|
+
...rest
|
|
188
|
+
}
|
|
189
|
+
);
|
|
255
190
|
};
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
191
|
+
const defaultElement$6 = "a";
|
|
192
|
+
const Link = ({
|
|
193
|
+
external = false,
|
|
194
|
+
ariaLabelExternalIcon = "(ekstern lenke)",
|
|
195
|
+
className,
|
|
196
|
+
margin = "both",
|
|
197
|
+
children,
|
|
198
|
+
as,
|
|
199
|
+
...rest
|
|
200
|
+
}) => {
|
|
201
|
+
const Element = as || defaultElement$6;
|
|
202
|
+
return /* @__PURE__ */ jsxs(
|
|
203
|
+
Element,
|
|
204
|
+
{
|
|
205
|
+
className: classNames(
|
|
206
|
+
"eds-link",
|
|
207
|
+
{
|
|
208
|
+
[`eds-link--margin-top`]: margin === "top",
|
|
209
|
+
[`eds-link--margin-bottom`]: margin === "bottom",
|
|
210
|
+
[`eds-link--margin-none`]: margin === "none"
|
|
211
|
+
},
|
|
212
|
+
className
|
|
213
|
+
),
|
|
214
|
+
...rest,
|
|
215
|
+
children: [
|
|
216
|
+
children,
|
|
217
|
+
external ? /* @__PURE__ */ jsx(
|
|
218
|
+
ExternalIcon,
|
|
219
|
+
{
|
|
220
|
+
className: "eds-link--ext-icon",
|
|
221
|
+
"aria-label": ariaLabelExternalIcon
|
|
222
|
+
}
|
|
223
|
+
) : /* @__PURE__ */ jsx(Fragment, {})
|
|
224
|
+
]
|
|
225
|
+
}
|
|
226
|
+
);
|
|
268
227
|
};
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
return
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
228
|
+
const defaultElement$5 = "strong";
|
|
229
|
+
const StrongText = ({
|
|
230
|
+
className,
|
|
231
|
+
margin = "both",
|
|
232
|
+
as,
|
|
233
|
+
...rest
|
|
234
|
+
}) => {
|
|
235
|
+
const Element = as || defaultElement$5;
|
|
236
|
+
return /* @__PURE__ */ jsx(
|
|
237
|
+
Element,
|
|
238
|
+
{
|
|
239
|
+
className: classNames(
|
|
240
|
+
"eds-strong-text",
|
|
241
|
+
{
|
|
242
|
+
[`eds-strong-text--margin-top`]: margin === "top",
|
|
243
|
+
[`eds-strong-text--margin-bottom`]: margin === "bottom",
|
|
244
|
+
[`eds-strong-text--margin-none`]: margin === "none"
|
|
245
|
+
},
|
|
246
|
+
className
|
|
247
|
+
),
|
|
248
|
+
...rest
|
|
249
|
+
}
|
|
250
|
+
);
|
|
281
251
|
};
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
252
|
+
const ListItem = ({
|
|
253
|
+
children,
|
|
254
|
+
className,
|
|
255
|
+
title,
|
|
256
|
+
...rest
|
|
257
|
+
}) => /* @__PURE__ */ jsxs("li", { className: classNames("eds-list-item", className), ...rest, children: [
|
|
258
|
+
title && /* @__PURE__ */ jsx(StrongText, { className: "eds-list-item__title", children: title }),
|
|
259
|
+
children
|
|
260
|
+
] });
|
|
261
|
+
const NumberedList = ({
|
|
262
|
+
className,
|
|
263
|
+
type = "1",
|
|
264
|
+
...rest
|
|
265
|
+
}) => /* @__PURE__ */ jsx(
|
|
266
|
+
"ol",
|
|
267
|
+
{
|
|
268
|
+
className: classNames(
|
|
269
|
+
"eds-numbered-list",
|
|
270
|
+
{ [`eds-numbered-list--type-${type}`]: type },
|
|
271
|
+
className
|
|
272
|
+
),
|
|
273
|
+
type,
|
|
274
|
+
...rest
|
|
275
|
+
}
|
|
276
|
+
);
|
|
277
|
+
const defaultElement$4 = "p";
|
|
278
|
+
const Paragraph = ({
|
|
279
|
+
margin = "bottom",
|
|
280
|
+
className,
|
|
281
|
+
as,
|
|
282
|
+
...rest
|
|
283
|
+
}) => {
|
|
284
|
+
const Element = as || defaultElement$4;
|
|
285
|
+
return /* @__PURE__ */ jsx(
|
|
286
|
+
Element,
|
|
287
|
+
{
|
|
288
|
+
className: classNames(
|
|
289
|
+
"eds-paragraph",
|
|
290
|
+
{
|
|
291
|
+
"eds-paragraph--margin-bottom": margin === "bottom",
|
|
292
|
+
"eds-paragraph--margin-none": margin === "none"
|
|
293
|
+
},
|
|
294
|
+
className
|
|
295
|
+
),
|
|
296
|
+
...rest
|
|
297
|
+
}
|
|
298
|
+
);
|
|
298
299
|
};
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
300
|
+
const defaultElement$3 = "pre";
|
|
301
|
+
const PreformattedText = ({
|
|
302
|
+
className,
|
|
303
|
+
as,
|
|
304
|
+
...rest
|
|
305
|
+
}) => {
|
|
306
|
+
const Element = as || defaultElement$3;
|
|
307
|
+
return /* @__PURE__ */ jsx(
|
|
308
|
+
Element,
|
|
309
|
+
{
|
|
310
|
+
className: classNames("eds-preformatted-text", className),
|
|
311
|
+
...rest
|
|
312
|
+
}
|
|
313
|
+
);
|
|
310
314
|
};
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
315
|
+
const defaultElement$2 = "span";
|
|
316
|
+
const SmallText = ({
|
|
317
|
+
className,
|
|
318
|
+
margin = "both",
|
|
319
|
+
as,
|
|
320
|
+
...rest
|
|
321
|
+
}) => {
|
|
322
|
+
const Element = as || defaultElement$2;
|
|
323
|
+
return /* @__PURE__ */ jsx(
|
|
324
|
+
Element,
|
|
325
|
+
{
|
|
326
|
+
className: classNames(
|
|
327
|
+
"eds-small-text",
|
|
328
|
+
{
|
|
329
|
+
[`eds-small-text--margin-top`]: margin === "top",
|
|
330
|
+
[`eds-small-text--margin-bottom`]: margin === "bottom",
|
|
331
|
+
[`eds-small-text--margin-none`]: margin === "none"
|
|
332
|
+
},
|
|
333
|
+
className
|
|
334
|
+
),
|
|
335
|
+
...rest
|
|
336
|
+
}
|
|
337
|
+
);
|
|
325
338
|
};
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
339
|
+
const defaultElement$1 = "span";
|
|
340
|
+
const SubLabel = ({
|
|
341
|
+
className,
|
|
342
|
+
margin = "both",
|
|
343
|
+
as,
|
|
344
|
+
...rest
|
|
345
|
+
}) => {
|
|
346
|
+
const Element = as || defaultElement$1;
|
|
347
|
+
return /* @__PURE__ */ jsx(
|
|
348
|
+
Element,
|
|
349
|
+
{
|
|
350
|
+
className: classNames(
|
|
351
|
+
"eds-sub-label",
|
|
352
|
+
{
|
|
353
|
+
[`eds-sub-label--margin-top`]: margin === "top",
|
|
354
|
+
[`eds-sub-label--margin-bottom`]: margin === "bottom",
|
|
355
|
+
[`eds-sub-label--margin-none`]: margin === "none"
|
|
356
|
+
},
|
|
357
|
+
className
|
|
358
|
+
),
|
|
359
|
+
...rest
|
|
360
|
+
}
|
|
361
|
+
);
|
|
340
362
|
};
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
363
|
+
const defaultElement = "p";
|
|
364
|
+
const SubParagraph = ({
|
|
365
|
+
className,
|
|
366
|
+
margin,
|
|
367
|
+
as,
|
|
368
|
+
...rest
|
|
369
|
+
}) => {
|
|
370
|
+
const Element = as || defaultElement;
|
|
371
|
+
return /* @__PURE__ */ jsx(
|
|
372
|
+
Element,
|
|
373
|
+
{
|
|
374
|
+
className: classNames(
|
|
375
|
+
"eds-sub-paragraph",
|
|
376
|
+
{
|
|
377
|
+
[`eds-sub-paragraph--margin-top`]: margin === "top",
|
|
378
|
+
[`eds-sub-paragraph--margin-bottom`]: margin === "bottom",
|
|
379
|
+
[`eds-sub-paragraph--margin-none`]: margin === "none"
|
|
380
|
+
},
|
|
381
|
+
className
|
|
382
|
+
),
|
|
383
|
+
...rest
|
|
384
|
+
}
|
|
385
|
+
);
|
|
354
386
|
};
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
387
|
+
const UnorderedList = ({
|
|
388
|
+
className,
|
|
389
|
+
...rest
|
|
390
|
+
}) => /* @__PURE__ */ jsx("ul", { className: classNames("eds-unordered-list", className), ...rest });
|
|
391
|
+
warnAboutMissingStyles("typography");
|
|
392
|
+
export {
|
|
393
|
+
Blockquote,
|
|
394
|
+
BlockquoteFooter,
|
|
395
|
+
CodeText,
|
|
396
|
+
EmphasizedText,
|
|
397
|
+
Heading1,
|
|
398
|
+
Heading2,
|
|
399
|
+
Heading3,
|
|
400
|
+
Heading4,
|
|
401
|
+
Heading5,
|
|
402
|
+
Heading6,
|
|
403
|
+
Label,
|
|
404
|
+
LeadParagraph,
|
|
405
|
+
Link,
|
|
406
|
+
ListItem,
|
|
407
|
+
NumberedList,
|
|
408
|
+
Paragraph,
|
|
409
|
+
PreformattedText,
|
|
410
|
+
SmallText,
|
|
411
|
+
StrongText,
|
|
412
|
+
SubLabel,
|
|
413
|
+
SubParagraph,
|
|
414
|
+
UnorderedList
|
|
363
415
|
};
|
|
364
|
-
|
|
365
|
-
warnAboutMissingStyles('typography');
|
|
366
|
-
|
|
367
|
-
export { Blockquote, BlockquoteFooter, CodeText, EmphasizedText, Heading1, Heading2, Heading3, Heading4, Heading5, Heading6, Label, LeadParagraph, Link, ListItem, NumberedList, Paragraph, PreformattedText, SmallText, StrongText, SubLabel, SubParagraph, UnorderedList };
|
|
368
416
|
//# sourceMappingURL=typography.esm.js.map
|