@shlinkio/shlink-frontend-kit 0.8.13 → 0.9.1

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/index.css CHANGED
@@ -1 +1 @@
1
- @media (max-width: 991px){.responsive-table__header{display:none}}@media (max-width: 991px){.responsive-table.table>:not(:first-child){border:none}}@media (max-width: 991px){.responsive-table__row{display:block;border-bottom:1px solid var(--border-color);border-top:2px solid var(--border-color);position:relative}.responsive-table__row:not(:last-child){margin-bottom:10px}}.responsive-table__cell.responsive-table__cell{vertical-align:middle!important}@media (max-width: 991px){.responsive-table__cell.responsive-table__cell{display:block;width:100%;position:relative;padding:.5rem;font-size:.9rem}.responsive-table__cell.responsive-table__cell[data-th]:before{content:attr(data-th) ": ";font-weight:700}.responsive-table__cell.responsive-table__cell:last-child{position:absolute;top:3.5px;right:.5rem;width:auto;padding:0;border:none}}@media (max-width: 991px){.responsive-table__cell.responsive-table__cell .btn-sm{padding:.1rem .4rem;margin-top:.16rem}}html:not([data-theme=dark]){--color-scheme: initial;--primary-color: #ffffff;--primary-color-alfa: rgba(255, 255, 255, .5);--secondary-color: #f5f6fe;--text-color: #232323;--border-color: rgba(0, 0, 0, .125);--active-color: #eeeeee;--brand-color: #4696e5;--input-color: #ffffff;--input-disabled-color: #f5f6fe;--input-border-color: rgba(0, 0, 0, .19);--input-text-color: #495057;--table-border-color: #dee2e6;--table-highlight-color: rgba(0, 0, 0, .075);--btn-close-filter: initial}html[data-theme=dark]{--color-scheme: dark;--primary-color: #161b22;--primary-color-alfa: rgba(22, 27, 34, .8);--secondary-color: #0f131a;--text-color: rgb(201, 209, 217);--border-color: rgba(255, 255, 255, .15);--active-color: #0f131a;--brand-color: #0b2d4e;--input-color: rgb(17.9928571429, 22.0821428571, 27.8071428571);--input-disabled-color: rgb(26.0071428571, 31.9178571429, 40.1928571429);--input-border-color: rgba(255, 255, 255, .15);--input-text-color: rgb(201, 209, 217);--table-border-color: #393d43;--table-highlight-color: rgba(255, 255, 255, .15);--btn-close-filter: invert(1)}:root{scroll-behavior:auto;color-scheme:var(--color-scheme)}html,body,#root{height:100%;background:var(--secondary-color);color:var(--text-color)}a,.btn-link{text-decoration:none}a:not(.nav-link):not(.navbar-brand):not(.page-link):not(.highlight-card):not(.btn):not(.dropdown-item):hover,.btn-link:hover{text-decoration:underline}.bg-main{background-color:#4696e5!important}.bg-warning{color:#232323}.card-body,.card-header,.list-group-item{background-color:transparent}.card-footer{background-color:var(--primary-color-alfa)}.card.card{box-shadow:0 .125rem .25rem #00000013;background-color:var(--primary-color);border-color:var(--border-color)}.list-group,.modal-content,.page-link,.page-item.disabled .page-link,.dropdown-menu{background-color:var(--primary-color)}.modal-header.modal-header,.modal-footer.modal-footer,.card-header.card-header,.card-footer.card-footer,.table.table thead th,.table.table th,.table.table td,.page-link.page-link,.page-link.page-link:hover,.page-item.page-item.disabled .page-link.page-link,.dropdown-divider.dropdown-divider,.dropdown-menu.dropdown-menu,.list-group-item.list-group-item,.modal-content.modal-content,hr{border-color:var(--border-color)}.table-bordered,.table-bordered thead th,.table-bordered thead td{border-color:var(--table-border-color)}.page-link:hover,.page-link:focus{background-color:var(--secondary-color)}.page-item.active .page-link{background-color:var(--brand-color);border-color:var(--brand-color)}.pagination .page-link{cursor:pointer}@media (min-width: 1200px){.container-xl{max-width:1320px}}@media (max-width: 767px){.container-xl{padding-right:0;padding-left:0}}.btn-block{display:block;width:100%}.btn-primary,.btn-primary:hover,.btn-primary:disabled,.btn-primary:active,.btn-primary:focus-visible,.btn-primary.active,.btn-outline-primary:hover,.btn-outline-primary:active.btn-outline-primary:active,.btn-outline-primary:focus-visible.btn-outline-primary:focus-visible,.btn-outline-primary.active.btn-outline-primary.active{color:#fff}.dropdown-item,.dropdown-item-text{color:var(--text-color)}.dropdown-item:not(:disabled){cursor:pointer}.dropdown-item:focus:not(:disabled),.dropdown-item:hover:not(:disabled),.dropdown-item.active:not(:disabled),.dropdown-item:active:not(:disabled){background-color:var(--active-color)!important;color:var(--text-color)!important}.dropdown-item--danger.dropdown-item--danger{color:#dc3545}.dropdown-item--danger.dropdown-item--danger:hover,.dropdown-item--danger.dropdown-item--danger:active,.dropdown-item--danger.dropdown-item--danger.active{color:#dc3545!important}.badge-main{color:#fff;background-color:var(--brand-color)}.close,.close:hover,.table,.table-hover>tbody>tr:hover>*,.table-hover>tbody>tr>*{color:var(--text-color)}.btn-close{filter:var(--btn-close-filter)}.table-hover tbody tr:hover{background-color:var(--secondary-color)}.form-control.form-control,.form-control.form-control:focus,.form-select.form-select,.form-select.form-select:focus{background-color:var(--primary-color);border-color:var(--input-border-color);color:var(--input-text-color)}.form-control.disabled,.form-control:disabled,.form-select.disabled,.form-select:disabled{background-color:var(--input-disabled-color);cursor:not-allowed}.card .form-control:not(:disabled),.card .form-control:not(:disabled):hover,.card .form-select:not(:disabled),.card .form-select:not(:disabled):hover,.modal .form-control:not(:disabled),.modal .form-control:not(:disabled):hover,.modal .form-select:not(:disabled),.modal .form-select:not(:disabled):hover{background-color:var(--input-color)}.card input[type=text]:not(:disabled),.dropdown input[type=text]:not(:disabled){background-color:var(--input-color)!important}.card input[type=date]:not(:disabled),.dropdown input[type=date]:not(:disabled){background-color:var(--input-color)!important}.card input[type=datetime-local]:not(:disabled),.dropdown input[type=datetime-local]:not(:disabled){background-color:var(--input-color)!important}.card input[type=password]:not(:disabled),.dropdown input[type=password]:not(:disabled){background-color:var(--input-color)!important}.card input[type=number]:not(:disabled),.dropdown input[type=number]:not(:disabled){background-color:var(--input-color)!important}.card input[type=email]:not(:disabled),.dropdown input[type=email]:not(:disabled){background-color:var(--input-color)!important}.card input[type=search]:not(:disabled),.dropdown input[type=search]:not(:disabled){background-color:var(--input-color)!important}.card input[type=url]:not(:disabled),.dropdown input[type=url]:not(:disabled){background-color:var(--input-color)!important}.input-group-text.input-group-text{border-color:var(--input-border-color)}.dropdown label{color:var(--text-color)!important}.table-active,.table-active>th,.table-active>td{background-color:var(--table-highlight-color)!important}@media (max-width: 767px){.navbar-brand{margin:0 auto!important}}.indivisible{white-space:nowrap}.pointer{cursor:pointer}.progress-bar{background-color:#4696e5}@media (max-width: 575px){.btn-xs-block{width:100%;display:block}}@media (max-width: 991px){.btn-md-block{width:100%;display:block}}@media (max-width: 767px){.btn-sm-block{width:100%;display:block}}.search-field{position:relative}.search-field:focus-within{z-index:1}.search-field__input.search-field__input{padding-left:40px;padding-right:40px}.search-field__input--no-border.search-field__input--no-border{border:none;border-radius:0}.search-field__icon{position:absolute;top:50%;transform:translateY(-50%);left:15px;color:#6c757d}.search-field__close{position:absolute;top:50%;transform:translateY(-50%);right:10px;cursor:pointer}.dropdown-btn__toggle.dropdown-btn__toggle{text-align:left}.dropdown-btn__toggle.dropdown-btn__toggle--with-caret{padding-right:1.75rem}.dropdown-btn__toggle.dropdown-btn__toggle,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled).active,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):active,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):focus,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):hover,.show>.dropdown-btn__toggle.dropdown-btn__toggle.dropdown-toggle{color:var(--input-text-color);background-color:var(--primary-color);border-color:var(--input-border-color)}.card .dropdown-btn__toggle.dropdown-btn__toggle,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled).active,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):active,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):focus,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):hover,.show>.card .dropdown-btn__toggle.dropdown-btn__toggle.dropdown-toggle{background-color:var(--input-color)}.dropdown-btn__toggle.dropdown-btn__toggle.disabled,.dropdown-btn__toggle.dropdown-btn__toggle:disabled{background-color:var(--input-disabled-color)}.dropdown-btn__toggle.dropdown-btn__toggle:after{position:absolute;top:50%;transform:translateY(-50%);right:.75rem}.nav-pills__nav{position:sticky!important;top:55px;z-index:2}.nav-pills__nav-link.nav-pills__nav-link{border-radius:0!important;padding-bottom:calc(.5rem - 3px)!important;border-bottom:3px solid transparent!important;color:#5d6778;font-weight:700;cursor:pointer;text-decoration:none}@media (min-width: 576px) and (max-width: 991px){.nav-pills__nav-link.nav-pills__nav-link{font-size:89%}}.nav-pills__nav-link:hover{color:#4696e5!important}.nav-pills__nav-link.active{border-color:#4696e5!important;background-color:var(--primary-color)!important;color:#4696e5!important}
1
+ @media (max-width: 991px){.responsive-table__header{display:none}}@media (max-width: 991px){.responsive-table.table>:not(:first-child){border:none}}@media (max-width: 991px){.responsive-table__row{display:block;border-bottom:1px solid var(--border-color);border-top:2px solid var(--border-color);position:relative}.responsive-table__row:not(:last-child){margin-bottom:10px}}.responsive-table__cell.responsive-table__cell{vertical-align:middle!important}@media (max-width: 991px){.responsive-table__cell.responsive-table__cell{display:block;width:100%;position:relative;padding:.5rem;font-size:.9rem}.responsive-table__cell.responsive-table__cell[data-th]:before{content:attr(data-th) ": ";font-weight:700}.responsive-table__cell.responsive-table__cell:last-child{position:absolute;top:3.5px;right:.5rem;width:auto;padding:0;border:none}}@media (max-width: 991px){.responsive-table__cell.responsive-table__cell .btn-sm{padding:.1rem .4rem;margin-top:.16rem}}:root{scroll-behavior:auto;color-scheme:var(--color-scheme)}html,body,#root{height:100%;background:var(--secondary-color);color:var(--text-color)}a,.btn-link{text-decoration:none}a:not(.nav-link):not(.navbar-brand):not(.page-link):not(.highlight-card):not(.btn):not(.dropdown-item):hover,.btn-link:hover{text-decoration:underline}.bg-main{background-color:#4696e5!important}.bg-warning{color:var(--tw-color-lm-text)}.card-body,.card-header,.list-group-item{background-color:transparent}.card-footer{background-color:var(--primary-color-alfa)}.card.card{box-shadow:0 .125rem .25rem #00000013;background-color:var(--primary-color);border-color:var(--border-color)}.list-group,.modal-content,.page-link,.page-item.disabled .page-link,.dropdown-menu{background-color:var(--primary-color)}.modal-header.modal-header,.modal-footer.modal-footer,.card-header.card-header,.card-footer.card-footer,.table.table thead th,.table.table th,.table.table td,.page-link.page-link,.page-link.page-link:hover,.page-item.page-item.disabled .page-link.page-link,.dropdown-divider.dropdown-divider,.dropdown-menu.dropdown-menu,.list-group-item.list-group-item,.modal-content.modal-content,hr{border-color:var(--border-color)}.table-bordered,.table-bordered thead th,.table-bordered thead td{border-color:var(--table-border-color)}.page-link:hover,.page-link:focus{background-color:var(--secondary-color)}.page-item.active .page-link{background-color:var(--brand-color);border-color:var(--brand-color)}.pagination .page-link{cursor:pointer}@media (min-width: 1200px){.container-xl{max-width:1320px}}@media (max-width: 767px){.container-xl{padding-right:0;padding-left:0}}.btn-block{display:block;width:100%}.btn-primary,.btn-primary:hover,.btn-primary:disabled,.btn-primary:active,.btn-primary:focus-visible,.btn-primary.active,.btn-outline-primary:hover,.btn-outline-primary:active.btn-outline-primary:active,.btn-outline-primary:focus-visible.btn-outline-primary:focus-visible,.btn-outline-primary.active.btn-outline-primary.active{color:#fff}.dropdown-item,.dropdown-item-text{color:var(--text-color)}.dropdown-item:not(:disabled){cursor:pointer}.dropdown-item:focus:not(:disabled),.dropdown-item:hover:not(:disabled),.dropdown-item.active:not(:disabled),.dropdown-item:active:not(:disabled){background-color:var(--active-color)!important;color:var(--text-color)!important}.dropdown-item--danger.dropdown-item--danger{color:#dc3545}.dropdown-item--danger.dropdown-item--danger:hover,.dropdown-item--danger.dropdown-item--danger:active,.dropdown-item--danger.dropdown-item--danger.active{color:#dc3545!important}.badge-main{color:#fff;background-color:var(--brand-color)}.close,.close:hover,.table,.table-hover>tbody>tr:hover>*,.table-hover>tbody>tr>*{color:var(--text-color)}.btn-close{filter:var(--btn-close-filter)}.table-hover tbody tr:hover{background-color:var(--secondary-color)}.form-control.form-control,.form-control.form-control:focus,.form-select.form-select,.form-select.form-select:focus{background-color:var(--primary-color);border-color:var(--input-border-color);color:var(--input-text-color)}.form-control.disabled,.form-control:disabled,.form-select.disabled,.form-select:disabled{background-color:var(--input-disabled-color);cursor:not-allowed}.card .form-control:not(:disabled),.card .form-control:not(:disabled):hover,.card .form-select:not(:disabled),.card .form-select:not(:disabled):hover,.modal .form-control:not(:disabled),.modal .form-control:not(:disabled):hover,.modal .form-select:not(:disabled),.modal .form-select:not(:disabled):hover{background-color:var(--input-color)}.card input[type=text]:not(:disabled),.dropdown input[type=text]:not(:disabled){background-color:var(--input-color)!important}.card input[type=date]:not(:disabled),.dropdown input[type=date]:not(:disabled){background-color:var(--input-color)!important}.card input[type=datetime-local]:not(:disabled),.dropdown input[type=datetime-local]:not(:disabled){background-color:var(--input-color)!important}.card input[type=password]:not(:disabled),.dropdown input[type=password]:not(:disabled){background-color:var(--input-color)!important}.card input[type=number]:not(:disabled),.dropdown input[type=number]:not(:disabled){background-color:var(--input-color)!important}.card input[type=email]:not(:disabled),.dropdown input[type=email]:not(:disabled){background-color:var(--input-color)!important}.card input[type=search]:not(:disabled),.dropdown input[type=search]:not(:disabled){background-color:var(--input-color)!important}.card input[type=url]:not(:disabled),.dropdown input[type=url]:not(:disabled){background-color:var(--input-color)!important}.input-group-text.input-group-text{border-color:var(--input-border-color)}.dropdown label{color:var(--text-color)!important}.table-active,.table-active>th,.table-active>td{background-color:var(--table-highlight-color)!important}@media (max-width: 767px){.navbar-brand{margin:0 auto!important}}.indivisible{white-space:nowrap}.pointer{cursor:pointer}.progress-bar{background-color:#4696e5}@media (max-width: 575px){.btn-xs-block{width:100%;display:block}}@media (max-width: 991px){.btn-md-block{width:100%;display:block}}@media (max-width: 767px){.btn-sm-block{width:100%;display:block}}.search-field{position:relative}.search-field:focus-within{z-index:1}.search-field__input.search-field__input{padding-left:40px;padding-right:40px}.search-field__input--no-border.search-field__input--no-border{border:none;border-radius:0}.search-field__icon{position:absolute;top:50%;transform:translateY(-50%);left:15px;color:#6c757d}.search-field__close{position:absolute;top:50%;transform:translateY(-50%);right:10px;cursor:pointer}.dropdown-btn__toggle.dropdown-btn__toggle{text-align:left}.dropdown-btn__toggle.dropdown-btn__toggle--with-caret{padding-right:1.75rem}.dropdown-btn__toggle.dropdown-btn__toggle,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled).active,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):active,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):focus,.dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):hover,.show>.dropdown-btn__toggle.dropdown-btn__toggle.dropdown-toggle{color:var(--input-text-color);background-color:var(--primary-color);border-color:var(--input-border-color)}.card .dropdown-btn__toggle.dropdown-btn__toggle,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled).active,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):active,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):focus,.card .dropdown-btn__toggle.dropdown-btn__toggle:not(:disabled):not(.disabled):hover,.show>.card .dropdown-btn__toggle.dropdown-btn__toggle.dropdown-toggle{background-color:var(--input-color)}.dropdown-btn__toggle.dropdown-btn__toggle.disabled,.dropdown-btn__toggle.dropdown-btn__toggle:disabled{background-color:var(--input-disabled-color)}.dropdown-btn__toggle.dropdown-btn__toggle:after{position:absolute;top:50%;transform:translateY(-50%);right:.75rem}.nav-pills__nav{position:sticky!important;top:55px;z-index:2}.nav-pills__nav-link.nav-pills__nav-link{border-radius:0!important;padding-bottom:calc(.5rem - 3px)!important;border-bottom:3px solid transparent!important;color:#5d6778;font-weight:700;cursor:pointer;text-decoration:none}@media (min-width: 576px) and (max-width: 991px){.nav-pills__nav-link.nav-pills__nav-link{font-size:89%}}.nav-pills__nav-link:hover{color:#4696e5!important}.nav-pills__nav-link.active{border-color:#4696e5!important;background-color:var(--primary-color)!important;color:#4696e5!important}
package/dist/index.js CHANGED
@@ -1,13 +1,14 @@
1
- import { jsx as s, jsxs as u, Fragment as f } from "react/jsx-runtime";
2
- import { faCircleNotch as E, faSearch as P, faEllipsisV as F, faSortAmountUp as H, faSortAmountDown as M } from "@fortawesome/free-solid-svg-icons";
1
+ import { jsx as s, jsxs as i, Fragment as f } from "react/jsx-runtime";
2
+ import { faCircleNotch as A, faSearch as E, faEllipsisV as P, faSortAmountUp as F, faSortAmountDown as H } from "@fortawesome/free-solid-svg-icons";
3
3
  import { FontAwesomeIcon as b } from "@fortawesome/react-fontawesome";
4
4
  import { clsx as h } from "clsx";
5
- import { Card as N, CardHeader as $, CardBody as G, Dropdown as k, DropdownToggle as O, DropdownMenu as S, NavItem as j, NavLink as U, Nav as V, DropdownItem as w } from "reactstrap";
6
- import { useId as y, useState as g, useRef as x, useCallback as C, useMemo as q, Children as Q, isValidElement as Y, useEffect as W } from "react";
5
+ import { Card as w, CardHeader as M, CardBody as $, Dropdown as v, DropdownToggle as k, DropdownMenu as S, NavItem as G, NavLink as j, Nav as U, DropdownItem as g } from "reactstrap";
6
+ import { useId as x, useState as N, useRef as q, useCallback as T, useMemo as Q, Children as V, isValidElement as Y, useEffect as W } from "react";
7
7
  import { useNavigate as z, useLocation as J, NavLink as X } from "react-router";
8
- import { u as Z, a as L } from "./use-toggle-PWLikLl6.js";
9
- const be = ({ className: e, children: r, loading: t = !1, type: n = "default", fullWidth: o = !1 }) => /* @__PURE__ */ s(
10
- N,
8
+ import { u as y } from "./use-toggle-C1uZwbSD.js";
9
+ import { a as je, b as Ue } from "./use-toggle-C1uZwbSD.js";
10
+ const fe = ({ className: e, children: r, loading: t = !1, type: n = "default", fullWidth: o = !1 }) => /* @__PURE__ */ s(
11
+ w,
11
12
  {
12
13
  body: !0,
13
14
  className: h(e, {
@@ -15,7 +16,7 @@ const be = ({ className: e, children: r, loading: t = !1, type: n = "default", f
15
16
  "w-75 mx-auto": !o,
16
17
  "border-danger": n === "error"
17
18
  }),
18
- children: /* @__PURE__ */ u(
19
+ children: /* @__PURE__ */ i(
19
20
  "h3",
20
21
  {
21
22
  className: h("text-center mb-0", {
@@ -23,18 +24,18 @@ const be = ({ className: e, children: r, loading: t = !1, type: n = "default", f
23
24
  "text-danger": n === "error"
24
25
  }),
25
26
  children: [
26
- t && /* @__PURE__ */ s(b, { icon: E, spin: !0 }),
27
+ t && /* @__PURE__ */ s(b, { icon: A, spin: !0 }),
27
28
  t && /* @__PURE__ */ s("span", { className: "ms-2", children: r ?? "Loading..." }),
28
29
  !t && r
29
30
  ]
30
31
  }
31
32
  )
32
33
  }
33
- ), B = ({ title: e, children: r, bodyClassName: t, ...n }) => /* @__PURE__ */ u(N, { ...n, children: [
34
- e && /* @__PURE__ */ s($, { role: "heading", "aria-level": 4, children: e }),
35
- /* @__PURE__ */ s(G, { className: t, children: r })
36
- ] }), ge = ({ children: e, type: r, className: t, small: n = !1 }) => /* @__PURE__ */ s(
37
- B,
34
+ ), Z = ({ title: e, children: r, bodyClassName: t, ...n }) => /* @__PURE__ */ i(w, { ...n, children: [
35
+ e && /* @__PURE__ */ s(M, { role: "heading", "aria-level": 4, children: e }),
36
+ /* @__PURE__ */ s($, { className: t, children: r })
37
+ ] }), pe = ({ children: e, type: r, className: t, small: n = !1 }) => /* @__PURE__ */ s(
38
+ Z,
38
39
  {
39
40
  role: "document",
40
41
  className: h("text-center", {
@@ -48,27 +49,27 @@ const be = ({ className: e, children: r, loading: t = !1, type: n = "default", f
48
49
  bodyClassName: h({ "p-2": n }),
49
50
  children: e
50
51
  }
51
- ), D = ({ checked: e = !1, onChange: r, className: t, children: n, type: o, inline: c = !1 }) => {
52
- const l = y(), m = (d) => r == null ? void 0 : r(d.target.checked, d), i = {
52
+ ), L = ({ checked: e = !1, onChange: r, className: t, children: n, type: o, inline: c = !1 }) => {
53
+ const l = x(), u = (m) => r == null ? void 0 : r(m.target.checked, m), d = {
53
54
  "form-switch": o === "switch",
54
55
  "form-checkbox": o === "checkbox"
55
56
  }, a = c ? { display: "inline-block" } : {};
56
- return /* @__PURE__ */ u("span", { className: h("form-check", i, t), style: a, children: [
57
- /* @__PURE__ */ s("input", { type: "checkbox", className: "form-check-input", id: l, checked: e, onChange: m }),
57
+ return /* @__PURE__ */ i("span", { className: h("form-check", d, t), style: a, children: [
58
+ /* @__PURE__ */ s("input", { type: "checkbox", className: "form-check-input", id: l, checked: e, onChange: u }),
58
59
  /* @__PURE__ */ s("label", { className: "form-check-label", htmlFor: l, children: n })
59
60
  ] });
60
- }, we = (e) => /* @__PURE__ */ s(D, { type: "checkbox", ...e }), Ne = (e) => /* @__PURE__ */ s(D, { type: "switch", ...e }), K = ({ children: e, label: r, className: t = "", labelClassName: n = "", noMargin: o = !1, id: c }) => /* @__PURE__ */ u("div", { className: `${t} ${o ? "" : "mb-3"}`, children: [
61
+ }, be = (e) => /* @__PURE__ */ s(L, { type: "checkbox", ...e }), ge = (e) => /* @__PURE__ */ s(L, { type: "switch", ...e }), B = ({ children: e, label: r, className: t = "", labelClassName: n = "", noMargin: o = !1, id: c }) => /* @__PURE__ */ i("div", { className: `${t} ${o ? "" : "mb-3"}`, children: [
61
62
  /* @__PURE__ */ s("label", { className: `form-label ${n}`, htmlFor: c, children: r }),
62
63
  e
63
- ] }), Ce = ({ children: e, value: r, onChange: t, type: n, required: o, placeholder: c, className: l, labelClassName: m }) => {
64
- const i = y();
65
- return /* @__PURE__ */ s(K, { label: /* @__PURE__ */ u(f, { children: [
64
+ ] }), we = ({ children: e, value: r, onChange: t, type: n, required: o, placeholder: c, className: l, labelClassName: u }) => {
65
+ const d = x();
66
+ return /* @__PURE__ */ s(B, { label: /* @__PURE__ */ i(f, { children: [
66
67
  e,
67
68
  ":"
68
- ] }), className: l, labelClassName: m, id: i, children: /* @__PURE__ */ s(
69
+ ] }), className: l, labelClassName: u, id: d, children: /* @__PURE__ */ s(
69
70
  "input",
70
71
  {
71
- id: i,
72
+ id: d,
72
73
  className: "form-control",
73
74
  type: n ?? "text",
74
75
  value: r,
@@ -77,17 +78,17 @@ const be = ({ className: e, children: r, loading: t = !1, type: n = "default", f
77
78
  onChange: (a) => t(a.target.value)
78
79
  }
79
80
  ) });
80
- }, ee = 500;
81
+ }, K = 500;
81
82
  let p;
82
- const v = () => {
83
+ const O = () => {
83
84
  p !== null && clearTimeout(p), p = null;
84
- }, _e = ({ onChange: e, className: r, large: t = !0, noBorder: n = !1, initialValue: o = "", setTimeout_: c = setTimeout }) => {
85
- const [l, m] = g(o), i = (a, d = ee) => {
86
- m(a), v(), p = c(() => {
87
- e(a), v();
88
- }, d);
85
+ }, Ne = ({ onChange: e, className: r, large: t = !0, noBorder: n = !1, initialValue: o = "", setTimeout_: c = setTimeout }) => {
86
+ const [l, u] = N(o), d = (a, m = K) => {
87
+ u(a), O(), p = c(() => {
88
+ e(a), O();
89
+ }, m);
89
90
  };
90
- return /* @__PURE__ */ u("div", { className: h("search-field", r), children: [
91
+ return /* @__PURE__ */ i("div", { className: h("search-field", r), children: [
91
92
  /* @__PURE__ */ s(
92
93
  "input",
93
94
  {
@@ -98,10 +99,10 @@ const v = () => {
98
99
  }),
99
100
  placeholder: "Search...",
100
101
  value: l,
101
- onChange: (a) => i(a.target.value)
102
+ onChange: (a) => d(a.target.value)
102
103
  }
103
104
  ),
104
- /* @__PURE__ */ s(b, { icon: P, className: "search-field__icon" }),
105
+ /* @__PURE__ */ s(b, { icon: E, className: "search-field__icon" }),
105
106
  /* @__PURE__ */ s(
106
107
  "button",
107
108
  {
@@ -110,14 +111,14 @@ const v = () => {
110
111
  className: "close search-field__close btn-close",
111
112
  hidden: l === "",
112
113
  id: "search-field__close",
113
- onClick: () => i("", 0)
114
+ onClick: () => d("", 0)
114
115
  }
115
116
  )
116
117
  ] });
117
- }, Te = () => x(null), ve = () => {
118
+ }, Ce = () => q(null), _e = () => {
118
119
  const e = z();
119
- return C(() => e(-1), [e]);
120
- }, re = (e) => {
120
+ return T(() => e(-1), [e]);
121
+ }, ee = (e) => {
121
122
  const r = new URLSearchParams(e), t = {};
122
123
  return r.forEach((n, o) => {
123
124
  if (o.endsWith("[]")) {
@@ -126,23 +127,15 @@ const v = () => {
126
127
  } else
127
128
  t[o] = n;
128
129
  }), t;
129
- }, ke = (e) => {
130
+ }, Oe = (e) => {
130
131
  const r = new URLSearchParams();
131
132
  for (const [t, n] of Object.entries(e))
132
133
  n !== void 0 && (Array.isArray(n) ? n.forEach((o) => r.append(`${t}[]`, `${o}`)) : r.append(t, `${n}`));
133
134
  return r.toString();
134
- }, Oe = () => {
135
+ }, ve = () => {
135
136
  const { search: e } = J();
136
- return q(() => re(e), [e]);
137
- }, te = 2e3, Se = (e = {}, r, t = globalThis.setTimeout, n = globalThis.clearTimeout) => {
138
- const { initialValue: o = !1, delay: c = te } = typeof e == "boolean" ? {
139
- initialValue: e,
140
- delay: r
141
- } : e, { setTimeout: l } = Z(c, t, n), [m, i] = g(o), a = x(o), d = C(() => {
142
- i(!a.current), l(() => i(a.current));
143
- }, [l]);
144
- return [m, d];
145
- }, ne = ({
137
+ return Q(() => ee(e), [e]);
138
+ }, re = ({
146
139
  text: e,
147
140
  disabled: r = !1,
148
141
  className: t,
@@ -150,23 +143,23 @@ const v = () => {
150
143
  dropdownClassName: o,
151
144
  noCaret: c,
152
145
  end: l = !1,
153
- minWidth: m,
154
- inline: i,
146
+ minWidth: u,
147
+ inline: d,
155
148
  size: a,
156
- ...d
149
+ ...m
157
150
  }) => {
158
- const [T, I] = L(), R = h("dropdown-btn__toggle", t, {
159
- "btn-block": !i,
151
+ const [_, I] = y(), D = h("dropdown-btn__toggle", t, {
152
+ "btn-block": !d,
160
153
  "dropdown-btn__toggle--with-caret": !c
161
- }), A = { minWidth: m && `${m}px` };
162
- return /* @__PURE__ */ u(k, { isOpen: T, toggle: I, disabled: r, className: o, children: [
163
- /* @__PURE__ */ s(O, { size: a, caret: !c, className: R, color: "primary", ...d, children: e }),
164
- /* @__PURE__ */ s(S, { className: "w-100", end: l, style: A, children: T && n })
154
+ }), R = { minWidth: u && `${u}px` };
155
+ return /* @__PURE__ */ i(v, { isOpen: _, toggle: I, disabled: r, className: o, children: [
156
+ /* @__PURE__ */ s(k, { size: a, caret: !c, className: D, color: "primary", ...m, children: e }),
157
+ /* @__PURE__ */ s(S, { className: "w-100", end: l, style: R, children: _ && n })
165
158
  ] });
166
- }, ye = ({ children: e, minWidth: r, label: t = "Options" }) => /* @__PURE__ */ s(
167
- ne,
159
+ }, ke = ({ children: e, minWidth: r, label: t = "Options" }) => /* @__PURE__ */ s(
160
+ re,
168
161
  {
169
- text: /* @__PURE__ */ s(b, { className: "px-1", icon: F }),
162
+ text: /* @__PURE__ */ s(b, { className: "px-1", icon: P }),
170
163
  "aria-label": t,
171
164
  size: "sm",
172
165
  minWidth: r,
@@ -175,41 +168,41 @@ const v = () => {
175
168
  inline: !0,
176
169
  children: e
177
170
  }
178
- ), se = ({ children: e, ...r }) => /* @__PURE__ */ s(j, { children: /* @__PURE__ */ s(U, { className: "nav-pills__nav-link", tag: X, ...r, children: e }) }), xe = ({ children: e, fill: r = !1, className: t = "" }) => /* @__PURE__ */ s(N, { className: `nav-pills__nav p-0 overflow-hidden ${t}`, body: !0, children: /* @__PURE__ */ s(V, { pills: !0, fill: r, children: Q.map(e, (n) => {
179
- if (!Y(n) || n.type !== se)
171
+ ), te = ({ children: e, ...r }) => /* @__PURE__ */ s(G, { children: /* @__PURE__ */ s(j, { className: "nav-pills__nav-link", tag: X, ...r, children: e }) }), Se = ({ children: e, fill: r = !1, className: t = "" }) => /* @__PURE__ */ s(w, { className: `nav-pills__nav p-0 overflow-hidden ${t}`, body: !0, children: /* @__PURE__ */ s(U, { pills: !0, fill: r, children: V.map(e, (n) => {
172
+ if (!Y(n) || n.type !== te)
180
173
  throw new Error("Only NavPillItem children are allowed inside NavPills.");
181
174
  return n;
182
175
  }) }) });
183
- function _(e, r, t) {
184
- return typeof e == "object" ? _(e.currentField, e.newField, e.currentOrderDir) : e !== r ? "ASC" : t ? {
176
+ function C(e, r, t) {
177
+ return typeof e == "object" ? C(e.currentField, e.newField, e.currentOrderDir) : e !== r ? "ASC" : t ? {
185
178
  ASC: "DESC",
186
179
  DESC: void 0
187
180
  }[t] : "ASC";
188
181
  }
189
- function oe(e, r, t) {
190
- return typeof e == "object" ? oe(e.currentField, e.newField, e.currentOrderDir) : {
182
+ function ne(e, r, t) {
183
+ return typeof e == "object" ? ne(e.currentField, e.newField, e.currentOrderDir) : {
191
184
  field: r,
192
- dir: _(e, r, t)
185
+ dir: C(e, r, t)
193
186
  };
194
187
  }
195
- const Le = (e, { field: r, dir: t }) => !r || !t ? e : e.sort((n, o) => {
188
+ const xe = (e, { field: r, dir: t }) => !r || !t ? e : e.sort((n, o) => {
196
189
  const c = t === "ASC" ? 1 : -1, l = t === "ASC" ? -1 : 1;
197
190
  return n[r] > o[r] ? c : l;
198
- }), De = (e) => e.dir ? `${e.field}-${e.dir}` : void 0, Ie = (e) => {
191
+ }), Te = (e) => e.dir ? `${e.field}-${e.dir}` : void 0, ye = (e) => {
199
192
  const [r, t] = e.split("-");
200
193
  return { field: r, dir: t };
201
- }, Re = (e) => {
202
- const [r, t] = g(e), n = C((o, c) => t({ field: o, dir: c }), []);
194
+ }, Le = (e) => {
195
+ const [r, t] = N(e), n = T((o, c) => t({ field: o, dir: c }), []);
203
196
  return [r, n];
204
197
  };
205
- function Ae({ items: e, order: r, onChange: t, isButton: n = !0, right: o = !1, prefixed: c = !0 }) {
206
- const [l, m] = L(), i = (a) => () => {
207
- const d = _(a, r.field, r.dir);
208
- t(d ? a : void 0, d);
198
+ function Ie({ items: e, order: r, onChange: t, isButton: n = !0, right: o = !1, prefixed: c = !0 }) {
199
+ const [l, u] = y(), d = (a) => () => {
200
+ const m = C(a, r.field, r.dir);
201
+ t(m ? a : void 0, m);
209
202
  };
210
- return /* @__PURE__ */ u(k, { isOpen: l, toggle: m, children: [
211
- /* @__PURE__ */ u(
212
- O,
203
+ return /* @__PURE__ */ i(v, { isOpen: l, toggle: u, children: [
204
+ /* @__PURE__ */ i(
205
+ k,
213
206
  {
214
207
  caret: !0,
215
208
  color: n ? "primary" : "link",
@@ -220,7 +213,7 @@ function Ae({ items: e, order: r, onChange: t, isButton: n = !0, right: o = !1,
220
213
  children: [
221
214
  !n && /* @__PURE__ */ s(f, { children: "Order by" }),
222
215
  n && !r.field && /* @__PURE__ */ s("i", { children: "Order by..." }),
223
- n && r.field && /* @__PURE__ */ u(f, { children: [
216
+ n && r.field && /* @__PURE__ */ i(f, { children: [
224
217
  c && "Order by: ",
225
218
  e[r.field],
226
219
  " - ",
@@ -229,74 +222,74 @@ function Ae({ items: e, order: r, onChange: t, isButton: n = !0, right: o = !1,
229
222
  ]
230
223
  }
231
224
  ),
232
- /* @__PURE__ */ s(S, { end: o, className: "w-100", style: n ? void 0 : { minWidth: "11rem" }, children: l && /* @__PURE__ */ u(f, { children: [
233
- Object.entries(e).map(([a, d]) => /* @__PURE__ */ u(
234
- w,
225
+ /* @__PURE__ */ s(S, { end: o, className: "w-100", style: n ? void 0 : { minWidth: "11rem" }, children: l && /* @__PURE__ */ i(f, { children: [
226
+ Object.entries(e).map(([a, m]) => /* @__PURE__ */ i(
227
+ g,
235
228
  {
236
229
  active: r.field === a,
237
- onClick: i(a),
230
+ onClick: d(a),
238
231
  className: "d-flex justify-content-between align-items-center",
239
232
  tabIndex: -1,
240
233
  children: [
241
- d,
242
- r.field === a && /* @__PURE__ */ s(b, { icon: r.dir === "ASC" ? H : M })
234
+ m,
235
+ r.field === a && /* @__PURE__ */ s(b, { icon: r.dir === "ASC" ? F : H })
243
236
  ]
244
237
  },
245
238
  a
246
239
  )),
247
- /* @__PURE__ */ s(w, { divider: !0, tag: "hr" }),
248
- /* @__PURE__ */ s(w, { disabled: !r.field, onClick: () => t(), tabIndex: -1, children: /* @__PURE__ */ s("i", { children: "Clear selection" }) })
240
+ /* @__PURE__ */ s(g, { divider: !0, tag: "hr" }),
241
+ /* @__PURE__ */ s(g, { disabled: !r.field, onClick: () => t(), tabIndex: -1, children: /* @__PURE__ */ s("i", { children: "Clear selection" }) })
249
242
  ] }) })
250
243
  ] });
251
244
  }
252
- const Ee = "#4696e5", Pe = "rgba(70, 150, 229, 0.4)", Fe = "#f77f28", He = "rgba(247, 127, 40, 0.4)", Me = "white", $e = "#161b22", ce = (e) => {
245
+ const De = "#4696e5", Re = "rgba(70, 150, 229, 0.4)", Ae = "#f77f28", Ee = "rgba(247, 127, 40, 0.4)", Pe = "white", Fe = "#161b22", se = (e) => {
253
246
  var r;
254
247
  return (r = document.querySelector("html")) == null ? void 0 : r.setAttribute("data-theme", e);
255
- }, Ge = () => {
248
+ }, He = () => {
256
249
  var e;
257
250
  return ((e = document.querySelector("html")) == null ? void 0 : e.getAttribute("data-theme")) === "dark";
258
- }, ae = (e = window.matchMedia.bind(window)) => e("(prefers-color-scheme: dark)").matches ? "dark" : "light", je = (e) => {
259
- const [r, t] = g(() => e ?? ae());
251
+ }, oe = (e = window.matchMedia.bind(window)) => e("(prefers-color-scheme: dark)").matches ? "dark" : "light", Me = (e) => {
252
+ const [r, t] = N(() => e ?? oe());
260
253
  return W(() => {
261
- ce(r);
254
+ se(r);
262
255
  }, [r]), [r, t];
263
256
  };
264
257
  export {
265
- we as Checkbox,
266
- ne as DropdownBtn,
267
- Fe as HIGHLIGHTED_COLOR,
268
- He as HIGHLIGHTED_COLOR_ALPHA,
269
- Ce as InputFormGroup,
270
- K as LabeledFormGroup,
271
- Ee as MAIN_COLOR,
272
- Pe as MAIN_COLOR_ALPHA,
273
- be as Message,
274
- se as NavPillItem,
275
- xe as NavPills,
276
- Ae as OrderingDropdown,
277
- $e as PRIMARY_DARK_COLOR,
278
- Me as PRIMARY_LIGHT_COLOR,
279
- ge as Result,
280
- ye as RowDropdownBtn,
281
- _e as SearchField,
282
- B as SimpleCard,
283
- Ne as ToggleSwitch,
284
- ce as changeThemeInMarkup,
285
- oe as determineOrder,
286
- _ as determineOrderDir,
287
- ae as getSystemPreferredTheme,
288
- Ge as isDarkThemeEnabled,
289
- De as orderToString,
290
- re as parseQueryString,
291
- Le as sortList,
292
- Ie as stringToOrder,
293
- ke as stringifyQueryParams,
294
- Te as useElementRef,
295
- ve as useGoBack,
296
- Re as useOrder,
297
- Oe as useParsedQuery,
298
- je as useTheme,
299
- Z as useTimeout,
300
- Se as useTimeoutToggle,
301
- L as useToggle
258
+ be as Checkbox,
259
+ re as DropdownBtn,
260
+ Ae as HIGHLIGHTED_COLOR,
261
+ Ee as HIGHLIGHTED_COLOR_ALPHA,
262
+ we as InputFormGroup,
263
+ B as LabeledFormGroup,
264
+ De as MAIN_COLOR,
265
+ Re as MAIN_COLOR_ALPHA,
266
+ fe as Message,
267
+ te as NavPillItem,
268
+ Se as NavPills,
269
+ Ie as OrderingDropdown,
270
+ Fe as PRIMARY_DARK_COLOR,
271
+ Pe as PRIMARY_LIGHT_COLOR,
272
+ pe as Result,
273
+ ke as RowDropdownBtn,
274
+ Ne as SearchField,
275
+ Z as SimpleCard,
276
+ ge as ToggleSwitch,
277
+ se as changeThemeInMarkup,
278
+ ne as determineOrder,
279
+ C as determineOrderDir,
280
+ oe as getSystemPreferredTheme,
281
+ He as isDarkThemeEnabled,
282
+ Te as orderToString,
283
+ ee as parseQueryString,
284
+ xe as sortList,
285
+ ye as stringToOrder,
286
+ Oe as stringifyQueryParams,
287
+ Ce as useElementRef,
288
+ _e as useGoBack,
289
+ Le as useOrder,
290
+ ve as useParsedQuery,
291
+ Me as useTheme,
292
+ je as useTimeout,
293
+ Ue as useTimeoutToggle,
294
+ y as useToggle
302
295
  };
@@ -74,7 +74,20 @@ export declare type CloseButtonProps = {
74
74
 
75
75
  declare type CommonCardModalProps = {
76
76
  /** Modal header title */
77
- title: string;
77
+ title: RequiredReactNode;
78
+ };
79
+
80
+ export declare const CopyToClipboardButton: FC<CopyToClipboardButtonProps>;
81
+
82
+ export declare type CopyToClipboardButtonProps = Omit<HTMLProps<HTMLButtonElement>, 'type' | 'onClick' | 'size'> & {
83
+ /** Text to be copied when the button is clicked */
84
+ text: string;
85
+ /** Size of the button. Defaults to `lg` */
86
+ size?: Size;
87
+ /** Test seam */
88
+ initialCopied?: boolean;
89
+ /** Test seam */
90
+ navigator_?: typeof globalThis.navigator;
78
91
  };
79
92
 
80
93
  declare type CoverCardModalProps = CommonCardModalProps & {