@gm-mobile/c-react 3.12.7-beta.1 → 3.12.7-beta.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@gm-mobile/c-react",
3
- "version": "3.12.7-beta.1",
3
+ "version": "3.12.7-beta.2",
4
4
  "description": "> TODO: description",
5
5
  "author": "liyatang <liyatang@qq.com>",
6
6
  "homepage": "https://github.com/gmfe/gm-mobile#readme",
@@ -21,9 +21,9 @@
21
21
  "url": "https://github.com/gmfe/gm-mobile/issues"
22
22
  },
23
23
  "dependencies": {
24
- "@gm-mobile/c-font": "^3.12.7-beta.1",
25
- "@gm-mobile/c-tool": "^3.12.7-beta.1",
26
- "@gm-mobile/locales": "^3.12.7-beta.1",
24
+ "@gm-mobile/c-font": "^3.12.7-beta.2",
25
+ "@gm-mobile/c-tool": "^3.12.7-beta.2",
26
+ "@gm-mobile/locales": "^3.12.7-beta.2",
27
27
  "dayjs": "^1.11.6"
28
28
  },
29
29
  "peerDependencies": {
@@ -34,5 +34,5 @@
34
34
  "prop-types": "^15.7.2",
35
35
  "react": "^16.13.1"
36
36
  },
37
- "gitHead": "9b275d36b99b3612258531c0b44d59a14e672f60"
37
+ "gitHead": "ed1c43a175d8b7af4bc3206ce1944c56b3e48d34"
38
38
  }
@@ -31,6 +31,7 @@ const BaseCalendar: FC<BaseCalendarProps> = ({
31
31
  height = 400,
32
32
  className,
33
33
  style,
34
+ canScrollWhenMaxOrMinChange = false,
34
35
  ...rest
35
36
  }) => {
36
37
  const [isSelectBegin, setIsSelectBegin] = useState(true)
@@ -101,6 +102,7 @@ const BaseCalendar: FC<BaseCalendarProps> = ({
101
102
  ))}
102
103
  </Flex>
103
104
  <MonthsList
105
+ canScrollWhenMaxOrMinChange={canScrollWhenMaxOrMinChange}
104
106
  selected={selected}
105
107
  type={type}
106
108
  height={height - 40} // 固定展示星期头部高度40
@@ -52,6 +52,8 @@ interface BaseCalendarProps
52
52
  disabledDate?: (date: Date) => boolean
53
53
  /** 定义日历高度,默认400 */
54
54
  height?: number
55
+ /** 当min 和max 改变时是否滚动 */
56
+ canScrollWhenMaxOrMinChange: boolean
55
57
  }
56
58
 
57
59
  interface CalendarProps