diff --git a/client_v2/src/lib/components/ExtraFieldsSection.svelte b/client_v2/src/lib/components/ExtraFieldsSection.svelte index 2a4b9c11..e5c1c848 100644 --- a/client_v2/src/lib/components/ExtraFieldsSection.svelte +++ b/client_v2/src/lib/components/ExtraFieldsSection.svelte @@ -22,8 +22,16 @@ * another entity, where an empty section is just noise. */ manage?: boolean; + /** + * Emit only the field rows — no section header, no grid of its own — so the + * caller can drop them straight into its own . Used by the + * read-only mirrors of another entity, where a second "Extra fields" heading + * in the same panel reads as a peer section rather than as more of the + * entity above it (#992). + */ + headless?: boolean; } - let { entity, extra, onchange, readonly = false, manage = false }: Props = $props(); + let { entity, extra, onchange, readonly = false, manage = false, headless = false }: Props = $props(); $effect(() => { fields.ensure(entity); @@ -43,20 +51,21 @@ > {/snippet} -{#if show} +{#snippet rows()} + {#each defs as f (f.key)} + + onchange(f.key, json)} {readonly} /> + + {/each} +{/snippet} + +{#if headless} + {@render rows()} +{:else if show} {m['settings.extraFields.tab']()} {#if defs.length} - {#each defs as f (f.key)} - - onchange(f.key, json)} - {readonly} - /> - - {/each} + {@render rows()} {:else}
{m['inspector.noExtraFields']()}
diff --git a/client_v2/src/lib/components/library/SpoolInspector.svelte b/client_v2/src/lib/components/library/SpoolInspector.svelte index 9ed430e1..c066fcab 100644 --- a/client_v2/src/lib/components/library/SpoolInspector.svelte +++ b/client_v2/src/lib/components/library/SpoolInspector.svelte @@ -376,10 +376,12 @@ {/if} {filament.registeredLabel} + + {}} readonly headless />
- {}} readonly /> - {vendor.registeredLabel} + + {}} readonly headless /> - - {}} readonly /> {:else}
{m['add.noManufacturer']()}
{/if}