@everchron/ec-shards 19.10.3 → 19.10.4

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
@@ -6262,6 +6262,10 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6262
6262
  type: Boolean,
6263
6263
  default: !1
6264
6264
  },
6265
+ highlighted: {
6266
+ type: Boolean,
6267
+ default: !1
6268
+ },
6265
6269
  expanded: {
6266
6270
  type: Boolean,
6267
6271
  default: !1
@@ -6346,6 +6350,9 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6346
6350
  cardExpanded() {
6347
6351
  return this.isExpanded && !!this.expandMode;
6348
6352
  },
6353
+ cardSelected() {
6354
+ return this.highlighted || this.isSelected;
6355
+ },
6349
6356
  expandLoading() {
6350
6357
  return this.loading || this.isLoading;
6351
6358
  },
@@ -6362,7 +6369,16 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6362
6369
  return !!this.$slots.header || this.selectable || this.showExpandButton || !!this.$slots.actions;
6363
6370
  },
6364
6371
  hasTimeline() {
6365
- return !!this.timeline;
6372
+ return !!(this.$slots.timelinePrimary || this.$slots.timelineSecondary || this.$slots.timelineTertiary || this.timeline);
6373
+ },
6374
+ showTimelinePrimary() {
6375
+ return !!(this.$slots.timelinePrimary || this.timelinePrimary);
6376
+ },
6377
+ showTimelineSecondary() {
6378
+ return !!(this.$slots.timelineSecondary || this.timelineSecondary);
6379
+ },
6380
+ showTimelineTertiary() {
6381
+ return !!(this.$slots.timelineTertiary || this.timelineTertiary);
6366
6382
  },
6367
6383
  timelinePrimary() {
6368
6384
  return this.normalizeTimelineField(this.timeline && this.timeline.primary);
@@ -6372,6 +6388,15 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6372
6388
  },
6373
6389
  timelineTertiary() {
6374
6390
  return this.normalizeTimelineField(this.timeline && this.timeline.tertiary);
6391
+ },
6392
+ timelinePrimaryClasses() {
6393
+ return this.getTimelineFieldClasses(this.timeline && this.timeline.primary, this.timelinePrimary);
6394
+ },
6395
+ timelineSecondaryClasses() {
6396
+ return this.getTimelineFieldClasses(this.timeline && this.timeline.secondary, this.timelineSecondary);
6397
+ },
6398
+ timelineTertiaryClasses() {
6399
+ return this.getTimelineFieldClasses(this.timeline && this.timeline.tertiary, this.timelineTertiary);
6375
6400
  }
6376
6401
  },
6377
6402
  watch: {
@@ -6406,6 +6431,15 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6406
6431
  mono: !1
6407
6432
  };
6408
6433
  },
6434
+ getTimelineFieldClasses(e, t) {
6435
+ return t ? {
6436
+ "is-ai": t.ai,
6437
+ "is-mono": t.mono
6438
+ } : e && typeof e == "object" ? {
6439
+ "is-ai": !!e.ai,
6440
+ "is-mono": !!e.mono
6441
+ } : {};
6442
+ },
6409
6443
  onCardClick(e) {
6410
6444
  this.disabled || (this.$emit("click", e), this.expandMode === "click" && this.toggleExpand());
6411
6445
  },
@@ -6477,82 +6511,73 @@ var qo = /*#__PURE__*/ H(Bo, [["render", Ko], ["__scopeId", "data-v-95f66a3d"]])
6477
6511
  ref: "footerInner",
6478
6512
  class: "ecs-content-card-footer-inner"
6479
6513
  };
6480
- function os(e, t, n, r, i, a) {
6481
- let u = A("ecs-checkbox"), d = A("ecs-button"), p = A("ecs-card");
6514
+ function os(t, n, r, i, a, u) {
6515
+ let p = A("ecs-checkbox"), m = A("ecs-button"), h = A("ecs-card");
6482
6516
  return T(), c("div", {
6483
- style: S(a.rootStyle),
6517
+ style: S(u.rootStyle),
6484
6518
  class: b(["ecs-content-card", [
6485
- i.isExpanded ? "is-expanded" : "",
6486
- i.isSelected ? "is-selected" : "",
6487
- a.hasSidebar ? "has-sidebar" : "",
6488
- a.hasTimeline ? "has-timeline" : "",
6489
- a.expandMode ? "is-expandable" : ""
6519
+ a.isExpanded ? "is-expanded" : "",
6520
+ u.cardSelected ? "is-highlighted" : "",
6521
+ u.hasSidebar ? "has-sidebar" : "",
6522
+ u.hasTimeline ? "has-timeline" : "",
6523
+ u.expandMode ? "is-expandable" : ""
6490
6524
  ]])
6491
- }, [a.hasTimeline ? (T(), c("div", {
6525
+ }, [u.hasTimeline ? (T(), c("div", {
6492
6526
  key: 0,
6493
- class: b(["ecs-content-card-timeline", [i.isExpanded ? "expanded" : ""]])
6527
+ class: b(["ecs-content-card-timeline", [a.isExpanded ? "expanded" : ""]])
6494
6528
  }, [l("div", Yo, [
6495
- a.timelinePrimary ? (T(), c("div", {
6529
+ u.showTimelinePrimary ? (T(), c("div", {
6496
6530
  key: 0,
6497
- class: b(["ecs-content-card-timeline-primary", {
6498
- "is-ai": a.timelinePrimary.ai,
6499
- "is-mono": a.timelinePrimary.mono
6500
- }])
6501
- }, N(a.timelinePrimary.value), 3)) : s("", !0),
6502
- a.timelineSecondary ? (T(), c("div", {
6531
+ class: b(["ecs-content-card-timeline-primary", u.timelinePrimaryClasses])
6532
+ }, [t.$slots.timelinePrimary ? k(t.$slots, "timelinePrimary", { key: 0 }, void 0, !0) : (T(), c(e, { key: 1 }, [d(N(u.timelinePrimary.value), 1)], 64))], 2)) : s("", !0),
6533
+ u.showTimelineSecondary ? (T(), c("div", {
6503
6534
  key: 1,
6504
- class: b(["ecs-content-card-timeline-secondary", {
6505
- "is-ai": a.timelineSecondary.ai,
6506
- "is-mono": a.timelineSecondary.mono
6507
- }])
6508
- }, N(a.timelineSecondary.value), 3)) : s("", !0),
6509
- a.timelineTertiary ? (T(), c("div", {
6535
+ class: b(["ecs-content-card-timeline-secondary", u.timelineSecondaryClasses])
6536
+ }, [t.$slots.timelineSecondary ? k(t.$slots, "timelineSecondary", { key: 0 }, void 0, !0) : (T(), c(e, { key: 1 }, [d(N(u.timelineSecondary.value), 1)], 64))], 2)) : s("", !0),
6537
+ u.showTimelineTertiary ? (T(), c("div", {
6510
6538
  key: 2,
6511
- class: b(["ecs-content-card-timeline-tertiary", {
6512
- "is-ai": a.timelineTertiary.ai,
6513
- "is-mono": a.timelineTertiary.mono
6514
- }])
6515
- }, N(a.timelineTertiary.value), 3)) : s("", !0)
6516
- ])], 2)) : s("", !0), f(p, {
6517
- onClick: a.onCardClick,
6518
- onDblclick: a.onCardDblclick,
6519
- id: n.id,
6520
- selected: i.isSelected,
6521
- expanded: a.cardExpanded,
6522
- hover: a.showHover,
6523
- progress: n.progress,
6524
- disabled: n.disabled,
6539
+ class: b(["ecs-content-card-timeline-tertiary", u.timelineTertiaryClasses])
6540
+ }, [t.$slots.timelineTertiary ? k(t.$slots, "timelineTertiary", { key: 0 }, void 0, !0) : (T(), c(e, { key: 1 }, [d(N(u.timelineTertiary.value), 1)], 64))], 2)) : s("", !0)
6541
+ ])], 2)) : s("", !0), f(h, {
6542
+ onClick: u.onCardClick,
6543
+ onDblclick: u.onCardDblclick,
6544
+ id: r.id,
6545
+ selected: u.cardSelected,
6546
+ expanded: u.cardExpanded,
6547
+ hover: u.showHover,
6548
+ progress: r.progress,
6549
+ disabled: r.disabled,
6525
6550
  class: "ecs-content-card-card"
6526
6551
  }, {
6527
6552
  default: I(() => [l("div", Xo, [l("div", Zo, [l("div", Qo, [
6528
- a.hasHeader ? (T(), c("div", $o, [
6529
- n.selectable ? (T(), c("div", {
6553
+ u.hasHeader ? (T(), c("div", $o, [
6554
+ r.selectable ? (T(), c("div", {
6530
6555
  key: 0,
6531
- onClick: t[0] ||= R(() => {}, ["stop"]),
6556
+ onClick: n[0] ||= R(() => {}, ["stop"]),
6532
6557
  class: "ecs-content-card-select"
6533
- }, [f(u, {
6534
- onInput: a.onSelectInput,
6535
- value: i.isSelected,
6536
- disabled: n.disabled
6558
+ }, [f(p, {
6559
+ onInput: u.onSelectInput,
6560
+ value: a.isSelected,
6561
+ disabled: r.disabled
6537
6562
  }, null, 8, [
6538
6563
  "onInput",
6539
6564
  "value",
6540
6565
  "disabled"
6541
6566
  ])])) : s("", !0),
6542
- e.$slots.header ? (T(), c("div", es, [k(e.$slots, "header", {}, void 0, !0)])) : s("", !0),
6543
- a.showExpandButton ? (T(), o(d, {
6567
+ t.$slots.header ? (T(), c("div", es, [k(t.$slots, "header", {}, void 0, !0)])) : s("", !0),
6568
+ u.showExpandButton ? (T(), o(m, {
6544
6569
  key: 2,
6545
- onClick: R(a.toggleExpand, ["stop"]),
6570
+ onClick: R(u.toggleExpand, ["stop"]),
6546
6571
  type: "secondary",
6547
6572
  "icon-only": "",
6548
6573
  size: "sml",
6549
- icon: i.isExpanded ? "collapse" : "expand",
6550
- loading: a.expandLoading,
6551
- active: i.isExpanded || null,
6552
- disabled: n.disabled,
6553
- "aria-controls": i.expandId,
6554
- "aria-expanded": i.isExpanded ? "true" : "false",
6555
- "aria-label": i.isExpanded ? "Collapse" : "Expand",
6574
+ icon: a.isExpanded ? "collapse" : "expand",
6575
+ loading: u.expandLoading,
6576
+ active: a.isExpanded || null,
6577
+ disabled: r.disabled,
6578
+ "aria-controls": a.expandId,
6579
+ "aria-expanded": a.isExpanded ? "true" : "false",
6580
+ "aria-label": a.isExpanded ? "Collapse" : "Expand",
6556
6581
  class: "ecs-content-card-expand-button"
6557
6582
  }, null, 8, [
6558
6583
  "onClick",
@@ -6564,34 +6589,34 @@ function os(e, t, n, r, i, a) {
6564
6589
  "aria-expanded",
6565
6590
  "aria-label"
6566
6591
  ])) : s("", !0),
6567
- e.$slots.actions ? (T(), c("div", {
6592
+ t.$slots.actions ? (T(), c("div", {
6568
6593
  key: 3,
6569
- onClick: t[1] ||= R(() => {}, ["stop"]),
6594
+ onClick: n[1] ||= R(() => {}, ["stop"]),
6570
6595
  class: "ecs-content-card-actions"
6571
- }, [k(e.$slots, "actions", {}, void 0, !0)])) : s("", !0)
6596
+ }, [k(t.$slots, "actions", {}, void 0, !0)])) : s("", !0)
6572
6597
  ])) : s("", !0),
6573
- l("div", { class: b(["ecs-content-card-content", { "has-select": n.selectable }]) }, [k(e.$slots, "default", {}, void 0, !0)], 2),
6574
- e.$slots.contentExpand ? (T(), c("div", {
6598
+ l("div", { class: b(["ecs-content-card-content", { "has-select": r.selectable }]) }, [k(t.$slots, "default", {}, void 0, !0)], 2),
6599
+ t.$slots.contentExpand ? (T(), c("div", {
6575
6600
  key: 1,
6576
- id: i.expandId,
6577
- style: S({ height: i.isExpanded ? i.expandHeight + "px" : "0px" }),
6578
- "aria-hidden": i.isExpanded ? "false" : "true",
6601
+ id: a.expandId,
6602
+ style: S({ height: a.isExpanded ? a.expandHeight + "px" : "0px" }),
6603
+ "aria-hidden": a.isExpanded ? "false" : "true",
6579
6604
  class: "ecs-content-card-expand"
6580
6605
  }, [l("div", {
6581
6606
  ref: "expandInner",
6582
- class: b(["ecs-content-card-expand-inner", { "has-select": n.selectable }])
6583
- }, [k(e.$slots, "contentExpand", {}, void 0, !0)], 2)], 12, ts)) : s("", !0)
6584
- ]), e.$slots.sidebar ? (T(), c("div", {
6607
+ class: b(["ecs-content-card-expand-inner", { "has-select": r.selectable }])
6608
+ }, [k(t.$slots, "contentExpand", {}, void 0, !0)], 2)], 12, ts)) : s("", !0)
6609
+ ]), t.$slots.sidebar ? (T(), c("div", {
6585
6610
  key: 0,
6586
- style: S({ width: i.isExpanded ? "300px" : "0px" }),
6587
- "aria-hidden": i.isExpanded ? "false" : "true",
6611
+ style: S({ width: a.isExpanded ? "300px" : "0px" }),
6612
+ "aria-hidden": a.isExpanded ? "false" : "true",
6588
6613
  class: "ecs-content-card-sidebar"
6589
- }, [l("div", rs, [k(e.$slots, "sidebar", {}, void 0, !0)], 512)], 12, ns)) : s("", !0)]), e.$slots.footer ? (T(), c("div", {
6614
+ }, [l("div", rs, [k(t.$slots, "sidebar", {}, void 0, !0)], 512)], 12, ns)) : s("", !0)]), t.$slots.footer ? (T(), c("div", {
6590
6615
  key: 0,
6591
- style: S(a.footerStyle),
6592
- "aria-hidden": a.footerHidden ? "true" : "false",
6593
- class: b(["ecs-content-card-footer", { "is-collapsing": n.hideFooterOnExpand }])
6594
- }, [l("div", as, [k(e.$slots, "footer", {}, void 0, !0)], 512)], 14, is)) : s("", !0)])]),
6616
+ style: S(u.footerStyle),
6617
+ "aria-hidden": u.footerHidden ? "true" : "false",
6618
+ class: b(["ecs-content-card-footer", { "is-collapsing": r.hideFooterOnExpand }])
6619
+ }, [l("div", as, [k(t.$slots, "footer", {}, void 0, !0)], 512)], 14, is)) : s("", !0)])]),
6595
6620
  _: 3
6596
6621
  }, 8, [
6597
6622
  "onClick",
@@ -6604,7 +6629,7 @@ function os(e, t, n, r, i, a) {
6604
6629
  "disabled"
6605
6630
  ])], 6);
6606
6631
  }
6607
- var ss = /*#__PURE__*/ H(Jo, [["render", os], ["__scopeId", "data-v-255198d5"]]), cs = {
6632
+ var ss = /*#__PURE__*/ H(Jo, [["render", os], ["__scopeId", "data-v-ca896d7a"]]), cs = {
6608
6633
  name: "ecs-formatted",
6609
6634
  components: { EcsSkeletonLoader: G },
6610
6635
  mixins: [Y],