Skip to content

Commit

Permalink
[webclient] vivid_ios api 제거 (#193)
Browse files Browse the repository at this point in the history
  • Loading branch information
ars-ki-00 authored Dec 1, 2024
1 parent 77e4c1c commit de0f33f
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 28 deletions.
4 changes: 1 addition & 3 deletions apps/snutt-webclient/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@ import {
implTokenLocalStorageRepository,
implTokenSessionStorageRepository,
} from '@/infrastructures/implBrowserStorageRepository';
import { implColorSnuttApiRepository } from '@/infrastructures/implColorSnuttApiRepository';
import { implFeedbackSnuttApiRepository } from '@/infrastructures/implFeedbackSnuttApiRepository';
import { getNotificationRepository } from '@/infrastructures/implNotificationSnuttApiRepository';
import { implSearchSnuttApiRepository } from '@/infrastructures/implSearchSnuttApiRepository';
Expand Down Expand Up @@ -104,11 +103,10 @@ export const App = () => {
const semesterRepository = implSemesterSnuttApiRepository({ snuttApi });
const searchRepository = implSearchSnuttApiRepository({ snuttApi });
const notificationRepository = getNotificationRepository({ snuttApi });
const colorRepository = implColorSnuttApiRepository({ snuttApi });

const feedbackService = getFeedbackService({ feedbackRepository });
const userService = getUserService({ userRepository });
const colorService = getColorService({ colorRepository });
const colorService = getColorService();
const notificationService = getNotificationService({ notificationRepository });
const searchService = getSearchService({ searchRepository });
const timetableService = getTimetableService({ timetableRepository });
Expand Down

This file was deleted.

23 changes: 15 additions & 8 deletions apps/snutt-webclient/src/usecases/colorService.ts
Original file line number Diff line number Diff line change
@@ -1,16 +1,23 @@
import type { Color } from '@/entities/color';

export interface ColorService {
getColorList(_: { token: string }): Promise<Color[]>;
getColorList(_: { token: string }): Color[];
}

type Deps = {
colorRepository: {
getColorPalette({ token }: { token: string }): Promise<Color[]>;
};
};
export const getColorService = ({ colorRepository }: Deps): ColorService => {
export const getColorService = (): ColorService => {
return {
getColorList: (req: { token: string }) => colorRepository.getColorPalette(req),
getColorList: () => {
return [
{ fg: '#ffffff', bg: '#e54459' },
{ fg: '#ffffff', bg: '#f58d3d' },
{ fg: '#ffffff', bg: '#fac52d' },
{ fg: '#ffffff', bg: '#a6d930' },
{ fg: '#ffffff', bg: '#2bc366' },
{ fg: '#ffffff', bg: '#1bd0c9' },
{ fg: '#ffffff', bg: '#1d99e9' },
{ fg: '#ffffff', bg: '#4f48c4' },
{ fg: '#ffffff', bg: '#af56b3' },
];
},
};
};

0 comments on commit de0f33f

Please sign in to comment.