@bcrumbs.net/inbox 0.0.52 → 0.0.55
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/{396ba1d86a9997b1.svg → 594c01a9720e0657.svg} +42 -42
- package/assets/ar/inbox.json +263 -256
- package/assets/en/inbox.json +265 -258
- package/{2998ffe42c3436c0.svg → cb9c022b3cf80e0f.svg} +43 -43
- package/index.cjs.d.ts +1 -1
- package/index.cjs.js +5068 -13392
- package/index.esm.d.ts +1 -1
- package/index.esm.js +5071 -13397
- package/package.json +1 -1
- package/src/app/ai/components/CrumbySettings/AutoTagRulesSection.d.ts +14 -0
- package/src/app/ai/components/CrumbySettings/tagRuleUtils.d.ts +28 -0
- package/src/app/auth/components/UserAvatar/AccountSettingsDropdown.d.ts +2 -1
- package/src/app/auth/components/UserAvatar/index.d.ts +2 -1
- package/src/app/auth/pages/CheckAuth.d.ts +10 -0
- package/src/app/auth/pages/Forget.d.ts +1 -3
- package/src/app/auth/pages/Password.d.ts +0 -1
- package/src/app/auth/pages/Profile.d.ts +0 -1
- package/src/app/auth/redux/actions/forgetPasswordAction.d.ts +1 -1
- package/src/app/auth/redux/actions/logoutAction.d.ts +2 -2
- package/src/app/auth/redux/actions/resetPasswordAction.d.ts +2 -2
- package/src/app/auth/redux/auth.types.d.ts +5 -1
- package/src/app/billing/context/SubscriptionContext.d.ts +3 -1
- package/src/app/billing/utils/pendingPlanPurchaseStorage.d.ts +10 -0
- package/src/app/contact/components/ContactFormFields.d.ts +2 -1
- package/src/app/contact/config/contactForm.d.ts +4 -0
- package/src/app/dashboard/components/BroadcastAnalyticsCard.d.ts +2 -1
- package/src/app/dashboard/utils/buildBroadcastReportOverviewAnalytics.d.ts +2 -0
- package/src/app/dashboard/utils/dateHelpers.d.ts +17 -0
- package/src/app/generic/components/HeaderImageInput.d.ts +2 -1
- package/src/app/generic/components/MessagePreview.d.ts +3 -1
- package/src/app/generic/components/PreviewHeaderImage.d.ts +2 -1
- package/src/app/generic/utils/logout.d.ts +1 -1
- package/src/app/inbox/components/Chat/ChatContent.d.ts +1 -3
- package/src/app/inbox/components/Chat/ChatHeader.d.ts +5 -1
- package/src/app/inbox/components/Chat/NoResultsFound.d.ts +3 -0
- package/src/app/inbox/components/Chat/index.d.ts +4 -1
- package/src/app/inbox/components/NewConvList/FilterDrawer.d.ts +2 -3
- package/src/app/inbox/components/NewConvList/HeaderSection.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/ChatDetails.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/ChatDetailsAndTimeline.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/ClientInfo.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/ConversationOverview.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/EditClientInfo.d.ts +3 -2
- package/src/app/inbox/components/NewDetails/index.d.ts +3 -2
- package/src/app/inbox/components/Shared/Inbox.d.ts +9 -7
- package/src/app/inbox/components/Shared/MobileActionSheet.d.ts +9 -0
- package/src/app/inbox/components/Shared/MobileMenu.d.ts +8 -0
- package/src/app/inbox/components/Shared/SharedStyle.d.ts +7 -0
- package/src/app/inbox/components/Shared/mobileMenuStyles.d.ts +20 -0
- package/src/app/inbox/constants/index.d.ts +1 -1
- package/src/app/inbox/hooks/useConversationById.d.ts +8 -0
- package/src/app/inbox/hooks/useInboxAssignableAis.d.ts +3 -0
- package/src/app/inbox/hooks/useMyAgent.d.ts +8 -0
- package/src/app/inbox/utils/convs.d.ts +4 -4
- package/src/app/inbox/utils/inboxAssignableAis.d.ts +10 -0
- package/src/app/inbox/utils/mobileInboxStyles.d.ts +6 -0
- package/src/app/layout/components/Header.d.ts +0 -4
- package/src/app/layout/constants/subMenu.d.ts +12 -2
- package/src/app/layout/context/EmbeddedInboxContext.d.ts +3 -0
- package/src/app/layout/context/MobileInboxNavContext.d.ts +9 -0
- package/src/app/layout/hooks/useMobileInboxVersion.d.ts +1 -3
- package/src/app/managemnet/components/CreateQuickReply.d.ts +8 -0
- package/src/app/managemnet/config/quickReplyDefinition.d.ts +4 -0
- package/src/app/managemnet/pages/quickReplies/index.d.ts +2 -0
- package/src/app/onboarding/utils/onboardingChecklistStorage.d.ts +4 -0
- package/src/app/resources/components/Integrations/Facebook/NoPagesFoundPopup.d.ts +2 -1
- package/src/app/resources/components/Integrations/Facebook/PagePickerPopup.d.ts +2 -1
- package/src/app/subscriptions/components/Plans/PlanCard.d.ts +10 -23
- package/src/app/subscriptions/components/Plans/ShowcasePlans.d.ts +5 -4
- package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionHeader.d.ts +1 -10
- package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionPlanLabel.d.ts +8 -0
- package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionProfileCard.d.ts +14 -0
- package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionUsageCard.d.ts +7 -0
- package/src/app/subscriptions/components/SubscriptionSettings/SubscriptionUsers.d.ts +3 -2
- package/src/app/subscriptions/components/SubscriptionSwitcher/Switcher.d.ts +4 -1
- package/src/app/subscriptions/components/SubscriptionSwitcher/index.d.ts +3 -1
- package/src/app/subscriptions/components/SubscriptionsList.d.ts +1 -0
- package/src/assets/locales/translations.d.ts +62 -0
- package/src/graphql.autogenerated.d.ts +539 -0
- package/src/graphql.billing.autogenerated.d.ts +3 -0
- package/src/lib/EmbeddedMobileMenu.d.ts +9 -0
- package/src/lib/conversation-chat.d.ts +11 -0
- package/src/lib/index.d.ts +4 -0
- package/src/utils/integration.d.ts +6 -0
package/package.json
CHANGED
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { BCDropListOptionsType } from '@bcrumbs.net/bc-ui';
|
|
2
|
+
import { TagType } from '../../../../graphql.autogenerated';
|
|
3
|
+
import { TagRuleDraft } from './tagRuleUtils';
|
|
4
|
+
export interface AutoTagRulesSectionProps {
|
|
5
|
+
title: string;
|
|
6
|
+
type: TagType;
|
|
7
|
+
rules: TagRuleDraft[];
|
|
8
|
+
onChange: (rules: TagRuleDraft[]) => void;
|
|
9
|
+
availableTags: BCDropListOptionsType[];
|
|
10
|
+
refetchTags: () => void;
|
|
11
|
+
defaultExpanded?: boolean;
|
|
12
|
+
}
|
|
13
|
+
declare const AutoTagRulesSection: ({ title, type, rules, onChange, availableTags, refetchTags, defaultExpanded, }: AutoTagRulesSectionProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
14
|
+
export default AutoTagRulesSection;
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export interface TagRuleDraft {
|
|
2
|
+
id: string;
|
|
3
|
+
tag: string;
|
|
4
|
+
rule: string;
|
|
5
|
+
}
|
|
6
|
+
export declare const createTagRuleDraftId: () => `${string}-${string}-${string}-${string}-${string}`;
|
|
7
|
+
export declare const toTagRuleDrafts: (rules?: {
|
|
8
|
+
tag: string;
|
|
9
|
+
rule: string;
|
|
10
|
+
}[] | null) => TagRuleDraft[];
|
|
11
|
+
export declare const normalizeTagRulesForSave: (rules: TagRuleDraft[]) => {
|
|
12
|
+
tag: string;
|
|
13
|
+
rule: string;
|
|
14
|
+
}[];
|
|
15
|
+
export declare const normalizeTagRulesFromConfig: (rules?: {
|
|
16
|
+
tag: string;
|
|
17
|
+
rule: string;
|
|
18
|
+
}[] | null) => {
|
|
19
|
+
tag: string;
|
|
20
|
+
rule: string;
|
|
21
|
+
}[];
|
|
22
|
+
export declare const areTagRulesEqual: (a: {
|
|
23
|
+
tag: string;
|
|
24
|
+
rule: string;
|
|
25
|
+
}[], b: {
|
|
26
|
+
tag: string;
|
|
27
|
+
rule: string;
|
|
28
|
+
}[]) => boolean;
|
|
@@ -8,5 +8,6 @@ export type AccountSettingsProps = {
|
|
|
8
8
|
itemsList: DropdownListItemType[];
|
|
9
9
|
dataTestid?: string;
|
|
10
10
|
userInfo?: any;
|
|
11
|
+
isMobile?: boolean;
|
|
11
12
|
};
|
|
12
|
-
export declare function AccountSettingsDropdown({ url, itemsList, itemClicked, text, color, dataTestid, userInfo }: PropsWithChildren<AccountSettingsProps>): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
13
|
+
export declare function AccountSettingsDropdown({ url, itemsList, itemClicked, text, color, dataTestid, userInfo, isMobile, }: PropsWithChildren<AccountSettingsProps>): import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -5,6 +5,7 @@ export type AccountWrapperProps = {
|
|
|
5
5
|
};
|
|
6
6
|
export type UserAvatarProps = {
|
|
7
7
|
onLogout: () => void;
|
|
8
|
+
isMobile?: boolean;
|
|
8
9
|
};
|
|
9
|
-
declare function UserAvatar({ onLogout }: UserAvatarProps): import("@emotion/react/jsx-runtime").JSX.Element | null;
|
|
10
|
+
declare function UserAvatar({ onLogout, isMobile }: UserAvatarProps): import("@emotion/react/jsx-runtime").JSX.Element | null;
|
|
10
11
|
export default UserAvatar;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Public entry from marketing pricing CTAs (?planType=...).
|
|
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
|
|
8
|
+
*/
|
|
9
|
+
declare const CheckAuth: () => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
10
|
+
export default CheckAuth;
|
|
@@ -2,9 +2,7 @@ export type Props = {
|
|
|
2
2
|
location: any;
|
|
3
3
|
history: any;
|
|
4
4
|
router: any;
|
|
5
|
-
forgetPasswordAction: (
|
|
6
|
-
login: any;
|
|
7
|
-
forgetPassword: any;
|
|
5
|
+
forgetPasswordAction: (email: string, customUrl: string) => any;
|
|
8
6
|
error: any;
|
|
9
7
|
status: any;
|
|
10
8
|
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare function forgetPasswordAction(
|
|
1
|
+
export declare function forgetPasswordAction(email: string, customResetPasswordUrl: string, time?: string): (dispatch: any) => void;
|
|
2
2
|
export declare function successForgetpassword(status: number, success?: any, time?: string): {
|
|
3
3
|
type: string;
|
|
4
4
|
time: string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export declare function setUserLogout(time?: string): {
|
|
1
|
+
export declare function setUserLogout(time?: string): Promise<{
|
|
2
2
|
type: string;
|
|
3
3
|
time: string;
|
|
4
4
|
isAuthenticated: boolean;
|
|
@@ -10,4 +10,4 @@ export declare function setUserLogout(time?: string): {
|
|
|
10
10
|
createdAt: string;
|
|
11
11
|
modifiedAt: string;
|
|
12
12
|
};
|
|
13
|
-
}
|
|
13
|
+
}>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export declare function resetPasswordAction(
|
|
1
|
+
import type { Dispatch } from 'redux';
|
|
2
|
+
export declare function resetPasswordAction(userId: string, token: string, password: string, confirpassword: string, time?: string): (dispatch: Dispatch) => void;
|
|
3
3
|
export declare function successResetpassword(status: number, success?: any, time?: string): {
|
|
4
4
|
type: string;
|
|
5
5
|
time: string;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Dispatch } from 'redux';
|
|
1
2
|
export declare const dateFormat = "dd/MM/yyyy HH:mm";
|
|
2
3
|
export declare const CHECK_IS_USER_IS_AUTHENTICATED = "CHECK_IS_USER_IS_AUTHENTICATED";
|
|
3
4
|
export declare const CHECK_IS_USER_IS_REGISTERED = "CHECK_IS_USER_IS_REGISTERED";
|
|
@@ -59,7 +60,10 @@ export type UnsetLoadingStateForUserRegister = (time: string) => any;
|
|
|
59
60
|
export type SetUserLogout = (time: string) => any;
|
|
60
61
|
export type CheckIfUserIsAuthenticated = (time: string) => any;
|
|
61
62
|
export type ResetLogError = () => any;
|
|
62
|
-
|
|
63
|
+
/** Action creator: returns a thunk (receives Redux `dispatch`). */
|
|
64
|
+
export interface ResetPasswordAction {
|
|
65
|
+
(userId: string, token: string, password: string, confirmPassword: string): (dispatch: Dispatch) => void;
|
|
66
|
+
}
|
|
63
67
|
export type UpdateProfileAction = (action: any, email: string) => any;
|
|
64
68
|
export type SetCurrentUserAction = (userInfo: {
|
|
65
69
|
Email: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { SubscriptionQuery, PlanType } from '../../../graphql.billing.autogenerated';
|
|
2
|
+
import { SubscriptionQuery, PlanType, Term } from '../../../graphql.billing.autogenerated';
|
|
3
3
|
export type CurrentSubscription = SubscriptionQuery['subscription'] | null;
|
|
4
4
|
export interface SubscriptionContextValue {
|
|
5
5
|
/** The current subscription data */
|
|
@@ -10,6 +10,8 @@ export interface SubscriptionContextValue {
|
|
|
10
10
|
error: Error | null;
|
|
11
11
|
/** The current plan type (e.g., 'free', 'basic', 'premium') */
|
|
12
12
|
planType: PlanType | null;
|
|
13
|
+
/** The current billing term (monthly or yearly) */
|
|
14
|
+
currentTerm: Term | null;
|
|
13
15
|
/** Refetch the subscription data */
|
|
14
16
|
refetch: () => void;
|
|
15
17
|
}
|
|
@@ -0,0 +1,10 @@
|
|
|
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
|
+
export declare function setPendingPlanPurchase(planType: string): void;
|
|
5
|
+
export declare function getPendingPlanPurchase(): PlanType | null;
|
|
6
|
+
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;
|
|
@@ -2,8 +2,9 @@ import { Tag } from '../../../graphql.autogenerated';
|
|
|
2
2
|
interface ContactFormFieldsProps {
|
|
3
3
|
renderField: any;
|
|
4
4
|
isEditMode?: boolean;
|
|
5
|
+
isPhoneReadOnly?: boolean;
|
|
5
6
|
renderDroplistField?: any;
|
|
6
7
|
clientStages?: Tag[];
|
|
7
8
|
}
|
|
8
|
-
declare const ContactFormFields: ({ renderField, renderDroplistField, isEditMode, clientStages }: ContactFormFieldsProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
9
|
+
declare const ContactFormFields: ({ renderField, renderDroplistField, isEditMode, isPhoneReadOnly, clientStages, }: ContactFormFieldsProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
9
10
|
export default ContactFormFields;
|
|
@@ -3,6 +3,7 @@ export declare enum FormFields {
|
|
|
3
3
|
name = "name",
|
|
4
4
|
surname = "surname",
|
|
5
5
|
email = "email",
|
|
6
|
+
phone = "phone",
|
|
6
7
|
externalClientId = "externalClientId",
|
|
7
8
|
address = "address",
|
|
8
9
|
country = "country",
|
|
@@ -23,6 +24,9 @@ export declare const FORM_INIT: {
|
|
|
23
24
|
validationType: BCValidationTypes;
|
|
24
25
|
}[];
|
|
25
26
|
};
|
|
27
|
+
phone: {
|
|
28
|
+
value: string;
|
|
29
|
+
};
|
|
26
30
|
externalClientId: {
|
|
27
31
|
value: string;
|
|
28
32
|
validations: {
|
|
@@ -5,6 +5,7 @@ interface BroadcastAnalyticsCardProps {
|
|
|
5
5
|
reportNodes: BroadcastReportFragment[];
|
|
6
6
|
integrationId?: string;
|
|
7
7
|
loading?: boolean;
|
|
8
|
+
selectedPeriod: string;
|
|
8
9
|
}
|
|
9
|
-
declare const BroadcastAnalyticsCard: ({ startDate, endDate, reportNodes, integrationId, loading, }: BroadcastAnalyticsCardProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare const BroadcastAnalyticsCard: ({ startDate, endDate, reportNodes, integrationId, loading, selectedPeriod, }: BroadcastAnalyticsCardProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
10
11
|
export default BroadcastAnalyticsCard;
|
|
@@ -13,5 +13,7 @@ export interface BroadcastReportOverviewAnalytics {
|
|
|
13
13
|
}
|
|
14
14
|
export interface BuildBroadcastReportOverviewOptions {
|
|
15
15
|
integrationId?: string;
|
|
16
|
+
/** Must match the dashboard period preset so the prior window matches the header dropdown (e.g. last month vs February). */
|
|
17
|
+
selectedPeriod?: string;
|
|
16
18
|
}
|
|
17
19
|
export declare function buildBroadcastReportOverviewAnalytics(reportNodes: BroadcastReportFragment[], startDate: string, endDate: string, options?: BuildBroadcastReportOverviewOptions): BroadcastReportOverviewAnalytics;
|
|
@@ -4,4 +4,21 @@ export declare const getDateRange: (period?: string) => {
|
|
|
4
4
|
startDate?: string;
|
|
5
5
|
endDate?: string;
|
|
6
6
|
};
|
|
7
|
+
/** Bounds for the period immediately before the current dashboard range (used for trend %). */
|
|
8
|
+
export type PreviousComparisonPeriod = {
|
|
9
|
+
start: Date;
|
|
10
|
+
end: Date;
|
|
11
|
+
/** When true, treat the range as [start, end) so the instant `end` belongs to the current period. */
|
|
12
|
+
endExclusive: boolean;
|
|
13
|
+
};
|
|
14
|
+
/**
|
|
15
|
+
* Calendar month presets compare to the full calendar month before the selected month.
|
|
16
|
+
* `thisMonth` and `last7Days` compare to an equal-duration window ending where the current range starts.
|
|
17
|
+
*/
|
|
18
|
+
export declare const getPreviousComparisonPeriod: (period?: string) => PreviousComparisonPeriod | null;
|
|
19
|
+
/** Widest ISO range needed to load both the selected period and its comparison period for broadcast reports. */
|
|
20
|
+
export declare const getBroadcastReportQueryDateRange: (period?: string) => {
|
|
21
|
+
startDate?: string;
|
|
22
|
+
endDate?: string;
|
|
23
|
+
};
|
|
7
24
|
export declare const formatTime: (seconds: number) => string;
|
|
@@ -3,6 +3,7 @@ type HeaderImageInputProps = {
|
|
|
3
3
|
value: string;
|
|
4
4
|
onChange: (value: string) => void;
|
|
5
5
|
hint?: string;
|
|
6
|
+
layout?: 'row' | 'column';
|
|
6
7
|
};
|
|
7
|
-
declare const _default: React.MemoExoticComponent<({ value, onChange, hint }: HeaderImageInputProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
8
|
+
declare const _default: React.MemoExoticComponent<({ value, onChange, hint, layout }: HeaderImageInputProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
8
9
|
export default _default;
|
|
@@ -22,6 +22,8 @@ interface MessagePreviewProps {
|
|
|
22
22
|
showHeader?: boolean;
|
|
23
23
|
showDate?: boolean;
|
|
24
24
|
minHeight?: number;
|
|
25
|
+
showImagePlaceholder?: boolean;
|
|
26
|
+
compactBubble?: boolean;
|
|
25
27
|
}
|
|
26
|
-
declare const _default: React.MemoExoticComponent<({ components, parameterValues, timestamp, dateLabel, contactName, contactSubtitle, loading, showHeader, showDate, minHeight, }: MessagePreviewProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
28
|
+
declare const _default: React.MemoExoticComponent<({ components, parameterValues, timestamp, dateLabel, contactName, contactSubtitle, loading, showHeader, showDate, minHeight, showImagePlaceholder, compactBubble, }: MessagePreviewProps) => import("@emotion/react/jsx-runtime").JSX.Element>;
|
|
27
29
|
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function logout(withoutRedirect?: boolean): void
|
|
1
|
+
export declare function logout(withoutRedirect?: boolean): Promise<void>;
|
|
@@ -2,9 +2,7 @@ import { ContactMessagePayload, Message, MessageType } from '../../../../graphql
|
|
|
2
2
|
interface ChatContentProps {
|
|
3
3
|
messages: Message[];
|
|
4
4
|
olderMessages?: Message[];
|
|
5
|
-
msgsLoading: boolean;
|
|
6
5
|
canContribute: boolean;
|
|
7
|
-
onConvEnd?: () => void;
|
|
8
6
|
sendMessage: (type: MessageType, content: string) => Promise<void>;
|
|
9
7
|
loadOlderMessages: () => void;
|
|
10
8
|
agentsIdsAvatarsMap: Record<string, string>;
|
|
@@ -31,5 +29,5 @@ interface ChatContentProps {
|
|
|
31
29
|
/** Called when user clicks "Add Contact" on a contact message card */
|
|
32
30
|
onContactAddContact?: (contact: ContactMessagePayload) => void;
|
|
33
31
|
}
|
|
34
|
-
declare const ChatContent: ({ messages, olderMessages,
|
|
32
|
+
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
33
|
export default ChatContent;
|
|
@@ -2,12 +2,16 @@ import React from 'react';
|
|
|
2
2
|
import { Conversation } from '../../../../../src/graphql.autogenerated';
|
|
3
3
|
interface Props {
|
|
4
4
|
selectedConv: Conversation;
|
|
5
|
-
onConvEnd
|
|
5
|
+
onConvEnd?: () => void;
|
|
6
|
+
showEndConversationButton?: boolean;
|
|
6
7
|
searchPattern?: string;
|
|
7
8
|
onSearchChange?: (value: string) => void;
|
|
8
9
|
searchMatchNo?: number;
|
|
9
10
|
onSearchMatchChange?: (matchNo: number) => void;
|
|
10
11
|
searchMatchCount?: number;
|
|
12
|
+
showOlderMessagesButton?: boolean;
|
|
13
|
+
isLoadingOlderMessages?: boolean;
|
|
14
|
+
onLoadOlderMessages?: () => void;
|
|
11
15
|
}
|
|
12
16
|
export declare const HeaderContainer: import("styled-components").StyledComponent<({ distance, alignItems, justifyContent, marginTop, marginRight, marginBottom, marginLeft, spaceBetween, overflow, children, width, height, dataTestid, minWidth, className, rtl, }: React.PropsWithChildren<import("@bcrumbs.net/bc-ui").HorizontalLayoutProps>) => import("@emotion/react/jsx-runtime").JSX.Element, any, {
|
|
13
17
|
rtl: boolean;
|
|
@@ -8,10 +8,13 @@ interface Props {
|
|
|
8
8
|
convsLength?: number;
|
|
9
9
|
loadingConvs?: boolean;
|
|
10
10
|
handleStartConversation?: () => void;
|
|
11
|
+
showNoResults?: boolean;
|
|
11
12
|
/** Called when user clicks "Message" on a contact message card */
|
|
12
13
|
onContactMessage?: (contact: ContactMessagePayload) => void;
|
|
13
14
|
/** Called when user clicks "Add Contact" on a contact message card */
|
|
14
15
|
onContactAddContact?: (contact: ContactMessagePayload) => void;
|
|
16
|
+
/** When false, hides the chat header (search, end conversation, etc.). Default true. */
|
|
17
|
+
showHeader?: boolean;
|
|
15
18
|
}
|
|
16
|
-
declare const Chat: ({ selectedConv, onConvEnd, agents, logo, rtl, convsLength, loadingConvs, handleStartConversation, onContactMessage, onContactAddContact, }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
19
|
+
declare const Chat: ({ selectedConv, onConvEnd, agents, logo, rtl, convsLength, loadingConvs, handleStartConversation, showNoResults, onContactMessage, onContactAddContact, showHeader, }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
17
20
|
export default Chat;
|
|
@@ -9,10 +9,9 @@ interface FilterDrawerProps {
|
|
|
9
9
|
convStages: Tag[];
|
|
10
10
|
integrations: Integration[];
|
|
11
11
|
myAgent: Agent | undefined;
|
|
12
|
-
|
|
13
|
-
isCrumbyEnabled: boolean;
|
|
12
|
+
assignableAis: Ai[];
|
|
14
13
|
rtl: boolean;
|
|
15
14
|
conversations: Conversation[];
|
|
16
15
|
}
|
|
17
|
-
declare const FilterDrawer: ({ isOpen, onClose, filters, onFiltersChange, agents, convStages, integrations, myAgent,
|
|
16
|
+
declare const FilterDrawer: ({ isOpen, onClose, filters, onFiltersChange, agents, convStages, integrations, myAgent, assignableAis, rtl, conversations, }: FilterDrawerProps) => import("@emotion/react/jsx-runtime").JSX.Element | null;
|
|
18
17
|
export default FilterDrawer;
|
|
@@ -10,10 +10,11 @@ interface HeaderSectionProps {
|
|
|
10
10
|
myAgent: Agent | undefined;
|
|
11
11
|
onFiltersChange: (filters: ConvsFilters) => void;
|
|
12
12
|
setShowStartConv: (show: boolean) => void;
|
|
13
|
-
|
|
13
|
+
/** Used to resolve the assignee filter label when filtering by AI */
|
|
14
|
+
aiAgents?: Ai[];
|
|
14
15
|
isTestVariant?: boolean;
|
|
15
16
|
isDrawerOpen?: boolean;
|
|
16
17
|
onFilterDrawerOpen?: () => void;
|
|
17
18
|
}
|
|
18
|
-
declare const HeaderSection: ({ agentsMenu, lifeCycleMenu, filters, agents, convStages, myAgent, onFiltersChange, setShowStartConv,
|
|
19
|
+
declare const HeaderSection: ({ agentsMenu, lifeCycleMenu, filters, agents, convStages, myAgent, onFiltersChange, setShowStartConv, aiAgents, isTestVariant, isDrawerOpen, onFilterDrawerOpen, }: HeaderSectionProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
19
20
|
export default HeaderSection;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Agent, Ai, Conversation, Tag } from '../../../../graphql.autogenerated';
|
|
2
2
|
interface ChatDetailsProps {
|
|
3
3
|
conversationTags: Tag[];
|
|
4
4
|
tagsLoading: boolean;
|
|
@@ -7,9 +7,10 @@ interface ChatDetailsProps {
|
|
|
7
7
|
interface ChatDetailsProps {
|
|
8
8
|
conv: Conversation;
|
|
9
9
|
agents: Agent[];
|
|
10
|
+
aiAgents?: Ai[];
|
|
10
11
|
convStages: Tag[];
|
|
11
12
|
onUpdate?: () => void;
|
|
12
13
|
convEnded: boolean;
|
|
13
14
|
}
|
|
14
|
-
declare const ChatDetails: ({ conv, agents, convStages, onUpdate, conversationTags, tagsLoading, refetchTags, convEnded, }: ChatDetailsProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
15
|
+
declare const ChatDetails: ({ conv, agents, aiAgents, convStages, onUpdate, conversationTags, tagsLoading, refetchTags, convEnded, }: ChatDetailsProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
15
16
|
export default ChatDetails;
|
|
@@ -1,7 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Ai, Agent, Conversation, Tag } from '../../../../graphql.autogenerated';
|
|
2
2
|
interface ChatDetailsAndTimelineProps {
|
|
3
3
|
conv: Conversation;
|
|
4
4
|
agents: Agent[];
|
|
5
|
+
aiAgents?: Ai[];
|
|
5
6
|
convStages: Tag[];
|
|
6
7
|
onUpdate?: () => void;
|
|
7
8
|
conversationTags: Tag[];
|
|
@@ -9,5 +10,5 @@ interface ChatDetailsAndTimelineProps {
|
|
|
9
10
|
refetchTags: () => void;
|
|
10
11
|
convEnded: boolean;
|
|
11
12
|
}
|
|
12
|
-
declare const ChatDetailsAndTimeline: ({ conv, agents, convStages, onUpdate, conversationTags, tagsLoading, refetchTags, convEnded, }: ChatDetailsAndTimelineProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
13
|
+
declare const ChatDetailsAndTimeline: ({ conv, agents, aiAgents, convStages, onUpdate, conversationTags, tagsLoading, refetchTags, convEnded, }: ChatDetailsAndTimelineProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
13
14
|
export default ChatDetailsAndTimeline;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Tag, ClientQuery } from '../../../../graphql.autogenerated';
|
|
1
|
+
import { Tag, ClientQuery, IntegrationType } from '../../../../graphql.autogenerated';
|
|
2
2
|
interface ClientInfoProps {
|
|
3
3
|
clientData: ClientQuery['client'] | undefined;
|
|
4
4
|
clientTags: Tag[];
|
|
@@ -9,6 +9,7 @@ interface ClientInfoProps {
|
|
|
9
9
|
setEditMode: (editMode: boolean) => void;
|
|
10
10
|
loading: boolean;
|
|
11
11
|
refetch: () => void;
|
|
12
|
+
integrationType?: IntegrationType;
|
|
12
13
|
}
|
|
13
|
-
declare const ClientInfo: ({ clientData, loading, clientTags, conversationTags, tagsLoading, refetchTags, editMode, setEditMode, refetch, }: ClientInfoProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
14
|
+
declare const ClientInfo: ({ clientData, loading, clientTags, conversationTags, tagsLoading, refetchTags, editMode, setEditMode, refetch, integrationType, }: ClientInfoProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
14
15
|
export default ClientInfo;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Agent, Ai, Conversation, Tag } from '../../../../graphql.autogenerated';
|
|
2
2
|
interface ConversationOverviewProps {
|
|
3
3
|
conv: Conversation;
|
|
4
4
|
agents: Agent[];
|
|
5
|
+
aiAgents?: Ai[];
|
|
5
6
|
convStages: Tag[];
|
|
6
7
|
onUpdate?: () => void;
|
|
7
8
|
convEnded: boolean;
|
|
8
9
|
}
|
|
9
|
-
declare const ConversationOverview: ({ conv, agents, convStages, onUpdate, convEnded }: ConversationOverviewProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
10
|
+
declare const ConversationOverview: ({ conv, agents, aiAgents, convStages, onUpdate, convEnded, }: ConversationOverviewProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
10
11
|
export default ConversationOverview;
|
|
@@ -1,8 +1,9 @@
|
|
|
1
|
-
import { ClientQuery } from '../../../../graphql.autogenerated';
|
|
1
|
+
import { ClientQuery, IntegrationType } from '../../../../graphql.autogenerated';
|
|
2
2
|
interface EditInfoProps {
|
|
3
3
|
setEditMode: (editMode: boolean) => void;
|
|
4
4
|
clientData: ClientQuery['client'];
|
|
5
5
|
onClientUpdate?: () => void;
|
|
6
|
+
integrationType?: IntegrationType;
|
|
6
7
|
}
|
|
7
|
-
declare const EditClientInfo: ({ setEditMode, clientData, onClientUpdate }: EditInfoProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
8
|
+
declare const EditClientInfo: ({ setEditMode, clientData, onClientUpdate, integrationType }: EditInfoProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
8
9
|
export default EditClientInfo;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
-
import {
|
|
2
|
+
import { Ai, Agent, Conversation, Tag } from '../../../../graphql.autogenerated';
|
|
3
3
|
interface Props {
|
|
4
4
|
conv: Conversation;
|
|
5
5
|
clientTags: Tag[];
|
|
@@ -7,9 +7,10 @@ interface Props {
|
|
|
7
7
|
tagsLoading: boolean;
|
|
8
8
|
refetchTags: () => void;
|
|
9
9
|
agents: Agent[];
|
|
10
|
+
aiAgents?: Ai[];
|
|
10
11
|
convStages: Tag[];
|
|
11
12
|
onUpdate?: () => void;
|
|
12
13
|
clientSectionPlaceholder?: React.ReactNode;
|
|
13
14
|
}
|
|
14
|
-
declare const NewDetails: ({ conv, clientTags, conversationTags, tagsLoading, refetchTags, agents, convStages, onUpdate, clientSectionPlaceholder, }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
15
|
+
declare const NewDetails: ({ conv, clientTags, conversationTags, tagsLoading, refetchTags, agents, aiAgents, convStages, onUpdate, clientSectionPlaceholder, }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
15
16
|
export default NewDetails;
|
|
@@ -1,4 +1,7 @@
|
|
|
1
1
|
/// <reference types="react" />
|
|
2
|
+
export { MobileMenu } from './MobileMenu';
|
|
3
|
+
export type { MobileViews } from './mobileMenuStyles';
|
|
4
|
+
export { mobileNavbar } from './mobileMenuStyles';
|
|
2
5
|
export declare const defaultSelectedConvId: any;
|
|
3
6
|
export declare const MobileWrapper: import("@emotion/styled").StyledComponent<{
|
|
4
7
|
theme?: import("@emotion/react").Theme | undefined;
|
|
@@ -7,12 +10,11 @@ export declare const MobileWrapper: import("@emotion/styled").StyledComponent<{
|
|
|
7
10
|
export declare const MobileContent: import("@emotion/styled").StyledComponent<{
|
|
8
11
|
theme?: import("@emotion/react").Theme | undefined;
|
|
9
12
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
13
|
+
} & {
|
|
14
|
+
$reserveBottomNavSpace?: boolean | undefined;
|
|
10
15
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
11
|
-
export declare const InboxNoSelectionContainer: (
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
activePage: MobileViews;
|
|
16
|
-
setActivePage: (page: MobileViews) => void;
|
|
17
|
-
hideDetails?: boolean;
|
|
16
|
+
export declare const InboxNoSelectionContainer: ({ convsLength, loadingConvs, handleStartConversation, }: {
|
|
17
|
+
convsLength?: number;
|
|
18
|
+
loadingConvs?: boolean;
|
|
19
|
+
handleStartConversation?: () => void;
|
|
18
20
|
}) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { ActionItem } from '@bcrumbs.net/bc-ui';
|
|
2
|
+
type Props = {
|
|
3
|
+
open: boolean;
|
|
4
|
+
title: string;
|
|
5
|
+
actions: ActionItem[];
|
|
6
|
+
onClose: () => void;
|
|
7
|
+
};
|
|
8
|
+
export declare const MobileActionSheet: ({ open, title, actions, onClose }: Props) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { MobileViews } from './mobileMenuStyles';
|
|
2
|
+
export type { MobileViews };
|
|
3
|
+
type MobileMenuProps = {
|
|
4
|
+
activePage: MobileViews;
|
|
5
|
+
setActivePage: (page: MobileViews) => void;
|
|
6
|
+
hideDetails?: boolean;
|
|
7
|
+
};
|
|
8
|
+
export declare const MobileMenu: ({ activePage, setActivePage, hideDetails }: MobileMenuProps) => import("@emotion/react/jsx-runtime").JSX.Element;
|
|
@@ -7,6 +7,8 @@ export declare const SectionContainer: import("@emotion/styled").StyledComponent
|
|
|
7
7
|
export declare const DetailsSectionLabel: import("@emotion/styled").StyledComponent<{
|
|
8
8
|
theme?: import("@emotion/react").Theme | undefined;
|
|
9
9
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
10
|
+
} & {
|
|
11
|
+
$isMobile?: boolean | undefined;
|
|
10
12
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
11
13
|
export declare const EditButton: import("@emotion/styled").StyledComponent<import("@bcrumbs.net/bc-ui").ButtonProps & import("react").RefAttributes<HTMLButtonElement> & {
|
|
12
14
|
theme?: import("@emotion/react").Theme | undefined;
|
|
@@ -14,6 +16,8 @@ export declare const EditButton: import("@emotion/styled").StyledComponent<impor
|
|
|
14
16
|
export declare const TagContainer: import("@emotion/styled").StyledComponent<{
|
|
15
17
|
theme?: import("@emotion/react").Theme | undefined;
|
|
16
18
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
19
|
+
} & {
|
|
20
|
+
$isMobile?: boolean | undefined;
|
|
17
21
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
18
22
|
export declare const ClientDetailsContainer: import("@emotion/styled").StyledComponent<{
|
|
19
23
|
theme?: import("@emotion/react").Theme | undefined;
|
|
@@ -24,8 +28,11 @@ export declare const ClientDetailsItem: import("@emotion/styled").StyledComponen
|
|
|
24
28
|
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
25
29
|
} & {
|
|
26
30
|
highlight?: boolean | undefined;
|
|
31
|
+
$isMobile?: boolean | undefined;
|
|
27
32
|
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLDivElement>, HTMLDivElement>, {}>;
|
|
33
|
+
export declare const getClientDetailsItemCss: (isMobile: boolean) => import("@emotion/react").SerializedStyles;
|
|
28
34
|
export declare const clientDetailsItemCss: import("@emotion/react").SerializedStyles;
|
|
35
|
+
export declare const getClientDetailsItemPhoneCss: (isMobile: boolean) => import("@emotion/react").SerializedStyles;
|
|
29
36
|
export declare const clientDetailsItemPhoneCss: import("@emotion/react").SerializedStyles;
|
|
30
37
|
export declare const createImageContainerStyle: (width: number | string, height: number | string, fontSize?: TextSizeRem, LineHeight?: LineHeightRem) => import("@emotion/react").SerializedStyles;
|
|
31
38
|
export declare const ArchivedLabelStyle: import("@emotion/styled").StyledComponent<{
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
export type MobileViews = 'convList' | 'chat' | 'details';
|
|
3
|
+
export declare const mobileNavbar: {
|
|
4
|
+
Wrapper: import("@emotion/styled").StyledComponent<{
|
|
5
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
6
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
7
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLElement>, HTMLElement>, {}>;
|
|
8
|
+
Items: import("@emotion/styled").StyledComponent<{
|
|
9
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
10
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
11
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLUListElement>, HTMLUListElement>, {}>;
|
|
12
|
+
Item: import("@emotion/styled").StyledComponent<{
|
|
13
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
14
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
15
|
+
}, import("react").DetailedHTMLProps<import("react").LiHTMLAttributes<HTMLLIElement>, HTMLLIElement>, {}>;
|
|
16
|
+
Icon: import("@emotion/styled").StyledComponent<{
|
|
17
|
+
theme?: import("@emotion/react").Theme | undefined;
|
|
18
|
+
as?: import("react").ElementType<any, keyof import("react").JSX.IntrinsicElements> | undefined;
|
|
19
|
+
}, import("react").DetailedHTMLProps<import("react").HTMLAttributes<HTMLSpanElement>, HTMLSpanElement>, {}>;
|
|
20
|
+
};
|
|
@@ -15,7 +15,7 @@ export declare const WABA_TEMPLATE_COSTS: {
|
|
|
15
15
|
UTILITY: number;
|
|
16
16
|
AUTHENTIC: number;
|
|
17
17
|
};
|
|
18
|
-
export declare const CONVERSATIONS_LIMIT =
|
|
18
|
+
export declare const CONVERSATIONS_LIMIT = 300;
|
|
19
19
|
export declare const WhatsappLanguageCodes: {
|
|
20
20
|
ar: string;
|
|
21
21
|
en: string;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Conversation } from '../../../graphql.autogenerated';
|
|
2
|
+
declare function useConversationById(convId: string | undefined, skip?: boolean): {
|
|
3
|
+
conversation: Conversation | undefined;
|
|
4
|
+
loading: boolean;
|
|
5
|
+
error: import("@apollo/client").ApolloError | undefined;
|
|
6
|
+
refetch: () => void;
|
|
7
|
+
};
|
|
8
|
+
export default useConversationById;
|