@everchron/ec-shards 19.12.1 → 19.12.3

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.
package/dist/ec-shards.js CHANGED
@@ -6397,6 +6397,15 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6397
6397
  loading: {
6398
6398
  type: Boolean,
6399
6399
  default: !1
6400
+ },
6401
+ checkboxHeight: { type: Number },
6402
+ sidebarWidth: {
6403
+ type: String,
6404
+ default: "300px"
6405
+ },
6406
+ sidebarBreakpoint: {
6407
+ type: Number,
6408
+ default: null
6400
6409
  }
6401
6410
  },
6402
6411
  data() {
@@ -6405,8 +6414,9 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6405
6414
  isExpanded: this.expanded,
6406
6415
  isLoading: !1,
6407
6416
  expandHeight: 0,
6408
- sidebarWidth: 0,
6417
+ sidebarInlineHeight: 0,
6409
6418
  footerHeight: 0,
6419
+ containerWidth: 0,
6410
6420
  expandId: ""
6411
6421
  };
6412
6422
  },
@@ -6414,6 +6424,15 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6414
6424
  rootStyle() {
6415
6425
  return { width: this.isExpanded ? this.expandedWidth : this.collapsedWidth };
6416
6426
  },
6427
+ resolvedSidebarWidth() {
6428
+ let e = this.sidebarWidth;
6429
+ if (typeof e != "string") return 0;
6430
+ let t = parseFloat(e);
6431
+ return isNaN(t) ? 0 : e.trim().endsWith("%") ? Math.round(this.containerWidth * t / 100) : t;
6432
+ },
6433
+ sidebarInline() {
6434
+ return this.sidebarBreakpoint != null && this.containerWidth > 0 && this.containerWidth <= this.sidebarBreakpoint;
6435
+ },
6417
6436
  expandMode() {
6418
6437
  return this.expandable === !0 || this.expandable === "button" ? "button" : this.expandable === "click" || this.expandable === "dblclick" ? this.expandable : null;
6419
6438
  },
@@ -6555,7 +6574,7 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6555
6574
  this.isExpanded !== t && (this.measure(), this.isExpanded = t, this.$emit("update:expanded", this.isExpanded));
6556
6575
  },
6557
6576
  setupObservers() {
6558
- typeof ResizeObserver > "u" || (this.resizeObserver = new ResizeObserver(() => this.measure()), this.observeRefs());
6577
+ typeof ResizeObserver > "u" || (this.resizeObserver = new ResizeObserver(() => this.measure()), this.$el && this.$el.nodeType === 1 && this.resizeObserver.observe(this.$el), this.observeRefs());
6559
6578
  },
6560
6579
  observeRefs() {
6561
6580
  if (!this.resizeObserver) return;
@@ -6563,6 +6582,7 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6563
6582
  let e = {
6564
6583
  expand: this.$refs.expandInner,
6565
6584
  sidebar: this.$refs.sidebarInner,
6585
+ sidebarInline: this.$refs.sidebarInlineInner,
6566
6586
  footer: this.$refs.footerInner
6567
6587
  };
6568
6588
  Object.keys(e).forEach((t) => {
@@ -6571,7 +6591,7 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6571
6591
  });
6572
6592
  },
6573
6593
  measure() {
6574
- this.$refs.expandInner && (this.expandHeight = this.$refs.expandInner.offsetHeight), this.$refs.sidebarInner && (this.sidebarWidth = this.$refs.sidebarInner.offsetWidth), this.$refs.footerInner && (this.footerHeight = this.$refs.footerInner.offsetHeight);
6594
+ this.$el && this.$el.nodeType === 1 && (this.containerWidth = this.$el.offsetWidth), this.$refs.expandInner && (this.expandHeight = this.$refs.expandInner.offsetHeight), this.$refs.sidebarInlineInner && (this.sidebarInlineHeight = this.$refs.sidebarInlineInner.offsetHeight), this.$refs.footerInner && (this.footerHeight = this.$refs.footerInner.offsetHeight);
6575
6595
  }
6576
6596
  }
6577
6597
  }, qo = { class: "ecs-content-card-timeline-inner" }, Jo = { class: "ecs-content-card-body" }, Yo = { class: "ecs-content-card-columns" }, Xo = { class: "ecs-content-card-main" }, Zo = {
@@ -6580,10 +6600,7 @@ var Go = /*#__PURE__*/ V(Ro, [["render", Wo], ["__scopeId", "data-v-95f66a3d"]])
6580
6600
  }, Qo = {
6581
6601
  key: 1,
6582
6602
  class: "ecs-content-card-header-content"
6583
- }, $o = ["id", "aria-hidden"], es = ["aria-hidden"], ts = {
6584
- ref: "sidebarInner",
6585
- class: "ecs-content-card-sidebar-inner"
6586
- }, ns = ["aria-hidden"], rs = {
6603
+ }, $o = ["id", "aria-hidden"], es = ["aria-hidden"], ts = ["aria-hidden"], ns = ["aria-hidden"], rs = {
6587
6604
  ref: "footerInner",
6588
6605
  class: "ecs-content-card-footer-inner"
6589
6606
  };
@@ -6630,7 +6647,8 @@ function is(t, n, r, i, a, u) {
6630
6647
  r.selectable ? (T(), c("div", {
6631
6648
  key: 0,
6632
6649
  onClick: n[0] ||= R(() => {}, ["stop"]),
6633
- class: "ecs-content-card-select"
6650
+ class: "ecs-content-card-select",
6651
+ style: S(r.checkboxHeight == null ? null : { height: r.checkboxHeight + "px" })
6634
6652
  }, [f(p, {
6635
6653
  onInput: u.onSelectInput,
6636
6654
  value: a.isSelected,
@@ -6639,7 +6657,7 @@ function is(t, n, r, i, a, u) {
6639
6657
  "onInput",
6640
6658
  "value",
6641
6659
  "disabled"
6642
- ])])) : s("", !0),
6660
+ ])], 4)) : s("", !0),
6643
6661
  t.$slots.header ? (T(), c("div", Qo, [k(t.$slots, "header", {}, void 0, !0)])) : s("", !0),
6644
6662
  u.showExpandButton ? (T(), o(m, {
6645
6663
  key: 2,
@@ -6681,13 +6699,26 @@ function is(t, n, r, i, a, u) {
6681
6699
  }, [l("div", {
6682
6700
  ref: "expandInner",
6683
6701
  class: b(["ecs-content-card-expand-inner", { "has-select": r.selectable }])
6684
- }, [k(t.$slots, "contentExpand", {}, void 0, !0)], 2)], 12, $o)) : s("", !0)
6685
- ]), t.$slots.sidebar ? (T(), c("div", {
6702
+ }, [k(t.$slots, "contentExpand", {}, void 0, !0)], 2)], 12, $o)) : s("", !0),
6703
+ t.$slots.sidebar && u.sidebarInline ? (T(), c("div", {
6704
+ key: 2,
6705
+ style: S({ height: a.isExpanded ? a.sidebarInlineHeight + "px" : "0px" }),
6706
+ "aria-hidden": a.isExpanded ? "false" : "true",
6707
+ class: "ecs-content-card-sidebar-inline"
6708
+ }, [l("div", {
6709
+ ref: "sidebarInlineInner",
6710
+ class: b(["ecs-content-card-sidebar-inline-inner", { "has-select": r.selectable }])
6711
+ }, [k(t.$slots, "sidebar", {}, void 0, !0)], 2)], 12, es)) : s("", !0)
6712
+ ]), t.$slots.sidebar && !u.sidebarInline ? (T(), c("div", {
6686
6713
  key: 0,
6687
- style: S({ width: a.isExpanded ? "300px" : "0px" }),
6714
+ style: S({ width: a.isExpanded ? u.resolvedSidebarWidth + "px" : "0px" }),
6688
6715
  "aria-hidden": a.isExpanded ? "false" : "true",
6689
6716
  class: "ecs-content-card-sidebar"
6690
- }, [l("div", ts, [k(t.$slots, "sidebar", {}, void 0, !0)], 512)], 12, es)) : s("", !0)]), t.$slots.footer ? (T(), c("div", {
6717
+ }, [l("div", {
6718
+ ref: "sidebarInner",
6719
+ style: S({ width: u.resolvedSidebarWidth + "px" }),
6720
+ class: "ecs-content-card-sidebar-inner"
6721
+ }, [k(t.$slots, "sidebar", {}, void 0, !0)], 4)], 12, ts)) : s("", !0)]), t.$slots.footer ? (T(), c("div", {
6691
6722
  key: 0,
6692
6723
  style: S(u.footerStyle),
6693
6724
  "aria-hidden": u.footerHidden ? "true" : "false",
@@ -6705,7 +6736,7 @@ function is(t, n, r, i, a, u) {
6705
6736
  "disabled"
6706
6737
  ])], 6);
6707
6738
  }
6708
- var as = /*#__PURE__*/ V(Ko, [["render", is], ["__scopeId", "data-v-d1f03f28"]]), os = {
6739
+ var as = /*#__PURE__*/ V(Ko, [["render", is], ["__scopeId", "data-v-a5144026"]]), os = {
6709
6740
  name: "ecs-formatted",
6710
6741
  components: { EcsSkeletonLoader: G },
6711
6742
  mixins: [Y],
@@ -11982,7 +12013,7 @@ function Bf(t, n, i, a, u, p) {
11982
12013
  })
11983
12014
  ], 10, Df);
11984
12015
  }
11985
- var Vf = /*#__PURE__*/ V(Ef, [["render", Bf], ["__scopeId", "data-v-01b37b2f"]]), Hf = { class: "ecs-flag" }, Uf = /*#__PURE__*/ V({
12016
+ var Vf = /*#__PURE__*/ V(Ef, [["render", Bf], ["__scopeId", "data-v-93d8b53b"]]), Hf = { class: "ecs-flag" }, Uf = /*#__PURE__*/ V({
11986
12017
  __name: "flag",
11987
12018
  props: { code: {
11988
12019
  type: String,