Skip to content

Commit

Permalink
refactor: add assets feature (#679)
Browse files Browse the repository at this point in the history
Co-authored-by: nina992 <nouralali992@gmail.com>
  • Loading branch information
nina992 and nina992 committed Sep 11, 2023
1 parent 5e41ba7 commit 41326d9
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 5 deletions.
Expand Up @@ -19,7 +19,7 @@ export type Asset = {
contentType: string;
};

export default ({
export const useManageAssets = ({
selectedAssets,
sort,
searchTerm,
Expand Down
@@ -1,14 +1,19 @@
import Button from "@reearth/beta/components/Button";
import Loading from "@reearth/beta/components/Loading";
import Text from "@reearth/beta/components/Text";
import AssetCard from "@reearth/beta/features/Assets/AssetCard";
import {
useManageAssets,
Asset as AssetType,
SortType,
fileFormats,
imageFormats,
} from "@reearth/beta/features/Assets/useManageAssets/hooks";
import { useT } from "@reearth/services/i18n";
import { styled } from "@reearth/services/theme";

import AssetCard from "../AssetCard";
import AssetDeleteModal from "../AssetDeleteModal";

import useHooks, { Asset as AssetType, SortType, fileFormats, imageFormats } from "./hooks";

export type Asset = AssetType;

export type AssetSortType = SortType;
Expand Down Expand Up @@ -63,7 +68,7 @@ const AssetContainer: React.FC<Props> = ({
openDeleteModal,
closeDeleteModal,
handleRemove,
} = useHooks({
} = useManageAssets({
sort,
selectedAssets,
searchTerm,
Expand Down

0 comments on commit 41326d9

Please sign in to comment.