mirror of https://github.com/buster-so/buster.git
update imports
This commit is contained in:
parent
8c875d1c76
commit
dbfcf74e3d
|
@ -54,7 +54,6 @@ export const ListDatasetGroupsComponent: React.FC<{
|
||||||
showHeader={true}
|
showHeader={true}
|
||||||
showSelectAll={false}
|
showSelectAll={false}
|
||||||
rowClassName="pl-[30px]!"
|
rowClassName="pl-[30px]!"
|
||||||
columnRowVariant="default"
|
|
||||||
emptyState={<EmptyStateList text="No dataset groups found" />}
|
emptyState={<EmptyStateList text="No dataset groups found" />}
|
||||||
/>
|
/>
|
||||||
</InfiniteListContainer>
|
</InfiniteListContainer>
|
||||||
|
|
|
@ -54,7 +54,6 @@ export const ListPermissionGroupsComponent: React.FC<{
|
||||||
showHeader={true}
|
showHeader={true}
|
||||||
showSelectAll={false}
|
showSelectAll={false}
|
||||||
rowClassName="pl-[30px]!"
|
rowClassName="pl-[30px]!"
|
||||||
columnRowVariant="default"
|
|
||||||
emptyState={<EmptyStateList text="No permission groups found" />}
|
emptyState={<EmptyStateList text="No permission groups found" />}
|
||||||
/>
|
/>
|
||||||
</InfiniteListContainer>
|
</InfiniteListContainer>
|
||||||
|
|
|
@ -102,7 +102,6 @@ export const ListUsersComponent: React.FC<{
|
||||||
rowClassName="pl-[30px]!"
|
rowClassName="pl-[30px]!"
|
||||||
// onSelectChange={setSelectedRowKeys}
|
// onSelectChange={setSelectedRowKeys}
|
||||||
// selectedRowKeys={selectedRowKeys}
|
// selectedRowKeys={selectedRowKeys}
|
||||||
columnRowVariant="default"
|
|
||||||
emptyState={<EmptyStateList text="No users found" variant="card" show={isFetched} />}
|
emptyState={<EmptyStateList text="No users found" variant="card" show={isFetched} />}
|
||||||
/>
|
/>
|
||||||
</InfiniteListContainer>
|
</InfiniteListContainer>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import type { Meta, StoryObj } from '@storybook/react';
|
import type { Meta, StoryObj } from '@storybook/react';
|
||||||
import { ContextMenu, ContextProps } from './ContextMenu';
|
import { ContextMenu } from './ContextMenu';
|
||||||
import {
|
import {
|
||||||
Window,
|
Window,
|
||||||
WindowSettings,
|
WindowSettings,
|
||||||
|
@ -383,7 +383,9 @@ export const ContextMenuWithEverything: Story = {
|
||||||
loading: false,
|
loading: false,
|
||||||
icon: <Window />,
|
icon: <Window />,
|
||||||
items: [
|
items: [
|
||||||
<div className="flex min-h-10 min-w-10 items-center rounded bg-red-300 p-1 text-red-600">
|
<div
|
||||||
|
key="nested-item"
|
||||||
|
className="flex min-h-10 min-w-10 items-center rounded bg-red-300 p-1 text-red-600">
|
||||||
This is a nested item
|
This is a nested item
|
||||||
</div>
|
</div>
|
||||||
]
|
]
|
||||||
|
|
|
@ -72,6 +72,8 @@ export const ContextMenu: React.FC<ContextMenuProps> = React.memo(
|
||||||
}
|
}
|
||||||
);
|
);
|
||||||
|
|
||||||
|
ContextMenu.displayName = 'ContextMenu';
|
||||||
|
|
||||||
const ContextMenuItemSelector: React.FC<{
|
const ContextMenuItemSelector: React.FC<{
|
||||||
item: ContextMenuItems[number];
|
item: ContextMenuItems[number];
|
||||||
index: number;
|
index: number;
|
||||||
|
|
|
@ -167,8 +167,6 @@ export const WithDisabledItems: Story = {
|
||||||
export const CustomWidth: Story = {
|
export const CustomWidth: Story = {
|
||||||
args: {
|
args: {
|
||||||
menuHeader: 'Custom Width Menu',
|
menuHeader: 'Custom Width Menu',
|
||||||
minWidth: 300,
|
|
||||||
maxWidth: 400,
|
|
||||||
items: [
|
items: [
|
||||||
{
|
{
|
||||||
value: '1',
|
value: '1',
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import { createStyles } from 'antd-style';
|
import { cn } from '@/lib/classMerge';
|
||||||
import React from 'react';
|
import React from 'react';
|
||||||
|
|
||||||
export const InfiniteListContainer: React.FC<{
|
export const InfiniteListContainer: React.FC<{
|
||||||
|
@ -6,15 +6,13 @@ export const InfiniteListContainer: React.FC<{
|
||||||
popupNode?: React.ReactNode;
|
popupNode?: React.ReactNode;
|
||||||
showContainerBorder?: boolean;
|
showContainerBorder?: boolean;
|
||||||
}> = React.memo(({ children, popupNode, showContainerBorder = true }) => {
|
}> = React.memo(({ children, popupNode, showContainerBorder = true }) => {
|
||||||
const { styles, cx } = useStyles();
|
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={cx('overflow-hidden', showContainerBorder && styles.container)}>
|
<div className={cn('overflow-hidden', showContainerBorder && 'border-border rounded border')}>
|
||||||
{children}
|
{children}
|
||||||
|
|
||||||
{popupNode && (
|
{popupNode && (
|
||||||
<div className="fixed bottom-0 left-0 right-0 w-full">
|
<div className="fixed right-0 bottom-0 left-0 w-full">
|
||||||
<div className="relative ml-[220px] mr-[55px]">{popupNode}</div>
|
<div className="relative mr-[55px] ml-[220px]">{popupNode}</div>
|
||||||
</div>
|
</div>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
|
@ -22,10 +20,3 @@ export const InfiniteListContainer: React.FC<{
|
||||||
});
|
});
|
||||||
|
|
||||||
InfiniteListContainer.displayName = 'InfiniteListContainer';
|
InfiniteListContainer.displayName = 'InfiniteListContainer';
|
||||||
|
|
||||||
const useStyles = createStyles(({ css, token }) => ({
|
|
||||||
container: css`
|
|
||||||
border: 0.5px solid ${token.colorBorder};
|
|
||||||
border-radius: ${token.borderRadius}px;
|
|
||||||
`
|
|
||||||
}));
|
|
||||||
|
|
Loading…
Reference in New Issue