chore: Moves components out of the commons folder (#18931)
* refactor: Moves components out of the commons folder * Fixes tests
This commit is contained in:
parent
2cb3635256
commit
fd4bd1edbc
|
|
@ -19,7 +19,7 @@
|
|||
import React from 'react';
|
||||
import { t, styled, supersetTheme } from '@superset-ui/core';
|
||||
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Button, { ButtonProps } from 'src/components/Button';
|
||||
import Icons from 'src/components/Icons';
|
||||
import {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,8 @@
|
|||
import React from 'react';
|
||||
import { shallow } from 'enzyme';
|
||||
import { Radio } from 'src/components/Radio';
|
||||
import { AutoComplete, Input } from 'src/common/components';
|
||||
import { AutoComplete } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { SaveDatasetModal } from 'src/SqlLab/components/SaveDatasetModal';
|
||||
|
||||
describe('SaveDatasetModal', () => {
|
||||
|
|
|
|||
|
|
@ -20,7 +20,8 @@
|
|||
import React, { FunctionComponent } from 'react';
|
||||
import { AutoCompleteProps } from 'antd/lib/auto-complete';
|
||||
import { Radio } from 'src/components/Radio';
|
||||
import { AutoComplete, Input } from 'src/common/components';
|
||||
import { AutoComplete } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import StyledModal from 'src/components/Modal';
|
||||
import Button from 'src/components/Button';
|
||||
import { styled, t } from '@superset-ui/core';
|
||||
|
|
|
|||
|
|
@ -17,7 +17,8 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React, { useState, useEffect } from 'react';
|
||||
import { Row, Col, Input, TextArea } from 'src/common/components';
|
||||
import { Row, Col } from 'src/common/components';
|
||||
import { Input, TextArea } from 'src/components/Input';
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import Button from 'src/components/Button';
|
||||
import { Form, FormItem } from 'src/components/Form';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
*/
|
||||
import React, { FunctionComponent, useState } from 'react';
|
||||
import SchemaForm, { FormProps, FormValidation } from 'react-jsonschema-form';
|
||||
import { Row, Col, Input, TextArea } from 'src/common/components';
|
||||
import { Row, Col } from 'src/common/components';
|
||||
import { Input, TextArea } from 'src/components/Input';
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import * as chrono from 'chrono-node';
|
||||
import ModalTrigger from 'src/components/ModalTrigger';
|
||||
|
|
|
|||
|
|
@ -31,13 +31,9 @@ import StyledModal from 'src/components/Modal';
|
|||
import Mousetrap from 'mousetrap';
|
||||
import Button from 'src/components/Button';
|
||||
import Timer from 'src/components/Timer';
|
||||
import {
|
||||
Dropdown,
|
||||
Menu as AntdMenu,
|
||||
Menu,
|
||||
Switch,
|
||||
Input,
|
||||
} from 'src/common/components';
|
||||
import { Dropdown, Switch } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Icons from 'src/components/Icons';
|
||||
import { detectOS } from 'src/utils/common';
|
||||
import {
|
||||
|
|
@ -578,19 +574,16 @@ class SqlEditor extends React.PureComponent {
|
|||
LIMIT_DROPDOWN.push(maxRow);
|
||||
|
||||
return (
|
||||
<AntdMenu>
|
||||
<Menu>
|
||||
{[...new Set(LIMIT_DROPDOWN)].map(limit => (
|
||||
<AntdMenu.Item
|
||||
key={`${limit}`}
|
||||
onClick={() => this.setQueryLimit(limit)}
|
||||
>
|
||||
<Menu.Item key={`${limit}`} onClick={() => this.setQueryLimit(limit)}>
|
||||
{/* // eslint-disable-line no-use-before-define */}
|
||||
<a role="button" styling="link">
|
||||
{this.convertToNumWithSpaces(limit)}
|
||||
</a>{' '}
|
||||
</AntdMenu.Item>
|
||||
</Menu.Item>
|
||||
))}
|
||||
</AntdMenu>
|
||||
</Menu>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import React from 'react';
|
|||
import PropTypes from 'prop-types';
|
||||
import { Dropdown } from 'src/components/Dropdown';
|
||||
import { EditableTabs } from 'src/components/Tabs';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { connect } from 'react-redux';
|
||||
import { bindActionCreators } from 'redux';
|
||||
import URI from 'urijs';
|
||||
|
|
|
|||
|
|
@ -16,16 +16,6 @@
|
|||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import React, { RefObject } from 'react';
|
||||
import { styled } from '@superset-ui/core';
|
||||
import {
|
||||
Dropdown,
|
||||
Menu as AntdMenu,
|
||||
Input as AntdInput,
|
||||
InputNumber as AntdInputNumber,
|
||||
Skeleton,
|
||||
} from 'antd';
|
||||
import { DropDownProps } from 'antd/lib/dropdown';
|
||||
/*
|
||||
Antd is re-exported from here so we can override components with Emotion as needed.
|
||||
|
||||
|
|
@ -70,193 +60,8 @@ export { default as List } from 'antd/lib/list';
|
|||
export type { AlertProps } from 'antd/lib/alert';
|
||||
export type { SelectProps } from 'antd/lib/select';
|
||||
export type { ListItemProps } from 'antd/lib/list';
|
||||
|
||||
export { default as Collapse } from 'src/components/Collapse';
|
||||
export { default as Badge } from 'src/components/Badge';
|
||||
export { default as Card } from 'src/components/Card';
|
||||
export { default as Progress } from 'src/components/ProgressBar';
|
||||
|
||||
export const MenuItem = styled(AntdMenu.Item)`
|
||||
> a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
&.ant-menu-item {
|
||||
height: ${({ theme }) => theme.gridUnit * 7}px;
|
||||
line-height: ${({ theme }) => theme.gridUnit * 7}px;
|
||||
a {
|
||||
border-bottom: none;
|
||||
transition: background-color ${({ theme }) => theme.transitionTiming}s;
|
||||
&:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: -3px;
|
||||
left: 50%;
|
||||
width: 0;
|
||||
height: 3px;
|
||||
opacity: 0;
|
||||
transform: translateX(-50%);
|
||||
transition: all ${({ theme }) => theme.transitionTiming}s;
|
||||
background-color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
&:focus {
|
||||
border-bottom: none;
|
||||
background-color: transparent;
|
||||
@media (max-width: 767px) {
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.ant-menu-item,
|
||||
&.ant-dropdown-menu-item {
|
||||
span[role='button'] {
|
||||
display: inline-block;
|
||||
width: 100%;
|
||||
}
|
||||
transition-duration: 0s;
|
||||
}
|
||||
`;
|
||||
|
||||
export const StyledNav = styled(AntdMenu)`
|
||||
line-height: 51px;
|
||||
border: none;
|
||||
|
||||
& > .ant-menu-item,
|
||||
& > .ant-menu-submenu {
|
||||
vertical-align: inherit;
|
||||
&:hover {
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.ant-menu-dark) > .ant-menu-submenu,
|
||||
&:not(.ant-menu-dark) > .ant-menu-item {
|
||||
&:hover {
|
||||
border-bottom: none;
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.ant-menu-dark) > .ant-menu-submenu,
|
||||
&:not(.ant-menu-dark) > .ant-menu-item {
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
& > .ant-menu-item > a {
|
||||
padding: ${({ theme }) => theme.gridUnit * 4}px;
|
||||
}
|
||||
`;
|
||||
|
||||
export const StyledSubMenu = styled(AntdMenu.SubMenu)`
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
border-bottom: none;
|
||||
.ant-menu-submenu-open,
|
||||
.ant-menu-submenu-active {
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
.ant-menu-submenu-title {
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
border-bottom: none;
|
||||
margin: 0;
|
||||
&:after {
|
||||
opacity: 1;
|
||||
width: calc(100% - 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
.ant-menu-submenu-title {
|
||||
position: relative;
|
||||
top: ${({ theme }) => -theme.gridUnit - 3}px;
|
||||
&:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: -3px;
|
||||
left: 50%;
|
||||
width: 0;
|
||||
height: 3px;
|
||||
opacity: 0;
|
||||
transform: translateX(-50%);
|
||||
transition: all ${({ theme }) => theme.transitionTiming}s;
|
||||
background-color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
}
|
||||
.ant-menu-submenu-arrow {
|
||||
top: 67%;
|
||||
}
|
||||
& > .ant-menu-submenu-title {
|
||||
padding: 0 ${({ theme }) => theme.gridUnit * 6}px 0
|
||||
${({ theme }) => theme.gridUnit * 3}px !important;
|
||||
span[role='img'] {
|
||||
position: absolute;
|
||||
right: ${({ theme }) => -theme.gridUnit + -2}px;
|
||||
top: ${({ theme }) => theme.gridUnit * 5.25}px;
|
||||
svg {
|
||||
font-size: ${({ theme }) => theme.gridUnit * 6}px;
|
||||
color: ${({ theme }) => theme.colors.grayscale.base};
|
||||
}
|
||||
}
|
||||
& > span {
|
||||
position: relative;
|
||||
top: 7px;
|
||||
}
|
||||
&:hover {
|
||||
color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export declare type MenuMode =
|
||||
| 'vertical'
|
||||
| 'vertical-left'
|
||||
| 'vertical-right'
|
||||
| 'horizontal'
|
||||
| 'inline';
|
||||
export const Menu = Object.assign(AntdMenu, {
|
||||
Item: MenuItem,
|
||||
});
|
||||
|
||||
export const MainNav = Object.assign(StyledNav, {
|
||||
Item: MenuItem,
|
||||
SubMenu: StyledSubMenu,
|
||||
Divider: AntdMenu.Divider,
|
||||
ItemGroup: AntdMenu.ItemGroup,
|
||||
});
|
||||
|
||||
interface ExtendedDropDownProps extends DropDownProps {
|
||||
ref?: RefObject<HTMLDivElement>;
|
||||
}
|
||||
|
||||
export const Input = styled(AntdInput)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
||||
export const InputNumber = styled(AntdInputNumber)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
||||
export const TextArea = styled(AntdInput.TextArea)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
||||
// @z-index-below-dashboard-header (100) - 1 = 99
|
||||
export const NoAnimationDropdown = (
|
||||
props: ExtendedDropDownProps & { children?: React.ReactNode },
|
||||
) => (
|
||||
<Dropdown overlayStyle={{ zIndex: 99, animationDuration: '0s' }} {...props} />
|
||||
);
|
||||
|
||||
export const ThinSkeleton = styled(Skeleton)`
|
||||
h3 {
|
||||
margin: ${({ theme }) => theme.gridUnit}px 0;
|
||||
}
|
||||
|
||||
ul {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
`;
|
||||
|
||||
export { default as Icon } from '@ant-design/icons';
|
||||
|
|
|
|||
|
|
@ -17,7 +17,8 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React, { useState, useRef, useCallback } from 'react';
|
||||
import { Input, Divider } from 'src/common/components';
|
||||
import { Divider } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { CronPicker, CronError, CronProps } from '.';
|
||||
|
||||
export default {
|
||||
|
|
|
|||
|
|
@ -35,7 +35,8 @@ import { useDebouncedEffect } from 'src/explore/exploreUtils';
|
|||
import { SLOW_DEBOUNCE } from 'src/constants';
|
||||
import { getClientErrorObject } from 'src/utils/getClientErrorObject';
|
||||
import Loading from 'src/components/Loading';
|
||||
import { Input, AntdInput } from 'src/common/components';
|
||||
import { AntdInput } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import {
|
||||
PAGE_SIZE as DATASET_PAGE_SIZE,
|
||||
SORT_BY as DATASET_SORT_BY,
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import React, { useState } from 'react';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import Modal from 'src/components/Modal';
|
||||
import { FormLabel } from 'src/components/Form';
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React from 'react';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { Dropdown, DropdownProps } from '.';
|
||||
|
||||
export default {
|
||||
|
|
|
|||
|
|
@ -16,8 +16,9 @@
|
|||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import React from 'react';
|
||||
import React, { RefObject } from 'react';
|
||||
import { Dropdown as AntdDropdown } from 'antd';
|
||||
import { DropDownProps } from 'antd/lib/dropdown';
|
||||
import { styled } from '@superset-ui/core';
|
||||
|
||||
const MenuDots = styled.div`
|
||||
|
|
@ -76,3 +77,17 @@ export const Dropdown = ({ overlay, ...rest }: DropdownProps) => (
|
|||
</MenuDotsWrapper>
|
||||
</AntdDropdown>
|
||||
);
|
||||
|
||||
interface ExtendedDropDownProps extends DropDownProps {
|
||||
ref?: RefObject<HTMLDivElement>;
|
||||
}
|
||||
|
||||
// @z-index-below-dashboard-header (100) - 1 = 99
|
||||
export const NoAnimationDropdown = (
|
||||
props: ExtendedDropDownProps & { children?: React.ReactNode },
|
||||
) => (
|
||||
<AntdDropdown
|
||||
overlayStyle={{ zIndex: 99, animationDuration: '0s' }}
|
||||
{...props}
|
||||
/>
|
||||
);
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React from 'react';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { DropdownButton, DropdownButtonProps } from '.';
|
||||
|
||||
export default {
|
||||
|
|
|
|||
|
|
@ -0,0 +1,35 @@
|
|||
/**
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import { styled } from '@superset-ui/core';
|
||||
import { Input as AntdInput, InputNumber as AntdInputNumber } from 'antd';
|
||||
|
||||
export const Input = styled(AntdInput)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
||||
export const InputNumber = styled(AntdInputNumber)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
||||
export const TextArea = styled(AntdInput.TextArea)`
|
||||
border: 1px solid ${({ theme }) => theme.colors.secondary.light3};
|
||||
border-radius: ${({ theme }) => theme.borderRadius}px;
|
||||
`;
|
||||
|
|
@ -21,7 +21,8 @@ import { action } from '@storybook/addon-actions';
|
|||
import { withKnobs, boolean, select, text } from '@storybook/addon-knobs';
|
||||
import DashboardImg from 'src/assets/images/dashboard-card-fallback.svg';
|
||||
import ChartImg from 'src/assets/images/chart-card-fallback.svg';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Icons from 'src/components/Icons';
|
||||
import FaveStar from 'src/components/FaveStar';
|
||||
import ListViewCard from '.';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import { styled, useTheme } from '@superset-ui/core';
|
||||
import { AntdCard, Skeleton, ThinSkeleton } from 'src/common/components';
|
||||
import { AntdCard, Skeleton } from 'src/common/components';
|
||||
import { Tooltip } from 'src/components/Tooltip';
|
||||
import ImageLoader, { BackgroundPosition } from './ImageLoader';
|
||||
import CertifiedBadge from '../CertifiedBadge';
|
||||
|
|
@ -136,6 +136,16 @@ const CoverFooterRight = styled.div`
|
|||
text-overflow: ellipsis;
|
||||
`;
|
||||
|
||||
const ThinSkeleton = styled(Skeleton)`
|
||||
h3 {
|
||||
margin: ${({ theme }) => theme.gridUnit}px 0;
|
||||
}
|
||||
|
||||
ul {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
`;
|
||||
|
||||
const paragraphConfig = { rows: 1, width: 150 };
|
||||
|
||||
interface LinkProps {
|
||||
|
|
|
|||
|
|
@ -0,0 +1,168 @@
|
|||
/**
|
||||
* Licensed to the Apache Software Foundation (ASF) under one
|
||||
* or more contributor license agreements. See the NOTICE file
|
||||
* distributed with this work for additional information
|
||||
* regarding copyright ownership. The ASF licenses this file
|
||||
* to you under the Apache License, Version 2.0 (the
|
||||
* "License"); you may not use this file except in compliance
|
||||
* with the License. You may obtain a copy of the License at
|
||||
*
|
||||
* http://www.apache.org/licenses/LICENSE-2.0
|
||||
*
|
||||
* Unless required by applicable law or agreed to in writing,
|
||||
* software distributed under the License is distributed on an
|
||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
||||
* KIND, either express or implied. See the License for the
|
||||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import { styled } from '@superset-ui/core';
|
||||
import { Menu as AntdMenu } from 'antd';
|
||||
|
||||
const MenuItem = styled(AntdMenu.Item)`
|
||||
> a {
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
&.ant-menu-item {
|
||||
height: ${({ theme }) => theme.gridUnit * 7}px;
|
||||
line-height: ${({ theme }) => theme.gridUnit * 7}px;
|
||||
a {
|
||||
border-bottom: none;
|
||||
transition: background-color ${({ theme }) => theme.transitionTiming}s;
|
||||
&:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: -3px;
|
||||
left: 50%;
|
||||
width: 0;
|
||||
height: 3px;
|
||||
opacity: 0;
|
||||
transform: translateX(-50%);
|
||||
transition: all ${({ theme }) => theme.transitionTiming}s;
|
||||
background-color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
&:focus {
|
||||
border-bottom: none;
|
||||
background-color: transparent;
|
||||
@media (max-width: 767px) {
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
&.ant-menu-item,
|
||||
&.ant-dropdown-menu-item {
|
||||
span[role='button'] {
|
||||
display: inline-block;
|
||||
width: 100%;
|
||||
}
|
||||
transition-duration: 0s;
|
||||
}
|
||||
`;
|
||||
|
||||
const StyledNav = styled(AntdMenu)`
|
||||
line-height: 51px;
|
||||
border: none;
|
||||
|
||||
& > .ant-menu-item,
|
||||
& > .ant-menu-submenu {
|
||||
vertical-align: inherit;
|
||||
&:hover {
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.ant-menu-dark) > .ant-menu-submenu,
|
||||
&:not(.ant-menu-dark) > .ant-menu-item {
|
||||
&:hover {
|
||||
border-bottom: none;
|
||||
}
|
||||
}
|
||||
|
||||
&:not(.ant-menu-dark) > .ant-menu-submenu,
|
||||
&:not(.ant-menu-dark) > .ant-menu-item {
|
||||
margin: 0px;
|
||||
}
|
||||
|
||||
& > .ant-menu-item > a {
|
||||
padding: ${({ theme }) => theme.gridUnit * 4}px;
|
||||
}
|
||||
`;
|
||||
|
||||
const StyledSubMenu = styled(AntdMenu.SubMenu)`
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
border-bottom: none;
|
||||
.ant-menu-submenu-open,
|
||||
.ant-menu-submenu-active {
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
.ant-menu-submenu-title {
|
||||
color: ${({ theme }) => theme.colors.grayscale.dark1};
|
||||
background-color: ${({ theme }) => theme.colors.primary.light5};
|
||||
border-bottom: none;
|
||||
margin: 0;
|
||||
&:after {
|
||||
opacity: 1;
|
||||
width: calc(100% - 1);
|
||||
}
|
||||
}
|
||||
}
|
||||
.ant-menu-submenu-title {
|
||||
position: relative;
|
||||
top: ${({ theme }) => -theme.gridUnit - 3}px;
|
||||
&:after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: -3px;
|
||||
left: 50%;
|
||||
width: 0;
|
||||
height: 3px;
|
||||
opacity: 0;
|
||||
transform: translateX(-50%);
|
||||
transition: all ${({ theme }) => theme.transitionTiming}s;
|
||||
background-color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
}
|
||||
.ant-menu-submenu-arrow {
|
||||
top: 67%;
|
||||
}
|
||||
& > .ant-menu-submenu-title {
|
||||
padding: 0 ${({ theme }) => theme.gridUnit * 6}px 0
|
||||
${({ theme }) => theme.gridUnit * 3}px !important;
|
||||
span[role='img'] {
|
||||
position: absolute;
|
||||
right: ${({ theme }) => -theme.gridUnit + -2}px;
|
||||
top: ${({ theme }) => theme.gridUnit * 5.25}px;
|
||||
svg {
|
||||
font-size: ${({ theme }) => theme.gridUnit * 6}px;
|
||||
color: ${({ theme }) => theme.colors.grayscale.base};
|
||||
}
|
||||
}
|
||||
& > span {
|
||||
position: relative;
|
||||
top: 7px;
|
||||
}
|
||||
&:hover {
|
||||
color: ${({ theme }) => theme.colors.primary.base};
|
||||
}
|
||||
}
|
||||
`;
|
||||
|
||||
export declare type MenuMode =
|
||||
| 'vertical'
|
||||
| 'vertical-left'
|
||||
| 'vertical-right'
|
||||
| 'horizontal'
|
||||
| 'inline';
|
||||
|
||||
export const Menu = Object.assign(AntdMenu, {
|
||||
Item: MenuItem,
|
||||
});
|
||||
|
||||
export const MainNav = Object.assign(StyledNav, {
|
||||
Item: MenuItem,
|
||||
SubMenu: StyledSubMenu,
|
||||
Divider: AntdMenu.Divider,
|
||||
ItemGroup: AntdMenu.ItemGroup,
|
||||
});
|
||||
|
|
@ -19,7 +19,8 @@
|
|||
import React from 'react';
|
||||
import cx from 'classnames';
|
||||
import { styled, useTheme } from '@superset-ui/core';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
||||
export interface OptionProps {
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@ import { t, SupersetTheme, css, useTheme } from '@superset-ui/core';
|
|||
import Icons from 'src/components/Icons';
|
||||
import { Switch } from 'src/components/Switch';
|
||||
import { AlertObject } from 'src/views/CRUD/alert/types';
|
||||
import { Menu, NoAnimationDropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { NoAnimationDropdown } from 'src/components/Dropdown';
|
||||
import { isFeatureEnabled, FeatureFlag } from 'src/featureFlags';
|
||||
|
||||
import DeleteModal from 'src/components/DeleteModal';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { Menu, Dropdown } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Button from 'src/components/Button';
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import ModalTrigger from 'src/components/ModalTrigger';
|
||||
|
|
|
|||
|
|
@ -21,7 +21,8 @@ import PropTypes from 'prop-types';
|
|||
|
||||
import { styled, SupersetClient, t } from '@superset-ui/core';
|
||||
|
||||
import { Menu, NoAnimationDropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { NoAnimationDropdown } from 'src/components/Dropdown';
|
||||
import Icons from 'src/components/Icons';
|
||||
import { URL_PARAMS } from 'src/constants';
|
||||
import ShareMenuItems from 'src/dashboard/components/menu/ShareMenuItems';
|
||||
|
|
|
|||
|
|
@ -17,7 +17,8 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React, { useCallback, useEffect, useState } from 'react';
|
||||
import { Form, Row, Col, Input } from 'src/common/components';
|
||||
import { Form, Row, Col } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { FormItem } from 'src/components/Form';
|
||||
import jsonStringify from 'json-stringify-pretty-compact';
|
||||
import Button from 'src/components/Button';
|
||||
|
|
|
|||
|
|
@ -19,7 +19,8 @@
|
|||
/* eslint-env browser */
|
||||
import React from 'react';
|
||||
import { Radio } from 'src/components/Radio';
|
||||
import { RadioChangeEvent, Input } from 'src/common/components';
|
||||
import { RadioChangeEvent } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import Button from 'src/components/Button';
|
||||
import { t, JsonResponse } from '@superset-ui/core';
|
||||
|
||||
|
|
|
|||
|
|
@ -22,7 +22,7 @@ import PropTypes from 'prop-types';
|
|||
import { List } from 'react-virtualized';
|
||||
import { createFilter } from 'react-search-input';
|
||||
import { t, styled, isFeatureEnabled, FeatureFlag } from '@superset-ui/core';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Select } from 'src/components';
|
||||
import Loading from 'src/components/Loading';
|
||||
import {
|
||||
|
|
|
|||
|
|
@ -23,8 +23,8 @@ import { render, screen } from 'spec/helpers/testing-library';
|
|||
import { FeatureFlag } from 'src/featureFlags';
|
||||
import SliceHeaderControls from '.';
|
||||
|
||||
jest.mock('src/common/components', () => {
|
||||
const original = jest.requireActual('src/common/components');
|
||||
jest.mock('src/components/Dropdown', () => {
|
||||
const original = jest.requireActual('src/components/Dropdown');
|
||||
return {
|
||||
...original,
|
||||
NoAnimationDropdown: (props: any) => (
|
||||
|
|
|
|||
|
|
@ -24,7 +24,8 @@ import {
|
|||
styled,
|
||||
t,
|
||||
} from '@superset-ui/core';
|
||||
import { Menu, NoAnimationDropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { NoAnimationDropdown } from 'src/components/Dropdown';
|
||||
import ShareMenuItems from 'src/dashboard/components/menu/ShareMenuItems';
|
||||
import downloadAsImage from 'src/utils/downloadAsImage';
|
||||
import { FeatureFlag, isFeatureEnabled } from 'src/featureFlags';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
|
||||
import React from 'react';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { render, screen, waitFor } from 'spec/helpers/testing-library';
|
||||
import userEvent from '@testing-library/user-event';
|
||||
import * as copyTextToClipboard from 'src/utils/copy';
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import React from 'react';
|
|||
import { useUrlShortener } from 'src/hooks/useUrlShortener';
|
||||
import copyTextToClipboard from 'src/utils/copy';
|
||||
import { t, logging } from '@superset-ui/core';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { getUrlParam } from 'src/utils/urlUtils';
|
||||
import { postFormData } from 'src/explore/exploreUtils/formData';
|
||||
import { useTabId } from 'src/hooks/useTabId';
|
||||
|
|
|
|||
|
|
@ -16,7 +16,8 @@
|
|||
* specific language governing permissions and limitations
|
||||
* under the License.
|
||||
*/
|
||||
import { Typography, Dropdown, Menu } from 'src/common/components';
|
||||
import { Typography, Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import React, { FC } from 'react';
|
||||
import {
|
||||
DataMaskState,
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import { FormItem } from 'src/components/Form';
|
||||
import { Input, TextArea } from 'src/common/components';
|
||||
import { Input, TextArea } from 'src/components/Input';
|
||||
import { NativeFilterType, styled, t } from '@superset-ui/core';
|
||||
|
||||
interface Props {
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
*/
|
||||
import { NativeFilterType, styled, t, useTheme } from '@superset-ui/core';
|
||||
import React from 'react';
|
||||
import { Dropdown, MainNav as Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { MainNav as Menu } from 'src/components/Menu';
|
||||
import FilterTitleContainer from './FilterTitleContainer';
|
||||
import { FilterRemoval } from './types';
|
||||
|
||||
|
|
|
|||
|
|
@ -50,7 +50,7 @@ import React, {
|
|||
import { PluginFilterSelectCustomizeProps } from 'src/filters/components/Select/types';
|
||||
import { useSelector } from 'react-redux';
|
||||
import { getChartDataRequest } from 'src/chart/chartAction';
|
||||
import { Input, TextArea } from 'src/common/components';
|
||||
import { Input, TextArea } from 'src/components/Input';
|
||||
import { Select } from 'src/components';
|
||||
import Collapse from 'src/components/Collapse';
|
||||
import BasicErrorAlert from 'src/components/ErrorMessage/BasicErrorAlert';
|
||||
|
|
|
|||
|
|
@ -25,7 +25,8 @@ import { Provider } from 'react-redux';
|
|||
import { mockStore } from 'spec/fixtures/mockStore';
|
||||
import { styledMount as mount } from 'spec/helpers/theming';
|
||||
import waitForComponentToPaint from 'spec/helpers/waitForComponentToPaint';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import Alert from 'src/components/Alert';
|
||||
import { FiltersConfigModal } from 'src/dashboard/components/nativeFilters/FiltersConfigModal/FiltersConfigModal';
|
||||
|
||||
|
|
|
|||
|
|
@ -30,7 +30,8 @@ import { Global } from '@emotion/react';
|
|||
import { Column } from 'react-table';
|
||||
import debounce from 'lodash/debounce';
|
||||
import { useDispatch } from 'react-redux';
|
||||
import { Input, Space } from 'src/common/components';
|
||||
import { Space } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import {
|
||||
BOOL_FALSE_DISPLAY,
|
||||
BOOL_TRUE_DISPLAY,
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ import { debounce } from 'lodash';
|
|||
import { matchSorter, rankings } from 'match-sorter';
|
||||
import { css, styled, t } from '@superset-ui/core';
|
||||
import Collapse from 'src/components/Collapse';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { FAST_DEBOUNCE } from 'src/constants';
|
||||
import { FeatureFlag, isFeatureEnabled } from 'src/featureFlags';
|
||||
import { ExploreActions } from 'src/explore/actions/exploreActions';
|
||||
|
|
|
|||
|
|
@ -21,7 +21,8 @@ import { shallow } from 'enzyme';
|
|||
import { styledMount as mount } from 'spec/helpers/theming';
|
||||
import thunk from 'redux-thunk';
|
||||
import configureStore from 'redux-mock-store';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import ExploreAdditionalActionsMenu from 'src/explore/components/ExploreAdditionalActionsMenu';
|
||||
|
||||
const mockStore = configureStore([thunk]);
|
||||
|
|
|
|||
|
|
@ -21,7 +21,8 @@ import { connect } from 'react-redux';
|
|||
import { bindActionCreators } from 'redux';
|
||||
import PropTypes from 'prop-types';
|
||||
import { t } from '@superset-ui/core';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import downloadAsImage from 'src/utils/downloadAsImage';
|
||||
import ModalTrigger from 'src/components/ModalTrigger';
|
||||
import { sliceUpdated } from 'src/explore/actions/exploreActions';
|
||||
|
|
|
|||
|
|
@ -19,7 +19,8 @@
|
|||
import React, { ReactChild, useCallback } from 'react';
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import Icons from 'src/components/Icons';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
|
||||
enum MENU_KEYS {
|
||||
EXPORT_ORIGINAL = 'export_original',
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
*/
|
||||
import React, { useMemo, useState, useCallback, useEffect } from 'react';
|
||||
import Modal from 'src/components/Modal';
|
||||
import { Form, Row, Col, Input, TextArea } from 'src/common/components';
|
||||
import { Form, Row, Col } from 'src/common/components';
|
||||
import { Input, TextArea } from 'src/components/Input';
|
||||
import Button from 'src/components/Button';
|
||||
import { Select } from 'src/components';
|
||||
import { SelectValue } from 'antd/lib/select';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
/* eslint camelcase: 0 */
|
||||
import React from 'react';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Form, FormItem } from 'src/components/Form';
|
||||
import Alert from 'src/components/Alert';
|
||||
import { JsonObject, t, styled } from '@superset-ui/core';
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React, { useEffect, useRef, useState } from 'react';
|
||||
import { InputNumber } from 'src/common/components';
|
||||
import { InputNumber } from 'src/components/Input';
|
||||
import { t, styled } from '@superset-ui/core';
|
||||
import { debounce } from 'lodash';
|
||||
import ControlHeader from 'src/explore/components/ControlHeader';
|
||||
|
|
|
|||
|
|
@ -20,7 +20,8 @@ import React from 'react';
|
|||
import { styled, t } from '@superset-ui/core';
|
||||
import { Form, FormItem, FormProps } from 'src/components/Form';
|
||||
import Select, { propertyComparator } from 'src/components/Select/Select';
|
||||
import { Col, InputNumber, Row } from 'src/common/components';
|
||||
import { Col, Row } from 'src/common/components';
|
||||
import { InputNumber } from 'src/components/Input';
|
||||
import Button from 'src/components/Button';
|
||||
import {
|
||||
COMPARATOR,
|
||||
|
|
|
|||
|
|
@ -20,7 +20,7 @@ import React from 'react';
|
|||
import sinon from 'sinon';
|
||||
import configureStore from 'redux-mock-store';
|
||||
import { shallow } from 'enzyme';
|
||||
import { Menu } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import {
|
||||
DatasourceModal,
|
||||
ChangeDatasourceModal,
|
||||
|
|
|
|||
|
|
@ -22,7 +22,8 @@ import PropTypes from 'prop-types';
|
|||
import { t, styled, supersetTheme } from '@superset-ui/core';
|
||||
import { getUrlParam } from 'src/utils/urlUtils';
|
||||
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { Tooltip } from 'src/components/Tooltip';
|
||||
import Icons from 'src/components/Icons';
|
||||
import {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
import React from 'react';
|
||||
import { t } from '@superset-ui/core';
|
||||
import { SEPARATOR } from 'src/explore/components/controls/DateFilterControl/utils';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { InfoTooltipWithTrigger } from '@superset-ui/chart-controls';
|
||||
import { FrameComponentProps } from 'src/explore/components/controls/DateFilterControl/types';
|
||||
import DateFunctionTooltip from './DateFunctionTooltip';
|
||||
|
|
|
|||
|
|
@ -20,7 +20,8 @@ import React from 'react';
|
|||
import { t } from '@superset-ui/core';
|
||||
import { Moment } from 'moment';
|
||||
import { isInteger } from 'lodash';
|
||||
import { Col, InputNumber, Row } from 'src/common/components';
|
||||
import { Col, Row } from 'src/common/components';
|
||||
import { InputNumber } from 'src/components/Input';
|
||||
import { DatePicker } from 'src/components/DatePicker';
|
||||
import { Radio } from 'src/components/Radio';
|
||||
import Select, { propertyComparator } from 'src/components/Select/Select';
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
import React, { useCallback, useState } from 'react';
|
||||
import { t } from '@superset-ui/core';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Tooltip } from 'src/components/Tooltip';
|
||||
|
||||
export const DndColumnSelectPopoverTitle = ({
|
||||
|
|
|
|||
|
|
@ -36,7 +36,7 @@ import AdhocFilter, {
|
|||
EXPRESSION_TYPES,
|
||||
CLAUSES,
|
||||
} from 'src/explore/components/controls/FilterControl/AdhocFilter';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { propertyComparator } from 'src/components/Select/Select';
|
||||
import { optionLabel } from 'src/utils/common';
|
||||
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React from 'react';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
|
||||
interface HiddenControlsProps {
|
||||
onChange: () => void;
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
import React from 'react';
|
||||
import { t } from '@superset-ui/core';
|
||||
import PropTypes from 'prop-types';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Tooltip } from 'src/components/Tooltip';
|
||||
|
||||
const propTypes = {
|
||||
|
|
|
|||
|
|
@ -18,7 +18,7 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { TextArea } from 'src/common/components';
|
||||
import { TextArea } from 'src/components/Input';
|
||||
import { t } from '@superset-ui/core';
|
||||
|
||||
import Button from 'src/components/Button';
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import React from 'react';
|
|||
import sinon from 'sinon';
|
||||
import { shallow } from 'enzyme';
|
||||
import { TextAreaEditor } from 'src/components/AsyncAceEditor';
|
||||
import { TextArea } from 'src/common/components';
|
||||
import { TextArea } from 'src/components/Input';
|
||||
|
||||
import TextAreaControl from 'src/explore/components/controls/TextAreaControl';
|
||||
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ import { legacyValidateNumber, legacyValidateInteger } from '@superset-ui/core';
|
|||
import debounce from 'lodash/debounce';
|
||||
import { FAST_DEBOUNCE } from 'src/constants';
|
||||
import ControlHeader from 'src/explore/components/ControlHeader';
|
||||
import { Input } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
|
||||
type InputValueType = string | number;
|
||||
|
||||
|
|
|
|||
|
|
@ -18,7 +18,8 @@
|
|||
*/
|
||||
import React from 'react';
|
||||
import PropTypes from 'prop-types';
|
||||
import { Row, Col, Input } from 'src/common/components';
|
||||
import { Row, Col } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import Button from 'src/components/Button';
|
||||
import Popover from 'src/components/Popover';
|
||||
import { Select } from 'src/components';
|
||||
|
|
|
|||
|
|
@ -34,7 +34,8 @@ import {
|
|||
SupersetTheme,
|
||||
useTheme,
|
||||
} from '@superset-ui/core';
|
||||
import { Collapse, Input } from 'src/common/components';
|
||||
import { Collapse } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import Label from 'src/components/Label';
|
||||
import { usePluginContext } from 'src/components/DynamicPlugins';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
|
|
|||
|
|
@ -21,8 +21,7 @@ import React from 'react';
|
|||
import { ReactWrapper } from 'enzyme';
|
||||
import { styledMount as mount } from 'spec/helpers/theming';
|
||||
import { CronPicker } from 'src/components/CronPicker';
|
||||
import { Input } from 'src/common/components';
|
||||
|
||||
import { Input } from 'src/components/Input';
|
||||
import { AlertReportCronScheduler } from './AlertReportCronScheduler';
|
||||
|
||||
describe('AlertReportCronScheduler', () => {
|
||||
|
|
|
|||
|
|
@ -19,7 +19,8 @@
|
|||
import React, { useState, useCallback, useRef, FunctionComponent } from 'react';
|
||||
import { t, useTheme } from '@superset-ui/core';
|
||||
|
||||
import { Input, AntdInput } from 'src/common/components';
|
||||
import { AntdInput } from 'src/common/components';
|
||||
import { Input } from 'src/components/Input';
|
||||
import { Radio } from 'src/components/Radio';
|
||||
import { CronPicker, CronError } from 'src/components/CronPicker';
|
||||
import { StyledInputContainer } from 'src/views/CRUD/alert/AlertReportModal';
|
||||
|
|
|
|||
|
|
@ -25,7 +25,8 @@ import Chart from 'src/types/Chart';
|
|||
|
||||
import ListViewCard from 'src/components/ListViewCard';
|
||||
import Label from 'src/components/Label';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import FaveStar from 'src/components/FaveStar';
|
||||
import FacePile from 'src/components/FacePile';
|
||||
import { handleChartDelete, CardStyles } from '../utils';
|
||||
|
|
|
|||
|
|
@ -21,7 +21,8 @@ import { Link, useHistory } from 'react-router-dom';
|
|||
import { t, useTheme } from '@superset-ui/core';
|
||||
import { handleDashboardDelete, CardStyles } from 'src/views/CRUD/utils';
|
||||
import { isFeatureEnabled, FeatureFlag } from 'src/featureFlags';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import ConfirmStatusChange from 'src/components/ConfirmStatusChange';
|
||||
import ListViewCard from 'src/components/ListViewCard';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
|
|
|||
|
|
@ -23,7 +23,8 @@ import sql from 'react-syntax-highlighter/dist/cjs/languages/hljs/sql';
|
|||
import github from 'react-syntax-highlighter/dist/cjs/styles/hljs/github';
|
||||
import { LoadingCards } from 'src/views/CRUD/welcome/Welcome';
|
||||
import withToasts from 'src/components/MessageToasts/withToasts';
|
||||
import { Dropdown, Menu } from 'src/common/components';
|
||||
import { Dropdown } from 'src/common/components';
|
||||
import { Menu } from 'src/components/Menu';
|
||||
import { copyQueryLink, useListViewResource } from 'src/views/CRUD/hooks';
|
||||
import ListViewCard from 'src/components/ListViewCard';
|
||||
import DeleteModal from 'src/components/DeleteModal';
|
||||
|
|
|
|||
|
|
@ -19,7 +19,7 @@
|
|||
import React from 'react';
|
||||
import { render, screen } from 'spec/helpers/testing-library';
|
||||
import userEvent from '@testing-library/user-event';
|
||||
import { MainNav as Menu } from 'src/common/components';
|
||||
import { MainNav as Menu } from 'src/components/Menu';
|
||||
import LanguagePicker from './LanguagePicker';
|
||||
|
||||
const mockedProps = {
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React from 'react';
|
||||
import { MainNav as Menu } from 'src/common/components';
|
||||
import { MainNav as Menu } from 'src/components/Menu';
|
||||
import { styled } from '@superset-ui/core';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
||||
|
|
|
|||
|
|
@ -21,13 +21,8 @@ import { styled, css, useTheme, SupersetTheme } from '@superset-ui/core';
|
|||
import { debounce } from 'lodash';
|
||||
import { Global } from '@emotion/react';
|
||||
import { getUrlParam } from 'src/utils/urlUtils';
|
||||
import {
|
||||
MainNav as DropdownMenu,
|
||||
MenuMode,
|
||||
Row,
|
||||
Col,
|
||||
Grid,
|
||||
} from 'src/common/components';
|
||||
import { Row, Col, Grid } from 'src/common/components';
|
||||
import { MainNav as DropdownMenu, MenuMode } from 'src/components/Menu';
|
||||
import { Tooltip } from 'src/components/Tooltip';
|
||||
import { Link } from 'react-router-dom';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@
|
|||
* under the License.
|
||||
*/
|
||||
import React, { useState } from 'react';
|
||||
import { MainNav as Menu } from 'src/common/components';
|
||||
import { MainNav as Menu } from 'src/components/Menu';
|
||||
import { t, styled, css, SupersetTheme } from '@superset-ui/core';
|
||||
import { Link } from 'react-router-dom';
|
||||
import Icons from 'src/components/Icons';
|
||||
|
|
|
|||
|
|
@ -21,7 +21,8 @@ import { Link, useHistory } from 'react-router-dom';
|
|||
import { styled } from '@superset-ui/core';
|
||||
import cx from 'classnames';
|
||||
import { debounce } from 'lodash';
|
||||
import { Menu, MenuMode, Row } from 'src/common/components';
|
||||
import { Row } from 'src/common/components';
|
||||
import { Menu, MenuMode } from 'src/components/Menu';
|
||||
import Button, { OnClickHandler } from 'src/components/Button';
|
||||
|
||||
const StyledHeader = styled.div`
|
||||
|
|
|
|||
Loading…
Reference in New Issue