Reduce resource drawer identity empty-state copy

This commit is contained in:
rcourtman 2026-03-19 23:04:48 +00:00
parent 89f5821085
commit 2f092ff063
4 changed files with 7 additions and 3 deletions

View file

@ -283,6 +283,9 @@ The identity card now follows the same rule: canonical identity rows stay in
the primary summary, while aliases, IPs, and tags live in a smaller
`Supporting context` block so the drawer answers "what is this resource" before
showing every attached label.
When that card has no owned identity rows or supporting labels yet, the sparse
fallback now stays terse (`No identity metadata yet.`) so empty state chrome
does not read heavier than the data it is standing in for.
Type-specific Docker, PBS, and PMG operational panels now also live inside a
collapsed `Service details` support block, so lane-specific controls and
breakdowns stay available without displacing the common runtime and identity

View file

@ -1120,7 +1120,7 @@ const DrawerContent: Component<ResourceDetailDrawerProps> = (props) => {
</Show>
<Show when={!identityCardHasRichData()}>
<div class="rounded border border-dashed bg-surface-hover px-2 py-1.5 text-[10px] ">
No enriched identity metadata yet.
No identity metadata yet.
</div>
</Show>
</div>

View file

@ -190,6 +190,7 @@ describe('ResourceDetailDrawer change history section', () => {
expect(screen.queryByText('Host details')).toBeNull();
expect(screen.queryByText('Service details')).toBeNull();
expect(screen.queryByText('Supporting context')).toBeNull();
expect(screen.queryByText('No identity metadata yet.')).toBeNull();
expect(screen.getByText('Discovery context')).toBeInTheDocument();
expect(
screen.queryByText('Supporting metadata only. The web interface path above stays primary.'),

View file

@ -250,7 +250,7 @@ describe('ResourceDetailDrawer runtime and identity cards', () => {
expect(getByText('Supporting context')).toBeInTheDocument();
expect(getByText('Aliases')).toBeInTheDocument();
expect(getAllByText('pmg-main').length).toBeGreaterThan(0);
expect(queryByText('No enriched identity metadata yet.')).toBeNull();
expect(queryByText('No identity metadata yet.')).toBeNull();
const sparse = baseResource({
id: 'host-min',
@ -267,7 +267,7 @@ describe('ResourceDetailDrawer runtime and identity cards', () => {
});
const sparseRender = render(() => <ResourceDetailDrawer resource={sparse} />);
expect(sparseRender.getByText('No enriched identity metadata yet.')).toBeInTheDocument();
expect(sparseRender.getByText('No identity metadata yet.')).toBeInTheDocument();
});
it('shows canonical metrics target identity for docker-backed host resources', () => {