Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Thumbnail select rework #1511

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 10 additions & 0 deletions src/apps/content-editor/src/app/components/Editor/Field/Field.js
Original file line number Diff line number Diff line change
Expand Up @@ -232,6 +232,11 @@ export default function Field({
open
fullScreen
sx={{ my: 2.5, mx: 10 }}
PaperProps={{
style: {
borderRadius: "4px",
},
}}
onClose={() => setImageModal()}
>
<IconButton
Expand Down Expand Up @@ -423,6 +428,11 @@ export default function Field({
open
fullScreen
sx={{ my: 2.5, mx: 10 }}
PaperProps={{
style: {
borderRadius: "4px",
},
}}
onClose={() => setImageModal()}
>
<IconButton
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,22 @@ import {
Tooltip,
} from "@mui/material";

import { alpha } from "@mui/material/styles";

interface Props {
filename: string;
onFilenameChange?: (value: string) => void;
onTitleChange?: (value: string) => void;
isEditable?: boolean;
isSelected?: boolean;
}

export const ThumbnailContent: FC<Props> = ({
filename,
onFilenameChange,
onTitleChange,
isEditable,
isSelected,
}) => {
const styledCardContent = {
px: onFilenameChange ? 0 : 1,
Expand All @@ -27,6 +31,12 @@ export const ThumbnailContent: FC<Props> = ({
overflow: "hidden",
whiteSpace: "nowrap",
textOverflow: "ellipsis",
backgroundColor: (theme: any) =>
isSelected &&
`${alpha(
theme.palette.primary.main,
theme.palette.action.hoverOpacity
)} !important`,
};

return (
Expand Down