Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: pin and rename feature #35

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
"react-slick": "^0.29.0",
"redux": "^4.0.0",
"slick-carousel": "^1.8.1",
"yarn": "^1.22.21",
"zabo-embed": "^0.0.7"
},
"devDependencies": {
Expand Down
17 changes: 17 additions & 0 deletions src/actions/timetable/timetable.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ export const DUPLICATE_TIMETABLE = BASE_STRING + 'DUPLICATE_TIMETABLE';
export const ADD_LECTURE_TO_TIMETABLE = BASE_STRING + 'ADD_LECTURE_TO_TIMETABLE';
export const REMOVE_LECTURE_FROM_TIMETABLE = BASE_STRING + 'REMOVE_LECTURE_FROM_TIMETABLE';
export const REORDER_TIMETABLE = BASE_STRING + 'REORDER_TIMETABLE';
export const PIN_TIMETABLE = BASE_STRING + 'PIN_TIMETABLE';
export const RENAME_TIMETABLE = BASE_STRING + 'RENAME_TIMETABLE';
export const UPDATE_CELL_SIZE = BASE_STRING + 'UPDATE_CELL_SIZE';
export const SET_IS_DRAGGING = BASE_STRING + 'SET_IS_DRAGGING';
export const SET_MOBILE_IS_TIMETABLE_TABS_OPEN = BASE_STRING + 'SET_MOBILE_IS_TIMETABLE_TABS_OPEN';
Expand Down Expand Up @@ -94,6 +96,21 @@ export function reorderTimetable(timetable, arrangeOrder) {
};
}

export function pinTimetable(timetable) {
return {
type: PIN_TIMETABLE,
timetable: timetable,
};
}

export function renameTimetable(timetable, name) {
return {
type: RENAME_TIMETABLE,
timetable: timetable,
name: name,
};
}

export function updateCellSize(width, height) {
return {
type: UPDATE_CELL_SIZE,
Expand Down
10 changes: 10 additions & 0 deletions src/common/components/dropdown/DropdownMenu.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
const dropdownMenu = [
{ key: 'pin', text: '기본으로 설정하기' },
{ key: 'rename', text: '시간표 이름 변경하기' },
{ key: 'share image', text: '이미지로 내보내기' },
{ key: 'share calendar', text: '캘린더로 내보내기' },
{ key: 'duplicate', text: '시간표 복제하기' },
{ key: 'delete', text: '시간표 삭제하기' },
];

export default dropdownMenu;
Loading
Loading