@bcrumbs.net/inbox 0.0.62 → 0.0.64

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.
Files changed (78) hide show
  1. package/assets/ar/inbox.json +3 -0
  2. package/assets/en/inbox.json +3 -0
  3. package/e2e/auth.setup.d.ts +1 -0
  4. package/e2e/checkout/checkout.flows.d.ts +18 -0
  5. package/e2e/global.teardown.d.ts +1 -0
  6. package/e2e/support/auth.d.ts +18 -0
  7. package/e2e/support/cleanup.d.ts +20 -0
  8. package/e2e/support/config.d.ts +23 -0
  9. package/e2e/support/fixtures.d.ts +16 -0
  10. package/e2e/support/identifiers.d.ts +13 -0
  11. package/e2e/support/index.d.ts +6 -0
  12. package/index.cjs.js +1363 -427
  13. package/index.esm.js +1365 -430
  14. package/package.json +2 -2
  15. package/playwright.config.d.ts +0 -4
  16. package/src/app/ai/components/playground/ThreadMessages.d.ts +3 -1
  17. package/src/app/auth/components/AcceptInvitation.d.ts +2 -0
  18. package/src/app/auth/components/AuthLanguagePicker.d.ts +3 -0
  19. package/src/app/auth/components/AuthVisualCarousel.d.ts +1 -0
  20. package/src/app/auth/components/ClerkForgetPanel.d.ts +6 -0
  21. package/src/app/auth/components/ClerkResetPasswordPanel.d.ts +6 -0
  22. package/src/app/auth/components/ClerkSessionBridge.d.ts +16 -0
  23. package/src/app/auth/components/ClerkSignInPanel.d.ts +2 -0
  24. package/src/app/auth/components/ClerkSignUpPanel.d.ts +2 -0
  25. package/src/app/auth/components/password-page/PasswordFormView.d.ts +10 -1
  26. package/src/app/auth/config/authProvider.d.ts +12 -0
  27. package/src/app/auth/config/clerkAppearance.d.ts +534 -0
  28. package/src/app/auth/config/clerkLocalization.d.ts +6 -0
  29. package/src/app/auth/pages/Auth.style.d.ts +28 -0
  30. package/src/app/auth/pages/CheckAuth.d.ts +7 -4
  31. package/src/app/auth/pages/Forget.d.ts +2 -2
  32. package/src/app/auth/pages/Login.d.ts +3 -3
  33. package/src/app/auth/pages/Password.d.ts +2 -2
  34. package/src/app/auth/pages/Register.d.ts +2 -3
  35. package/src/app/auth/utils/clerkTracking.d.ts +9 -0
  36. package/src/app/billing/pages/GatewayWelcomePage.d.ts +2 -0
  37. package/src/app/billing/pages/GuidePage.d.ts +1 -0
  38. package/src/app/billing/utils/isGatewayPlan.d.ts +2 -0
  39. package/src/app/billing/utils/pendingPlanPurchaseStorage.d.ts +6 -6
  40. package/src/app/broadcast/constants.d.ts +2 -0
  41. package/src/app/contact/components/ImportProgressDialog.d.ts +2 -1
  42. package/src/app/generic/hooks/useOnlineStatus.d.ts +1 -1
  43. package/src/app/generic/hooks/usePaginatedQuery.d.ts +1 -0
  44. package/src/app/inbox/components/Chat/ChatContent.d.ts +3 -1
  45. package/src/app/inbox/components/NewDetails/ContactActionsMenu.d.ts +9 -0
  46. package/src/app/inbox/components/NewDetails/UserHeader.d.ts +2 -1
  47. package/src/app/inbox/components/Shared/MobileChatDetailsSlider.d.ts +1 -0
  48. package/src/app/inbox/components/Shared/MobileDetailsSwipeHint.d.ts +1 -1
  49. package/src/app/inbox/components/Shared/SharedStyle.d.ts +8 -0
  50. package/src/app/inbox/hooks/useConvEnhance.d.ts +3 -1
  51. package/src/app/inbox/hooks/useConversationsPerodicFetch.d.ts +7 -0
  52. package/src/app/inbox/utils/convAssistStorage.d.ts +9 -4
  53. package/src/app/inbox/utils/convs.d.ts +4 -0
  54. package/src/app/inbox/utils/sounds.d.ts +2 -0
  55. package/src/app/layout/components/LogoutPopin.d.ts +6 -3
  56. package/src/app/layout/components/language/index.d.ts +5 -1
  57. package/src/app/layout/constants/index.d.ts +35 -0
  58. package/src/app/managemnet/config/webhookDefinition.d.ts +4 -0
  59. package/src/app/managemnet/pages/generalSettings/WritingAssistanceSettings.d.ts +9 -0
  60. package/src/app/managemnet/pages/generalSettings/holidayConstants.d.ts +5 -0
  61. package/src/app/managemnet/pages/generalSettings/writingConstants.d.ts +6 -0
  62. package/src/app/resources/components/Agents/CreateAgent.d.ts +7 -3
  63. package/src/app/subscriptions/components/NewSubscription/SubscriptionSuccess.d.ts +3 -1
  64. package/src/app/subscriptions/components/Plans/PlanCard.d.ts +3 -1
  65. package/src/app/subscriptions/components/Plans/ShowcasePlans.d.ts +3 -1
  66. package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionCreditsCard.d.ts +5 -0
  67. package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionProfile.d.ts +0 -1
  68. package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionUsers.d.ts +0 -1
  69. package/src/app/subscriptions/components/SubscriptionSettings/index.d.ts +17 -2
  70. package/src/app/subscriptions/constants/Plans.d.ts +2 -1
  71. package/src/app/subscriptions/utils/estimateUpgradeProration.d.ts +26 -0
  72. package/src/assets/locales/translations.d.ts +151 -0
  73. package/src/environments/environment.dev.d.ts +2 -0
  74. package/src/environments/types.d.ts +7 -0
  75. package/src/graphql.autogenerated.d.ts +981 -4
  76. package/src/graphql.billing.autogenerated.d.ts +193 -0
  77. package/src/lib/EmbeddedMobileMenu.d.ts +1 -2
  78. package/src/lib/index.d.ts +1 -0
@@ -1,17 +1,44 @@
1
1
  /// <reference types="react" />
2
2
  export declare const TEAL = "#16616C";
3
+ /** AuthVisualCarousel is `display: none` below this width. */
4
+ export declare const AUTH_VISUAL_MIN_WIDTH_PX = 1200;
3
5
  export declare const AuthContainer: import("@emotion/styled").StyledComponent<{
4
6
  theme?: import("@emotion/react").Theme | undefined;
5
7
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
8
+ } & {
9
+ rtl?: boolean | undefined;
10
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
11
+ /** Floating language control — top end of the auth shell (RTL-aware). */
12
+ export declare const AuthLanguagePickerWrap: import("@emotion/styled").StyledComponent<{
13
+ theme?: import("@emotion/react").Theme | undefined;
14
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
6
15
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
7
16
  export declare const AuthFormColumn: import("@emotion/styled").StyledComponent<{
8
17
  theme?: import("@emotion/react").Theme | undefined;
9
18
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
19
+ } & {
20
+ rtl?: boolean | undefined;
10
21
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
11
22
  export declare const AuthFormContent: import("@emotion/styled").StyledComponent<{
12
23
  theme?: import("@emotion/react").Theme | undefined;
13
24
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
14
25
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
26
+ /** Tighter stack so the BC logo sits near Clerk's heading (legacy keeps the 48px gap). */
27
+ export declare const ClerkAuthFormColumn: import("@emotion/styled").StyledComponent<{
28
+ theme?: import("@emotion/react").Theme | undefined;
29
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
30
+ } & {
31
+ rtl?: boolean | undefined;
32
+ } & import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
33
+ theme?: import("@emotion/react").Theme | undefined;
34
+ }, {}, {}>;
35
+ /** Clerk v5 draws the card shadow on .cl-cardBox; force it off inside our auth shell. */
36
+ export declare const ClerkAuthFormContent: import("@emotion/styled").StyledComponent<{
37
+ theme?: import("@emotion/react").Theme | undefined;
38
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
39
+ } & import("react").ClassAttributes<HTMLDivElement> & import("react").HTMLAttributes<HTMLDivElement> & {
40
+ theme?: import("@emotion/react").Theme | undefined;
41
+ }, {}, {}>;
15
42
  export declare const SigninForm: import("@emotion/styled").StyledComponent<{
16
43
  theme?: import("@emotion/react").Theme | undefined;
17
44
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
@@ -62,6 +89,7 @@ export declare const SignUpFooter: import("@emotion/styled").StyledComponent<{
62
89
  export declare const SignUpLink: import("@emotion/styled").StyledComponent<import("react-router-dom").LinkProps<unknown> & import("react").RefAttributes<HTMLAnchorElement> & {
63
90
  theme?: import("@emotion/react").Theme | undefined;
64
91
  }, {}, {}>;
92
+ /** @deprecated Prefer AuthVisualCarousel — kept for any residual imports */
65
93
  export declare const HelloCon: import("@emotion/styled").StyledComponent<{
66
94
  theme?: import("@emotion/react").Theme | undefined;
67
95
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
@@ -1,10 +1,13 @@
1
1
  /**
2
2
  * Public entry from marketing pricing CTAs (?planType=...).
3
3
  * Verifies the session via currentUser, then:
4
- * - authenticated + planType in query → upgrade flow (auto Polar/Stripe checkout)
5
- * - authenticated + no planType → inbox
6
- * - guest + planType → register with planType preserved
7
- * - guest + no planType → login
4
+ * - authenticated + plan intent → upgrade flow (auto Polar/Stripe checkout)
5
+ * - authenticated + no plan intent → inbox
6
+ * - guest + plan intent → register with planType preserved
7
+ * - guest + no plan intent → login
8
+ *
9
+ * The plan intent comes from the query when present, otherwise from the value stored earlier
10
+ * in this tab.
8
11
  */
9
12
  declare const CheckAuth: () => import("@emotion/react/jsx-runtime").JSX.Element;
10
13
  export default CheckAuth;
@@ -6,5 +6,5 @@ export type Props = {
6
6
  error: any;
7
7
  status: any;
8
8
  };
9
- declare const _default: any;
10
- export default _default;
9
+ declare const Forget: (props: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
10
+ export default Forget;
@@ -1,3 +1,3 @@
1
- /// <reference types="react" />
2
- declare const _default: import("react").ComponentClass<{}, any>;
3
- export default _default;
1
+ export declare const LegacyLoginPage: (props: any) => import("@emotion/react/jsx-runtime").JSX.Element;
2
+ declare const Login: (props: any) => import("@emotion/react/jsx-runtime").JSX.Element;
3
+ export default Login;
@@ -8,5 +8,5 @@ export type Props = {
8
8
  error: any;
9
9
  status: any;
10
10
  };
11
- declare const _default: any;
12
- export default _default;
11
+ declare const Password: (props: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
12
+ export default Password;
@@ -1,3 +1,2 @@
1
- /// <reference types="react" />
2
- declare const _default: import("react").ComponentClass<{}, any>;
3
- export default _default;
1
+ declare const Register: (props: any) => import("@emotion/react/jsx-runtime").JSX.Element;
2
+ export default Register;
@@ -0,0 +1,9 @@
1
+ import type { PostHog } from 'posthog-js';
2
+ /** Funnel / UX events captured in the portal for Clerk auth flows. */
3
+ export declare const ClerkTrackingEvents: {
4
+ readonly SignupStarted: "Signup Started";
5
+ readonly ForgetPasswordSuccess: "Forget Password Success";
6
+ readonly ResetPasswordSuccess: "Reset Password Success";
7
+ };
8
+ export declare function captureClerkEvent(posthog: PostHog | null | undefined, eventName: string, properties?: Record<string, string | number | boolean | undefined>): void;
9
+ export declare function identifyClerkUser(posthog: PostHog | null | undefined, userId: string, email?: string): void;
@@ -0,0 +1,2 @@
1
+ /** First-run welcome for Gateway workspaces — continues to the API Guide. */
2
+ export default function GatewayWelcomePage(): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1 @@
1
+ export default function GuidePage(): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -0,0 +1,2 @@
1
+ export declare function isGatewayPlan(planType: string | null | undefined): boolean;
2
+ export declare const GATEWAY_WEBHOOK_EVENTS: readonly ["INCOMING_MESSAGE", "MESSAGE_UPDATED", "OUTGOING_MESSAGE"];
@@ -1,10 +1,10 @@
1
1
  import { PlanType } from '../../../graphql.billing.autogenerated';
2
- /** Normalizes landing-page planType query values to billing PlanType. */
3
- export declare function normalizePendingPlanType(raw: string | null | undefined): PlanType | null;
4
2
  export declare function setPendingPlanPurchase(planType: string): void;
5
3
  export declare function getPendingPlanPurchase(): PlanType | null;
6
4
  export declare function clearPendingPlanPurchase(): void;
7
- /** True when the URL search string contains a valid paid planType. */
8
- export declare function hasPlanTypeInSearch(search: string): boolean;
9
- /** Reads planType from a URL search string and persists it when valid. */
10
- export declare function capturePendingPlanFromSearch(search: string): PlanType | null;
5
+ /**
6
+ * Resolves the plan the user intends to buy from the URL first, then from the stored value.
7
+ * A planType found in the URL is persisted, so later steps of the flow keep working once the
8
+ * query param is gone.
9
+ */
10
+ export declare function resolvePendingPlanType(search: string): PlanType | null;
@@ -0,0 +1,2 @@
1
+ /** Matches core BROADCAST_RECENT_INBOUND_MESSAGE_DAYS — contacts must have inbound activity in this window. */
2
+ export declare const BROADCAST_RECENT_INBOUND_MESSAGE_DAYS = 90;
@@ -8,6 +8,7 @@ type ImportProgressDialogProps = {
8
8
  title?: string;
9
9
  completedTitle?: string;
10
10
  failedTitle?: string;
11
+ onCancel?: () => void;
11
12
  };
12
- declare const ImportProgressDialog: ({ isOpen, progress, status, onClose, rtl, title, completedTitle, failedTitle, }: ImportProgressDialogProps) => import("@emotion/react/jsx-runtime").JSX.Element;
13
+ declare const ImportProgressDialog: ({ isOpen, progress, status, onClose, rtl, title, completedTitle, failedTitle, onCancel, }: ImportProgressDialogProps) => import("@emotion/react/jsx-runtime").JSX.Element;
13
14
  export default ImportProgressDialog;
@@ -1,5 +1,5 @@
1
1
  export declare function useOnlineStatus(): {
2
2
  isOnline: boolean;
3
- networkStatus: "online" | "offline" | "checking";
3
+ networkStatus: "offline" | "online" | "checking";
4
4
  isChecking: boolean;
5
5
  };
@@ -22,6 +22,7 @@ export interface PaginationOptions {
22
22
  additionalVariables?: Record<string, any>;
23
23
  searchQuery?: string;
24
24
  count?: boolean;
25
+ context?: Record<string, unknown>;
25
26
  }
26
27
  export interface UsePaginatedQueryResult<T> {
27
28
  items: T[];
@@ -14,6 +14,8 @@ interface ChatContentProps {
14
14
  searchMatchNo: number;
15
15
  onSearchMatchCount: (count: number) => void;
16
16
  onMessageReply: (messageId: string) => void;
17
+ onMessageReact?: (messageId: string, emoji: string) => void;
18
+ onMessageUnreact?: (messageId: string, emoji: string) => void;
17
19
  replyMessage: {
18
20
  title: string;
19
21
  content: string;
@@ -30,5 +32,5 @@ interface ChatContentProps {
30
32
  /** Called when user clicks "Add Contact" on a contact message card */
31
33
  onContactAddContact?: (contact: ContactMessagePayload) => void;
32
34
  }
33
- declare const ChatContent: ({ messages, olderMessages, canContribute, sendMessage, loadOlderMessages, agentsIdsAvatarsMap, noteMode, onNoteSend, onCloseNoteMode, onAddNoteClick, searchPattern, searchMatchNo, onSearchMatchCount, onMessageReply, replyMessage, onCancelReplyMessage, errorMessage, statusFailureMessage, logo, conversationId, onContactMessage, onContactAddContact, }: ChatContentProps) => import("@emotion/react/jsx-runtime").JSX.Element;
35
+ declare const ChatContent: ({ messages, olderMessages, canContribute, sendMessage, loadOlderMessages, agentsIdsAvatarsMap, noteMode, onNoteSend, onCloseNoteMode, onAddNoteClick, searchPattern, searchMatchNo, onSearchMatchCount, onMessageReply, onMessageReact, onMessageUnreact, replyMessage, onCancelReplyMessage, errorMessage, statusFailureMessage, logo, conversationId, onContactMessage, onContactAddContact, }: ChatContentProps) => import("@emotion/react/jsx-runtime").JSX.Element;
34
36
  export default ChatContent;
@@ -0,0 +1,9 @@
1
+ interface ContactActionsMenuProps {
2
+ clientId: string;
3
+ clientName: string;
4
+ deletedAt?: string | null;
5
+ blacklistedAt?: string | null;
6
+ onActionComplete?: () => void;
7
+ }
8
+ declare const ContactActionsMenu: ({ clientId, clientName, deletedAt, blacklistedAt, onActionComplete, }: ContactActionsMenuProps) => import("@emotion/react/jsx-runtime").JSX.Element;
9
+ export default ContactActionsMenu;
@@ -3,6 +3,7 @@ interface UserHeaderProps {
3
3
  clientData: ClientQuery['client'] | undefined;
4
4
  setEditMode: (editMode: boolean) => void;
5
5
  onBackToList?: () => void;
6
+ onClientActionComplete?: () => void;
6
7
  }
7
- declare const UserHeader: ({ clientData, setEditMode, onBackToList }: UserHeaderProps) => import("@emotion/react/jsx-runtime").JSX.Element;
8
+ declare const UserHeader: ({ clientData, setEditMode, onBackToList, onClientActionComplete }: UserHeaderProps) => import("@emotion/react/jsx-runtime").JSX.Element;
8
9
  export default UserHeader;
@@ -8,6 +8,7 @@ type MobileChatDetailsSliderProps = {
8
8
  };
9
9
  /**
10
10
  * Side-by-side chat/details pager with follow-the-finger drag.
11
+ * Pane order is always [chat | details] in physical LTR space.
11
12
  * Edge chevron buttons remain for one-tap navigation.
12
13
  */
13
14
  export declare const MobileChatDetailsSlider: ({ showDetails, onShowDetailsChange, rtl, chat, details, }: MobileChatDetailsSliderProps) => import("@emotion/react/jsx-runtime").JSX.Element;
@@ -5,5 +5,5 @@ type MobileDetailsSwipeHintProps = {
5
5
  direction?: 'toDetails' | 'toChat';
6
6
  };
7
7
  /** Edge affordance for mobile chat ↔ details swipe navigation. */
8
- export declare const MobileDetailsSwipeHint: ({ rtl, onClick, direction, }: MobileDetailsSwipeHintProps) => import("@emotion/react/jsx-runtime").JSX.Element;
8
+ export declare const MobileDetailsSwipeHint: ({ onClick, direction, }: MobileDetailsSwipeHintProps) => import("@emotion/react/jsx-runtime").JSX.Element;
9
9
  export {};
@@ -33,3 +33,11 @@ export declare const ArchivedLabelStyle: import("@emotion/styled").StyledCompone
33
33
  theme?: import("@emotion/react").Theme | undefined;
34
34
  as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
35
35
  }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
36
+ export declare const BlockedLabelStyle: import("@emotion/styled").StyledComponent<{
37
+ theme?: import("@emotion/react").Theme | undefined;
38
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
39
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
40
+ export declare const StatusLabelsRow: import("@emotion/styled").StyledComponent<{
41
+ theme?: import("@emotion/react").Theme | undefined;
42
+ as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
43
+ }, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
@@ -1,14 +1,16 @@
1
1
  import { type MutableRefObject } from 'react';
2
+ import { type EnhanceWritingCacheSettings } from '../utils/convAssistStorage';
2
3
  export interface UseConvEnhanceOptions {
3
4
  enabled: boolean;
4
5
  workspaceId: number | undefined;
5
6
  conversationId: string | undefined;
6
7
  composerDraftRef: MutableRefObject<string>;
8
+ writingSettings: EnhanceWritingCacheSettings;
7
9
  onBeforeEnhance?: () => void;
8
10
  /** Fired when replace draft is applied so parent can skip auto-complete debounce for that update. */
9
11
  onReplaceDraftApplied?: () => void;
10
12
  }
11
- export declare function useConvEnhance({ enabled, workspaceId, conversationId, composerDraftRef, onBeforeEnhance, onReplaceDraftApplied, }: UseConvEnhanceOptions): {
13
+ export declare function useConvEnhance({ enabled, workspaceId, conversationId, composerDraftRef, writingSettings, onBeforeEnhance, onReplaceDraftApplied, }: UseConvEnhanceOptions): {
12
14
  autoCompleteReplaceDraft: string | undefined;
13
15
  autoCompleteReplaceDraftKey: number;
14
16
  isEnhanceLoading: boolean;
@@ -52,6 +52,13 @@ declare function useConversationsPeriodicFetch(selectedConvId?: string, onSelect
52
52
  replyToContent: string;
53
53
  replyToType: import("../../../graphql.autogenerated").MessageType;
54
54
  } | null | undefined;
55
+ reactions?: {
56
+ __typename?: "MessageReaction" | undefined;
57
+ emoji: string;
58
+ isAgent: boolean;
59
+ agentId?: string | null | undefined;
60
+ createdAt: any;
61
+ }[] | null | undefined;
55
62
  }[] | null | undefined;
56
63
  client?: {
57
64
  __typename?: "ConversationClient" | undefined;
@@ -1,11 +1,16 @@
1
- /** Enhance cache key: workspace + draft only (no conversation). */
2
- export declare function buildEnhanceCacheKey(workspaceId: number, draft: string): string;
1
+ /** Writing settings that affect enhance output (included in cache key). */
2
+ export type EnhanceWritingCacheSettings = {
3
+ readingLevel: string;
4
+ brandVoice: string;
5
+ };
6
+ /** Enhance cache key: workspace + writing settings + draft (no conversation). */
7
+ export declare function buildEnhanceCacheKey(workspaceId: number, draft: string, writingSettings: EnhanceWritingCacheSettings): string;
3
8
  export declare function getPersistedAutoComplete(workspaceId: number, cacheKey: string): string | undefined;
4
9
  export declare function setPersistedAutoComplete(workspaceId: number, cacheKey: string, suffix: string): void;
5
10
  /** Removes all auto-complete entries for a conversation (e.g. when it is closed). */
6
11
  export declare function clearPersistedAutoCompleteForConversation(workspaceId: number, convId: string): void;
7
- export declare function getPersistedEnhance(workspaceId: number, draft: string): string | undefined;
8
- export declare function setPersistedEnhance(workspaceId: number, draft: string, enhancedText: string): void;
12
+ export declare function getPersistedEnhance(workspaceId: number, draft: string, writingSettings: EnhanceWritingCacheSettings): string | undefined;
13
+ export declare function setPersistedEnhance(workspaceId: number, draft: string, writingSettings: EnhanceWritingCacheSettings, enhancedText: string): void;
9
14
  /** Warm in-memory LRU from localStorage (bounded). */
10
15
  export declare function hydrateAutoCompleteMemoryCache(workspaceId: number, memoryCache: {
11
16
  set: (key: string, suffix: string) => void;
@@ -46,6 +46,10 @@ interface BuildLifeCycleMenuOptions {
46
46
  export declare function getNumOfNewClientMessages(messages: Maybe<Message[]> | undefined): number;
47
47
  export declare function getLastMessage(messages: Maybe<Message[]> | undefined, filterFn?: (m: Message) => boolean): Message | undefined;
48
48
  export declare function hashStatuses(messages?: Maybe<Message[]> | null): string;
49
+ /** Include reaction fingerprint so reaction updates remount into chat without a status change. */
50
+ export declare function hashReactions(messages?: Maybe<Message[]> | null): string;
51
+ /** Replace or remove the business-side reaction while keeping the client's. */
52
+ export declare function replaceAgentReaction(reactions: Message['reactions'] | undefined, emoji: string | null, agentId?: string | null): NonNullable<Message['reactions']>;
49
53
  export declare function isOutside24HourWindow(message: Message | null | undefined): boolean;
50
54
  export declare function formatSeconds(value: number): string;
51
55
  type StartedTimeAgoTranslation = (key: string, options?: {
@@ -1,2 +1,4 @@
1
+ export declare function setInboxAudioBaseUrl(baseUrl?: string | null): void;
2
+ export declare function getInboxAudioBaseUrl(): string;
1
3
  export declare function playRecMessageSound(): void;
2
4
  export declare function playSendMessageSound(): void;
@@ -1,3 +1,6 @@
1
- export declare function LogoutPopin({ onClose }: {
2
- onClose: () => void;
3
- }): import("@emotion/react/jsx-runtime").JSX.Element;
1
+ type LogoutPopinProps = {
2
+ open: boolean;
3
+ onOpenChange: (open: boolean) => void;
4
+ };
5
+ export declare function LogoutPopin({ open, onOpenChange }: LogoutPopinProps): import("@emotion/react/jsx-runtime").JSX.Element;
6
+ export {};
@@ -1,2 +1,6 @@
1
- declare function SwitchLanguage(): import("@emotion/react/jsx-runtime").JSX.Element;
1
+ type SwitchLanguageProps = {
2
+ /** White icon + hover when the auth carousel is on screen (1200px+). */
3
+ variant?: 'default' | 'onDark';
4
+ };
5
+ declare function SwitchLanguage({ variant }: SwitchLanguageProps): import("@emotion/react/jsx-runtime").JSX.Element;
2
6
  export default SwitchLanguage;
@@ -1,4 +1,39 @@
1
1
  import { Permission } from '@bcrumbs.net/bc-shared';
2
+ /** Left-nav for Gateway (API template) workspaces — flat, no Management parent. */
3
+ export declare const BCGatewayNavigation: {
4
+ leftLinks: ({
5
+ label: string;
6
+ title: string;
7
+ icon: import("@emotion/react/jsx-runtime").JSX.Element;
8
+ link: string;
9
+ action: string;
10
+ description: string;
11
+ tags: string[];
12
+ requiredPermissions: Permission[];
13
+ matchActive?: undefined;
14
+ } | {
15
+ label: string;
16
+ title: string;
17
+ icon: import("@emotion/react/jsx-runtime").JSX.Element;
18
+ link: string;
19
+ action: string;
20
+ matchActive: boolean;
21
+ description: string;
22
+ tags: string[];
23
+ requiredPermissions: Permission[];
24
+ })[];
25
+ leftBottomLinks: {
26
+ label: string;
27
+ title: string;
28
+ icon: import("@emotion/react/jsx-runtime").JSX.Element;
29
+ link: string;
30
+ action: string;
31
+ tags: string[];
32
+ requiredPermissions: Permission[];
33
+ }[];
34
+ };
35
+ /** Paths that are top-level Gateway nav items (no Management sub-sidebar). */
36
+ export declare function isGatewayFlatNavPath(pathname: string): boolean;
2
37
  export declare const BCMainNavigation: {
3
38
  leftLinks: ({
4
39
  label: string;
@@ -1,4 +1,8 @@
1
1
  import { Webhook } from '../../../graphql.autogenerated';
2
2
  import { ResourceDefinition } from './types';
3
+ export declare function getWebhookEventOptions(isGateway?: boolean): {
4
+ value: string;
5
+ label: string;
6
+ }[];
3
7
  declare const webhookDefinition: ResourceDefinition<Webhook>;
4
8
  export default webhookDefinition;
@@ -0,0 +1,9 @@
1
+ export type WritingAssistanceSettingsProps = {
2
+ loading: boolean;
3
+ writingReadingLevel: string;
4
+ writingBrandVoice: string;
5
+ onReadingLevelChange: (value: string) => void;
6
+ onBrandVoiceChange: (value: string) => void;
7
+ };
8
+ declare const WritingAssistanceSettings: ({ loading, writingReadingLevel, writingBrandVoice, onReadingLevelChange, onBrandVoiceChange, }: WritingAssistanceSettingsProps) => import("@emotion/react/jsx-runtime").JSX.Element;
9
+ export default WritingAssistanceSettings;
@@ -0,0 +1,5 @@
1
+ export declare const HOLIDAY_WEEKDAYS: readonly ["SUN", "MON", "TUE", "WED", "THU", "FRI", "SAT"];
2
+ export type HolidayWeekday = (typeof HOLIDAY_WEEKDAYS)[number];
3
+ export declare const HOLIDAY_TIMEZONES: readonly ["UTC", "America/New_York", "America/Chicago", "America/Denver", "America/Los_Angeles", "America/Phoenix", "America/Sao_Paulo", "America/Manaus", "America/Fortaleza", "Europe/London", "Europe/Paris", "Europe/Berlin", "Europe/Madrid", "Europe/Rome", "Europe/Amsterdam", "Europe/Istanbul", "Asia/Amman", "Asia/Riyadh", "Asia/Dubai", "Asia/Beirut", "Asia/Kuwait", "Asia/Qatar", "Asia/Bahrain", "Asia/Baghdad", "Asia/Jerusalem", "Africa/Cairo", "Africa/Casablanca", "Africa/Algiers", "Africa/Tunis", "Africa/Tripoli"];
4
+ export type HolidayTimezone = (typeof HOLIDAY_TIMEZONES)[number];
5
+ export declare const DEFAULT_HOLIDAY_TIMEZONE: HolidayTimezone;
@@ -0,0 +1,6 @@
1
+ export declare const WRITING_READING_LEVELS: readonly ["SIMPLE", "STANDARD", "TECHNICAL"];
2
+ export type WritingReadingLevelOption = (typeof WRITING_READING_LEVELS)[number];
3
+ export declare const DEFAULT_WRITING_READING_LEVEL: WritingReadingLevelOption;
4
+ export declare const WRITING_BRAND_VOICES: readonly ["FRIENDLY", "FORMAL", "EMPATHETIC", "CONCISE", "ENTHUSIASTIC", "PLAYFUL"];
5
+ export type WritingBrandVoiceOption = (typeof WRITING_BRAND_VOICES)[number];
6
+ export declare const DEFAULT_WRITING_BRAND_VOICE: WritingBrandVoiceOption;
@@ -1,3 +1,7 @@
1
- export declare const companyUsersQueryOptions: any;
2
- declare const _default: any;
3
- export default _default;
1
+ import { Agent } from '../../../../graphql.autogenerated';
2
+ import { ResourceDefinition } from '../../config';
3
+ type CreateAgentProps = {
4
+ resourceDef: ResourceDefinition<Agent>;
5
+ };
6
+ declare const CreateAgent: ({ resourceDef }: CreateAgentProps) => import("@emotion/react/jsx-runtime").JSX.Element;
7
+ export default CreateAgent;
@@ -3,6 +3,8 @@ type SubscriptionSuccessProps = {
3
3
  workspaceId?: number;
4
4
  /** When false, copy reflects activation without a payment (free plan). */
5
5
  paid?: boolean;
6
+ /** Gateway workspaces continue to Guide instead of Inbox. */
7
+ gateway?: boolean;
6
8
  };
7
- export declare const SubscriptionSuccess: ({ workspaceId, paid }: SubscriptionSuccessProps) => import("@emotion/react/jsx-runtime").JSX.Element;
9
+ export declare const SubscriptionSuccess: ({ workspaceId, paid, gateway }: SubscriptionSuccessProps) => import("@emotion/react/jsx-runtime").JSX.Element;
8
10
  export default SubscriptionSuccess;
@@ -9,5 +9,7 @@ export type PlanCardProps = {
9
9
  loading?: boolean;
10
10
  processing?: boolean;
11
11
  available?: boolean;
12
+ /** Stable hook for tests (e.g. `plan-choose-free`). */
13
+ testId?: string;
12
14
  };
13
- export declare function PlanCard({ name, price, subtitle, features, isCurrent, isPopular, onChoose, loading, processing, available, }: PlanCardProps): import("@emotion/react/jsx-runtime").JSX.Element;
15
+ export declare function PlanCard({ name, price, subtitle, features, isCurrent, isPopular, onChoose, loading, processing, available, testId, }: PlanCardProps): import("@emotion/react/jsx-runtime").JSX.Element;
@@ -3,6 +3,8 @@ import { PlanType, Term } from '../../../../graphql.billing.autogenerated';
3
3
  type ShowcasePlansProps = {
4
4
  onPlanPicked: (plan: PlanTypes, term: Term, includeAi: boolean) => void;
5
5
  disableFreePlan?: boolean;
6
+ /** Show prepaid WhatsApp API Gateway plan (free → gateway only). */
7
+ showGatewayPlan?: boolean;
6
8
  currentPlanType?: PlanType | null;
7
9
  /** The billing term the user is currently subscribed to */
8
10
  currentTerm?: Term | null;
@@ -13,5 +15,5 @@ type ShowcasePlansProps = {
13
15
  /** Force the Crumby AI plan toggle on (e.g. deep-link from upgrade CTA). */
14
16
  defaultIncludeAi?: boolean;
15
17
  };
16
- export declare const ShowcasePlans: ({ onPlanPicked, disableFreePlan, currentPlanType, currentTerm, selectingPlan, processing, loadingPlanType, defaultIncludeAi, }: ShowcasePlansProps) => import("@emotion/react/jsx-runtime").JSX.Element;
18
+ export declare const ShowcasePlans: ({ onPlanPicked, disableFreePlan, showGatewayPlan, currentPlanType, currentTerm, selectingPlan, processing, loadingPlanType, defaultIncludeAi, }: ShowcasePlansProps) => import("@emotion/react/jsx-runtime").JSX.Element;
17
19
  export default ShowcasePlans;
@@ -0,0 +1,5 @@
1
+ type SubscriptionCreditsCardProps = {
2
+ workspaceId: number;
3
+ };
4
+ declare const SubscriptionCreditsCard: ({ workspaceId }: SubscriptionCreditsCardProps) => import("@emotion/react/jsx-runtime").JSX.Element | null;
5
+ export default SubscriptionCreditsCard;
@@ -4,7 +4,6 @@ type SubscriptionProfileRouteProps = {
4
4
  subscriptionAccountId: string;
5
5
  subscriptionCreateDate: string;
6
6
  onUpdate: () => any;
7
- updateCompany: (id: string, name: string) => any;
8
7
  config: any;
9
8
  isEditing: boolean;
10
9
  onSave?: (name: string) => Promise<void>;
@@ -5,7 +5,6 @@ type SubscriptionProfileRouteProps = {
5
5
  refetchUsers: any;
6
6
  loadingUsers: boolean;
7
7
  inviteUser: (companyId: number, Email: string, actorEmail: string) => Promise<unknown>;
8
- removeUserFromCompany: (companyId: number, userId: string) => Promise<unknown>;
9
8
  };
10
9
  export declare const SubscriptionUsers: (props: SubscriptionProfileRouteProps) => import("@emotion/react/jsx-runtime").JSX.Element;
11
10
  declare const _default: any;
@@ -4,11 +4,26 @@ export type WorkspaceCompany = {
4
4
  AccountId?: string | null;
5
5
  CreateDate?: string | null;
6
6
  };
7
+ export type InviteStatus = 'PENDING' | 'APPROVED';
8
+ /** Legacy Membership user shape still expected by SubscriptionUsers / agent pickers. */
9
+ export type CompanyUserRow = {
10
+ Id: string;
11
+ Email?: string | null;
12
+ UserName?: string | null;
13
+ IsEnabled?: boolean;
14
+ inviteStatus?: InviteStatus;
15
+ };
16
+ interface Props {
17
+ companies: WorkspaceCompany[];
18
+ subscriptionId?: string | number;
19
+ refetchCompanies: () => Promise<unknown>;
20
+ loadingCompanies?: boolean;
21
+ }
7
22
  export declare enum TABS {
8
23
  PROFILE = "PROFILE",
9
24
  USERS = "USERS",
10
25
  INTEGRATIONS = "INTEGRATIONS",
11
26
  BILLING = "BILLING"
12
27
  }
13
- declare const _default: any;
14
- export default _default;
28
+ declare const SubscriptionSettings: ({ subscriptionId, refetchCompanies, companies, loadingCompanies, }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
29
+ export default SubscriptionSettings;
@@ -15,7 +15,8 @@ export declare enum PlanTypes {
15
15
  AUTOMATE = "automate",
16
16
  AUTOMATE_PLUS = "automate_plus",
17
17
  AUTOMATE_MAX = "automate_max",
18
- CUSTOM = "custom"
18
+ CUSTOM = "custom",
19
+ GATEWAY = "gateway"
19
20
  }
20
21
  export declare const PlanPrices: {
21
22
  [key in PlanTypes]: number;
@@ -0,0 +1,26 @@
1
+ import { PlanType, Term } from '../../../graphql.billing.autogenerated';
2
+ export type UpgradeProrationEstimate = {
3
+ newPlanPrice: number;
4
+ remainingValue: number;
5
+ chargeAmount: number;
6
+ remainingDays: number;
7
+ };
8
+ /** True when the target plan/term costs more than the current one for the billing period. */
9
+ export declare function isHigherPricedPlan(params: {
10
+ currentPlanType: PlanType;
11
+ currentTerm: Term;
12
+ targetPlanType: PlanType;
13
+ targetTerm: Term;
14
+ }): boolean;
15
+ /**
16
+ * Estimates Polar-style mid-cycle upgrade charge:
17
+ * (newPeriodPrice − currentPeriodPrice) × remainingFraction, floored at 0.
18
+ */
19
+ export declare function estimateUpgradeProration(params: {
20
+ currentPlanType: PlanType;
21
+ currentTerm: Term;
22
+ targetPlanType: PlanType;
23
+ targetTerm: Term;
24
+ startDate?: string | null;
25
+ endDate?: string | null;
26
+ }): UpgradeProrationEstimate | null;