@peasant-labs/fairtrade 0.0.61 → 0.0.63
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/lib/{adapter-BSfSbqWE.js → adapter-ChziRV1K.js} +25 -20
- package/dist/lib/commons.js +202 -202
- package/dist/lib/components.css +1 -1
- package/dist/lib/share.js +4 -4
- package/dist/lib/types/TranscriptLibraryTable.d.ts +208 -0
- package/dist/lib/types/groupPageRows.d.ts +56 -0
- package/dist/lib/types/index.d.ts +7 -0
- package/dist/lib/types/table/align-class.d.ts +6 -0
- package/dist/lib/types/table/column-align.d.ts +44 -0
- package/dist/lib/types/table/library-pickers.d.ts +50 -0
- package/dist/lib/types/transcript/Scrubber.d.ts +16 -2
- package/dist/lib/types/transcript/TranscriptBoundary.d.ts +20 -0
- package/dist/lib/types/transcript/TranscriptViewer.d.ts +1 -1
- package/dist/lib/types/transcript/action-groups.d.ts +5 -1
- package/dist/lib/types/transcript/adapter.d.ts +16 -0
- package/dist/lib/types/transcript/index.d.ts +15 -1
- package/dist/lib/types/transcript/segments.d.ts +146 -0
- package/dist/lib/types/transcript/state-capabilities.d.ts +24 -0
- package/dist/lib/types/transcript/view-model.d.ts +12 -0
- package/dist/lib/types/transcript/wire-types.d.ts +12 -0
- package/dist/lib/types/ui/transcript/adapter.d.ts +16 -0
- package/dist/lib/types/ui/transcript/view-model.d.ts +12 -0
- package/dist/lib/types/ui/transcript/wire-types.d.ts +12 -0
- package/dist/lib/{ui-DoP5-XrV.js → ui-B89Zfh7B.js} +5482 -4408
- package/dist/lib/ui.js +6 -6
- package/package.json +7 -5
package/dist/lib/commons.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Dt as e, Tt as t, ft as n, mt as r, pt as i } from "./GraphLegend-e9x79JtU.js";
|
|
2
|
-
import {
|
|
2
|
+
import { Cr as a, It as o, Lt as s, Pt as c, Rr as l, Rt as u, Tt as d, U as f, Vt as p, W as ee, bn as m, br as h, bt as g, gn as _, gr as v, sr as y, vn as b, vt as x, wt as S, xr as C, xt as w, yn as T, zt as E } from "./ui-B89Zfh7B.js";
|
|
3
3
|
import { p as D } from "./time-CpVBzcqQ.js";
|
|
4
4
|
import { i as O, o as k, r as A } from "./format-B3uT2wzU.js";
|
|
5
5
|
import { useEffect as j, useId as te, useMemo as M, useRef as N, useState as P } from "react";
|
|
@@ -337,16 +337,16 @@ function Le({ collective: e, href: t, onOpen: n }) {
|
|
|
337
337
|
children: r
|
|
338
338
|
});
|
|
339
339
|
}
|
|
340
|
-
function Re({ data: e, className: n = "", title: i = "explore transcripts", resultsFooter: a, defaultLayout: o = "grid", onFiltersChange: s, onOpenTranscript:
|
|
341
|
-
let _ = g
|
|
340
|
+
function Re({ data: e, className: n = "", title: i = "explore transcripts", resultsFooter: a, defaultLayout: o = "grid", onFiltersChange: s, onOpenTranscript: c, onOpenProfile: l, onOpenCollective: u, transcriptHref: d, profileHref: m, collectiveHref: h, headingLevel: g }) {
|
|
341
|
+
let _ = ee(g, "Explore"), v = f(_, 0), y = f(_, 1), b = f(_, 2), S = Ne(e), C = S.transcripts.transcripts, [w, T] = P(""), [D, O] = P(""), [k, A] = P("recent"), [F, ne] = P("all"), [R, re] = P(() => /* @__PURE__ */ new Set()), [z, ie] = P(o), [oe, se] = P(!1), B = te(), [V, H] = P(() => Pe(S.transcripts.page)), [U, W] = P(null), [le, G] = P("browse"), K = N(!0), q = N(null);
|
|
342
342
|
j(() => {
|
|
343
343
|
if (K.current) {
|
|
344
|
-
K.current = !1, O(
|
|
344
|
+
K.current = !1, O(w);
|
|
345
345
|
return;
|
|
346
346
|
}
|
|
347
|
-
let e = setTimeout(() => O(
|
|
347
|
+
let e = setTimeout(() => O(w), 250);
|
|
348
348
|
return () => clearTimeout(e);
|
|
349
|
-
}, [K,
|
|
349
|
+
}, [K, w]), j(() => {
|
|
350
350
|
let e = JSON.stringify([
|
|
351
351
|
D,
|
|
352
352
|
k,
|
|
@@ -401,19 +401,19 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
401
401
|
t.linkedGithubOrg
|
|
402
402
|
].filter(Boolean).join(" ").toLowerCase().includes(e)) : null;
|
|
403
403
|
}, [S.collectives, D]), Z = C, ve = R.size, Q = S.transcripts.total ?? C.length, ye = V, be = S.transcripts.limit || C.length || 1, xe = (e) => {
|
|
404
|
-
if (
|
|
405
|
-
|
|
404
|
+
if (c) {
|
|
405
|
+
c(e);
|
|
406
406
|
return;
|
|
407
407
|
}
|
|
408
408
|
W(e.id), G("detail");
|
|
409
409
|
}, Se = () => {
|
|
410
|
-
if (
|
|
411
|
-
|
|
410
|
+
if (l && Y) {
|
|
411
|
+
l(Y);
|
|
412
412
|
return;
|
|
413
413
|
}
|
|
414
414
|
J ? (W(J.id), G("profile")) : C[0] && (W(C[0].id), G("profile"));
|
|
415
415
|
}, Ce = () => {
|
|
416
|
-
|
|
416
|
+
T(""), O(""), A("recent"), ne("all"), re(/* @__PURE__ */ new Set()), H(1);
|
|
417
417
|
}, we = M(() => Y ? [...je(X, (e) => e.projectName || "untitled project").entries()].map(([e, t]) => ({
|
|
418
418
|
project: e,
|
|
419
419
|
items: t
|
|
@@ -589,7 +589,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
589
589
|
})]
|
|
590
590
|
})]
|
|
591
591
|
}),
|
|
592
|
-
/* @__PURE__ */ I(
|
|
592
|
+
/* @__PURE__ */ I(E, { tiles: [
|
|
593
593
|
{
|
|
594
594
|
key: "transcripts",
|
|
595
595
|
label: "transcripts",
|
|
@@ -665,7 +665,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
665
665
|
})]
|
|
666
666
|
})]
|
|
667
667
|
}),
|
|
668
|
-
/* @__PURE__ */ I(
|
|
668
|
+
/* @__PURE__ */ I(E, { tiles: [
|
|
669
669
|
{
|
|
670
670
|
key: "transcripts",
|
|
671
671
|
label: "transcripts",
|
|
@@ -725,7 +725,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
725
725
|
className: "cex-lib-rows",
|
|
726
726
|
children: t.map((e) => /* @__PURE__ */ I(Ie, {
|
|
727
727
|
transcript: e,
|
|
728
|
-
href:
|
|
728
|
+
href: d?.(e),
|
|
729
729
|
onOpen: xe
|
|
730
730
|
}, e.id))
|
|
731
731
|
})]
|
|
@@ -747,16 +747,16 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
747
747
|
/* @__PURE__ */ I("input", {
|
|
748
748
|
className: "input",
|
|
749
749
|
type: "text",
|
|
750
|
-
value:
|
|
751
|
-
onChange: (e) =>
|
|
750
|
+
value: w,
|
|
751
|
+
onChange: (e) => T(e.target.value),
|
|
752
752
|
placeholder: "search transcripts",
|
|
753
753
|
"aria-label": "search transcripts, collectives, projects, models"
|
|
754
754
|
}),
|
|
755
|
-
|
|
755
|
+
w && /* @__PURE__ */ I("button", {
|
|
756
756
|
type: "button",
|
|
757
757
|
className: "cex-clear",
|
|
758
758
|
"aria-label": "clear search",
|
|
759
|
-
onClick: () =>
|
|
759
|
+
onClick: () => T(""),
|
|
760
760
|
children: /* @__PURE__ */ I(pe, {
|
|
761
761
|
size: 14,
|
|
762
762
|
"aria-hidden": "true"
|
|
@@ -788,7 +788,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
788
788
|
/* @__PURE__ */ I("div", {
|
|
789
789
|
id: B,
|
|
790
790
|
className: `cex-filter-panel${oe ? " is-open" : ""}`,
|
|
791
|
-
children: /* @__PURE__ */ I(
|
|
791
|
+
children: /* @__PURE__ */ I(p, {
|
|
792
792
|
order: k,
|
|
793
793
|
onOrder: (e) => A(e),
|
|
794
794
|
providers: me,
|
|
@@ -831,8 +831,8 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
831
831
|
className: "cex-coll-grid",
|
|
832
832
|
children: ge.map((e) => /* @__PURE__ */ I(Le, {
|
|
833
833
|
collective: e,
|
|
834
|
-
href:
|
|
835
|
-
onOpen:
|
|
834
|
+
href: h?.(e),
|
|
835
|
+
onOpen: u
|
|
836
836
|
}, e.id))
|
|
837
837
|
})]
|
|
838
838
|
}),
|
|
@@ -903,7 +903,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
903
903
|
className: "cex-grid",
|
|
904
904
|
children: Z.map((e) => /* @__PURE__ */ I(Fe, {
|
|
905
905
|
transcript: e,
|
|
906
|
-
href:
|
|
906
|
+
href: d?.(e),
|
|
907
907
|
onOpen: xe,
|
|
908
908
|
cardHeading: y
|
|
909
909
|
}, e.id))
|
|
@@ -911,7 +911,7 @@ function Re({ data: e, className: n = "", title: i = "explore transcripts", resu
|
|
|
911
911
|
className: "cex-list",
|
|
912
912
|
children: Z.map((e) => /* @__PURE__ */ I(Ie, {
|
|
913
913
|
transcript: e,
|
|
914
|
-
href:
|
|
914
|
+
href: d?.(e),
|
|
915
915
|
onOpen: xe
|
|
916
916
|
}, e.id))
|
|
917
917
|
}),
|
|
@@ -1546,7 +1546,7 @@ function Je() {
|
|
|
1546
1546
|
})]
|
|
1547
1547
|
})
|
|
1548
1548
|
]
|
|
1549
|
-
}), /* @__PURE__ */ I(
|
|
1549
|
+
}), /* @__PURE__ */ I(m, {
|
|
1550
1550
|
open: i,
|
|
1551
1551
|
title: /* @__PURE__ */ L(F, { children: [
|
|
1552
1552
|
"make ",
|
|
@@ -1668,7 +1668,7 @@ function et(e, t, n) {
|
|
|
1668
1668
|
}, e));
|
|
1669
1669
|
}
|
|
1670
1670
|
function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
1671
|
-
let { collectives: n = [], linkedOrgs: r = [], title: i = "collectives", deck:
|
|
1671
|
+
let { collectives: n = [], linkedOrgs: r = [], title: i = "collectives", deck: o, crumb: s, caption: c = "collectives", createLabel: u = "new collective", createBusy: d = !1, whoCanPublish: f = Ye, whoCanRead: p = Xe } = e, { onCreateCollective: ee, onOpenCollective: m, onSearchCollectives: h } = t, [g, _] = P(!1), [v, b] = P(""), [x, S] = P(""), [C, w] = P(f[0]?.value ?? ""), [E, D] = P(p[0]?.value ?? ""), [O, A] = P(""), [j, M] = P(""), N = te(), F = [
|
|
1672
1672
|
{
|
|
1673
1673
|
key: "name",
|
|
1674
1674
|
label: "name",
|
|
@@ -1729,7 +1729,7 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1729
1729
|
children: [
|
|
1730
1730
|
s ? /* @__PURE__ */ I("div", {
|
|
1731
1731
|
className: "cmg-crumb",
|
|
1732
|
-
children: /* @__PURE__ */ I(
|
|
1732
|
+
children: /* @__PURE__ */ I(a, { items: [{ label: s }] })
|
|
1733
1733
|
}) : null,
|
|
1734
1734
|
/* @__PURE__ */ L("header", {
|
|
1735
1735
|
className: "iu-page-head",
|
|
@@ -1740,24 +1740,24 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1740
1740
|
children: i
|
|
1741
1741
|
}), /* @__PURE__ */ L("button", {
|
|
1742
1742
|
type: "button",
|
|
1743
|
-
className: "btn btn-sm " + (
|
|
1744
|
-
"aria-expanded":
|
|
1745
|
-
onClick: () =>
|
|
1743
|
+
className: "btn btn-sm " + (g ? "btn-secondary" : "btn-primary"),
|
|
1744
|
+
"aria-expanded": g,
|
|
1745
|
+
onClick: () => _((e) => !e),
|
|
1746
1746
|
children: [
|
|
1747
1747
|
/* @__PURE__ */ I(Y, {
|
|
1748
1748
|
size: 14,
|
|
1749
1749
|
"aria-hidden": "true"
|
|
1750
1750
|
}),
|
|
1751
1751
|
" ",
|
|
1752
|
-
|
|
1752
|
+
g ? "close" : u
|
|
1753
1753
|
]
|
|
1754
1754
|
})]
|
|
1755
|
-
}),
|
|
1755
|
+
}), o ? /* @__PURE__ */ I("p", {
|
|
1756
1756
|
className: "iu-page-sub",
|
|
1757
|
-
children:
|
|
1757
|
+
children: o
|
|
1758
1758
|
}) : null]
|
|
1759
1759
|
}),
|
|
1760
|
-
|
|
1760
|
+
g && /* @__PURE__ */ L("section", {
|
|
1761
1761
|
className: "cmg-form card",
|
|
1762
1762
|
"aria-labelledby": `${N}-form`,
|
|
1763
1763
|
children: [
|
|
@@ -1777,8 +1777,8 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1777
1777
|
}), /* @__PURE__ */ I("input", {
|
|
1778
1778
|
className: "input",
|
|
1779
1779
|
type: "text",
|
|
1780
|
-
value:
|
|
1781
|
-
onChange: (e) =>
|
|
1780
|
+
value: v,
|
|
1781
|
+
onChange: (e) => b(e.target.value)
|
|
1782
1782
|
})]
|
|
1783
1783
|
}),
|
|
1784
1784
|
/* @__PURE__ */ L("label", {
|
|
@@ -1789,19 +1789,19 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1789
1789
|
}), /* @__PURE__ */ I("textarea", {
|
|
1790
1790
|
className: "input",
|
|
1791
1791
|
rows: 2,
|
|
1792
|
-
value:
|
|
1793
|
-
onChange: (e) =>
|
|
1792
|
+
value: x,
|
|
1793
|
+
onChange: (e) => S(e.target.value)
|
|
1794
1794
|
})]
|
|
1795
1795
|
}),
|
|
1796
1796
|
/* @__PURE__ */ I("div", {
|
|
1797
1797
|
className: "cmg-field",
|
|
1798
|
-
children: /* @__PURE__ */ I(
|
|
1798
|
+
children: /* @__PURE__ */ I(T, {
|
|
1799
1799
|
variant: "select",
|
|
1800
1800
|
label: "who can publish",
|
|
1801
1801
|
name: "who-can-publish",
|
|
1802
|
-
value:
|
|
1803
|
-
onChange:
|
|
1804
|
-
options:
|
|
1802
|
+
value: C,
|
|
1803
|
+
onChange: w,
|
|
1804
|
+
options: f.map((e) => ({
|
|
1805
1805
|
...e,
|
|
1806
1806
|
rationale: e.help
|
|
1807
1807
|
}))
|
|
@@ -1809,7 +1809,7 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1809
1809
|
}),
|
|
1810
1810
|
/* @__PURE__ */ I("div", {
|
|
1811
1811
|
className: "cmg-field",
|
|
1812
|
-
children: /* @__PURE__ */ I(
|
|
1812
|
+
children: /* @__PURE__ */ I(T, {
|
|
1813
1813
|
variant: "select",
|
|
1814
1814
|
label: "who can read",
|
|
1815
1815
|
name: "who-can-read",
|
|
@@ -1846,27 +1846,27 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1846
1846
|
children: [/* @__PURE__ */ I("button", {
|
|
1847
1847
|
type: "button",
|
|
1848
1848
|
className: "btn btn-sm btn-primary",
|
|
1849
|
-
disabled: !
|
|
1849
|
+
disabled: !v.trim() || d,
|
|
1850
1850
|
"aria-describedby": N,
|
|
1851
1851
|
onClick: () => ee?.({
|
|
1852
|
-
name:
|
|
1853
|
-
purpose:
|
|
1854
|
-
mode:
|
|
1852
|
+
name: v,
|
|
1853
|
+
purpose: x,
|
|
1854
|
+
mode: C,
|
|
1855
1855
|
access: E,
|
|
1856
1856
|
org: O
|
|
1857
1857
|
}),
|
|
1858
|
-
children:
|
|
1858
|
+
children: d ? "creating" : "create collective"
|
|
1859
1859
|
}), /* @__PURE__ */ I("span", {
|
|
1860
1860
|
id: N,
|
|
1861
1861
|
className: "cmg-form-hint mono",
|
|
1862
|
-
children:
|
|
1862
|
+
children: f.find((e) => e.value === C)?.help
|
|
1863
1863
|
})]
|
|
1864
1864
|
})
|
|
1865
1865
|
]
|
|
1866
1866
|
}),
|
|
1867
1867
|
/* @__PURE__ */ L("div", {
|
|
1868
1868
|
className: "cmg-section",
|
|
1869
|
-
children: [/* @__PURE__ */ I(
|
|
1869
|
+
children: [/* @__PURE__ */ I(y, {
|
|
1870
1870
|
caption: `${c} ${n.length}`,
|
|
1871
1871
|
columns: F,
|
|
1872
1872
|
rows: n,
|
|
@@ -1876,7 +1876,7 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1876
1876
|
children: "in a curated collective, each transcript you publish waits for the owner to approve it."
|
|
1877
1877
|
}) : null]
|
|
1878
1878
|
}),
|
|
1879
|
-
|
|
1879
|
+
h && /* @__PURE__ */ L("section", {
|
|
1880
1880
|
className: "cmg-section",
|
|
1881
1881
|
"aria-labelledby": `${N}-find`,
|
|
1882
1882
|
children: [/* @__PURE__ */ I("h3", {
|
|
@@ -1887,9 +1887,9 @@ function tt({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1887
1887
|
className: "cmg-find",
|
|
1888
1888
|
role: "search",
|
|
1889
1889
|
onSubmit: (e) => {
|
|
1890
|
-
e.preventDefault(),
|
|
1890
|
+
e.preventDefault(), h(j);
|
|
1891
1891
|
},
|
|
1892
|
-
children: [/* @__PURE__ */ I(
|
|
1892
|
+
children: [/* @__PURE__ */ I(l, {
|
|
1893
1893
|
label: "collective or github org",
|
|
1894
1894
|
type: "search",
|
|
1895
1895
|
iconLeft: fe,
|
|
@@ -1927,7 +1927,7 @@ function rt(e = {}) {
|
|
|
1927
1927
|
};
|
|
1928
1928
|
}
|
|
1929
1929
|
function it({ data: e = {}, actions: t = {} } = {}) {
|
|
1930
|
-
let { owners: r = [], linkedRepos: i = [], hrefFor:
|
|
1930
|
+
let { owners: r = [], linkedRepos: i = [], hrefFor: s } = e, l = rt(e.collective), { onSettings: u, onContribute: d, onReview: f, onOpenTranscript: p, onOpenPullRequest: ee, onLinkRepos: m, onShowMore: h } = t, [_, v] = P(!1), b = te(), x = l.transcriptCount ?? l.transcripts.length, S = [
|
|
1931
1931
|
{
|
|
1932
1932
|
key: "title",
|
|
1933
1933
|
label: "title",
|
|
@@ -1941,8 +1941,8 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1941
1941
|
className: "iu-session-text",
|
|
1942
1942
|
children: [/* @__PURE__ */ I($e, {
|
|
1943
1943
|
className: "iu-session-title",
|
|
1944
|
-
href:
|
|
1945
|
-
onOpen:
|
|
1944
|
+
href: s?.("transcript", t.id),
|
|
1945
|
+
onOpen: p ? () => p(t.id) : void 0,
|
|
1946
1946
|
children: t.title
|
|
1947
1947
|
}), /* @__PURE__ */ L("span", {
|
|
1948
1948
|
className: "iu-session-sub",
|
|
@@ -1971,8 +1971,8 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1971
1971
|
label: "pull requests",
|
|
1972
1972
|
render: (e, t) => t.pullRequests?.length ? /* @__PURE__ */ L("span", {
|
|
1973
1973
|
className: "cmg-prs",
|
|
1974
|
-
children: [/* @__PURE__ */ I(
|
|
1975
|
-
items: et(t.pullRequests,
|
|
1974
|
+
children: [/* @__PURE__ */ I(c, {
|
|
1975
|
+
items: et(t.pullRequests, ee, s),
|
|
1976
1976
|
label: "pull requests",
|
|
1977
1977
|
noun: ["pull request", "pull requests"]
|
|
1978
1978
|
}), t.repo && /* @__PURE__ */ I("span", {
|
|
@@ -1988,21 +1988,21 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
1988
1988
|
key: "when",
|
|
1989
1989
|
label: "when"
|
|
1990
1990
|
}
|
|
1991
|
-
],
|
|
1991
|
+
], w = [
|
|
1992
1992
|
{
|
|
1993
1993
|
key: "read",
|
|
1994
1994
|
title: "who can read",
|
|
1995
|
-
text:
|
|
1995
|
+
text: l.whoCanRead
|
|
1996
1996
|
},
|
|
1997
1997
|
{
|
|
1998
1998
|
key: "publish",
|
|
1999
1999
|
title: "who can publish",
|
|
2000
|
-
text:
|
|
2000
|
+
text: l.whoCanPublish
|
|
2001
2001
|
},
|
|
2002
2002
|
{
|
|
2003
2003
|
key: "role",
|
|
2004
2004
|
title: "your role",
|
|
2005
|
-
text:
|
|
2005
|
+
text: l.yourRole
|
|
2006
2006
|
}
|
|
2007
2007
|
].filter((e) => e.text);
|
|
2008
2008
|
return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ L("div", {
|
|
@@ -2010,10 +2010,10 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2010
2010
|
children: [
|
|
2011
2011
|
/* @__PURE__ */ I("div", {
|
|
2012
2012
|
className: "cmg-crumb-content",
|
|
2013
|
-
children: /* @__PURE__ */ I(
|
|
2013
|
+
children: /* @__PURE__ */ I(a, { items: [{
|
|
2014
2014
|
label: "collectives",
|
|
2015
|
-
href:
|
|
2016
|
-
}, { label:
|
|
2015
|
+
href: s?.("collectives")
|
|
2016
|
+
}, { label: l.name }] })
|
|
2017
2017
|
}),
|
|
2018
2018
|
/* @__PURE__ */ L("header", {
|
|
2019
2019
|
className: "iu-page-head",
|
|
@@ -2021,43 +2021,43 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2021
2021
|
className: "iu-page-titlerow",
|
|
2022
2022
|
children: [/* @__PURE__ */ I("h2", {
|
|
2023
2023
|
className: "iu-page-title iu-page-title-content",
|
|
2024
|
-
id:
|
|
2025
|
-
children:
|
|
2024
|
+
id: b,
|
|
2025
|
+
children: l.name
|
|
2026
2026
|
}), /* @__PURE__ */ L("span", {
|
|
2027
2027
|
className: "cmg-actions",
|
|
2028
|
-
children: [
|
|
2028
|
+
children: [l.role === "owner" && u && /* @__PURE__ */ L("button", {
|
|
2029
2029
|
type: "button",
|
|
2030
2030
|
className: "btn btn-secondary btn-sm",
|
|
2031
|
-
onClick: () =>
|
|
2031
|
+
onClick: () => u(),
|
|
2032
2032
|
children: [/* @__PURE__ */ I(X, {
|
|
2033
2033
|
size: 14,
|
|
2034
2034
|
"aria-hidden": "true"
|
|
2035
2035
|
}), " settings"]
|
|
2036
|
-
}), (
|
|
2036
|
+
}), (d || f) && /* @__PURE__ */ I(C, {
|
|
2037
2037
|
icon: J,
|
|
2038
2038
|
ariaLabel: "more",
|
|
2039
2039
|
size: "sm",
|
|
2040
2040
|
align: "end",
|
|
2041
|
-
items: [...
|
|
2041
|
+
items: [...d ? [{
|
|
2042
2042
|
label: "publish several transcripts",
|
|
2043
2043
|
icon: Z,
|
|
2044
|
-
onSelect: () =>
|
|
2045
|
-
}] : [], ...
|
|
2044
|
+
onSelect: () => d()
|
|
2045
|
+
}] : [], ...f ? [{
|
|
2046
2046
|
label: "review transcripts",
|
|
2047
2047
|
icon: ie,
|
|
2048
|
-
onSelect: () =>
|
|
2048
|
+
onSelect: () => f()
|
|
2049
2049
|
}] : []]
|
|
2050
2050
|
})]
|
|
2051
2051
|
})]
|
|
2052
|
-
}),
|
|
2052
|
+
}), l.purpose ? /* @__PURE__ */ I("p", {
|
|
2053
2053
|
className: "iu-page-sub",
|
|
2054
|
-
children:
|
|
2054
|
+
children: l.purpose
|
|
2055
2055
|
}) : null]
|
|
2056
2056
|
}),
|
|
2057
|
-
|
|
2057
|
+
w.length > 0 && /* @__PURE__ */ I("ul", {
|
|
2058
2058
|
className: "cmg-policies",
|
|
2059
2059
|
"aria-label": "how this collective works",
|
|
2060
|
-
children:
|
|
2060
|
+
children: w.map((e) => /* @__PURE__ */ L("li", {
|
|
2061
2061
|
className: "cmg-policy",
|
|
2062
2062
|
children: [/* @__PURE__ */ I("h3", {
|
|
2063
2063
|
className: "cmg-policy-title",
|
|
@@ -2068,18 +2068,18 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2068
2068
|
})]
|
|
2069
2069
|
}, e.key))
|
|
2070
2070
|
}),
|
|
2071
|
-
/* @__PURE__ */ I(
|
|
2072
|
-
items:
|
|
2073
|
-
label: `${
|
|
2071
|
+
/* @__PURE__ */ I(o, {
|
|
2072
|
+
items: l.stats,
|
|
2073
|
+
label: `${l.name} in numbers`
|
|
2074
2074
|
}),
|
|
2075
2075
|
/* @__PURE__ */ L("div", {
|
|
2076
2076
|
className: "cmg-home",
|
|
2077
2077
|
children: [/* @__PURE__ */ L("div", {
|
|
2078
2078
|
className: "cmg-home-main",
|
|
2079
|
-
children: [/* @__PURE__ */ I(
|
|
2080
|
-
caption: `transcripts ${
|
|
2081
|
-
columns:
|
|
2082
|
-
rows:
|
|
2079
|
+
children: [/* @__PURE__ */ I(y, {
|
|
2080
|
+
caption: `transcripts ${x}`,
|
|
2081
|
+
columns: S,
|
|
2082
|
+
rows: l.transcripts,
|
|
2083
2083
|
rowKey: (e) => e.id
|
|
2084
2084
|
}), /* @__PURE__ */ L("div", {
|
|
2085
2085
|
className: "iu-page-foot",
|
|
@@ -2089,15 +2089,15 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2089
2089
|
"showing ",
|
|
2090
2090
|
/* @__PURE__ */ I("span", {
|
|
2091
2091
|
className: "tnum",
|
|
2092
|
-
children:
|
|
2092
|
+
children: l.transcripts.length
|
|
2093
2093
|
}),
|
|
2094
2094
|
" of ",
|
|
2095
2095
|
/* @__PURE__ */ I("span", {
|
|
2096
2096
|
className: "tnum",
|
|
2097
|
-
children:
|
|
2097
|
+
children: x
|
|
2098
2098
|
})
|
|
2099
2099
|
]
|
|
2100
|
-
}),
|
|
2100
|
+
}), x > l.transcripts.length && h && /* @__PURE__ */ I("button", {
|
|
2101
2101
|
type: "button",
|
|
2102
2102
|
className: "btn btn-secondary btn-sm",
|
|
2103
2103
|
onClick: () => h(),
|
|
@@ -2112,36 +2112,36 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2112
2112
|
children: [/* @__PURE__ */ I("h3", {
|
|
2113
2113
|
className: "cmg-rail-title",
|
|
2114
2114
|
children: "github orgs"
|
|
2115
|
-
}),
|
|
2115
|
+
}), l.org ? /* @__PURE__ */ L("p", {
|
|
2116
2116
|
className: "cmg-rail-line",
|
|
2117
2117
|
children: [
|
|
2118
2118
|
/* @__PURE__ */ I(H, { "aria-hidden": "true" }),
|
|
2119
2119
|
" ",
|
|
2120
2120
|
/* @__PURE__ */ I("span", {
|
|
2121
2121
|
className: "mono",
|
|
2122
|
-
children:
|
|
2122
|
+
children: l.org.login
|
|
2123
2123
|
}),
|
|
2124
|
-
typeof
|
|
2124
|
+
typeof l.org.total == "number" ? /* @__PURE__ */ L(F, { children: [
|
|
2125
2125
|
", ",
|
|
2126
2126
|
/* @__PURE__ */ I("span", {
|
|
2127
2127
|
className: "tnum",
|
|
2128
|
-
children:
|
|
2128
|
+
children: l.org.linked ?? 0
|
|
2129
2129
|
}),
|
|
2130
2130
|
" of ",
|
|
2131
2131
|
/* @__PURE__ */ I("span", {
|
|
2132
2132
|
className: "tnum",
|
|
2133
|
-
children:
|
|
2133
|
+
children: l.org.total
|
|
2134
2134
|
}),
|
|
2135
2135
|
" repos linked"
|
|
2136
2136
|
] }) : null,
|
|
2137
|
-
|
|
2137
|
+
l.role === "owner" && m && /* @__PURE__ */ I("button", {
|
|
2138
2138
|
type: "button",
|
|
2139
2139
|
className: "btn btn-ghost btn-sm",
|
|
2140
|
-
onClick: () =>
|
|
2140
|
+
onClick: () => v(!0),
|
|
2141
2141
|
children: "manage"
|
|
2142
2142
|
})
|
|
2143
2143
|
]
|
|
2144
|
-
}) :
|
|
2144
|
+
}) : l.org === null ? /* @__PURE__ */ I("p", {
|
|
2145
2145
|
className: "cmg-rail-line cmg-none",
|
|
2146
2146
|
children: "nothing linked"
|
|
2147
2147
|
}) : null]
|
|
@@ -2150,33 +2150,33 @@ function it({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2150
2150
|
children: [
|
|
2151
2151
|
/* @__PURE__ */ L("h3", {
|
|
2152
2152
|
className: "cmg-rail-title",
|
|
2153
|
-
children: ["members", typeof
|
|
2153
|
+
children: ["members", typeof l.memberCount == "number" ? /* @__PURE__ */ L(F, { children: [" ", /* @__PURE__ */ I("span", {
|
|
2154
2154
|
className: "tnum cmg-count",
|
|
2155
|
-
children:
|
|
2155
|
+
children: l.memberCount
|
|
2156
2156
|
})] }) : null]
|
|
2157
2157
|
}),
|
|
2158
|
-
|
|
2158
|
+
l.memberBreakdown ? /* @__PURE__ */ I("p", {
|
|
2159
2159
|
className: "cmg-note",
|
|
2160
|
-
children:
|
|
2160
|
+
children: l.memberBreakdown
|
|
2161
2161
|
}) : null,
|
|
2162
2162
|
/* @__PURE__ */ I(nt, {
|
|
2163
|
-
members:
|
|
2164
|
-
count:
|
|
2163
|
+
members: l.members,
|
|
2164
|
+
count: l.memberCount ?? l.members.length
|
|
2165
2165
|
})
|
|
2166
2166
|
]
|
|
2167
2167
|
})]
|
|
2168
2168
|
})]
|
|
2169
2169
|
})
|
|
2170
2170
|
]
|
|
2171
|
-
}),
|
|
2172
|
-
open:
|
|
2173
|
-
onClose: () =>
|
|
2171
|
+
}), m && /* @__PURE__ */ I(g, {
|
|
2172
|
+
open: _,
|
|
2173
|
+
onClose: () => v(!1),
|
|
2174
2174
|
owners: r,
|
|
2175
2175
|
initialSelected: i,
|
|
2176
|
-
title: `link repositories from ${
|
|
2177
|
-
description: `pull requests in linked repos show the transcripts published to ${
|
|
2176
|
+
title: `link repositories from ${l.org?.login ?? "github"}`,
|
|
2177
|
+
description: `pull requests in linked repos show the transcripts published to ${l.name}.`,
|
|
2178
2178
|
onSave: (e) => {
|
|
2179
|
-
|
|
2179
|
+
m(e), v(!1);
|
|
2180
2180
|
}
|
|
2181
2181
|
})] });
|
|
2182
2182
|
}
|
|
@@ -2207,27 +2207,27 @@ var lt = {
|
|
|
2207
2207
|
"danger zone": ge
|
|
2208
2208
|
};
|
|
2209
2209
|
function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
2210
|
-
let { owners: n = [], linkedRepos: r = [], showOnPullRequests: i = !1, whoCanPublish:
|
|
2210
|
+
let { owners: n = [], linkedRepos: r = [], showOnPullRequests: i = !1, whoCanPublish: o = Ye, whoCanRead: s = Xe, memberLeavesChoices: c = at, hrefFor: u } = e, f = rt(e.collective), p = (e) => (n) => t.onCommit ? t.onCommit(e, n) : Promise.resolve(), [ee, m] = P(!1), [h, _] = P(""), y = !!(t.onTransferOwnership || t.onDelete), b = [
|
|
2211
2211
|
"general",
|
|
2212
2212
|
"access",
|
|
2213
2213
|
"members",
|
|
2214
2214
|
"github orgs",
|
|
2215
2215
|
"pull requests",
|
|
2216
|
-
...
|
|
2217
|
-
],
|
|
2216
|
+
...y ? ["danger zone"] : []
|
|
2217
|
+
], x = (e) => `cmg-settings-${e.replace(/ /g, "-")}`;
|
|
2218
2218
|
return /* @__PURE__ */ L(F, { children: [/* @__PURE__ */ L("div", {
|
|
2219
2219
|
className: "iu-page cmg-settings",
|
|
2220
2220
|
children: [
|
|
2221
2221
|
/* @__PURE__ */ I("div", {
|
|
2222
2222
|
className: "cmg-crumb-content",
|
|
2223
|
-
children: /* @__PURE__ */ I(
|
|
2223
|
+
children: /* @__PURE__ */ I(a, { items: [
|
|
2224
2224
|
{
|
|
2225
2225
|
label: "collectives",
|
|
2226
|
-
href:
|
|
2226
|
+
href: u?.("collectives")
|
|
2227
2227
|
},
|
|
2228
2228
|
{
|
|
2229
|
-
label:
|
|
2230
|
-
href:
|
|
2229
|
+
label: f.name,
|
|
2230
|
+
href: u?.("collective", f.id)
|
|
2231
2231
|
},
|
|
2232
2232
|
{ label: "settings" }
|
|
2233
2233
|
] })
|
|
@@ -2238,72 +2238,72 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2238
2238
|
className: "iu-page-title",
|
|
2239
2239
|
children: [/* @__PURE__ */ I("span", {
|
|
2240
2240
|
className: "iu-page-title-content",
|
|
2241
|
-
children:
|
|
2241
|
+
children: f.name
|
|
2242
2242
|
}), ", settings"]
|
|
2243
2243
|
})
|
|
2244
2244
|
}),
|
|
2245
|
-
/* @__PURE__ */ L(
|
|
2246
|
-
sections:
|
|
2247
|
-
id:
|
|
2245
|
+
/* @__PURE__ */ L(w, {
|
|
2246
|
+
sections: b.map((e) => ({
|
|
2247
|
+
id: x(e),
|
|
2248
2248
|
label: e,
|
|
2249
|
-
href: `#${
|
|
2249
|
+
href: `#${x(e)}`,
|
|
2250
2250
|
icon: lt[e]
|
|
2251
2251
|
})),
|
|
2252
|
-
currentId:
|
|
2252
|
+
currentId: x(b[0]),
|
|
2253
2253
|
spy: !0,
|
|
2254
2254
|
children: [
|
|
2255
|
-
/* @__PURE__ */ L(
|
|
2255
|
+
/* @__PURE__ */ L(S, {
|
|
2256
2256
|
label: "general",
|
|
2257
2257
|
defaultOpen: !0,
|
|
2258
|
-
id:
|
|
2259
|
-
children: [/* @__PURE__ */ I(
|
|
2258
|
+
id: x("general"),
|
|
2259
|
+
children: [/* @__PURE__ */ I(d, {
|
|
2260
2260
|
label: "name",
|
|
2261
2261
|
control: "text",
|
|
2262
|
-
value:
|
|
2263
|
-
onCommit:
|
|
2264
|
-
}), /* @__PURE__ */ I(
|
|
2262
|
+
value: f.name,
|
|
2263
|
+
onCommit: p("name")
|
|
2264
|
+
}), /* @__PURE__ */ I(d, {
|
|
2265
2265
|
label: "purpose",
|
|
2266
2266
|
control: "text",
|
|
2267
|
-
value:
|
|
2268
|
-
onCommit:
|
|
2267
|
+
value: f.purpose ?? "",
|
|
2268
|
+
onCommit: p("purpose")
|
|
2269
2269
|
})]
|
|
2270
2270
|
}),
|
|
2271
|
-
/* @__PURE__ */ L(
|
|
2271
|
+
/* @__PURE__ */ L(S, {
|
|
2272
2272
|
label: "access",
|
|
2273
2273
|
defaultOpen: !0,
|
|
2274
|
-
id:
|
|
2275
|
-
children: [/* @__PURE__ */ I(
|
|
2274
|
+
id: x("access"),
|
|
2275
|
+
children: [/* @__PURE__ */ I(d, {
|
|
2276
2276
|
label: "who can publish",
|
|
2277
|
-
help: ((e) => e.filter((e) => e.help).map((e) => `${e.label}: ${e.help}`).join(" "))(
|
|
2277
|
+
help: ((e) => e.filter((e) => e.help).map((e) => `${e.label}: ${e.help}`).join(" "))(o),
|
|
2278
2278
|
control: "select",
|
|
2279
|
-
value: st(
|
|
2280
|
-
options: ot(
|
|
2281
|
-
onCommit:
|
|
2282
|
-
}), /* @__PURE__ */ I(
|
|
2279
|
+
value: st(f.mode, o),
|
|
2280
|
+
options: ot(f.mode, o),
|
|
2281
|
+
onCommit: p("mode")
|
|
2282
|
+
}), /* @__PURE__ */ I(d, {
|
|
2283
2283
|
label: "who can read",
|
|
2284
2284
|
help: "members read and publish. contributors publish, and read only if who can read allows it.",
|
|
2285
2285
|
control: "select",
|
|
2286
|
-
value: st(
|
|
2287
|
-
options: ot(
|
|
2288
|
-
onCommit:
|
|
2286
|
+
value: st(f.access, s),
|
|
2287
|
+
options: ot(f.access, s),
|
|
2288
|
+
onCommit: p("access")
|
|
2289
2289
|
})]
|
|
2290
2290
|
}),
|
|
2291
|
-
/* @__PURE__ */ L(
|
|
2291
|
+
/* @__PURE__ */ L(S, {
|
|
2292
2292
|
label: "members",
|
|
2293
2293
|
defaultOpen: !0,
|
|
2294
|
-
count:
|
|
2294
|
+
count: f.memberCount ?? null,
|
|
2295
2295
|
noun: ["member", "members"],
|
|
2296
|
-
id:
|
|
2296
|
+
id: x("members"),
|
|
2297
2297
|
children: [
|
|
2298
2298
|
t.onInvite && /* @__PURE__ */ L("form", {
|
|
2299
2299
|
className: "srow cmg-invite",
|
|
2300
2300
|
onSubmit: (e) => {
|
|
2301
|
-
e.preventDefault(), t.onInvite(h),
|
|
2301
|
+
e.preventDefault(), t.onInvite(h), _("");
|
|
2302
2302
|
},
|
|
2303
|
-
children: [/* @__PURE__ */ I(
|
|
2303
|
+
children: [/* @__PURE__ */ I(l, {
|
|
2304
2304
|
label: "invite by github username",
|
|
2305
2305
|
value: h,
|
|
2306
|
-
onChange: (e) =>
|
|
2306
|
+
onChange: (e) => _(e.target.value),
|
|
2307
2307
|
placeholder: "github username"
|
|
2308
2308
|
}), /* @__PURE__ */ I("button", {
|
|
2309
2309
|
type: "submit",
|
|
@@ -2315,10 +2315,10 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2315
2315
|
/* @__PURE__ */ I("ul", {
|
|
2316
2316
|
className: "cmg-member-list",
|
|
2317
2317
|
"aria-label": "members",
|
|
2318
|
-
children:
|
|
2318
|
+
children: f.members.map((e) => /* @__PURE__ */ L("li", {
|
|
2319
2319
|
className: "cmg-member",
|
|
2320
2320
|
children: [
|
|
2321
|
-
/* @__PURE__ */ I(
|
|
2321
|
+
/* @__PURE__ */ I(v, {
|
|
2322
2322
|
name: e.name ?? e.handle,
|
|
2323
2323
|
size: "sm"
|
|
2324
2324
|
}),
|
|
@@ -2364,40 +2364,40 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2364
2364
|
]
|
|
2365
2365
|
}, e.handle))
|
|
2366
2366
|
}),
|
|
2367
|
-
/* @__PURE__ */ I(
|
|
2367
|
+
/* @__PURE__ */ I(d, {
|
|
2368
2368
|
label: "when a member leaves",
|
|
2369
2369
|
help: "what happens to the transcripts they published here.",
|
|
2370
2370
|
control: "select",
|
|
2371
|
-
value: st(
|
|
2372
|
-
options: ot(
|
|
2373
|
-
onCommit:
|
|
2371
|
+
value: st(f.memberLeaves, c),
|
|
2372
|
+
options: ot(f.memberLeaves, c),
|
|
2373
|
+
onCommit: p("memberLeaves")
|
|
2374
2374
|
})
|
|
2375
2375
|
]
|
|
2376
2376
|
}),
|
|
2377
|
-
/* @__PURE__ */ I(
|
|
2377
|
+
/* @__PURE__ */ I(S, {
|
|
2378
2378
|
label: "github orgs",
|
|
2379
2379
|
defaultOpen: !0,
|
|
2380
|
-
count:
|
|
2380
|
+
count: f.org === void 0 ? null : +!!f.org,
|
|
2381
2381
|
noun: ["org", "orgs"],
|
|
2382
|
-
id:
|
|
2382
|
+
id: x("github orgs"),
|
|
2383
2383
|
children: /* @__PURE__ */ L("div", {
|
|
2384
2384
|
className: "srow",
|
|
2385
2385
|
children: [/* @__PURE__ */ L("span", {
|
|
2386
2386
|
className: "srow-text-col",
|
|
2387
2387
|
children: [/* @__PURE__ */ I("span", {
|
|
2388
2388
|
className: "srow-label",
|
|
2389
|
-
children:
|
|
2389
|
+
children: f.org ? f.org.login : f.org === null ? "no org linked" : "github org"
|
|
2390
2390
|
}), /* @__PURE__ */ L("span", {
|
|
2391
2391
|
className: "srow-help",
|
|
2392
|
-
children: [typeof
|
|
2392
|
+
children: [typeof f.org?.total == "number" ? /* @__PURE__ */ L(F, { children: [
|
|
2393
2393
|
/* @__PURE__ */ I("span", {
|
|
2394
2394
|
className: "tnum",
|
|
2395
|
-
children:
|
|
2395
|
+
children: f.org.linked ?? 0
|
|
2396
2396
|
}),
|
|
2397
2397
|
" of ",
|
|
2398
2398
|
/* @__PURE__ */ I("span", {
|
|
2399
2399
|
className: "tnum",
|
|
2400
|
-
children:
|
|
2400
|
+
children: f.org.total
|
|
2401
2401
|
}),
|
|
2402
2402
|
" repos linked. "
|
|
2403
2403
|
] }) : null, "a collective links one github org today."]
|
|
@@ -2410,24 +2410,24 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2410
2410
|
})]
|
|
2411
2411
|
})
|
|
2412
2412
|
}),
|
|
2413
|
-
/* @__PURE__ */ I(
|
|
2413
|
+
/* @__PURE__ */ I(S, {
|
|
2414
2414
|
label: "pull requests",
|
|
2415
2415
|
defaultOpen: !0,
|
|
2416
2416
|
count: 1,
|
|
2417
|
-
id:
|
|
2418
|
-
children: /* @__PURE__ */ I(
|
|
2417
|
+
id: x("pull requests"),
|
|
2418
|
+
children: /* @__PURE__ */ I(d, {
|
|
2419
2419
|
label: "show transcripts on pull requests",
|
|
2420
2420
|
help: "adds a peasant / prompts comment and check on pull requests in this collective's repos, listing which commits have transcripts. it never blocks merging.",
|
|
2421
2421
|
control: "switch",
|
|
2422
2422
|
value: i,
|
|
2423
|
-
onCommit:
|
|
2423
|
+
onCommit: p("showOnPullRequests")
|
|
2424
2424
|
})
|
|
2425
2425
|
}),
|
|
2426
|
-
|
|
2426
|
+
y && /* @__PURE__ */ L(S, {
|
|
2427
2427
|
label: "danger zone",
|
|
2428
2428
|
defaultOpen: !0,
|
|
2429
2429
|
count: null,
|
|
2430
|
-
id:
|
|
2430
|
+
id: x("danger zone"),
|
|
2431
2431
|
children: [t.onTransferOwnership && /* @__PURE__ */ L("div", {
|
|
2432
2432
|
className: "srow",
|
|
2433
2433
|
children: [/* @__PURE__ */ I("span", {
|
|
@@ -2445,13 +2445,13 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2445
2445
|
className: "srow-help",
|
|
2446
2446
|
children: [
|
|
2447
2447
|
"delete ",
|
|
2448
|
-
|
|
2448
|
+
f.name,
|
|
2449
2449
|
" for ",
|
|
2450
|
-
typeof
|
|
2450
|
+
typeof f.memberCount == "number" ? /* @__PURE__ */ L(F, { children: [
|
|
2451
2451
|
"all ",
|
|
2452
2452
|
/* @__PURE__ */ I("span", {
|
|
2453
2453
|
className: "tnum",
|
|
2454
|
-
children:
|
|
2454
|
+
children: f.memberCount
|
|
2455
2455
|
}),
|
|
2456
2456
|
" members"
|
|
2457
2457
|
] }) : "all its members",
|
|
@@ -2468,12 +2468,12 @@ function ut({ data: e = {}, actions: t = {} } = {}) {
|
|
|
2468
2468
|
]
|
|
2469
2469
|
})
|
|
2470
2470
|
]
|
|
2471
|
-
}), t.onLinkRepos && /* @__PURE__ */ I(
|
|
2472
|
-
open:
|
|
2471
|
+
}), t.onLinkRepos && /* @__PURE__ */ I(g, {
|
|
2472
|
+
open: ee,
|
|
2473
2473
|
onClose: () => m(!1),
|
|
2474
2474
|
owners: n,
|
|
2475
2475
|
initialSelected: r,
|
|
2476
|
-
title: `link repositories from ${
|
|
2476
|
+
title: `link repositories from ${f.org?.login ?? "github"}`,
|
|
2477
2477
|
onSave: (e) => {
|
|
2478
2478
|
t.onLinkRepos(e), m(!1);
|
|
2479
2479
|
}
|
|
@@ -2525,8 +2525,8 @@ function ht(e) {
|
|
|
2525
2525
|
}).format(t).toLowerCase();
|
|
2526
2526
|
}
|
|
2527
2527
|
function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
2528
|
-
let { collective: r = dt, providerShare: i = [], pendingReview:
|
|
2529
|
-
|
|
2528
|
+
let { collective: r = dt, providerShare: i = [], pendingReview: a = [], members: o = [], redactions: c = [], browseRows: l = [], roleOptions: d = [], initialRole: f = "", initialShowRedaction: p = !1, initialBrowseGated: ee = !1, stats: m = ft } = e || pt, { onRoleChange: g, onJoin: v, onLeave: y, onSettings: x, onContribute: S, onToggleBrowse: C } = t || {}, [w, T] = P(f || r.role || ""), [D, O] = P(!!p), [k, A] = P(!!ee), j = w || r.role || "guest", te = j === "owner", N = j === "guest", F = n && d.length > 0, ne = M(() => F ? d : [], [F, d]), R = (e) => {
|
|
2529
|
+
T(e), g?.(e);
|
|
2530
2530
|
};
|
|
2531
2531
|
return /* @__PURE__ */ I("div", {
|
|
2532
2532
|
className: "cmg-root",
|
|
@@ -2586,7 +2586,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2586
2586
|
children: ne.map((e) => /* @__PURE__ */ I("button", {
|
|
2587
2587
|
type: "button",
|
|
2588
2588
|
className: "cmg-roleseg",
|
|
2589
|
-
"aria-pressed":
|
|
2589
|
+
"aria-pressed": w === e,
|
|
2590
2590
|
onClick: () => R(e),
|
|
2591
2591
|
children: e
|
|
2592
2592
|
}, e))
|
|
@@ -2605,34 +2605,34 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2605
2605
|
N ? /* @__PURE__ */ L("button", {
|
|
2606
2606
|
type: "button",
|
|
2607
2607
|
className: "btn btn-sm btn-primary",
|
|
2608
|
-
onClick: () =>
|
|
2608
|
+
onClick: () => v?.(),
|
|
2609
2609
|
children: [/* @__PURE__ */ I(ve, {
|
|
2610
2610
|
size: 14,
|
|
2611
2611
|
"aria-hidden": "true"
|
|
2612
2612
|
}), " join as contributor"]
|
|
2613
2613
|
}) : null,
|
|
2614
|
-
(j === "member" || j === "contributor") &&
|
|
2614
|
+
(j === "member" || j === "contributor") && S ? /* @__PURE__ */ L("button", {
|
|
2615
2615
|
type: "button",
|
|
2616
2616
|
className: "btn btn-sm btn-primary",
|
|
2617
|
-
onClick: () =>
|
|
2617
|
+
onClick: () => S?.(),
|
|
2618
2618
|
children: [/* @__PURE__ */ I(me, {
|
|
2619
2619
|
size: 14,
|
|
2620
2620
|
"aria-hidden": "true"
|
|
2621
2621
|
}), " contribute"]
|
|
2622
2622
|
}) : null,
|
|
2623
|
-
(j === "member" || j === "contributor") &&
|
|
2623
|
+
(j === "member" || j === "contributor") && y ? /* @__PURE__ */ L("button", {
|
|
2624
2624
|
type: "button",
|
|
2625
2625
|
className: "btn btn-sm btn-danger",
|
|
2626
|
-
onClick: () =>
|
|
2626
|
+
onClick: () => y?.(),
|
|
2627
2627
|
children: [/* @__PURE__ */ I(q, {
|
|
2628
2628
|
size: 14,
|
|
2629
2629
|
"aria-hidden": "true"
|
|
2630
2630
|
}), " leave"]
|
|
2631
2631
|
}) : null,
|
|
2632
|
-
te &&
|
|
2632
|
+
te && x ? /* @__PURE__ */ L("button", {
|
|
2633
2633
|
type: "button",
|
|
2634
2634
|
className: "btn btn-sm btn-secondary",
|
|
2635
|
-
onClick: () =>
|
|
2635
|
+
onClick: () => x?.(),
|
|
2636
2636
|
children: [/* @__PURE__ */ I(X, {
|
|
2637
2637
|
size: 14,
|
|
2638
2638
|
"aria-hidden": "true"
|
|
@@ -2645,40 +2645,40 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2645
2645
|
/* @__PURE__ */ L("div", {
|
|
2646
2646
|
className: "cmg-tiles",
|
|
2647
2647
|
children: [
|
|
2648
|
-
/* @__PURE__ */ I(
|
|
2648
|
+
/* @__PURE__ */ I(s, {
|
|
2649
2649
|
label: "contributions",
|
|
2650
2650
|
value: r.acceptanceMode || "open",
|
|
2651
2651
|
tone: "teal"
|
|
2652
2652
|
}),
|
|
2653
|
-
/* @__PURE__ */ I(
|
|
2653
|
+
/* @__PURE__ */ I(s, {
|
|
2654
2654
|
label: "access",
|
|
2655
2655
|
value: r.dataAccess || "members only",
|
|
2656
2656
|
tone: "amber"
|
|
2657
2657
|
}),
|
|
2658
|
-
/* @__PURE__ */ I(
|
|
2658
|
+
/* @__PURE__ */ I(s, {
|
|
2659
2659
|
label: "your role",
|
|
2660
2660
|
value: j
|
|
2661
2661
|
})
|
|
2662
2662
|
]
|
|
2663
2663
|
}),
|
|
2664
|
-
/* @__PURE__ */ I(
|
|
2664
|
+
/* @__PURE__ */ I(E, { tiles: [
|
|
2665
2665
|
{
|
|
2666
2666
|
key: "transcripts",
|
|
2667
2667
|
label: "transcripts",
|
|
2668
|
-
value:
|
|
2669
|
-
sub: `across ${
|
|
2668
|
+
value: m.transcripts,
|
|
2669
|
+
sub: `across ${m.projects}`
|
|
2670
2670
|
},
|
|
2671
2671
|
{
|
|
2672
2672
|
key: "tokens",
|
|
2673
2673
|
label: "tokens",
|
|
2674
|
-
value:
|
|
2675
|
-
sub:
|
|
2674
|
+
value: m.tokens,
|
|
2675
|
+
sub: m.turns
|
|
2676
2676
|
},
|
|
2677
2677
|
{
|
|
2678
2678
|
key: "contributors",
|
|
2679
2679
|
label: "contributors",
|
|
2680
|
-
value:
|
|
2681
|
-
sub:
|
|
2680
|
+
value: m.contributors,
|
|
2681
|
+
sub: m.hours
|
|
2682
2682
|
}
|
|
2683
2683
|
] }),
|
|
2684
2684
|
/* @__PURE__ */ L("div", {
|
|
@@ -2693,7 +2693,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2693
2693
|
id: "cmg-share-h",
|
|
2694
2694
|
className: "cmg-sub",
|
|
2695
2695
|
children: "provider share"
|
|
2696
|
-
}), /* @__PURE__ */ I(
|
|
2696
|
+
}), /* @__PURE__ */ I(u, {
|
|
2697
2697
|
label: "provider share",
|
|
2698
2698
|
total: 100,
|
|
2699
2699
|
data: i.map((e) => ({
|
|
@@ -2702,7 +2702,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2702
2702
|
}))
|
|
2703
2703
|
})]
|
|
2704
2704
|
}) : null,
|
|
2705
|
-
|
|
2705
|
+
a.length > 0 ? /* @__PURE__ */ I("div", {
|
|
2706
2706
|
style: {
|
|
2707
2707
|
overflow: "auto",
|
|
2708
2708
|
maxWidth: "100%"
|
|
@@ -2710,7 +2710,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2710
2710
|
children: /* @__PURE__ */ I(b, {
|
|
2711
2711
|
title: "pending review",
|
|
2712
2712
|
emptyLabel: "no shares awaiting review.",
|
|
2713
|
-
items:
|
|
2713
|
+
items: a.map((e) => ({
|
|
2714
2714
|
id: e.id,
|
|
2715
2715
|
kind: "share",
|
|
2716
2716
|
who: e.title || "untitled transcript",
|
|
@@ -2718,7 +2718,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2718
2718
|
}))
|
|
2719
2719
|
})
|
|
2720
2720
|
}) : null,
|
|
2721
|
-
|
|
2721
|
+
c.length > 0 ? /* @__PURE__ */ L("section", {
|
|
2722
2722
|
className: "card cmg-redact-sec",
|
|
2723
2723
|
"aria-labelledby": "cmg-redact-h",
|
|
2724
2724
|
children: [/* @__PURE__ */ L("div", {
|
|
@@ -2742,14 +2742,14 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2742
2742
|
})]
|
|
2743
2743
|
}), D ? /* @__PURE__ */ I("div", {
|
|
2744
2744
|
className: "cmg-redact-list",
|
|
2745
|
-
children:
|
|
2745
|
+
children: c.map((e) => /* @__PURE__ */ L("article", {
|
|
2746
2746
|
className: "cmg-redact",
|
|
2747
2747
|
children: [
|
|
2748
2748
|
/* @__PURE__ */ L("div", {
|
|
2749
2749
|
className: "cmg-redact-head",
|
|
2750
2750
|
children: [/* @__PURE__ */ I("span", {
|
|
2751
2751
|
className: "cmg-redact-badges",
|
|
2752
|
-
children: /* @__PURE__ */ I(
|
|
2752
|
+
children: /* @__PURE__ */ I(h, { children: String(e.catLabel || e.cat || "item").toLowerCase() })
|
|
2753
2753
|
}), /* @__PURE__ */ I("span", {
|
|
2754
2754
|
className: "cmg-redact-file mono",
|
|
2755
2755
|
children: e.file || "unknown"
|
|
@@ -2809,14 +2809,14 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2809
2809
|
N ? /* @__PURE__ */ L("button", {
|
|
2810
2810
|
type: "button",
|
|
2811
2811
|
className: "btn btn-sm btn-primary",
|
|
2812
|
-
onClick: () =>
|
|
2812
|
+
onClick: () => v?.(),
|
|
2813
2813
|
children: [/* @__PURE__ */ I(ve, {
|
|
2814
2814
|
size: 14,
|
|
2815
2815
|
"aria-hidden": "true"
|
|
2816
2816
|
}), " join as contributor"]
|
|
2817
2817
|
}) : null
|
|
2818
2818
|
]
|
|
2819
|
-
}) :
|
|
2819
|
+
}) : l.length > 0 ? /* @__PURE__ */ L("table", {
|
|
2820
2820
|
className: "dtable cmg-dtable",
|
|
2821
2821
|
children: [/* @__PURE__ */ I("thead", { children: /* @__PURE__ */ L("tr", { children: [
|
|
2822
2822
|
/* @__PURE__ */ I("th", {
|
|
@@ -2845,7 +2845,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2845
2845
|
scope: "col",
|
|
2846
2846
|
children: "date"
|
|
2847
2847
|
})
|
|
2848
|
-
] }) }), /* @__PURE__ */ I("tbody", { children:
|
|
2848
|
+
] }) }), /* @__PURE__ */ I("tbody", { children: l.map((e) => /* @__PURE__ */ L("tr", { children: [
|
|
2849
2849
|
/* @__PURE__ */ I("td", { children: e.title || "untitled transcript" }),
|
|
2850
2850
|
/* @__PURE__ */ I("td", {
|
|
2851
2851
|
className: "mono",
|
|
@@ -2888,7 +2888,7 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2888
2888
|
})]
|
|
2889
2889
|
})
|
|
2890
2890
|
]
|
|
2891
|
-
}),
|
|
2891
|
+
}), o.length > 0 ? /* @__PURE__ */ I("aside", {
|
|
2892
2892
|
className: "sidebar cmg-d-rail",
|
|
2893
2893
|
"aria-label": "collective sidebar",
|
|
2894
2894
|
children: /* @__PURE__ */ I("div", {
|
|
@@ -2896,10 +2896,10 @@ function gt({ data: e = pt, actions: t = {}, demoRoleSwitcher: n = !1 } = {}) {
|
|
|
2896
2896
|
overflow: "auto",
|
|
2897
2897
|
maxWidth: "100%"
|
|
2898
2898
|
},
|
|
2899
|
-
children: /* @__PURE__ */ I(
|
|
2899
|
+
children: /* @__PURE__ */ I(_, {
|
|
2900
2900
|
title: "members",
|
|
2901
2901
|
roles: ["member", "contributor"],
|
|
2902
|
-
members:
|
|
2902
|
+
members: o.map((e) => ({
|
|
2903
2903
|
handle: e.handle || e.githubUsername || "@unknown",
|
|
2904
2904
|
name: e.name || e.displayName || e.githubUsername || "unknown",
|
|
2905
2905
|
role: e.role || "member",
|