@signalplus/params-about 0.1.44 → 0.1.47

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/index.d.ts CHANGED
@@ -127,6 +127,10 @@ interface ParamValueEditorData {
127
127
  valueId?: string;
128
128
  [key: string]: any;
129
129
  };
130
+ defaultValue?: {
131
+ valueId?: string;
132
+ [key: string]: any;
133
+ };
130
134
  }
131
135
  interface ParamValueEditorProps {
132
136
  allParams: ParentSelectorProps['parentOptions'];
package/lib/es/index.js CHANGED
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * Bundle of @signalplus/params-about
3
- * Generated: 2022-04-19
4
- * Version: 0.1.44
3
+ * Generated: 2022-04-27
4
+ * Version: 0.1.47
5
5
  * License: MIT
6
6
  * Author: 2631541504@qq.com
7
7
  */
@@ -810,7 +810,7 @@ var Expiries = /*#__PURE__*/function (_PureComponent) {
810
810
 
811
811
  var placeholder = /*#__PURE__*/React.createElement("span", {
812
812
  className: "param-expiries-placeholder"
813
- }, "Choose an expiry");
813
+ }, "Choose");
814
814
 
815
815
  if (this.props.multiple === false) {
816
816
  var _this$props$value2;
@@ -1594,6 +1594,7 @@ var ParamFormModal = /*#__PURE__*/function () {
1594
1594
  _createClass(ParamFormModal, null, [{
1595
1595
  key: "show",
1596
1596
  value: function show(props) {
1597
+ window.addEventListener('popstate', ParamFormModal.hide);
1597
1598
  return ParamFormModal.el.render(props).then(function () {
1598
1599
  ParamFormModal.el.ref.onShow();
1599
1600
  });
@@ -1601,6 +1602,7 @@ var ParamFormModal = /*#__PURE__*/function () {
1601
1602
  }, {
1602
1603
  key: "hide",
1603
1604
  value: function hide() {
1605
+ window.removeEventListener('popstate', ParamFormModal.hide);
1604
1606
  return ParamFormModal.el.render().then(function () {
1605
1607
  ParamFormModal.el.ref.onHide();
1606
1608
  });
@@ -1665,6 +1667,18 @@ var ParamValueEditor = /*#__PURE__*/function (_PureComponent) {
1665
1667
  }
1666
1668
  }, props.value || '-');
1667
1669
  }
1670
+ }, {
1671
+ label: 'Default Value',
1672
+ name: 'defaultValue',
1673
+ className: 'param-default-value',
1674
+ Comp: function Comp(props) {
1675
+ console.log("props", props);
1676
+ return /*#__PURE__*/React.createElement(ParamRenderer, Object.assign({}, props, {
1677
+ readonly: true,
1678
+ expiriesOptions: _this2.props.expiriesOptions,
1679
+ valueType: _this2.props.valueType
1680
+ }));
1681
+ }
1668
1682
  }, {
1669
1683
  label: 'Value before',
1670
1684
  name: 'valueBefore',
@@ -1820,6 +1834,7 @@ var ParamValueEditorModal = /*#__PURE__*/function () {
1820
1834
  _createClass(ParamValueEditorModal, null, [{
1821
1835
  key: "show",
1822
1836
  value: function show(props) {
1837
+ window.addEventListener('popstate', ParamValueEditorModal.hide);
1823
1838
  return ParamValueEditorModal.el.render(props).then(function () {
1824
1839
  ParamValueEditorModal.el.ref.onShow();
1825
1840
  });
@@ -1827,6 +1842,7 @@ var ParamValueEditorModal = /*#__PURE__*/function () {
1827
1842
  }, {
1828
1843
  key: "hide",
1829
1844
  value: function hide() {
1845
+ window.removeEventListener('popstate', ParamValueEditorModal.hide);
1830
1846
  return ParamValueEditorModal.el.render().then(function () {
1831
1847
  ParamValueEditorModal.el.ref.onHide();
1832
1848
  });
@@ -2099,6 +2115,7 @@ var ParamGroupEditorModal = /*#__PURE__*/function () {
2099
2115
  _createClass(ParamGroupEditorModal, null, [{
2100
2116
  key: "show",
2101
2117
  value: function show(props) {
2118
+ window.addEventListener('popstate', ParamGroupEditorModal.hide);
2102
2119
  return ParamGroupEditorModal.el.render(props).then(function () {
2103
2120
  ParamGroupEditorModal.el.ref.onShow();
2104
2121
  });
@@ -2106,6 +2123,7 @@ var ParamGroupEditorModal = /*#__PURE__*/function () {
2106
2123
  }, {
2107
2124
  key: "hide",
2108
2125
  value: function hide() {
2126
+ window.removeEventListener('popstate', ParamGroupEditorModal.hide);
2109
2127
  return ParamGroupEditorModal.el.render().then(function () {
2110
2128
  ParamGroupEditorModal.el.ref.onHide();
2111
2129
  });
@@ -2380,6 +2398,7 @@ var ParamMoverModal = /*#__PURE__*/function () {
2380
2398
  _createClass(ParamMoverModal, null, [{
2381
2399
  key: "show",
2382
2400
  value: function show(props) {
2401
+ window.addEventListener('popstate', ParamMoverModal.hide);
2383
2402
  return ParamMoverModal.el.render(props).then(function () {
2384
2403
  ParamMoverModal.el.ref.onShow();
2385
2404
  });
@@ -2387,6 +2406,7 @@ var ParamMoverModal = /*#__PURE__*/function () {
2387
2406
  }, {
2388
2407
  key: "hide",
2389
2408
  value: function hide() {
2409
+ window.removeEventListener('popstate', ParamMoverModal.hide);
2390
2410
  return ParamMoverModal.el.render().then(function () {
2391
2411
  ParamMoverModal.el.ref.onHide();
2392
2412
  });
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@signalplus/params-about",
3
- "version": "0.1.44",
3
+ "version": "0.1.47",
4
4
  "description": "A description for the module",
5
5
  "main": "./lib/umd/index.js",
6
6
  "module": "./lib/es/index.js",