diff --git a/superset-frontend/src/common/components/CronPicker/CronPicker.tsx b/superset-frontend/src/common/components/CronPicker/CronPicker.tsx index b5825ec56b..d859640644 100644 --- a/superset-frontend/src/common/components/CronPicker/CronPicker.tsx +++ b/superset-frontend/src/common/components/CronPicker/CronPicker.tsx @@ -17,6 +17,7 @@ * under the License. */ import React from 'react'; +import { ConfigProvider } from 'antd'; import { styled, t } from '@superset-ui/core'; import ReactCronPicker, { Locale, CronProps } from 'react-js-cron'; @@ -103,7 +104,11 @@ export const LOCALE: Locale = { }; export const CronPicker = styled((props: CronProps) => ( - + trigger.parentElement as HTMLElement} + > + + ))` .react-js-cron-select:not(.react-js-cron-custom-select) > div:first-of-type, .react-js-cron-custom-select { diff --git a/superset-frontend/src/common/components/Select.tsx b/superset-frontend/src/common/components/Select.tsx index 75bd073912..49dc91d692 100644 --- a/superset-frontend/src/common/components/Select.tsx +++ b/superset-frontend/src/common/components/Select.tsx @@ -16,10 +16,16 @@ * specific language governing permissions and limitations * under the License. */ +import React from 'react'; import { styled } from '@superset-ui/core'; -import { Select as BaseSelect } from 'src/common/components'; +import { Select as BaseSelect, SelectProps } from 'src/common/components'; -const StyledSelect = styled(BaseSelect)` +const StyledSelect = styled((props: SelectProps) => ( + trigger.parentNode} + {...props} + /> +))` display: block; `; diff --git a/superset-frontend/src/common/components/index.tsx b/superset-frontend/src/common/components/index.tsx index 4f4ece2de4..fb2d514023 100644 --- a/superset-frontend/src/common/components/index.tsx +++ b/superset-frontend/src/common/components/index.tsx @@ -44,7 +44,6 @@ export { Slider, Row, Space, - Select, Skeleton, Switch, Tag, @@ -52,10 +51,11 @@ export { Tooltip, Input as AntdInput, } from 'antd'; -export { default as Alert, AlertProps } from 'antd/lib/alert'; -export { TreeProps } from 'antd/lib/tree'; export { FormInstance } from 'antd/lib/form'; export { RadioChangeEvent } from 'antd/lib/radio'; +export { TreeProps } from 'antd/lib/tree'; +export { default as Alert, AlertProps } from 'antd/lib/alert'; +export { default as Select, SelectProps } from 'antd/lib/select'; export { default as Collapse } from './Collapse'; export { default as Progress } from './ProgressBar';