Skip to content

Commit 04e598b

Browse files
committed
update column
1 parent 7baacb9 commit 04e598b

File tree

2 files changed

+33
-23
lines changed

2 files changed

+33
-23
lines changed

frontend/src/pages/org/collection-detail.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -626,10 +626,8 @@ export class CollectionDetail extends BtrixElement {
626626
(col) => html`
627627
${this.localize.bytes(col.totalSize)}
628628
${col.hasDedupeIndex
629-
? html`<sl-tooltip content=${msg("Deduplicated")}>
630-
<btrix-badge variant="success" pill
631-
>${msg("Deduped")}</btrix-badge
632-
>
629+
? html`<sl-tooltip content=${msg("Deduplicated")} hoist>
630+
<btrix-badge variant="primary">${msg("Deduped")}</btrix-badge>
633631
</sl-tooltip>`
634632
: nothing}
635633
`,

frontend/src/pages/org/collections-list.ts

Lines changed: 31 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import { emptyMessage } from "@/layouts/emptyMessage";
2525
import { pageHeader } from "@/layouts/pageHeader";
2626
import { RouteNamespace } from "@/routes";
2727
import { metadata } from "@/strings/collections/metadata";
28+
import { noData } from "@/strings/ui";
2829
import { monthYearDateRange } from "@/strings/utils";
2930
import type { APIPaginatedList, APIPaginationQuery } from "@/types/api";
3031
import { CollectionAccess, type Collection } from "@/types/collection";
@@ -484,7 +485,7 @@ export class CollectionsList extends WithSearchOrgContext(BtrixElement) {
484485
return html`
485486
<btrix-table
486487
class="[--btrix-table-column-gap:var(--sl-spacing-small)]"
487-
style="--btrix-table-grid-template-columns: min-content [clickable-start] minmax(min-content, 60ch) repeat(4, 1fr) [clickable-end] min-content"
488+
style="--btrix-table-grid-template-columns: min-content [clickable-start] minmax(min-content, 60ch) repeat(5, 1fr) [clickable-end] min-content"
488489
>
489490
<btrix-table-head class="mb-2 mt-1 whitespace-nowrap">
490491
<btrix-table-header-cell>
@@ -496,10 +497,15 @@ export class CollectionsList extends WithSearchOrgContext(BtrixElement) {
496497
<btrix-table-header-cell>
497498
${msg("Archived Items")}
498499
</btrix-table-header-cell>
499-
<btrix-table-header-cell
500-
>${msg("Total Pages")}</btrix-table-header-cell
501-
>
502-
<btrix-table-header-cell>${msg("Size")}</btrix-table-header-cell>
500+
<btrix-table-header-cell>
501+
${msg("Total Pages")}
502+
</btrix-table-header-cell>
503+
<btrix-table-header-cell>
504+
${msg("Total Size")}
505+
</btrix-table-header-cell>
506+
<btrix-table-header-cell>
507+
${msg("Deduplication")}
508+
</btrix-table-header-cell>
503509
<btrix-table-header-cell>
504510
${msg("Last Modified")}
505511
</btrix-table-header-cell>
@@ -610,7 +616,7 @@ export class CollectionsList extends WithSearchOrgContext(BtrixElement) {
610616
</btrix-table-cell>
611617
<btrix-table-cell rowClickTarget="a">
612618
<a
613-
class="block truncate py-2"
619+
class="block truncate py-2.5"
614620
href=${`${this.navigate.orgBasePath}/collections/view/${col.id}`}
615621
@click=${this.navigate.link}
616622
>
@@ -625,26 +631,32 @@ export class CollectionsList extends WithSearchOrgContext(BtrixElement) {
625631
${pluralOf("items", col.crawlCount)}
626632
</btrix-table-cell>
627633
<btrix-table-cell>
628-
${this.localize.number(col.pageCount, { notation: "compact" })}
629-
${pluralOf("pages", col.pageCount)}
634+
${col.crawlCount
635+
? html`${this.localize.number(col.pageCount, { notation: "compact" })}
636+
${pluralOf("pages", col.pageCount)}`
637+
: noData}
630638
</btrix-table-cell>
631-
<btrix-table-cell class="gap-2">
632-
${this.localize.bytes(col.totalSize || 0)}
639+
<btrix-table-cell>
640+
${col.crawlCount ? this.localize.bytes(col.totalSize || 0) : noData}
641+
</btrix-table-cell>
642+
<btrix-table-cell>
633643
${col.hasDedupeIndex
634-
? html`<sl-tooltip content=${msg("Deduplicated")}>
635-
<btrix-badge variant="success" pill
636-
>${msg("Deduped")}</btrix-badge
637-
>
644+
? html`<sl-tooltip content=${msg("Deduplication Source")}>
645+
<btrix-badge variant="primary">${msg("Source")}</btrix-badge>
638646
</sl-tooltip>`
639-
: nothing}
647+
: noData}
640648
</btrix-table-cell>
641-
<btrix-table-cell>
649+
<btrix-table-cell class="flex-col items-start justify-center gap-0.5">
642650
<btrix-format-date
643651
date=${col.modified}
644-
month="2-digit"
645-
day="2-digit"
646-
year="numeric"
652+
dateStyle="medium"
647653
></btrix-format-date>
654+
<div class="font-monostyle text-xs leading-4 text-neutral-500">
655+
<btrix-format-date
656+
date=${col.modified}
657+
timeStyle="medium"
658+
></btrix-format-date>
659+
</div>
648660
</btrix-table-cell>
649661
<btrix-table-cell class="p-0">
650662
${this.isCrawler ? this.renderActions(col) : ""}

0 commit comments

Comments
 (0)