@texonom/nreact 1.5.1 → 1.5.3

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
@@ -21,26 +21,26 @@ var le = (n, a) => {
21
21
  };
22
22
  import e from "react";
23
23
  import lt from "@fisch0920/medium-zoom";
24
- import { uuidToId as Ee, getBlockParentPage as Je, getPageTableOfContents as he, getTextContent as ie, getBlockCollectionId as it, getBlockIcon as ct, isUrl as st } from "@texonom/nutils";
24
+ import { uuidToId as ve, getBlockParentPage as Je, getPageTableOfContents as he, getTextContent as ie, getBlockCollectionId as it, getBlockIcon as ct, isUrl as st } from "@texonom/nutils";
25
25
  import { formatDate as Mt, formatNotionDateTime as Ht, isUrl as At } from "@texonom/nutils";
26
- import { u as ce, T as C, G as mt, E as dt, P as Xe, L as Ne, a as Ke, A as Qe, g as ut, N as ft } from "./asset-wrapper-CmbIDPIw.js";
27
- import { l as Dt, B as Rt, C as zt, H as Ut, k as Wt, e as Vt, f as qt, j as Gt, S as Yt, h as Zt, d as Jt, b as Xt, c as Kt, i as Qt } from "./asset-wrapper-CmbIDPIw.js";
28
- import { c as ve, g as pt } from "./_commonjsHelpers-bAxELxBV.js";
26
+ import { u as ce, T as C, G as mt, E as dt, P as Xe, L as Ne, a as Ke, A as Qe, g as ut, N as pt } from "./asset-wrapper-CaHInqoM.js";
27
+ import { l as Dt, B as Rt, C as zt, H as Ut, k as Wt, e as Vt, f as qt, j as Gt, S as Yt, h as Zt, d as Jt, b as Xt, c as Kt, i as Qt } from "./asset-wrapper-CaHInqoM.js";
28
+ import { c as Ee, g as ft } from "./_commonjsHelpers-bAxELxBV.js";
29
29
  import { C as tn, P as nn, i as on } from "./collection-column-title-l4hmVo49.js";
30
30
  const gt = ({ block: n, className: a }) => {
31
- var r, d, g;
32
- const { recordMap: o } = ce(), m = o.signed_urls[n.id] || ((g = (d = (r = n.properties) == null ? void 0 : r.source) == null ? void 0 : d[0]) == null ? void 0 : g[0]);
31
+ var r, d, v;
32
+ const { recordMap: o } = ce(), m = o.signed_urls[n.id] || ((v = (d = (r = n.properties) == null ? void 0 : r.source) == null ? void 0 : d[0]) == null ? void 0 : v[0]);
33
33
  return /* @__PURE__ */ e.createElement("div", { className: `notion-audio ${a || ""}` }, /* @__PURE__ */ e.createElement("audio", { controls: !0, preload: "none", src: m }));
34
- }, vt = (n) => {
34
+ }, Et = (n) => {
35
35
  const m = n, { className: a } = m, o = le(m, ["className"]);
36
36
  return /* @__PURE__ */ e.createElement("svg", be(W({ className: a }, o), { viewBox: "0 0 30 30" }), /* @__PURE__ */ e.createElement("path", { d: "M22,8v12c0,3.866-3.134,7-7,7s-7-3.134-7-7V8c0-2.762,2.238-5,5-5s5,2.238,5,5v12c0,1.657-1.343,3-3,3s-3-1.343-3-3V8h-2v12c0,2.762,2.238,5,5,5s5-2.238,5-5V8c0-3.866-3.134-7-7-7S6,4.134,6,8v12c0,4.971,4.029,9,9,9s9-4.029,9-9V8H22z" }));
37
- }, Et = ({ block: n, className: a }) => {
38
- var d, g, N, _, v;
39
- const { components: o, recordMap: m } = ce(), r = m.signed_urls[n.id] || ((N = (g = (d = n.properties) == null ? void 0 : d.source) == null ? void 0 : g[0]) == null ? void 0 : N[0]);
40
- return /* @__PURE__ */ e.createElement("div", { className: `notion-file ${a || ""}` }, /* @__PURE__ */ e.createElement(o.Link, { className: "notion-file-link", href: r, target: "_blank", rel: "noopener noreferrer" }, /* @__PURE__ */ e.createElement(vt, { className: "notion-file-icon" }), /* @__PURE__ */ e.createElement("div", { className: "notion-file-info" }, /* @__PURE__ */ e.createElement("div", { className: "notion-file-title" }, /* @__PURE__ */ e.createElement(C, { value: ((_ = n.properties) == null ? void 0 : _.title) || [["File"]], block: n })), ((v = n.properties) == null ? void 0 : v.size) && /* @__PURE__ */ e.createElement("div", { className: "notion-file-size" }, /* @__PURE__ */ e.createElement(C, { value: n.properties.size, block: n })))));
37
+ }, vt = ({ block: n, className: a }) => {
38
+ var d, v, N, y, b;
39
+ const { components: o, recordMap: m } = ce(), r = m.signed_urls[n.id] || ((N = (v = (d = n.properties) == null ? void 0 : d.source) == null ? void 0 : v[0]) == null ? void 0 : N[0]);
40
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-file ${a || ""}` }, /* @__PURE__ */ e.createElement(o.Link, { className: "notion-file-link", href: r, target: "_blank", rel: "noopener noreferrer" }, /* @__PURE__ */ e.createElement(Et, { className: "notion-file-icon" }), /* @__PURE__ */ e.createElement("div", { className: "notion-file-info" }, /* @__PURE__ */ e.createElement("div", { className: "notion-file-title" }, /* @__PURE__ */ e.createElement(C, { value: ((y = n.properties) == null ? void 0 : y.title) || [["File"]], block: n })), ((b = n.properties) == null ? void 0 : b.size) && /* @__PURE__ */ e.createElement("div", { className: "notion-file-size" }, /* @__PURE__ */ e.createElement(C, { value: n.properties.size, block: n })))));
41
41
  }, bt = ({ block: n, className: a }) => {
42
- var g;
43
- const { components: o, mapImageUrl: m } = ce(), r = (g = n.format) == null ? void 0 : g.drive_properties;
42
+ var v;
43
+ const { components: o, mapImageUrl: m } = ce(), r = (v = n.format) == null ? void 0 : v.drive_properties;
44
44
  if (!r) return null;
45
45
  let d;
46
46
  try {
@@ -68,69 +68,69 @@ var ke, et;
68
68
  function ht() {
69
69
  if (et) return ke;
70
70
  et = 1;
71
- var n = "Expected a function", a = NaN, o = "[object Symbol]", m = /^\s+|\s+$/g, r = /^[-+]0x[0-9a-f]+$/i, d = /^0b[01]+$/i, g = /^0o[0-7]+$/i, N = parseInt, _ = typeof ve == "object" && ve && ve.Object === Object && ve, v = typeof self == "object" && self && self.Object === Object && self, y = _ || v || Function("return this")(), T = Object.prototype, O = T.toString, L = Math.max, t = Math.min, f = function() {
72
- return y.Date.now();
71
+ var n = "Expected a function", a = NaN, o = "[object Symbol]", m = /^\s+|\s+$/g, r = /^[-+]0x[0-9a-f]+$/i, d = /^0b[01]+$/i, v = /^0o[0-7]+$/i, N = parseInt, y = typeof Ee == "object" && Ee && Ee.Object === Object && Ee, b = typeof self == "object" && self && self.Object === Object && self, _ = y || b || Function("return this")(), T = Object.prototype, O = T.toString, L = Math.max, t = Math.min, g = function() {
72
+ return _.Date.now();
73
73
  };
74
- function B(i, u, h) {
75
- var k, I, q, c, w, S, H = 0, te = !1, A = !1, G = !0;
74
+ function B(i, p, h) {
75
+ var k, I, q, c, x, S, H = 0, te = !1, A = !1, G = !0;
76
76
  if (typeof i != "function")
77
77
  throw new TypeError(n);
78
- u = R(u) || 0, M(h) && (te = !!h.leading, A = "maxWait" in h, q = A ? L(R(h.maxWait) || 0, u) : q, G = "trailing" in h ? !!h.trailing : G);
79
- function Y(p) {
78
+ p = R(p) || 0, M(h) && (te = !!h.leading, A = "maxWait" in h, q = A ? L(R(h.maxWait) || 0, p) : q, G = "trailing" in h ? !!h.trailing : G);
79
+ function Y(E) {
80
80
  var P = k, F = I;
81
- return k = I = void 0, H = p, c = i.apply(F, P), c;
81
+ return k = I = void 0, H = E, c = i.apply(F, P), c;
82
82
  }
83
- function se(p) {
84
- return H = p, w = setTimeout(z, u), te ? Y(p) : c;
83
+ function se(E) {
84
+ return H = E, x = setTimeout(z, p), te ? Y(E) : c;
85
85
  }
86
- function me(p) {
87
- var P = p - S, F = p - H, ae = u - P;
86
+ function me(E) {
87
+ var P = E - S, F = E - H, ae = p - P;
88
88
  return A ? t(ae, q - F) : ae;
89
89
  }
90
- function ne(p) {
91
- var P = p - S, F = p - H;
92
- return S === void 0 || P >= u || P < 0 || A && F >= q;
90
+ function ne(E) {
91
+ var P = E - S, F = E - H;
92
+ return S === void 0 || P >= p || P < 0 || A && F >= q;
93
93
  }
94
94
  function z() {
95
- var p = f();
96
- if (ne(p))
97
- return oe(p);
98
- w = setTimeout(z, me(p));
95
+ var E = g();
96
+ if (ne(E))
97
+ return oe(E);
98
+ x = setTimeout(z, me(E));
99
99
  }
100
- function oe(p) {
101
- return w = void 0, G && k ? Y(p) : (k = I = void 0, c);
100
+ function oe(E) {
101
+ return x = void 0, G && k ? Y(E) : (k = I = void 0, c);
102
102
  }
103
103
  function de() {
104
- w !== void 0 && clearTimeout(w), H = 0, k = S = I = w = void 0;
104
+ x !== void 0 && clearTimeout(x), H = 0, k = S = I = x = void 0;
105
105
  }
106
106
  function ue() {
107
- return w === void 0 ? c : oe(f());
107
+ return x === void 0 ? c : oe(g());
108
108
  }
109
109
  function Z() {
110
- var p = f(), P = ne(p);
111
- if (k = arguments, I = this, S = p, P) {
112
- if (w === void 0)
110
+ var E = g(), P = ne(E);
111
+ if (k = arguments, I = this, S = E, P) {
112
+ if (x === void 0)
113
113
  return se(S);
114
114
  if (A)
115
- return w = setTimeout(z, u), Y(S);
115
+ return x = setTimeout(z, p), Y(S);
116
116
  }
117
- return w === void 0 && (w = setTimeout(z, u)), c;
117
+ return x === void 0 && (x = setTimeout(z, p)), c;
118
118
  }
119
119
  return Z.cancel = de, Z.flush = ue, Z;
120
120
  }
121
- function V(i, u, h) {
121
+ function V(i, p, h) {
122
122
  var k = !0, I = !0;
123
123
  if (typeof i != "function")
124
124
  throw new TypeError(n);
125
- return M(h) && (k = "leading" in h ? !!h.leading : k, I = "trailing" in h ? !!h.trailing : I), B(i, u, {
125
+ return M(h) && (k = "leading" in h ? !!h.leading : k, I = "trailing" in h ? !!h.trailing : I), B(i, p, {
126
126
  leading: k,
127
- maxWait: u,
127
+ maxWait: p,
128
128
  trailing: I
129
129
  });
130
130
  }
131
131
  function M(i) {
132
- var u = typeof i;
133
- return !!i && (u == "object" || u == "function");
132
+ var p = typeof i;
133
+ return !!i && (p == "object" || p == "function");
134
134
  }
135
135
  function Q(i) {
136
136
  return !!i && typeof i == "object";
@@ -144,30 +144,30 @@ function ht() {
144
144
  if (ee(i))
145
145
  return a;
146
146
  if (M(i)) {
147
- var u = typeof i.valueOf == "function" ? i.valueOf() : i;
148
- i = M(u) ? u + "" : u;
147
+ var p = typeof i.valueOf == "function" ? i.valueOf() : i;
148
+ i = M(p) ? p + "" : p;
149
149
  }
150
150
  if (typeof i != "string")
151
151
  return i === 0 ? i : +i;
152
152
  i = i.replace(m, "");
153
153
  var h = d.test(i);
154
- return h || g.test(i) ? N(i.slice(2), h ? 2 : 8) : r.test(i) ? a : +i;
154
+ return h || v.test(i) ? N(i.slice(2), h ? 2 : 8) : r.test(i) ? a : +i;
155
155
  }
156
156
  return ke = V, ke;
157
157
  }
158
158
  var Nt = ht();
159
- const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSection: o, pageAside: m, hasToc: r, hasAside: d, className: g }) => {
160
- const _ = e.useMemo(
159
+ const kt = /* @__PURE__ */ ft(Nt), yt = ({ toc: n, activeSection: a, setActiveSection: o, pageAside: m, hasToc: r, hasAside: d, className: v }) => {
160
+ const y = e.useMemo(
161
161
  () => kt(() => {
162
- const v = document.getElementsByClassName("notion-h");
163
- let y = null, T = a;
164
- for (let O = 0; O < v.length; ++O) {
165
- const L = v[O];
162
+ const b = document.getElementsByClassName("notion-h");
163
+ let _ = null, T = a;
164
+ for (let O = 0; O < b.length; ++O) {
165
+ const L = b[O];
166
166
  if (!L || !(L instanceof Element)) continue;
167
167
  T || (T = L.getAttribute("data-id"));
168
- const t = L.getBoundingClientRect(), f = y ? t.top - y.bottom : 0, B = Math.max(150, f / 4);
168
+ const t = L.getBoundingClientRect(), g = _ ? t.top - _.bottom : 0, B = Math.max(150, g / 4);
169
169
  if (t.top - B < 0) {
170
- T = L.getAttribute("data-id"), y = t;
170
+ T = L.getAttribute("data-id"), _ = t;
171
171
  continue;
172
172
  }
173
173
  break;
@@ -182,19 +182,19 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
182
182
  );
183
183
  return e.useEffect(() => {
184
184
  if (r)
185
- return window.addEventListener("scroll", _), _(), () => {
186
- window.removeEventListener("scroll", _);
185
+ return window.addEventListener("scroll", y), y(), () => {
186
+ window.removeEventListener("scroll", y);
187
187
  };
188
- }, [r, _]), d ? /* @__PURE__ */ e.createElement("aside", { className: `notion-aside ${g || ""}` }, r && /* @__PURE__ */ e.createElement("div", { className: "notion-aside-table-of-contents" }, /* @__PURE__ */ e.createElement("div", { className: "notion-aside-table-of-contents-header" }, "Table of Contents"), /* @__PURE__ */ e.createElement("nav", { className: "notion-table-of-contents" }, n.map((v) => {
189
- const y = Ee(v.id);
188
+ }, [r, y]), d ? /* @__PURE__ */ e.createElement("aside", { className: `notion-aside ${v || ""}` }, r && /* @__PURE__ */ e.createElement("div", { className: "notion-aside-table-of-contents" }, /* @__PURE__ */ e.createElement("div", { className: "notion-aside-table-of-contents-header" }, "Table of Contents"), /* @__PURE__ */ e.createElement("nav", { className: "notion-table-of-contents" }, n.map((b) => {
189
+ const _ = ve(b.id);
190
190
  return /* @__PURE__ */ e.createElement(
191
191
  "a",
192
192
  {
193
- key: y,
194
- href: `#${y}`,
193
+ key: _,
194
+ href: `#${_}`,
195
195
  className: `notion-table-of-contents-item
196
- notion-table-of-contents-item-indent-level-${v.indentLevel}
197
- ${a === y && "notion-table-of-contents-active-item"}`
196
+ notion-table-of-contents-item-indent-level-${b.indentLevel}
197
+ ${a === _ && "notion-table-of-contents-active-item"}`
198
198
  },
199
199
  /* @__PURE__ */ e.createElement(
200
200
  "span",
@@ -202,19 +202,19 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
202
202
  className: "notion-table-of-contents-item-body",
203
203
  style: {
204
204
  display: "inline-block",
205
- marginLeft: v.indentLevel * 16
205
+ marginLeft: b.indentLevel * 16
206
206
  }
207
207
  },
208
- v.text
208
+ b.text
209
209
  )
210
210
  );
211
211
  }))), m) : null;
212
- }, yt = ({ block: n, level: a }) => {
212
+ }, _t = ({ block: n, level: a }) => {
213
213
  var r, d;
214
214
  if (!n)
215
215
  return process.env.NODE_ENV !== "production" && console.warn("missing sync pointer block", n.id), null;
216
216
  const o = n, m = (d = (r = o == null ? void 0 : o.format) == null ? void 0 : r.transclusion_reference_pointer) == null ? void 0 : d.id;
217
- return m ? /* @__PURE__ */ e.createElement(_e, { key: m, level: a, blockId: m }) : null;
217
+ return m ? /* @__PURE__ */ e.createElement(ye, { key: m, level: a, blockId: m }) : null;
218
218
  }, $t = (n) => {
219
219
  const m = n, { className: a } = m, o = le(m, ["className"]);
220
220
  return /* @__PURE__ */ e.createElement("svg", be(W({ className: a }, o), { viewBox: "0 0 16 16", width: "16", height: "16" }), /* @__PURE__ */ e.createElement(
@@ -225,21 +225,21 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
225
225
  }
226
226
  ));
227
227
  }, tt = {}, nt = {}, Ct = (n) => {
228
- var w, S, H, te, A, G, Y, se, me, ne, z, oe, de, ue, Z, p, P, F, ae, ye, $e, Ce, we, xe, Ie, Le, Pe, Te, Se, je, Oe, Be, Me, He, Ae, Fe, De, Re, ze, Ue, We, Ve, qe;
228
+ var x, S, H, te, A, G, Y, se, me, ne, z, oe, de, ue, Z, E, P, F, ae, _e, $e, Ce, xe, we, Ie, Le, Pe, Te, Se, je, Oe, Be, Me, He, Ae, Fe, De, Re, ze, Ue, We, Ve, qe;
229
229
  const a = ce(), {
230
230
  components: o,
231
231
  fullPage: m,
232
232
  recordMap: r,
233
233
  mapPageUrl: d,
234
- mapImageUrl: g,
234
+ mapImageUrl: v,
235
235
  showTableOfContents: N,
236
- minTableOfContentsItems: _,
237
- defaultPageIcon: v,
238
- defaultPageCover: y,
236
+ minTableOfContentsItems: y,
237
+ defaultPageIcon: b,
238
+ defaultPageCover: _,
239
239
  defaultPageCoverPosition: T
240
240
  } = a, [O, L] = e.useState(null), {
241
241
  block: t,
242
- children: f,
242
+ children: g,
243
243
  level: B,
244
244
  className: V,
245
245
  bodyClassName: M,
@@ -247,7 +247,7 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
247
247
  footer: ee,
248
248
  pageHeader: R,
249
249
  pageFooter: i,
250
- pageTitle: u,
250
+ pageTitle: p,
251
251
  pageAside: h,
252
252
  pageCover: k,
253
253
  hideBlockId: I,
@@ -258,32 +258,32 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
258
258
  const l = t;
259
259
  l.type = "collection_view_page";
260
260
  }
261
- const c = I ? "notion-block" : `notion-block-${Ee(t.id)}`;
261
+ const c = I ? "notion-block" : `notion-block-${ve(t.id)}`;
262
262
  switch (t.type) {
263
263
  case "collection_view_page":
264
264
  // fallthrough
265
265
  case "page":
266
266
  if (B === 0) {
267
267
  const {
268
- page_icon: l = v,
269
- page_cover: s = y,
270
- page_cover_position: E = T,
271
- page_full_width: b,
272
- page_small_text: x
268
+ page_icon: l = b,
269
+ page_cover: s = _,
270
+ page_cover_position: u = T,
271
+ page_full_width: f,
272
+ page_small_text: w
273
273
  } = t.format || {};
274
274
  if (m) {
275
275
  const $ = t.type === "page" ? t.properties : {
276
- title: (S = (w = r.collection[it(t, r)]) == null ? void 0 : w.value) == null ? void 0 : S.name
277
- }, D = `center ${(1 - (E || 0.5)) * 100}%`;
276
+ title: (S = (x = r.collection[it(t, r)]) == null ? void 0 : x.value) == null ? void 0 : S.name
277
+ }, D = `center ${(1 - (u || 0.5)) * 100}%`;
278
278
  let j = nt[D];
279
279
  j || (j = nt[D] = {
280
280
  objectPosition: D
281
281
  });
282
- const X = (H = ct(t, r)) != null ? H : v, U = X && st(X), re = he(t, r), fe = N && re.length >= _, K = (fe || h) && !b, pe = k || s;
283
- return /* @__PURE__ */ e.createElement("div", { className: `notion notion-app ${c} ${V || ""}` }, /* @__PURE__ */ e.createElement("div", { className: "notion-viewport" }), /* @__PURE__ */ e.createElement("div", { className: "notion-frame" }, !q && /* @__PURE__ */ e.createElement(o.Header, { block: t }), Q, /* @__PURE__ */ e.createElement("div", { className: "notion-page-scroller" }, pe && (k || /* @__PURE__ */ e.createElement("div", { className: "notion-page-cover-wrapper" }, /* @__PURE__ */ e.createElement(
282
+ const X = (H = ct(t, r)) != null ? H : b, U = X && st(X), re = he(t, r), pe = N && re.length >= y, K = (pe || h) && !f, fe = k || s;
283
+ return /* @__PURE__ */ e.createElement("div", { className: `notion notion-app ${c} ${V || ""}` }, /* @__PURE__ */ e.createElement("div", { className: "notion-viewport" }), /* @__PURE__ */ e.createElement("div", { className: "notion-frame" }, !q && /* @__PURE__ */ e.createElement(o.Header, { block: t }), Q, /* @__PURE__ */ e.createElement("div", { className: "notion-page-scroller" }, fe && (k || /* @__PURE__ */ e.createElement("div", { className: "notion-page-cover-wrapper" }, /* @__PURE__ */ e.createElement(
284
284
  Ne,
285
285
  {
286
- src: g(s, t),
286
+ src: v(s, t),
287
287
  alt: ie($ == null ? void 0 : $.title),
288
288
  priority: !0,
289
289
  className: "notion-page-cover",
@@ -293,33 +293,33 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
293
293
  "main",
294
294
  {
295
295
  className: `notion-page
296
- ${pe ? "notion-page-has-cover" : "notion-page-no-cover"}
296
+ ${fe ? "notion-page-has-cover" : "notion-page-no-cover"}
297
297
  ${l ? "notion-page-has-icon" : "notion-page-no-icon"}
298
298
  ${U ? "notion-page-has-image-icon" : "notion-page-has-text-icon"}
299
299
  notion-full-page
300
- ${b && "notion-full-width"}
301
- ${x && "notion-small-text"}
300
+ ${f && "notion-full-width"}
301
+ ${w && "notion-small-text"}
302
302
  ${M}`
303
303
  },
304
- l && /* @__PURE__ */ e.createElement(Ke, { block: t, defaultIcon: v, inline: !1 }),
304
+ l && /* @__PURE__ */ e.createElement(Ke, { block: t, defaultIcon: b, inline: !1 }),
305
305
  R,
306
- /* @__PURE__ */ e.createElement("h1", { className: "notion-title" }, u != null ? u : /* @__PURE__ */ e.createElement(C, { value: $ == null ? void 0 : $.title, block: t })),
306
+ /* @__PURE__ */ e.createElement("h1", { className: "notion-title" }, p != null ? p : /* @__PURE__ */ e.createElement(C, { value: $ == null ? void 0 : $.title, block: t })),
307
307
  (t.type === "collection_view_page" || t.type === "page" && t.parent_table === "collection") && /* @__PURE__ */ e.createElement(o.Collection, { block: t, ctx: a }),
308
308
  t.type !== "collection_view_page" && /* @__PURE__ */ e.createElement(
309
309
  "div",
310
310
  {
311
311
  className: `notion-page-content
312
312
  ${K && "notion-page-content-has-aside"}
313
- ${fe && "notion-page-content-has-toc"}`
313
+ ${pe && "notion-page-content-has-toc"}`
314
314
  },
315
- /* @__PURE__ */ e.createElement("article", { className: "notion-page-content-inner" }, f),
315
+ /* @__PURE__ */ e.createElement("article", { className: "notion-page-content-inner" }, g),
316
316
  K && /* @__PURE__ */ e.createElement(
317
- _t,
317
+ yt,
318
318
  {
319
319
  toc: re,
320
320
  activeSection: O,
321
321
  setActiveSection: L,
322
- hasToc: fe,
322
+ hasToc: pe,
323
323
  hasAside: K,
324
324
  pageAside: h
325
325
  }
@@ -333,8 +333,8 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
333
333
  {
334
334
  className: `notion
335
335
  notion-page
336
- ${b && "notion-full-width"}
337
- ${x && "notion-small-text"}
336
+ ${f && "notion-full-width"}
337
+ ${w && "notion-small-text"}
338
338
  ${c}
339
339
  ${V || ""}
340
340
  ${M}`
@@ -342,7 +342,7 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
342
342
  /* @__PURE__ */ e.createElement("div", { className: "notion-viewport" }),
343
343
  R,
344
344
  (t.type === "collection_view_page" || t.type === "page" && t.parent_table === "collection") && /* @__PURE__ */ e.createElement(o.Collection, { block: t, ctx: a }),
345
- t.type !== "collection_view_page" && f,
345
+ t.type !== "collection_view_page" && g,
346
346
  i
347
347
  );
348
348
  } else {
@@ -362,40 +362,40 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
362
362
  // fallthrough
363
363
  case "sub_sub_header": {
364
364
  if (!t.properties) return null;
365
- const l = (A = t.format) == null ? void 0 : A.block_color, s = Ee(t.id), E = ie(t.properties.title) || `Notion Header ${s}`;
366
- let b = tt[t.id], x;
367
- if (b === void 0) {
365
+ const l = (A = t.format) == null ? void 0 : A.block_color, s = ve(t.id), u = ie(t.properties.title) || `Notion Header ${s}`;
366
+ let f = tt[t.id], w;
367
+ if (f === void 0) {
368
368
  const re = Je(t, r);
369
369
  if (re) {
370
- const K = he(re, r).find((pe) => pe.id === t.id);
371
- K && (b = K.indentLevel, tt[t.id] = b);
370
+ const K = he(re, r).find((fe) => fe.id === t.id);
371
+ K && (f = K.indentLevel, tt[t.id] = f);
372
372
  }
373
373
  }
374
- b !== void 0 && (x = `notion-h-indent-${b}`);
374
+ f !== void 0 && (w = `notion-h-indent-${f}`);
375
375
  const $ = t.type === "header", J = t.type === "sub_header", D = t.type === "sub_sub_header", j = `${$ && "notion-h notion-h1"}
376
376
  ${J && "notion-h notion-h2"}
377
377
  ${D && "notion-h notion-h3"}
378
378
  ${l && `notion-${l}`}
379
- ${x},
380
- ${c}`, X = /* @__PURE__ */ e.createElement("span", null, /* @__PURE__ */ e.createElement("div", { id: s, className: "notion-header-anchor" }), !((G = t.format) != null && G.toggleable) && /* @__PURE__ */ e.createElement("a", { className: "notion-hash-link", href: `#${s}`, title: E }, /* @__PURE__ */ e.createElement($t, null)), /* @__PURE__ */ e.createElement("span", { className: "notion-h-title" }, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })));
379
+ ${w},
380
+ ${c}`, X = /* @__PURE__ */ e.createElement("span", null, /* @__PURE__ */ e.createElement("div", { id: s, className: "notion-header-anchor" }), !((G = t.format) != null && G.toggleable) && /* @__PURE__ */ e.createElement("a", { className: "notion-hash-link", href: `#${s}`, title: u }, /* @__PURE__ */ e.createElement($t, null)), /* @__PURE__ */ e.createElement("span", { className: "notion-h-title" }, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })));
381
381
  let U = null;
382
- return $ ? U = /* @__PURE__ */ e.createElement("h2", { className: j, "data-id": s }, X) : J ? U = /* @__PURE__ */ e.createElement("h3", { className: j, "data-id": s }, X) : U = /* @__PURE__ */ e.createElement("h4", { className: j, "data-id": s }, X), (Y = t.format) != null && Y.toggleable ? /* @__PURE__ */ e.createElement("details", { className: `notion-toggle ${c}` }, /* @__PURE__ */ e.createElement("summary", null, U), /* @__PURE__ */ e.createElement("div", null, f)) : U;
382
+ return $ ? U = /* @__PURE__ */ e.createElement("h2", { className: j, "data-id": s }, X) : J ? U = /* @__PURE__ */ e.createElement("h3", { className: j, "data-id": s }, X) : U = /* @__PURE__ */ e.createElement("h4", { className: j, "data-id": s }, X), (Y = t.format) != null && Y.toggleable ? /* @__PURE__ */ e.createElement("details", { className: `notion-toggle ${c}` }, /* @__PURE__ */ e.createElement("summary", null, U), /* @__PURE__ */ e.createElement("div", null, g)) : U;
383
383
  }
384
384
  case "divider":
385
385
  return /* @__PURE__ */ e.createElement("hr", { className: `notion-hr ${c}` });
386
386
  case "text": {
387
387
  if (!t.properties && !((se = t.content) != null && se.length)) return /* @__PURE__ */ e.createElement("div", { className: `notion-blank ${c}` }, " ");
388
388
  const l = (me = t.format) == null ? void 0 : me.block_color;
389
- return /* @__PURE__ */ e.createElement("div", { className: `notion-text ${l && `notion-${l}`} ${c}` }, ((ne = t.properties) == null ? void 0 : ne.title) && /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t }), f && /* @__PURE__ */ e.createElement("div", { className: "notion-text-children" }, f));
389
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-text ${l && `notion-${l}`} ${c}` }, ((ne = t.properties) == null ? void 0 : ne.title) && /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t }), g && /* @__PURE__ */ e.createElement("div", { className: "notion-text-children" }, g));
390
390
  }
391
391
  case "bulleted_list":
392
392
  // fallthrough
393
393
  case "numbered_list": {
394
- const l = (x, $) => t.type === "bulleted_list" ? /* @__PURE__ */ e.createElement("ul", { className: `notion-list notion-list-disc ${c}` }, x) : /* @__PURE__ */ e.createElement("ol", { start: $, className: `notion-list notion-list-numbered ${c}` }, x);
394
+ const l = (w, $) => t.type === "bulleted_list" ? /* @__PURE__ */ e.createElement("ul", { className: `notion-list notion-list-disc ${c}` }, w) : /* @__PURE__ */ e.createElement("ol", { start: $, className: `notion-list notion-list-numbered ${c}` }, w);
395
395
  let s = null;
396
- t.content ? s = /* @__PURE__ */ e.createElement(e.Fragment, null, t.properties && /* @__PURE__ */ e.createElement("li", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })), l(f)) : s = t.properties ? /* @__PURE__ */ e.createElement("li", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })) : null;
397
- const E = t.type !== ((oe = (z = r.block[t.parent_id]) == null ? void 0 : z.value) == null ? void 0 : oe.type), b = ut(t.id, r.block);
398
- return E ? l(s, b) : s;
396
+ t.content ? s = /* @__PURE__ */ e.createElement(e.Fragment, null, t.properties && /* @__PURE__ */ e.createElement("li", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })), l(g)) : s = t.properties ? /* @__PURE__ */ e.createElement("li", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })) : null;
397
+ const u = t.type !== ((oe = (z = r.block[t.parent_id]) == null ? void 0 : z.value) == null ? void 0 : oe.type), f = ut(t.id, r.block);
398
+ return u ? l(s, f) : s;
399
399
  }
400
400
  case "embed":
401
401
  return /* @__PURE__ */ e.createElement(o.Embed, { blockId: c, block: t });
@@ -424,21 +424,21 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
424
424
  case "audio":
425
425
  return /* @__PURE__ */ e.createElement(gt, { block: t, className: c });
426
426
  case "file":
427
- return /* @__PURE__ */ e.createElement(Et, { block: t, className: c });
427
+ return /* @__PURE__ */ e.createElement(vt, { block: t, className: c });
428
428
  case "equation":
429
429
  return /* @__PURE__ */ e.createElement(o.Equation, { block: t, inline: !1, className: c });
430
430
  case "code":
431
431
  return /* @__PURE__ */ e.createElement(o.Code, { block: t });
432
432
  case "column_list":
433
- return /* @__PURE__ */ e.createElement("div", { className: `notion-row ${c}` }, f);
433
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-row ${c}` }, g);
434
434
  case "column": {
435
- const l = "min(32px, 4vw)", s = ((Z = t.format) == null ? void 0 : Z.column_ratio) || 0.5, E = (p = r.block[t.parent_id]) == null ? void 0 : p.value, $ = { width: `calc((100% - (${(((P = E == null ? void 0 : E.content) == null ? void 0 : P.length) || Math.max(2, Math.ceil(1 / s))) - 1} * ${l})) * ${s})` };
436
- return /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", { className: `notion-column ${c}`, style: $ }, f), /* @__PURE__ */ e.createElement("div", { className: "notion-spacer" }));
435
+ const l = "min(32px, 4vw)", s = ((Z = t.format) == null ? void 0 : Z.column_ratio) || 0.5, u = (E = r.block[t.parent_id]) == null ? void 0 : E.value, $ = { width: `calc((100% - (${(((P = u == null ? void 0 : u.content) == null ? void 0 : P.length) || Math.max(2, Math.ceil(1 / s))) - 1} * ${l})) * ${s})` };
436
+ return /* @__PURE__ */ e.createElement(e.Fragment, null, /* @__PURE__ */ e.createElement("div", { className: `notion-column ${c}`, style: $ }, g), /* @__PURE__ */ e.createElement("div", { className: "notion-spacer" }));
437
437
  }
438
438
  case "quote": {
439
439
  if (!t.properties) return null;
440
440
  const l = (F = t.format) == null ? void 0 : F.block_color;
441
- return /* @__PURE__ */ e.createElement("blockquote", { className: `notion-quote ${l && `notion-${l}`} ${c}` }, /* @__PURE__ */ e.createElement("div", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })), f);
441
+ return /* @__PURE__ */ e.createElement("blockquote", { className: `notion-quote ${l && `notion-${l}`} ${c}` }, /* @__PURE__ */ e.createElement("div", null, /* @__PURE__ */ e.createElement(C, { value: t.properties.title, block: t })), g);
442
442
  }
443
443
  case "collection_view":
444
444
  return /* @__PURE__ */ e.createElement(o.Collection, { block: t, className: c, ctx: a });
@@ -446,10 +446,10 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
446
446
  return o.Callout ? /* @__PURE__ */ e.createElement(o.Callout, { block: t, className: c }) : /* @__PURE__ */ e.createElement(
447
447
  "div",
448
448
  {
449
- className: `notion-callout ${((ae = t.format) == null ? void 0 : ae.block_color) && `notion-${(ye = t.format) == null ? void 0 : ye.block_color}_co`} ${c}`
449
+ className: `notion-callout ${((ae = t.format) == null ? void 0 : ae.block_color) && `notion-${(_e = t.format) == null ? void 0 : _e.block_color}_co`} ${c}`
450
450
  },
451
451
  /* @__PURE__ */ e.createElement(Ke, { block: t }),
452
- /* @__PURE__ */ e.createElement("div", { className: "notion-callout-text" }, /* @__PURE__ */ e.createElement(C, { value: ($e = t.properties) == null ? void 0 : $e.title, block: t }), f)
452
+ /* @__PURE__ */ e.createElement("div", { className: "notion-callout-text" }, /* @__PURE__ */ e.createElement(C, { value: ($e = t.properties) == null ? void 0 : $e.title, block: t }), g)
453
453
  );
454
454
  case "bookmark": {
455
455
  if (!t.properties) return null;
@@ -459,76 +459,90 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
459
459
  if (s || (s = ie(l)), s && s.startsWith("http"))
460
460
  try {
461
461
  s = new URL(s).hostname;
462
- } catch (E) {
462
+ } catch (u) {
463
463
  }
464
- return /* @__PURE__ */ e.createElement("div", { className: "notion-row" }, /* @__PURE__ */ e.createElement(
464
+ return /* @__PURE__ */ e.createElement(
465
465
  o.Link,
466
466
  {
467
467
  target: "_blank",
468
468
  rel: "noopener noreferrer",
469
- className: `notion-bookmark ${((we = t.format) == null ? void 0 : we.block_color) && `notion-${t.format.block_color}`} ${c}`,
469
+ className: `notion-bookmark ${((xe = t.format) == null ? void 0 : xe.block_color) && `notion-${t.format.block_color}`} ${c}`,
470
470
  href: l[0][0]
471
471
  },
472
- /* @__PURE__ */ e.createElement("div", null, s && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-title" }, /* @__PURE__ */ e.createElement(C, { value: [[s]], block: t })), ((xe = t.properties) == null ? void 0 : xe.description) && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-description" }, /* @__PURE__ */ e.createElement(C, { value: (Ie = t.properties) == null ? void 0 : Ie.description, block: t })), /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link" }, ((Le = t.format) == null ? void 0 : Le.bookmark_icon) && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link-icon" }, /* @__PURE__ */ e.createElement(Ne, { src: g((Pe = t.format) == null ? void 0 : Pe.bookmark_icon, t), alt: s })), /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link-text" }, /* @__PURE__ */ e.createElement(C, { value: l, block: t })))),
472
+ /* @__PURE__ */ e.createElement("div", null, s && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-title" }, /* @__PURE__ */ e.createElement(C, { value: [[s]], block: t })), ((we = t.properties) == null ? void 0 : we.description) && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-description" }, /* @__PURE__ */ e.createElement(C, { value: (Ie = t.properties) == null ? void 0 : Ie.description, block: t })), /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link" }, ((Le = t.format) == null ? void 0 : Le.bookmark_icon) && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link-icon" }, /* @__PURE__ */ e.createElement(
473
+ Ne,
474
+ {
475
+ src: v((Pe = t.format) == null ? void 0 : Pe.bookmark_icon, t),
476
+ alt: s,
477
+ onError: (u) => {
478
+ const f = u.currentTarget;
479
+ f.style.display = "none";
480
+ }
481
+ }
482
+ )), /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-link-text" }, /* @__PURE__ */ e.createElement(C, { value: l, block: t })))),
473
483
  ((Te = t.format) == null ? void 0 : Te.bookmark_cover) && /* @__PURE__ */ e.createElement("div", { className: "notion-bookmark-image" }, /* @__PURE__ */ e.createElement(
474
484
  Ne,
475
485
  {
476
- src: g((Se = t.format) == null ? void 0 : Se.bookmark_cover, t),
486
+ src: v((Se = t.format) == null ? void 0 : Se.bookmark_cover, t),
477
487
  alt: ie((je = t.properties) == null ? void 0 : je.title),
478
488
  style: {
479
489
  objectFit: "cover"
490
+ },
491
+ onError: (u) => {
492
+ const f = u.currentTarget;
493
+ f.style.display = "none";
480
494
  }
481
495
  }
482
496
  ))
483
- ));
497
+ );
484
498
  }
485
499
  case "toggle":
486
- return /* @__PURE__ */ e.createElement("details", { className: `notion-toggle ${c}` }, /* @__PURE__ */ e.createElement("summary", null, /* @__PURE__ */ e.createElement(C, { value: (Oe = t.properties) == null ? void 0 : Oe.title, block: t })), /* @__PURE__ */ e.createElement("div", null, f));
500
+ return /* @__PURE__ */ e.createElement("details", { className: `notion-toggle ${c}` }, /* @__PURE__ */ e.createElement("summary", null, /* @__PURE__ */ e.createElement(C, { value: (Oe = t.properties) == null ? void 0 : Oe.title, block: t })), /* @__PURE__ */ e.createElement("div", null, g));
487
501
  case "table_of_contents": {
488
502
  const l = Je(t, r);
489
503
  if (!l) return null;
490
- const s = he(l, r), E = (Be = t.format) == null ? void 0 : Be.block_color;
491
- return /* @__PURE__ */ e.createElement("div", { className: `notion-table-of-contents ${E && `notion-${E}`} ${c}` }, s.map((b) => /* @__PURE__ */ e.createElement("a", { key: b.id, href: `#${Ee(b.id)}`, className: "notion-table-of-contents-item" }, /* @__PURE__ */ e.createElement(
504
+ const s = he(l, r), u = (Be = t.format) == null ? void 0 : Be.block_color;
505
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-table-of-contents ${u && `notion-${u}`} ${c}` }, s.map((f) => /* @__PURE__ */ e.createElement("a", { key: f.id, href: `#${ve(f.id)}`, className: "notion-table-of-contents-item" }, /* @__PURE__ */ e.createElement(
492
506
  "span",
493
507
  {
494
508
  className: "notion-table-of-contents-item-body",
495
509
  style: {
496
510
  display: "inline-block",
497
- marginLeft: b.indentLevel * 24
511
+ marginLeft: f.indentLevel * 24
498
512
  }
499
513
  },
500
- b.text
514
+ f.text
501
515
  ))));
502
516
  }
503
517
  case "to_do": {
504
518
  const l = ((Ae = (He = (Me = t.properties) == null ? void 0 : Me.checked) == null ? void 0 : He[0]) == null ? void 0 : Ae[0]) === "Yes";
505
- return /* @__PURE__ */ e.createElement("div", { className: `notion-to-do ${c}` }, /* @__PURE__ */ e.createElement("div", { className: "notion-to-do-item" }, /* @__PURE__ */ e.createElement(o.Checkbox, { blockId: c, isChecked: l }), /* @__PURE__ */ e.createElement("div", { className: `notion-to-do-body ${l && "notion-to-do-checked"}` }, /* @__PURE__ */ e.createElement(C, { value: (Fe = t.properties) == null ? void 0 : Fe.title, block: t }))), /* @__PURE__ */ e.createElement("div", { className: "notion-to-do-children" }, f));
519
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-to-do ${c}` }, /* @__PURE__ */ e.createElement("div", { className: "notion-to-do-item" }, /* @__PURE__ */ e.createElement(o.Checkbox, { blockId: c, isChecked: l }), /* @__PURE__ */ e.createElement("div", { className: `notion-to-do-body ${l && "notion-to-do-checked"}` }, /* @__PURE__ */ e.createElement(C, { value: (Fe = t.properties) == null ? void 0 : Fe.title, block: t }))), /* @__PURE__ */ e.createElement("div", { className: "notion-to-do-children" }, g));
506
520
  }
507
521
  case "transclusion_container":
508
- return /* @__PURE__ */ e.createElement("div", { className: `notion-sync-block ${c}` }, f);
522
+ return /* @__PURE__ */ e.createElement("div", { className: `notion-sync-block ${c}` }, g);
509
523
  case "transclusion_reference":
510
- return /* @__PURE__ */ e.createElement(yt, W({ block: t, level: B + 1 }, n));
524
+ return /* @__PURE__ */ e.createElement(_t, W({ block: t, level: B + 1 }, n));
511
525
  case "alias": {
512
526
  const l = (Re = (De = t == null ? void 0 : t.format) == null ? void 0 : De.alias_pointer) == null ? void 0 : Re.id, s = (ze = r.block[l]) == null ? void 0 : ze.value;
513
527
  return s ? /* @__PURE__ */ e.createElement(o.PageLink, { className: `notion-page-link ${l}}`, href: d(l) }, /* @__PURE__ */ e.createElement(Xe, { block: s })) : (console.debug('"alias" missing block', l), null);
514
528
  }
515
529
  case "table":
516
- return /* @__PURE__ */ e.createElement("table", { className: `notion-simple-table ${c}` }, /* @__PURE__ */ e.createElement("tbody", null, f));
530
+ return /* @__PURE__ */ e.createElement("table", { className: `notion-simple-table ${c}` }, /* @__PURE__ */ e.createElement("tbody", null, g));
517
531
  case "table_row": {
518
- const l = (Ue = r.block[t.parent_id]) == null ? void 0 : Ue.value, s = (We = l.format) == null ? void 0 : We.table_block_column_order, E = (Ve = l.format) == null ? void 0 : Ve.table_block_column_format, b = (qe = t.format) == null ? void 0 : qe.block_color;
519
- return !l || !s ? null : /* @__PURE__ */ e.createElement("tr", { className: `notion-simple-table-row ${b && `notion-${b}`} ${c}` }, s.map((x) => {
532
+ const l = (Ue = r.block[t.parent_id]) == null ? void 0 : Ue.value, s = (We = l.format) == null ? void 0 : We.table_block_column_order, u = (Ve = l.format) == null ? void 0 : Ve.table_block_column_format, f = (qe = t.format) == null ? void 0 : qe.block_color;
533
+ return !l || !s ? null : /* @__PURE__ */ e.createElement("tr", { className: `notion-simple-table-row ${f && `notion-${f}`} ${c}` }, s.map((w) => {
520
534
  var J, D, j;
521
- const $ = (J = E == null ? void 0 : E[x]) == null ? void 0 : J.color;
535
+ const $ = (J = u == null ? void 0 : u[w]) == null ? void 0 : J.color;
522
536
  return /* @__PURE__ */ e.createElement(
523
537
  "td",
524
538
  {
525
- key: x,
539
+ key: w,
526
540
  className: $ ? `notion-${$}` : "",
527
541
  style: {
528
- width: ((D = E == null ? void 0 : E[x]) == null ? void 0 : D.width) || 120
542
+ width: ((D = u == null ? void 0 : u[w]) == null ? void 0 : D.width) || 120
529
543
  }
530
544
  },
531
- /* @__PURE__ */ e.createElement("div", { className: "notion-simple-table-cell" }, /* @__PURE__ */ e.createElement(C, { value: ((j = t.properties) == null ? void 0 : j[x]) || [["ㅤ"]], block: t }))
545
+ /* @__PURE__ */ e.createElement("div", { className: "notion-simple-table-cell" }, /* @__PURE__ */ e.createElement(C, { value: ((j = t.properties) == null ? void 0 : j[w]) || [["ㅤ"]], block: t }))
532
546
  );
533
547
  }));
534
548
  }
@@ -545,16 +559,16 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
545
559
  mapImageUrl: m,
546
560
  searchNotion: r,
547
561
  isShowingSearch: d,
548
- onHideSearch: g,
562
+ onHideSearch: v,
549
563
  fullPage: N,
550
- rootPageId: _,
551
- rootDomain: v,
552
- rootSpaceId: y,
564
+ rootPageId: y,
565
+ rootDomain: b,
566
+ rootSpaceId: _,
553
567
  darkMode: T,
554
568
  previewImages: O,
555
569
  forceCustomImages: L,
556
570
  showCollectionViewDropdown: t,
557
- linkTableTitleProperties: f,
571
+ linkTableTitleProperties: g,
558
572
  isLinkCollectionToUrlProperty: B,
559
573
  isImageZoomable: V = !0,
560
574
  showTableOfContents: M,
@@ -562,7 +576,7 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
562
576
  defaultPageIcon: ee,
563
577
  defaultPageCover: R,
564
578
  defaultPageCoverPosition: i
565
- } = k, u = le(k, [
579
+ } = k, p = le(k, [
566
580
  "components",
567
581
  "recordMap",
568
582
  "mapPageUrl",
@@ -591,12 +605,12 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
591
605
  () => typeof window != "undefined" && lt({
592
606
  background: "rgba(0, 0, 0, 0.8)",
593
607
  minZoomScale: 2,
594
- margin: wt()
608
+ margin: xt()
595
609
  }),
596
610
  []
597
611
  );
598
612
  return /* @__PURE__ */ e.createElement(
599
- ft,
613
+ pt,
600
614
  {
601
615
  components: n,
602
616
  recordMap: a,
@@ -604,16 +618,16 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
604
618
  mapImageUrl: m,
605
619
  searchNotion: r,
606
620
  isShowingSearch: d,
607
- onHideSearch: g,
621
+ onHideSearch: v,
608
622
  fullPage: N,
609
- rootPageId: _,
610
- rootDomain: v,
611
- rootSpaceId: y,
623
+ rootPageId: y,
624
+ rootDomain: b,
625
+ rootSpaceId: _,
612
626
  darkMode: T,
613
627
  previewImages: O,
614
628
  forceCustomImages: L,
615
629
  showCollectionViewDropdown: t,
616
- linkTableTitleProperties: f,
630
+ linkTableTitleProperties: g,
617
631
  isLinkCollectionToUrlProperty: B,
618
632
  showTableOfContents: M,
619
633
  minTableOfContentsItems: Q,
@@ -622,15 +636,15 @@ const kt = /* @__PURE__ */ pt(Nt), _t = ({ toc: n, activeSection: a, setActiveSe
622
636
  defaultPageCoverPosition: i,
623
637
  zoom: V ? I : null
624
638
  },
625
- /* @__PURE__ */ e.createElement(_e, W({}, u))
639
+ /* @__PURE__ */ e.createElement(ye, W({}, p))
626
640
  );
627
- }, _e = (m) => {
641
+ }, ye = (m) => {
628
642
  var r = m, { level: n = 0, blockId: a } = r, o = le(r, ["level", "blockId"]);
629
- var _, v;
630
- const { recordMap: d } = ce(), g = a || Object.keys(d.block)[0], N = (_ = d.block[g]) == null ? void 0 : _.value;
631
- return N ? /* @__PURE__ */ e.createElement(Ct, W({ key: g, level: n, block: N }, o), (v = N == null ? void 0 : N.content) == null ? void 0 : v.map((y) => /* @__PURE__ */ e.createElement(_e, W({ key: y, blockId: y, level: n + 1 }, o)))) : (process.env.NODE_ENV !== "production" && console.warn("missing block", a), null);
643
+ var y, b;
644
+ const { recordMap: d } = ce(), v = a || Object.keys(d.block)[0], N = (y = d.block[v]) == null ? void 0 : y.value;
645
+ return N ? /* @__PURE__ */ e.createElement(Ct, W({ key: v, level: n, block: N }, o), (b = N == null ? void 0 : N.content) == null ? void 0 : b.map((_) => /* @__PURE__ */ e.createElement(ye, W({ key: _, blockId: _, level: n + 1 }, o)))) : (process.env.NODE_ENV !== "production" && console.warn("missing block", a), null);
632
646
  };
633
- function wt() {
647
+ function xt() {
634
648
  const n = window.innerWidth;
635
649
  return n < 500 ? 8 : n < 800 ? 20 : n < 1280 ? 30 : n < 1600 ? 40 : n < 1920 ? 48 : 72;
636
650
  }
@@ -643,16 +657,16 @@ export {
643
657
  zt as Checkbox,
644
658
  tn as CollectionColumnTitle,
645
659
  dt as EOI,
646
- Et as File,
660
+ vt as File,
647
661
  bt as GoogleDrive,
648
662
  mt as GracefulImage,
649
663
  Ut as Header,
650
664
  Wt as LiteYouTubeEmbed,
651
- _e as NotionBlockRenderer,
665
+ ye as NotionBlockRenderer,
652
666
  Vt as NotionContextConsumer,
653
- ft as NotionContextProvider,
667
+ pt as NotionContextProvider,
654
668
  jt as NotionRenderer,
655
- _t as PageAside,
669
+ yt as PageAside,
656
670
  Ke as PageIcon,
657
671
  qt as PageIconImpl,
658
672
  Xe as PageTitle,
@@ -660,7 +674,7 @@ export {
660
674
  nn as PropertyIcon,
661
675
  Yt as Search,
662
676
  Zt as SearchDialog,
663
- yt as SyncPointerBlock,
677
+ _t as SyncPointerBlock,
664
678
  C as Text,
665
679
  Jt as dummyLink,
666
680
  Mt as formatDate,