From bdbb441a3de43f6b561907e7f54fb13ad4cac40c Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Sun, 30 Jul 2023 21:36:32 +0900
Subject: [PATCH 01/22] =?UTF-8?q?fix:=20lint=20=EC=84=A4=EC=A0=95=20?=
=?UTF-8?q?=EC=88=98=EC=A0=95?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.eslintrc.cjs | 29 +++++++++++++++--------------
1 file changed, 15 insertions(+), 14 deletions(-)
diff --git a/.eslintrc.cjs b/.eslintrc.cjs
index 926756e..99df7f1 100644
--- a/.eslintrc.cjs
+++ b/.eslintrc.cjs
@@ -4,23 +4,24 @@ module.exports = {
es2021: true,
},
extends: [
- "standard-with-typescript",
- "plugin:react/recommended",
- "prettier",
- "plugin:prettier/recommended",
- "plugin:storybook/recommended",
+ 'standard-with-typescript',
+ 'plugin:react/recommended',
+ 'prettier',
+ 'plugin:prettier/recommended',
+ 'plugin:storybook/recommended',
+ 'eslint-config-prettier',
],
parserOptions: {
- ecmaVersion: "latest",
- sourceType: "module",
- project: "./tsconfig.json",
+ ecmaVersion: 'latest',
+ sourceType: 'module',
+ project: './tsconfig.json',
},
- plugins: ["react", "@typescript-eslint"],
+ plugins: ['react', '@typescript-eslint'],
rules: {
- "react/react-in-jsx-scope": "off",
- "@typescript-eslint/explicit-function-return-type": "off",
- "@typescript-eslint/triple-slash-reference": "off",
- "@typescript-eslint/no-non-null-assertion": "off",
+ 'react/react-in-jsx-scope': 'off',
+ '@typescript-eslint/explicit-function-return-type': 'off',
+ '@typescript-eslint/triple-slash-reference': 'off',
+ '@typescript-eslint/no-non-null-assertion': 'off',
},
- ignorePatterns: [".eslintrc.cjs", "vite.config.ts"],
+ ignorePatterns: ['.eslintrc.cjs', 'vite.config.ts'],
};
From 6be2277b3321fb9a7a1dbcc29390ae395410d8fa Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Sat, 5 Aug 2023 14:24:49 +0900
Subject: [PATCH 02/22] =?UTF-8?q?feat:=20=EC=B6=94=EC=96=B5=EC=9D=98=20?=
=?UTF-8?q?=EC=A1=B0=EA=B0=81=20=EC=96=91=EC=8B=9D=EC=9D=84=20=EB=A7=8C?=
=?UTF-8?q?=EB=93=A0=EB=8B=A4.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
.eslintrc.cjs | 2 +-
src/App.tsx | 413 ++++++++++++++++++++++++++++++++++++-
src/component/Click.css.ts | 72 +++++++
src/component/Click.tsx | 106 ++++++++++
src/index.css | 2 +-
tsconfig.json | 2 +-
tsconfig.node.json | 3 +-
7 files changed, 594 insertions(+), 6 deletions(-)
create mode 100644 src/component/Click.css.ts
create mode 100644 src/component/Click.tsx
diff --git a/.eslintrc.cjs b/.eslintrc.cjs
index 99df7f1..870bd85 100644
--- a/.eslintrc.cjs
+++ b/.eslintrc.cjs
@@ -14,7 +14,7 @@ module.exports = {
parserOptions: {
ecmaVersion: 'latest',
sourceType: 'module',
- project: './tsconfig.json',
+ //project: './tsconfig.json',
},
plugins: ['react', '@typescript-eslint'],
rules: {
diff --git a/src/App.tsx b/src/App.tsx
index 2a73e54..fc386d1 100644
--- a/src/App.tsx
+++ b/src/App.tsx
@@ -1,7 +1,416 @@
import './App.css';
+import Click from './component/Click';
+
+// App.tsx or App.js
function App() {
- return
hello, world! ;
-}
+ const handleClick = () => {
+ console.log("CLICK")
+ window.location.href = 'https://www.google.com';
+ };
+ return (
+
+
+
+ 2022.11.23
+ 버튼
+
+ 강원도에서의 겨울
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ 2023.07.23
+ 버튼
+
+ 강원도에서의 여름
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다.
+ 밤의 아랫쪽이 하얘졌다. 신호소에 기차가 멈춰 섰다.
+ 건너편 좌석의 여자가 일어서 다가오더니, 시마무라 앞의 유리창을 열어젖혔다.
+ 눈의 냉기가 흘러들었다.
+ 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー"
+ 등불을 들고 천천히 눈을 밟고 온 남자는 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+
+
+ );
+}
export default App;
diff --git a/src/component/Click.css.ts b/src/component/Click.css.ts
new file mode 100644
index 0000000..de6a5ce
--- /dev/null
+++ b/src/component/Click.css.ts
@@ -0,0 +1,72 @@
+import { style } from '@vanilla-extract/css';
+
+export const click = style({
+ position: 'relative',
+ width: '100%',
+ height: '180px',
+ borderRadius: '4px',
+ boxShadow: '0 4px 6px rgba(0, 0, 0, 0.1)',
+ padding: '16px',
+ display: 'flex',
+ flexDirection: 'column',
+ alignItems: 'flex-start',
+ gap: '8px',
+ background: 'transparent',
+ zIndex: '100',
+});
+
+export const date = style({
+ fontSize: '12px',
+ color: 'gray',
+ margin: 0,
+});
+
+export const heading = style({
+ fontSize: '16px',
+ fontWeight: 'bold',
+ color: 'black',
+ margin: 0,
+});
+
+export const description = style({
+ fontSize: '12px',
+ color: 'gray',
+ margin: 0,
+ overflow: 'hidden',
+ textAlign: 'left'
+});
+
+export const button = style({
+ backgroundColor: 'transparent',
+ border: '1px solid #0070f3',
+ borderRadius: '4px',
+ color: '#0070f3',
+ cursor: 'pointer',
+ padding: '6px 12px',
+ textAlign: 'center',
+});
+
+export const image = style({
+ width: '100%',
+ borderRadius: '4px',
+});
+
+export const cardImage = style({
+ width: '100%',
+ borderRadius: '4px',
+});
+
+export const avatarImage = style({
+ borderRadius: '50%',
+});
+
+export const backgroundImage = style({
+ position: 'absolute',
+ width: '100%',
+ height: '100%',
+ top: '0',
+ left: '0',
+ opacity: '0.25'
+});
+
+
diff --git a/src/component/Click.tsx b/src/component/Click.tsx
new file mode 100644
index 0000000..d96d47d
--- /dev/null
+++ b/src/component/Click.tsx
@@ -0,0 +1,106 @@
+import type { ReactNode } from 'react';
+import { createContext, useContext } from 'react';
+import {
+ click,
+ date,
+ heading,
+ button,
+ backgroundImage,
+ description,
+} from './Click.css';
+
+interface ClickContextProps {
+ onClick?: () => void;
+}
+
+const ClickContext = createContext({});
+
+function useClickContext(): ClickContextProps {
+ const context = useContext(ClickContext);
+
+ if (!context.onClick) {
+ throw new Error(
+ 'Child components of Click cannot be rendered outside the Click component!'
+ );
+ }
+
+ return context;
+}
+
+interface ChildrenProps {
+ children: ReactNode;
+}
+
+interface ClickProps extends ChildrenProps {
+ onClick?: () => void;
+}
+
+const Click = ({ children, onClick }: ClickProps) => {
+ return (
+
+
+ {children}
+
+
+ );
+};
+
+interface DateProps extends ChildrenProps {}
+
+const Date = ({ children }: DateProps) => {
+ return {children} ;
+};
+
+Click.Date = Date;
+
+interface HeadingProps extends ChildrenProps {}
+
+const Heading = ({ children }: HeadingProps) => {
+ return {children} ;
+};
+
+Click.Heading = Heading;
+
+interface DescriptionProps extends ChildrenProps {}
+
+const Description = ({ children }: DescriptionProps) => {
+ return {children}
;
+};
+
+Click.Description = Description;
+
+interface ButtonProps extends ChildrenProps {}
+
+const Button = ({ children }: ButtonProps) => {
+ const { onClick } = useClickContext();
+
+ return (
+
+ {children}
+
+ );
+};
+
+Click.Button = Button;
+
+interface ImageProps {
+ src: string;
+ alt: string;
+ type?: string;
+}
+
+const Image = ({ src, alt, type }: ImageProps) => {
+ useClickContext();
+
+ return (
+
+ );
+};
+
+Click.Image = Image;
+
+export default Click;
diff --git a/src/index.css b/src/index.css
index 2c3fac6..12e77c9 100644
--- a/src/index.css
+++ b/src/index.css
@@ -5,7 +5,7 @@
color-scheme: light dark;
color: rgba(255, 255, 255, 0.87);
- background-color: #242424;
+ background-color: #dad7d7;
font-synthesis: none;
text-rendering: optimizeLegibility;
diff --git a/tsconfig.json b/tsconfig.json
index 376bd0b..b22b621 100644
--- a/tsconfig.json
+++ b/tsconfig.json
@@ -20,6 +20,6 @@
"noUnusedParameters": true,
"noFallthroughCasesInSwitch": true
},
- "include": ["src/**/*"],
+ "include": ["src/**/*.tsx", "src/**/*.ts",],
"references": [{ "path": "./tsconfig.node.json" }]
}
diff --git a/tsconfig.node.json b/tsconfig.node.json
index 3bd178a..bde2807 100644
--- a/tsconfig.node.json
+++ b/tsconfig.node.json
@@ -5,6 +5,7 @@
"skipLibCheck": true,
"module": "ESNext",
"moduleResolution": "bundler",
- "allowSyntheticDefaultImports": true
+ "allowSyntheticDefaultImports": true,
+ "allowImportingTsExtensions": false
}
}
From 935d459ba5ec6579d148fae30ce1275b31ac4d7d Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Sun, 6 Aug 2023 20:31:59 +0900
Subject: [PATCH 03/22] =?UTF-8?q?fix:=20baseUrl=EC=9D=84=20=EC=88=98?=
=?UTF-8?q?=EC=A0=95=ED=95=9C=EB=8B=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/utils/fetchApi.ts | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/src/utils/fetchApi.ts b/src/utils/fetchApi.ts
index 4f6eb77..a64d357 100644
--- a/src/utils/fetchApi.ts
+++ b/src/utils/fetchApi.ts
@@ -1,7 +1,8 @@
-const baseURL = 'localhost:3000';
+const baseURL = 'http://localhost:3000'
export async function fetchApi(url, options = {}) {
-
+ // 토큰을 가져와서 헤더에 넣어주는 경우 고려
+ // header에 Authorization: Bearer {token} 추가만 하면 됨
const defaultOptions = {
method: 'GET',
headers: {
From deabee0a4333afe90389745ce33956e0cd65609a Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Sun, 6 Aug 2023 21:00:41 +0900
Subject: [PATCH 04/22] =?UTF-8?q?feat:=20=EC=A3=BC=EB=A7=88=EB=93=B1=20?=
=?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=80=20=EC=83=9D=EC=84=B1=20=EB=B0=8F=20?=
=?UTF-8?q?=EA=B3=B5=ED=86=B5=EB=90=9C=20=EB=A0=88=EC=9D=B4=EC=95=84?=
=?UTF-8?q?=EC=9B=83=EC=9D=84=20=EB=B6=84=EB=A6=AC=ED=95=9C=EB=8B=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/main.tsx | 18 ++++++++++++++++--
src/pages/Kaleidoscope.tsx | 7 +++++++
src/pages/Layout.css.ts | 15 +++++++++++++++
src/pages/Layout.tsx | 14 ++++++++++++++
4 files changed, 52 insertions(+), 2 deletions(-)
create mode 100644 src/pages/Kaleidoscope.tsx
create mode 100644 src/pages/Layout.css.ts
create mode 100644 src/pages/Layout.tsx
diff --git a/src/main.tsx b/src/main.tsx
index 2cc1f84..b0f16a4 100644
--- a/src/main.tsx
+++ b/src/main.tsx
@@ -1,10 +1,24 @@
import ReactDOM from 'react-dom/client';
-import App from './App';
import './index.css';
import { StrictMode } from 'react';
+import { createBrowserRouter, RouterProvider } from 'react-router-dom';
+import Kaleidoscope from './pages/kaleidoscope';
+import Layout from './pages/Layout';
+
+const router = createBrowserRouter([
+ {
+ path: '/',
+ element: (
+
+
+
+ ),
+ },
+]);
+
ReactDOM.createRoot(document.getElementById('root')!).render(
-
+
);
diff --git a/src/pages/Kaleidoscope.tsx b/src/pages/Kaleidoscope.tsx
new file mode 100644
index 0000000..b08403d
--- /dev/null
+++ b/src/pages/Kaleidoscope.tsx
@@ -0,0 +1,7 @@
+const Kaleidoscope = () => {
+ return (
+ kaleidoscope
+ )
+}
+
+export default Kaleidoscope
\ No newline at end of file
diff --git a/src/pages/Layout.css.ts b/src/pages/Layout.css.ts
new file mode 100644
index 0000000..0daf9aa
--- /dev/null
+++ b/src/pages/Layout.css.ts
@@ -0,0 +1,15 @@
+import { style } from "@vanilla-extract/css";
+
+export const navBar = style({
+ position: 'fixed',
+ bottom: 0,
+ left: 0,
+ width: '100%',
+ height: '56px',
+ backgroundColor: 'lightblue',
+ display: 'flex',
+ justifyContent: 'space-around',
+ alignItems: 'center',
+ padding: '10px',
+ zIndex: 100,
+});
\ No newline at end of file
diff --git a/src/pages/Layout.tsx b/src/pages/Layout.tsx
new file mode 100644
index 0000000..13b4cb1
--- /dev/null
+++ b/src/pages/Layout.tsx
@@ -0,0 +1,14 @@
+import { navBar } from "./Layout.css";
+
+const Layout = ({ children }) => {
+ return (
+
+
+ 1,2,3,4
+
+ {children}
+
+ );
+};
+
+export default Layout;
\ No newline at end of file
From 4839b7626d4b3212bc03b0c268242063685f4175 Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Mon, 7 Aug 2023 10:29:12 +0900
Subject: [PATCH 05/22] =?UTF-8?q?feat:=20=EC=A3=BC=EB=A7=88=EB=93=B1=20?=
=?UTF-8?q?=ED=8E=98=EC=9D=B4=EC=A7=80=EC=9D=98=20=EC=A0=9C=EB=AA=A9=20?=
=?UTF-8?q?=EB=B0=8F=20=EC=83=81=EB=8B=A8=20=ED=83=9C=EA=B7=B8=EB=A5=BC=20?=
=?UTF-8?q?=EC=99=84=EC=84=B1=ED=95=9C=EB=8B=A4.?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/App.css | 35 +++++----------------
src/component/Select.css.ts | 43 ++++++++++++++++++++++++++
src/component/Select.tsx | 58 +++++++++++++++++++++++++++++++++++
src/index.css | 21 +++++--------
src/pages/Kaleidoscope.css.ts | 29 ++++++++++++++++++
src/pages/Kaleidoscope.tsx | 42 ++++++++++++++++++++++---
src/pages/Layout.css.ts | 2 +-
src/pages/Layout.tsx | 10 ++++--
8 files changed, 190 insertions(+), 50 deletions(-)
create mode 100644 src/component/Select.css.ts
create mode 100644 src/component/Select.tsx
create mode 100644 src/pages/Kaleidoscope.css.ts
diff --git a/src/App.css b/src/App.css
index b9d355d..5c70994 100644
--- a/src/App.css
+++ b/src/App.css
@@ -1,36 +1,15 @@
#root {
max-width: 1280px;
- margin: 0 auto;
- padding: 2rem;
+ box-sizing: border-box;
text-align: center;
+ width: 100%;
+ height: 100%;
}
-.logo {
- height: 6em;
- padding: 1.5em;
- will-change: filter;
- transition: filter 300ms;
-}
-.logo:hover {
- filter: drop-shadow(0 0 2em #646cffaa);
-}
-.logo.react:hover {
- filter: drop-shadow(0 0 2em #61dafbaa);
-}
-
-@keyframes logo-spin {
- from {
- transform: rotate(0deg);
- }
- to {
- transform: rotate(360deg);
- }
-}
-
-@media (prefers-reduced-motion: no-preference) {
- a:nth-of-type(2) .logo {
- animation: logo-spin infinite 20s linear;
- }
+body {
+ font-family: 'Roboto', sans-serif;
+ width: 100vw;
+ margin: 0;
}
.card {
diff --git a/src/component/Select.css.ts b/src/component/Select.css.ts
new file mode 100644
index 0000000..ccb962a
--- /dev/null
+++ b/src/component/Select.css.ts
@@ -0,0 +1,43 @@
+import { style } from '@vanilla-extract/css';
+
+export const scrollableContainer = style({
+ display: 'flex',
+ overflowX: 'auto',
+ height: '80px',
+ padding: '0px 12px',
+ zIndex: 1,
+ background: 'white',
+ '::-webkit-scrollbar': {
+ display: 'none',
+ },
+});
+
+export const tagStyle = style({
+ minWidth: '60px',
+ width: '60px',
+ padding: '5px 10px',
+ margin: '0 5px',
+ backgroundColor: 'white',
+ color: 'black',
+ fontSize: '14px',
+ fontWeight: 'bold',
+ textAlign: 'center',
+ borderRadius: '5px',
+ border: '1px solid #ccc',
+ cursor: 'pointer',
+});
+
+export const selectedTagStyle = style({
+ backgroundColor: 'black',
+ color: 'white',
+ minWidth: '60px',
+ width: '60px',
+ padding: '5px 10px',
+ margin: '0 5px',
+ fontSize: '14px',
+ fontWeight: 'bold',
+ textAlign: 'center',
+ borderRadius: '5px',
+ border: '1px solid #ccc',
+ cursor: 'pointer',
+});
diff --git a/src/component/Select.tsx b/src/component/Select.tsx
new file mode 100644
index 0000000..940fce7
--- /dev/null
+++ b/src/component/Select.tsx
@@ -0,0 +1,58 @@
+import { ReactNode, createContext, useContext, useState } from 'react';
+
+interface SelectContextProps {
+ selected: string;
+ setSelected: (value: string) => void;
+}
+
+const SelectContext = createContext(null);
+
+interface SelectProps {
+ children: ReactNode;
+ defaultOption: string;
+ className?: string;
+}
+
+const Select = ({ children, defaultOption, className }: SelectProps) => {
+ const [selected, setSelected] = useState(defaultOption);
+
+ const contextValue: SelectContextProps = {
+ selected,
+ setSelected,
+ };
+
+ return (
+
+
+
+ );
+};
+
+interface OptionProps {
+ value: string;
+ children: ReactNode;
+ className?: { selectedTagStyle: string; tagStyle: string };
+}
+
+const Option = ({ value, children, className }: OptionProps) => {
+ const context = useContext(SelectContext);
+ if (context === undefined) {
+ throw new Error('은 Select 아래에서만 사용 가능!!');
+ }
+
+ const { selected, setSelected } = context;
+ const { selectedTagStyle, tagStyle } = className;
+
+ const isSelected = selected === value;
+ const optionClassName = `${isSelected ? selectedTagStyle : tagStyle}`;
+
+ return (
+ setSelected(value)} className={`${optionClassName}`}>
+ {children}
+
+ );
+};
+
+Select.Option = Option;
+
+export default Select;
diff --git a/src/index.css b/src/index.css
index 12e77c9..9a7755b 100644
--- a/src/index.css
+++ b/src/index.css
@@ -1,5 +1,4 @@
:root {
- font-family: Inter, system-ui, Avenir, Helvetica, Arial, sans-serif;
line-height: 1.5;
font-weight: 400;
@@ -26,6 +25,7 @@ a:hover {
body {
margin: 0;
display: flex;
+ width: 100vw;
place-items: center;
min-width: 320px;
min-height: 100vh;
@@ -36,6 +36,12 @@ h1 {
line-height: 1.1;
}
+ul {
+ list-style: none;
+ padding: 0;
+ margin: 0;
+}
+
button {
border-radius: 8px;
border: 1px solid transparent;
@@ -54,16 +60,3 @@ button:focus,
button:focus-visible {
outline: 4px auto -webkit-focus-ring-color;
}
-
-@media (prefers-color-scheme: light) {
- :root {
- color: #213547;
- background-color: #ffffff;
- }
- a:hover {
- color: #747bff;
- }
- button {
- background-color: #f9f9f9;
- }
-}
diff --git a/src/pages/Kaleidoscope.css.ts b/src/pages/Kaleidoscope.css.ts
new file mode 100644
index 0000000..f5bb1d9
--- /dev/null
+++ b/src/pages/Kaleidoscope.css.ts
@@ -0,0 +1,29 @@
+import { style } from '@vanilla-extract/css';
+
+export const pageWrapper = style({
+ display: 'flex',
+ flexDirection: 'column',
+ height: '100vh',
+ width: '100vw',
+ backgroundColor: 'white',
+});
+
+export const pageTitle = style({
+ fontFamily: 'SF Pro Display',
+ fontSize: '24px',
+ whiteSpace: 'nowrap',
+ textOverflow: 'ellipsis',
+ padding: '0 20px',
+});
+
+export const blurText = style({
+ fontWeight: 'normal',
+ fontSize: '20px',
+ color: 'rgba(0, 0, 0, 0.6)',
+});
+
+export const boldText = style({
+ fontWeight: 'bold',
+ fontSize: '26px',
+ color: 'black',
+});
diff --git a/src/pages/Kaleidoscope.tsx b/src/pages/Kaleidoscope.tsx
index b08403d..9a86ece 100644
--- a/src/pages/Kaleidoscope.tsx
+++ b/src/pages/Kaleidoscope.tsx
@@ -1,7 +1,41 @@
+import Select from '../component/Select';
+import {
+ scrollableContainer,
+ selectedTagStyle,
+ tagStyle,
+} from '../component/Select.css';
+import { boldText, pageTitle, pageWrapper } from './Kaleidoscope.css';
+
+const options = [
+ { value: '전부', label: '전부' },
+ { value: '추억', label: '추억' },
+ { value: '후회', label: '후회' },
+ { value: '혼자', label: '혼자' },
+ { value: '같이', label: '같이' },
+];
+
const Kaleidoscope = () => {
return (
- kaleidoscope
- )
-}
+ <>
+
+
+ 기억
+
+
+
+ {options.map((option) => (
+
+ {option.label}
+
+ ))}
+
+
+ >
+ );
+};
-export default Kaleidoscope
\ No newline at end of file
+export default Kaleidoscope;
diff --git a/src/pages/Layout.css.ts b/src/pages/Layout.css.ts
index 0daf9aa..b24a9b4 100644
--- a/src/pages/Layout.css.ts
+++ b/src/pages/Layout.css.ts
@@ -6,7 +6,7 @@ export const navBar = style({
left: 0,
width: '100%',
height: '56px',
- backgroundColor: 'lightblue',
+ backgroundColor: '#9BACB4',
display: 'flex',
justifyContent: 'space-around',
alignItems: 'center',
diff --git a/src/pages/Layout.tsx b/src/pages/Layout.tsx
index 13b4cb1..ea3e4a2 100644
--- a/src/pages/Layout.tsx
+++ b/src/pages/Layout.tsx
@@ -2,12 +2,16 @@ import { navBar } from "./Layout.css";
const Layout = ({ children }) => {
return (
-
+ <>
- 1,2,3,4
+ 1
+ 2
+ +
+ 3
+ 4
{children}
-
+ >
);
};
From 15d5e7ea00679b6ef3751d240da43a5cbd178ea2 Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Mon, 7 Aug 2023 10:46:10 +0900
Subject: [PATCH 06/22] =?UTF-8?q?refactor:=20=EC=83=81=EB=8B=A8=20?=
=?UTF-8?q?=ED=83=AD=20css=EB=A5=BC=20=EC=88=98=EC=A0=95=ED=95=9C=EB=8B=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/component/Select.css.ts | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/src/component/Select.css.ts b/src/component/Select.css.ts
index ccb962a..cb33927 100644
--- a/src/component/Select.css.ts
+++ b/src/component/Select.css.ts
@@ -2,8 +2,9 @@ import { style } from '@vanilla-extract/css';
export const scrollableContainer = style({
display: 'flex',
+ justifyContent: 'stretch',
overflowX: 'auto',
- height: '80px',
+ height: '65px',
padding: '0px 12px',
zIndex: 1,
background: 'white',
@@ -13,6 +14,9 @@ export const scrollableContainer = style({
});
export const tagStyle = style({
+ display: 'flex',
+ justifyContent: 'center',
+ alignItems: 'center',
minWidth: '60px',
width: '60px',
padding: '5px 10px',
@@ -28,6 +32,9 @@ export const tagStyle = style({
});
export const selectedTagStyle = style({
+ display: 'flex',
+ justifyContent: 'center',
+ alignItems: 'center',
backgroundColor: 'black',
color: 'white',
minWidth: '60px',
From fa031b2eae90a6e3839eee9c58ebb6fbfdbee943 Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Tue, 8 Aug 2023 00:05:47 +0900
Subject: [PATCH 07/22] =?UTF-8?q?feat:=20=EA=B0=81=EA=B0=81=EC=9D=98=20?=
=?UTF-8?q?=EA=B8=B0=EC=96=B5=EA=B3=BC=20=EA=B8=B0=EC=96=B5=20=EB=A6=AC?=
=?UTF-8?q?=EC=8A=A4=ED=8A=B8=EC=9D=98=20=EB=A0=88=EC=9D=B4=EC=95=84?=
=?UTF-8?q?=EC=9B=83=EC=9D=84=20=EA=B5=AC=ED=98=84=ED=95=9C=EB=8B=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/component/{Click.css.ts => Card.css.ts} | 32 +++---
src/component/Card.tsx | 93 +++++++++++++++++
src/component/Click.tsx | 106 --------------------
src/pages/Kaleidoscope.css.ts | 13 +++
src/pages/Kaleidoscope.tsx | 34 ++++++-
5 files changed, 158 insertions(+), 120 deletions(-)
rename src/component/{Click.css.ts => Card.css.ts} (67%)
create mode 100644 src/component/Card.tsx
delete mode 100644 src/component/Click.tsx
diff --git a/src/component/Click.css.ts b/src/component/Card.css.ts
similarity index 67%
rename from src/component/Click.css.ts
rename to src/component/Card.css.ts
index de6a5ce..8e40c82 100644
--- a/src/component/Click.css.ts
+++ b/src/component/Card.css.ts
@@ -1,12 +1,12 @@
import { style } from '@vanilla-extract/css';
-export const click = style({
+export const card = style({
position: 'relative',
- width: '100%',
height: '180px',
borderRadius: '4px',
- boxShadow: '0 4px 6px rgba(0, 0, 0, 0.1)',
+ boxShadow: '0 4px 6px rgba(0, 0, 0, 0.2)',
padding: '16px',
+ marginBottom: '8px',
display: 'flex',
flexDirection: 'column',
alignItems: 'flex-start',
@@ -33,16 +33,24 @@ export const description = style({
color: 'gray',
margin: 0,
overflow: 'hidden',
- textAlign: 'left'
+ display: '-webkit-box',
+ WebkitLineClamp: 3,
+ WebkitBoxOrient: 'vertical',
+ textAlign: 'left',
});
-export const button = style({
- backgroundColor: 'transparent',
- border: '1px solid #0070f3',
+export const category = style({
+ display: 'flex',
+ alignItems: 'center',
+ justifyContent: 'center',
+ backgroundColor: 'black',
+ border: '1px solid #333a',
borderRadius: '4px',
- color: '#0070f3',
- cursor: 'pointer',
- padding: '6px 12px',
+ color: 'white',
+ width: '36px',
+ height: '24px',
+ fontSize: '12px',
+ padding: '0px',
textAlign: 'center',
});
@@ -66,7 +74,5 @@ export const backgroundImage = style({
height: '100%',
top: '0',
left: '0',
- opacity: '0.25'
+ opacity: '0.25',
});
-
-
diff --git a/src/component/Card.tsx b/src/component/Card.tsx
new file mode 100644
index 0000000..b299020
--- /dev/null
+++ b/src/component/Card.tsx
@@ -0,0 +1,93 @@
+import type { ReactNode } from 'react';
+import { createContext, useContext } from 'react';
+import {
+ card,
+ date,
+ heading,
+ button,
+ backgroundImage,
+ description,
+ category,
+} from './Card.css';
+
+interface CardContextProps {
+ onClick?: () => void;
+}
+
+const CardContext = createContext({});
+
+function useCardContext(): CardContextProps {
+ const context = useContext(CardContext);
+
+ if (!context.onClick) {
+ throw new Error(
+ 'Child components of Card cannot be rendered outside the Card component!'
+ );
+ }
+
+ return context;
+}
+
+interface ChildrenProps {
+ children: ReactNode;
+}
+
+interface CardProps extends ChildrenProps {
+ onClick?: () => void;
+}
+
+const Card = ({ children, onClick }: CardProps) => {
+ return (
+
+
+ {children}
+
+
+ );
+};
+
+const Date = ({ children }: ChildrenProps) => {
+ return {children} ;
+};
+
+Card.Date = Date;
+
+const Heading = ({ children }: ChildrenProps) => {
+ return {children} ;
+};
+
+Card.Heading = Heading;
+
+const Description = ({ children }: ChildrenProps) => {
+ return {children}
;
+};
+
+Card.Description = Description;
+
+const Category = ({ children }: ChildrenProps) => {
+ return {children}
;
+};
+
+Card.Category = Category;
+
+interface ImageProps {
+ src: string;
+ alt: string;
+ type?: string;
+}
+
+const Image = ({ src, alt, type }: ImageProps) => {
+ useCardContext();
+
+ return (
+
+ );
+};
+
+Card.Image = Image;
+
+export default Card;
diff --git a/src/component/Click.tsx b/src/component/Click.tsx
deleted file mode 100644
index d96d47d..0000000
--- a/src/component/Click.tsx
+++ /dev/null
@@ -1,106 +0,0 @@
-import type { ReactNode } from 'react';
-import { createContext, useContext } from 'react';
-import {
- click,
- date,
- heading,
- button,
- backgroundImage,
- description,
-} from './Click.css';
-
-interface ClickContextProps {
- onClick?: () => void;
-}
-
-const ClickContext = createContext({});
-
-function useClickContext(): ClickContextProps {
- const context = useContext(ClickContext);
-
- if (!context.onClick) {
- throw new Error(
- 'Child components of Click cannot be rendered outside the Click component!'
- );
- }
-
- return context;
-}
-
-interface ChildrenProps {
- children: ReactNode;
-}
-
-interface ClickProps extends ChildrenProps {
- onClick?: () => void;
-}
-
-const Click = ({ children, onClick }: ClickProps) => {
- return (
-
-
- {children}
-
-
- );
-};
-
-interface DateProps extends ChildrenProps {}
-
-const Date = ({ children }: DateProps) => {
- return {children} ;
-};
-
-Click.Date = Date;
-
-interface HeadingProps extends ChildrenProps {}
-
-const Heading = ({ children }: HeadingProps) => {
- return {children} ;
-};
-
-Click.Heading = Heading;
-
-interface DescriptionProps extends ChildrenProps {}
-
-const Description = ({ children }: DescriptionProps) => {
- return {children}
;
-};
-
-Click.Description = Description;
-
-interface ButtonProps extends ChildrenProps {}
-
-const Button = ({ children }: ButtonProps) => {
- const { onClick } = useClickContext();
-
- return (
-
- {children}
-
- );
-};
-
-Click.Button = Button;
-
-interface ImageProps {
- src: string;
- alt: string;
- type?: string;
-}
-
-const Image = ({ src, alt, type }: ImageProps) => {
- useClickContext();
-
- return (
-
- );
-};
-
-Click.Image = Image;
-
-export default Click;
diff --git a/src/pages/Kaleidoscope.css.ts b/src/pages/Kaleidoscope.css.ts
index f5bb1d9..c45ac90 100644
--- a/src/pages/Kaleidoscope.css.ts
+++ b/src/pages/Kaleidoscope.css.ts
@@ -27,3 +27,16 @@ export const boldText = style({
fontSize: '26px',
color: 'black',
});
+
+export const pageContent = style({
+ display: 'flex',
+ flexDirection: 'column',
+ overflow: 'scroll',
+ padding: '16px',
+});
+
+export const cardHeader = style({
+ display: 'flex',
+ width: '100%',
+ justifyContent: 'space-between',
+});
diff --git a/src/pages/Kaleidoscope.tsx b/src/pages/Kaleidoscope.tsx
index 9a86ece..24864eb 100644
--- a/src/pages/Kaleidoscope.tsx
+++ b/src/pages/Kaleidoscope.tsx
@@ -1,10 +1,17 @@
+import Card from '../component/Card';
import Select from '../component/Select';
import {
scrollableContainer,
selectedTagStyle,
tagStyle,
} from '../component/Select.css';
-import { boldText, pageTitle, pageWrapper } from './Kaleidoscope.css';
+import {
+ boldText,
+ cardHeader,
+ pageContent,
+ pageTitle,
+ pageWrapper,
+} from './Kaleidoscope.css';
const options = [
{ value: '전부', label: '전부' },
@@ -33,6 +40,31 @@ const Kaleidoscope = () => {
))}
+
+
+ {[1, 2, 3, 1, 2, 3].map((m) => (
+ {}}>
+
+ 2022.11.23
+ 여행
+
+ 강원도에서의 겨울
+
+ 국경의 긴 터널을 빠져나오자, 설국이었다. 밤의 아랫쪽이 하얘졌다.
+ 신호소에 기차가 멈춰 섰다. 건너편 좌석의 여자가 일어서
+ 다가오더니, 시마무라 앞의 유리창을 열어젖혔다. 눈의 냉기가
+ 흘러들었다. 여자는 한껏 창 밖으로 몸을 내밀어 멀리 외치는 듯이,
+ "역장니임, 역장니임ー" 등불을 들고 천천히 눈을 밟고 온 남자는
+ 목도리를 콧등까지 두르고, 귀에 모자의 모피를 드리우고 있었다.
+
+
+
+ ))}
+
>
);
From 4b9bc6f31cdea99cdad05a2e482777a7c04ccb51 Mon Sep 17 00:00:00 2001
From: afds4567 <33995840+afds4567@users.noreply.github.com>
Date: Wed, 23 Aug 2023 18:32:23 +0900
Subject: [PATCH 08/22] =?UTF-8?q?feat:=20=ED=95=84=EC=9A=94=ED=95=9C=20?=
=?UTF-8?q?=EC=84=A4=EC=A0=95=20=EB=B0=8F=20=EB=B6=88=ED=95=84=EC=9A=94?=
=?UTF-8?q?=ED=95=9C=20=ED=8C=8C=EC=9D=BC=EC=9D=84=20=EC=82=AD=EC=A0=9C?=
=?UTF-8?q?=ED=95=9C=EB=8B=A4?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
index.html | 5 +
mockServer/package.json | 10 +
mockServer/yarn.lock | 424 ++++++++++++++++++++++++++++++++++
package.json | 8 +-
src/App.css | 29 +--
src/App.tsx | 416 ---------------------------------
src/assets/Calender.svg | 8 +
src/assets/Place.svg | 3 +
src/assets/Star.svg | 5 +
src/index.css | 72 ++----
src/pages/Kaleidoscope.css.ts | 42 ----
src/pages/Kaleidoscope.tsx | 73 ------
src/vite-env.d.ts | 1 +
tsconfig.json | 3 +-
tsconfig.node.json | 6 +-
vite.config.ts | 7 +-
yarn.lock | 317 ++++++++++++++++++++++++-
17 files changed, 819 insertions(+), 610 deletions(-)
create mode 100644 mockServer/package.json
create mode 100644 mockServer/yarn.lock
create mode 100644 src/assets/Calender.svg
create mode 100644 src/assets/Place.svg
create mode 100644 src/assets/Star.svg
delete mode 100644 src/pages/Kaleidoscope.css.ts
delete mode 100644 src/pages/Kaleidoscope.tsx
diff --git a/index.html b/index.html
index 96e1ec4..97194af 100644
--- a/index.html
+++ b/index.html
@@ -7,6 +7,11 @@
+
+