@industry-theme/file-city-panel 0.5.78 → 0.5.79

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.
@@ -1 +1 @@
1
- {"version":3,"file":"TrailRequestIntroModal.d.ts","sourceRoot":"","sources":["../../../../src/panels/FileCityTrailExplorerPanel/overlays/TrailRequestIntroModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAY,KAAK,KAAK,EAAE,MAAM,+BAA+B,CAAC;AAErE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAmCzD;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,2BAA2B;IAC1C;;;;;;OAMG;IACH,IAAI,EAAE,MAAM,CAAC;IACb;;;;;OAKG;IACH,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB;;;;OAIG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;;OAGG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,gEAAgE;IAChE,WAAW,EAAE,MAAM,CAAC;IACpB,+EAA+E;IAC/E,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,uDAAuD;IACvD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;OAIG;IACH,KAAK,CAAC,EAAE;QAAE,EAAE,CAAC,EAAE,MAAM,CAAC;QAAC,KAAK,EAAE,MAAM,CAAC;QAAC,UAAU,CAAC,EAAE,MAAM,CAAA;KAAE,EAAE,CAAC;IAC9D,oDAAoD;IACpD,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;;;OAKG;IACH,WAAW,EAAE,MAAM,GAAG,KAAK,CAAC;IAC5B;;;OAGG;IACH,OAAO,EAAE,CAAC,IAAI,EAAE,MAAM,GAAG,KAAK,KAAK,IAAI,CAAC;IACxC;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,CAAC,SAAS,EAAE,MAAM,EAAE,IAAI,EAAE,MAAM,GAAG,KAAK,KAAK,IAAI,CAAC;IAClE,qEAAqE;IACrE,SAAS,EAAE,MAAM,IAAI,CAAC;IACtB;;;;OAIG;IACH,QAAQ,CAAC,EAAE,YAAY,EAAE,CAAC;IAC1B;;;;;;OAMG;IACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;IAC9B;;;;;;OAMG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB;;;;;;;;;;;;;;OAcG;IACH,SAAS,CAAC,EAAE;QACV,QAAQ,EAAE,MAAM,EAAE,CAAC;QACnB,cAAc,EAAE,MAAM,CAAC;KACxB,CAAC;IACF;;;;;;OAMG;IACH,aAAa,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,EAAE,CAAC,CAAC;CAC1C;AAED,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CA2qBxE,CAAC;AA6JF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC;IAC/B,KAAK,EAAE,KAAK,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb;;;uDAGmD;IACnD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;8BAC0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CA6CA,CAAC"}
1
+ {"version":3,"file":"TrailRequestIntroModal.d.ts","sourceRoot":"","sources":["../../../../src/panels/FileCityTrailExplorerPanel/overlays/TrailRequestIntroModal.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAY,KAAK,KAAK,EAAE,MAAM,+BAA+B,CAAC;AAErE,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,sBAAsB,CAAC;AAmCzD;;;;;;;;;;;GAWG;AACH,MAAM,WAAW,2BAA2B;IAC1C;;;;;;OAMG;IACH,IAAI,EAAE,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AAM,EAAE,MAAM,EAAE,CAAC,CAAC;CAC1C;AAED,eAAO,MAAM,sBAAsB,EAAE,KAAK,CAAC,EAAE,CAAC,2BAA2B,CAuvBxE,CAAC;AA6JF;;;;;;;;;;;;GAYG;AACH,eAAO,MAAM,SAAS,EAAE,KAAK,CAAC,EAAE,CAAC;IAC/B,KAAK,EAAE,KAAK,CAAC;IACb,IAAI,EAAE,MAAM,CAAC;IACb;;;uDAGmD;IACnD,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB;8BAC0B;IAC1B,IAAI,CAAC,EAAE,MAAM,CAAC;CACf,CA6CA,CAAC"}
@@ -258336,6 +258336,20 @@ const TrailRequestIntroModal = ({
258336
258336
  React.useEffect(() => {
258337
258337
  if (!showManifest) setNoteAuthorFilter(null);
258338
258338
  }, [showManifest]);
258339
+ const [expandedPaths, setExpandedPaths] = React.useState(
258340
+ () => /* @__PURE__ */ new Set()
258341
+ );
258342
+ React.useEffect(() => {
258343
+ if (!showManifest) setExpandedPaths(/* @__PURE__ */ new Set());
258344
+ }, [showManifest]);
258345
+ const togglePathExpansion = React.useCallback((index2) => {
258346
+ setExpandedPaths((prev) => {
258347
+ const next2 = new Set(prev);
258348
+ if (next2.has(index2)) next2.delete(index2);
258349
+ else next2.add(index2);
258350
+ return next2;
258351
+ });
258352
+ }, []);
258339
258353
  const visitTotal = ((visitedBy == null ? void 0 : visitedBy.verified.length) ?? 0) + ((visitedBy == null ? void 0 : visitedBy.anonymousCount) ?? 0);
258340
258354
  const [selectedMode, setSelectedMode] = React.useState(
258341
258355
  defaultMode
@@ -258739,6 +258753,9 @@ const TrailRequestIntroModal = ({
258739
258753
  const clickable = !!onBeginAtStep;
258740
258754
  const matchesFilter = filteredMarkerIds != null && step.id != null && filteredMarkerIds.has(step.id);
258741
258755
  const dimmed = filteredMarkerIds != null && !matchesFilter;
258756
+ const fileName = step.sourcePath ? step.sourcePath.split("/").pop() || step.sourcePath : null;
258757
+ const pathExpanded = expandedPaths.has(i);
258758
+ const rowBackground = matchesFilter ? `color-mix(in srgb, ${theme2.colors.accent} 18%, transparent)` : "transparent";
258742
258759
  return /* @__PURE__ */ jsx(
258743
258760
  "li",
258744
258761
  {
@@ -258748,30 +258765,18 @@ const TrailRequestIntroModal = ({
258748
258765
  transition: "opacity 120ms ease"
258749
258766
  },
258750
258767
  children: /* @__PURE__ */ jsxs(
258751
- "button",
258768
+ "div",
258752
258769
  {
258753
- type: "button",
258754
- onClick: () => {
258755
- if (onBeginAtStep) onBeginAtStep(i, selectedMode);
258756
- },
258757
- disabled: !clickable,
258758
258770
  style: {
258759
- all: "unset",
258760
258771
  boxSizing: "border-box",
258761
258772
  display: "flex",
258762
- gap: 12,
258763
- alignItems: "baseline",
258773
+ flexDirection: "column",
258764
258774
  width: "100%",
258765
258775
  padding: "6px 8px",
258766
258776
  margin: "0 -8px",
258767
258777
  borderRadius: theme2.radii[1],
258768
- cursor: clickable ? "pointer" : "default",
258769
- fontFamily: "inherit",
258770
- fontSize: "inherit",
258771
- lineHeight: "inherit",
258772
- color: "inherit",
258773
258778
  transition: "background 100ms ease",
258774
- background: matchesFilter ? `color-mix(in srgb, ${theme2.colors.accent} 18%, transparent)` : "transparent",
258779
+ background: rowBackground,
258775
258780
  borderLeft: matchesFilter ? `3px solid ${theme2.colors.accent}` : "3px solid transparent",
258776
258781
  paddingLeft: 8
258777
258782
  },
@@ -258781,44 +258786,110 @@ const TrailRequestIntroModal = ({
258781
258786
  }
258782
258787
  },
258783
258788
  onMouseLeave: (e) => {
258784
- e.currentTarget.style.background = matchesFilter ? `color-mix(in srgb, ${theme2.colors.accent} 18%, transparent)` : "transparent";
258789
+ e.currentTarget.style.background = rowBackground;
258785
258790
  },
258786
- title: clickable ? `Start walkthrough at step ${i + 1}` : void 0,
258787
258791
  children: [
258788
- /* @__PURE__ */ jsx(
258789
- "span",
258790
- {
258791
- style: {
258792
- color: theme2.colors.textTertiary,
258793
- flexShrink: 0,
258794
- minWidth: 24
258795
- },
258796
- children: String(i + 1).padStart(2, "0")
258797
- }
258798
- ),
258799
- /* @__PURE__ */ jsx(
258800
- "span",
258792
+ /* @__PURE__ */ jsxs(
258793
+ "div",
258801
258794
  {
258802
258795
  style: {
258803
- flex: 1,
258804
- minWidth: 0,
258805
- color: theme2.colors.text
258796
+ display: "flex",
258797
+ gap: 12,
258798
+ alignItems: "baseline",
258799
+ width: "100%"
258806
258800
  },
258807
- children: step.label
258801
+ children: [
258802
+ /* @__PURE__ */ jsxs(
258803
+ "button",
258804
+ {
258805
+ type: "button",
258806
+ onClick: () => {
258807
+ if (onBeginAtStep) onBeginAtStep(i, selectedMode);
258808
+ },
258809
+ disabled: !clickable,
258810
+ title: clickable ? `Start walkthrough at step ${i + 1}` : void 0,
258811
+ style: {
258812
+ all: "unset",
258813
+ boxSizing: "border-box",
258814
+ display: "flex",
258815
+ gap: 12,
258816
+ alignItems: "baseline",
258817
+ flex: 1,
258818
+ minWidth: 0,
258819
+ cursor: clickable ? "pointer" : "default",
258820
+ fontFamily: "inherit",
258821
+ fontSize: "inherit",
258822
+ lineHeight: "inherit",
258823
+ color: "inherit"
258824
+ },
258825
+ children: [
258826
+ /* @__PURE__ */ jsx(
258827
+ "span",
258828
+ {
258829
+ style: {
258830
+ color: theme2.colors.textTertiary,
258831
+ flexShrink: 0,
258832
+ minWidth: 24
258833
+ },
258834
+ children: String(i + 1).padStart(2, "0")
258835
+ }
258836
+ ),
258837
+ /* @__PURE__ */ jsx(
258838
+ "span",
258839
+ {
258840
+ style: {
258841
+ flex: 1,
258842
+ minWidth: 0,
258843
+ color: theme2.colors.text,
258844
+ overflow: "hidden",
258845
+ textOverflow: "ellipsis",
258846
+ whiteSpace: "nowrap"
258847
+ },
258848
+ children: step.label
258849
+ }
258850
+ )
258851
+ ]
258852
+ }
258853
+ ),
258854
+ fileName ? /* @__PURE__ */ jsx(
258855
+ "button",
258856
+ {
258857
+ type: "button",
258858
+ onClick: () => togglePathExpansion(i),
258859
+ "aria-expanded": pathExpanded,
258860
+ title: pathExpanded ? "Hide full path" : step.sourcePath ?? void 0,
258861
+ style: {
258862
+ all: "unset",
258863
+ boxSizing: "border-box",
258864
+ flexShrink: 0,
258865
+ maxWidth: "50%",
258866
+ overflow: "hidden",
258867
+ textOverflow: "ellipsis",
258868
+ whiteSpace: "nowrap",
258869
+ color: pathExpanded ? theme2.colors.text : theme2.colors.textTertiary,
258870
+ cursor: "pointer",
258871
+ textDecoration: pathExpanded ? "underline" : "none",
258872
+ textDecorationStyle: "dotted",
258873
+ textUnderlineOffset: 2
258874
+ },
258875
+ children: fileName
258876
+ }
258877
+ ) : null
258878
+ ]
258808
258879
  }
258809
258880
  ),
258810
- step.sourcePath ? /* @__PURE__ */ jsx(
258811
- "span",
258881
+ pathExpanded && step.sourcePath ? /* @__PURE__ */ jsx(
258882
+ "div",
258812
258883
  {
258813
258884
  style: {
258885
+ marginTop: 4,
258886
+ marginLeft: 36,
258887
+ fontFamily: theme2.fonts.monospace,
258888
+ fontSize: theme2.fontSizes[0],
258814
258889
  color: theme2.colors.textTertiary,
258815
- flexShrink: 1,
258816
- minWidth: 0,
258817
- overflow: "hidden",
258818
- textOverflow: "ellipsis",
258819
- whiteSpace: "nowrap"
258890
+ wordBreak: "break-all",
258891
+ lineHeight: 1.4
258820
258892
  },
258821
- title: step.sourcePath,
258822
258893
  children: step.sourcePath
258823
258894
  }
258824
258895
  ) : null