-
-
Notifications
You must be signed in to change notification settings - Fork 39
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
Adding Future Gachas/Future Events to a new tab for EN, KR, and TW ease of access #512
base: dev
Are you sure you want to change the base?
Changes from 11 commits
daf9744
716d8f3
b7213e7
d774fb1
688e0b8
1c0893e
4a9fbed
2302bf9
ef08727
8887539
1088be1
f759c63
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -103,6 +103,9 @@ const HomeView = lazy(() => import("./Home")); | |
const MusicList = lazy(() => import("./music/MusicList")); | ||
const GachaList = lazy(() => import("./gacha/GachaList")); | ||
const EventList = lazy(() => import("./event/EventList")); | ||
const FutureGachaList = lazy(() => import("./future/FutureGachaList")); | ||
const FutureEventList = lazy(() => import("./future/FutureEventList")); | ||
const FutureEventDetail = lazy(() => import("./future/FutureEventDetail")); | ||
const GachaDetail = lazy(() => import("./gacha/GachaDetail")); | ||
const CardDetail = lazy(() => import("./card/CardDetail")); | ||
const MusicDetail = lazy(() => import("./music/MusicDetail")); | ||
|
@@ -391,7 +394,9 @@ const DrawerContent: React.FC<{ | |
onFoldButtonClick?: React.MouseEventHandler<HTMLButtonElement>; | ||
}> = ({ open, onFoldButtonClick }) => { | ||
const { t } = useTranslation(); | ||
|
||
const { | ||
settings: { isShowSpoiler }, | ||
} = useRootStore(); | ||
const leftBtns: IListItemLinkProps[][] = React.useMemo( | ||
() => [ | ||
[ | ||
|
@@ -441,6 +446,24 @@ const DrawerContent: React.FC<{ | |
text: t("common:gacha"), | ||
to: "/gacha", | ||
}, | ||
{ | ||
children: [ | ||
{ | ||
disabled: false, | ||
text: t("common:futureevent"), | ||
to: "/futureevent", | ||
}, | ||
{ | ||
disabled: false, | ||
text: t("common:futuregacha"), | ||
to: "/futuregacha", | ||
}, | ||
], | ||
disabled: !isShowSpoiler, | ||
icon: <CalendarText></CalendarText>, | ||
text: t("common:futures"), | ||
to: "/futureevent", | ||
}, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Prefer the future variants in a single menu item with children, I can do it after merge if you want |
||
{ | ||
disabled: false, | ||
icon: <CalendarText></CalendarText>, | ||
|
@@ -1140,6 +1163,15 @@ const AppInner = observer((props: { theme: Theme }) => { | |
<Route path="/gacha/:gachaId"> | ||
<GachaDetail /> | ||
</Route> | ||
<Route path="/futuregacha" exact> | ||
<FutureGachaList /> | ||
</Route> | ||
<Route path="/futureevent" exact> | ||
<FutureEventList /> | ||
</Route> | ||
<Route path="/futureevent/:eventId"> | ||
<FutureEventDetail /> | ||
</Route> | ||
<Route path="/event" exact> | ||
<EventList /> | ||
</Route> | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -336,6 +336,19 @@ const Home: React.FC = () => { | |
</Grid> | ||
</LinkNoDecoration> | ||
</Grid> | ||
<Grid item> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hide if |
||
<LinkNoDecoration | ||
to="/futuregacha" | ||
style={{ color: theme.palette.primary.main }} | ||
> | ||
<Grid container direction="row" alignContent="center"> | ||
<Grid item> | ||
<MoveToInbox fontSize="small"></MoveToInbox> | ||
</Grid> | ||
<Grid item>{t("common:futuregacha")}</Grid> | ||
</Grid> | ||
</LinkNoDecoration> | ||
</Grid> | ||
<Grid item> | ||
<LinkNoDecoration | ||
to="/gacha" | ||
|
@@ -349,6 +362,19 @@ const Home: React.FC = () => { | |
</Grid> | ||
</LinkNoDecoration> | ||
</Grid> | ||
<Grid item> | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Hide if |
||
<LinkNoDecoration | ||
to="/futureevent" | ||
style={{ color: theme.palette.primary.main }} | ||
> | ||
<Grid container direction="row" alignContent="center"> | ||
<Grid item> | ||
<MoveToInbox fontSize="small"></MoveToInbox> | ||
</Grid> | ||
<Grid item>{t("common:futureevent")}</Grid> | ||
</Grid> | ||
</LinkNoDecoration> | ||
</Grid> | ||
<Grid item> | ||
<LinkNoDecoration | ||
to="/event" | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hide if
!isShowSpoiler
?