Skip to content

Commit

Permalink
fix(live2d): event soung loading not properly & sound not clear
Browse files Browse the repository at this point in the history
  • Loading branch information
K-bai committed Dec 9, 2024
1 parent e08f0f6 commit d3506df
Show file tree
Hide file tree
Showing 13 changed files with 949 additions and 552 deletions.
4 changes: 2 additions & 2 deletions src/pages/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -567,7 +567,7 @@ const DrawerContent: React.FC<{
{
disabled: false,
text: "Live2D",
to: "/storyreader_live2d",
to: "/storyreader-live2d",
},
],
disabled: false,
Expand Down Expand Up @@ -1179,7 +1179,7 @@ const AppInner = observer((props: { theme: Theme }) => {
<Route path="/storyreader">
<StoryReader />
</Route>
<Route path="/storyreader_live2d">
<Route path="/storyreader-live2d">
<StoryReaderLive2D />
</Route>
<Route path="/mission/title">
Expand Down
33 changes: 20 additions & 13 deletions src/pages/storyreader-live2d/StoryReaderLive2D.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ import {
CardContent,
Avatar,
styled,
Alert,
} from "@mui/material";
import React, { Fragment, useMemo } from "react";
import { useTranslation } from "react-i18next";
Expand Down Expand Up @@ -69,7 +70,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {

const breadcrumbNameMap: { [key: string]: string } = useMemo(
() => ({
storyreader_live2d: t("common:storyReader"),
"storyreader-live2d": t("common:storyReader"),
eventStory: t("story_reader:selectValue.eventStory"),
unitStory: t("story_reader:selectValue.unitStory"),
charaStory: t("story_reader:selectValue.charaStory"),
Expand All @@ -84,6 +85,12 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
return (
<Fragment>
<TypographyHeader>{t("common:storyReader")}</TypographyHeader>
<Alert
severity="warning"
sx={(theme) => ({ margin: theme.spacing(1, 0) })}
>
{t("common:betaIndicator")}
</Alert>
<Route>
{({ location }) => {
const pathnames = location.pathname.split("/").filter((x) => x);
Expand Down Expand Up @@ -275,7 +282,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
<Route path={`${path}`} exact>
<Grid container spacing={1}>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/eventStory">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/eventStory">
<CardSelect>
<CardContent>
<Typography>
Expand All @@ -286,7 +293,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
</LinkNoDecorationAlsoNoHover>
</Grid>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/unitStory">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/unitStory">
<CardSelect>
<CardContent>
<Typography>
Expand All @@ -297,7 +304,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
</LinkNoDecorationAlsoNoHover>
</Grid>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/charaStory">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/charaStory">
<CardSelect>
<CardContent>
<Typography>
Expand All @@ -308,7 +315,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
</LinkNoDecorationAlsoNoHover>
</Grid>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/cardStory">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/cardStory">
<CardSelect>
<CardContent>
<Typography>
Expand All @@ -319,7 +326,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
</LinkNoDecorationAlsoNoHover>
</Grid>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/areaTalk">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/areaTalk">
<CardSelect>
<CardContent>
<Typography>
Expand All @@ -330,7 +337,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
</LinkNoDecorationAlsoNoHover>
</Grid>
<Grid item xs={12} sm={6} md={3}>
<LinkNoDecorationAlsoNoHover to="/storyreader_live2d/specialStory">
<LinkNoDecorationAlsoNoHover to="/storyreader-live2d/specialStory">
<CardSelect>
<CardContent>
<Typography>
Expand Down Expand Up @@ -363,7 +370,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
.map((ev) => (
<Grid item xs={12} sm={6} md={3} key={ev.id}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/eventStory/${ev.id}`}
to={`/storyreader-live2d/eventStory/${ev.id}`}
>
<CardSelect>
<CardContent>
Expand Down Expand Up @@ -458,7 +465,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
unitProfiles.map((unit) => (
<Grid item xs={12} sm={6} md={3} key={unit.unit}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/unitStory/${unit.unit}`}
to={`/storyreader-live2d/unitStory/${unit.unit}`}
>
<CardSelect>
<CardContent>
Expand Down Expand Up @@ -587,7 +594,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
characterProfiles.map((character) => (
<Grid item xs={12} sm={6} md={3} key={character.characterId}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/charaStory/${character.characterId}`}
to={`/storyreader-live2d/charaStory/${character.characterId}`}
>
<CardSelect>
<CardContent>
Expand Down Expand Up @@ -632,7 +639,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
characterProfiles.map((character) => (
<Grid item xs={12} sm={6} md={3} key={character.characterId}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/cardStory/${character.characterId}`}
to={`/storyreader-live2d/cardStory/${character.characterId}`}
>
<CardSelect>
<CardContent>
Expand Down Expand Up @@ -777,7 +784,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
.map((area) => (
<Grid item xs={12} sm={6} md={3} key={area.id}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/areaTalk/${area.id}`}
to={`/storyreader-live2d/areaTalk/${area.id}`}
>
<CardSelect>
<CardContent>
Expand Down Expand Up @@ -941,7 +948,7 @@ const StoryReaderLive2D: React.FC<unknown> = observer(() => {
.map((sp) => (
<Grid item xs={12} sm={6} md={3} key={sp.id}>
<LinkNoDecorationAlsoNoHover
to={`/storyreader_live2d/specialStory/${sp.id}`}
to={`/storyreader-live2d/specialStory/${sp.id}`}
>
<CardSelect>
<CardContent>
Expand Down
Loading

0 comments on commit d3506df

Please sign in to comment.