@micromag/screen-title 0.4.70 → 0.4.74
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/index.d.ts +4 -2
- package/es/index.js +216 -276
- package/package.json +16 -15
package/es/index.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { ForwardedRef } from 'react';
|
|
3
|
+
import { HeadingElement, TextElement, BoxStyle, Label, Header, Footer, BackgroundElement, MediaElement } from '@micromag/core';
|
|
3
4
|
|
|
4
5
|
interface TitleScreenProps {
|
|
5
6
|
layout?: 'top' | 'middle' | 'bottom' | 'split' | 'split-top' | 'split-bottom';
|
|
@@ -18,9 +19,10 @@ interface TitleScreenProps {
|
|
|
18
19
|
current?: boolean;
|
|
19
20
|
active?: boolean;
|
|
20
21
|
transitionStagger?: number;
|
|
22
|
+
mediaRef?: ForwardedRef<MediaElement> | null;
|
|
21
23
|
className?: string | null;
|
|
22
24
|
}
|
|
23
|
-
declare function TitleScreen({ layout, title, subtitle, description, boxStyle, withSubtitle, withDescription, withBox, spacing, descriptionEmptyLabel, header, footer, background, current, active, className, }: TitleScreenProps): react_jsx_runtime.JSX.Element;
|
|
25
|
+
declare function TitleScreen({ layout, title, subtitle, description, boxStyle, withSubtitle, withDescription, withBox, spacing, descriptionEmptyLabel, header, footer, background, current, active, mediaRef: customMediaRef, className, }: TitleScreenProps): react_jsx_runtime.JSX.Element;
|
|
24
26
|
|
|
25
27
|
interface TitleSubtitleCreditsScreenProps {
|
|
26
28
|
credits?: TextElement | null;
|
package/es/index.js
CHANGED
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import { FormattedMessage, defineMessage } from 'react-intl';
|
|
2
|
-
import _objectSpread from '@babel/runtime/helpers/objectSpread2';
|
|
3
|
-
import _defineProperty from '@babel/runtime/helpers/defineProperty';
|
|
4
2
|
import classNames from 'classnames';
|
|
5
3
|
import { ScreenElement } from '@micromag/core/components';
|
|
6
4
|
import { useScreenSize, useScreenRenderContext, useViewerContext, useViewerWebView, usePlaybackContext, usePlaybackMediaRef } from '@micromag/core/contexts';
|
|
7
|
-
import { isTextFilled, isHeaderFilled, isFooterFilled, getFooterProps, getStyleFromBox } from '@micromag/core/utils';
|
|
5
|
+
import { isTextFilled, isHeaderFilled, isFooterFilled, getFooterProps, getStyleFromBox, mergeRefs } from '@micromag/core/utils';
|
|
8
6
|
import Background from '@micromag/element-background';
|
|
9
7
|
import Container from '@micromag/element-container';
|
|
10
8
|
import Footer from '@micromag/element-footer';
|
|
@@ -13,136 +11,124 @@ import Heading from '@micromag/element-heading';
|
|
|
13
11
|
import Layout, { Spacer } from '@micromag/element-layout';
|
|
14
12
|
import Text from '@micromag/element-text';
|
|
15
13
|
import { jsx, jsxs, Fragment } from 'react/jsx-runtime';
|
|
16
|
-
import
|
|
17
|
-
import _extends from '@babel/runtime/helpers/extends';
|
|
18
|
-
import _objectWithoutProperties from '@babel/runtime/helpers/objectWithoutProperties';
|
|
14
|
+
import { c } from 'react/compiler-runtime';
|
|
19
15
|
|
|
20
16
|
var styles = {"container":"micromag-screen-title-container","background":"micromag-screen-title-background","content":"micromag-screen-title-content","emptyTitle":"micromag-screen-title-emptyTitle","emptySubtitle":"micromag-screen-title-emptySubtitle","emptyDescription":"micromag-screen-title-emptyDescription","title":"micromag-screen-title-title","withMargin":"micromag-screen-title-withMargin","subtitle":"micromag-screen-title-subtitle","box":"micromag-screen-title-box","isPlaceholder":"micromag-screen-title-isPlaceholder","layout":"micromag-screen-title-layout"};
|
|
21
17
|
|
|
22
|
-
function TitleScreen(
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
var verticalAlign = isSplitted ? layoutParts[1] || null : layoutParts[0];
|
|
91
|
-
var titleWithMargin = hasTitle && (hasSubtitle || hasDescription) && (!isSplitted || verticalAlign === 'top');
|
|
92
|
-
var subtitleWithMargin = hasSubtitle && hasDescription && (!isSplitted || verticalAlign === 'bottom');
|
|
93
|
-
var backgroundPlaying = current && (isView || isEdit) && (isCurrentMedia || !isView);
|
|
94
|
-
var backgroundShouldLoad = current || active;
|
|
95
|
-
var hasHeader = isHeaderFilled(header);
|
|
96
|
-
var hasFooter = isFooterFilled(footer);
|
|
97
|
-
var footerProps = getFooterProps(footer, {
|
|
98
|
-
isView: isView,
|
|
99
|
-
current: current,
|
|
100
|
-
openWebView: openWebView,
|
|
101
|
-
isPreview: isPreview
|
|
18
|
+
function TitleScreen({
|
|
19
|
+
layout = 'top',
|
|
20
|
+
title = null,
|
|
21
|
+
subtitle = null,
|
|
22
|
+
description = null,
|
|
23
|
+
boxStyle = null,
|
|
24
|
+
withSubtitle = false,
|
|
25
|
+
withDescription = false,
|
|
26
|
+
withBox = false,
|
|
27
|
+
spacing = 20,
|
|
28
|
+
descriptionEmptyLabel = /*#__PURE__*/jsx(FormattedMessage, {
|
|
29
|
+
id: "507VAi",
|
|
30
|
+
defaultMessage: "Description"
|
|
31
|
+
}),
|
|
32
|
+
header = null,
|
|
33
|
+
footer = null,
|
|
34
|
+
background = null,
|
|
35
|
+
current = true,
|
|
36
|
+
active = true,
|
|
37
|
+
mediaRef: customMediaRef = null,
|
|
38
|
+
className = null
|
|
39
|
+
}) {
|
|
40
|
+
const {
|
|
41
|
+
width,
|
|
42
|
+
height,
|
|
43
|
+
resolution
|
|
44
|
+
} = useScreenSize();
|
|
45
|
+
const {
|
|
46
|
+
isView,
|
|
47
|
+
isPreview,
|
|
48
|
+
isPlaceholder,
|
|
49
|
+
isEdit
|
|
50
|
+
} = useScreenRenderContext();
|
|
51
|
+
const {
|
|
52
|
+
topHeight: viewerTopHeight,
|
|
53
|
+
bottomHeight: viewerBottomHeight,
|
|
54
|
+
bottomSidesWidth: viewerBottomSidesWidth
|
|
55
|
+
} = useViewerContext();
|
|
56
|
+
const {
|
|
57
|
+
open: openWebView
|
|
58
|
+
} = useViewerWebView();
|
|
59
|
+
const {
|
|
60
|
+
muted
|
|
61
|
+
} = usePlaybackContext();
|
|
62
|
+
const {
|
|
63
|
+
ref: mediaRef,
|
|
64
|
+
isCurrent: isCurrentMedia = false
|
|
65
|
+
} = usePlaybackMediaRef(current, true);
|
|
66
|
+
const hasTitle = isTextFilled(title);
|
|
67
|
+
const hasSubtitle = isTextFilled(subtitle);
|
|
68
|
+
const hasDescription = isTextFilled(description);
|
|
69
|
+
const layoutParts = layout.split('-');
|
|
70
|
+
const isSplitted = layoutParts[0] === 'split';
|
|
71
|
+
const isTopLayout = layout === 'top';
|
|
72
|
+
const isMiddleLayout = layout === 'middle';
|
|
73
|
+
const isBottomLayout = layout === 'bottom';
|
|
74
|
+
const verticalAlign = isSplitted ? layoutParts[1] || null : layoutParts[0];
|
|
75
|
+
const titleWithMargin = hasTitle && (hasSubtitle || hasDescription) && (!isSplitted || verticalAlign === 'top');
|
|
76
|
+
const subtitleWithMargin = hasSubtitle && hasDescription && (!isSplitted || verticalAlign === 'bottom');
|
|
77
|
+
const backgroundPlaying = current && (isView || isEdit) && (isCurrentMedia || !isView);
|
|
78
|
+
const backgroundShouldLoad = current || active;
|
|
79
|
+
const hasHeader = isHeaderFilled(header);
|
|
80
|
+
const hasFooter = isFooterFilled(footer);
|
|
81
|
+
const footerProps = getFooterProps(footer, {
|
|
82
|
+
isView,
|
|
83
|
+
current,
|
|
84
|
+
openWebView,
|
|
85
|
+
isPreview
|
|
102
86
|
});
|
|
103
|
-
|
|
87
|
+
const titleElement = /*#__PURE__*/jsx(ScreenElement, {
|
|
104
88
|
placeholder: "title",
|
|
105
89
|
emptyLabel: /*#__PURE__*/jsx(FormattedMessage, {
|
|
106
90
|
id: "2ZOPe+",
|
|
107
|
-
defaultMessage:
|
|
108
|
-
"type": 0,
|
|
109
|
-
"value": "Title"
|
|
110
|
-
}]
|
|
91
|
+
defaultMessage: "Title"
|
|
111
92
|
}),
|
|
112
93
|
emptyClassName: styles.emptyTitle,
|
|
113
94
|
isEmpty: !hasTitle,
|
|
114
|
-
children: hasTitle ? /*#__PURE__*/jsx(Heading,
|
|
115
|
-
className: classNames([styles.title,
|
|
116
|
-
|
|
95
|
+
children: hasTitle ? /*#__PURE__*/jsx(Heading, {
|
|
96
|
+
className: classNames([styles.title, {
|
|
97
|
+
[styles.withMargin]: titleWithMargin
|
|
98
|
+
}]),
|
|
99
|
+
...title,
|
|
117
100
|
size: 1
|
|
118
|
-
})
|
|
101
|
+
}) : null
|
|
119
102
|
}, "title");
|
|
120
|
-
|
|
103
|
+
const subtitleElement = withSubtitle ? /*#__PURE__*/jsx(ScreenElement, {
|
|
121
104
|
placeholder: "subtitle",
|
|
122
105
|
emptyLabel: /*#__PURE__*/jsx(FormattedMessage, {
|
|
123
106
|
id: "d60tSn",
|
|
124
|
-
defaultMessage:
|
|
125
|
-
"type": 0,
|
|
126
|
-
"value": "Subtitle"
|
|
127
|
-
}]
|
|
107
|
+
defaultMessage: "Subtitle"
|
|
128
108
|
}),
|
|
129
109
|
emptyClassName: styles.emptySubtitle,
|
|
130
110
|
isEmpty: !hasSubtitle,
|
|
131
|
-
children: hasSubtitle ? /*#__PURE__*/jsx(Heading,
|
|
132
|
-
className: classNames([styles.subtitle,
|
|
133
|
-
|
|
111
|
+
children: hasSubtitle ? /*#__PURE__*/jsx(Heading, {
|
|
112
|
+
className: classNames([styles.subtitle, {
|
|
113
|
+
[styles.withMargin]: subtitleWithMargin
|
|
114
|
+
}]),
|
|
115
|
+
...subtitle,
|
|
134
116
|
size: 2
|
|
135
|
-
})
|
|
117
|
+
}) : null
|
|
136
118
|
}, "subtitle") : null;
|
|
137
|
-
|
|
119
|
+
const descriptionElement = withDescription ? /*#__PURE__*/jsx(ScreenElement, {
|
|
138
120
|
placeholder: "shortText",
|
|
139
121
|
emptyLabel: descriptionEmptyLabel,
|
|
140
122
|
emptyClassName: styles.emptyDescription,
|
|
141
123
|
isEmpty: !hasDescription,
|
|
142
|
-
children: hasDescription ? /*#__PURE__*/jsx(Text,
|
|
124
|
+
children: hasDescription ? /*#__PURE__*/jsx(Text, {
|
|
125
|
+
...description
|
|
126
|
+
}) : null
|
|
143
127
|
}, "description") : null;
|
|
144
128
|
return /*#__PURE__*/jsxs("div", {
|
|
145
|
-
className: classNames([styles.container, className,
|
|
129
|
+
className: classNames([styles.container, className, {
|
|
130
|
+
[styles.isPlaceholder]: isPlaceholder
|
|
131
|
+
}]),
|
|
146
132
|
"data-screen-ready": true,
|
|
147
133
|
children: [/*#__PURE__*/jsx(Container, {
|
|
148
134
|
width: width,
|
|
@@ -162,7 +148,9 @@ function TitleScreen(_ref) {
|
|
|
162
148
|
style: {
|
|
163
149
|
paddingBottom: spacing
|
|
164
150
|
},
|
|
165
|
-
children: /*#__PURE__*/jsx(Header,
|
|
151
|
+
children: /*#__PURE__*/jsx(Header, {
|
|
152
|
+
...header
|
|
153
|
+
})
|
|
166
154
|
}) : null, !isPlaceholder && hasFooter && isMiddleLayout ? /*#__PURE__*/jsx(Spacer, {}, "spacer-cta-top") : null, !isPlaceholder && hasHeader && isBottomLayout ? /*#__PURE__*/jsx(Spacer, {}, "spacer-cta-top") : null, !isPlaceholder && hasHeader && !hasFooter && isMiddleLayout ? /*#__PURE__*/jsx(Spacer, {}, "spacer-cta-top") : null, withBox && !isSplitted ? /*#__PURE__*/jsx("div", {
|
|
167
155
|
className: styles.box,
|
|
168
156
|
style: isEdit || isPlaceholder || hasTitle || hasSubtitle || hasDescription ? getStyleFromBox(boxStyle) : null,
|
|
@@ -185,7 +173,9 @@ function TitleScreen(_ref) {
|
|
|
185
173
|
paddingLeft: Math.max(0, viewerBottomSidesWidth - spacing),
|
|
186
174
|
paddingRight: Math.max(0, viewerBottomSidesWidth - spacing)
|
|
187
175
|
},
|
|
188
|
-
children: /*#__PURE__*/jsx(Footer,
|
|
176
|
+
children: /*#__PURE__*/jsx(Footer, {
|
|
177
|
+
...footerProps
|
|
178
|
+
})
|
|
189
179
|
}, "call-to-action") : null]
|
|
190
180
|
})
|
|
191
181
|
}), !isPlaceholder ? /*#__PURE__*/jsx(Background, {
|
|
@@ -196,45 +186,100 @@ function TitleScreen(_ref) {
|
|
|
196
186
|
playing: backgroundPlaying,
|
|
197
187
|
muted: muted,
|
|
198
188
|
shouldLoad: backgroundShouldLoad,
|
|
199
|
-
mediaRef: mediaRef,
|
|
189
|
+
mediaRef: mergeRefs(mediaRef, customMediaRef),
|
|
200
190
|
withoutVideo: isPreview,
|
|
201
191
|
className: styles.background
|
|
202
192
|
}) : null]
|
|
203
193
|
});
|
|
204
194
|
}
|
|
205
195
|
|
|
206
|
-
function TitleSubtitleScreen(
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
196
|
+
function TitleSubtitleScreen(t0) {
|
|
197
|
+
const $ = c(4);
|
|
198
|
+
let props;
|
|
199
|
+
if ($[0] !== t0) {
|
|
200
|
+
({
|
|
201
|
+
...props
|
|
202
|
+
} = t0);
|
|
203
|
+
$[0] = t0;
|
|
204
|
+
$[1] = props;
|
|
205
|
+
} else {
|
|
206
|
+
props = $[1];
|
|
207
|
+
}
|
|
208
|
+
let t1;
|
|
209
|
+
if ($[2] !== props) {
|
|
210
|
+
t1 = /*#__PURE__*/jsx(TitleScreen, {
|
|
211
|
+
...props,
|
|
212
|
+
withSubtitle: true
|
|
213
|
+
});
|
|
214
|
+
$[2] = props;
|
|
215
|
+
$[3] = t1;
|
|
216
|
+
} else {
|
|
217
|
+
t1 = $[3];
|
|
218
|
+
}
|
|
219
|
+
return t1;
|
|
211
220
|
}
|
|
212
221
|
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
222
|
+
function TitleSubtitleCreditsScreen(t0) {
|
|
223
|
+
const $ = c(7);
|
|
224
|
+
let props;
|
|
225
|
+
let t1;
|
|
226
|
+
if ($[0] !== t0) {
|
|
227
|
+
({
|
|
228
|
+
credits: t1,
|
|
229
|
+
...props
|
|
230
|
+
} = t0);
|
|
231
|
+
$[0] = t0;
|
|
232
|
+
$[1] = props;
|
|
233
|
+
$[2] = t1;
|
|
234
|
+
} else {
|
|
235
|
+
props = $[1];
|
|
236
|
+
t1 = $[2];
|
|
237
|
+
}
|
|
238
|
+
const credits = t1 === undefined ? null : t1;
|
|
239
|
+
let t2;
|
|
240
|
+
if ($[3] === Symbol.for("react.memo_cache_sentinel")) {
|
|
241
|
+
t2 = /*#__PURE__*/jsx(FormattedMessage, {
|
|
223
242
|
id: "/hupzO",
|
|
224
|
-
defaultMessage:
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
}
|
|
243
|
+
defaultMessage: "Credits"
|
|
244
|
+
});
|
|
245
|
+
$[3] = t2;
|
|
246
|
+
} else {
|
|
247
|
+
t2 = $[3];
|
|
248
|
+
}
|
|
249
|
+
let t3;
|
|
250
|
+
if ($[4] !== credits || $[5] !== props) {
|
|
251
|
+
t3 = /*#__PURE__*/jsx(TitleScreen, {
|
|
252
|
+
...props,
|
|
253
|
+
description: credits,
|
|
254
|
+
withSubtitle: true,
|
|
255
|
+
withDescription: true,
|
|
256
|
+
descriptionEmptyLabel: t2
|
|
257
|
+
});
|
|
258
|
+
$[4] = credits;
|
|
259
|
+
$[5] = props;
|
|
260
|
+
$[6] = t3;
|
|
261
|
+
} else {
|
|
262
|
+
t3 = $[6];
|
|
263
|
+
}
|
|
264
|
+
return t3;
|
|
230
265
|
}
|
|
231
266
|
|
|
232
267
|
function TitleWithBoxScreen(props) {
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
268
|
+
const $ = c(2);
|
|
269
|
+
let t0;
|
|
270
|
+
if ($[0] !== props) {
|
|
271
|
+
t0 = /*#__PURE__*/jsx(TitleScreen, {
|
|
272
|
+
...props,
|
|
273
|
+
withSubtitle: true,
|
|
274
|
+
withDescription: true,
|
|
275
|
+
withBox: true
|
|
276
|
+
});
|
|
277
|
+
$[0] = props;
|
|
278
|
+
$[1] = t0;
|
|
279
|
+
} else {
|
|
280
|
+
t0 = $[1];
|
|
281
|
+
}
|
|
282
|
+
return t0;
|
|
238
283
|
}
|
|
239
284
|
|
|
240
285
|
var definition = [{
|
|
@@ -243,19 +288,13 @@ var definition = [{
|
|
|
243
288
|
group: {
|
|
244
289
|
label: defineMessage({
|
|
245
290
|
id: "uKJRh2",
|
|
246
|
-
defaultMessage:
|
|
247
|
-
"type": 0,
|
|
248
|
-
"value": "Title"
|
|
249
|
-
}]
|
|
291
|
+
defaultMessage: "Title"
|
|
250
292
|
}),
|
|
251
293
|
order: 1
|
|
252
294
|
},
|
|
253
295
|
title: defineMessage({
|
|
254
296
|
id: "dVcog7",
|
|
255
|
-
defaultMessage:
|
|
256
|
-
"type": 0,
|
|
257
|
-
"value": "Title"
|
|
258
|
-
}]
|
|
297
|
+
defaultMessage: "Title"
|
|
259
298
|
}),
|
|
260
299
|
component: TitleScreen,
|
|
261
300
|
layouts: ['top', 'middle', 'bottom'],
|
|
@@ -266,10 +305,7 @@ var definition = [{
|
|
|
266
305
|
defaultValue: 'top',
|
|
267
306
|
label: defineMessage({
|
|
268
307
|
id: "4iBXj2",
|
|
269
|
-
defaultMessage:
|
|
270
|
-
"type": 0,
|
|
271
|
-
"value": "Layout"
|
|
272
|
-
}]
|
|
308
|
+
defaultMessage: "Layout"
|
|
273
309
|
})
|
|
274
310
|
}, {
|
|
275
311
|
name: 'title',
|
|
@@ -279,30 +315,21 @@ var definition = [{
|
|
|
279
315
|
},
|
|
280
316
|
label: defineMessage({
|
|
281
317
|
id: "N25iDO",
|
|
282
|
-
defaultMessage:
|
|
283
|
-
"type": 0,
|
|
284
|
-
"value": "Title"
|
|
285
|
-
}]
|
|
318
|
+
defaultMessage: "Title"
|
|
286
319
|
})
|
|
287
320
|
}, {
|
|
288
321
|
name: 'background',
|
|
289
322
|
type: 'background',
|
|
290
323
|
label: defineMessage({
|
|
291
324
|
id: "+MPZRu",
|
|
292
|
-
defaultMessage:
|
|
293
|
-
"type": 0,
|
|
294
|
-
"value": "Background"
|
|
295
|
-
}]
|
|
325
|
+
defaultMessage: "Background"
|
|
296
326
|
})
|
|
297
327
|
}, {
|
|
298
328
|
name: 'header',
|
|
299
329
|
type: 'header',
|
|
300
330
|
label: defineMessage({
|
|
301
331
|
id: "rhuDxI",
|
|
302
|
-
defaultMessage:
|
|
303
|
-
"type": 0,
|
|
304
|
-
"value": "Header"
|
|
305
|
-
}]
|
|
332
|
+
defaultMessage: "Header"
|
|
306
333
|
}),
|
|
307
334
|
theme: {
|
|
308
335
|
badge: {
|
|
@@ -317,10 +344,7 @@ var definition = [{
|
|
|
317
344
|
type: 'footer',
|
|
318
345
|
label: defineMessage({
|
|
319
346
|
id: "g4nybp",
|
|
320
|
-
defaultMessage:
|
|
321
|
-
"type": 0,
|
|
322
|
-
"value": "Footer"
|
|
323
|
-
}]
|
|
347
|
+
defaultMessage: "Footer"
|
|
324
348
|
}),
|
|
325
349
|
theme: {
|
|
326
350
|
callToAction: {
|
|
@@ -337,19 +361,13 @@ var definition = [{
|
|
|
337
361
|
group: {
|
|
338
362
|
label: defineMessage({
|
|
339
363
|
id: "uKJRh2",
|
|
340
|
-
defaultMessage:
|
|
341
|
-
"type": 0,
|
|
342
|
-
"value": "Title"
|
|
343
|
-
}]
|
|
364
|
+
defaultMessage: "Title"
|
|
344
365
|
}),
|
|
345
366
|
order: 1
|
|
346
367
|
},
|
|
347
368
|
title: defineMessage({
|
|
348
369
|
id: "P1dwGU",
|
|
349
|
-
defaultMessage:
|
|
350
|
-
"type": 0,
|
|
351
|
-
"value": "Title with subtitle"
|
|
352
|
-
}]
|
|
370
|
+
defaultMessage: "Title with subtitle"
|
|
353
371
|
}),
|
|
354
372
|
component: TitleSubtitleScreen,
|
|
355
373
|
layouts: ['top', 'middle', 'bottom', 'split'],
|
|
@@ -360,10 +378,7 @@ var definition = [{
|
|
|
360
378
|
defaultValue: 'top',
|
|
361
379
|
label: defineMessage({
|
|
362
380
|
id: "4iBXj2",
|
|
363
|
-
defaultMessage:
|
|
364
|
-
"type": 0,
|
|
365
|
-
"value": "Layout"
|
|
366
|
-
}]
|
|
381
|
+
defaultMessage: "Layout"
|
|
367
382
|
})
|
|
368
383
|
}, {
|
|
369
384
|
name: 'title',
|
|
@@ -373,10 +388,7 @@ var definition = [{
|
|
|
373
388
|
},
|
|
374
389
|
label: defineMessage({
|
|
375
390
|
id: "N25iDO",
|
|
376
|
-
defaultMessage:
|
|
377
|
-
"type": 0,
|
|
378
|
-
"value": "Title"
|
|
379
|
-
}]
|
|
391
|
+
defaultMessage: "Title"
|
|
380
392
|
})
|
|
381
393
|
}, {
|
|
382
394
|
name: 'subtitle',
|
|
@@ -386,30 +398,21 @@ var definition = [{
|
|
|
386
398
|
},
|
|
387
399
|
label: defineMessage({
|
|
388
400
|
id: "EcZYpr",
|
|
389
|
-
defaultMessage:
|
|
390
|
-
"type": 0,
|
|
391
|
-
"value": "Subtitle"
|
|
392
|
-
}]
|
|
401
|
+
defaultMessage: "Subtitle"
|
|
393
402
|
})
|
|
394
403
|
}, {
|
|
395
404
|
name: 'background',
|
|
396
405
|
type: 'background',
|
|
397
406
|
label: defineMessage({
|
|
398
407
|
id: "+MPZRu",
|
|
399
|
-
defaultMessage:
|
|
400
|
-
"type": 0,
|
|
401
|
-
"value": "Background"
|
|
402
|
-
}]
|
|
408
|
+
defaultMessage: "Background"
|
|
403
409
|
})
|
|
404
410
|
}, {
|
|
405
411
|
name: 'header',
|
|
406
412
|
type: 'header',
|
|
407
413
|
label: defineMessage({
|
|
408
414
|
id: "rhuDxI",
|
|
409
|
-
defaultMessage:
|
|
410
|
-
"type": 0,
|
|
411
|
-
"value": "Header"
|
|
412
|
-
}]
|
|
415
|
+
defaultMessage: "Header"
|
|
413
416
|
}),
|
|
414
417
|
theme: {
|
|
415
418
|
badge: {
|
|
@@ -424,10 +427,7 @@ var definition = [{
|
|
|
424
427
|
type: 'footer',
|
|
425
428
|
label: defineMessage({
|
|
426
429
|
id: "g4nybp",
|
|
427
|
-
defaultMessage:
|
|
428
|
-
"type": 0,
|
|
429
|
-
"value": "Footer"
|
|
430
|
-
}]
|
|
430
|
+
defaultMessage: "Footer"
|
|
431
431
|
}),
|
|
432
432
|
theme: {
|
|
433
433
|
callToAction: {
|
|
@@ -444,19 +444,13 @@ var definition = [{
|
|
|
444
444
|
group: {
|
|
445
445
|
label: defineMessage({
|
|
446
446
|
id: "uKJRh2",
|
|
447
|
-
defaultMessage:
|
|
448
|
-
"type": 0,
|
|
449
|
-
"value": "Title"
|
|
450
|
-
}]
|
|
447
|
+
defaultMessage: "Title"
|
|
451
448
|
}),
|
|
452
449
|
order: 1
|
|
453
450
|
},
|
|
454
451
|
title: defineMessage({
|
|
455
452
|
id: "vZrFq6",
|
|
456
|
-
defaultMessage:
|
|
457
|
-
"type": 0,
|
|
458
|
-
"value": "Title with subtitle and credits"
|
|
459
|
-
}]
|
|
453
|
+
defaultMessage: "Title with subtitle and credits"
|
|
460
454
|
}),
|
|
461
455
|
component: TitleSubtitleCreditsScreen,
|
|
462
456
|
layouts: ['top', 'middle', 'bottom', 'split-top', 'split-bottom'],
|
|
@@ -467,10 +461,7 @@ var definition = [{
|
|
|
467
461
|
defaultValue: 'top',
|
|
468
462
|
label: defineMessage({
|
|
469
463
|
id: "4iBXj2",
|
|
470
|
-
defaultMessage:
|
|
471
|
-
"type": 0,
|
|
472
|
-
"value": "Layout"
|
|
473
|
-
}]
|
|
464
|
+
defaultMessage: "Layout"
|
|
474
465
|
})
|
|
475
466
|
}, {
|
|
476
467
|
name: 'title',
|
|
@@ -480,10 +471,7 @@ var definition = [{
|
|
|
480
471
|
},
|
|
481
472
|
label: defineMessage({
|
|
482
473
|
id: "N25iDO",
|
|
483
|
-
defaultMessage:
|
|
484
|
-
"type": 0,
|
|
485
|
-
"value": "Title"
|
|
486
|
-
}]
|
|
474
|
+
defaultMessage: "Title"
|
|
487
475
|
})
|
|
488
476
|
}, {
|
|
489
477
|
name: 'subtitle',
|
|
@@ -493,10 +481,7 @@ var definition = [{
|
|
|
493
481
|
},
|
|
494
482
|
label: defineMessage({
|
|
495
483
|
id: "EcZYpr",
|
|
496
|
-
defaultMessage:
|
|
497
|
-
"type": 0,
|
|
498
|
-
"value": "Subtitle"
|
|
499
|
-
}]
|
|
484
|
+
defaultMessage: "Subtitle"
|
|
500
485
|
})
|
|
501
486
|
}, {
|
|
502
487
|
name: 'credits',
|
|
@@ -506,30 +491,21 @@ var definition = [{
|
|
|
506
491
|
},
|
|
507
492
|
label: defineMessage({
|
|
508
493
|
id: "upzOTm",
|
|
509
|
-
defaultMessage:
|
|
510
|
-
"type": 0,
|
|
511
|
-
"value": "Credits"
|
|
512
|
-
}]
|
|
494
|
+
defaultMessage: "Credits"
|
|
513
495
|
})
|
|
514
496
|
}, {
|
|
515
497
|
name: 'background',
|
|
516
498
|
type: 'background',
|
|
517
499
|
label: defineMessage({
|
|
518
500
|
id: "+MPZRu",
|
|
519
|
-
defaultMessage:
|
|
520
|
-
"type": 0,
|
|
521
|
-
"value": "Background"
|
|
522
|
-
}]
|
|
501
|
+
defaultMessage: "Background"
|
|
523
502
|
})
|
|
524
503
|
}, {
|
|
525
504
|
name: 'header',
|
|
526
505
|
type: 'header',
|
|
527
506
|
label: defineMessage({
|
|
528
507
|
id: "rhuDxI",
|
|
529
|
-
defaultMessage:
|
|
530
|
-
"type": 0,
|
|
531
|
-
"value": "Header"
|
|
532
|
-
}]
|
|
508
|
+
defaultMessage: "Header"
|
|
533
509
|
}),
|
|
534
510
|
theme: {
|
|
535
511
|
badge: {
|
|
@@ -544,10 +520,7 @@ var definition = [{
|
|
|
544
520
|
type: 'footer',
|
|
545
521
|
label: defineMessage({
|
|
546
522
|
id: "g4nybp",
|
|
547
|
-
defaultMessage:
|
|
548
|
-
"type": 0,
|
|
549
|
-
"value": "Footer"
|
|
550
|
-
}]
|
|
523
|
+
defaultMessage: "Footer"
|
|
551
524
|
}),
|
|
552
525
|
theme: {
|
|
553
526
|
callToAction: {
|
|
@@ -564,19 +537,13 @@ var definition = [{
|
|
|
564
537
|
group: {
|
|
565
538
|
label: defineMessage({
|
|
566
539
|
id: "uKJRh2",
|
|
567
|
-
defaultMessage:
|
|
568
|
-
"type": 0,
|
|
569
|
-
"value": "Title"
|
|
570
|
-
}]
|
|
540
|
+
defaultMessage: "Title"
|
|
571
541
|
}),
|
|
572
542
|
order: 1
|
|
573
543
|
},
|
|
574
544
|
title: defineMessage({
|
|
575
545
|
id: "9a5s+m",
|
|
576
|
-
defaultMessage:
|
|
577
|
-
"type": 0,
|
|
578
|
-
"value": "Title with box"
|
|
579
|
-
}]
|
|
546
|
+
defaultMessage: "Title with box"
|
|
580
547
|
}),
|
|
581
548
|
component: TitleWithBoxScreen,
|
|
582
549
|
layouts: ['top', 'middle', 'bottom', 'split-top', 'split-bottom'],
|
|
@@ -587,10 +554,7 @@ var definition = [{
|
|
|
587
554
|
defaultValue: 'top',
|
|
588
555
|
label: defineMessage({
|
|
589
556
|
id: "4iBXj2",
|
|
590
|
-
defaultMessage:
|
|
591
|
-
"type": 0,
|
|
592
|
-
"value": "Layout"
|
|
593
|
-
}]
|
|
557
|
+
defaultMessage: "Layout"
|
|
594
558
|
})
|
|
595
559
|
}, {
|
|
596
560
|
name: 'title',
|
|
@@ -600,10 +564,7 @@ var definition = [{
|
|
|
600
564
|
},
|
|
601
565
|
label: defineMessage({
|
|
602
566
|
id: "N25iDO",
|
|
603
|
-
defaultMessage:
|
|
604
|
-
"type": 0,
|
|
605
|
-
"value": "Title"
|
|
606
|
-
}]
|
|
567
|
+
defaultMessage: "Title"
|
|
607
568
|
})
|
|
608
569
|
}, {
|
|
609
570
|
name: 'subtitle',
|
|
@@ -613,10 +574,7 @@ var definition = [{
|
|
|
613
574
|
},
|
|
614
575
|
label: defineMessage({
|
|
615
576
|
id: "EcZYpr",
|
|
616
|
-
defaultMessage:
|
|
617
|
-
"type": 0,
|
|
618
|
-
"value": "Subtitle"
|
|
619
|
-
}]
|
|
577
|
+
defaultMessage: "Subtitle"
|
|
620
578
|
})
|
|
621
579
|
}, {
|
|
622
580
|
name: 'description',
|
|
@@ -626,30 +584,21 @@ var definition = [{
|
|
|
626
584
|
},
|
|
627
585
|
label: defineMessage({
|
|
628
586
|
id: "ZCe0r4",
|
|
629
|
-
defaultMessage:
|
|
630
|
-
"type": 0,
|
|
631
|
-
"value": "Description"
|
|
632
|
-
}]
|
|
587
|
+
defaultMessage: "Description"
|
|
633
588
|
})
|
|
634
589
|
}, {
|
|
635
590
|
type: 'fields',
|
|
636
591
|
isList: true,
|
|
637
592
|
label: defineMessage({
|
|
638
593
|
id: "LOknw0",
|
|
639
|
-
defaultMessage:
|
|
640
|
-
"type": 0,
|
|
641
|
-
"value": "Styles"
|
|
642
|
-
}]
|
|
594
|
+
defaultMessage: "Styles"
|
|
643
595
|
}),
|
|
644
596
|
fields: [{
|
|
645
597
|
name: 'boxStyle',
|
|
646
598
|
type: 'box-style-form',
|
|
647
599
|
label: defineMessage({
|
|
648
600
|
id: "f5Yipd",
|
|
649
|
-
defaultMessage:
|
|
650
|
-
"type": 0,
|
|
651
|
-
"value": "Box"
|
|
652
|
-
}]
|
|
601
|
+
defaultMessage: "Box"
|
|
653
602
|
})
|
|
654
603
|
}]
|
|
655
604
|
}, {
|
|
@@ -657,20 +606,14 @@ var definition = [{
|
|
|
657
606
|
type: 'background',
|
|
658
607
|
label: defineMessage({
|
|
659
608
|
id: "cDj1mZ",
|
|
660
|
-
defaultMessage:
|
|
661
|
-
"type": 0,
|
|
662
|
-
"value": "Background"
|
|
663
|
-
}]
|
|
609
|
+
defaultMessage: "Background"
|
|
664
610
|
})
|
|
665
611
|
}, {
|
|
666
612
|
name: 'header',
|
|
667
613
|
type: 'header',
|
|
668
614
|
label: defineMessage({
|
|
669
615
|
id: "rhuDxI",
|
|
670
|
-
defaultMessage:
|
|
671
|
-
"type": 0,
|
|
672
|
-
"value": "Header"
|
|
673
|
-
}]
|
|
616
|
+
defaultMessage: "Header"
|
|
674
617
|
}),
|
|
675
618
|
theme: {
|
|
676
619
|
badge: {
|
|
@@ -685,10 +628,7 @@ var definition = [{
|
|
|
685
628
|
type: 'footer',
|
|
686
629
|
label: defineMessage({
|
|
687
630
|
id: "g4nybp",
|
|
688
|
-
defaultMessage:
|
|
689
|
-
"type": 0,
|
|
690
|
-
"value": "Footer"
|
|
691
|
-
}]
|
|
631
|
+
defaultMessage: "Footer"
|
|
692
632
|
}),
|
|
693
633
|
theme: {
|
|
694
634
|
callToAction: {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/screen-title",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.74",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -36,6 +36,7 @@
|
|
|
36
36
|
"exports": {
|
|
37
37
|
".": {
|
|
38
38
|
"types": "./es/index.d.ts",
|
|
39
|
+
"style": "./assets/css/styles.css",
|
|
39
40
|
"import": "./es/index.js"
|
|
40
41
|
},
|
|
41
42
|
"./assets/css/styles": "./assets/css/styles.css",
|
|
@@ -52,24 +53,24 @@
|
|
|
52
53
|
"build": "../../scripts/prepare-package.sh --types"
|
|
53
54
|
},
|
|
54
55
|
"devDependencies": {
|
|
55
|
-
"react": "^
|
|
56
|
-
"react-dom": "^
|
|
56
|
+
"react": "^19.0.0",
|
|
57
|
+
"react-dom": "^19.0.0"
|
|
57
58
|
},
|
|
58
59
|
"peerDependencies": {
|
|
59
|
-
"react": "^
|
|
60
|
-
"react-dom": "^
|
|
60
|
+
"react": "^19.0.0",
|
|
61
|
+
"react-dom": "^19.0.0"
|
|
61
62
|
},
|
|
62
63
|
"dependencies": {
|
|
63
64
|
"@babel/runtime": "^7.28.6",
|
|
64
|
-
"@micromag/core": "^0.4.
|
|
65
|
-
"@micromag/element-background": "^0.4.
|
|
66
|
-
"@micromag/element-container": "^0.4.
|
|
67
|
-
"@micromag/element-footer": "^0.4.
|
|
68
|
-
"@micromag/element-header": "^0.4.
|
|
69
|
-
"@micromag/element-heading": "^0.4.
|
|
70
|
-
"@micromag/element-layout": "^0.4.
|
|
71
|
-
"@micromag/element-text": "^0.4.
|
|
72
|
-
"@micromag/transforms": "^0.4.
|
|
65
|
+
"@micromag/core": "^0.4.74",
|
|
66
|
+
"@micromag/element-background": "^0.4.74",
|
|
67
|
+
"@micromag/element-container": "^0.4.74",
|
|
68
|
+
"@micromag/element-footer": "^0.4.74",
|
|
69
|
+
"@micromag/element-header": "^0.4.74",
|
|
70
|
+
"@micromag/element-heading": "^0.4.74",
|
|
71
|
+
"@micromag/element-layout": "^0.4.74",
|
|
72
|
+
"@micromag/element-text": "^0.4.74",
|
|
73
|
+
"@micromag/transforms": "^0.4.74",
|
|
73
74
|
"classnames": "^2.2.6",
|
|
74
75
|
"lodash": "^4.17.23",
|
|
75
76
|
"react-intl": "^8.1.3 || ^10.0.0",
|
|
@@ -79,6 +80,6 @@
|
|
|
79
80
|
"access": "public",
|
|
80
81
|
"registry": "https://registry.npmjs.org/"
|
|
81
82
|
},
|
|
82
|
-
"gitHead": "
|
|
83
|
+
"gitHead": "fe510ee87845280d0760cb292aef9d2eb69e67c1",
|
|
83
84
|
"types": "es/index.d.ts"
|
|
84
85
|
}
|