ui-kit-ck-consultant 0.5.276 → 0.5.278
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/dist/index.js +10 -2
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +10 -2
- package/dist/index.modern.js.map +1 -1
- package/package.json +1 -1
package/dist/index.js
CHANGED
@@ -360,6 +360,7 @@ var FormInput = /*#__PURE__*/function (_React$Component) {
|
|
360
360
|
}, "*") : '') : '', /*#__PURE__*/React__default.createElement("div", {
|
361
361
|
className: style$2.form_input_container_icon
|
362
362
|
}, /*#__PURE__*/React__default.createElement("div", null, this.props.children), /*#__PURE__*/React__default.createElement("input", {
|
363
|
+
autoFocus: this.props.autoFocus,
|
363
364
|
style: this.props.styleInput,
|
364
365
|
className: style$2.form_input_icon,
|
365
366
|
type: this.props.type,
|
@@ -384,6 +385,7 @@ var FormInput = /*#__PURE__*/function (_React$Component) {
|
|
384
385
|
}, this.props.title, ' ', this.props.required ? /*#__PURE__*/React__default.createElement("span", {
|
385
386
|
className: "red"
|
386
387
|
}, "*") : '') : '', /*#__PURE__*/React__default.createElement("input", {
|
388
|
+
autoFocus: this.props.autoFocus,
|
387
389
|
style: this.props.styleInput,
|
388
390
|
className: style$2.form_input,
|
389
391
|
type: this.props.type,
|
@@ -4286,7 +4288,7 @@ var Gauge = /*#__PURE__*/function (_React$Component) {
|
|
4286
4288
|
_this = _React$Component.call(this, props) || this;
|
4287
4289
|
|
4288
4290
|
_this.eventMouseUp = function () {
|
4289
|
-
if (_this.state.
|
4291
|
+
if (_this.state.isActive) {
|
4290
4292
|
_this.setState({
|
4291
4293
|
isActive: false
|
4292
4294
|
});
|
@@ -4303,7 +4305,13 @@ var Gauge = /*#__PURE__*/function (_React$Component) {
|
|
4303
4305
|
var width = currentTargetRect.width;
|
4304
4306
|
var positionX = e.pageX - currentTargetRect.left;
|
4305
4307
|
var step = _this.props.step ? _this.props.step : 1;
|
4306
|
-
var position = positionX * 100 / width - positionX * 100 / width % step;
|
4308
|
+
var position = Math.round(positionX * 100 / width) - Math.round(positionX * 100 / width) % step;
|
4309
|
+
|
4310
|
+
if (position > 100) {
|
4311
|
+
position = 100;
|
4312
|
+
} else if (position < 0) {
|
4313
|
+
position = 0;
|
4314
|
+
}
|
4307
4315
|
|
4308
4316
|
_this.setState({
|
4309
4317
|
position: position
|