@gpa-gemstone/react-forms 1.1.59 → 1.1.60

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.
@@ -36,6 +36,7 @@ Object.defineProperty(exports, "__esModule", { value: true });
36
36
  var React = require("react");
37
37
  var HelperMessage_1 = require("./HelperMessage");
38
38
  var helper_functions_1 = require("@gpa-gemstone/helper-functions");
39
+ var lodash_1 = require("lodash");
39
40
  function StylableSelect(props) {
40
41
  var _a = React.useState(false), show = _a[0], setShow = _a[1];
41
42
  var _b = React.useState(props.Options[0].Element), selected = _b[0], setSelected = _b[1];
@@ -68,10 +69,10 @@ function StylableSelect(props) {
68
69
  };
69
70
  }, []);
70
71
  React.useEffect(function () {
71
- var element = props.Options.find(function (e) { return e.Value === props.Record[props.Field]; });
72
+ var element = props.Options.find(function (e) { return (0, lodash_1.isEqual)(e.Value, props.Record[props.Field]); });
72
73
  setSelected(element !== undefined ? element.Element : React.createElement("div", null));
73
74
  }, [props.Record, props.Options]);
74
- return (React.createElement("div", { ref: stylableSelect, style: { position: 'relative', display: 'inline-block', width: 'inherit' } },
75
+ return (React.createElement("div", { ref: stylableSelect, style: { position: 'absolute', display: 'inline-block', width: 'inherit' } },
75
76
  (props.Label !== "") ?
76
77
  React.createElement("label", null,
77
78
  props.Label === undefined ? props.Field : props.Label,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gpa-gemstone/react-forms",
3
- "version": "1.1.59",
3
+ "version": "1.1.60",
4
4
  "description": "React Form modules for gpa webapps",
5
5
  "main": "lib/index.js",
6
6
  "types": "lib/index.d.ts",