@sheinx/base 3.8.10-beta.6 → 3.8.10-beta.7

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.
@@ -34,8 +34,8 @@ var Day = function Day(props) {
34
34
  props.onChange(date, noClose || props.type === 'datetime');
35
35
  props.setTarget(undefined);
36
36
  });
37
- var setCurrent = (0, _hooks.usePersistFn)(function (date) {
38
- props.setCurrent(date, areaType);
37
+ var setCurrent = (0, _hooks.usePersistFn)(function (date, type) {
38
+ props.setCurrent(date, type || areaType);
39
39
  });
40
40
  var _useDatePick = (0, _hooks.useDatePick)({
41
41
  current: props.current,
@@ -23,8 +23,8 @@ var Month = function Month(props) {
23
23
  var changeMode = (0, _hooks.usePersistFn)(function () {
24
24
  props.setMode('day');
25
25
  });
26
- var setCurrent = (0, _hooks.usePersistFn)(function (date) {
27
- props.setCurrent(date, 'month');
26
+ var setCurrent = (0, _hooks.usePersistFn)(function (date, type) {
27
+ props.setCurrent(date, type || 'month');
28
28
  });
29
29
  var _useMonthPick = (0, _hooks.useMonthPick)({
30
30
  current: props.current,
@@ -18,8 +18,8 @@ var Quarter = function Quarter(props) {
18
18
  var jssStyle = props.jssStyle;
19
19
  var config = (0, _config.useConfig)();
20
20
  var styles = jssStyle === null || jssStyle === void 0 || (_jssStyle$datePicker = jssStyle.datePicker) === null || _jssStyle$datePicker === void 0 ? void 0 : _jssStyle$datePicker.call(jssStyle);
21
- var setCurrent = (0, _hooks.usePersistFn)(function (date) {
22
- props.setCurrent(date, 'quarter');
21
+ var setCurrent = (0, _hooks.usePersistFn)(function (date, type) {
22
+ props.setCurrent(date, type || 'quarter');
23
23
  });
24
24
  var _useQuarterPick = (0, _hooks.useQuarterPick)({
25
25
  current: props.current,
@@ -22,8 +22,8 @@ var Year = function Year(props) {
22
22
  var changeMode = (0, _hooks.usePersistFn)(function () {
23
23
  props.setMode('month');
24
24
  });
25
- var setCurrent = (0, _hooks.usePersistFn)(function (date) {
26
- props.setCurrent(date, 'year');
25
+ var setCurrent = (0, _hooks.usePersistFn)(function (date, type) {
26
+ props.setCurrent(date, type || 'year');
27
27
  });
28
28
  var _useYearPick = (0, _hooks.useYearPick)({
29
29
  current: props.current,
@@ -29,8 +29,8 @@ var Day = function Day(props) {
29
29
  props.onChange(date, noClose || props.type === 'datetime');
30
30
  props.setTarget(undefined);
31
31
  });
32
- var setCurrent = usePersistFn(function (date) {
33
- props.setCurrent(date, areaType);
32
+ var setCurrent = usePersistFn(function (date, type) {
33
+ props.setCurrent(date, type || areaType);
34
34
  });
35
35
  var _useDatePick = useDatePick({
36
36
  current: props.current,
@@ -17,8 +17,8 @@ var Month = function Month(props) {
17
17
  var changeMode = usePersistFn(function () {
18
18
  props.setMode('day');
19
19
  });
20
- var setCurrent = usePersistFn(function (date) {
21
- props.setCurrent(date, 'month');
20
+ var setCurrent = usePersistFn(function (date, type) {
21
+ props.setCurrent(date, type || 'month');
22
22
  });
23
23
  var _useMonthPick = useMonthPick({
24
24
  current: props.current,
@@ -12,8 +12,8 @@ var Quarter = function Quarter(props) {
12
12
  var jssStyle = props.jssStyle;
13
13
  var config = useConfig();
14
14
  var styles = jssStyle === null || jssStyle === void 0 || (_jssStyle$datePicker = jssStyle.datePicker) === null || _jssStyle$datePicker === void 0 ? void 0 : _jssStyle$datePicker.call(jssStyle);
15
- var setCurrent = usePersistFn(function (date) {
16
- props.setCurrent(date, 'quarter');
15
+ var setCurrent = usePersistFn(function (date, type) {
16
+ props.setCurrent(date, type || 'quarter');
17
17
  });
18
18
  var _useQuarterPick = useQuarterPick({
19
19
  current: props.current,
@@ -16,8 +16,8 @@ var Year = function Year(props) {
16
16
  var changeMode = usePersistFn(function () {
17
17
  props.setMode('month');
18
18
  });
19
- var setCurrent = usePersistFn(function (date) {
20
- props.setCurrent(date, 'year');
19
+ var setCurrent = usePersistFn(function (date, type) {
20
+ props.setCurrent(date, type || 'year');
21
21
  });
22
22
  var _useYearPick = useYearPick({
23
23
  current: props.current,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sheinx/base",
3
- "version": "3.8.10-beta.6",
3
+ "version": "3.8.10-beta.7",
4
4
  "description": "",
5
5
  "keywords": [],
6
6
  "license": "MIT",
@@ -10,7 +10,7 @@
10
10
  "module": "./esm/index.js",
11
11
  "typings": "./cjs/index.d.ts",
12
12
  "dependencies": {
13
- "@sheinx/hooks": "3.8.10-beta.6",
13
+ "@sheinx/hooks": "3.8.10-beta.7",
14
14
  "immer": "^10.0.0",
15
15
  "classnames": "^2.0.0",
16
16
  "@shined/reactive": "^0.1.3-alpha.0"