${entries.map(([k, v], index) => {
const isLast = index === entries.length - 1;
return when(
isObject(v),
() => html`
{
if (e) this._collapseSet.add(e as JsonCollapse);
})}
>
${this.renderPropertyKey(k, isArray)}
${when(
Array.isArray(v),
() => html`Array(${v.length})`,
() => html`Object{…}`,
)}${when(!isLast, () => html`,`)}
${this.renderPropertyKey(k, isArray)}
{
if (e) this._subViewer.add(e as JsonViewer);
})}
>
`,
() => {
const content = html`
${this.renderPropertyKey(k, isArray)}
${when(
!isLast,
() => html`,`,
)}
`;
return html`
${content}
${content}
`;
},
);
})}