Skip to content

Commit

Permalink
fix: copy changes to the description and content of modal
Browse files Browse the repository at this point in the history
  • Loading branch information
AmanAgarwal041 committed Jan 13, 2025
1 parent b6f7164 commit 13d9896
Show file tree
Hide file tree
Showing 4 changed files with 24 additions and 16 deletions.
20 changes: 10 additions & 10 deletions app/client/src/ce/constants/messages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2575,34 +2575,34 @@ export const REQUEST_NEW_INTEGRATIONS = {
REQUEST_NEW_BUTTON: () => "Request a new integration",
REQUEST_BUTTON: () => "Request integration",
CANCEL_BUTTON: () => "Cancel",
REQUEST_MODAL_HEADING: () => "Request a new integration",
REQUEST_MODAL_HEADING: () => "Request new integration",
REQUEST_MODAL_INTEGRATION: {
LABEL: () => "Integration",
LABEL: () => "Integration name",
PLACEHOLDER: () => "E.g. Zendesk, JIRA, Slack, others",
NAME: "integration",
ERROR: () => "Please enter integration name",
},
REQUEST_MODAL_USECASE: {
LABEL: () => "Tell us more about your case",
LABEL: () => "How would this integration help you?",
PLACEHOLDER: () =>
"E.g. I want to create an app to manage my customers’ account.",
"For example, organizing client data or automating reports.",
NAME: "useCase",
},
REQUEST_MODAL_EMAIL: {
LABEL: () => "Email",
DESCRIPTION: () =>
"Appsmith will use this email exclusively to follow up on your integration request.",
"We’ll use this email solely to follow up on your request.",
NAME: "email",
ERROR: () => "Please enter email",
},
SUCCESS_TOAST_MESSAGE: () => "Thank you! We are looking into your request.",
};

export const PREMIUM_DATASOURCES = {
RELEVANT_EMAIL_DESCRIPTION: () =>
"Unblock advanced integrations. Let our team guide you in selecting the plan that fits your needs. Schedule a call now to see how Appsmith can transform your workflows!",
NON_RELEVANT_EMAIL_DESCRIPTION: () =>
"Unblock advanced integrations. Let our team guide you in selecting the plan that fits your needs. Give us your email and the Appsmith team will reach out to you soon.",
RELEVANT_EMAIL_DESCRIPTION: (integrationName: string) =>
`Ready to connect with ${integrationName}? This feature is part of our premium plans. Schedule a call with our team to explore the right plan for your needs. We’re excited to help you get started!`,
NON_RELEVANT_EMAIL_DESCRIPTION: (integrationName: string) =>
`Ready to connect with ${integrationName}? This feature is part of our premium plans. We'll help you find a plan that fits your needs. Simply share your email, and we'll be in touch soon.`,
LEARN_MORE: () => "Learn more about Premium",
SCHEDULE_CALL: () => "Schedule a call",
SUBMIT: () => "Submit",
Expand All @@ -2611,7 +2611,7 @@ export const PREMIUM_DATASOURCES = {
FORM_EMAIL: {
LABEL: () => "Email",
DESCRIPTION: () =>
"Appsmith will use this email to follow up on your integration interest.",
"We’ll use this email solely to follow up on your request.",
NAME: "email",
ERROR: () => "Please enter email",
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ const PremiumDatasourceContactForm = (
<Text renderAs="p">
{getContactFormModalDescription(
props.email || "",
props.integrationName,
!isFreePlanInstance,
)}
</Text>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -79,15 +79,22 @@ export const getContactFormModalTitle = (

export const getContactFormModalDescription = (
email: string,
integrationName: string,
isBusinessOrEnterprise?: boolean,
) => {
const validRelevantEmail = isRelevantEmail(email);

return isBusinessOrEnterprise
? createMessage(PREMIUM_DATASOURCES.COMING_SOON_DESCRIPTION)
: validRelevantEmail
? createMessage(PREMIUM_DATASOURCES.RELEVANT_EMAIL_DESCRIPTION)
: createMessage(PREMIUM_DATASOURCES.NON_RELEVANT_EMAIL_DESCRIPTION);
? createMessage(
PREMIUM_DATASOURCES.RELEVANT_EMAIL_DESCRIPTION,
integrationName,
)
: createMessage(
PREMIUM_DATASOURCES.NON_RELEVANT_EMAIL_DESCRIPTION,
integrationName,
);
};

export const shouldLearnMoreButtonBeVisible = (
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import { Button, Flex, toast } from "@appsmith/ads";
import { Button, ModalFooter, toast } from "@appsmith/ads";
import { Close } from "@radix-ui/react-dialog";
import { createMessage, REQUEST_NEW_INTEGRATIONS } from "ee/constants/messages";
import type { AppState } from "ee/reducers";
Expand All @@ -21,7 +21,7 @@ import AnalyticsUtil from "ee/utils/AnalyticsUtil";
const FormWrapper = styled.form`
display: flex;
flex-direction: column;
gap: var(--ads-spaces-7);
gap: var(--ads-spaces-5);
`;

const RequestIntegrationForm = (props: RequestIntegrationFormProps) => {
Expand Down Expand Up @@ -75,7 +75,7 @@ const RequestIntegrationForm = (props: RequestIntegrationFormProps) => {
size="md"
type="email"
/>
<Flex gap="spaces-7" justifyContent="flex-end" marginTop="spaces-3">
<ModalFooter>
<Close>
<Button aria-label="Close" kind="secondary" size="md">
{createMessage(REQUEST_NEW_INTEGRATIONS.CANCEL_BUTTON)}
Expand All @@ -84,7 +84,7 @@ const RequestIntegrationForm = (props: RequestIntegrationFormProps) => {
<Button isDisabled={props.invalid} size="md" type="submit">
{createMessage(REQUEST_NEW_INTEGRATIONS.REQUEST_BUTTON)}
</Button>
</Flex>
</ModalFooter>
</FormWrapper>
);
};
Expand Down

0 comments on commit 13d9896

Please sign in to comment.