Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(mobile): the composer, model sheet and subagent bar show which account a thread uses #15922

Closedvitalyiegorov(GitHub profile, opens in a new tab)wants to merge 8 commits intomain fromrefs/pull/15922/headopened View on GitHub

Showing 10 changed files with 51 additions and 38 deletions (loading 7).

x
0 of 10 viewed, 10 left
30 additions and 30 deletionsapps/mobile/src/components/ProviderIcon.tsxModified
View file
@@ -151,51 +151,51 @@
readonly iconUrl?: string | null;
readonly provider: string | null | undefined;
readonly size?: number;
- readonly displayName: string;
+ readonly displayName?: string;
readonly accentColor?: string;
readonly showBadge?: boolean;
readonly surfaceColor: string;
}) {
+ if (!props.showBadge) {
+ return <ProviderIcon iconUrl={props.iconUrl} provider={props.provider} size={props.size} />;
+ }
return (
<View style={{ position: "relative" }}>
<View style={{ opacity: 0.6 }}>
<ProviderIcon iconUrl={props.iconUrl} provider={props.provider} size={props.size} />
</View>
- {props.showBadge ? (
- // A wide right-aligned box lets the badge fit its initials. Alone, an
- // absolute badge is capped at the icon's width, which clips "WO".
+ {/* A wide box lets initials extend beyond the glyph without clipping. */}
+ <View
+ pointerEvents="none"
+ style={{ position: "absolute", right: -3, bottom: -3, width: 32, alignItems: "flex-end" }}
+ >
<View
- pointerEvents="none"
- style={{ position: "absolute", right: -3, bottom: -3, width: 32, alignItems: "flex-end" }}
+ className={props.accentColor ? undefined : "bg-card"}