Add tooltip over remix icon
This commit is contained in:
parent
2172647282
commit
ea8fd7a423
1 changed files with 10 additions and 9 deletions
|
|
@ -11,18 +11,19 @@ import classNames from 'classnames'
|
||||||
import reactStringReplace from 'react-string-replace'
|
import reactStringReplace from 'react-string-replace'
|
||||||
|
|
||||||
import Alert from '~components/Alert'
|
import Alert from '~components/Alert'
|
||||||
|
|
||||||
import Button from '~components/Button'
|
import Button from '~components/Button'
|
||||||
import CharLimitedFieldset from '~components/CharLimitedFieldset'
|
import CharLimitedFieldset from '~components/CharLimitedFieldset'
|
||||||
import Input from '~components/Input'
|
|
||||||
import DurationInput from '~components/DurationInput'
|
import DurationInput from '~components/DurationInput'
|
||||||
import Token from '~components/Token'
|
|
||||||
import GridRepCollection from '~components/GridRepCollection'
|
import GridRepCollection from '~components/GridRepCollection'
|
||||||
import GridRep from '~components/GridRep'
|
import GridRep from '~components/GridRep'
|
||||||
|
import Input from '~components/Input'
|
||||||
import RaidDropdown from '~components/RaidDropdown'
|
import RaidDropdown from '~components/RaidDropdown'
|
||||||
import TextFieldset from '~components/TextFieldset'
|
|
||||||
import Switch from '~components/Switch'
|
import Switch from '~components/Switch'
|
||||||
|
import Tooltip from '~components/Tooltip'
|
||||||
|
import TextFieldset from '~components/TextFieldset'
|
||||||
|
import Token from '~components/Token'
|
||||||
|
|
||||||
|
import api from '~utils/api'
|
||||||
import { accountState } from '~utils/accountState'
|
import { accountState } from '~utils/accountState'
|
||||||
import { appState } from '~utils/appState'
|
import { appState } from '~utils/appState'
|
||||||
import { formatTimeAgo } from '~utils/timeAgo'
|
import { formatTimeAgo } from '~utils/timeAgo'
|
||||||
|
|
@ -36,7 +37,6 @@ import RemixIcon from '~public/icons/Remix.svg'
|
||||||
import type { DetailsObject } from 'types'
|
import type { DetailsObject } from 'types'
|
||||||
|
|
||||||
import './index.scss'
|
import './index.scss'
|
||||||
import api from '~utils/api'
|
|
||||||
|
|
||||||
// Props
|
// Props
|
||||||
interface Props {
|
interface Props {
|
||||||
|
|
@ -308,8 +308,8 @@ const PartyDetails = (props: Props) => {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Methods: Navigation
|
// Methods: Navigation
|
||||||
function goTo(shortcode: string) {
|
function goTo(shortcode?: string) {
|
||||||
router.push(`/p/${shortcode}`)
|
if (shortcode) router.push(`/p/${shortcode}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Methods: Favorites
|
// Methods: Favorites
|
||||||
|
|
@ -710,12 +710,13 @@ const PartyDetails = (props: Props) => {
|
||||||
{name ? name : t('no_title')}
|
{name ? name : t('no_title')}
|
||||||
</h1>
|
</h1>
|
||||||
{party.remix && party.sourceParty ? (
|
{party.remix && party.sourceParty ? (
|
||||||
<Link href={`/p/${party.sourceParty.shortcode}`} passHref>
|
<Tooltip content="Go to original team">
|
||||||
<Button
|
<Button
|
||||||
className="IconButton Blended"
|
className="IconButton Blended"
|
||||||
leftAccessoryIcon={<RemixIcon />}
|
leftAccessoryIcon={<RemixIcon />}
|
||||||
|
onClick={() => goTo(party.sourceParty?.shortcode)}
|
||||||
/>
|
/>
|
||||||
</Link>
|
</Tooltip>
|
||||||
) : (
|
) : (
|
||||||
''
|
''
|
||||||
)}
|
)}
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue