@assemblyvoting/ui-library 3.3.8-beta.1 → 3.3.8-beta.3

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.js CHANGED
@@ -30380,10 +30380,7 @@ const $41 = {
30380
30380
  class: "AVRankedSummary--table",
30381
30381
  id: "ranked_summary_table",
30382
30382
  "data-test": "table"
30383
- }, c61 = { class: "AVRankedSummary--heading" }, e61 = {
30384
- class: "AVRankedSummary--summary",
30385
- "data-test": "summary"
30386
- }, l61 = { key: 0 }, a61 = { key: 1 }, t61 = { key: 2 }, s61 = /* @__PURE__ */ W({
30383
+ }, c61 = { class: "AVRankedSummary--heading" }, e61 = { key: 0 }, l61 = { key: 1 }, a61 = { key: 2 }, t61 = /* @__PURE__ */ W({
30387
30384
  __name: "AVRankedSummary",
30388
30385
  props: {
30389
30386
  result: {},
@@ -30433,57 +30430,63 @@ const $41 = {
30433
30430
  r("td", null, M(d.elected && z + 1 || ""), 1),
30434
30431
  r("td", {
30435
30432
  class: $({
30436
- "AVRankedSummary--title-color-white": o.theme === "dark",
30437
- "AVRankedSummary--title-color-black": o.theme === "light"
30433
+ "AVRankedSummary--title-color-white": o.theme === "dark" && !d.elected && !d.tied,
30434
+ "AVRankedSummary--title-color-black": o.theme === "light" || d.elected || d.tied
30438
30435
  })
30439
30436
  }, M(d.title[i.value]), 3),
30440
30437
  (u(!0), p(Y, null, r1(d.rounds, (m, h) => (u(), p("td", {
30441
30438
  key: `round_nr_${h}`,
30442
30439
  class: $(["AVRankedSummary--text", {
30443
30440
  "AVRankedSummary--text-bold": h + 1 === l.value,
30444
- "AVRankedSummary--title-color-white": o.theme === "dark",
30445
- "AVRankedSummary--title-color-black": o.theme === "light"
30441
+ "AVRankedSummary--title-color-white": o.theme === "dark" && !d.elected && !d.tied,
30442
+ "AVRankedSummary--title-color-black": o.theme === "light" || d.elected || d.tied
30446
30443
  }])
30447
30444
  }, M(m.count), 3))), 128))
30448
30445
  ], 2))), 128))
30449
30446
  ])
30450
30447
  ])
30451
30448
  ]),
30452
- r("div", e61, [
30449
+ r("div", {
30450
+ class: $(["AVRankedSummary--summary", {
30451
+ "AVRankedSummary--title-color-white": o.theme === "dark",
30452
+ "AVRankedSummary--title-color-black": o.theme === "light"
30453
+ }]),
30454
+ "data-test": "summary"
30455
+ }, [
30453
30456
  r("p", null, M(O(n)("js.components.AVRankedSummary.summary.seats")) + ": " + M(o.seats), 1),
30454
- o.distributionNumber > 0 ? (u(), p("p", l61, M(O(n)("js.components.AVRankedSummary.summary.distribution")) + ": " + M(o.distributionNumber), 1)) : T("", !0),
30455
- a.value.length > 0 ? (u(), p("p", a61, [
30457
+ o.distributionNumber > 0 ? (u(), p("p", e61, M(O(n)("js.components.AVRankedSummary.summary.distribution")) + ": " + M(o.distributionNumber), 1)) : T("", !0),
30458
+ a.value.length > 0 ? (u(), p("p", l61, [
30456
30459
  o1(M(O(n)("js.components.AVRankedSummary.summary.elected")) + ": ", 1),
30457
30460
  r("span", null, M(a.value.join(", ")), 1)
30458
30461
  ])) : T("", !0),
30459
- t.value.length > 0 ? (u(), p("p", t61, [
30462
+ t.value.length > 0 ? (u(), p("p", a61, [
30460
30463
  o1(M(O(n)("js.components.AVRankedSummary.summary.tied")) + ": ", 1),
30461
30464
  r("span", null, M(t.value.join(", ")), 1)
30462
30465
  ])) : T("", !0)
30463
- ])
30466
+ ], 2)
30464
30467
  ], 64));
30465
30468
  }
30466
- }), n61 = /* @__PURE__ */ J(s61, [["__scopeId", "data-v-1e6d07c5"]]), i61 = { class: "AVInstantRunoffSummary" }, o61 = {
30469
+ }), s61 = /* @__PURE__ */ J(t61, [["__scopeId", "data-v-8c98c441"]]), n61 = { class: "AVInstantRunoffSummary" }, i61 = {
30467
30470
  class: "AVInstantRunoffSummary--title",
30468
30471
  "data-test": "seat-title"
30469
- }, r61 = { class: "AVInstantRunoffSummary--container" }, f61 = { class: "AVInstantRunoffSummary--table-container" }, u61 = {
30472
+ }, o61 = { class: "AVInstantRunoffSummary--container" }, r61 = { class: "AVInstantRunoffSummary--table-container" }, f61 = {
30470
30473
  class: "AVInstantRunoffSummary--table",
30471
30474
  id: "ranked_summary_table",
30472
30475
  "data-test": "table"
30473
- }, m61 = { class: "AVInstantRunoffSummary--heading" }, d61 = {
30476
+ }, u61 = { class: "AVInstantRunoffSummary--heading" }, m61 = {
30474
30477
  key: 0,
30475
30478
  class: "AVInstantRunoffSummary--summary",
30476
30479
  "data-test": "not-included"
30477
- }, p61 = {
30480
+ }, d61 = {
30478
30481
  class: "AVInstantRunoffSummary--summary",
30479
30482
  "data-test": "abstain"
30480
- }, z61 = {
30483
+ }, p61 = {
30481
30484
  class: "AVInstantRunoffSummary--summary",
30482
30485
  "data-test": "total"
30483
- }, h61 = {
30486
+ }, z61 = {
30484
30487
  class: "AVInstantRunoffSummary--summary",
30485
30488
  "data-test": "quota"
30486
- }, L61 = /* @__PURE__ */ W({
30489
+ }, h61 = /* @__PURE__ */ W({
30487
30490
  __name: "AVInstantRunoffSummary",
30488
30491
  props: {
30489
30492
  rounds: {
@@ -30537,12 +30540,12 @@ const $41 = {
30537
30540
  { deep: !0 }
30538
30541
  ), (o, f) => {
30539
30542
  const d = P("AVIcon"), z = p2("tooltip");
30540
- return u(), p("div", i61, [
30541
- r("h5", o61, M(O(n)("js.components.AVInstantRunoffSummary.seat_n", { n: c.seatNumber })), 1),
30542
- r("div", r61, [
30543
- r("div", f61, [
30544
- r("table", u61, [
30545
- r("thead", m61, [
30543
+ return u(), p("div", n61, [
30544
+ r("h5", i61, M(O(n)("js.components.AVInstantRunoffSummary.seat_n", { n: c.seatNumber })), 1),
30545
+ r("div", o61, [
30546
+ r("div", r61, [
30547
+ r("table", f61, [
30548
+ r("thead", u61, [
30546
30549
  r("tr", null, [
30547
30550
  r("th", null, M(O(n)("js.components.AVInstantRunoffSummary.header.candidate")), 1),
30548
30551
  (u(!0), p(Y, null, r1(c.rounds, (m, h) => R1((u(), p("th", {
@@ -30601,19 +30604,19 @@ const $41 = {
30601
30604
  ])
30602
30605
  ])
30603
30606
  ]),
30604
- c.votesNotIncluded ? (u(), p("p", d61, [
30607
+ c.votesNotIncluded ? (u(), p("p", m61, [
30605
30608
  r("strong", null, M(O(n)("js.components.AVInstantRunoffSummary.summary.not_included_count")), 1),
30606
30609
  o1(" " + M(c.votesNotIncluded), 1)
30607
30610
  ])) : T("", !0),
30608
- r("p", p61, [
30611
+ r("p", d61, [
30609
30612
  r("strong", null, M(O(n)("js.components.AVInstantRunoffSummary.summary.abstain")), 1),
30610
30613
  o1(" " + M(c.blankVotes), 1)
30611
30614
  ]),
30612
- r("p", z61, [
30615
+ r("p", p61, [
30613
30616
  r("strong", null, M(O(n)("js.components.AVInstantRunoffSummary.summary.total_votes")), 1),
30614
30617
  o1(" " + M(c.totalVotes), 1)
30615
30618
  ]),
30616
- r("p", h61, [
30619
+ r("p", z61, [
30617
30620
  r("strong", null, M(O(n)("js.components.AVInstantRunoffSummary.summary.quota")), 1),
30618
30621
  o1(" " + M(c.quota), 1)
30619
30622
  ])
@@ -30621,16 +30624,16 @@ const $41 = {
30621
30624
  ]);
30622
30625
  };
30623
30626
  }
30624
- }), M61 = /* @__PURE__ */ J(L61, [["__scopeId", "data-v-cb5cf40d"]]);
30625
- var g61 = {}, b61 = { class: "flex items-center" }, v61 = { class: "flex flex-col items-center justify-center p-3 w-full" };
30626
- function C61(c, e) {
30627
+ }), L61 = /* @__PURE__ */ J(h61, [["__scopeId", "data-v-cb5cf40d"]]);
30628
+ var M61 = {}, g61 = { class: "flex items-center" }, b61 = { class: "flex flex-col items-center justify-center p-3 w-full" };
30629
+ function v61(c, e) {
30627
30630
  var l = P("AVNavbarItem"), a = P("AVNavigationItemList"), t = P("AVMenuDropdown"), s = P("AVNavbar"), n = P("AVLabel"), i = P("AVTabSwitcher"), o = P("AVSidebarItem"), f = P("AVButton"), d = P("AVSidebar"), z = P("AVContent"), m = P("AVFooter");
30628
30631
  return u(), p(Y, null, [
30629
30632
  w(s, null, {
30630
30633
  default: a1(function() {
30631
30634
  return [
30632
30635
  e[0] || (e[0] = r("a", { href: "#" }, "LOGO", -1)),
30633
- r("div", b61, [
30636
+ r("div", g61, [
30634
30637
  w(a, { type: "navbar" }, {
30635
30638
  default: a1(function() {
30636
30639
  return [
@@ -30673,7 +30676,7 @@ function C61(c, e) {
30673
30676
  w(d, null, {
30674
30677
  default: a1(function() {
30675
30678
  return [
30676
- r("div", v61, [
30679
+ r("div", b61, [
30677
30680
  e[1] || (e[1] = r("h2", { class: "mb-4" }, "Election Name", -1)),
30678
30681
  w(n, {
30679
30682
  value: "draft",
@@ -30785,16 +30788,16 @@ function C61(c, e) {
30785
30788
  w(m)
30786
30789
  ], 64);
30787
30790
  }
30788
- const A61 = /* @__PURE__ */ J(g61, [["render", C61]]);
30789
- var _61 = {}, x61 = { class: "flex items-center" }, N61 = { class: "flex flex-col items-center justify-center p-3 w-full" };
30790
- function y61(c, e) {
30791
+ const C61 = /* @__PURE__ */ J(M61, [["render", v61]]);
30792
+ var A61 = {}, _61 = { class: "flex items-center" }, x61 = { class: "flex flex-col items-center justify-center p-3 w-full" };
30793
+ function N61(c, e) {
30791
30794
  var l = P("AVNavbarItem"), a = P("AVNavigationItemList"), t = P("AVMenuDropdown"), s = P("AVNavbar"), n = P("AVLabel"), i = P("AVTabSwitcher"), o = P("AVSidebarItem"), f = P("AVButton"), d = P("AVSidebar"), z = P("AVContent"), m = P("AVFooter");
30792
30795
  return u(), p(Y, null, [
30793
30796
  w(s, null, {
30794
30797
  default: a1(function() {
30795
30798
  return [
30796
30799
  e[0] || (e[0] = r("a", { href: "#" }, "LOGO", -1)),
30797
- r("div", x61, [
30800
+ r("div", _61, [
30798
30801
  w(a, { type: "navbar" }, {
30799
30802
  default: a1(function() {
30800
30803
  return [
@@ -30837,7 +30840,7 @@ function y61(c, e) {
30837
30840
  w(d, null, {
30838
30841
  default: a1(function() {
30839
30842
  return [
30840
- r("div", N61, [
30843
+ r("div", x61, [
30841
30844
  e[1] || (e[1] = r("h2", { class: "mb-4" }, "Election Name", -1)),
30842
30845
  w(n, {
30843
30846
  value: "draft",
@@ -30982,16 +30985,16 @@ function y61(c, e) {
30982
30985
  w(m)
30983
30986
  ], 64);
30984
30987
  }
30985
- const k61 = /* @__PURE__ */ J(_61, [["render", y61]]);
30986
- var S61 = {}, V61 = { class: "flex items-center" };
30987
- function w61(c, e) {
30988
+ const y61 = /* @__PURE__ */ J(A61, [["render", N61]]);
30989
+ var k61 = {}, S61 = { class: "flex items-center" };
30990
+ function V61(c, e) {
30988
30991
  var l = P("AVNavbarItem"), a = P("AVNavigationItemList"), t = P("AVMenuDropdown"), s = P("AVNavbar"), n = P("AVContent"), i = P("AVFooter");
30989
30992
  return u(), p(Y, null, [
30990
30993
  w(s, null, {
30991
30994
  default: a1(function() {
30992
30995
  return [
30993
30996
  e[0] || (e[0] = r("a", { href: "#" }, "LOGO", -1)),
30994
- r("div", V61, [
30997
+ r("div", S61, [
30995
30998
  w(a, { type: "navbar" }, {
30996
30999
  default: a1(function() {
30997
31000
  return [
@@ -31054,10 +31057,10 @@ function w61(c, e) {
31054
31057
  })
31055
31058
  ], 64);
31056
31059
  }
31057
- const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex items-center" }, H61 = { href: "/new" }, I61 = { class: "new-election-button" }, O61 = {
31060
+ const w61 = /* @__PURE__ */ J(k61, [["render", V61]]), E61 = { class: "flex items-center" }, T61 = { href: "/new" }, H61 = { class: "new-election-button" }, I61 = {
31058
31061
  key: 0,
31059
31062
  class: "no-elections-container"
31060
- }, P61 = /* @__PURE__ */ W({
31063
+ }, O61 = /* @__PURE__ */ W({
31061
31064
  __name: "ElectionDashboardLayout",
31062
31065
  setup(c) {
31063
31066
  const e = [
@@ -31116,7 +31119,7 @@ const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex item
31116
31119
  w(i, null, {
31117
31120
  default: a1(() => [
31118
31121
  a[0] || (a[0] = r("a", { href: "#" }, "LOGO", -1)),
31119
- r("div", T61, [
31122
+ r("div", E61, [
31120
31123
  w(s, { type: "navbar" }, {
31121
31124
  default: a1(() => [
31122
31125
  w(t, {
@@ -31157,7 +31160,7 @@ const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex item
31157
31160
  class: "dashboard-container"
31158
31161
  }, {
31159
31162
  default: a1(() => [
31160
- r("a", H61, [
31163
+ r("a", T61, [
31161
31164
  w(f, {
31162
31165
  variant: "rounded",
31163
31166
  role: "button"
@@ -31169,7 +31172,7 @@ const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex item
31169
31172
  "data-test": "title"
31170
31173
  }, "Create new election")
31171
31174
  ], -1)),
31172
- r("div", I61, [
31175
+ r("div", H61, [
31173
31176
  w(o, {
31174
31177
  icon: "fa-solid fa-circle-plus",
31175
31178
  class: "new-election-icon"
@@ -31179,7 +31182,7 @@ const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex item
31179
31182
  _: 1
31180
31183
  })
31181
31184
  ]),
31182
- e.length === 0 ? (u(), p("div", O61, [
31185
+ e.length === 0 ? (u(), p("div", I61, [
31183
31186
  w(o, {
31184
31187
  icon: "fa-solid fa-folder-open",
31185
31188
  class: "no-elections-icon"
@@ -31216,9 +31219,9 @@ const E61 = /* @__PURE__ */ J(S61, [["render", w61]]), T61 = { class: "flex item
31216
31219
  ], 64);
31217
31220
  };
31218
31221
  }
31219
- }), D61 = /* @__PURE__ */ J(P61, [["__scopeId", "data-v-20fc858f"]]), F61 = {
31222
+ }), P61 = /* @__PURE__ */ J(O61, [["__scopeId", "data-v-20fc858f"]]), R61 = {
31220
31223
  install: function(c, e) {
31221
- e === void 0 && (e = null), c.use(DG), c.component("AVIcon", xQ), c.component("AVButton", kQ), c.component("AVSpinner", VQ), c.component("AVBullet", T6), c.component("AVTextInput", FQ), c.component("AVNumberInput", GQ), c.component("AVPasswordInput", aY), c.component("AVDatetimeInput", uY), c.component("AVTextArea", gY), c.component("AVCard", AY), c.component("AVRoundButton", xY), c.component("AVLabel", vY), c.component("AVDropdown", IY), c.component("AVDropdownContent", DY), c.component("AVDropdownItem", FY), c.component("AVAlert", WY), c.component("AVFileInput", AK), c.component("AVRadio", yK), c.component("AVLink", VK), c.component("AVNavbarItem", OK), c.component("AVSidebarItem", $K), c.component("AVTooltip", WK), c.component("AVMenuDropdown", QK), c.component("AVMenuDropdownContent", XK), c.component("AVMenuDropdownItem", lX), c.component("AVAsyncButton", nX), c.component("AVTabSwitcher", fX), c.component("AVBallotSummary", zX), c.component("AVTimedCard", gX), c.component("AVBasicSteps", AX), c.component("AVSteps", yX), c.component("AVOptionSelect", EX), c.component("AVOptionCheckbox", DX), c.component("AVTransitionSlide", RX), c.component("AVCollapser", qX), c.component("AVLinkVisualizer", WX), c.component("AVVerticalStep", o11), c.component("AVAnimatedMenuButton", f11), c.component("AVProgressBar", p11), c.component("AVWaitingDots", M11), c.component("AVRadioGroup", A11), c.component("AVNavigationItemList", x11), c.component("AVBreadcrumb", V11), c.component("AVElectionCard", G11), c.component("AVBallotStyleCard", a21), c.component("AVSummaryOption", m21), c.component("AVOption", w21), c.component("AVBlankOption", R21), c.component("AVWriteInOption", Q21), c.component("AVSubmissionHelper", i31), c.component("AVSearchBallot", C31), c.component("AVSplitWeightHelper", k31), c.component("AVSplitWizardHeader", H31), c.component("AVElectaContestCard", D31), c.component("AVResultOption", J31), c.component("AVFooter", Y31), c.component("AVSidebar", e41), c.component("AVNavbar", s41), c.component("AVContent", u41), c.component("AVModal", p41), c.component("AVBallot", A41), c.component("AVPileSummary", D41), c.component("AVSplitHelper", f01), c.component("AVResourceSection", w01), c.component("AVCalculateResultContent", J01), c.component("AVNormalSummary", Y01), c.component("AVRankedSummary", n61), c.component("AVInstantRunoffSummary", M61), c.component("OneColumnLayout", A61), c.component("TwoColumnsLayout", k61), c.component("NoSidebarLayout", E61), c.component("ElectionDashboardLayout", D61), c.provide("i18n", e || In), c.provide("iconNames", PJ);
31224
+ e === void 0 && (e = null), c.use(DG), c.component("AVIcon", xQ), c.component("AVButton", kQ), c.component("AVSpinner", VQ), c.component("AVBullet", T6), c.component("AVTextInput", FQ), c.component("AVNumberInput", GQ), c.component("AVPasswordInput", aY), c.component("AVDatetimeInput", uY), c.component("AVTextArea", gY), c.component("AVCard", AY), c.component("AVRoundButton", xY), c.component("AVLabel", vY), c.component("AVDropdown", IY), c.component("AVDropdownContent", DY), c.component("AVDropdownItem", FY), c.component("AVAlert", WY), c.component("AVFileInput", AK), c.component("AVRadio", yK), c.component("AVLink", VK), c.component("AVNavbarItem", OK), c.component("AVSidebarItem", $K), c.component("AVTooltip", WK), c.component("AVMenuDropdown", QK), c.component("AVMenuDropdownContent", XK), c.component("AVMenuDropdownItem", lX), c.component("AVAsyncButton", nX), c.component("AVTabSwitcher", fX), c.component("AVBallotSummary", zX), c.component("AVTimedCard", gX), c.component("AVBasicSteps", AX), c.component("AVSteps", yX), c.component("AVOptionSelect", EX), c.component("AVOptionCheckbox", DX), c.component("AVTransitionSlide", RX), c.component("AVCollapser", qX), c.component("AVLinkVisualizer", WX), c.component("AVVerticalStep", o11), c.component("AVAnimatedMenuButton", f11), c.component("AVProgressBar", p11), c.component("AVWaitingDots", M11), c.component("AVRadioGroup", A11), c.component("AVNavigationItemList", x11), c.component("AVBreadcrumb", V11), c.component("AVElectionCard", G11), c.component("AVBallotStyleCard", a21), c.component("AVSummaryOption", m21), c.component("AVOption", w21), c.component("AVBlankOption", R21), c.component("AVWriteInOption", Q21), c.component("AVSubmissionHelper", i31), c.component("AVSearchBallot", C31), c.component("AVSplitWeightHelper", k31), c.component("AVSplitWizardHeader", H31), c.component("AVElectaContestCard", D31), c.component("AVResultOption", J31), c.component("AVFooter", Y31), c.component("AVSidebar", e41), c.component("AVNavbar", s41), c.component("AVContent", u41), c.component("AVModal", p41), c.component("AVBallot", A41), c.component("AVPileSummary", D41), c.component("AVSplitHelper", f01), c.component("AVResourceSection", w01), c.component("AVCalculateResultContent", J01), c.component("AVNormalSummary", Y01), c.component("AVRankedSummary", s61), c.component("AVInstantRunoffSummary", L61), c.component("OneColumnLayout", C61), c.component("TwoColumnsLayout", y61), c.component("NoSidebarLayout", w61), c.component("ElectionDashboardLayout", P61), c.provide("i18n", e || In), c.provide("iconNames", PJ);
31222
31225
  }
31223
31226
  };
31224
31227
  export {
@@ -31245,7 +31248,7 @@ export {
31245
31248
  AK as AVFileInput,
31246
31249
  Y31 as AVFooter,
31247
31250
  xQ as AVIcon,
31248
- M61 as AVInstantRunoffSummary,
31251
+ L61 as AVInstantRunoffSummary,
31249
31252
  vY as AVLabel,
31250
31253
  VK as AVLink,
31251
31254
  WX as AVLinkVisualizer,
@@ -31266,7 +31269,7 @@ export {
31266
31269
  p11 as AVProgressBar,
31267
31270
  yK as AVRadio,
31268
31271
  A11 as AVRadioGroup,
31269
- n61 as AVRankedSummary,
31272
+ s61 as AVRankedSummary,
31270
31273
  w01 as AVResourceSection,
31271
31274
  J31 as AVResultOption,
31272
31275
  xY as AVRoundButton,
@@ -31288,10 +31291,10 @@ export {
31288
31291
  RX as AVTransitionSlide,
31289
31292
  M11 as AVWaitingDots,
31290
31293
  Q21 as AVWriteInOption,
31291
- D61 as ElectionDashboardLayout,
31292
- E61 as NoSidebarLayout,
31293
- A61 as OneColumnLayout,
31294
- k61 as TwoColumnsLayout,
31295
- F61 as default,
31294
+ P61 as ElectionDashboardLayout,
31295
+ w61 as NoSidebarLayout,
31296
+ C61 as OneColumnLayout,
31297
+ y61 as TwoColumnsLayout,
31298
+ R61 as default,
31296
31299
  PJ as iconNames
31297
31300
  };