git-truck 1.5.7 → 1.5.8

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/build/index.js CHANGED
@@ -26547,8 +26547,8 @@ var require_useHover = __commonJS({
26547
26547
  "node_modules/react-use/lib/useHover.js"(exports) {
26548
26548
  "use strict";
26549
26549
  Object.defineProperty(exports, "__esModule", { value: !0 });
26550
- var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports)), React = tslib_1.__importStar(require_react()), util_1 = require_util2(), useState11 = React.useState, useHover = function(element) {
26551
- var _a2 = useState11(!1), state = _a2[0], setState = _a2[1], onMouseEnter = function(originalOnMouseEnter) {
26550
+ var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports)), React = tslib_1.__importStar(require_react()), util_1 = require_util2(), useState12 = React.useState, useHover = function(element) {
26551
+ var _a2 = useState12(!1), state = _a2[0], setState = _a2[1], onMouseEnter = function(originalOnMouseEnter) {
26552
26552
  return function(event) {
26553
26553
  (originalOnMouseEnter || util_1.noop)(event), setState(!0);
26554
26554
  };
@@ -28405,7 +28405,7 @@ var require_useSize = __commonJS({
28405
28405
  "node_modules/react-use/lib/useSize.js"(exports) {
28406
28406
  "use strict";
28407
28407
  Object.defineProperty(exports, "__esModule", { value: !0 });
28408
- var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports)), React = tslib_1.__importStar(require_react()), util_1 = require_util2(), useState11 = React.useState, useEffect8 = React.useEffect, useRef5 = React.useRef, DRAF = function(callback) {
28408
+ var tslib_1 = (init_tslib_es6(), __toCommonJS(tslib_es6_exports)), React = tslib_1.__importStar(require_react()), util_1 = require_util2(), useState12 = React.useState, useEffect8 = React.useEffect, useRef5 = React.useRef, DRAF = function(callback) {
28409
28409
  return setTimeout(callback, 35);
28410
28410
  }, useSize = function(element, _a2) {
28411
28411
  var _b2 = _a2 === void 0 ? {} : _a2, _c2 = _b2.width, width = _c2 === void 0 ? 1 / 0 : _c2, _d = _b2.height, height = _d === void 0 ? 1 / 0 : _d;
@@ -28414,7 +28414,7 @@ var require_useSize = __commonJS({
28414
28414
  typeof element == "function" ? element({ width, height }) : element,
28415
28415
  { width, height }
28416
28416
  ];
28417
- var _e3 = useState11({ width, height }), state = _e3[0], setState = _e3[1];
28417
+ var _e3 = useState12({ width, height }), state = _e3[0], setState = _e3[1];
28418
28418
  typeof element == "function" && (element = element(state));
28419
28419
  var style = element.props.style || {}, ref = useRef5(null), window2 = null, setSize = function() {
28420
28420
  var iframe = ref.current, size = iframe ? {
@@ -48675,7 +48675,7 @@ var LegendBarIndicator = ({ visible, offset }) => /* @__PURE__ */ (0, import_jsx
48675
48675
  );
48676
48676
 
48677
48677
  // src/tailwind.css
48678
- var tailwind_default = "/build/_assets/tailwind-SKGXOX4B.css";
48678
+ var tailwind_default = "/build/_assets/tailwind-UOXC4AQW.css";
48679
48679
 
48680
48680
  // src/root.tsx
48681
48681
  var import_jsx_runtime3 = __toESM(require_jsx_runtime()), meta = () => [{ title: "Git Truck" }];
@@ -48758,7 +48758,7 @@ __export(repo_exports, {
48758
48758
  default: () => Repo,
48759
48759
  loader: () => loader
48760
48760
  });
48761
- var import_path8 = require("path"), import_react61 = __toESM(require_react()), import_react_use5 = __toESM(require_lib5()), import_node2 = __toESM(require_dist2()), import_remix_typedjson = __toESM(require_dist5()), import_react62 = __toESM(require_dist3());
48761
+ var import_path8 = require("path"), import_react62 = __toESM(require_react()), import_react_use5 = __toESM(require_lib5()), import_node2 = __toESM(require_dist2()), import_remix_typedjson = __toESM(require_dist5()), import_react63 = __toESM(require_dist3());
48762
48762
 
48763
48763
  // src/analyzer/analyze.server.ts
48764
48764
  var import_fs3 = require("fs");
@@ -48846,7 +48846,7 @@ var import_perf_hooks = require("perf_hooks"), import_path2 = require("path"), i
48846
48846
  // package.json
48847
48847
  var package_default = {
48848
48848
  name: "git-truck",
48849
- version: "1.5.7",
48849
+ version: "1.5.8",
48850
48850
  private: !1,
48851
48851
  description: "Visualizing a Git repository",
48852
48852
  license: "MIT",
@@ -53981,7 +53981,7 @@ async function getTruckConfigWithArgs(repo) {
53981
53981
  }
53982
53982
 
53983
53983
  // src/components/DetailsCard.tsx
53984
- var import_react13 = __toESM(require_react()), import_react14 = __toESM(require_dist3());
53984
+ var import_react14 = __toESM(require_react()), import_react15 = __toESM(require_dist3());
53985
53985
 
53986
53986
  // src/components/AuthorDistFragment.tsx
53987
53987
  var import_react8 = __toESM(require_react());
@@ -57037,57 +57037,156 @@ byteSize.defaultOptions = function(options) {
57037
57037
  var byte_size_default = byteSize;
57038
57038
 
57039
57039
  // src/components/DetailsCard.tsx
57040
- var import_js4 = __toESM(require_mdi()), import_react15 = __toESM(require_Icon());
57040
+ var import_js4 = __toESM(require_mdi()), import_react16 = __toESM(require_Icon());
57041
57041
 
57042
57042
  // src/components/FileHistoryElement.tsx
57043
+ var import_react13 = __toESM(require_react());
57044
+
57045
+ // src/assets/commit_icon.png
57046
+ var commit_icon_default = "/build/_assets/commit_icon-JEPGHU5X.png";
57047
+
57048
+ // src/components/accordion/Accordion.tsx
57043
57049
  var import_react12 = __toESM(require_react());
57044
- var import_jsx_runtime7 = __toESM(require_jsx_runtime());
57050
+
57051
+ // src/components/accordion/AccordionItem.tsx
57052
+ var import_clsx2 = __toESM(require_clsx()), import_jsx_runtime7 = __toESM(require_jsx_runtime());
57053
+ function AccordionItem({
57054
+ data,
57055
+ isOpen,
57056
+ btnOnClick,
57057
+ titleLabels
57058
+ }) {
57059
+ return /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("li", { className: "border-0 ", children: [
57060
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("h2", { className: "w-full m-0", children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: (0, import_clsx2.default)("flex items-center b-0 w-full cursor-pointer " + "after:content-[''] after:shrink-0 after:w-[14px] after:h-[14px] after:ml-auto after:transition-[transform] after:duration-[200ms] after:ease-out after:bg-[length:14px_14px] after:bg-no-repeat after:bg-arrow", {
57061
+ "text-[16px] font-semibold": titleLabels,
57062
+ "text-[14px] font-normal": !titleLabels,
57063
+ "after:-rotate-180": isOpen,
57064
+ "after:rotate-0": !isOpen
57065
+ }), onClick: btnOnClick, title: data.title, children: data.title }) }),
57066
+ /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("ul", { className: "block m-0 p-0 text-sm transition-[height] duration-[200ms] ease-out", style: { height: isOpen ? "auto" : "0" }, children: isOpen && /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { children: data.content }) })
57067
+ ] });
57068
+ }
57069
+ var AccordionItem_default = AccordionItem;
57070
+
57071
+ // src/components/accordion/Accordion.tsx
57072
+ var import_jsx_runtime8 = __toESM(require_jsx_runtime());
57073
+ function Accordion({
57074
+ items,
57075
+ itemsCutoff,
57076
+ multipleOpen,
57077
+ openByDefault,
57078
+ titleLabels,
57079
+ currentState,
57080
+ actionClickLabels,
57081
+ setCollapsed,
57082
+ collapsed
57083
+ }) {
57084
+ let [currentIdx, setCurrentIdx] = (0, import_react12.useState)(new Array()), btnOnClick = (idx) => {
57085
+ setCurrentIdx(
57086
+ multipleOpen ? (currentValue) => currentValue.includes(idx) ? currentValue.filter((item) => item !== idx) : [...currentValue, idx] : (currentValue) => currentValue.includes(idx) ? [] : [idx]
57087
+ );
57088
+ }, cutItems = collapsed ? items.slice(0, itemsCutoff) : items;
57089
+ return openByDefault && !multipleOpen && setCurrentIdx([0]), /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("ul", { className: "block m-0 pl-4 overflow-x-hidden", children: [
57090
+ cutItems.map((item, idx) => /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_jsx_runtime8.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
57091
+ AccordionItem_default,
57092
+ {
57093
+ data: item,
57094
+ isOpen: currentState && currentState[idx] ? currentState[idx] : openByDefault && multipleOpen ? !currentIdx.includes(idx) : currentIdx.includes(idx),
57095
+ titleLabels,
57096
+ btnOnClick: () => {
57097
+ btnOnClick(idx), actionClickLabels && actionClickLabels(idx);
57098
+ }
57099
+ },
57100
+ item.title + idx + "--accordion"
57101
+ ) })),
57102
+ /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
57103
+ ShowMoreLabel,
57104
+ {
57105
+ show: collapsed && items.length > itemsCutoff,
57106
+ items: items.slice(itemsCutoff),
57107
+ toggle: () => setCollapsed(!collapsed)
57108
+ }
57109
+ )
57110
+ ] });
57111
+ }
57112
+ function ShowMoreLabel(props) {
57113
+ return props.show ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("span", { className: "whitespace-pre text-xs font-medium opacity-70 hover:cursor-pointer", onClick: props.toggle, children: [
57114
+ "+",
57115
+ props.items.length,
57116
+ " more day",
57117
+ props.items.length > 1 ? "s" : ""
57118
+ ] }) : null;
57119
+ }
57120
+ var Accordion_default = Accordion;
57121
+
57122
+ // src/components/FileHistoryElement.tsx
57123
+ var import_jsx_runtime9 = __toESM(require_jsx_runtime());
57045
57124
  function FileHistoryElement(props) {
57046
57125
  let { analyzerData } = useData(), fileCommits = [];
57047
- if (props.clickedObject.type === "blob")
57048
- fileCommits = props.clickedObject.commits.map((c7) => analyzerData.commits[c7]);
57049
- else
57050
- try {
57051
- fileCommits = Array.from(calculateCommitsForSubTree(props.clickedObject)).map((c7) => analyzerData.commits[c7]).sort((a, b4) => b4.time - a.time);
57052
- } catch (e) {
57053
- console.log(e);
57054
- }
57055
- return /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CommitHistory, { commits: fileCommits });
57126
+ return props.clickedObject.type === "blob" ? fileCommits = props.clickedObject.commits.map((c7) => analyzerData.commits[c7]) : fileCommits = Array.from(calculateCommitsForSubTree(props.clickedObject)).map((c7) => analyzerData.commits[c7]).sort((a, b4) => b4.time - a.time), /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(CommitHistory, { commits: fileCommits });
57056
57127
  }
57057
57128
  function CommitDistFragment(props) {
57058
- return props.show ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(import_jsx_runtime7.Fragment, { children: props.items.map((commit) => /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_react12.Fragment, { children: [
57059
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(
57060
- "span",
57061
- {
57062
- className: "overflow-hidden overflow-ellipsis whitespace-pre text-sm font-bold opacity-80",
57063
- title: commit.message + " (" + commit.author + ")",
57064
- children: commit.message
57065
- }
57066
- ),
57067
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("p", { className: "break-all text-right text-sm", children: dateFormatLong(commit.time) })
57068
- ] }, commit.time.toString() + commit.message)) }) : null;
57129
+ if (!props.items)
57130
+ return null;
57131
+ let sortMethod = props.sortBy !== void 0 ? props.sortBy : "date", cleanGroupItems = sortCommits(props.items, sortMethod), items = new Array();
57132
+ for (let [key, values] of Object.entries(cleanGroupItems))
57133
+ items.push({
57134
+ title: key,
57135
+ content: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_jsx_runtime9.Fragment, { children: values.map((value) => /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_jsx_runtime9.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
57136
+ "li",
57137
+ {
57138
+ className: "cursor-auto",
57139
+ style: { listStyleImage: `url(${commit_icon_default})` },
57140
+ onClick: () => props.handleOnClick ? props.handleOnClick(value) : null,
57141
+ children: value.message
57142
+ },
57143
+ value.time + value.message + "--itemContentAccordion"
57144
+ ) })) })
57145
+ });
57146
+ return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react13.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
57147
+ Accordion_default,
57148
+ {
57149
+ titleLabels: !0,
57150
+ multipleOpen: !0,
57151
+ openByDefault: !0,
57152
+ items,
57153
+ itemsCutoff: props.commitCutoff,
57154
+ collapsed: props.collapsed,
57155
+ setCollapsed: props.setCollapsed
57156
+ }
57157
+ ) }, items.length.toString() + sortMethod + props.commitCutoff.toString() + (/* @__PURE__ */ new Date()).toDateString());
57069
57158
  }
57070
57159
  function CommitHistory(props) {
57071
- let commitHistoryExpandId = (0, import_react12.useId)(), [collapsed, setCollapsed] = (0, import_react12.useState)(!0), commits = props.commits ?? [], commitCutoff = 2;
57072
- return commits.length <= commitCutoff + 1 ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_jsx_runtime7.Fragment, { children: [
57073
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("h3", { className: "font-bold", children: "Commit history" }),
57074
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("div", { className: "grid grid-cols-[1fr,auto] gap-x-1 gap-y-1.5", children: commits.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CommitDistFragment, { show: !0, items: commits }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("p", { children: "No commits found" }) })
57075
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)(import_jsx_runtime7.Fragment, { children: [
57076
- /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "flex cursor-pointer justify-between hover:opacity-70", children: [
57077
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("label", { className: "label grow", htmlFor: commitHistoryExpandId, children: /* @__PURE__ */ (0, import_jsx_runtime7.jsx)("h3", { className: "font-bold", children: "Commit history" }) }),
57078
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(ChevronButton, { id: commitHistoryExpandId, open: !collapsed, onClick: () => setCollapsed(!collapsed) })
57160
+ let commitHistoryExpandId = (0, import_react13.useId)(), [collapsed, setCollapsed] = (0, import_react13.useState)(!0), commits = props.commits ?? [], commitCutoff = 3;
57161
+ return commits.length == 0 ? /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
57162
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("h3", { className: "font-bold", children: "Commit history" }),
57163
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("p", { children: "No commits found" }) })
57164
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)(import_jsx_runtime9.Fragment, { children: [
57165
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "flex cursor-pointer justify-between hover:opacity-70", children: [
57166
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("label", { className: "label grow", children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("h3", { className: "font-bold", children: "Commit history" }) }),
57167
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(ChevronButton, { id: commitHistoryExpandId, open: !collapsed, onClick: () => setCollapsed(!collapsed) })
57079
57168
  ] }),
57080
- /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("div", { className: "grid grid-cols-[1fr,auto] gap-x-1 gap-y-1.5", children: [
57081
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CommitDistFragment, { show: !0, items: commits.slice(0, commitCutoff) }),
57082
- /* @__PURE__ */ (0, import_jsx_runtime7.jsx)(CommitDistFragment, { show: !collapsed, items: commits.slice(commitCutoff) }),
57083
- collapsed ? /* @__PURE__ */ (0, import_jsx_runtime7.jsxs)("button", { className: "text-left text-xs opacity-70 hover:opacity-100", onClick: () => setCollapsed(!collapsed), children: [
57084
- "+ ",
57085
- commits.slice(commitCutoff).length,
57086
- " more"
57087
- ] }) : null
57088
- ] })
57169
+ /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(CommitDistFragment, { commitCutoff: collapsed ? commitCutoff : commits.length, items: commits, setCollapsed, collapsed: !0 }) })
57089
57170
  ] });
57090
57171
  }
57172
+ function sortCommits(items, method) {
57173
+ let cleanGroupItems = {};
57174
+ switch (method) {
57175
+ case "author":
57176
+ items.map((commit) => {
57177
+ let author = commit.author;
57178
+ return cleanGroupItems[author] || (cleanGroupItems[author] = []), cleanGroupItems[author].push(commit), commit;
57179
+ });
57180
+ break;
57181
+ case "date":
57182
+ default:
57183
+ items.map((commit) => {
57184
+ let date = dateFormatLong(commit.time);
57185
+ return cleanGroupItems[date] || (cleanGroupItems[date] = []), cleanGroupItems[date].push(commit), commit;
57186
+ });
57187
+ }
57188
+ return cleanGroupItems;
57189
+ }
57091
57190
  function calculateCommitsForSubTree(tree) {
57092
57191
  let commitSet = /* @__PURE__ */ new Set();
57093
57192
  subTree(tree);
@@ -57106,8 +57205,8 @@ function calculateCommitsForSubTree(tree) {
57106
57205
  }
57107
57206
 
57108
57207
  // src/components/DetailsCard.tsx
57109
- var import_clsx2 = __toESM(require_clsx());
57110
- var import_jsx_runtime8 = __toESM(require_jsx_runtime());
57208
+ var import_clsx3 = __toESM(require_clsx());
57209
+ var import_jsx_runtime10 = __toESM(require_jsx_runtime());
57111
57210
  function OneFolderOut(path) {
57112
57211
  let index = path.lastIndexOf("/"), index2 = path.lastIndexOf("\\");
57113
57212
  return index !== -1 ? path.slice(0, index) : index2 !== -1 ? path.slice(0, index2) : path;
@@ -57117,13 +57216,13 @@ function DetailsCard({
57117
57216
  showUnionAuthorsModal
57118
57217
  }) {
57119
57218
  var _a2;
57120
- let { setClickedObject, clickedObject } = useClickedObject(), location2 = (0, import_react14.useLocation)(), { metricType, authorshipType } = useOptions(), { state } = (0, import_react14.useNavigation)(), { setPath, path } = usePath(), { analyzerData } = useData(), isProcessingHideRef = (0, import_react13.useRef)(!1);
57121
- (0, import_react13.useEffect)(() => {
57219
+ let { setClickedObject, clickedObject } = useClickedObject(), location2 = (0, import_react15.useLocation)(), { metricType, authorshipType } = useOptions(), { state } = (0, import_react15.useNavigation)(), { setPath, path } = usePath(), { analyzerData } = useData(), isProcessingHideRef = (0, import_react14.useRef)(!1);
57220
+ (0, import_react14.useEffect)(() => {
57122
57221
  isProcessingHideRef.current && (setClickedObject(null), isProcessingHideRef.current = !1);
57123
- }, [clickedObject, setClickedObject, state]), (0, import_react13.useEffect)(() => {
57222
+ }, [clickedObject, setClickedObject, state]), (0, import_react14.useEffect)(() => {
57124
57223
  setClickedObject((clickedObject2) => findObjectInTree(analyzerData.commit.tree, clickedObject2));
57125
57224
  }, [analyzerData, setClickedObject]);
57126
- let [metricsData] = useMetrics(), { backgroundColor, color, lightBackground } = (0, import_react13.useMemo)(() => {
57225
+ let [metricsData] = useMetrics(), { backgroundColor, color, lightBackground } = (0, import_react14.useMemo)(() => {
57127
57226
  var _a3, _b2;
57128
57227
  if (!clickedObject)
57129
57228
  return {
@@ -57141,53 +57240,53 @@ function DetailsCard({
57141
57240
  if (!clickedObject)
57142
57241
  return null;
57143
57242
  let isBlob2 = clickedObject.type === "blob", extension = last(clickedObject.name.split("."));
57144
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57243
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57145
57244
  "div",
57146
57245
  {
57147
- className: (0, import_clsx2.default)(className, "card flex grow flex-col gap-2 transition-colors"),
57246
+ className: (0, import_clsx3.default)(className, "card flex grow flex-col gap-2 transition-colors"),
57148
57247
  style: color ? {
57149
57248
  backgroundColor,
57150
57249
  color
57151
57250
  } : {},
57152
57251
  children: [
57153
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex grow flex-col gap-2", children: [
57154
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("h2", { className: "card__title grid grid-cols-[auto,1fr,auto] gap-2", children: [
57155
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react15.Icon, { path: clickedObject.type === "blob" ? import_js4.mdiFile : import_js4.mdiFolder, size: "1.25em" }),
57156
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "truncate", title: clickedObject.name, children: clickedObject.name }),
57157
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(CloseButton, { absolute: !1, onClick: () => setClickedObject(null) })
57252
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex grow flex-col gap-2", children: [
57253
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("h2", { className: "card__title grid grid-cols-[auto,1fr,auto] gap-2", children: [
57254
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react16.Icon, { path: clickedObject.type === "blob" ? import_js4.mdiFile : import_js4.mdiFolder, size: "1.25em" }),
57255
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "truncate", title: clickedObject.name, children: clickedObject.name }),
57256
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(CloseButton, { absolute: !1, onClick: () => setClickedObject(null) })
57158
57257
  ] }),
57159
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "grid grid-cols-[auto,1fr] gap-x-3 gap-y-1", children: [
57160
- isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57161
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(SizeEntry, { size: clickedObject.sizeInBytes, isBinary: clickedObject.isBinary }),
57162
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(CommitsEntry, { clickedBlob: clickedObject }),
57163
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(LastchangedEntry, { clickedBlob: clickedObject })
57164
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(FileAndSubfolderCountEntries, { clickedTree: clickedObject }),
57165
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(PathEntry, { path: clickedObject.path })
57258
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "grid grid-cols-[auto,1fr] gap-x-3 gap-y-1", children: [
57259
+ isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57260
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(SizeEntry, { size: clickedObject.sizeInBytes, isBinary: clickedObject.isBinary }),
57261
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(CommitsEntry, { clickedBlob: clickedObject }),
57262
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(LastchangedEntry, { clickedBlob: clickedObject })
57263
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(FileAndSubfolderCountEntries, { clickedTree: clickedObject }),
57264
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(PathEntry, { path: clickedObject.path })
57166
57265
  ] }),
57167
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "card bg-white/70 text-black", children: isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuthorDistribution, { authors: (_a2 = clickedObject.unionedAuthors) == null ? void 0 : _a2[authorshipType] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuthorDistribution, { authors: calculateAuthorshipForSubTree(clickedObject, authorshipType) }) }),
57168
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57266
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "card bg-white/70 text-black", children: isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(AuthorDistribution, { authors: (_a2 = clickedObject.unionedAuthors) == null ? void 0 : _a2[authorshipType] }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(AuthorDistribution, { authors: calculateAuthorshipForSubTree(clickedObject, authorshipType) }) }),
57267
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57169
57268
  "button",
57170
57269
  {
57171
- className: (0, import_clsx2.default)("btn", {
57270
+ className: (0, import_clsx3.default)("btn", {
57172
57271
  "btn--outlined--light": !lightBackground,
57173
57272
  "btn--outlined": lightBackground
57174
57273
  }),
57175
57274
  onClick: showUnionAuthorsModal,
57176
57275
  children: [
57177
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react15.Icon, { path: import_js4.mdiAccountMultiple }),
57276
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react16.Icon, { path: import_js4.mdiAccountMultiple }),
57178
57277
  "Group authors"
57179
57278
  ]
57180
57279
  }
57181
57280
  ),
57182
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "card bg-white/70 text-black", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(FileHistoryElement, { state, clickedObject }) })
57281
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "card bg-white/70 text-black", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(FileHistoryElement, { state, clickedObject }) })
57183
57282
  ] }),
57184
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex gap-2", children: isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57185
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_react14.Form, { className: "w-max", method: "post", action: location2.pathname, children: [
57186
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("input", { type: "hidden", name: "ignore", value: clickedObject.path }),
57187
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57283
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex gap-2", children: isBlob2 ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57284
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react15.Form, { className: "w-max", method: "post", action: location2.pathname, children: [
57285
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("input", { type: "hidden", name: "ignore", value: clickedObject.path }),
57286
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57188
57287
  "button",
57189
57288
  {
57190
- className: (0, import_clsx2.default)("btn", {
57289
+ className: (0, import_clsx3.default)("btn", {
57191
57290
  "btn--outlined--light": !lightBackground,
57192
57291
  "btn--outlined": lightBackground
57193
57292
  }),
@@ -57198,18 +57297,18 @@ function DetailsCard({
57198
57297
  },
57199
57298
  title: "Hide this file",
57200
57299
  children: [
57201
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react15.Icon, { path: import_js4.mdiEyeOffOutline }),
57300
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react16.Icon, { path: import_js4.mdiEyeOffOutline }),
57202
57301
  "Hide"
57203
57302
  ]
57204
57303
  }
57205
57304
  )
57206
57305
  ] }),
57207
- clickedObject.name.includes(".") ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_react14.Form, { className: "w-max", method: "post", action: location2.pathname, children: [
57208
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("input", { type: "hidden", name: "ignore", value: `*.${extension}` }),
57209
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57306
+ clickedObject.name.includes(".") ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react15.Form, { className: "w-max", method: "post", action: location2.pathname, children: [
57307
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("input", { type: "hidden", name: "ignore", value: `*.${extension}` }),
57308
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57210
57309
  "button",
57211
57310
  {
57212
- className: (0, import_clsx2.default)("btn", {
57311
+ className: (0, import_clsx3.default)("btn", {
57213
57312
  "btn--outlined--light": !lightBackground,
57214
57313
  "btn--outlined": lightBackground
57215
57314
  }),
@@ -57219,8 +57318,8 @@ function DetailsCard({
57219
57318
  isProcessingHideRef.current = !0;
57220
57319
  },
57221
57320
  children: [
57222
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react15.Icon, { path: import_js4.mdiEyeOffOutline }),
57223
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("span", { children: [
57321
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react16.Icon, { path: import_js4.mdiEyeOffOutline }),
57322
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("span", { children: [
57224
57323
  "Hide .",
57225
57324
  extension,
57226
57325
  " files"
@@ -57229,12 +57328,12 @@ function DetailsCard({
57229
57328
  }
57230
57329
  )
57231
57330
  ] }) : null
57232
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_jsx_runtime8.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_react14.Form, { method: "post", action: location2.pathname, children: [
57233
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("input", { type: "hidden", name: "ignore", value: clickedObject.path }),
57234
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57331
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_jsx_runtime10.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react15.Form, { method: "post", action: location2.pathname, children: [
57332
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("input", { type: "hidden", name: "ignore", value: clickedObject.path }),
57333
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57235
57334
  "button",
57236
57335
  {
57237
- className: (0, import_clsx2.default)("btn", {
57336
+ className: (0, import_clsx3.default)("btn", {
57238
57337
  "btn--outlined--light": !lightBackground,
57239
57338
  "btn--outlined": lightBackground
57240
57339
  }),
@@ -57244,7 +57343,7 @@ function DetailsCard({
57244
57343
  isProcessingHideRef.current = !0, setPath(OneFolderOut(path));
57245
57344
  },
57246
57345
  children: [
57247
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_react15.Icon, { path: import_js4.mdiEyeOffOutline }),
57346
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react16.Icon, { path: import_js4.mdiEyeOffOutline }),
57248
57347
  "Hide this folder"
57249
57348
  ]
57250
57349
  }
@@ -57274,35 +57373,35 @@ function findObjectInTree(tree, object) {
57274
57373
  }
57275
57374
  function FileAndSubfolderCountEntries(props) {
57276
57375
  let folderCount = props.clickedTree.children.filter((child) => child.type === "tree").length, fileCount = props.clickedTree.children.length - folderCount;
57277
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57278
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Files" }),
57279
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "break-all text-sm", children: fileCount }),
57280
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Folders" }),
57281
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "break-all text-sm", children: folderCount })
57376
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57377
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Files" }),
57378
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "break-all text-sm", children: fileCount }),
57379
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Folders" }),
57380
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "break-all text-sm", children: folderCount })
57282
57381
  ] });
57283
57382
  }
57284
57383
  function CommitsEntry(props) {
57285
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57286
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Commits" }),
57287
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "break-all text-sm", children: props.clickedBlob.commits.length > 0 ? props.clickedBlob.commits.length : 0 })
57384
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57385
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Commits" }),
57386
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "break-all text-sm", children: props.clickedBlob.commits.length > 0 ? props.clickedBlob.commits.length : 0 })
57288
57387
  ] });
57289
57388
  }
57290
57389
  function LastchangedEntry(props) {
57291
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57292
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Last changed" }),
57293
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "break-all text-sm", children: dateFormatLong(props.clickedBlob.lastChangeEpoch) })
57390
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57391
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Last changed" }),
57392
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "break-all text-sm", children: dateFormatLong(props.clickedBlob.lastChangeEpoch) })
57294
57393
  ] });
57295
57394
  }
57296
57395
  function PathEntry(props) {
57297
- let { state } = (0, import_react14.useNavigation)(), { clickedObject } = useClickedObject();
57298
- return clickedObject ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57299
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Located at" }),
57300
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "grid grid-cols-[1fr,auto] items-center justify-between gap-2 break-all text-sm", children: [
57301
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { className: "truncate", title: props.path, children: props.path }),
57302
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_react14.Form, { method: "post", action: location.pathname, title: clickedObject.name, children: [
57303
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("input", { type: "hidden", name: "open", value: clickedObject.path }),
57304
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("button", { className: "btn--icon", disabled: state !== "idle", children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
57305
- import_react15.Icon,
57396
+ let { state } = (0, import_react15.useNavigation)(), { clickedObject } = useClickedObject();
57397
+ return clickedObject ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57398
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex grow items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Located at" }),
57399
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "grid grid-cols-[1fr,auto] items-center justify-between gap-2 break-all text-sm", children: [
57400
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { className: "truncate", title: props.path, children: props.path }),
57401
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react15.Form, { method: "post", action: location.pathname, title: clickedObject.name, children: [
57402
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("input", { type: "hidden", name: "open", value: clickedObject.path }),
57403
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("button", { className: "btn--icon", disabled: state !== "idle", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
57404
+ import_react16.Icon,
57306
57405
  {
57307
57406
  path: import_js4.mdiOpenInNew,
57308
57407
  size: "1.25em",
@@ -57316,15 +57415,15 @@ function PathEntry(props) {
57316
57415
  }
57317
57416
  function SizeEntry(props) {
57318
57417
  let size = byte_size_default(props.size ?? 0);
57319
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57320
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "flex items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Size" }),
57321
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("p", { className: "break-all text-sm", children: [
57418
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57419
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex items-center overflow-hidden overflow-ellipsis whitespace-pre text-sm font-semibold", children: "Size" }),
57420
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("p", { className: "break-all text-sm", children: [
57322
57421
  size.value,
57323
57422
  " ",
57324
57423
  size.unit,
57325
57424
  " ",
57326
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("span", { className: "opacity-50", children: props.isBinary ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57327
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("br", {}),
57425
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "opacity-50", children: props.isBinary ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57426
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("br", {}),
57328
57427
  "(binary file)"
57329
57428
  ] }) : null })
57330
57429
  ] })
@@ -57332,18 +57431,18 @@ function SizeEntry(props) {
57332
57431
  }
57333
57432
  var authorCutoff = 2;
57334
57433
  function AuthorDistribution(props) {
57335
- let authorDistributionExpandId = (0, import_react13.useId)(), [collapsed, setCollapsed] = (0, import_react13.useState)(!0), contribDist = Object.entries(makePercentResponsibilityDistribution(props.authors)).sort(
57434
+ let authorDistributionExpandId = (0, import_react14.useId)(), [collapsed, setCollapsed] = (0, import_react14.useState)(!0), contribDist = Object.entries(makePercentResponsibilityDistribution(props.authors)).sort(
57336
57435
  (a, b4) => a[1] < b4[1] ? 1 : -1
57337
57436
  ), authorsAreCutoff = contribDist.length > authorCutoff + 1;
57338
- return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: "flex flex-col gap-2", children: [
57339
- /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)("div", { className: `flex justify-between ${authorsAreCutoff ? "cursor-pointer hover:opacity-70" : ""}`, children: [
57340
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("label", { className: "label grow", htmlFor: authorDistributionExpandId, children: /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("h3", { className: "font-bold", children: "Author distribution" }) }),
57341
- authorsAreCutoff ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(ChevronButton, { id: authorDistributionExpandId, open: !collapsed, onClick: () => setCollapsed(!collapsed) }) : null
57437
+ return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex flex-col gap-2", children: [
57438
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: `flex justify-between ${authorsAreCutoff ? "cursor-pointer hover:opacity-70" : ""}`, children: [
57439
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("label", { className: "label grow", htmlFor: authorDistributionExpandId, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("h3", { className: "font-bold", children: "Author distribution" }) }),
57440
+ authorsAreCutoff ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(ChevronButton, { id: authorDistributionExpandId, open: !collapsed, onClick: () => setCollapsed(!collapsed) }) : null
57342
57441
  ] }),
57343
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("div", { className: "grid grid-cols-[1fr,auto] gap-1", children: authorsAreCutoff ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(import_jsx_runtime8.Fragment, { children: [
57344
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuthorDistFragment, { show: !0, items: contribDist.slice(0, authorCutoff) }),
57345
- /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuthorDistFragment, { show: !collapsed, items: contribDist.slice(authorCutoff) }),
57346
- collapsed ? /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
57442
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "grid grid-cols-[1fr,auto] gap-1", children: authorsAreCutoff ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_jsx_runtime10.Fragment, { children: [
57443
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(AuthorDistFragment, { show: !0, items: contribDist.slice(0, authorCutoff) }),
57444
+ /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(AuthorDistFragment, { show: !collapsed, items: contribDist.slice(authorCutoff) }),
57445
+ collapsed ? /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
57347
57446
  "button",
57348
57447
  {
57349
57448
  className: "text-left text-xs opacity-70 hover:opacity-100",
@@ -57355,7 +57454,7 @@ function AuthorDistribution(props) {
57355
57454
  ]
57356
57455
  }
57357
57456
  ) : null
57358
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(import_jsx_runtime8.Fragment, { children: contribDist.length > 0 && !hasZeroContributions(props.authors) ? /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(AuthorDistFragment, { show: !0, items: contribDist }) : /* @__PURE__ */ (0, import_jsx_runtime8.jsx)("p", { children: "No authors found" }) }) })
57457
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_jsx_runtime10.Fragment, { children: contribDist.length > 0 && !hasZeroContributions(props.authors) ? /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(AuthorDistFragment, { show: !0, items: contribDist }) : /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { children: "No authors found" }) }) })
57359
57458
  ] });
57360
57459
  }
57361
57460
  function makePercentResponsibilityDistribution(unionedAuthors) {
@@ -57395,11 +57494,11 @@ function calculateAuthorshipForSubTree(tree, authorshipType) {
57395
57494
  }
57396
57495
 
57397
57496
  // src/components/GlobalInfo.tsx
57398
- var import_react33 = __toESM(require_dist3());
57399
- var import_react34 = __toESM(require_react());
57497
+ var import_react34 = __toESM(require_dist3());
57498
+ var import_react35 = __toESM(require_react());
57400
57499
 
57401
57500
  // src/components/RevisionSelect.tsx
57402
- var import_js5 = __toESM(require_mdi()), import_react16 = __toESM(require_Icon()), import_jsx_runtime9 = __toESM(require_jsx_runtime());
57501
+ var import_js5 = __toESM(require_mdi()), import_react17 = __toESM(require_Icon()), import_jsx_runtime11 = __toESM(require_jsx_runtime());
57403
57502
  function RevisionSelect({
57404
57503
  headGroups,
57405
57504
  analyzedHeads,
@@ -57408,12 +57507,12 @@ function RevisionSelect({
57408
57507
  ...props
57409
57508
  }) {
57410
57509
  let groupsEntries = Object.entries(headGroups);
57411
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsxs)("div", { className: "grid w-full grid-cols-[auto_1fr] place-items-center gap-2", children: [
57412
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(import_react16.Icon, { path: import_js5.mdiSourceBranch, size: 0.75 }),
57413
- /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("select", { className: `input text-gray-800 ${className}`, ...props, children: groupsEntries.map(
57414
- ([group, heads]) => Object.entries(heads).length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime9.jsx)("optgroup", { label: group, children: Object.entries(heads).map(([headName, head]) => {
57510
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "grid w-full grid-cols-[auto_1fr] place-items-center gap-2", children: [
57511
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react17.Icon, { path: import_js5.mdiSourceBranch, size: 0.75 }),
57512
+ /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("select", { className: `input text-gray-800 ${className}`, ...props, children: groupsEntries.map(
57513
+ ([group, heads]) => Object.entries(heads).length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("optgroup", { label: group, children: Object.entries(heads).map(([headName, head]) => {
57415
57514
  let isAnalyzed = analyzedHeads[head];
57416
- return /* @__PURE__ */ (0, import_jsx_runtime9.jsx)(
57515
+ return /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(
57417
57516
  "option",
57418
57517
  {
57419
57518
  value: headName,
@@ -57430,7 +57529,7 @@ function RevisionSelect({
57430
57529
 
57431
57530
  // src/components/GlobalInfo.tsx
57432
57531
  var import_js6 = __toESM(require_mdi());
57433
- var import_react35 = __toESM(require_Icon());
57532
+ var import_react36 = __toESM(require_Icon());
57434
57533
 
57435
57534
  // node_modules/@react-spring/rafz/dist/esm/index.js
57436
57535
  var f = r(), n = (e) => c3(e, f), m = r();
@@ -57526,7 +57625,7 @@ function Q(e, t) {
57526
57625
  }
57527
57626
 
57528
57627
  // node_modules/@react-spring/shared/dist/esm/index.js
57529
- var import_react17 = __toESM(require_react()), import_react18 = __toESM(require_react()), import_react19 = __toESM(require_react()), import_react20 = __toESM(require_react()), import_react21 = __toESM(require_react()), import_react22 = __toESM(require_react()), import_react23 = __toESM(require_react()), import_react24 = __toESM(require_react());
57628
+ var import_react18 = __toESM(require_react()), import_react19 = __toESM(require_react()), import_react20 = __toESM(require_react()), import_react21 = __toESM(require_react()), import_react22 = __toESM(require_react()), import_react23 = __toESM(require_react()), import_react24 = __toESM(require_react()), import_react25 = __toESM(require_react());
57530
57629
  var ze = Object.defineProperty, Le = (e, t) => {
57531
57630
  for (var r2 in t)
57532
57631
  ze(e, r2, { get: t[r2], enumerable: !0 });
@@ -57750,21 +57849,21 @@ function er() {
57750
57849
  function or(e) {
57751
57850
  return l2.str(e) && (e[0] == "#" || /\d/.test(e) || !h2() && b2.test(e) || e in (c4 || {}));
57752
57851
  }
57753
- var Q2 = h2() ? import_react20.useEffect : import_react20.useLayoutEffect, Ce = () => {
57754
- let e = (0, import_react19.useRef)(!1);
57852
+ var Q2 = h2() ? import_react21.useEffect : import_react21.useLayoutEffect, Ce = () => {
57853
+ let e = (0, import_react20.useRef)(!1);
57755
57854
  return Q2(() => (e.current = !0, () => {
57756
57855
  e.current = !1;
57757
57856
  }), []), e;
57758
57857
  };
57759
57858
  function Mr() {
57760
- let e = (0, import_react18.useState)()[1], t = Ce();
57859
+ let e = (0, import_react19.useState)()[1], t = Ce();
57761
57860
  return () => {
57762
57861
  t.current && e(Math.random());
57763
57862
  };
57764
57863
  }
57765
57864
  function Lr(e, t) {
57766
- let [r2] = (0, import_react21.useState)(() => ({ inputs: t, result: e() })), n2 = (0, import_react21.useRef)(), f3 = n2.current, o = f3;
57767
- return o ? t && o.inputs && it(t, o.inputs) || (o = { inputs: t, result: e() }) : o = r2, (0, import_react21.useEffect)(() => {
57865
+ let [r2] = (0, import_react22.useState)(() => ({ inputs: t, result: e() })), n2 = (0, import_react22.useRef)(), f3 = n2.current, o = f3;
57866
+ return o ? t && o.inputs && it(t, o.inputs) || (o = { inputs: t, result: e() }) : o = r2, (0, import_react22.useEffect)(() => {
57768
57867
  n2.current = o, f3 == r2 && (r2.inputs = r2.result = void 0);
57769
57868
  }, [o]), o.result;
57770
57869
  }
@@ -57776,19 +57875,19 @@ function it(e, t) {
57776
57875
  return !1;
57777
57876
  return !0;
57778
57877
  }
57779
- var $r = (e) => (0, import_react22.useEffect)(e, ut), ut = [];
57878
+ var $r = (e) => (0, import_react23.useEffect)(e, ut), ut = [];
57780
57879
  function Ur(e) {
57781
- let t = (0, import_react23.useRef)();
57782
- return (0, import_react23.useEffect)(() => {
57880
+ let t = (0, import_react24.useRef)();
57881
+ return (0, import_react24.useEffect)(() => {
57783
57882
  t.current = e;
57784
57883
  }), t.current;
57785
57884
  }
57786
57885
 
57787
57886
  // node_modules/@react-spring/core/dist/esm/index.js
57788
- var import_react26 = __toESM(require_react());
57887
+ var import_react27 = __toESM(require_react());
57789
57888
 
57790
57889
  // node_modules/@react-spring/animated/dist/esm/index.js
57791
- var O2 = __toESM(require_react()), import_react25 = __toESM(require_react());
57890
+ var O2 = __toESM(require_react()), import_react26 = __toESM(require_react());
57792
57891
  var h3 = Symbol.for("Animated:node"), v2 = (e) => !!e && e[h3] === e, k2 = (e) => e && e[h3], D2 = (e, t) => mt(e, h3, t), F = (e) => e && e[h3] && e[h3].getPayload(), c5 = class {
57793
57892
  payload;
57794
57893
  constructor() {
@@ -57900,16 +57999,16 @@ function Le2(e) {
57900
57999
  }
57901
58000
  var x2 = (e, t) => {
57902
58001
  let r2 = !l2.fun(e) || e.prototype && e.prototype.isReactComponent;
57903
- return (0, import_react25.forwardRef)((n2, a) => {
57904
- let i2 = (0, import_react25.useRef)(null), o = r2 && (0, import_react25.useCallback)((s) => {
58002
+ return (0, import_react26.forwardRef)((n2, a) => {
58003
+ let i2 = (0, import_react26.useRef)(null), o = r2 && (0, import_react26.useCallback)((s) => {
57905
58004
  i2.current = ae2(a, s);
57906
58005
  }, [a]), [m3, T2] = ne2(n2, t), W3 = Mr(), P2 = () => {
57907
58006
  let s = i2.current;
57908
58007
  r2 && !s || (s ? t.applyAnimatedValues(s, m3.getValue(!0)) : !1) === !1 && W3();
57909
- }, _3 = new b3(P2, T2), p3 = (0, import_react25.useRef)();
58008
+ }, _3 = new b3(P2, T2), p3 = (0, import_react26.useRef)();
57910
58009
  Q2(() => (p3.current = _3, Ve(T2, (s) => Gt(s, _3)), () => {
57911
58010
  p3.current && (Ve(p3.current.deps, (s) => Qt(s, p3.current)), n.cancel(p3.current.update));
57912
- })), (0, import_react25.useEffect)(P2, []), $r(() => () => {
58011
+ })), (0, import_react26.useEffect)(P2, []), $r(() => () => {
57913
58012
  let s = p3.current;
57914
58013
  Ve(s.deps, (S2) => Qt(S2, s));
57915
58014
  });
@@ -57942,10 +58041,10 @@ var j2 = Symbol.for("AnimatedComponent"), Ke2 = (e, { applyAnimatedValues: t = (
57942
58041
  }, I = (e) => l2.str(e) ? e : e && l2.str(e.displayName) ? e.displayName : l2.fun(e) && e.name || null;
57943
58042
 
57944
58043
  // node_modules/@react-spring/core/dist/esm/index.js
57945
- var Be2 = __toESM(require_react()), import_react27 = __toESM(require_react());
57946
- var import_react28 = __toESM(require_react());
57947
- var Oe2 = __toESM(require_react()), import_react29 = __toESM(require_react());
57948
- var import_react30 = __toESM(require_react());
58044
+ var Be2 = __toESM(require_react()), import_react28 = __toESM(require_react());
58045
+ var import_react29 = __toESM(require_react());
58046
+ var Oe2 = __toESM(require_react()), import_react30 = __toESM(require_react());
58047
+ var import_react31 = __toESM(require_react());
57949
58048
  function I2(t, ...e) {
57950
58049
  return l2.fun(t) ? t(...e) : t;
57951
58050
  }
@@ -58583,7 +58682,7 @@ function jt(t, e) {
58583
58682
  });
58584
58683
  }
58585
58684
  var H3 = ({ children: t, ...e }) => {
58586
- let n2 = (0, import_react27.useContext)(Ge2), r2 = e.pause || !!n2.pause, o = e.immediate || !!n2.immediate;
58685
+ let n2 = (0, import_react28.useContext)(Ge2), r2 = e.pause || !!n2.pause, o = e.immediate || !!n2.immediate;
58587
58686
  e = Lr(() => ({ pause: r2, immediate: o }), [r2, o]);
58588
58687
  let { Provider: s } = Ge2;
58589
58688
  return Be2.createElement(s, { value: e }, t);
@@ -58643,19 +58742,19 @@ var fe2 = () => {
58643
58742
  function He2(t, e, n2) {
58644
58743
  let r2 = l2.fun(e) && e;
58645
58744
  r2 && !n2 && (n2 = []);
58646
- let o = (0, import_react26.useMemo)(() => r2 || arguments.length == 3 ? fe2() : void 0, []), s = (0, import_react26.useRef)(0), i2 = Mr(), a = (0, import_react26.useMemo)(() => ({ ctrls: [], queue: [], flush(h5, g3) {
58745
+ let o = (0, import_react27.useMemo)(() => r2 || arguments.length == 3 ? fe2() : void 0, []), s = (0, import_react27.useRef)(0), i2 = Mr(), a = (0, import_react27.useMemo)(() => ({ ctrls: [], queue: [], flush(h5, g3) {
58647
58746
  let x4 = _e2(h5, g3);
58648
58747
  return s.current > 0 && !a.queue.length && !Object.keys(x4).some((A2) => !h5.springs[A2]) ? ze2(h5, g3) : new Promise((A2) => {
58649
58748
  pt(h5, x4), a.queue.push(() => {
58650
58749
  A2(ze2(h5, g3));
58651
58750
  }), i2();
58652
58751
  });
58653
- } }), []), u4 = (0, import_react26.useRef)([...a.ctrls]), p3 = [], f3 = Ur(t) || 0;
58654
- (0, import_react26.useMemo)(() => {
58752
+ } }), []), u4 = (0, import_react27.useRef)([...a.ctrls]), p3 = [], f3 = Ur(t) || 0;
58753
+ (0, import_react27.useMemo)(() => {
58655
58754
  Ve(u4.current.slice(t, f3), (h5) => {
58656
58755
  xe2(h5, o), h5.stop(!0);
58657
58756
  }), u4.current.length = t, d4(f3, t);
58658
- }, [t]), (0, import_react26.useMemo)(() => {
58757
+ }, [t]), (0, import_react27.useMemo)(() => {
58659
58758
  d4(0, Math.min(f3, t));
58660
58759
  }, n2);
58661
58760
  function d4(h5, g3) {
@@ -58664,7 +58763,7 @@ function He2(t, e, n2) {
58664
58763
  A2 && (p3[x4] = Ot(A2));
58665
58764
  }
58666
58765
  }
58667
- let m3 = u4.current.map((h5, g3) => _e2(h5, p3[g3])), b4 = (0, import_react26.useContext)(H3), c7 = Ur(b4), P2 = b4 !== c7 && Ue2(b4);
58766
+ let m3 = u4.current.map((h5, g3) => _e2(h5, p3[g3])), b4 = (0, import_react27.useContext)(H3), c7 = Ur(b4), P2 = b4 !== c7 && Ue2(b4);
58668
58767
  Q2(() => {
58669
58768
  s.current++, a.ctrls = u4.current;
58670
58769
  let { queue: h5 } = a;
@@ -58801,14 +58900,14 @@ p2.assign({ batchedUpdates: import_react_dom.unstable_batchedUpdates, createStri
58801
58900
  var q2 = Ke2(C2, { applyAnimatedValues: V2, createAnimatedStyle: (t) => new g2(t), getComponentProps: ({ scrollTop: t, scrollLeft: e, ...r2 }) => r2 }), it3 = q2.animated;
58802
58901
 
58803
58902
  // src/hooks.ts
58804
- var import_react31 = __toESM(require_react()), import_react32 = __toESM(require_react()), import_react_use = __toESM(require_lib5()), import_react_use_size = __toESM(require_dist7());
58903
+ var import_react32 = __toESM(require_react()), import_react33 = __toESM(require_react()), import_react_use = __toESM(require_lib5()), import_react_use_size = __toESM(require_dist7());
58805
58904
  function useComponentSize() {
58806
58905
  let { ref, width, height } = (0, import_react_use_size.useComponentSize)();
58807
- return (0, import_react32.useMemo)(() => [ref, { width, height }], [ref, width, height]);
58906
+ return (0, import_react33.useMemo)(() => [ref, { width, height }], [ref, width, height]);
58808
58907
  }
58809
58908
  function useToggleableSpring(props) {
58810
58909
  let { transitionsEnabled } = useOptions(), [initialRender, setInitialRender] = (0, import_react_use.useBoolean)(!0);
58811
- return (0, import_react32.useEffect)(() => {
58910
+ return (0, import_react33.useEffect)(() => {
58812
58911
  setTimeout(() => setInitialRender(!1), 0);
58813
58912
  }, [setInitialRender]), J2({
58814
58913
  ...typeof props == "object" ? props : {},
@@ -58816,70 +58915,70 @@ function useToggleableSpring(props) {
58816
58915
  });
58817
58916
  }
58818
58917
  function useClient() {
58819
- let [client, setClient] = (0, import_react31.useState)(!1);
58820
- return (0, import_react32.useEffect)(() => {
58918
+ let [client, setClient] = (0, import_react32.useState)(!1);
58919
+ return (0, import_react33.useEffect)(() => {
58821
58920
  setClient(!0);
58822
58921
  }, [setClient]), client;
58823
58922
  }
58824
58923
 
58825
58924
  // src/components/GlobalInfo.tsx
58826
- var import_clsx3 = __toESM(require_clsx()), import_jsx_runtime10 = __toESM(require_jsx_runtime()), title = "Git Truck", analyzingTitle = "Analyzing | Git Truck", GlobalInfo = (0, import_react34.memo)(function() {
58827
- let client = useClient(), { analyzerData, repo } = useData(), transitionState = (0, import_react33.useNavigation)(), location2 = (0, import_react33.useLocation)(), navigate = (0, import_react33.useNavigate)(), [isAnalyzing, setIsAnalyzing] = (0, import_react34.useState)(!1), [analysisDetailsVisible, setAnalysisDetailsVisible] = (0, import_react34.useState)(!1);
58828
- (0, import_react34.useEffect)(() => {
58925
+ var import_clsx4 = __toESM(require_clsx()), import_jsx_runtime12 = __toESM(require_jsx_runtime()), title = "Git Truck", analyzingTitle = "Analyzing | Git Truck", GlobalInfo = (0, import_react35.memo)(function() {
58926
+ let client = useClient(), { analyzerData, repo } = useData(), transitionState = (0, import_react34.useNavigation)(), location2 = (0, import_react34.useLocation)(), navigate = (0, import_react34.useNavigate)(), [isAnalyzing, setIsAnalyzing] = (0, import_react35.useState)(!1), [analysisDetailsVisible, setAnalysisDetailsVisible] = (0, import_react35.useState)(!1);
58927
+ (0, import_react35.useEffect)(() => {
58829
58928
  document.title = isAnalyzing ? analyzingTitle : title;
58830
58929
  }, [isAnalyzing]);
58831
58930
  let switchBranch = (branch) => {
58832
58931
  setIsAnalyzing(!0), navigate(["", repo.name, branch].join("/"));
58833
58932
  };
58834
- (0, import_react34.useEffect)(() => {
58933
+ (0, import_react35.useEffect)(() => {
58835
58934
  transitionState.state === "idle" && setIsAnalyzing(!1);
58836
58935
  }, [transitionState.state]);
58837
58936
  let isoString = new Date(analyzerData.lastRunEpoch).toISOString();
58838
- return /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("div", { className: "flex flex-col gap-2", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "card", children: [
58839
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex items-center justify-between gap-2", children: [
58840
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "relative flex items-center", children: [
58841
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
58937
+ return /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { className: "flex flex-col gap-2", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "card", children: [
58938
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "flex items-center justify-between gap-2", children: [
58939
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "relative flex items-center", children: [
58940
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
58842
58941
  "button",
58843
58942
  {
58844
58943
  className: "btn--icon btn--primary",
58845
58944
  title: "See analysis details",
58846
58945
  onClick: () => setAnalysisDetailsVisible(!0),
58847
- children: /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react35.Icon, { path: import_js6.mdiInformation, size: "1.5em" })
58946
+ children: /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react36.Icon, { path: import_js6.mdiInformation, size: "1.5em" })
58848
58947
  }
58849
58948
  ),
58850
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
58949
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
58851
58950
  "div",
58852
58951
  {
58853
- className: (0, import_clsx3.default)("card absolute left-0 top-0 z-10 h-max w-max shadow transition-opacity", {
58952
+ className: (0, import_clsx4.default)("card absolute left-0 top-0 z-10 h-max w-max shadow transition-opacity", {
58854
58953
  "hidden opacity-0": !analysisDetailsVisible
58855
58954
  }),
58856
58955
  children: [
58857
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("h2", { className: "card__title", children: "Analysis details" }),
58858
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(CloseButton, { onClick: () => setAnalysisDetailsVisible(!1) }),
58859
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "grid auto-rows-fr grid-cols-2 gap-0", children: [
58860
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { children: "Analyzed" }),
58861
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("time", { className: "text-right", dateTime: isoString, title: isoString, children: client ? dateTimeFormatShort(analyzerData.lastRunEpoch) : "" }),
58862
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { children: "As of commit" }),
58863
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-right", title: analyzerData.commit.message ?? "No commit message", children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(Code, { inline: !0, children: [
58956
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("h2", { className: "card__title", children: "Analysis details" }),
58957
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(CloseButton, { onClick: () => setAnalysisDetailsVisible(!1) }),
58958
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "grid auto-rows-fr grid-cols-2 gap-0", children: [
58959
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { children: "Analyzed" }),
58960
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("time", { className: "text-right", dateTime: isoString, title: isoString, children: client ? dateTimeFormatShort(analyzerData.lastRunEpoch) : "" }),
58961
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { children: "As of commit" }),
58962
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { className: "text-right", title: analyzerData.commit.message ?? "No commit message", children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(Code, { inline: !0, children: [
58864
58963
  "#",
58865
58964
  analyzerData.commit.hash.slice(0, 7)
58866
58965
  ] }) }),
58867
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { children: "Files analyzed" }),
58868
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("span", { className: "text-right", children: analyzerData.commit.fileCount ?? 0 })
58966
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { children: "Files analyzed" }),
58967
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("span", { className: "text-right", children: analyzerData.commit.fileCount ?? 0 })
58869
58968
  ] })
58870
58969
  ]
58871
58970
  }
58872
58971
  )
58873
58972
  ] }),
58874
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("h2", { className: "card__title grow justify-start gap-2", title: repo.name, children: repo.name })
58973
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("h2", { className: "card__title grow justify-start gap-2", title: repo.name, children: repo.name })
58875
58974
  ] }),
58876
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { className: "flex w-full auto-cols-max place-items-stretch gap-2", children: [
58877
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(import_react33.Link, { className: "btn btn--primary grow", to: "..", title: "See all repositories", children: [
58878
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react35.Icon, { path: import_js6.mdiArrowTopLeft, size: 0.75 }),
58879
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("p", { children: "See more repositories" })
58975
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "flex w-full auto-cols-max place-items-stretch gap-2", children: [
58976
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(import_react34.Link, { className: "btn btn--primary grow", to: "..", title: "See all repositories", children: [
58977
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react36.Icon, { path: import_js6.mdiArrowTopLeft, size: 0.75 }),
58978
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("p", { children: "See more repositories" })
58880
58979
  ] }),
58881
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)(
58882
- import_react33.Form,
58980
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)(
58981
+ import_react34.Form,
58883
58982
  {
58884
58983
  method: "post",
58885
58984
  action: location2.pathname,
@@ -58887,16 +58986,16 @@ var import_clsx3 = __toESM(require_clsx()), import_jsx_runtime10 = __toESM(requi
58887
58986
  setIsAnalyzing(!0);
58888
58987
  },
58889
58988
  children: [
58890
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)("input", { type: "hidden", name: "refresh", value: "true" }),
58891
- /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("button", { className: "btn", disabled: transitionState.state !== "idle", children: [
58892
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(import_react35.Icon, { path: import_js6.mdiRefresh, size: "1.25em" }),
58989
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("input", { type: "hidden", name: "refresh", value: "true" }),
58990
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("button", { className: "btn", disabled: transitionState.state !== "idle", children: [
58991
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_react36.Icon, { path: import_js6.mdiRefresh, size: "1.25em" }),
58893
58992
  isAnalyzing ? "Analyzing..." : "Refresh"
58894
58993
  ] })
58895
58994
  ]
58896
58995
  }
58897
58996
  )
58898
58997
  ] }),
58899
- /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(
58998
+ /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
58900
58999
  RevisionSelect,
58901
59000
  {
58902
59001
  disabled: isAnalyzing,
@@ -58912,62 +59011,62 @@ var import_clsx3 = __toESM(require_clsx()), import_jsx_runtime10 = __toESM(requi
58912
59011
 
58913
59012
  // src/components/HiddenFiles.tsx
58914
59013
  var import_react_use2 = __toESM(require_lib5());
58915
- var import_react36 = __toESM(require_dist3()), import_js7 = __toESM(require_mdi());
58916
- var import_react37 = __toESM(require_Icon()), import_react38 = __toESM(require_react()), import_jsx_runtime11 = __toESM(require_jsx_runtime());
59014
+ var import_react37 = __toESM(require_dist3()), import_js7 = __toESM(require_mdi());
59015
+ var import_react38 = __toESM(require_Icon()), import_react39 = __toESM(require_react()), import_jsx_runtime13 = __toESM(require_jsx_runtime());
58917
59016
  function hiddenFileFormat(ignored) {
58918
59017
  if (!ignored.includes("/"))
58919
59018
  return ignored;
58920
59019
  let split = ignored.split("/");
58921
59020
  return split[split.length - 1];
58922
59021
  }
58923
- var HiddenFiles = (0, import_react38.memo)(function() {
58924
- let location2 = (0, import_react36.useLocation)(), [expanded, setExpanded] = (0, import_react_use2.useBoolean)(!1), navigationState = (0, import_react36.useNavigation)(), { analyzerData } = useData(), expandHiddenFilesButtonId = (0, import_react38.useId)();
58925
- return /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "card flex flex-col gap-2", children: [
58926
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
59022
+ var HiddenFiles = (0, import_react39.memo)(function() {
59023
+ let location2 = (0, import_react37.useLocation)(), [expanded, setExpanded] = (0, import_react_use2.useBoolean)(!1), navigationState = (0, import_react37.useNavigation)(), { analyzerData } = useData(), expandHiddenFilesButtonId = (0, import_react39.useId)();
59024
+ return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "card flex flex-col gap-2", children: [
59025
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
58927
59026
  "h2",
58928
59027
  {
58929
59028
  className: "card__title cursor-pointer justify-start gap-2 hover:opacity-70",
58930
59029
  onClick: () => setExpanded(!expanded),
58931
59030
  role: "button",
58932
59031
  children: [
58933
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react37.Icon, { path: import_js7.mdiEyeOff, size: "1.25em" }),
59032
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react38.Icon, { path: import_js7.mdiEyeOff, size: "1.25em" }),
58934
59033
  "Hidden files (",
58935
59034
  analyzerData.hiddenFiles.length,
58936
59035
  ")",
58937
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(ChevronButton, { id: expandHiddenFilesButtonId, className: "absolute right-2 top-2", open: expanded })
59036
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(ChevronButton, { id: expandHiddenFilesButtonId, className: "absolute right-2 top-2", open: expanded })
58938
59037
  ]
58939
59038
  }
58940
59039
  ),
58941
- expanded ? /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("div", { children: analyzerData.hiddenFiles.map((hidden) => /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)("div", { className: "grid grid-cols-[auto_1fr] gap-2", title: hidden, children: [
58942
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(import_react36.Form, { className: "w-4", method: "post", action: location2.pathname, children: [
58943
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("input", { type: "hidden", name: "unignore", value: hidden }),
58944
- /* @__PURE__ */ (0, import_jsx_runtime11.jsxs)(
59040
+ expanded ? /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("div", { children: analyzerData.hiddenFiles.map((hidden) => /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "grid grid-cols-[auto_1fr] gap-2", title: hidden, children: [
59041
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_react37.Form, { className: "w-4", method: "post", action: location2.pathname, children: [
59042
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("input", { type: "hidden", name: "unignore", value: hidden }),
59043
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(
58945
59044
  "button",
58946
59045
  {
58947
59046
  className: "btn--icon btn--hover-swap h-4",
58948
59047
  title: "Show file",
58949
59048
  disabled: navigationState.state !== "idle",
58950
59049
  children: [
58951
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react37.Icon, { path: import_js7.mdiEyeOff, className: "inline-block h-full" }),
58952
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)(import_react37.Icon, { path: import_js7.mdiEye, className: "hover-swap inline-block h-full" })
59050
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react38.Icon, { path: import_js7.mdiEyeOff, className: "inline-block h-full" }),
59051
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(import_react38.Icon, { path: import_js7.mdiEye, className: "hover-swap inline-block h-full" })
58953
59052
  ]
58954
59053
  }
58955
59054
  )
58956
59055
  ] }),
58957
- /* @__PURE__ */ (0, import_jsx_runtime11.jsx)("span", { className: "text-sm opacity-70", children: hiddenFileFormat(hidden) })
59056
+ /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "text-sm opacity-70", children: hiddenFileFormat(hidden) })
58958
59057
  ] }, hidden)) }) : null
58959
59058
  ] });
58960
59059
  });
58961
59060
 
58962
59061
  // src/components/legend/Legend.tsx
58963
- var import_js8 = __toESM(require_mdi()), import_react40 = __toESM(require_Icon());
59062
+ var import_js8 = __toESM(require_mdi()), import_react41 = __toESM(require_Icon());
58964
59063
 
58965
59064
  // src/components/legend/SegmentLegend.tsx
58966
- var import_jsx_runtime12 = __toESM(require_jsx_runtime());
59065
+ var import_jsx_runtime14 = __toESM(require_jsx_runtime());
58967
59066
  function SegmentLegend({ hoveredObject, metricCache }) {
58968
59067
  let [steps, textGenerator, colorGenerator, offsetStepCalc] = metricCache.legend, width = 100 / steps, arrowVisible = !1, arrowOffset = 0, clickedObject = useClickedObject().clickedObject ?? hoveredObject ?? null;
58969
- return isBlob(clickedObject) && (arrowVisible = !0, arrowOffset = width / 2 + width * offsetStepCalc(clickedObject)), /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(import_jsx_runtime12.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { className: "relative", children: [
58970
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { className: "flex", children: [...Array(steps)].map((_3, i2) => steps >= 4 ? /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
59068
+ return isBlob(clickedObject) && (arrowVisible = !0, arrowOffset = width / 2 + width * offsetStepCalc(clickedObject)), /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_jsx_runtime14.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: "relative", children: [
59069
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { className: "flex", children: [...Array(steps)].map((_3, i2) => steps >= 4 ? /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
58971
59070
  MetricSegment,
58972
59071
  {
58973
59072
  width,
@@ -58976,7 +59075,7 @@ function SegmentLegend({ hoveredObject, metricCache }) {
58976
59075
  top: i2 % 2 === 0
58977
59076
  },
58978
59077
  `legend-${i2}`
58979
- ) : /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(
59078
+ ) : /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(
58980
59079
  TopMetricSegment,
58981
59080
  {
58982
59081
  width,
@@ -58985,84 +59084,84 @@ function SegmentLegend({ hoveredObject, metricCache }) {
58985
59084
  },
58986
59085
  `legend-${i2}`
58987
59086
  )) }),
58988
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)(LegendBarIndicator, { offset: arrowOffset, visible: arrowVisible })
59087
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(LegendBarIndicator, { offset: arrowOffset, visible: arrowVisible })
58989
59088
  ] }) });
58990
59089
  }
58991
59090
  function MetricSegment({ width, color, text, top }) {
58992
- return top ? /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
58993
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-6px" }, children: text }),
58994
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-2px" }, children: "/" }),
58995
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { backgroundColor: color, height: "20px" } }),
58996
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "40px" } })
58997
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
58998
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "32px" } }),
58999
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { backgroundColor: color, height: "20px" } }),
59000
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginTop: "-7px" }, children: "\\" }),
59001
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginTop: "-4px" }, children: text })
59091
+ return top ? /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
59092
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-6px" }, children: text }),
59093
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-2px" }, children: "/" }),
59094
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { backgroundColor: color, height: "20px" } }),
59095
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "40px" } })
59096
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
59097
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "32px" } }),
59098
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { backgroundColor: color, height: "20px" } }),
59099
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginTop: "-7px" }, children: "\\" }),
59100
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginTop: "-4px" }, children: text })
59002
59101
  ] });
59003
59102
  }
59004
59103
  function TopMetricSegment({ width, color, text }) {
59005
- return /* @__PURE__ */ (0, import_jsx_runtime12.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
59006
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-6px" }, children: text }),
59007
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-2px" }, children: "/" }),
59008
- /* @__PURE__ */ (0, import_jsx_runtime12.jsx)("div", { style: { backgroundColor: color, height: "20px" } })
59104
+ return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { style: { display: "flex", flexDirection: "column", width: `${width}%` }, children: [
59105
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-6px" }, children: text }),
59106
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { textAlign: "left", height: "20px", marginBottom: "-2px" }, children: "/" }),
59107
+ /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("div", { style: { backgroundColor: color, height: "20px" } })
59009
59108
  ] });
59010
59109
  }
59011
59110
 
59012
59111
  // src/components/legend/GradiantLegend.tsx
59013
- var import_react39 = __toESM(require_react());
59014
- var import_jsx_runtime13 = __toESM(require_jsx_runtime());
59112
+ var import_react40 = __toESM(require_react());
59113
+ var import_jsx_runtime15 = __toESM(require_jsx_runtime());
59015
59114
  function GradientLegend({ hoveredObject, metricCache }) {
59016
- let [minValue, maxValue, minValueAltFormat, maxValueAltFormat, minColor, maxColor] = metricCache.legend, { clickedObject } = useClickedObject(), path = (clickedObject == null ? void 0 : clickedObject.path) ?? (hoveredObject == null ? void 0 : hoveredObject.path) ?? null, color = path ? metricCache.colormap.get(path) : null, blobLightness = color ? getLightness(color) : -1, offset = (0, import_react39.useMemo)(() => {
59115
+ let [minValue, maxValue, minValueAltFormat, maxValueAltFormat, minColor, maxColor] = metricCache.legend, { clickedObject } = useClickedObject(), path = (clickedObject == null ? void 0 : clickedObject.path) ?? (hoveredObject == null ? void 0 : hoveredObject.path) ?? null, color = path ? metricCache.colormap.get(path) : null, blobLightness = color ? getLightness(color) : -1, offset = (0, import_react40.useMemo)(() => {
59017
59116
  let min = getLightness(minColor), diff = getLightness(maxColor) - min;
59018
59117
  return diff === 0 ? 1 : (blobLightness - min) / diff;
59019
59118
  }, [blobLightness, maxColor, minColor]), visible = path !== null;
59020
- return /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)(import_jsx_runtime13.Fragment, { children: [
59021
- /* @__PURE__ */ (0, import_jsx_runtime13.jsxs)("div", { className: "flex justify-between", children: [
59022
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "font-bold", title: minValueAltFormat, children: minValue }),
59023
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)("span", { className: "font-bold", title: maxValueAltFormat, children: maxValue })
59119
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(import_jsx_runtime15.Fragment, { children: [
59120
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)("div", { className: "flex justify-between", children: [
59121
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "font-bold", title: minValueAltFormat, children: minValue }),
59122
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("span", { className: "font-bold", title: maxValueAltFormat, children: maxValue })
59024
59123
  ] }),
59025
- /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(
59124
+ /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(
59026
59125
  "div",
59027
59126
  {
59028
59127
  className: "relative h-6 w-full rounded-full",
59029
59128
  style: {
59030
59129
  backgroundImage: `linear-gradient(to right, ${minColor}, ${maxColor})`
59031
59130
  },
59032
- children: /* @__PURE__ */ (0, import_jsx_runtime13.jsx)(LegendBarIndicator, { offset: offset * 100, visible })
59131
+ children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(LegendBarIndicator, { offset: offset * 100, visible })
59033
59132
  }
59034
59133
  )
59035
59134
  ] });
59036
59135
  }
59037
59136
 
59038
59137
  // src/components/legend/Legend.tsx
59039
- var import_react41 = __toESM(require_react()), import_jsx_runtime14 = __toESM(require_jsx_runtime());
59138
+ var import_react42 = __toESM(require_react()), import_jsx_runtime16 = __toESM(require_jsx_runtime());
59040
59139
  function Legend({
59041
59140
  hoveredObject,
59042
59141
  showUnionAuthorsModal,
59043
59142
  className = ""
59044
59143
  }) {
59045
- let { metricType, authorshipType } = useOptions(), [metricsData] = useMetrics(), deferredHoveredObject = (0, import_react41.useDeferredValue)(hoveredObject), metricCache = metricsData[authorshipType].get(metricType) ?? void 0;
59144
+ let { metricType, authorshipType } = useOptions(), [metricsData] = useMetrics(), deferredHoveredObject = (0, import_react42.useDeferredValue)(hoveredObject), metricCache = metricsData[authorshipType].get(metricType) ?? void 0;
59046
59145
  if (metricCache === void 0)
59047
59146
  return null;
59048
- let legend = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_jsx_runtime14.Fragment, {});
59147
+ let legend = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_jsx_runtime16.Fragment, {});
59049
59148
  switch (getMetricLegendType(metricType)) {
59050
59149
  case "POINT":
59051
- legend = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(PointLegend, { metricCache, hoveredObject: deferredHoveredObject });
59150
+ legend = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(PointLegend, { metricCache, hoveredObject: deferredHoveredObject });
59052
59151
  break;
59053
59152
  case "GRADIENT":
59054
- legend = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(GradientLegend, { metricCache, hoveredObject: deferredHoveredObject });
59153
+ legend = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(GradientLegend, { metricCache, hoveredObject: deferredHoveredObject });
59055
59154
  break;
59056
59155
  case "SEGMENTS":
59057
- legend = /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(SegmentLegend, { metricCache, hoveredObject: deferredHoveredObject });
59156
+ legend = /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(SegmentLegend, { metricCache, hoveredObject: deferredHoveredObject });
59058
59157
  break;
59059
59158
  }
59060
- return /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("div", { className: `card flex-shrink-0 overflow-hidden ${className}`, children: [
59061
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("h2", { className: "card__title", children: "Legend" }),
59062
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("h3", { className: "card__subtitle", children: Metric[metricType] }),
59063
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)("p", { className: "card-p", children: getMetricDescription(metricType, authorshipType) }),
59064
- metricType === "TOP_CONTRIBUTOR" || metricType === "SINGLE_AUTHOR" ? /* @__PURE__ */ (0, import_jsx_runtime14.jsxs)("button", { className: "btn", onClick: showUnionAuthorsModal, children: [
59065
- /* @__PURE__ */ (0, import_jsx_runtime14.jsx)(import_react40.Icon, { path: import_js8.mdiAccountMultiple }),
59159
+ return /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: `card flex-shrink-0 overflow-hidden ${className}`, children: [
59160
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("h2", { className: "card__title", children: "Legend" }),
59161
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("h3", { className: "card__subtitle", children: Metric[metricType] }),
59162
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("p", { className: "card-p", children: getMetricDescription(metricType, authorshipType) }),
59163
+ metricType === "TOP_CONTRIBUTOR" || metricType === "SINGLE_AUTHOR" ? /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("button", { className: "btn", onClick: showUnionAuthorsModal, children: [
59164
+ /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react41.Icon, { path: import_js8.mdiAccountMultiple }),
59066
59165
  "Group authors"
59067
59166
  ] }) : null,
59068
59167
  legend
@@ -59070,19 +59169,19 @@ function Legend({
59070
59169
  }
59071
59170
 
59072
59171
  // src/components/EnumSelect.tsx
59073
- var import_react42 = __toESM(require_Icon()), import_clsx4 = __toESM(require_clsx()), import_jsx_runtime15 = __toESM(require_jsx_runtime());
59172
+ var import_react43 = __toESM(require_Icon()), import_clsx5 = __toESM(require_clsx()), import_jsx_runtime17 = __toESM(require_jsx_runtime());
59074
59173
  function EnumSelect(props) {
59075
59174
  let enumEntries = Object.entries(props.enum);
59076
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)("div", { className: "flex flex-wrap gap-0", children: enumEntries.map(([key, value]) => /* @__PURE__ */ (0, import_jsx_runtime15.jsxs)(
59175
+ return /* @__PURE__ */ (0, import_jsx_runtime17.jsx)("div", { className: "flex flex-wrap gap-0", children: enumEntries.map(([key, value]) => /* @__PURE__ */ (0, import_jsx_runtime17.jsxs)(
59077
59176
  "button",
59078
59177
  {
59079
- className: (0, import_clsx4.default)("btn flex h-auto w-max justify-between gap-2 rounded-lg px-1 py-1 text-xs/none", {
59178
+ className: (0, import_clsx5.default)("btn flex h-auto w-max justify-between gap-2 rounded-lg px-1 py-1 text-xs/none", {
59080
59179
  "btn--primary": key === props.defaultValue,
59081
59180
  "btn--outlined border-transparent hover:text-blue-500": key !== props.defaultValue
59082
59181
  }),
59083
59182
  onClick: () => props.onChange(key),
59084
59183
  children: [
59085
- /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(import_react42.default, { path: props.iconMap[key], size: "1rem" }),
59184
+ /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(import_react43.default, { path: props.iconMap[key], size: "1rem" }),
59086
59185
  value
59087
59186
  ]
59088
59187
  },
@@ -59091,10 +59190,10 @@ function EnumSelect(props) {
59091
59190
  }
59092
59191
 
59093
59192
  // src/components/Options.tsx
59094
- var import_react43 = __toESM(require_Icon()), import_react44 = __toESM(require_react()), import_js9 = __toESM(require_mdi());
59193
+ var import_react44 = __toESM(require_Icon()), import_react45 = __toESM(require_react()), import_js9 = __toESM(require_mdi());
59095
59194
  var import_react_use3 = __toESM(require_lib5());
59096
- var import_jsx_runtime16 = __toESM(require_jsx_runtime());
59097
- var Options2 = (0, import_react44.memo)(function() {
59195
+ var import_jsx_runtime18 = __toESM(require_jsx_runtime());
59196
+ var Options2 = (0, import_react45.memo)(function() {
59098
59197
  let {
59099
59198
  metricType,
59100
59199
  chartType,
@@ -59140,13 +59239,13 @@ var Options2 = (0, import_react44.memo)(function() {
59140
59239
  SINGLE_AUTHOR: "TRUCK_FACTOR",
59141
59240
  LAST_CHANGED: "LAST_CHANGED"
59142
59241
  };
59143
- return /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_jsx_runtime16.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("div", { className: "card", children: [
59144
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59145
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59146
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiPuzzle, size: "1.25em" }),
59242
+ return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_jsx_runtime18.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "card", children: [
59243
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59244
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59245
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiPuzzle, size: "1.25em" }),
59147
59246
  "Layout"
59148
59247
  ] }),
59149
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
59248
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59150
59249
  EnumSelect,
59151
59250
  {
59152
59251
  enum: Chart,
@@ -59156,12 +59255,12 @@ var Options2 = (0, import_react44.memo)(function() {
59156
59255
  }
59157
59256
  )
59158
59257
  ] }),
59159
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59160
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59161
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiPalette, size: "1.25em" }),
59258
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59259
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59260
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiPalette, size: "1.25em" }),
59162
59261
  "Color"
59163
59262
  ] }),
59164
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
59263
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59165
59264
  EnumSelect,
59166
59265
  {
59167
59266
  enum: Metric,
@@ -59176,12 +59275,12 @@ var Options2 = (0, import_react44.memo)(function() {
59176
59275
  }
59177
59276
  )
59178
59277
  ] }),
59179
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59180
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59181
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiImageSizeSelectSmall, size: "1.25em" }),
59278
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59279
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59280
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiImageSizeSelectSmall, size: "1.25em" }),
59182
59281
  "Size"
59183
59282
  ] }),
59184
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
59283
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59185
59284
  EnumSelect,
59186
59285
  {
59187
59286
  enum: SizeMetric,
@@ -59191,12 +59290,12 @@ var Options2 = (0, import_react44.memo)(function() {
59191
59290
  }
59192
59291
  )
59193
59292
  ] }),
59194
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59195
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59196
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiFamilyTree, size: "1.25em" }),
59293
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59294
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59295
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiFamilyTree, size: "1.25em" }),
59197
59296
  "Hiearchy"
59198
59297
  ] }),
59199
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
59298
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59200
59299
  EnumSelect,
59201
59300
  {
59202
59301
  enum: Hierarchy,
@@ -59206,12 +59305,12 @@ var Options2 = (0, import_react44.memo)(function() {
59206
59305
  }
59207
59306
  )
59208
59307
  ] }),
59209
- hierarchyType === "NESTED" ? /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59210
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59211
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiViewModule, size: "1.25em" }),
59308
+ hierarchyType === "NESTED" ? /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59309
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59310
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiViewModule, size: "1.25em" }),
59212
59311
  "Depth"
59213
59312
  ] }),
59214
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(
59313
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59215
59314
  EnumSelect,
59216
59315
  {
59217
59316
  enum: Depth,
@@ -59221,12 +59320,12 @@ var Options2 = (0, import_react44.memo)(function() {
59221
59320
  }
59222
59321
  )
59223
59322
  ] }) : null,
59224
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59225
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59226
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { path: import_js9.mdiCog, size: "1.25em" }),
59323
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("fieldset", { className: "rounded-lg border p-2", children: [
59324
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("legend", { className: "card__title ml-1.5 justify-start gap-2", children: [
59325
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { path: import_js9.mdiCog, size: "1.25em" }),
59227
59326
  "Settings"
59228
59327
  ] }),
59229
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
59328
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
59230
59329
  CheckboxWithLabel,
59231
59330
  {
59232
59331
  className: "text-sm",
@@ -59236,12 +59335,12 @@ var Options2 = (0, import_react44.memo)(function() {
59236
59335
  },
59237
59336
  title: "Enable to sync size metric with color metric",
59238
59337
  children: [
59239
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { className: "ml-1.5", path: import_js9.mdiLink, size: "1.25em" }),
59240
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)("span", { children: "Link size and color option" })
59338
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { className: "ml-1.5", path: import_js9.mdiLink, size: "1.25em" }),
59339
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { children: "Link size and color option" })
59241
59340
  ]
59242
59341
  }
59243
59342
  ),
59244
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
59343
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
59245
59344
  CheckboxWithLabel,
59246
59345
  {
59247
59346
  className: "text-sm",
@@ -59249,12 +59348,12 @@ var Options2 = (0, import_react44.memo)(function() {
59249
59348
  onChange: (e) => setTransitionsEnabled(e.target.checked),
59250
59349
  title: "Disable to improve performance when zooming",
59251
59350
  children: [
59252
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { className: "ml-1.5", path: import_js9.mdiTransition, size: "1.25em" }),
59351
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { className: "ml-1.5", path: import_js9.mdiTransition, size: "1.25em" }),
59253
59352
  "Transitions"
59254
59353
  ]
59255
59354
  }
59256
59355
  ),
59257
- /* @__PURE__ */ (0, import_jsx_runtime16.jsxs)(
59356
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
59258
59357
  CheckboxWithLabel,
59259
59358
  {
59260
59359
  className: "text-sm",
@@ -59262,7 +59361,7 @@ var Options2 = (0, import_react44.memo)(function() {
59262
59361
  onChange: (e) => setLabelsVisible(e.target.checked),
59263
59362
  title: "Disable to improve performance",
59264
59363
  children: [
59265
- /* @__PURE__ */ (0, import_jsx_runtime16.jsx)(import_react43.Icon, { className: "ml-1.5", path: import_js9.mdiLabel, size: "1.25em" }),
59364
+ /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react44.Icon, { className: "ml-1.5", path: import_js9.mdiLabel, size: "1.25em" }),
59266
59365
  "Labels"
59267
59366
  ]
59268
59367
  }
@@ -59272,21 +59371,21 @@ var Options2 = (0, import_react44.memo)(function() {
59272
59371
  });
59273
59372
 
59274
59373
  // src/components/Providers.tsx
59275
- var import_react46 = __toESM(require_react());
59374
+ var import_react47 = __toESM(require_react());
59276
59375
 
59277
59376
  // src/contexts/SearchContext.ts
59278
- var import_react45 = __toESM(require_react()), SearchContext = (0, import_react45.createContext)(void 0);
59377
+ var import_react46 = __toESM(require_react()), SearchContext = (0, import_react46.createContext)(void 0);
59279
59378
  function useSearch() {
59280
- let context = (0, import_react45.useContext)(SearchContext);
59379
+ let context = (0, import_react46.useContext)(SearchContext);
59281
59380
  if (!context)
59282
59381
  throw new Error("useSearch must be used within a SearchProvider");
59283
59382
  return context;
59284
59383
  }
59285
59384
 
59286
59385
  // src/components/Providers.tsx
59287
- var import_jsx_runtime17 = __toESM(require_jsx_runtime());
59386
+ var import_jsx_runtime19 = __toESM(require_jsx_runtime());
59288
59387
  function Providers({ children, data }) {
59289
- let [options, setOptions] = (0, import_react46.useState)(null), [searchResults, setSearchResults] = (0, import_react46.useState)({}), [path, setPath] = (0, import_react46.useState)(data.repo.name), [clickedObject, setClickedObject] = (0, import_react46.useState)(null), metricsData = (0, import_react46.useMemo)(() => createMetricData(data.analyzerData), [data]), optionsValue = (0, import_react46.useMemo)(
59388
+ let [options, setOptions] = (0, import_react47.useState)(null), [searchResults, setSearchResults] = (0, import_react47.useState)({}), [path, setPath] = (0, import_react47.useState)(data.repo.name), [clickedObject, setClickedObject] = (0, import_react47.useState)(null), metricsData = (0, import_react47.useMemo)(() => createMetricData(data.analyzerData), [data]), optionsValue = (0, import_react47.useMemo)(
59290
59389
  () => ({
59291
59390
  ...getDefaultOptionsContextValue(),
59292
59391
  ...options,
@@ -59330,35 +59429,35 @@ function Providers({ children, data }) {
59330
59429
  }),
59331
59430
  [options]
59332
59431
  );
59333
- return (0, import_react46.useEffect)(() => {
59432
+ return (0, import_react47.useEffect)(() => {
59334
59433
  let canceled = !1;
59335
59434
  return options && requestAnimationFrame(() => {
59336
59435
  canceled || localStorage.setItem(OPTIONS_LOCAL_STORAGE_KEY, JSON.stringify(options));
59337
59436
  }), () => {
59338
59437
  canceled = !0;
59339
59438
  };
59340
- }, [options]), (0, import_react46.useEffect)(() => {
59439
+ }, [options]), (0, import_react47.useEffect)(() => {
59341
59440
  let savedOptions = localStorage.getItem(OPTIONS_LOCAL_STORAGE_KEY);
59342
59441
  savedOptions && setOptions({
59343
59442
  ...getDefaultOptionsContextValue(JSON.parse(savedOptions)),
59344
59443
  hasLoadedSavedOptions: !0
59345
59444
  });
59346
- }, []), /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(DataContext.Provider, { value: data, children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(MetricsContext.Provider, { value: metricsData, children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(OptionsContext.Provider, { value: optionsValue, children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(
59445
+ }, []), /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(DataContext.Provider, { value: data, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(MetricsContext.Provider, { value: metricsData, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(OptionsContext.Provider, { value: optionsValue, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59347
59446
  SearchContext.Provider,
59348
59447
  {
59349
59448
  value: {
59350
59449
  searchResults,
59351
59450
  setSearchResults
59352
59451
  },
59353
- children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(PathContext.Provider, { value: { path, setPath }, children: /* @__PURE__ */ (0, import_jsx_runtime17.jsx)(ClickedObjectContext.Provider, { value: { clickedObject, setClickedObject }, children }) })
59452
+ children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(PathContext.Provider, { value: { path, setPath }, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(ClickedObjectContext.Provider, { value: { clickedObject, setClickedObject }, children }) })
59354
59453
  }
59355
59454
  ) }) }) });
59356
59455
  }
59357
59456
 
59358
59457
  // src/components/SearchCard.tsx
59359
- var import_react47 = __toESM(require_react());
59360
59458
  var import_react48 = __toESM(require_react());
59361
- var import_react49 = __toESM(require_Icon()), import_js10 = __toESM(require_mdi()), import_jsx_runtime18 = __toESM(require_jsx_runtime());
59459
+ var import_react49 = __toESM(require_react());
59460
+ var import_react50 = __toESM(require_Icon()), import_js10 = __toESM(require_mdi()), import_jsx_runtime20 = __toESM(require_jsx_runtime());
59362
59461
  function findSearchResults(tree, searchString) {
59363
59462
  let searchResults = {};
59364
59463
  function subTreeSearch(subTree) {
@@ -59367,9 +59466,9 @@ function findSearchResults(tree, searchString) {
59367
59466
  }
59368
59467
  return subTreeSearch(tree), searchResults;
59369
59468
  }
59370
- var SearchCard = (0, import_react47.memo)(function() {
59371
- let searchFieldRef = (0, import_react47.useRef)(null), [isTransitioning, startTransition] = (0, import_react47.useTransition)(), [searchText, setSearchText] = (0, import_react47.useState)(""), { searchResults, setSearchResults } = useSearch(), searchResultsArray = (0, import_react47.useMemo)(() => Object.values(searchResults), [searchResults]), id = (0, import_react48.useId)(), { analyzerData } = useData();
59372
- return (0, import_react47.useEffect)(() => {
59469
+ var SearchCard = (0, import_react48.memo)(function() {
59470
+ let searchFieldRef = (0, import_react48.useRef)(null), [isTransitioning, startTransition] = (0, import_react48.useTransition)(), [searchText, setSearchText] = (0, import_react48.useState)(""), { searchResults, setSearchResults } = useSearch(), searchResultsArray = (0, import_react48.useMemo)(() => Object.values(searchResults), [searchResults]), id = (0, import_react49.useId)(), { analyzerData } = useData();
59471
+ return (0, import_react48.useEffect)(() => {
59373
59472
  let searchOverride = (event) => {
59374
59473
  var _a2;
59375
59474
  event.ctrlKey && event.key === "f" && (event.preventDefault(), (_a2 = searchFieldRef.current) == null || _a2.focus());
@@ -59377,14 +59476,14 @@ var SearchCard = (0, import_react47.memo)(function() {
59377
59476
  return document.body.addEventListener("keydown", searchOverride), () => {
59378
59477
  document.body.removeEventListener("keydown", searchOverride);
59379
59478
  };
59380
- }, []), /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(import_jsx_runtime18.Fragment, { children: [
59381
- /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "card sticky top-0 z-10 flex flex-col gap-2", children: [
59382
- /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("h2", { className: "card__title justify-start gap-2", children: [
59383
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react49.Icon, { path: import_js10.mdiMagnify, size: "1.25em" }),
59479
+ }, []), /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(import_jsx_runtime20.Fragment, { children: [
59480
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "card sticky top-0 z-10 flex flex-col gap-2", children: [
59481
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("h2", { className: "card__title justify-start gap-2", children: [
59482
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react50.Icon, { path: import_js10.mdiMagnify, size: "1.25em" }),
59384
59483
  "Search"
59385
59484
  ] }),
59386
- /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)("div", { className: "flex gap-2", children: [
59387
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59485
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { className: "flex gap-2", children: [
59486
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
59388
59487
  "input",
59389
59488
  {
59390
59489
  className: "input",
@@ -59401,7 +59500,7 @@ var SearchCard = (0, import_react47.memo)(function() {
59401
59500
  }
59402
59501
  }
59403
59502
  ),
59404
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(
59503
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(
59405
59504
  "button",
59406
59505
  {
59407
59506
  className: "btn btn--primary",
@@ -59415,11 +59514,11 @@ var SearchCard = (0, import_react47.memo)(function() {
59415
59514
  }
59416
59515
  )
59417
59516
  ] }),
59418
- isTransitioning || searchText.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("p", { className: "card-p", children: isTransitioning ? "Searching..." : searchText.length > 0 ? `${searchResultsArray.length} results` : null }) : null
59517
+ isTransitioning || searchText.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("p", { className: "card-p", children: isTransitioning ? "Searching..." : searchText.length > 0 ? `${searchResultsArray.length} results` : null }) : null
59419
59518
  ] }),
59420
- searchResultsArray.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(SearchResultsList, {}) : null
59519
+ searchResultsArray.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(SearchResultsList, {}) : null
59421
59520
  ] });
59422
- }), SearchResultsList = (0, import_react47.memo)(function() {
59521
+ }), SearchResultsList = (0, import_react48.memo)(function() {
59423
59522
  let { setPath } = usePath(), { setClickedObject } = useClickedObject(), { searchResults } = useSearch();
59424
59523
  function onClick(object) {
59425
59524
  if (setClickedObject(object), object.type === "tree")
@@ -59429,7 +59528,7 @@ var SearchCard = (0, import_react47.memo)(function() {
59429
59528
  setPath(allExceptLast(object.path.split(sep3)).join(sep3));
59430
59529
  }
59431
59530
  }
59432
- return /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("div", { className: "card relative gap-0", children: Object.values(searchResults).map((result) => /* @__PURE__ */ (0, import_jsx_runtime18.jsxs)(
59531
+ return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "card relative gap-0", children: Object.values(searchResults).map((result) => /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
59433
59532
  "button",
59434
59533
  {
59435
59534
  className: "flex items-center justify-start gap-2 text-sm font-bold opacity-70 hover:opacity-100",
@@ -59437,8 +59536,8 @@ var SearchCard = (0, import_react47.memo)(function() {
59437
59536
  value: result.path,
59438
59537
  onClick: () => onClick(result),
59439
59538
  children: [
59440
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)(import_react49.Icon, { path: result.type === "tree" ? import_js10.mdiFolder : import_js10.mdiFileOutline, size: 0.75, className: "shrink-0" }),
59441
- /* @__PURE__ */ (0, import_jsx_runtime18.jsx)("span", { className: "truncate", children: result.name })
59539
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react50.Icon, { path: result.type === "tree" ? import_js10.mdiFolder : import_js10.mdiFileOutline, size: 0.75, className: "shrink-0" }),
59540
+ /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { className: "truncate", children: result.name })
59442
59541
  ]
59443
59542
  },
59444
59543
  result.path
@@ -59446,10 +59545,10 @@ var SearchCard = (0, import_react47.memo)(function() {
59446
59545
  });
59447
59546
 
59448
59547
  // src/components/UnionAuthorsModal.tsx
59449
- var import_react50 = __toESM(require_react()), import_react51 = __toESM(require_react()), import_react52 = __toESM(require_dist3());
59450
- var import_react_use4 = __toESM(require_lib5()), import_react53 = __toESM(require_Icon()), import_js11 = __toESM(require_mdi()), import_jsx_runtime19 = __toESM(require_jsx_runtime());
59548
+ var import_react51 = __toESM(require_react()), import_react52 = __toESM(require_react()), import_react53 = __toESM(require_dist3());
59549
+ var import_react_use4 = __toESM(require_lib5()), import_react54 = __toESM(require_Icon()), import_js11 = __toESM(require_mdi()), import_jsx_runtime21 = __toESM(require_jsx_runtime());
59451
59550
  function UnionAuthorsModal({ visible, onClose }) {
59452
- let { repo, analyzerData, truckConfig } = useData(), submit = (0, import_react52.useSubmit)(), { authors } = analyzerData, authorUnions = truckConfig.unionedAuthors ?? [], [selectedAuthors, setSelectedAuthors] = (0, import_react51.useState)([]), [filter, setFilter] = (0, import_react51.useState)(""), navigationData = (0, import_react52.useNavigation)(), [, authorColors] = useMetrics(), [, startTransition] = (0, import_react50.useTransition)(), flattedUnionedAuthors = authorUnions.reduce((acc, union) => [...acc, ...union], []).sort(stringSorter);
59551
+ let { repo, analyzerData, truckConfig } = useData(), submit = (0, import_react53.useSubmit)(), { authors } = analyzerData, authorUnions = truckConfig.unionedAuthors ?? [], [selectedAuthors, setSelectedAuthors] = (0, import_react52.useState)([]), [filter, setFilter] = (0, import_react52.useState)(""), navigationData = (0, import_react53.useNavigation)(), [, authorColors] = useMetrics(), [, startTransition] = (0, import_react51.useTransition)(), flattedUnionedAuthors = authorUnions.reduce((acc, union) => [...acc, ...union], []).sort(stringSorter);
59453
59552
  function ungroup(groupToUnGroup) {
59454
59553
  let newAuthorUnions = authorUnions.filter((_3, i2) => i2 !== groupToUnGroup), form = new FormData();
59455
59554
  form.append("unionedAuthors", JSON.stringify(newAuthorUnions)), submit(form, {
@@ -59488,7 +59587,7 @@ function UnionAuthorsModal({ visible, onClose }) {
59488
59587
  let getColorFromDisplayName = (displayName) => authorColors.get(displayName) ?? "#333";
59489
59588
  if (!visible)
59490
59589
  return null;
59491
- let ungroupedAuthorsMessage = ungroupedAuthorsSorted.length === 0 ? "All detected authors have been grouped" : "Select the authors that you know are the same person", groupedAuthorsMessage = authorUnions.length === 0 ? "No authors have been grouped yet" : "", ungroupedAuthersEntries = ungroupedAuthorsSorted.filter((author) => author.toLowerCase().includes(filter.toLowerCase())).map((author) => /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59590
+ let ungroupedAuthorsMessage = ungroupedAuthorsSorted.length === 0 ? "All detected authors have been grouped" : "Select the authors that you know are the same person", groupedAuthorsMessage = authorUnions.length === 0 ? "No authors have been grouped yet" : "", ungroupedAuthersEntries = ungroupedAuthorsSorted.filter((author) => author.toLowerCase().includes(filter.toLowerCase())).map((author) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
59492
59591
  CheckboxWithLabel,
59493
59592
  {
59494
59593
  className: "hover:opacity-70",
@@ -59498,20 +59597,20 @@ function UnionAuthorsModal({ visible, onClose }) {
59498
59597
  let newSelectedAuthors = (_a2 = e.target) != null && _a2.checked ? [...selectedAuthors, author] : selectedAuthors.filter((a) => a !== author);
59499
59598
  setSelectedAuthors(newSelectedAuthors);
59500
59599
  },
59501
- children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "inline-flex flex-row place-items-center gap-2", children: [
59502
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(LegendDot, { dotColor: getColorFromDisplayName(author) }),
59600
+ children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "inline-flex flex-row place-items-center gap-2", children: [
59601
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(LegendDot, { dotColor: getColorFromDisplayName(author) }),
59503
59602
  author
59504
59603
  ] })
59505
59604
  },
59506
59605
  author
59507
59606
  )), groupedAuthorsEntries = authorUnions.map((aliasGroup, aliasGroupIndex) => {
59508
59607
  let displayName = aliasGroup[0], disabled2 = navigationData.state !== "idle", color = getColorFromDisplayName(displayName);
59509
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "card m-0 flex flex-col p-2", children: [
59510
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "inline-flex flex-row place-items-center gap-2", children: [
59511
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(LegendDot, { dotColor: color }),
59512
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("b", { children: displayName })
59608
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "card m-0 flex flex-col p-2", children: [
59609
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "inline-flex flex-row place-items-center gap-2", children: [
59610
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(LegendDot, { dotColor: color }),
59611
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("b", { children: displayName })
59513
59612
  ] }),
59514
- aliasGroup.slice(1).sort(stringSorter).map((alias) => /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59613
+ aliasGroup.slice(1).sort(stringSorter).map((alias) => /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
59515
59614
  AliasEntry,
59516
59615
  {
59517
59616
  alias,
@@ -59520,14 +59619,14 @@ function UnionAuthorsModal({ visible, onClose }) {
59520
59619
  },
59521
59620
  alias
59522
59621
  )),
59523
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "flex justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("button", { className: "btn", onClick: () => ungroup(aliasGroupIndex), title: "Ungroup", disabled: disabled2, children: "Ungroup" }) })
59622
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "flex justify-end", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("button", { className: "btn", onClick: () => ungroup(aliasGroupIndex), title: "Ungroup", disabled: disabled2, children: "Ungroup" }) })
59524
59623
  ] }, aliasGroupIndex);
59525
59624
  });
59526
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "fixed inset-0 z-10 grid bg-black/50 p-2", onClick: handleModalWrapperClick, children: /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "card relative mx-auto grid h-full max-h-full w-auto max-w-screen-lg grid-flow-col grid-cols-[1fr_1fr] grid-rows-[max-content_max-content_max-content_max-content_1fr_max-content] gap-4 overflow-hidden", children: [
59527
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("h2", { className: "col-span-2 text-2xl", children: "Group authors" }),
59528
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("h3", { className: "text-lg font-bold", children: "Ungrouped authors" }),
59529
- ungroupedAuthorsSorted.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)("div", { className: "flex justify-end gap-2", children: [
59530
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59625
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "fixed inset-0 z-10 grid bg-black/50 p-2", onClick: handleModalWrapperClick, children: /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "card relative mx-auto grid h-full max-h-full w-auto max-w-screen-lg grid-flow-col grid-cols-[1fr_1fr] grid-rows-[max-content_max-content_max-content_max-content_1fr_max-content] gap-4 overflow-hidden", children: [
59626
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("h2", { className: "col-span-2 text-2xl", children: "Group authors" }),
59627
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("h3", { className: "text-lg font-bold", children: "Ungrouped authors" }),
59628
+ ungroupedAuthorsSorted.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "flex justify-end gap-2", children: [
59629
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
59531
59630
  "input",
59532
59631
  {
59533
59632
  className: "input",
@@ -59536,7 +59635,7 @@ function UnionAuthorsModal({ visible, onClose }) {
59536
59635
  onChange: (e) => startTransition(() => setFilter(e.target.value))
59537
59636
  }
59538
59637
  ),
59539
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59638
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
59540
59639
  "button",
59541
59640
  {
59542
59641
  disabled: disabled || selectedAuthors.length === 0,
@@ -59545,7 +59644,7 @@ function UnionAuthorsModal({ visible, onClose }) {
59545
59644
  children: "Clear"
59546
59645
  }
59547
59646
  ),
59548
- /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
59647
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
59549
59648
  "button",
59550
59649
  {
59551
59650
  className: "btn btn--primary",
@@ -59553,17 +59652,17 @@ function UnionAuthorsModal({ visible, onClose }) {
59553
59652
  title: "Group the selected authors",
59554
59653
  disabled: disabled || selectedAuthors.length === 0,
59555
59654
  children: [
59556
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_react53.Icon, { path: import_js11.mdiAccountMultiple, size: 1 }),
59655
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react54.Icon, { path: import_js11.mdiAccountMultiple, size: 1 }),
59557
59656
  "Group"
59558
59657
  ]
59559
59658
  }
59560
59659
  )
59561
- ] }) : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {}),
59562
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("p", { children: ungroupedAuthorsMessage }),
59563
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "min-h-0 overflow-y-auto rounded-md bg-slate-50 p-4 shadow-inner", children: ungroupedAuthersEntries }),
59564
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {}),
59565
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("h3", { className: "text-lg font-bold", children: "Grouped authors" }),
59566
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "mr-6 flex justify-end gap-4", children: authorUnions.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(
59660
+ ] }) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", {}),
59661
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { children: ungroupedAuthorsMessage }),
59662
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "min-h-0 overflow-y-auto rounded-md bg-slate-50 p-4 shadow-inner", children: ungroupedAuthersEntries }),
59663
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", {}),
59664
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("h3", { className: "text-lg font-bold", children: "Grouped authors" }),
59665
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "mr-6 flex justify-end gap-4", children: authorUnions.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(
59567
59666
  "button",
59568
59667
  {
59569
59668
  className: "btn btn--danger",
@@ -59573,18 +59672,18 @@ function UnionAuthorsModal({ visible, onClose }) {
59573
59672
  },
59574
59673
  children: "Ungroup all"
59575
59674
  }
59576
- ) : /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", {}) }),
59577
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("p", { children: groupedAuthorsMessage }),
59578
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "flex flex-col gap-4 overflow-y-auto rounded-md bg-slate-50 p-4 shadow-inner", children: authorUnions.length > 0 ? groupedAuthorsEntries : null }),
59579
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("div", { className: "mr-6 flex justify-end gap-4", children: /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("button", { className: "btn", onClick: onClose, children: "Done" }) }),
59580
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(CloseButton, { onClick: onClose })
59675
+ ) : /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", {}) }),
59676
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("p", { children: groupedAuthorsMessage }),
59677
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "flex flex-col gap-4 overflow-y-auto rounded-md bg-slate-50 p-4 shadow-inner", children: authorUnions.length > 0 ? groupedAuthorsEntries : null }),
59678
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("div", { className: "mr-6 flex justify-end gap-4", children: /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("button", { className: "btn", onClick: onClose, children: "Done" }) }),
59679
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(CloseButton, { onClick: onClose })
59581
59680
  ] }) });
59582
59681
  function AliasEntry({
59583
59682
  alias,
59584
59683
  onClick,
59585
59684
  disabled: disabled2
59586
59685
  }) {
59587
- return /* @__PURE__ */ (0, import_jsx_runtime19.jsxs)(
59686
+ return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
59588
59687
  "button",
59589
59688
  {
59590
59689
  className: "btn--icon flex grid-flow-col gap-2 text-sm [&:hover>svg]:opacity-50 [&>svg]:opacity-0",
@@ -59592,8 +59691,8 @@ function UnionAuthorsModal({ visible, onClose }) {
59592
59691
  onClick,
59593
59692
  title: "Make display name for this grouping",
59594
59693
  children: [
59595
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)(import_react53.Icon, { path: import_js11.mdiArrowUp, size: 0.75 }),
59596
- /* @__PURE__ */ (0, import_jsx_runtime19.jsx)("label", { className: "label", children: alias })
59694
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react54.Icon, { path: import_js11.mdiArrowUp, size: 0.75 }),
59695
+ /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("label", { className: "label", children: alias })
59597
59696
  ]
59598
59697
  },
59599
59698
  alias
@@ -59606,10 +59705,10 @@ var stringSorter = (a, b4) => a.toLowerCase().localeCompare(b4.toLowerCase());
59606
59705
  var import_js15 = __toESM(require_mdi());
59607
59706
 
59608
59707
  // src/components/Breadcrumb.tsx
59609
- var import_js12 = __toESM(require_mdi()), import_react54 = __toESM(require_Icon()), import_react55 = __toESM(require_react());
59610
- var import_jsx_runtime20 = __toESM(require_jsx_runtime());
59708
+ var import_js12 = __toESM(require_mdi()), import_react55 = __toESM(require_Icon()), import_react56 = __toESM(require_react());
59709
+ var import_jsx_runtime22 = __toESM(require_jsx_runtime());
59611
59710
  function Breadcrumb() {
59612
- let { repo } = useData(), { path, setPath } = usePath(), paths = (0, import_react55.useMemo)(() => {
59711
+ let { repo } = useData(), { path, setPath } = usePath(), paths = (0, import_react56.useMemo)(() => {
59613
59712
  let temppath = path, paths2 = [];
59614
59713
  for (let i2 = 0; i2 < 8 && temppath !== ""; i2++) {
59615
59714
  let idx = temppath.lastIndexOf("/");
@@ -59617,34 +59716,34 @@ function Breadcrumb() {
59617
59716
  }
59618
59717
  return temppath !== "" && (paths2 = paths2.slice(0, paths2.length - 1), paths2.push(["...", ""]), paths2.push([repo.name, repo.name])), paths2.reverse();
59619
59718
  }, [path, repo.name]);
59620
- return /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("div", { className: "flex items-center gap-1", children: paths.length > 1 ? paths.map(([name, p3], i2) => p3 === "" || i2 === paths.length - 1 ? p3 === "" ? /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(import_react55.Fragment, { children: [
59621
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { className: "font-bold", children: name }),
59622
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react54.default, { path: import_js12.mdiChevronRight, size: 1 })
59623
- ] }, p3) : /* @__PURE__ */ (0, import_jsx_runtime20.jsx)("span", { className: "font-bold", children: name }, p3) : /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(import_jsx_runtime20.Fragment, { children: [
59624
- /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)(
59719
+ return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "flex items-center gap-1", children: paths.length > 1 ? paths.map(([name, p3], i2) => p3 === "" || i2 === paths.length - 1 ? p3 === "" ? /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_react56.Fragment, { children: [
59720
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "font-bold", children: name }),
59721
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_react55.default, { path: import_js12.mdiChevronRight, size: 1 })
59722
+ ] }, p3) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "font-bold", children: name }, p3) : /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [
59723
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(
59625
59724
  "button",
59626
59725
  {
59627
59726
  className: "card flex flex-row gap-2 px-2 py-1 font-bold hover:opacity-70",
59628
59727
  onClick: () => setPath(p3),
59629
59728
  children: [
59630
- i2 === 0 ? /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react54.default, { path: import_js12.mdiHome, size: 1 }) : null,
59729
+ i2 === 0 ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_react55.default, { path: import_js12.mdiHome, size: 1 }) : null,
59631
59730
  name
59632
59731
  ]
59633
59732
  },
59634
59733
  p3
59635
59734
  ),
59636
- /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(import_react54.default, { path: import_js12.mdiChevronRight, size: 1 })
59735
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(import_react55.default, { path: import_js12.mdiChevronRight, size: 1 })
59637
59736
  ] })) : null });
59638
59737
  }
59639
59738
 
59640
59739
  // src/components/FeedbackCard.tsx
59641
- var import_js13 = __toESM(require_mdi()), import_react56 = __toESM(require_Icon()), import_react57 = __toESM(require_react()), import_jsx_runtime21 = __toESM(require_jsx_runtime()), FeedbackCard = (0, import_react57.memo)(function() {
59642
- return /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "card", children: [
59643
- /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)("div", { className: "flex items-center justify-between", children: [
59644
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)("h3", { className: "card__title", children: "Help improve Git Truck" }),
59645
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react56.default, { path: import_js13.mdiForum, size: 1 })
59740
+ var import_js13 = __toESM(require_mdi()), import_react57 = __toESM(require_Icon()), import_react58 = __toESM(require_react()), import_jsx_runtime23 = __toESM(require_jsx_runtime()), FeedbackCard = (0, import_react58.memo)(function() {
59741
+ return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "card", children: [
59742
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)("div", { className: "flex items-center justify-between", children: [
59743
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("h3", { className: "card__title", children: "Help improve Git Truck" }),
59744
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react57.default, { path: import_js13.mdiForum, size: 1 })
59646
59745
  ] }),
59647
- /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
59746
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
59648
59747
  "a",
59649
59748
  {
59650
59749
  className: "btn",
@@ -59652,12 +59751,12 @@ var import_js13 = __toESM(require_mdi()), import_react56 = __toESM(require_Icon(
59652
59751
  target: "_blank",
59653
59752
  rel: "noopener noreferrer",
59654
59753
  children: [
59655
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react56.default, { path: import_js13.mdiMessageDraw }),
59754
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react57.default, { path: import_js13.mdiMessageDraw }),
59656
59755
  "Answer questionnaire"
59657
59756
  ]
59658
59757
  }
59659
59758
  ),
59660
- /* @__PURE__ */ (0, import_jsx_runtime21.jsxs)(
59759
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
59661
59760
  "a",
59662
59761
  {
59663
59762
  className: "btn",
@@ -59665,7 +59764,7 @@ var import_js13 = __toESM(require_mdi()), import_react56 = __toESM(require_Icon(
59665
59764
  target: "_blank",
59666
59765
  rel: "noopener noreferrer",
59667
59766
  children: [
59668
- /* @__PURE__ */ (0, import_jsx_runtime21.jsx)(import_react56.default, { path: import_js13.mdiAlertCircleOutline }),
59767
+ /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react57.default, { path: import_js13.mdiAlertCircleOutline }),
59669
59768
  "Open an issue"
59670
59769
  ]
59671
59770
  }
@@ -60152,17 +60251,17 @@ function binary_default(parent, x0, y0, x1, y1) {
60152
60251
  }
60153
60252
 
60154
60253
  // src/components/Chart.tsx
60155
- var import_react58 = __toESM(require_react());
60254
+ var import_react59 = __toESM(require_react());
60156
60255
 
60157
60256
  // src/const.ts
60158
60257
  var searchMatchColor = "red";
60159
60258
 
60160
60259
  // src/components/Chart.tsx
60161
- var import_clsx5 = __toESM(require_clsx());
60162
- var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_react58.memo)(function({
60260
+ var import_clsx6 = __toESM(require_clsx());
60261
+ var import_jsx_runtime24 = __toESM(require_jsx_runtime()), Chart2 = (0, import_react59.memo)(function({
60163
60262
  setHoveredObject
60164
60263
  }) {
60165
- let [ref, rawSize] = useComponentSize(), { searchResults } = useSearch(), size = (0, import_react58.useDeferredValue)(rawSize), { analyzerData } = useData(), { chartType, sizeMetric, depthType, hierarchyType } = useOptions(), { path } = usePath(), { clickedObject, setClickedObject } = useClickedObject(), { setPath } = usePath(), numberOfDepthLevels;
60264
+ let [ref, rawSize] = useComponentSize(), { searchResults } = useSearch(), size = (0, import_react59.useDeferredValue)(rawSize), { analyzerData } = useData(), { chartType, sizeMetric, depthType, hierarchyType } = useOptions(), { path } = usePath(), { clickedObject, setClickedObject } = useClickedObject(), { setPath } = usePath(), numberOfDepthLevels;
60166
60265
  switch (depthType) {
60167
60266
  case "One":
60168
60267
  numberOfDepthLevels = 1;
@@ -60183,7 +60282,7 @@ var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_r
60183
60282
  default:
60184
60283
  numberOfDepthLevels = void 0;
60185
60284
  }
60186
- let nodes = (0, import_react58.useMemo)(() => {
60285
+ let nodes = (0, import_react59.useMemo)(() => {
60187
60286
  if (size.width === 0 || size.height === 0)
60188
60287
  return [];
60189
60288
  let commit = hierarchyType === "NESTED" ? analyzerData.commit : {
@@ -60195,7 +60294,7 @@ var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_r
60195
60294
  };
60196
60295
  return createPartitionedHiearchy(commit, size, chartType, sizeMetric, path).descendants();
60197
60296
  }, [size, hierarchyType, analyzerData.commit, chartType, sizeMetric, path]);
60198
- (0, import_react58.useEffect)(() => {
60297
+ (0, import_react59.useEffect)(() => {
60199
60298
  setHoveredObject(null);
60200
60299
  }, [chartType, analyzerData.commit, size, setHoveredObject]);
60201
60300
  let createGroupHandlers = (d4, isRoot) => isBlob(d4.data) ? {
@@ -60211,10 +60310,10 @@ var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_r
60211
60310
  },
60212
60311
  onMouseOut: () => setHoveredObject(null)
60213
60312
  };
60214
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("div", { className: "relative grid place-items-center overflow-hidden", ref, children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60313
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "relative grid place-items-center overflow-hidden", ref, children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60215
60314
  "svg",
60216
60315
  {
60217
- className: (0, import_clsx5.default)("grid h-full w-full place-items-center", {
60316
+ className: (0, import_clsx6.default)("grid h-full w-full place-items-center", {
60218
60317
  "cursor-zoom-out": path.includes("/")
60219
60318
  }),
60220
60319
  xmlns: "http://www.w3.org/2000/svg",
@@ -60223,22 +60322,22 @@ var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_r
60223
60322
  let parentPath = path.split("/").slice(0, -1).join("/");
60224
60323
  setPath(parentPath === "" ? "/" : parentPath);
60225
60324
  },
60226
- children: nodes.map((d4, i2) => numberOfDepthLevels !== void 0 && d4.depth > numberOfDepthLevels ? null : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60325
+ children: nodes.map((d4, i2) => numberOfDepthLevels !== void 0 && d4.depth > numberOfDepthLevels ? null : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60227
60326
  "g",
60228
60327
  {
60229
- className: (0, import_clsx5.default)("hover:opacity-60", {
60328
+ className: (0, import_clsx6.default)("hover:opacity-60", {
60230
60329
  "cursor-pointer": i2 === 0,
60231
60330
  "cursor-zoom-in": i2 > 0 && isTree(d4.data),
60232
60331
  "animate-blink": (clickedObject == null ? void 0 : clickedObject.path) === d4.data.path
60233
60332
  }),
60234
60333
  ...createGroupHandlers(d4, i2 === 0),
60235
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(Node3, { isRoot: i2 === 0, d: d4, isSearchMatch: Boolean(searchResults[d4.data.path]) })
60334
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Node3, { isRoot: i2 === 0, d: d4, isSearchMatch: Boolean(searchResults[d4.data.path]) })
60236
60335
  },
60237
60336
  `${chartType}${d4.data.path}`
60238
60337
  ))
60239
60338
  }
60240
60339
  ) });
60241
- }), Node3 = (0, import_react58.memo)(function({
60340
+ }), Node3 = (0, import_react59.memo)(function({
60242
60341
  d: d4,
60243
60342
  isRoot,
60244
60343
  isSearchMatch
@@ -60267,18 +60366,18 @@ var import_jsx_runtime22 = __toESM(require_jsx_runtime()), Chart2 = (0, import_r
60267
60366
  default:
60268
60367
  throw Error("Unknown chart type");
60269
60368
  }
60270
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [
60271
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60369
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
60370
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60272
60371
  Path,
60273
60372
  {
60274
- className: (0, import_clsx5.default)({
60373
+ className: (0, import_clsx6.default)({
60275
60374
  "cursor-pointer": isBlob(d4.data)
60276
60375
  }),
60277
60376
  d: d4,
60278
60377
  isSearchMatch
60279
60378
  }
60280
60379
  ),
60281
- showLabel ? chartType === "BUBBLE_CHART" ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(CircleText, { d: d4, displayText }) : /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60380
+ showLabel ? chartType === "BUBBLE_CHART" ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(CircleText, { d: d4, displayText }) : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60282
60381
  RectText,
60283
60382
  {
60284
60383
  className: "font-mono",
@@ -60297,7 +60396,7 @@ function Path({
60297
60396
  className = ""
60298
60397
  }) {
60299
60398
  var _a2;
60300
- let [metricsData] = useMetrics(), { chartType, metricType, authorshipType } = useOptions(), dProp = (0, import_react58.useMemo)(() => {
60399
+ let [metricsData] = useMetrics(), { chartType, metricType, authorshipType } = useOptions(), dProp = (0, import_react59.useMemo)(() => {
60301
60400
  if (chartType === "BUBBLE_CHART") {
60302
60401
  let datum = d4;
60303
60402
  return circlePathFromCircle(datum.x, datum.y + 14 - 1, datum.r - 1);
@@ -60317,11 +60416,11 @@ function Path({
60317
60416
  strokeWidth: "1px",
60318
60417
  fill: isBlob(d4.data) ? ((_a2 = metricsData[authorshipType].get(metricType)) == null ? void 0 : _a2.colormap.get(d4.data.path)) ?? "grey" : "transparent"
60319
60418
  });
60320
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60419
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60321
60420
  it3.path,
60322
60421
  {
60323
60422
  ...props,
60324
- className: (0, import_clsx5.default)(className, {
60423
+ className: (0, import_clsx6.default)(className, {
60325
60424
  "animate-stroke-pulse": isSearchMatch,
60326
60425
  "stroke-black/20": isTree(d4.data)
60327
60426
  })
@@ -60339,20 +60438,20 @@ function CircleText({
60339
60438
  }), textProps = useToggleableSpring({
60340
60439
  fill: isBlob(d4.data) ? getTextColorFromBackground(((_a2 = metricsData[authorshipType].get(metricType)) == null ? void 0 : _a2.colormap.get(d4.data.path)) ?? "#333") : "#333"
60341
60440
  });
60342
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)(import_jsx_runtime22.Fragment, { children: [
60343
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(it3.path, { ...props, id: d4.data.path, className: "pointer-events-none fill-none stroke-none" }),
60344
- isTree(d4.data) ? /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60441
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
60442
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(it3.path, { ...props, id: d4.data.path, className: "pointer-events-none fill-none stroke-none" }),
60443
+ isTree(d4.data) ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60345
60444
  it3.text,
60346
60445
  {
60347
60446
  className: "pointer-events-none stroke-white stroke-[7px] font-mono text-sm font-bold",
60348
60447
  strokeLinecap: "round",
60349
- children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("textPath", { startOffset: "50%", dominantBaseline: "central", textAnchor: "middle", xlinkHref: `#${d4.data.path}`, children: displayText })
60448
+ children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("textPath", { startOffset: "50%", dominantBaseline: "central", textAnchor: "middle", xlinkHref: `#${d4.data.path}`, children: displayText })
60350
60449
  }
60351
60450
  ) : null,
60352
- /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(it3.text, { ...textProps, className: "pointer-events-none", children: /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60451
+ /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(it3.text, { ...textProps, className: "pointer-events-none", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60353
60452
  "textPath",
60354
60453
  {
60355
- className: (0, import_clsx5.default)("font-mono", className, {
60454
+ className: (0, import_clsx6.default)("font-mono", className, {
60356
60455
  "text-sm font-bold": isTree(d4.data),
60357
60456
  "text-xs": !isTree(d4.data)
60358
60457
  }),
@@ -60376,11 +60475,11 @@ function RectText({
60376
60475
  y: d4.y0 + yOffset,
60377
60476
  fill: isBlob(d4.data) ? getTextColorFromBackground(((_a2 = metricsData[authorshipType].get(metricType)) == null ? void 0 : _a2.colormap.get(d4.data.path)) ?? "#333") : "#333"
60378
60477
  });
60379
- return /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
60478
+ return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60380
60479
  it3.text,
60381
60480
  {
60382
60481
  ...props,
60383
- className: (0, import_clsx5.default)("pointer-events-none", className, {
60482
+ className: (0, import_clsx6.default)("pointer-events-none", className, {
60384
60483
  "font-bold": isTree(d4.data)
60385
60484
  }),
60386
60485
  children: displayText
@@ -60462,20 +60561,20 @@ function flatten(tree) {
60462
60561
  }
60463
60562
 
60464
60563
  // src/routes/$repo.$.tsx
60465
- var import_react63 = __toESM(require_Icon());
60466
- var import_clsx6 = __toESM(require_clsx());
60564
+ var import_react64 = __toESM(require_Icon());
60565
+ var import_clsx7 = __toESM(require_clsx());
60467
60566
 
60468
60567
  // src/components/Tooltip.tsx
60469
- var import_react59 = __toESM(require_react());
60470
- var import_js14 = __toESM(require_mdi()), import_react60 = __toESM(require_Icon()), import_jsx_runtime23 = __toESM(require_jsx_runtime()), Tooltip = (0, import_react59.memo)(function({ hoveredObject, x: x4, y: y5 }) {
60471
- let tooltipRef = (0, import_react59.useRef)(null), { metricType, authorshipType } = useOptions(), [metricsData] = useMetrics(), color = (0, import_react59.useMemo)(() => {
60568
+ var import_react60 = __toESM(require_react());
60569
+ var import_js14 = __toESM(require_mdi()), import_react61 = __toESM(require_Icon()), import_jsx_runtime25 = __toESM(require_jsx_runtime()), Tooltip = (0, import_react60.memo)(function({ hoveredObject, x: x4, y: y5 }) {
60570
+ let tooltipRef = (0, import_react60.useRef)(null), { metricType, authorshipType } = useOptions(), [metricsData] = useMetrics(), color = (0, import_react60.useMemo)(() => {
60472
60571
  var _a2, _b2;
60473
60572
  if (!hoveredObject)
60474
60573
  return null;
60475
60574
  let colormap = (_b2 = (_a2 = metricsData[authorshipType]) == null ? void 0 : _a2.get(metricType)) == null ? void 0 : _b2.colormap;
60476
60575
  return (colormap == null ? void 0 : colormap.get(hoveredObject.path)) ?? "grey";
60477
- }, [hoveredObject, metricsData, metricType, authorshipType]), right = (0, import_react59.useMemo)(() => x4 < window.innerWidth / 2, [x4]), top = (0, import_react59.useMemo)(() => y5 < window.innerHeight / 2, [y5]), xTransform = (0, import_react59.useMemo)(() => right ? `calc(1rem + ${x4}px)` : `calc(-1rem + ${x4}px - 100%)`, [right, x4]), yTransform = (0, import_react59.useMemo)(() => top ? `calc(1rem + ${y5}px)` : `calc(-1rem + ${y5}px - 100%)`, [top, y5]), visible = hoveredObject !== null;
60478
- return /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(
60576
+ }, [hoveredObject, metricsData, metricType, authorshipType]), right = (0, import_react60.useMemo)(() => x4 < window.innerWidth / 2, [x4]), top = (0, import_react60.useMemo)(() => y5 < window.innerHeight / 2, [y5]), xTransform = (0, import_react60.useMemo)(() => right ? `calc(1rem + ${x4}px)` : `calc(-1rem + ${x4}px - 100%)`, [right, x4]), yTransform = (0, import_react60.useMemo)(() => top ? `calc(1rem + ${y5}px)` : `calc(-1rem + ${y5}px - 100%)`, [top, y5]), visible = hoveredObject !== null;
60577
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
60479
60578
  "div",
60480
60579
  {
60481
60580
  className: `card absolute left-0 top-0 flex w-max flex-row place-items-center rounded-full py-0 pl-1 pr-2 will-change-transform ${visible ? "visible" : "hidden"}`,
@@ -60484,10 +60583,10 @@ var import_js14 = __toESM(require_mdi()), import_react60 = __toESM(require_Icon(
60484
60583
  transform: visible ? `translate(${xTransform}, ${yTransform})` : "none"
60485
60584
  },
60486
60585
  children: [
60487
- (hoveredObject == null ? void 0 : hoveredObject.type) === "blob" ? color ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(LegendDot, { dotColor: color }) : null : /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react60.default, { className: "ml-0.5", path: import_js14.mdiFolder, size: 0.75 }),
60488
- /* @__PURE__ */ (0, import_jsx_runtime23.jsx)("span", { className: "card__subtitle items-center font-bold", children: hoveredObject && isBlob(hoveredObject) ? hoveredObject == null ? void 0 : hoveredObject.name : allExceptFirst((hoveredObject == null ? void 0 : hoveredObject.path.split("/")) ?? []).map((segment, index, segments) => /* @__PURE__ */ (0, import_jsx_runtime23.jsxs)(import_react59.Fragment, { children: [
60586
+ (hoveredObject == null ? void 0 : hoveredObject.type) === "blob" ? color ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(LegendDot, { dotColor: color }) : null : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_react61.default, { className: "ml-0.5", path: import_js14.mdiFolder, size: 0.75 }),
60587
+ /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: "card__subtitle items-center font-bold", children: hoveredObject && isBlob(hoveredObject) ? hoveredObject == null ? void 0 : hoveredObject.name : allExceptFirst((hoveredObject == null ? void 0 : hoveredObject.path.split("/")) ?? []).map((segment, index, segments) => /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_react60.Fragment, { children: [
60489
60588
  segment,
60490
- segments.length > 1 && index < segments.length - 1 ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_react60.default, { path: import_js14.mdiMenuRight, size: 1 }) : null
60589
+ segments.length > 1 && index < segments.length - 1 ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_react61.default, { path: import_js14.mdiMenuRight, size: 1 }) : null
60491
60590
  ] }, `segment-${index}${segment}`)) }),
60492
60591
  (hoveredObject == null ? void 0 : hoveredObject.type) === "blob" ? ColorMetricDependentInfo({
60493
60592
  metric: metricType,
@@ -60506,7 +60605,7 @@ function ColorMetricDependentInfo(props) {
60506
60605
  return noCommits ? `${noCommits} commit${noCommits > 1 ? "s" : null}` : null;
60507
60606
  case "LAST_CHANGED":
60508
60607
  let epoch = (_b2 = props.hoveredBlob) == null ? void 0 : _b2.lastChangeEpoch;
60509
- return epoch ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_jsx_runtime23.Fragment, { children: dateFormatRelative(epoch) }) : null;
60608
+ return epoch ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_jsx_runtime25.Fragment, { children: dateFormatRelative(epoch) }) : null;
60510
60609
  case "SINGLE_AUTHOR":
60511
60610
  let authors = props.hoveredBlob ? Object.entries(((_d = (_c2 = props.hoveredBlob) == null ? void 0 : _c2.unionedAuthors) == null ? void 0 : _d[props.authorshipType]) ?? []) : [];
60512
60611
  switch (authors.length) {
@@ -60519,7 +60618,7 @@ function ColorMetricDependentInfo(props) {
60519
60618
  }
60520
60619
  case "TOP_CONTRIBUTOR":
60521
60620
  let dominant = ((_f = (_e3 = props.hoveredBlob) == null ? void 0 : _e3.dominantAuthor) == null ? void 0 : _f[props.authorshipType]) ?? void 0;
60522
- return dominant ? /* @__PURE__ */ (0, import_jsx_runtime23.jsx)(import_jsx_runtime23.Fragment, { children: dominant[0] }) : null;
60621
+ return dominant ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(import_jsx_runtime25.Fragment, { children: dominant[0] }) : null;
60523
60622
  case "TRUCK_FACTOR":
60524
60623
  let authorCount = Object.entries(((_h = (_g = props.hoveredBlob) == null ? void 0 : _g.unionedAuthors) == null ? void 0 : _h.HISTORICAL) ?? []).length;
60525
60624
  switch (authorCount) {
@@ -60536,7 +60635,7 @@ function ColorMetricDependentInfo(props) {
60536
60635
  }
60537
60636
 
60538
60637
  // src/routes/$repo.$.tsx
60539
- var import_react_dom2 = __toESM(require_react_dom()), import_js16 = __toESM(require_mdi()), import_jsx_runtime24 = __toESM(require_jsx_runtime()), invalidateCache = !1, loader = async ({ params }) => {
60638
+ var import_react_dom2 = __toESM(require_react_dom()), import_js16 = __toESM(require_mdi()), import_jsx_runtime26 = __toESM(require_jsx_runtime()), invalidateCache = !1, loader = async ({ params }) => {
60540
60639
  if (!params.repo || !params["*"])
60541
60640
  return (0, import_node2.redirect)("/");
60542
60641
  let [args, truckConfig] = await getTruckConfigWithArgs(params.repo), options = {
@@ -60593,102 +60692,102 @@ var import_react_dom2 = __toESM(require_react_dom()), import_js16 = __toESM(requ
60593
60692
  }
60594
60693
  return null;
60595
60694
  }, ErrorBoundary2 = () => {
60596
- let error2 = (0, import_react62.useRouteError)();
60597
- if ((0, import_react61.useEffect)(() => {
60695
+ let error2 = (0, import_react63.useRouteError)();
60696
+ if ((0, import_react62.useEffect)(() => {
60598
60697
  console.error(error2);
60599
- }, [error2]), (0, import_react62.isRouteErrorResponse)(error2))
60600
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "app-container", children: [
60601
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", {}),
60602
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "card", children: [
60603
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("h1", { children: "An error occured!" }),
60604
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("p", { children: "See console for more infomation." }),
60605
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("p", { children: [
60698
+ }, [error2]), (0, import_react63.isRouteErrorResponse)(error2))
60699
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "app-container", children: [
60700
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", {}),
60701
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card", children: [
60702
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("h1", { children: "An error occured!" }),
60703
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { children: "See console for more infomation." }),
60704
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("p", { children: [
60606
60705
  "Message: ",
60607
60706
  error2.data.message
60608
60707
  ] }),
60609
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Code, { children: error2.data.message }),
60610
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react62.Link, { to: ".", children: "Retry" }) }),
60611
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react62.Link, { to: "..", children: "Go back" }) })
60708
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Code, { children: error2.data.message }),
60709
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react63.Link, { to: ".", children: "Retry" }) }),
60710
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react63.Link, { to: "..", children: "Go back" }) })
60612
60711
  ] })
60613
60712
  ] });
60614
60713
  let errorMessage = "Unknown error";
60615
- return typeof error2 == "string" ? errorMessage = error2 : typeof error2 == "object" && error2 !== null && "message" in error2 && typeof error2.message == "string" && (errorMessage = error2.message), /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "app-container", children: [
60616
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", {}),
60617
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "card", children: [
60618
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("h1", { children: "An error occured!" }),
60619
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("p", { children: "See console for more infomation." }),
60620
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Code, { children: errorMessage }),
60621
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react62.Link, { to: ".", children: "Retry" }) }),
60622
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react62.Link, { to: "..", children: "Go back" }) })
60714
+ return typeof error2 == "string" ? errorMessage = error2 : typeof error2 == "object" && error2 !== null && "message" in error2 && typeof error2.message == "string" && (errorMessage = error2.message), /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "app-container", children: [
60715
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", {}),
60716
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card", children: [
60717
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("h1", { children: "An error occured!" }),
60718
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { children: "See console for more infomation." }),
60719
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Code, { children: errorMessage }),
60720
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react63.Link, { to: ".", children: "Retry" }) }),
60721
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react63.Link, { to: "..", children: "Go back" }) })
60623
60722
  ] })
60624
60723
  ] });
60625
- }, UpdateNotifier = (0, import_react61.memo)(function() {
60724
+ }, UpdateNotifier = (0, import_react62.memo)(function() {
60626
60725
  let { gitTruckInfo } = useData();
60627
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "card", children: [
60628
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("p", { children: [
60726
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card", children: [
60727
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("p", { children: [
60629
60728
  "Update available: ",
60630
60729
  gitTruckInfo.latestVersion
60631
60730
  ] }),
60632
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("p", { className: "card-p", children: [
60731
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("p", { className: "card-p", children: [
60633
60732
  "Currently installed: ",
60634
60733
  gitTruckInfo.version
60635
60734
  ] }),
60636
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("p", { className: "card-p", children: [
60735
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("p", { className: "card-p", children: [
60637
60736
  "To update, close application and run: ",
60638
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Code, { inline: !0, children: "npx git-truck@latest" })
60737
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Code, { inline: !0, children: "npx git-truck@latest" })
60639
60738
  ] })
60640
60739
  ] });
60641
60740
  });
60642
60741
  function Repo() {
60643
- let client = useClient(), data = (0, import_remix_typedjson.useTypedLoaderData)(), { analyzerData, gitTruckInfo } = data, [isLeftPanelCollapse, setIsLeftPanelCollapse] = (0, import_react61.useState)(!1), [isRightPanelCollapse, setIsRightPanelCollapse] = (0, import_react61.useState)(!1), [isFullscreen, setIsFullscreen] = (0, import_react61.useState)(!1), [unionAuthorsModalOpen, setUnionAuthorsModalOpen] = (0, import_react_use5.useBoolean)(!1), [hoveredObject, setHoveredObject] = (0, import_react61.useState)(null), showUnionAuthorsModal = () => setUnionAuthorsModalOpen(!0);
60742
+ let client = useClient(), data = (0, import_remix_typedjson.useTypedLoaderData)(), { analyzerData, gitTruckInfo } = data, [isLeftPanelCollapse, setIsLeftPanelCollapse] = (0, import_react62.useState)(!1), [isRightPanelCollapse, setIsRightPanelCollapse] = (0, import_react62.useState)(!1), [isFullscreen, setIsFullscreen] = (0, import_react62.useState)(!1), [unionAuthorsModalOpen, setUnionAuthorsModalOpen] = (0, import_react_use5.useBoolean)(!1), [hoveredObject, setHoveredObject] = (0, import_react62.useState)(null), showUnionAuthorsModal = () => setUnionAuthorsModalOpen(!0);
60644
60743
  if (!analyzerData)
60645
60744
  return null;
60646
60745
  function defineTheContainerClass() {
60647
60746
  return isFullscreen ? "fullscreen" : isLeftPanelCollapse && isRightPanelCollapse ? "both-collapse" : isLeftPanelCollapse ? "left-collapse" : isRightPanelCollapse ? "right-collapse" : "";
60648
60747
  }
60649
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(Providers, { data, children: [
60650
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: `app-container ${defineTheContainerClass()}`, children: [
60651
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("aside", { className: (0, import_clsx6.default)("flex flex-col gap-2 p-2 pl-0", {
60748
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(Providers, { data, children: [
60749
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: `app-container ${defineTheContainerClass()}`, children: [
60750
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("aside", { className: (0, import_clsx7.default)("flex flex-col gap-2 p-2 pl-0", {
60652
60751
  "overflow-y-auto": !isFullscreen
60653
60752
  }), children: [
60654
- isFullscreen ? null : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "absolute z-10", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { onClick: () => setIsLeftPanelCollapse(!isLeftPanelCollapse), className: (0, import_clsx6.default)("absolute top-half-screen rounded-full bg-white w-8 h-8 flex items-center cursor-pointer justify-center border-solid border-2 border-sky-500", {
60753
+ isFullscreen ? null : /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "absolute z-10", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { onClick: () => setIsLeftPanelCollapse(!isLeftPanelCollapse), className: (0, import_clsx7.default)("absolute top-half-screen rounded-full bg-white w-8 h-8 flex items-center cursor-pointer justify-center border-solid border-2 border-sky-500", {
60655
60754
  "left-arrow-space": !isLeftPanelCollapse
60656
- }), children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react63.Icon, { path: isLeftPanelCollapse ? import_js16.mdiChevronRight : import_js16.mdiChevronLeft, size: 1 }) }) }),
60657
- isLeftPanelCollapse ? null : /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
60658
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(GlobalInfo, {}),
60659
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Options2, {}),
60660
- analyzerData.hiddenFiles.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(HiddenFiles, {}) : null,
60661
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(SearchCard, {})
60755
+ }), children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react64.Icon, { path: isLeftPanelCollapse ? import_js16.mdiChevronRight : import_js16.mdiChevronLeft, size: 1 }) }) }),
60756
+ isLeftPanelCollapse ? null : /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(import_jsx_runtime26.Fragment, { children: [
60757
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(GlobalInfo, {}),
60758
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Options2, {}),
60759
+ analyzerData.hiddenFiles.length > 0 ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(HiddenFiles, {}) : null,
60760
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(SearchCard, {})
60662
60761
  ] })
60663
60762
  ] }),
60664
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("main", { className: "grid h-full min-w-[100px] grid-rows-[auto,1fr] gap-2 overflow-y-hidden p-2", children: [
60665
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("header", { className: "grid grid-flow-col items-center justify-between gap-2", children: [
60666
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Breadcrumb, {}),
60667
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(FullscreenButton, { setIsFullscreen, isFullscreen })
60763
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("main", { className: "grid h-full min-w-[100px] grid-rows-[auto,1fr] gap-2 overflow-y-hidden p-2", children: [
60764
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("header", { className: "grid grid-flow-col items-center justify-between gap-2", children: [
60765
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Breadcrumb, {}),
60766
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(FullscreenButton, { setIsFullscreen, isFullscreen })
60668
60767
  ] }),
60669
- client ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(ChartWrapper, { hoveredObject, setHoveredObject }) : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", {})
60768
+ client ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(ChartWrapper, { hoveredObject, setHoveredObject }) : /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", {})
60670
60769
  ] }),
60671
- /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("aside", { className: (0, import_clsx6.default)("flex flex-col gap-2 p-2 pl-0", {
60770
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("aside", { className: (0, import_clsx7.default)("flex flex-col gap-2 p-2 pl-0", {
60672
60771
  "overflow-y-auto": !isFullscreen
60673
60772
  }), children: [
60674
- isFullscreen ? null : /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { className: "absolute z-10", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)("div", { onClick: () => setIsRightPanelCollapse(!isRightPanelCollapse), className: "absolute right-0 top-half-screen rounded-full bg-white w-8 h-8 flex items-center cursor-pointer justify-center border-solid border-2 border-sky-500", children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react63.Icon, { path: isRightPanelCollapse ? import_js16.mdiChevronLeft : import_js16.mdiChevronRight, size: 1 }) }) }),
60675
- isRightPanelCollapse ? null : /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)(import_jsx_runtime24.Fragment, { children: [
60676
- gitTruckInfo.latestVersion && semverCompare(gitTruckInfo.latestVersion, gitTruckInfo.version) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(UpdateNotifier, {}) : null,
60677
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60773
+ isFullscreen ? null : /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "absolute z-10", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { onClick: () => setIsRightPanelCollapse(!isRightPanelCollapse), className: "absolute right-0 top-half-screen rounded-full bg-white w-8 h-8 flex items-center cursor-pointer justify-center border-solid border-2 border-sky-500", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react64.Icon, { path: isRightPanelCollapse ? import_js16.mdiChevronLeft : import_js16.mdiChevronRight, size: 1 }) }) }),
60774
+ isRightPanelCollapse ? null : /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(import_jsx_runtime26.Fragment, { children: [
60775
+ gitTruckInfo.latestVersion && semverCompare(gitTruckInfo.latestVersion, gitTruckInfo.version) === 1 ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(UpdateNotifier, {}) : null,
60776
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
60678
60777
  DetailsCard,
60679
60778
  {
60680
- className: (0, import_clsx6.default)({
60779
+ className: (0, import_clsx7.default)({
60681
60780
  "absolute bottom-0 right-0 max-h-screen -translate-x-full overflow-y-auto shadow shadow-black/50": isFullscreen
60682
60781
  }),
60683
60782
  showUnionAuthorsModal
60684
60783
  }
60685
60784
  ),
60686
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Legend, { hoveredObject, showUnionAuthorsModal }),
60687
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(FeedbackCard, {})
60785
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Legend, { hoveredObject, showUnionAuthorsModal }),
60786
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(FeedbackCard, {})
60688
60787
  ] })
60689
60788
  ] })
60690
60789
  ] }),
60691
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60790
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
60692
60791
  UnionAuthorsModal,
60693
60792
  {
60694
60793
  visible: unionAuthorsModalOpen,
@@ -60699,17 +60798,17 @@ function Repo() {
60699
60798
  )
60700
60799
  ] });
60701
60800
  }
60702
- var FullscreenButton = (0, import_react61.memo)(function({
60801
+ var FullscreenButton = (0, import_react62.memo)(function({
60703
60802
  setIsFullscreen,
60704
60803
  isFullscreen
60705
60804
  }) {
60706
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(
60805
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
60707
60806
  "button",
60708
60807
  {
60709
60808
  className: "card btn--icon p-1",
60710
60809
  onClick: () => setIsFullscreen((isFullscreen2) => !isFullscreen2),
60711
60810
  title: "Toggle full view",
60712
- children: /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(import_react63.Icon, { path: isFullscreen ? import_js15.mdiFullscreenExit : import_js15.mdiFullscreen, size: 1 })
60811
+ children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react64.Icon, { path: isFullscreen ? import_js15.mdiFullscreenExit : import_js15.mdiFullscreen, size: 1 })
60713
60812
  }
60714
60813
  );
60715
60814
  });
@@ -60717,11 +60816,11 @@ function ChartWrapper({
60717
60816
  hoveredObject,
60718
60817
  setHoveredObject
60719
60818
  }) {
60720
- let chartWrapperRef = (0, import_react61.useRef)(null), bodyRef = (0, import_react61.useRef)(document.body), mouse = (0, import_react_use5.useMouse)(bodyRef);
60721
- return /* @__PURE__ */ (0, import_jsx_runtime24.jsxs)("div", { className: "card grid overflow-y-hidden p-2", ref: chartWrapperRef, children: [
60722
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Chart2, { setHoveredObject }),
60819
+ let chartWrapperRef = (0, import_react62.useRef)(null), bodyRef = (0, import_react62.useRef)(document.body), mouse = (0, import_react_use5.useMouse)(bodyRef);
60820
+ return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card grid overflow-y-hidden p-2", ref: chartWrapperRef, children: [
60821
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Chart2, { setHoveredObject }),
60723
60822
  (0, import_react_dom2.createPortal)(
60724
- /* @__PURE__ */ (0, import_jsx_runtime24.jsx)(Tooltip, { hoveredObject, x: mouse.docX, y: mouse.docY, w: window.innerWidth }),
60823
+ /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Tooltip, { hoveredObject, x: mouse.docX, y: mouse.docY, w: window.innerWidth }),
60725
60824
  document.body
60726
60825
  )
60727
60826
  ] });
@@ -60733,30 +60832,30 @@ __export(index_exports, {
60733
60832
  default: () => Index,
60734
60833
  loader: () => loader2
60735
60834
  });
60736
- var import_react64 = __toESM(require_dist3());
60835
+ var import_react65 = __toESM(require_dist3());
60737
60836
 
60738
60837
  // src/components/LoadingIndicator.tsx
60739
- var import_clsx7 = __toESM(require_clsx());
60838
+ var import_clsx8 = __toESM(require_clsx());
60740
60839
 
60741
60840
  // src/assets/truck.gif
60742
60841
  var truck_default = "/build/_assets/truck-7F5JWBYT.gif";
60743
60842
 
60744
60843
  // src/components/LoadingIndicator.tsx
60745
- var import_jsx_runtime25 = __toESM(require_jsx_runtime());
60844
+ var import_jsx_runtime27 = __toESM(require_jsx_runtime());
60746
60845
  function LoadingIndicator({
60747
60846
  loadingText = "Loading",
60748
60847
  className = ""
60749
60848
  }) {
60750
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
60849
+ return /* @__PURE__ */ (0, import_jsx_runtime27.jsx)(
60751
60850
  "div",
60752
60851
  {
60753
- className: (0, import_clsx7.default)("grid h-full w-full place-items-center", className),
60852
+ className: (0, import_clsx8.default)("grid h-full w-full place-items-center", className),
60754
60853
  style: {
60755
60854
  backgroundColor: "var(--global-bg-color)"
60756
60855
  },
60757
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "flex animate-hide-initially flex-col px-2 py-2 opacity-0", children: [
60758
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("p", { className: "text-center text-3xl font-bold uppercase tracking-[0.5em] opacity-70", children: loadingText }),
60759
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("img", { src: truck_default, alt: "\u{1F69B}", className: "w-full min-w-0 max-w-sm" })
60856
+ children: /* @__PURE__ */ (0, import_jsx_runtime27.jsxs)("div", { className: "flex animate-hide-initially flex-col px-2 py-2 opacity-0", children: [
60857
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("p", { className: "text-center text-3xl font-bold uppercase tracking-[0.5em] opacity-70", children: loadingText }),
60858
+ /* @__PURE__ */ (0, import_jsx_runtime27.jsx)("img", { src: truck_default, alt: "\u{1F69B}", className: "w-full min-w-0 max-w-sm" })
60760
60859
  ] })
60761
60860
  }
60762
60861
  );
@@ -60764,13 +60863,13 @@ function LoadingIndicator({
60764
60863
 
60765
60864
  // src/routes/_index.tsx
60766
60865
  var import_path9 = require("path");
60767
- var import_react65 = __toESM(require_react());
60866
+ var import_react66 = __toESM(require_react());
60768
60867
 
60769
60868
  // src/assets/truck.png
60770
60869
  var truck_default2 = "/build/_assets/truck-JLDVJULS.png";
60771
60870
 
60772
60871
  // src/routes/_index.tsx
60773
- var import_jsx_runtime26 = __toESM(require_jsx_runtime());
60872
+ var import_jsx_runtime28 = __toESM(require_jsx_runtime());
60774
60873
  async function getResponse() {
60775
60874
  let args = getArgsWithDefaults(), [repo, repositories] = await GitCaller.scanDirectoryForRepositories(args.path, args.invalidateCache), baseDir = (0, import_path9.resolve)(repo ? getBaseDirFromPath(args.path) : args.path);
60776
60875
  return {
@@ -60782,69 +60881,69 @@ async function getResponse() {
60782
60881
  }
60783
60882
  var loader2 = async () => await getResponse();
60784
60883
  function Index() {
60785
- let { repositories, baseDir, baseDirName } = (0, import_react64.useLoaderData)();
60786
- return (0, import_react64.useNavigation)().state !== "idle" ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "grid h-screen place-items-center", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(LoadingIndicator, { loadingText: "Analyzing" }) }) : /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("main", { className: "m-auto flex min-h-screen w-full max-w-7xl flex-col gap-2 p-2", children: [
60787
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card", children: [
60788
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("h1", { className: "flex items-center text-4xl", children: [
60789
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("img", { src: truck_default2, alt: "Git Truck", className: "mr-2 inline-block h-12" }),
60884
+ let { repositories, baseDir, baseDirName } = (0, import_react65.useLoaderData)();
60885
+ return (0, import_react65.useNavigation)().state !== "idle" ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: "grid h-screen place-items-center", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(LoadingIndicator, { loadingText: "Analyzing" }) }) : /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("main", { className: "m-auto flex min-h-screen w-full max-w-7xl flex-col gap-2 p-2", children: [
60886
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "card", children: [
60887
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("h1", { className: "flex items-center text-4xl", children: [
60888
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("img", { src: truck_default2, alt: "Git Truck", className: "mr-2 inline-block h-12" }),
60790
60889
  "Git Truck"
60791
60890
  ] }),
60792
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("p", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(import_jsx_runtime26.Fragment, { children: [
60891
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("p", { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(import_jsx_runtime28.Fragment, { children: [
60793
60892
  "Found ",
60794
60893
  repositories.length,
60795
60894
  " git repositor",
60796
60895
  repositories.length === 1 ? "y" : "ies",
60797
60896
  " in the folder",
60798
60897
  " ",
60799
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Code, { inline: !0, title: baseDir, children: baseDirName }),
60898
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Code, { inline: !0, title: baseDir, children: baseDirName }),
60800
60899
  "."
60801
60900
  ] }) })
60802
60901
  ] }),
60803
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(RepositoryGrid, { repositories })
60902
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(RepositoryGrid, { repositories })
60804
60903
  ] });
60805
60904
  }
60806
60905
  function RepositoryGrid({ repositories }) {
60807
- return repositories.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_jsx_runtime26.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("p", { children: [
60906
+ return repositories.length === 0 ? /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_jsx_runtime28.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("p", { children: [
60808
60907
  "Try running ",
60809
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Code, { inline: !0, children: "git-truck" }),
60908
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(Code, { inline: !0, children: "git-truck" }),
60810
60909
  " in another folder or provide another path as argument."
60811
- ] }) }) : /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_jsx_runtime26.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("nav", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("ul", { className: "grid grid-cols-[repeat(auto-fit,minmax(225px,1fr))] gap-2", children: [
60812
- repositories.map((repo) => /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(RepositoryEntry, { repo }, repo.path)),
60813
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("li", { className: "card gap-3 p-0", children: [
60814
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
60910
+ ] }) }) : /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_jsx_runtime28.Fragment, { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("nav", { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("ul", { className: "grid grid-cols-[repeat(auto-fit,minmax(225px,1fr))] gap-2", children: [
60911
+ repositories.map((repo) => /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(RepositoryEntry, { repo }, repo.path)),
60912
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("li", { className: "card gap-3 p-0", children: [
60913
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
60815
60914
  "h2",
60816
60915
  {
60817
60916
  className: "card__title rounded-t bg-gradient-to-r from-blue-500 to-blue-600 p-3 pb-3 text-white transition-colors",
60818
60917
  title: "Add repository",
60819
60918
  children: [
60820
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "line-clamp-1 break-all", children: "Add repository" }),
60821
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "align-content-start right-0 top-0 flex min-w-max select-none place-items-center rounded-full bg-white/20 px-2 py-1.5 text-xs font-bold uppercase leading-none tracking-widest text-white/90", children: "Coming soon" })
60919
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "line-clamp-1 break-all", children: "Add repository" }),
60920
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "align-content-start right-0 top-0 flex min-w-max select-none place-items-center rounded-full bg-white/20 px-2 py-1.5 text-xs font-bold uppercase leading-none tracking-widest text-white/90", children: "Coming soon" })
60822
60921
  ]
60823
60922
  }
60824
60923
  ),
60825
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "flex flex-col gap-2 p-3 pt-0", children: [
60826
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("input", { type: "text", className: "input", placeholder: "git@github.com/owner/repo.git" }),
60827
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("button", { className: "btn", disabled: !0, title: "Coming soon!", children: "Clone" })
60924
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "flex flex-col gap-2 p-3 pt-0", children: [
60925
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("input", { type: "text", className: "input", placeholder: "git@github.com/owner/repo.git" }),
60926
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("button", { className: "btn", disabled: !0, title: "Coming soon!", children: "Clone" })
60828
60927
  ] })
60829
60928
  ] })
60830
60929
  ] }) }) });
60831
60930
  }
60832
60931
  function RepositoryEntry({ repo }) {
60833
- let [head, setHead] = (0, import_react65.useState)(repo.currentHead), path = getPathFromRepoAndHead(repo.name, head), branchIsAnalyzed = repo.analyzedHeads[head];
60834
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "card gap-3 p-0", children: [
60835
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)(
60932
+ let [head, setHead] = (0, import_react66.useState)(repo.currentHead), path = getPathFromRepoAndHead(repo.name, head), branchIsAnalyzed = repo.analyzedHeads[head];
60933
+ return /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { children: /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "card gap-3 p-0", children: [
60934
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)(
60836
60935
  "h2",
60837
60936
  {
60838
60937
  className: `card__title rounded-t bg-gradient-to-r p-3 text-white ${branchIsAnalyzed ? " from-green-500 to-green-600 " : "from-gray-500 to-gray-600"}`,
60839
60938
  title: repo.name,
60840
60939
  children: [
60841
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("h2", { className: "line-clamp-1 break-all", children: repo.name }),
60842
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("span", { className: "align-content-start right-0 top-0 flex min-w-max select-none place-items-center rounded-full bg-white/20 px-2 py-1.5 text-xs font-bold uppercase leading-none tracking-widest text-white/90", children: branchIsAnalyzed ? "Ready" : "Not analyzed" })
60940
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("h2", { className: "line-clamp-1 break-all", children: repo.name }),
60941
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("span", { className: "align-content-start right-0 top-0 flex min-w-max select-none place-items-center rounded-full bg-white/20 px-2 py-1.5 text-xs font-bold uppercase leading-none tracking-widest text-white/90", children: branchIsAnalyzed ? "Ready" : "Not analyzed" })
60843
60942
  ]
60844
60943
  }
60845
60944
  ),
60846
- /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "flex flex-col gap-2 p-3 pt-0", children: [
60847
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
60945
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsxs)("div", { className: "flex flex-col gap-2 p-3 pt-0", children: [
60946
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(
60848
60947
  RevisionSelect,
60849
60948
  {
60850
60949
  value: head,
@@ -60853,13 +60952,13 @@ function RepositoryEntry({ repo }) {
60853
60952
  analyzedHeads: repo.analyzedHeads
60854
60953
  }
60855
60954
  ),
60856
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)("div", { className: "grid", children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(import_react64.Link, { className: `btn ${branchIsAnalyzed ? "btn--success" : ""}`, to: path, children: branchIsAnalyzed ? "View" : "Analyze" }) })
60955
+ /* @__PURE__ */ (0, import_jsx_runtime28.jsx)("div", { className: "grid", children: /* @__PURE__ */ (0, import_jsx_runtime28.jsx)(import_react65.Link, { className: `btn ${branchIsAnalyzed ? "btn--success" : ""}`, to: path, children: branchIsAnalyzed ? "View" : "Analyze" }) })
60857
60956
  ] })
60858
60957
  ] }) }, repo.name);
60859
60958
  }
60860
60959
 
60861
60960
  // server-assets-manifest:@remix-run/dev/assets-manifest
60862
- var assets_manifest_default = { entry: { module: "/build/entry.client-M7INZBM2.js", imports: ["/build/_shared/chunk-BUBLCW34.js", "/build/_shared/chunk-3UPJXOEK.js"] }, routes: { root: { id: "root", parentId: void 0, path: "", index: void 0, caseSensitive: void 0, module: "/build/root-WJJUW2IT.js", imports: ["/build/_shared/chunk-OC2B4XO6.js"], hasAction: !1, hasLoader: !1, hasCatchBoundary: !1, hasErrorBoundary: !0 }, "routes/$repo.$": { id: "routes/$repo.$", parentId: "root", path: ":repo/*", index: void 0, caseSensitive: void 0, module: "/build/routes/$repo.$-REZRHPX4.js", imports: ["/build/_shared/chunk-FPAJUGXO.js"], hasAction: !0, hasLoader: !0, hasCatchBoundary: !1, hasErrorBoundary: !0 }, "routes/_index": { id: "routes/_index", parentId: "root", path: void 0, index: !0, caseSensitive: void 0, module: "/build/routes/_index-S6SPE73O.js", imports: ["/build/_shared/chunk-FPAJUGXO.js"], hasAction: !1, hasLoader: !0, hasCatchBoundary: !1, hasErrorBoundary: !1 } }, cssBundleHref: void 0, version: "3a0a65b7", hmr: void 0, url: "/build/manifest-3A0A65B7.js" };
60961
+ var assets_manifest_default = { entry: { module: "/build/entry.client-M7INZBM2.js", imports: ["/build/_shared/chunk-BUBLCW34.js", "/build/_shared/chunk-3UPJXOEK.js"] }, routes: { root: { id: "root", parentId: void 0, path: "", index: void 0, caseSensitive: void 0, module: "/build/root-ZVIQW45T.js", imports: ["/build/_shared/chunk-OC2B4XO6.js"], hasAction: !1, hasLoader: !1, hasCatchBoundary: !1, hasErrorBoundary: !0 }, "routes/$repo.$": { id: "routes/$repo.$", parentId: "root", path: ":repo/*", index: void 0, caseSensitive: void 0, module: "/build/routes/$repo.$-W7XUG2YI.js", imports: ["/build/_shared/chunk-FPAJUGXO.js"], hasAction: !0, hasLoader: !0, hasCatchBoundary: !1, hasErrorBoundary: !0 }, "routes/_index": { id: "routes/_index", parentId: "root", path: void 0, index: !0, caseSensitive: void 0, module: "/build/routes/_index-S6SPE73O.js", imports: ["/build/_shared/chunk-FPAJUGXO.js"], hasAction: !1, hasLoader: !0, hasCatchBoundary: !1, hasErrorBoundary: !1 } }, cssBundleHref: void 0, version: "7e9df16d", hmr: void 0, url: "/build/manifest-7E9DF16D.js" };
60863
60962
 
60864
60963
  // server-entry-module:@remix-run/dev/server-build
60865
60964
  var assetsBuildDirectory = "public/build", future = { unstable_dev: !0, unstable_postcss: !1, unstable_tailwind: !1, v2_errorBoundary: !0, v2_meta: !0, v2_normalizeFormMethod: !0, v2_routeConvention: !0 }, publicPath = "/build/", entry = { module: entry_server_exports }, routes = {