@elasticias/ui 1.0.5 → 1.0.6

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.
@@ -4794,15 +4794,30 @@ class EfBuildStampComponent {
4794
4794
  owner = input('', ...(ngDevMode ? [{ debugName: "owner" }] : /* istanbul ignore next */ []));
4795
4795
  info = inject(EF_BUILD_INFO, { optional: true });
4796
4796
  year = new Date().getFullYear();
4797
- /** Commit and branch always identify a build; a version only appears when
4798
- * the app actually maintains one, so an unversioned app shows no `v`. */
4799
- detail = computed(() => {
4797
+ /**
4798
+ * A released build is known by its version; an unreleased one has no
4799
+ * version to be known by, so it shows what actually identifies it.
4800
+ *
4801
+ * That is not a cosmetic split. Only production is cut from a tag, so
4802
+ * only production has a number a person can repeat back to you. On
4803
+ * develop and staging the honest answer is where it came from and when.
4804
+ */
4805
+ label = computed(() => {
4800
4806
  if (!this.info)
4801
4807
  return '';
4802
- const parts = [this.info.commit, this.info.branch];
4803
4808
  if (this.info.version)
4804
- parts.push(`v${this.info.version}`);
4805
- return parts.join(' · ');
4809
+ return `v${this.info.version}`;
4810
+ return [this.info.environment, this.info.commit, this.info.date]
4811
+ .filter(Boolean)
4812
+ .join(' · ');
4813
+ }, ...(ngDevMode ? [{ debugName: "label" }] : /* istanbul ignore next */ []));
4814
+ /** The rest of the identity, for when the label is only a version. */
4815
+ detail = computed(() => {
4816
+ if (!this.info)
4817
+ return '';
4818
+ return [this.info.commit, this.info.environment, this.info.date]
4819
+ .filter(Boolean)
4820
+ .join(' · ');
4806
4821
  }, ...(ngDevMode ? [{ debugName: "detail" }] : /* istanbul ignore next */ []));
4807
4822
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.11", ngImport: i0, type: EfBuildStampComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
4808
4823
  static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.11", type: EfBuildStampComponent, isStandalone: true, selector: "ef-build-stamp", inputs: { owner: { classPropertyName: "owner", publicName: "owner", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: `
@@ -4812,7 +4827,7 @@ class EfBuildStampComponent {
4812
4827
  <span class="ef-build-stamp__owner">© {{ year }} {{ owner() }}</span>
4813
4828
  <span class="ef-build-stamp__sep" aria-hidden="true">·</span>
4814
4829
  }
4815
- <span class="ef-build-stamp__build">build {{ info.date }}</span>
4830
+ <span class="ef-build-stamp__build">{{ label() }}</span>
4816
4831
  </span>
4817
4832
  }
4818
4833
  `, isInline: true, dependencies: [{ kind: "directive", type: EfTooltipDirective, selector: "[efTooltip]" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
@@ -4830,7 +4845,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.11", ngImpo
4830
4845
  <span class="ef-build-stamp__owner">© {{ year }} {{ owner() }}</span>
4831
4846
  <span class="ef-build-stamp__sep" aria-hidden="true">·</span>
4832
4847
  }
4833
- <span class="ef-build-stamp__build">build {{ info.date }}</span>
4848
+ <span class="ef-build-stamp__build">{{ label() }}</span>
4834
4849
  </span>
4835
4850
  }
4836
4851
  `,