Skip to content

armgit / ente

Public Imported from GitHub
0

πŸ’š End-to-end encrypted cloud for everything.

npx @mui/codemod@latest v6.0.0/sx-prop src

Manav Rathi084fb5bbed41
diff --git a/web/apps/photos/src/components/Collections/CollectionShare.tsx b/web/apps/photos/src/components/Collections/CollectionShare.tsx
index f01d1e1fd4..95c1301452 100644
--- a/web/apps/photos/src/components/Collections/CollectionShare.tsx
+++ b/web/apps/photos/src/components/Collections/CollectionShare.tsx
@@ -303,10 +303,10 @@ const EnablePublicShareOptions: React.FC<EnablePublicShareOptionsProps> = ({
<Typography
textAlign={"center"}
variant="small"
- sx={{
- color: (theme) => theme.colors.danger.A700,
+ sx={(theme) => ({
+ color: theme.colors.danger.A700,
mt: 0.5,
- }}
+ })}
>
{sharableLinkError}
</Typography>
@@ -1462,10 +1462,10 @@ const ManagePublicShareOptions: React.FC<ManagePublicShareOptionsProps> = ({
<Typography
textAlign={"center"}
variant="small"
- sx={{
- color: (theme) => theme.colors.danger.A700,
+ sx={(theme) => ({
+ color: theme.colors.danger.A700,
mt: 0.5,
- }}
+ })}
>
{sharableLinkError}
</Typography>
diff --git a/web/apps/photos/src/components/DropdownInput.tsx b/web/apps/photos/src/components/DropdownInput.tsx
index 80224af30a..16154e484f 100644
--- a/web/apps/photos/src/components/DropdownInput.tsx
+++ b/web/apps/photos/src/components/DropdownInput.tsx
@@ -102,11 +102,11 @@ export default function DropdownInput<T extends string>({
key={option.value}
divider={index !== options.length - 1}
value={option.value}
- sx={{
+ sx={(theme) => ({
px: "16px",
py: "14px",
- color: (theme) => theme.palette.primary.main,
- }}
+ color: theme.palette.primary.main,
+ })}
>
{option.label}
</MenuItem>
diff --git a/web/apps/photos/src/components/Notification.tsx b/web/apps/photos/src/components/Notification.tsx
index f0236121ae..67aca7c16f 100644
--- a/web/apps/photos/src/components/Notification.tsx
+++ b/web/apps/photos/src/components/Notification.tsx
@@ -59,12 +59,12 @@ export default function Notification({
<Button
color={attributes.variant}
onClick={handleClick}
- sx={{
+ sx={(theme) => ({
textAlign: "left",
flex: "1",
- padding: (theme) => theme.spacing(1.5, 2),
+ padding: theme.spacing(1.5, 2),
borderRadius: "8px",
- }}
+ })}
>
<Stack
flex={"1"}
diff --git a/web/apps/photos/src/components/WatchFolder.tsx b/web/apps/photos/src/components/WatchFolder.tsx
index 22c93fb3b4..b1e2a3513d 100644
--- a/web/apps/photos/src/components/WatchFolder.tsx
+++ b/web/apps/photos/src/components/WatchFolder.tsx
@@ -218,11 +218,11 @@ const CheckmarkIcon: React.FC = () => {
return (
<CheckIcon
fontSize="small"
- sx={{
+ sx={(theme) => ({
display: "inline",
fontSize: "15px",
- color: (theme) => theme.palette.secondary.main,
- }}
+ color: theme.palette.secondary.main,
+ })}
/>
);
};
diff --git a/web/apps/photos/src/pages/gallery.tsx b/web/apps/photos/src/pages/gallery.tsx
index 7df69feb2d..695d134319 100644
--- a/web/apps/photos/src/pages/gallery.tsx
+++ b/web/apps/photos/src/pages/gallery.tsx
@@ -1183,10 +1183,10 @@ const HiddenSectionNavbarContents: React.FC<
> = ({ onBack }) => (
<HorizontalFlex
gap={"24px"}
- sx={{
+ sx={(theme) => ({
width: "100%",
- background: (theme) => theme.palette.background.default,
- }}
+ background: theme.palette.background.default,
+ })}
>
<IconButton onClick={onBack}>
<ArrowBackIcon />