あ
This commit is contained in:
parent
9c20f5d8d5
commit
0f8016fcde
2 changed files with 3 additions and 1 deletions
|
@ -3,6 +3,7 @@ import React from 'react';
|
||||||
export type TabItem = {
|
export type TabItem = {
|
||||||
label: string;
|
label: string;
|
||||||
key: string;
|
key: string;
|
||||||
|
isNew?: boolean;
|
||||||
};
|
};
|
||||||
|
|
||||||
export type TabProps = {
|
export type TabProps = {
|
||||||
|
@ -23,6 +24,7 @@ export const Tab: React.VFC<TabProps> = (props) => {
|
||||||
onClick={() => props.onSelect(item.key)}
|
onClick={() => props.onSelect(item.key)}
|
||||||
>
|
>
|
||||||
{item.label}
|
{item.label}
|
||||||
|
{item.isNew && <sup className="text-primary text-bold" style={{marginLeft: 2}}>NEW!</sup>}
|
||||||
</button>
|
</button>
|
||||||
);
|
);
|
||||||
})}
|
})}
|
||||||
|
|
|
@ -30,7 +30,7 @@ export const IndexSessionPage: React.VFC = () => {
|
||||||
const it: TabItem[] = [];
|
const it: TabItem[] = [];
|
||||||
it.push({ label: t('_nav.misshai'), key: 'misshai' });
|
it.push({ label: t('_nav.misshai'), key: 'misshai' });
|
||||||
it.push({ label: t('_nav.accounts'), key: 'accounts' });
|
it.push({ label: t('_nav.accounts'), key: 'accounts' });
|
||||||
it.push({ label: t('_nav.catAdjuster'), key: 'nekomimi' });
|
it.push({ label: t('_nav.catAdjuster'), key: 'nekomimi', isNew: true });
|
||||||
if (data?.isAdmin) {
|
if (data?.isAdmin) {
|
||||||
it.push({ label: 'Admin', key: 'admin' });
|
it.push({ label: 'Admin', key: 'admin' });
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue