Merged PR 74: develop動作確認
## 概要 [Task1498: develop動作確認](https://paruru.nds-tyo.co.jp:8443/tfs/ReciproCollection/fa4924a4-d079-4fab-9fb5-a9a11eb205f0/_workitems/edit/1498) - 言語の読み取りと描画のタイミングで言語切り替えが凡例されないことがあるので、各ページで実施するように修正しました。 ## レビューポイント - 共有 - 後ほどしっかりしたロジックを検討します。 ## UIの変更 ## 動作確認状況 - ローカルで確認
This commit is contained in:
parent
a4c93b3023
commit
f75b8545b1
@ -1,4 +1,4 @@
|
|||||||
import React from "react";
|
import React, { useEffect } from "react";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { getTranslationID } from "translation";
|
import { getTranslationID } from "translation";
|
||||||
import Header from "components/header";
|
import Header from "components/header";
|
||||||
@ -7,7 +7,18 @@ import styles from "styles/app.module.scss";
|
|||||||
import emailCheck from "../../assets/images/email_check.svg";
|
import emailCheck from "../../assets/images/email_check.svg";
|
||||||
|
|
||||||
const SignupCompletePage: React.FC = (): JSX.Element => {
|
const SignupCompletePage: React.FC = (): JSX.Element => {
|
||||||
const [t] = useTranslation();
|
const [t, i18n] = useTranslation();
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const language = document.cookie
|
||||||
|
.split(";")
|
||||||
|
.map((x) => x.split("="))
|
||||||
|
.find((x) => x.length === 2 && x[0] === "language");
|
||||||
|
|
||||||
|
if (language) {
|
||||||
|
i18n.changeLanguage(language[1]);
|
||||||
|
}
|
||||||
|
}, [i18n]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles.wrap}>
|
<div className={styles.wrap}>
|
||||||
|
|||||||
@ -1,15 +1,29 @@
|
|||||||
import Footer from "components/footer";
|
import Footer from "components/footer";
|
||||||
import Header from "components/header";
|
import Header from "components/header";
|
||||||
import { selectPageState } from "features/signup/selectors";
|
import { selectPageState } from "features/signup/selectors";
|
||||||
import React from "react";
|
import React, { useEffect } from "react";
|
||||||
import { useSelector } from "react-redux";
|
import { useSelector } from "react-redux";
|
||||||
import { Navigate } from "react-router-dom";
|
import { Navigate } from "react-router-dom";
|
||||||
|
import { useTranslation } from "react-i18next";
|
||||||
import SignupInput from "./signupInput";
|
import SignupInput from "./signupInput";
|
||||||
import SignupConfirm from "./signupConfirm";
|
import SignupConfirm from "./signupConfirm";
|
||||||
|
|
||||||
const SignupPage: React.FC<{ completeTo: string }> = ({
|
const SignupPage: React.FC<{ completeTo: string }> = ({
|
||||||
completeTo,
|
completeTo,
|
||||||
}): JSX.Element => {
|
}): JSX.Element => {
|
||||||
|
const { i18n } = useTranslation();
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const language = document.cookie
|
||||||
|
.split(";")
|
||||||
|
.map((x) => x.split("="))
|
||||||
|
.find((x) => x.length === 2 && x[0] === "language");
|
||||||
|
|
||||||
|
if (language) {
|
||||||
|
i18n.changeLanguage(language[1]);
|
||||||
|
}
|
||||||
|
}, [i18n]);
|
||||||
|
|
||||||
const state = useSelector(selectPageState);
|
const state = useSelector(selectPageState);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|||||||
@ -3,10 +3,22 @@ import Header from "components/header";
|
|||||||
import styles from "styles/app.module.scss";
|
import styles from "styles/app.module.scss";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { getTranslationID } from "translation";
|
import { getTranslationID } from "translation";
|
||||||
|
import { useEffect } from "react";
|
||||||
import check_circle from "../../assets/images/check_circle.svg";
|
import check_circle from "../../assets/images/check_circle.svg";
|
||||||
|
|
||||||
const VerifyPage: React.FC = (): JSX.Element => {
|
const VerifyPage: React.FC = (): JSX.Element => {
|
||||||
const [t] = useTranslation();
|
const [t, i18n] = useTranslation();
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const language = document.cookie
|
||||||
|
.split(";")
|
||||||
|
.map((x) => x.split("="))
|
||||||
|
.find((x) => x.length === 2 && x[0] === "language");
|
||||||
|
|
||||||
|
if (language) {
|
||||||
|
i18n.changeLanguage(language[1]);
|
||||||
|
}
|
||||||
|
}, [i18n]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles.wrap}>
|
<div className={styles.wrap}>
|
||||||
|
|||||||
@ -7,11 +7,18 @@ import { getTranslationID } from "translation";
|
|||||||
import report from "../../assets/images/report.svg";
|
import report from "../../assets/images/report.svg";
|
||||||
|
|
||||||
const VerifyFailedPage: React.FC = (): JSX.Element => {
|
const VerifyFailedPage: React.FC = (): JSX.Element => {
|
||||||
const [t] = useTranslation();
|
const [t, i18n] = useTranslation();
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
// 初期表示時の処理を記述
|
const language = document.cookie
|
||||||
}, []);
|
.split(";")
|
||||||
|
.map((x) => x.split("="))
|
||||||
|
.find((x) => x.length === 2 && x[0] === "language");
|
||||||
|
|
||||||
|
if (language) {
|
||||||
|
i18n.changeLanguage(language[1]);
|
||||||
|
}
|
||||||
|
}, [i18n]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles.wrap}>
|
<div className={styles.wrap}>
|
||||||
|
|||||||
@ -3,10 +3,22 @@ import Header from "components/header";
|
|||||||
import styles from "styles/app.module.scss";
|
import styles from "styles/app.module.scss";
|
||||||
import { useTranslation } from "react-i18next";
|
import { useTranslation } from "react-i18next";
|
||||||
import { getTranslationID } from "translation";
|
import { getTranslationID } from "translation";
|
||||||
|
import { useEffect } from "react";
|
||||||
import check_circle from "../../assets/images/check_circle.svg";
|
import check_circle from "../../assets/images/check_circle.svg";
|
||||||
|
|
||||||
const VerifySuccessPage: React.FC = (): JSX.Element => {
|
const VerifySuccessPage: React.FC = (): JSX.Element => {
|
||||||
const [t] = useTranslation();
|
const [t, i18n] = useTranslation();
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const language = document.cookie
|
||||||
|
.split(";")
|
||||||
|
.map((x) => x.split("="))
|
||||||
|
.find((x) => x.length === 2 && x[0] === "language");
|
||||||
|
|
||||||
|
if (language) {
|
||||||
|
i18n.changeLanguage(language[1]);
|
||||||
|
}
|
||||||
|
}, [i18n]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className={styles.wrap}>
|
<div className={styles.wrap}>
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user