Commit af60a167 authored by 田翔's avatar 田翔

解决下拉框组件以及时间类组件弹出层不随组件滚动问题

parent ba75dc1a
{
"name": "panda-xform",
"version": "2.0.7",
"description": "2.0.7: 对话框统一调整为可拖拽",
"version": "2.0.8",
"description": "2.0.8: 解决下拉框组件以及时间类组件弹出层不随组件滚动问题",
"keywords": [
"panda-xform"
],
......@@ -37,7 +37,6 @@
"moment": "^2.29.1",
"qrcode.react": "^3.1.0",
"react": "17.0.2",
"react-draggable": "^4.4.5",
"react-file-viewer": "^1.2.1",
"react-sign2": "^0.0.3",
"react-svg": "15.1.9",
......
......@@ -2247,15 +2247,15 @@ const dateWidgets = [
type: 'object',
properties: {},
},
format: {
title: '日期格式',
type: 'string',
enum: ['date', 'dateTime', 'year', 'month', 'week', 'quarter'],
default: 'date',
enumNames: ['日期', '日期时间', '日期年份', '日期月份', '日期周', '日期季度'],
displayType: 'row',
labelWidth: 80,
},
// format: {
// title: '日期格式',
// type: 'string',
// enum: ['date', 'dateTime', 'year', 'month', 'week', 'quarter'],
// default: 'date',
// enumNames: ['日期', '日期时间', '日期年份', '日期月份', '日期周', '日期季度'],
// displayType: 'row',
// labelWidth: 80,
// },
options: {
title: '选项',
type: 'string',
......
......@@ -60,6 +60,7 @@ const UserSelect = (props) => {
onFocus={selectFocus}
onChange={selectChange}
options={pullDown}
getPopupContainer={(targterNode) => targterNode.parentElement || document.body}
>
</Select>
)
......
......@@ -44,6 +44,7 @@ const DateTime = (props) => {
showTime={format === 'dateTime'}
style={{ width: '100%' }}
locale={locale}
getPopupContainer={(targterNode) => targterNode.parentElement || document.body}
/>
);
......
import React, { useMemo } from 'react'
import { TimePicker } from 'antd'
import locale from 'antd/lib/date-picker/locale/zh_CN'
import moment from 'moment'
const Time = (props) => {
......@@ -32,6 +33,8 @@ const Time = (props) => {
value={valueShow}
onChange={timeChange}
disabledDate={disabledDate}
locale={locale}
getPopupContainer={(targterNode) => targterNode.parentElement || document.body}
/>
)
......
......@@ -118,6 +118,7 @@ const ComboBox = (props) => {
placeholder={placeholder}
onChange={handleChange}
allowClear
getPopupContainer={(targterNode) => targterNode.parentElement || document.body}
>
{children}
</Select>
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment