@hook-sdk/template 0.12.0 → 0.14.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
@@ -200,9 +200,15 @@ interface UseLoginFormResult {
200
200
  email: string;
201
201
  setEmail: (v: string) => void;
202
202
  emailError: string | null;
203
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
204
+ markEmailTouched: () => void;
203
205
  password: string;
204
206
  setPassword: (v: string) => void;
205
207
  passwordError: string | null;
208
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
209
+ markPasswordTouched: () => void;
210
+ /** True after the user has attempted submit at least once. */
211
+ formSubmitAttempted: boolean;
206
212
  /**
207
213
  * Submete o form. Retorna true se o login deu OK (cookies setados), false
208
214
  * se validação falhou, credenciais inválidas, rate-limit ou erro de rede.
@@ -225,12 +231,20 @@ interface UseSignupFormResult {
225
231
  name: string;
226
232
  setName: (v: string) => void;
227
233
  nameError: string | null;
234
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
235
+ markNameTouched: () => void;
228
236
  email: string;
229
237
  setEmail: (v: string) => void;
230
238
  emailError: string | null;
239
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
240
+ markEmailTouched: () => void;
231
241
  password: string;
232
242
  setPassword: (v: string) => void;
233
243
  passwordError: string | null;
244
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
245
+ markPasswordTouched: () => void;
246
+ /** True after the user has attempted submit at least once. */
247
+ formSubmitAttempted: boolean;
234
248
  /**
235
249
  * Submete o form. Retorna true se o signup deu OK (backend respondeu 2xx),
236
250
  * false se validação falhou, houve erro de rede/servidor, ou email já em uso.
@@ -254,6 +268,10 @@ interface UseForgotFormResult {
254
268
  email: string;
255
269
  setEmail: (v: string) => void;
256
270
  emailError: string | null;
271
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
272
+ markEmailTouched: () => void;
273
+ /** True after the user has attempted submit at least once. */
274
+ formSubmitAttempted: boolean;
257
275
  /**
258
276
  * Submete o form. Retorna true se o backend aceitou a requisição (email
259
277
  * de reset foi enfileirado — sem leak de "existe esse email" por design),
@@ -274,9 +292,15 @@ interface UseResetFormResult {
274
292
  password: string;
275
293
  setPassword: (v: string) => void;
276
294
  passwordError: string | null;
295
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
296
+ markPasswordTouched: () => void;
277
297
  confirm: string;
278
298
  setConfirm: (v: string) => void;
279
299
  confirmError: string | null;
300
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
301
+ markConfirmTouched: () => void;
302
+ /** True after the user has attempted submit at least once. */
303
+ formSubmitAttempted: boolean;
280
304
  submit: () => Promise<void>;
281
305
  submitting: boolean;
282
306
  canSubmit: boolean;
package/dist/index.d.ts CHANGED
@@ -200,9 +200,15 @@ interface UseLoginFormResult {
200
200
  email: string;
201
201
  setEmail: (v: string) => void;
202
202
  emailError: string | null;
203
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
204
+ markEmailTouched: () => void;
203
205
  password: string;
204
206
  setPassword: (v: string) => void;
205
207
  passwordError: string | null;
208
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
209
+ markPasswordTouched: () => void;
210
+ /** True after the user has attempted submit at least once. */
211
+ formSubmitAttempted: boolean;
206
212
  /**
207
213
  * Submete o form. Retorna true se o login deu OK (cookies setados), false
208
214
  * se validação falhou, credenciais inválidas, rate-limit ou erro de rede.
@@ -225,12 +231,20 @@ interface UseSignupFormResult {
225
231
  name: string;
226
232
  setName: (v: string) => void;
227
233
  nameError: string | null;
234
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
235
+ markNameTouched: () => void;
228
236
  email: string;
229
237
  setEmail: (v: string) => void;
230
238
  emailError: string | null;
239
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
240
+ markEmailTouched: () => void;
231
241
  password: string;
232
242
  setPassword: (v: string) => void;
233
243
  passwordError: string | null;
244
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
245
+ markPasswordTouched: () => void;
246
+ /** True after the user has attempted submit at least once. */
247
+ formSubmitAttempted: boolean;
234
248
  /**
235
249
  * Submete o form. Retorna true se o signup deu OK (backend respondeu 2xx),
236
250
  * false se validação falhou, houve erro de rede/servidor, ou email já em uso.
@@ -254,6 +268,10 @@ interface UseForgotFormResult {
254
268
  email: string;
255
269
  setEmail: (v: string) => void;
256
270
  emailError: string | null;
271
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
272
+ markEmailTouched: () => void;
273
+ /** True after the user has attempted submit at least once. */
274
+ formSubmitAttempted: boolean;
257
275
  /**
258
276
  * Submete o form. Retorna true se o backend aceitou a requisição (email
259
277
  * de reset foi enfileirado — sem leak de "existe esse email" por design),
@@ -274,9 +292,15 @@ interface UseResetFormResult {
274
292
  password: string;
275
293
  setPassword: (v: string) => void;
276
294
  passwordError: string | null;
295
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
296
+ markPasswordTouched: () => void;
277
297
  confirm: string;
278
298
  setConfirm: (v: string) => void;
279
299
  confirmError: string | null;
300
+ /** Wave 5 #42: call on input blur so the error becomes visible. */
301
+ markConfirmTouched: () => void;
302
+ /** True after the user has attempted submit at least once. */
303
+ formSubmitAttempted: boolean;
280
304
  submit: () => Promise<void>;
281
305
  submitting: boolean;
282
306
  canSubmit: boolean;