chore(app): added the Creator badge

This commit is contained in:
2026-05-02 15:40:05 +02:00
parent 6765c075a5
commit d8d8a00fd9
15 changed files with 142 additions and 27 deletions
@@ -5,7 +5,10 @@
<ProfilePlayerAvatar :playerTD2Info="playerTD2Info" />
<div>
<h2 class="player-name-header" :class="{ 'text--donator': isPlayerDonator }">
<h2
class="player-name-header"
:class="{ 'text--donator': isPlayerDonator, 'text--creator': isPlayerCreator }"
>
<a :href="`https://td2.info.pl/profile/?u=${route.query.playerId}`" target="_blank">
<img
v-if="isPlayerDonator"
@@ -232,6 +235,7 @@ import { useApiStore } from '../../store/apiStore';
import StationStatusBadge from '../Global/StationStatusBadge.vue';
import ProfilePlayerAvatar from './ProfilePlayerAvatar.vue';
import { getRegionNameById } from '../../utils/regionUtils';
import { isCreator } from '../../utils/userUtils';
const { t } = useI18n();
@@ -257,6 +261,8 @@ const isPlayerDonator = computed(() =>
props.playerName ? apiStore.donatorsData.includes(props.playerName) : false
);
const isPlayerCreator = computed(() => (props.playerName ? isCreator(props.playerName) : false));
const activeDispatches = computed(() => {
if (!props.playerName) return [];
if (!apiStore.activeData || !apiStore.activeData.activeSceneries) return [];