Merge pull request #695 from suyanhanx/component-file-name-unify

chore: TSX file name unify
This commit is contained in:
DarkSky 2023-01-09 14:03:48 +08:00 committed by GitHub
commit c4df4da082
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
55 changed files with 56 additions and 56 deletions

View File

@ -8,7 +8,7 @@ import {
TelegramIcon,
RedditIcon,
LinkIcon,
} from './icons';
} from './Icons';
import logo from './affine-text-logo.png';
import {
StyledBigLink,

View File

@ -13,7 +13,7 @@ import {
ConnectorIcon,
UndoIcon,
RedoIcon,
} from './icons';
} from './Icons';
import { Tooltip } from '@/ui/tooltip';
import Slide from '@mui/material/Slide';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';

View File

@ -11,8 +11,8 @@ import type {
AnimateRadioProps,
AnimateRadioItemProps,
} from './type';
import { useTheme } from '@/providers/themeProvider';
import { EdgelessIcon, PaperIcon } from './icons';
import { useTheme } from '@/providers/ThemeProvider';
import { EdgelessIcon, PaperIcon } from './Icons';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';
import { usePageHelper } from '@/hooks/use-page-helper';
import { useTranslation } from 'react-i18next';

View File

@ -8,8 +8,8 @@ import {
import { Content } from '@/ui/layout';
import { useAppState } from '@/providers/app-state-provider/context';
import EditorModeSwitch from '@/components/editor-mode-switch';
import QuickSearchButton from './quick-search-button';
import Header from './header';
import QuickSearchButton from './QuickSearchButton';
import Header from './Header';
import usePropsUpdated from '@/hooks/use-props-updated';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';

View File

@ -8,10 +8,10 @@ import {
} from './styles';
import CloseIcon from '@mui/icons-material/Close';
import { getWarningMessage, shouldShowWarning } from './utils';
import EditorOptionMenu from './header-right-items/editor-option-menu';
import TrashButtonGroup from './header-right-items/trash-button-group';
import EditorOptionMenu from './header-right-items/EditorOptionMenu';
import TrashButtonGroup from './header-right-items/TrashButtonGroup';
import ThemeModeSwitch from './header-right-items/theme-mode-switch';
import SyncUser from './header-right-items/sync-user';
import SyncUser from './header-right-items/SyncUser';
const BrowserWarning = ({
show,

View File

@ -1,7 +1,7 @@
import { PropsWithChildren, ReactNode } from 'react';
import Header from './header';
import Header from './Header';
import { StyledPageListTittleWrapper } from './styles';
import QuickSearchButton from './quick-search-button';
import QuickSearchButton from './QuickSearchButton';
export type PageListHeaderProps = PropsWithChildren<{
icon?: ReactNode;

View File

@ -2,7 +2,7 @@ import React from 'react';
import { IconButton, IconButtonProps } from '@/ui/button';
import { Tooltip } from '@/ui/tooltip';
import { ArrowDownIcon } from '@blocksuite/icons';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { useTranslation } from 'react-i18next';
export const QuickSearchButton = ({
onClick,

View File

@ -13,7 +13,7 @@ import {
} from '@blocksuite/icons';
import { useAppState } from '@/providers/app-state-provider';
import { usePageHelper } from '@/hooks/use-page-helper';
import { useConfirm } from '@/providers/confirm-provider';
import { useConfirm } from '@/providers/ConfirmProvider';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';
import { toast } from '@/ui/toast';
import { useTranslation } from 'react-i18next';

View File

@ -1,5 +1,5 @@
import { CloudUnsyncedIcon, CloudInsyncIcon } from '@blocksuite/icons';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { useAppState } from '@/providers/app-state-provider/context';
import { IconButton } from '@/ui/button';

View File

@ -1,7 +1,7 @@
import { Button } from '@/ui/button';
import { usePageHelper } from '@/hooks/use-page-helper';
import { useAppState } from '@/providers/app-state-provider';
import { useConfirm } from '@/providers/confirm-provider';
import { useConfirm } from '@/providers/ConfirmProvider';
import { useRouter } from 'next/router';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';

View File

@ -1,6 +1,6 @@
import { useState } from 'react';
import { useTheme } from '@/providers/themeProvider';
import { MoonIcon, SunIcon } from './icons';
import { useTheme } from '@/providers/ThemeProvider';
import { MoonIcon, SunIcon } from './Icons';
import { StyledThemeModeSwitch, StyledSwitchItem } from './style';
export const ThemeModeSwitch = () => {

View File

@ -1,3 +1,3 @@
export * from './header';
export * from './editor-header';
export * from './page-list-header';
export * from './Header';
export * from './EditorHeader';
export * from './PageListHeader';

View File

@ -5,12 +5,12 @@ import {
StyledIslandWrapper,
StyledTransformIcon,
} from './style';
import { CloseIcon, ContactIcon, HelpIcon, KeyboardIcon } from './icons';
import { CloseIcon, ContactIcon, HelpIcon, KeyboardIcon } from './Icons';
import Grow from '@mui/material/Grow';
import { Tooltip } from '@/ui/tooltip';
import { useTranslation } from 'react-i18next';
import { useModal } from '@/providers/global-modal-provider';
import { useTheme } from '@/providers/themeProvider';
import { useModal } from '@/providers/GlobalModalProvider';
import { useTheme } from '@/providers/ThemeProvider';
import useCurrentPageMeta from '@/hooks/use-current-page-meta';
export type IslandItemNames = 'contact' | 'shortcuts';
export const HelpIsland = ({

View File

@ -1,5 +1,5 @@
import { styled } from '@/styles';
import Loading from './loading';
import Loading from './Loading';
// Used for the full page loading
const StyledLoadingContainer = styled('div')(() => {

View File

@ -1,3 +1,3 @@
import Loading from './loading';
export * from './page-loading';
import Loading from './Loading';
export * from './PageLoading';
export default Loading;

View File

@ -1,8 +1,8 @@
import { getDataCenter } from '@affine/datacenter';
import { styled } from '@/styles';
import { Button } from '@/ui/button';
import { useModal } from '@/providers/global-modal-provider';
import { GoogleIcon, StayLogOutIcon } from './icons';
import { useModal } from '@/providers/GlobalModalProvider';
import { GoogleIcon, StayLogOutIcon } from './Icons';
export const GoogleLoginButton = () => {
const { triggerLoginModal } = useModal();

View File

@ -1,4 +1,4 @@
import { useConfirm } from '@/providers/confirm-provider';
import { useConfirm } from '@/providers/ConfirmProvider';
import { PageMeta } from '@/providers/app-state-provider';
import { Menu, MenuItem } from '@/ui/menu';
import { Wrapper } from '@/ui/layout';

View File

@ -12,18 +12,18 @@ import {
StyledTitleWrapper,
} from './styles';
import { Table, TableBody, TableCell, TableHead, TableRow } from '@/ui/table';
import { OperationCell, TrashOperationCell } from './operation-cell';
import Empty from './empty';
import { OperationCell, TrashOperationCell } from './OperationCell';
import Empty from './Empty';
import { Content } from '@/ui/layout';
import React from 'react';
import DateCell from '@/components/page-list/date-cell';
import DateCell from '@/components/page-list/DateCell';
import { IconButton } from '@/ui/button';
import { Tooltip } from '@/ui/tooltip';
import { useRouter } from 'next/router';
import { useAppState } from '@/providers/app-state-provider/context';
import { toast } from '@/ui/toast';
import { usePageHelper } from '@/hooks/use-page-helper';
import { useTheme } from '@/providers/themeProvider';
import { useTheme } from '@/providers/ThemeProvider';
import { useTranslation } from 'react-i18next';
const FavoriteTag = ({
pageMeta: { favorite, id },

View File

@ -1,7 +1,7 @@
import React from 'react';
import { AddIcon } from '@blocksuite/icons';
import { StyledModalFooterContent } from './style';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { Command } from 'cmdk';
import { usePageHelper } from '@/hooks/use-page-helper';
import { useTranslation } from 'react-i18next';

View File

@ -1,12 +1,12 @@
import { Command } from 'cmdk';
import { StyledListItem, StyledNotFound } from './style';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { PaperIcon, EdgelessIcon } from '@blocksuite/icons';
import { Dispatch, SetStateAction, useEffect, useState } from 'react';
import { useAppState } from '@/providers/app-state-provider';
import { useRouter } from 'next/router';
import { useSwitchToConfig } from './config';
import { NoResultSVG } from './noResultSVG';
import { NoResultSVG } from './NoResultSVG';
import { useTranslation } from 'react-i18next';
import usePageHelper from '@/hooks/use-page-helper';
import usePageMetaList from '@/hooks/use-page-meta-list';

View File

@ -6,12 +6,12 @@ import {
StyledModalDivider,
StyledShortcut,
} from './style';
import { Input } from './input';
import { Results } from './results';
import { Footer } from './footer';
import { Input } from './Input';
import { Results } from './Results';
import { Footer } from './Footer';
import { Command } from 'cmdk';
import { useEffect, useState } from 'react';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { getUaHelper } from '@/utils';
import { useAppState } from '@/providers/app-state-provider';
type TransitionsModalProps = {

View File

@ -1,5 +1,5 @@
import { createPortal } from 'react-dom';
import { KeyboardIcon } from './icons';
import { KeyboardIcon } from './Icons';
import {
StyledListItem,
StyledModalHeader,

View File

@ -1 +1 @@
export * from './delete';
export * from './Delete';

View File

@ -1 +1 @@
export * from './general';
export * from './General';

View File

@ -1 +1 @@
export * from './leave';
export * from './Leave';

View File

@ -1 +1 @@
export * from './workspace-setting';
export * from './WorkspaceSetting';

View File

@ -13,7 +13,7 @@ import {
import { WorkspaceSetting } from '@/components/workspace-setting';
import { useCallback, useEffect, useState } from 'react';
import { getDataCenter, WorkspaceType } from '@affine/datacenter';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
export type WorkspaceDetails = Record<
string,

View File

@ -1 +1 @@
export * from './workspace-create';
export * from './WorkspaceCreate';

View File

@ -1,6 +1,6 @@
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { styled } from '@/styles';
import { AffineIcon } from '../../icons/icons';
import { AffineIcon } from '../../icons/Icons';
import {
WorkspaceItemAvatar,
LoginItemWrapper,

View File

@ -4,7 +4,7 @@ import { SelectorPopperContent } from './SelectorPopperContent';
import { useState } from 'react';
import { useAppState } from '@/providers/app-state-provider';
import { WorkspaceType } from '@affine/datacenter';
import { AffineIcon } from '../icons/icons';
import { AffineIcon } from '../icons/Icons';
export const WorkspaceSelector = () => {
const [isShow, setIsShow] = useState(false);

View File

@ -24,7 +24,7 @@ import {
} from '@blocksuite/icons';
import Link from 'next/link';
import { Tooltip } from '@/ui/tooltip';
import { useModal } from '@/providers/global-modal-provider';
import { useModal } from '@/providers/GlobalModalProvider';
import { useAppState } from '@/providers/app-state-provider/context';
import { IconButton } from '@/ui/button';
import useLocalStorage from '@/hooks/use-local-storage';

View File

@ -10,9 +10,9 @@ import '../utils/print-build-info';
import ProviderComposer from '@/components/provider-composer';
import type { PropsWithChildren, ReactElement, ReactNode } from 'react';
import type { NextPage } from 'next';
import { AppStateProvider } from '@/providers/app-state-provider/provider';
import ConfirmProvider from '@/providers/confirm-provider';
import { ModalProvider } from '@/providers/global-modal-provider';
import { AppStateProvider } from '@/providers/app-state-provider/Provider';
import ConfirmProvider from '@/providers/ConfirmProvider';
import { ModalProvider } from '@/providers/GlobalModalProvider';
import { useRouter } from 'next/router';
import { useEffect } from 'react';
import { useAppState } from '@/providers/app-state-provider';
@ -20,7 +20,7 @@ import { PageLoading } from '@/components/loading';
import Head from 'next/head';
import '@/libs/i18n';
const ThemeProvider = dynamic(() => import('@/providers/themeProvider'), {
const ThemeProvider = dynamic(() => import('@/providers/ThemeProvider'), {
ssr: false,
});

View File

@ -10,7 +10,7 @@ import type {
} from './context';
import { Page, Workspace as StoreWorkspace } from '@blocksuite/store';
import { EditorContainer } from '@blocksuite/editor';
const DynamicBlocksuite = dynamic(() => import('./dynamic-blocksuite'), {
const DynamicBlocksuite = dynamic(() => import('./DynamicBlocksuite'), {
ssr: false,
});