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.cjs
CHANGED
@@ -1039,8 +1039,8 @@ var DropDown = function DropDown(props) {
|
|
1039
1039
|
options = _props$options === void 0 ? [] : _props$options,
|
1040
1040
|
value = props.value,
|
1041
1041
|
onChange = props.onChange,
|
1042
|
-
_props$
|
1043
|
-
|
1042
|
+
_props$predictive = props.predictive,
|
1043
|
+
predictive = _props$predictive === void 0 ? false : _props$predictive,
|
1044
1044
|
_props$readOnly3 = props.readOnly,
|
1045
1045
|
readOnly = _props$readOnly3 === void 0 ? false : _props$readOnly3;
|
1046
1046
|
|
@@ -1065,7 +1065,7 @@ var DropDown = function DropDown(props) {
|
|
1065
1065
|
}, [value]);
|
1066
1066
|
|
1067
1067
|
function change(id, value) {
|
1068
|
-
if (
|
1068
|
+
if (predictive) {
|
1069
1069
|
setLabel(value);
|
1070
1070
|
} else {
|
1071
1071
|
if (onChange) onChange(id, value);
|
@@ -1098,7 +1098,7 @@ var DropDown = function DropDown(props) {
|
|
1098
1098
|
var canShow = open == true && Array.isArray(options);
|
1099
1099
|
|
1100
1100
|
if (canShow) {
|
1101
|
-
var filterActive =
|
1101
|
+
var filterActive = predictive === true && label && label.length > 0;
|
1102
1102
|
var items = filterActive ? options.filter(function (option) {
|
1103
1103
|
return option.label.toUpperCase().indexOf(label.toUpperCase()) >= 0;
|
1104
1104
|
}) : options;
|