0
0
Fork 0

設定画面を調整

This commit is contained in:
Xeltica 2022-09-15 16:26:53 +09:00
parent 34395eedd8
commit e3f7399b54
2 changed files with 41 additions and 39 deletions

View file

@ -53,6 +53,7 @@
"settings": "設定", "settings": "設定",
"accentColor": "アクセントカラー", "accentColor": "アクセントカラー",
"changelog": "更新履歴", "changelog": "更新履歴",
"otherSettings": "その他の設定",
"_sidebar": { "_sidebar": {
"dashboard": "ダッシュボード", "dashboard": "ダッシュボード",
"tools": "ツール", "tools": "ツール",

View file

@ -110,13 +110,13 @@ export const SettingPage: React.VFC = () => {
})); }));
}, [dispatch, t]); }, [dispatch, t]);
return session.isLoading || !data ? ( return session.isLoading || !data ? (
<div className="skeleton" style={{width: '100%', height: '128px'}}></div> <div className="skeleton" style={{width: '100%', height: '128px'}}></div>
) : ( ) : (
<article className="fade"> <article className="fade">
<h2><i className="fas fa-palette"></i> {t('appearance')}</h2> <h2><i className="fas fa-palette"></i> {t('appearance')}</h2>
<section> <div className="vstack">
<div className="card pa-2">
<h3>{t('theme')}</h3> <h3>{t('theme')}</h3>
<div className="vstack"> <div className="vstack">
{ {
@ -128,17 +128,17 @@ export const SettingPage: React.VFC = () => {
)) ))
} }
</div> </div>
</section> </div>
<section> <div className="card pa-2">
<h3>{t('accentColor')}</h3> <h3>{t('accentColor')}</h3>
<div className="hstack slim wrap mb-2"> <div className="hstack slim wrap mb-2">
{designSystemColors.map(c => ( {designSystemColors.map(c => (
<ColorInput className="shadow-2" type="radio" color={c} value={c} checked={c === currentAccentColor} onChange={e => dispatch(changeAccentColor(e.target.value))} /> <ColorInput className="shadow-2" type="radio" color={c} value={c} checked={c === currentAccentColor} onChange={e => dispatch(changeAccentColor(e.target.value))} />
))} ))}
</div> </div>
<button className="btn primary">{t('resetToDefault')}</button> <button className="btn primary" onClick={() => dispatch(changeAccentColor('green'))}>{t('resetToDefault')}</button>
</section> </div>
<section> <div className="card pa-2">
<h3>{t('language')}</h3> <h3>{t('language')}</h3>
<select name="currentLang" className="input-field" value={currentLang} onChange={(e) => dispatch(changeLang(e.target.value))}> <select name="currentLang" className="input-field" value={currentLang} onChange={(e) => dispatch(changeLang(e.target.value))}>
{ {
@ -154,9 +154,10 @@ export const SettingPage: React.VFC = () => {
<a href="https://crowdin.com/project/misskey-tools" target="_blank" rel="noopener noreferrer">{t('helpTranslation')}</a> <a href="https://crowdin.com/project/misskey-tools" target="_blank" rel="noopener noreferrer">{t('helpTranslation')}</a>
</div> </div>
</div> </div>
</section> </div>
</div>
<section> <section>
<h2></h2> <h2>{t('otherSettings')}</h2>
<div className="list-form"> <div className="list-form">
<button className="item" onClick={onClickLogout}> <button className="item" onClick={onClickLogout}>
<i className="icon fas fa-arrow-up-right-from-square" /> <i className="icon fas fa-arrow-up-right-from-square" />