diff --git a/.github/workflows/cross.yml b/.github/workflows/cross.yml index 855a8f1..c24b204 100644 --- a/.github/workflows/cross.yml +++ b/.github/workflows/cross.yml @@ -84,6 +84,7 @@ jobs: check-latest: true - name: Write environment #TODO: add coachroach ssl certificate + shell: bash run: | echo $envfile > .env.tmp sed 's/ /\n/g' .env.tmp > .env diff --git a/.github/workflows/cross[hardhat].yml b/.github/workflows/cross[hardhat].yml index f06c4c3..1b15a0c 100644 --- a/.github/workflows/cross[hardhat].yml +++ b/.github/workflows/cross[hardhat].yml @@ -32,7 +32,7 @@ jobs: max-parallel: 2 fail-fast: false matrix: - os: [ubuntu-latest, macos-latest, windows-latest] + os: [windows-latest, ubuntu-latest, macos-latest] node_version: [18, 19, 20] architecture: [x64] @@ -54,6 +54,7 @@ jobs: check-latest: true - name: Write environment + shell: bash run: | echo $envfile > .env.tmp sed 's/ /\n/g' .env.tmp > .env diff --git a/.prettierignore b/.prettierignore index abcbe54..eac195a 100644 --- a/.prettierignore +++ b/.prettierignore @@ -1,3 +1,4 @@ .next/ pnpm-lock.yaml prisma/generated +hardhat/ \ No newline at end of file diff --git a/src/app/dashboard/repository/components/repository.tsx b/src/app/dashboard/repository/components/repository.tsx index b65a5ff..a02856a 100644 --- a/src/app/dashboard/repository/components/repository.tsx +++ b/src/app/dashboard/repository/components/repository.tsx @@ -1,47 +1,51 @@ +import useModelStore, { IModel } from '@/state/modelStore' import React from 'react' import { BiLike } from 'react-icons/bi' import { GoDownload } from 'react-icons/go' -export default function Repository({ repository }) { +export default function Repository() { + const { models } = useModelStore() + return (
-
- {repository.map((item) => ( -
-
-
- - {item.label} - -
-
- {item.title} + + {/* extract the values of the object */} + {models && Object.values(models).map(model => ( +
+
+
+ + {'Text Generation'} + +
+
+ {model.name} +
+
+

{model.description}

+
+
+
+ Updated {"12 2023"}
-
-

{item.description}

+
+ + {'12k'}
-
-
- Updated {item.time} -
-
- - {item.dowloaded} -
-
- - {item.likes} -
+
+ + {'50'}
- -
- ))} -
+ +
+
+ ))} +
) } diff --git a/src/app/dashboard/repository/page.tsx b/src/app/dashboard/repository/page.tsx index 7263276..7ebac2a 100644 --- a/src/app/dashboard/repository/page.tsx +++ b/src/app/dashboard/repository/page.tsx @@ -75,7 +75,7 @@ export default function Page() {
- +
diff --git a/src/state/modelStore.ts b/src/state/modelStore.ts index 0e3c0a4..06525d1 100644 --- a/src/state/modelStore.ts +++ b/src/state/modelStore.ts @@ -3,9 +3,9 @@ import { devtools, persist } from 'zustand/middleware' import { upsert_user } from '@app/explore/upsert_user' import { Model, TrainingRequest } from '@prisma/client' -type IModel = Omit, 'updatedAt'> +export type IModel = Omit, 'updatedAt'> -interface Models { +export interface Models { [modelId: string]: IModel }