@selectwin/kit 0.1.99 → 0.1.101

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,5 +1,5 @@
1
1
  import { ReactNode } from 'react';
2
- export declare function SelectModal({ open, onClose, title, subtitle, children, footer, aside, size, showClose, noise, dividedHeader, theme, }: {
2
+ export declare function SelectModal({ open, onClose, title, subtitle, children, footer, aside, size, showClose, noise, dividedHeader, backdrop, theme, }: {
3
3
  open: boolean;
4
4
  onClose: () => void;
5
5
  title?: ReactNode;
@@ -13,5 +13,8 @@ export declare function SelectModal({ open, onClose, title, subtitle, children,
13
13
  noise?: boolean;
14
14
  /** Add a hairline under the header (Clerk form modals, e.g. New permission). */
15
15
  dividedHeader?: boolean;
16
+ /** `blur` desfoca a página atrás do scrim — para gates que prometem esconder o que há por
17
+ * trás (queda do servidor): escurecer só não esconde, o conteúdo segue legível. */
18
+ backdrop?: 'dim' | 'blur';
16
19
  theme?: 'light' | 'dark';
17
20
  }): import('react').ReactPortal | null;
@@ -0,0 +1,26 @@
1
+ import { ReactNode } from 'react';
2
+ export type SelectRetryPhase = 'waiting' | 'trying' | 'done';
3
+ export type SelectRetryStatusProps = {
4
+ phase: SelectRetryPhase;
5
+ /** Epoch ms of the next attempt (phase `waiting`). */
6
+ nextAttemptAt?: number | null;
7
+ /** Length of the current wait in ms — where the bar started from. */
8
+ waitMs?: number;
9
+ /** Attempts already made — the quiet caption under the bar. The caption line is ALWAYS there
10
+ * (its text changes per phase) so the box keeps its height and a centered modal doesn't hop. */
11
+ attempt?: number;
12
+ /** In-flight indicator (phase `trying`); defaults to the kit ring. */
13
+ mark?: ReactNode;
14
+ /** Right-aligned control on the status line (hidden while `trying`/`done`). */
15
+ action?: ReactNode;
16
+ waitingLabel?: (seconds: number) => ReactNode;
17
+ tryingLabel?: ReactNode;
18
+ doneLabel?: ReactNode;
19
+ attemptLabel?: (attempt: number) => ReactNode;
20
+ /** Caption before any attempt was made. */
21
+ firstLabel?: ReactNode;
22
+ /** Caption once it worked. */
23
+ doneCaption?: ReactNode;
24
+ className?: string;
25
+ };
26
+ export declare function SelectRetryStatus({ phase, nextAttemptAt, waitMs, attempt, mark, action, waitingLabel, tryingLabel, doneLabel, attemptLabel, firstLabel, doneCaption, className, }: SelectRetryStatusProps): import("react").JSX.Element;
package/dist/index.d.ts CHANGED
@@ -40,6 +40,7 @@ export { SelectIdentityFooter } from './SelectIdentityFooter';
40
40
  export { SelectOtpInput } from './SelectOtpInput';
41
41
  export { SelectBackLink } from './SelectBackLink';
42
42
  export { SelectResendButton } from './SelectResendButton';
43
+ export { SelectRetryStatus, type SelectRetryStatusProps, type SelectRetryPhase } from './SelectRetryStatus';
43
44
  export { SelectPasswordStrength, passwordScore, type SelectPasswordRule } from './SelectPasswordStrength';
44
45
  export { SelectLoader, type SelectLoaderProps } from './SelectLoader';
45
46
  export { SelectText } from './SelectText';