Remove pronouns from GroupCards

This commit is contained in:
Kalle 2026-08-06 15:31:17 +03:00
parent 00a95bba6a
commit fb22fb698a
7 changed files with 0 additions and 30 deletions

View File

@ -157,7 +157,6 @@ function groupWithTeamAndMembers(
"GroupMember.role",
"GroupMember.note",
"User.inGameName",
"User.pronouns",
"User.vc",
"User.languages",
"User.noScreen",

View File

@ -75,7 +75,6 @@ export async function findCurrentGroups() {
"Group.status",
"GroupMatch.id as matchId",
commonUserMembersAgg(eb, {
pronouns: eb.ref("User.pronouns"),
mapModePreferences: eb.ref("User.mapModePreferences"),
noScreen: eb.ref("User.noScreen"),
role: eb.ref("GroupMember.role"),

View File

@ -32,7 +32,6 @@ function createMember(overrides: Partial<SQGroupMember> = {}): SQGroupMember {
friendCode: null,
inGameName: null,
note: null,
pronouns: null,
skillDifference: undefined,
noScreen: undefined,
@ -84,7 +83,6 @@ function createOwnGroupMember(
friendCode: null,
inGameName: null,
note: null,
pronouns: null,
skillDifference: undefined,
noScreen: undefined,

View File

@ -291,11 +291,6 @@ function GroupMember({
</span>
</span>
</UserCard>
{member.pronouns ? (
<span className="text-lighter ml-1 text-xxs">
{member.pronouns.subject}/{member.pronouns.object}
</span>
) : null}
</div>
<div
className={clsx(

View File

@ -387,7 +387,6 @@ function lfgMembersAgg(
return commonUserMembersAgg(eb, {
languages: eb.ref("User.languages"),
vc: eb.ref("User.vc"),
pronouns: eb.ref("User.pronouns"),
role: eb.ref("TournamentTeamMember.role"),
isStayAsSub: eb.ref("TournamentTeamMember.isStayAsSub"),
weapons: matchProfileWeapons(eb),

View File

@ -11,7 +11,6 @@ import { SendouPopover } from "~/components/elements/Popover";
import { FormWithConfirm } from "~/components/FormWithConfirm";
import { Image, WeaponImage } from "~/components/Image";
import { NoteAvatar } from "~/components/NoteAvatar";
import type { Pronouns } from "~/db/tables-json";
import { useUser } from "~/features/auth/core/user";
import { IS_Q_LOOKING_MOBILE_BREAKPOINT } from "~/features/sendouq/q-constants";
import { useTournament } from "~/features/tournament/routes/to.$id";
@ -40,7 +39,6 @@ export type LFGGroupMember = {
customUrl: string | null;
languages: UnifiedLanguageCode[];
vc: "YES" | "NO" | "LISTEN_ONLY" | null;
pronouns: Pronouns | null;
role: "OWNER" | "MANAGER" | "REGULAR";
isStayAsSub: boolean;
weapons: Array<{
@ -218,11 +216,6 @@ function LFGGroupMemberRow({
<span className={styles.name}>{member.username}</span>
</span>
</UserCard>
{member.pronouns ? (
<span className="text-lighter ml-1 text-xxs">
{member.pronouns.subject}/{member.pronouns.object}
</span>
) : null}
</div>
<div className="ml-auto stack horizontal sm items-center">
{showActions || (!showActions && member.role === "OWNER") ? (

View File

@ -1,6 +1,5 @@
import type { LoaderFunctionArgs } from "react-router";
import * as R from "remeda";
import type { Pronouns } from "~/db/tables-json";
import type { getUser } from "~/features/auth/core/user.server";
import {
tournamentFromDBCached,
@ -183,7 +182,6 @@ async function resolveOwnTeam({
customUrl: m.customUrl,
languages: [],
vc: null,
pronouns: null,
role: m.role,
isStayAsSub: false,
weapons: null,
@ -210,7 +208,6 @@ function transformMembers(
const languages = m.languages ?? [];
const weapons = parseWeapons(m.weapons);
const pronouns = parsePronouns(m.pronouns);
return {
id: m.id,
@ -221,7 +218,6 @@ function transformMembers(
customUrl: m.customUrl,
languages,
vc: m.vc,
pronouns,
role: m.role,
isStayAsSub: m.isStayAsSub === 1,
weapons,
@ -252,12 +248,3 @@ function parseWeapons(raw: unknown): Array<{
}),
);
}
function parsePronouns(raw: unknown): Pronouns | null {
if (!raw) return null;
const parsed = typeof raw === "string" ? JSON.parse(raw) : raw;
if (!parsed || typeof parsed !== "object") return null;
return parsed as Pronouns;
}