@micromag/core 0.3.814 → 0.3.820

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 +54 -10
  2. package/lib/index.js +54 -10
  3. package/package.json +2 -2
package/es/index.js CHANGED
@@ -1210,7 +1210,7 @@ var FieldsManager = /*#__PURE__*/function (_DefinitionsManager) {
1210
1210
  }]);
1211
1211
  }(DefinitionsManager);
1212
1212
 
1213
- var _excluded$7 = ["medias"],
1213
+ var _excluded$8 = ["medias"],
1214
1214
  _excluded2$3 = ["medias"];
1215
1215
  var MediasParser = /*#__PURE__*/function () {
1216
1216
  function MediasParser(_ref) {
@@ -1230,7 +1230,7 @@ var MediasParser = /*#__PURE__*/function () {
1230
1230
  if (typeof this.parsedThemesCache[storyId] === 'undefined') {
1231
1231
  var _this$toPath = this.toPath(theme),
1232
1232
  themeMedias = _this$toPath.medias,
1233
- newTheme = _objectWithoutProperties(_this$toPath, _excluded$7);
1233
+ newTheme = _objectWithoutProperties(_this$toPath, _excluded$8);
1234
1234
  this.parsedThemesCache[storyId] = {
1235
1235
  themeMedias: themeMedias,
1236
1236
  newTheme: newTheme
@@ -1536,7 +1536,7 @@ var ScreensManager = /*#__PURE__*/function (_DefinitionsManager) {
1536
1536
  }]);
1537
1537
  }(DefinitionsManager);
1538
1538
 
1539
- var _excluded$6 = ["fonts"];
1539
+ var _excluded$7 = ["fonts"];
1540
1540
  var FontsParser = /*#__PURE__*/function () {
1541
1541
  function FontsParser(_ref) {
1542
1542
  var fieldsManager = _ref.fieldsManager,
@@ -1585,7 +1585,7 @@ var FontsParser = /*#__PURE__*/function () {
1585
1585
  var _this$parse = this.parse(theme),
1586
1586
  _this$parse$fonts = _this$parse.fonts,
1587
1587
  themeFonts = _this$parse$fonts === void 0 ? [] : _this$parse$fonts,
1588
- newTheme = _objectWithoutProperties(_this$parse, _excluded$6);
1588
+ newTheme = _objectWithoutProperties(_this$parse, _excluded$7);
1589
1589
  return fonts.length > 0 || themeFonts.length > 0 ? _objectSpread(_objectSpread({}, story), {}, {
1590
1590
  theme: newTheme,
1591
1591
  fonts: uniq([].concat(_toConsumableArray(themeFonts), _toConsumableArray(fonts)), 'name')
@@ -1661,7 +1661,7 @@ var FontsParser = /*#__PURE__*/function () {
1661
1661
  }]);
1662
1662
  }();
1663
1663
 
1664
- var _excluded$5 = ["shareIncentive", "callToAction"];
1664
+ var _excluded$6 = ["shareIncentive", "callToAction"];
1665
1665
  /* eslint-disable class-methods-use-this */
1666
1666
  var ShareCall = /*#__PURE__*/function () {
1667
1667
  function ShareCall() {
@@ -1688,7 +1688,7 @@ var ShareCall = /*#__PURE__*/function () {
1688
1688
  shareIncentive = _ref2$shareIncentive === void 0 ? null : _ref2$shareIncentive,
1689
1689
  _ref2$callToAction = _ref2.callToAction,
1690
1690
  callToAction = _ref2$callToAction === void 0 ? null : _ref2$callToAction,
1691
- restScreen = _objectWithoutProperties(_ref2, _excluded$5);
1691
+ restScreen = _objectWithoutProperties(_ref2, _excluded$6);
1692
1692
  var _ref3 = screen || {},
1693
1693
  _ref3$header = _ref3.header,
1694
1694
  header = _ref3$header === void 0 ? null : _ref3$header,
@@ -1717,7 +1717,7 @@ var ShareCall = /*#__PURE__*/function () {
1717
1717
  }();
1718
1718
  ShareCall.prototype.priority = 0;
1719
1719
 
1720
- var _excluded$4 = ["answers"],
1720
+ var _excluded$5 = ["answers"],
1721
1721
  _excluded2$2 = ["customAnswerLabel"];
1722
1722
  /* eslint-disable class-methods-use-this */
1723
1723
  var CustomAnswerLabel = /*#__PURE__*/function () {
@@ -1748,7 +1748,7 @@ var CustomAnswerLabel = /*#__PURE__*/function () {
1748
1748
  var _ref2 = screen || {},
1749
1749
  _ref2$answers = _ref2.answers,
1750
1750
  answers = _ref2$answers === void 0 ? null : _ref2$answers,
1751
- restScreen = _objectWithoutProperties(_ref2, _excluded$4);
1751
+ restScreen = _objectWithoutProperties(_ref2, _excluded$5);
1752
1752
  return _objectSpread(_objectSpread({}, restScreen), {}, {
1753
1753
  answers: answers.map(function () {
1754
1754
  var answer = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
@@ -1768,7 +1768,7 @@ var CustomAnswerLabel = /*#__PURE__*/function () {
1768
1768
  }();
1769
1769
  CustomAnswerLabel.prototype.priority = 1;
1770
1770
 
1771
- var _excluded$3 = ["items"],
1771
+ var _excluded$4 = ["items"],
1772
1772
  _excluded2$1 = ["label", "textStyle"];
1773
1773
 
1774
1774
  /* eslint-disable class-methods-use-this */
@@ -1802,7 +1802,7 @@ var KeypadItemLabel = /*#__PURE__*/function () {
1802
1802
  var _ref2 = screen || {},
1803
1803
  _ref2$items = _ref2.items,
1804
1804
  items = _ref2$items === void 0 ? null : _ref2$items,
1805
- restScreen = _objectWithoutProperties(_ref2, _excluded$3);
1805
+ restScreen = _objectWithoutProperties(_ref2, _excluded$4);
1806
1806
  return _objectSpread(_objectSpread({}, restScreen), {}, {
1807
1807
  items: items.map(function () {
1808
1808
  var item = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
@@ -1826,12 +1826,56 @@ var KeypadItemLabel = /*#__PURE__*/function () {
1826
1826
  }();
1827
1827
  KeypadItemLabel.prototype.priority = 1;
1828
1828
 
1829
+ var _excluded$3 = ["keypadSettings"];
1830
+ /* eslint-disable class-methods-use-this */
1831
+ var KeypadSettings = /*#__PURE__*/function () {
1832
+ function KeypadSettings() {
1833
+ _classCallCheck(this, KeypadSettings);
1834
+ }
1835
+ return _createClass(KeypadSettings, [{
1836
+ key: "test",
1837
+ value: function test(screen) {
1838
+ var _ref = screen || {},
1839
+ _ref$type = _ref.type,
1840
+ type = _ref$type === void 0 ? null : _ref$type,
1841
+ _ref$keypadSettings = _ref.keypadSettings,
1842
+ keypadSettings = _ref$keypadSettings === void 0 ? null : _ref$keypadSettings;
1843
+ if (type !== 'keypad' || keypadSettings === null) {
1844
+ return false;
1845
+ }
1846
+ var _ref2 = keypadSettings || {},
1847
+ _ref2$layout = _ref2.layout,
1848
+ keypadSettingsLayout = _ref2$layout === void 0 ? null : _ref2$layout;
1849
+ if (keypadSettingsLayout === null) {
1850
+ return false;
1851
+ }
1852
+ return true;
1853
+ }
1854
+ }, {
1855
+ key: "parse",
1856
+ value: function parse(screen) {
1857
+ var _ref3 = screen || {},
1858
+ _ref3$keypadSettings = _ref3.keypadSettings,
1859
+ keypadSettings = _ref3$keypadSettings === void 0 ? null : _ref3$keypadSettings,
1860
+ restScreen = _objectWithoutProperties(_ref3, _excluded$3);
1861
+ var _ref4 = keypadSettings || {},
1862
+ _ref4$layout = _ref4.layout,
1863
+ keypadSettingsLayout = _ref4$layout === void 0 ? null : _ref4$layout;
1864
+ return _objectSpread(_objectSpread({}, restScreen), {}, {
1865
+ keypadLayout: keypadSettingsLayout
1866
+ });
1867
+ }
1868
+ }]);
1869
+ }();
1870
+ KeypadSettings.prototype.priority = 1;
1871
+
1829
1872
  // export { default as ButtonPadding } from './ButtonPadding';
1830
1873
 
1831
1874
  var migrations = /*#__PURE__*/Object.freeze({
1832
1875
  __proto__: null,
1833
1876
  CustomAnswerLabel: CustomAnswerLabel,
1834
1877
  KeypadItemLabel: KeypadItemLabel,
1878
+ KeypadSettings: KeypadSettings,
1835
1879
  ShareCall: ShareCall
1836
1880
  });
1837
1881
 
package/lib/index.js CHANGED
@@ -1212,7 +1212,7 @@ var FieldsManager = /*#__PURE__*/function (_DefinitionsManager) {
1212
1212
  }]);
1213
1213
  }(DefinitionsManager);
1214
1214
 
1215
- var _excluded$7 = ["medias"],
1215
+ var _excluded$8 = ["medias"],
1216
1216
  _excluded2$3 = ["medias"];
1217
1217
  var MediasParser = /*#__PURE__*/function () {
1218
1218
  function MediasParser(_ref) {
@@ -1232,7 +1232,7 @@ var MediasParser = /*#__PURE__*/function () {
1232
1232
  if (typeof this.parsedThemesCache[storyId] === 'undefined') {
1233
1233
  var _this$toPath = this.toPath(theme),
1234
1234
  themeMedias = _this$toPath.medias,
1235
- newTheme = _objectWithoutProperties(_this$toPath, _excluded$7);
1235
+ newTheme = _objectWithoutProperties(_this$toPath, _excluded$8);
1236
1236
  this.parsedThemesCache[storyId] = {
1237
1237
  themeMedias: themeMedias,
1238
1238
  newTheme: newTheme
@@ -1538,7 +1538,7 @@ var ScreensManager = /*#__PURE__*/function (_DefinitionsManager) {
1538
1538
  }]);
1539
1539
  }(DefinitionsManager);
1540
1540
 
1541
- var _excluded$6 = ["fonts"];
1541
+ var _excluded$7 = ["fonts"];
1542
1542
  var FontsParser = /*#__PURE__*/function () {
1543
1543
  function FontsParser(_ref) {
1544
1544
  var fieldsManager = _ref.fieldsManager,
@@ -1587,7 +1587,7 @@ var FontsParser = /*#__PURE__*/function () {
1587
1587
  var _this$parse = this.parse(theme),
1588
1588
  _this$parse$fonts = _this$parse.fonts,
1589
1589
  themeFonts = _this$parse$fonts === void 0 ? [] : _this$parse$fonts,
1590
- newTheme = _objectWithoutProperties(_this$parse, _excluded$6);
1590
+ newTheme = _objectWithoutProperties(_this$parse, _excluded$7);
1591
1591
  return fonts.length > 0 || themeFonts.length > 0 ? _objectSpread(_objectSpread({}, story), {}, {
1592
1592
  theme: newTheme,
1593
1593
  fonts: uniq([].concat(_toConsumableArray(themeFonts), _toConsumableArray(fonts)), 'name')
@@ -1663,7 +1663,7 @@ var FontsParser = /*#__PURE__*/function () {
1663
1663
  }]);
1664
1664
  }();
1665
1665
 
1666
- var _excluded$5 = ["shareIncentive", "callToAction"];
1666
+ var _excluded$6 = ["shareIncentive", "callToAction"];
1667
1667
  /* eslint-disable class-methods-use-this */
1668
1668
  var ShareCall = /*#__PURE__*/function () {
1669
1669
  function ShareCall() {
@@ -1690,7 +1690,7 @@ var ShareCall = /*#__PURE__*/function () {
1690
1690
  shareIncentive = _ref2$shareIncentive === void 0 ? null : _ref2$shareIncentive,
1691
1691
  _ref2$callToAction = _ref2.callToAction,
1692
1692
  callToAction = _ref2$callToAction === void 0 ? null : _ref2$callToAction,
1693
- restScreen = _objectWithoutProperties(_ref2, _excluded$5);
1693
+ restScreen = _objectWithoutProperties(_ref2, _excluded$6);
1694
1694
  var _ref3 = screen || {},
1695
1695
  _ref3$header = _ref3.header,
1696
1696
  header = _ref3$header === void 0 ? null : _ref3$header,
@@ -1719,7 +1719,7 @@ var ShareCall = /*#__PURE__*/function () {
1719
1719
  }();
1720
1720
  ShareCall.prototype.priority = 0;
1721
1721
 
1722
- var _excluded$4 = ["answers"],
1722
+ var _excluded$5 = ["answers"],
1723
1723
  _excluded2$2 = ["customAnswerLabel"];
1724
1724
  /* eslint-disable class-methods-use-this */
1725
1725
  var CustomAnswerLabel = /*#__PURE__*/function () {
@@ -1750,7 +1750,7 @@ var CustomAnswerLabel = /*#__PURE__*/function () {
1750
1750
  var _ref2 = screen || {},
1751
1751
  _ref2$answers = _ref2.answers,
1752
1752
  answers = _ref2$answers === void 0 ? null : _ref2$answers,
1753
- restScreen = _objectWithoutProperties(_ref2, _excluded$4);
1753
+ restScreen = _objectWithoutProperties(_ref2, _excluded$5);
1754
1754
  return _objectSpread(_objectSpread({}, restScreen), {}, {
1755
1755
  answers: answers.map(function () {
1756
1756
  var answer = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
@@ -1770,7 +1770,7 @@ var CustomAnswerLabel = /*#__PURE__*/function () {
1770
1770
  }();
1771
1771
  CustomAnswerLabel.prototype.priority = 1;
1772
1772
 
1773
- var _excluded$3 = ["items"],
1773
+ var _excluded$4 = ["items"],
1774
1774
  _excluded2$1 = ["label", "textStyle"];
1775
1775
 
1776
1776
  /* eslint-disable class-methods-use-this */
@@ -1804,7 +1804,7 @@ var KeypadItemLabel = /*#__PURE__*/function () {
1804
1804
  var _ref2 = screen || {},
1805
1805
  _ref2$items = _ref2.items,
1806
1806
  items = _ref2$items === void 0 ? null : _ref2$items,
1807
- restScreen = _objectWithoutProperties(_ref2, _excluded$3);
1807
+ restScreen = _objectWithoutProperties(_ref2, _excluded$4);
1808
1808
  return _objectSpread(_objectSpread({}, restScreen), {}, {
1809
1809
  items: items.map(function () {
1810
1810
  var item = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : null;
@@ -1828,12 +1828,56 @@ var KeypadItemLabel = /*#__PURE__*/function () {
1828
1828
  }();
1829
1829
  KeypadItemLabel.prototype.priority = 1;
1830
1830
 
1831
+ var _excluded$3 = ["keypadSettings"];
1832
+ /* eslint-disable class-methods-use-this */
1833
+ var KeypadSettings = /*#__PURE__*/function () {
1834
+ function KeypadSettings() {
1835
+ _classCallCheck(this, KeypadSettings);
1836
+ }
1837
+ return _createClass(KeypadSettings, [{
1838
+ key: "test",
1839
+ value: function test(screen) {
1840
+ var _ref = screen || {},
1841
+ _ref$type = _ref.type,
1842
+ type = _ref$type === void 0 ? null : _ref$type,
1843
+ _ref$keypadSettings = _ref.keypadSettings,
1844
+ keypadSettings = _ref$keypadSettings === void 0 ? null : _ref$keypadSettings;
1845
+ if (type !== 'keypad' || keypadSettings === null) {
1846
+ return false;
1847
+ }
1848
+ var _ref2 = keypadSettings || {},
1849
+ _ref2$layout = _ref2.layout,
1850
+ keypadSettingsLayout = _ref2$layout === void 0 ? null : _ref2$layout;
1851
+ if (keypadSettingsLayout === null) {
1852
+ return false;
1853
+ }
1854
+ return true;
1855
+ }
1856
+ }, {
1857
+ key: "parse",
1858
+ value: function parse(screen) {
1859
+ var _ref3 = screen || {},
1860
+ _ref3$keypadSettings = _ref3.keypadSettings,
1861
+ keypadSettings = _ref3$keypadSettings === void 0 ? null : _ref3$keypadSettings,
1862
+ restScreen = _objectWithoutProperties(_ref3, _excluded$3);
1863
+ var _ref4 = keypadSettings || {},
1864
+ _ref4$layout = _ref4.layout,
1865
+ keypadSettingsLayout = _ref4$layout === void 0 ? null : _ref4$layout;
1866
+ return _objectSpread(_objectSpread({}, restScreen), {}, {
1867
+ keypadLayout: keypadSettingsLayout
1868
+ });
1869
+ }
1870
+ }]);
1871
+ }();
1872
+ KeypadSettings.prototype.priority = 1;
1873
+
1831
1874
  // export { default as ButtonPadding } from './ButtonPadding';
1832
1875
 
1833
1876
  var migrations = /*#__PURE__*/Object.freeze({
1834
1877
  __proto__: null,
1835
1878
  CustomAnswerLabel: CustomAnswerLabel,
1836
1879
  KeypadItemLabel: KeypadItemLabel,
1880
+ KeypadSettings: KeypadSettings,
1837
1881
  ShareCall: ShareCall
1838
1882
  });
1839
1883
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@micromag/core",
3
- "version": "0.3.814",
3
+ "version": "0.3.820",
4
4
  "private": false,
5
5
  "description": "",
6
6
  "keywords": [
@@ -168,5 +168,5 @@
168
168
  "access": "public",
169
169
  "registry": "https://registry.npmjs.org/"
170
170
  },
171
- "gitHead": "96d19c8ede8dc2e8c051ba118975258e061a8da2"
171
+ "gitHead": "c4ef0ae4055720a367551328e824ad3b111e4c9f"
172
172
  }