Move ServerCard dimmed style to Card theme variant
Replaces inline style and opacity prop on ServerCard with a new 'disabled' variant on the Card theme, per AGENTS.md rules against inline styles on components. Also picks up prettier formatting on ResourcesScreen. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
064b807ea4
commit
4f37321e2c
1 changed files with 18 additions and 14 deletions
|
|
@ -10,7 +10,18 @@ export const ThemeCard = Card.extend({
|
|||
if (props.variant === "responsive") return { root: "card-responsive" };
|
||||
return {};
|
||||
},
|
||||
styles: () => ({
|
||||
root: { backgroundColor: "var(--inspector-surface-card)" },
|
||||
}),
|
||||
styles: (_theme, props) => {
|
||||
if (props.variant === "disabled") {
|
||||
return {
|
||||
root: {
|
||||
backgroundColor: "var(--inspector-surface-card)",
|
||||
opacity: 0.4,
|
||||
pointerEvents: "none",
|
||||
},
|
||||
};
|
||||
}
|
||||
return {
|
||||
root: { backgroundColor: "var(--inspector-surface-card)" },
|
||||
};
|
||||
},
|
||||
});
|
||||
|
|
|
|||
Loading…
Reference in a new issue