@sheinx/hooks 3.6.1 → 3.6.2-beta.1
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/cjs/components/use-datepicker/use-datepicker-format.d.ts.map +1 -1
- package/cjs/components/use-datepicker/use-datepicker-format.js +3 -1
- package/esm/components/use-datepicker/use-datepicker-format.d.ts.map +1 -1
- package/esm/components/use-datepicker/use-datepicker-format.js +3 -1
- package/package.json +1 -1
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"use-datepicker-format.d.ts","sourceRoot":"","sources":["use-datepicker-format.ts"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,KAAK,EACV,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AAkEtC,QAAA,MAAM,mBAAmB;;;;;;;;;;;;;;;;;
|
1
|
+
{"version":3,"file":"use-datepicker-format.d.ts","sourceRoot":"","sources":["use-datepicker-format.ts"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,KAAK,EACV,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AAkEtC,QAAA,MAAM,mBAAmB;;;;;;;;;;;;;;;;;0BA2Me,gBAAgB;sCAiEJ,MAAM;iCA7BX,MAAM,SAAS,MAAM;yCA5LrD,OAAO,GAAG,KAAK,GAAG,SAAS,QAAQ,MAAM,UAAU,IAAI,KAAK,OAAO;uCAWvE,MAAM,cAAc,CAAC,IAAI,EAAE,CAAC,QAC3B,MAAM;kBACG,MAAM,SAAS;mBAAS,GAAG;;+BA4CrC,IAAI,YAAY,OAAO,GAAG,KAAK,GAAG,SAAS,gBAAgB,MAAM;;CA4N3E,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
@@ -195,6 +195,9 @@ var useDatePickerFormat = function useDatePickerFormat(props) {
|
|
195
195
|
var mode = getTypeMode(type);
|
196
196
|
var disabled = position === 'end' ? context.modeDisabledEnd[mode] : context.modeDisabledStart[mode];
|
197
197
|
var isDisabled = disabled ? disabled(date) : false;
|
198
|
+
if (triggerType === 'input' && !isDisabled) {
|
199
|
+
isDisabled = isDisabledInputDate(position === 'end' ? [currentArr[0], date] : [date, currentArr[1]]);
|
200
|
+
}
|
198
201
|
if (type === 'datetime' && !isDisabled) {
|
199
202
|
var disabledTime = position === 'end' ? context.modeDisabledEnd['time'] : context.modeDisabledStart['time'];
|
200
203
|
isDisabled = disabledTime ? disabledTime(date, triggerType) : false;
|
@@ -263,7 +266,6 @@ var useDatePickerFormat = function useDatePickerFormat(props) {
|
|
263
266
|
formatValue = getFormatValueArr(inputValue);
|
264
267
|
}
|
265
268
|
}
|
266
|
-
// const formatValue = getFormatValueArr(stateDate);
|
267
269
|
var v = range ? formatValue : formatValue[0];
|
268
270
|
if (range && (!stateDate[0] || !stateDate[1]) && !props.allowSingle) {
|
269
271
|
return;
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"use-datepicker-format.d.ts","sourceRoot":"","sources":["use-datepicker-format.ts"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,KAAK,EACV,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AAkEtC,QAAA,MAAM,mBAAmB;;;;;;;;;;;;;;;;;
|
1
|
+
{"version":3,"file":"use-datepicker-format.d.ts","sourceRoot":"","sources":["use-datepicker-format.ts"],"names":[],"mappings":"AAAA,OAAO,KAAsC,MAAM,OAAO,CAAC;AAE3D,OAAO,KAAK,EACV,kBAAkB,EAClB,mBAAmB,EACnB,wBAAwB,EACzB,MAAM,8BAA8B,CAAC;AAkEtC,QAAA,MAAM,mBAAmB;;;;;;;;;;;;;;;;;0BA2Me,gBAAgB;sCAiEJ,MAAM;iCA7BX,MAAM,SAAS,MAAM;yCA5LrD,OAAO,GAAG,KAAK,GAAG,SAAS,QAAQ,MAAM,UAAU,IAAI,KAAK,OAAO;uCAWvE,MAAM,cAAc,CAAC,IAAI,EAAE,CAAC,QAC3B,MAAM;kBACG,MAAM,SAAS;mBAAS,GAAG;;+BA4CrC,IAAI,YAAY,OAAO,GAAG,KAAK,GAAG,SAAS,gBAAgB,MAAM;;CA4N3E,CAAC;AAEF,eAAe,mBAAmB,CAAC"}
|
@@ -188,6 +188,9 @@ var useDatePickerFormat = function useDatePickerFormat(props) {
|
|
188
188
|
var mode = getTypeMode(type);
|
189
189
|
var disabled = position === 'end' ? context.modeDisabledEnd[mode] : context.modeDisabledStart[mode];
|
190
190
|
var isDisabled = disabled ? disabled(date) : false;
|
191
|
+
if (triggerType === 'input' && !isDisabled) {
|
192
|
+
isDisabled = isDisabledInputDate(position === 'end' ? [currentArr[0], date] : [date, currentArr[1]]);
|
193
|
+
}
|
191
194
|
if (type === 'datetime' && !isDisabled) {
|
192
195
|
var disabledTime = position === 'end' ? context.modeDisabledEnd['time'] : context.modeDisabledStart['time'];
|
193
196
|
isDisabled = disabledTime ? disabledTime(date, triggerType) : false;
|
@@ -256,7 +259,6 @@ var useDatePickerFormat = function useDatePickerFormat(props) {
|
|
256
259
|
formatValue = getFormatValueArr(inputValue);
|
257
260
|
}
|
258
261
|
}
|
259
|
-
// const formatValue = getFormatValueArr(stateDate);
|
260
262
|
var v = range ? formatValue : formatValue[0];
|
261
263
|
if (range && (!stateDate[0] || !stateDate[1]) && !props.allowSingle) {
|
262
264
|
return;
|