ywana-core8 0.0.244 → 0.0.245
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.cjs +4 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.modern.js +4 -4
- package/dist/index.modern.js.map +1 -1
- package/dist/index.umd.js +4 -4
- package/dist/index.umd.js.map +1 -1
- package/package.json +1 -1
- package/src/html/textfield.js +3 -3
- package/src/html/textfield.test.js +12 -4
- package/src/widgets/login/LoginBox.test.js +11 -0
package/dist/index.modern.js
CHANGED
@@ -1031,8 +1031,8 @@ var DropDown = function DropDown(props) {
|
|
1031
1031
|
options = _props$options === void 0 ? [] : _props$options,
|
1032
1032
|
value = props.value,
|
1033
1033
|
onChange = props.onChange,
|
1034
|
-
_props$
|
1035
|
-
|
1034
|
+
_props$predictive = props.predictive,
|
1035
|
+
predictive = _props$predictive === void 0 ? false : _props$predictive,
|
1036
1036
|
_props$readOnly3 = props.readOnly,
|
1037
1037
|
readOnly = _props$readOnly3 === void 0 ? false : _props$readOnly3;
|
1038
1038
|
|
@@ -1057,7 +1057,7 @@ var DropDown = function DropDown(props) {
|
|
1057
1057
|
}, [value]);
|
1058
1058
|
|
1059
1059
|
function change(id, value) {
|
1060
|
-
if (
|
1060
|
+
if (predictive) {
|
1061
1061
|
setLabel(value);
|
1062
1062
|
} else {
|
1063
1063
|
if (onChange) onChange(id, value);
|
@@ -1090,7 +1090,7 @@ var DropDown = function DropDown(props) {
|
|
1090
1090
|
var canShow = open == true && Array.isArray(options);
|
1091
1091
|
|
1092
1092
|
if (canShow) {
|
1093
|
-
var filterActive =
|
1093
|
+
var filterActive = predictive === true && label && label.length > 0;
|
1094
1094
|
var items = filterActive ? options.filter(function (option) {
|
1095
1095
|
return option.label.toUpperCase().indexOf(label.toUpperCase()) >= 0;
|
1096
1096
|
}) : options;
|