@realiizlabs/admin 0.15.7 → 0.15.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.
@@ -1116,7 +1116,7 @@ function makeHandlers(ctx) {
1116
1116
  }
1117
1117
 
1118
1118
  // src/version.ts
1119
- var ADMIN_VERSION = "0.15.7" ;
1119
+ var ADMIN_VERSION = "0.15.8" ;
1120
1120
 
1121
1121
  // src/studio/update.ts
1122
1122
  var PACKAGE_NAME = "@realiizlabs/admin";
@@ -1104,7 +1104,7 @@ function makeHandlers(ctx) {
1104
1104
  }
1105
1105
 
1106
1106
  // src/version.ts
1107
- var ADMIN_VERSION = "0.15.7" ;
1107
+ var ADMIN_VERSION = "0.15.8" ;
1108
1108
 
1109
1109
  // src/studio/update.ts
1110
1110
  var PACKAGE_NAME = "@realiizlabs/admin";
@@ -739,7 +739,7 @@ function Tabs({ options, value, onChange, label = "Sections" }) {
739
739
  }
740
740
 
741
741
  // src/version.ts
742
- var ADMIN_VERSION = "0.15.7" ;
742
+ var ADMIN_VERSION = "0.15.8" ;
743
743
 
744
744
  // src/studio-ui/css.ts
745
745
  var STUDIO_CSS = `
@@ -906,12 +906,20 @@ var STUDIO_CSS = `
906
906
  .rz-admin .rz-help__search svg { position: absolute; left: .9rem; top: 50%; transform: translateY(-50%); color: var(--text-muted); pointer-events: none; }
907
907
  .rz-admin .rz-help__search input { width: 100%; padding-left: 2.6rem; font-size: 1rem; }
908
908
  .rz-admin .rz-help__body { display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: 2rem; align-items: start; }
909
- @media (max-width: 760px) { .rz-admin .rz-help__body { grid-template-columns: 1fr; gap: 1rem; } .rz-admin .rz-help__nav { display: flex; flex-wrap: wrap; gap: .25rem; } }
910
909
  .rz-admin .rz-help__nav { position: sticky; top: calc(var(--rz-topbar) + 1rem); display: flex; flex-direction: column; gap: .1rem; }
911
- .rz-admin .rz-help__navitem { padding: .45rem .75rem; border-radius: 6px; color: var(--text-secondary); text-decoration: none; font-size: .875rem; }
910
+ .rz-admin .rz-help__navitem { padding: .45rem .75rem; border-radius: 6px; color: var(--text-secondary); text-decoration: none; font-size: .875rem; white-space: nowrap; }
912
911
  .rz-admin .rz-help__navitem:hover { background: var(--surface-2); color: var(--text-primary); }
913
912
  .rz-admin .rz-help__navitem--active { background: var(--surface-2); color: var(--signal); font-weight: 500; }
914
913
  .rz-admin .rz-help__main { max-width: 44rem; min-width: 0; }
914
+ /* Phones: sections become one row of chips that scrolls sideways above the content (must come
915
+ after the desktop rules above \u2014 same specificity, last one wins). */
916
+ @media (max-width: 760px) {
917
+ .rz-admin .rz-help__body { grid-template-columns: 1fr; gap: 1rem; }
918
+ .rz-admin .rz-help__nav { position: static; flex-direction: row; gap: .35rem; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch; margin: 0 -14px; padding: .1rem 14px .4rem; -webkit-mask-image: linear-gradient(90deg, #000 calc(100% - 2.5rem), transparent); mask-image: linear-gradient(90deg, #000 calc(100% - 2.5rem), transparent); }
919
+ .rz-admin .rz-help__nav::-webkit-scrollbar { display: none; }
920
+ .rz-admin .rz-help__navitem { flex: 0 0 auto; border: 1px solid var(--border); border-radius: 999px; padding: .4rem .8rem; background: var(--surface-1); }
921
+ .rz-admin .rz-help__navitem--active { border-color: var(--signal); }
922
+ }
915
923
  .rz-admin .rz-help__h { font-family: var(--rz-font-display); font-size: 1.5rem; font-weight: 600; letter-spacing: -.01em; margin: 0 0 .35rem; }
916
924
  .rz-admin .rz-help__blurb { color: var(--text-secondary); margin: 0 0 1.25rem; }
917
925
  .rz-admin .rz-help__count { color: var(--text-muted); font-size: .85rem; margin: 0 0 .75rem; }
@@ -1071,7 +1079,8 @@ function InstallTracker({ installing, compact = false }) {
1071
1079
  }, []);
1072
1080
  const minimize = (on) => {
1073
1081
  try {
1074
- on ? localStorage.setItem(MIN_KEY, "1") : localStorage.removeItem(MIN_KEY);
1082
+ if (on) localStorage.setItem(MIN_KEY, "1");
1083
+ else localStorage.removeItem(MIN_KEY);
1075
1084
  } catch {
1076
1085
  }
1077
1086
  setMinimized(on);
@@ -5603,6 +5612,12 @@ function StudioHelp() {
5603
5612
  };
5604
5613
  const hits = q.trim().length > 1 ? searchHelp(q) : null;
5605
5614
  const activeSection = view.kind === "section" ? view.id : view.article.section;
5615
+ const nav = react.useRef(null);
5616
+ react.useEffect(() => {
5617
+ const el = nav.current;
5618
+ if (!el || el.scrollWidth <= el.clientWidth) return;
5619
+ el.querySelector(".rz-help__navitem--active")?.scrollIntoView?.({ inline: "center", block: "nearest" });
5620
+ }, [activeSection, hits]);
5606
5621
  return /* @__PURE__ */ jsxRuntime.jsxs("div", { ref: top, className: "rz-help", children: [
5607
5622
  /* @__PURE__ */ jsxRuntime.jsx(PageHeader, { eyebrow: "Help", title: "Help center", subtitle: "Everything about running your website from Studio, in plain English. Search, or browse by section." }),
5608
5623
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rz-help__search", children: [
@@ -5626,7 +5641,7 @@ function StudioHelp() {
5626
5641
  )
5627
5642
  ] }),
5628
5643
  /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "rz-help__body", children: [
5629
- /* @__PURE__ */ jsxRuntime.jsx("nav", { className: "rz-help__nav", "aria-label": "Help sections", children: HELP_SECTIONS.map((s) => /* @__PURE__ */ jsxRuntime.jsx("a", { href: `#s-${s.id}`, className: `rz-help__navitem${!hits && activeSection === s.id ? " rz-help__navitem--active" : ""}`, onClick: (e) => {
5644
+ /* @__PURE__ */ jsxRuntime.jsx("nav", { ref: nav, className: "rz-help__nav", "aria-label": "Help sections", children: HELP_SECTIONS.map((s) => /* @__PURE__ */ jsxRuntime.jsx("a", { href: `#s-${s.id}`, className: `rz-help__navitem${!hits && activeSection === s.id ? " rz-help__navitem--active" : ""}`, onClick: (e) => {
5630
5645
  e.preventDefault();
5631
5646
  go(`s-${s.id}`);
5632
5647
  }, children: s.title }, s.id)) }),