From 55f1d18e94779ec11ce14a56ba982f322ed7263c Mon Sep 17 00:00:00 2001 From: kj1352 Date: Tue, 13 Jul 2021 20:10:38 +0530 Subject: [PATCH] data structure defined --- .../categories/details/CategoryDetails.module.scss | 0 src/components/categories/details/CategoryDetails.tsx | 8 ++++++++ src/components/revise/Revise.module.scss | 1 + src/structure/category.ts | 7 +++++++ src/structure/medals.ts | 6 ++++++ src/structure/profile.ts | 9 +++++++++ src/structure/shelf.ts | 8 ++++++++ src/structure/word.ts | 10 ++++++++++ 8 files changed, 49 insertions(+) create mode 100644 src/components/categories/details/CategoryDetails.module.scss create mode 100644 src/components/categories/details/CategoryDetails.tsx create mode 100644 src/structure/category.ts create mode 100644 src/structure/medals.ts create mode 100644 src/structure/profile.ts create mode 100644 src/structure/shelf.ts create mode 100644 src/structure/word.ts diff --git a/src/components/categories/details/CategoryDetails.module.scss b/src/components/categories/details/CategoryDetails.module.scss new file mode 100644 index 0000000..e69de29 diff --git a/src/components/categories/details/CategoryDetails.tsx b/src/components/categories/details/CategoryDetails.tsx new file mode 100644 index 0000000..38fd44b --- /dev/null +++ b/src/components/categories/details/CategoryDetails.tsx @@ -0,0 +1,8 @@ +import React from "react"; +import styles from './CategoryDetails.module.scss'; + +export const CategoryDetails: React.FC = () => { + return
+ +
+} \ No newline at end of file diff --git a/src/components/revise/Revise.module.scss b/src/components/revise/Revise.module.scss index 0460a37..5e5297a 100644 --- a/src/components/revise/Revise.module.scss +++ b/src/components/revise/Revise.module.scss @@ -4,6 +4,7 @@ background-color: white; position: relative; z-index: 2; + overflow-x: hidden; } .finishButton { diff --git a/src/structure/category.ts b/src/structure/category.ts new file mode 100644 index 0000000..8ffcd2f --- /dev/null +++ b/src/structure/category.ts @@ -0,0 +1,7 @@ +import { IShelf } from "./shelf"; + +export type ICategory = { + name: string, + icon: string, + shelves: Array +}; \ No newline at end of file diff --git a/src/structure/medals.ts b/src/structure/medals.ts new file mode 100644 index 0000000..dbc81a7 --- /dev/null +++ b/src/structure/medals.ts @@ -0,0 +1,6 @@ +export type IMedal = { + name: string, + minValue: number, + maxValue: number, + icon: string, +}; \ No newline at end of file diff --git a/src/structure/profile.ts b/src/structure/profile.ts new file mode 100644 index 0000000..96f8f46 --- /dev/null +++ b/src/structure/profile.ts @@ -0,0 +1,9 @@ +import { ICategory } from "./category"; +import { IMedal } from "./medals"; + +export type IProfile = { + name: string, + image: string, + medal: IMedal, + categories: Array +}; \ No newline at end of file diff --git a/src/structure/shelf.ts b/src/structure/shelf.ts new file mode 100644 index 0000000..37c6697 --- /dev/null +++ b/src/structure/shelf.ts @@ -0,0 +1,8 @@ +import { IWord } from "./word"; + +export type IShelf = { + words: Array, + revisedWords: Array, + description: string, + viewPermission: 'PRIVATE' | 'PUBLIC'; +}; \ No newline at end of file diff --git a/src/structure/word.ts b/src/structure/word.ts new file mode 100644 index 0000000..78c94f7 --- /dev/null +++ b/src/structure/word.ts @@ -0,0 +1,10 @@ +export type IWord = { + name: string, + pronounciation: string, + audioPronounciationURL: string, + grammaticalDetails: Array<{ + typeName: 'NOUN' | 'ADJECTIVE' | 'VERB', + description: string, + }>, + similarWords: Array +} \ No newline at end of file