Skip to content

armgit / ente

Public Imported from GitHub
0

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

[photos] Use Hugeicons for cover selection

AswinAsok782197448c70
diff --git a/web/apps/photos/public/images/cover-selected.svg b/web/apps/photos/public/images/cover-selected.svg
deleted file mode 100644
index cbb965e6c3..0000000000
--- a/web/apps/photos/public/images/cover-selected.svg
+++ /dev/null
@@ -1,5 +0,0 @@
-<svg preserveAspectRatio="none" overflow="visible" style="display: block;" width="13" height="13" viewBox="0 0 13 13" fill="none" xmlns="http://www.w3.org/2000/svg">
-<g id="Frame">
-<path id="Vector" d="M2.16667 6.77083L5.14583 9.75L10.8333 3.52083" stroke-width="1.625" stroke-linecap="round" stroke-linejoin="round" stroke="white" style="stroke:white;stroke-opacity:1;"/>
-</g>
-</svg>
diff --git a/web/apps/photos/src/components/collections/CoverPhotoGrid.tsx b/web/apps/photos/src/components/collections/CoverPhotoGrid.tsx
index 3e3fc6f8e6..fa1b361be9 100644
--- a/web/apps/photos/src/components/collections/CoverPhotoGrid.tsx
+++ b/web/apps/photos/src/components/collections/CoverPhotoGrid.tsx
@@ -1,3 +1,5 @@
+import { Tick02Icon } from "@hugeicons/core-free-icons";
+import { HugeiconsIcon } from "@hugeicons/react";
import { Box, styled } from "@mui/material";
import log from "ente-base/log";
import { downloadManager } from "ente-gallery/services/download";
@@ -188,11 +190,12 @@ const CoverPhotoCard = memo(
placeItems: "center",
}}
>
- <img
- src="/images/cover-selected.svg"
- width={13}
- height={13}
- alt=""
+ <HugeiconsIcon
+ icon={Tick02Icon}
+ size={13}
+ strokeWidth={3}
+ color="#fff"
+ aria-hidden
/>
</Box>
</Box>
diff --git a/web/apps/photos/tests/cover-photo-grid.test.tsx b/web/apps/photos/tests/cover-photo-grid.test.tsx
index 23e04a2a44..ee9e26e03c 100644
--- a/web/apps/photos/tests/cover-photo-grid.test.tsx
+++ b/web/apps/photos/tests/cover-photo-grid.test.tsx
@@ -57,7 +57,7 @@ describe("cover photo grid", () => {
expect(markup).toMatch(/aria-label="Photo 1" aria-pressed="true"/);
expect(markup.match(/>Current</g)).toHaveLength(1);
expect(
- markup.match(/src="\/images\/cover-selected.svg"/g),
+ markup.match(/<svg\b[^>]*width="13"[^>]*height="13"[^>]*>/g),
).toHaveLength(1);
});