@fluid-topics/ft-reader-topic-metadata 1.1.80 → 1.1.82

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,8 @@ import { PropertyValues } from "lit";
2
2
  import { FtReaderTopicMetadataProperties } from "./ft-reader-topic-metadata.properties";
3
3
  import { FtReaderTopicComponent } from "@fluid-topics/ft-reader-topic-context/build/registration";
4
4
  import { ElementDefinitionsMap } from "@fluid-topics/ft-wc-utils";
5
- export declare class FtReaderTopicMetadata extends FtReaderTopicComponent implements FtReaderTopicMetadataProperties {
5
+ declare const FtReaderTopicMetadata_base: typeof FtReaderTopicComponent & import("@fluid-topics/ft-wc-utils").Constructor<import("@fluid-topics/ft-app-context/build/mixins/withDateFormat").FtLitElementWithDateFormatInterface>;
6
+ export declare class FtReaderTopicMetadata extends FtReaderTopicMetadata_base implements FtReaderTopicMetadataProperties {
6
7
  static elementDefinitions: ElementDefinitionsMap;
7
8
  static styles: import("lit").CSSResult;
8
9
  key?: string;
@@ -20,3 +21,4 @@ export declare class FtReaderTopicMetadata extends FtReaderTopicComponent implem
20
21
  protected onStoreAvailable(): void;
21
22
  private updateContent;
22
23
  }
24
+ export {};
@@ -11,7 +11,8 @@ import { FtReaderTopicComponent } from "@fluid-topics/ft-reader-topic-context/bu
11
11
  import { ClusteringHelper } from "@fluid-topics/ft-wc-utils";
12
12
  import { FtTooltip } from "@fluid-topics/ft-tooltip";
13
13
  import { FtChip } from "@fluid-topics/ft-chip";
14
- class FtReaderTopicMetadata extends FtReaderTopicComponent {
14
+ import { withDateFormat } from "@fluid-topics/ft-app-context/build/mixins/withDateFormat";
15
+ class FtReaderTopicMetadata extends withDateFormat(FtReaderTopicComponent) {
15
16
  constructor() {
16
17
  super(...arguments);
17
18
  this.multiLine = false;
@@ -74,8 +75,8 @@ class FtReaderTopicMetadata extends FtReaderTopicComponent {
74
75
  if (["key", "tocNode"].some(p => props.has(p))) {
75
76
  this.updateContent();
76
77
  }
77
- if (props.has("metadata")) {
78
- this.flatMetadata = ClusteringHelper.flattenMetadata(this.metadata);
78
+ if (props.has("metadata") || this.dateFormatOptionsChanged(props)) {
79
+ this.flatMetadata = ClusteringHelper.flattenMetadata(this.formatDateValues(this.metadata));
79
80
  }
80
81
  }
81
82
  onStoreAvailable() {