@micromag/screen-timeline 0.3.444 → 0.3.447

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.
Files changed (3) hide show
  1. package/es/index.js +1 -43
  2. package/lib/index.js +1 -43
  3. package/package.json +13 -13
package/es/index.js CHANGED
@@ -22,7 +22,6 @@ import Text from '@micromag/element-text';
22
22
  import Visual from '@micromag/element-visual';
23
23
  import _objectDestructuringEmpty from '@babel/runtime/helpers/objectDestructuringEmpty';
24
24
  import _extends from '@babel/runtime/helpers/extends';
25
- import { Text as Text$1, Container as Container$1 } from '@micromag/transforms/apple-news';
26
25
 
27
26
  var styles = {"container":"micromag-screen-timeline-container","background":"micromag-screen-timeline-background","empty":"micromag-screen-timeline-empty","content":"micromag-screen-timeline-content","emptyTitle":"micromag-screen-timeline-emptyTitle","item":"micromag-screen-timeline-item","element":"micromag-screen-timeline-element","hidden":"micromag-screen-timeline-hidden","body":"micromag-screen-timeline-body","timeline":"micromag-screen-timeline-timeline","line":"micromag-screen-timeline-line","bullet":"micromag-screen-timeline-bullet","last":"micromag-screen-timeline-last","title":"micromag-screen-timeline-title","description":"micromag-screen-timeline-description","imageContainer":"micromag-screen-timeline-imageContainer","image":"micromag-screen-timeline-image","video":"micromag-screen-timeline-video","callToAction":"micromag-screen-timeline-callToAction","disabled":"micromag-screen-timeline-disabled","isPlaceholder":"micromag-screen-timeline-isPlaceholder","scroll":"micromag-screen-timeline-scroll","circleBulletShape":"micromag-screen-timeline-circleBulletShape","withoutLines":"micromag-screen-timeline-withoutLines"};
28
27
 
@@ -357,47 +356,6 @@ var TimelineIllustratedScreen = function TimelineIllustratedScreen(_ref) {
357
356
  }));
358
357
  };
359
358
 
360
- var transform = function transform(newStory, _ref) {
361
- var _ref$items = _ref.items,
362
- items = _ref$items === void 0 ? [] : _ref$items;
363
- var allItems = items || [];
364
- var list = allItems.reduce(function (acc, it) {
365
- var _Text = Text$1(acc.story, it.title),
366
- titleStory = _Text.story,
367
- titleComponent = _Text.component;
368
- var _Text2 = Text$1(titleStory, it.description),
369
- descriptionStory = _Text2.story,
370
- descriptionComponent = _Text2.component;
371
- var _Container = Container$1(descriptionStory, [].concat(_toConsumableArray(titleComponent ? [titleComponent] : []), _toConsumableArray(descriptionComponent ? [descriptionComponent] : []))),
372
- containerStory = _Container.story,
373
- containerComponent = _Container.component;
374
- return {
375
- story: containerStory,
376
- components: [].concat(_toConsumableArray(acc.components || []), _toConsumableArray(containerComponent ? [containerComponent] : []))
377
- };
378
- }, {
379
- story: newStory,
380
- components: []
381
- });
382
- var _ref2 = list || {},
383
- reducedStory = _ref2.story,
384
- _ref2$components = _ref2.components,
385
- reducedComponents = _ref2$components === void 0 ? [] : _ref2$components;
386
- var _Container2 = Container$1(reducedStory, reducedComponents),
387
- bigContainerStory = _Container2.story,
388
- bigContainerComponent = _Container2.component;
389
- return _objectSpread(_objectSpread({}, bigContainerStory), {}, {
390
- components: [].concat(_toConsumableArray(newStory.components || []), _toConsumableArray(bigContainerComponent ? [bigContainerComponent] : []))
391
- });
392
- };
393
-
394
- // eslint-disable-next-line
395
-
396
- var transforms = /*#__PURE__*/Object.freeze({
397
- __proto__: null,
398
- appleNews: transform
399
- });
400
-
401
359
  var definition = [{
402
360
  id: 'timeline',
403
361
  type: 'screen',
@@ -420,7 +378,7 @@ var definition = [{
420
378
  }),
421
379
  component: Timeline,
422
380
  layouts: ['normal'],
423
- transforms: transforms,
381
+ // transforms,
424
382
  fields: [{
425
383
  name: 'title',
426
384
  type: 'heading-element',
package/lib/index.js CHANGED
@@ -26,7 +26,6 @@ var Text = require('@micromag/element-text');
26
26
  var Visual = require('@micromag/element-visual');
27
27
  var _objectDestructuringEmpty = require('@babel/runtime/helpers/objectDestructuringEmpty');
28
28
  var _extends = require('@babel/runtime/helpers/extends');
29
- var appleNews = require('@micromag/transforms/apple-news');
30
29
 
31
30
  var styles = {"container":"micromag-screen-timeline-container","background":"micromag-screen-timeline-background","empty":"micromag-screen-timeline-empty","content":"micromag-screen-timeline-content","emptyTitle":"micromag-screen-timeline-emptyTitle","item":"micromag-screen-timeline-item","element":"micromag-screen-timeline-element","hidden":"micromag-screen-timeline-hidden","body":"micromag-screen-timeline-body","timeline":"micromag-screen-timeline-timeline","line":"micromag-screen-timeline-line","bullet":"micromag-screen-timeline-bullet","last":"micromag-screen-timeline-last","title":"micromag-screen-timeline-title","description":"micromag-screen-timeline-description","imageContainer":"micromag-screen-timeline-imageContainer","image":"micromag-screen-timeline-image","video":"micromag-screen-timeline-video","callToAction":"micromag-screen-timeline-callToAction","disabled":"micromag-screen-timeline-disabled","isPlaceholder":"micromag-screen-timeline-isPlaceholder","scroll":"micromag-screen-timeline-scroll","circleBulletShape":"micromag-screen-timeline-circleBulletShape","withoutLines":"micromag-screen-timeline-withoutLines"};
32
31
 
@@ -361,47 +360,6 @@ var TimelineIllustratedScreen = function TimelineIllustratedScreen(_ref) {
361
360
  }));
362
361
  };
363
362
 
364
- var transform = function transform(newStory, _ref) {
365
- var _ref$items = _ref.items,
366
- items = _ref$items === void 0 ? [] : _ref$items;
367
- var allItems = items || [];
368
- var list = allItems.reduce(function (acc, it) {
369
- var _Text = appleNews.Text(acc.story, it.title),
370
- titleStory = _Text.story,
371
- titleComponent = _Text.component;
372
- var _Text2 = appleNews.Text(titleStory, it.description),
373
- descriptionStory = _Text2.story,
374
- descriptionComponent = _Text2.component;
375
- var _Container = appleNews.Container(descriptionStory, [].concat(_toConsumableArray(titleComponent ? [titleComponent] : []), _toConsumableArray(descriptionComponent ? [descriptionComponent] : []))),
376
- containerStory = _Container.story,
377
- containerComponent = _Container.component;
378
- return {
379
- story: containerStory,
380
- components: [].concat(_toConsumableArray(acc.components || []), _toConsumableArray(containerComponent ? [containerComponent] : []))
381
- };
382
- }, {
383
- story: newStory,
384
- components: []
385
- });
386
- var _ref2 = list || {},
387
- reducedStory = _ref2.story,
388
- _ref2$components = _ref2.components,
389
- reducedComponents = _ref2$components === void 0 ? [] : _ref2$components;
390
- var _Container2 = appleNews.Container(reducedStory, reducedComponents),
391
- bigContainerStory = _Container2.story,
392
- bigContainerComponent = _Container2.component;
393
- return _objectSpread(_objectSpread({}, bigContainerStory), {}, {
394
- components: [].concat(_toConsumableArray(newStory.components || []), _toConsumableArray(bigContainerComponent ? [bigContainerComponent] : []))
395
- });
396
- };
397
-
398
- // eslint-disable-next-line
399
-
400
- var transforms = /*#__PURE__*/Object.freeze({
401
- __proto__: null,
402
- appleNews: transform
403
- });
404
-
405
363
  var definition = [{
406
364
  id: 'timeline',
407
365
  type: 'screen',
@@ -424,7 +382,7 @@ var definition = [{
424
382
  }),
425
383
  component: Timeline,
426
384
  layouts: ['normal'],
427
- transforms: transforms,
385
+ // transforms,
428
386
  fields: [{
429
387
  name: 'title',
430
388
  type: 'heading-element',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@micromag/screen-timeline",
3
- "version": "0.3.444",
3
+ "version": "0.3.447",
4
4
  "private": false,
5
5
  "description": "",
6
6
  "keywords": [
@@ -59,17 +59,17 @@
59
59
  },
60
60
  "dependencies": {
61
61
  "@babel/runtime": "^7.13.10",
62
- "@micromag/core": "^0.3.444",
63
- "@micromag/element-background": "^0.3.444",
64
- "@micromag/element-container": "^0.3.444",
65
- "@micromag/element-footer": "^0.3.444",
66
- "@micromag/element-header": "^0.3.444",
67
- "@micromag/element-heading": "^0.3.444",
68
- "@micromag/element-layout": "^0.3.444",
69
- "@micromag/element-scroll": "^0.3.444",
70
- "@micromag/element-text": "^0.3.444",
71
- "@micromag/element-visual": "^0.3.444",
72
- "@micromag/transforms": "^0.3.444",
62
+ "@micromag/core": "^0.3.447",
63
+ "@micromag/element-background": "^0.3.447",
64
+ "@micromag/element-container": "^0.3.447",
65
+ "@micromag/element-footer": "^0.3.447",
66
+ "@micromag/element-header": "^0.3.447",
67
+ "@micromag/element-heading": "^0.3.447",
68
+ "@micromag/element-layout": "^0.3.447",
69
+ "@micromag/element-scroll": "^0.3.447",
70
+ "@micromag/element-text": "^0.3.447",
71
+ "@micromag/element-visual": "^0.3.447",
72
+ "@micromag/transforms": "^0.3.447",
73
73
  "classnames": "^2.2.6",
74
74
  "lodash": "^4.17.21",
75
75
  "prop-types": "^15.7.2",
@@ -80,5 +80,5 @@
80
80
  "access": "public",
81
81
  "registry": "https://registry.npmjs.org/"
82
82
  },
83
- "gitHead": "40bfd80ccd7a777ffebb0a6d9006c8ebad6a22bd"
83
+ "gitHead": "ec175c602ce6f59b7561f57c92da443814109d50"
84
84
  }