Skip to content

Commit

Permalink
fix: useModalStore관련 오류 임시 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
(hoooooony) committed Jan 8, 2024
1 parent 114d8ac commit 22aa902
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/LINT_CHECK.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,4 @@ jobs:
- name: Check lint
run: yarn lint
- name: Type Check
run: yarn tsc
run: yarn typecheck
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"lint": "yarn lint:eslint && yarn lint:stylelint",
"lint:eslint": "eslint src/ --ext .tsx,.ts",
"lint:stylelint": "stylelint \"src/**/*.scss\" --config .stylelint.json",
"typecheck": "tsc"
"typecheck": "tsc --project tsconfig.json"
},
"eslintConfig": {
"extends": [
Expand Down
8 changes: 8 additions & 0 deletions src/store/modalStore.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,13 @@ interface ModalStore {
openTimeState: OperatingTime;
closeTimeState: OperatingTime;
shopClosedState: { [key: string]: boolean };
searchShopState: string; // 수정 요망
selectedShopId:string; // 수정 요망
setOpenTimeState: (state: OperatingTime) => void;
setCloseTimeState: (state: OperatingTime) => void;
setShopClosedState: (state: { [key: string]: boolean }) => void;
setSearchShopState: (state: string) => void; // 수정 요망
setSelectedShopId:(state:string) => void; // 수정 요망
}

const initialOperatingTime: OperatingTime = {
Expand All @@ -36,9 +40,13 @@ const useModalStore = create<ModalStore>((set) => ({
openTimeState: initialOperatingTime,
closeTimeState: initialOperatingTime,
shopClosedState: initialShopClosed,
searchShopState: '', // 수정 요망
selectedShopId: '', // 수정 요망
setOpenTimeState: (state) => set(() => ({ openTimeState: state })),
setCloseTimeState: (state) => set(() => ({ closeTimeState: state })),
setShopClosedState: (state) => set({ shopClosedState: state }),
setSearchShopState: (state) => set({ searchShopState: state }), // 수정 요망
setSelectedShopId: (state) => set({ selectedShopId: state }), // 수정 요망
}));

export default useModalStore;

0 comments on commit 22aa902

Please sign in to comment.