mirror of
https://github.com/toeverything/AFFiNE.git
synced 2024-11-27 05:33:10 +03:00
Merge pull request #695 from suyanhanx/component-file-name-unify
chore: TSX file name unify
This commit is contained in:
commit
c4df4da082
@ -8,7 +8,7 @@ import {
|
||||
TelegramIcon,
|
||||
RedditIcon,
|
||||
LinkIcon,
|
||||
} from './icons';
|
||||
} from './Icons';
|
||||
import logo from './affine-text-logo.png';
|
||||
import {
|
||||
StyledBigLink,
|
||||
|
@ -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';
|
||||
|
@ -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';
|
||||
|
@ -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';
|
||||
|
@ -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,
|
@ -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;
|
@ -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,
|
@ -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';
|
@ -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';
|
||||
|
@ -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';
|
||||
|
@ -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 = () => {
|
||||
|
@ -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';
|
||||
|
@ -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 = ({
|
||||
|
@ -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')(() => {
|
@ -1,3 +1,3 @@
|
||||
import Loading from './loading';
|
||||
export * from './page-loading';
|
||||
import Loading from './Loading';
|
||||
export * from './PageLoading';
|
||||
export default Loading;
|
||||
|
@ -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();
|
||||
|
@ -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';
|
@ -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 },
|
||||
|
@ -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';
|
@ -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';
|
@ -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 = {
|
||||
|
@ -1,5 +1,5 @@
|
||||
import { createPortal } from 'react-dom';
|
||||
import { KeyboardIcon } from './icons';
|
||||
import { KeyboardIcon } from './Icons';
|
||||
import {
|
||||
StyledListItem,
|
||||
StyledModalHeader,
|
||||
|
@ -1 +1 @@
|
||||
export * from './delete';
|
||||
export * from './Delete';
|
||||
|
@ -1 +1 @@
|
||||
export * from './general';
|
||||
export * from './General';
|
||||
|
@ -1 +1 @@
|
||||
export * from './leave';
|
||||
export * from './Leave';
|
||||
|
@ -1 +1 @@
|
||||
export * from './workspace-setting';
|
||||
export * from './WorkspaceSetting';
|
||||
|
@ -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,
|
||||
|
@ -1 +1 @@
|
||||
export * from './workspace-create';
|
||||
export * from './WorkspaceCreate';
|
||||
|
@ -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,
|
||||
|
@ -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);
|
||||
|
@ -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';
|
||||
|
@ -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,
|
||||
});
|
||||
|
||||
|
@ -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,
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user