@hipay/hipay-material-ui 1.0.0-beta.3 → 1.0.0-beta.4
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/HiDatePicker/HiDatePicker.js +12 -14
- package/HiForm/HiFormControl.js +4 -1
- package/HiForm/HiInput.js +4 -4
- package/HiForm/HiSearchField.js +1 -1
- package/HiSelect/HiSelect.js +285 -257
- package/HiSelect/HiSelectField.js +8 -6
- package/HiSelect/HiSuggestSelect.js +25 -47
- package/HiSelect/HiSuggestSelectField.js +88 -80
- package/HiSelect/SelectInput.js +32 -21
- package/HiSelectableList/HiSelectableListItem.js +3 -0
- package/HiTopBar/HiTopBar.js +16 -12
- package/es/HiDatePicker/HiDatePicker.js +12 -14
- package/es/HiForm/HiFormControl.js +4 -1
- package/es/HiForm/HiInput.js +4 -4
- package/es/HiForm/HiSearchField.js +1 -1
- package/es/HiSelect/HiSelect.js +261 -229
- package/es/HiSelect/HiSelectField.js +9 -7
- package/es/HiSelect/HiSuggestSelect.js +24 -39
- package/es/HiSelect/HiSuggestSelectField.js +77 -69
- package/es/HiSelect/SelectInput.js +42 -21
- package/es/HiSelectableList/HiSelectableListItem.js +3 -0
- package/es/HiTopBar/HiTopBar.js +16 -8
- package/index.es.js +1 -1
- package/index.js +1 -1
- package/package.json +1 -1
- package/umd/hipay-material-ui.development.js +8684 -8694
- package/umd/hipay-material-ui.production.min.js +5 -5
@@ -131,21 +131,19 @@ var HiDatePicker = function (_React$Component) {
|
|
131
131
|
}, {
|
132
132
|
key: 'handleDayChange',
|
133
133
|
value: function handleDayChange(day, modifiers) {
|
134
|
-
if (
|
135
|
-
|
136
|
-
|
137
|
-
|
138
|
-
|
139
|
-
|
140
|
-
if (this.props.
|
141
|
-
|
142
|
-
|
143
|
-
|
144
|
-
day.setHours(0, 0);
|
145
|
-
}
|
134
|
+
if (modifiers.selected) {
|
135
|
+
// Deselect day
|
136
|
+
this.props.onChange(undefined);
|
137
|
+
} else {
|
138
|
+
// Keep Time if set
|
139
|
+
if (this.props.enableTime && day !== undefined) {
|
140
|
+
if (this.props.value) {
|
141
|
+
day.setHours(this.props.value.getHours(), this.props.value.getMinutes());
|
142
|
+
} else {
|
143
|
+
day.setHours(0, 0);
|
146
144
|
}
|
147
|
-
this.props.onChange(day);
|
148
145
|
}
|
146
|
+
this.props.onChange(day);
|
149
147
|
}
|
150
148
|
if (day instanceof Date && !this.props.enableTime && modifiers.selected !== true) {
|
151
149
|
// Hide overlay & remove focus on input
|
@@ -400,7 +398,7 @@ HiDatePicker.propTypes = process.env.NODE_ENV !== "production" ? {
|
|
400
398
|
*
|
401
399
|
* @param {Date} date sélectionnée
|
402
400
|
*/
|
403
|
-
onChange: _propTypes2.default.func,
|
401
|
+
onChange: _propTypes2.default.func.isRequired,
|
404
402
|
/**
|
405
403
|
* Callback au reset de l'input
|
406
404
|
*/
|
package/HiForm/HiFormControl.js
CHANGED
@@ -163,10 +163,13 @@ var HiFormControl = function (_React$PureComponent) {
|
|
163
163
|
|
164
164
|
(0, _createClass3.default)(HiFormControl, [{
|
165
165
|
key: 'handleHelperClick',
|
166
|
-
value: function handleHelperClick() {
|
166
|
+
value: function handleHelperClick(event) {
|
167
167
|
this.setState(function (prevState) {
|
168
168
|
return { helperOpen: !prevState.helperOpen };
|
169
169
|
});
|
170
|
+
if (event) {
|
171
|
+
event.preventDefault();
|
172
|
+
}
|
170
173
|
}
|
171
174
|
}, {
|
172
175
|
key: 'handleFocus',
|
package/HiForm/HiInput.js
CHANGED
@@ -124,7 +124,7 @@ var styles = exports.styles = function styles(theme) {
|
|
124
124
|
rightIcon: {
|
125
125
|
margin: '0 8px',
|
126
126
|
width: 18,
|
127
|
-
height:
|
127
|
+
height: 39,
|
128
128
|
color: theme.palette.neutral.normal
|
129
129
|
},
|
130
130
|
rightIconFocus: {
|
@@ -147,10 +147,10 @@ var styles = exports.styles = function styles(theme) {
|
|
147
147
|
padding: 0
|
148
148
|
}),
|
149
149
|
inputText: {
|
150
|
-
height:
|
150
|
+
height: 39
|
151
151
|
},
|
152
152
|
inputTextarea: {
|
153
|
-
minHeight:
|
153
|
+
minHeight: 39,
|
154
154
|
paddingTop: 8
|
155
155
|
},
|
156
156
|
iconPointer: {
|
@@ -158,7 +158,7 @@ var styles = exports.styles = function styles(theme) {
|
|
158
158
|
cursor: 'pointer'
|
159
159
|
},
|
160
160
|
eraseButton: {
|
161
|
-
height:
|
161
|
+
height: 39,
|
162
162
|
width: 40,
|
163
163
|
display: 'inline-block'
|
164
164
|
},
|
package/HiForm/HiSearchField.js
CHANGED