@hero-design/rn 8.46.1 → 8.46.2
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/.turbo/turbo-build.log +2 -2
- package/CHANGELOG.md +6 -0
- package/es/index.js +1 -1
- package/lib/index.js +1 -1
- package/package.json +1 -1
- package/src/components/DatePicker/useCalculateDate.tsx +1 -1
package/.turbo/turbo-build.log
CHANGED
|
@@ -3,6 +3,6 @@ $ rollup -c
|
|
|
3
3
|
[36m
|
|
4
4
|
[1msrc/index.ts[22m → [1mlib/index.js, es/index.js[22m...[39m
|
|
5
5
|
[1m[33m(!) Plugin replace: @rollup/plugin-replace: 'preventAssignment' currently defaults to false. It is recommended to set this option to `true`, as the next major version will default this option to `true`.[39m[22m
|
|
6
|
-
[1m[33m(!) Plugin node-resolve: preferring built-in module 'events' over local alternative at '/
|
|
7
|
-
[32mcreated [1mlib/index.js, es/index.js[22m in [
|
|
6
|
+
[1m[33m(!) Plugin node-resolve: preferring built-in module 'events' over local alternative at '/runner/_work/hero-design/hero-design/node_modules/events/events.js', pass 'preferBuiltins: false' to disable this behavior or 'preferBuiltins: true' to disable this warning[39m[22m
|
|
7
|
+
[32mcreated [1mlib/index.js, es/index.js[22m in [1m22s[22m[39m
|
|
8
8
|
$ tsc --noEmit false --emitDeclarationOnly --project tsconfig.prod.json
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @hero-design/rn
|
|
2
2
|
|
|
3
|
+
## 8.46.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#2432](https://github.com/Thinkei/hero-design/pull/2432) [`82d119eb0`](https://github.com/Thinkei/hero-design/commit/82d119eb076b934474494eeaa49ae51abfc245d5) Thanks [@vinhphan-eh](https://github.com/vinhphan-eh)! - [DatePicker] Update useCalculateDate comparison logic
|
|
8
|
+
|
|
3
9
|
## 8.46.1
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/es/index.js
CHANGED
|
@@ -13099,7 +13099,7 @@ var useCalculateDate = function useCalculateDate(_ref) {
|
|
|
13099
13099
|
value = _ref.value;
|
|
13100
13100
|
useEffect(function () {
|
|
13101
13101
|
var newDate = getDateValue(value || new Date(), minDate, maxDate);
|
|
13102
|
-
if (newDate !== value) {
|
|
13102
|
+
if (value && newDate.toDateString() !== value.toDateString()) {
|
|
13103
13103
|
onChange(newDate);
|
|
13104
13104
|
}
|
|
13105
13105
|
}, [maxDate, minDate, value]);
|
package/lib/index.js
CHANGED
|
@@ -13129,7 +13129,7 @@ var useCalculateDate = function useCalculateDate(_ref) {
|
|
|
13129
13129
|
value = _ref.value;
|
|
13130
13130
|
React.useEffect(function () {
|
|
13131
13131
|
var newDate = getDateValue(value || new Date(), minDate, maxDate);
|
|
13132
|
-
if (newDate !== value) {
|
|
13132
|
+
if (value && newDate.toDateString() !== value.toDateString()) {
|
|
13133
13133
|
onChange(newDate);
|
|
13134
13134
|
}
|
|
13135
13135
|
}, [maxDate, minDate, value]);
|
package/package.json
CHANGED
|
@@ -25,7 +25,7 @@ const useCalculateDate = ({
|
|
|
25
25
|
}: Pick<DatePickerProps, 'maxDate' | 'minDate' | 'onChange' | 'value'>) => {
|
|
26
26
|
useEffect(() => {
|
|
27
27
|
const newDate = getDateValue(value || new Date(), minDate, maxDate);
|
|
28
|
-
if (newDate !== value) {
|
|
28
|
+
if (value && newDate.toDateString() !== value.toDateString()) {
|
|
29
29
|
onChange(newDate);
|
|
30
30
|
}
|
|
31
31
|
}, [maxDate, minDate, value]);
|