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

⚠️ wip #630

Draft
wants to merge 5 commits into
base: v2
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions apps/web/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@
"@tanstack/react-query": "5.18.1",
"@ygtang/api": "workspace:^",
"@ygtang/constants": "workspace:*",
"@ygtang/hooks": "workspace:*",
"@ygtang/http": "workspace:^",
"@ygtang/ui-components": "workspace:*",
"@ygtang/ui-styles": "workspace:*",
Expand Down
Binary file added apps/webextension/public/insp-empty.webp
Binary file not shown.
36 changes: 36 additions & 0 deletions apps/webextension/src/components/Thumbnails/Thumbnails.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import { css } from "@emotion/react";
import { InspirationInterface, InspirationType } from "@ygtang/api";
import { Thumbnail } from "@ygtang/ui-components";

interface Props {
inspirations: InspirationInterface[];
}

export default function Thumbnails({ inspirations }: Props) {
return (
<div css={thumbnailWrapperCss}>
{inspirations.map(
({ id, type, content, openGraphResponse, memo, tagResponses }) => (
<Thumbnail
key={id}
id={id}
type={type as InspirationType}
content={content}
tags={tagResponses}
openGraph={openGraphResponse}
memo={memo}
/>
),
)}
</div>
);
}

const thumbnailWrapperCss = css`
width: 100%;
padding-top: 16px;
padding-bottom: 5px;
display: grid;
grid-template-columns: 1fr 1fr;
gap: 8px;
`;
1 change: 1 addition & 0 deletions apps/webextension/src/components/Thumbnails/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export { default } from "./Thumbnails";
Loading