@scalemule/nextjs 0.1.24 → 0.1.27

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/client.d.mts CHANGED
@@ -1,4 +1,4 @@
1
- import { a8 as StorageAdapter, A as ApiError } from './index-DTWyUcyd.mjs';
1
+ import { a8 as StorageAdapter, A as ApiError } from './index-zQloSkpW.mjs';
2
2
 
3
3
  /**
4
4
  * ScaleMule API Client
@@ -137,6 +137,19 @@ declare class ScaleMuleClient {
137
137
  * Set session after login
138
138
  */
139
139
  setSession(token: string, userId: string): Promise<void>;
140
+ /**
141
+ * Token-only setter for member-auth surfaces.
142
+ *
143
+ * Unlike `setSession(token, userId)`, this does NOT persist a userId or
144
+ * write to local storage — useful when the host platform owns identity
145
+ * (e.g. ScaleMule's member dashboards use `MemberAuthProvider` and the
146
+ * token comes from a `${env}_member_access_token` cookie). The token is
147
+ * applied in-memory and used as a `Bearer` Authorization header on
148
+ * subsequent requests.
149
+ *
150
+ * Pass `null` to clear without touching userId/storage.
151
+ */
152
+ setSessionToken(token: string | null): void;
140
153
  /**
141
154
  * Clear session on logout
142
155
  */
package/dist/client.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { a8 as StorageAdapter, A as ApiError } from './index-DTWyUcyd.js';
1
+ import { a8 as StorageAdapter, A as ApiError } from './index-zQloSkpW.js';
2
2
 
3
3
  /**
4
4
  * ScaleMule API Client
@@ -137,6 +137,19 @@ declare class ScaleMuleClient {
137
137
  * Set session after login
138
138
  */
139
139
  setSession(token: string, userId: string): Promise<void>;
140
+ /**
141
+ * Token-only setter for member-auth surfaces.
142
+ *
143
+ * Unlike `setSession(token, userId)`, this does NOT persist a userId or
144
+ * write to local storage — useful when the host platform owns identity
145
+ * (e.g. ScaleMule's member dashboards use `MemberAuthProvider` and the
146
+ * token comes from a `${env}_member_access_token` cookie). The token is
147
+ * applied in-memory and used as a `Bearer` Authorization header on
148
+ * subsequent requests.
149
+ *
150
+ * Pass `null` to clear without touching userId/storage.
151
+ */
152
+ setSessionToken(token: string | null): void;
140
153
  /**
141
154
  * Clear session on logout
142
155
  */
package/dist/client.js CHANGED
@@ -433,6 +433,24 @@ var ScaleMuleClient = class {
433
433
  console.log("[ScaleMule] Session set for user:", userId);
434
434
  }
435
435
  }
436
+ /**
437
+ * Token-only setter for member-auth surfaces.
438
+ *
439
+ * Unlike `setSession(token, userId)`, this does NOT persist a userId or
440
+ * write to local storage — useful when the host platform owns identity
441
+ * (e.g. ScaleMule's member dashboards use `MemberAuthProvider` and the
442
+ * token comes from a `${env}_member_access_token` cookie). The token is
443
+ * applied in-memory and used as a `Bearer` Authorization header on
444
+ * subsequent requests.
445
+ *
446
+ * Pass `null` to clear without touching userId/storage.
447
+ */
448
+ setSessionToken(token) {
449
+ this.sessionToken = token;
450
+ if (this.debug) {
451
+ console.log("[ScaleMule] Session token", token ? "set (token-only)" : "cleared (token-only)");
452
+ }
453
+ }
436
454
  /**
437
455
  * Clear session on logout
438
456
  */
@@ -497,6 +515,8 @@ var ScaleMuleClient = class {
497
515
  console.log(`[ScaleMule] ${options.method || "GET"} ${path}`);
498
516
  }
499
517
  let lastError = null;
518
+ const MAX_REFRESH_ATTEMPTS = 1;
519
+ let refreshAttempts = 0;
500
520
  for (let attempt = 0; attempt <= maxRetries; attempt++) {
501
521
  const controller = new AbortController();
502
522
  const timeoutId = setTimeout(() => controller.abort(), timeout);
@@ -520,7 +540,8 @@ var ScaleMuleClient = class {
520
540
  if (!response.ok) {
521
541
  const rawError = responseData?.error;
522
542
  const error = rawError && typeof rawError === "object" ? rawError : { code: `HTTP_${response.status}`, message: typeof rawError === "string" ? rawError : responseData?.message || text || response.statusText };
523
- if (response.status === 401 && this.sessionToken && !options.isAutoRefresh) {
543
+ if (response.status === 401 && this.sessionToken && !options.isAutoRefresh && refreshAttempts < MAX_REFRESH_ATTEMPTS) {
544
+ refreshAttempts++;
524
545
  if (this.debug) console.log("[ScaleMule] 401 received, attempting auto-refresh...");
525
546
  if (!this.refreshPromise) {
526
547
  this.onRefreshStart?.();
package/dist/client.mjs CHANGED
@@ -431,6 +431,24 @@ var ScaleMuleClient = class {
431
431
  console.log("[ScaleMule] Session set for user:", userId);
432
432
  }
433
433
  }
434
+ /**
435
+ * Token-only setter for member-auth surfaces.
436
+ *
437
+ * Unlike `setSession(token, userId)`, this does NOT persist a userId or
438
+ * write to local storage — useful when the host platform owns identity
439
+ * (e.g. ScaleMule's member dashboards use `MemberAuthProvider` and the
440
+ * token comes from a `${env}_member_access_token` cookie). The token is
441
+ * applied in-memory and used as a `Bearer` Authorization header on
442
+ * subsequent requests.
443
+ *
444
+ * Pass `null` to clear without touching userId/storage.
445
+ */
446
+ setSessionToken(token) {
447
+ this.sessionToken = token;
448
+ if (this.debug) {
449
+ console.log("[ScaleMule] Session token", token ? "set (token-only)" : "cleared (token-only)");
450
+ }
451
+ }
434
452
  /**
435
453
  * Clear session on logout
436
454
  */
@@ -495,6 +513,8 @@ var ScaleMuleClient = class {
495
513
  console.log(`[ScaleMule] ${options.method || "GET"} ${path}`);
496
514
  }
497
515
  let lastError = null;
516
+ const MAX_REFRESH_ATTEMPTS = 1;
517
+ let refreshAttempts = 0;
498
518
  for (let attempt = 0; attempt <= maxRetries; attempt++) {
499
519
  const controller = new AbortController();
500
520
  const timeoutId = setTimeout(() => controller.abort(), timeout);
@@ -518,7 +538,8 @@ var ScaleMuleClient = class {
518
538
  if (!response.ok) {
519
539
  const rawError = responseData?.error;
520
540
  const error = rawError && typeof rawError === "object" ? rawError : { code: `HTTP_${response.status}`, message: typeof rawError === "string" ? rawError : responseData?.message || text || response.statusText };
521
- if (response.status === 401 && this.sessionToken && !options.isAutoRefresh) {
541
+ if (response.status === 401 && this.sessionToken && !options.isAutoRefresh && refreshAttempts < MAX_REFRESH_ATTEMPTS) {
542
+ refreshAttempts++;
522
543
  if (this.debug) console.log("[ScaleMule] 401 received, attempting auto-refresh...");
523
544
  if (!this.refreshPromise) {
524
545
  this.onRefreshStart?.();
@@ -248,7 +248,11 @@ interface OAuthCallbackResponse {
248
248
  }
249
249
  interface LinkedAccount {
250
250
  provider: string;
251
- provider_user_id: string;
251
+ /**
252
+ * Not returned by GET /v1/auth/oauth/providers today. Reserved for a
253
+ * future endpoint that exposes the external user id; treat as optional.
254
+ */
255
+ provider_user_id?: string;
252
256
  provider_email?: string;
253
257
  linked_at: string;
254
258
  }
@@ -248,7 +248,11 @@ interface OAuthCallbackResponse {
248
248
  }
249
249
  interface LinkedAccount {
250
250
  provider: string;
251
- provider_user_id: string;
251
+ /**
252
+ * Not returned by GET /v1/auth/oauth/providers today. Reserved for a
253
+ * future endpoint that exposes the external user id; treat as optional.
254
+ */
255
+ provider_user_id?: string;
252
256
  provider_email?: string;
253
257
  linked_at: string;
254
258
  }
package/dist/index.d.mts CHANGED
@@ -1,14 +1,27 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import { ApiError, RealtimeService, StorageService, PhotoService, VideoService, AudioService, TtsService, TtsJobStatus, FileStatus, TtsAudioInfo } from '@scalemule/sdk';
2
+ import { ApiError, RealtimeService, StorageService, PhotoService, VideoService, AudioService, TtsService, TtsJobStatus, FileStatus } from '@scalemule/sdk';
3
3
  import * as React from 'react';
4
4
  import { ReactNode, ReactElement } from 'react';
5
5
  import { MoneyClient } from '@scalemule/money';
6
6
  export { MoneyClient, MoneyClientConfig, createMoneyClient } from '@scalemule/money';
7
7
  import { ScaleMuleClient } from './client.mjs';
8
8
  export { ClientConfig, RequestOptions, createClient } from './client.mjs';
9
- import { S as ScaleMuleConfig, U as User, L as LoginResponse, A as ApiError$1, a as UseAuthReturn, b as UseBillingReturn, c as ListFilesParams, d as UseContentReturn, e as UseUserReturn, f as UseAnalyticsOptions, g as UseAnalyticsReturn } from './index-DTWyUcyd.mjs';
10
- export { h as AccountBalance, i as AnalyticsEvent, j as ApiResponse, B as BatchTrackRequest, k as BillingPayment, l as BillingPayout, m as BillingRefund, n as BillingTransaction, C as ChangeEmailRequest, o as ChangePasswordRequest, p as ClientContext, q as ConnectedAccount, D as DeviceFingerprint, r as DeviceInfo, E as EnhancedAnalyticsEvent, F as ForgotPasswordRequest, K as KnownAccountInfo, s as LinkedAccount, t as ListFilesResponse, u as LoginDeviceInfo, v as LoginRequest, w as LoginResponseWithMFA, x as LoginRiskInfo, M as MFAChallengeResponse, y as MFAMethod, z as MFASMSSetupResponse, G as MFASetupRequest, H as MFAStatus, I as MFATOTPSetupResponse, J as MFAVerifyRequest, O as OAuthCallbackRequest, N as OAuthCallbackResponse, P as OAuthConfig, Q as OAuthProvider, R as OAuthStartResponse, T as PageViewData, V as PayoutSchedule, W as PhoneLoginRequest, X as PhoneSendCodeRequest, Y as PhoneVerifyRequest, Z as Profile, _ as RefreshResponse, $ as RegisterRequest, a0 as ResetPasswordRequest, a1 as ScaleMuleApiError, a2 as ScaleMuleEnvironment, a3 as Session, a4 as SignedUploadCompleteRequest, a5 as SignedUploadRequest, a6 as SignedUploadResponse, a7 as SignedUploadUrl, a8 as StorageAdapter, a9 as StorageFile, aa as TrackEventResponse, ab as TransactionSummary, ac as UTMParams, ad as UpdateProfileRequest, ae as UploadOptions, af as UploadResponse, ag as VerifyEmailRequest } from './index-DTWyUcyd.mjs';
9
+ import { S as ScaleMuleConfig, U as User, L as LoginResponse, A as ApiError$1, a as UseAuthReturn, b as UseBillingReturn, c as ListFilesParams, d as UseContentReturn, e as UseUserReturn, f as UseAnalyticsOptions, g as UseAnalyticsReturn } from './index-zQloSkpW.mjs';
10
+ export { h as AccountBalance, i as AnalyticsEvent, j as ApiResponse, B as BatchTrackRequest, k as BillingPayment, l as BillingPayout, m as BillingRefund, n as BillingTransaction, C as ChangeEmailRequest, o as ChangePasswordRequest, p as ClientContext, q as ConnectedAccount, D as DeviceFingerprint, r as DeviceInfo, E as EnhancedAnalyticsEvent, F as ForgotPasswordRequest, K as KnownAccountInfo, s as LinkedAccount, t as ListFilesResponse, u as LoginDeviceInfo, v as LoginRequest, w as LoginResponseWithMFA, x as LoginRiskInfo, M as MFAChallengeResponse, y as MFAMethod, z as MFASMSSetupResponse, G as MFASetupRequest, H as MFAStatus, I as MFATOTPSetupResponse, J as MFAVerifyRequest, O as OAuthCallbackRequest, N as OAuthCallbackResponse, P as OAuthConfig, Q as OAuthProvider, R as OAuthStartResponse, T as PageViewData, V as PayoutSchedule, W as PhoneLoginRequest, X as PhoneSendCodeRequest, Y as PhoneVerifyRequest, Z as Profile, _ as RefreshResponse, $ as RegisterRequest, a0 as ResetPasswordRequest, a1 as ScaleMuleApiError, a2 as ScaleMuleEnvironment, a3 as Session, a4 as SignedUploadCompleteRequest, a5 as SignedUploadRequest, a6 as SignedUploadResponse, a7 as SignedUploadUrl, a8 as StorageAdapter, a9 as StorageFile, aa as TrackEventResponse, ab as TransactionSummary, ac as UTMParams, ad as UpdateProfileRequest, ae as UploadOptions, af as UploadResponse, ag as VerifyEmailRequest } from './index-zQloSkpW.mjs';
11
11
 
12
+ /**
13
+ * Tri-state file visibility — `'private' | 'app_public' | 'anonymous_visible'`.
14
+ *
15
+ * Locally redeclared here rather than imported from `@scalemule/sdk`
16
+ * so this package can ship before the sdk's `Visibility` export is
17
+ * published. Once `@scalemule/sdk` ≥ the version that exports
18
+ * `Visibility` is the minimum dep version, swap this for an `import
19
+ * type { Visibility } from '@scalemule/sdk'`.
20
+ *
21
+ * Keep the union members in lockstep with the storage migration's
22
+ * ENUM and the SDK's typed export.
23
+ */
24
+ type Visibility = 'private' | 'app_public' | 'anonymous_visible';
12
25
  /**
13
26
  * Result of a single {@link useMedia} upload call.
14
27
  *
@@ -33,8 +46,24 @@ interface MediaUploadResult {
33
46
  hls_url_promise: Promise<string | null>;
34
47
  /** The file's MIME type — preserved from the input File / Blob. */
35
48
  mime_type: string;
36
- /** Whether the resulting storage object is public-readable. */
49
+ /** Whether the resulting storage object is public-readable.
50
+ * Derived from `visibility !== 'private'` for back-compat with
51
+ * callers that still branch on the boolean. */
37
52
  is_public: boolean;
53
+ /**
54
+ * Resolved tri-state visibility from the storage service. Use this
55
+ * over `is_public` for new code — `is_public: true` covers both
56
+ * `'app_public'` (auth-gated CDN) and `'anonymous_visible'`
57
+ * (unsigned public CDN), which have different delivery contracts.
58
+ */
59
+ visibility: Visibility;
60
+ /**
61
+ * Stable unsigned public-CDN URL — populated only when
62
+ * `visibility === 'anonymous_visible'`. Drop directly into
63
+ * `<img src>` on logged-out pages. For other visibilities use
64
+ * `original_view_url` (signed) or the photo transform URL.
65
+ */
66
+ cdn_url: string | null;
38
67
  }
39
68
  /**
40
69
  * Per-app media-pipeline policy. Drives release-gating + processing
@@ -55,10 +84,34 @@ interface MediaUploadResult {
55
84
  */
56
85
  type MediaPolicy = 'fast_trusted' | 'safe_visible' | 'safe_public' | 'moderated' | 'compliance';
57
86
  interface UseMediaUploadOptions {
58
- /** Whether the resulting storage object should be public-readable.
87
+ /**
88
+ * Tri-state visibility (preferred — see {@link Visibility} in
89
+ * `@scalemule/sdk`). Three modes:
90
+ * - `'private'` — owner + app members only (DEFAULT)
91
+ * - `'app_public'` — readable by any authenticated end-user
92
+ * in the same application; same semantics
93
+ * the legacy `is_public: true` flag has
94
+ * always had
95
+ * - `'anonymous_visible'` — world-readable on the unsigned public
96
+ * CDN. Returned `cdn_url` is safe to drop
97
+ * into `<img src>` on a logged-out page.
98
+ *
99
+ * If both `visibility` and `is_public` are passed, `visibility`
100
+ * wins. `'anonymous_visible'` requires the operator to have
101
+ * provisioned the anonymous-delivery bucket — the storage service
102
+ * surfaces 503 `ANONYMOUS_DELIVERY_NOT_CONFIGURED` otherwise (the
103
+ * SDK never silently demotes).
104
+ */
105
+ visibility?: Visibility;
106
+ /**
107
+ * Legacy two-state visibility flag. `true` → `app_public`; `false`
108
+ * → `private`. Prefer the typed `visibility` field for new code —
109
+ * `is_public: true` cannot express `anonymous_visible`.
110
+ *
59
111
  * Default: `false` (private). Public is opt-in for surfaces that
60
112
  * genuinely need it (avatars, public listings). Chat / DM uploads
61
- * should always be private. */
113
+ * should always be private.
114
+ */
62
115
  is_public?: boolean;
63
116
  /**
64
117
  * Per-call media-policy override. Defaults to `safe_visible` (visible
@@ -219,7 +272,7 @@ interface ScaleMuleProviderProps extends ScaleMuleConfig {
219
272
  * The platform stores the per-app policy in
220
273
  * `application_storage_settings.media_policy` (Phase 4 / P3, live in
221
274
  * prod). On boot, the provider fetches `GET /v1/storage/policy` (a
222
- * lightweight `EndUserOnly` endpoint added in `@scalemule/sdk@0.0.45`)
275
+ * lightweight `MemberOrEndUser` endpoint added in `@scalemule/sdk@0.0.45`)
223
276
  * and uses the returned policy as the effective default.
224
277
  *
225
278
  * Passing this prop overrides the auto-fetched value — useful for
@@ -227,8 +280,42 @@ interface ScaleMuleProviderProps extends ScaleMuleConfig {
227
280
  * platform config.
228
281
  */
229
282
  mediaPolicy?: MediaPolicy;
283
+ /**
284
+ * Member-auth bridge. When set, the provider runs in **member mode**:
285
+ *
286
+ * - Skips the `/v1/auth/me` end-user lookup and the auth-proxy
287
+ * `/me` flow. Identity is owned upstream (e.g. `MemberAuthProvider`
288
+ * in `web/scalemule-app`).
289
+ * - Calls `getToken()` on mount and propagates the returned token
290
+ * to all three SDK clients (`client`, `baseClient`, `money`) as a
291
+ * `Bearer` Authorization header. Returning `null` clears the token.
292
+ * - Re-polls every {@link memberTokenPollMs} milliseconds (default
293
+ * 60s) so cookie rotation in the host platform is picked up
294
+ * without a full page reload.
295
+ *
296
+ * Use {@link userResolver} alongside this prop to populate `user` from
297
+ * a member-auth endpoint instead of `/v1/auth/me`.
298
+ *
299
+ * Mutually exclusive with `authProxyUrl`. If both are set, `getToken`
300
+ * wins and the auth-proxy path is skipped.
301
+ */
302
+ getToken?: () => string | null | Promise<string | null>;
303
+ /**
304
+ * Resolves the `User` shown to the app in member-auth mode. The
305
+ * provider calls this once after the initial token is set; the host
306
+ * platform typically just returns its own `MemberProfile` mapped to
307
+ * the SDK's `User` shape. Optional — if omitted, `user` stays `null`
308
+ * and the host platform is responsible for surfacing identity.
309
+ */
310
+ userResolver?: () => Promise<User | null>;
311
+ /**
312
+ * Member-mode token poll interval in milliseconds. Default 60_000
313
+ * (1 minute). Pass `null` to disable polling (only the mount-time
314
+ * read happens).
315
+ */
316
+ memberTokenPollMs?: number | null;
230
317
  }
231
- declare function ScaleMuleProvider({ apiKey, applicationId, environment, gatewayUrl, debug, storage, analyticsProxyUrl, authProxyUrl, telemetryEndpoint, publishableKey, enableAccountSwitcher, accountSwitcherPrivacy, children, onLogin, onLogout, onAuthError, bootstrapFlags, mediaPolicy, }: ScaleMuleProviderProps): react_jsx_runtime.JSX.Element;
318
+ declare function ScaleMuleProvider({ apiKey, applicationId, environment, gatewayUrl, debug, storage, analyticsProxyUrl, authProxyUrl, telemetryEndpoint, publishableKey, enableAccountSwitcher, accountSwitcherPrivacy, children, onLogin, onLogout, onAuthError, bootstrapFlags, mediaPolicy, getToken, userResolver, memberTokenPollMs, }: ScaleMuleProviderProps): react_jsx_runtime.JSX.Element;
232
319
  declare function useScaleMule(): ScaleMuleContextValue;
233
320
  declare function useScaleMuleClient(): ScaleMuleClient;
234
321
  declare function useMoneyClient(): MoneyClient;
@@ -850,6 +937,35 @@ interface UseFeedbackResult {
850
937
  */
851
938
  declare function useFeedback(options?: UseFeedbackOptions): UseFeedbackResult;
852
939
 
940
+ interface VoteState {
941
+ /** Caller's current vote: 1 = upvote, -1 = downvote, 0 = no vote. */
942
+ value: 1 | -1 | 0;
943
+ up_count: number;
944
+ down_count: number;
945
+ score: number;
946
+ }
947
+ interface UseVoteOptions {
948
+ /** Application-defined target type. e.g. "weekmob_post", "gistyo_gist". */
949
+ targetType: string;
950
+ targetId: string;
951
+ /** Optional seed (from SSR or list query). */
952
+ initialState?: VoteState | null;
953
+ /** Refetch even when initialState is provided. Default false. */
954
+ refetchOnMount?: boolean;
955
+ /** Skip the initial fetch entirely (anonymous viewers). Default true. */
956
+ enabled?: boolean;
957
+ }
958
+ interface UseVoteReturn {
959
+ state: VoteState;
960
+ isLoading: boolean;
961
+ error: Error | null;
962
+ /** Cast (or change/clear) the caller's vote with optimistic update. */
963
+ cast: (value: 1 | -1 | 0) => Promise<void>;
964
+ /** Refetch the canonical state from the server. */
965
+ refetch: () => Promise<void>;
966
+ }
967
+ declare function useVote({ targetType, targetId, initialState, refetchOnMount, enabled, }: UseVoteOptions): UseVoteReturn;
968
+
853
969
  interface FeedbackWidgetProps {
854
970
  /** Floating-button corner. Default `bottom-right`. */
855
971
  position?: 'bottom-right' | 'bottom-left' | 'top-right' | 'top-left';
@@ -888,21 +1004,32 @@ interface FeedbackWidgetProps {
888
1004
  */
889
1005
  declare function FeedbackWidget(props: FeedbackWidgetProps): ReactElement | null;
890
1006
 
891
- type NarrationPlayerAudio = TtsAudioInfo & {
892
- waveform_peaks?: number[] | null;
893
- ai_generated?: boolean;
894
- };
895
- interface NarrationPlayerProps {
896
- audio: NarrationPlayerAudio;
897
- className?: string;
898
- providerLabel?: string;
899
- narrationLabel?: string;
900
- refreshing?: boolean;
901
- onRefresh?: () => void | Promise<void>;
902
- showRefreshButton?: boolean;
903
- onPlaybackError?: () => void;
1007
+ interface VoteButtonClassNames {
1008
+ root?: string;
1009
+ upButton?: string;
1010
+ upButtonActive?: string;
1011
+ downButton?: string;
1012
+ downButtonActive?: string;
1013
+ score?: string;
1014
+ scorePositive?: string;
1015
+ scoreNegative?: string;
1016
+ }
1017
+ interface VoteButtonProps {
1018
+ targetType: string;
1019
+ targetId: string;
1020
+ /** Server-known initial state, e.g. seeded from a list query. */
1021
+ initialState?: VoteState | null;
1022
+ /** Visual layout. "horizontal" = up | score | down. "stacked" = column. */
1023
+ layout?: 'horizontal' | 'stacked';
1024
+ size?: 'compact' | 'regular';
1025
+ /** Called when an anonymous user clicks vote. */
1026
+ onSignInRequired?: () => void;
1027
+ onError?: (error: unknown) => void;
1028
+ classNames?: VoteButtonClassNames;
1029
+ upLabel?: string;
1030
+ downLabel?: string;
904
1031
  }
905
- declare function NarrationPlayer({ audio, className, providerLabel, narrationLabel, refreshing, onRefresh, showRefreshButton, onPlaybackError, }: NarrationPlayerProps): react_jsx_runtime.JSX.Element | null;
1032
+ declare function VoteButton({ targetType, targetId, initialState, layout, size, onSignInRequired, onError, classNames, upLabel, downLabel, }: VoteButtonProps): react_jsx_runtime.JSX.Element;
906
1033
 
907
1034
  /**
908
1035
  * Client-side validation helpers
@@ -1062,4 +1189,4 @@ declare function createSafeLogger(prefix: string): {
1062
1189
  error: (message: string, data?: unknown) => void;
1063
1190
  };
1064
1191
 
1065
- export { ApiError$1 as ApiError, type AudioFile, type AudioUploadResult, type ConversationKind, type FeatureFlagEvaluation, type FeatureFlagEvaluation as FeatureFlagResult, type FeedbackItem, type FeedbackItemInput, type FeedbackPriority, type FeedbackStatus, type FeedbackType, FeedbackWidget, type FeedbackWidgetConfig, type FeedbackWidgetProps, ListFilesParams, LoginResponse, type MediaPolicy, type MediaUploadResult, NarrationPlayer, type NarrationPlayerAudio, type NarrationPlayerProps, type PasswordValidationResult, type PhoneCountry, type PhoneValidationResult, type RealtimeEvent, type RealtimeMessage, type RealtimeStatus, ScaleMuleClient, ScaleMuleConfig, ScaleMuleMedia, type ScaleMuleMediaProps, ScaleMuleProvider, type ScaleMuleProviderProps, UseAnalyticsOptions, UseAnalyticsReturn, type UseAudioReturn, type UseAudioUploadOptions, UseAuthReturn, UseBillingReturn, UseContentReturn, type UseFeatureFlagsOptions, type UseFeatureFlagsReturn, type UseFeedbackOptions, type UseFeedbackResult, type UseFileStatusOptions, type UseFileStatusReturn, type UseFeatureFlagsOptions as UseFlagsOptions, type UseFeatureFlagsReturn as UseFlagsReturn, type UseMediaReturn, type UseMediaUploadOptions, type UsePushNotificationsOptions, type UsePushNotificationsReturn, type UseRealtimeOptions, type UseRealtimeReturn, type UseShareOptions, type UseShareReturn, type UseTtsJobOptions, type UseTtsJobReturn, UseUserReturn, User, type UsernameValidationResult, composePhone, createSafeLogger, normalizePhone, phoneCountries, sanitizeForLog, useAnalytics, useAudio, useAuth, useBilling, useContent, useFeatureFlags, useFeedback, useFileStatus, useMedia, useMoney, useMoneyClient, usePushNotifications, useRealtime, useScaleMule, useScaleMuleClient, useShare, useTtsJob, useUser, validateForm, validators };
1192
+ export { ApiError$1 as ApiError, type AudioFile, type AudioUploadResult, type ConversationKind, type FeatureFlagEvaluation, type FeatureFlagEvaluation as FeatureFlagResult, type FeedbackItem, type FeedbackItemInput, type FeedbackPriority, type FeedbackStatus, type FeedbackType, FeedbackWidget, type FeedbackWidgetConfig, type FeedbackWidgetProps, ListFilesParams, LoginResponse, type MediaPolicy, type MediaUploadResult, type PasswordValidationResult, type PhoneCountry, type PhoneValidationResult, type RealtimeEvent, type RealtimeMessage, type RealtimeStatus, ScaleMuleClient, ScaleMuleConfig, ScaleMuleMedia, type ScaleMuleMediaProps, ScaleMuleProvider, type ScaleMuleProviderProps, UseAnalyticsOptions, UseAnalyticsReturn, type UseAudioReturn, type UseAudioUploadOptions, UseAuthReturn, UseBillingReturn, UseContentReturn, type UseFeatureFlagsOptions, type UseFeatureFlagsReturn, type UseFeedbackOptions, type UseFeedbackResult, type UseFileStatusOptions, type UseFileStatusReturn, type UseFeatureFlagsOptions as UseFlagsOptions, type UseFeatureFlagsReturn as UseFlagsReturn, type UseMediaReturn, type UseMediaUploadOptions, type UsePushNotificationsOptions, type UsePushNotificationsReturn, type UseRealtimeOptions, type UseRealtimeReturn, type UseShareOptions, type UseShareReturn, type UseTtsJobOptions, type UseTtsJobReturn, UseUserReturn, type UseVoteOptions, type UseVoteReturn, User, type UsernameValidationResult, VoteButton, type VoteButtonClassNames, type VoteButtonProps, type VoteState, composePhone, createSafeLogger, normalizePhone, phoneCountries, sanitizeForLog, useAnalytics, useAudio, useAuth, useBilling, useContent, useFeatureFlags, useFeedback, useFileStatus, useMedia, useMoney, useMoneyClient, usePushNotifications, useRealtime, useScaleMule, useScaleMuleClient, useShare, useTtsJob, useUser, useVote, validateForm, validators };