-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'migration@reducers/common' into migration
- Loading branch information
Showing
9 changed files
with
79 additions
and
70 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { MediaAction, SET_IS_PORTRAIT } from '../../actions/common/media'; | ||
|
||
interface MediaState { | ||
isPortrait: boolean; | ||
} | ||
|
||
const initialState: MediaState = { | ||
isPortrait: false, | ||
}; | ||
|
||
const media = (state = initialState, action: MediaAction): MediaState => { | ||
switch (action.type) { | ||
case SET_IS_PORTRAIT: | ||
return { ...state, isPortrait: action.isPortrait }; | ||
default: | ||
return state; | ||
} | ||
}; | ||
|
||
export default media; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
import { SET_SEMESTERS, SemesterAction } from '../../actions/common/semester'; | ||
import Semester from '@/shapes/model/subject/Semester'; | ||
|
||
interface SemesterState { | ||
semesters: Semester[] | null; | ||
} | ||
|
||
const initialState: SemesterState = { | ||
semesters: null, | ||
}; | ||
|
||
const semester = (state = initialState, action: SemesterAction): SemesterState => { | ||
switch (action.type) { | ||
case SET_SEMESTERS: | ||
return { ...state, semesters: action.semesters }; | ||
default: | ||
return state; | ||
} | ||
}; | ||
|
||
export default semester; |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
import { SET_TRACKS, TrackAction, Tracks } from '../../actions/common/track'; | ||
|
||
interface TrackState { | ||
tracks: Tracks | null; | ||
} | ||
|
||
const initialState: TrackState = { | ||
tracks: null, | ||
}; | ||
|
||
const track = (state = initialState, action: TrackAction): TrackState => { | ||
switch (action.type) { | ||
case SET_TRACKS: | ||
return { ...state, tracks: action.tracks }; | ||
default: | ||
return state; | ||
} | ||
}; | ||
|
||
export default track; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters