@hook-sdk/template 0.4.1 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.cts CHANGED
@@ -278,6 +278,7 @@ type SubscriptionStatus = 'active' | 'trialing' | 'expired' | 'canceled' | 'past
278
278
  declare function usePaywallState(): {
279
279
  status: SubscriptionStatus;
280
280
  daysLeftInTrial: number | null;
281
+ initialLoadComplete: boolean;
281
282
  checkout: (args: {
282
283
  cpf: string;
283
284
  cycle?: "MONTHLY" | "YEARLY";
@@ -466,7 +467,6 @@ interface InstallActions {
466
467
  promptInstall: () => Promise<boolean>;
467
468
  dismissSession: () => void;
468
469
  dismissPermanent: () => void;
469
- showIOSOtherHelp: () => void;
470
470
  copyLink: () => Promise<void>;
471
471
  reset: () => void;
472
472
  }
package/dist/index.d.ts CHANGED
@@ -278,6 +278,7 @@ type SubscriptionStatus = 'active' | 'trialing' | 'expired' | 'canceled' | 'past
278
278
  declare function usePaywallState(): {
279
279
  status: SubscriptionStatus;
280
280
  daysLeftInTrial: number | null;
281
+ initialLoadComplete: boolean;
281
282
  checkout: (args: {
282
283
  cpf: string;
283
284
  cycle?: "MONTHLY" | "YEARLY";
@@ -466,7 +467,6 @@ interface InstallActions {
466
467
  promptInstall: () => Promise<boolean>;
467
468
  dismissSession: () => void;
468
469
  dismissPermanent: () => void;
469
- showIOSOtherHelp: () => void;
470
470
  copyLink: () => Promise<void>;
471
471
  reset: () => void;
472
472
  }
package/dist/index.js CHANGED
@@ -1,5 +1,5 @@
1
1
  // src/AppRoot.tsx
2
- import { useCallback as useCallback7, useEffect as useEffect7, useRef as useRef2, useState as useState12 } from "react";
2
+ import { useCallback as useCallback7, useEffect as useEffect7, useRef as useRef2, useState as useState11 } from "react";
3
3
  import { useHook as useHook8 } from "@hook-sdk/sdk";
4
4
 
5
5
  // src/internal/TemplateConfigContext.tsx
@@ -100,6 +100,7 @@ function usePaywallState() {
100
100
  const [error, setError] = useState2(null);
101
101
  const status = subscription.status();
102
102
  const daysLeftInTrial = subscription.daysLeftInTrial();
103
+ const initialLoadComplete = subscription.initialLoadComplete;
103
104
  const checkout = useCallback(
104
105
  async (args) => {
105
106
  setOpening(true);
@@ -125,7 +126,7 @@ function usePaywallState() {
125
126
  setError(err);
126
127
  }
127
128
  }, [subscription]);
128
- return { status, daysLeftInTrial, checkout, cancel, opening, error };
129
+ return { status, daysLeftInTrial, initialLoadComplete, checkout, cancel, opening, error };
129
130
  }
130
131
 
131
132
  // src/internal/SubscriptionGate.tsx
@@ -138,8 +139,9 @@ var BLOCKING = /* @__PURE__ */ new Set([
138
139
  ]);
139
140
  function SubscriptionGate({ Paywall, children }) {
140
141
  const { mode } = useTemplateConfig();
141
- const { status } = usePaywallState();
142
+ const { status, initialLoadComplete } = usePaywallState();
142
143
  if (mode === "free") return /* @__PURE__ */ jsx5(Fragment2, { children });
144
+ if (!initialLoadComplete && status === "none") return null;
143
145
  if (BLOCKING.has(status)) return /* @__PURE__ */ jsx5(Paywall, {});
144
146
  return /* @__PURE__ */ jsx5(Fragment2, { children });
145
147
  }
@@ -402,9 +404,6 @@ function useInstallPrompt(slug) {
402
404
  setIsDismissedPermanent(true);
403
405
  track("pwa_install_permanent_dismiss", { slug, platform, prior_skip_count: skipCount });
404
406
  }, [slug, platform, skipCount]);
405
- const showIOSOtherHelp = useCallback2(() => {
406
- track("pwa_install_ios_other_help_shown", { slug });
407
- }, [slug]);
408
407
  const copyLink = useCallback2(async () => {
409
408
  if (typeof navigator === "undefined" || typeof location === "undefined") return;
410
409
  try {
@@ -443,7 +442,6 @@ function useInstallPrompt(slug) {
443
442
  promptInstall,
444
443
  dismissSession,
445
444
  dismissPermanent,
446
- showIOSOtherHelp,
447
445
  copyLink,
448
446
  reset
449
447
  };
@@ -503,23 +501,22 @@ var INSTALL_COPY = {
503
501
  skipPermanent: "N\xE3o me pergunte mais"
504
502
  },
505
503
  iosOther: {
506
- title: "Abra no Safari pra instalar",
507
- subtitle: "No Chrome/Firefox/Edge do iPhone n\xE3o d\xE1 pra instalar PWA. Abra o link no Safari.",
508
- ctaPrimary: "Abrir no Safari",
509
- ctaSecondary: "Copiar link",
510
- copiedToast: "Link copiado. Cole no Safari.",
511
- skip: "Continuar mesmo assim",
512
- skipPermanent: "N\xE3o me pergunte mais",
513
- help: {
514
- step1: {
515
- title: "Toque em \u22EF ou no bot\xE3o compartilhar",
516
- subtitle: "Na barra inferior ou superior do navegador"
517
- },
518
- step2: {
519
- title: 'Escolha "Abrir no Safari"',
520
- subtitle: "O app vai abrir direto no Safari"
521
- }
522
- }
504
+ title: "Adicione \xE0 sua Tela de In\xEDcio",
505
+ subtitle: "Siga os 3 passos",
506
+ step1: {
507
+ title: "Toque em Compartilhar",
508
+ subtitle: "Geralmente no topo ou no menu do navegador"
509
+ },
510
+ step2: {
511
+ title: 'Role e toque em "Adicionar \xE0 Tela de In\xEDcio"',
512
+ iconLabel: "Adicionar \xE0 Tela de In\xEDcio"
513
+ },
514
+ step3: {
515
+ title: 'Toque em "Adicionar" pra confirmar',
516
+ buttonLabel: "Adicionar"
517
+ },
518
+ skip: "Continuar no navegador",
519
+ skipPermanent: "N\xE3o me pergunte mais"
523
520
  },
524
521
  inApp: {
525
522
  instagram: {
@@ -654,18 +651,6 @@ var primaryButtonStyle = {
654
651
  cursor: "pointer",
655
652
  marginBottom: 12
656
653
  };
657
- var secondaryButtonStyle = {
658
- width: "100%",
659
- padding: "12px 20px",
660
- background: "transparent",
661
- color: "var(--hook-color-primary)",
662
- border: "1px solid var(--hook-color-primary)",
663
- borderRadius: 999,
664
- fontSize: 15,
665
- fontWeight: 500,
666
- cursor: "pointer",
667
- marginBottom: 12
668
- };
669
654
  var skipLinkStyle = {
670
655
  display: "block",
671
656
  width: "100%",
@@ -1072,7 +1057,6 @@ function IOSafariVariant({
1072
1057
  }
1073
1058
 
1074
1059
  // src/components/InstallGate/variants/IOSOtherVariant.tsx
1075
- import { useState as useState4 } from "react";
1076
1060
  import { jsx as jsx13, jsxs as jsxs7 } from "react/jsx-runtime";
1077
1061
  function IOSOtherVariant({
1078
1062
  state,
@@ -1080,101 +1064,84 @@ function IOSOtherVariant({
1080
1064
  }) {
1081
1065
  const copy = INSTALL_COPY.iosOther;
1082
1066
  const showPermanent = shouldShowPermanentOption(state);
1083
- const [copied, setCopied] = useState4(false);
1084
- const [helpOpen, setHelpOpen] = useState4(false);
1085
- const handleCopy = async () => {
1086
- await actions.copyLink();
1087
- setCopied(true);
1088
- setTimeout(() => setCopied(false), 2e3);
1089
- };
1090
- const handleShowHelp = () => {
1091
- if (!helpOpen) actions.showIOSOtherHelp();
1092
- setHelpOpen(true);
1093
- };
1094
1067
  return /* @__PURE__ */ jsxs7(InstallSplash, { title: copy.title, subtitle: copy.subtitle, children: [
1095
1068
  /* @__PURE__ */ jsx13(
1096
- "button",
1069
+ Step2,
1097
1070
  {
1098
- "data-testid": "install-prompt-cta-ios-other-primary",
1099
- type: "button",
1100
- onClick: handleShowHelp,
1101
- "aria-expanded": helpOpen,
1102
- style: primaryButtonStyle,
1103
- children: copy.ctaPrimary
1071
+ n: 1,
1072
+ title: copy.step1.title,
1073
+ subtitle: copy.step1.subtitle,
1074
+ visual: /* @__PURE__ */ jsx13(
1075
+ "div",
1076
+ {
1077
+ style: {
1078
+ display: "flex",
1079
+ justifyContent: "center",
1080
+ alignItems: "center",
1081
+ background: "#f5f5f7",
1082
+ borderRadius: 12,
1083
+ padding: "12px 0",
1084
+ marginTop: 8
1085
+ },
1086
+ children: /* @__PURE__ */ jsx13(ShareIconIOS, { size: 32, style: { color: "var(--hook-color-primary)" } })
1087
+ }
1088
+ )
1104
1089
  }
1105
1090
  ),
1106
1091
  /* @__PURE__ */ jsx13(
1107
- "button",
1092
+ Step2,
1108
1093
  {
1109
- "data-testid": "install-prompt-cta-ios-other-secondary",
1110
- type: "button",
1111
- onClick: () => void handleCopy(),
1112
- style: secondaryButtonStyle,
1113
- children: copied ? copy.copiedToast : copy.ctaSecondary
1094
+ n: 2,
1095
+ title: copy.step2.title,
1096
+ visual: /* @__PURE__ */ jsxs7(
1097
+ "div",
1098
+ {
1099
+ style: {
1100
+ display: "flex",
1101
+ alignItems: "center",
1102
+ gap: 10,
1103
+ background: "#f5f5f7",
1104
+ borderRadius: 12,
1105
+ padding: "12px 14px",
1106
+ marginTop: 8
1107
+ },
1108
+ children: [
1109
+ /* @__PURE__ */ jsx13(SquarePlusIcon, { size: 22, style: { color: "#555" } }),
1110
+ /* @__PURE__ */ jsx13("span", { style: { fontSize: 14, color: "#333" }, children: copy.step2.iconLabel })
1111
+ ]
1112
+ }
1113
+ )
1114
1114
  }
1115
1115
  ),
1116
- helpOpen && /* @__PURE__ */ jsxs7(
1117
- "div",
1116
+ /* @__PURE__ */ jsx13(
1117
+ Step2,
1118
1118
  {
1119
- "data-testid": "install-prompt-ios-other-help",
1120
- style: { marginTop: 20, textAlign: "left" },
1121
- children: [
1122
- /* @__PURE__ */ jsx13(
1123
- Step2,
1124
- {
1125
- n: 1,
1126
- title: copy.help.step1.title,
1127
- subtitle: copy.help.step1.subtitle,
1128
- visual: /* @__PURE__ */ jsx13(
1129
- "div",
1130
- {
1131
- style: {
1132
- display: "flex",
1133
- justifyContent: "center",
1134
- alignItems: "center",
1135
- background: "#f5f5f7",
1136
- borderRadius: 12,
1137
- padding: "12px 0",
1138
- marginTop: 8
1139
- },
1140
- children: /* @__PURE__ */ jsx13(
1141
- MenuDotsHorizontalIcon,
1142
- {
1143
- size: 28,
1144
- style: { color: "var(--hook-color-primary)" }
1145
- }
1146
- )
1147
- }
1148
- )
1149
- }
1150
- ),
1151
- /* @__PURE__ */ jsx13(
1152
- Step2,
1153
- {
1154
- n: 2,
1155
- title: copy.help.step2.title,
1156
- subtitle: copy.help.step2.subtitle,
1157
- visual: /* @__PURE__ */ jsxs7(
1158
- "div",
1159
- {
1160
- style: {
1161
- display: "flex",
1162
- alignItems: "center",
1163
- gap: 10,
1164
- background: "#f5f5f7",
1165
- borderRadius: 12,
1166
- padding: "12px 14px",
1167
- marginTop: 8
1168
- },
1169
- children: [
1170
- /* @__PURE__ */ jsx13(ExternalLinkIcon, { size: 22, style: { color: "#555" } }),
1171
- /* @__PURE__ */ jsx13("span", { style: { fontSize: 14, color: "#333" }, children: "Abrir no Safari" })
1172
- ]
1173
- }
1174
- )
1175
- }
1176
- )
1177
- ]
1119
+ n: 3,
1120
+ title: copy.step3.title,
1121
+ visual: /* @__PURE__ */ jsx13(
1122
+ "div",
1123
+ {
1124
+ style: {
1125
+ display: "flex",
1126
+ justifyContent: "flex-end",
1127
+ background: "#f5f5f7",
1128
+ borderRadius: 12,
1129
+ padding: "10px 14px",
1130
+ marginTop: 8
1131
+ },
1132
+ children: /* @__PURE__ */ jsx13(
1133
+ "span",
1134
+ {
1135
+ style: {
1136
+ color: "var(--hook-color-primary)",
1137
+ fontSize: 15,
1138
+ fontWeight: 600
1139
+ },
1140
+ children: copy.step3.buttonLabel
1141
+ }
1142
+ )
1143
+ }
1144
+ )
1178
1145
  }
1179
1146
  ),
1180
1147
  /* @__PURE__ */ jsx13(
@@ -1183,7 +1150,7 @@ function IOSOtherVariant({
1183
1150
  "data-testid": "install-prompt-skip-session",
1184
1151
  type: "button",
1185
1152
  onClick: actions.dismissSession,
1186
- style: skipLinkStyle,
1153
+ style: { ...skipLinkStyle, marginTop: 16 },
1187
1154
  children: copy.skip
1188
1155
  }
1189
1156
  ),
@@ -1201,7 +1168,7 @@ function IOSOtherVariant({
1201
1168
  }
1202
1169
 
1203
1170
  // src/components/InstallGate/variants/InAppBrowserVariant.tsx
1204
- import { useState as useState5 } from "react";
1171
+ import { useState as useState4 } from "react";
1205
1172
  import { jsx as jsx14, jsxs as jsxs8 } from "react/jsx-runtime";
1206
1173
  function InAppBrowserVariant({
1207
1174
  state,
@@ -1211,7 +1178,7 @@ function InAppBrowserVariant({
1211
1178
  const appCopy = INSTALL_COPY.inApp[app] ?? INSTALL_COPY.inApp.other;
1212
1179
  const copy = INSTALL_COPY.inApp;
1213
1180
  const showPermanent = shouldShowPermanentOption(state);
1214
- const [copied, setCopied] = useState5(false);
1181
+ const [copied, setCopied] = useState4(false);
1215
1182
  const handleCopy = async () => {
1216
1183
  await actions.copyLink();
1217
1184
  setCopied(true);
@@ -1480,7 +1447,7 @@ var ErrorBoundary = class extends Component {
1480
1447
  };
1481
1448
 
1482
1449
  // src/hooks/useLoginForm.ts
1483
- import { useCallback as useCallback3, useMemo as useMemo2, useState as useState6 } from "react";
1450
+ import { useCallback as useCallback3, useMemo as useMemo2, useState as useState5 } from "react";
1484
1451
  import { useHook as useHook4 } from "@hook-sdk/sdk";
1485
1452
 
1486
1453
  // src/errors.ts
@@ -1517,10 +1484,10 @@ var EMAIL_RE = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
1517
1484
  var MIN_PASSWORD = 8;
1518
1485
  function useLoginForm() {
1519
1486
  const { auth } = useHook4();
1520
- const [email, setEmail] = useState6("");
1521
- const [password, setPassword] = useState6("");
1522
- const [submitting, setSubmitting] = useState6(false);
1523
- const [error, setError] = useState6(null);
1487
+ const [email, setEmail] = useState5("");
1488
+ const [password, setPassword] = useState5("");
1489
+ const [submitting, setSubmitting] = useState5(false);
1490
+ const [error, setError] = useState5(null);
1524
1491
  const emailError = useMemo2(() => {
1525
1492
  if (email.length === 0) return null;
1526
1493
  if (!EMAIL_RE.test(email)) return "Formato de e-mail inv\xE1lido.";
@@ -1631,7 +1598,7 @@ function GoogleGlyph() {
1631
1598
  }
1632
1599
 
1633
1600
  // src/internal/OAuthErrorBanner.tsx
1634
- import { useEffect as useEffect5, useState as useState7 } from "react";
1601
+ import { useEffect as useEffect5, useState as useState6 } from "react";
1635
1602
  import { jsx as jsx19, jsxs as jsxs13 } from "react/jsx-runtime";
1636
1603
  var ERROR_MESSAGES = {
1637
1604
  invalid_state: "Sess\xE3o expirou, tente de novo.",
@@ -1652,7 +1619,7 @@ function stripErrorFromUrl() {
1652
1619
  window.history.replaceState({}, "", url.toString());
1653
1620
  }
1654
1621
  function OAuthErrorBanner() {
1655
- const [code, setCode] = useState7(() => readErrorCode());
1622
+ const [code, setCode] = useState6(() => readErrorCode());
1656
1623
  useEffect5(() => {
1657
1624
  if (code !== null) stripErrorFromUrl();
1658
1625
  }, [code]);
@@ -1786,17 +1753,17 @@ function DefaultLoginScreen({ onNavigate }) {
1786
1753
  }
1787
1754
 
1788
1755
  // src/hooks/useSignupForm.ts
1789
- import { useCallback as useCallback4, useMemo as useMemo3, useState as useState8 } from "react";
1756
+ import { useCallback as useCallback4, useMemo as useMemo3, useState as useState7 } from "react";
1790
1757
  import { useHook as useHook5 } from "@hook-sdk/sdk";
1791
1758
  var EMAIL_RE2 = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
1792
1759
  var MIN_PASSWORD2 = 8;
1793
1760
  function useSignupForm() {
1794
1761
  const { auth } = useHook5();
1795
- const [name, setName] = useState8("");
1796
- const [email, setEmail] = useState8("");
1797
- const [password, setPassword] = useState8("");
1798
- const [submitting, setSubmitting] = useState8(false);
1799
- const [error, setError] = useState8(null);
1762
+ const [name, setName] = useState7("");
1763
+ const [email, setEmail] = useState7("");
1764
+ const [password, setPassword] = useState7("");
1765
+ const [submitting, setSubmitting] = useState7(false);
1766
+ const [error, setError] = useState7(null);
1800
1767
  const nameError = useMemo3(() => {
1801
1768
  if (name.length === 0) return null;
1802
1769
  if (name.trim().length < 2) return "Nome muito curto.";
@@ -1901,15 +1868,15 @@ function DefaultSignupScreen({ onNavigate }) {
1901
1868
  }
1902
1869
 
1903
1870
  // src/hooks/useForgotForm.ts
1904
- import { useCallback as useCallback5, useMemo as useMemo4, useState as useState9 } from "react";
1871
+ import { useCallback as useCallback5, useMemo as useMemo4, useState as useState8 } from "react";
1905
1872
  import { useHook as useHook6 } from "@hook-sdk/sdk";
1906
1873
  var EMAIL_RE3 = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
1907
1874
  function useForgotForm() {
1908
1875
  const { auth } = useHook6();
1909
- const [email, setEmail] = useState9("");
1910
- const [submitting, setSubmitting] = useState9(false);
1911
- const [sent, setSent] = useState9(false);
1912
- const [error, setError] = useState9(null);
1876
+ const [email, setEmail] = useState8("");
1877
+ const [submitting, setSubmitting] = useState8(false);
1878
+ const [sent, setSent] = useState8(false);
1879
+ const [error, setError] = useState8(null);
1913
1880
  const emailError = useMemo4(() => {
1914
1881
  if (email.length === 0) return null;
1915
1882
  if (!EMAIL_RE3.test(email)) return "Formato de e-mail inv\xE1lido.";
@@ -1975,17 +1942,17 @@ function DefaultForgotScreen({ onNavigate }) {
1975
1942
  }
1976
1943
 
1977
1944
  // src/hooks/useResetForm.ts
1978
- import { useCallback as useCallback6, useEffect as useEffect6, useMemo as useMemo5, useState as useState10 } from "react";
1945
+ import { useCallback as useCallback6, useEffect as useEffect6, useMemo as useMemo5, useState as useState9 } from "react";
1979
1946
  import { useHook as useHook7 } from "@hook-sdk/sdk";
1980
1947
  var MIN_PASSWORD3 = 12;
1981
1948
  function useResetForm() {
1982
1949
  const { auth } = useHook7();
1983
- const [token, setToken] = useState10(null);
1984
- const [password, setPassword] = useState10("");
1985
- const [confirm, setConfirm] = useState10("");
1986
- const [submitting, setSubmitting] = useState10(false);
1987
- const [done, setDone] = useState10(false);
1988
- const [error, setError] = useState10(null);
1950
+ const [token, setToken] = useState9(null);
1951
+ const [password, setPassword] = useState9("");
1952
+ const [confirm, setConfirm] = useState9("");
1953
+ const [submitting, setSubmitting] = useState9(false);
1954
+ const [done, setDone] = useState9(false);
1955
+ const [error, setError] = useState9(null);
1989
1956
  useEffect6(() => {
1990
1957
  if (typeof window === "undefined") return;
1991
1958
  const params = new URLSearchParams(window.location.search);
@@ -2081,13 +2048,13 @@ function DefaultResetScreen({ onNavigate }) {
2081
2048
  }
2082
2049
 
2083
2050
  // src/defaults/DefaultPaywall.tsx
2084
- import { useState as useState11 } from "react";
2051
+ import { useState as useState10 } from "react";
2085
2052
  import { jsx as jsx24, jsxs as jsxs18 } from "react/jsx-runtime";
2086
2053
  function DefaultPaywall() {
2087
2054
  const config = useTemplateConfig();
2088
2055
  const { checkout, opening, error } = usePaywallState();
2089
2056
  const p = config.subscription.paywall_config;
2090
- const [cpf, setCpf] = useState11("");
2057
+ const [cpf, setCpf] = useState10("");
2091
2058
  const cpfDigits = cpf.replace(/\D/g, "");
2092
2059
  const canCheckout = cpfDigits.length === 11 && !opening;
2093
2060
  return /* @__PURE__ */ jsxs18("main", { style: { padding: 24, maxWidth: 440, margin: "0 auto", textAlign: "center" }, children: [
@@ -2147,7 +2114,7 @@ function PaymentReturnHandler({ children }) {
2147
2114
  const subRef = useRef2(subscription);
2148
2115
  subRef.current = subscription;
2149
2116
  const runIdRef = useRef2(0);
2150
- const [state, setState] = useState12("idle");
2117
+ const [state, setState] = useState11("idle");
2151
2118
  const runPoll = useCallback7(() => {
2152
2119
  const runId = ++runIdRef.current;
2153
2120
  setState("confirming");
@@ -2251,7 +2218,7 @@ function AppRoot({
2251
2218
  }
2252
2219
 
2253
2220
  // src/hooks/usePush.ts
2254
- import { useCallback as useCallback8, useEffect as useEffect8, useState as useState13 } from "react";
2221
+ import { useCallback as useCallback8, useEffect as useEffect8, useState as useState12 } from "react";
2255
2222
  import { useHook as useHook9 } from "@hook-sdk/sdk";
2256
2223
  function detectIosNeedsInstall() {
2257
2224
  if (typeof navigator === "undefined" || typeof window === "undefined") return false;
@@ -2279,7 +2246,7 @@ function deriveState(push) {
2279
2246
  }
2280
2247
  function usePush() {
2281
2248
  const { push } = useHook9();
2282
- const [state, setState] = useState13(() => deriveState(push));
2249
+ const [state, setState] = useState12(() => deriveState(push));
2283
2250
  useEffect8(() => {
2284
2251
  setState(deriveState(push));
2285
2252
  }, [push]);
@@ -2397,13 +2364,13 @@ function useSubscription() {
2397
2364
  }
2398
2365
 
2399
2366
  // src/hooks/useReminders.ts
2400
- import { useCallback as useCallback9, useEffect as useEffect10, useState as useState14 } from "react";
2367
+ import { useCallback as useCallback9, useEffect as useEffect10, useState as useState13 } from "react";
2401
2368
  import { useHook as useHook12 } from "@hook-sdk/sdk";
2402
2369
  function useReminders() {
2403
2370
  const { push } = useHook12();
2404
2371
  const r = push.reminders;
2405
- const [reminders, setReminders] = useState14([]);
2406
- const [loading, setLoading] = useState14(true);
2372
+ const [reminders, setReminders] = useState13([]);
2373
+ const [loading, setLoading] = useState13(true);
2407
2374
  const reload = useCallback9(async () => {
2408
2375
  setLoading(true);
2409
2376
  try {
@@ -2434,9 +2401,9 @@ function useReminders() {
2434
2401
  }
2435
2402
 
2436
2403
  // src/hooks/useToast.ts
2437
- import { useCallback as useCallback10, useState as useState15 } from "react";
2404
+ import { useCallback as useCallback10, useState as useState14 } from "react";
2438
2405
  function useToast() {
2439
- const [items, setItems] = useState15([]);
2406
+ const [items, setItems] = useState14([]);
2440
2407
  const show = useCallback10((message, kind = "info") => {
2441
2408
  const id = `${Date.now()}-${Math.random().toString(36).slice(2, 8)}`;
2442
2409
  setItems((prev) => [...prev, { id, message, kind }]);