mirror of
https://github.com/ente-io/ente.git
synced 2025-08-09 07:48:52 +00:00
Inline
This commit is contained in:
parent
51ba9270e7
commit
6ccc85d318
@ -1,15 +1,24 @@
|
|||||||
import { useIsTouchscreen } from "@/base/hooks";
|
import { useIsTouchscreen } from "@/base/hooks";
|
||||||
import { FocusVisibleButton } from "@/new/photos/components/FocusVisibleButton";
|
import { FocusVisibleButton } from "@/new/photos/components/FocusVisibleButton";
|
||||||
|
import { SpaceBetweenFlex } from "@/new/photos/components/mui";
|
||||||
import DialogTitleWithCloseButton, {
|
import DialogTitleWithCloseButton, {
|
||||||
DialogTitleWithCloseButtonSm,
|
|
||||||
dialogCloseHandler,
|
dialogCloseHandler,
|
||||||
} from "@ente/shared/components/DialogBox/TitleWithCloseButton";
|
} from "@ente/shared/components/DialogBox/TitleWithCloseButton";
|
||||||
import { EnteMenuItem } from "@ente/shared/components/Menu/EnteMenuItem";
|
import { EnteMenuItem } from "@ente/shared/components/Menu/EnteMenuItem";
|
||||||
import ChevronRight from "@mui/icons-material/ChevronRight";
|
import ChevronRight from "@mui/icons-material/ChevronRight";
|
||||||
|
import CloseIcon from "@mui/icons-material/Close";
|
||||||
import GoogleIcon from "@mui/icons-material/Google";
|
import GoogleIcon from "@mui/icons-material/Google";
|
||||||
import { default as FileUploadIcon } from "@mui/icons-material/ImageOutlined";
|
import { default as FileUploadIcon } from "@mui/icons-material/ImageOutlined";
|
||||||
import { default as FolderUploadIcon } from "@mui/icons-material/PermMediaOutlined";
|
import { default as FolderUploadIcon } from "@mui/icons-material/PermMediaOutlined";
|
||||||
import { Box, Dialog, Link, Stack, Typography } from "@mui/material";
|
import {
|
||||||
|
Box,
|
||||||
|
Dialog,
|
||||||
|
DialogTitle,
|
||||||
|
IconButton,
|
||||||
|
Link,
|
||||||
|
Stack,
|
||||||
|
Typography,
|
||||||
|
} from "@mui/material";
|
||||||
import { t } from "i18next";
|
import { t } from "i18next";
|
||||||
import React, { useContext, useEffect, useState } from "react";
|
import React, { useContext, useEffect, useState } from "react";
|
||||||
import { PublicCollectionGalleryContext } from "utils/publicCollectionGallery";
|
import { PublicCollectionGalleryContext } from "utils/publicCollectionGallery";
|
||||||
@ -211,9 +220,18 @@ const TakeoutOptions: React.FC<Omit<OptionsProps, "intent">> = ({
|
|||||||
}) => {
|
}) => {
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
<DialogTitleWithCloseButtonSm onClose={onClose}>
|
<DialogTitle>
|
||||||
{t("google_takeout")}
|
<SpaceBetweenFlex>
|
||||||
</DialogTitleWithCloseButtonSm>
|
{t("google_takeout")}
|
||||||
|
<IconButton
|
||||||
|
aria-label={t("close")}
|
||||||
|
color="secondary"
|
||||||
|
onClick={onClose}
|
||||||
|
>
|
||||||
|
<CloseIcon />
|
||||||
|
</IconButton>
|
||||||
|
</SpaceBetweenFlex>
|
||||||
|
</DialogTitle>
|
||||||
|
|
||||||
<Box p={1.5}>
|
<Box p={1.5}>
|
||||||
<Stack gap={2.5}>
|
<Stack gap={2.5}>
|
||||||
|
@ -37,28 +37,6 @@ const DialogTitleWithCloseButton: React.FC<
|
|||||||
};
|
};
|
||||||
export default DialogTitleWithCloseButton;
|
export default DialogTitleWithCloseButton;
|
||||||
|
|
||||||
export const DialogTitleWithCloseButtonSm: React.FC<
|
|
||||||
React.PropsWithChildren<DialogTitleWithCloseButtonProps>
|
|
||||||
> = ({ children, onClose }) => {
|
|
||||||
return (
|
|
||||||
<DialogTitle>
|
|
||||||
<SpaceBetweenFlex>
|
|
||||||
{children}
|
|
||||||
{onClose && (
|
|
||||||
<IconButton
|
|
||||||
aria-label="close"
|
|
||||||
onClick={onClose}
|
|
||||||
sx={{ float: "right" }}
|
|
||||||
color="secondary"
|
|
||||||
>
|
|
||||||
<CloseIcon />
|
|
||||||
</IconButton>
|
|
||||||
)}
|
|
||||||
</SpaceBetweenFlex>
|
|
||||||
</DialogTitle>
|
|
||||||
);
|
|
||||||
};
|
|
||||||
|
|
||||||
export const dialogCloseHandler =
|
export const dialogCloseHandler =
|
||||||
({
|
({
|
||||||
staticBackdrop,
|
staticBackdrop,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user