wini-web-components 1.7.6 → 1.7.7

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.
@@ -5,6 +5,7 @@ interface CheckboxProps {
5
5
  value?: boolean;
6
6
  checkColor?: string;
7
7
  disabled?: boolean;
8
+ className?: string;
8
9
  style?: CSSProperties;
9
10
  /** default 2.4rem **/
10
11
  size?: number | string;
@@ -50,7 +50,7 @@ var Checkbox = /** @class */ (function (_super) {
50
50
  };
51
51
  Checkbox.prototype.render = function () {
52
52
  var _this = this;
53
- var _a, _b, _c, _d;
53
+ var _a, _b, _c, _d, _e;
54
54
  var convertStyle = {
55
55
  width: (_a = this.props.size) !== null && _a !== void 0 ? _a : '2.4rem',
56
56
  height: (_b = this.props.size) !== null && _b !== void 0 ? _b : '2.4rem',
@@ -64,7 +64,7 @@ var Checkbox = /** @class */ (function (_super) {
64
64
  delete this.props.style.maxHeight;
65
65
  convertStyle = __assign(__assign({}, this.props.style), convertStyle);
66
66
  }
67
- return react_1.default.createElement("label", { id: this.props.id, className: "".concat(checkbox_module_css_1.default['checkbox-container'], " row"), style: convertStyle, "is-null-value": "".concat(this.state.value == undefined), onClick: this.props.onClick },
67
+ return react_1.default.createElement("label", { id: this.props.id, className: "".concat(checkbox_module_css_1.default['checkbox-container'], " row ").concat((_c = this.props.className) !== null && _c !== void 0 ? _c : ''), style: convertStyle, "is-null-value": "".concat(this.state.value == undefined), onClick: this.props.onClick },
68
68
  react_1.default.createElement("input", { type: "checkbox", checked: this.state.value, disabled: this.props.disabled, onChange: function (ev) {
69
69
  ev.stopPropagation();
70
70
  var newValue = !_this.state.value;
@@ -73,8 +73,8 @@ var Checkbox = /** @class */ (function (_super) {
73
73
  _this.props.onChange(newValue);
74
74
  } }),
75
75
  react_1.default.createElement("svg", { width: "100%", height: "100%", viewBox: "0 0 20 20", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, this.state.value == undefined ?
76
- react_1.default.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.79199 9.95298C4.79199 9.69148 5.00398 9.47949 5.26548 9.47949H14.7352C14.9967 9.47949 15.2087 9.69148 15.2087 9.95298C15.2087 10.2145 14.9967 10.4265 14.7352 10.4265H5.26548C5.00398 10.4265 4.79199 10.2145 4.79199 9.95298Z", fill: (_c = this.props.checkColor) !== null && _c !== void 0 ? _c : '#ffffff' }) :
77
- react_1.default.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M15.07 6.49317C15.2549 6.67808 15.2549 6.97787 15.07 7.16278L8.91467 13.3181C8.72977 13.503 8.42997 13.503 8.24507 13.3181L4.93067 10.0037C4.74577 9.81878 4.74577 9.51899 4.93067 9.33408C5.11558 9.14917 5.41537 9.14917 5.60028 9.33408L8.57987 12.3137L14.4004 6.49317C14.5853 6.30827 14.8851 6.30827 15.07 6.49317Z", fill: (_d = this.props.checkColor) !== null && _d !== void 0 ? _d : '#ffffff' })));
76
+ react_1.default.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M4.79199 9.95298C4.79199 9.69148 5.00398 9.47949 5.26548 9.47949H14.7352C14.9967 9.47949 15.2087 9.69148 15.2087 9.95298C15.2087 10.2145 14.9967 10.4265 14.7352 10.4265H5.26548C5.00398 10.4265 4.79199 10.2145 4.79199 9.95298Z", fill: (_d = this.props.checkColor) !== null && _d !== void 0 ? _d : '#ffffff' }) :
77
+ react_1.default.createElement("path", { fillRule: "evenodd", clipRule: "evenodd", d: "M15.07 6.49317C15.2549 6.67808 15.2549 6.97787 15.07 7.16278L8.91467 13.3181C8.72977 13.503 8.42997 13.503 8.24507 13.3181L4.93067 10.0037C4.74577 9.81878 4.74577 9.51899 4.93067 9.33408C5.11558 9.14917 5.41537 9.14917 5.60028 9.33408L8.57987 12.3137L14.4004 6.49317C14.5853 6.30827 14.8851 6.30827 15.07 6.49317Z", fill: (_e = this.props.checkColor) !== null && _e !== void 0 ? _e : '#ffffff' })));
78
78
  };
79
79
  return Checkbox;
80
80
  }(react_1.default.Component));
@@ -4,6 +4,7 @@ interface SwitchProps {
4
4
  onChange?: (value: boolean) => void;
5
5
  value?: boolean;
6
6
  disabled?: boolean;
7
+ className?: string;
7
8
  style?: CSSProperties;
8
9
  size?: number | string;
9
10
  dotColor?: string;
@@ -50,7 +50,7 @@ var Switch = /** @class */ (function (_super) {
50
50
  };
51
51
  Switch.prototype.render = function () {
52
52
  var _this = this;
53
- var _a, _b, _c, _d;
53
+ var _a, _b, _c, _d, _e;
54
54
  var propStyle = {
55
55
  '--off-bg': (_a = this.props.offBackground) !== null && _a !== void 0 ? _a : 'var(--neutral-main-background-color)',
56
56
  '--on-bg': (_b = this.props.onBackground) !== null && _b !== void 0 ? _b : 'var(--infor-main-color)',
@@ -67,7 +67,7 @@ var Switch = /** @class */ (function (_super) {
67
67
  delete this.props.style.maxHeight;
68
68
  convertStyle = __assign(__assign({}, this.props.style), convertStyle);
69
69
  }
70
- return react_1.default.createElement("label", { id: this.props.id, className: "".concat(switch_module_css_1.default['switch-container'], " row"), style: convertStyle },
70
+ return react_1.default.createElement("label", { id: this.props.id, className: "".concat(switch_module_css_1.default['switch-container'], " row ").concat((_e = this.props.className) !== null && _e !== void 0 ? _e : ''), style: convertStyle },
71
71
  react_1.default.createElement("input", { type: "checkbox", checked: this.state.value, name: this.props.name, disabled: this.props.disabled, onChange: function () {
72
72
  var newValue = !_this.state.value;
73
73
  _this.setState({ value: newValue });